1 #!/bin/bash 2 # 3 # ########################################################## 4 # ### THIS FILE IS AUTOMATICALLY GENERATED. DO NOT EDIT. ### 5 # ########################################################## 6 # 7 #! /bin/sh 8 # Guess values for system-dependent variables and create Makefiles. 9 # Generated by GNU Autoconf 2.69 for OpenJDK jdk9. 10 # 11 # Report bugs to <build-dev@openjdk.java.net>. 12 # 13 # 14 # Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc. 15 # 16 # 17 # This configure script is free software; the Free Software Foundation 18 # gives unlimited permission to copy, distribute and modify it. 19 ## -------------------- ## 20 ## M4sh Initialization. ## 21 ## -------------------- ## 22 23 # Be more Bourne compatible 24 DUALCASE=1; export DUALCASE # for MKS sh 25 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : 26 emulate sh 27 NULLCMD=: 28 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which 29 # is contrary to our usage. Disable this feature. 30 alias -g '${1+"$@"}'='"$@"' 31 setopt NO_GLOB_SUBST 32 else 33 case `(set -o) 2>/dev/null` in #( 34 *posix*) : 35 set -o posix ;; #( 36 *) : 37 ;; 38 esac 39 fi 40 41 42 as_nl=' 43 ' 44 export as_nl 45 # Printing a long string crashes Solaris 7 /usr/bin/printf. 46 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' 47 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo 48 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo 49 # Prefer a ksh shell builtin over an external printf program on Solaris, 50 # but without wasting forks for bash or zsh. 51 if test -z "$BASH_VERSION$ZSH_VERSION" \ 52 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then 53 as_echo='print -r --' 54 as_echo_n='print -rn --' 55 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then 56 as_echo='printf %s\n' 57 as_echo_n='printf %s' 58 else 59 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then 60 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' 61 as_echo_n='/usr/ucb/echo -n' 62 else 63 as_echo_body='eval expr "X$1" : "X\\(.*\\)"' 64 as_echo_n_body='eval 65 arg=$1; 66 case $arg in #( 67 *"$as_nl"*) 68 expr "X$arg" : "X\\(.*\\)$as_nl"; 69 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; 70 esac; 71 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" 72 ' 73 export as_echo_n_body 74 as_echo_n='sh -c $as_echo_n_body as_echo' 75 fi 76 export as_echo_body 77 as_echo='sh -c $as_echo_body as_echo' 78 fi 79 80 # The user is always right. 81 if test "${PATH_SEPARATOR+set}" != set; then 82 PATH_SEPARATOR=: 83 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { 84 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || 85 PATH_SEPARATOR=';' 86 } 87 fi 88 89 90 # IFS 91 # We need space, tab and new line, in precisely that order. Quoting is 92 # there to prevent editors from complaining about space-tab. 93 # (If _AS_PATH_WALK were called with IFS unset, it would disable word 94 # splitting by setting IFS to empty value.) 95 IFS=" "" $as_nl" 96 97 # Find who we are. Look in the path if we contain no directory separator. 98 as_myself= 99 case $0 in #(( 100 *[\\/]* ) as_myself=$0 ;; 101 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 102 for as_dir in $PATH 103 do 104 IFS=$as_save_IFS 105 test -z "$as_dir" && as_dir=. 106 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break 107 done 108 IFS=$as_save_IFS 109 110 ;; 111 esac 112 # We did not find ourselves, most probably we were run as `sh COMMAND' 113 # in which case we are not to be found in the path. 114 if test "x$as_myself" = x; then 115 as_myself=$0 116 fi 117 if test ! -f "$as_myself"; then 118 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 119 exit 1 120 fi 121 122 # Unset variables that we do not need and which cause bugs (e.g. in 123 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" 124 # suppresses any "Segmentation fault" message there. '((' could 125 # trigger a bug in pdksh 5.2.14. 126 for as_var in BASH_ENV ENV MAIL MAILPATH 127 do eval test x\${$as_var+set} = xset \ 128 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : 129 done 130 PS1='$ ' 131 PS2='> ' 132 PS4='+ ' 133 134 # NLS nuisances. 135 LC_ALL=C 136 export LC_ALL 137 LANGUAGE=C 138 export LANGUAGE 139 140 # CDPATH. 141 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH 142 143 # Use a proper internal environment variable to ensure we don't fall 144 # into an infinite loop, continuously re-executing ourselves. 145 if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then 146 _as_can_reexec=no; export _as_can_reexec; 147 # We cannot yet assume a decent shell, so we have to provide a 148 # neutralization value for shells without unset; and this also 149 # works around shells that cannot unset nonexistent variables. 150 # Preserve -v and -x to the replacement shell. 151 BASH_ENV=/dev/null 152 ENV=/dev/null 153 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV 154 case $- in # (((( 155 *v*x* | *x*v* ) as_opts=-vx ;; 156 *v* ) as_opts=-v ;; 157 *x* ) as_opts=-x ;; 158 * ) as_opts= ;; 159 esac 160 exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} 161 # Admittedly, this is quite paranoid, since all the known shells bail 162 # out after a failed `exec'. 163 $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 164 as_fn_exit 255 165 fi 166 # We don't want this to propagate to other subprocesses. 167 { _as_can_reexec=; unset _as_can_reexec;} 168 if test "x$CONFIG_SHELL" = x; then 169 as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then : 170 emulate sh 171 NULLCMD=: 172 # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which 173 # is contrary to our usage. Disable this feature. 174 alias -g '\${1+\"\$@\"}'='\"\$@\"' 175 setopt NO_GLOB_SUBST 176 else 177 case \`(set -o) 2>/dev/null\` in #( 178 *posix*) : 179 set -o posix ;; #( 180 *) : 181 ;; 182 esac 183 fi 184 " 185 as_required="as_fn_return () { (exit \$1); } 186 as_fn_success () { as_fn_return 0; } 187 as_fn_failure () { as_fn_return 1; } 188 as_fn_ret_success () { return 0; } 189 as_fn_ret_failure () { return 1; } 190 191 exitcode=0 192 as_fn_success || { exitcode=1; echo as_fn_success failed.; } 193 as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; } 194 as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; } 195 as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; } 196 if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then : 197 198 else 199 exitcode=1; echo positional parameters were not saved. 200 fi 201 test x\$exitcode = x0 || exit 1 202 test -x / || exit 1" 203 as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO 204 as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO 205 eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && 206 test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1 207 test \$(( 1 + 1 )) = 2 || exit 1" 208 if (eval "$as_required") 2>/dev/null; then : 209 as_have_required=yes 210 else 211 as_have_required=no 212 fi 213 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then : 214 215 else 216 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 217 as_found=false 218 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH 219 do 220 IFS=$as_save_IFS 221 test -z "$as_dir" && as_dir=. 222 as_found=: 223 case $as_dir in #( 224 /*) 225 for as_base in sh bash ksh sh5; do 226 # Try only shells that exist, to save several forks. 227 as_shell=$as_dir/$as_base 228 if { test -f "$as_shell" || test -f "$as_shell.exe"; } && 229 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then : 230 CONFIG_SHELL=$as_shell as_have_required=yes 231 if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then : 232 break 2 233 fi 234 fi 235 done;; 236 esac 237 as_found=false 238 done 239 $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } && 240 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then : 241 CONFIG_SHELL=$SHELL as_have_required=yes 242 fi; } 243 IFS=$as_save_IFS 244 245 246 if test "x$CONFIG_SHELL" != x; then : 247 export CONFIG_SHELL 248 # We cannot yet assume a decent shell, so we have to provide a 249 # neutralization value for shells without unset; and this also 250 # works around shells that cannot unset nonexistent variables. 251 # Preserve -v and -x to the replacement shell. 252 BASH_ENV=/dev/null 253 ENV=/dev/null 254 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV 255 case $- in # (((( 256 *v*x* | *x*v* ) as_opts=-vx ;; 257 *v* ) as_opts=-v ;; 258 *x* ) as_opts=-x ;; 259 * ) as_opts= ;; 260 esac 261 exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} 262 # Admittedly, this is quite paranoid, since all the known shells bail 263 # out after a failed `exec'. 264 $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 265 exit 255 266 fi 267 268 if test x$as_have_required = xno; then : 269 $as_echo "$0: This script requires a shell more modern than all" 270 $as_echo "$0: the shells that I found on your system." 271 if test x${ZSH_VERSION+set} = xset ; then 272 $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should" 273 $as_echo "$0: be upgraded to zsh 4.3.4 or later." 274 else 275 $as_echo "$0: Please tell bug-autoconf@gnu.org and 276 $0: build-dev@openjdk.java.net about your system, including 277 $0: any error possibly output before this message. Then 278 $0: install a modern shell, or manually run the script 279 $0: under such a shell if you do have one." 280 fi 281 exit 1 282 fi 283 fi 284 fi 285 SHELL=${CONFIG_SHELL-/bin/sh} 286 export SHELL 287 # Unset more variables known to interfere with behavior of common tools. 288 CLICOLOR_FORCE= GREP_OPTIONS= 289 unset CLICOLOR_FORCE GREP_OPTIONS 290 291 ## --------------------- ## 292 ## M4sh Shell Functions. ## 293 ## --------------------- ## 294 # as_fn_unset VAR 295 # --------------- 296 # Portably unset VAR. 297 as_fn_unset () 298 { 299 { eval $1=; unset $1;} 300 } 301 as_unset=as_fn_unset 302 303 # as_fn_set_status STATUS 304 # ----------------------- 305 # Set $? to STATUS, without forking. 306 as_fn_set_status () 307 { 308 return $1 309 } # as_fn_set_status 310 311 # as_fn_exit STATUS 312 # ----------------- 313 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. 314 as_fn_exit () 315 { 316 set +e 317 as_fn_set_status $1 318 exit $1 319 } # as_fn_exit 320 321 # as_fn_mkdir_p 322 # ------------- 323 # Create "$as_dir" as a directory, including parents if necessary. 324 as_fn_mkdir_p () 325 { 326 327 case $as_dir in #( 328 -*) as_dir=./$as_dir;; 329 esac 330 test -d "$as_dir" || eval $as_mkdir_p || { 331 as_dirs= 332 while :; do 333 case $as_dir in #( 334 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( 335 *) as_qdir=$as_dir;; 336 esac 337 as_dirs="'$as_qdir' $as_dirs" 338 as_dir=`$as_dirname -- "$as_dir" || 339 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 340 X"$as_dir" : 'X\(//\)[^/]' \| \ 341 X"$as_dir" : 'X\(//\)$' \| \ 342 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || 343 $as_echo X"$as_dir" | 344 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 345 s//\1/ 346 q 347 } 348 /^X\(\/\/\)[^/].*/{ 349 s//\1/ 350 q 351 } 352 /^X\(\/\/\)$/{ 353 s//\1/ 354 q 355 } 356 /^X\(\/\).*/{ 357 s//\1/ 358 q 359 } 360 s/.*/./; q'` 361 test -d "$as_dir" && break 362 done 363 test -z "$as_dirs" || eval "mkdir $as_dirs" 364 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" 365 366 367 } # as_fn_mkdir_p 368 369 # as_fn_executable_p FILE 370 # ----------------------- 371 # Test if FILE is an executable regular file. 372 as_fn_executable_p () 373 { 374 test -f "$1" && test -x "$1" 375 } # as_fn_executable_p 376 # as_fn_append VAR VALUE 377 # ---------------------- 378 # Append the text in VALUE to the end of the definition contained in VAR. Take 379 # advantage of any shell optimizations that allow amortized linear growth over 380 # repeated appends, instead of the typical quadratic growth present in naive 381 # implementations. 382 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : 383 eval 'as_fn_append () 384 { 385 eval $1+=\$2 386 }' 387 else 388 as_fn_append () 389 { 390 eval $1=\$$1\$2 391 } 392 fi # as_fn_append 393 394 # as_fn_arith ARG... 395 # ------------------ 396 # Perform arithmetic evaluation on the ARGs, and store the result in the 397 # global $as_val. Take advantage of shells that can avoid forks. The arguments 398 # must be portable across $(()) and expr. 399 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : 400 eval 'as_fn_arith () 401 { 402 as_val=$(( $* )) 403 }' 404 else 405 as_fn_arith () 406 { 407 as_val=`expr "$@" || test $? -eq 1` 408 } 409 fi # as_fn_arith 410 411 412 # as_fn_error STATUS ERROR [LINENO LOG_FD] 413 # ---------------------------------------- 414 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are 415 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the 416 # script with STATUS, using 1 if that was 0. 417 as_fn_error () 418 { 419 as_status=$1; test $as_status -eq 0 && as_status=1 420 if test "$4"; then 421 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 422 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 423 fi 424 $as_echo "$as_me: error: $2" >&2 425 as_fn_exit $as_status 426 } # as_fn_error 427 428 if expr a : '\(a\)' >/dev/null 2>&1 && 429 test "X`expr 00001 : '.*\(...\)'`" = X001; then 430 as_expr=expr 431 else 432 as_expr=false 433 fi 434 435 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then 436 as_basename=basename 437 else 438 as_basename=false 439 fi 440 441 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then 442 as_dirname=dirname 443 else 444 as_dirname=false 445 fi 446 447 as_me=`$as_basename -- "$0" || 448 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ 449 X"$0" : 'X\(//\)$' \| \ 450 X"$0" : 'X\(/\)' \| . 2>/dev/null || 451 $as_echo X/"$0" | 452 sed '/^.*\/\([^/][^/]*\)\/*$/{ 453 s//\1/ 454 q 455 } 456 /^X\/\(\/\/\)$/{ 457 s//\1/ 458 q 459 } 460 /^X\/\(\/\).*/{ 461 s//\1/ 462 q 463 } 464 s/.*/./; q'` 465 466 # Avoid depending upon Character Ranges. 467 as_cr_letters='abcdefghijklmnopqrstuvwxyz' 468 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' 469 as_cr_Letters=$as_cr_letters$as_cr_LETTERS 470 as_cr_digits='0123456789' 471 as_cr_alnum=$as_cr_Letters$as_cr_digits 472 473 474 as_lineno_1=$LINENO as_lineno_1a=$LINENO 475 as_lineno_2=$LINENO as_lineno_2a=$LINENO 476 eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" && 477 test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || { 478 # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-) 479 sed -n ' 480 p 481 /[$]LINENO/= 482 ' <$as_myself | 483 sed ' 484 s/[$]LINENO.*/&-/ 485 t lineno 486 b 487 :lineno 488 N 489 :loop 490 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ 491 t loop 492 s/-\n.*// 493 ' >$as_me.lineno && 494 chmod +x "$as_me.lineno" || 495 { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } 496 497 # If we had to re-execute with $CONFIG_SHELL, we're ensured to have 498 # already done that, so ensure we don't try to do so again and fall 499 # in an infinite loop. This has already happened in practice. 500 _as_can_reexec=no; export _as_can_reexec 501 # Don't try to exec as it changes $[0], causing all sort of problems 502 # (the dirname of $[0] is not the place where we might find the 503 # original and so on. Autoconf is especially sensitive to this). 504 . "./$as_me.lineno" 505 # Exit status is that of the last command. 506 exit 507 } 508 509 ECHO_C= ECHO_N= ECHO_T= 510 case `echo -n x` in #((((( 511 -n*) 512 case `echo 'xy\c'` in 513 *c*) ECHO_T=' ';; # ECHO_T is single tab character. 514 xy) ECHO_C='\c';; 515 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null 516 ECHO_T=' ';; 517 esac;; 518 *) 519 ECHO_N='-n';; 520 esac 521 522 rm -f conf$$ conf$$.exe conf$$.file 523 if test -d conf$$.dir; then 524 rm -f conf$$.dir/conf$$.file 525 else 526 rm -f conf$$.dir 527 mkdir conf$$.dir 2>/dev/null 528 fi 529 if (echo >conf$$.file) 2>/dev/null; then 530 if ln -s conf$$.file conf$$ 2>/dev/null; then 531 as_ln_s='ln -s' 532 # ... but there are two gotchas: 533 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. 534 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. 535 # In both cases, we have to default to `cp -pR'. 536 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || 537 as_ln_s='cp -pR' 538 elif ln conf$$.file conf$$ 2>/dev/null; then 539 as_ln_s=ln 540 else 541 as_ln_s='cp -pR' 542 fi 543 else 544 as_ln_s='cp -pR' 545 fi 546 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file 547 rmdir conf$$.dir 2>/dev/null 548 549 if mkdir -p . 2>/dev/null; then 550 as_mkdir_p='mkdir -p "$as_dir"' 551 else 552 test -d ./-p && rmdir ./-p 553 as_mkdir_p=false 554 fi 555 556 as_test_x='test -x' 557 as_executable_p=as_fn_executable_p 558 559 # Sed expression to map a string onto a valid CPP name. 560 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" 561 562 # Sed expression to map a string onto a valid variable name. 563 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" 564 565 566 test -n "$DJDIR" || exec 7<&0 </dev/null 567 exec 6>&1 568 569 # Name of the host. 570 # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status, 571 # so uname gets run too. 572 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` 573 574 # 575 # Initializations. 576 # 577 ac_default_prefix=/usr/local 578 ac_clean_files= 579 ac_config_libobj_dir=. 580 LIBOBJS= 581 cross_compiling=no 582 subdirs= 583 MFLAGS= 584 MAKEFLAGS= 585 586 # Identity of this package. 587 PACKAGE_NAME='OpenJDK' 588 PACKAGE_TARNAME='openjdk' 589 PACKAGE_VERSION='jdk9' 590 PACKAGE_STRING='OpenJDK jdk9' 591 PACKAGE_BUGREPORT='build-dev@openjdk.java.net' 592 PACKAGE_URL='http://openjdk.java.net' 593 594 # Factoring default headers for most tests. 595 ac_includes_default="\ 596 #include <stdio.h> 597 #ifdef HAVE_SYS_TYPES_H 598 # include <sys/types.h> 599 #endif 600 #ifdef HAVE_SYS_STAT_H 601 # include <sys/stat.h> 602 #endif 603 #ifdef STDC_HEADERS 604 # include <stdlib.h> 605 # include <stddef.h> 606 #else 607 # ifdef HAVE_STDLIB_H 608 # include <stdlib.h> 609 # endif 610 #endif 611 #ifdef HAVE_STRING_H 612 # if !defined STDC_HEADERS && defined HAVE_MEMORY_H 613 # include <memory.h> 614 # endif 615 # include <string.h> 616 #endif 617 #ifdef HAVE_STRINGS_H 618 # include <strings.h> 619 #endif 620 #ifdef HAVE_INTTYPES_H 621 # include <inttypes.h> 622 #endif 623 #ifdef HAVE_STDINT_H 624 # include <stdint.h> 625 #endif 626 #ifdef HAVE_UNISTD_H 627 # include <unistd.h> 628 #endif" 629 630 ac_subst_vars='LTLIBOBJS 631 LIBOBJS 632 CFLAGS_CCACHE 633 CCACHE 634 USE_PRECOMPILED_HEADER 635 BUILD_ICECC 636 ICECC 637 ICECC_WRAPPER 638 ICECC_CREATE_ENV 639 ICECC_CMD 640 ENABLE_JAVAC_SERVER 641 ENABLE_SJAVAC 642 SJAVAC_SERVER_JAVA_FLAGS 643 SJAVAC_SERVER_JAVA 644 JAVA_TOOL_FLAGS_SMALL 645 JAVA_FLAGS_SMALL 646 JAVA_FLAGS_JAVAC 647 BOOTCYCLE_JVM_ARGS_BIG 648 JAVA_FLAGS_BIG 649 JAVA_FLAGS 650 TEST_JOBS 651 JOBS 652 MEMORY_SIZE 653 NUM_CORES 654 ENABLE_GENERATE_CLASSLIST 655 BUILD_FAILURE_HANDLER 656 ENABLE_INTREE_EC 657 VALID_JVM_FEATURES 658 JVM_FEATURES_custom 659 JVM_FEATURES_zeroshark 660 JVM_FEATURES_zero 661 JVM_FEATURES_minimal 662 JVM_FEATURES_core 663 JVM_FEATURES_client 664 JVM_FEATURES_server 665 INCLUDE_GRAAL 666 ELF_LIBS 667 ELF_CFLAGS 668 STLPORT_LIB 669 LIBZIP_CAN_USE_MMAP 670 LIBDL 671 LIBM 672 USE_EXTERNAL_LCMS 673 LCMS_LIBS 674 LCMS_CFLAGS 675 USE_EXTERNAL_LIBZ 676 USE_EXTERNAL_LIBPNG 677 PNG_LIBS 678 PNG_CFLAGS 679 USE_EXTERNAL_LIBGIF 680 USE_EXTERNAL_LIBJPEG 681 LLVM_LIBS 682 LLVM_LDFLAGS 683 LLVM_CFLAGS 684 LLVM_CONFIG 685 LIBFFI_LIB_FILE 686 ENABLE_LIBFFI_BUNDLING 687 LIBFFI_LIBS 688 LIBFFI_CFLAGS 689 ALSA_LIBS 690 ALSA_CFLAGS 691 FREETYPE_BUNDLE_LIB_PATH 692 FREETYPE_LIBS 693 FREETYPE_CFLAGS 694 CUPS_CFLAGS 695 X_EXTRA_LIBS 696 X_LIBS 697 X_PRE_LIBS 698 X_CFLAGS 699 XMKMF 700 MSVCP_DLL 701 MSVCR_DLL 702 LIBCXX 703 FIXPATH_DETACH_FLAG 704 FIXPATH 705 BUILD_GTEST 706 ENABLE_AOT 707 GCOV_ENABLED 708 ZIP_EXTERNAL_DEBUG_SYMBOLS 709 COPY_DEBUG_SYMBOLS 710 COMPILE_WITH_DEBUG_SYMBOLS 711 CFLAGS_WARNINGS_ARE_ERRORS 712 BUILD_CC_DISABLE_WARNING_PREFIX 713 DISABLE_WARNING_PREFIX 714 WARNINGS_AS_ERRORS 715 COMPILER_SUPPORTS_TARGET_BITS_FLAG 716 LDFLAGS_TESTEXE 717 LDFLAGS_TESTLIB 718 CXXFLAGS_TESTEXE 719 CXXFLAGS_TESTLIB 720 CFLAGS_TESTEXE 721 CFLAGS_TESTLIB 722 OPENJDK_BUILD_JVM_LIBS 723 OPENJDK_BUILD_JVM_ASFLAGS 724 OPENJDK_BUILD_JVM_LDFLAGS 725 OPENJDK_BUILD_JVM_CFLAGS 726 OPENJDK_BUILD_LDFLAGS_HASH_STYLE 727 OPENJDK_BUILD_LDFLAGS_CXX_JDK 728 OPENJDK_BUILD_JDKEXE_LIBS 729 OPENJDK_BUILD_JDKLIB_LIBS 730 OPENJDK_BUILD_LDFLAGS_JDKEXE 731 OPENJDK_BUILD_LDFLAGS_JDKLIB 732 OPENJDK_BUILD_CXXFLAGS_JDKEXE 733 OPENJDK_BUILD_CXXFLAGS_JDKLIB 734 OPENJDK_BUILD_CFLAGS_JDKEXE 735 OPENJDK_BUILD_CFLAGS_JDKLIB 736 OPENJDK_BUILD_CXXSTD_CXXFLAG 737 JVM_LIBS 738 JVM_ASFLAGS 739 JVM_LDFLAGS 740 JVM_CFLAGS 741 LDFLAGS_HASH_STYLE 742 LDFLAGS_CXX_JDK 743 JDKEXE_LIBS 744 JDKLIB_LIBS 745 LDFLAGS_JDKEXE 746 LDFLAGS_JDKLIB 747 CXXFLAGS_JDKEXE 748 CXXFLAGS_JDKLIB 749 CFLAGS_JDKEXE 750 CFLAGS_JDKLIB 751 MACOSX_VERSION_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 JT_HOME 792 JTREGEXE 793 HOTSPOT_TOOLCHAIN_TYPE 794 USING_BROKEN_SUSE_LD 795 PACKAGE_PATH 796 BUILD_AS 797 BUILD_LDCXX 798 BUILD_LD 799 BUILD_STRIP 800 BUILD_OBJCOPY 801 BUILD_AR 802 BUILD_NM 803 BUILD_CXX 804 BUILD_CC 805 BUILD_SYSROOT_LDFLAGS 806 BUILD_SYSROOT_CFLAGS 807 ac_ct_OBJDUMP 808 OBJDUMP 809 ac_ct_OBJCOPY 810 OBJCOPY 811 ac_ct_NM 812 ac_ct_STRIP 813 GNM 814 NM 815 STRIP 816 MSBUILD 817 DUMPBIN 818 RC 819 MT 820 LIPO 821 ac_ct_AR 822 AR 823 AS 824 LDCXX 825 LD 826 CXXCPP 827 CPP 828 CXX_VERSION_NUMBER 829 CC_VERSION_NUMBER 830 ac_ct_CXX 831 CXXFLAGS 832 CXX 833 TOOLCHAIN_PATH_CXX 834 POTENTIAL_CXX 835 OBJEXT 836 EXEEXT 837 ac_ct_CC 838 CPPFLAGS 839 LDFLAGS 840 CFLAGS 841 CC 842 TOOLCHAIN_PATH_CC 843 POTENTIAL_CC 844 TOOLCHAIN_VERSION 845 VS_LIB 846 VS_INCLUDE 847 VS_PATH 848 CYGWIN_LINK 849 SYSROOT_LDFLAGS 850 SYSROOT_CFLAGS 851 EXTRA_LDFLAGS 852 EXTRA_CXXFLAGS 853 EXTRA_CFLAGS 854 EXE_SUFFIX 855 OBJ_SUFFIX 856 STATIC_LIBRARY 857 SHARED_LIBRARY 858 STATIC_LIBRARY_SUFFIX 859 SHARED_LIBRARY_SUFFIX 860 LIBRARY_PREFIX 861 TOOLCHAIN_TYPE 862 STATIC_BUILD 863 IMPORT_MODULES_MAKE 864 IMPORT_MODULES_SRC 865 IMPORT_MODULES_MAN 866 IMPORT_MODULES_LEGAL 867 IMPORT_MODULES_CONF 868 IMPORT_MODULES_LIBS 869 IMPORT_MODULES_CMDS 870 IMPORT_MODULES_CLASSES 871 BUILD_OUTPUT 872 JDK_TOPDIR 873 NASHORN_TOPDIR 874 HOTSPOT_TOPDIR 875 JAXWS_TOPDIR 876 JAXP_TOPDIR 877 CORBA_TOPDIR 878 LANGTOOLS_TOPDIR 879 EXTERNAL_BUILDJDK 880 BUILD_JDK 881 CREATE_BUILDJDK 882 JLINK 883 JMOD 884 JAVAC_FLAGS 885 BOOT_JDK_MODULAR 886 BOOT_JDK_SOURCETARGET 887 JARSIGNER 888 JAR 889 JAVAH 890 JAVAC 891 JAVA 892 BOOT_JDK 893 JAVA_CHECK 894 JAVAC_CHECK 895 VERSION_IS_GA 896 VERSION_SHORT 897 VERSION_STRING 898 VERSION_NUMBER_FOUR_POSITIONS 899 VERSION_NUMBER 900 VERSION_OPT 901 VERSION_BUILD 902 VERSION_PRE 903 VERSION_PATCH 904 VERSION_SECURITY 905 VERSION_MINOR 906 VERSION_MAJOR 907 MACOSX_BUNDLE_ID_BASE 908 MACOSX_BUNDLE_NAME_BASE 909 HOTSPOT_VM_DISTRO 910 COMPANY_NAME 911 JDK_RC_PLATFORM_NAME 912 PRODUCT_SUFFIX 913 PRODUCT_NAME 914 LAUNCHER_NAME 915 JLINK_KEEP_PACKAGED_MODULES 916 COPYRIGHT_YEAR 917 COMPRESS_JARS 918 INCLUDE_SA 919 UNLIMITED_CRYPTO 920 CACERTS_FILE 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 TIME 936 STAT 937 HG 938 READELF 939 OTOOL 940 LDD 941 ZIPEXE 942 UNZIP 943 TAR_SUPPORTS_TRANSFORM 944 TAR_INCLUDE_PARAM 945 TAR_CREATE_EXTRA_PARAM 946 TAR_TYPE 947 FIND_DELETE 948 OUTPUT_SYNC 949 OUTPUT_SYNC_SUPPORTED 950 CHECK_TOOLSDIR_MAKE 951 CHECK_TOOLSDIR_GMAKE 952 CHECK_MAKE 953 CHECK_GMAKE 954 MAKE 955 PKGHANDLER 956 CONFIGURESUPPORT_OUTPUTDIR 957 OUTPUT_ROOT 958 CONF_NAME 959 SPEC 960 SDKROOT 961 XCODEBUILD 962 JVM_VARIANT_MAIN 963 VALID_JVM_VARIANTS 964 JVM_VARIANTS 965 DEBUG_LEVEL 966 HOTSPOT_DEBUG_LEVEL 967 JDK_VARIANT 968 USERNAME 969 CANONICAL_TOPDIR 970 ORIGINAL_TOPDIR 971 TOPDIR 972 PATH_SEP 973 HOTSPOT_BUILD_CPU_DEFINE 974 HOTSPOT_BUILD_CPU_ARCH 975 HOTSPOT_BUILD_CPU 976 HOTSPOT_BUILD_OS_TYPE 977 HOTSPOT_BUILD_OS 978 OPENJDK_BUILD_BUNDLE_PLATFORM 979 OPENJDK_BUILD_OS_EXPORT_DIR 980 OPENJDK_BUILD_CPU_OSARCH 981 OPENJDK_BUILD_CPU_ISADIR 982 OPENJDK_BUILD_CPU_LEGACY_LIB 983 OPENJDK_BUILD_CPU_LEGACY 984 HOTSPOT_TARGET_CPU_DEFINE 985 HOTSPOT_TARGET_CPU_ARCH 986 HOTSPOT_TARGET_CPU 987 HOTSPOT_TARGET_OS_TYPE 988 HOTSPOT_TARGET_OS 989 DEFINE_CROSS_COMPILE_ARCH 990 OPENJDK_TARGET_BUNDLE_PLATFORM 991 OPENJDK_TARGET_OS_EXPORT_DIR 992 OPENJDK_TARGET_CPU_OSARCH 993 OPENJDK_TARGET_CPU_ISADIR 994 OPENJDK_TARGET_CPU_LEGACY_LIB 995 OPENJDK_TARGET_CPU_LEGACY 996 OPENJDK_MODULE_TARGET_OS_ARCH 997 OPENJDK_MODULE_TARGET_OS_NAME 998 COMPILE_TYPE 999 OPENJDK_TARGET_CPU_ENDIAN 1000 OPENJDK_TARGET_CPU_BITS 1001 OPENJDK_TARGET_CPU_ARCH 1002 OPENJDK_TARGET_CPU 1003 OPENJDK_TARGET_OS_ENV 1004 OPENJDK_TARGET_OS_TYPE 1005 OPENJDK_TARGET_OS 1006 OPENJDK_BUILD_CPU_ENDIAN 1007 OPENJDK_BUILD_CPU_BITS 1008 OPENJDK_BUILD_CPU_ARCH 1009 OPENJDK_BUILD_CPU 1010 OPENJDK_BUILD_OS_ENV 1011 OPENJDK_BUILD_OS_TYPE 1012 OPENJDK_BUILD_OS 1013 OPENJDK_BUILD_AUTOCONF_NAME 1014 OPENJDK_TARGET_AUTOCONF_NAME 1015 target_os 1016 target_vendor 1017 target_cpu 1018 target 1019 host_os 1020 host_vendor 1021 host_cpu 1022 host 1023 build_os 1024 build_vendor 1025 build_cpu 1026 build 1027 PANDOC 1028 NICE 1029 CPIO 1030 DF 1031 READLINK 1032 CYGPATH 1033 SED 1034 FGREP 1035 EGREP 1036 GREP 1037 AWK 1038 XARGS 1039 WHICH 1040 WC 1041 UNIQ 1042 UNAME 1043 TR 1044 TOUCH 1045 TEE 1046 TAR 1047 TAIL 1048 SORT 1049 SH 1050 RMDIR 1051 RM 1052 PRINTF 1053 NAWK 1054 MV 1055 MKTEMP 1056 MKDIR 1057 LS 1058 LN 1059 GZIP 1060 GUNZIP 1061 HEAD 1062 FIND 1063 FILE 1064 EXPR 1065 ECHO 1066 DIRNAME 1067 DIFF 1068 DATE 1069 CUT 1070 CP 1071 COMM 1072 CMP 1073 CHMOD 1074 CAT 1075 BASH 1076 BASENAME 1077 DATE_WHEN_CONFIGURED 1078 ORIGINAL_PATH 1079 CONFIGURE_COMMAND_LINE 1080 target_alias 1081 host_alias 1082 build_alias 1083 LIBS 1084 ECHO_T 1085 ECHO_N 1086 ECHO_C 1087 DEFS 1088 mandir 1089 localedir 1090 libdir 1091 psdir 1092 pdfdir 1093 dvidir 1094 htmldir 1095 infodir 1096 docdir 1097 oldincludedir 1098 includedir 1099 localstatedir 1100 sharedstatedir 1101 sysconfdir 1102 datadir 1103 datarootdir 1104 libexecdir 1105 sbindir 1106 bindir 1107 program_transform_name 1108 prefix 1109 exec_prefix 1110 PACKAGE_URL 1111 PACKAGE_BUGREPORT 1112 PACKAGE_STRING 1113 PACKAGE_VERSION 1114 PACKAGE_TARNAME 1115 PACKAGE_NAME 1116 PATH_SEPARATOR 1117 SHELL' 1118 ac_subst_files='' 1119 ac_user_opts=' 1120 enable_option_checking 1121 with_target_bits 1122 enable_openjdk_only 1123 with_custom_make_dir 1124 with_jdk_variant 1125 enable_debug 1126 with_debug_level 1127 with_jvm_variants 1128 with_cpu_port 1129 with_devkit 1130 with_sys_root 1131 with_sysroot 1132 with_tools_dir 1133 with_toolchain_path 1134 with_extra_path 1135 with_sdk_name 1136 with_conf_name 1137 with_output_sync 1138 with_default_make_target 1139 enable_headless_only 1140 with_cacerts_file 1141 enable_unlimited_crypto 1142 with_copyright_year 1143 enable_keep_packaged_modules 1144 with_milestone 1145 with_update_version 1146 with_user_release_suffix 1147 with_build_number 1148 with_version_string 1149 with_version_pre 1150 with_version_opt 1151 with_version_build 1152 with_version_major 1153 with_version_minor 1154 with_version_security 1155 with_version_patch 1156 with_boot_jdk 1157 with_build_jdk 1158 with_add_source_root 1159 with_override_source_root 1160 with_adds_and_overrides 1161 with_override_langtools 1162 with_override_corba 1163 with_override_jaxp 1164 with_override_jaxws 1165 with_override_hotspot 1166 with_override_nashorn 1167 with_override_jdk 1168 with_import_hotspot 1169 with_import_modules 1170 enable_static_build 1171 with_toolchain_type 1172 with_extra_cflags 1173 with_extra_cxxflags 1174 with_extra_ldflags 1175 with_toolchain_version 1176 with_build_devkit 1177 with_jtreg 1178 with_abi_profile 1179 enable_warnings_as_errors 1180 with_native_debug_symbols 1181 enable_debug_symbols 1182 enable_zip_debug_info 1183 enable_native_coverage 1184 enable_dtrace 1185 enable_aot 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_freetype 1194 with_freetype_include 1195 with_freetype_lib 1196 with_freetype_src 1197 enable_freetype_bundling 1198 with_alsa 1199 with_alsa_include 1200 with_alsa_lib 1201 with_libffi 1202 with_libffi_include 1203 with_libffi_lib 1204 enable_libffi_bundling 1205 with_libjpeg 1206 with_giflib 1207 with_libpng 1208 with_zlib 1209 with_lcms 1210 with_dxsdk 1211 with_dxsdk_lib 1212 with_dxsdk_include 1213 with_libelf 1214 with_libelf_include 1215 with_libelf_lib 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 OTOOL 1291 READELF 1292 HG 1293 STAT 1294 TIME 1295 DTRACE 1296 PATCH 1297 DSYMUTIL 1298 XATTR 1299 CODESIGN 1300 SETFILE 1301 PKG_CONFIG 1302 JAVA 1303 JAVAC 1304 JAVAH 1305 JAR 1306 JARSIGNER 1307 CC 1308 CFLAGS 1309 LDFLAGS 1310 LIBS 1311 CPPFLAGS 1312 CXX 1313 CXXFLAGS 1314 CCC 1315 CPP 1316 CXXCPP 1317 AS 1318 AR 1319 LIPO 1320 STRIP 1321 NM 1322 GNM 1323 OBJCOPY 1324 OBJDUMP 1325 BUILD_CC 1326 BUILD_CXX 1327 BUILD_NM 1328 BUILD_AR 1329 BUILD_OBJCOPY 1330 BUILD_STRIP 1331 JTREGEXE 1332 XMKMF 1333 FREETYPE_CFLAGS 1334 FREETYPE_LIBS 1335 ALSA_CFLAGS 1336 ALSA_LIBS 1337 LIBFFI_CFLAGS 1338 LIBFFI_LIBS 1339 PNG_CFLAGS 1340 PNG_LIBS 1341 LCMS_CFLAGS 1342 LCMS_LIBS 1343 ELF_CFLAGS 1344 ELF_LIBS 1345 ICECC_CMD 1346 ICECC_CREATE_ENV 1347 ICECC_WRAPPER 1348 CCACHE' 1349 1350 1351 # Initialize some variables set by options. 1352 ac_init_help= 1353 ac_init_version=false 1354 ac_unrecognized_opts= 1355 ac_unrecognized_sep= 1356 # The variables have the same names as the options, with 1357 # dashes changed to underlines. 1358 cache_file=/dev/null 1359 exec_prefix=NONE 1360 no_create= 1361 no_recursion= 1362 prefix=NONE 1363 program_prefix=NONE 1364 program_suffix=NONE 1365 program_transform_name=s,x,x, 1366 silent= 1367 site= 1368 srcdir= 1369 verbose= 1370 x_includes=NONE 1371 x_libraries=NONE 1372 1373 # Installation directory options. 1374 # These are left unexpanded so users can "make install exec_prefix=/foo" 1375 # and all the variables that are supposed to be based on exec_prefix 1376 # by default will actually change. 1377 # Use braces instead of parens because sh, perl, etc. also accept them. 1378 # (The list follows the same order as the GNU Coding Standards.) 1379 bindir='${exec_prefix}/bin' 1380 sbindir='${exec_prefix}/sbin' 1381 libexecdir='${exec_prefix}/libexec' 1382 datarootdir='${prefix}/share' 1383 datadir='${datarootdir}' 1384 sysconfdir='${prefix}/etc' 1385 sharedstatedir='${prefix}/com' 1386 localstatedir='${prefix}/var' 1387 includedir='${prefix}/include' 1388 oldincludedir='/usr/include' 1389 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' 1390 infodir='${datarootdir}/info' 1391 htmldir='${docdir}' 1392 dvidir='${docdir}' 1393 pdfdir='${docdir}' 1394 psdir='${docdir}' 1395 libdir='${exec_prefix}/lib' 1396 localedir='${datarootdir}/locale' 1397 mandir='${datarootdir}/man' 1398 1399 ac_prev= 1400 ac_dashdash= 1401 for ac_option 1402 do 1403 # If the previous option needs an argument, assign it. 1404 if test -n "$ac_prev"; then 1405 eval $ac_prev=\$ac_option 1406 ac_prev= 1407 continue 1408 fi 1409 1410 case $ac_option in 1411 *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; 1412 *=) ac_optarg= ;; 1413 *) ac_optarg=yes ;; 1414 esac 1415 1416 # Accept the important Cygnus configure options, so we can diagnose typos. 1417 1418 case $ac_dashdash$ac_option in 1419 --) 1420 ac_dashdash=yes ;; 1421 1422 -bindir | --bindir | --bindi | --bind | --bin | --bi) 1423 ac_prev=bindir ;; 1424 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) 1425 bindir=$ac_optarg ;; 1426 1427 -build | --build | --buil | --bui | --bu) 1428 ac_prev=build_alias ;; 1429 -build=* | --build=* | --buil=* | --bui=* | --bu=*) 1430 build_alias=$ac_optarg ;; 1431 1432 -cache-file | --cache-file | --cache-fil | --cache-fi \ 1433 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) 1434 ac_prev=cache_file ;; 1435 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ 1436 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) 1437 cache_file=$ac_optarg ;; 1438 1439 --config-cache | -C) 1440 cache_file=config.cache ;; 1441 1442 -datadir | --datadir | --datadi | --datad) 1443 ac_prev=datadir ;; 1444 -datadir=* | --datadir=* | --datadi=* | --datad=*) 1445 datadir=$ac_optarg ;; 1446 1447 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ 1448 | --dataroo | --dataro | --datar) 1449 ac_prev=datarootdir ;; 1450 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ 1451 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) 1452 datarootdir=$ac_optarg ;; 1453 1454 -disable-* | --disable-*) 1455 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` 1456 # Reject names that are not valid shell variable names. 1457 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1458 as_fn_error $? "invalid feature name: $ac_useropt" 1459 ac_useropt_orig=$ac_useropt 1460 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` 1461 case $ac_user_opts in 1462 *" 1463 "enable_$ac_useropt" 1464 "*) ;; 1465 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" 1466 ac_unrecognized_sep=', ';; 1467 esac 1468 eval enable_$ac_useropt=no ;; 1469 1470 -docdir | --docdir | --docdi | --doc | --do) 1471 ac_prev=docdir ;; 1472 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) 1473 docdir=$ac_optarg ;; 1474 1475 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) 1476 ac_prev=dvidir ;; 1477 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) 1478 dvidir=$ac_optarg ;; 1479 1480 -enable-* | --enable-*) 1481 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` 1482 # Reject names that are not valid shell variable names. 1483 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1484 as_fn_error $? "invalid feature name: $ac_useropt" 1485 ac_useropt_orig=$ac_useropt 1486 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` 1487 case $ac_user_opts in 1488 *" 1489 "enable_$ac_useropt" 1490 "*) ;; 1491 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" 1492 ac_unrecognized_sep=', ';; 1493 esac 1494 eval enable_$ac_useropt=\$ac_optarg ;; 1495 1496 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ 1497 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ 1498 | --exec | --exe | --ex) 1499 ac_prev=exec_prefix ;; 1500 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ 1501 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ 1502 | --exec=* | --exe=* | --ex=*) 1503 exec_prefix=$ac_optarg ;; 1504 1505 -gas | --gas | --ga | --g) 1506 # Obsolete; use --with-gas. 1507 with_gas=yes ;; 1508 1509 -help | --help | --hel | --he | -h) 1510 ac_init_help=long ;; 1511 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) 1512 ac_init_help=recursive ;; 1513 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) 1514 ac_init_help=short ;; 1515 1516 -host | --host | --hos | --ho) 1517 ac_prev=host_alias ;; 1518 -host=* | --host=* | --hos=* | --ho=*) 1519 host_alias=$ac_optarg ;; 1520 1521 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) 1522 ac_prev=htmldir ;; 1523 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ 1524 | --ht=*) 1525 htmldir=$ac_optarg ;; 1526 1527 -includedir | --includedir | --includedi | --included | --include \ 1528 | --includ | --inclu | --incl | --inc) 1529 ac_prev=includedir ;; 1530 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ 1531 | --includ=* | --inclu=* | --incl=* | --inc=*) 1532 includedir=$ac_optarg ;; 1533 1534 -infodir | --infodir | --infodi | --infod | --info | --inf) 1535 ac_prev=infodir ;; 1536 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) 1537 infodir=$ac_optarg ;; 1538 1539 -libdir | --libdir | --libdi | --libd) 1540 ac_prev=libdir ;; 1541 -libdir=* | --libdir=* | --libdi=* | --libd=*) 1542 libdir=$ac_optarg ;; 1543 1544 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ 1545 | --libexe | --libex | --libe) 1546 ac_prev=libexecdir ;; 1547 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ 1548 | --libexe=* | --libex=* | --libe=*) 1549 libexecdir=$ac_optarg ;; 1550 1551 -localedir | --localedir | --localedi | --localed | --locale) 1552 ac_prev=localedir ;; 1553 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) 1554 localedir=$ac_optarg ;; 1555 1556 -localstatedir | --localstatedir | --localstatedi | --localstated \ 1557 | --localstate | --localstat | --localsta | --localst | --locals) 1558 ac_prev=localstatedir ;; 1559 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ 1560 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) 1561 localstatedir=$ac_optarg ;; 1562 1563 -mandir | --mandir | --mandi | --mand | --man | --ma | --m) 1564 ac_prev=mandir ;; 1565 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) 1566 mandir=$ac_optarg ;; 1567 1568 -nfp | --nfp | --nf) 1569 # Obsolete; use --without-fp. 1570 with_fp=no ;; 1571 1572 -no-create | --no-create | --no-creat | --no-crea | --no-cre \ 1573 | --no-cr | --no-c | -n) 1574 no_create=yes ;; 1575 1576 -no-recursion | --no-recursion | --no-recursio | --no-recursi \ 1577 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) 1578 no_recursion=yes ;; 1579 1580 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ 1581 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ 1582 | --oldin | --oldi | --old | --ol | --o) 1583 ac_prev=oldincludedir ;; 1584 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ 1585 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ 1586 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) 1587 oldincludedir=$ac_optarg ;; 1588 1589 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) 1590 ac_prev=prefix ;; 1591 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) 1592 prefix=$ac_optarg ;; 1593 1594 -program-prefix | --program-prefix | --program-prefi | --program-pref \ 1595 | --program-pre | --program-pr | --program-p) 1596 ac_prev=program_prefix ;; 1597 -program-prefix=* | --program-prefix=* | --program-prefi=* \ 1598 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) 1599 program_prefix=$ac_optarg ;; 1600 1601 -program-suffix | --program-suffix | --program-suffi | --program-suff \ 1602 | --program-suf | --program-su | --program-s) 1603 ac_prev=program_suffix ;; 1604 -program-suffix=* | --program-suffix=* | --program-suffi=* \ 1605 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) 1606 program_suffix=$ac_optarg ;; 1607 1608 -program-transform-name | --program-transform-name \ 1609 | --program-transform-nam | --program-transform-na \ 1610 | --program-transform-n | --program-transform- \ 1611 | --program-transform | --program-transfor \ 1612 | --program-transfo | --program-transf \ 1613 | --program-trans | --program-tran \ 1614 | --progr-tra | --program-tr | --program-t) 1615 ac_prev=program_transform_name ;; 1616 -program-transform-name=* | --program-transform-name=* \ 1617 | --program-transform-nam=* | --program-transform-na=* \ 1618 | --program-transform-n=* | --program-transform-=* \ 1619 | --program-transform=* | --program-transfor=* \ 1620 | --program-transfo=* | --program-transf=* \ 1621 | --program-trans=* | --program-tran=* \ 1622 | --progr-tra=* | --program-tr=* | --program-t=*) 1623 program_transform_name=$ac_optarg ;; 1624 1625 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) 1626 ac_prev=pdfdir ;; 1627 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) 1628 pdfdir=$ac_optarg ;; 1629 1630 -psdir | --psdir | --psdi | --psd | --ps) 1631 ac_prev=psdir ;; 1632 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) 1633 psdir=$ac_optarg ;; 1634 1635 -q | -quiet | --quiet | --quie | --qui | --qu | --q \ 1636 | -silent | --silent | --silen | --sile | --sil) 1637 silent=yes ;; 1638 1639 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) 1640 ac_prev=sbindir ;; 1641 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ 1642 | --sbi=* | --sb=*) 1643 sbindir=$ac_optarg ;; 1644 1645 -sharedstatedir | --sharedstatedir | --sharedstatedi \ 1646 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ 1647 | --sharedst | --shareds | --shared | --share | --shar \ 1648 | --sha | --sh) 1649 ac_prev=sharedstatedir ;; 1650 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ 1651 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ 1652 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ 1653 | --sha=* | --sh=*) 1654 sharedstatedir=$ac_optarg ;; 1655 1656 -site | --site | --sit) 1657 ac_prev=site ;; 1658 -site=* | --site=* | --sit=*) 1659 site=$ac_optarg ;; 1660 1661 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) 1662 ac_prev=srcdir ;; 1663 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) 1664 srcdir=$ac_optarg ;; 1665 1666 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ 1667 | --syscon | --sysco | --sysc | --sys | --sy) 1668 ac_prev=sysconfdir ;; 1669 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ 1670 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) 1671 sysconfdir=$ac_optarg ;; 1672 1673 -target | --target | --targe | --targ | --tar | --ta | --t) 1674 ac_prev=target_alias ;; 1675 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) 1676 target_alias=$ac_optarg ;; 1677 1678 -v | -verbose | --verbose | --verbos | --verbo | --verb) 1679 verbose=yes ;; 1680 1681 -version | --version | --versio | --versi | --vers | -V) 1682 ac_init_version=: ;; 1683 1684 -with-* | --with-*) 1685 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` 1686 # Reject names that are not valid shell variable names. 1687 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1688 as_fn_error $? "invalid package name: $ac_useropt" 1689 ac_useropt_orig=$ac_useropt 1690 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` 1691 case $ac_user_opts in 1692 *" 1693 "with_$ac_useropt" 1694 "*) ;; 1695 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" 1696 ac_unrecognized_sep=', ';; 1697 esac 1698 eval with_$ac_useropt=\$ac_optarg ;; 1699 1700 -without-* | --without-*) 1701 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` 1702 # Reject names that are not valid shell variable names. 1703 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1704 as_fn_error $? "invalid package name: $ac_useropt" 1705 ac_useropt_orig=$ac_useropt 1706 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` 1707 case $ac_user_opts in 1708 *" 1709 "with_$ac_useropt" 1710 "*) ;; 1711 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" 1712 ac_unrecognized_sep=', ';; 1713 esac 1714 eval with_$ac_useropt=no ;; 1715 1716 --x) 1717 # Obsolete; use --with-x. 1718 with_x=yes ;; 1719 1720 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ 1721 | --x-incl | --x-inc | --x-in | --x-i) 1722 ac_prev=x_includes ;; 1723 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ 1724 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) 1725 x_includes=$ac_optarg ;; 1726 1727 -x-libraries | --x-libraries | --x-librarie | --x-librari \ 1728 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) 1729 ac_prev=x_libraries ;; 1730 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ 1731 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) 1732 x_libraries=$ac_optarg ;; 1733 1734 -*) as_fn_error $? "unrecognized option: \`$ac_option' 1735 Try \`$0 --help' for more information" 1736 ;; 1737 1738 *=*) 1739 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` 1740 # Reject names that are not valid shell variable names. 1741 case $ac_envvar in #( 1742 '' | [0-9]* | *[!_$as_cr_alnum]* ) 1743 as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; 1744 esac 1745 eval $ac_envvar=\$ac_optarg 1746 export $ac_envvar ;; 1747 1748 *) 1749 # FIXME: should be removed in autoconf 3.0. 1750 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 1751 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && 1752 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 1753 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}" 1754 ;; 1755 1756 esac 1757 done 1758 1759 if test -n "$ac_prev"; then 1760 ac_option=--`echo $ac_prev | sed 's/_/-/g'` 1761 as_fn_error $? "missing argument to $ac_option" 1762 fi 1763 1764 if test -n "$ac_unrecognized_opts"; then 1765 case $enable_option_checking in 1766 no) ;; 1767 fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; 1768 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; 1769 esac 1770 fi 1771 1772 # Check all directory arguments for consistency. 1773 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ 1774 datadir sysconfdir sharedstatedir localstatedir includedir \ 1775 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ 1776 libdir localedir mandir 1777 do 1778 eval ac_val=\$$ac_var 1779 # Remove trailing slashes. 1780 case $ac_val in 1781 */ ) 1782 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` 1783 eval $ac_var=\$ac_val;; 1784 esac 1785 # Be sure to have absolute directory names. 1786 case $ac_val in 1787 [\\/$]* | ?:[\\/]* ) continue;; 1788 NONE | '' ) case $ac_var in *prefix ) continue;; esac;; 1789 esac 1790 as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val" 1791 done 1792 1793 # There might be people who depend on the old broken behavior: `$host' 1794 # used to hold the argument of --host etc. 1795 # FIXME: To remove some day. 1796 build=$build_alias 1797 host=$host_alias 1798 target=$target_alias 1799 1800 # FIXME: To remove some day. 1801 if test "x$host_alias" != x; then 1802 if test "x$build_alias" = x; then 1803 cross_compiling=maybe 1804 elif test "x$build_alias" != "x$host_alias"; then 1805 cross_compiling=yes 1806 fi 1807 fi 1808 1809 ac_tool_prefix= 1810 test -n "$host_alias" && ac_tool_prefix=$host_alias- 1811 1812 test "$silent" = yes && exec 6>/dev/null 1813 1814 1815 ac_pwd=`pwd` && test -n "$ac_pwd" && 1816 ac_ls_di=`ls -di .` && 1817 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || 1818 as_fn_error $? "working directory cannot be determined" 1819 test "X$ac_ls_di" = "X$ac_pwd_ls_di" || 1820 as_fn_error $? "pwd does not report name of working directory" 1821 1822 1823 # Find the source files, if location was not specified. 1824 if test -z "$srcdir"; then 1825 ac_srcdir_defaulted=yes 1826 # Try the directory containing this script, then the parent directory. 1827 ac_confdir=`$as_dirname -- "$as_myself" || 1828 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 1829 X"$as_myself" : 'X\(//\)[^/]' \| \ 1830 X"$as_myself" : 'X\(//\)$' \| \ 1831 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || 1832 $as_echo X"$as_myself" | 1833 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 1834 s//\1/ 1835 q 1836 } 1837 /^X\(\/\/\)[^/].*/{ 1838 s//\1/ 1839 q 1840 } 1841 /^X\(\/\/\)$/{ 1842 s//\1/ 1843 q 1844 } 1845 /^X\(\/\).*/{ 1846 s//\1/ 1847 q 1848 } 1849 s/.*/./; q'` 1850 srcdir=$ac_confdir 1851 if test ! -r "$srcdir/$ac_unique_file"; then 1852 srcdir=.. 1853 fi 1854 else 1855 ac_srcdir_defaulted=no 1856 fi 1857 if test ! -r "$srcdir/$ac_unique_file"; then 1858 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." 1859 as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" 1860 fi 1861 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" 1862 ac_abs_confdir=`( 1863 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" 1864 pwd)` 1865 # When building in place, set srcdir=. 1866 if test "$ac_abs_confdir" = "$ac_pwd"; then 1867 srcdir=. 1868 fi 1869 # Remove unnecessary trailing slashes from srcdir. 1870 # Double slashes in file names in object file debugging info 1871 # mess up M-x gdb in Emacs. 1872 case $srcdir in 1873 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; 1874 esac 1875 for ac_var in $ac_precious_vars; do 1876 eval ac_env_${ac_var}_set=\${${ac_var}+set} 1877 eval ac_env_${ac_var}_value=\$${ac_var} 1878 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} 1879 eval ac_cv_env_${ac_var}_value=\$${ac_var} 1880 done 1881 1882 # 1883 # Report the --help message. 1884 # 1885 if test "$ac_init_help" = "long"; then 1886 # Omit some internal or obsolete options to make the list less imposing. 1887 # This message is too long to be a string in the A/UX 3.1 sh. 1888 cat <<_ACEOF 1889 \`configure' configures OpenJDK jdk9 to adapt to many kinds of systems. 1890 1891 Usage: $0 [OPTION]... [VAR=VALUE]... 1892 1893 To assign environment variables (e.g., CC, CFLAGS...), specify them as 1894 VAR=VALUE. See below for descriptions of some of the useful variables. 1895 1896 Defaults for the options are specified in brackets. 1897 1898 Configuration: 1899 -h, --help display this help and exit 1900 --help=short display options specific to this package 1901 --help=recursive display the short help of all the included packages 1902 -V, --version display version information and exit 1903 -q, --quiet, --silent do not print \`checking ...' messages 1904 --cache-file=FILE cache test results in FILE [disabled] 1905 -C, --config-cache alias for \`--cache-file=config.cache' 1906 -n, --no-create do not create output files 1907 --srcdir=DIR find the sources in DIR [configure dir or \`..'] 1908 1909 Installation directories: 1910 --prefix=PREFIX install architecture-independent files in PREFIX 1911 [$ac_default_prefix] 1912 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX 1913 [PREFIX] 1914 1915 By default, \`make install' will install all the files in 1916 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify 1917 an installation prefix other than \`$ac_default_prefix' using \`--prefix', 1918 for instance \`--prefix=\$HOME'. 1919 1920 For better control, use the options below. 1921 1922 Fine tuning of the installation directories: 1923 --bindir=DIR user executables [EPREFIX/bin] 1924 --sbindir=DIR system admin executables [EPREFIX/sbin] 1925 --libexecdir=DIR program executables [EPREFIX/libexec] 1926 --sysconfdir=DIR read-only single-machine data [PREFIX/etc] 1927 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] 1928 --localstatedir=DIR modifiable single-machine data [PREFIX/var] 1929 --libdir=DIR object code libraries [EPREFIX/lib] 1930 --includedir=DIR C header files [PREFIX/include] 1931 --oldincludedir=DIR C header files for non-gcc [/usr/include] 1932 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] 1933 --datadir=DIR read-only architecture-independent data [DATAROOTDIR] 1934 --infodir=DIR info documentation [DATAROOTDIR/info] 1935 --localedir=DIR locale-dependent data [DATAROOTDIR/locale] 1936 --mandir=DIR man documentation [DATAROOTDIR/man] 1937 --docdir=DIR documentation root [DATAROOTDIR/doc/openjdk] 1938 --htmldir=DIR html documentation [DOCDIR] 1939 --dvidir=DIR dvi documentation [DOCDIR] 1940 --pdfdir=DIR pdf documentation [DOCDIR] 1941 --psdir=DIR ps documentation [DOCDIR] 1942 _ACEOF 1943 1944 cat <<\_ACEOF 1945 1946 X features: 1947 --x-includes=DIR X include files are in DIR 1948 --x-libraries=DIR X library files are in DIR 1949 1950 System types: 1951 --build=BUILD configure for building on BUILD [guessed] 1952 --host=HOST cross-compile to build programs to run on HOST [BUILD] 1953 --target=TARGET configure for building compilers for TARGET [HOST] 1954 _ACEOF 1955 fi 1956 1957 if test -n "$ac_init_help"; then 1958 case $ac_init_help in 1959 short | recursive ) echo "Configuration of OpenJDK jdk9:";; 1960 esac 1961 cat <<\_ACEOF 1962 1963 Optional Features: 1964 --disable-option-checking ignore unrecognized --enable/--with options 1965 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) 1966 --enable-FEATURE[=ARG] include FEATURE [ARG=yes] 1967 --enable-openjdk-only suppress building custom source even if present 1968 [disabled] 1969 --enable-debug set the debug level to fastdebug (shorthand for 1970 --with-debug-level=fastdebug) [disabled] 1971 --enable-headless-only only build headless (no GUI) support [disabled] 1972 --disable-unlimited-crypto 1973 Disable unlimited crypto policy [enabled] 1974 --disable-keep-packaged-modules 1975 Do not keep packaged modules in jdk image [enable] 1976 --enable-static-build enable static library build [disabled] 1977 --disable-warnings-as-errors 1978 do not consider native warnings to be an error 1979 [enabled] 1980 --enable-debug-symbols Deprecated. Option is kept for backwards 1981 compatibility and is ignored 1982 --enable-zip-debug-info Deprecated. Option is kept for backwards 1983 compatibility and is ignored 1984 --enable-native-coverage 1985 enable native compilation with code coverage 1986 data[disabled] 1987 --enable-dtrace[=yes/no/auto] 1988 enable dtrace. Default is auto, where dtrace is 1989 enabled if all dependencies are present. 1990 --enable-aot[=yes/no/auto] 1991 enable ahead of time compilation feature. Default is 1992 auto, where aot is enabled if all dependencies are 1993 present. 1994 --disable-hotspot-gtest Disables building of the Hotspot unit tests 1995 --disable-freetype-bundling 1996 disable bundling of the freetype library with the 1997 build result [enabled on Windows or when using 1998 --with-freetype, disabled otherwise] 1999 --enable-libffi-bundling 2000 enable bundling of libffi.so to make the built JDK 2001 runnable on more systems 2002 --enable-jtreg-failure-handler 2003 forces build of the jtreg failure handler to be 2004 enabled, missing dependencies become fatal errors. 2005 Default is auto, where the failure handler is built 2006 if all dependencies are present and otherwise just 2007 disabled. 2008 --disable-generate-classlist 2009 forces enabling or disabling of the generation of a 2010 CDS classlist at build time. Default is to generate 2011 it when either the server or client JVMs are built. 2012 --enable-sjavac use sjavac to do fast incremental compiles 2013 [disabled] 2014 --disable-javac-server disable javac server [enabled] 2015 --enable-icecc enable distribted compilation of native code using 2016 icecc/icecream [disabled] 2017 --disable-precompiled-headers 2018 disable using precompiled headers when compiling C++ 2019 [enabled] 2020 --enable-ccache enable using ccache to speed up recompilations 2021 [disabled] 2022 2023 Optional Packages: 2024 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] 2025 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) 2026 --with-target-bits build 32-bit or 64-bit binaries (for platforms that 2027 support it), e.g. --with-target-bits=32 [guessed] 2028 --with-custom-make-dir Deprecated. Option is kept for backwards 2029 compatibility and is ignored 2030 --with-jdk-variant JDK variant to build (normal) [normal] 2031 --with-debug-level set the debug level (release, fastdebug, slowdebug, 2032 optimized) [release] 2033 --with-jvm-variants JVM variants (separated by commas) to build 2034 (server,client,minimal,core,zero,zeroshark,custom) 2035 [server] 2036 --with-cpu-port specify sources to use for Hotspot 64-bit ARM port 2037 (arm64,aarch64) [aarch64] 2038 --with-devkit use this devkit for compilers, tools and resources 2039 --with-sys-root alias for --with-sysroot for backwards compatability 2040 --with-sysroot use this directory as sysroot 2041 --with-tools-dir alias for --with-toolchain-path for backwards 2042 compatibility 2043 --with-toolchain-path prepend these directories when searching for 2044 toolchain binaries (compilers etc) 2045 --with-extra-path prepend these directories to the default path 2046 --with-sdk-name use the platform SDK of the given name. [macosx] 2047 --with-conf-name use this as the name of the configuration [generated 2048 from important configuration options] 2049 --with-output-sync set make output sync type if supported by make. 2050 [recurse] 2051 --with-default-make-target 2052 set the default make target [exploded-image] 2053 --with-cacerts-file specify alternative cacerts file 2054 --with-copyright-year Set copyright year value for build [current year] 2055 --with-milestone Deprecated. Option is kept for backwards 2056 compatibility and is ignored 2057 --with-update-version Deprecated. Option is kept for backwards 2058 compatibility and is ignored 2059 --with-user-release-suffix 2060 Deprecated. Option is kept for backwards 2061 compatibility and is ignored 2062 --with-build-number Deprecated. Option is kept for backwards 2063 compatibility and is ignored 2064 --with-version-string Set version string [calculated] 2065 --with-version-pre Set the base part of the version 'PRE' field 2066 (pre-release identifier) ['internal'] 2067 --with-version-opt Set version 'OPT' field (build metadata) 2068 [<timestamp>.<user>.<dirname>] 2069 --with-version-build Set version 'BUILD' field (build number) [not 2070 specified] 2071 --with-version-major Set version 'MAJOR' field (first number) [current 2072 source value] 2073 --with-version-minor Set version 'MINOR' field (second number) [current 2074 source value] 2075 --with-version-security Set version 'SECURITY' field (third number) [current 2076 source value] 2077 --with-version-patch Set version 'PATCH' field (fourth number) [not 2078 specified] 2079 --with-boot-jdk path to Boot JDK (used to bootstrap build) [probed] 2080 --with-build-jdk path to JDK of same version as is being built[the 2081 newly built JDK] 2082 --with-add-source-root Deprecated. Option is kept for backwards 2083 compatibility and is ignored 2084 --with-override-source-root 2085 Deprecated. Option is kept for backwards 2086 compatibility and is ignored 2087 --with-adds-and-overrides 2088 Deprecated. Option is kept for backwards 2089 compatibility and is ignored 2090 --with-override-langtools 2091 Deprecated. Option is kept for backwards 2092 compatibility and is ignored 2093 --with-override-corba Deprecated. Option is kept for backwards 2094 compatibility and is ignored 2095 --with-override-jaxp Deprecated. Option is kept for backwards 2096 compatibility and is ignored 2097 --with-override-jaxws Deprecated. Option is kept for backwards 2098 compatibility and is ignored 2099 --with-override-hotspot Deprecated. Option is kept for backwards 2100 compatibility and is ignored 2101 --with-override-nashorn Deprecated. Option is kept for backwards 2102 compatibility and is ignored 2103 --with-override-jdk Deprecated. Option is kept for backwards 2104 compatibility and is ignored 2105 --with-import_hotspot Deprecated. Option is kept for backwards 2106 compatibility and is ignored 2107 --with-import-modules import a set of prebuilt modules either as a zip 2108 file or an exploded directory 2109 --with-toolchain-type the toolchain type (or family) to use, use '--help' 2110 to show possible values [platform dependent] 2111 --with-extra-cflags extra flags to be used when compiling jdk c-files 2112 --with-extra-cxxflags extra flags to be used when compiling jdk c++-files 2113 --with-extra-ldflags extra flags to be used when linking jdk 2114 --with-toolchain-version 2115 the version of the toolchain to look for, use 2116 '--help' to show possible values [platform 2117 dependent] 2118 --with-build-devkit Devkit to use for the build platform toolchain 2119 --with-jtreg Regression Test Harness [probed] 2120 --with-abi-profile specify ABI profile for ARM builds 2121 (arm-vfp-sflt,arm-vfp-hflt,arm-sflt, 2122 armv5-vfp-sflt,armv6-vfp-hflt,arm64,aarch64) 2123 [toolchain dependent] 2124 --with-native-debug-symbols 2125 set the native debug symbol configuration (none, 2126 internal, external, zipped) [varying] 2127 --with-stdc++lib=<static>,<dynamic>,<default> 2128 force linking of the C++ runtime on Linux to either 2129 static or dynamic, default is static with dynamic as 2130 fallback 2131 --with-msvcr-dll path to microsoft C runtime dll (msvcr*.dll) 2132 (Windows only) [probed] 2133 --with-msvcp-dll path to microsoft C++ runtime dll (msvcp*.dll) 2134 (Windows only) [probed] 2135 --with-x use the X Window System 2136 --with-cups specify prefix directory for the cups package 2137 (expecting the headers under PATH/include) 2138 --with-cups-include specify directory for the cups include files 2139 --with-freetype specify prefix directory for the freetype package 2140 (expecting the libraries under PATH/lib and the 2141 headers under PATH/include) 2142 --with-freetype-include specify directory for the freetype include files 2143 --with-freetype-lib specify directory for the freetype library 2144 --with-freetype-src specify directory with freetype sources to 2145 automatically build the library (experimental, 2146 Windows-only) 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-libelf specify prefix directory for the libelf package 2174 (expecting the libraries under PATH/lib and the 2175 headers under PATH/include) 2176 --with-libelf-include specify directory for the libelf include files 2177 --with-libelf-lib specify directory for the libelf library 2178 --with-jvm-features additional JVM features to enable (separated by 2179 comma), use '--help' to show possible values [none] 2180 --with-jvm-interpreter Deprecated. Option is kept for backwards 2181 compatibility and is ignored 2182 --with-num-cores number of cores in the build system, e.g. 2183 --with-num-cores=8 [probed] 2184 --with-memory-size memory (in MB) available in the build system, e.g. 2185 --with-memory-size=1024 [probed] 2186 --with-jobs number of parallel jobs to let make run [calculated 2187 based on cores and memory] 2188 --with-test-jobs number of parallel tests jobs to run [based on build 2189 jobs] 2190 --with-boot-jdk-jvmargs specify JVM arguments to be passed to all java 2191 invocations of boot JDK, overriding the default 2192 values, e.g --with-boot-jdk-jvmargs="-Xmx8G 2193 -enableassertions" 2194 --with-sjavac-server-java 2195 use this java binary for running the sjavac 2196 background server [Boot JDK java] 2197 --with-ccache-dir where to store ccache files [~/.ccache] 2198 2199 Some influential environment variables: 2200 BASENAME Override default value for BASENAME 2201 BASH Override default value for BASH 2202 CAT Override default value for CAT 2203 CHMOD Override default value for CHMOD 2204 CMP Override default value for CMP 2205 COMM Override default value for COMM 2206 CP Override default value for CP 2207 CUT Override default value for CUT 2208 DATE Override default value for DATE 2209 DIFF Override default value for DIFF 2210 DIRNAME Override default value for DIRNAME 2211 ECHO Override default value for ECHO 2212 EXPR Override default value for EXPR 2213 FILE Override default value for FILE 2214 FIND Override default value for FIND 2215 HEAD Override default value for HEAD 2216 GUNZIP Override default value for GUNZIP 2217 GZIP Override default value for GZIP 2218 LN Override default value for LN 2219 LS Override default value for LS 2220 MKDIR Override default value for MKDIR 2221 MKTEMP Override default value for MKTEMP 2222 MV Override default value for MV 2223 NAWK Override default value for NAWK 2224 PRINTF Override default value for PRINTF 2225 RM Override default value for RM 2226 RMDIR Override default value for RMDIR 2227 SH Override default value for SH 2228 SORT Override default value for SORT 2229 TAIL Override default value for TAIL 2230 TAR Override default value for TAR 2231 TEE Override default value for TEE 2232 TOUCH Override default value for TOUCH 2233 TR Override default value for TR 2234 UNAME Override default value for UNAME 2235 UNIQ Override default value for UNIQ 2236 WC Override default value for WC 2237 WHICH Override default value for WHICH 2238 XARGS Override default value for XARGS 2239 AWK Override default value for AWK 2240 GREP Override default value for GREP 2241 EGREP Override default value for EGREP 2242 FGREP Override default value for FGREP 2243 SED Override default value for SED 2244 CYGPATH Override default value for CYGPATH 2245 READLINK Override default value for READLINK 2246 DF Override default value for DF 2247 CPIO Override default value for CPIO 2248 NICE Override default value for NICE 2249 PANDOC Override default value for PANDOC 2250 MAKE Override default value for MAKE 2251 UNZIP Override default value for UNZIP 2252 ZIPEXE Override default value for ZIPEXE 2253 LDD Override default value for LDD 2254 OTOOL Override default value for OTOOL 2255 READELF Override default value for READELF 2256 HG Override default value for HG 2257 STAT Override default value for STAT 2258 TIME Override default value for TIME 2259 DTRACE Override default value for DTRACE 2260 PATCH Override default value for PATCH 2261 DSYMUTIL Override default value for DSYMUTIL 2262 XATTR Override default value for XATTR 2263 CODESIGN Override default value for CODESIGN 2264 SETFILE Override default value for SETFILE 2265 PKG_CONFIG path to pkg-config utility 2266 JAVA Override default value for JAVA 2267 JAVAC Override default value for JAVAC 2268 JAVAH Override default value for JAVAH 2269 JAR Override default value for JAR 2270 JARSIGNER Override default value for JARSIGNER 2271 CC C compiler command 2272 CFLAGS C compiler flags 2273 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a 2274 nonstandard directory <lib dir> 2275 LIBS libraries to pass to the linker, e.g. -l<library> 2276 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if 2277 you have headers in a nonstandard directory <include dir> 2278 CXX C++ compiler command 2279 CXXFLAGS C++ compiler flags 2280 CPP C preprocessor 2281 CXXCPP C++ preprocessor 2282 AS Override default value for AS 2283 AR Override default value for AR 2284 LIPO Override default value for LIPO 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 ELF_CFLAGS C compiler flags for ELF, overriding pkg-config 2313 ELF_LIBS linker flags for ELF, overriding pkg-config 2314 ICECC_CMD Override default value for ICECC_CMD 2315 ICECC_CREATE_ENV 2316 Override default value for ICECC_CREATE_ENV 2317 ICECC_WRAPPER 2318 Override default value for ICECC_WRAPPER 2319 CCACHE Override default value for CCACHE 2320 2321 Use these variables to override the choices made by `configure' or to help 2322 it to find libraries and programs with nonstandard names/locations. 2323 2324 Report bugs to <build-dev@openjdk.java.net>. 2325 OpenJDK home page: <http://openjdk.java.net>. 2326 _ACEOF 2327 ac_status=$? 2328 fi 2329 2330 if test "$ac_init_help" = "recursive"; then 2331 # If there are subdirs, report their specific --help. 2332 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue 2333 test -d "$ac_dir" || 2334 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || 2335 continue 2336 ac_builddir=. 2337 2338 case "$ac_dir" in 2339 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; 2340 *) 2341 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` 2342 # A ".." for each directory in $ac_dir_suffix. 2343 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` 2344 case $ac_top_builddir_sub in 2345 "") ac_top_builddir_sub=. ac_top_build_prefix= ;; 2346 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; 2347 esac ;; 2348 esac 2349 ac_abs_top_builddir=$ac_pwd 2350 ac_abs_builddir=$ac_pwd$ac_dir_suffix 2351 # for backward compatibility: 2352 ac_top_builddir=$ac_top_build_prefix 2353 2354 case $srcdir in 2355 .) # We are building in place. 2356 ac_srcdir=. 2357 ac_top_srcdir=$ac_top_builddir_sub 2358 ac_abs_top_srcdir=$ac_pwd ;; 2359 [\\/]* | ?:[\\/]* ) # Absolute name. 2360 ac_srcdir=$srcdir$ac_dir_suffix; 2361 ac_top_srcdir=$srcdir 2362 ac_abs_top_srcdir=$srcdir ;; 2363 *) # Relative name. 2364 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix 2365 ac_top_srcdir=$ac_top_build_prefix$srcdir 2366 ac_abs_top_srcdir=$ac_pwd/$srcdir ;; 2367 esac 2368 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix 2369 2370 cd "$ac_dir" || { ac_status=$?; continue; } 2371 # Check for guested configure. 2372 if test -f "$ac_srcdir/configure.gnu"; then 2373 echo && 2374 $SHELL "$ac_srcdir/configure.gnu" --help=recursive 2375 elif test -f "$ac_srcdir/configure"; then 2376 echo && 2377 $SHELL "$ac_srcdir/configure" --help=recursive 2378 else 2379 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 2380 fi || ac_status=$? 2381 cd "$ac_pwd" || { ac_status=$?; break; } 2382 done 2383 fi 2384 2385 test -n "$ac_init_help" && exit $ac_status 2386 if $ac_init_version; then 2387 cat <<\_ACEOF 2388 OpenJDK configure jdk9 2389 generated by GNU Autoconf 2.69 2390 2391 Copyright (C) 2012 Free Software Foundation, Inc. 2392 This configure script is free software; the Free Software Foundation 2393 gives unlimited permission to copy, distribute and modify it. 2394 _ACEOF 2395 exit 2396 fi 2397 2398 ## ------------------------ ## 2399 ## Autoconf initialization. ## 2400 ## ------------------------ ## 2401 2402 # ac_fn_c_try_compile LINENO 2403 # -------------------------- 2404 # Try to compile conftest.$ac_ext, and return whether this succeeded. 2405 ac_fn_c_try_compile () 2406 { 2407 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2408 rm -f conftest.$ac_objext 2409 if { { ac_try="$ac_compile" 2410 case "(($ac_try" in 2411 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2412 *) ac_try_echo=$ac_try;; 2413 esac 2414 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2415 $as_echo "$ac_try_echo"; } >&5 2416 (eval "$ac_compile") 2>conftest.err 2417 ac_status=$? 2418 if test -s conftest.err; then 2419 grep -v '^ *+' conftest.err >conftest.er1 2420 cat conftest.er1 >&5 2421 mv -f conftest.er1 conftest.err 2422 fi 2423 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2424 test $ac_status = 0; } && { 2425 test -z "$ac_c_werror_flag" || 2426 test ! -s conftest.err 2427 } && test -s conftest.$ac_objext; then : 2428 ac_retval=0 2429 else 2430 $as_echo "$as_me: failed program was:" >&5 2431 sed 's/^/| /' conftest.$ac_ext >&5 2432 2433 ac_retval=1 2434 fi 2435 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2436 as_fn_set_status $ac_retval 2437 2438 } # ac_fn_c_try_compile 2439 2440 # ac_fn_cxx_try_compile LINENO 2441 # ---------------------------- 2442 # Try to compile conftest.$ac_ext, and return whether this succeeded. 2443 ac_fn_cxx_try_compile () 2444 { 2445 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2446 rm -f conftest.$ac_objext 2447 if { { ac_try="$ac_compile" 2448 case "(($ac_try" in 2449 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2450 *) ac_try_echo=$ac_try;; 2451 esac 2452 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2453 $as_echo "$ac_try_echo"; } >&5 2454 (eval "$ac_compile") 2>conftest.err 2455 ac_status=$? 2456 if test -s conftest.err; then 2457 grep -v '^ *+' conftest.err >conftest.er1 2458 cat conftest.er1 >&5 2459 mv -f conftest.er1 conftest.err 2460 fi 2461 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2462 test $ac_status = 0; } && { 2463 test -z "$ac_cxx_werror_flag" || 2464 test ! -s conftest.err 2465 } && test -s conftest.$ac_objext; then : 2466 ac_retval=0 2467 else 2468 $as_echo "$as_me: failed program was:" >&5 2469 sed 's/^/| /' conftest.$ac_ext >&5 2470 2471 ac_retval=1 2472 fi 2473 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2474 as_fn_set_status $ac_retval 2475 2476 } # ac_fn_cxx_try_compile 2477 2478 # ac_fn_c_try_cpp LINENO 2479 # ---------------------- 2480 # Try to preprocess conftest.$ac_ext, and return whether this succeeded. 2481 ac_fn_c_try_cpp () 2482 { 2483 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2484 if { { ac_try="$ac_cpp conftest.$ac_ext" 2485 case "(($ac_try" in 2486 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2487 *) ac_try_echo=$ac_try;; 2488 esac 2489 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2490 $as_echo "$ac_try_echo"; } >&5 2491 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err 2492 ac_status=$? 2493 if test -s conftest.err; then 2494 grep -v '^ *+' conftest.err >conftest.er1 2495 cat conftest.er1 >&5 2496 mv -f conftest.er1 conftest.err 2497 fi 2498 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2499 test $ac_status = 0; } > conftest.i && { 2500 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || 2501 test ! -s conftest.err 2502 }; then : 2503 ac_retval=0 2504 else 2505 $as_echo "$as_me: failed program was:" >&5 2506 sed 's/^/| /' conftest.$ac_ext >&5 2507 2508 ac_retval=1 2509 fi 2510 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2511 as_fn_set_status $ac_retval 2512 2513 } # ac_fn_c_try_cpp 2514 2515 # ac_fn_cxx_try_cpp LINENO 2516 # ------------------------ 2517 # Try to preprocess conftest.$ac_ext, and return whether this succeeded. 2518 ac_fn_cxx_try_cpp () 2519 { 2520 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2521 if { { ac_try="$ac_cpp conftest.$ac_ext" 2522 case "(($ac_try" in 2523 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2524 *) ac_try_echo=$ac_try;; 2525 esac 2526 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2527 $as_echo "$ac_try_echo"; } >&5 2528 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err 2529 ac_status=$? 2530 if test -s conftest.err; then 2531 grep -v '^ *+' conftest.err >conftest.er1 2532 cat conftest.er1 >&5 2533 mv -f conftest.er1 conftest.err 2534 fi 2535 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2536 test $ac_status = 0; } > conftest.i && { 2537 test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" || 2538 test ! -s conftest.err 2539 }; then : 2540 ac_retval=0 2541 else 2542 $as_echo "$as_me: failed program was:" >&5 2543 sed 's/^/| /' conftest.$ac_ext >&5 2544 2545 ac_retval=1 2546 fi 2547 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2548 as_fn_set_status $ac_retval 2549 2550 } # ac_fn_cxx_try_cpp 2551 2552 # ac_fn_c_try_link LINENO 2553 # ----------------------- 2554 # Try to link conftest.$ac_ext, and return whether this succeeded. 2555 ac_fn_c_try_link () 2556 { 2557 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2558 rm -f conftest.$ac_objext conftest$ac_exeext 2559 if { { ac_try="$ac_link" 2560 case "(($ac_try" in 2561 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2562 *) ac_try_echo=$ac_try;; 2563 esac 2564 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2565 $as_echo "$ac_try_echo"; } >&5 2566 (eval "$ac_link") 2>conftest.err 2567 ac_status=$? 2568 if test -s conftest.err; then 2569 grep -v '^ *+' conftest.err >conftest.er1 2570 cat conftest.er1 >&5 2571 mv -f conftest.er1 conftest.err 2572 fi 2573 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2574 test $ac_status = 0; } && { 2575 test -z "$ac_c_werror_flag" || 2576 test ! -s conftest.err 2577 } && test -s conftest$ac_exeext && { 2578 test "$cross_compiling" = yes || 2579 test -x conftest$ac_exeext 2580 }; then : 2581 ac_retval=0 2582 else 2583 $as_echo "$as_me: failed program was:" >&5 2584 sed 's/^/| /' conftest.$ac_ext >&5 2585 2586 ac_retval=1 2587 fi 2588 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information 2589 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would 2590 # interfere with the next link command; also delete a directory that is 2591 # left behind by Apple's compiler. We do this before executing the actions. 2592 rm -rf conftest.dSYM conftest_ipa8_conftest.oo 2593 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2594 as_fn_set_status $ac_retval 2595 2596 } # ac_fn_c_try_link 2597 2598 # ac_fn_cxx_check_header_mongrel LINENO HEADER VAR INCLUDES 2599 # --------------------------------------------------------- 2600 # Tests whether HEADER exists, giving a warning if it cannot be compiled using 2601 # the include files in INCLUDES and setting the cache variable VAR 2602 # accordingly. 2603 ac_fn_cxx_check_header_mongrel () 2604 { 2605 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2606 if eval \${$3+:} false; then : 2607 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2608 $as_echo_n "checking for $2... " >&6; } 2609 if eval \${$3+:} false; then : 2610 $as_echo_n "(cached) " >&6 2611 fi 2612 eval ac_res=\$$3 2613 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 2614 $as_echo "$ac_res" >&6; } 2615 else 2616 # Is the header compilable? 2617 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 2618 $as_echo_n "checking $2 usability... " >&6; } 2619 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2620 /* end confdefs.h. */ 2621 $4 2622 #include <$2> 2623 _ACEOF 2624 if ac_fn_cxx_try_compile "$LINENO"; then : 2625 ac_header_compiler=yes 2626 else 2627 ac_header_compiler=no 2628 fi 2629 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2630 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 2631 $as_echo "$ac_header_compiler" >&6; } 2632 2633 # Is the header present? 2634 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 2635 $as_echo_n "checking $2 presence... " >&6; } 2636 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2637 /* end confdefs.h. */ 2638 #include <$2> 2639 _ACEOF 2640 if ac_fn_cxx_try_cpp "$LINENO"; then : 2641 ac_header_preproc=yes 2642 else 2643 ac_header_preproc=no 2644 fi 2645 rm -f conftest.err conftest.i conftest.$ac_ext 2646 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 2647 $as_echo "$ac_header_preproc" >&6; } 2648 2649 # So? What about this header? 2650 case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in #(( 2651 yes:no: ) 2652 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 2653 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;} 2654 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 2655 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} 2656 ;; 2657 no:yes:* ) 2658 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 2659 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} 2660 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 2661 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} 2662 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 2663 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} 2664 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 2665 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} 2666 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 2667 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} 2668 ( $as_echo "## ----------------------------------------- ## 2669 ## Report this to build-dev@openjdk.java.net ## 2670 ## ----------------------------------------- ##" 2671 ) | sed "s/^/$as_me: WARNING: /" >&2 2672 ;; 2673 esac 2674 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2675 $as_echo_n "checking for $2... " >&6; } 2676 if eval \${$3+:} false; then : 2677 $as_echo_n "(cached) " >&6 2678 else 2679 eval "$3=\$ac_header_compiler" 2680 fi 2681 eval ac_res=\$$3 2682 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 2683 $as_echo "$ac_res" >&6; } 2684 fi 2685 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2686 2687 } # ac_fn_cxx_check_header_mongrel 2688 2689 # ac_fn_cxx_try_run LINENO 2690 # ------------------------ 2691 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes 2692 # that executables *can* be run. 2693 ac_fn_cxx_try_run () 2694 { 2695 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2696 if { { ac_try="$ac_link" 2697 case "(($ac_try" in 2698 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2699 *) ac_try_echo=$ac_try;; 2700 esac 2701 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2702 $as_echo "$ac_try_echo"; } >&5 2703 (eval "$ac_link") 2>&5 2704 ac_status=$? 2705 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2706 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' 2707 { { case "(($ac_try" in 2708 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2709 *) ac_try_echo=$ac_try;; 2710 esac 2711 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2712 $as_echo "$ac_try_echo"; } >&5 2713 (eval "$ac_try") 2>&5 2714 ac_status=$? 2715 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2716 test $ac_status = 0; }; }; then : 2717 ac_retval=0 2718 else 2719 $as_echo "$as_me: program exited with status $ac_status" >&5 2720 $as_echo "$as_me: failed program was:" >&5 2721 sed 's/^/| /' conftest.$ac_ext >&5 2722 2723 ac_retval=$ac_status 2724 fi 2725 rm -rf conftest.dSYM conftest_ipa8_conftest.oo 2726 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2727 as_fn_set_status $ac_retval 2728 2729 } # ac_fn_cxx_try_run 2730 2731 # ac_fn_cxx_check_header_compile LINENO HEADER VAR INCLUDES 2732 # --------------------------------------------------------- 2733 # Tests whether HEADER exists and can be compiled using the include files in 2734 # INCLUDES, setting the cache variable VAR accordingly. 2735 ac_fn_cxx_check_header_compile () 2736 { 2737 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2738 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2739 $as_echo_n "checking for $2... " >&6; } 2740 if eval \${$3+:} false; then : 2741 $as_echo_n "(cached) " >&6 2742 else 2743 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2744 /* end confdefs.h. */ 2745 $4 2746 #include <$2> 2747 _ACEOF 2748 if ac_fn_cxx_try_compile "$LINENO"; then : 2749 eval "$3=yes" 2750 else 2751 eval "$3=no" 2752 fi 2753 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2754 fi 2755 eval ac_res=\$$3 2756 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 2757 $as_echo "$ac_res" >&6; } 2758 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2759 2760 } # ac_fn_cxx_check_header_compile 2761 2762 # ac_fn_cxx_compute_int LINENO EXPR VAR INCLUDES 2763 # ---------------------------------------------- 2764 # Tries to find the compile-time value of EXPR in a program that includes 2765 # INCLUDES, setting VAR accordingly. Returns whether the value could be 2766 # computed 2767 ac_fn_cxx_compute_int () 2768 { 2769 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2770 if test "$cross_compiling" = yes; then 2771 # Depending upon the size, compute the lo and hi bounds. 2772 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2773 /* end confdefs.h. */ 2774 $4 2775 int 2776 main () 2777 { 2778 static int test_array [1 - 2 * !(($2) >= 0)]; 2779 test_array [0] = 0; 2780 return test_array [0]; 2781 2782 ; 2783 return 0; 2784 } 2785 _ACEOF 2786 if ac_fn_cxx_try_compile "$LINENO"; then : 2787 ac_lo=0 ac_mid=0 2788 while :; do 2789 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2790 /* end confdefs.h. */ 2791 $4 2792 int 2793 main () 2794 { 2795 static int test_array [1 - 2 * !(($2) <= $ac_mid)]; 2796 test_array [0] = 0; 2797 return test_array [0]; 2798 2799 ; 2800 return 0; 2801 } 2802 _ACEOF 2803 if ac_fn_cxx_try_compile "$LINENO"; then : 2804 ac_hi=$ac_mid; break 2805 else 2806 as_fn_arith $ac_mid + 1 && ac_lo=$as_val 2807 if test $ac_lo -le $ac_mid; then 2808 ac_lo= ac_hi= 2809 break 2810 fi 2811 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val 2812 fi 2813 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2814 done 2815 else 2816 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2817 /* end confdefs.h. */ 2818 $4 2819 int 2820 main () 2821 { 2822 static int test_array [1 - 2 * !(($2) < 0)]; 2823 test_array [0] = 0; 2824 return test_array [0]; 2825 2826 ; 2827 return 0; 2828 } 2829 _ACEOF 2830 if ac_fn_cxx_try_compile "$LINENO"; then : 2831 ac_hi=-1 ac_mid=-1 2832 while :; do 2833 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2834 /* end confdefs.h. */ 2835 $4 2836 int 2837 main () 2838 { 2839 static int test_array [1 - 2 * !(($2) >= $ac_mid)]; 2840 test_array [0] = 0; 2841 return test_array [0]; 2842 2843 ; 2844 return 0; 2845 } 2846 _ACEOF 2847 if ac_fn_cxx_try_compile "$LINENO"; then : 2848 ac_lo=$ac_mid; break 2849 else 2850 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val 2851 if test $ac_mid -le $ac_hi; then 2852 ac_lo= ac_hi= 2853 break 2854 fi 2855 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val 2856 fi 2857 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2858 done 2859 else 2860 ac_lo= ac_hi= 2861 fi 2862 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2863 fi 2864 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2865 # Binary search between lo and hi bounds. 2866 while test "x$ac_lo" != "x$ac_hi"; do 2867 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val 2868 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2869 /* end confdefs.h. */ 2870 $4 2871 int 2872 main () 2873 { 2874 static int test_array [1 - 2 * !(($2) <= $ac_mid)]; 2875 test_array [0] = 0; 2876 return test_array [0]; 2877 2878 ; 2879 return 0; 2880 } 2881 _ACEOF 2882 if ac_fn_cxx_try_compile "$LINENO"; then : 2883 ac_hi=$ac_mid 2884 else 2885 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val 2886 fi 2887 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2888 done 2889 case $ac_lo in #(( 2890 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;; 2891 '') ac_retval=1 ;; 2892 esac 2893 else 2894 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2895 /* end confdefs.h. */ 2896 $4 2897 static long int longval () { return $2; } 2898 static unsigned long int ulongval () { return $2; } 2899 #include <stdio.h> 2900 #include <stdlib.h> 2901 int 2902 main () 2903 { 2904 2905 FILE *f = fopen ("conftest.val", "w"); 2906 if (! f) 2907 return 1; 2908 if (($2) < 0) 2909 { 2910 long int i = longval (); 2911 if (i != ($2)) 2912 return 1; 2913 fprintf (f, "%ld", i); 2914 } 2915 else 2916 { 2917 unsigned long int i = ulongval (); 2918 if (i != ($2)) 2919 return 1; 2920 fprintf (f, "%lu", i); 2921 } 2922 /* Do not output a trailing newline, as this causes \r\n confusion 2923 on some platforms. */ 2924 return ferror (f) || fclose (f) != 0; 2925 2926 ; 2927 return 0; 2928 } 2929 _ACEOF 2930 if ac_fn_cxx_try_run "$LINENO"; then : 2931 echo >>conftest.val; read $3 <conftest.val; ac_retval=0 2932 else 2933 ac_retval=1 2934 fi 2935 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 2936 conftest.$ac_objext conftest.beam conftest.$ac_ext 2937 rm -f conftest.val 2938 2939 fi 2940 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2941 as_fn_set_status $ac_retval 2942 2943 } # ac_fn_cxx_compute_int 2944 2945 # ac_fn_cxx_try_link LINENO 2946 # ------------------------- 2947 # Try to link conftest.$ac_ext, and return whether this succeeded. 2948 ac_fn_cxx_try_link () 2949 { 2950 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2951 rm -f conftest.$ac_objext conftest$ac_exeext 2952 if { { ac_try="$ac_link" 2953 case "(($ac_try" in 2954 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2955 *) ac_try_echo=$ac_try;; 2956 esac 2957 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2958 $as_echo "$ac_try_echo"; } >&5 2959 (eval "$ac_link") 2>conftest.err 2960 ac_status=$? 2961 if test -s conftest.err; then 2962 grep -v '^ *+' conftest.err >conftest.er1 2963 cat conftest.er1 >&5 2964 mv -f conftest.er1 conftest.err 2965 fi 2966 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2967 test $ac_status = 0; } && { 2968 test -z "$ac_cxx_werror_flag" || 2969 test ! -s conftest.err 2970 } && test -s conftest$ac_exeext && { 2971 test "$cross_compiling" = yes || 2972 test -x conftest$ac_exeext 2973 }; then : 2974 ac_retval=0 2975 else 2976 $as_echo "$as_me: failed program was:" >&5 2977 sed 's/^/| /' conftest.$ac_ext >&5 2978 2979 ac_retval=1 2980 fi 2981 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information 2982 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would 2983 # interfere with the next link command; also delete a directory that is 2984 # left behind by Apple's compiler. We do this before executing the actions. 2985 rm -rf conftest.dSYM conftest_ipa8_conftest.oo 2986 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2987 as_fn_set_status $ac_retval 2988 2989 } # ac_fn_cxx_try_link 2990 2991 # ac_fn_cxx_check_func LINENO FUNC VAR 2992 # ------------------------------------ 2993 # Tests whether FUNC exists, setting the cache variable VAR accordingly 2994 ac_fn_cxx_check_func () 2995 { 2996 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2997 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2998 $as_echo_n "checking for $2... " >&6; } 2999 if eval \${$3+:} false; then : 3000 $as_echo_n "(cached) " >&6 3001 else 3002 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3003 /* end confdefs.h. */ 3004 /* Define $2 to an innocuous variant, in case <limits.h> declares $2. 3005 For example, HP-UX 11i <limits.h> declares gettimeofday. */ 3006 #define $2 innocuous_$2 3007 3008 /* System header to define __stub macros and hopefully few prototypes, 3009 which can conflict with char $2 (); below. 3010 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 3011 <limits.h> exists even on freestanding compilers. */ 3012 3013 #ifdef __STDC__ 3014 # include <limits.h> 3015 #else 3016 # include <assert.h> 3017 #endif 3018 3019 #undef $2 3020 3021 /* Override any GCC internal prototype to avoid an error. 3022 Use char because int might match the return type of a GCC 3023 builtin and then its argument prototype would still apply. */ 3024 #ifdef __cplusplus 3025 extern "C" 3026 #endif 3027 char $2 (); 3028 /* The GNU C library defines this for functions which it implements 3029 to always fail with ENOSYS. Some functions are actually named 3030 something starting with __ and the normal name is an alias. */ 3031 #if defined __stub_$2 || defined __stub___$2 3032 choke me 3033 #endif 3034 3035 int 3036 main () 3037 { 3038 return $2 (); 3039 ; 3040 return 0; 3041 } 3042 _ACEOF 3043 if ac_fn_cxx_try_link "$LINENO"; then : 3044 eval "$3=yes" 3045 else 3046 eval "$3=no" 3047 fi 3048 rm -f core conftest.err conftest.$ac_objext \ 3049 conftest$ac_exeext conftest.$ac_ext 3050 fi 3051 eval ac_res=\$$3 3052 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 3053 $as_echo "$ac_res" >&6; } 3054 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 3055 3056 } # ac_fn_cxx_check_func 3057 3058 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES 3059 # ------------------------------------------------------- 3060 # Tests whether HEADER exists and can be compiled using the include files in 3061 # INCLUDES, setting the cache variable VAR accordingly. 3062 ac_fn_c_check_header_compile () 3063 { 3064 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 3065 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 3066 $as_echo_n "checking for $2... " >&6; } 3067 if eval \${$3+:} false; then : 3068 $as_echo_n "(cached) " >&6 3069 else 3070 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3071 /* end confdefs.h. */ 3072 $4 3073 #include <$2> 3074 _ACEOF 3075 if ac_fn_c_try_compile "$LINENO"; then : 3076 eval "$3=yes" 3077 else 3078 eval "$3=no" 3079 fi 3080 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 3081 fi 3082 eval ac_res=\$$3 3083 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 3084 $as_echo "$ac_res" >&6; } 3085 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 3086 3087 } # ac_fn_c_check_header_compile 3088 cat >config.log <<_ACEOF 3089 This file contains any messages produced by compilers while 3090 running configure, to aid debugging if configure makes a mistake. 3091 3092 It was created by OpenJDK $as_me jdk9, which was 3093 generated by GNU Autoconf 2.69. Invocation command line was 3094 3095 $ $0 $@ 3096 3097 _ACEOF 3098 exec 5>>config.log 3099 { 3100 cat <<_ASUNAME 3101 ## --------- ## 3102 ## Platform. ## 3103 ## --------- ## 3104 3105 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` 3106 uname -m = `(uname -m) 2>/dev/null || echo unknown` 3107 uname -r = `(uname -r) 2>/dev/null || echo unknown` 3108 uname -s = `(uname -s) 2>/dev/null || echo unknown` 3109 uname -v = `(uname -v) 2>/dev/null || echo unknown` 3110 3111 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` 3112 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` 3113 3114 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` 3115 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` 3116 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` 3117 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` 3118 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` 3119 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` 3120 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` 3121 3122 _ASUNAME 3123 3124 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 3125 for as_dir in $PATH 3126 do 3127 IFS=$as_save_IFS 3128 test -z "$as_dir" && as_dir=. 3129 $as_echo "PATH: $as_dir" 3130 done 3131 IFS=$as_save_IFS 3132 3133 } >&5 3134 3135 cat >&5 <<_ACEOF 3136 3137 3138 ## ----------- ## 3139 ## Core tests. ## 3140 ## ----------- ## 3141 3142 _ACEOF 3143 3144 3145 # Keep a trace of the command line. 3146 # Strip out --no-create and --no-recursion so they do not pile up. 3147 # Strip out --silent because we don't want to record it for future runs. 3148 # Also quote any args containing shell meta-characters. 3149 # Make two passes to allow for proper duplicate-argument suppression. 3150 ac_configure_args= 3151 ac_configure_args0= 3152 ac_configure_args1= 3153 ac_must_keep_next=false 3154 for ac_pass in 1 2 3155 do 3156 for ac_arg 3157 do 3158 case $ac_arg in 3159 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; 3160 -q | -quiet | --quiet | --quie | --qui | --qu | --q \ 3161 | -silent | --silent | --silen | --sile | --sil) 3162 continue ;; 3163 *\'*) 3164 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; 3165 esac 3166 case $ac_pass in 3167 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; 3168 2) 3169 as_fn_append ac_configure_args1 " '$ac_arg'" 3170 if test $ac_must_keep_next = true; then 3171 ac_must_keep_next=false # Got value, back to normal. 3172 else 3173 case $ac_arg in 3174 *=* | --config-cache | -C | -disable-* | --disable-* \ 3175 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ 3176 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ 3177 | -with-* | --with-* | -without-* | --without-* | --x) 3178 case "$ac_configure_args0 " in 3179 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; 3180 esac 3181 ;; 3182 -* ) ac_must_keep_next=true ;; 3183 esac 3184 fi 3185 as_fn_append ac_configure_args " '$ac_arg'" 3186 ;; 3187 esac 3188 done 3189 done 3190 { ac_configure_args0=; unset ac_configure_args0;} 3191 { ac_configure_args1=; unset ac_configure_args1;} 3192 3193 # When interrupted or exit'd, cleanup temporary files, and complete 3194 # config.log. We remove comments because anyway the quotes in there 3195 # would cause problems or look ugly. 3196 # WARNING: Use '\'' to represent an apostrophe within the trap. 3197 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. 3198 trap 'exit_status=$? 3199 # Save into config.log some information that might help in debugging. 3200 { 3201 echo 3202 3203 $as_echo "## ---------------- ## 3204 ## Cache variables. ## 3205 ## ---------------- ##" 3206 echo 3207 # The following way of writing the cache mishandles newlines in values, 3208 ( 3209 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do 3210 eval ac_val=\$$ac_var 3211 case $ac_val in #( 3212 *${as_nl}*) 3213 case $ac_var in #( 3214 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 3215 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; 3216 esac 3217 case $ac_var in #( 3218 _ | IFS | as_nl) ;; #( 3219 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( 3220 *) { eval $ac_var=; unset $ac_var;} ;; 3221 esac ;; 3222 esac 3223 done 3224 (set) 2>&1 | 3225 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( 3226 *${as_nl}ac_space=\ *) 3227 sed -n \ 3228 "s/'\''/'\''\\\\'\'''\''/g; 3229 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" 3230 ;; #( 3231 *) 3232 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" 3233 ;; 3234 esac | 3235 sort 3236 ) 3237 echo 3238 3239 $as_echo "## ----------------- ## 3240 ## Output variables. ## 3241 ## ----------------- ##" 3242 echo 3243 for ac_var in $ac_subst_vars 3244 do 3245 eval ac_val=\$$ac_var 3246 case $ac_val in 3247 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; 3248 esac 3249 $as_echo "$ac_var='\''$ac_val'\''" 3250 done | sort 3251 echo 3252 3253 if test -n "$ac_subst_files"; then 3254 $as_echo "## ------------------- ## 3255 ## File substitutions. ## 3256 ## ------------------- ##" 3257 echo 3258 for ac_var in $ac_subst_files 3259 do 3260 eval ac_val=\$$ac_var 3261 case $ac_val in 3262 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; 3263 esac 3264 $as_echo "$ac_var='\''$ac_val'\''" 3265 done | sort 3266 echo 3267 fi 3268 3269 if test -s confdefs.h; then 3270 $as_echo "## ----------- ## 3271 ## confdefs.h. ## 3272 ## ----------- ##" 3273 echo 3274 cat confdefs.h 3275 echo 3276 fi 3277 test "$ac_signal" != 0 && 3278 $as_echo "$as_me: caught signal $ac_signal" 3279 $as_echo "$as_me: exit $exit_status" 3280 } >&5 3281 rm -f core *.core core.conftest.* && 3282 rm -f -r conftest* confdefs* conf$$* $ac_clean_files && 3283 exit $exit_status 3284 ' 0 3285 for ac_signal in 1 2 13 15; do 3286 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal 3287 done 3288 ac_signal=0 3289 3290 # confdefs.h avoids OS command line length limits that DEFS can exceed. 3291 rm -f -r conftest* confdefs.h 3292 3293 $as_echo "/* confdefs.h */" > confdefs.h 3294 3295 # Predefined preprocessor variables. 3296 3297 cat >>confdefs.h <<_ACEOF 3298 #define PACKAGE_NAME "$PACKAGE_NAME" 3299 _ACEOF 3300 3301 cat >>confdefs.h <<_ACEOF 3302 #define PACKAGE_TARNAME "$PACKAGE_TARNAME" 3303 _ACEOF 3304 3305 cat >>confdefs.h <<_ACEOF 3306 #define PACKAGE_VERSION "$PACKAGE_VERSION" 3307 _ACEOF 3308 3309 cat >>confdefs.h <<_ACEOF 3310 #define PACKAGE_STRING "$PACKAGE_STRING" 3311 _ACEOF 3312 3313 cat >>confdefs.h <<_ACEOF 3314 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" 3315 _ACEOF 3316 3317 cat >>confdefs.h <<_ACEOF 3318 #define PACKAGE_URL "$PACKAGE_URL" 3319 _ACEOF 3320 3321 3322 # Let the site file select an alternate cache file if it wants to. 3323 # Prefer an explicitly selected file to automatically selected ones. 3324 ac_site_file1=NONE 3325 ac_site_file2=NONE 3326 if test -n "$CONFIG_SITE"; then 3327 # We do not want a PATH search for config.site. 3328 case $CONFIG_SITE in #(( 3329 -*) ac_site_file1=./$CONFIG_SITE;; 3330 */*) ac_site_file1=$CONFIG_SITE;; 3331 *) ac_site_file1=./$CONFIG_SITE;; 3332 esac 3333 elif test "x$prefix" != xNONE; then 3334 ac_site_file1=$prefix/share/config.site 3335 ac_site_file2=$prefix/etc/config.site 3336 else 3337 ac_site_file1=$ac_default_prefix/share/config.site 3338 ac_site_file2=$ac_default_prefix/etc/config.site 3339 fi 3340 for ac_site_file in "$ac_site_file1" "$ac_site_file2" 3341 do 3342 test "x$ac_site_file" = xNONE && continue 3343 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then 3344 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 3345 $as_echo "$as_me: loading site script $ac_site_file" >&6;} 3346 sed 's/^/| /' "$ac_site_file" >&5 3347 . "$ac_site_file" \ 3348 || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 3349 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 3350 as_fn_error $? "failed to load site script $ac_site_file 3351 See \`config.log' for more details" "$LINENO" 5; } 3352 fi 3353 done 3354 3355 if test -r "$cache_file"; then 3356 # Some versions of bash will fail to source /dev/null (special files 3357 # actually), so we avoid doing that. DJGPP emulates it as a regular file. 3358 if test /dev/null != "$cache_file" && test -f "$cache_file"; then 3359 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 3360 $as_echo "$as_me: loading cache $cache_file" >&6;} 3361 case $cache_file in 3362 [\\/]* | ?:[\\/]* ) . "$cache_file";; 3363 *) . "./$cache_file";; 3364 esac 3365 fi 3366 else 3367 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 3368 $as_echo "$as_me: creating cache $cache_file" >&6;} 3369 >$cache_file 3370 fi 3371 3372 # Check that the precious variables saved in the cache have kept the same 3373 # value. 3374 ac_cache_corrupted=false 3375 for ac_var in $ac_precious_vars; do 3376 eval ac_old_set=\$ac_cv_env_${ac_var}_set 3377 eval ac_new_set=\$ac_env_${ac_var}_set 3378 eval ac_old_val=\$ac_cv_env_${ac_var}_value 3379 eval ac_new_val=\$ac_env_${ac_var}_value 3380 case $ac_old_set,$ac_new_set in 3381 set,) 3382 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 3383 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} 3384 ac_cache_corrupted=: ;; 3385 ,set) 3386 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 3387 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} 3388 ac_cache_corrupted=: ;; 3389 ,);; 3390 *) 3391 if test "x$ac_old_val" != "x$ac_new_val"; then 3392 # differences in whitespace do not lead to failure. 3393 ac_old_val_w=`echo x $ac_old_val` 3394 ac_new_val_w=`echo x $ac_new_val` 3395 if test "$ac_old_val_w" != "$ac_new_val_w"; then 3396 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 3397 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} 3398 ac_cache_corrupted=: 3399 else 3400 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 3401 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} 3402 eval $ac_var=\$ac_old_val 3403 fi 3404 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 3405 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;} 3406 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 3407 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;} 3408 fi;; 3409 esac 3410 # Pass precious variables to config.status. 3411 if test "$ac_new_set" = set; then 3412 case $ac_new_val in 3413 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; 3414 *) ac_arg=$ac_var=$ac_new_val ;; 3415 esac 3416 case " $ac_configure_args " in 3417 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. 3418 *) as_fn_append ac_configure_args " '$ac_arg'" ;; 3419 esac 3420 fi 3421 done 3422 if $ac_cache_corrupted; then 3423 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 3424 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 3425 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 3426 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} 3427 as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 3428 fi 3429 ## -------------------- ## 3430 ## Main body of script. ## 3431 ## -------------------- ## 3432 3433 ac_ext=c 3434 ac_cpp='$CPP $CPPFLAGS' 3435 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 3436 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 3437 ac_compiler_gnu=$ac_cv_c_compiler_gnu 3438 3439 3440 3441 ac_aux_dir= 3442 for ac_dir in $TOPDIR/common/autoconf/build-aux "$srcdir"/$TOPDIR/common/autoconf/build-aux; do 3443 if test -f "$ac_dir/install-sh"; then 3444 ac_aux_dir=$ac_dir 3445 ac_install_sh="$ac_aux_dir/install-sh -c" 3446 break 3447 elif test -f "$ac_dir/install.sh"; then 3448 ac_aux_dir=$ac_dir 3449 ac_install_sh="$ac_aux_dir/install.sh -c" 3450 break 3451 elif test -f "$ac_dir/shtool"; then 3452 ac_aux_dir=$ac_dir 3453 ac_install_sh="$ac_aux_dir/shtool install -c" 3454 break 3455 fi 3456 done 3457 if test -z "$ac_aux_dir"; then 3458 as_fn_error $? "cannot find install-sh, install.sh, or shtool in $TOPDIR/common/autoconf/build-aux \"$srcdir\"/$TOPDIR/common/autoconf/build-aux" "$LINENO" 5 3459 fi 3460 3461 # These three variables are undocumented and unsupported, 3462 # and are intended to be withdrawn in a future Autoconf release. 3463 # They can cause serious problems if a builder's source tree is in a directory 3464 # whose full name contains unusual characters. 3465 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. 3466 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. 3467 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. 3468 3469 3470 # pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*- 3471 3472 # 3473 # Copyright (c) 2012, 2013, Oracle and/or its affiliates. All rights reserved. 3474 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3475 # 3476 # This code is free software; you can redistribute it and/or modify it 3477 # under the terms of the GNU General Public License version 2 only, as 3478 # published by the Free Software Foundation. Oracle designates this 3479 # particular file as subject to the "Classpath" exception as provided 3480 # by Oracle in the LICENSE file that accompanied this code. 3481 # 3482 # This code is distributed in the hope that it will be useful, but WITHOUT 3483 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3484 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3485 # version 2 for more details (a copy is included in the LICENSE file that 3486 # accompanied this code). 3487 # 3488 # You should have received a copy of the GNU General Public License version 3489 # 2 along with this work; if not, write to the Free Software Foundation, 3490 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3491 # 3492 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3493 # or visit www.oracle.com if you need additional information or have any 3494 # questions. 3495 # 3496 3497 # 3498 # Copyright © 2004 Scott James Remnant <scott@netsplit.com>. 3499 # 3500 # This program is free software; you can redistribute it and/or modify 3501 # it under the terms of the GNU General Public License as published by 3502 # the Free Software Foundation; either version 2 of the License, or 3503 # (at your option) any later version. 3504 # 3505 # This program is distributed in the hope that it will be useful, but 3506 # WITHOUT ANY WARRANTY; without even the implied warranty of 3507 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 3508 # General Public License for more details. 3509 # 3510 # You should have received a copy of the GNU General Public License 3511 # along with this program; if not, write to the Free Software 3512 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 3513 # 3514 # As a special exception to the GNU General Public License, if you 3515 # distribute this file as part of a program that contains a 3516 # configuration script generated by Autoconf, you may include it under 3517 # the same distribution terms that you use for the rest of that program. 3518 3519 # PKG_PROG_PKG_CONFIG([MIN-VERSION]) 3520 # ---------------------------------- 3521 # PKG_PROG_PKG_CONFIG 3522 3523 # PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]) 3524 # 3525 # Check to see whether a particular set of modules exists. Similar 3526 # to PKG_CHECK_MODULES(), but does not set variables or print errors. 3527 # 3528 # 3529 # Similar to PKG_CHECK_MODULES, make sure that the first instance of 3530 # this or PKG_CHECK_MODULES is called, or make sure to call 3531 # PKG_CHECK_EXISTS manually 3532 # -------------------------------------------------------------- 3533 3534 3535 3536 # _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES]) 3537 # --------------------------------------------- 3538 # _PKG_CONFIG 3539 3540 # _PKG_SHORT_ERRORS_SUPPORTED 3541 # ----------------------------- 3542 # _PKG_SHORT_ERRORS_SUPPORTED 3543 3544 3545 # PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND], 3546 # [ACTION-IF-NOT-FOUND]) 3547 # 3548 # 3549 # Note that if there is a possibility the first call to 3550 # PKG_CHECK_MODULES might not happen, you should be sure to include an 3551 # explicit call to PKG_PROG_PKG_CONFIG in your configure.ac 3552 # 3553 # 3554 # -------------------------------------------------------------- 3555 # PKG_CHECK_MODULES 3556 3557 3558 # Include these first... 3559 # 3560 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 3561 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3562 # 3563 # This code is free software; you can redistribute it and/or modify it 3564 # under the terms of the GNU General Public License version 2 only, as 3565 # published by the Free Software Foundation. Oracle designates this 3566 # particular file as subject to the "Classpath" exception as provided 3567 # by Oracle in the LICENSE file that accompanied this code. 3568 # 3569 # This code is distributed in the hope that it will be useful, but WITHOUT 3570 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3571 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3572 # version 2 for more details (a copy is included in the LICENSE file that 3573 # accompanied this code). 3574 # 3575 # You should have received a copy of the GNU General Public License version 3576 # 2 along with this work; if not, write to the Free Software Foundation, 3577 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3578 # 3579 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3580 # or visit www.oracle.com if you need additional information or have any 3581 # questions. 3582 # 3583 3584 # Create a function/macro that takes a series of named arguments. The call is 3585 # similar to AC_DEFUN, but the setup of the function looks like this: 3586 # BASIC_DEFUN_NAMED([MYFUNC], [FOO *BAR], [$@], [ 3587 # ... do something 3588 # AC_MSG_NOTICE([Value of BAR is ARG_BAR]) 3589 # ]) 3590 # A star (*) in front of a named argument means that it is required and it's 3591 # presence will be verified. To pass e.g. the first value as a normal indexed 3592 # argument, use [m4_shift($@)] as the third argument instead of [$@]. These 3593 # arguments are referenced in the function by their name prefixed by ARG_, e.g. 3594 # "ARG_FOO". 3595 # 3596 # The generated function can be called like this: 3597 # MYFUNC(FOO: [foo-val], 3598 # BAR: [ 3599 # $ECHO hello world 3600 # ]) 3601 # Note that the argument value must start on the same line as the argument name. 3602 # 3603 # Argument 1: Name of the function to define 3604 # Argument 2: List of legal named arguments, with a * prefix for required arguments 3605 # Argument 3: Argument array to treat as named, typically $@ 3606 # Argument 4: The main function body 3607 3608 3609 # Test if $1 is a valid argument to $3 (often is $JAVA passed as $3) 3610 # If so, then append $1 to $2 \ 3611 # Also set JVM_ARG_OK to true/false depending on outcome. 3612 3613 3614 # Appends a string to a path variable, only adding the : when needed. 3615 3616 3617 # Prepends a string to a path variable, only adding the : when needed. 3618 3619 3620 # This will make sure the given variable points to a full and proper 3621 # path. This means: 3622 # 1) There will be no spaces in the path. On unix platforms, 3623 # spaces in the path will result in an error. On Windows, 3624 # the path will be rewritten using short-style to be space-free. 3625 # 2) The path will be absolute, and it will be in unix-style (on 3626 # cygwin). 3627 # $1: The name of the variable to fix 3628 3629 3630 # This will make sure the given variable points to a executable 3631 # with a full and proper path. This means: 3632 # 1) There will be no spaces in the path. On unix platforms, 3633 # spaces in the path will result in an error. On Windows, 3634 # the path will be rewritten using short-style to be space-free. 3635 # 2) The path will be absolute, and it will be in unix-style (on 3636 # cygwin). 3637 # Any arguments given to the executable is preserved. 3638 # If the input variable does not have a directory specification, then 3639 # it need to be in the PATH. 3640 # $1: The name of the variable to fix 3641 3642 3643 3644 3645 # Register a --with argument but mark it as deprecated 3646 # $1: The name of the with argument to deprecate, not including --with- 3647 3648 3649 # Register a --enable argument but mark it as deprecated 3650 # $1: The name of the with argument to deprecate, not including --enable- 3651 # $2: The name of the argument to deprecate, in shell variable style (i.e. with _ instead of -) 3652 # $3: Messages to user. 3653 3654 3655 3656 3657 # Test that variable $1 denoting a program is not empty. If empty, exit with an error. 3658 # $1: variable to check 3659 3660 3661 # Check that there are no unprocessed overridden variables left. 3662 # If so, they are an incorrect argument and we will exit with an error. 3663 3664 3665 # Setup a tool for the given variable. If correctly specified by the user, 3666 # use that value, otherwise search for the tool using the supplied code snippet. 3667 # $1: variable to set 3668 # $2: code snippet to call to look for the tool 3669 # $3: code snippet to call if variable was used to find tool 3670 3671 3672 # Call BASIC_SETUP_TOOL with AC_PATH_PROGS to locate the tool 3673 # $1: variable to set 3674 # $2: executable name (or list of names) to look for 3675 # $3: [path] 3676 3677 3678 # Call BASIC_SETUP_TOOL with AC_CHECK_TOOLS to locate the tool 3679 # $1: variable to set 3680 # $2: executable name (or list of names) to look for 3681 3682 3683 # Like BASIC_PATH_PROGS but fails if no tool was found. 3684 # $1: variable to set 3685 # $2: executable name (or list of names) to look for 3686 # $3: [path] 3687 3688 3689 # Like BASIC_SETUP_TOOL but fails if no tool was found. 3690 # $1: variable to set 3691 # $2: autoconf macro to call to look for the special tool 3692 3693 3694 # Setup the most fundamental tools that relies on not much else to set up, 3695 # but is used by much of the early bootstrap code. 3696 3697 3698 # Setup basic configuration paths, and platform-specific stuff related to PATHs. 3699 3700 3701 # Evaluates platform specific overrides for devkit variables. 3702 # $1: Name of variable 3703 3704 3705 3706 3707 3708 3709 #%%% Simple tools %%% 3710 3711 # Check if we have found a usable version of make 3712 # $1: the path to a potential make binary (or empty) 3713 # $2: the description on how we found this 3714 3715 3716 3717 3718 # Goes looking for a usable version of GNU make. 3719 3720 3721 3722 3723 3724 3725 3726 3727 3728 3729 # Check if build directory is on local disk. If not possible to determine, 3730 # we prefer to claim it's local. 3731 # Argument 1: directory to test 3732 # Argument 2: what to do if it is on local disk 3733 # Argument 3: what to do otherwise (remote disk or failure) 3734 3735 3736 # Check that source files have basic read permissions set. This might 3737 # not be the case in cygwin in certain conditions. 3738 3739 3740 3741 3742 # Check for support for specific options in bash 3743 3744 3745 ################################################################################ 3746 # 3747 # Default make target 3748 # 3749 3750 3751 # Code to run after AC_OUTPUT 3752 3753 3754 # 3755 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 3756 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3757 # 3758 # This code is free software; you can redistribute it and/or modify it 3759 # under the terms of the GNU General Public License version 2 only, as 3760 # published by the Free Software Foundation. Oracle designates this 3761 # particular file as subject to the "Classpath" exception as provided 3762 # by Oracle in the LICENSE file that accompanied this code. 3763 # 3764 # This code is distributed in the hope that it will be useful, but WITHOUT 3765 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3766 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3767 # version 2 for more details (a copy is included in the LICENSE file that 3768 # accompanied this code). 3769 # 3770 # You should have received a copy of the GNU General Public License version 3771 # 2 along with this work; if not, write to the Free Software Foundation, 3772 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3773 # 3774 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3775 # or visit www.oracle.com if you need additional information or have any 3776 # questions. 3777 # 3778 3779 3780 3781 3782 3783 # Helper function which possibly converts a path using DOS-style short mode. 3784 # If so, the updated path is stored in $new_path. 3785 # $1: The path to check 3786 3787 3788 # Helper function which possibly converts a path using DOS-style short mode. 3789 # If so, the updated path is stored in $new_path. 3790 # $1: The path to check 3791 3792 3793 # FIXME: The BASIC_FIXUP_*_CYGWIN/MSYS is most likely too convoluted 3794 # and could probably be heavily simplified. However, all changes in this 3795 # area tend to need lot of testing in different scenarios, and in lack of 3796 # proper unit testing, cleaning this up has not been deemed worth the effort 3797 # at the moment. 3798 3799 3800 3801 3802 3803 3804 3805 3806 3807 # Setup basic configuration paths, and platform-specific stuff related to PATHs. 3808 3809 3810 3811 3812 # ... then the rest 3813 # 3814 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 3815 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3816 # 3817 # This code is free software; you can redistribute it and/or modify it 3818 # under the terms of the GNU General Public License version 2 only, as 3819 # published by the Free Software Foundation. Oracle designates this 3820 # particular file as subject to the "Classpath" exception as provided 3821 # by Oracle in the LICENSE file that accompanied this code. 3822 # 3823 # This code is distributed in the hope that it will be useful, but WITHOUT 3824 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3825 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3826 # version 2 for more details (a copy is included in the LICENSE file that 3827 # accompanied this code). 3828 # 3829 # You should have received a copy of the GNU General Public License version 3830 # 2 along with this work; if not, write to the Free Software Foundation, 3831 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3832 # 3833 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3834 # or visit www.oracle.com if you need additional information or have any 3835 # questions. 3836 # 3837 3838 ######################################################################## 3839 # This file handles detection of the Boot JDK. The Boot JDK detection 3840 # process has been developed as a response to solve a complex real-world 3841 # problem. Initially, it was simple, but it has grown as platform after 3842 # platform, idiosyncracy after idiosyncracy has been supported. 3843 # 3844 # The basic idea is this: 3845 # 1) You need an acceptable *) JDK to use as a Boot JDK 3846 # 2) There are several ways to locate a JDK, that are mostly platform 3847 # dependent **) 3848 # 3) You can have multiple JDKs installed 3849 # 4) If possible, configure should try to dig out an acceptable JDK 3850 # automatically, without having to resort to command-line options 3851 # 3852 # *) acceptable means e.g. JDK7 for building JDK8, a complete JDK (with 3853 # javac) and not a JRE, etc. 3854 # 3855 # **) On Windows we typically use a well-known path. 3856 # On MacOSX we typically use the tool java_home. 3857 # On Linux we typically find javac in the $PATH, and then follow a 3858 # chain of symlinks that often ends up in a real JDK. 3859 # 3860 # This leads to the code where we check in different ways to locate a 3861 # JDK, and if one is found, check if it is acceptable. If not, we print 3862 # our reasons for rejecting it (useful when debugging non-working 3863 # configure situations) and continue checking the next one. 3864 ######################################################################## 3865 3866 # Execute the check given as argument, and verify the result 3867 # If the Boot JDK was previously found, do nothing 3868 # $1 A command line (typically autoconf macro) to execute 3869 3870 3871 # Test: Is bootjdk explicitly set by command line arguments? 3872 3873 3874 # Test: Is $JAVA_HOME set? 3875 3876 3877 # Test: Is there a java or javac in the PATH, which is a symlink to the JDK? 3878 3879 3880 # Test: Is there a /usr/libexec/java_home? (Typically on MacOSX) 3881 # $1: Argument to the java_home binary (optional) 3882 3883 3884 # Test: On MacOS X, can we find a boot jdk using /usr/libexec/java_home? 3885 3886 3887 # Look for a jdk in the given path. If there are multiple, try to select the newest. 3888 # If found, set BOOT_JDK and BOOT_JDK_FOUND. 3889 # $1 = Path to directory containing jdk installations. 3890 # $2 = String to append to the found JDK directory to get the proper JDK home 3891 3892 3893 # Call BOOTJDK_FIND_BEST_JDK_IN_DIRECTORY, but use the given 3894 # environmental variable as base for where to look. 3895 # $1 Name of an environmal variable, assumed to point to the Program Files directory. 3896 3897 3898 # Test: Is there a JDK installed in default, well-known locations? 3899 3900 3901 # Check that a command-line tool in the Boot JDK is correct 3902 # $1 = name of variable to assign 3903 # $2 = name of binary 3904 3905 3906 ############################################################################### 3907 # 3908 # We need a Boot JDK to bootstrap the build. 3909 # 3910 3911 3912 3913 3914 3915 # BUILD_JDK: the location of the latest JDK that can run 3916 # on the host system and supports the target class file version 3917 # generated in this JDK build. This variable should only be 3918 # used after the launchers are built. 3919 # 3920 3921 # Execute the check given as argument, and verify the result. 3922 # If the JDK was previously found, do nothing. 3923 # $1 A command line (typically autoconf macro) to execute 3924 3925 3926 # By default the BUILD_JDK is the JDK_OUTPUTDIR. If the target architecture 3927 # is different than the host system doing the build (e.g. cross-compilation), 3928 # a special BUILD_JDK is built as part of the build process. An external 3929 # prebuilt BUILD_JDK can also be supplied. 3930 3931 3932 # 3933 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 3934 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3935 # 3936 # This code is free software; you can redistribute it and/or modify it 3937 # under the terms of the GNU General Public License version 2 only, as 3938 # published by the Free Software Foundation. Oracle designates this 3939 # particular file as subject to the "Classpath" exception as provided 3940 # by Oracle in the LICENSE file that accompanied this code. 3941 # 3942 # This code is distributed in the hope that it will be useful, but WITHOUT 3943 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3944 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3945 # version 2 for more details (a copy is included in the LICENSE file that 3946 # accompanied this code). 3947 # 3948 # You should have received a copy of the GNU General Public License version 3949 # 2 along with this work; if not, write to the Free Software Foundation, 3950 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3951 # 3952 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3953 # or visit www.oracle.com if you need additional information or have any 3954 # questions. 3955 # 3956 3957 3958 3959 3960 3961 3962 3963 3964 3965 3966 3967 3968 3969 3970 3971 3972 3973 ################################################################################ 3974 # 3975 # Runs icecc-create-env once and prints the error if it fails 3976 # 3977 # $1: arguments to icecc-create-env 3978 # $2: log file 3979 # 3980 3981 3982 ################################################################################ 3983 # 3984 # Optionally enable distributed compilation of native code using icecc/icecream 3985 # 3986 3987 3988 3989 3990 3991 3992 3993 # 3994 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 3995 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3996 # 3997 # This code is free software; you can redistribute it and/or modify it 3998 # under the terms of the GNU General Public License version 2 only, as 3999 # published by the Free Software Foundation. Oracle designates this 4000 # particular file as subject to the "Classpath" exception as provided 4001 # by Oracle in the LICENSE file that accompanied this code. 4002 # 4003 # This code is distributed in the hope that it will be useful, but WITHOUT 4004 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4005 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4006 # version 2 for more details (a copy is included in the LICENSE file that 4007 # accompanied this code). 4008 # 4009 # You should have received a copy of the GNU General Public License version 4010 # 2 along with this work; if not, write to the Free Software Foundation, 4011 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4012 # 4013 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4014 # or visit www.oracle.com if you need additional information or have any 4015 # questions. 4016 # 4017 4018 ################################################################################ 4019 # 4020 # Setup ABI profile (for arm) 4021 # 4022 4023 4024 # Reset the global CFLAGS/LDFLAGS variables and initialize them with the 4025 # corresponding configure arguments instead 4026 4027 4028 # Setup the sysroot flags and add them to global CFLAGS and LDFLAGS so 4029 # that configure can use them while detecting compilers. 4030 # TOOLCHAIN_TYPE is available here. 4031 # Param 1 - Optional prefix to all variables. (e.g BUILD_) 4032 4033 4034 4035 4036 4037 4038 # Documentation on common flags used for solstudio in HIGHEST. 4039 # 4040 # WARNING: Use of OPTIMIZATION_LEVEL=HIGHEST in your Makefile needs to be 4041 # done with care, there are some assumptions below that need to 4042 # be understood about the use of pointers, and IEEE behavior. 4043 # 4044 # -fns: Use non-standard floating point mode (not IEEE 754) 4045 # -fsimple: Do some simplification of floating point arithmetic (not IEEE 754) 4046 # -fsingle: Use single precision floating point with 'float' 4047 # -xalias_level=basic: Assume memory references via basic pointer types do not alias 4048 # (Source with excessing pointer casting and data access with mixed 4049 # pointer types are not recommended) 4050 # -xbuiltin=%all: Use intrinsic or inline versions for math/std functions 4051 # (If you expect perfect errno behavior, do not use this) 4052 # -xdepend: Loop data dependency optimizations (need -xO3 or higher) 4053 # -xrestrict: Pointer parameters to functions do not overlap 4054 # (Similar to -xalias_level=basic usage, but less obvious sometimes. 4055 # If you pass in multiple pointers to the same data, do not use this) 4056 # -xlibmil: Inline some library routines 4057 # (If you expect perfect errno behavior, do not use this) 4058 # -xlibmopt: Use optimized math routines (CURRENTLY DISABLED) 4059 # (If you expect perfect errno behavior, do not use this) 4060 # Can cause undefined external on Solaris 8 X86 on __sincos, removing for now 4061 4062 # FIXME: this will never happen since sparc != sparcv9, ie 32 bit, which we don't build anymore. 4063 # Bug? 4064 #if test "x$OPENJDK_TARGET_CPU" = xsparc; then 4065 # CFLAGS_JDK="${CFLAGS_JDK} -xmemalign=4s" 4066 # CXXFLAGS_JDK="${CXXFLAGS_JDK} -xmemalign=4s" 4067 #fi 4068 4069 4070 4071 4072 4073 4074 ################################################################################ 4075 # $1 - Either BUILD or TARGET to pick the correct OS/CPU variables to check 4076 # conditionals against. 4077 # $2 - Optional prefix for each variable defined. 4078 4079 4080 # FLAGS_C_COMPILER_CHECK_ARGUMENTS(ARGUMENT: [ARGUMENT], IF_TRUE: [RUN-IF-TRUE], 4081 # IF_FALSE: [RUN-IF-FALSE]) 4082 # ------------------------------------------------------------ 4083 # Check that the C compiler supports an argument 4084 4085 4086 4087 4088 # FLAGS_CXX_COMPILER_CHECK_ARGUMENTS(ARGUMENT: [ARGUMENT], IF_TRUE: [RUN-IF-TRUE], 4089 # IF_FALSE: [RUN-IF-FALSE]) 4090 # ------------------------------------------------------------ 4091 # Check that the C++ compiler supports an argument 4092 4093 4094 4095 4096 # FLAGS_COMPILER_CHECK_ARGUMENTS(ARGUMENT: [ARGUMENT], IF_TRUE: [RUN-IF-TRUE], 4097 # IF_FALSE: [RUN-IF-FALSE]) 4098 # ------------------------------------------------------------ 4099 # Check that the C and C++ compilers support an argument 4100 4101 4102 4103 4104 # FLAGS_LINKER_CHECK_ARGUMENTS(ARGUMENT: [ARGUMENT], IF_TRUE: [RUN-IF-TRUE], 4105 # IF_FALSE: [RUN-IF-FALSE]) 4106 # ------------------------------------------------------------ 4107 # Check that the linker support an argument 4108 4109 4110 4111 4112 4113 4114 # FLAGS_SETUP_GCC6_COMPILER_FLAGS([PREFIX]) 4115 # Arguments: 4116 # $1 - Optional prefix for each variable defined. 4117 4118 4119 # 4120 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 4121 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4122 # 4123 # This code is free software; you can redistribute it and/or modify it 4124 # under the terms of the GNU General Public License version 2 only, as 4125 # published by the Free Software Foundation. Oracle designates this 4126 # particular file as subject to the "Classpath" exception as provided 4127 # by Oracle in the LICENSE file that accompanied this code. 4128 # 4129 # This code is distributed in the hope that it will be useful, but WITHOUT 4130 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4131 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4132 # version 2 for more details (a copy is included in the LICENSE file that 4133 # accompanied this code). 4134 # 4135 # You should have received a copy of the GNU General Public License version 4136 # 2 along with this work; if not, write to the Free Software Foundation, 4137 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4138 # 4139 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4140 # or visit www.oracle.com if you need additional information or have any 4141 # questions. 4142 # 4143 4144 4145 4146 4147 4148 cygwin_help() { 4149 case $1 in 4150 unzip) 4151 PKGHANDLER_COMMAND="( cd <location of cygwin setup.exe> && cmd /c setup -q -P unzip )" 4152 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 4153 ;; 4154 zip) 4155 PKGHANDLER_COMMAND="( cd <location of cygwin setup.exe> && cmd /c setup -q -P zip )" 4156 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 4157 ;; 4158 make) 4159 PKGHANDLER_COMMAND="( cd <location of cygwin setup.exe> && cmd /c setup -q -P make )" 4160 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 4161 ;; 4162 freetype) 4163 HELP_MSG=" 4164 The freetype library can now be build during the configure process. 4165 Download the freetype sources and unpack them into an arbitrary directory: 4166 4167 wget http://download.savannah.gnu.org/releases/freetype/freetype-2.5.3.tar.gz 4168 tar -xzf freetype-2.5.3.tar.gz 4169 4170 Then run configure with '--with-freetype-src=<freetype_src>'. This will 4171 automatically build the freetype library into '<freetype_src>/lib64' for 64-bit 4172 builds or into '<freetype_src>/lib32' for 32-bit builds. 4173 Afterwards you can always use '--with-freetype-include=<freetype_src>/include' 4174 and '--with-freetype-lib=<freetype_src>/lib32|64' for other builds. 4175 4176 Alternatively you can unpack the sources like this to use the default directory: 4177 4178 tar --one-top-level=$HOME/freetype --strip-components=1 -xzf freetype-2.5.3.tar.gz" 4179 ;; 4180 esac 4181 } 4182 4183 msys_help() { 4184 PKGHANDLER_COMMAND="" 4185 } 4186 4187 apt_help() { 4188 case $1 in 4189 reduced) 4190 PKGHANDLER_COMMAND="sudo apt-get install gcc-multilib g++-multilib" ;; 4191 devkit) 4192 PKGHANDLER_COMMAND="sudo apt-get install build-essential" ;; 4193 openjdk) 4194 PKGHANDLER_COMMAND="sudo apt-get install openjdk-8-jdk" ;; 4195 alsa) 4196 PKGHANDLER_COMMAND="sudo apt-get install libasound2-dev" ;; 4197 cups) 4198 PKGHANDLER_COMMAND="sudo apt-get install libcups2-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 elf) 4210 PKGHANDLER_COMMAND="sudo apt-get install libelf-dev" ;; 4211 esac 4212 } 4213 4214 yum_help() { 4215 case $1 in 4216 devkit) 4217 PKGHANDLER_COMMAND="sudo yum groupinstall \"Development Tools\"" ;; 4218 openjdk) 4219 PKGHANDLER_COMMAND="sudo yum install java-1.8.0-openjdk-devel" ;; 4220 alsa) 4221 PKGHANDLER_COMMAND="sudo yum install alsa-lib-devel" ;; 4222 cups) 4223 PKGHANDLER_COMMAND="sudo yum install cups-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 elf) 4231 PKGHANDLER_COMMAND="sudo yum install elfutils-libelf-devel" ;; 4232 esac 4233 } 4234 4235 brew_help() { 4236 case $1 in 4237 openjdk) 4238 PKGHANDLER_COMMAND="brew cask install java" ;; 4239 freetype) 4240 PKGHANDLER_COMMAND="brew install freetype" ;; 4241 ccache) 4242 PKGHANDLER_COMMAND="brew install ccache" ;; 4243 esac 4244 } 4245 4246 port_help() { 4247 PKGHANDLER_COMMAND="" 4248 } 4249 4250 pkgutil_help() { 4251 PKGHANDLER_COMMAND="" 4252 } 4253 4254 pkgadd_help() { 4255 PKGHANDLER_COMMAND="" 4256 } 4257 4258 # This function will check if we're called from the "configure" wrapper while 4259 # printing --help. If so, we will print out additional information that can 4260 # only be extracted within the autoconf script, and then exit. This must be 4261 # called at the very beginning in configure.ac. 4262 4263 4264 4265 4266 4267 4268 # 4269 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 4270 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4271 # 4272 # This code is free software; you can redistribute it and/or modify it 4273 # under the terms of the GNU General Public License version 2 only, as 4274 # published by the Free Software Foundation. Oracle designates this 4275 # particular file as subject to the "Classpath" exception as provided 4276 # by Oracle in the LICENSE file that accompanied this code. 4277 # 4278 # This code is distributed in the hope that it will be useful, but WITHOUT 4279 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4280 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4281 # version 2 for more details (a copy is included in the LICENSE file that 4282 # accompanied this code). 4283 # 4284 # You should have received a copy of the GNU General Public License version 4285 # 2 along with this work; if not, write to the Free Software Foundation, 4286 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4287 # 4288 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4289 # or visit www.oracle.com if you need additional information or have any 4290 # questions. 4291 # 4292 4293 # All valid JVM features, regardless of platform 4294 VALID_JVM_FEATURES="compiler1 compiler2 zero shark minimal dtrace jvmti jvmci \ 4295 graal fprof vm-structs jni-check services management all-gcs nmt cds \ 4296 static-build link-time-opt aot" 4297 4298 # All valid JVM variants 4299 VALID_JVM_VARIANTS="server client minimal core zero zeroshark custom" 4300 4301 ############################################################################### 4302 # Check if the specified JVM variant should be built. To be used in shell if 4303 # constructs, like this: 4304 # if HOTSPOT_CHECK_JVM_VARIANT(server); then 4305 # 4306 # Only valid to use after HOTSPOT_SETUP_JVM_VARIANTS has setup variants. 4307 4308 # Definition kept in one line to allow inlining in if statements. 4309 # Additional [] needed to keep m4 from mangling shell constructs. 4310 4311 4312 ############################################################################### 4313 # Check if the specified JVM features are explicitly enabled. To be used in 4314 # shell if constructs, like this: 4315 # if HOTSPOT_CHECK_JVM_FEATURE(jvmti); then 4316 # 4317 # Only valid to use after HOTSPOT_SETUP_JVM_FEATURES has setup features. 4318 4319 # Definition kept in one line to allow inlining in if statements. 4320 # Additional [] needed to keep m4 from mangling shell constructs. 4321 4322 4323 ############################################################################### 4324 # Check which variants of the JVM that we want to build. Available variants are: 4325 # server: normal interpreter, and a tiered C1/C2 compiler 4326 # client: normal interpreter, and C1 (no C2 compiler) 4327 # minimal: reduced form of client with optional features stripped out 4328 # core: normal interpreter only, no compiler 4329 # zero: C++ based interpreter only, no compiler 4330 # zeroshark: C++ based interpreter, and a llvm-based compiler 4331 # custom: baseline JVM with no default features 4332 # 4333 4334 4335 ############################################################################### 4336 # Check if dtrace should be enabled and has all prerequisites present. 4337 # 4338 4339 4340 ################################################################################ 4341 # Check if AOT should be enabled 4342 # 4343 4344 4345 ############################################################################### 4346 # Set up all JVM features for each JVM variant. 4347 # 4348 4349 4350 ############################################################################### 4351 # Validate JVM features once all setup is complete, including custom setup. 4352 # 4353 4354 4355 ################################################################################ 4356 # 4357 # Specify which sources will be used to build the 64-bit ARM port 4358 # 4359 # --with-cpu-port=arm64 will use hotspot/src/cpu/arm 4360 # --with-cpu-port=aarch64 will use hotspot/src/cpu/aarch64 4361 # 4362 4363 4364 4365 ################################################################################ 4366 # Check if gtest should be built 4367 # 4368 4369 4370 # 4371 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 4372 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4373 # 4374 # This code is free software; you can redistribute it and/or modify it 4375 # under the terms of the GNU General Public License version 2 only, as 4376 # published by the Free Software Foundation. Oracle designates this 4377 # particular file as subject to the "Classpath" exception as provided 4378 # by Oracle in the LICENSE file that accompanied this code. 4379 # 4380 # This code is distributed in the hope that it will be useful, but WITHOUT 4381 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4382 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4383 # version 2 for more details (a copy is included in the LICENSE file that 4384 # accompanied this code). 4385 # 4386 # You should have received a copy of the GNU General Public License version 4387 # 2 along with this work; if not, write to the Free Software Foundation, 4388 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4389 # 4390 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4391 # or visit www.oracle.com if you need additional information or have any 4392 # questions. 4393 # 4394 4395 ############################################################################### 4396 # Check which variant of the JDK that we want to build. 4397 # Currently we have: 4398 # normal: standard edition 4399 # but the custom make system may add other variants 4400 # 4401 # Effectively the JDK variant gives a name to a specific set of 4402 # modules to compile into the JDK. 4403 4404 4405 ############################################################################### 4406 # Set the debug level 4407 # release: no debug information, all optimizations, no asserts. 4408 # optimized: no debug information, all optimizations, no asserts, HotSpot target is 'optimized'. 4409 # fastdebug: debug information (-g), all optimizations, all asserts 4410 # slowdebug: debug information (-g), no optimizations, all asserts 4411 4412 4413 ############################################################################### 4414 # 4415 # Should we build only OpenJDK even if closed sources are present? 4416 # 4417 4418 4419 4420 4421 ############################################################################### 4422 # 4423 # Enable or disable the elliptic curve crypto implementation 4424 # 4425 4426 4427 4428 4429 ################################################################################ 4430 # 4431 # Gcov coverage data for hotspot 4432 # 4433 4434 4435 ################################################################################ 4436 # 4437 # Static build support. When enabled will generate static 4438 # libraries instead of shared libraries for all JDK libs. 4439 # 4440 4441 4442 ################################################################################ 4443 # 4444 # jlink options. 4445 # We always keep packaged modules in JDK image. 4446 # 4447 4448 4449 ################################################################################ 4450 # 4451 # Check if building of the jtreg failure handler should be enabled. 4452 # 4453 4454 4455 ################################################################################ 4456 # 4457 # Enable or disable generation of the classlist at build time 4458 # 4459 4460 4461 # 4462 # Copyright (c) 2015, 2016, Oracle and/or its affiliates. All rights reserved. 4463 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4464 # 4465 # This code is free software; you can redistribute it and/or modify it 4466 # under the terms of the GNU General Public License version 2 only, as 4467 # published by the Free Software Foundation. Oracle designates this 4468 # particular file as subject to the "Classpath" exception as provided 4469 # by Oracle in the LICENSE file that accompanied this code. 4470 # 4471 # This code is distributed in the hope that it will be useful, but WITHOUT 4472 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4473 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4474 # version 2 for more details (a copy is included in the LICENSE file that 4475 # accompanied this code). 4476 # 4477 # You should have received a copy of the GNU General Public License version 4478 # 2 along with this work; if not, write to the Free Software Foundation, 4479 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4480 # 4481 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4482 # or visit www.oracle.com if you need additional information or have any 4483 # questions. 4484 # 4485 4486 ############################################################################### 4487 # 4488 # Setup version numbers 4489 # 4490 4491 # Verify that a given string represents a valid version number, and assign it 4492 # to a variable. 4493 4494 # Argument 1: the variable to assign to 4495 # Argument 2: the value given by the user 4496 4497 4498 4499 4500 # 4501 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 4502 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4503 # 4504 # This code is free software; you can redistribute it and/or modify it 4505 # under the terms of the GNU General Public License version 2 only, as 4506 # published by the Free Software Foundation. Oracle designates this 4507 # particular file as subject to the "Classpath" exception as provided 4508 # by Oracle in the LICENSE file that accompanied this code. 4509 # 4510 # This code is distributed in the hope that it will be useful, but WITHOUT 4511 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4512 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4513 # version 2 for more details (a copy is included in the LICENSE file that 4514 # accompanied this code). 4515 # 4516 # You should have received a copy of the GNU General Public License version 4517 # 2 along with this work; if not, write to the Free Software Foundation, 4518 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4519 # 4520 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4521 # or visit www.oracle.com if you need additional information or have any 4522 # questions. 4523 # 4524 4525 # Major library component reside in separate files. 4526 # 4527 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. 4528 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4529 # 4530 # This code is free software; you can redistribute it and/or modify it 4531 # under the terms of the GNU General Public License version 2 only, as 4532 # published by the Free Software Foundation. Oracle designates this 4533 # particular file as subject to the "Classpath" exception as provided 4534 # by Oracle in the LICENSE file that accompanied this code. 4535 # 4536 # This code is distributed in the hope that it will be useful, but WITHOUT 4537 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4538 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4539 # version 2 for more details (a copy is included in the LICENSE file that 4540 # accompanied this code). 4541 # 4542 # You should have received a copy of the GNU General Public License version 4543 # 2 along with this work; if not, write to the Free Software Foundation, 4544 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4545 # 4546 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4547 # or visit www.oracle.com if you need additional information or have any 4548 # questions. 4549 # 4550 4551 ################################################################################ 4552 # Setup alsa (Advanced Linux Sound Architecture) 4553 ################################################################################ 4554 4555 4556 # 4557 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 4558 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4559 # 4560 # This code is free software; you can redistribute it and/or modify it 4561 # under the terms of the GNU General Public License version 2 only, as 4562 # published by the Free Software Foundation. Oracle designates this 4563 # particular file as subject to the "Classpath" exception as provided 4564 # by Oracle in the LICENSE file that accompanied this code. 4565 # 4566 # This code is distributed in the hope that it will be useful, but WITHOUT 4567 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4568 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4569 # version 2 for more details (a copy is included in the LICENSE file that 4570 # accompanied this code). 4571 # 4572 # You should have received a copy of the GNU General Public License version 4573 # 2 along with this work; if not, write to the Free Software Foundation, 4574 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4575 # 4576 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4577 # or visit www.oracle.com if you need additional information or have any 4578 # questions. 4579 # 4580 4581 ################################################################################ 4582 # Setup bundled libraries. 4583 # 4584 # For libjpeg, giflib, libpng, lcms2 and zlib, the source is present in the 4585 # OpenJDK repository. Default is to use these libraries as bundled, but they 4586 # might be replaced by en external version by the user. 4587 ################################################################################ 4588 4589 4590 ################################################################################ 4591 # Setup libjpeg 4592 ################################################################################ 4593 4594 4595 ################################################################################ 4596 # Setup giflib 4597 ################################################################################ 4598 4599 4600 ################################################################################ 4601 # Setup libpng 4602 ################################################################################ 4603 4604 4605 ################################################################################ 4606 # Setup zlib 4607 ################################################################################ 4608 4609 4610 ################################################################################ 4611 # Setup lcms (Little CMS) 4612 ################################################################################ 4613 4614 4615 # 4616 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 4617 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4618 # 4619 # This code is free software; you can redistribute it and/or modify it 4620 # under the terms of the GNU General Public License version 2 only, as 4621 # published by the Free Software Foundation. Oracle designates this 4622 # particular file as subject to the "Classpath" exception as provided 4623 # by Oracle in the LICENSE file that accompanied this code. 4624 # 4625 # This code is distributed in the hope that it will be useful, but WITHOUT 4626 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4627 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4628 # version 2 for more details (a copy is included in the LICENSE file that 4629 # accompanied this code). 4630 # 4631 # You should have received a copy of the GNU General Public License version 4632 # 2 along with this work; if not, write to the Free Software Foundation, 4633 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4634 # 4635 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4636 # or visit www.oracle.com if you need additional information or have any 4637 # questions. 4638 # 4639 4640 ################################################################################ 4641 # Setup cups (Common Unix Printing System) 4642 ################################################################################ 4643 4644 4645 # 4646 # Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. 4647 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4648 # 4649 # This code is free software; you can redistribute it and/or modify it 4650 # under the terms of the GNU General Public License version 2 only, as 4651 # published by the Free Software Foundation. Oracle designates this 4652 # particular file as subject to the "Classpath" exception as provided 4653 # by Oracle in the LICENSE file that accompanied this code. 4654 # 4655 # This code is distributed in the hope that it will be useful, but WITHOUT 4656 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4657 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4658 # version 2 for more details (a copy is included in the LICENSE file that 4659 # accompanied this code). 4660 # 4661 # You should have received a copy of the GNU General Public License version 4662 # 2 along with this work; if not, write to the Free Software Foundation, 4663 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4664 # 4665 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4666 # or visit www.oracle.com if you need additional information or have any 4667 # questions. 4668 # 4669 4670 ################################################################################ 4671 # Setup libffi (Foreign Function Interface) 4672 ################################################################################ 4673 4674 4675 # 4676 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 4677 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4678 # 4679 # This code is free software; you can redistribute it and/or modify it 4680 # under the terms of the GNU General Public License version 2 only, as 4681 # published by the Free Software Foundation. Oracle designates this 4682 # particular file as subject to the "Classpath" exception as provided 4683 # by Oracle in the LICENSE file that accompanied this code. 4684 # 4685 # This code is distributed in the hope that it will be useful, but WITHOUT 4686 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4687 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4688 # version 2 for more details (a copy is included in the LICENSE file that 4689 # accompanied this code). 4690 # 4691 # You should have received a copy of the GNU General Public License version 4692 # 2 along with this work; if not, write to the Free Software Foundation, 4693 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4694 # 4695 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4696 # or visit www.oracle.com if you need additional information or have any 4697 # questions. 4698 # 4699 4700 ################################################################################ 4701 # Build the freetype lib from source 4702 ################################################################################ 4703 4704 4705 ################################################################################ 4706 # Check if a potential freeype library match is correct and usable 4707 ################################################################################ 4708 4709 4710 ################################################################################ 4711 # Setup freetype (The FreeType2 font rendering library) 4712 ################################################################################ 4713 4714 4715 # 4716 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 4717 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4718 # 4719 # This code is free software; you can redistribute it and/or modify it 4720 # under the terms of the GNU General Public License version 2 only, as 4721 # published by the Free Software Foundation. Oracle designates this 4722 # particular file as subject to the "Classpath" exception as provided 4723 # by Oracle in the LICENSE file that accompanied this code. 4724 # 4725 # This code is distributed in the hope that it will be useful, but WITHOUT 4726 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4727 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4728 # version 2 for more details (a copy is included in the LICENSE file that 4729 # accompanied this code). 4730 # 4731 # You should have received a copy of the GNU General Public License version 4732 # 2 along with this work; if not, write to the Free Software Foundation, 4733 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4734 # 4735 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4736 # or visit www.oracle.com if you need additional information or have any 4737 # questions. 4738 # 4739 4740 ################################################################################ 4741 # Setup the standard C/C++ runtime libraries. 4742 # 4743 # Most importantly, determine if stdc++ should be linked statically or 4744 # dynamically. 4745 ################################################################################ 4746 4747 4748 # 4749 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. 4750 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4751 # 4752 # This code is free software; you can redistribute it and/or modify it 4753 # under the terms of the GNU General Public License version 2 only, as 4754 # published by the Free Software Foundation. Oracle designates this 4755 # particular file as subject to the "Classpath" exception as provided 4756 # by Oracle in the LICENSE file that accompanied this code. 4757 # 4758 # This code is distributed in the hope that it will be useful, but WITHOUT 4759 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4760 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4761 # version 2 for more details (a copy is included in the LICENSE file that 4762 # accompanied this code). 4763 # 4764 # You should have received a copy of the GNU General Public License version 4765 # 2 along with this work; if not, write to the Free Software Foundation, 4766 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4767 # 4768 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4769 # or visit www.oracle.com if you need additional information or have any 4770 # questions. 4771 # 4772 4773 ################################################################################ 4774 # Setup X11 Windows system 4775 ################################################################################ 4776 4777 4778 # 4779 # Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. 4780 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4781 # 4782 # This code is free software; you can redistribute it and/or modify it 4783 # under the terms of the GNU General Public License version 2 only, as 4784 # published by the Free Software Foundation. Oracle designates this 4785 # particular file as subject to the "Classpath" exception as provided 4786 # by Oracle in the LICENSE file that accompanied this code. 4787 # 4788 # This code is distributed in the hope that it will be useful, but WITHOUT 4789 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4790 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4791 # version 2 for more details (a copy is included in the LICENSE file that 4792 # accompanied this code). 4793 # 4794 # You should have received a copy of the GNU General Public License version 4795 # 2 along with this work; if not, write to the Free Software Foundation, 4796 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4797 # 4798 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4799 # or visit www.oracle.com if you need additional information or have any 4800 # questions. 4801 # 4802 4803 ################################################################################ 4804 # Setup libelf (ELF library) 4805 ################################################################################ 4806 4807 4808 4809 ################################################################################ 4810 # Determine which libraries are needed for this configuration 4811 ################################################################################ 4812 4813 4814 ################################################################################ 4815 # Parse library options, and setup needed libraries 4816 ################################################################################ 4817 4818 4819 ################################################################################ 4820 # Setup llvm (Low-Level VM) 4821 ################################################################################ 4822 4823 4824 ################################################################################ 4825 # Setup various libraries, typically small system libraries 4826 ################################################################################ 4827 4828 4829 ################################################################################ 4830 # libstlport.so.1 is needed for running gtest on Solaris. Find it to 4831 # redistribute it in the test image. 4832 ################################################################################ 4833 4834 4835 4836 # 4837 # Copyright (c) 2011, 2017, Oracle and/or its affiliates. All rights reserved. 4838 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4839 # 4840 # This code is free software; you can redistribute it and/or modify it 4841 # under the terms of the GNU General Public License version 2 only, as 4842 # published by the Free Software Foundation. Oracle designates this 4843 # particular file as subject to the "Classpath" exception as provided 4844 # by Oracle in the LICENSE file that accompanied this code. 4845 # 4846 # This code is distributed in the hope that it will be useful, but WITHOUT 4847 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4848 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4849 # version 2 for more details (a copy is included in the LICENSE file that 4850 # accompanied this code). 4851 # 4852 # You should have received a copy of the GNU General Public License version 4853 # 2 along with this work; if not, write to the Free Software Foundation, 4854 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4855 # 4856 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4857 # or visit www.oracle.com if you need additional information or have any 4858 # questions. 4859 # 4860 4861 # Support macro for PLATFORM_EXTRACT_TARGET_AND_BUILD. 4862 # Converts autoconf style CPU name to OpenJDK style, into 4863 # VAR_CPU, VAR_CPU_ARCH, VAR_CPU_BITS and VAR_CPU_ENDIAN. 4864 4865 4866 # Support macro for PLATFORM_EXTRACT_TARGET_AND_BUILD. 4867 # Converts autoconf style OS name to OpenJDK style, into 4868 # VAR_OS, VAR_OS_TYPE and VAR_OS_ENV. 4869 4870 4871 # Expects $host_os $host_cpu $build_os and $build_cpu 4872 # and $with_target_bits to have been setup! 4873 # 4874 # Translate the standard triplet(quadruplet) definition 4875 # of the target/build system into OPENJDK_TARGET_OS, OPENJDK_TARGET_CPU, 4876 # OPENJDK_BUILD_OS, etc. 4877 4878 4879 # Check if a reduced build (32-bit on 64-bit platforms) is requested, and modify behaviour 4880 # accordingly. Must be done after setting up build and target system, but before 4881 # doing anything else with these values. 4882 4883 4884 # Setup the legacy variables, for controlling the old makefiles. 4885 # 4886 4887 4888 # $1 - Either TARGET or BUILD to setup the variables for. 4889 4890 4891 4892 4893 #%%% Build and target systems %%% 4894 4895 4896 4897 4898 # Support macro for PLATFORM_SETUP_OPENJDK_TARGET_BITS. 4899 # Add -mX to various FLAGS variables. 4900 4901 4902 4903 4904 4905 4906 # 4907 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 4908 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4909 # 4910 # This code is free software; you can redistribute it and/or modify it 4911 # under the terms of the GNU General Public License version 2 only, as 4912 # published by the Free Software Foundation. Oracle designates this 4913 # particular file as subject to the "Classpath" exception as provided 4914 # by Oracle in the LICENSE file that accompanied this code. 4915 # 4916 # This code is distributed in the hope that it will be useful, but WITHOUT 4917 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4918 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4919 # version 2 for more details (a copy is included in the LICENSE file that 4920 # accompanied this code). 4921 # 4922 # You should have received a copy of the GNU General Public License version 4923 # 2 along with this work; if not, write to the Free Software Foundation, 4924 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4925 # 4926 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4927 # or visit www.oracle.com if you need additional information or have any 4928 # questions. 4929 # 4930 4931 4932 4933 4934 4935 4936 4937 ################################################################################ 4938 # Define a mechanism for importing extra prebuilt modules 4939 # 4940 4941 4942 4943 # 4944 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 4945 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4946 # 4947 # This code is free software; you can redistribute it and/or modify it 4948 # under the terms of the GNU General Public License version 2 only, as 4949 # published by the Free Software Foundation. Oracle designates this 4950 # particular file as subject to the "Classpath" exception as provided 4951 # by Oracle in the LICENSE file that accompanied this code. 4952 # 4953 # This code is distributed in the hope that it will be useful, but WITHOUT 4954 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4955 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4956 # version 2 for more details (a copy is included in the LICENSE file that 4957 # accompanied this code). 4958 # 4959 # You should have received a copy of the GNU General Public License version 4960 # 2 along with this work; if not, write to the Free Software Foundation, 4961 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4962 # 4963 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4964 # or visit www.oracle.com if you need additional information or have any 4965 # questions. 4966 # 4967 4968 ######################################################################## 4969 # This file is responsible for detecting, verifying and setting up the 4970 # toolchain, i.e. the compiler, linker and related utilities. It will setup 4971 # proper paths to the binaries, but it will not setup any flags. 4972 # 4973 # The binaries used is determined by the toolchain type, which is the family of 4974 # compilers and related tools that are used. 4975 ######################################################################## 4976 4977 4978 # All valid toolchains, regardless of platform (used by help.m4) 4979 VALID_TOOLCHAINS_all="gcc clang solstudio xlc microsoft" 4980 4981 # These toolchains are valid on different platforms 4982 VALID_TOOLCHAINS_linux="gcc clang" 4983 VALID_TOOLCHAINS_solaris="solstudio" 4984 VALID_TOOLCHAINS_macosx="gcc clang" 4985 VALID_TOOLCHAINS_aix="xlc" 4986 VALID_TOOLCHAINS_windows="microsoft" 4987 4988 # Toolchain descriptions 4989 TOOLCHAIN_DESCRIPTION_clang="clang/LLVM" 4990 TOOLCHAIN_DESCRIPTION_gcc="GNU Compiler Collection" 4991 TOOLCHAIN_DESCRIPTION_microsoft="Microsoft Visual Studio" 4992 TOOLCHAIN_DESCRIPTION_solstudio="Oracle Solaris Studio" 4993 TOOLCHAIN_DESCRIPTION_xlc="IBM XL C/C++" 4994 4995 # Minimum supported versions, empty means unspecified 4996 TOOLCHAIN_MINIMUM_VERSION_clang="3.2" 4997 TOOLCHAIN_MINIMUM_VERSION_gcc="4.3" 4998 TOOLCHAIN_MINIMUM_VERSION_microsoft="16.00.30319.01" # VS2010 4999 TOOLCHAIN_MINIMUM_VERSION_solstudio="5.13" 5000 TOOLCHAIN_MINIMUM_VERSION_xlc="" 5001 5002 # Prepare the system so that TOOLCHAIN_CHECK_COMPILER_VERSION can be called. 5003 # Must have CC_VERSION_NUMBER and CXX_VERSION_NUMBER. 5004 # $1 - optional variable prefix for compiler and version variables (BUILD_) 5005 # $2 - optional variable prefix for comparable variable (OPENJDK_BUILD_) 5006 5007 5008 # Check if the configured compiler (C and C++) is of a specific version or 5009 # newer. TOOLCHAIN_PREPARE_FOR_VERSION_COMPARISONS must have been called before. 5010 # 5011 # Arguments: 5012 # VERSION: The version string to check against the found version 5013 # IF_AT_LEAST: block to run if the compiler is at least this version (>=) 5014 # IF_OLDER_THAN: block to run if the compiler is older than this version (<) 5015 # PREFIX: Optional variable prefix for compiler to compare version for (OPENJDK_BUILD_) 5016 5017 5018 5019 5020 # Setup a number of variables describing how native output files are 5021 # named on this platform/toolchain. 5022 5023 5024 # Determine which toolchain type to use, and make sure it is valid for this 5025 # platform. Setup various information about the selected toolchain. 5026 5027 5028 # Before we start detecting the toolchain executables, we might need some 5029 # special setup, e.g. additional paths etc. 5030 5031 5032 # Restore path, etc 5033 5034 5035 # Check if a compiler is of the toolchain type we expect, and save the version 5036 # information from it. If the compiler does not match the expected type, 5037 # this function will abort using AC_MSG_ERROR. If it matches, the version will 5038 # be stored in CC_VERSION_NUMBER/CXX_VERSION_NUMBER (as a dotted number), and 5039 # the full version string in CC_VERSION_STRING/CXX_VERSION_STRING. 5040 # 5041 # $1 = compiler to test (CC or CXX) 5042 # $2 = human readable name of compiler (C or C++) 5043 5044 5045 # Try to locate the given C or C++ compiler in the path, or otherwise. 5046 # 5047 # $1 = compiler to test (CC or CXX) 5048 # $2 = human readable name of compiler (C or C++) 5049 # $3 = compiler name to search for 5050 5051 5052 # Detect the core components of the toolchain, i.e. the compilers (CC and CXX), 5053 # preprocessor (CPP and CXXCPP), the linker (LD), the assembler (AS) and the 5054 # archiver (AR). Verify that the compilers are correct according to the 5055 # toolchain type. 5056 5057 5058 # Setup additional tools that is considered a part of the toolchain, but not the 5059 # core part. Many of these are highly platform-specific and do not exist, 5060 # and/or are not needed on all platforms. 5061 5062 5063 # Setup the build tools (i.e, the compiler and linker used to build programs 5064 # that should be run on the build platform, not the target platform, as a build 5065 # helper). Since the non-cross-compile case uses the normal, target compilers 5066 # for this, we can only do this after these have been setup. 5067 5068 5069 # Do some additional checks on the detected tools. 5070 5071 5072 # Setup the JTReg Regression Test Harness. 5073 5074 5075 # 5076 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. 5077 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 5078 # 5079 # This code is free software; you can redistribute it and/or modify it 5080 # under the terms of the GNU General Public License version 2 only, as 5081 # published by the Free Software Foundation. Oracle designates this 5082 # particular file as subject to the "Classpath" exception as provided 5083 # by Oracle in the LICENSE file that accompanied this code. 5084 # 5085 # This code is distributed in the hope that it will be useful, but WITHOUT 5086 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 5087 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 5088 # version 2 for more details (a copy is included in the LICENSE file that 5089 # accompanied this code). 5090 # 5091 # You should have received a copy of the GNU General Public License version 5092 # 2 along with this work; if not, write to the Free Software Foundation, 5093 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 5094 # 5095 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 5096 # or visit www.oracle.com if you need additional information or have any 5097 # questions. 5098 # 5099 5100 ################################################################################ 5101 # The order of these defines the priority by which we try to find them. 5102 VALID_VS_VERSIONS="2013 2012 2010" 5103 5104 VS_DESCRIPTION_2010="Microsoft Visual Studio 2010" 5105 VS_VERSION_INTERNAL_2010=100 5106 VS_MSVCR_2010=msvcr100.dll 5107 # We don't use msvcp on Visual Studio 2010 5108 #VS_MSVCP_2010=msvcp100.dll 5109 VS_ENVVAR_2010="VS100COMNTOOLS" 5110 VS_VS_INSTALLDIR_2010="Microsoft Visual Studio 10.0" 5111 VS_SDK_INSTALLDIR_2010="Microsoft SDKs/Windows/v7.1" 5112 VS_VS_PLATFORM_NAME_2010="v100" 5113 VS_SDK_PLATFORM_NAME_2010="Windows7.1SDK" 5114 5115 VS_DESCRIPTION_2012="Microsoft Visual Studio 2012" 5116 VS_VERSION_INTERNAL_2012=110 5117 VS_MSVCR_2012=msvcr110.dll 5118 VS_MSVCP_2012=msvcp110.dll 5119 VS_ENVVAR_2012="VS110COMNTOOLS" 5120 VS_VS_INSTALLDIR_2012="Microsoft Visual Studio 11.0" 5121 VS_SDK_INSTALLDIR_2012= 5122 VS_VS_PLATFORM_NAME_2012="v110" 5123 VS_SDK_PLATFORM_NAME_2012= 5124 5125 VS_DESCRIPTION_2013="Microsoft Visual Studio 2013" 5126 VS_VERSION_INTERNAL_2013=120 5127 VS_MSVCR_2013=msvcr120.dll 5128 VS_MSVCP_2013=msvcp120.dll 5129 VS_ENVVAR_2013="VS120COMNTOOLS" 5130 VS_VS_INSTALLDIR_2013="Microsoft Visual Studio 12.0" 5131 VS_SDK_INSTALLDIR_2013= 5132 VS_VS_PLATFORM_NAME_2013="v120" 5133 VS_SDK_PLATFORM_NAME_2013= 5134 5135 ################################################################################ 5136 5137 5138 5139 ################################################################################ 5140 5141 5142 5143 ################################################################################ 5144 # Finds the bat or cmd file in Visual Studio or the SDK that sets up a proper 5145 # build environment and assigns it to VS_ENV_CMD 5146 5147 5148 ################################################################################ 5149 5150 5151 5152 ################################################################################ 5153 # Check if the VS env variables were setup prior to running configure. 5154 # If not, then find vcvarsall.bat and run it automatically, and integrate 5155 # the set env variables into the spec file. 5156 5157 5158 5159 5160 5161 5162 5163 5164 5165 5166 5167 5168 5169 5170 # This line needs to be here, verbatim, after all includes and the dummy hook 5171 # definitions. It is replaced with custom functionality when building 5172 # custom sources. 5173 #CUSTOM_AUTOCONF_INCLUDE 5174 5175 # Do not change or remove the following line, it is needed for consistency checks: 5176 DATE_WHEN_GENERATED=1491256793 5177 5178 ############################################################################### 5179 # 5180 # Initialization / Boot-strapping 5181 # 5182 # The bootstrapping process needs to solve the "chicken or the egg" problem, 5183 # thus it jumps back and forth, each time gaining something needed later on. 5184 # 5185 ############################################################################### 5186 5187 # If we are requested to print additional help, do that and then exit. 5188 # This must be the very first call. 5189 5190 if test "x$CONFIGURE_PRINT_ADDITIONAL_HELP" != x; then 5191 5192 # Print available toolchains 5193 $PRINTF "The following toolchains are available as arguments to --with-toolchain-type.\n" 5194 $PRINTF "Which are valid to use depends on the build platform.\n" 5195 for toolchain in $VALID_TOOLCHAINS_all; do 5196 # Use indirect variable referencing 5197 toolchain_var_name=TOOLCHAIN_DESCRIPTION_$toolchain 5198 TOOLCHAIN_DESCRIPTION=${!toolchain_var_name} 5199 $PRINTF " %-10s %s\n" $toolchain "$TOOLCHAIN_DESCRIPTION" 5200 done 5201 $PRINTF "\n" 5202 5203 # Print available jvm features 5204 $PRINTF "The following JVM features are available as arguments to --with-jvm-features.\n" 5205 $PRINTF "Which are valid to use depends on the target platform.\n " 5206 $PRINTF "%s " $VALID_JVM_FEATURES 5207 $PRINTF "\n" 5208 5209 # And now exit directly 5210 exit 0 5211 fi 5212 5213 5214 # Basic initialization that must happen first of all in the normal process. 5215 5216 # Save the original command line. This is passed to us by the wrapper configure script. 5217 5218 # Save the path variable before it gets changed 5219 ORIGINAL_PATH="$PATH" 5220 5221 DATE_WHEN_CONFIGURED=`LANG=C date` 5222 5223 { $as_echo "$as_me:${as_lineno-$LINENO}: Configuration created at $DATE_WHEN_CONFIGURED." >&5 5224 $as_echo "$as_me: Configuration created at $DATE_WHEN_CONFIGURED." >&6;} 5225 { $as_echo "$as_me:${as_lineno-$LINENO}: configure script generated at timestamp $DATE_WHEN_GENERATED." >&5 5226 $as_echo "$as_me: configure script generated at timestamp $DATE_WHEN_GENERATED." >&6;} 5227 5228 5229 # Start with tools that do not need have cross compilation support 5230 # and can be expected to be found in the default PATH. These tools are 5231 # used by configure. 5232 5233 # First are all the simple required tools. 5234 5235 5236 5237 # Publish this variable in the help. 5238 5239 5240 if [ -z "${BASENAME+x}" ]; then 5241 # The variable is not set by user, try to locate tool using the code snippet 5242 for ac_prog in basename 5243 do 5244 # Extract the first word of "$ac_prog", so it can be a program name with args. 5245 set dummy $ac_prog; ac_word=$2 5246 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5247 $as_echo_n "checking for $ac_word... " >&6; } 5248 if ${ac_cv_path_BASENAME+:} false; then : 5249 $as_echo_n "(cached) " >&6 5250 else 5251 case $BASENAME in 5252 [\\/]* | ?:[\\/]*) 5253 ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path. 5254 ;; 5255 *) 5256 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5257 for as_dir in $PATH 5258 do 5259 IFS=$as_save_IFS 5260 test -z "$as_dir" && as_dir=. 5261 for ac_exec_ext in '' $ac_executable_extensions; do 5262 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5263 ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext" 5264 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5265 break 2 5266 fi 5267 done 5268 done 5269 IFS=$as_save_IFS 5270 5271 ;; 5272 esac 5273 fi 5274 BASENAME=$ac_cv_path_BASENAME 5275 if test -n "$BASENAME"; then 5276 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5 5277 $as_echo "$BASENAME" >&6; } 5278 else 5279 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5280 $as_echo "no" >&6; } 5281 fi 5282 5283 5284 test -n "$BASENAME" && break 5285 done 5286 5287 else 5288 # The variable is set, but is it from the command line or the environment? 5289 5290 # Try to remove the string !BASENAME! from our list. 5291 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BASENAME!/} 5292 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 5293 # If it failed, the variable was not from the command line. Ignore it, 5294 # but warn the user (except for BASH, which is always set by the calling BASH). 5295 if test "xBASENAME" != xBASH; then 5296 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BASENAME from the environment. Use command line variables instead." >&5 5297 $as_echo "$as_me: WARNING: Ignoring value of BASENAME from the environment. Use command line variables instead." >&2;} 5298 fi 5299 # Try to locate tool using the code snippet 5300 for ac_prog in basename 5301 do 5302 # Extract the first word of "$ac_prog", so it can be a program name with args. 5303 set dummy $ac_prog; ac_word=$2 5304 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5305 $as_echo_n "checking for $ac_word... " >&6; } 5306 if ${ac_cv_path_BASENAME+:} false; then : 5307 $as_echo_n "(cached) " >&6 5308 else 5309 case $BASENAME in 5310 [\\/]* | ?:[\\/]*) 5311 ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path. 5312 ;; 5313 *) 5314 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5315 for as_dir in $PATH 5316 do 5317 IFS=$as_save_IFS 5318 test -z "$as_dir" && as_dir=. 5319 for ac_exec_ext in '' $ac_executable_extensions; do 5320 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5321 ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext" 5322 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5323 break 2 5324 fi 5325 done 5326 done 5327 IFS=$as_save_IFS 5328 5329 ;; 5330 esac 5331 fi 5332 BASENAME=$ac_cv_path_BASENAME 5333 if test -n "$BASENAME"; then 5334 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5 5335 $as_echo "$BASENAME" >&6; } 5336 else 5337 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5338 $as_echo "no" >&6; } 5339 fi 5340 5341 5342 test -n "$BASENAME" && break 5343 done 5344 5345 else 5346 # If it succeeded, then it was overridden by the user. We will use it 5347 # for the tool. 5348 5349 # First remove it from the list of overridden variables, so we can test 5350 # for unknown variables in the end. 5351 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 5352 5353 # Check if we try to supply an empty value 5354 if test "x$BASENAME" = x; then 5355 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BASENAME= (no value)" >&5 5356 $as_echo "$as_me: Setting user supplied tool BASENAME= (no value)" >&6;} 5357 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASENAME" >&5 5358 $as_echo_n "checking for BASENAME... " >&6; } 5359 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 5360 $as_echo "disabled" >&6; } 5361 else 5362 # Check if the provided tool contains a complete path. 5363 tool_specified="$BASENAME" 5364 tool_basename="${tool_specified##*/}" 5365 if test "x$tool_basename" = "x$tool_specified"; then 5366 # A command without a complete path is provided, search $PATH. 5367 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BASENAME=$tool_basename" >&5 5368 $as_echo "$as_me: Will search for user supplied tool BASENAME=$tool_basename" >&6;} 5369 # Extract the first word of "$tool_basename", so it can be a program name with args. 5370 set dummy $tool_basename; ac_word=$2 5371 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5372 $as_echo_n "checking for $ac_word... " >&6; } 5373 if ${ac_cv_path_BASENAME+:} false; then : 5374 $as_echo_n "(cached) " >&6 5375 else 5376 case $BASENAME in 5377 [\\/]* | ?:[\\/]*) 5378 ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path. 5379 ;; 5380 *) 5381 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5382 for as_dir in $PATH 5383 do 5384 IFS=$as_save_IFS 5385 test -z "$as_dir" && as_dir=. 5386 for ac_exec_ext in '' $ac_executable_extensions; do 5387 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5388 ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext" 5389 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5390 break 2 5391 fi 5392 done 5393 done 5394 IFS=$as_save_IFS 5395 5396 ;; 5397 esac 5398 fi 5399 BASENAME=$ac_cv_path_BASENAME 5400 if test -n "$BASENAME"; then 5401 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5 5402 $as_echo "$BASENAME" >&6; } 5403 else 5404 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5405 $as_echo "no" >&6; } 5406 fi 5407 5408 5409 if test "x$BASENAME" = x; then 5410 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 5411 fi 5412 else 5413 # Otherwise we believe it is a complete path. Use it as it is. 5414 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BASENAME=$tool_specified" >&5 5415 $as_echo "$as_me: Will use user supplied tool BASENAME=$tool_specified" >&6;} 5416 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASENAME" >&5 5417 $as_echo_n "checking for BASENAME... " >&6; } 5418 if test ! -x "$tool_specified"; then 5419 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 5420 $as_echo "not found" >&6; } 5421 as_fn_error $? "User supplied tool BASENAME=$tool_specified does not exist or is not executable" "$LINENO" 5 5422 fi 5423 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 5424 $as_echo "$tool_specified" >&6; } 5425 fi 5426 fi 5427 fi 5428 5429 fi 5430 5431 5432 5433 if test "x$BASENAME" = x; then 5434 as_fn_error $? "Could not find required tool for BASENAME" "$LINENO" 5 5435 fi 5436 5437 5438 5439 5440 5441 # Publish this variable in the help. 5442 5443 5444 if [ -z "${BASH+x}" ]; then 5445 # The variable is not set by user, try to locate tool using the code snippet 5446 for ac_prog in bash 5447 do 5448 # Extract the first word of "$ac_prog", so it can be a program name with args. 5449 set dummy $ac_prog; ac_word=$2 5450 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5451 $as_echo_n "checking for $ac_word... " >&6; } 5452 if ${ac_cv_path_BASH+:} false; then : 5453 $as_echo_n "(cached) " >&6 5454 else 5455 case $BASH in 5456 [\\/]* | ?:[\\/]*) 5457 ac_cv_path_BASH="$BASH" # Let the user override the test with a path. 5458 ;; 5459 *) 5460 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5461 for as_dir in $PATH 5462 do 5463 IFS=$as_save_IFS 5464 test -z "$as_dir" && as_dir=. 5465 for ac_exec_ext in '' $ac_executable_extensions; do 5466 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5467 ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext" 5468 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5469 break 2 5470 fi 5471 done 5472 done 5473 IFS=$as_save_IFS 5474 5475 ;; 5476 esac 5477 fi 5478 BASH=$ac_cv_path_BASH 5479 if test -n "$BASH"; then 5480 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5 5481 $as_echo "$BASH" >&6; } 5482 else 5483 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5484 $as_echo "no" >&6; } 5485 fi 5486 5487 5488 test -n "$BASH" && break 5489 done 5490 5491 else 5492 # The variable is set, but is it from the command line or the environment? 5493 5494 # Try to remove the string !BASH! from our list. 5495 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BASH!/} 5496 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 5497 # If it failed, the variable was not from the command line. Ignore it, 5498 # but warn the user (except for BASH, which is always set by the calling BASH). 5499 if test "xBASH" != xBASH; then 5500 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BASH from the environment. Use command line variables instead." >&5 5501 $as_echo "$as_me: WARNING: Ignoring value of BASH from the environment. Use command line variables instead." >&2;} 5502 fi 5503 # Try to locate tool using the code snippet 5504 for ac_prog in bash 5505 do 5506 # Extract the first word of "$ac_prog", so it can be a program name with args. 5507 set dummy $ac_prog; ac_word=$2 5508 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5509 $as_echo_n "checking for $ac_word... " >&6; } 5510 if ${ac_cv_path_BASH+:} false; then : 5511 $as_echo_n "(cached) " >&6 5512 else 5513 case $BASH in 5514 [\\/]* | ?:[\\/]*) 5515 ac_cv_path_BASH="$BASH" # Let the user override the test with a path. 5516 ;; 5517 *) 5518 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5519 for as_dir in $PATH 5520 do 5521 IFS=$as_save_IFS 5522 test -z "$as_dir" && as_dir=. 5523 for ac_exec_ext in '' $ac_executable_extensions; do 5524 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5525 ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext" 5526 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5527 break 2 5528 fi 5529 done 5530 done 5531 IFS=$as_save_IFS 5532 5533 ;; 5534 esac 5535 fi 5536 BASH=$ac_cv_path_BASH 5537 if test -n "$BASH"; then 5538 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5 5539 $as_echo "$BASH" >&6; } 5540 else 5541 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5542 $as_echo "no" >&6; } 5543 fi 5544 5545 5546 test -n "$BASH" && break 5547 done 5548 5549 else 5550 # If it succeeded, then it was overridden by the user. We will use it 5551 # for the tool. 5552 5553 # First remove it from the list of overridden variables, so we can test 5554 # for unknown variables in the end. 5555 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 5556 5557 # Check if we try to supply an empty value 5558 if test "x$BASH" = x; then 5559 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BASH= (no value)" >&5 5560 $as_echo "$as_me: Setting user supplied tool BASH= (no value)" >&6;} 5561 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASH" >&5 5562 $as_echo_n "checking for BASH... " >&6; } 5563 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 5564 $as_echo "disabled" >&6; } 5565 else 5566 # Check if the provided tool contains a complete path. 5567 tool_specified="$BASH" 5568 tool_basename="${tool_specified##*/}" 5569 if test "x$tool_basename" = "x$tool_specified"; then 5570 # A command without a complete path is provided, search $PATH. 5571 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BASH=$tool_basename" >&5 5572 $as_echo "$as_me: Will search for user supplied tool BASH=$tool_basename" >&6;} 5573 # Extract the first word of "$tool_basename", so it can be a program name with args. 5574 set dummy $tool_basename; ac_word=$2 5575 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5576 $as_echo_n "checking for $ac_word... " >&6; } 5577 if ${ac_cv_path_BASH+:} false; then : 5578 $as_echo_n "(cached) " >&6 5579 else 5580 case $BASH in 5581 [\\/]* | ?:[\\/]*) 5582 ac_cv_path_BASH="$BASH" # Let the user override the test with a path. 5583 ;; 5584 *) 5585 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5586 for as_dir in $PATH 5587 do 5588 IFS=$as_save_IFS 5589 test -z "$as_dir" && as_dir=. 5590 for ac_exec_ext in '' $ac_executable_extensions; do 5591 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5592 ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext" 5593 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5594 break 2 5595 fi 5596 done 5597 done 5598 IFS=$as_save_IFS 5599 5600 ;; 5601 esac 5602 fi 5603 BASH=$ac_cv_path_BASH 5604 if test -n "$BASH"; then 5605 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5 5606 $as_echo "$BASH" >&6; } 5607 else 5608 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5609 $as_echo "no" >&6; } 5610 fi 5611 5612 5613 if test "x$BASH" = x; then 5614 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 5615 fi 5616 else 5617 # Otherwise we believe it is a complete path. Use it as it is. 5618 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BASH=$tool_specified" >&5 5619 $as_echo "$as_me: Will use user supplied tool BASH=$tool_specified" >&6;} 5620 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASH" >&5 5621 $as_echo_n "checking for BASH... " >&6; } 5622 if test ! -x "$tool_specified"; then 5623 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 5624 $as_echo "not found" >&6; } 5625 as_fn_error $? "User supplied tool BASH=$tool_specified does not exist or is not executable" "$LINENO" 5 5626 fi 5627 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 5628 $as_echo "$tool_specified" >&6; } 5629 fi 5630 fi 5631 fi 5632 5633 fi 5634 5635 5636 5637 if test "x$BASH" = x; then 5638 as_fn_error $? "Could not find required tool for BASH" "$LINENO" 5 5639 fi 5640 5641 5642 5643 5644 5645 # Publish this variable in the help. 5646 5647 5648 if [ -z "${CAT+x}" ]; then 5649 # The variable is not set by user, try to locate tool using the code snippet 5650 for ac_prog in cat 5651 do 5652 # Extract the first word of "$ac_prog", so it can be a program name with args. 5653 set dummy $ac_prog; ac_word=$2 5654 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5655 $as_echo_n "checking for $ac_word... " >&6; } 5656 if ${ac_cv_path_CAT+:} false; then : 5657 $as_echo_n "(cached) " >&6 5658 else 5659 case $CAT in 5660 [\\/]* | ?:[\\/]*) 5661 ac_cv_path_CAT="$CAT" # Let the user override the test with a path. 5662 ;; 5663 *) 5664 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5665 for as_dir in $PATH 5666 do 5667 IFS=$as_save_IFS 5668 test -z "$as_dir" && as_dir=. 5669 for ac_exec_ext in '' $ac_executable_extensions; do 5670 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5671 ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext" 5672 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5673 break 2 5674 fi 5675 done 5676 done 5677 IFS=$as_save_IFS 5678 5679 ;; 5680 esac 5681 fi 5682 CAT=$ac_cv_path_CAT 5683 if test -n "$CAT"; then 5684 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5 5685 $as_echo "$CAT" >&6; } 5686 else 5687 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5688 $as_echo "no" >&6; } 5689 fi 5690 5691 5692 test -n "$CAT" && break 5693 done 5694 5695 else 5696 # The variable is set, but is it from the command line or the environment? 5697 5698 # Try to remove the string !CAT! from our list. 5699 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CAT!/} 5700 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 5701 # If it failed, the variable was not from the command line. Ignore it, 5702 # but warn the user (except for BASH, which is always set by the calling BASH). 5703 if test "xCAT" != xBASH; then 5704 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CAT from the environment. Use command line variables instead." >&5 5705 $as_echo "$as_me: WARNING: Ignoring value of CAT from the environment. Use command line variables instead." >&2;} 5706 fi 5707 # Try to locate tool using the code snippet 5708 for ac_prog in cat 5709 do 5710 # Extract the first word of "$ac_prog", so it can be a program name with args. 5711 set dummy $ac_prog; ac_word=$2 5712 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5713 $as_echo_n "checking for $ac_word... " >&6; } 5714 if ${ac_cv_path_CAT+:} false; then : 5715 $as_echo_n "(cached) " >&6 5716 else 5717 case $CAT in 5718 [\\/]* | ?:[\\/]*) 5719 ac_cv_path_CAT="$CAT" # Let the user override the test with a path. 5720 ;; 5721 *) 5722 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5723 for as_dir in $PATH 5724 do 5725 IFS=$as_save_IFS 5726 test -z "$as_dir" && as_dir=. 5727 for ac_exec_ext in '' $ac_executable_extensions; do 5728 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5729 ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext" 5730 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5731 break 2 5732 fi 5733 done 5734 done 5735 IFS=$as_save_IFS 5736 5737 ;; 5738 esac 5739 fi 5740 CAT=$ac_cv_path_CAT 5741 if test -n "$CAT"; then 5742 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5 5743 $as_echo "$CAT" >&6; } 5744 else 5745 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5746 $as_echo "no" >&6; } 5747 fi 5748 5749 5750 test -n "$CAT" && break 5751 done 5752 5753 else 5754 # If it succeeded, then it was overridden by the user. We will use it 5755 # for the tool. 5756 5757 # First remove it from the list of overridden variables, so we can test 5758 # for unknown variables in the end. 5759 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 5760 5761 # Check if we try to supply an empty value 5762 if test "x$CAT" = x; then 5763 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CAT= (no value)" >&5 5764 $as_echo "$as_me: Setting user supplied tool CAT= (no value)" >&6;} 5765 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CAT" >&5 5766 $as_echo_n "checking for CAT... " >&6; } 5767 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 5768 $as_echo "disabled" >&6; } 5769 else 5770 # Check if the provided tool contains a complete path. 5771 tool_specified="$CAT" 5772 tool_basename="${tool_specified##*/}" 5773 if test "x$tool_basename" = "x$tool_specified"; then 5774 # A command without a complete path is provided, search $PATH. 5775 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CAT=$tool_basename" >&5 5776 $as_echo "$as_me: Will search for user supplied tool CAT=$tool_basename" >&6;} 5777 # Extract the first word of "$tool_basename", so it can be a program name with args. 5778 set dummy $tool_basename; ac_word=$2 5779 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5780 $as_echo_n "checking for $ac_word... " >&6; } 5781 if ${ac_cv_path_CAT+:} false; then : 5782 $as_echo_n "(cached) " >&6 5783 else 5784 case $CAT in 5785 [\\/]* | ?:[\\/]*) 5786 ac_cv_path_CAT="$CAT" # Let the user override the test with a path. 5787 ;; 5788 *) 5789 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5790 for as_dir in $PATH 5791 do 5792 IFS=$as_save_IFS 5793 test -z "$as_dir" && as_dir=. 5794 for ac_exec_ext in '' $ac_executable_extensions; do 5795 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5796 ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext" 5797 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5798 break 2 5799 fi 5800 done 5801 done 5802 IFS=$as_save_IFS 5803 5804 ;; 5805 esac 5806 fi 5807 CAT=$ac_cv_path_CAT 5808 if test -n "$CAT"; then 5809 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5 5810 $as_echo "$CAT" >&6; } 5811 else 5812 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5813 $as_echo "no" >&6; } 5814 fi 5815 5816 5817 if test "x$CAT" = x; then 5818 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 5819 fi 5820 else 5821 # Otherwise we believe it is a complete path. Use it as it is. 5822 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CAT=$tool_specified" >&5 5823 $as_echo "$as_me: Will use user supplied tool CAT=$tool_specified" >&6;} 5824 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CAT" >&5 5825 $as_echo_n "checking for CAT... " >&6; } 5826 if test ! -x "$tool_specified"; then 5827 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 5828 $as_echo "not found" >&6; } 5829 as_fn_error $? "User supplied tool CAT=$tool_specified does not exist or is not executable" "$LINENO" 5 5830 fi 5831 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 5832 $as_echo "$tool_specified" >&6; } 5833 fi 5834 fi 5835 fi 5836 5837 fi 5838 5839 5840 5841 if test "x$CAT" = x; then 5842 as_fn_error $? "Could not find required tool for CAT" "$LINENO" 5 5843 fi 5844 5845 5846 5847 5848 5849 # Publish this variable in the help. 5850 5851 5852 if [ -z "${CHMOD+x}" ]; then 5853 # The variable is not set by user, try to locate tool using the code snippet 5854 for ac_prog in chmod 5855 do 5856 # Extract the first word of "$ac_prog", so it can be a program name with args. 5857 set dummy $ac_prog; ac_word=$2 5858 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5859 $as_echo_n "checking for $ac_word... " >&6; } 5860 if ${ac_cv_path_CHMOD+:} false; then : 5861 $as_echo_n "(cached) " >&6 5862 else 5863 case $CHMOD in 5864 [\\/]* | ?:[\\/]*) 5865 ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path. 5866 ;; 5867 *) 5868 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5869 for as_dir in $PATH 5870 do 5871 IFS=$as_save_IFS 5872 test -z "$as_dir" && as_dir=. 5873 for ac_exec_ext in '' $ac_executable_extensions; do 5874 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5875 ac_cv_path_CHMOD="$as_dir/$ac_word$ac_exec_ext" 5876 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5877 break 2 5878 fi 5879 done 5880 done 5881 IFS=$as_save_IFS 5882 5883 ;; 5884 esac 5885 fi 5886 CHMOD=$ac_cv_path_CHMOD 5887 if test -n "$CHMOD"; then 5888 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5 5889 $as_echo "$CHMOD" >&6; } 5890 else 5891 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5892 $as_echo "no" >&6; } 5893 fi 5894 5895 5896 test -n "$CHMOD" && break 5897 done 5898 5899 else 5900 # The variable is set, but is it from the command line or the environment? 5901 5902 # Try to remove the string !CHMOD! from our list. 5903 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CHMOD!/} 5904 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 5905 # If it failed, the variable was not from the command line. Ignore it, 5906 # but warn the user (except for BASH, which is always set by the calling BASH). 5907 if test "xCHMOD" != xBASH; then 5908 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CHMOD from the environment. Use command line variables instead." >&5 5909 $as_echo "$as_me: WARNING: Ignoring value of CHMOD from the environment. Use command line variables instead." >&2;} 5910 fi 5911 # Try to locate tool using the code snippet 5912 for ac_prog in chmod 5913 do 5914 # Extract the first word of "$ac_prog", so it can be a program name with args. 5915 set dummy $ac_prog; ac_word=$2 5916 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5917 $as_echo_n "checking for $ac_word... " >&6; } 5918 if ${ac_cv_path_CHMOD+:} false; then : 5919 $as_echo_n "(cached) " >&6 5920 else 5921 case $CHMOD in 5922 [\\/]* | ?:[\\/]*) 5923 ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path. 5924 ;; 5925 *) 5926 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5927 for as_dir in $PATH 5928 do 5929 IFS=$as_save_IFS 5930 test -z "$as_dir" && as_dir=. 5931 for ac_exec_ext in '' $ac_executable_extensions; do 5932 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5933 ac_cv_path_CHMOD="$as_dir/$ac_word$ac_exec_ext" 5934 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5935 break 2 5936 fi 5937 done 5938 done 5939 IFS=$as_save_IFS 5940 5941 ;; 5942 esac 5943 fi 5944 CHMOD=$ac_cv_path_CHMOD 5945 if test -n "$CHMOD"; then 5946 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5 5947 $as_echo "$CHMOD" >&6; } 5948 else 5949 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5950 $as_echo "no" >&6; } 5951 fi 5952 5953 5954 test -n "$CHMOD" && break 5955 done 5956 5957 else 5958 # If it succeeded, then it was overridden by the user. We will use it 5959 # for the tool. 5960 5961 # First remove it from the list of overridden variables, so we can test 5962 # for unknown variables in the end. 5963 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 5964 5965 # Check if we try to supply an empty value 5966 if test "x$CHMOD" = x; then 5967 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CHMOD= (no value)" >&5 5968 $as_echo "$as_me: Setting user supplied tool CHMOD= (no value)" >&6;} 5969 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CHMOD" >&5 5970 $as_echo_n "checking for CHMOD... " >&6; } 5971 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 5972 $as_echo "disabled" >&6; } 5973 else 5974 # Check if the provided tool contains a complete path. 5975 tool_specified="$CHMOD" 5976 tool_basename="${tool_specified##*/}" 5977 if test "x$tool_basename" = "x$tool_specified"; then 5978 # A command without a complete path is provided, search $PATH. 5979 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CHMOD=$tool_basename" >&5 5980 $as_echo "$as_me: Will search for user supplied tool CHMOD=$tool_basename" >&6;} 5981 # Extract the first word of "$tool_basename", so it can be a program name with args. 5982 set dummy $tool_basename; ac_word=$2 5983 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5984 $as_echo_n "checking for $ac_word... " >&6; } 5985 if ${ac_cv_path_CHMOD+:} false; then : 5986 $as_echo_n "(cached) " >&6 5987 else 5988 case $CHMOD in 5989 [\\/]* | ?:[\\/]*) 5990 ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path. 5991 ;; 5992 *) 5993 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5994 for as_dir in $PATH 5995 do 5996 IFS=$as_save_IFS 5997 test -z "$as_dir" && as_dir=. 5998 for ac_exec_ext in '' $ac_executable_extensions; do 5999 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6000 ac_cv_path_CHMOD="$as_dir/$ac_word$ac_exec_ext" 6001 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6002 break 2 6003 fi 6004 done 6005 done 6006 IFS=$as_save_IFS 6007 6008 ;; 6009 esac 6010 fi 6011 CHMOD=$ac_cv_path_CHMOD 6012 if test -n "$CHMOD"; then 6013 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5 6014 $as_echo "$CHMOD" >&6; } 6015 else 6016 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6017 $as_echo "no" >&6; } 6018 fi 6019 6020 6021 if test "x$CHMOD" = x; then 6022 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 6023 fi 6024 else 6025 # Otherwise we believe it is a complete path. Use it as it is. 6026 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CHMOD=$tool_specified" >&5 6027 $as_echo "$as_me: Will use user supplied tool CHMOD=$tool_specified" >&6;} 6028 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CHMOD" >&5 6029 $as_echo_n "checking for CHMOD... " >&6; } 6030 if test ! -x "$tool_specified"; then 6031 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 6032 $as_echo "not found" >&6; } 6033 as_fn_error $? "User supplied tool CHMOD=$tool_specified does not exist or is not executable" "$LINENO" 5 6034 fi 6035 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 6036 $as_echo "$tool_specified" >&6; } 6037 fi 6038 fi 6039 fi 6040 6041 fi 6042 6043 6044 6045 if test "x$CHMOD" = x; then 6046 as_fn_error $? "Could not find required tool for CHMOD" "$LINENO" 5 6047 fi 6048 6049 6050 6051 6052 6053 # Publish this variable in the help. 6054 6055 6056 if [ -z "${CMP+x}" ]; then 6057 # The variable is not set by user, try to locate tool using the code snippet 6058 for ac_prog in cmp 6059 do 6060 # Extract the first word of "$ac_prog", so it can be a program name with args. 6061 set dummy $ac_prog; ac_word=$2 6062 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6063 $as_echo_n "checking for $ac_word... " >&6; } 6064 if ${ac_cv_path_CMP+:} false; then : 6065 $as_echo_n "(cached) " >&6 6066 else 6067 case $CMP in 6068 [\\/]* | ?:[\\/]*) 6069 ac_cv_path_CMP="$CMP" # Let the user override the test with a path. 6070 ;; 6071 *) 6072 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6073 for as_dir in $PATH 6074 do 6075 IFS=$as_save_IFS 6076 test -z "$as_dir" && as_dir=. 6077 for ac_exec_ext in '' $ac_executable_extensions; do 6078 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6079 ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext" 6080 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6081 break 2 6082 fi 6083 done 6084 done 6085 IFS=$as_save_IFS 6086 6087 ;; 6088 esac 6089 fi 6090 CMP=$ac_cv_path_CMP 6091 if test -n "$CMP"; then 6092 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5 6093 $as_echo "$CMP" >&6; } 6094 else 6095 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6096 $as_echo "no" >&6; } 6097 fi 6098 6099 6100 test -n "$CMP" && break 6101 done 6102 6103 else 6104 # The variable is set, but is it from the command line or the environment? 6105 6106 # Try to remove the string !CMP! from our list. 6107 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CMP!/} 6108 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 6109 # If it failed, the variable was not from the command line. Ignore it, 6110 # but warn the user (except for BASH, which is always set by the calling BASH). 6111 if test "xCMP" != xBASH; then 6112 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CMP from the environment. Use command line variables instead." >&5 6113 $as_echo "$as_me: WARNING: Ignoring value of CMP from the environment. Use command line variables instead." >&2;} 6114 fi 6115 # Try to locate tool using the code snippet 6116 for ac_prog in cmp 6117 do 6118 # Extract the first word of "$ac_prog", so it can be a program name with args. 6119 set dummy $ac_prog; ac_word=$2 6120 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6121 $as_echo_n "checking for $ac_word... " >&6; } 6122 if ${ac_cv_path_CMP+:} false; then : 6123 $as_echo_n "(cached) " >&6 6124 else 6125 case $CMP in 6126 [\\/]* | ?:[\\/]*) 6127 ac_cv_path_CMP="$CMP" # Let the user override the test with a path. 6128 ;; 6129 *) 6130 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6131 for as_dir in $PATH 6132 do 6133 IFS=$as_save_IFS 6134 test -z "$as_dir" && as_dir=. 6135 for ac_exec_ext in '' $ac_executable_extensions; do 6136 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6137 ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext" 6138 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6139 break 2 6140 fi 6141 done 6142 done 6143 IFS=$as_save_IFS 6144 6145 ;; 6146 esac 6147 fi 6148 CMP=$ac_cv_path_CMP 6149 if test -n "$CMP"; then 6150 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5 6151 $as_echo "$CMP" >&6; } 6152 else 6153 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6154 $as_echo "no" >&6; } 6155 fi 6156 6157 6158 test -n "$CMP" && break 6159 done 6160 6161 else 6162 # If it succeeded, then it was overridden by the user. We will use it 6163 # for the tool. 6164 6165 # First remove it from the list of overridden variables, so we can test 6166 # for unknown variables in the end. 6167 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 6168 6169 # Check if we try to supply an empty value 6170 if test "x$CMP" = x; then 6171 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CMP= (no value)" >&5 6172 $as_echo "$as_me: Setting user supplied tool CMP= (no value)" >&6;} 6173 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CMP" >&5 6174 $as_echo_n "checking for CMP... " >&6; } 6175 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 6176 $as_echo "disabled" >&6; } 6177 else 6178 # Check if the provided tool contains a complete path. 6179 tool_specified="$CMP" 6180 tool_basename="${tool_specified##*/}" 6181 if test "x$tool_basename" = "x$tool_specified"; then 6182 # A command without a complete path is provided, search $PATH. 6183 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CMP=$tool_basename" >&5 6184 $as_echo "$as_me: Will search for user supplied tool CMP=$tool_basename" >&6;} 6185 # Extract the first word of "$tool_basename", so it can be a program name with args. 6186 set dummy $tool_basename; ac_word=$2 6187 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6188 $as_echo_n "checking for $ac_word... " >&6; } 6189 if ${ac_cv_path_CMP+:} false; then : 6190 $as_echo_n "(cached) " >&6 6191 else 6192 case $CMP in 6193 [\\/]* | ?:[\\/]*) 6194 ac_cv_path_CMP="$CMP" # Let the user override the test with a path. 6195 ;; 6196 *) 6197 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6198 for as_dir in $PATH 6199 do 6200 IFS=$as_save_IFS 6201 test -z "$as_dir" && as_dir=. 6202 for ac_exec_ext in '' $ac_executable_extensions; do 6203 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6204 ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext" 6205 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6206 break 2 6207 fi 6208 done 6209 done 6210 IFS=$as_save_IFS 6211 6212 ;; 6213 esac 6214 fi 6215 CMP=$ac_cv_path_CMP 6216 if test -n "$CMP"; then 6217 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5 6218 $as_echo "$CMP" >&6; } 6219 else 6220 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6221 $as_echo "no" >&6; } 6222 fi 6223 6224 6225 if test "x$CMP" = x; then 6226 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 6227 fi 6228 else 6229 # Otherwise we believe it is a complete path. Use it as it is. 6230 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CMP=$tool_specified" >&5 6231 $as_echo "$as_me: Will use user supplied tool CMP=$tool_specified" >&6;} 6232 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CMP" >&5 6233 $as_echo_n "checking for CMP... " >&6; } 6234 if test ! -x "$tool_specified"; then 6235 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 6236 $as_echo "not found" >&6; } 6237 as_fn_error $? "User supplied tool CMP=$tool_specified does not exist or is not executable" "$LINENO" 5 6238 fi 6239 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 6240 $as_echo "$tool_specified" >&6; } 6241 fi 6242 fi 6243 fi 6244 6245 fi 6246 6247 6248 6249 if test "x$CMP" = x; then 6250 as_fn_error $? "Could not find required tool for CMP" "$LINENO" 5 6251 fi 6252 6253 6254 6255 6256 6257 # Publish this variable in the help. 6258 6259 6260 if [ -z "${COMM+x}" ]; then 6261 # The variable is not set by user, try to locate tool using the code snippet 6262 for ac_prog in comm 6263 do 6264 # Extract the first word of "$ac_prog", so it can be a program name with args. 6265 set dummy $ac_prog; ac_word=$2 6266 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6267 $as_echo_n "checking for $ac_word... " >&6; } 6268 if ${ac_cv_path_COMM+:} false; then : 6269 $as_echo_n "(cached) " >&6 6270 else 6271 case $COMM in 6272 [\\/]* | ?:[\\/]*) 6273 ac_cv_path_COMM="$COMM" # Let the user override the test with a path. 6274 ;; 6275 *) 6276 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6277 for as_dir in $PATH 6278 do 6279 IFS=$as_save_IFS 6280 test -z "$as_dir" && as_dir=. 6281 for ac_exec_ext in '' $ac_executable_extensions; do 6282 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6283 ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext" 6284 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6285 break 2 6286 fi 6287 done 6288 done 6289 IFS=$as_save_IFS 6290 6291 ;; 6292 esac 6293 fi 6294 COMM=$ac_cv_path_COMM 6295 if test -n "$COMM"; then 6296 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5 6297 $as_echo "$COMM" >&6; } 6298 else 6299 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6300 $as_echo "no" >&6; } 6301 fi 6302 6303 6304 test -n "$COMM" && break 6305 done 6306 6307 else 6308 # The variable is set, but is it from the command line or the environment? 6309 6310 # Try to remove the string !COMM! from our list. 6311 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!COMM!/} 6312 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 6313 # If it failed, the variable was not from the command line. Ignore it, 6314 # but warn the user (except for BASH, which is always set by the calling BASH). 6315 if test "xCOMM" != xBASH; then 6316 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of COMM from the environment. Use command line variables instead." >&5 6317 $as_echo "$as_me: WARNING: Ignoring value of COMM from the environment. Use command line variables instead." >&2;} 6318 fi 6319 # Try to locate tool using the code snippet 6320 for ac_prog in comm 6321 do 6322 # Extract the first word of "$ac_prog", so it can be a program name with args. 6323 set dummy $ac_prog; ac_word=$2 6324 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6325 $as_echo_n "checking for $ac_word... " >&6; } 6326 if ${ac_cv_path_COMM+:} false; then : 6327 $as_echo_n "(cached) " >&6 6328 else 6329 case $COMM in 6330 [\\/]* | ?:[\\/]*) 6331 ac_cv_path_COMM="$COMM" # Let the user override the test with a path. 6332 ;; 6333 *) 6334 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6335 for as_dir in $PATH 6336 do 6337 IFS=$as_save_IFS 6338 test -z "$as_dir" && as_dir=. 6339 for ac_exec_ext in '' $ac_executable_extensions; do 6340 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6341 ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext" 6342 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6343 break 2 6344 fi 6345 done 6346 done 6347 IFS=$as_save_IFS 6348 6349 ;; 6350 esac 6351 fi 6352 COMM=$ac_cv_path_COMM 6353 if test -n "$COMM"; then 6354 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5 6355 $as_echo "$COMM" >&6; } 6356 else 6357 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6358 $as_echo "no" >&6; } 6359 fi 6360 6361 6362 test -n "$COMM" && break 6363 done 6364 6365 else 6366 # If it succeeded, then it was overridden by the user. We will use it 6367 # for the tool. 6368 6369 # First remove it from the list of overridden variables, so we can test 6370 # for unknown variables in the end. 6371 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 6372 6373 # Check if we try to supply an empty value 6374 if test "x$COMM" = x; then 6375 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool COMM= (no value)" >&5 6376 $as_echo "$as_me: Setting user supplied tool COMM= (no value)" >&6;} 6377 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for COMM" >&5 6378 $as_echo_n "checking for COMM... " >&6; } 6379 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 6380 $as_echo "disabled" >&6; } 6381 else 6382 # Check if the provided tool contains a complete path. 6383 tool_specified="$COMM" 6384 tool_basename="${tool_specified##*/}" 6385 if test "x$tool_basename" = "x$tool_specified"; then 6386 # A command without a complete path is provided, search $PATH. 6387 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool COMM=$tool_basename" >&5 6388 $as_echo "$as_me: Will search for user supplied tool COMM=$tool_basename" >&6;} 6389 # Extract the first word of "$tool_basename", so it can be a program name with args. 6390 set dummy $tool_basename; ac_word=$2 6391 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6392 $as_echo_n "checking for $ac_word... " >&6; } 6393 if ${ac_cv_path_COMM+:} false; then : 6394 $as_echo_n "(cached) " >&6 6395 else 6396 case $COMM in 6397 [\\/]* | ?:[\\/]*) 6398 ac_cv_path_COMM="$COMM" # Let the user override the test with a path. 6399 ;; 6400 *) 6401 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6402 for as_dir in $PATH 6403 do 6404 IFS=$as_save_IFS 6405 test -z "$as_dir" && as_dir=. 6406 for ac_exec_ext in '' $ac_executable_extensions; do 6407 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6408 ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext" 6409 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6410 break 2 6411 fi 6412 done 6413 done 6414 IFS=$as_save_IFS 6415 6416 ;; 6417 esac 6418 fi 6419 COMM=$ac_cv_path_COMM 6420 if test -n "$COMM"; then 6421 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5 6422 $as_echo "$COMM" >&6; } 6423 else 6424 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6425 $as_echo "no" >&6; } 6426 fi 6427 6428 6429 if test "x$COMM" = x; then 6430 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 6431 fi 6432 else 6433 # Otherwise we believe it is a complete path. Use it as it is. 6434 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool COMM=$tool_specified" >&5 6435 $as_echo "$as_me: Will use user supplied tool COMM=$tool_specified" >&6;} 6436 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for COMM" >&5 6437 $as_echo_n "checking for COMM... " >&6; } 6438 if test ! -x "$tool_specified"; then 6439 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 6440 $as_echo "not found" >&6; } 6441 as_fn_error $? "User supplied tool COMM=$tool_specified does not exist or is not executable" "$LINENO" 5 6442 fi 6443 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 6444 $as_echo "$tool_specified" >&6; } 6445 fi 6446 fi 6447 fi 6448 6449 fi 6450 6451 6452 6453 if test "x$COMM" = x; then 6454 as_fn_error $? "Could not find required tool for COMM" "$LINENO" 5 6455 fi 6456 6457 6458 6459 6460 6461 # Publish this variable in the help. 6462 6463 6464 if [ -z "${CP+x}" ]; then 6465 # The variable is not set by user, try to locate tool using the code snippet 6466 for ac_prog in cp 6467 do 6468 # Extract the first word of "$ac_prog", so it can be a program name with args. 6469 set dummy $ac_prog; ac_word=$2 6470 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6471 $as_echo_n "checking for $ac_word... " >&6; } 6472 if ${ac_cv_path_CP+:} false; then : 6473 $as_echo_n "(cached) " >&6 6474 else 6475 case $CP in 6476 [\\/]* | ?:[\\/]*) 6477 ac_cv_path_CP="$CP" # Let the user override the test with a path. 6478 ;; 6479 *) 6480 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6481 for as_dir in $PATH 6482 do 6483 IFS=$as_save_IFS 6484 test -z "$as_dir" && as_dir=. 6485 for ac_exec_ext in '' $ac_executable_extensions; do 6486 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6487 ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext" 6488 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6489 break 2 6490 fi 6491 done 6492 done 6493 IFS=$as_save_IFS 6494 6495 ;; 6496 esac 6497 fi 6498 CP=$ac_cv_path_CP 6499 if test -n "$CP"; then 6500 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CP" >&5 6501 $as_echo "$CP" >&6; } 6502 else 6503 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6504 $as_echo "no" >&6; } 6505 fi 6506 6507 6508 test -n "$CP" && break 6509 done 6510 6511 else 6512 # The variable is set, but is it from the command line or the environment? 6513 6514 # Try to remove the string !CP! from our list. 6515 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CP!/} 6516 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 6517 # If it failed, the variable was not from the command line. Ignore it, 6518 # but warn the user (except for BASH, which is always set by the calling BASH). 6519 if test "xCP" != xBASH; then 6520 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CP from the environment. Use command line variables instead." >&5 6521 $as_echo "$as_me: WARNING: Ignoring value of CP from the environment. Use command line variables instead." >&2;} 6522 fi 6523 # Try to locate tool using the code snippet 6524 for ac_prog in cp 6525 do 6526 # Extract the first word of "$ac_prog", so it can be a program name with args. 6527 set dummy $ac_prog; ac_word=$2 6528 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6529 $as_echo_n "checking for $ac_word... " >&6; } 6530 if ${ac_cv_path_CP+:} false; then : 6531 $as_echo_n "(cached) " >&6 6532 else 6533 case $CP in 6534 [\\/]* | ?:[\\/]*) 6535 ac_cv_path_CP="$CP" # Let the user override the test with a path. 6536 ;; 6537 *) 6538 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6539 for as_dir in $PATH 6540 do 6541 IFS=$as_save_IFS 6542 test -z "$as_dir" && as_dir=. 6543 for ac_exec_ext in '' $ac_executable_extensions; do 6544 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6545 ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext" 6546 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6547 break 2 6548 fi 6549 done 6550 done 6551 IFS=$as_save_IFS 6552 6553 ;; 6554 esac 6555 fi 6556 CP=$ac_cv_path_CP 6557 if test -n "$CP"; then 6558 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CP" >&5 6559 $as_echo "$CP" >&6; } 6560 else 6561 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6562 $as_echo "no" >&6; } 6563 fi 6564 6565 6566 test -n "$CP" && break 6567 done 6568 6569 else 6570 # If it succeeded, then it was overridden by the user. We will use it 6571 # for the tool. 6572 6573 # First remove it from the list of overridden variables, so we can test 6574 # for unknown variables in the end. 6575 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 6576 6577 # Check if we try to supply an empty value 6578 if test "x$CP" = x; then 6579 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CP= (no value)" >&5 6580 $as_echo "$as_me: Setting user supplied tool CP= (no value)" >&6;} 6581 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CP" >&5 6582 $as_echo_n "checking for CP... " >&6; } 6583 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 6584 $as_echo "disabled" >&6; } 6585 else 6586 # Check if the provided tool contains a complete path. 6587 tool_specified="$CP" 6588 tool_basename="${tool_specified##*/}" 6589 if test "x$tool_basename" = "x$tool_specified"; then 6590 # A command without a complete path is provided, search $PATH. 6591 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CP=$tool_basename" >&5 6592 $as_echo "$as_me: Will search for user supplied tool CP=$tool_basename" >&6;} 6593 # Extract the first word of "$tool_basename", so it can be a program name with args. 6594 set dummy $tool_basename; ac_word=$2 6595 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6596 $as_echo_n "checking for $ac_word... " >&6; } 6597 if ${ac_cv_path_CP+:} false; then : 6598 $as_echo_n "(cached) " >&6 6599 else 6600 case $CP in 6601 [\\/]* | ?:[\\/]*) 6602 ac_cv_path_CP="$CP" # Let the user override the test with a path. 6603 ;; 6604 *) 6605 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6606 for as_dir in $PATH 6607 do 6608 IFS=$as_save_IFS 6609 test -z "$as_dir" && as_dir=. 6610 for ac_exec_ext in '' $ac_executable_extensions; do 6611 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6612 ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext" 6613 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6614 break 2 6615 fi 6616 done 6617 done 6618 IFS=$as_save_IFS 6619 6620 ;; 6621 esac 6622 fi 6623 CP=$ac_cv_path_CP 6624 if test -n "$CP"; then 6625 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CP" >&5 6626 $as_echo "$CP" >&6; } 6627 else 6628 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6629 $as_echo "no" >&6; } 6630 fi 6631 6632 6633 if test "x$CP" = x; then 6634 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 6635 fi 6636 else 6637 # Otherwise we believe it is a complete path. Use it as it is. 6638 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CP=$tool_specified" >&5 6639 $as_echo "$as_me: Will use user supplied tool CP=$tool_specified" >&6;} 6640 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CP" >&5 6641 $as_echo_n "checking for CP... " >&6; } 6642 if test ! -x "$tool_specified"; then 6643 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 6644 $as_echo "not found" >&6; } 6645 as_fn_error $? "User supplied tool CP=$tool_specified does not exist or is not executable" "$LINENO" 5 6646 fi 6647 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 6648 $as_echo "$tool_specified" >&6; } 6649 fi 6650 fi 6651 fi 6652 6653 fi 6654 6655 6656 6657 if test "x$CP" = x; then 6658 as_fn_error $? "Could not find required tool for CP" "$LINENO" 5 6659 fi 6660 6661 6662 6663 6664 6665 # Publish this variable in the help. 6666 6667 6668 if [ -z "${CUT+x}" ]; then 6669 # The variable is not set by user, try to locate tool using the code snippet 6670 for ac_prog in cut 6671 do 6672 # Extract the first word of "$ac_prog", so it can be a program name with args. 6673 set dummy $ac_prog; ac_word=$2 6674 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6675 $as_echo_n "checking for $ac_word... " >&6; } 6676 if ${ac_cv_path_CUT+:} false; then : 6677 $as_echo_n "(cached) " >&6 6678 else 6679 case $CUT in 6680 [\\/]* | ?:[\\/]*) 6681 ac_cv_path_CUT="$CUT" # Let the user override the test with a path. 6682 ;; 6683 *) 6684 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6685 for as_dir in $PATH 6686 do 6687 IFS=$as_save_IFS 6688 test -z "$as_dir" && as_dir=. 6689 for ac_exec_ext in '' $ac_executable_extensions; do 6690 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6691 ac_cv_path_CUT="$as_dir/$ac_word$ac_exec_ext" 6692 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6693 break 2 6694 fi 6695 done 6696 done 6697 IFS=$as_save_IFS 6698 6699 ;; 6700 esac 6701 fi 6702 CUT=$ac_cv_path_CUT 6703 if test -n "$CUT"; then 6704 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUT" >&5 6705 $as_echo "$CUT" >&6; } 6706 else 6707 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6708 $as_echo "no" >&6; } 6709 fi 6710 6711 6712 test -n "$CUT" && break 6713 done 6714 6715 else 6716 # The variable is set, but is it from the command line or the environment? 6717 6718 # Try to remove the string !CUT! from our list. 6719 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CUT!/} 6720 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 6721 # If it failed, the variable was not from the command line. Ignore it, 6722 # but warn the user (except for BASH, which is always set by the calling BASH). 6723 if test "xCUT" != xBASH; then 6724 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CUT from the environment. Use command line variables instead." >&5 6725 $as_echo "$as_me: WARNING: Ignoring value of CUT from the environment. Use command line variables instead." >&2;} 6726 fi 6727 # Try to locate tool using the code snippet 6728 for ac_prog in cut 6729 do 6730 # Extract the first word of "$ac_prog", so it can be a program name with args. 6731 set dummy $ac_prog; ac_word=$2 6732 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6733 $as_echo_n "checking for $ac_word... " >&6; } 6734 if ${ac_cv_path_CUT+:} false; then : 6735 $as_echo_n "(cached) " >&6 6736 else 6737 case $CUT in 6738 [\\/]* | ?:[\\/]*) 6739 ac_cv_path_CUT="$CUT" # Let the user override the test with a path. 6740 ;; 6741 *) 6742 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6743 for as_dir in $PATH 6744 do 6745 IFS=$as_save_IFS 6746 test -z "$as_dir" && as_dir=. 6747 for ac_exec_ext in '' $ac_executable_extensions; do 6748 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6749 ac_cv_path_CUT="$as_dir/$ac_word$ac_exec_ext" 6750 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6751 break 2 6752 fi 6753 done 6754 done 6755 IFS=$as_save_IFS 6756 6757 ;; 6758 esac 6759 fi 6760 CUT=$ac_cv_path_CUT 6761 if test -n "$CUT"; then 6762 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUT" >&5 6763 $as_echo "$CUT" >&6; } 6764 else 6765 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6766 $as_echo "no" >&6; } 6767 fi 6768 6769 6770 test -n "$CUT" && break 6771 done 6772 6773 else 6774 # If it succeeded, then it was overridden by the user. We will use it 6775 # for the tool. 6776 6777 # First remove it from the list of overridden variables, so we can test 6778 # for unknown variables in the end. 6779 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 6780 6781 # Check if we try to supply an empty value 6782 if test "x$CUT" = x; then 6783 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CUT= (no value)" >&5 6784 $as_echo "$as_me: Setting user supplied tool CUT= (no value)" >&6;} 6785 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CUT" >&5 6786 $as_echo_n "checking for CUT... " >&6; } 6787 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 6788 $as_echo "disabled" >&6; } 6789 else 6790 # Check if the provided tool contains a complete path. 6791 tool_specified="$CUT" 6792 tool_basename="${tool_specified##*/}" 6793 if test "x$tool_basename" = "x$tool_specified"; then 6794 # A command without a complete path is provided, search $PATH. 6795 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CUT=$tool_basename" >&5 6796 $as_echo "$as_me: Will search for user supplied tool CUT=$tool_basename" >&6;} 6797 # Extract the first word of "$tool_basename", so it can be a program name with args. 6798 set dummy $tool_basename; ac_word=$2 6799 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6800 $as_echo_n "checking for $ac_word... " >&6; } 6801 if ${ac_cv_path_CUT+:} false; then : 6802 $as_echo_n "(cached) " >&6 6803 else 6804 case $CUT in 6805 [\\/]* | ?:[\\/]*) 6806 ac_cv_path_CUT="$CUT" # Let the user override the test with a path. 6807 ;; 6808 *) 6809 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6810 for as_dir in $PATH 6811 do 6812 IFS=$as_save_IFS 6813 test -z "$as_dir" && as_dir=. 6814 for ac_exec_ext in '' $ac_executable_extensions; do 6815 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6816 ac_cv_path_CUT="$as_dir/$ac_word$ac_exec_ext" 6817 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6818 break 2 6819 fi 6820 done 6821 done 6822 IFS=$as_save_IFS 6823 6824 ;; 6825 esac 6826 fi 6827 CUT=$ac_cv_path_CUT 6828 if test -n "$CUT"; then 6829 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUT" >&5 6830 $as_echo "$CUT" >&6; } 6831 else 6832 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6833 $as_echo "no" >&6; } 6834 fi 6835 6836 6837 if test "x$CUT" = x; then 6838 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 6839 fi 6840 else 6841 # Otherwise we believe it is a complete path. Use it as it is. 6842 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CUT=$tool_specified" >&5 6843 $as_echo "$as_me: Will use user supplied tool CUT=$tool_specified" >&6;} 6844 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CUT" >&5 6845 $as_echo_n "checking for CUT... " >&6; } 6846 if test ! -x "$tool_specified"; then 6847 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 6848 $as_echo "not found" >&6; } 6849 as_fn_error $? "User supplied tool CUT=$tool_specified does not exist or is not executable" "$LINENO" 5 6850 fi 6851 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 6852 $as_echo "$tool_specified" >&6; } 6853 fi 6854 fi 6855 fi 6856 6857 fi 6858 6859 6860 6861 if test "x$CUT" = x; then 6862 as_fn_error $? "Could not find required tool for CUT" "$LINENO" 5 6863 fi 6864 6865 6866 6867 6868 6869 # Publish this variable in the help. 6870 6871 6872 if [ -z "${DATE+x}" ]; then 6873 # The variable is not set by user, try to locate tool using the code snippet 6874 for ac_prog in date 6875 do 6876 # Extract the first word of "$ac_prog", so it can be a program name with args. 6877 set dummy $ac_prog; ac_word=$2 6878 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6879 $as_echo_n "checking for $ac_word... " >&6; } 6880 if ${ac_cv_path_DATE+:} false; then : 6881 $as_echo_n "(cached) " >&6 6882 else 6883 case $DATE in 6884 [\\/]* | ?:[\\/]*) 6885 ac_cv_path_DATE="$DATE" # Let the user override the test with a path. 6886 ;; 6887 *) 6888 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6889 for as_dir in $PATH 6890 do 6891 IFS=$as_save_IFS 6892 test -z "$as_dir" && as_dir=. 6893 for ac_exec_ext in '' $ac_executable_extensions; do 6894 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6895 ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext" 6896 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6897 break 2 6898 fi 6899 done 6900 done 6901 IFS=$as_save_IFS 6902 6903 ;; 6904 esac 6905 fi 6906 DATE=$ac_cv_path_DATE 6907 if test -n "$DATE"; then 6908 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DATE" >&5 6909 $as_echo "$DATE" >&6; } 6910 else 6911 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6912 $as_echo "no" >&6; } 6913 fi 6914 6915 6916 test -n "$DATE" && break 6917 done 6918 6919 else 6920 # The variable is set, but is it from the command line or the environment? 6921 6922 # Try to remove the string !DATE! from our list. 6923 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DATE!/} 6924 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 6925 # If it failed, the variable was not from the command line. Ignore it, 6926 # but warn the user (except for BASH, which is always set by the calling BASH). 6927 if test "xDATE" != xBASH; then 6928 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DATE from the environment. Use command line variables instead." >&5 6929 $as_echo "$as_me: WARNING: Ignoring value of DATE from the environment. Use command line variables instead." >&2;} 6930 fi 6931 # Try to locate tool using the code snippet 6932 for ac_prog in date 6933 do 6934 # Extract the first word of "$ac_prog", so it can be a program name with args. 6935 set dummy $ac_prog; ac_word=$2 6936 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6937 $as_echo_n "checking for $ac_word... " >&6; } 6938 if ${ac_cv_path_DATE+:} false; then : 6939 $as_echo_n "(cached) " >&6 6940 else 6941 case $DATE in 6942 [\\/]* | ?:[\\/]*) 6943 ac_cv_path_DATE="$DATE" # Let the user override the test with a path. 6944 ;; 6945 *) 6946 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6947 for as_dir in $PATH 6948 do 6949 IFS=$as_save_IFS 6950 test -z "$as_dir" && as_dir=. 6951 for ac_exec_ext in '' $ac_executable_extensions; do 6952 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6953 ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext" 6954 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6955 break 2 6956 fi 6957 done 6958 done 6959 IFS=$as_save_IFS 6960 6961 ;; 6962 esac 6963 fi 6964 DATE=$ac_cv_path_DATE 6965 if test -n "$DATE"; then 6966 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DATE" >&5 6967 $as_echo "$DATE" >&6; } 6968 else 6969 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6970 $as_echo "no" >&6; } 6971 fi 6972 6973 6974 test -n "$DATE" && break 6975 done 6976 6977 else 6978 # If it succeeded, then it was overridden by the user. We will use it 6979 # for the tool. 6980 6981 # First remove it from the list of overridden variables, so we can test 6982 # for unknown variables in the end. 6983 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 6984 6985 # Check if we try to supply an empty value 6986 if test "x$DATE" = x; then 6987 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DATE= (no value)" >&5 6988 $as_echo "$as_me: Setting user supplied tool DATE= (no value)" >&6;} 6989 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DATE" >&5 6990 $as_echo_n "checking for DATE... " >&6; } 6991 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 6992 $as_echo "disabled" >&6; } 6993 else 6994 # Check if the provided tool contains a complete path. 6995 tool_specified="$DATE" 6996 tool_basename="${tool_specified##*/}" 6997 if test "x$tool_basename" = "x$tool_specified"; then 6998 # A command without a complete path is provided, search $PATH. 6999 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DATE=$tool_basename" >&5 7000 $as_echo "$as_me: Will search for user supplied tool DATE=$tool_basename" >&6;} 7001 # Extract the first word of "$tool_basename", so it can be a program name with args. 7002 set dummy $tool_basename; ac_word=$2 7003 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7004 $as_echo_n "checking for $ac_word... " >&6; } 7005 if ${ac_cv_path_DATE+:} false; then : 7006 $as_echo_n "(cached) " >&6 7007 else 7008 case $DATE in 7009 [\\/]* | ?:[\\/]*) 7010 ac_cv_path_DATE="$DATE" # Let the user override the test with a path. 7011 ;; 7012 *) 7013 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7014 for as_dir in $PATH 7015 do 7016 IFS=$as_save_IFS 7017 test -z "$as_dir" && as_dir=. 7018 for ac_exec_ext in '' $ac_executable_extensions; do 7019 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7020 ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext" 7021 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7022 break 2 7023 fi 7024 done 7025 done 7026 IFS=$as_save_IFS 7027 7028 ;; 7029 esac 7030 fi 7031 DATE=$ac_cv_path_DATE 7032 if test -n "$DATE"; then 7033 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DATE" >&5 7034 $as_echo "$DATE" >&6; } 7035 else 7036 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7037 $as_echo "no" >&6; } 7038 fi 7039 7040 7041 if test "x$DATE" = x; then 7042 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 7043 fi 7044 else 7045 # Otherwise we believe it is a complete path. Use it as it is. 7046 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DATE=$tool_specified" >&5 7047 $as_echo "$as_me: Will use user supplied tool DATE=$tool_specified" >&6;} 7048 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DATE" >&5 7049 $as_echo_n "checking for DATE... " >&6; } 7050 if test ! -x "$tool_specified"; then 7051 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 7052 $as_echo "not found" >&6; } 7053 as_fn_error $? "User supplied tool DATE=$tool_specified does not exist or is not executable" "$LINENO" 5 7054 fi 7055 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 7056 $as_echo "$tool_specified" >&6; } 7057 fi 7058 fi 7059 fi 7060 7061 fi 7062 7063 7064 7065 if test "x$DATE" = x; then 7066 as_fn_error $? "Could not find required tool for DATE" "$LINENO" 5 7067 fi 7068 7069 7070 7071 7072 7073 # Publish this variable in the help. 7074 7075 7076 if [ -z "${DIFF+x}" ]; then 7077 # The variable is not set by user, try to locate tool using the code snippet 7078 for ac_prog in gdiff diff 7079 do 7080 # Extract the first word of "$ac_prog", so it can be a program name with args. 7081 set dummy $ac_prog; ac_word=$2 7082 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7083 $as_echo_n "checking for $ac_word... " >&6; } 7084 if ${ac_cv_path_DIFF+:} false; then : 7085 $as_echo_n "(cached) " >&6 7086 else 7087 case $DIFF in 7088 [\\/]* | ?:[\\/]*) 7089 ac_cv_path_DIFF="$DIFF" # Let the user override the test with a path. 7090 ;; 7091 *) 7092 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7093 for as_dir in $PATH 7094 do 7095 IFS=$as_save_IFS 7096 test -z "$as_dir" && as_dir=. 7097 for ac_exec_ext in '' $ac_executable_extensions; do 7098 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7099 ac_cv_path_DIFF="$as_dir/$ac_word$ac_exec_ext" 7100 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7101 break 2 7102 fi 7103 done 7104 done 7105 IFS=$as_save_IFS 7106 7107 ;; 7108 esac 7109 fi 7110 DIFF=$ac_cv_path_DIFF 7111 if test -n "$DIFF"; then 7112 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIFF" >&5 7113 $as_echo "$DIFF" >&6; } 7114 else 7115 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7116 $as_echo "no" >&6; } 7117 fi 7118 7119 7120 test -n "$DIFF" && break 7121 done 7122 7123 else 7124 # The variable is set, but is it from the command line or the environment? 7125 7126 # Try to remove the string !DIFF! from our list. 7127 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DIFF!/} 7128 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 7129 # If it failed, the variable was not from the command line. Ignore it, 7130 # but warn the user (except for BASH, which is always set by the calling BASH). 7131 if test "xDIFF" != xBASH; then 7132 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DIFF from the environment. Use command line variables instead." >&5 7133 $as_echo "$as_me: WARNING: Ignoring value of DIFF from the environment. Use command line variables instead." >&2;} 7134 fi 7135 # Try to locate tool using the code snippet 7136 for ac_prog in gdiff diff 7137 do 7138 # Extract the first word of "$ac_prog", so it can be a program name with args. 7139 set dummy $ac_prog; ac_word=$2 7140 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7141 $as_echo_n "checking for $ac_word... " >&6; } 7142 if ${ac_cv_path_DIFF+:} false; then : 7143 $as_echo_n "(cached) " >&6 7144 else 7145 case $DIFF in 7146 [\\/]* | ?:[\\/]*) 7147 ac_cv_path_DIFF="$DIFF" # Let the user override the test with a path. 7148 ;; 7149 *) 7150 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7151 for as_dir in $PATH 7152 do 7153 IFS=$as_save_IFS 7154 test -z "$as_dir" && as_dir=. 7155 for ac_exec_ext in '' $ac_executable_extensions; do 7156 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7157 ac_cv_path_DIFF="$as_dir/$ac_word$ac_exec_ext" 7158 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7159 break 2 7160 fi 7161 done 7162 done 7163 IFS=$as_save_IFS 7164 7165 ;; 7166 esac 7167 fi 7168 DIFF=$ac_cv_path_DIFF 7169 if test -n "$DIFF"; then 7170 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIFF" >&5 7171 $as_echo "$DIFF" >&6; } 7172 else 7173 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7174 $as_echo "no" >&6; } 7175 fi 7176 7177 7178 test -n "$DIFF" && break 7179 done 7180 7181 else 7182 # If it succeeded, then it was overridden by the user. We will use it 7183 # for the tool. 7184 7185 # First remove it from the list of overridden variables, so we can test 7186 # for unknown variables in the end. 7187 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 7188 7189 # Check if we try to supply an empty value 7190 if test "x$DIFF" = x; then 7191 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DIFF= (no value)" >&5 7192 $as_echo "$as_me: Setting user supplied tool DIFF= (no value)" >&6;} 7193 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIFF" >&5 7194 $as_echo_n "checking for DIFF... " >&6; } 7195 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 7196 $as_echo "disabled" >&6; } 7197 else 7198 # Check if the provided tool contains a complete path. 7199 tool_specified="$DIFF" 7200 tool_basename="${tool_specified##*/}" 7201 if test "x$tool_basename" = "x$tool_specified"; then 7202 # A command without a complete path is provided, search $PATH. 7203 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DIFF=$tool_basename" >&5 7204 $as_echo "$as_me: Will search for user supplied tool DIFF=$tool_basename" >&6;} 7205 # Extract the first word of "$tool_basename", so it can be a program name with args. 7206 set dummy $tool_basename; ac_word=$2 7207 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7208 $as_echo_n "checking for $ac_word... " >&6; } 7209 if ${ac_cv_path_DIFF+:} false; then : 7210 $as_echo_n "(cached) " >&6 7211 else 7212 case $DIFF in 7213 [\\/]* | ?:[\\/]*) 7214 ac_cv_path_DIFF="$DIFF" # Let the user override the test with a path. 7215 ;; 7216 *) 7217 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7218 for as_dir in $PATH 7219 do 7220 IFS=$as_save_IFS 7221 test -z "$as_dir" && as_dir=. 7222 for ac_exec_ext in '' $ac_executable_extensions; do 7223 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7224 ac_cv_path_DIFF="$as_dir/$ac_word$ac_exec_ext" 7225 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7226 break 2 7227 fi 7228 done 7229 done 7230 IFS=$as_save_IFS 7231 7232 ;; 7233 esac 7234 fi 7235 DIFF=$ac_cv_path_DIFF 7236 if test -n "$DIFF"; then 7237 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIFF" >&5 7238 $as_echo "$DIFF" >&6; } 7239 else 7240 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7241 $as_echo "no" >&6; } 7242 fi 7243 7244 7245 if test "x$DIFF" = x; then 7246 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 7247 fi 7248 else 7249 # Otherwise we believe it is a complete path. Use it as it is. 7250 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DIFF=$tool_specified" >&5 7251 $as_echo "$as_me: Will use user supplied tool DIFF=$tool_specified" >&6;} 7252 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIFF" >&5 7253 $as_echo_n "checking for DIFF... " >&6; } 7254 if test ! -x "$tool_specified"; then 7255 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 7256 $as_echo "not found" >&6; } 7257 as_fn_error $? "User supplied tool DIFF=$tool_specified does not exist or is not executable" "$LINENO" 5 7258 fi 7259 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 7260 $as_echo "$tool_specified" >&6; } 7261 fi 7262 fi 7263 fi 7264 7265 fi 7266 7267 7268 7269 if test "x$DIFF" = x; then 7270 as_fn_error $? "Could not find required tool for DIFF" "$LINENO" 5 7271 fi 7272 7273 7274 7275 7276 7277 # Publish this variable in the help. 7278 7279 7280 if [ -z "${DIRNAME+x}" ]; then 7281 # The variable is not set by user, try to locate tool using the code snippet 7282 for ac_prog in dirname 7283 do 7284 # Extract the first word of "$ac_prog", so it can be a program name with args. 7285 set dummy $ac_prog; ac_word=$2 7286 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7287 $as_echo_n "checking for $ac_word... " >&6; } 7288 if ${ac_cv_path_DIRNAME+:} false; then : 7289 $as_echo_n "(cached) " >&6 7290 else 7291 case $DIRNAME in 7292 [\\/]* | ?:[\\/]*) 7293 ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path. 7294 ;; 7295 *) 7296 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7297 for as_dir in $PATH 7298 do 7299 IFS=$as_save_IFS 7300 test -z "$as_dir" && as_dir=. 7301 for ac_exec_ext in '' $ac_executable_extensions; do 7302 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7303 ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext" 7304 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7305 break 2 7306 fi 7307 done 7308 done 7309 IFS=$as_save_IFS 7310 7311 ;; 7312 esac 7313 fi 7314 DIRNAME=$ac_cv_path_DIRNAME 7315 if test -n "$DIRNAME"; then 7316 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5 7317 $as_echo "$DIRNAME" >&6; } 7318 else 7319 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7320 $as_echo "no" >&6; } 7321 fi 7322 7323 7324 test -n "$DIRNAME" && break 7325 done 7326 7327 else 7328 # The variable is set, but is it from the command line or the environment? 7329 7330 # Try to remove the string !DIRNAME! from our list. 7331 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DIRNAME!/} 7332 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 7333 # If it failed, the variable was not from the command line. Ignore it, 7334 # but warn the user (except for BASH, which is always set by the calling BASH). 7335 if test "xDIRNAME" != xBASH; then 7336 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DIRNAME from the environment. Use command line variables instead." >&5 7337 $as_echo "$as_me: WARNING: Ignoring value of DIRNAME from the environment. Use command line variables instead." >&2;} 7338 fi 7339 # Try to locate tool using the code snippet 7340 for ac_prog in dirname 7341 do 7342 # Extract the first word of "$ac_prog", so it can be a program name with args. 7343 set dummy $ac_prog; ac_word=$2 7344 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7345 $as_echo_n "checking for $ac_word... " >&6; } 7346 if ${ac_cv_path_DIRNAME+:} false; then : 7347 $as_echo_n "(cached) " >&6 7348 else 7349 case $DIRNAME in 7350 [\\/]* | ?:[\\/]*) 7351 ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path. 7352 ;; 7353 *) 7354 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7355 for as_dir in $PATH 7356 do 7357 IFS=$as_save_IFS 7358 test -z "$as_dir" && as_dir=. 7359 for ac_exec_ext in '' $ac_executable_extensions; do 7360 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7361 ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext" 7362 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7363 break 2 7364 fi 7365 done 7366 done 7367 IFS=$as_save_IFS 7368 7369 ;; 7370 esac 7371 fi 7372 DIRNAME=$ac_cv_path_DIRNAME 7373 if test -n "$DIRNAME"; then 7374 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5 7375 $as_echo "$DIRNAME" >&6; } 7376 else 7377 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7378 $as_echo "no" >&6; } 7379 fi 7380 7381 7382 test -n "$DIRNAME" && break 7383 done 7384 7385 else 7386 # If it succeeded, then it was overridden by the user. We will use it 7387 # for the tool. 7388 7389 # First remove it from the list of overridden variables, so we can test 7390 # for unknown variables in the end. 7391 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 7392 7393 # Check if we try to supply an empty value 7394 if test "x$DIRNAME" = x; then 7395 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DIRNAME= (no value)" >&5 7396 $as_echo "$as_me: Setting user supplied tool DIRNAME= (no value)" >&6;} 7397 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIRNAME" >&5 7398 $as_echo_n "checking for DIRNAME... " >&6; } 7399 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 7400 $as_echo "disabled" >&6; } 7401 else 7402 # Check if the provided tool contains a complete path. 7403 tool_specified="$DIRNAME" 7404 tool_basename="${tool_specified##*/}" 7405 if test "x$tool_basename" = "x$tool_specified"; then 7406 # A command without a complete path is provided, search $PATH. 7407 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DIRNAME=$tool_basename" >&5 7408 $as_echo "$as_me: Will search for user supplied tool DIRNAME=$tool_basename" >&6;} 7409 # Extract the first word of "$tool_basename", so it can be a program name with args. 7410 set dummy $tool_basename; ac_word=$2 7411 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7412 $as_echo_n "checking for $ac_word... " >&6; } 7413 if ${ac_cv_path_DIRNAME+:} false; then : 7414 $as_echo_n "(cached) " >&6 7415 else 7416 case $DIRNAME in 7417 [\\/]* | ?:[\\/]*) 7418 ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path. 7419 ;; 7420 *) 7421 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7422 for as_dir in $PATH 7423 do 7424 IFS=$as_save_IFS 7425 test -z "$as_dir" && as_dir=. 7426 for ac_exec_ext in '' $ac_executable_extensions; do 7427 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7428 ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext" 7429 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7430 break 2 7431 fi 7432 done 7433 done 7434 IFS=$as_save_IFS 7435 7436 ;; 7437 esac 7438 fi 7439 DIRNAME=$ac_cv_path_DIRNAME 7440 if test -n "$DIRNAME"; then 7441 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5 7442 $as_echo "$DIRNAME" >&6; } 7443 else 7444 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7445 $as_echo "no" >&6; } 7446 fi 7447 7448 7449 if test "x$DIRNAME" = x; then 7450 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 7451 fi 7452 else 7453 # Otherwise we believe it is a complete path. Use it as it is. 7454 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DIRNAME=$tool_specified" >&5 7455 $as_echo "$as_me: Will use user supplied tool DIRNAME=$tool_specified" >&6;} 7456 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIRNAME" >&5 7457 $as_echo_n "checking for DIRNAME... " >&6; } 7458 if test ! -x "$tool_specified"; then 7459 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 7460 $as_echo "not found" >&6; } 7461 as_fn_error $? "User supplied tool DIRNAME=$tool_specified does not exist or is not executable" "$LINENO" 5 7462 fi 7463 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 7464 $as_echo "$tool_specified" >&6; } 7465 fi 7466 fi 7467 fi 7468 7469 fi 7470 7471 7472 7473 if test "x$DIRNAME" = x; then 7474 as_fn_error $? "Could not find required tool for DIRNAME" "$LINENO" 5 7475 fi 7476 7477 7478 7479 7480 7481 # Publish this variable in the help. 7482 7483 7484 if [ -z "${ECHO+x}" ]; then 7485 # The variable is not set by user, try to locate tool using the code snippet 7486 for ac_prog in echo 7487 do 7488 # Extract the first word of "$ac_prog", so it can be a program name with args. 7489 set dummy $ac_prog; ac_word=$2 7490 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7491 $as_echo_n "checking for $ac_word... " >&6; } 7492 if ${ac_cv_path_ECHO+:} false; then : 7493 $as_echo_n "(cached) " >&6 7494 else 7495 case $ECHO in 7496 [\\/]* | ?:[\\/]*) 7497 ac_cv_path_ECHO="$ECHO" # Let the user override the test with a path. 7498 ;; 7499 *) 7500 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7501 for as_dir in $PATH 7502 do 7503 IFS=$as_save_IFS 7504 test -z "$as_dir" && as_dir=. 7505 for ac_exec_ext in '' $ac_executable_extensions; do 7506 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7507 ac_cv_path_ECHO="$as_dir/$ac_word$ac_exec_ext" 7508 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7509 break 2 7510 fi 7511 done 7512 done 7513 IFS=$as_save_IFS 7514 7515 ;; 7516 esac 7517 fi 7518 ECHO=$ac_cv_path_ECHO 7519 if test -n "$ECHO"; then 7520 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ECHO" >&5 7521 $as_echo "$ECHO" >&6; } 7522 else 7523 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7524 $as_echo "no" >&6; } 7525 fi 7526 7527 7528 test -n "$ECHO" && break 7529 done 7530 7531 else 7532 # The variable is set, but is it from the command line or the environment? 7533 7534 # Try to remove the string !ECHO! from our list. 7535 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ECHO!/} 7536 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 7537 # If it failed, the variable was not from the command line. Ignore it, 7538 # but warn the user (except for BASH, which is always set by the calling BASH). 7539 if test "xECHO" != xBASH; then 7540 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ECHO from the environment. Use command line variables instead." >&5 7541 $as_echo "$as_me: WARNING: Ignoring value of ECHO from the environment. Use command line variables instead." >&2;} 7542 fi 7543 # Try to locate tool using the code snippet 7544 for ac_prog in echo 7545 do 7546 # Extract the first word of "$ac_prog", so it can be a program name with args. 7547 set dummy $ac_prog; ac_word=$2 7548 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7549 $as_echo_n "checking for $ac_word... " >&6; } 7550 if ${ac_cv_path_ECHO+:} false; then : 7551 $as_echo_n "(cached) " >&6 7552 else 7553 case $ECHO in 7554 [\\/]* | ?:[\\/]*) 7555 ac_cv_path_ECHO="$ECHO" # Let the user override the test with a path. 7556 ;; 7557 *) 7558 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7559 for as_dir in $PATH 7560 do 7561 IFS=$as_save_IFS 7562 test -z "$as_dir" && as_dir=. 7563 for ac_exec_ext in '' $ac_executable_extensions; do 7564 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7565 ac_cv_path_ECHO="$as_dir/$ac_word$ac_exec_ext" 7566 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7567 break 2 7568 fi 7569 done 7570 done 7571 IFS=$as_save_IFS 7572 7573 ;; 7574 esac 7575 fi 7576 ECHO=$ac_cv_path_ECHO 7577 if test -n "$ECHO"; then 7578 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ECHO" >&5 7579 $as_echo "$ECHO" >&6; } 7580 else 7581 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7582 $as_echo "no" >&6; } 7583 fi 7584 7585 7586 test -n "$ECHO" && break 7587 done 7588 7589 else 7590 # If it succeeded, then it was overridden by the user. We will use it 7591 # for the tool. 7592 7593 # First remove it from the list of overridden variables, so we can test 7594 # for unknown variables in the end. 7595 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 7596 7597 # Check if we try to supply an empty value 7598 if test "x$ECHO" = x; then 7599 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ECHO= (no value)" >&5 7600 $as_echo "$as_me: Setting user supplied tool ECHO= (no value)" >&6;} 7601 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ECHO" >&5 7602 $as_echo_n "checking for ECHO... " >&6; } 7603 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 7604 $as_echo "disabled" >&6; } 7605 else 7606 # Check if the provided tool contains a complete path. 7607 tool_specified="$ECHO" 7608 tool_basename="${tool_specified##*/}" 7609 if test "x$tool_basename" = "x$tool_specified"; then 7610 # A command without a complete path is provided, search $PATH. 7611 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ECHO=$tool_basename" >&5 7612 $as_echo "$as_me: Will search for user supplied tool ECHO=$tool_basename" >&6;} 7613 # Extract the first word of "$tool_basename", so it can be a program name with args. 7614 set dummy $tool_basename; ac_word=$2 7615 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7616 $as_echo_n "checking for $ac_word... " >&6; } 7617 if ${ac_cv_path_ECHO+:} false; then : 7618 $as_echo_n "(cached) " >&6 7619 else 7620 case $ECHO in 7621 [\\/]* | ?:[\\/]*) 7622 ac_cv_path_ECHO="$ECHO" # Let the user override the test with a path. 7623 ;; 7624 *) 7625 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7626 for as_dir in $PATH 7627 do 7628 IFS=$as_save_IFS 7629 test -z "$as_dir" && as_dir=. 7630 for ac_exec_ext in '' $ac_executable_extensions; do 7631 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7632 ac_cv_path_ECHO="$as_dir/$ac_word$ac_exec_ext" 7633 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7634 break 2 7635 fi 7636 done 7637 done 7638 IFS=$as_save_IFS 7639 7640 ;; 7641 esac 7642 fi 7643 ECHO=$ac_cv_path_ECHO 7644 if test -n "$ECHO"; then 7645 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ECHO" >&5 7646 $as_echo "$ECHO" >&6; } 7647 else 7648 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7649 $as_echo "no" >&6; } 7650 fi 7651 7652 7653 if test "x$ECHO" = x; then 7654 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 7655 fi 7656 else 7657 # Otherwise we believe it is a complete path. Use it as it is. 7658 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ECHO=$tool_specified" >&5 7659 $as_echo "$as_me: Will use user supplied tool ECHO=$tool_specified" >&6;} 7660 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ECHO" >&5 7661 $as_echo_n "checking for ECHO... " >&6; } 7662 if test ! -x "$tool_specified"; then 7663 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 7664 $as_echo "not found" >&6; } 7665 as_fn_error $? "User supplied tool ECHO=$tool_specified does not exist or is not executable" "$LINENO" 5 7666 fi 7667 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 7668 $as_echo "$tool_specified" >&6; } 7669 fi 7670 fi 7671 fi 7672 7673 fi 7674 7675 7676 7677 if test "x$ECHO" = x; then 7678 as_fn_error $? "Could not find required tool for ECHO" "$LINENO" 5 7679 fi 7680 7681 7682 7683 7684 7685 # Publish this variable in the help. 7686 7687 7688 if [ -z "${EXPR+x}" ]; then 7689 # The variable is not set by user, try to locate tool using the code snippet 7690 for ac_prog in expr 7691 do 7692 # Extract the first word of "$ac_prog", so it can be a program name with args. 7693 set dummy $ac_prog; ac_word=$2 7694 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7695 $as_echo_n "checking for $ac_word... " >&6; } 7696 if ${ac_cv_path_EXPR+:} false; then : 7697 $as_echo_n "(cached) " >&6 7698 else 7699 case $EXPR in 7700 [\\/]* | ?:[\\/]*) 7701 ac_cv_path_EXPR="$EXPR" # Let the user override the test with a path. 7702 ;; 7703 *) 7704 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7705 for as_dir in $PATH 7706 do 7707 IFS=$as_save_IFS 7708 test -z "$as_dir" && as_dir=. 7709 for ac_exec_ext in '' $ac_executable_extensions; do 7710 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7711 ac_cv_path_EXPR="$as_dir/$ac_word$ac_exec_ext" 7712 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7713 break 2 7714 fi 7715 done 7716 done 7717 IFS=$as_save_IFS 7718 7719 ;; 7720 esac 7721 fi 7722 EXPR=$ac_cv_path_EXPR 7723 if test -n "$EXPR"; then 7724 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPR" >&5 7725 $as_echo "$EXPR" >&6; } 7726 else 7727 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7728 $as_echo "no" >&6; } 7729 fi 7730 7731 7732 test -n "$EXPR" && break 7733 done 7734 7735 else 7736 # The variable is set, but is it from the command line or the environment? 7737 7738 # Try to remove the string !EXPR! from our list. 7739 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!EXPR!/} 7740 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 7741 # If it failed, the variable was not from the command line. Ignore it, 7742 # but warn the user (except for BASH, which is always set by the calling BASH). 7743 if test "xEXPR" != xBASH; then 7744 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of EXPR from the environment. Use command line variables instead." >&5 7745 $as_echo "$as_me: WARNING: Ignoring value of EXPR from the environment. Use command line variables instead." >&2;} 7746 fi 7747 # Try to locate tool using the code snippet 7748 for ac_prog in expr 7749 do 7750 # Extract the first word of "$ac_prog", so it can be a program name with args. 7751 set dummy $ac_prog; ac_word=$2 7752 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7753 $as_echo_n "checking for $ac_word... " >&6; } 7754 if ${ac_cv_path_EXPR+:} false; then : 7755 $as_echo_n "(cached) " >&6 7756 else 7757 case $EXPR in 7758 [\\/]* | ?:[\\/]*) 7759 ac_cv_path_EXPR="$EXPR" # Let the user override the test with a path. 7760 ;; 7761 *) 7762 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7763 for as_dir in $PATH 7764 do 7765 IFS=$as_save_IFS 7766 test -z "$as_dir" && as_dir=. 7767 for ac_exec_ext in '' $ac_executable_extensions; do 7768 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7769 ac_cv_path_EXPR="$as_dir/$ac_word$ac_exec_ext" 7770 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7771 break 2 7772 fi 7773 done 7774 done 7775 IFS=$as_save_IFS 7776 7777 ;; 7778 esac 7779 fi 7780 EXPR=$ac_cv_path_EXPR 7781 if test -n "$EXPR"; then 7782 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPR" >&5 7783 $as_echo "$EXPR" >&6; } 7784 else 7785 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7786 $as_echo "no" >&6; } 7787 fi 7788 7789 7790 test -n "$EXPR" && break 7791 done 7792 7793 else 7794 # If it succeeded, then it was overridden by the user. We will use it 7795 # for the tool. 7796 7797 # First remove it from the list of overridden variables, so we can test 7798 # for unknown variables in the end. 7799 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 7800 7801 # Check if we try to supply an empty value 7802 if test "x$EXPR" = x; then 7803 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool EXPR= (no value)" >&5 7804 $as_echo "$as_me: Setting user supplied tool EXPR= (no value)" >&6;} 7805 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EXPR" >&5 7806 $as_echo_n "checking for EXPR... " >&6; } 7807 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 7808 $as_echo "disabled" >&6; } 7809 else 7810 # Check if the provided tool contains a complete path. 7811 tool_specified="$EXPR" 7812 tool_basename="${tool_specified##*/}" 7813 if test "x$tool_basename" = "x$tool_specified"; then 7814 # A command without a complete path is provided, search $PATH. 7815 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool EXPR=$tool_basename" >&5 7816 $as_echo "$as_me: Will search for user supplied tool EXPR=$tool_basename" >&6;} 7817 # Extract the first word of "$tool_basename", so it can be a program name with args. 7818 set dummy $tool_basename; ac_word=$2 7819 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7820 $as_echo_n "checking for $ac_word... " >&6; } 7821 if ${ac_cv_path_EXPR+:} false; then : 7822 $as_echo_n "(cached) " >&6 7823 else 7824 case $EXPR in 7825 [\\/]* | ?:[\\/]*) 7826 ac_cv_path_EXPR="$EXPR" # Let the user override the test with a path. 7827 ;; 7828 *) 7829 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7830 for as_dir in $PATH 7831 do 7832 IFS=$as_save_IFS 7833 test -z "$as_dir" && as_dir=. 7834 for ac_exec_ext in '' $ac_executable_extensions; do 7835 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7836 ac_cv_path_EXPR="$as_dir/$ac_word$ac_exec_ext" 7837 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7838 break 2 7839 fi 7840 done 7841 done 7842 IFS=$as_save_IFS 7843 7844 ;; 7845 esac 7846 fi 7847 EXPR=$ac_cv_path_EXPR 7848 if test -n "$EXPR"; then 7849 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPR" >&5 7850 $as_echo "$EXPR" >&6; } 7851 else 7852 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7853 $as_echo "no" >&6; } 7854 fi 7855 7856 7857 if test "x$EXPR" = x; then 7858 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 7859 fi 7860 else 7861 # Otherwise we believe it is a complete path. Use it as it is. 7862 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool EXPR=$tool_specified" >&5 7863 $as_echo "$as_me: Will use user supplied tool EXPR=$tool_specified" >&6;} 7864 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EXPR" >&5 7865 $as_echo_n "checking for EXPR... " >&6; } 7866 if test ! -x "$tool_specified"; then 7867 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 7868 $as_echo "not found" >&6; } 7869 as_fn_error $? "User supplied tool EXPR=$tool_specified does not exist or is not executable" "$LINENO" 5 7870 fi 7871 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 7872 $as_echo "$tool_specified" >&6; } 7873 fi 7874 fi 7875 fi 7876 7877 fi 7878 7879 7880 7881 if test "x$EXPR" = x; then 7882 as_fn_error $? "Could not find required tool for EXPR" "$LINENO" 5 7883 fi 7884 7885 7886 7887 7888 7889 # Publish this variable in the help. 7890 7891 7892 if [ -z "${FILE+x}" ]; then 7893 # The variable is not set by user, try to locate tool using the code snippet 7894 for ac_prog in file 7895 do 7896 # Extract the first word of "$ac_prog", so it can be a program name with args. 7897 set dummy $ac_prog; ac_word=$2 7898 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7899 $as_echo_n "checking for $ac_word... " >&6; } 7900 if ${ac_cv_path_FILE+:} false; then : 7901 $as_echo_n "(cached) " >&6 7902 else 7903 case $FILE in 7904 [\\/]* | ?:[\\/]*) 7905 ac_cv_path_FILE="$FILE" # Let the user override the test with a path. 7906 ;; 7907 *) 7908 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7909 for as_dir in $PATH 7910 do 7911 IFS=$as_save_IFS 7912 test -z "$as_dir" && as_dir=. 7913 for ac_exec_ext in '' $ac_executable_extensions; do 7914 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7915 ac_cv_path_FILE="$as_dir/$ac_word$ac_exec_ext" 7916 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7917 break 2 7918 fi 7919 done 7920 done 7921 IFS=$as_save_IFS 7922 7923 ;; 7924 esac 7925 fi 7926 FILE=$ac_cv_path_FILE 7927 if test -n "$FILE"; then 7928 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILE" >&5 7929 $as_echo "$FILE" >&6; } 7930 else 7931 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7932 $as_echo "no" >&6; } 7933 fi 7934 7935 7936 test -n "$FILE" && break 7937 done 7938 7939 else 7940 # The variable is set, but is it from the command line or the environment? 7941 7942 # Try to remove the string !FILE! from our list. 7943 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FILE!/} 7944 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 7945 # If it failed, the variable was not from the command line. Ignore it, 7946 # but warn the user (except for BASH, which is always set by the calling BASH). 7947 if test "xFILE" != xBASH; then 7948 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FILE from the environment. Use command line variables instead." >&5 7949 $as_echo "$as_me: WARNING: Ignoring value of FILE from the environment. Use command line variables instead." >&2;} 7950 fi 7951 # Try to locate tool using the code snippet 7952 for ac_prog in file 7953 do 7954 # Extract the first word of "$ac_prog", so it can be a program name with args. 7955 set dummy $ac_prog; ac_word=$2 7956 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7957 $as_echo_n "checking for $ac_word... " >&6; } 7958 if ${ac_cv_path_FILE+:} false; then : 7959 $as_echo_n "(cached) " >&6 7960 else 7961 case $FILE in 7962 [\\/]* | ?:[\\/]*) 7963 ac_cv_path_FILE="$FILE" # Let the user override the test with a path. 7964 ;; 7965 *) 7966 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7967 for as_dir in $PATH 7968 do 7969 IFS=$as_save_IFS 7970 test -z "$as_dir" && as_dir=. 7971 for ac_exec_ext in '' $ac_executable_extensions; do 7972 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7973 ac_cv_path_FILE="$as_dir/$ac_word$ac_exec_ext" 7974 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7975 break 2 7976 fi 7977 done 7978 done 7979 IFS=$as_save_IFS 7980 7981 ;; 7982 esac 7983 fi 7984 FILE=$ac_cv_path_FILE 7985 if test -n "$FILE"; then 7986 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILE" >&5 7987 $as_echo "$FILE" >&6; } 7988 else 7989 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7990 $as_echo "no" >&6; } 7991 fi 7992 7993 7994 test -n "$FILE" && break 7995 done 7996 7997 else 7998 # If it succeeded, then it was overridden by the user. We will use it 7999 # for the tool. 8000 8001 # First remove it from the list of overridden variables, so we can test 8002 # for unknown variables in the end. 8003 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 8004 8005 # Check if we try to supply an empty value 8006 if test "x$FILE" = x; then 8007 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool FILE= (no value)" >&5 8008 $as_echo "$as_me: Setting user supplied tool FILE= (no value)" >&6;} 8009 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FILE" >&5 8010 $as_echo_n "checking for FILE... " >&6; } 8011 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 8012 $as_echo "disabled" >&6; } 8013 else 8014 # Check if the provided tool contains a complete path. 8015 tool_specified="$FILE" 8016 tool_basename="${tool_specified##*/}" 8017 if test "x$tool_basename" = "x$tool_specified"; then 8018 # A command without a complete path is provided, search $PATH. 8019 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FILE=$tool_basename" >&5 8020 $as_echo "$as_me: Will search for user supplied tool FILE=$tool_basename" >&6;} 8021 # Extract the first word of "$tool_basename", so it can be a program name with args. 8022 set dummy $tool_basename; ac_word=$2 8023 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8024 $as_echo_n "checking for $ac_word... " >&6; } 8025 if ${ac_cv_path_FILE+:} false; then : 8026 $as_echo_n "(cached) " >&6 8027 else 8028 case $FILE in 8029 [\\/]* | ?:[\\/]*) 8030 ac_cv_path_FILE="$FILE" # Let the user override the test with a path. 8031 ;; 8032 *) 8033 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8034 for as_dir in $PATH 8035 do 8036 IFS=$as_save_IFS 8037 test -z "$as_dir" && as_dir=. 8038 for ac_exec_ext in '' $ac_executable_extensions; do 8039 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8040 ac_cv_path_FILE="$as_dir/$ac_word$ac_exec_ext" 8041 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8042 break 2 8043 fi 8044 done 8045 done 8046 IFS=$as_save_IFS 8047 8048 ;; 8049 esac 8050 fi 8051 FILE=$ac_cv_path_FILE 8052 if test -n "$FILE"; then 8053 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILE" >&5 8054 $as_echo "$FILE" >&6; } 8055 else 8056 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8057 $as_echo "no" >&6; } 8058 fi 8059 8060 8061 if test "x$FILE" = x; then 8062 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 8063 fi 8064 else 8065 # Otherwise we believe it is a complete path. Use it as it is. 8066 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FILE=$tool_specified" >&5 8067 $as_echo "$as_me: Will use user supplied tool FILE=$tool_specified" >&6;} 8068 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FILE" >&5 8069 $as_echo_n "checking for FILE... " >&6; } 8070 if test ! -x "$tool_specified"; then 8071 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 8072 $as_echo "not found" >&6; } 8073 as_fn_error $? "User supplied tool FILE=$tool_specified does not exist or is not executable" "$LINENO" 5 8074 fi 8075 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 8076 $as_echo "$tool_specified" >&6; } 8077 fi 8078 fi 8079 fi 8080 8081 fi 8082 8083 8084 8085 if test "x$FILE" = x; then 8086 as_fn_error $? "Could not find required tool for FILE" "$LINENO" 5 8087 fi 8088 8089 8090 8091 8092 8093 # Publish this variable in the help. 8094 8095 8096 if [ -z "${FIND+x}" ]; then 8097 # The variable is not set by user, try to locate tool using the code snippet 8098 for ac_prog in find 8099 do 8100 # Extract the first word of "$ac_prog", so it can be a program name with args. 8101 set dummy $ac_prog; ac_word=$2 8102 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8103 $as_echo_n "checking for $ac_word... " >&6; } 8104 if ${ac_cv_path_FIND+:} false; then : 8105 $as_echo_n "(cached) " >&6 8106 else 8107 case $FIND in 8108 [\\/]* | ?:[\\/]*) 8109 ac_cv_path_FIND="$FIND" # Let the user override the test with a path. 8110 ;; 8111 *) 8112 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8113 for as_dir in $PATH 8114 do 8115 IFS=$as_save_IFS 8116 test -z "$as_dir" && as_dir=. 8117 for ac_exec_ext in '' $ac_executable_extensions; do 8118 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8119 ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext" 8120 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8121 break 2 8122 fi 8123 done 8124 done 8125 IFS=$as_save_IFS 8126 8127 ;; 8128 esac 8129 fi 8130 FIND=$ac_cv_path_FIND 8131 if test -n "$FIND"; then 8132 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5 8133 $as_echo "$FIND" >&6; } 8134 else 8135 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8136 $as_echo "no" >&6; } 8137 fi 8138 8139 8140 test -n "$FIND" && break 8141 done 8142 8143 else 8144 # The variable is set, but is it from the command line or the environment? 8145 8146 # Try to remove the string !FIND! from our list. 8147 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FIND!/} 8148 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 8149 # If it failed, the variable was not from the command line. Ignore it, 8150 # but warn the user (except for BASH, which is always set by the calling BASH). 8151 if test "xFIND" != xBASH; then 8152 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FIND from the environment. Use command line variables instead." >&5 8153 $as_echo "$as_me: WARNING: Ignoring value of FIND from the environment. Use command line variables instead." >&2;} 8154 fi 8155 # Try to locate tool using the code snippet 8156 for ac_prog in find 8157 do 8158 # Extract the first word of "$ac_prog", so it can be a program name with args. 8159 set dummy $ac_prog; ac_word=$2 8160 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8161 $as_echo_n "checking for $ac_word... " >&6; } 8162 if ${ac_cv_path_FIND+:} false; then : 8163 $as_echo_n "(cached) " >&6 8164 else 8165 case $FIND in 8166 [\\/]* | ?:[\\/]*) 8167 ac_cv_path_FIND="$FIND" # Let the user override the test with a path. 8168 ;; 8169 *) 8170 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8171 for as_dir in $PATH 8172 do 8173 IFS=$as_save_IFS 8174 test -z "$as_dir" && as_dir=. 8175 for ac_exec_ext in '' $ac_executable_extensions; do 8176 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8177 ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext" 8178 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8179 break 2 8180 fi 8181 done 8182 done 8183 IFS=$as_save_IFS 8184 8185 ;; 8186 esac 8187 fi 8188 FIND=$ac_cv_path_FIND 8189 if test -n "$FIND"; then 8190 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5 8191 $as_echo "$FIND" >&6; } 8192 else 8193 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8194 $as_echo "no" >&6; } 8195 fi 8196 8197 8198 test -n "$FIND" && break 8199 done 8200 8201 else 8202 # If it succeeded, then it was overridden by the user. We will use it 8203 # for the tool. 8204 8205 # First remove it from the list of overridden variables, so we can test 8206 # for unknown variables in the end. 8207 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 8208 8209 # Check if we try to supply an empty value 8210 if test "x$FIND" = x; then 8211 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool FIND= (no value)" >&5 8212 $as_echo "$as_me: Setting user supplied tool FIND= (no value)" >&6;} 8213 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FIND" >&5 8214 $as_echo_n "checking for FIND... " >&6; } 8215 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 8216 $as_echo "disabled" >&6; } 8217 else 8218 # Check if the provided tool contains a complete path. 8219 tool_specified="$FIND" 8220 tool_basename="${tool_specified##*/}" 8221 if test "x$tool_basename" = "x$tool_specified"; then 8222 # A command without a complete path is provided, search $PATH. 8223 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FIND=$tool_basename" >&5 8224 $as_echo "$as_me: Will search for user supplied tool FIND=$tool_basename" >&6;} 8225 # Extract the first word of "$tool_basename", so it can be a program name with args. 8226 set dummy $tool_basename; ac_word=$2 8227 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8228 $as_echo_n "checking for $ac_word... " >&6; } 8229 if ${ac_cv_path_FIND+:} false; then : 8230 $as_echo_n "(cached) " >&6 8231 else 8232 case $FIND in 8233 [\\/]* | ?:[\\/]*) 8234 ac_cv_path_FIND="$FIND" # Let the user override the test with a path. 8235 ;; 8236 *) 8237 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8238 for as_dir in $PATH 8239 do 8240 IFS=$as_save_IFS 8241 test -z "$as_dir" && as_dir=. 8242 for ac_exec_ext in '' $ac_executable_extensions; do 8243 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8244 ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext" 8245 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8246 break 2 8247 fi 8248 done 8249 done 8250 IFS=$as_save_IFS 8251 8252 ;; 8253 esac 8254 fi 8255 FIND=$ac_cv_path_FIND 8256 if test -n "$FIND"; then 8257 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5 8258 $as_echo "$FIND" >&6; } 8259 else 8260 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8261 $as_echo "no" >&6; } 8262 fi 8263 8264 8265 if test "x$FIND" = x; then 8266 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 8267 fi 8268 else 8269 # Otherwise we believe it is a complete path. Use it as it is. 8270 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FIND=$tool_specified" >&5 8271 $as_echo "$as_me: Will use user supplied tool FIND=$tool_specified" >&6;} 8272 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FIND" >&5 8273 $as_echo_n "checking for FIND... " >&6; } 8274 if test ! -x "$tool_specified"; then 8275 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 8276 $as_echo "not found" >&6; } 8277 as_fn_error $? "User supplied tool FIND=$tool_specified does not exist or is not executable" "$LINENO" 5 8278 fi 8279 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 8280 $as_echo "$tool_specified" >&6; } 8281 fi 8282 fi 8283 fi 8284 8285 fi 8286 8287 8288 8289 if test "x$FIND" = x; then 8290 as_fn_error $? "Could not find required tool for FIND" "$LINENO" 5 8291 fi 8292 8293 8294 8295 8296 8297 # Publish this variable in the help. 8298 8299 8300 if [ -z "${HEAD+x}" ]; then 8301 # The variable is not set by user, try to locate tool using the code snippet 8302 for ac_prog in head 8303 do 8304 # Extract the first word of "$ac_prog", so it can be a program name with args. 8305 set dummy $ac_prog; ac_word=$2 8306 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8307 $as_echo_n "checking for $ac_word... " >&6; } 8308 if ${ac_cv_path_HEAD+:} false; then : 8309 $as_echo_n "(cached) " >&6 8310 else 8311 case $HEAD in 8312 [\\/]* | ?:[\\/]*) 8313 ac_cv_path_HEAD="$HEAD" # Let the user override the test with a path. 8314 ;; 8315 *) 8316 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8317 for as_dir in $PATH 8318 do 8319 IFS=$as_save_IFS 8320 test -z "$as_dir" && as_dir=. 8321 for ac_exec_ext in '' $ac_executable_extensions; do 8322 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8323 ac_cv_path_HEAD="$as_dir/$ac_word$ac_exec_ext" 8324 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8325 break 2 8326 fi 8327 done 8328 done 8329 IFS=$as_save_IFS 8330 8331 ;; 8332 esac 8333 fi 8334 HEAD=$ac_cv_path_HEAD 8335 if test -n "$HEAD"; then 8336 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HEAD" >&5 8337 $as_echo "$HEAD" >&6; } 8338 else 8339 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8340 $as_echo "no" >&6; } 8341 fi 8342 8343 8344 test -n "$HEAD" && break 8345 done 8346 8347 else 8348 # The variable is set, but is it from the command line or the environment? 8349 8350 # Try to remove the string !HEAD! from our list. 8351 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!HEAD!/} 8352 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 8353 # If it failed, the variable was not from the command line. Ignore it, 8354 # but warn the user (except for BASH, which is always set by the calling BASH). 8355 if test "xHEAD" != xBASH; then 8356 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of HEAD from the environment. Use command line variables instead." >&5 8357 $as_echo "$as_me: WARNING: Ignoring value of HEAD from the environment. Use command line variables instead." >&2;} 8358 fi 8359 # Try to locate tool using the code snippet 8360 for ac_prog in head 8361 do 8362 # Extract the first word of "$ac_prog", so it can be a program name with args. 8363 set dummy $ac_prog; ac_word=$2 8364 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8365 $as_echo_n "checking for $ac_word... " >&6; } 8366 if ${ac_cv_path_HEAD+:} false; then : 8367 $as_echo_n "(cached) " >&6 8368 else 8369 case $HEAD in 8370 [\\/]* | ?:[\\/]*) 8371 ac_cv_path_HEAD="$HEAD" # Let the user override the test with a path. 8372 ;; 8373 *) 8374 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8375 for as_dir in $PATH 8376 do 8377 IFS=$as_save_IFS 8378 test -z "$as_dir" && as_dir=. 8379 for ac_exec_ext in '' $ac_executable_extensions; do 8380 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8381 ac_cv_path_HEAD="$as_dir/$ac_word$ac_exec_ext" 8382 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8383 break 2 8384 fi 8385 done 8386 done 8387 IFS=$as_save_IFS 8388 8389 ;; 8390 esac 8391 fi 8392 HEAD=$ac_cv_path_HEAD 8393 if test -n "$HEAD"; then 8394 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HEAD" >&5 8395 $as_echo "$HEAD" >&6; } 8396 else 8397 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8398 $as_echo "no" >&6; } 8399 fi 8400 8401 8402 test -n "$HEAD" && break 8403 done 8404 8405 else 8406 # If it succeeded, then it was overridden by the user. We will use it 8407 # for the tool. 8408 8409 # First remove it from the list of overridden variables, so we can test 8410 # for unknown variables in the end. 8411 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 8412 8413 # Check if we try to supply an empty value 8414 if test "x$HEAD" = x; then 8415 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool HEAD= (no value)" >&5 8416 $as_echo "$as_me: Setting user supplied tool HEAD= (no value)" >&6;} 8417 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HEAD" >&5 8418 $as_echo_n "checking for HEAD... " >&6; } 8419 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 8420 $as_echo "disabled" >&6; } 8421 else 8422 # Check if the provided tool contains a complete path. 8423 tool_specified="$HEAD" 8424 tool_basename="${tool_specified##*/}" 8425 if test "x$tool_basename" = "x$tool_specified"; then 8426 # A command without a complete path is provided, search $PATH. 8427 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool HEAD=$tool_basename" >&5 8428 $as_echo "$as_me: Will search for user supplied tool HEAD=$tool_basename" >&6;} 8429 # Extract the first word of "$tool_basename", so it can be a program name with args. 8430 set dummy $tool_basename; ac_word=$2 8431 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8432 $as_echo_n "checking for $ac_word... " >&6; } 8433 if ${ac_cv_path_HEAD+:} false; then : 8434 $as_echo_n "(cached) " >&6 8435 else 8436 case $HEAD in 8437 [\\/]* | ?:[\\/]*) 8438 ac_cv_path_HEAD="$HEAD" # Let the user override the test with a path. 8439 ;; 8440 *) 8441 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8442 for as_dir in $PATH 8443 do 8444 IFS=$as_save_IFS 8445 test -z "$as_dir" && as_dir=. 8446 for ac_exec_ext in '' $ac_executable_extensions; do 8447 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8448 ac_cv_path_HEAD="$as_dir/$ac_word$ac_exec_ext" 8449 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8450 break 2 8451 fi 8452 done 8453 done 8454 IFS=$as_save_IFS 8455 8456 ;; 8457 esac 8458 fi 8459 HEAD=$ac_cv_path_HEAD 8460 if test -n "$HEAD"; then 8461 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HEAD" >&5 8462 $as_echo "$HEAD" >&6; } 8463 else 8464 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8465 $as_echo "no" >&6; } 8466 fi 8467 8468 8469 if test "x$HEAD" = x; then 8470 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 8471 fi 8472 else 8473 # Otherwise we believe it is a complete path. Use it as it is. 8474 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool HEAD=$tool_specified" >&5 8475 $as_echo "$as_me: Will use user supplied tool HEAD=$tool_specified" >&6;} 8476 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HEAD" >&5 8477 $as_echo_n "checking for HEAD... " >&6; } 8478 if test ! -x "$tool_specified"; then 8479 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 8480 $as_echo "not found" >&6; } 8481 as_fn_error $? "User supplied tool HEAD=$tool_specified does not exist or is not executable" "$LINENO" 5 8482 fi 8483 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 8484 $as_echo "$tool_specified" >&6; } 8485 fi 8486 fi 8487 fi 8488 8489 fi 8490 8491 8492 8493 if test "x$HEAD" = x; then 8494 as_fn_error $? "Could not find required tool for HEAD" "$LINENO" 5 8495 fi 8496 8497 8498 8499 8500 8501 # Publish this variable in the help. 8502 8503 8504 if [ -z "${GUNZIP+x}" ]; then 8505 # The variable is not set by user, try to locate tool using the code snippet 8506 for ac_prog in gunzip 8507 do 8508 # Extract the first word of "$ac_prog", so it can be a program name with args. 8509 set dummy $ac_prog; ac_word=$2 8510 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8511 $as_echo_n "checking for $ac_word... " >&6; } 8512 if ${ac_cv_path_GUNZIP+:} false; then : 8513 $as_echo_n "(cached) " >&6 8514 else 8515 case $GUNZIP in 8516 [\\/]* | ?:[\\/]*) 8517 ac_cv_path_GUNZIP="$GUNZIP" # Let the user override the test with a path. 8518 ;; 8519 *) 8520 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8521 for as_dir in $PATH 8522 do 8523 IFS=$as_save_IFS 8524 test -z "$as_dir" && as_dir=. 8525 for ac_exec_ext in '' $ac_executable_extensions; do 8526 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8527 ac_cv_path_GUNZIP="$as_dir/$ac_word$ac_exec_ext" 8528 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8529 break 2 8530 fi 8531 done 8532 done 8533 IFS=$as_save_IFS 8534 8535 ;; 8536 esac 8537 fi 8538 GUNZIP=$ac_cv_path_GUNZIP 8539 if test -n "$GUNZIP"; then 8540 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GUNZIP" >&5 8541 $as_echo "$GUNZIP" >&6; } 8542 else 8543 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8544 $as_echo "no" >&6; } 8545 fi 8546 8547 8548 test -n "$GUNZIP" && break 8549 done 8550 8551 else 8552 # The variable is set, but is it from the command line or the environment? 8553 8554 # Try to remove the string !GUNZIP! from our list. 8555 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!GUNZIP!/} 8556 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 8557 # If it failed, the variable was not from the command line. Ignore it, 8558 # but warn the user (except for BASH, which is always set by the calling BASH). 8559 if test "xGUNZIP" != xBASH; then 8560 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of GUNZIP from the environment. Use command line variables instead." >&5 8561 $as_echo "$as_me: WARNING: Ignoring value of GUNZIP from the environment. Use command line variables instead." >&2;} 8562 fi 8563 # Try to locate tool using the code snippet 8564 for ac_prog in gunzip 8565 do 8566 # Extract the first word of "$ac_prog", so it can be a program name with args. 8567 set dummy $ac_prog; ac_word=$2 8568 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8569 $as_echo_n "checking for $ac_word... " >&6; } 8570 if ${ac_cv_path_GUNZIP+:} false; then : 8571 $as_echo_n "(cached) " >&6 8572 else 8573 case $GUNZIP in 8574 [\\/]* | ?:[\\/]*) 8575 ac_cv_path_GUNZIP="$GUNZIP" # Let the user override the test with a path. 8576 ;; 8577 *) 8578 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8579 for as_dir in $PATH 8580 do 8581 IFS=$as_save_IFS 8582 test -z "$as_dir" && as_dir=. 8583 for ac_exec_ext in '' $ac_executable_extensions; do 8584 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8585 ac_cv_path_GUNZIP="$as_dir/$ac_word$ac_exec_ext" 8586 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8587 break 2 8588 fi 8589 done 8590 done 8591 IFS=$as_save_IFS 8592 8593 ;; 8594 esac 8595 fi 8596 GUNZIP=$ac_cv_path_GUNZIP 8597 if test -n "$GUNZIP"; then 8598 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GUNZIP" >&5 8599 $as_echo "$GUNZIP" >&6; } 8600 else 8601 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8602 $as_echo "no" >&6; } 8603 fi 8604 8605 8606 test -n "$GUNZIP" && break 8607 done 8608 8609 else 8610 # If it succeeded, then it was overridden by the user. We will use it 8611 # for the tool. 8612 8613 # First remove it from the list of overridden variables, so we can test 8614 # for unknown variables in the end. 8615 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 8616 8617 # Check if we try to supply an empty value 8618 if test "x$GUNZIP" = x; then 8619 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool GUNZIP= (no value)" >&5 8620 $as_echo "$as_me: Setting user supplied tool GUNZIP= (no value)" >&6;} 8621 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GUNZIP" >&5 8622 $as_echo_n "checking for GUNZIP... " >&6; } 8623 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 8624 $as_echo "disabled" >&6; } 8625 else 8626 # Check if the provided tool contains a complete path. 8627 tool_specified="$GUNZIP" 8628 tool_basename="${tool_specified##*/}" 8629 if test "x$tool_basename" = "x$tool_specified"; then 8630 # A command without a complete path is provided, search $PATH. 8631 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool GUNZIP=$tool_basename" >&5 8632 $as_echo "$as_me: Will search for user supplied tool GUNZIP=$tool_basename" >&6;} 8633 # Extract the first word of "$tool_basename", so it can be a program name with args. 8634 set dummy $tool_basename; ac_word=$2 8635 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8636 $as_echo_n "checking for $ac_word... " >&6; } 8637 if ${ac_cv_path_GUNZIP+:} false; then : 8638 $as_echo_n "(cached) " >&6 8639 else 8640 case $GUNZIP in 8641 [\\/]* | ?:[\\/]*) 8642 ac_cv_path_GUNZIP="$GUNZIP" # Let the user override the test with a path. 8643 ;; 8644 *) 8645 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8646 for as_dir in $PATH 8647 do 8648 IFS=$as_save_IFS 8649 test -z "$as_dir" && as_dir=. 8650 for ac_exec_ext in '' $ac_executable_extensions; do 8651 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8652 ac_cv_path_GUNZIP="$as_dir/$ac_word$ac_exec_ext" 8653 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8654 break 2 8655 fi 8656 done 8657 done 8658 IFS=$as_save_IFS 8659 8660 ;; 8661 esac 8662 fi 8663 GUNZIP=$ac_cv_path_GUNZIP 8664 if test -n "$GUNZIP"; then 8665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GUNZIP" >&5 8666 $as_echo "$GUNZIP" >&6; } 8667 else 8668 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8669 $as_echo "no" >&6; } 8670 fi 8671 8672 8673 if test "x$GUNZIP" = x; then 8674 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 8675 fi 8676 else 8677 # Otherwise we believe it is a complete path. Use it as it is. 8678 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool GUNZIP=$tool_specified" >&5 8679 $as_echo "$as_me: Will use user supplied tool GUNZIP=$tool_specified" >&6;} 8680 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GUNZIP" >&5 8681 $as_echo_n "checking for GUNZIP... " >&6; } 8682 if test ! -x "$tool_specified"; then 8683 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 8684 $as_echo "not found" >&6; } 8685 as_fn_error $? "User supplied tool GUNZIP=$tool_specified does not exist or is not executable" "$LINENO" 5 8686 fi 8687 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 8688 $as_echo "$tool_specified" >&6; } 8689 fi 8690 fi 8691 fi 8692 8693 fi 8694 8695 8696 8697 if test "x$GUNZIP" = x; then 8698 as_fn_error $? "Could not find required tool for GUNZIP" "$LINENO" 5 8699 fi 8700 8701 8702 8703 8704 8705 # Publish this variable in the help. 8706 8707 8708 if [ -z "${GZIP+x}" ]; then 8709 # The variable is not set by user, try to locate tool using the code snippet 8710 for ac_prog in pigz gzip 8711 do 8712 # Extract the first word of "$ac_prog", so it can be a program name with args. 8713 set dummy $ac_prog; ac_word=$2 8714 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8715 $as_echo_n "checking for $ac_word... " >&6; } 8716 if ${ac_cv_path_GZIP+:} false; then : 8717 $as_echo_n "(cached) " >&6 8718 else 8719 case $GZIP in 8720 [\\/]* | ?:[\\/]*) 8721 ac_cv_path_GZIP="$GZIP" # Let the user override the test with a path. 8722 ;; 8723 *) 8724 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8725 for as_dir in $PATH 8726 do 8727 IFS=$as_save_IFS 8728 test -z "$as_dir" && as_dir=. 8729 for ac_exec_ext in '' $ac_executable_extensions; do 8730 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8731 ac_cv_path_GZIP="$as_dir/$ac_word$ac_exec_ext" 8732 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8733 break 2 8734 fi 8735 done 8736 done 8737 IFS=$as_save_IFS 8738 8739 ;; 8740 esac 8741 fi 8742 GZIP=$ac_cv_path_GZIP 8743 if test -n "$GZIP"; then 8744 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP" >&5 8745 $as_echo "$GZIP" >&6; } 8746 else 8747 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8748 $as_echo "no" >&6; } 8749 fi 8750 8751 8752 test -n "$GZIP" && break 8753 done 8754 8755 else 8756 # The variable is set, but is it from the command line or the environment? 8757 8758 # Try to remove the string !GZIP! from our list. 8759 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!GZIP!/} 8760 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 8761 # If it failed, the variable was not from the command line. Ignore it, 8762 # but warn the user (except for BASH, which is always set by the calling BASH). 8763 if test "xGZIP" != xBASH; then 8764 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of GZIP from the environment. Use command line variables instead." >&5 8765 $as_echo "$as_me: WARNING: Ignoring value of GZIP from the environment. Use command line variables instead." >&2;} 8766 fi 8767 # Try to locate tool using the code snippet 8768 for ac_prog in pigz gzip 8769 do 8770 # Extract the first word of "$ac_prog", so it can be a program name with args. 8771 set dummy $ac_prog; ac_word=$2 8772 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8773 $as_echo_n "checking for $ac_word... " >&6; } 8774 if ${ac_cv_path_GZIP+:} false; then : 8775 $as_echo_n "(cached) " >&6 8776 else 8777 case $GZIP in 8778 [\\/]* | ?:[\\/]*) 8779 ac_cv_path_GZIP="$GZIP" # Let the user override the test with a path. 8780 ;; 8781 *) 8782 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8783 for as_dir in $PATH 8784 do 8785 IFS=$as_save_IFS 8786 test -z "$as_dir" && as_dir=. 8787 for ac_exec_ext in '' $ac_executable_extensions; do 8788 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8789 ac_cv_path_GZIP="$as_dir/$ac_word$ac_exec_ext" 8790 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8791 break 2 8792 fi 8793 done 8794 done 8795 IFS=$as_save_IFS 8796 8797 ;; 8798 esac 8799 fi 8800 GZIP=$ac_cv_path_GZIP 8801 if test -n "$GZIP"; then 8802 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP" >&5 8803 $as_echo "$GZIP" >&6; } 8804 else 8805 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8806 $as_echo "no" >&6; } 8807 fi 8808 8809 8810 test -n "$GZIP" && break 8811 done 8812 8813 else 8814 # If it succeeded, then it was overridden by the user. We will use it 8815 # for the tool. 8816 8817 # First remove it from the list of overridden variables, so we can test 8818 # for unknown variables in the end. 8819 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 8820 8821 # Check if we try to supply an empty value 8822 if test "x$GZIP" = x; then 8823 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool GZIP= (no value)" >&5 8824 $as_echo "$as_me: Setting user supplied tool GZIP= (no value)" >&6;} 8825 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GZIP" >&5 8826 $as_echo_n "checking for GZIP... " >&6; } 8827 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 8828 $as_echo "disabled" >&6; } 8829 else 8830 # Check if the provided tool contains a complete path. 8831 tool_specified="$GZIP" 8832 tool_basename="${tool_specified##*/}" 8833 if test "x$tool_basename" = "x$tool_specified"; then 8834 # A command without a complete path is provided, search $PATH. 8835 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool GZIP=$tool_basename" >&5 8836 $as_echo "$as_me: Will search for user supplied tool GZIP=$tool_basename" >&6;} 8837 # Extract the first word of "$tool_basename", so it can be a program name with args. 8838 set dummy $tool_basename; ac_word=$2 8839 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8840 $as_echo_n "checking for $ac_word... " >&6; } 8841 if ${ac_cv_path_GZIP+:} false; then : 8842 $as_echo_n "(cached) " >&6 8843 else 8844 case $GZIP in 8845 [\\/]* | ?:[\\/]*) 8846 ac_cv_path_GZIP="$GZIP" # Let the user override the test with a path. 8847 ;; 8848 *) 8849 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8850 for as_dir in $PATH 8851 do 8852 IFS=$as_save_IFS 8853 test -z "$as_dir" && as_dir=. 8854 for ac_exec_ext in '' $ac_executable_extensions; do 8855 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8856 ac_cv_path_GZIP="$as_dir/$ac_word$ac_exec_ext" 8857 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8858 break 2 8859 fi 8860 done 8861 done 8862 IFS=$as_save_IFS 8863 8864 ;; 8865 esac 8866 fi 8867 GZIP=$ac_cv_path_GZIP 8868 if test -n "$GZIP"; then 8869 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP" >&5 8870 $as_echo "$GZIP" >&6; } 8871 else 8872 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8873 $as_echo "no" >&6; } 8874 fi 8875 8876 8877 if test "x$GZIP" = x; then 8878 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 8879 fi 8880 else 8881 # Otherwise we believe it is a complete path. Use it as it is. 8882 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool GZIP=$tool_specified" >&5 8883 $as_echo "$as_me: Will use user supplied tool GZIP=$tool_specified" >&6;} 8884 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GZIP" >&5 8885 $as_echo_n "checking for GZIP... " >&6; } 8886 if test ! -x "$tool_specified"; then 8887 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 8888 $as_echo "not found" >&6; } 8889 as_fn_error $? "User supplied tool GZIP=$tool_specified does not exist or is not executable" "$LINENO" 5 8890 fi 8891 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 8892 $as_echo "$tool_specified" >&6; } 8893 fi 8894 fi 8895 fi 8896 8897 fi 8898 8899 8900 8901 if test "x$GZIP" = x; then 8902 as_fn_error $? "Could not find required tool for GZIP" "$LINENO" 5 8903 fi 8904 8905 8906 8907 8908 8909 # Publish this variable in the help. 8910 8911 8912 if [ -z "${LN+x}" ]; then 8913 # The variable is not set by user, try to locate tool using the code snippet 8914 for ac_prog in ln 8915 do 8916 # Extract the first word of "$ac_prog", so it can be a program name with args. 8917 set dummy $ac_prog; ac_word=$2 8918 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8919 $as_echo_n "checking for $ac_word... " >&6; } 8920 if ${ac_cv_path_LN+:} false; then : 8921 $as_echo_n "(cached) " >&6 8922 else 8923 case $LN in 8924 [\\/]* | ?:[\\/]*) 8925 ac_cv_path_LN="$LN" # Let the user override the test with a path. 8926 ;; 8927 *) 8928 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8929 for as_dir in $PATH 8930 do 8931 IFS=$as_save_IFS 8932 test -z "$as_dir" && as_dir=. 8933 for ac_exec_ext in '' $ac_executable_extensions; do 8934 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8935 ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext" 8936 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8937 break 2 8938 fi 8939 done 8940 done 8941 IFS=$as_save_IFS 8942 8943 ;; 8944 esac 8945 fi 8946 LN=$ac_cv_path_LN 8947 if test -n "$LN"; then 8948 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5 8949 $as_echo "$LN" >&6; } 8950 else 8951 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8952 $as_echo "no" >&6; } 8953 fi 8954 8955 8956 test -n "$LN" && break 8957 done 8958 8959 else 8960 # The variable is set, but is it from the command line or the environment? 8961 8962 # Try to remove the string !LN! from our list. 8963 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LN!/} 8964 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 8965 # If it failed, the variable was not from the command line. Ignore it, 8966 # but warn the user (except for BASH, which is always set by the calling BASH). 8967 if test "xLN" != xBASH; then 8968 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LN from the environment. Use command line variables instead." >&5 8969 $as_echo "$as_me: WARNING: Ignoring value of LN from the environment. Use command line variables instead." >&2;} 8970 fi 8971 # Try to locate tool using the code snippet 8972 for ac_prog in ln 8973 do 8974 # Extract the first word of "$ac_prog", so it can be a program name with args. 8975 set dummy $ac_prog; ac_word=$2 8976 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8977 $as_echo_n "checking for $ac_word... " >&6; } 8978 if ${ac_cv_path_LN+:} false; then : 8979 $as_echo_n "(cached) " >&6 8980 else 8981 case $LN in 8982 [\\/]* | ?:[\\/]*) 8983 ac_cv_path_LN="$LN" # Let the user override the test with a path. 8984 ;; 8985 *) 8986 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8987 for as_dir in $PATH 8988 do 8989 IFS=$as_save_IFS 8990 test -z "$as_dir" && as_dir=. 8991 for ac_exec_ext in '' $ac_executable_extensions; do 8992 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8993 ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext" 8994 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8995 break 2 8996 fi 8997 done 8998 done 8999 IFS=$as_save_IFS 9000 9001 ;; 9002 esac 9003 fi 9004 LN=$ac_cv_path_LN 9005 if test -n "$LN"; then 9006 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5 9007 $as_echo "$LN" >&6; } 9008 else 9009 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9010 $as_echo "no" >&6; } 9011 fi 9012 9013 9014 test -n "$LN" && break 9015 done 9016 9017 else 9018 # If it succeeded, then it was overridden by the user. We will use it 9019 # for the tool. 9020 9021 # First remove it from the list of overridden variables, so we can test 9022 # for unknown variables in the end. 9023 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 9024 9025 # Check if we try to supply an empty value 9026 if test "x$LN" = x; then 9027 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool LN= (no value)" >&5 9028 $as_echo "$as_me: Setting user supplied tool LN= (no value)" >&6;} 9029 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LN" >&5 9030 $as_echo_n "checking for LN... " >&6; } 9031 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 9032 $as_echo "disabled" >&6; } 9033 else 9034 # Check if the provided tool contains a complete path. 9035 tool_specified="$LN" 9036 tool_basename="${tool_specified##*/}" 9037 if test "x$tool_basename" = "x$tool_specified"; then 9038 # A command without a complete path is provided, search $PATH. 9039 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LN=$tool_basename" >&5 9040 $as_echo "$as_me: Will search for user supplied tool LN=$tool_basename" >&6;} 9041 # Extract the first word of "$tool_basename", so it can be a program name with args. 9042 set dummy $tool_basename; ac_word=$2 9043 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9044 $as_echo_n "checking for $ac_word... " >&6; } 9045 if ${ac_cv_path_LN+:} false; then : 9046 $as_echo_n "(cached) " >&6 9047 else 9048 case $LN in 9049 [\\/]* | ?:[\\/]*) 9050 ac_cv_path_LN="$LN" # Let the user override the test with a path. 9051 ;; 9052 *) 9053 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9054 for as_dir in $PATH 9055 do 9056 IFS=$as_save_IFS 9057 test -z "$as_dir" && as_dir=. 9058 for ac_exec_ext in '' $ac_executable_extensions; do 9059 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9060 ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext" 9061 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9062 break 2 9063 fi 9064 done 9065 done 9066 IFS=$as_save_IFS 9067 9068 ;; 9069 esac 9070 fi 9071 LN=$ac_cv_path_LN 9072 if test -n "$LN"; then 9073 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5 9074 $as_echo "$LN" >&6; } 9075 else 9076 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9077 $as_echo "no" >&6; } 9078 fi 9079 9080 9081 if test "x$LN" = x; then 9082 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 9083 fi 9084 else 9085 # Otherwise we believe it is a complete path. Use it as it is. 9086 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LN=$tool_specified" >&5 9087 $as_echo "$as_me: Will use user supplied tool LN=$tool_specified" >&6;} 9088 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LN" >&5 9089 $as_echo_n "checking for LN... " >&6; } 9090 if test ! -x "$tool_specified"; then 9091 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 9092 $as_echo "not found" >&6; } 9093 as_fn_error $? "User supplied tool LN=$tool_specified does not exist or is not executable" "$LINENO" 5 9094 fi 9095 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 9096 $as_echo "$tool_specified" >&6; } 9097 fi 9098 fi 9099 fi 9100 9101 fi 9102 9103 9104 9105 if test "x$LN" = x; then 9106 as_fn_error $? "Could not find required tool for LN" "$LINENO" 5 9107 fi 9108 9109 9110 9111 9112 9113 # Publish this variable in the help. 9114 9115 9116 if [ -z "${LS+x}" ]; then 9117 # The variable is not set by user, try to locate tool using the code snippet 9118 for ac_prog in ls 9119 do 9120 # Extract the first word of "$ac_prog", so it can be a program name with args. 9121 set dummy $ac_prog; ac_word=$2 9122 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9123 $as_echo_n "checking for $ac_word... " >&6; } 9124 if ${ac_cv_path_LS+:} false; then : 9125 $as_echo_n "(cached) " >&6 9126 else 9127 case $LS in 9128 [\\/]* | ?:[\\/]*) 9129 ac_cv_path_LS="$LS" # Let the user override the test with a path. 9130 ;; 9131 *) 9132 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9133 for as_dir in $PATH 9134 do 9135 IFS=$as_save_IFS 9136 test -z "$as_dir" && as_dir=. 9137 for ac_exec_ext in '' $ac_executable_extensions; do 9138 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9139 ac_cv_path_LS="$as_dir/$ac_word$ac_exec_ext" 9140 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9141 break 2 9142 fi 9143 done 9144 done 9145 IFS=$as_save_IFS 9146 9147 ;; 9148 esac 9149 fi 9150 LS=$ac_cv_path_LS 9151 if test -n "$LS"; then 9152 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LS" >&5 9153 $as_echo "$LS" >&6; } 9154 else 9155 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9156 $as_echo "no" >&6; } 9157 fi 9158 9159 9160 test -n "$LS" && break 9161 done 9162 9163 else 9164 # The variable is set, but is it from the command line or the environment? 9165 9166 # Try to remove the string !LS! from our list. 9167 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LS!/} 9168 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 9169 # If it failed, the variable was not from the command line. Ignore it, 9170 # but warn the user (except for BASH, which is always set by the calling BASH). 9171 if test "xLS" != xBASH; then 9172 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LS from the environment. Use command line variables instead." >&5 9173 $as_echo "$as_me: WARNING: Ignoring value of LS from the environment. Use command line variables instead." >&2;} 9174 fi 9175 # Try to locate tool using the code snippet 9176 for ac_prog in ls 9177 do 9178 # Extract the first word of "$ac_prog", so it can be a program name with args. 9179 set dummy $ac_prog; ac_word=$2 9180 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9181 $as_echo_n "checking for $ac_word... " >&6; } 9182 if ${ac_cv_path_LS+:} false; then : 9183 $as_echo_n "(cached) " >&6 9184 else 9185 case $LS in 9186 [\\/]* | ?:[\\/]*) 9187 ac_cv_path_LS="$LS" # Let the user override the test with a path. 9188 ;; 9189 *) 9190 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9191 for as_dir in $PATH 9192 do 9193 IFS=$as_save_IFS 9194 test -z "$as_dir" && as_dir=. 9195 for ac_exec_ext in '' $ac_executable_extensions; do 9196 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9197 ac_cv_path_LS="$as_dir/$ac_word$ac_exec_ext" 9198 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9199 break 2 9200 fi 9201 done 9202 done 9203 IFS=$as_save_IFS 9204 9205 ;; 9206 esac 9207 fi 9208 LS=$ac_cv_path_LS 9209 if test -n "$LS"; then 9210 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LS" >&5 9211 $as_echo "$LS" >&6; } 9212 else 9213 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9214 $as_echo "no" >&6; } 9215 fi 9216 9217 9218 test -n "$LS" && break 9219 done 9220 9221 else 9222 # If it succeeded, then it was overridden by the user. We will use it 9223 # for the tool. 9224 9225 # First remove it from the list of overridden variables, so we can test 9226 # for unknown variables in the end. 9227 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 9228 9229 # Check if we try to supply an empty value 9230 if test "x$LS" = x; then 9231 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool LS= (no value)" >&5 9232 $as_echo "$as_me: Setting user supplied tool LS= (no value)" >&6;} 9233 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LS" >&5 9234 $as_echo_n "checking for LS... " >&6; } 9235 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 9236 $as_echo "disabled" >&6; } 9237 else 9238 # Check if the provided tool contains a complete path. 9239 tool_specified="$LS" 9240 tool_basename="${tool_specified##*/}" 9241 if test "x$tool_basename" = "x$tool_specified"; then 9242 # A command without a complete path is provided, search $PATH. 9243 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LS=$tool_basename" >&5 9244 $as_echo "$as_me: Will search for user supplied tool LS=$tool_basename" >&6;} 9245 # Extract the first word of "$tool_basename", so it can be a program name with args. 9246 set dummy $tool_basename; ac_word=$2 9247 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9248 $as_echo_n "checking for $ac_word... " >&6; } 9249 if ${ac_cv_path_LS+:} false; then : 9250 $as_echo_n "(cached) " >&6 9251 else 9252 case $LS in 9253 [\\/]* | ?:[\\/]*) 9254 ac_cv_path_LS="$LS" # Let the user override the test with a path. 9255 ;; 9256 *) 9257 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9258 for as_dir in $PATH 9259 do 9260 IFS=$as_save_IFS 9261 test -z "$as_dir" && as_dir=. 9262 for ac_exec_ext in '' $ac_executable_extensions; do 9263 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9264 ac_cv_path_LS="$as_dir/$ac_word$ac_exec_ext" 9265 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9266 break 2 9267 fi 9268 done 9269 done 9270 IFS=$as_save_IFS 9271 9272 ;; 9273 esac 9274 fi 9275 LS=$ac_cv_path_LS 9276 if test -n "$LS"; then 9277 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LS" >&5 9278 $as_echo "$LS" >&6; } 9279 else 9280 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9281 $as_echo "no" >&6; } 9282 fi 9283 9284 9285 if test "x$LS" = x; then 9286 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 9287 fi 9288 else 9289 # Otherwise we believe it is a complete path. Use it as it is. 9290 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LS=$tool_specified" >&5 9291 $as_echo "$as_me: Will use user supplied tool LS=$tool_specified" >&6;} 9292 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LS" >&5 9293 $as_echo_n "checking for LS... " >&6; } 9294 if test ! -x "$tool_specified"; then 9295 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 9296 $as_echo "not found" >&6; } 9297 as_fn_error $? "User supplied tool LS=$tool_specified does not exist or is not executable" "$LINENO" 5 9298 fi 9299 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 9300 $as_echo "$tool_specified" >&6; } 9301 fi 9302 fi 9303 fi 9304 9305 fi 9306 9307 9308 9309 if test "x$LS" = x; then 9310 as_fn_error $? "Could not find required tool for LS" "$LINENO" 5 9311 fi 9312 9313 9314 9315 9316 9317 # Publish this variable in the help. 9318 9319 9320 if [ -z "${MKDIR+x}" ]; then 9321 # The variable is not set by user, try to locate tool using the code snippet 9322 for ac_prog in mkdir 9323 do 9324 # Extract the first word of "$ac_prog", so it can be a program name with args. 9325 set dummy $ac_prog; ac_word=$2 9326 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9327 $as_echo_n "checking for $ac_word... " >&6; } 9328 if ${ac_cv_path_MKDIR+:} false; then : 9329 $as_echo_n "(cached) " >&6 9330 else 9331 case $MKDIR in 9332 [\\/]* | ?:[\\/]*) 9333 ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path. 9334 ;; 9335 *) 9336 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9337 for as_dir in $PATH 9338 do 9339 IFS=$as_save_IFS 9340 test -z "$as_dir" && as_dir=. 9341 for ac_exec_ext in '' $ac_executable_extensions; do 9342 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9343 ac_cv_path_MKDIR="$as_dir/$ac_word$ac_exec_ext" 9344 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9345 break 2 9346 fi 9347 done 9348 done 9349 IFS=$as_save_IFS 9350 9351 ;; 9352 esac 9353 fi 9354 MKDIR=$ac_cv_path_MKDIR 9355 if test -n "$MKDIR"; then 9356 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR" >&5 9357 $as_echo "$MKDIR" >&6; } 9358 else 9359 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9360 $as_echo "no" >&6; } 9361 fi 9362 9363 9364 test -n "$MKDIR" && break 9365 done 9366 9367 else 9368 # The variable is set, but is it from the command line or the environment? 9369 9370 # Try to remove the string !MKDIR! from our list. 9371 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MKDIR!/} 9372 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 9373 # If it failed, the variable was not from the command line. Ignore it, 9374 # but warn the user (except for BASH, which is always set by the calling BASH). 9375 if test "xMKDIR" != xBASH; then 9376 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MKDIR from the environment. Use command line variables instead." >&5 9377 $as_echo "$as_me: WARNING: Ignoring value of MKDIR from the environment. Use command line variables instead." >&2;} 9378 fi 9379 # Try to locate tool using the code snippet 9380 for ac_prog in mkdir 9381 do 9382 # Extract the first word of "$ac_prog", so it can be a program name with args. 9383 set dummy $ac_prog; ac_word=$2 9384 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9385 $as_echo_n "checking for $ac_word... " >&6; } 9386 if ${ac_cv_path_MKDIR+:} false; then : 9387 $as_echo_n "(cached) " >&6 9388 else 9389 case $MKDIR in 9390 [\\/]* | ?:[\\/]*) 9391 ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path. 9392 ;; 9393 *) 9394 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9395 for as_dir in $PATH 9396 do 9397 IFS=$as_save_IFS 9398 test -z "$as_dir" && as_dir=. 9399 for ac_exec_ext in '' $ac_executable_extensions; do 9400 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9401 ac_cv_path_MKDIR="$as_dir/$ac_word$ac_exec_ext" 9402 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9403 break 2 9404 fi 9405 done 9406 done 9407 IFS=$as_save_IFS 9408 9409 ;; 9410 esac 9411 fi 9412 MKDIR=$ac_cv_path_MKDIR 9413 if test -n "$MKDIR"; then 9414 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR" >&5 9415 $as_echo "$MKDIR" >&6; } 9416 else 9417 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9418 $as_echo "no" >&6; } 9419 fi 9420 9421 9422 test -n "$MKDIR" && break 9423 done 9424 9425 else 9426 # If it succeeded, then it was overridden by the user. We will use it 9427 # for the tool. 9428 9429 # First remove it from the list of overridden variables, so we can test 9430 # for unknown variables in the end. 9431 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 9432 9433 # Check if we try to supply an empty value 9434 if test "x$MKDIR" = x; then 9435 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool MKDIR= (no value)" >&5 9436 $as_echo "$as_me: Setting user supplied tool MKDIR= (no value)" >&6;} 9437 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKDIR" >&5 9438 $as_echo_n "checking for MKDIR... " >&6; } 9439 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 9440 $as_echo "disabled" >&6; } 9441 else 9442 # Check if the provided tool contains a complete path. 9443 tool_specified="$MKDIR" 9444 tool_basename="${tool_specified##*/}" 9445 if test "x$tool_basename" = "x$tool_specified"; then 9446 # A command without a complete path is provided, search $PATH. 9447 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MKDIR=$tool_basename" >&5 9448 $as_echo "$as_me: Will search for user supplied tool MKDIR=$tool_basename" >&6;} 9449 # Extract the first word of "$tool_basename", so it can be a program name with args. 9450 set dummy $tool_basename; ac_word=$2 9451 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9452 $as_echo_n "checking for $ac_word... " >&6; } 9453 if ${ac_cv_path_MKDIR+:} false; then : 9454 $as_echo_n "(cached) " >&6 9455 else 9456 case $MKDIR in 9457 [\\/]* | ?:[\\/]*) 9458 ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path. 9459 ;; 9460 *) 9461 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9462 for as_dir in $PATH 9463 do 9464 IFS=$as_save_IFS 9465 test -z "$as_dir" && as_dir=. 9466 for ac_exec_ext in '' $ac_executable_extensions; do 9467 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9468 ac_cv_path_MKDIR="$as_dir/$ac_word$ac_exec_ext" 9469 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9470 break 2 9471 fi 9472 done 9473 done 9474 IFS=$as_save_IFS 9475 9476 ;; 9477 esac 9478 fi 9479 MKDIR=$ac_cv_path_MKDIR 9480 if test -n "$MKDIR"; then 9481 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR" >&5 9482 $as_echo "$MKDIR" >&6; } 9483 else 9484 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9485 $as_echo "no" >&6; } 9486 fi 9487 9488 9489 if test "x$MKDIR" = x; then 9490 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 9491 fi 9492 else 9493 # Otherwise we believe it is a complete path. Use it as it is. 9494 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MKDIR=$tool_specified" >&5 9495 $as_echo "$as_me: Will use user supplied tool MKDIR=$tool_specified" >&6;} 9496 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKDIR" >&5 9497 $as_echo_n "checking for MKDIR... " >&6; } 9498 if test ! -x "$tool_specified"; then 9499 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 9500 $as_echo "not found" >&6; } 9501 as_fn_error $? "User supplied tool MKDIR=$tool_specified does not exist or is not executable" "$LINENO" 5 9502 fi 9503 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 9504 $as_echo "$tool_specified" >&6; } 9505 fi 9506 fi 9507 fi 9508 9509 fi 9510 9511 9512 9513 if test "x$MKDIR" = x; then 9514 as_fn_error $? "Could not find required tool for MKDIR" "$LINENO" 5 9515 fi 9516 9517 9518 9519 9520 9521 # Publish this variable in the help. 9522 9523 9524 if [ -z "${MKTEMP+x}" ]; then 9525 # The variable is not set by user, try to locate tool using the code snippet 9526 for ac_prog in mktemp 9527 do 9528 # Extract the first word of "$ac_prog", so it can be a program name with args. 9529 set dummy $ac_prog; ac_word=$2 9530 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9531 $as_echo_n "checking for $ac_word... " >&6; } 9532 if ${ac_cv_path_MKTEMP+:} false; then : 9533 $as_echo_n "(cached) " >&6 9534 else 9535 case $MKTEMP in 9536 [\\/]* | ?:[\\/]*) 9537 ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path. 9538 ;; 9539 *) 9540 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9541 for as_dir in $PATH 9542 do 9543 IFS=$as_save_IFS 9544 test -z "$as_dir" && as_dir=. 9545 for ac_exec_ext in '' $ac_executable_extensions; do 9546 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9547 ac_cv_path_MKTEMP="$as_dir/$ac_word$ac_exec_ext" 9548 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9549 break 2 9550 fi 9551 done 9552 done 9553 IFS=$as_save_IFS 9554 9555 ;; 9556 esac 9557 fi 9558 MKTEMP=$ac_cv_path_MKTEMP 9559 if test -n "$MKTEMP"; then 9560 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKTEMP" >&5 9561 $as_echo "$MKTEMP" >&6; } 9562 else 9563 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9564 $as_echo "no" >&6; } 9565 fi 9566 9567 9568 test -n "$MKTEMP" && break 9569 done 9570 9571 else 9572 # The variable is set, but is it from the command line or the environment? 9573 9574 # Try to remove the string !MKTEMP! from our list. 9575 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MKTEMP!/} 9576 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 9577 # If it failed, the variable was not from the command line. Ignore it, 9578 # but warn the user (except for BASH, which is always set by the calling BASH). 9579 if test "xMKTEMP" != xBASH; then 9580 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MKTEMP from the environment. Use command line variables instead." >&5 9581 $as_echo "$as_me: WARNING: Ignoring value of MKTEMP from the environment. Use command line variables instead." >&2;} 9582 fi 9583 # Try to locate tool using the code snippet 9584 for ac_prog in mktemp 9585 do 9586 # Extract the first word of "$ac_prog", so it can be a program name with args. 9587 set dummy $ac_prog; ac_word=$2 9588 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9589 $as_echo_n "checking for $ac_word... " >&6; } 9590 if ${ac_cv_path_MKTEMP+:} false; then : 9591 $as_echo_n "(cached) " >&6 9592 else 9593 case $MKTEMP in 9594 [\\/]* | ?:[\\/]*) 9595 ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path. 9596 ;; 9597 *) 9598 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9599 for as_dir in $PATH 9600 do 9601 IFS=$as_save_IFS 9602 test -z "$as_dir" && as_dir=. 9603 for ac_exec_ext in '' $ac_executable_extensions; do 9604 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9605 ac_cv_path_MKTEMP="$as_dir/$ac_word$ac_exec_ext" 9606 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9607 break 2 9608 fi 9609 done 9610 done 9611 IFS=$as_save_IFS 9612 9613 ;; 9614 esac 9615 fi 9616 MKTEMP=$ac_cv_path_MKTEMP 9617 if test -n "$MKTEMP"; then 9618 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKTEMP" >&5 9619 $as_echo "$MKTEMP" >&6; } 9620 else 9621 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9622 $as_echo "no" >&6; } 9623 fi 9624 9625 9626 test -n "$MKTEMP" && break 9627 done 9628 9629 else 9630 # If it succeeded, then it was overridden by the user. We will use it 9631 # for the tool. 9632 9633 # First remove it from the list of overridden variables, so we can test 9634 # for unknown variables in the end. 9635 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 9636 9637 # Check if we try to supply an empty value 9638 if test "x$MKTEMP" = x; then 9639 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool MKTEMP= (no value)" >&5 9640 $as_echo "$as_me: Setting user supplied tool MKTEMP= (no value)" >&6;} 9641 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKTEMP" >&5 9642 $as_echo_n "checking for MKTEMP... " >&6; } 9643 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 9644 $as_echo "disabled" >&6; } 9645 else 9646 # Check if the provided tool contains a complete path. 9647 tool_specified="$MKTEMP" 9648 tool_basename="${tool_specified##*/}" 9649 if test "x$tool_basename" = "x$tool_specified"; then 9650 # A command without a complete path is provided, search $PATH. 9651 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MKTEMP=$tool_basename" >&5 9652 $as_echo "$as_me: Will search for user supplied tool MKTEMP=$tool_basename" >&6;} 9653 # Extract the first word of "$tool_basename", so it can be a program name with args. 9654 set dummy $tool_basename; ac_word=$2 9655 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9656 $as_echo_n "checking for $ac_word... " >&6; } 9657 if ${ac_cv_path_MKTEMP+:} false; then : 9658 $as_echo_n "(cached) " >&6 9659 else 9660 case $MKTEMP in 9661 [\\/]* | ?:[\\/]*) 9662 ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path. 9663 ;; 9664 *) 9665 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9666 for as_dir in $PATH 9667 do 9668 IFS=$as_save_IFS 9669 test -z "$as_dir" && as_dir=. 9670 for ac_exec_ext in '' $ac_executable_extensions; do 9671 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9672 ac_cv_path_MKTEMP="$as_dir/$ac_word$ac_exec_ext" 9673 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9674 break 2 9675 fi 9676 done 9677 done 9678 IFS=$as_save_IFS 9679 9680 ;; 9681 esac 9682 fi 9683 MKTEMP=$ac_cv_path_MKTEMP 9684 if test -n "$MKTEMP"; then 9685 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKTEMP" >&5 9686 $as_echo "$MKTEMP" >&6; } 9687 else 9688 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9689 $as_echo "no" >&6; } 9690 fi 9691 9692 9693 if test "x$MKTEMP" = x; then 9694 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 9695 fi 9696 else 9697 # Otherwise we believe it is a complete path. Use it as it is. 9698 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MKTEMP=$tool_specified" >&5 9699 $as_echo "$as_me: Will use user supplied tool MKTEMP=$tool_specified" >&6;} 9700 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKTEMP" >&5 9701 $as_echo_n "checking for MKTEMP... " >&6; } 9702 if test ! -x "$tool_specified"; then 9703 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 9704 $as_echo "not found" >&6; } 9705 as_fn_error $? "User supplied tool MKTEMP=$tool_specified does not exist or is not executable" "$LINENO" 5 9706 fi 9707 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 9708 $as_echo "$tool_specified" >&6; } 9709 fi 9710 fi 9711 fi 9712 9713 fi 9714 9715 9716 9717 if test "x$MKTEMP" = x; then 9718 as_fn_error $? "Could not find required tool for MKTEMP" "$LINENO" 5 9719 fi 9720 9721 9722 9723 9724 9725 # Publish this variable in the help. 9726 9727 9728 if [ -z "${MV+x}" ]; then 9729 # The variable is not set by user, try to locate tool using the code snippet 9730 for ac_prog in mv 9731 do 9732 # Extract the first word of "$ac_prog", so it can be a program name with args. 9733 set dummy $ac_prog; ac_word=$2 9734 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9735 $as_echo_n "checking for $ac_word... " >&6; } 9736 if ${ac_cv_path_MV+:} false; then : 9737 $as_echo_n "(cached) " >&6 9738 else 9739 case $MV in 9740 [\\/]* | ?:[\\/]*) 9741 ac_cv_path_MV="$MV" # Let the user override the test with a path. 9742 ;; 9743 *) 9744 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9745 for as_dir in $PATH 9746 do 9747 IFS=$as_save_IFS 9748 test -z "$as_dir" && as_dir=. 9749 for ac_exec_ext in '' $ac_executable_extensions; do 9750 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9751 ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext" 9752 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9753 break 2 9754 fi 9755 done 9756 done 9757 IFS=$as_save_IFS 9758 9759 ;; 9760 esac 9761 fi 9762 MV=$ac_cv_path_MV 9763 if test -n "$MV"; then 9764 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MV" >&5 9765 $as_echo "$MV" >&6; } 9766 else 9767 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9768 $as_echo "no" >&6; } 9769 fi 9770 9771 9772 test -n "$MV" && break 9773 done 9774 9775 else 9776 # The variable is set, but is it from the command line or the environment? 9777 9778 # Try to remove the string !MV! from our list. 9779 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MV!/} 9780 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 9781 # If it failed, the variable was not from the command line. Ignore it, 9782 # but warn the user (except for BASH, which is always set by the calling BASH). 9783 if test "xMV" != xBASH; then 9784 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MV from the environment. Use command line variables instead." >&5 9785 $as_echo "$as_me: WARNING: Ignoring value of MV from the environment. Use command line variables instead." >&2;} 9786 fi 9787 # Try to locate tool using the code snippet 9788 for ac_prog in mv 9789 do 9790 # Extract the first word of "$ac_prog", so it can be a program name with args. 9791 set dummy $ac_prog; ac_word=$2 9792 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9793 $as_echo_n "checking for $ac_word... " >&6; } 9794 if ${ac_cv_path_MV+:} false; then : 9795 $as_echo_n "(cached) " >&6 9796 else 9797 case $MV in 9798 [\\/]* | ?:[\\/]*) 9799 ac_cv_path_MV="$MV" # Let the user override the test with a path. 9800 ;; 9801 *) 9802 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9803 for as_dir in $PATH 9804 do 9805 IFS=$as_save_IFS 9806 test -z "$as_dir" && as_dir=. 9807 for ac_exec_ext in '' $ac_executable_extensions; do 9808 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9809 ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext" 9810 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9811 break 2 9812 fi 9813 done 9814 done 9815 IFS=$as_save_IFS 9816 9817 ;; 9818 esac 9819 fi 9820 MV=$ac_cv_path_MV 9821 if test -n "$MV"; then 9822 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MV" >&5 9823 $as_echo "$MV" >&6; } 9824 else 9825 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9826 $as_echo "no" >&6; } 9827 fi 9828 9829 9830 test -n "$MV" && break 9831 done 9832 9833 else 9834 # If it succeeded, then it was overridden by the user. We will use it 9835 # for the tool. 9836 9837 # First remove it from the list of overridden variables, so we can test 9838 # for unknown variables in the end. 9839 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 9840 9841 # Check if we try to supply an empty value 9842 if test "x$MV" = x; then 9843 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool MV= (no value)" >&5 9844 $as_echo "$as_me: Setting user supplied tool MV= (no value)" >&6;} 9845 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MV" >&5 9846 $as_echo_n "checking for MV... " >&6; } 9847 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 9848 $as_echo "disabled" >&6; } 9849 else 9850 # Check if the provided tool contains a complete path. 9851 tool_specified="$MV" 9852 tool_basename="${tool_specified##*/}" 9853 if test "x$tool_basename" = "x$tool_specified"; then 9854 # A command without a complete path is provided, search $PATH. 9855 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MV=$tool_basename" >&5 9856 $as_echo "$as_me: Will search for user supplied tool MV=$tool_basename" >&6;} 9857 # Extract the first word of "$tool_basename", so it can be a program name with args. 9858 set dummy $tool_basename; ac_word=$2 9859 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9860 $as_echo_n "checking for $ac_word... " >&6; } 9861 if ${ac_cv_path_MV+:} false; then : 9862 $as_echo_n "(cached) " >&6 9863 else 9864 case $MV in 9865 [\\/]* | ?:[\\/]*) 9866 ac_cv_path_MV="$MV" # Let the user override the test with a path. 9867 ;; 9868 *) 9869 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9870 for as_dir in $PATH 9871 do 9872 IFS=$as_save_IFS 9873 test -z "$as_dir" && as_dir=. 9874 for ac_exec_ext in '' $ac_executable_extensions; do 9875 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9876 ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext" 9877 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9878 break 2 9879 fi 9880 done 9881 done 9882 IFS=$as_save_IFS 9883 9884 ;; 9885 esac 9886 fi 9887 MV=$ac_cv_path_MV 9888 if test -n "$MV"; then 9889 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MV" >&5 9890 $as_echo "$MV" >&6; } 9891 else 9892 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9893 $as_echo "no" >&6; } 9894 fi 9895 9896 9897 if test "x$MV" = x; then 9898 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 9899 fi 9900 else 9901 # Otherwise we believe it is a complete path. Use it as it is. 9902 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MV=$tool_specified" >&5 9903 $as_echo "$as_me: Will use user supplied tool MV=$tool_specified" >&6;} 9904 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MV" >&5 9905 $as_echo_n "checking for MV... " >&6; } 9906 if test ! -x "$tool_specified"; then 9907 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 9908 $as_echo "not found" >&6; } 9909 as_fn_error $? "User supplied tool MV=$tool_specified does not exist or is not executable" "$LINENO" 5 9910 fi 9911 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 9912 $as_echo "$tool_specified" >&6; } 9913 fi 9914 fi 9915 fi 9916 9917 fi 9918 9919 9920 9921 if test "x$MV" = x; then 9922 as_fn_error $? "Could not find required tool for MV" "$LINENO" 5 9923 fi 9924 9925 9926 9927 9928 9929 # Publish this variable in the help. 9930 9931 9932 if [ -z "${NAWK+x}" ]; then 9933 # The variable is not set by user, try to locate tool using the code snippet 9934 for ac_prog in nawk gawk awk 9935 do 9936 # Extract the first word of "$ac_prog", so it can be a program name with args. 9937 set dummy $ac_prog; ac_word=$2 9938 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9939 $as_echo_n "checking for $ac_word... " >&6; } 9940 if ${ac_cv_path_NAWK+:} false; then : 9941 $as_echo_n "(cached) " >&6 9942 else 9943 case $NAWK in 9944 [\\/]* | ?:[\\/]*) 9945 ac_cv_path_NAWK="$NAWK" # Let the user override the test with a path. 9946 ;; 9947 *) 9948 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9949 for as_dir in $PATH 9950 do 9951 IFS=$as_save_IFS 9952 test -z "$as_dir" && as_dir=. 9953 for ac_exec_ext in '' $ac_executable_extensions; do 9954 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9955 ac_cv_path_NAWK="$as_dir/$ac_word$ac_exec_ext" 9956 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9957 break 2 9958 fi 9959 done 9960 done 9961 IFS=$as_save_IFS 9962 9963 ;; 9964 esac 9965 fi 9966 NAWK=$ac_cv_path_NAWK 9967 if test -n "$NAWK"; then 9968 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NAWK" >&5 9969 $as_echo "$NAWK" >&6; } 9970 else 9971 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9972 $as_echo "no" >&6; } 9973 fi 9974 9975 9976 test -n "$NAWK" && break 9977 done 9978 9979 else 9980 # The variable is set, but is it from the command line or the environment? 9981 9982 # Try to remove the string !NAWK! from our list. 9983 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NAWK!/} 9984 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 9985 # If it failed, the variable was not from the command line. Ignore it, 9986 # but warn the user (except for BASH, which is always set by the calling BASH). 9987 if test "xNAWK" != xBASH; then 9988 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NAWK from the environment. Use command line variables instead." >&5 9989 $as_echo "$as_me: WARNING: Ignoring value of NAWK from the environment. Use command line variables instead." >&2;} 9990 fi 9991 # Try to locate tool using the code snippet 9992 for ac_prog in nawk gawk awk 9993 do 9994 # Extract the first word of "$ac_prog", so it can be a program name with args. 9995 set dummy $ac_prog; ac_word=$2 9996 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9997 $as_echo_n "checking for $ac_word... " >&6; } 9998 if ${ac_cv_path_NAWK+:} false; then : 9999 $as_echo_n "(cached) " >&6 10000 else 10001 case $NAWK in 10002 [\\/]* | ?:[\\/]*) 10003 ac_cv_path_NAWK="$NAWK" # Let the user override the test with a path. 10004 ;; 10005 *) 10006 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10007 for as_dir in $PATH 10008 do 10009 IFS=$as_save_IFS 10010 test -z "$as_dir" && as_dir=. 10011 for ac_exec_ext in '' $ac_executable_extensions; do 10012 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10013 ac_cv_path_NAWK="$as_dir/$ac_word$ac_exec_ext" 10014 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10015 break 2 10016 fi 10017 done 10018 done 10019 IFS=$as_save_IFS 10020 10021 ;; 10022 esac 10023 fi 10024 NAWK=$ac_cv_path_NAWK 10025 if test -n "$NAWK"; then 10026 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NAWK" >&5 10027 $as_echo "$NAWK" >&6; } 10028 else 10029 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10030 $as_echo "no" >&6; } 10031 fi 10032 10033 10034 test -n "$NAWK" && break 10035 done 10036 10037 else 10038 # If it succeeded, then it was overridden by the user. We will use it 10039 # for the tool. 10040 10041 # First remove it from the list of overridden variables, so we can test 10042 # for unknown variables in the end. 10043 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 10044 10045 # Check if we try to supply an empty value 10046 if test "x$NAWK" = x; then 10047 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool NAWK= (no value)" >&5 10048 $as_echo "$as_me: Setting user supplied tool NAWK= (no value)" >&6;} 10049 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NAWK" >&5 10050 $as_echo_n "checking for NAWK... " >&6; } 10051 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 10052 $as_echo "disabled" >&6; } 10053 else 10054 # Check if the provided tool contains a complete path. 10055 tool_specified="$NAWK" 10056 tool_basename="${tool_specified##*/}" 10057 if test "x$tool_basename" = "x$tool_specified"; then 10058 # A command without a complete path is provided, search $PATH. 10059 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NAWK=$tool_basename" >&5 10060 $as_echo "$as_me: Will search for user supplied tool NAWK=$tool_basename" >&6;} 10061 # Extract the first word of "$tool_basename", so it can be a program name with args. 10062 set dummy $tool_basename; ac_word=$2 10063 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10064 $as_echo_n "checking for $ac_word... " >&6; } 10065 if ${ac_cv_path_NAWK+:} false; then : 10066 $as_echo_n "(cached) " >&6 10067 else 10068 case $NAWK in 10069 [\\/]* | ?:[\\/]*) 10070 ac_cv_path_NAWK="$NAWK" # Let the user override the test with a path. 10071 ;; 10072 *) 10073 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10074 for as_dir in $PATH 10075 do 10076 IFS=$as_save_IFS 10077 test -z "$as_dir" && as_dir=. 10078 for ac_exec_ext in '' $ac_executable_extensions; do 10079 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10080 ac_cv_path_NAWK="$as_dir/$ac_word$ac_exec_ext" 10081 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10082 break 2 10083 fi 10084 done 10085 done 10086 IFS=$as_save_IFS 10087 10088 ;; 10089 esac 10090 fi 10091 NAWK=$ac_cv_path_NAWK 10092 if test -n "$NAWK"; then 10093 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NAWK" >&5 10094 $as_echo "$NAWK" >&6; } 10095 else 10096 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10097 $as_echo "no" >&6; } 10098 fi 10099 10100 10101 if test "x$NAWK" = x; then 10102 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 10103 fi 10104 else 10105 # Otherwise we believe it is a complete path. Use it as it is. 10106 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NAWK=$tool_specified" >&5 10107 $as_echo "$as_me: Will use user supplied tool NAWK=$tool_specified" >&6;} 10108 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NAWK" >&5 10109 $as_echo_n "checking for NAWK... " >&6; } 10110 if test ! -x "$tool_specified"; then 10111 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 10112 $as_echo "not found" >&6; } 10113 as_fn_error $? "User supplied tool NAWK=$tool_specified does not exist or is not executable" "$LINENO" 5 10114 fi 10115 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 10116 $as_echo "$tool_specified" >&6; } 10117 fi 10118 fi 10119 fi 10120 10121 fi 10122 10123 10124 10125 if test "x$NAWK" = x; then 10126 as_fn_error $? "Could not find required tool for NAWK" "$LINENO" 5 10127 fi 10128 10129 10130 10131 10132 10133 # Publish this variable in the help. 10134 10135 10136 if [ -z "${PRINTF+x}" ]; then 10137 # The variable is not set by user, try to locate tool using the code snippet 10138 for ac_prog in printf 10139 do 10140 # Extract the first word of "$ac_prog", so it can be a program name with args. 10141 set dummy $ac_prog; ac_word=$2 10142 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10143 $as_echo_n "checking for $ac_word... " >&6; } 10144 if ${ac_cv_path_PRINTF+:} false; then : 10145 $as_echo_n "(cached) " >&6 10146 else 10147 case $PRINTF in 10148 [\\/]* | ?:[\\/]*) 10149 ac_cv_path_PRINTF="$PRINTF" # Let the user override the test with a path. 10150 ;; 10151 *) 10152 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10153 for as_dir in $PATH 10154 do 10155 IFS=$as_save_IFS 10156 test -z "$as_dir" && as_dir=. 10157 for ac_exec_ext in '' $ac_executable_extensions; do 10158 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10159 ac_cv_path_PRINTF="$as_dir/$ac_word$ac_exec_ext" 10160 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10161 break 2 10162 fi 10163 done 10164 done 10165 IFS=$as_save_IFS 10166 10167 ;; 10168 esac 10169 fi 10170 PRINTF=$ac_cv_path_PRINTF 10171 if test -n "$PRINTF"; then 10172 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRINTF" >&5 10173 $as_echo "$PRINTF" >&6; } 10174 else 10175 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10176 $as_echo "no" >&6; } 10177 fi 10178 10179 10180 test -n "$PRINTF" && break 10181 done 10182 10183 else 10184 # The variable is set, but is it from the command line or the environment? 10185 10186 # Try to remove the string !PRINTF! from our list. 10187 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!PRINTF!/} 10188 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 10189 # If it failed, the variable was not from the command line. Ignore it, 10190 # but warn the user (except for BASH, which is always set by the calling BASH). 10191 if test "xPRINTF" != xBASH; then 10192 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of PRINTF from the environment. Use command line variables instead." >&5 10193 $as_echo "$as_me: WARNING: Ignoring value of PRINTF from the environment. Use command line variables instead." >&2;} 10194 fi 10195 # Try to locate tool using the code snippet 10196 for ac_prog in printf 10197 do 10198 # Extract the first word of "$ac_prog", so it can be a program name with args. 10199 set dummy $ac_prog; ac_word=$2 10200 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10201 $as_echo_n "checking for $ac_word... " >&6; } 10202 if ${ac_cv_path_PRINTF+:} false; then : 10203 $as_echo_n "(cached) " >&6 10204 else 10205 case $PRINTF in 10206 [\\/]* | ?:[\\/]*) 10207 ac_cv_path_PRINTF="$PRINTF" # Let the user override the test with a path. 10208 ;; 10209 *) 10210 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10211 for as_dir in $PATH 10212 do 10213 IFS=$as_save_IFS 10214 test -z "$as_dir" && as_dir=. 10215 for ac_exec_ext in '' $ac_executable_extensions; do 10216 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10217 ac_cv_path_PRINTF="$as_dir/$ac_word$ac_exec_ext" 10218 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10219 break 2 10220 fi 10221 done 10222 done 10223 IFS=$as_save_IFS 10224 10225 ;; 10226 esac 10227 fi 10228 PRINTF=$ac_cv_path_PRINTF 10229 if test -n "$PRINTF"; then 10230 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRINTF" >&5 10231 $as_echo "$PRINTF" >&6; } 10232 else 10233 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10234 $as_echo "no" >&6; } 10235 fi 10236 10237 10238 test -n "$PRINTF" && break 10239 done 10240 10241 else 10242 # If it succeeded, then it was overridden by the user. We will use it 10243 # for the tool. 10244 10245 # First remove it from the list of overridden variables, so we can test 10246 # for unknown variables in the end. 10247 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 10248 10249 # Check if we try to supply an empty value 10250 if test "x$PRINTF" = x; then 10251 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool PRINTF= (no value)" >&5 10252 $as_echo "$as_me: Setting user supplied tool PRINTF= (no value)" >&6;} 10253 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PRINTF" >&5 10254 $as_echo_n "checking for PRINTF... " >&6; } 10255 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 10256 $as_echo "disabled" >&6; } 10257 else 10258 # Check if the provided tool contains a complete path. 10259 tool_specified="$PRINTF" 10260 tool_basename="${tool_specified##*/}" 10261 if test "x$tool_basename" = "x$tool_specified"; then 10262 # A command without a complete path is provided, search $PATH. 10263 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool PRINTF=$tool_basename" >&5 10264 $as_echo "$as_me: Will search for user supplied tool PRINTF=$tool_basename" >&6;} 10265 # Extract the first word of "$tool_basename", so it can be a program name with args. 10266 set dummy $tool_basename; ac_word=$2 10267 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10268 $as_echo_n "checking for $ac_word... " >&6; } 10269 if ${ac_cv_path_PRINTF+:} false; then : 10270 $as_echo_n "(cached) " >&6 10271 else 10272 case $PRINTF in 10273 [\\/]* | ?:[\\/]*) 10274 ac_cv_path_PRINTF="$PRINTF" # Let the user override the test with a path. 10275 ;; 10276 *) 10277 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10278 for as_dir in $PATH 10279 do 10280 IFS=$as_save_IFS 10281 test -z "$as_dir" && as_dir=. 10282 for ac_exec_ext in '' $ac_executable_extensions; do 10283 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10284 ac_cv_path_PRINTF="$as_dir/$ac_word$ac_exec_ext" 10285 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10286 break 2 10287 fi 10288 done 10289 done 10290 IFS=$as_save_IFS 10291 10292 ;; 10293 esac 10294 fi 10295 PRINTF=$ac_cv_path_PRINTF 10296 if test -n "$PRINTF"; then 10297 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRINTF" >&5 10298 $as_echo "$PRINTF" >&6; } 10299 else 10300 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10301 $as_echo "no" >&6; } 10302 fi 10303 10304 10305 if test "x$PRINTF" = x; then 10306 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 10307 fi 10308 else 10309 # Otherwise we believe it is a complete path. Use it as it is. 10310 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool PRINTF=$tool_specified" >&5 10311 $as_echo "$as_me: Will use user supplied tool PRINTF=$tool_specified" >&6;} 10312 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PRINTF" >&5 10313 $as_echo_n "checking for PRINTF... " >&6; } 10314 if test ! -x "$tool_specified"; then 10315 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 10316 $as_echo "not found" >&6; } 10317 as_fn_error $? "User supplied tool PRINTF=$tool_specified does not exist or is not executable" "$LINENO" 5 10318 fi 10319 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 10320 $as_echo "$tool_specified" >&6; } 10321 fi 10322 fi 10323 fi 10324 10325 fi 10326 10327 10328 10329 if test "x$PRINTF" = x; then 10330 as_fn_error $? "Could not find required tool for PRINTF" "$LINENO" 5 10331 fi 10332 10333 10334 10335 10336 10337 # Publish this variable in the help. 10338 10339 10340 if [ -z "${RM+x}" ]; then 10341 # The variable is not set by user, try to locate tool using the code snippet 10342 for ac_prog in rm 10343 do 10344 # Extract the first word of "$ac_prog", so it can be a program name with args. 10345 set dummy $ac_prog; ac_word=$2 10346 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10347 $as_echo_n "checking for $ac_word... " >&6; } 10348 if ${ac_cv_path_RM+:} false; then : 10349 $as_echo_n "(cached) " >&6 10350 else 10351 case $RM in 10352 [\\/]* | ?:[\\/]*) 10353 ac_cv_path_RM="$RM" # Let the user override the test with a path. 10354 ;; 10355 *) 10356 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10357 for as_dir in $PATH 10358 do 10359 IFS=$as_save_IFS 10360 test -z "$as_dir" && as_dir=. 10361 for ac_exec_ext in '' $ac_executable_extensions; do 10362 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10363 ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext" 10364 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10365 break 2 10366 fi 10367 done 10368 done 10369 IFS=$as_save_IFS 10370 10371 ;; 10372 esac 10373 fi 10374 RM=$ac_cv_path_RM 10375 if test -n "$RM"; then 10376 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RM" >&5 10377 $as_echo "$RM" >&6; } 10378 else 10379 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10380 $as_echo "no" >&6; } 10381 fi 10382 10383 10384 test -n "$RM" && break 10385 done 10386 10387 else 10388 # The variable is set, but is it from the command line or the environment? 10389 10390 # Try to remove the string !RM! from our list. 10391 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!RM!/} 10392 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 10393 # If it failed, the variable was not from the command line. Ignore it, 10394 # but warn the user (except for BASH, which is always set by the calling BASH). 10395 if test "xRM" != xBASH; then 10396 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of RM from the environment. Use command line variables instead." >&5 10397 $as_echo "$as_me: WARNING: Ignoring value of RM from the environment. Use command line variables instead." >&2;} 10398 fi 10399 # Try to locate tool using the code snippet 10400 for ac_prog in rm 10401 do 10402 # Extract the first word of "$ac_prog", so it can be a program name with args. 10403 set dummy $ac_prog; ac_word=$2 10404 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10405 $as_echo_n "checking for $ac_word... " >&6; } 10406 if ${ac_cv_path_RM+:} false; then : 10407 $as_echo_n "(cached) " >&6 10408 else 10409 case $RM in 10410 [\\/]* | ?:[\\/]*) 10411 ac_cv_path_RM="$RM" # Let the user override the test with a path. 10412 ;; 10413 *) 10414 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10415 for as_dir in $PATH 10416 do 10417 IFS=$as_save_IFS 10418 test -z "$as_dir" && as_dir=. 10419 for ac_exec_ext in '' $ac_executable_extensions; do 10420 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10421 ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext" 10422 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10423 break 2 10424 fi 10425 done 10426 done 10427 IFS=$as_save_IFS 10428 10429 ;; 10430 esac 10431 fi 10432 RM=$ac_cv_path_RM 10433 if test -n "$RM"; then 10434 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RM" >&5 10435 $as_echo "$RM" >&6; } 10436 else 10437 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10438 $as_echo "no" >&6; } 10439 fi 10440 10441 10442 test -n "$RM" && break 10443 done 10444 10445 else 10446 # If it succeeded, then it was overridden by the user. We will use it 10447 # for the tool. 10448 10449 # First remove it from the list of overridden variables, so we can test 10450 # for unknown variables in the end. 10451 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 10452 10453 # Check if we try to supply an empty value 10454 if test "x$RM" = x; then 10455 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool RM= (no value)" >&5 10456 $as_echo "$as_me: Setting user supplied tool RM= (no value)" >&6;} 10457 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RM" >&5 10458 $as_echo_n "checking for RM... " >&6; } 10459 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 10460 $as_echo "disabled" >&6; } 10461 else 10462 # Check if the provided tool contains a complete path. 10463 tool_specified="$RM" 10464 tool_basename="${tool_specified##*/}" 10465 if test "x$tool_basename" = "x$tool_specified"; then 10466 # A command without a complete path is provided, search $PATH. 10467 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool RM=$tool_basename" >&5 10468 $as_echo "$as_me: Will search for user supplied tool RM=$tool_basename" >&6;} 10469 # Extract the first word of "$tool_basename", so it can be a program name with args. 10470 set dummy $tool_basename; ac_word=$2 10471 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10472 $as_echo_n "checking for $ac_word... " >&6; } 10473 if ${ac_cv_path_RM+:} false; then : 10474 $as_echo_n "(cached) " >&6 10475 else 10476 case $RM in 10477 [\\/]* | ?:[\\/]*) 10478 ac_cv_path_RM="$RM" # Let the user override the test with a path. 10479 ;; 10480 *) 10481 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10482 for as_dir in $PATH 10483 do 10484 IFS=$as_save_IFS 10485 test -z "$as_dir" && as_dir=. 10486 for ac_exec_ext in '' $ac_executable_extensions; do 10487 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10488 ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext" 10489 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10490 break 2 10491 fi 10492 done 10493 done 10494 IFS=$as_save_IFS 10495 10496 ;; 10497 esac 10498 fi 10499 RM=$ac_cv_path_RM 10500 if test -n "$RM"; then 10501 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RM" >&5 10502 $as_echo "$RM" >&6; } 10503 else 10504 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10505 $as_echo "no" >&6; } 10506 fi 10507 10508 10509 if test "x$RM" = x; then 10510 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 10511 fi 10512 else 10513 # Otherwise we believe it is a complete path. Use it as it is. 10514 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool RM=$tool_specified" >&5 10515 $as_echo "$as_me: Will use user supplied tool RM=$tool_specified" >&6;} 10516 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RM" >&5 10517 $as_echo_n "checking for RM... " >&6; } 10518 if test ! -x "$tool_specified"; then 10519 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 10520 $as_echo "not found" >&6; } 10521 as_fn_error $? "User supplied tool RM=$tool_specified does not exist or is not executable" "$LINENO" 5 10522 fi 10523 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 10524 $as_echo "$tool_specified" >&6; } 10525 fi 10526 fi 10527 fi 10528 10529 fi 10530 10531 10532 10533 if test "x$RM" = x; then 10534 as_fn_error $? "Could not find required tool for RM" "$LINENO" 5 10535 fi 10536 10537 10538 10539 10540 10541 # Publish this variable in the help. 10542 10543 10544 if [ -z "${RMDIR+x}" ]; then 10545 # The variable is not set by user, try to locate tool using the code snippet 10546 for ac_prog in rmdir 10547 do 10548 # Extract the first word of "$ac_prog", so it can be a program name with args. 10549 set dummy $ac_prog; ac_word=$2 10550 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10551 $as_echo_n "checking for $ac_word... " >&6; } 10552 if ${ac_cv_path_RMDIR+:} false; then : 10553 $as_echo_n "(cached) " >&6 10554 else 10555 case $RMDIR in 10556 [\\/]* | ?:[\\/]*) 10557 ac_cv_path_RMDIR="$RMDIR" # Let the user override the test with a path. 10558 ;; 10559 *) 10560 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10561 for as_dir in $PATH 10562 do 10563 IFS=$as_save_IFS 10564 test -z "$as_dir" && as_dir=. 10565 for ac_exec_ext in '' $ac_executable_extensions; do 10566 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10567 ac_cv_path_RMDIR="$as_dir/$ac_word$ac_exec_ext" 10568 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10569 break 2 10570 fi 10571 done 10572 done 10573 IFS=$as_save_IFS 10574 10575 ;; 10576 esac 10577 fi 10578 RMDIR=$ac_cv_path_RMDIR 10579 if test -n "$RMDIR"; then 10580 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RMDIR" >&5 10581 $as_echo "$RMDIR" >&6; } 10582 else 10583 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10584 $as_echo "no" >&6; } 10585 fi 10586 10587 10588 test -n "$RMDIR" && break 10589 done 10590 10591 else 10592 # The variable is set, but is it from the command line or the environment? 10593 10594 # Try to remove the string !RMDIR! from our list. 10595 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!RMDIR!/} 10596 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 10597 # If it failed, the variable was not from the command line. Ignore it, 10598 # but warn the user (except for BASH, which is always set by the calling BASH). 10599 if test "xRMDIR" != xBASH; then 10600 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of RMDIR from the environment. Use command line variables instead." >&5 10601 $as_echo "$as_me: WARNING: Ignoring value of RMDIR from the environment. Use command line variables instead." >&2;} 10602 fi 10603 # Try to locate tool using the code snippet 10604 for ac_prog in rmdir 10605 do 10606 # Extract the first word of "$ac_prog", so it can be a program name with args. 10607 set dummy $ac_prog; ac_word=$2 10608 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10609 $as_echo_n "checking for $ac_word... " >&6; } 10610 if ${ac_cv_path_RMDIR+:} false; then : 10611 $as_echo_n "(cached) " >&6 10612 else 10613 case $RMDIR in 10614 [\\/]* | ?:[\\/]*) 10615 ac_cv_path_RMDIR="$RMDIR" # Let the user override the test with a path. 10616 ;; 10617 *) 10618 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10619 for as_dir in $PATH 10620 do 10621 IFS=$as_save_IFS 10622 test -z "$as_dir" && as_dir=. 10623 for ac_exec_ext in '' $ac_executable_extensions; do 10624 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10625 ac_cv_path_RMDIR="$as_dir/$ac_word$ac_exec_ext" 10626 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10627 break 2 10628 fi 10629 done 10630 done 10631 IFS=$as_save_IFS 10632 10633 ;; 10634 esac 10635 fi 10636 RMDIR=$ac_cv_path_RMDIR 10637 if test -n "$RMDIR"; then 10638 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RMDIR" >&5 10639 $as_echo "$RMDIR" >&6; } 10640 else 10641 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10642 $as_echo "no" >&6; } 10643 fi 10644 10645 10646 test -n "$RMDIR" && break 10647 done 10648 10649 else 10650 # If it succeeded, then it was overridden by the user. We will use it 10651 # for the tool. 10652 10653 # First remove it from the list of overridden variables, so we can test 10654 # for unknown variables in the end. 10655 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 10656 10657 # Check if we try to supply an empty value 10658 if test "x$RMDIR" = x; then 10659 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool RMDIR= (no value)" >&5 10660 $as_echo "$as_me: Setting user supplied tool RMDIR= (no value)" >&6;} 10661 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RMDIR" >&5 10662 $as_echo_n "checking for RMDIR... " >&6; } 10663 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 10664 $as_echo "disabled" >&6; } 10665 else 10666 # Check if the provided tool contains a complete path. 10667 tool_specified="$RMDIR" 10668 tool_basename="${tool_specified##*/}" 10669 if test "x$tool_basename" = "x$tool_specified"; then 10670 # A command without a complete path is provided, search $PATH. 10671 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool RMDIR=$tool_basename" >&5 10672 $as_echo "$as_me: Will search for user supplied tool RMDIR=$tool_basename" >&6;} 10673 # Extract the first word of "$tool_basename", so it can be a program name with args. 10674 set dummy $tool_basename; ac_word=$2 10675 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10676 $as_echo_n "checking for $ac_word... " >&6; } 10677 if ${ac_cv_path_RMDIR+:} false; then : 10678 $as_echo_n "(cached) " >&6 10679 else 10680 case $RMDIR in 10681 [\\/]* | ?:[\\/]*) 10682 ac_cv_path_RMDIR="$RMDIR" # Let the user override the test with a path. 10683 ;; 10684 *) 10685 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10686 for as_dir in $PATH 10687 do 10688 IFS=$as_save_IFS 10689 test -z "$as_dir" && as_dir=. 10690 for ac_exec_ext in '' $ac_executable_extensions; do 10691 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10692 ac_cv_path_RMDIR="$as_dir/$ac_word$ac_exec_ext" 10693 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10694 break 2 10695 fi 10696 done 10697 done 10698 IFS=$as_save_IFS 10699 10700 ;; 10701 esac 10702 fi 10703 RMDIR=$ac_cv_path_RMDIR 10704 if test -n "$RMDIR"; then 10705 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RMDIR" >&5 10706 $as_echo "$RMDIR" >&6; } 10707 else 10708 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10709 $as_echo "no" >&6; } 10710 fi 10711 10712 10713 if test "x$RMDIR" = x; then 10714 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 10715 fi 10716 else 10717 # Otherwise we believe it is a complete path. Use it as it is. 10718 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool RMDIR=$tool_specified" >&5 10719 $as_echo "$as_me: Will use user supplied tool RMDIR=$tool_specified" >&6;} 10720 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RMDIR" >&5 10721 $as_echo_n "checking for RMDIR... " >&6; } 10722 if test ! -x "$tool_specified"; then 10723 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 10724 $as_echo "not found" >&6; } 10725 as_fn_error $? "User supplied tool RMDIR=$tool_specified does not exist or is not executable" "$LINENO" 5 10726 fi 10727 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 10728 $as_echo "$tool_specified" >&6; } 10729 fi 10730 fi 10731 fi 10732 10733 fi 10734 10735 10736 10737 if test "x$RMDIR" = x; then 10738 as_fn_error $? "Could not find required tool for RMDIR" "$LINENO" 5 10739 fi 10740 10741 10742 10743 10744 10745 # Publish this variable in the help. 10746 10747 10748 if [ -z "${SH+x}" ]; then 10749 # The variable is not set by user, try to locate tool using the code snippet 10750 for ac_prog in sh 10751 do 10752 # Extract the first word of "$ac_prog", so it can be a program name with args. 10753 set dummy $ac_prog; ac_word=$2 10754 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10755 $as_echo_n "checking for $ac_word... " >&6; } 10756 if ${ac_cv_path_SH+:} false; then : 10757 $as_echo_n "(cached) " >&6 10758 else 10759 case $SH in 10760 [\\/]* | ?:[\\/]*) 10761 ac_cv_path_SH="$SH" # Let the user override the test with a path. 10762 ;; 10763 *) 10764 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10765 for as_dir in $PATH 10766 do 10767 IFS=$as_save_IFS 10768 test -z "$as_dir" && as_dir=. 10769 for ac_exec_ext in '' $ac_executable_extensions; do 10770 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10771 ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext" 10772 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10773 break 2 10774 fi 10775 done 10776 done 10777 IFS=$as_save_IFS 10778 10779 ;; 10780 esac 10781 fi 10782 SH=$ac_cv_path_SH 10783 if test -n "$SH"; then 10784 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5 10785 $as_echo "$SH" >&6; } 10786 else 10787 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10788 $as_echo "no" >&6; } 10789 fi 10790 10791 10792 test -n "$SH" && break 10793 done 10794 10795 else 10796 # The variable is set, but is it from the command line or the environment? 10797 10798 # Try to remove the string !SH! from our list. 10799 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SH!/} 10800 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 10801 # If it failed, the variable was not from the command line. Ignore it, 10802 # but warn the user (except for BASH, which is always set by the calling BASH). 10803 if test "xSH" != xBASH; then 10804 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SH from the environment. Use command line variables instead." >&5 10805 $as_echo "$as_me: WARNING: Ignoring value of SH from the environment. Use command line variables instead." >&2;} 10806 fi 10807 # Try to locate tool using the code snippet 10808 for ac_prog in sh 10809 do 10810 # Extract the first word of "$ac_prog", so it can be a program name with args. 10811 set dummy $ac_prog; ac_word=$2 10812 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10813 $as_echo_n "checking for $ac_word... " >&6; } 10814 if ${ac_cv_path_SH+:} false; then : 10815 $as_echo_n "(cached) " >&6 10816 else 10817 case $SH in 10818 [\\/]* | ?:[\\/]*) 10819 ac_cv_path_SH="$SH" # Let the user override the test with a path. 10820 ;; 10821 *) 10822 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10823 for as_dir in $PATH 10824 do 10825 IFS=$as_save_IFS 10826 test -z "$as_dir" && as_dir=. 10827 for ac_exec_ext in '' $ac_executable_extensions; do 10828 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10829 ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext" 10830 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10831 break 2 10832 fi 10833 done 10834 done 10835 IFS=$as_save_IFS 10836 10837 ;; 10838 esac 10839 fi 10840 SH=$ac_cv_path_SH 10841 if test -n "$SH"; then 10842 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5 10843 $as_echo "$SH" >&6; } 10844 else 10845 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10846 $as_echo "no" >&6; } 10847 fi 10848 10849 10850 test -n "$SH" && break 10851 done 10852 10853 else 10854 # If it succeeded, then it was overridden by the user. We will use it 10855 # for the tool. 10856 10857 # First remove it from the list of overridden variables, so we can test 10858 # for unknown variables in the end. 10859 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 10860 10861 # Check if we try to supply an empty value 10862 if test "x$SH" = x; then 10863 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool SH= (no value)" >&5 10864 $as_echo "$as_me: Setting user supplied tool SH= (no value)" >&6;} 10865 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SH" >&5 10866 $as_echo_n "checking for SH... " >&6; } 10867 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 10868 $as_echo "disabled" >&6; } 10869 else 10870 # Check if the provided tool contains a complete path. 10871 tool_specified="$SH" 10872 tool_basename="${tool_specified##*/}" 10873 if test "x$tool_basename" = "x$tool_specified"; then 10874 # A command without a complete path is provided, search $PATH. 10875 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SH=$tool_basename" >&5 10876 $as_echo "$as_me: Will search for user supplied tool SH=$tool_basename" >&6;} 10877 # Extract the first word of "$tool_basename", so it can be a program name with args. 10878 set dummy $tool_basename; ac_word=$2 10879 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10880 $as_echo_n "checking for $ac_word... " >&6; } 10881 if ${ac_cv_path_SH+:} false; then : 10882 $as_echo_n "(cached) " >&6 10883 else 10884 case $SH in 10885 [\\/]* | ?:[\\/]*) 10886 ac_cv_path_SH="$SH" # Let the user override the test with a path. 10887 ;; 10888 *) 10889 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10890 for as_dir in $PATH 10891 do 10892 IFS=$as_save_IFS 10893 test -z "$as_dir" && as_dir=. 10894 for ac_exec_ext in '' $ac_executable_extensions; do 10895 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10896 ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext" 10897 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10898 break 2 10899 fi 10900 done 10901 done 10902 IFS=$as_save_IFS 10903 10904 ;; 10905 esac 10906 fi 10907 SH=$ac_cv_path_SH 10908 if test -n "$SH"; then 10909 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5 10910 $as_echo "$SH" >&6; } 10911 else 10912 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10913 $as_echo "no" >&6; } 10914 fi 10915 10916 10917 if test "x$SH" = x; then 10918 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 10919 fi 10920 else 10921 # Otherwise we believe it is a complete path. Use it as it is. 10922 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SH=$tool_specified" >&5 10923 $as_echo "$as_me: Will use user supplied tool SH=$tool_specified" >&6;} 10924 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SH" >&5 10925 $as_echo_n "checking for SH... " >&6; } 10926 if test ! -x "$tool_specified"; then 10927 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 10928 $as_echo "not found" >&6; } 10929 as_fn_error $? "User supplied tool SH=$tool_specified does not exist or is not executable" "$LINENO" 5 10930 fi 10931 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 10932 $as_echo "$tool_specified" >&6; } 10933 fi 10934 fi 10935 fi 10936 10937 fi 10938 10939 10940 10941 if test "x$SH" = x; then 10942 as_fn_error $? "Could not find required tool for SH" "$LINENO" 5 10943 fi 10944 10945 10946 10947 10948 10949 # Publish this variable in the help. 10950 10951 10952 if [ -z "${SORT+x}" ]; then 10953 # The variable is not set by user, try to locate tool using the code snippet 10954 for ac_prog in sort 10955 do 10956 # Extract the first word of "$ac_prog", so it can be a program name with args. 10957 set dummy $ac_prog; ac_word=$2 10958 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10959 $as_echo_n "checking for $ac_word... " >&6; } 10960 if ${ac_cv_path_SORT+:} false; then : 10961 $as_echo_n "(cached) " >&6 10962 else 10963 case $SORT in 10964 [\\/]* | ?:[\\/]*) 10965 ac_cv_path_SORT="$SORT" # Let the user override the test with a path. 10966 ;; 10967 *) 10968 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10969 for as_dir in $PATH 10970 do 10971 IFS=$as_save_IFS 10972 test -z "$as_dir" && as_dir=. 10973 for ac_exec_ext in '' $ac_executable_extensions; do 10974 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10975 ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext" 10976 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10977 break 2 10978 fi 10979 done 10980 done 10981 IFS=$as_save_IFS 10982 10983 ;; 10984 esac 10985 fi 10986 SORT=$ac_cv_path_SORT 10987 if test -n "$SORT"; then 10988 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5 10989 $as_echo "$SORT" >&6; } 10990 else 10991 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10992 $as_echo "no" >&6; } 10993 fi 10994 10995 10996 test -n "$SORT" && break 10997 done 10998 10999 else 11000 # The variable is set, but is it from the command line or the environment? 11001 11002 # Try to remove the string !SORT! from our list. 11003 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SORT!/} 11004 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 11005 # If it failed, the variable was not from the command line. Ignore it, 11006 # but warn the user (except for BASH, which is always set by the calling BASH). 11007 if test "xSORT" != xBASH; then 11008 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SORT from the environment. Use command line variables instead." >&5 11009 $as_echo "$as_me: WARNING: Ignoring value of SORT from the environment. Use command line variables instead." >&2;} 11010 fi 11011 # Try to locate tool using the code snippet 11012 for ac_prog in sort 11013 do 11014 # Extract the first word of "$ac_prog", so it can be a program name with args. 11015 set dummy $ac_prog; ac_word=$2 11016 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11017 $as_echo_n "checking for $ac_word... " >&6; } 11018 if ${ac_cv_path_SORT+:} false; then : 11019 $as_echo_n "(cached) " >&6 11020 else 11021 case $SORT in 11022 [\\/]* | ?:[\\/]*) 11023 ac_cv_path_SORT="$SORT" # Let the user override the test with a path. 11024 ;; 11025 *) 11026 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11027 for as_dir in $PATH 11028 do 11029 IFS=$as_save_IFS 11030 test -z "$as_dir" && as_dir=. 11031 for ac_exec_ext in '' $ac_executable_extensions; do 11032 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11033 ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext" 11034 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11035 break 2 11036 fi 11037 done 11038 done 11039 IFS=$as_save_IFS 11040 11041 ;; 11042 esac 11043 fi 11044 SORT=$ac_cv_path_SORT 11045 if test -n "$SORT"; then 11046 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5 11047 $as_echo "$SORT" >&6; } 11048 else 11049 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11050 $as_echo "no" >&6; } 11051 fi 11052 11053 11054 test -n "$SORT" && break 11055 done 11056 11057 else 11058 # If it succeeded, then it was overridden by the user. We will use it 11059 # for the tool. 11060 11061 # First remove it from the list of overridden variables, so we can test 11062 # for unknown variables in the end. 11063 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 11064 11065 # Check if we try to supply an empty value 11066 if test "x$SORT" = x; then 11067 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool SORT= (no value)" >&5 11068 $as_echo "$as_me: Setting user supplied tool SORT= (no value)" >&6;} 11069 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SORT" >&5 11070 $as_echo_n "checking for SORT... " >&6; } 11071 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 11072 $as_echo "disabled" >&6; } 11073 else 11074 # Check if the provided tool contains a complete path. 11075 tool_specified="$SORT" 11076 tool_basename="${tool_specified##*/}" 11077 if test "x$tool_basename" = "x$tool_specified"; then 11078 # A command without a complete path is provided, search $PATH. 11079 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SORT=$tool_basename" >&5 11080 $as_echo "$as_me: Will search for user supplied tool SORT=$tool_basename" >&6;} 11081 # Extract the first word of "$tool_basename", so it can be a program name with args. 11082 set dummy $tool_basename; ac_word=$2 11083 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11084 $as_echo_n "checking for $ac_word... " >&6; } 11085 if ${ac_cv_path_SORT+:} false; then : 11086 $as_echo_n "(cached) " >&6 11087 else 11088 case $SORT in 11089 [\\/]* | ?:[\\/]*) 11090 ac_cv_path_SORT="$SORT" # Let the user override the test with a path. 11091 ;; 11092 *) 11093 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11094 for as_dir in $PATH 11095 do 11096 IFS=$as_save_IFS 11097 test -z "$as_dir" && as_dir=. 11098 for ac_exec_ext in '' $ac_executable_extensions; do 11099 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11100 ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext" 11101 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11102 break 2 11103 fi 11104 done 11105 done 11106 IFS=$as_save_IFS 11107 11108 ;; 11109 esac 11110 fi 11111 SORT=$ac_cv_path_SORT 11112 if test -n "$SORT"; then 11113 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5 11114 $as_echo "$SORT" >&6; } 11115 else 11116 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11117 $as_echo "no" >&6; } 11118 fi 11119 11120 11121 if test "x$SORT" = x; then 11122 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 11123 fi 11124 else 11125 # Otherwise we believe it is a complete path. Use it as it is. 11126 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SORT=$tool_specified" >&5 11127 $as_echo "$as_me: Will use user supplied tool SORT=$tool_specified" >&6;} 11128 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SORT" >&5 11129 $as_echo_n "checking for SORT... " >&6; } 11130 if test ! -x "$tool_specified"; then 11131 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 11132 $as_echo "not found" >&6; } 11133 as_fn_error $? "User supplied tool SORT=$tool_specified does not exist or is not executable" "$LINENO" 5 11134 fi 11135 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 11136 $as_echo "$tool_specified" >&6; } 11137 fi 11138 fi 11139 fi 11140 11141 fi 11142 11143 11144 11145 if test "x$SORT" = x; then 11146 as_fn_error $? "Could not find required tool for SORT" "$LINENO" 5 11147 fi 11148 11149 11150 11151 11152 11153 # Publish this variable in the help. 11154 11155 11156 if [ -z "${TAIL+x}" ]; then 11157 # The variable is not set by user, try to locate tool using the code snippet 11158 for ac_prog in tail 11159 do 11160 # Extract the first word of "$ac_prog", so it can be a program name with args. 11161 set dummy $ac_prog; ac_word=$2 11162 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11163 $as_echo_n "checking for $ac_word... " >&6; } 11164 if ${ac_cv_path_TAIL+:} false; then : 11165 $as_echo_n "(cached) " >&6 11166 else 11167 case $TAIL in 11168 [\\/]* | ?:[\\/]*) 11169 ac_cv_path_TAIL="$TAIL" # Let the user override the test with a path. 11170 ;; 11171 *) 11172 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11173 for as_dir in $PATH 11174 do 11175 IFS=$as_save_IFS 11176 test -z "$as_dir" && as_dir=. 11177 for ac_exec_ext in '' $ac_executable_extensions; do 11178 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11179 ac_cv_path_TAIL="$as_dir/$ac_word$ac_exec_ext" 11180 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11181 break 2 11182 fi 11183 done 11184 done 11185 IFS=$as_save_IFS 11186 11187 ;; 11188 esac 11189 fi 11190 TAIL=$ac_cv_path_TAIL 11191 if test -n "$TAIL"; then 11192 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAIL" >&5 11193 $as_echo "$TAIL" >&6; } 11194 else 11195 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11196 $as_echo "no" >&6; } 11197 fi 11198 11199 11200 test -n "$TAIL" && break 11201 done 11202 11203 else 11204 # The variable is set, but is it from the command line or the environment? 11205 11206 # Try to remove the string !TAIL! from our list. 11207 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TAIL!/} 11208 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 11209 # If it failed, the variable was not from the command line. Ignore it, 11210 # but warn the user (except for BASH, which is always set by the calling BASH). 11211 if test "xTAIL" != xBASH; then 11212 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TAIL from the environment. Use command line variables instead." >&5 11213 $as_echo "$as_me: WARNING: Ignoring value of TAIL from the environment. Use command line variables instead." >&2;} 11214 fi 11215 # Try to locate tool using the code snippet 11216 for ac_prog in tail 11217 do 11218 # Extract the first word of "$ac_prog", so it can be a program name with args. 11219 set dummy $ac_prog; ac_word=$2 11220 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11221 $as_echo_n "checking for $ac_word... " >&6; } 11222 if ${ac_cv_path_TAIL+:} false; then : 11223 $as_echo_n "(cached) " >&6 11224 else 11225 case $TAIL in 11226 [\\/]* | ?:[\\/]*) 11227 ac_cv_path_TAIL="$TAIL" # Let the user override the test with a path. 11228 ;; 11229 *) 11230 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11231 for as_dir in $PATH 11232 do 11233 IFS=$as_save_IFS 11234 test -z "$as_dir" && as_dir=. 11235 for ac_exec_ext in '' $ac_executable_extensions; do 11236 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11237 ac_cv_path_TAIL="$as_dir/$ac_word$ac_exec_ext" 11238 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11239 break 2 11240 fi 11241 done 11242 done 11243 IFS=$as_save_IFS 11244 11245 ;; 11246 esac 11247 fi 11248 TAIL=$ac_cv_path_TAIL 11249 if test -n "$TAIL"; then 11250 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAIL" >&5 11251 $as_echo "$TAIL" >&6; } 11252 else 11253 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11254 $as_echo "no" >&6; } 11255 fi 11256 11257 11258 test -n "$TAIL" && break 11259 done 11260 11261 else 11262 # If it succeeded, then it was overridden by the user. We will use it 11263 # for the tool. 11264 11265 # First remove it from the list of overridden variables, so we can test 11266 # for unknown variables in the end. 11267 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 11268 11269 # Check if we try to supply an empty value 11270 if test "x$TAIL" = x; then 11271 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TAIL= (no value)" >&5 11272 $as_echo "$as_me: Setting user supplied tool TAIL= (no value)" >&6;} 11273 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAIL" >&5 11274 $as_echo_n "checking for TAIL... " >&6; } 11275 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 11276 $as_echo "disabled" >&6; } 11277 else 11278 # Check if the provided tool contains a complete path. 11279 tool_specified="$TAIL" 11280 tool_basename="${tool_specified##*/}" 11281 if test "x$tool_basename" = "x$tool_specified"; then 11282 # A command without a complete path is provided, search $PATH. 11283 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TAIL=$tool_basename" >&5 11284 $as_echo "$as_me: Will search for user supplied tool TAIL=$tool_basename" >&6;} 11285 # Extract the first word of "$tool_basename", so it can be a program name with args. 11286 set dummy $tool_basename; ac_word=$2 11287 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11288 $as_echo_n "checking for $ac_word... " >&6; } 11289 if ${ac_cv_path_TAIL+:} false; then : 11290 $as_echo_n "(cached) " >&6 11291 else 11292 case $TAIL in 11293 [\\/]* | ?:[\\/]*) 11294 ac_cv_path_TAIL="$TAIL" # Let the user override the test with a path. 11295 ;; 11296 *) 11297 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11298 for as_dir in $PATH 11299 do 11300 IFS=$as_save_IFS 11301 test -z "$as_dir" && as_dir=. 11302 for ac_exec_ext in '' $ac_executable_extensions; do 11303 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11304 ac_cv_path_TAIL="$as_dir/$ac_word$ac_exec_ext" 11305 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11306 break 2 11307 fi 11308 done 11309 done 11310 IFS=$as_save_IFS 11311 11312 ;; 11313 esac 11314 fi 11315 TAIL=$ac_cv_path_TAIL 11316 if test -n "$TAIL"; then 11317 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAIL" >&5 11318 $as_echo "$TAIL" >&6; } 11319 else 11320 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11321 $as_echo "no" >&6; } 11322 fi 11323 11324 11325 if test "x$TAIL" = x; then 11326 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 11327 fi 11328 else 11329 # Otherwise we believe it is a complete path. Use it as it is. 11330 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TAIL=$tool_specified" >&5 11331 $as_echo "$as_me: Will use user supplied tool TAIL=$tool_specified" >&6;} 11332 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAIL" >&5 11333 $as_echo_n "checking for TAIL... " >&6; } 11334 if test ! -x "$tool_specified"; then 11335 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 11336 $as_echo "not found" >&6; } 11337 as_fn_error $? "User supplied tool TAIL=$tool_specified does not exist or is not executable" "$LINENO" 5 11338 fi 11339 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 11340 $as_echo "$tool_specified" >&6; } 11341 fi 11342 fi 11343 fi 11344 11345 fi 11346 11347 11348 11349 if test "x$TAIL" = x; then 11350 as_fn_error $? "Could not find required tool for TAIL" "$LINENO" 5 11351 fi 11352 11353 11354 11355 11356 11357 # Publish this variable in the help. 11358 11359 11360 if [ -z "${TAR+x}" ]; then 11361 # The variable is not set by user, try to locate tool using the code snippet 11362 for ac_prog in gtar tar 11363 do 11364 # Extract the first word of "$ac_prog", so it can be a program name with args. 11365 set dummy $ac_prog; ac_word=$2 11366 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11367 $as_echo_n "checking for $ac_word... " >&6; } 11368 if ${ac_cv_path_TAR+:} false; then : 11369 $as_echo_n "(cached) " >&6 11370 else 11371 case $TAR in 11372 [\\/]* | ?:[\\/]*) 11373 ac_cv_path_TAR="$TAR" # Let the user override the test with a path. 11374 ;; 11375 *) 11376 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11377 for as_dir in $PATH 11378 do 11379 IFS=$as_save_IFS 11380 test -z "$as_dir" && as_dir=. 11381 for ac_exec_ext in '' $ac_executable_extensions; do 11382 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11383 ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext" 11384 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11385 break 2 11386 fi 11387 done 11388 done 11389 IFS=$as_save_IFS 11390 11391 ;; 11392 esac 11393 fi 11394 TAR=$ac_cv_path_TAR 11395 if test -n "$TAR"; then 11396 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5 11397 $as_echo "$TAR" >&6; } 11398 else 11399 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11400 $as_echo "no" >&6; } 11401 fi 11402 11403 11404 test -n "$TAR" && break 11405 done 11406 11407 else 11408 # The variable is set, but is it from the command line or the environment? 11409 11410 # Try to remove the string !TAR! from our list. 11411 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TAR!/} 11412 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 11413 # If it failed, the variable was not from the command line. Ignore it, 11414 # but warn the user (except for BASH, which is always set by the calling BASH). 11415 if test "xTAR" != xBASH; then 11416 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TAR from the environment. Use command line variables instead." >&5 11417 $as_echo "$as_me: WARNING: Ignoring value of TAR from the environment. Use command line variables instead." >&2;} 11418 fi 11419 # Try to locate tool using the code snippet 11420 for ac_prog in gtar tar 11421 do 11422 # Extract the first word of "$ac_prog", so it can be a program name with args. 11423 set dummy $ac_prog; ac_word=$2 11424 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11425 $as_echo_n "checking for $ac_word... " >&6; } 11426 if ${ac_cv_path_TAR+:} false; then : 11427 $as_echo_n "(cached) " >&6 11428 else 11429 case $TAR in 11430 [\\/]* | ?:[\\/]*) 11431 ac_cv_path_TAR="$TAR" # Let the user override the test with a path. 11432 ;; 11433 *) 11434 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11435 for as_dir in $PATH 11436 do 11437 IFS=$as_save_IFS 11438 test -z "$as_dir" && as_dir=. 11439 for ac_exec_ext in '' $ac_executable_extensions; do 11440 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11441 ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext" 11442 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11443 break 2 11444 fi 11445 done 11446 done 11447 IFS=$as_save_IFS 11448 11449 ;; 11450 esac 11451 fi 11452 TAR=$ac_cv_path_TAR 11453 if test -n "$TAR"; then 11454 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5 11455 $as_echo "$TAR" >&6; } 11456 else 11457 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11458 $as_echo "no" >&6; } 11459 fi 11460 11461 11462 test -n "$TAR" && break 11463 done 11464 11465 else 11466 # If it succeeded, then it was overridden by the user. We will use it 11467 # for the tool. 11468 11469 # First remove it from the list of overridden variables, so we can test 11470 # for unknown variables in the end. 11471 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 11472 11473 # Check if we try to supply an empty value 11474 if test "x$TAR" = x; then 11475 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TAR= (no value)" >&5 11476 $as_echo "$as_me: Setting user supplied tool TAR= (no value)" >&6;} 11477 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAR" >&5 11478 $as_echo_n "checking for TAR... " >&6; } 11479 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 11480 $as_echo "disabled" >&6; } 11481 else 11482 # Check if the provided tool contains a complete path. 11483 tool_specified="$TAR" 11484 tool_basename="${tool_specified##*/}" 11485 if test "x$tool_basename" = "x$tool_specified"; then 11486 # A command without a complete path is provided, search $PATH. 11487 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TAR=$tool_basename" >&5 11488 $as_echo "$as_me: Will search for user supplied tool TAR=$tool_basename" >&6;} 11489 # Extract the first word of "$tool_basename", so it can be a program name with args. 11490 set dummy $tool_basename; ac_word=$2 11491 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11492 $as_echo_n "checking for $ac_word... " >&6; } 11493 if ${ac_cv_path_TAR+:} false; then : 11494 $as_echo_n "(cached) " >&6 11495 else 11496 case $TAR in 11497 [\\/]* | ?:[\\/]*) 11498 ac_cv_path_TAR="$TAR" # Let the user override the test with a path. 11499 ;; 11500 *) 11501 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11502 for as_dir in $PATH 11503 do 11504 IFS=$as_save_IFS 11505 test -z "$as_dir" && as_dir=. 11506 for ac_exec_ext in '' $ac_executable_extensions; do 11507 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11508 ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext" 11509 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11510 break 2 11511 fi 11512 done 11513 done 11514 IFS=$as_save_IFS 11515 11516 ;; 11517 esac 11518 fi 11519 TAR=$ac_cv_path_TAR 11520 if test -n "$TAR"; then 11521 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5 11522 $as_echo "$TAR" >&6; } 11523 else 11524 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11525 $as_echo "no" >&6; } 11526 fi 11527 11528 11529 if test "x$TAR" = x; then 11530 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 11531 fi 11532 else 11533 # Otherwise we believe it is a complete path. Use it as it is. 11534 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TAR=$tool_specified" >&5 11535 $as_echo "$as_me: Will use user supplied tool TAR=$tool_specified" >&6;} 11536 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAR" >&5 11537 $as_echo_n "checking for TAR... " >&6; } 11538 if test ! -x "$tool_specified"; then 11539 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 11540 $as_echo "not found" >&6; } 11541 as_fn_error $? "User supplied tool TAR=$tool_specified does not exist or is not executable" "$LINENO" 5 11542 fi 11543 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 11544 $as_echo "$tool_specified" >&6; } 11545 fi 11546 fi 11547 fi 11548 11549 fi 11550 11551 11552 11553 if test "x$TAR" = x; then 11554 as_fn_error $? "Could not find required tool for TAR" "$LINENO" 5 11555 fi 11556 11557 11558 11559 11560 11561 # Publish this variable in the help. 11562 11563 11564 if [ -z "${TEE+x}" ]; then 11565 # The variable is not set by user, try to locate tool using the code snippet 11566 for ac_prog in tee 11567 do 11568 # Extract the first word of "$ac_prog", so it can be a program name with args. 11569 set dummy $ac_prog; ac_word=$2 11570 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11571 $as_echo_n "checking for $ac_word... " >&6; } 11572 if ${ac_cv_path_TEE+:} false; then : 11573 $as_echo_n "(cached) " >&6 11574 else 11575 case $TEE in 11576 [\\/]* | ?:[\\/]*) 11577 ac_cv_path_TEE="$TEE" # Let the user override the test with a path. 11578 ;; 11579 *) 11580 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11581 for as_dir in $PATH 11582 do 11583 IFS=$as_save_IFS 11584 test -z "$as_dir" && as_dir=. 11585 for ac_exec_ext in '' $ac_executable_extensions; do 11586 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11587 ac_cv_path_TEE="$as_dir/$ac_word$ac_exec_ext" 11588 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11589 break 2 11590 fi 11591 done 11592 done 11593 IFS=$as_save_IFS 11594 11595 ;; 11596 esac 11597 fi 11598 TEE=$ac_cv_path_TEE 11599 if test -n "$TEE"; then 11600 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5 11601 $as_echo "$TEE" >&6; } 11602 else 11603 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11604 $as_echo "no" >&6; } 11605 fi 11606 11607 11608 test -n "$TEE" && break 11609 done 11610 11611 else 11612 # The variable is set, but is it from the command line or the environment? 11613 11614 # Try to remove the string !TEE! from our list. 11615 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TEE!/} 11616 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 11617 # If it failed, the variable was not from the command line. Ignore it, 11618 # but warn the user (except for BASH, which is always set by the calling BASH). 11619 if test "xTEE" != xBASH; then 11620 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TEE from the environment. Use command line variables instead." >&5 11621 $as_echo "$as_me: WARNING: Ignoring value of TEE from the environment. Use command line variables instead." >&2;} 11622 fi 11623 # Try to locate tool using the code snippet 11624 for ac_prog in tee 11625 do 11626 # Extract the first word of "$ac_prog", so it can be a program name with args. 11627 set dummy $ac_prog; ac_word=$2 11628 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11629 $as_echo_n "checking for $ac_word... " >&6; } 11630 if ${ac_cv_path_TEE+:} false; then : 11631 $as_echo_n "(cached) " >&6 11632 else 11633 case $TEE in 11634 [\\/]* | ?:[\\/]*) 11635 ac_cv_path_TEE="$TEE" # Let the user override the test with a path. 11636 ;; 11637 *) 11638 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11639 for as_dir in $PATH 11640 do 11641 IFS=$as_save_IFS 11642 test -z "$as_dir" && as_dir=. 11643 for ac_exec_ext in '' $ac_executable_extensions; do 11644 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11645 ac_cv_path_TEE="$as_dir/$ac_word$ac_exec_ext" 11646 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11647 break 2 11648 fi 11649 done 11650 done 11651 IFS=$as_save_IFS 11652 11653 ;; 11654 esac 11655 fi 11656 TEE=$ac_cv_path_TEE 11657 if test -n "$TEE"; then 11658 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5 11659 $as_echo "$TEE" >&6; } 11660 else 11661 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11662 $as_echo "no" >&6; } 11663 fi 11664 11665 11666 test -n "$TEE" && break 11667 done 11668 11669 else 11670 # If it succeeded, then it was overridden by the user. We will use it 11671 # for the tool. 11672 11673 # First remove it from the list of overridden variables, so we can test 11674 # for unknown variables in the end. 11675 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 11676 11677 # Check if we try to supply an empty value 11678 if test "x$TEE" = x; then 11679 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TEE= (no value)" >&5 11680 $as_echo "$as_me: Setting user supplied tool TEE= (no value)" >&6;} 11681 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TEE" >&5 11682 $as_echo_n "checking for TEE... " >&6; } 11683 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 11684 $as_echo "disabled" >&6; } 11685 else 11686 # Check if the provided tool contains a complete path. 11687 tool_specified="$TEE" 11688 tool_basename="${tool_specified##*/}" 11689 if test "x$tool_basename" = "x$tool_specified"; then 11690 # A command without a complete path is provided, search $PATH. 11691 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TEE=$tool_basename" >&5 11692 $as_echo "$as_me: Will search for user supplied tool TEE=$tool_basename" >&6;} 11693 # Extract the first word of "$tool_basename", so it can be a program name with args. 11694 set dummy $tool_basename; ac_word=$2 11695 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11696 $as_echo_n "checking for $ac_word... " >&6; } 11697 if ${ac_cv_path_TEE+:} false; then : 11698 $as_echo_n "(cached) " >&6 11699 else 11700 case $TEE in 11701 [\\/]* | ?:[\\/]*) 11702 ac_cv_path_TEE="$TEE" # Let the user override the test with a path. 11703 ;; 11704 *) 11705 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11706 for as_dir in $PATH 11707 do 11708 IFS=$as_save_IFS 11709 test -z "$as_dir" && as_dir=. 11710 for ac_exec_ext in '' $ac_executable_extensions; do 11711 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11712 ac_cv_path_TEE="$as_dir/$ac_word$ac_exec_ext" 11713 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11714 break 2 11715 fi 11716 done 11717 done 11718 IFS=$as_save_IFS 11719 11720 ;; 11721 esac 11722 fi 11723 TEE=$ac_cv_path_TEE 11724 if test -n "$TEE"; then 11725 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5 11726 $as_echo "$TEE" >&6; } 11727 else 11728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11729 $as_echo "no" >&6; } 11730 fi 11731 11732 11733 if test "x$TEE" = x; then 11734 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 11735 fi 11736 else 11737 # Otherwise we believe it is a complete path. Use it as it is. 11738 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TEE=$tool_specified" >&5 11739 $as_echo "$as_me: Will use user supplied tool TEE=$tool_specified" >&6;} 11740 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TEE" >&5 11741 $as_echo_n "checking for TEE... " >&6; } 11742 if test ! -x "$tool_specified"; then 11743 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 11744 $as_echo "not found" >&6; } 11745 as_fn_error $? "User supplied tool TEE=$tool_specified does not exist or is not executable" "$LINENO" 5 11746 fi 11747 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 11748 $as_echo "$tool_specified" >&6; } 11749 fi 11750 fi 11751 fi 11752 11753 fi 11754 11755 11756 11757 if test "x$TEE" = x; then 11758 as_fn_error $? "Could not find required tool for TEE" "$LINENO" 5 11759 fi 11760 11761 11762 11763 11764 11765 # Publish this variable in the help. 11766 11767 11768 if [ -z "${TOUCH+x}" ]; then 11769 # The variable is not set by user, try to locate tool using the code snippet 11770 for ac_prog in touch 11771 do 11772 # Extract the first word of "$ac_prog", so it can be a program name with args. 11773 set dummy $ac_prog; ac_word=$2 11774 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11775 $as_echo_n "checking for $ac_word... " >&6; } 11776 if ${ac_cv_path_TOUCH+:} false; then : 11777 $as_echo_n "(cached) " >&6 11778 else 11779 case $TOUCH in 11780 [\\/]* | ?:[\\/]*) 11781 ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path. 11782 ;; 11783 *) 11784 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11785 for as_dir in $PATH 11786 do 11787 IFS=$as_save_IFS 11788 test -z "$as_dir" && as_dir=. 11789 for ac_exec_ext in '' $ac_executable_extensions; do 11790 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11791 ac_cv_path_TOUCH="$as_dir/$ac_word$ac_exec_ext" 11792 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11793 break 2 11794 fi 11795 done 11796 done 11797 IFS=$as_save_IFS 11798 11799 ;; 11800 esac 11801 fi 11802 TOUCH=$ac_cv_path_TOUCH 11803 if test -n "$TOUCH"; then 11804 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOUCH" >&5 11805 $as_echo "$TOUCH" >&6; } 11806 else 11807 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11808 $as_echo "no" >&6; } 11809 fi 11810 11811 11812 test -n "$TOUCH" && break 11813 done 11814 11815 else 11816 # The variable is set, but is it from the command line or the environment? 11817 11818 # Try to remove the string !TOUCH! from our list. 11819 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TOUCH!/} 11820 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 11821 # If it failed, the variable was not from the command line. Ignore it, 11822 # but warn the user (except for BASH, which is always set by the calling BASH). 11823 if test "xTOUCH" != xBASH; then 11824 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TOUCH from the environment. Use command line variables instead." >&5 11825 $as_echo "$as_me: WARNING: Ignoring value of TOUCH from the environment. Use command line variables instead." >&2;} 11826 fi 11827 # Try to locate tool using the code snippet 11828 for ac_prog in touch 11829 do 11830 # Extract the first word of "$ac_prog", so it can be a program name with args. 11831 set dummy $ac_prog; ac_word=$2 11832 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11833 $as_echo_n "checking for $ac_word... " >&6; } 11834 if ${ac_cv_path_TOUCH+:} false; then : 11835 $as_echo_n "(cached) " >&6 11836 else 11837 case $TOUCH in 11838 [\\/]* | ?:[\\/]*) 11839 ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path. 11840 ;; 11841 *) 11842 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11843 for as_dir in $PATH 11844 do 11845 IFS=$as_save_IFS 11846 test -z "$as_dir" && as_dir=. 11847 for ac_exec_ext in '' $ac_executable_extensions; do 11848 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11849 ac_cv_path_TOUCH="$as_dir/$ac_word$ac_exec_ext" 11850 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11851 break 2 11852 fi 11853 done 11854 done 11855 IFS=$as_save_IFS 11856 11857 ;; 11858 esac 11859 fi 11860 TOUCH=$ac_cv_path_TOUCH 11861 if test -n "$TOUCH"; then 11862 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOUCH" >&5 11863 $as_echo "$TOUCH" >&6; } 11864 else 11865 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11866 $as_echo "no" >&6; } 11867 fi 11868 11869 11870 test -n "$TOUCH" && break 11871 done 11872 11873 else 11874 # If it succeeded, then it was overridden by the user. We will use it 11875 # for the tool. 11876 11877 # First remove it from the list of overridden variables, so we can test 11878 # for unknown variables in the end. 11879 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 11880 11881 # Check if we try to supply an empty value 11882 if test "x$TOUCH" = x; then 11883 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TOUCH= (no value)" >&5 11884 $as_echo "$as_me: Setting user supplied tool TOUCH= (no value)" >&6;} 11885 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TOUCH" >&5 11886 $as_echo_n "checking for TOUCH... " >&6; } 11887 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 11888 $as_echo "disabled" >&6; } 11889 else 11890 # Check if the provided tool contains a complete path. 11891 tool_specified="$TOUCH" 11892 tool_basename="${tool_specified##*/}" 11893 if test "x$tool_basename" = "x$tool_specified"; then 11894 # A command without a complete path is provided, search $PATH. 11895 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TOUCH=$tool_basename" >&5 11896 $as_echo "$as_me: Will search for user supplied tool TOUCH=$tool_basename" >&6;} 11897 # Extract the first word of "$tool_basename", so it can be a program name with args. 11898 set dummy $tool_basename; ac_word=$2 11899 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11900 $as_echo_n "checking for $ac_word... " >&6; } 11901 if ${ac_cv_path_TOUCH+:} false; then : 11902 $as_echo_n "(cached) " >&6 11903 else 11904 case $TOUCH in 11905 [\\/]* | ?:[\\/]*) 11906 ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path. 11907 ;; 11908 *) 11909 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11910 for as_dir in $PATH 11911 do 11912 IFS=$as_save_IFS 11913 test -z "$as_dir" && as_dir=. 11914 for ac_exec_ext in '' $ac_executable_extensions; do 11915 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11916 ac_cv_path_TOUCH="$as_dir/$ac_word$ac_exec_ext" 11917 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11918 break 2 11919 fi 11920 done 11921 done 11922 IFS=$as_save_IFS 11923 11924 ;; 11925 esac 11926 fi 11927 TOUCH=$ac_cv_path_TOUCH 11928 if test -n "$TOUCH"; then 11929 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOUCH" >&5 11930 $as_echo "$TOUCH" >&6; } 11931 else 11932 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11933 $as_echo "no" >&6; } 11934 fi 11935 11936 11937 if test "x$TOUCH" = x; then 11938 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 11939 fi 11940 else 11941 # Otherwise we believe it is a complete path. Use it as it is. 11942 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TOUCH=$tool_specified" >&5 11943 $as_echo "$as_me: Will use user supplied tool TOUCH=$tool_specified" >&6;} 11944 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TOUCH" >&5 11945 $as_echo_n "checking for TOUCH... " >&6; } 11946 if test ! -x "$tool_specified"; then 11947 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 11948 $as_echo "not found" >&6; } 11949 as_fn_error $? "User supplied tool TOUCH=$tool_specified does not exist or is not executable" "$LINENO" 5 11950 fi 11951 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 11952 $as_echo "$tool_specified" >&6; } 11953 fi 11954 fi 11955 fi 11956 11957 fi 11958 11959 11960 11961 if test "x$TOUCH" = x; then 11962 as_fn_error $? "Could not find required tool for TOUCH" "$LINENO" 5 11963 fi 11964 11965 11966 11967 11968 11969 # Publish this variable in the help. 11970 11971 11972 if [ -z "${TR+x}" ]; then 11973 # The variable is not set by user, try to locate tool using the code snippet 11974 for ac_prog in tr 11975 do 11976 # Extract the first word of "$ac_prog", so it can be a program name with args. 11977 set dummy $ac_prog; ac_word=$2 11978 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11979 $as_echo_n "checking for $ac_word... " >&6; } 11980 if ${ac_cv_path_TR+:} false; then : 11981 $as_echo_n "(cached) " >&6 11982 else 11983 case $TR in 11984 [\\/]* | ?:[\\/]*) 11985 ac_cv_path_TR="$TR" # Let the user override the test with a path. 11986 ;; 11987 *) 11988 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11989 for as_dir in $PATH 11990 do 11991 IFS=$as_save_IFS 11992 test -z "$as_dir" && as_dir=. 11993 for ac_exec_ext in '' $ac_executable_extensions; do 11994 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11995 ac_cv_path_TR="$as_dir/$ac_word$ac_exec_ext" 11996 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11997 break 2 11998 fi 11999 done 12000 done 12001 IFS=$as_save_IFS 12002 12003 ;; 12004 esac 12005 fi 12006 TR=$ac_cv_path_TR 12007 if test -n "$TR"; then 12008 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TR" >&5 12009 $as_echo "$TR" >&6; } 12010 else 12011 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12012 $as_echo "no" >&6; } 12013 fi 12014 12015 12016 test -n "$TR" && break 12017 done 12018 12019 else 12020 # The variable is set, but is it from the command line or the environment? 12021 12022 # Try to remove the string !TR! from our list. 12023 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TR!/} 12024 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 12025 # If it failed, the variable was not from the command line. Ignore it, 12026 # but warn the user (except for BASH, which is always set by the calling BASH). 12027 if test "xTR" != xBASH; then 12028 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TR from the environment. Use command line variables instead." >&5 12029 $as_echo "$as_me: WARNING: Ignoring value of TR from the environment. Use command line variables instead." >&2;} 12030 fi 12031 # Try to locate tool using the code snippet 12032 for ac_prog in tr 12033 do 12034 # Extract the first word of "$ac_prog", so it can be a program name with args. 12035 set dummy $ac_prog; ac_word=$2 12036 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12037 $as_echo_n "checking for $ac_word... " >&6; } 12038 if ${ac_cv_path_TR+:} false; then : 12039 $as_echo_n "(cached) " >&6 12040 else 12041 case $TR in 12042 [\\/]* | ?:[\\/]*) 12043 ac_cv_path_TR="$TR" # Let the user override the test with a path. 12044 ;; 12045 *) 12046 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12047 for as_dir in $PATH 12048 do 12049 IFS=$as_save_IFS 12050 test -z "$as_dir" && as_dir=. 12051 for ac_exec_ext in '' $ac_executable_extensions; do 12052 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12053 ac_cv_path_TR="$as_dir/$ac_word$ac_exec_ext" 12054 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12055 break 2 12056 fi 12057 done 12058 done 12059 IFS=$as_save_IFS 12060 12061 ;; 12062 esac 12063 fi 12064 TR=$ac_cv_path_TR 12065 if test -n "$TR"; then 12066 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TR" >&5 12067 $as_echo "$TR" >&6; } 12068 else 12069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12070 $as_echo "no" >&6; } 12071 fi 12072 12073 12074 test -n "$TR" && break 12075 done 12076 12077 else 12078 # If it succeeded, then it was overridden by the user. We will use it 12079 # for the tool. 12080 12081 # First remove it from the list of overridden variables, so we can test 12082 # for unknown variables in the end. 12083 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 12084 12085 # Check if we try to supply an empty value 12086 if test "x$TR" = x; then 12087 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TR= (no value)" >&5 12088 $as_echo "$as_me: Setting user supplied tool TR= (no value)" >&6;} 12089 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TR" >&5 12090 $as_echo_n "checking for TR... " >&6; } 12091 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 12092 $as_echo "disabled" >&6; } 12093 else 12094 # Check if the provided tool contains a complete path. 12095 tool_specified="$TR" 12096 tool_basename="${tool_specified##*/}" 12097 if test "x$tool_basename" = "x$tool_specified"; then 12098 # A command without a complete path is provided, search $PATH. 12099 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TR=$tool_basename" >&5 12100 $as_echo "$as_me: Will search for user supplied tool TR=$tool_basename" >&6;} 12101 # Extract the first word of "$tool_basename", so it can be a program name with args. 12102 set dummy $tool_basename; ac_word=$2 12103 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12104 $as_echo_n "checking for $ac_word... " >&6; } 12105 if ${ac_cv_path_TR+:} false; then : 12106 $as_echo_n "(cached) " >&6 12107 else 12108 case $TR in 12109 [\\/]* | ?:[\\/]*) 12110 ac_cv_path_TR="$TR" # Let the user override the test with a path. 12111 ;; 12112 *) 12113 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12114 for as_dir in $PATH 12115 do 12116 IFS=$as_save_IFS 12117 test -z "$as_dir" && as_dir=. 12118 for ac_exec_ext in '' $ac_executable_extensions; do 12119 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12120 ac_cv_path_TR="$as_dir/$ac_word$ac_exec_ext" 12121 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12122 break 2 12123 fi 12124 done 12125 done 12126 IFS=$as_save_IFS 12127 12128 ;; 12129 esac 12130 fi 12131 TR=$ac_cv_path_TR 12132 if test -n "$TR"; then 12133 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TR" >&5 12134 $as_echo "$TR" >&6; } 12135 else 12136 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12137 $as_echo "no" >&6; } 12138 fi 12139 12140 12141 if test "x$TR" = x; then 12142 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 12143 fi 12144 else 12145 # Otherwise we believe it is a complete path. Use it as it is. 12146 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TR=$tool_specified" >&5 12147 $as_echo "$as_me: Will use user supplied tool TR=$tool_specified" >&6;} 12148 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TR" >&5 12149 $as_echo_n "checking for TR... " >&6; } 12150 if test ! -x "$tool_specified"; then 12151 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 12152 $as_echo "not found" >&6; } 12153 as_fn_error $? "User supplied tool TR=$tool_specified does not exist or is not executable" "$LINENO" 5 12154 fi 12155 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 12156 $as_echo "$tool_specified" >&6; } 12157 fi 12158 fi 12159 fi 12160 12161 fi 12162 12163 12164 12165 if test "x$TR" = x; then 12166 as_fn_error $? "Could not find required tool for TR" "$LINENO" 5 12167 fi 12168 12169 12170 12171 12172 12173 # Publish this variable in the help. 12174 12175 12176 if [ -z "${UNAME+x}" ]; then 12177 # The variable is not set by user, try to locate tool using the code snippet 12178 for ac_prog in uname 12179 do 12180 # Extract the first word of "$ac_prog", so it can be a program name with args. 12181 set dummy $ac_prog; ac_word=$2 12182 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12183 $as_echo_n "checking for $ac_word... " >&6; } 12184 if ${ac_cv_path_UNAME+:} false; then : 12185 $as_echo_n "(cached) " >&6 12186 else 12187 case $UNAME in 12188 [\\/]* | ?:[\\/]*) 12189 ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path. 12190 ;; 12191 *) 12192 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12193 for as_dir in $PATH 12194 do 12195 IFS=$as_save_IFS 12196 test -z "$as_dir" && as_dir=. 12197 for ac_exec_ext in '' $ac_executable_extensions; do 12198 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12199 ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext" 12200 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12201 break 2 12202 fi 12203 done 12204 done 12205 IFS=$as_save_IFS 12206 12207 ;; 12208 esac 12209 fi 12210 UNAME=$ac_cv_path_UNAME 12211 if test -n "$UNAME"; then 12212 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5 12213 $as_echo "$UNAME" >&6; } 12214 else 12215 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12216 $as_echo "no" >&6; } 12217 fi 12218 12219 12220 test -n "$UNAME" && break 12221 done 12222 12223 else 12224 # The variable is set, but is it from the command line or the environment? 12225 12226 # Try to remove the string !UNAME! from our list. 12227 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!UNAME!/} 12228 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 12229 # If it failed, the variable was not from the command line. Ignore it, 12230 # but warn the user (except for BASH, which is always set by the calling BASH). 12231 if test "xUNAME" != xBASH; then 12232 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of UNAME from the environment. Use command line variables instead." >&5 12233 $as_echo "$as_me: WARNING: Ignoring value of UNAME from the environment. Use command line variables instead." >&2;} 12234 fi 12235 # Try to locate tool using the code snippet 12236 for ac_prog in uname 12237 do 12238 # Extract the first word of "$ac_prog", so it can be a program name with args. 12239 set dummy $ac_prog; ac_word=$2 12240 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12241 $as_echo_n "checking for $ac_word... " >&6; } 12242 if ${ac_cv_path_UNAME+:} false; then : 12243 $as_echo_n "(cached) " >&6 12244 else 12245 case $UNAME in 12246 [\\/]* | ?:[\\/]*) 12247 ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path. 12248 ;; 12249 *) 12250 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12251 for as_dir in $PATH 12252 do 12253 IFS=$as_save_IFS 12254 test -z "$as_dir" && as_dir=. 12255 for ac_exec_ext in '' $ac_executable_extensions; do 12256 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12257 ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext" 12258 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12259 break 2 12260 fi 12261 done 12262 done 12263 IFS=$as_save_IFS 12264 12265 ;; 12266 esac 12267 fi 12268 UNAME=$ac_cv_path_UNAME 12269 if test -n "$UNAME"; then 12270 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5 12271 $as_echo "$UNAME" >&6; } 12272 else 12273 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12274 $as_echo "no" >&6; } 12275 fi 12276 12277 12278 test -n "$UNAME" && break 12279 done 12280 12281 else 12282 # If it succeeded, then it was overridden by the user. We will use it 12283 # for the tool. 12284 12285 # First remove it from the list of overridden variables, so we can test 12286 # for unknown variables in the end. 12287 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 12288 12289 # Check if we try to supply an empty value 12290 if test "x$UNAME" = x; then 12291 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool UNAME= (no value)" >&5 12292 $as_echo "$as_me: Setting user supplied tool UNAME= (no value)" >&6;} 12293 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNAME" >&5 12294 $as_echo_n "checking for UNAME... " >&6; } 12295 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 12296 $as_echo "disabled" >&6; } 12297 else 12298 # Check if the provided tool contains a complete path. 12299 tool_specified="$UNAME" 12300 tool_basename="${tool_specified##*/}" 12301 if test "x$tool_basename" = "x$tool_specified"; then 12302 # A command without a complete path is provided, search $PATH. 12303 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool UNAME=$tool_basename" >&5 12304 $as_echo "$as_me: Will search for user supplied tool UNAME=$tool_basename" >&6;} 12305 # Extract the first word of "$tool_basename", so it can be a program name with args. 12306 set dummy $tool_basename; ac_word=$2 12307 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12308 $as_echo_n "checking for $ac_word... " >&6; } 12309 if ${ac_cv_path_UNAME+:} false; then : 12310 $as_echo_n "(cached) " >&6 12311 else 12312 case $UNAME in 12313 [\\/]* | ?:[\\/]*) 12314 ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path. 12315 ;; 12316 *) 12317 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12318 for as_dir in $PATH 12319 do 12320 IFS=$as_save_IFS 12321 test -z "$as_dir" && as_dir=. 12322 for ac_exec_ext in '' $ac_executable_extensions; do 12323 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12324 ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext" 12325 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12326 break 2 12327 fi 12328 done 12329 done 12330 IFS=$as_save_IFS 12331 12332 ;; 12333 esac 12334 fi 12335 UNAME=$ac_cv_path_UNAME 12336 if test -n "$UNAME"; then 12337 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5 12338 $as_echo "$UNAME" >&6; } 12339 else 12340 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12341 $as_echo "no" >&6; } 12342 fi 12343 12344 12345 if test "x$UNAME" = x; then 12346 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 12347 fi 12348 else 12349 # Otherwise we believe it is a complete path. Use it as it is. 12350 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool UNAME=$tool_specified" >&5 12351 $as_echo "$as_me: Will use user supplied tool UNAME=$tool_specified" >&6;} 12352 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNAME" >&5 12353 $as_echo_n "checking for UNAME... " >&6; } 12354 if test ! -x "$tool_specified"; then 12355 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 12356 $as_echo "not found" >&6; } 12357 as_fn_error $? "User supplied tool UNAME=$tool_specified does not exist or is not executable" "$LINENO" 5 12358 fi 12359 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 12360 $as_echo "$tool_specified" >&6; } 12361 fi 12362 fi 12363 fi 12364 12365 fi 12366 12367 12368 12369 if test "x$UNAME" = x; then 12370 as_fn_error $? "Could not find required tool for UNAME" "$LINENO" 5 12371 fi 12372 12373 12374 12375 12376 12377 # Publish this variable in the help. 12378 12379 12380 if [ -z "${UNIQ+x}" ]; then 12381 # The variable is not set by user, try to locate tool using the code snippet 12382 for ac_prog in uniq 12383 do 12384 # Extract the first word of "$ac_prog", so it can be a program name with args. 12385 set dummy $ac_prog; ac_word=$2 12386 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12387 $as_echo_n "checking for $ac_word... " >&6; } 12388 if ${ac_cv_path_UNIQ+:} false; then : 12389 $as_echo_n "(cached) " >&6 12390 else 12391 case $UNIQ in 12392 [\\/]* | ?:[\\/]*) 12393 ac_cv_path_UNIQ="$UNIQ" # Let the user override the test with a path. 12394 ;; 12395 *) 12396 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12397 for as_dir in $PATH 12398 do 12399 IFS=$as_save_IFS 12400 test -z "$as_dir" && as_dir=. 12401 for ac_exec_ext in '' $ac_executable_extensions; do 12402 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12403 ac_cv_path_UNIQ="$as_dir/$ac_word$ac_exec_ext" 12404 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12405 break 2 12406 fi 12407 done 12408 done 12409 IFS=$as_save_IFS 12410 12411 ;; 12412 esac 12413 fi 12414 UNIQ=$ac_cv_path_UNIQ 12415 if test -n "$UNIQ"; then 12416 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNIQ" >&5 12417 $as_echo "$UNIQ" >&6; } 12418 else 12419 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12420 $as_echo "no" >&6; } 12421 fi 12422 12423 12424 test -n "$UNIQ" && break 12425 done 12426 12427 else 12428 # The variable is set, but is it from the command line or the environment? 12429 12430 # Try to remove the string !UNIQ! from our list. 12431 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!UNIQ!/} 12432 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 12433 # If it failed, the variable was not from the command line. Ignore it, 12434 # but warn the user (except for BASH, which is always set by the calling BASH). 12435 if test "xUNIQ" != xBASH; then 12436 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of UNIQ from the environment. Use command line variables instead." >&5 12437 $as_echo "$as_me: WARNING: Ignoring value of UNIQ from the environment. Use command line variables instead." >&2;} 12438 fi 12439 # Try to locate tool using the code snippet 12440 for ac_prog in uniq 12441 do 12442 # Extract the first word of "$ac_prog", so it can be a program name with args. 12443 set dummy $ac_prog; ac_word=$2 12444 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12445 $as_echo_n "checking for $ac_word... " >&6; } 12446 if ${ac_cv_path_UNIQ+:} false; then : 12447 $as_echo_n "(cached) " >&6 12448 else 12449 case $UNIQ in 12450 [\\/]* | ?:[\\/]*) 12451 ac_cv_path_UNIQ="$UNIQ" # Let the user override the test with a path. 12452 ;; 12453 *) 12454 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12455 for as_dir in $PATH 12456 do 12457 IFS=$as_save_IFS 12458 test -z "$as_dir" && as_dir=. 12459 for ac_exec_ext in '' $ac_executable_extensions; do 12460 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12461 ac_cv_path_UNIQ="$as_dir/$ac_word$ac_exec_ext" 12462 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12463 break 2 12464 fi 12465 done 12466 done 12467 IFS=$as_save_IFS 12468 12469 ;; 12470 esac 12471 fi 12472 UNIQ=$ac_cv_path_UNIQ 12473 if test -n "$UNIQ"; then 12474 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNIQ" >&5 12475 $as_echo "$UNIQ" >&6; } 12476 else 12477 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12478 $as_echo "no" >&6; } 12479 fi 12480 12481 12482 test -n "$UNIQ" && break 12483 done 12484 12485 else 12486 # If it succeeded, then it was overridden by the user. We will use it 12487 # for the tool. 12488 12489 # First remove it from the list of overridden variables, so we can test 12490 # for unknown variables in the end. 12491 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 12492 12493 # Check if we try to supply an empty value 12494 if test "x$UNIQ" = x; then 12495 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool UNIQ= (no value)" >&5 12496 $as_echo "$as_me: Setting user supplied tool UNIQ= (no value)" >&6;} 12497 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNIQ" >&5 12498 $as_echo_n "checking for UNIQ... " >&6; } 12499 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 12500 $as_echo "disabled" >&6; } 12501 else 12502 # Check if the provided tool contains a complete path. 12503 tool_specified="$UNIQ" 12504 tool_basename="${tool_specified##*/}" 12505 if test "x$tool_basename" = "x$tool_specified"; then 12506 # A command without a complete path is provided, search $PATH. 12507 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool UNIQ=$tool_basename" >&5 12508 $as_echo "$as_me: Will search for user supplied tool UNIQ=$tool_basename" >&6;} 12509 # Extract the first word of "$tool_basename", so it can be a program name with args. 12510 set dummy $tool_basename; ac_word=$2 12511 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12512 $as_echo_n "checking for $ac_word... " >&6; } 12513 if ${ac_cv_path_UNIQ+:} false; then : 12514 $as_echo_n "(cached) " >&6 12515 else 12516 case $UNIQ in 12517 [\\/]* | ?:[\\/]*) 12518 ac_cv_path_UNIQ="$UNIQ" # Let the user override the test with a path. 12519 ;; 12520 *) 12521 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12522 for as_dir in $PATH 12523 do 12524 IFS=$as_save_IFS 12525 test -z "$as_dir" && as_dir=. 12526 for ac_exec_ext in '' $ac_executable_extensions; do 12527 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12528 ac_cv_path_UNIQ="$as_dir/$ac_word$ac_exec_ext" 12529 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12530 break 2 12531 fi 12532 done 12533 done 12534 IFS=$as_save_IFS 12535 12536 ;; 12537 esac 12538 fi 12539 UNIQ=$ac_cv_path_UNIQ 12540 if test -n "$UNIQ"; then 12541 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNIQ" >&5 12542 $as_echo "$UNIQ" >&6; } 12543 else 12544 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12545 $as_echo "no" >&6; } 12546 fi 12547 12548 12549 if test "x$UNIQ" = x; then 12550 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 12551 fi 12552 else 12553 # Otherwise we believe it is a complete path. Use it as it is. 12554 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool UNIQ=$tool_specified" >&5 12555 $as_echo "$as_me: Will use user supplied tool UNIQ=$tool_specified" >&6;} 12556 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNIQ" >&5 12557 $as_echo_n "checking for UNIQ... " >&6; } 12558 if test ! -x "$tool_specified"; then 12559 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 12560 $as_echo "not found" >&6; } 12561 as_fn_error $? "User supplied tool UNIQ=$tool_specified does not exist or is not executable" "$LINENO" 5 12562 fi 12563 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 12564 $as_echo "$tool_specified" >&6; } 12565 fi 12566 fi 12567 fi 12568 12569 fi 12570 12571 12572 12573 if test "x$UNIQ" = x; then 12574 as_fn_error $? "Could not find required tool for UNIQ" "$LINENO" 5 12575 fi 12576 12577 12578 12579 12580 12581 # Publish this variable in the help. 12582 12583 12584 if [ -z "${WC+x}" ]; then 12585 # The variable is not set by user, try to locate tool using the code snippet 12586 for ac_prog in wc 12587 do 12588 # Extract the first word of "$ac_prog", so it can be a program name with args. 12589 set dummy $ac_prog; ac_word=$2 12590 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12591 $as_echo_n "checking for $ac_word... " >&6; } 12592 if ${ac_cv_path_WC+:} false; then : 12593 $as_echo_n "(cached) " >&6 12594 else 12595 case $WC in 12596 [\\/]* | ?:[\\/]*) 12597 ac_cv_path_WC="$WC" # Let the user override the test with a path. 12598 ;; 12599 *) 12600 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12601 for as_dir in $PATH 12602 do 12603 IFS=$as_save_IFS 12604 test -z "$as_dir" && as_dir=. 12605 for ac_exec_ext in '' $ac_executable_extensions; do 12606 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12607 ac_cv_path_WC="$as_dir/$ac_word$ac_exec_ext" 12608 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12609 break 2 12610 fi 12611 done 12612 done 12613 IFS=$as_save_IFS 12614 12615 ;; 12616 esac 12617 fi 12618 WC=$ac_cv_path_WC 12619 if test -n "$WC"; then 12620 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WC" >&5 12621 $as_echo "$WC" >&6; } 12622 else 12623 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12624 $as_echo "no" >&6; } 12625 fi 12626 12627 12628 test -n "$WC" && break 12629 done 12630 12631 else 12632 # The variable is set, but is it from the command line or the environment? 12633 12634 # Try to remove the string !WC! from our list. 12635 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!WC!/} 12636 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 12637 # If it failed, the variable was not from the command line. Ignore it, 12638 # but warn the user (except for BASH, which is always set by the calling BASH). 12639 if test "xWC" != xBASH; then 12640 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of WC from the environment. Use command line variables instead." >&5 12641 $as_echo "$as_me: WARNING: Ignoring value of WC from the environment. Use command line variables instead." >&2;} 12642 fi 12643 # Try to locate tool using the code snippet 12644 for ac_prog in wc 12645 do 12646 # Extract the first word of "$ac_prog", so it can be a program name with args. 12647 set dummy $ac_prog; ac_word=$2 12648 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12649 $as_echo_n "checking for $ac_word... " >&6; } 12650 if ${ac_cv_path_WC+:} false; then : 12651 $as_echo_n "(cached) " >&6 12652 else 12653 case $WC in 12654 [\\/]* | ?:[\\/]*) 12655 ac_cv_path_WC="$WC" # Let the user override the test with a path. 12656 ;; 12657 *) 12658 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12659 for as_dir in $PATH 12660 do 12661 IFS=$as_save_IFS 12662 test -z "$as_dir" && as_dir=. 12663 for ac_exec_ext in '' $ac_executable_extensions; do 12664 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12665 ac_cv_path_WC="$as_dir/$ac_word$ac_exec_ext" 12666 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12667 break 2 12668 fi 12669 done 12670 done 12671 IFS=$as_save_IFS 12672 12673 ;; 12674 esac 12675 fi 12676 WC=$ac_cv_path_WC 12677 if test -n "$WC"; then 12678 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WC" >&5 12679 $as_echo "$WC" >&6; } 12680 else 12681 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12682 $as_echo "no" >&6; } 12683 fi 12684 12685 12686 test -n "$WC" && break 12687 done 12688 12689 else 12690 # If it succeeded, then it was overridden by the user. We will use it 12691 # for the tool. 12692 12693 # First remove it from the list of overridden variables, so we can test 12694 # for unknown variables in the end. 12695 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 12696 12697 # Check if we try to supply an empty value 12698 if test "x$WC" = x; then 12699 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool WC= (no value)" >&5 12700 $as_echo "$as_me: Setting user supplied tool WC= (no value)" >&6;} 12701 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WC" >&5 12702 $as_echo_n "checking for WC... " >&6; } 12703 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 12704 $as_echo "disabled" >&6; } 12705 else 12706 # Check if the provided tool contains a complete path. 12707 tool_specified="$WC" 12708 tool_basename="${tool_specified##*/}" 12709 if test "x$tool_basename" = "x$tool_specified"; then 12710 # A command without a complete path is provided, search $PATH. 12711 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool WC=$tool_basename" >&5 12712 $as_echo "$as_me: Will search for user supplied tool WC=$tool_basename" >&6;} 12713 # Extract the first word of "$tool_basename", so it can be a program name with args. 12714 set dummy $tool_basename; ac_word=$2 12715 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12716 $as_echo_n "checking for $ac_word... " >&6; } 12717 if ${ac_cv_path_WC+:} false; then : 12718 $as_echo_n "(cached) " >&6 12719 else 12720 case $WC in 12721 [\\/]* | ?:[\\/]*) 12722 ac_cv_path_WC="$WC" # Let the user override the test with a path. 12723 ;; 12724 *) 12725 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12726 for as_dir in $PATH 12727 do 12728 IFS=$as_save_IFS 12729 test -z "$as_dir" && as_dir=. 12730 for ac_exec_ext in '' $ac_executable_extensions; do 12731 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12732 ac_cv_path_WC="$as_dir/$ac_word$ac_exec_ext" 12733 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12734 break 2 12735 fi 12736 done 12737 done 12738 IFS=$as_save_IFS 12739 12740 ;; 12741 esac 12742 fi 12743 WC=$ac_cv_path_WC 12744 if test -n "$WC"; then 12745 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WC" >&5 12746 $as_echo "$WC" >&6; } 12747 else 12748 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12749 $as_echo "no" >&6; } 12750 fi 12751 12752 12753 if test "x$WC" = x; then 12754 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 12755 fi 12756 else 12757 # Otherwise we believe it is a complete path. Use it as it is. 12758 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool WC=$tool_specified" >&5 12759 $as_echo "$as_me: Will use user supplied tool WC=$tool_specified" >&6;} 12760 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WC" >&5 12761 $as_echo_n "checking for WC... " >&6; } 12762 if test ! -x "$tool_specified"; then 12763 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 12764 $as_echo "not found" >&6; } 12765 as_fn_error $? "User supplied tool WC=$tool_specified does not exist or is not executable" "$LINENO" 5 12766 fi 12767 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 12768 $as_echo "$tool_specified" >&6; } 12769 fi 12770 fi 12771 fi 12772 12773 fi 12774 12775 12776 12777 if test "x$WC" = x; then 12778 as_fn_error $? "Could not find required tool for WC" "$LINENO" 5 12779 fi 12780 12781 12782 12783 12784 12785 # Publish this variable in the help. 12786 12787 12788 if [ -z "${WHICH+x}" ]; then 12789 # The variable is not set by user, try to locate tool using the code snippet 12790 for ac_prog in which 12791 do 12792 # Extract the first word of "$ac_prog", so it can be a program name with args. 12793 set dummy $ac_prog; ac_word=$2 12794 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12795 $as_echo_n "checking for $ac_word... " >&6; } 12796 if ${ac_cv_path_WHICH+:} false; then : 12797 $as_echo_n "(cached) " >&6 12798 else 12799 case $WHICH in 12800 [\\/]* | ?:[\\/]*) 12801 ac_cv_path_WHICH="$WHICH" # Let the user override the test with a path. 12802 ;; 12803 *) 12804 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12805 for as_dir in $PATH 12806 do 12807 IFS=$as_save_IFS 12808 test -z "$as_dir" && as_dir=. 12809 for ac_exec_ext in '' $ac_executable_extensions; do 12810 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12811 ac_cv_path_WHICH="$as_dir/$ac_word$ac_exec_ext" 12812 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12813 break 2 12814 fi 12815 done 12816 done 12817 IFS=$as_save_IFS 12818 12819 ;; 12820 esac 12821 fi 12822 WHICH=$ac_cv_path_WHICH 12823 if test -n "$WHICH"; then 12824 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WHICH" >&5 12825 $as_echo "$WHICH" >&6; } 12826 else 12827 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12828 $as_echo "no" >&6; } 12829 fi 12830 12831 12832 test -n "$WHICH" && break 12833 done 12834 12835 else 12836 # The variable is set, but is it from the command line or the environment? 12837 12838 # Try to remove the string !WHICH! from our list. 12839 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!WHICH!/} 12840 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 12841 # If it failed, the variable was not from the command line. Ignore it, 12842 # but warn the user (except for BASH, which is always set by the calling BASH). 12843 if test "xWHICH" != xBASH; then 12844 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of WHICH from the environment. Use command line variables instead." >&5 12845 $as_echo "$as_me: WARNING: Ignoring value of WHICH from the environment. Use command line variables instead." >&2;} 12846 fi 12847 # Try to locate tool using the code snippet 12848 for ac_prog in which 12849 do 12850 # Extract the first word of "$ac_prog", so it can be a program name with args. 12851 set dummy $ac_prog; ac_word=$2 12852 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12853 $as_echo_n "checking for $ac_word... " >&6; } 12854 if ${ac_cv_path_WHICH+:} false; then : 12855 $as_echo_n "(cached) " >&6 12856 else 12857 case $WHICH in 12858 [\\/]* | ?:[\\/]*) 12859 ac_cv_path_WHICH="$WHICH" # Let the user override the test with a path. 12860 ;; 12861 *) 12862 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12863 for as_dir in $PATH 12864 do 12865 IFS=$as_save_IFS 12866 test -z "$as_dir" && as_dir=. 12867 for ac_exec_ext in '' $ac_executable_extensions; do 12868 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12869 ac_cv_path_WHICH="$as_dir/$ac_word$ac_exec_ext" 12870 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12871 break 2 12872 fi 12873 done 12874 done 12875 IFS=$as_save_IFS 12876 12877 ;; 12878 esac 12879 fi 12880 WHICH=$ac_cv_path_WHICH 12881 if test -n "$WHICH"; then 12882 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WHICH" >&5 12883 $as_echo "$WHICH" >&6; } 12884 else 12885 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12886 $as_echo "no" >&6; } 12887 fi 12888 12889 12890 test -n "$WHICH" && break 12891 done 12892 12893 else 12894 # If it succeeded, then it was overridden by the user. We will use it 12895 # for the tool. 12896 12897 # First remove it from the list of overridden variables, so we can test 12898 # for unknown variables in the end. 12899 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 12900 12901 # Check if we try to supply an empty value 12902 if test "x$WHICH" = x; then 12903 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool WHICH= (no value)" >&5 12904 $as_echo "$as_me: Setting user supplied tool WHICH= (no value)" >&6;} 12905 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WHICH" >&5 12906 $as_echo_n "checking for WHICH... " >&6; } 12907 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 12908 $as_echo "disabled" >&6; } 12909 else 12910 # Check if the provided tool contains a complete path. 12911 tool_specified="$WHICH" 12912 tool_basename="${tool_specified##*/}" 12913 if test "x$tool_basename" = "x$tool_specified"; then 12914 # A command without a complete path is provided, search $PATH. 12915 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool WHICH=$tool_basename" >&5 12916 $as_echo "$as_me: Will search for user supplied tool WHICH=$tool_basename" >&6;} 12917 # Extract the first word of "$tool_basename", so it can be a program name with args. 12918 set dummy $tool_basename; ac_word=$2 12919 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12920 $as_echo_n "checking for $ac_word... " >&6; } 12921 if ${ac_cv_path_WHICH+:} false; then : 12922 $as_echo_n "(cached) " >&6 12923 else 12924 case $WHICH in 12925 [\\/]* | ?:[\\/]*) 12926 ac_cv_path_WHICH="$WHICH" # Let the user override the test with a path. 12927 ;; 12928 *) 12929 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12930 for as_dir in $PATH 12931 do 12932 IFS=$as_save_IFS 12933 test -z "$as_dir" && as_dir=. 12934 for ac_exec_ext in '' $ac_executable_extensions; do 12935 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12936 ac_cv_path_WHICH="$as_dir/$ac_word$ac_exec_ext" 12937 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12938 break 2 12939 fi 12940 done 12941 done 12942 IFS=$as_save_IFS 12943 12944 ;; 12945 esac 12946 fi 12947 WHICH=$ac_cv_path_WHICH 12948 if test -n "$WHICH"; then 12949 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WHICH" >&5 12950 $as_echo "$WHICH" >&6; } 12951 else 12952 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12953 $as_echo "no" >&6; } 12954 fi 12955 12956 12957 if test "x$WHICH" = x; then 12958 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 12959 fi 12960 else 12961 # Otherwise we believe it is a complete path. Use it as it is. 12962 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool WHICH=$tool_specified" >&5 12963 $as_echo "$as_me: Will use user supplied tool WHICH=$tool_specified" >&6;} 12964 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WHICH" >&5 12965 $as_echo_n "checking for WHICH... " >&6; } 12966 if test ! -x "$tool_specified"; then 12967 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 12968 $as_echo "not found" >&6; } 12969 as_fn_error $? "User supplied tool WHICH=$tool_specified does not exist or is not executable" "$LINENO" 5 12970 fi 12971 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 12972 $as_echo "$tool_specified" >&6; } 12973 fi 12974 fi 12975 fi 12976 12977 fi 12978 12979 12980 12981 if test "x$WHICH" = x; then 12982 as_fn_error $? "Could not find required tool for WHICH" "$LINENO" 5 12983 fi 12984 12985 12986 12987 12988 12989 # Publish this variable in the help. 12990 12991 12992 if [ -z "${XARGS+x}" ]; then 12993 # The variable is not set by user, try to locate tool using the code snippet 12994 for ac_prog in xargs 12995 do 12996 # Extract the first word of "$ac_prog", so it can be a program name with args. 12997 set dummy $ac_prog; ac_word=$2 12998 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12999 $as_echo_n "checking for $ac_word... " >&6; } 13000 if ${ac_cv_path_XARGS+:} false; then : 13001 $as_echo_n "(cached) " >&6 13002 else 13003 case $XARGS in 13004 [\\/]* | ?:[\\/]*) 13005 ac_cv_path_XARGS="$XARGS" # Let the user override the test with a path. 13006 ;; 13007 *) 13008 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13009 for as_dir in $PATH 13010 do 13011 IFS=$as_save_IFS 13012 test -z "$as_dir" && as_dir=. 13013 for ac_exec_ext in '' $ac_executable_extensions; do 13014 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13015 ac_cv_path_XARGS="$as_dir/$ac_word$ac_exec_ext" 13016 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13017 break 2 13018 fi 13019 done 13020 done 13021 IFS=$as_save_IFS 13022 13023 ;; 13024 esac 13025 fi 13026 XARGS=$ac_cv_path_XARGS 13027 if test -n "$XARGS"; then 13028 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XARGS" >&5 13029 $as_echo "$XARGS" >&6; } 13030 else 13031 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13032 $as_echo "no" >&6; } 13033 fi 13034 13035 13036 test -n "$XARGS" && break 13037 done 13038 13039 else 13040 # The variable is set, but is it from the command line or the environment? 13041 13042 # Try to remove the string !XARGS! from our list. 13043 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!XARGS!/} 13044 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 13045 # If it failed, the variable was not from the command line. Ignore it, 13046 # but warn the user (except for BASH, which is always set by the calling BASH). 13047 if test "xXARGS" != xBASH; then 13048 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of XARGS from the environment. Use command line variables instead." >&5 13049 $as_echo "$as_me: WARNING: Ignoring value of XARGS from the environment. Use command line variables instead." >&2;} 13050 fi 13051 # Try to locate tool using the code snippet 13052 for ac_prog in xargs 13053 do 13054 # Extract the first word of "$ac_prog", so it can be a program name with args. 13055 set dummy $ac_prog; ac_word=$2 13056 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13057 $as_echo_n "checking for $ac_word... " >&6; } 13058 if ${ac_cv_path_XARGS+:} false; then : 13059 $as_echo_n "(cached) " >&6 13060 else 13061 case $XARGS in 13062 [\\/]* | ?:[\\/]*) 13063 ac_cv_path_XARGS="$XARGS" # Let the user override the test with a path. 13064 ;; 13065 *) 13066 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13067 for as_dir in $PATH 13068 do 13069 IFS=$as_save_IFS 13070 test -z "$as_dir" && as_dir=. 13071 for ac_exec_ext in '' $ac_executable_extensions; do 13072 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13073 ac_cv_path_XARGS="$as_dir/$ac_word$ac_exec_ext" 13074 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13075 break 2 13076 fi 13077 done 13078 done 13079 IFS=$as_save_IFS 13080 13081 ;; 13082 esac 13083 fi 13084 XARGS=$ac_cv_path_XARGS 13085 if test -n "$XARGS"; then 13086 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XARGS" >&5 13087 $as_echo "$XARGS" >&6; } 13088 else 13089 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13090 $as_echo "no" >&6; } 13091 fi 13092 13093 13094 test -n "$XARGS" && break 13095 done 13096 13097 else 13098 # If it succeeded, then it was overridden by the user. We will use it 13099 # for the tool. 13100 13101 # First remove it from the list of overridden variables, so we can test 13102 # for unknown variables in the end. 13103 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 13104 13105 # Check if we try to supply an empty value 13106 if test "x$XARGS" = x; then 13107 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool XARGS= (no value)" >&5 13108 $as_echo "$as_me: Setting user supplied tool XARGS= (no value)" >&6;} 13109 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XARGS" >&5 13110 $as_echo_n "checking for XARGS... " >&6; } 13111 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 13112 $as_echo "disabled" >&6; } 13113 else 13114 # Check if the provided tool contains a complete path. 13115 tool_specified="$XARGS" 13116 tool_basename="${tool_specified##*/}" 13117 if test "x$tool_basename" = "x$tool_specified"; then 13118 # A command without a complete path is provided, search $PATH. 13119 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool XARGS=$tool_basename" >&5 13120 $as_echo "$as_me: Will search for user supplied tool XARGS=$tool_basename" >&6;} 13121 # Extract the first word of "$tool_basename", so it can be a program name with args. 13122 set dummy $tool_basename; ac_word=$2 13123 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13124 $as_echo_n "checking for $ac_word... " >&6; } 13125 if ${ac_cv_path_XARGS+:} false; then : 13126 $as_echo_n "(cached) " >&6 13127 else 13128 case $XARGS in 13129 [\\/]* | ?:[\\/]*) 13130 ac_cv_path_XARGS="$XARGS" # Let the user override the test with a path. 13131 ;; 13132 *) 13133 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13134 for as_dir in $PATH 13135 do 13136 IFS=$as_save_IFS 13137 test -z "$as_dir" && as_dir=. 13138 for ac_exec_ext in '' $ac_executable_extensions; do 13139 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13140 ac_cv_path_XARGS="$as_dir/$ac_word$ac_exec_ext" 13141 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13142 break 2 13143 fi 13144 done 13145 done 13146 IFS=$as_save_IFS 13147 13148 ;; 13149 esac 13150 fi 13151 XARGS=$ac_cv_path_XARGS 13152 if test -n "$XARGS"; then 13153 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XARGS" >&5 13154 $as_echo "$XARGS" >&6; } 13155 else 13156 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13157 $as_echo "no" >&6; } 13158 fi 13159 13160 13161 if test "x$XARGS" = x; then 13162 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 13163 fi 13164 else 13165 # Otherwise we believe it is a complete path. Use it as it is. 13166 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool XARGS=$tool_specified" >&5 13167 $as_echo "$as_me: Will use user supplied tool XARGS=$tool_specified" >&6;} 13168 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XARGS" >&5 13169 $as_echo_n "checking for XARGS... " >&6; } 13170 if test ! -x "$tool_specified"; then 13171 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 13172 $as_echo "not found" >&6; } 13173 as_fn_error $? "User supplied tool XARGS=$tool_specified does not exist or is not executable" "$LINENO" 5 13174 fi 13175 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 13176 $as_echo "$tool_specified" >&6; } 13177 fi 13178 fi 13179 fi 13180 13181 fi 13182 13183 13184 13185 if test "x$XARGS" = x; then 13186 as_fn_error $? "Could not find required tool for XARGS" "$LINENO" 5 13187 fi 13188 13189 13190 13191 # Then required tools that require some special treatment. 13192 13193 13194 # Publish this variable in the help. 13195 13196 13197 if [ -z "${AWK+x}" ]; then 13198 # The variable is not set by user, try to locate tool using the code snippet 13199 for ac_prog in gawk mawk nawk awk 13200 do 13201 # Extract the first word of "$ac_prog", so it can be a program name with args. 13202 set dummy $ac_prog; ac_word=$2 13203 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13204 $as_echo_n "checking for $ac_word... " >&6; } 13205 if ${ac_cv_prog_AWK+:} false; then : 13206 $as_echo_n "(cached) " >&6 13207 else 13208 if test -n "$AWK"; then 13209 ac_cv_prog_AWK="$AWK" # Let the user override the test. 13210 else 13211 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13212 for as_dir in $PATH 13213 do 13214 IFS=$as_save_IFS 13215 test -z "$as_dir" && as_dir=. 13216 for ac_exec_ext in '' $ac_executable_extensions; do 13217 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13218 ac_cv_prog_AWK="$ac_prog" 13219 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13220 break 2 13221 fi 13222 done 13223 done 13224 IFS=$as_save_IFS 13225 13226 fi 13227 fi 13228 AWK=$ac_cv_prog_AWK 13229 if test -n "$AWK"; then 13230 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 13231 $as_echo "$AWK" >&6; } 13232 else 13233 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13234 $as_echo "no" >&6; } 13235 fi 13236 13237 13238 test -n "$AWK" && break 13239 done 13240 13241 else 13242 # The variable is set, but is it from the command line or the environment? 13243 13244 # Try to remove the string !AWK! from our list. 13245 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AWK!/} 13246 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 13247 # If it failed, the variable was not from the command line. Ignore it, 13248 # but warn the user (except for BASH, which is always set by the calling BASH). 13249 if test "xAWK" != xBASH; then 13250 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AWK from the environment. Use command line variables instead." >&5 13251 $as_echo "$as_me: WARNING: Ignoring value of AWK from the environment. Use command line variables instead." >&2;} 13252 fi 13253 # Try to locate tool using the code snippet 13254 for ac_prog in gawk mawk nawk awk 13255 do 13256 # Extract the first word of "$ac_prog", so it can be a program name with args. 13257 set dummy $ac_prog; ac_word=$2 13258 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13259 $as_echo_n "checking for $ac_word... " >&6; } 13260 if ${ac_cv_prog_AWK+:} false; then : 13261 $as_echo_n "(cached) " >&6 13262 else 13263 if test -n "$AWK"; then 13264 ac_cv_prog_AWK="$AWK" # Let the user override the test. 13265 else 13266 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13267 for as_dir in $PATH 13268 do 13269 IFS=$as_save_IFS 13270 test -z "$as_dir" && as_dir=. 13271 for ac_exec_ext in '' $ac_executable_extensions; do 13272 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13273 ac_cv_prog_AWK="$ac_prog" 13274 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13275 break 2 13276 fi 13277 done 13278 done 13279 IFS=$as_save_IFS 13280 13281 fi 13282 fi 13283 AWK=$ac_cv_prog_AWK 13284 if test -n "$AWK"; then 13285 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 13286 $as_echo "$AWK" >&6; } 13287 else 13288 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13289 $as_echo "no" >&6; } 13290 fi 13291 13292 13293 test -n "$AWK" && break 13294 done 13295 13296 else 13297 # If it succeeded, then it was overridden by the user. We will use it 13298 # for the tool. 13299 13300 # First remove it from the list of overridden variables, so we can test 13301 # for unknown variables in the end. 13302 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 13303 13304 # Check if we try to supply an empty value 13305 if test "x$AWK" = x; then 13306 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool AWK= (no value)" >&5 13307 $as_echo "$as_me: Setting user supplied tool AWK= (no value)" >&6;} 13308 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AWK" >&5 13309 $as_echo_n "checking for AWK... " >&6; } 13310 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 13311 $as_echo "disabled" >&6; } 13312 else 13313 # Check if the provided tool contains a complete path. 13314 tool_specified="$AWK" 13315 tool_basename="${tool_specified##*/}" 13316 if test "x$tool_basename" = "x$tool_specified"; then 13317 # A command without a complete path is provided, search $PATH. 13318 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AWK=$tool_basename" >&5 13319 $as_echo "$as_me: Will search for user supplied tool AWK=$tool_basename" >&6;} 13320 # Extract the first word of "$tool_basename", so it can be a program name with args. 13321 set dummy $tool_basename; ac_word=$2 13322 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13323 $as_echo_n "checking for $ac_word... " >&6; } 13324 if ${ac_cv_path_AWK+:} false; then : 13325 $as_echo_n "(cached) " >&6 13326 else 13327 case $AWK in 13328 [\\/]* | ?:[\\/]*) 13329 ac_cv_path_AWK="$AWK" # Let the user override the test with a path. 13330 ;; 13331 *) 13332 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13333 for as_dir in $PATH 13334 do 13335 IFS=$as_save_IFS 13336 test -z "$as_dir" && as_dir=. 13337 for ac_exec_ext in '' $ac_executable_extensions; do 13338 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13339 ac_cv_path_AWK="$as_dir/$ac_word$ac_exec_ext" 13340 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13341 break 2 13342 fi 13343 done 13344 done 13345 IFS=$as_save_IFS 13346 13347 ;; 13348 esac 13349 fi 13350 AWK=$ac_cv_path_AWK 13351 if test -n "$AWK"; then 13352 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 13353 $as_echo "$AWK" >&6; } 13354 else 13355 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13356 $as_echo "no" >&6; } 13357 fi 13358 13359 13360 if test "x$AWK" = x; then 13361 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 13362 fi 13363 else 13364 # Otherwise we believe it is a complete path. Use it as it is. 13365 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AWK=$tool_specified" >&5 13366 $as_echo "$as_me: Will use user supplied tool AWK=$tool_specified" >&6;} 13367 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AWK" >&5 13368 $as_echo_n "checking for AWK... " >&6; } 13369 if test ! -x "$tool_specified"; then 13370 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 13371 $as_echo "not found" >&6; } 13372 as_fn_error $? "User supplied tool AWK=$tool_specified does not exist or is not executable" "$LINENO" 5 13373 fi 13374 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 13375 $as_echo "$tool_specified" >&6; } 13376 fi 13377 fi 13378 fi 13379 13380 fi 13381 13382 13383 if test "x$AWK" = x; then 13384 as_fn_error $? "Could not find required tool for AWK" "$LINENO" 5 13385 fi 13386 13387 13388 13389 13390 # Publish this variable in the help. 13391 13392 13393 if [ -z "${GREP+x}" ]; then 13394 # The variable is not set by user, try to locate tool using the code snippet 13395 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 13396 $as_echo_n "checking for grep that handles long lines and -e... " >&6; } 13397 if ${ac_cv_path_GREP+:} false; then : 13398 $as_echo_n "(cached) " >&6 13399 else 13400 if test -z "$GREP"; then 13401 ac_path_GREP_found=false 13402 # Loop through the user's path and test for each of PROGNAME-LIST 13403 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13404 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13405 do 13406 IFS=$as_save_IFS 13407 test -z "$as_dir" && as_dir=. 13408 for ac_prog in grep ggrep; do 13409 for ac_exec_ext in '' $ac_executable_extensions; do 13410 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" 13411 as_fn_executable_p "$ac_path_GREP" || continue 13412 # Check for GNU ac_path_GREP and select it if it is found. 13413 # Check for GNU $ac_path_GREP 13414 case `"$ac_path_GREP" --version 2>&1` in 13415 *GNU*) 13416 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; 13417 *) 13418 ac_count=0 13419 $as_echo_n 0123456789 >"conftest.in" 13420 while : 13421 do 13422 cat "conftest.in" "conftest.in" >"conftest.tmp" 13423 mv "conftest.tmp" "conftest.in" 13424 cp "conftest.in" "conftest.nl" 13425 $as_echo 'GREP' >> "conftest.nl" 13426 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break 13427 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13428 as_fn_arith $ac_count + 1 && ac_count=$as_val 13429 if test $ac_count -gt ${ac_path_GREP_max-0}; then 13430 # Best one so far, save it but keep looking for a better one 13431 ac_cv_path_GREP="$ac_path_GREP" 13432 ac_path_GREP_max=$ac_count 13433 fi 13434 # 10*(2^10) chars as input seems more than enough 13435 test $ac_count -gt 10 && break 13436 done 13437 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13438 esac 13439 13440 $ac_path_GREP_found && break 3 13441 done 13442 done 13443 done 13444 IFS=$as_save_IFS 13445 if test -z "$ac_cv_path_GREP"; then 13446 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13447 fi 13448 else 13449 ac_cv_path_GREP=$GREP 13450 fi 13451 13452 fi 13453 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 13454 $as_echo "$ac_cv_path_GREP" >&6; } 13455 GREP="$ac_cv_path_GREP" 13456 13457 13458 else 13459 # The variable is set, but is it from the command line or the environment? 13460 13461 # Try to remove the string !GREP! from our list. 13462 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!GREP!/} 13463 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 13464 # If it failed, the variable was not from the command line. Ignore it, 13465 # but warn the user (except for BASH, which is always set by the calling BASH). 13466 if test "xGREP" != xBASH; then 13467 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of GREP from the environment. Use command line variables instead." >&5 13468 $as_echo "$as_me: WARNING: Ignoring value of GREP from the environment. Use command line variables instead." >&2;} 13469 fi 13470 # Try to locate tool using the code snippet 13471 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 13472 $as_echo_n "checking for grep that handles long lines and -e... " >&6; } 13473 if ${ac_cv_path_GREP+:} false; then : 13474 $as_echo_n "(cached) " >&6 13475 else 13476 if test -z "$GREP"; then 13477 ac_path_GREP_found=false 13478 # Loop through the user's path and test for each of PROGNAME-LIST 13479 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13480 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13481 do 13482 IFS=$as_save_IFS 13483 test -z "$as_dir" && as_dir=. 13484 for ac_prog in grep ggrep; do 13485 for ac_exec_ext in '' $ac_executable_extensions; do 13486 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" 13487 as_fn_executable_p "$ac_path_GREP" || continue 13488 # Check for GNU ac_path_GREP and select it if it is found. 13489 # Check for GNU $ac_path_GREP 13490 case `"$ac_path_GREP" --version 2>&1` in 13491 *GNU*) 13492 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; 13493 *) 13494 ac_count=0 13495 $as_echo_n 0123456789 >"conftest.in" 13496 while : 13497 do 13498 cat "conftest.in" "conftest.in" >"conftest.tmp" 13499 mv "conftest.tmp" "conftest.in" 13500 cp "conftest.in" "conftest.nl" 13501 $as_echo 'GREP' >> "conftest.nl" 13502 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break 13503 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13504 as_fn_arith $ac_count + 1 && ac_count=$as_val 13505 if test $ac_count -gt ${ac_path_GREP_max-0}; then 13506 # Best one so far, save it but keep looking for a better one 13507 ac_cv_path_GREP="$ac_path_GREP" 13508 ac_path_GREP_max=$ac_count 13509 fi 13510 # 10*(2^10) chars as input seems more than enough 13511 test $ac_count -gt 10 && break 13512 done 13513 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13514 esac 13515 13516 $ac_path_GREP_found && break 3 13517 done 13518 done 13519 done 13520 IFS=$as_save_IFS 13521 if test -z "$ac_cv_path_GREP"; then 13522 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13523 fi 13524 else 13525 ac_cv_path_GREP=$GREP 13526 fi 13527 13528 fi 13529 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 13530 $as_echo "$ac_cv_path_GREP" >&6; } 13531 GREP="$ac_cv_path_GREP" 13532 13533 13534 else 13535 # If it succeeded, then it was overridden by the user. We will use it 13536 # for the tool. 13537 13538 # First remove it from the list of overridden variables, so we can test 13539 # for unknown variables in the end. 13540 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 13541 13542 # Check if we try to supply an empty value 13543 if test "x$GREP" = x; then 13544 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool GREP= (no value)" >&5 13545 $as_echo "$as_me: Setting user supplied tool GREP= (no value)" >&6;} 13546 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GREP" >&5 13547 $as_echo_n "checking for GREP... " >&6; } 13548 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 13549 $as_echo "disabled" >&6; } 13550 else 13551 # Check if the provided tool contains a complete path. 13552 tool_specified="$GREP" 13553 tool_basename="${tool_specified##*/}" 13554 if test "x$tool_basename" = "x$tool_specified"; then 13555 # A command without a complete path is provided, search $PATH. 13556 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool GREP=$tool_basename" >&5 13557 $as_echo "$as_me: Will search for user supplied tool GREP=$tool_basename" >&6;} 13558 # Extract the first word of "$tool_basename", so it can be a program name with args. 13559 set dummy $tool_basename; ac_word=$2 13560 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13561 $as_echo_n "checking for $ac_word... " >&6; } 13562 if ${ac_cv_path_GREP+:} false; then : 13563 $as_echo_n "(cached) " >&6 13564 else 13565 case $GREP in 13566 [\\/]* | ?:[\\/]*) 13567 ac_cv_path_GREP="$GREP" # Let the user override the test with a path. 13568 ;; 13569 *) 13570 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13571 for as_dir in $PATH 13572 do 13573 IFS=$as_save_IFS 13574 test -z "$as_dir" && as_dir=. 13575 for ac_exec_ext in '' $ac_executable_extensions; do 13576 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13577 ac_cv_path_GREP="$as_dir/$ac_word$ac_exec_ext" 13578 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13579 break 2 13580 fi 13581 done 13582 done 13583 IFS=$as_save_IFS 13584 13585 ;; 13586 esac 13587 fi 13588 GREP=$ac_cv_path_GREP 13589 if test -n "$GREP"; then 13590 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GREP" >&5 13591 $as_echo "$GREP" >&6; } 13592 else 13593 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13594 $as_echo "no" >&6; } 13595 fi 13596 13597 13598 if test "x$GREP" = x; then 13599 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 13600 fi 13601 else 13602 # Otherwise we believe it is a complete path. Use it as it is. 13603 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool GREP=$tool_specified" >&5 13604 $as_echo "$as_me: Will use user supplied tool GREP=$tool_specified" >&6;} 13605 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GREP" >&5 13606 $as_echo_n "checking for GREP... " >&6; } 13607 if test ! -x "$tool_specified"; then 13608 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 13609 $as_echo "not found" >&6; } 13610 as_fn_error $? "User supplied tool GREP=$tool_specified does not exist or is not executable" "$LINENO" 5 13611 fi 13612 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 13613 $as_echo "$tool_specified" >&6; } 13614 fi 13615 fi 13616 fi 13617 13618 fi 13619 13620 13621 if test "x$GREP" = x; then 13622 as_fn_error $? "Could not find required tool for GREP" "$LINENO" 5 13623 fi 13624 13625 13626 13627 13628 # Publish this variable in the help. 13629 13630 13631 if [ -z "${EGREP+x}" ]; then 13632 # The variable is not set by user, try to locate tool using the code snippet 13633 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 13634 $as_echo_n "checking for egrep... " >&6; } 13635 if ${ac_cv_path_EGREP+:} false; then : 13636 $as_echo_n "(cached) " >&6 13637 else 13638 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 13639 then ac_cv_path_EGREP="$GREP -E" 13640 else 13641 if test -z "$EGREP"; then 13642 ac_path_EGREP_found=false 13643 # Loop through the user's path and test for each of PROGNAME-LIST 13644 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13645 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13646 do 13647 IFS=$as_save_IFS 13648 test -z "$as_dir" && as_dir=. 13649 for ac_prog in egrep; do 13650 for ac_exec_ext in '' $ac_executable_extensions; do 13651 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" 13652 as_fn_executable_p "$ac_path_EGREP" || continue 13653 # Check for GNU ac_path_EGREP and select it if it is found. 13654 # Check for GNU $ac_path_EGREP 13655 case `"$ac_path_EGREP" --version 2>&1` in 13656 *GNU*) 13657 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; 13658 *) 13659 ac_count=0 13660 $as_echo_n 0123456789 >"conftest.in" 13661 while : 13662 do 13663 cat "conftest.in" "conftest.in" >"conftest.tmp" 13664 mv "conftest.tmp" "conftest.in" 13665 cp "conftest.in" "conftest.nl" 13666 $as_echo 'EGREP' >> "conftest.nl" 13667 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break 13668 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13669 as_fn_arith $ac_count + 1 && ac_count=$as_val 13670 if test $ac_count -gt ${ac_path_EGREP_max-0}; then 13671 # Best one so far, save it but keep looking for a better one 13672 ac_cv_path_EGREP="$ac_path_EGREP" 13673 ac_path_EGREP_max=$ac_count 13674 fi 13675 # 10*(2^10) chars as input seems more than enough 13676 test $ac_count -gt 10 && break 13677 done 13678 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13679 esac 13680 13681 $ac_path_EGREP_found && break 3 13682 done 13683 done 13684 done 13685 IFS=$as_save_IFS 13686 if test -z "$ac_cv_path_EGREP"; then 13687 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13688 fi 13689 else 13690 ac_cv_path_EGREP=$EGREP 13691 fi 13692 13693 fi 13694 fi 13695 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 13696 $as_echo "$ac_cv_path_EGREP" >&6; } 13697 EGREP="$ac_cv_path_EGREP" 13698 13699 13700 else 13701 # The variable is set, but is it from the command line or the environment? 13702 13703 # Try to remove the string !EGREP! from our list. 13704 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!EGREP!/} 13705 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 13706 # If it failed, the variable was not from the command line. Ignore it, 13707 # but warn the user (except for BASH, which is always set by the calling BASH). 13708 if test "xEGREP" != xBASH; then 13709 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of EGREP from the environment. Use command line variables instead." >&5 13710 $as_echo "$as_me: WARNING: Ignoring value of EGREP from the environment. Use command line variables instead." >&2;} 13711 fi 13712 # Try to locate tool using the code snippet 13713 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 13714 $as_echo_n "checking for egrep... " >&6; } 13715 if ${ac_cv_path_EGREP+:} false; then : 13716 $as_echo_n "(cached) " >&6 13717 else 13718 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 13719 then ac_cv_path_EGREP="$GREP -E" 13720 else 13721 if test -z "$EGREP"; then 13722 ac_path_EGREP_found=false 13723 # Loop through the user's path and test for each of PROGNAME-LIST 13724 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13725 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13726 do 13727 IFS=$as_save_IFS 13728 test -z "$as_dir" && as_dir=. 13729 for ac_prog in egrep; do 13730 for ac_exec_ext in '' $ac_executable_extensions; do 13731 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" 13732 as_fn_executable_p "$ac_path_EGREP" || continue 13733 # Check for GNU ac_path_EGREP and select it if it is found. 13734 # Check for GNU $ac_path_EGREP 13735 case `"$ac_path_EGREP" --version 2>&1` in 13736 *GNU*) 13737 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; 13738 *) 13739 ac_count=0 13740 $as_echo_n 0123456789 >"conftest.in" 13741 while : 13742 do 13743 cat "conftest.in" "conftest.in" >"conftest.tmp" 13744 mv "conftest.tmp" "conftest.in" 13745 cp "conftest.in" "conftest.nl" 13746 $as_echo 'EGREP' >> "conftest.nl" 13747 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break 13748 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13749 as_fn_arith $ac_count + 1 && ac_count=$as_val 13750 if test $ac_count -gt ${ac_path_EGREP_max-0}; then 13751 # Best one so far, save it but keep looking for a better one 13752 ac_cv_path_EGREP="$ac_path_EGREP" 13753 ac_path_EGREP_max=$ac_count 13754 fi 13755 # 10*(2^10) chars as input seems more than enough 13756 test $ac_count -gt 10 && break 13757 done 13758 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13759 esac 13760 13761 $ac_path_EGREP_found && break 3 13762 done 13763 done 13764 done 13765 IFS=$as_save_IFS 13766 if test -z "$ac_cv_path_EGREP"; then 13767 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13768 fi 13769 else 13770 ac_cv_path_EGREP=$EGREP 13771 fi 13772 13773 fi 13774 fi 13775 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 13776 $as_echo "$ac_cv_path_EGREP" >&6; } 13777 EGREP="$ac_cv_path_EGREP" 13778 13779 13780 else 13781 # If it succeeded, then it was overridden by the user. We will use it 13782 # for the tool. 13783 13784 # First remove it from the list of overridden variables, so we can test 13785 # for unknown variables in the end. 13786 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 13787 13788 # Check if we try to supply an empty value 13789 if test "x$EGREP" = x; then 13790 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool EGREP= (no value)" >&5 13791 $as_echo "$as_me: Setting user supplied tool EGREP= (no value)" >&6;} 13792 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGREP" >&5 13793 $as_echo_n "checking for EGREP... " >&6; } 13794 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 13795 $as_echo "disabled" >&6; } 13796 else 13797 # Check if the provided tool contains a complete path. 13798 tool_specified="$EGREP" 13799 tool_basename="${tool_specified##*/}" 13800 if test "x$tool_basename" = "x$tool_specified"; then 13801 # A command without a complete path is provided, search $PATH. 13802 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool EGREP=$tool_basename" >&5 13803 $as_echo "$as_me: Will search for user supplied tool EGREP=$tool_basename" >&6;} 13804 # Extract the first word of "$tool_basename", so it can be a program name with args. 13805 set dummy $tool_basename; ac_word=$2 13806 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13807 $as_echo_n "checking for $ac_word... " >&6; } 13808 if ${ac_cv_path_EGREP+:} false; then : 13809 $as_echo_n "(cached) " >&6 13810 else 13811 case $EGREP in 13812 [\\/]* | ?:[\\/]*) 13813 ac_cv_path_EGREP="$EGREP" # Let the user override the test with a path. 13814 ;; 13815 *) 13816 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13817 for as_dir in $PATH 13818 do 13819 IFS=$as_save_IFS 13820 test -z "$as_dir" && as_dir=. 13821 for ac_exec_ext in '' $ac_executable_extensions; do 13822 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13823 ac_cv_path_EGREP="$as_dir/$ac_word$ac_exec_ext" 13824 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13825 break 2 13826 fi 13827 done 13828 done 13829 IFS=$as_save_IFS 13830 13831 ;; 13832 esac 13833 fi 13834 EGREP=$ac_cv_path_EGREP 13835 if test -n "$EGREP"; then 13836 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EGREP" >&5 13837 $as_echo "$EGREP" >&6; } 13838 else 13839 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13840 $as_echo "no" >&6; } 13841 fi 13842 13843 13844 if test "x$EGREP" = x; then 13845 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 13846 fi 13847 else 13848 # Otherwise we believe it is a complete path. Use it as it is. 13849 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool EGREP=$tool_specified" >&5 13850 $as_echo "$as_me: Will use user supplied tool EGREP=$tool_specified" >&6;} 13851 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGREP" >&5 13852 $as_echo_n "checking for EGREP... " >&6; } 13853 if test ! -x "$tool_specified"; then 13854 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 13855 $as_echo "not found" >&6; } 13856 as_fn_error $? "User supplied tool EGREP=$tool_specified does not exist or is not executable" "$LINENO" 5 13857 fi 13858 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 13859 $as_echo "$tool_specified" >&6; } 13860 fi 13861 fi 13862 fi 13863 13864 fi 13865 13866 13867 if test "x$EGREP" = x; then 13868 as_fn_error $? "Could not find required tool for EGREP" "$LINENO" 5 13869 fi 13870 13871 13872 13873 13874 # Publish this variable in the help. 13875 13876 13877 if [ -z "${FGREP+x}" ]; then 13878 # The variable is not set by user, try to locate tool using the code snippet 13879 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5 13880 $as_echo_n "checking for fgrep... " >&6; } 13881 if ${ac_cv_path_FGREP+:} false; then : 13882 $as_echo_n "(cached) " >&6 13883 else 13884 if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1 13885 then ac_cv_path_FGREP="$GREP -F" 13886 else 13887 if test -z "$FGREP"; then 13888 ac_path_FGREP_found=false 13889 # Loop through the user's path and test for each of PROGNAME-LIST 13890 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13891 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13892 do 13893 IFS=$as_save_IFS 13894 test -z "$as_dir" && as_dir=. 13895 for ac_prog in fgrep; do 13896 for ac_exec_ext in '' $ac_executable_extensions; do 13897 ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext" 13898 as_fn_executable_p "$ac_path_FGREP" || continue 13899 # Check for GNU ac_path_FGREP and select it if it is found. 13900 # Check for GNU $ac_path_FGREP 13901 case `"$ac_path_FGREP" --version 2>&1` in 13902 *GNU*) 13903 ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;; 13904 *) 13905 ac_count=0 13906 $as_echo_n 0123456789 >"conftest.in" 13907 while : 13908 do 13909 cat "conftest.in" "conftest.in" >"conftest.tmp" 13910 mv "conftest.tmp" "conftest.in" 13911 cp "conftest.in" "conftest.nl" 13912 $as_echo 'FGREP' >> "conftest.nl" 13913 "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break 13914 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13915 as_fn_arith $ac_count + 1 && ac_count=$as_val 13916 if test $ac_count -gt ${ac_path_FGREP_max-0}; then 13917 # Best one so far, save it but keep looking for a better one 13918 ac_cv_path_FGREP="$ac_path_FGREP" 13919 ac_path_FGREP_max=$ac_count 13920 fi 13921 # 10*(2^10) chars as input seems more than enough 13922 test $ac_count -gt 10 && break 13923 done 13924 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13925 esac 13926 13927 $ac_path_FGREP_found && break 3 13928 done 13929 done 13930 done 13931 IFS=$as_save_IFS 13932 if test -z "$ac_cv_path_FGREP"; then 13933 as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13934 fi 13935 else 13936 ac_cv_path_FGREP=$FGREP 13937 fi 13938 13939 fi 13940 fi 13941 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5 13942 $as_echo "$ac_cv_path_FGREP" >&6; } 13943 FGREP="$ac_cv_path_FGREP" 13944 13945 13946 else 13947 # The variable is set, but is it from the command line or the environment? 13948 13949 # Try to remove the string !FGREP! from our list. 13950 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FGREP!/} 13951 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 13952 # If it failed, the variable was not from the command line. Ignore it, 13953 # but warn the user (except for BASH, which is always set by the calling BASH). 13954 if test "xFGREP" != xBASH; then 13955 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FGREP from the environment. Use command line variables instead." >&5 13956 $as_echo "$as_me: WARNING: Ignoring value of FGREP from the environment. Use command line variables instead." >&2;} 13957 fi 13958 # Try to locate tool using the code snippet 13959 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5 13960 $as_echo_n "checking for fgrep... " >&6; } 13961 if ${ac_cv_path_FGREP+:} false; then : 13962 $as_echo_n "(cached) " >&6 13963 else 13964 if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1 13965 then ac_cv_path_FGREP="$GREP -F" 13966 else 13967 if test -z "$FGREP"; then 13968 ac_path_FGREP_found=false 13969 # Loop through the user's path and test for each of PROGNAME-LIST 13970 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13971 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13972 do 13973 IFS=$as_save_IFS 13974 test -z "$as_dir" && as_dir=. 13975 for ac_prog in fgrep; do 13976 for ac_exec_ext in '' $ac_executable_extensions; do 13977 ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext" 13978 as_fn_executable_p "$ac_path_FGREP" || continue 13979 # Check for GNU ac_path_FGREP and select it if it is found. 13980 # Check for GNU $ac_path_FGREP 13981 case `"$ac_path_FGREP" --version 2>&1` in 13982 *GNU*) 13983 ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;; 13984 *) 13985 ac_count=0 13986 $as_echo_n 0123456789 >"conftest.in" 13987 while : 13988 do 13989 cat "conftest.in" "conftest.in" >"conftest.tmp" 13990 mv "conftest.tmp" "conftest.in" 13991 cp "conftest.in" "conftest.nl" 13992 $as_echo 'FGREP' >> "conftest.nl" 13993 "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break 13994 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13995 as_fn_arith $ac_count + 1 && ac_count=$as_val 13996 if test $ac_count -gt ${ac_path_FGREP_max-0}; then 13997 # Best one so far, save it but keep looking for a better one 13998 ac_cv_path_FGREP="$ac_path_FGREP" 13999 ac_path_FGREP_max=$ac_count 14000 fi 14001 # 10*(2^10) chars as input seems more than enough 14002 test $ac_count -gt 10 && break 14003 done 14004 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 14005 esac 14006 14007 $ac_path_FGREP_found && break 3 14008 done 14009 done 14010 done 14011 IFS=$as_save_IFS 14012 if test -z "$ac_cv_path_FGREP"; then 14013 as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 14014 fi 14015 else 14016 ac_cv_path_FGREP=$FGREP 14017 fi 14018 14019 fi 14020 fi 14021 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5 14022 $as_echo "$ac_cv_path_FGREP" >&6; } 14023 FGREP="$ac_cv_path_FGREP" 14024 14025 14026 else 14027 # If it succeeded, then it was overridden by the user. We will use it 14028 # for the tool. 14029 14030 # First remove it from the list of overridden variables, so we can test 14031 # for unknown variables in the end. 14032 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 14033 14034 # Check if we try to supply an empty value 14035 if test "x$FGREP" = x; then 14036 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool FGREP= (no value)" >&5 14037 $as_echo "$as_me: Setting user supplied tool FGREP= (no value)" >&6;} 14038 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FGREP" >&5 14039 $as_echo_n "checking for FGREP... " >&6; } 14040 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 14041 $as_echo "disabled" >&6; } 14042 else 14043 # Check if the provided tool contains a complete path. 14044 tool_specified="$FGREP" 14045 tool_basename="${tool_specified##*/}" 14046 if test "x$tool_basename" = "x$tool_specified"; then 14047 # A command without a complete path is provided, search $PATH. 14048 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FGREP=$tool_basename" >&5 14049 $as_echo "$as_me: Will search for user supplied tool FGREP=$tool_basename" >&6;} 14050 # Extract the first word of "$tool_basename", so it can be a program name with args. 14051 set dummy $tool_basename; ac_word=$2 14052 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14053 $as_echo_n "checking for $ac_word... " >&6; } 14054 if ${ac_cv_path_FGREP+:} false; then : 14055 $as_echo_n "(cached) " >&6 14056 else 14057 case $FGREP in 14058 [\\/]* | ?:[\\/]*) 14059 ac_cv_path_FGREP="$FGREP" # Let the user override the test with a path. 14060 ;; 14061 *) 14062 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14063 for as_dir in $PATH 14064 do 14065 IFS=$as_save_IFS 14066 test -z "$as_dir" && as_dir=. 14067 for ac_exec_ext in '' $ac_executable_extensions; do 14068 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14069 ac_cv_path_FGREP="$as_dir/$ac_word$ac_exec_ext" 14070 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14071 break 2 14072 fi 14073 done 14074 done 14075 IFS=$as_save_IFS 14076 14077 ;; 14078 esac 14079 fi 14080 FGREP=$ac_cv_path_FGREP 14081 if test -n "$FGREP"; then 14082 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FGREP" >&5 14083 $as_echo "$FGREP" >&6; } 14084 else 14085 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14086 $as_echo "no" >&6; } 14087 fi 14088 14089 14090 if test "x$FGREP" = x; then 14091 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 14092 fi 14093 else 14094 # Otherwise we believe it is a complete path. Use it as it is. 14095 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FGREP=$tool_specified" >&5 14096 $as_echo "$as_me: Will use user supplied tool FGREP=$tool_specified" >&6;} 14097 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FGREP" >&5 14098 $as_echo_n "checking for FGREP... " >&6; } 14099 if test ! -x "$tool_specified"; then 14100 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 14101 $as_echo "not found" >&6; } 14102 as_fn_error $? "User supplied tool FGREP=$tool_specified does not exist or is not executable" "$LINENO" 5 14103 fi 14104 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 14105 $as_echo "$tool_specified" >&6; } 14106 fi 14107 fi 14108 fi 14109 14110 fi 14111 14112 14113 if test "x$FGREP" = x; then 14114 as_fn_error $? "Could not find required tool for FGREP" "$LINENO" 5 14115 fi 14116 14117 14118 14119 14120 # Publish this variable in the help. 14121 14122 14123 if [ -z "${SED+x}" ]; then 14124 # The variable is not set by user, try to locate tool using the code snippet 14125 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 14126 $as_echo_n "checking for a sed that does not truncate output... " >&6; } 14127 if ${ac_cv_path_SED+:} false; then : 14128 $as_echo_n "(cached) " >&6 14129 else 14130 ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ 14131 for ac_i in 1 2 3 4 5 6 7; do 14132 ac_script="$ac_script$as_nl$ac_script" 14133 done 14134 echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed 14135 { ac_script=; unset ac_script;} 14136 if test -z "$SED"; then 14137 ac_path_SED_found=false 14138 # Loop through the user's path and test for each of PROGNAME-LIST 14139 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14140 for as_dir in $PATH 14141 do 14142 IFS=$as_save_IFS 14143 test -z "$as_dir" && as_dir=. 14144 for ac_prog in sed gsed; do 14145 for ac_exec_ext in '' $ac_executable_extensions; do 14146 ac_path_SED="$as_dir/$ac_prog$ac_exec_ext" 14147 as_fn_executable_p "$ac_path_SED" || continue 14148 # Check for GNU ac_path_SED and select it if it is found. 14149 # Check for GNU $ac_path_SED 14150 case `"$ac_path_SED" --version 2>&1` in 14151 *GNU*) 14152 ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;; 14153 *) 14154 ac_count=0 14155 $as_echo_n 0123456789 >"conftest.in" 14156 while : 14157 do 14158 cat "conftest.in" "conftest.in" >"conftest.tmp" 14159 mv "conftest.tmp" "conftest.in" 14160 cp "conftest.in" "conftest.nl" 14161 $as_echo '' >> "conftest.nl" 14162 "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break 14163 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 14164 as_fn_arith $ac_count + 1 && ac_count=$as_val 14165 if test $ac_count -gt ${ac_path_SED_max-0}; then 14166 # Best one so far, save it but keep looking for a better one 14167 ac_cv_path_SED="$ac_path_SED" 14168 ac_path_SED_max=$ac_count 14169 fi 14170 # 10*(2^10) chars as input seems more than enough 14171 test $ac_count -gt 10 && break 14172 done 14173 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 14174 esac 14175 14176 $ac_path_SED_found && break 3 14177 done 14178 done 14179 done 14180 IFS=$as_save_IFS 14181 if test -z "$ac_cv_path_SED"; then 14182 as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5 14183 fi 14184 else 14185 ac_cv_path_SED=$SED 14186 fi 14187 14188 fi 14189 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5 14190 $as_echo "$ac_cv_path_SED" >&6; } 14191 SED="$ac_cv_path_SED" 14192 rm -f conftest.sed 14193 14194 else 14195 # The variable is set, but is it from the command line or the environment? 14196 14197 # Try to remove the string !SED! from our list. 14198 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SED!/} 14199 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 14200 # If it failed, the variable was not from the command line. Ignore it, 14201 # but warn the user (except for BASH, which is always set by the calling BASH). 14202 if test "xSED" != xBASH; then 14203 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SED from the environment. Use command line variables instead." >&5 14204 $as_echo "$as_me: WARNING: Ignoring value of SED from the environment. Use command line variables instead." >&2;} 14205 fi 14206 # Try to locate tool using the code snippet 14207 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 14208 $as_echo_n "checking for a sed that does not truncate output... " >&6; } 14209 if ${ac_cv_path_SED+:} false; then : 14210 $as_echo_n "(cached) " >&6 14211 else 14212 ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ 14213 for ac_i in 1 2 3 4 5 6 7; do 14214 ac_script="$ac_script$as_nl$ac_script" 14215 done 14216 echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed 14217 { ac_script=; unset ac_script;} 14218 if test -z "$SED"; then 14219 ac_path_SED_found=false 14220 # Loop through the user's path and test for each of PROGNAME-LIST 14221 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14222 for as_dir in $PATH 14223 do 14224 IFS=$as_save_IFS 14225 test -z "$as_dir" && as_dir=. 14226 for ac_prog in sed gsed; do 14227 for ac_exec_ext in '' $ac_executable_extensions; do 14228 ac_path_SED="$as_dir/$ac_prog$ac_exec_ext" 14229 as_fn_executable_p "$ac_path_SED" || continue 14230 # Check for GNU ac_path_SED and select it if it is found. 14231 # Check for GNU $ac_path_SED 14232 case `"$ac_path_SED" --version 2>&1` in 14233 *GNU*) 14234 ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;; 14235 *) 14236 ac_count=0 14237 $as_echo_n 0123456789 >"conftest.in" 14238 while : 14239 do 14240 cat "conftest.in" "conftest.in" >"conftest.tmp" 14241 mv "conftest.tmp" "conftest.in" 14242 cp "conftest.in" "conftest.nl" 14243 $as_echo '' >> "conftest.nl" 14244 "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break 14245 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 14246 as_fn_arith $ac_count + 1 && ac_count=$as_val 14247 if test $ac_count -gt ${ac_path_SED_max-0}; then 14248 # Best one so far, save it but keep looking for a better one 14249 ac_cv_path_SED="$ac_path_SED" 14250 ac_path_SED_max=$ac_count 14251 fi 14252 # 10*(2^10) chars as input seems more than enough 14253 test $ac_count -gt 10 && break 14254 done 14255 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 14256 esac 14257 14258 $ac_path_SED_found && break 3 14259 done 14260 done 14261 done 14262 IFS=$as_save_IFS 14263 if test -z "$ac_cv_path_SED"; then 14264 as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5 14265 fi 14266 else 14267 ac_cv_path_SED=$SED 14268 fi 14269 14270 fi 14271 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5 14272 $as_echo "$ac_cv_path_SED" >&6; } 14273 SED="$ac_cv_path_SED" 14274 rm -f conftest.sed 14275 14276 else 14277 # If it succeeded, then it was overridden by the user. We will use it 14278 # for the tool. 14279 14280 # First remove it from the list of overridden variables, so we can test 14281 # for unknown variables in the end. 14282 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 14283 14284 # Check if we try to supply an empty value 14285 if test "x$SED" = x; then 14286 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool SED= (no value)" >&5 14287 $as_echo "$as_me: Setting user supplied tool SED= (no value)" >&6;} 14288 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SED" >&5 14289 $as_echo_n "checking for SED... " >&6; } 14290 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 14291 $as_echo "disabled" >&6; } 14292 else 14293 # Check if the provided tool contains a complete path. 14294 tool_specified="$SED" 14295 tool_basename="${tool_specified##*/}" 14296 if test "x$tool_basename" = "x$tool_specified"; then 14297 # A command without a complete path is provided, search $PATH. 14298 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SED=$tool_basename" >&5 14299 $as_echo "$as_me: Will search for user supplied tool SED=$tool_basename" >&6;} 14300 # Extract the first word of "$tool_basename", so it can be a program name with args. 14301 set dummy $tool_basename; ac_word=$2 14302 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14303 $as_echo_n "checking for $ac_word... " >&6; } 14304 if ${ac_cv_path_SED+:} false; then : 14305 $as_echo_n "(cached) " >&6 14306 else 14307 case $SED in 14308 [\\/]* | ?:[\\/]*) 14309 ac_cv_path_SED="$SED" # Let the user override the test with a path. 14310 ;; 14311 *) 14312 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14313 for as_dir in $PATH 14314 do 14315 IFS=$as_save_IFS 14316 test -z "$as_dir" && as_dir=. 14317 for ac_exec_ext in '' $ac_executable_extensions; do 14318 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14319 ac_cv_path_SED="$as_dir/$ac_word$ac_exec_ext" 14320 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14321 break 2 14322 fi 14323 done 14324 done 14325 IFS=$as_save_IFS 14326 14327 ;; 14328 esac 14329 fi 14330 SED=$ac_cv_path_SED 14331 if test -n "$SED"; then 14332 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SED" >&5 14333 $as_echo "$SED" >&6; } 14334 else 14335 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14336 $as_echo "no" >&6; } 14337 fi 14338 14339 14340 if test "x$SED" = x; then 14341 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 14342 fi 14343 else 14344 # Otherwise we believe it is a complete path. Use it as it is. 14345 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SED=$tool_specified" >&5 14346 $as_echo "$as_me: Will use user supplied tool SED=$tool_specified" >&6;} 14347 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SED" >&5 14348 $as_echo_n "checking for SED... " >&6; } 14349 if test ! -x "$tool_specified"; then 14350 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 14351 $as_echo "not found" >&6; } 14352 as_fn_error $? "User supplied tool SED=$tool_specified does not exist or is not executable" "$LINENO" 5 14353 fi 14354 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 14355 $as_echo "$tool_specified" >&6; } 14356 fi 14357 fi 14358 fi 14359 14360 fi 14361 14362 14363 if test "x$SED" = x; then 14364 as_fn_error $? "Could not find required tool for SED" "$LINENO" 5 14365 fi 14366 14367 14368 14369 # Always force rm. 14370 RM="$RM -f" 14371 14372 # pwd behaves differently on various platforms and some don't support the -L flag. 14373 # Always use the bash builtin pwd to get uniform behavior. 14374 THEPWDCMD=pwd 14375 14376 # These are not required on all platforms 14377 14378 14379 # Publish this variable in the help. 14380 14381 14382 if [ -z "${CYGPATH+x}" ]; then 14383 # The variable is not set by user, try to locate tool using the code snippet 14384 for ac_prog in cygpath 14385 do 14386 # Extract the first word of "$ac_prog", so it can be a program name with args. 14387 set dummy $ac_prog; ac_word=$2 14388 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14389 $as_echo_n "checking for $ac_word... " >&6; } 14390 if ${ac_cv_path_CYGPATH+:} false; then : 14391 $as_echo_n "(cached) " >&6 14392 else 14393 case $CYGPATH in 14394 [\\/]* | ?:[\\/]*) 14395 ac_cv_path_CYGPATH="$CYGPATH" # Let the user override the test with a path. 14396 ;; 14397 *) 14398 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14399 for as_dir in $PATH 14400 do 14401 IFS=$as_save_IFS 14402 test -z "$as_dir" && as_dir=. 14403 for ac_exec_ext in '' $ac_executable_extensions; do 14404 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14405 ac_cv_path_CYGPATH="$as_dir/$ac_word$ac_exec_ext" 14406 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14407 break 2 14408 fi 14409 done 14410 done 14411 IFS=$as_save_IFS 14412 14413 ;; 14414 esac 14415 fi 14416 CYGPATH=$ac_cv_path_CYGPATH 14417 if test -n "$CYGPATH"; then 14418 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5 14419 $as_echo "$CYGPATH" >&6; } 14420 else 14421 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14422 $as_echo "no" >&6; } 14423 fi 14424 14425 14426 test -n "$CYGPATH" && break 14427 done 14428 14429 else 14430 # The variable is set, but is it from the command line or the environment? 14431 14432 # Try to remove the string !CYGPATH! from our list. 14433 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CYGPATH!/} 14434 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 14435 # If it failed, the variable was not from the command line. Ignore it, 14436 # but warn the user (except for BASH, which is always set by the calling BASH). 14437 if test "xCYGPATH" != xBASH; then 14438 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CYGPATH from the environment. Use command line variables instead." >&5 14439 $as_echo "$as_me: WARNING: Ignoring value of CYGPATH from the environment. Use command line variables instead." >&2;} 14440 fi 14441 # Try to locate tool using the code snippet 14442 for ac_prog in cygpath 14443 do 14444 # Extract the first word of "$ac_prog", so it can be a program name with args. 14445 set dummy $ac_prog; ac_word=$2 14446 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14447 $as_echo_n "checking for $ac_word... " >&6; } 14448 if ${ac_cv_path_CYGPATH+:} false; then : 14449 $as_echo_n "(cached) " >&6 14450 else 14451 case $CYGPATH in 14452 [\\/]* | ?:[\\/]*) 14453 ac_cv_path_CYGPATH="$CYGPATH" # Let the user override the test with a path. 14454 ;; 14455 *) 14456 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14457 for as_dir in $PATH 14458 do 14459 IFS=$as_save_IFS 14460 test -z "$as_dir" && as_dir=. 14461 for ac_exec_ext in '' $ac_executable_extensions; do 14462 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14463 ac_cv_path_CYGPATH="$as_dir/$ac_word$ac_exec_ext" 14464 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14465 break 2 14466 fi 14467 done 14468 done 14469 IFS=$as_save_IFS 14470 14471 ;; 14472 esac 14473 fi 14474 CYGPATH=$ac_cv_path_CYGPATH 14475 if test -n "$CYGPATH"; then 14476 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5 14477 $as_echo "$CYGPATH" >&6; } 14478 else 14479 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14480 $as_echo "no" >&6; } 14481 fi 14482 14483 14484 test -n "$CYGPATH" && break 14485 done 14486 14487 else 14488 # If it succeeded, then it was overridden by the user. We will use it 14489 # for the tool. 14490 14491 # First remove it from the list of overridden variables, so we can test 14492 # for unknown variables in the end. 14493 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 14494 14495 # Check if we try to supply an empty value 14496 if test "x$CYGPATH" = x; then 14497 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CYGPATH= (no value)" >&5 14498 $as_echo "$as_me: Setting user supplied tool CYGPATH= (no value)" >&6;} 14499 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CYGPATH" >&5 14500 $as_echo_n "checking for CYGPATH... " >&6; } 14501 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 14502 $as_echo "disabled" >&6; } 14503 else 14504 # Check if the provided tool contains a complete path. 14505 tool_specified="$CYGPATH" 14506 tool_basename="${tool_specified##*/}" 14507 if test "x$tool_basename" = "x$tool_specified"; then 14508 # A command without a complete path is provided, search $PATH. 14509 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CYGPATH=$tool_basename" >&5 14510 $as_echo "$as_me: Will search for user supplied tool CYGPATH=$tool_basename" >&6;} 14511 # Extract the first word of "$tool_basename", so it can be a program name with args. 14512 set dummy $tool_basename; ac_word=$2 14513 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14514 $as_echo_n "checking for $ac_word... " >&6; } 14515 if ${ac_cv_path_CYGPATH+:} false; then : 14516 $as_echo_n "(cached) " >&6 14517 else 14518 case $CYGPATH in 14519 [\\/]* | ?:[\\/]*) 14520 ac_cv_path_CYGPATH="$CYGPATH" # Let the user override the test with a path. 14521 ;; 14522 *) 14523 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14524 for as_dir in $PATH 14525 do 14526 IFS=$as_save_IFS 14527 test -z "$as_dir" && as_dir=. 14528 for ac_exec_ext in '' $ac_executable_extensions; do 14529 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14530 ac_cv_path_CYGPATH="$as_dir/$ac_word$ac_exec_ext" 14531 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14532 break 2 14533 fi 14534 done 14535 done 14536 IFS=$as_save_IFS 14537 14538 ;; 14539 esac 14540 fi 14541 CYGPATH=$ac_cv_path_CYGPATH 14542 if test -n "$CYGPATH"; then 14543 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5 14544 $as_echo "$CYGPATH" >&6; } 14545 else 14546 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14547 $as_echo "no" >&6; } 14548 fi 14549 14550 14551 if test "x$CYGPATH" = x; then 14552 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 14553 fi 14554 else 14555 # Otherwise we believe it is a complete path. Use it as it is. 14556 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CYGPATH=$tool_specified" >&5 14557 $as_echo "$as_me: Will use user supplied tool CYGPATH=$tool_specified" >&6;} 14558 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CYGPATH" >&5 14559 $as_echo_n "checking for CYGPATH... " >&6; } 14560 if test ! -x "$tool_specified"; then 14561 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 14562 $as_echo "not found" >&6; } 14563 as_fn_error $? "User supplied tool CYGPATH=$tool_specified does not exist or is not executable" "$LINENO" 5 14564 fi 14565 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 14566 $as_echo "$tool_specified" >&6; } 14567 fi 14568 fi 14569 fi 14570 14571 fi 14572 14573 14574 14575 14576 # Publish this variable in the help. 14577 14578 14579 if [ -z "${READLINK+x}" ]; then 14580 # The variable is not set by user, try to locate tool using the code snippet 14581 for ac_prog in greadlink readlink 14582 do 14583 # Extract the first word of "$ac_prog", so it can be a program name with args. 14584 set dummy $ac_prog; ac_word=$2 14585 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14586 $as_echo_n "checking for $ac_word... " >&6; } 14587 if ${ac_cv_path_READLINK+:} false; then : 14588 $as_echo_n "(cached) " >&6 14589 else 14590 case $READLINK in 14591 [\\/]* | ?:[\\/]*) 14592 ac_cv_path_READLINK="$READLINK" # Let the user override the test with a path. 14593 ;; 14594 *) 14595 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14596 for as_dir in $PATH 14597 do 14598 IFS=$as_save_IFS 14599 test -z "$as_dir" && as_dir=. 14600 for ac_exec_ext in '' $ac_executable_extensions; do 14601 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14602 ac_cv_path_READLINK="$as_dir/$ac_word$ac_exec_ext" 14603 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14604 break 2 14605 fi 14606 done 14607 done 14608 IFS=$as_save_IFS 14609 14610 ;; 14611 esac 14612 fi 14613 READLINK=$ac_cv_path_READLINK 14614 if test -n "$READLINK"; then 14615 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINK" >&5 14616 $as_echo "$READLINK" >&6; } 14617 else 14618 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14619 $as_echo "no" >&6; } 14620 fi 14621 14622 14623 test -n "$READLINK" && break 14624 done 14625 14626 else 14627 # The variable is set, but is it from the command line or the environment? 14628 14629 # Try to remove the string !READLINK! from our list. 14630 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!READLINK!/} 14631 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 14632 # If it failed, the variable was not from the command line. Ignore it, 14633 # but warn the user (except for BASH, which is always set by the calling BASH). 14634 if test "xREADLINK" != xBASH; then 14635 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of READLINK from the environment. Use command line variables instead." >&5 14636 $as_echo "$as_me: WARNING: Ignoring value of READLINK from the environment. Use command line variables instead." >&2;} 14637 fi 14638 # Try to locate tool using the code snippet 14639 for ac_prog in greadlink readlink 14640 do 14641 # Extract the first word of "$ac_prog", so it can be a program name with args. 14642 set dummy $ac_prog; ac_word=$2 14643 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14644 $as_echo_n "checking for $ac_word... " >&6; } 14645 if ${ac_cv_path_READLINK+:} false; then : 14646 $as_echo_n "(cached) " >&6 14647 else 14648 case $READLINK in 14649 [\\/]* | ?:[\\/]*) 14650 ac_cv_path_READLINK="$READLINK" # Let the user override the test with a path. 14651 ;; 14652 *) 14653 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14654 for as_dir in $PATH 14655 do 14656 IFS=$as_save_IFS 14657 test -z "$as_dir" && as_dir=. 14658 for ac_exec_ext in '' $ac_executable_extensions; do 14659 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14660 ac_cv_path_READLINK="$as_dir/$ac_word$ac_exec_ext" 14661 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14662 break 2 14663 fi 14664 done 14665 done 14666 IFS=$as_save_IFS 14667 14668 ;; 14669 esac 14670 fi 14671 READLINK=$ac_cv_path_READLINK 14672 if test -n "$READLINK"; then 14673 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINK" >&5 14674 $as_echo "$READLINK" >&6; } 14675 else 14676 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14677 $as_echo "no" >&6; } 14678 fi 14679 14680 14681 test -n "$READLINK" && break 14682 done 14683 14684 else 14685 # If it succeeded, then it was overridden by the user. We will use it 14686 # for the tool. 14687 14688 # First remove it from the list of overridden variables, so we can test 14689 # for unknown variables in the end. 14690 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 14691 14692 # Check if we try to supply an empty value 14693 if test "x$READLINK" = x; then 14694 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool READLINK= (no value)" >&5 14695 $as_echo "$as_me: Setting user supplied tool READLINK= (no value)" >&6;} 14696 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READLINK" >&5 14697 $as_echo_n "checking for READLINK... " >&6; } 14698 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 14699 $as_echo "disabled" >&6; } 14700 else 14701 # Check if the provided tool contains a complete path. 14702 tool_specified="$READLINK" 14703 tool_basename="${tool_specified##*/}" 14704 if test "x$tool_basename" = "x$tool_specified"; then 14705 # A command without a complete path is provided, search $PATH. 14706 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool READLINK=$tool_basename" >&5 14707 $as_echo "$as_me: Will search for user supplied tool READLINK=$tool_basename" >&6;} 14708 # Extract the first word of "$tool_basename", so it can be a program name with args. 14709 set dummy $tool_basename; ac_word=$2 14710 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14711 $as_echo_n "checking for $ac_word... " >&6; } 14712 if ${ac_cv_path_READLINK+:} false; then : 14713 $as_echo_n "(cached) " >&6 14714 else 14715 case $READLINK in 14716 [\\/]* | ?:[\\/]*) 14717 ac_cv_path_READLINK="$READLINK" # Let the user override the test with a path. 14718 ;; 14719 *) 14720 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14721 for as_dir in $PATH 14722 do 14723 IFS=$as_save_IFS 14724 test -z "$as_dir" && as_dir=. 14725 for ac_exec_ext in '' $ac_executable_extensions; do 14726 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14727 ac_cv_path_READLINK="$as_dir/$ac_word$ac_exec_ext" 14728 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14729 break 2 14730 fi 14731 done 14732 done 14733 IFS=$as_save_IFS 14734 14735 ;; 14736 esac 14737 fi 14738 READLINK=$ac_cv_path_READLINK 14739 if test -n "$READLINK"; then 14740 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINK" >&5 14741 $as_echo "$READLINK" >&6; } 14742 else 14743 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14744 $as_echo "no" >&6; } 14745 fi 14746 14747 14748 if test "x$READLINK" = x; then 14749 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 14750 fi 14751 else 14752 # Otherwise we believe it is a complete path. Use it as it is. 14753 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool READLINK=$tool_specified" >&5 14754 $as_echo "$as_me: Will use user supplied tool READLINK=$tool_specified" >&6;} 14755 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READLINK" >&5 14756 $as_echo_n "checking for READLINK... " >&6; } 14757 if test ! -x "$tool_specified"; then 14758 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 14759 $as_echo "not found" >&6; } 14760 as_fn_error $? "User supplied tool READLINK=$tool_specified does not exist or is not executable" "$LINENO" 5 14761 fi 14762 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 14763 $as_echo "$tool_specified" >&6; } 14764 fi 14765 fi 14766 fi 14767 14768 fi 14769 14770 14771 14772 14773 # Publish this variable in the help. 14774 14775 14776 if [ -z "${DF+x}" ]; then 14777 # The variable is not set by user, try to locate tool using the code snippet 14778 for ac_prog in df 14779 do 14780 # Extract the first word of "$ac_prog", so it can be a program name with args. 14781 set dummy $ac_prog; ac_word=$2 14782 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14783 $as_echo_n "checking for $ac_word... " >&6; } 14784 if ${ac_cv_path_DF+:} false; then : 14785 $as_echo_n "(cached) " >&6 14786 else 14787 case $DF in 14788 [\\/]* | ?:[\\/]*) 14789 ac_cv_path_DF="$DF" # Let the user override the test with a path. 14790 ;; 14791 *) 14792 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14793 for as_dir in $PATH 14794 do 14795 IFS=$as_save_IFS 14796 test -z "$as_dir" && as_dir=. 14797 for ac_exec_ext in '' $ac_executable_extensions; do 14798 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14799 ac_cv_path_DF="$as_dir/$ac_word$ac_exec_ext" 14800 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14801 break 2 14802 fi 14803 done 14804 done 14805 IFS=$as_save_IFS 14806 14807 ;; 14808 esac 14809 fi 14810 DF=$ac_cv_path_DF 14811 if test -n "$DF"; then 14812 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DF" >&5 14813 $as_echo "$DF" >&6; } 14814 else 14815 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14816 $as_echo "no" >&6; } 14817 fi 14818 14819 14820 test -n "$DF" && break 14821 done 14822 14823 else 14824 # The variable is set, but is it from the command line or the environment? 14825 14826 # Try to remove the string !DF! from our list. 14827 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DF!/} 14828 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 14829 # If it failed, the variable was not from the command line. Ignore it, 14830 # but warn the user (except for BASH, which is always set by the calling BASH). 14831 if test "xDF" != xBASH; then 14832 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DF from the environment. Use command line variables instead." >&5 14833 $as_echo "$as_me: WARNING: Ignoring value of DF from the environment. Use command line variables instead." >&2;} 14834 fi 14835 # Try to locate tool using the code snippet 14836 for ac_prog in df 14837 do 14838 # Extract the first word of "$ac_prog", so it can be a program name with args. 14839 set dummy $ac_prog; ac_word=$2 14840 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14841 $as_echo_n "checking for $ac_word... " >&6; } 14842 if ${ac_cv_path_DF+:} false; then : 14843 $as_echo_n "(cached) " >&6 14844 else 14845 case $DF in 14846 [\\/]* | ?:[\\/]*) 14847 ac_cv_path_DF="$DF" # Let the user override the test with a path. 14848 ;; 14849 *) 14850 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14851 for as_dir in $PATH 14852 do 14853 IFS=$as_save_IFS 14854 test -z "$as_dir" && as_dir=. 14855 for ac_exec_ext in '' $ac_executable_extensions; do 14856 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14857 ac_cv_path_DF="$as_dir/$ac_word$ac_exec_ext" 14858 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14859 break 2 14860 fi 14861 done 14862 done 14863 IFS=$as_save_IFS 14864 14865 ;; 14866 esac 14867 fi 14868 DF=$ac_cv_path_DF 14869 if test -n "$DF"; then 14870 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DF" >&5 14871 $as_echo "$DF" >&6; } 14872 else 14873 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14874 $as_echo "no" >&6; } 14875 fi 14876 14877 14878 test -n "$DF" && break 14879 done 14880 14881 else 14882 # If it succeeded, then it was overridden by the user. We will use it 14883 # for the tool. 14884 14885 # First remove it from the list of overridden variables, so we can test 14886 # for unknown variables in the end. 14887 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 14888 14889 # Check if we try to supply an empty value 14890 if test "x$DF" = x; then 14891 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DF= (no value)" >&5 14892 $as_echo "$as_me: Setting user supplied tool DF= (no value)" >&6;} 14893 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DF" >&5 14894 $as_echo_n "checking for DF... " >&6; } 14895 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 14896 $as_echo "disabled" >&6; } 14897 else 14898 # Check if the provided tool contains a complete path. 14899 tool_specified="$DF" 14900 tool_basename="${tool_specified##*/}" 14901 if test "x$tool_basename" = "x$tool_specified"; then 14902 # A command without a complete path is provided, search $PATH. 14903 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DF=$tool_basename" >&5 14904 $as_echo "$as_me: Will search for user supplied tool DF=$tool_basename" >&6;} 14905 # Extract the first word of "$tool_basename", so it can be a program name with args. 14906 set dummy $tool_basename; ac_word=$2 14907 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14908 $as_echo_n "checking for $ac_word... " >&6; } 14909 if ${ac_cv_path_DF+:} false; then : 14910 $as_echo_n "(cached) " >&6 14911 else 14912 case $DF in 14913 [\\/]* | ?:[\\/]*) 14914 ac_cv_path_DF="$DF" # Let the user override the test with a path. 14915 ;; 14916 *) 14917 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14918 for as_dir in $PATH 14919 do 14920 IFS=$as_save_IFS 14921 test -z "$as_dir" && as_dir=. 14922 for ac_exec_ext in '' $ac_executable_extensions; do 14923 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14924 ac_cv_path_DF="$as_dir/$ac_word$ac_exec_ext" 14925 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14926 break 2 14927 fi 14928 done 14929 done 14930 IFS=$as_save_IFS 14931 14932 ;; 14933 esac 14934 fi 14935 DF=$ac_cv_path_DF 14936 if test -n "$DF"; then 14937 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DF" >&5 14938 $as_echo "$DF" >&6; } 14939 else 14940 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14941 $as_echo "no" >&6; } 14942 fi 14943 14944 14945 if test "x$DF" = x; then 14946 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 14947 fi 14948 else 14949 # Otherwise we believe it is a complete path. Use it as it is. 14950 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DF=$tool_specified" >&5 14951 $as_echo "$as_me: Will use user supplied tool DF=$tool_specified" >&6;} 14952 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DF" >&5 14953 $as_echo_n "checking for DF... " >&6; } 14954 if test ! -x "$tool_specified"; then 14955 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 14956 $as_echo "not found" >&6; } 14957 as_fn_error $? "User supplied tool DF=$tool_specified does not exist or is not executable" "$LINENO" 5 14958 fi 14959 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 14960 $as_echo "$tool_specified" >&6; } 14961 fi 14962 fi 14963 fi 14964 14965 fi 14966 14967 14968 14969 14970 # Publish this variable in the help. 14971 14972 14973 if [ -z "${CPIO+x}" ]; then 14974 # The variable is not set by user, try to locate tool using the code snippet 14975 for ac_prog in cpio bsdcpio 14976 do 14977 # Extract the first word of "$ac_prog", so it can be a program name with args. 14978 set dummy $ac_prog; ac_word=$2 14979 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14980 $as_echo_n "checking for $ac_word... " >&6; } 14981 if ${ac_cv_path_CPIO+:} false; then : 14982 $as_echo_n "(cached) " >&6 14983 else 14984 case $CPIO in 14985 [\\/]* | ?:[\\/]*) 14986 ac_cv_path_CPIO="$CPIO" # Let the user override the test with a path. 14987 ;; 14988 *) 14989 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14990 for as_dir in $PATH 14991 do 14992 IFS=$as_save_IFS 14993 test -z "$as_dir" && as_dir=. 14994 for ac_exec_ext in '' $ac_executable_extensions; do 14995 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14996 ac_cv_path_CPIO="$as_dir/$ac_word$ac_exec_ext" 14997 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14998 break 2 14999 fi 15000 done 15001 done 15002 IFS=$as_save_IFS 15003 15004 ;; 15005 esac 15006 fi 15007 CPIO=$ac_cv_path_CPIO 15008 if test -n "$CPIO"; then 15009 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPIO" >&5 15010 $as_echo "$CPIO" >&6; } 15011 else 15012 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15013 $as_echo "no" >&6; } 15014 fi 15015 15016 15017 test -n "$CPIO" && break 15018 done 15019 15020 else 15021 # The variable is set, but is it from the command line or the environment? 15022 15023 # Try to remove the string !CPIO! from our list. 15024 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CPIO!/} 15025 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 15026 # If it failed, the variable was not from the command line. Ignore it, 15027 # but warn the user (except for BASH, which is always set by the calling BASH). 15028 if test "xCPIO" != xBASH; then 15029 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CPIO from the environment. Use command line variables instead." >&5 15030 $as_echo "$as_me: WARNING: Ignoring value of CPIO from the environment. Use command line variables instead." >&2;} 15031 fi 15032 # Try to locate tool using the code snippet 15033 for ac_prog in cpio bsdcpio 15034 do 15035 # Extract the first word of "$ac_prog", so it can be a program name with args. 15036 set dummy $ac_prog; ac_word=$2 15037 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15038 $as_echo_n "checking for $ac_word... " >&6; } 15039 if ${ac_cv_path_CPIO+:} false; then : 15040 $as_echo_n "(cached) " >&6 15041 else 15042 case $CPIO in 15043 [\\/]* | ?:[\\/]*) 15044 ac_cv_path_CPIO="$CPIO" # Let the user override the test with a path. 15045 ;; 15046 *) 15047 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15048 for as_dir in $PATH 15049 do 15050 IFS=$as_save_IFS 15051 test -z "$as_dir" && as_dir=. 15052 for ac_exec_ext in '' $ac_executable_extensions; do 15053 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15054 ac_cv_path_CPIO="$as_dir/$ac_word$ac_exec_ext" 15055 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15056 break 2 15057 fi 15058 done 15059 done 15060 IFS=$as_save_IFS 15061 15062 ;; 15063 esac 15064 fi 15065 CPIO=$ac_cv_path_CPIO 15066 if test -n "$CPIO"; then 15067 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPIO" >&5 15068 $as_echo "$CPIO" >&6; } 15069 else 15070 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15071 $as_echo "no" >&6; } 15072 fi 15073 15074 15075 test -n "$CPIO" && break 15076 done 15077 15078 else 15079 # If it succeeded, then it was overridden by the user. We will use it 15080 # for the tool. 15081 15082 # First remove it from the list of overridden variables, so we can test 15083 # for unknown variables in the end. 15084 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 15085 15086 # Check if we try to supply an empty value 15087 if test "x$CPIO" = x; then 15088 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CPIO= (no value)" >&5 15089 $as_echo "$as_me: Setting user supplied tool CPIO= (no value)" >&6;} 15090 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CPIO" >&5 15091 $as_echo_n "checking for CPIO... " >&6; } 15092 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 15093 $as_echo "disabled" >&6; } 15094 else 15095 # Check if the provided tool contains a complete path. 15096 tool_specified="$CPIO" 15097 tool_basename="${tool_specified##*/}" 15098 if test "x$tool_basename" = "x$tool_specified"; then 15099 # A command without a complete path is provided, search $PATH. 15100 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CPIO=$tool_basename" >&5 15101 $as_echo "$as_me: Will search for user supplied tool CPIO=$tool_basename" >&6;} 15102 # Extract the first word of "$tool_basename", so it can be a program name with args. 15103 set dummy $tool_basename; ac_word=$2 15104 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15105 $as_echo_n "checking for $ac_word... " >&6; } 15106 if ${ac_cv_path_CPIO+:} false; then : 15107 $as_echo_n "(cached) " >&6 15108 else 15109 case $CPIO in 15110 [\\/]* | ?:[\\/]*) 15111 ac_cv_path_CPIO="$CPIO" # Let the user override the test with a path. 15112 ;; 15113 *) 15114 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15115 for as_dir in $PATH 15116 do 15117 IFS=$as_save_IFS 15118 test -z "$as_dir" && as_dir=. 15119 for ac_exec_ext in '' $ac_executable_extensions; do 15120 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15121 ac_cv_path_CPIO="$as_dir/$ac_word$ac_exec_ext" 15122 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15123 break 2 15124 fi 15125 done 15126 done 15127 IFS=$as_save_IFS 15128 15129 ;; 15130 esac 15131 fi 15132 CPIO=$ac_cv_path_CPIO 15133 if test -n "$CPIO"; then 15134 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPIO" >&5 15135 $as_echo "$CPIO" >&6; } 15136 else 15137 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15138 $as_echo "no" >&6; } 15139 fi 15140 15141 15142 if test "x$CPIO" = x; then 15143 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 15144 fi 15145 else 15146 # Otherwise we believe it is a complete path. Use it as it is. 15147 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CPIO=$tool_specified" >&5 15148 $as_echo "$as_me: Will use user supplied tool CPIO=$tool_specified" >&6;} 15149 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CPIO" >&5 15150 $as_echo_n "checking for CPIO... " >&6; } 15151 if test ! -x "$tool_specified"; then 15152 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 15153 $as_echo "not found" >&6; } 15154 as_fn_error $? "User supplied tool CPIO=$tool_specified does not exist or is not executable" "$LINENO" 5 15155 fi 15156 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 15157 $as_echo "$tool_specified" >&6; } 15158 fi 15159 fi 15160 fi 15161 15162 fi 15163 15164 15165 15166 15167 # Publish this variable in the help. 15168 15169 15170 if [ -z "${NICE+x}" ]; then 15171 # The variable is not set by user, try to locate tool using the code snippet 15172 for ac_prog in nice 15173 do 15174 # Extract the first word of "$ac_prog", so it can be a program name with args. 15175 set dummy $ac_prog; ac_word=$2 15176 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15177 $as_echo_n "checking for $ac_word... " >&6; } 15178 if ${ac_cv_path_NICE+:} false; then : 15179 $as_echo_n "(cached) " >&6 15180 else 15181 case $NICE in 15182 [\\/]* | ?:[\\/]*) 15183 ac_cv_path_NICE="$NICE" # Let the user override the test with a path. 15184 ;; 15185 *) 15186 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15187 for as_dir in $PATH 15188 do 15189 IFS=$as_save_IFS 15190 test -z "$as_dir" && as_dir=. 15191 for ac_exec_ext in '' $ac_executable_extensions; do 15192 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15193 ac_cv_path_NICE="$as_dir/$ac_word$ac_exec_ext" 15194 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15195 break 2 15196 fi 15197 done 15198 done 15199 IFS=$as_save_IFS 15200 15201 ;; 15202 esac 15203 fi 15204 NICE=$ac_cv_path_NICE 15205 if test -n "$NICE"; then 15206 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NICE" >&5 15207 $as_echo "$NICE" >&6; } 15208 else 15209 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15210 $as_echo "no" >&6; } 15211 fi 15212 15213 15214 test -n "$NICE" && break 15215 done 15216 15217 else 15218 # The variable is set, but is it from the command line or the environment? 15219 15220 # Try to remove the string !NICE! from our list. 15221 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NICE!/} 15222 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 15223 # If it failed, the variable was not from the command line. Ignore it, 15224 # but warn the user (except for BASH, which is always set by the calling BASH). 15225 if test "xNICE" != xBASH; then 15226 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NICE from the environment. Use command line variables instead." >&5 15227 $as_echo "$as_me: WARNING: Ignoring value of NICE from the environment. Use command line variables instead." >&2;} 15228 fi 15229 # Try to locate tool using the code snippet 15230 for ac_prog in nice 15231 do 15232 # Extract the first word of "$ac_prog", so it can be a program name with args. 15233 set dummy $ac_prog; ac_word=$2 15234 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15235 $as_echo_n "checking for $ac_word... " >&6; } 15236 if ${ac_cv_path_NICE+:} false; then : 15237 $as_echo_n "(cached) " >&6 15238 else 15239 case $NICE in 15240 [\\/]* | ?:[\\/]*) 15241 ac_cv_path_NICE="$NICE" # Let the user override the test with a path. 15242 ;; 15243 *) 15244 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15245 for as_dir in $PATH 15246 do 15247 IFS=$as_save_IFS 15248 test -z "$as_dir" && as_dir=. 15249 for ac_exec_ext in '' $ac_executable_extensions; do 15250 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15251 ac_cv_path_NICE="$as_dir/$ac_word$ac_exec_ext" 15252 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15253 break 2 15254 fi 15255 done 15256 done 15257 IFS=$as_save_IFS 15258 15259 ;; 15260 esac 15261 fi 15262 NICE=$ac_cv_path_NICE 15263 if test -n "$NICE"; then 15264 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NICE" >&5 15265 $as_echo "$NICE" >&6; } 15266 else 15267 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15268 $as_echo "no" >&6; } 15269 fi 15270 15271 15272 test -n "$NICE" && break 15273 done 15274 15275 else 15276 # If it succeeded, then it was overridden by the user. We will use it 15277 # for the tool. 15278 15279 # First remove it from the list of overridden variables, so we can test 15280 # for unknown variables in the end. 15281 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 15282 15283 # Check if we try to supply an empty value 15284 if test "x$NICE" = x; then 15285 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool NICE= (no value)" >&5 15286 $as_echo "$as_me: Setting user supplied tool NICE= (no value)" >&6;} 15287 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NICE" >&5 15288 $as_echo_n "checking for NICE... " >&6; } 15289 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 15290 $as_echo "disabled" >&6; } 15291 else 15292 # Check if the provided tool contains a complete path. 15293 tool_specified="$NICE" 15294 tool_basename="${tool_specified##*/}" 15295 if test "x$tool_basename" = "x$tool_specified"; then 15296 # A command without a complete path is provided, search $PATH. 15297 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NICE=$tool_basename" >&5 15298 $as_echo "$as_me: Will search for user supplied tool NICE=$tool_basename" >&6;} 15299 # Extract the first word of "$tool_basename", so it can be a program name with args. 15300 set dummy $tool_basename; ac_word=$2 15301 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15302 $as_echo_n "checking for $ac_word... " >&6; } 15303 if ${ac_cv_path_NICE+:} false; then : 15304 $as_echo_n "(cached) " >&6 15305 else 15306 case $NICE in 15307 [\\/]* | ?:[\\/]*) 15308 ac_cv_path_NICE="$NICE" # Let the user override the test with a path. 15309 ;; 15310 *) 15311 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15312 for as_dir in $PATH 15313 do 15314 IFS=$as_save_IFS 15315 test -z "$as_dir" && as_dir=. 15316 for ac_exec_ext in '' $ac_executable_extensions; do 15317 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15318 ac_cv_path_NICE="$as_dir/$ac_word$ac_exec_ext" 15319 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15320 break 2 15321 fi 15322 done 15323 done 15324 IFS=$as_save_IFS 15325 15326 ;; 15327 esac 15328 fi 15329 NICE=$ac_cv_path_NICE 15330 if test -n "$NICE"; then 15331 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NICE" >&5 15332 $as_echo "$NICE" >&6; } 15333 else 15334 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15335 $as_echo "no" >&6; } 15336 fi 15337 15338 15339 if test "x$NICE" = x; then 15340 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 15341 fi 15342 else 15343 # Otherwise we believe it is a complete path. Use it as it is. 15344 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NICE=$tool_specified" >&5 15345 $as_echo "$as_me: Will use user supplied tool NICE=$tool_specified" >&6;} 15346 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NICE" >&5 15347 $as_echo_n "checking for NICE... " >&6; } 15348 if test ! -x "$tool_specified"; then 15349 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 15350 $as_echo "not found" >&6; } 15351 as_fn_error $? "User supplied tool NICE=$tool_specified does not exist or is not executable" "$LINENO" 5 15352 fi 15353 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 15354 $as_echo "$tool_specified" >&6; } 15355 fi 15356 fi 15357 fi 15358 15359 fi 15360 15361 15362 15363 15364 # Publish this variable in the help. 15365 15366 15367 if [ -z "${PANDOC+x}" ]; then 15368 # The variable is not set by user, try to locate tool using the code snippet 15369 for ac_prog in pandoc 15370 do 15371 # Extract the first word of "$ac_prog", so it can be a program name with args. 15372 set dummy $ac_prog; ac_word=$2 15373 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15374 $as_echo_n "checking for $ac_word... " >&6; } 15375 if ${ac_cv_path_PANDOC+:} false; then : 15376 $as_echo_n "(cached) " >&6 15377 else 15378 case $PANDOC in 15379 [\\/]* | ?:[\\/]*) 15380 ac_cv_path_PANDOC="$PANDOC" # Let the user override the test with a path. 15381 ;; 15382 *) 15383 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15384 for as_dir in $PATH 15385 do 15386 IFS=$as_save_IFS 15387 test -z "$as_dir" && as_dir=. 15388 for ac_exec_ext in '' $ac_executable_extensions; do 15389 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15390 ac_cv_path_PANDOC="$as_dir/$ac_word$ac_exec_ext" 15391 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15392 break 2 15393 fi 15394 done 15395 done 15396 IFS=$as_save_IFS 15397 15398 ;; 15399 esac 15400 fi 15401 PANDOC=$ac_cv_path_PANDOC 15402 if test -n "$PANDOC"; then 15403 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PANDOC" >&5 15404 $as_echo "$PANDOC" >&6; } 15405 else 15406 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15407 $as_echo "no" >&6; } 15408 fi 15409 15410 15411 test -n "$PANDOC" && break 15412 done 15413 15414 else 15415 # The variable is set, but is it from the command line or the environment? 15416 15417 # Try to remove the string !PANDOC! from our list. 15418 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!PANDOC!/} 15419 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 15420 # If it failed, the variable was not from the command line. Ignore it, 15421 # but warn the user (except for BASH, which is always set by the calling BASH). 15422 if test "xPANDOC" != xBASH; then 15423 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of PANDOC from the environment. Use command line variables instead." >&5 15424 $as_echo "$as_me: WARNING: Ignoring value of PANDOC from the environment. Use command line variables instead." >&2;} 15425 fi 15426 # Try to locate tool using the code snippet 15427 for ac_prog in pandoc 15428 do 15429 # Extract the first word of "$ac_prog", so it can be a program name with args. 15430 set dummy $ac_prog; ac_word=$2 15431 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15432 $as_echo_n "checking for $ac_word... " >&6; } 15433 if ${ac_cv_path_PANDOC+:} false; then : 15434 $as_echo_n "(cached) " >&6 15435 else 15436 case $PANDOC in 15437 [\\/]* | ?:[\\/]*) 15438 ac_cv_path_PANDOC="$PANDOC" # Let the user override the test with a path. 15439 ;; 15440 *) 15441 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15442 for as_dir in $PATH 15443 do 15444 IFS=$as_save_IFS 15445 test -z "$as_dir" && as_dir=. 15446 for ac_exec_ext in '' $ac_executable_extensions; do 15447 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15448 ac_cv_path_PANDOC="$as_dir/$ac_word$ac_exec_ext" 15449 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15450 break 2 15451 fi 15452 done 15453 done 15454 IFS=$as_save_IFS 15455 15456 ;; 15457 esac 15458 fi 15459 PANDOC=$ac_cv_path_PANDOC 15460 if test -n "$PANDOC"; then 15461 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PANDOC" >&5 15462 $as_echo "$PANDOC" >&6; } 15463 else 15464 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15465 $as_echo "no" >&6; } 15466 fi 15467 15468 15469 test -n "$PANDOC" && break 15470 done 15471 15472 else 15473 # If it succeeded, then it was overridden by the user. We will use it 15474 # for the tool. 15475 15476 # First remove it from the list of overridden variables, so we can test 15477 # for unknown variables in the end. 15478 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 15479 15480 # Check if we try to supply an empty value 15481 if test "x$PANDOC" = x; then 15482 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool PANDOC= (no value)" >&5 15483 $as_echo "$as_me: Setting user supplied tool PANDOC= (no value)" >&6;} 15484 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PANDOC" >&5 15485 $as_echo_n "checking for PANDOC... " >&6; } 15486 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 15487 $as_echo "disabled" >&6; } 15488 else 15489 # Check if the provided tool contains a complete path. 15490 tool_specified="$PANDOC" 15491 tool_basename="${tool_specified##*/}" 15492 if test "x$tool_basename" = "x$tool_specified"; then 15493 # A command without a complete path is provided, search $PATH. 15494 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool PANDOC=$tool_basename" >&5 15495 $as_echo "$as_me: Will search for user supplied tool PANDOC=$tool_basename" >&6;} 15496 # Extract the first word of "$tool_basename", so it can be a program name with args. 15497 set dummy $tool_basename; ac_word=$2 15498 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15499 $as_echo_n "checking for $ac_word... " >&6; } 15500 if ${ac_cv_path_PANDOC+:} false; then : 15501 $as_echo_n "(cached) " >&6 15502 else 15503 case $PANDOC in 15504 [\\/]* | ?:[\\/]*) 15505 ac_cv_path_PANDOC="$PANDOC" # Let the user override the test with a path. 15506 ;; 15507 *) 15508 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15509 for as_dir in $PATH 15510 do 15511 IFS=$as_save_IFS 15512 test -z "$as_dir" && as_dir=. 15513 for ac_exec_ext in '' $ac_executable_extensions; do 15514 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15515 ac_cv_path_PANDOC="$as_dir/$ac_word$ac_exec_ext" 15516 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15517 break 2 15518 fi 15519 done 15520 done 15521 IFS=$as_save_IFS 15522 15523 ;; 15524 esac 15525 fi 15526 PANDOC=$ac_cv_path_PANDOC 15527 if test -n "$PANDOC"; then 15528 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PANDOC" >&5 15529 $as_echo "$PANDOC" >&6; } 15530 else 15531 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15532 $as_echo "no" >&6; } 15533 fi 15534 15535 15536 if test "x$PANDOC" = x; then 15537 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 15538 fi 15539 else 15540 # Otherwise we believe it is a complete path. Use it as it is. 15541 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool PANDOC=$tool_specified" >&5 15542 $as_echo "$as_me: Will use user supplied tool PANDOC=$tool_specified" >&6;} 15543 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PANDOC" >&5 15544 $as_echo_n "checking for PANDOC... " >&6; } 15545 if test ! -x "$tool_specified"; then 15546 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 15547 $as_echo "not found" >&6; } 15548 as_fn_error $? "User supplied tool PANDOC=$tool_specified does not exist or is not executable" "$LINENO" 5 15549 fi 15550 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 15551 $as_echo "$tool_specified" >&6; } 15552 fi 15553 fi 15554 fi 15555 15556 fi 15557 15558 15559 15560 15561 # Now we can determine OpenJDK build and target platforms. This is required to 15562 # have early on. 15563 # Make sure we can run config.sub. 15564 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || 15565 as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5 15566 15567 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5 15568 $as_echo_n "checking build system type... " >&6; } 15569 if ${ac_cv_build+:} false; then : 15570 $as_echo_n "(cached) " >&6 15571 else 15572 ac_build_alias=$build_alias 15573 test "x$ac_build_alias" = x && 15574 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"` 15575 test "x$ac_build_alias" = x && 15576 as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5 15577 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` || 15578 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5 15579 15580 fi 15581 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5 15582 $as_echo "$ac_cv_build" >&6; } 15583 case $ac_cv_build in 15584 *-*-*) ;; 15585 *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;; 15586 esac 15587 build=$ac_cv_build 15588 ac_save_IFS=$IFS; IFS='-' 15589 set x $ac_cv_build 15590 shift 15591 build_cpu=$1 15592 build_vendor=$2 15593 shift; shift 15594 # Remember, the first character of IFS is used to create $*, 15595 # except with old shells: 15596 build_os=$* 15597 IFS=$ac_save_IFS 15598 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac 15599 15600 15601 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5 15602 $as_echo_n "checking host system type... " >&6; } 15603 if ${ac_cv_host+:} false; then : 15604 $as_echo_n "(cached) " >&6 15605 else 15606 if test "x$host_alias" = x; then 15607 ac_cv_host=$ac_cv_build 15608 else 15609 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` || 15610 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5 15611 fi 15612 15613 fi 15614 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5 15615 $as_echo "$ac_cv_host" >&6; } 15616 case $ac_cv_host in 15617 *-*-*) ;; 15618 *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;; 15619 esac 15620 host=$ac_cv_host 15621 ac_save_IFS=$IFS; IFS='-' 15622 set x $ac_cv_host 15623 shift 15624 host_cpu=$1 15625 host_vendor=$2 15626 shift; shift 15627 # Remember, the first character of IFS is used to create $*, 15628 # except with old shells: 15629 host_os=$* 15630 IFS=$ac_save_IFS 15631 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac 15632 15633 15634 { $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5 15635 $as_echo_n "checking target system type... " >&6; } 15636 if ${ac_cv_target+:} false; then : 15637 $as_echo_n "(cached) " >&6 15638 else 15639 if test "x$target_alias" = x; then 15640 ac_cv_target=$ac_cv_host 15641 else 15642 ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` || 15643 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5 15644 fi 15645 15646 fi 15647 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5 15648 $as_echo "$ac_cv_target" >&6; } 15649 case $ac_cv_target in 15650 *-*-*) ;; 15651 *) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;; 15652 esac 15653 target=$ac_cv_target 15654 ac_save_IFS=$IFS; IFS='-' 15655 set x $ac_cv_target 15656 shift 15657 target_cpu=$1 15658 target_vendor=$2 15659 shift; shift 15660 # Remember, the first character of IFS is used to create $*, 15661 # except with old shells: 15662 target_os=$* 15663 IFS=$ac_save_IFS 15664 case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac 15665 15666 15667 # The aliases save the names the user supplied, while $host etc. 15668 # will get canonicalized. 15669 test -n "$target_alias" && 15670 test "$program_prefix$program_suffix$program_transform_name" = \ 15671 NONENONEs,x,x, && 15672 program_prefix=${target_alias}- 15673 15674 # Figure out the build and target systems. # Note that in autoconf terminology, "build" is obvious, but "target" 15675 # is confusing; it assumes you are cross-compiling a cross-compiler (!) and "target" is thus the target of the 15676 # product you're building. The target of this build is called "host". Since this is confusing to most people, we 15677 # have not adopted that system, but use "target" as the platform we are building for. In some places though we need 15678 # to use the configure naming style. 15679 15680 15681 15682 15683 15684 # Copy the autoconf trip/quadruplet verbatim to OPENJDK_TARGET_AUTOCONF_NAME 15685 # (from the autoconf "host") and OPENJDK_BUILD_AUTOCONF_NAME 15686 # Note that we might later on rewrite e.g. OPENJDK_TARGET_CPU due to reduced build, 15687 # but this will not change the value of OPENJDK_TARGET_AUTOCONF_NAME. 15688 OPENJDK_TARGET_AUTOCONF_NAME="$host" 15689 OPENJDK_BUILD_AUTOCONF_NAME="$build" 15690 15691 15692 15693 # Convert the autoconf OS/CPU value to our own data, into the VAR_OS/CPU variables. 15694 15695 case "$build_os" in 15696 *linux*) 15697 VAR_OS=linux 15698 VAR_OS_TYPE=unix 15699 ;; 15700 *solaris*) 15701 VAR_OS=solaris 15702 VAR_OS_TYPE=unix 15703 ;; 15704 *darwin*) 15705 VAR_OS=macosx 15706 VAR_OS_TYPE=unix 15707 ;; 15708 *bsd*) 15709 VAR_OS=bsd 15710 VAR_OS_TYPE=unix 15711 ;; 15712 *cygwin*) 15713 VAR_OS=windows 15714 VAR_OS_ENV=windows.cygwin 15715 ;; 15716 *mingw*) 15717 VAR_OS=windows 15718 VAR_OS_ENV=windows.msys 15719 ;; 15720 *aix*) 15721 VAR_OS=aix 15722 VAR_OS_TYPE=unix 15723 ;; 15724 *) 15725 as_fn_error $? "unsupported operating system $build_os" "$LINENO" 5 15726 ;; 15727 esac 15728 15729 15730 # First argument is the cpu name from the trip/quad 15731 case "$build_cpu" in 15732 x86_64) 15733 VAR_CPU=x86_64 15734 VAR_CPU_ARCH=x86 15735 VAR_CPU_BITS=64 15736 VAR_CPU_ENDIAN=little 15737 ;; 15738 i?86) 15739 VAR_CPU=x86 15740 VAR_CPU_ARCH=x86 15741 VAR_CPU_BITS=32 15742 VAR_CPU_ENDIAN=little 15743 ;; 15744 arm*) 15745 VAR_CPU=arm 15746 VAR_CPU_ARCH=arm 15747 VAR_CPU_BITS=32 15748 VAR_CPU_ENDIAN=little 15749 ;; 15750 aarch64) 15751 VAR_CPU=aarch64 15752 VAR_CPU_ARCH=aarch64 15753 VAR_CPU_BITS=64 15754 VAR_CPU_ENDIAN=little 15755 ;; 15756 powerpc) 15757 VAR_CPU=ppc 15758 VAR_CPU_ARCH=ppc 15759 VAR_CPU_BITS=32 15760 VAR_CPU_ENDIAN=big 15761 ;; 15762 powerpc64) 15763 VAR_CPU=ppc64 15764 VAR_CPU_ARCH=ppc 15765 VAR_CPU_BITS=64 15766 VAR_CPU_ENDIAN=big 15767 ;; 15768 powerpc64le) 15769 VAR_CPU=ppc64le 15770 VAR_CPU_ARCH=ppc 15771 VAR_CPU_BITS=64 15772 VAR_CPU_ENDIAN=little 15773 ;; 15774 s390) 15775 VAR_CPU=s390 15776 VAR_CPU_ARCH=s390 15777 VAR_CPU_BITS=32 15778 VAR_CPU_ENDIAN=big 15779 ;; 15780 s390x) 15781 VAR_CPU=s390x 15782 VAR_CPU_ARCH=s390 15783 VAR_CPU_BITS=64 15784 VAR_CPU_ENDIAN=big 15785 ;; 15786 sparc) 15787 VAR_CPU=sparc 15788 VAR_CPU_ARCH=sparc 15789 VAR_CPU_BITS=32 15790 VAR_CPU_ENDIAN=big 15791 ;; 15792 sparcv9|sparc64) 15793 VAR_CPU=sparcv9 15794 VAR_CPU_ARCH=sparc 15795 VAR_CPU_BITS=64 15796 VAR_CPU_ENDIAN=big 15797 ;; 15798 *) 15799 as_fn_error $? "unsupported cpu $build_cpu" "$LINENO" 5 15800 ;; 15801 esac 15802 15803 # ..and setup our own variables. (Do this explicitly to facilitate searching) 15804 OPENJDK_BUILD_OS="$VAR_OS" 15805 if test "x$VAR_OS_TYPE" != x; then 15806 OPENJDK_BUILD_OS_TYPE="$VAR_OS_TYPE" 15807 else 15808 OPENJDK_BUILD_OS_TYPE="$VAR_OS" 15809 fi 15810 if test "x$VAR_OS_ENV" != x; then 15811 OPENJDK_BUILD_OS_ENV="$VAR_OS_ENV" 15812 else 15813 OPENJDK_BUILD_OS_ENV="$VAR_OS" 15814 fi 15815 OPENJDK_BUILD_CPU="$VAR_CPU" 15816 OPENJDK_BUILD_CPU_ARCH="$VAR_CPU_ARCH" 15817 OPENJDK_BUILD_CPU_BITS="$VAR_CPU_BITS" 15818 OPENJDK_BUILD_CPU_ENDIAN="$VAR_CPU_ENDIAN" 15819 15820 15821 15822 15823 15824 15825 15826 15827 { $as_echo "$as_me:${as_lineno-$LINENO}: checking openjdk-build os-cpu" >&5 15828 $as_echo_n "checking openjdk-build os-cpu... " >&6; } 15829 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_BUILD_OS-$OPENJDK_BUILD_CPU" >&5 15830 $as_echo "$OPENJDK_BUILD_OS-$OPENJDK_BUILD_CPU" >&6; } 15831 15832 # Convert the autoconf OS/CPU value to our own data, into the VAR_OS/CPU variables. 15833 15834 case "$host_os" in 15835 *linux*) 15836 VAR_OS=linux 15837 VAR_OS_TYPE=unix 15838 ;; 15839 *solaris*) 15840 VAR_OS=solaris 15841 VAR_OS_TYPE=unix 15842 ;; 15843 *darwin*) 15844 VAR_OS=macosx 15845 VAR_OS_TYPE=unix 15846 ;; 15847 *bsd*) 15848 VAR_OS=bsd 15849 VAR_OS_TYPE=unix 15850 ;; 15851 *cygwin*) 15852 VAR_OS=windows 15853 VAR_OS_ENV=windows.cygwin 15854 ;; 15855 *mingw*) 15856 VAR_OS=windows 15857 VAR_OS_ENV=windows.msys 15858 ;; 15859 *aix*) 15860 VAR_OS=aix 15861 VAR_OS_TYPE=unix 15862 ;; 15863 *) 15864 as_fn_error $? "unsupported operating system $host_os" "$LINENO" 5 15865 ;; 15866 esac 15867 15868 15869 # First argument is the cpu name from the trip/quad 15870 case "$host_cpu" in 15871 x86_64) 15872 VAR_CPU=x86_64 15873 VAR_CPU_ARCH=x86 15874 VAR_CPU_BITS=64 15875 VAR_CPU_ENDIAN=little 15876 ;; 15877 i?86) 15878 VAR_CPU=x86 15879 VAR_CPU_ARCH=x86 15880 VAR_CPU_BITS=32 15881 VAR_CPU_ENDIAN=little 15882 ;; 15883 arm*) 15884 VAR_CPU=arm 15885 VAR_CPU_ARCH=arm 15886 VAR_CPU_BITS=32 15887 VAR_CPU_ENDIAN=little 15888 ;; 15889 aarch64) 15890 VAR_CPU=aarch64 15891 VAR_CPU_ARCH=aarch64 15892 VAR_CPU_BITS=64 15893 VAR_CPU_ENDIAN=little 15894 ;; 15895 powerpc) 15896 VAR_CPU=ppc 15897 VAR_CPU_ARCH=ppc 15898 VAR_CPU_BITS=32 15899 VAR_CPU_ENDIAN=big 15900 ;; 15901 powerpc64) 15902 VAR_CPU=ppc64 15903 VAR_CPU_ARCH=ppc 15904 VAR_CPU_BITS=64 15905 VAR_CPU_ENDIAN=big 15906 ;; 15907 powerpc64le) 15908 VAR_CPU=ppc64le 15909 VAR_CPU_ARCH=ppc 15910 VAR_CPU_BITS=64 15911 VAR_CPU_ENDIAN=little 15912 ;; 15913 s390) 15914 VAR_CPU=s390 15915 VAR_CPU_ARCH=s390 15916 VAR_CPU_BITS=32 15917 VAR_CPU_ENDIAN=big 15918 ;; 15919 s390x) 15920 VAR_CPU=s390x 15921 VAR_CPU_ARCH=s390 15922 VAR_CPU_BITS=64 15923 VAR_CPU_ENDIAN=big 15924 ;; 15925 sparc) 15926 VAR_CPU=sparc 15927 VAR_CPU_ARCH=sparc 15928 VAR_CPU_BITS=32 15929 VAR_CPU_ENDIAN=big 15930 ;; 15931 sparcv9|sparc64) 15932 VAR_CPU=sparcv9 15933 VAR_CPU_ARCH=sparc 15934 VAR_CPU_BITS=64 15935 VAR_CPU_ENDIAN=big 15936 ;; 15937 *) 15938 as_fn_error $? "unsupported cpu $host_cpu" "$LINENO" 5 15939 ;; 15940 esac 15941 15942 # ... and setup our own variables. (Do this explicitly to facilitate searching) 15943 OPENJDK_TARGET_OS="$VAR_OS" 15944 if test "x$VAR_OS_TYPE" != x; then 15945 OPENJDK_TARGET_OS_TYPE="$VAR_OS_TYPE" 15946 else 15947 OPENJDK_TARGET_OS_TYPE="$VAR_OS" 15948 fi 15949 if test "x$VAR_OS_ENV" != x; then 15950 OPENJDK_TARGET_OS_ENV="$VAR_OS_ENV" 15951 else 15952 OPENJDK_TARGET_OS_ENV="$VAR_OS" 15953 fi 15954 OPENJDK_TARGET_CPU="$VAR_CPU" 15955 OPENJDK_TARGET_CPU_ARCH="$VAR_CPU_ARCH" 15956 OPENJDK_TARGET_CPU_BITS="$VAR_CPU_BITS" 15957 OPENJDK_TARGET_CPU_ENDIAN="$VAR_CPU_ENDIAN" 15958 15959 15960 15961 15962 15963 15964 15965 15966 { $as_echo "$as_me:${as_lineno-$LINENO}: checking openjdk-target os-cpu" >&5 15967 $as_echo_n "checking openjdk-target os-cpu... " >&6; } 15968 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" >&5 15969 $as_echo "$OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" >&6; } 15970 15971 15972 15973 # Check whether --with-target-bits was given. 15974 if test "${with_target_bits+set}" = set; then : 15975 withval=$with_target_bits; 15976 fi 15977 15978 15979 # We have three types of compiles: 15980 # native == normal compilation, target system == build system 15981 # cross == traditional cross compilation, target system != build system; special toolchain needed 15982 # reduced == using native compilers, but with special flags (e.g. -m32) to produce 32-bit builds on 64-bit machines 15983 # 15984 if test "x$OPENJDK_BUILD_AUTOCONF_NAME" != "x$OPENJDK_TARGET_AUTOCONF_NAME"; then 15985 # We're doing a proper cross-compilation 15986 COMPILE_TYPE="cross" 15987 else 15988 COMPILE_TYPE="native" 15989 fi 15990 15991 if test "x$with_target_bits" != x; then 15992 if test "x$COMPILE_TYPE" = "xcross"; then 15993 as_fn_error $? "It is not possible to combine --with-target-bits=X and proper cross-compilation. Choose either." "$LINENO" 5 15994 fi 15995 15996 if test "x$with_target_bits" = x32 && test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 15997 # A reduced build is requested 15998 COMPILE_TYPE="reduced" 15999 OPENJDK_TARGET_CPU_BITS=32 16000 if test "x$OPENJDK_TARGET_CPU_ARCH" = "xx86"; then 16001 OPENJDK_TARGET_CPU=x86 16002 elif test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then 16003 OPENJDK_TARGET_CPU=sparc 16004 else 16005 as_fn_error $? "Reduced build (--with-target-bits=32) is only supported on x86_64 and sparcv9" "$LINENO" 5 16006 fi 16007 elif test "x$with_target_bits" = x64 && test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 16008 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 16009 elif test "x$with_target_bits" = "x$OPENJDK_TARGET_CPU_BITS"; then 16010 { $as_echo "$as_me:${as_lineno-$LINENO}: --with-target-bits are set to build platform address size; argument has no meaning" >&5 16011 $as_echo "$as_me: --with-target-bits are set to build platform address size; argument has no meaning" >&6;} 16012 else 16013 as_fn_error $? "--with-target-bits can only be 32 or 64, you specified $with_target_bits!" "$LINENO" 5 16014 fi 16015 fi 16016 16017 16018 { $as_echo "$as_me:${as_lineno-$LINENO}: checking compilation type" >&5 16019 $as_echo_n "checking compilation type... " >&6; } 16020 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMPILE_TYPE" >&5 16021 $as_echo "$COMPILE_TYPE" >&6; } 16022 16023 16024 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 16025 OPENJDK_MODULE_TARGET_OS_NAME="macos" 16026 else 16027 OPENJDK_MODULE_TARGET_OS_NAME="$OPENJDK_TARGET_OS" 16028 fi 16029 16030 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 16031 OPENJDK_MODULE_TARGET_OS_ARCH="amd64" 16032 else 16033 OPENJDK_MODULE_TARGET_OS_ARCH="$OPENJDK_TARGET_CPU" 16034 fi 16035 16036 16037 16038 16039 16040 16041 # Also store the legacy naming of the cpu. 16042 # Ie i586 and amd64 instead of x86 and x86_64 16043 OPENJDK_TARGET_CPU_LEGACY="$OPENJDK_TARGET_CPU" 16044 if test "x$OPENJDK_TARGET_CPU" = xx86; then 16045 OPENJDK_TARGET_CPU_LEGACY="i586" 16046 elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then 16047 # On all platforms except MacOSX replace x86_64 with amd64. 16048 OPENJDK_TARGET_CPU_LEGACY="amd64" 16049 fi 16050 16051 16052 # And the second legacy naming of the cpu. 16053 # Ie i386 and amd64 instead of x86 and x86_64. 16054 OPENJDK_TARGET_CPU_LEGACY_LIB="$OPENJDK_TARGET_CPU" 16055 if test "x$OPENJDK_TARGET_CPU" = xx86; then 16056 OPENJDK_TARGET_CPU_LEGACY_LIB="i386" 16057 elif test "x$OPENJDK_TARGET_CPU" = xx86_64; then 16058 OPENJDK_TARGET_CPU_LEGACY_LIB="amd64" 16059 fi 16060 16061 16062 # OPENJDK_TARGET_CPU_ISADIR is normally empty. On 64-bit Solaris systems, it is set to 16063 # /amd64 or /sparcv9. This string is appended to some library paths, like this: 16064 # /usr/lib${OPENJDK_TARGET_CPU_ISADIR}/libexample.so 16065 OPENJDK_TARGET_CPU_ISADIR="" 16066 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 16067 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 16068 OPENJDK_TARGET_CPU_ISADIR="/amd64" 16069 elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then 16070 OPENJDK_TARGET_CPU_ISADIR="/sparcv9" 16071 fi 16072 fi 16073 16074 16075 # Setup OPENJDK_TARGET_CPU_OSARCH, which is used to set the os.arch Java system property 16076 OPENJDK_TARGET_CPU_OSARCH="$OPENJDK_TARGET_CPU" 16077 if test "x$OPENJDK_TARGET_OS" = xlinux && test "x$OPENJDK_TARGET_CPU" = xx86; then 16078 # On linux only, we replace x86 with i386. 16079 OPENJDK_TARGET_CPU_OSARCH="i386" 16080 elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then 16081 # On all platforms except macosx, we replace x86_64 with amd64. 16082 OPENJDK_TARGET_CPU_OSARCH="amd64" 16083 fi 16084 16085 16086 OPENJDK_TARGET_CPU_JLI="$OPENJDK_TARGET_CPU" 16087 if test "x$OPENJDK_TARGET_CPU" = xx86; then 16088 OPENJDK_TARGET_CPU_JLI="i386" 16089 elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then 16090 # On all platforms except macosx, we replace x86_64 with amd64. 16091 OPENJDK_TARGET_CPU_JLI="amd64" 16092 fi 16093 16094 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 16095 OPENJDK_TARGET_OS_EXPORT_DIR=macosx 16096 else 16097 OPENJDK_TARGET_OS_EXPORT_DIR=${OPENJDK_TARGET_OS_TYPE} 16098 fi 16099 16100 16101 # The new version string in JDK 9 also defined new naming of OS and ARCH for bundles 16102 # Macosx is osx and x86_64 is x64 16103 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 16104 OPENJDK_TARGET_OS_BUNDLE="osx" 16105 else 16106 OPENJDK_TARGET_OS_BUNDLE="$OPENJDK_TARGET_OS" 16107 fi 16108 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 16109 OPENJDK_TARGET_CPU_BUNDLE="x64" 16110 else 16111 OPENJDK_TARGET_CPU_BUNDLE="$OPENJDK_TARGET_CPU" 16112 fi 16113 OPENJDK_TARGET_BUNDLE_PLATFORM="${OPENJDK_TARGET_OS_BUNDLE}-${OPENJDK_TARGET_CPU_BUNDLE}" 16114 16115 16116 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 16117 # -D_LP64=1 is only set on linux and mac. Setting on windows causes diff in 16118 # unpack200.exe. This variable is used in 16119 # FLAGS_SETUP_COMPILER_FLAGS_FOR_JDK_HELPER. 16120 if test "x$OPENJDK_TARGET_OS" = xlinux || test "x$OPENJDK_TARGET_OS" = xmacosx; then 16121 OPENJDK_TARGET_ADD_LP64="-D_LP64=1" 16122 fi 16123 fi 16124 16125 if test "x$COMPILE_TYPE" = "xcross"; then 16126 # FIXME: ... or should this include reduced builds..? 16127 DEFINE_CROSS_COMPILE_ARCH="CROSS_COMPILE_ARCH:=$OPENJDK_TARGET_CPU_LEGACY" 16128 else 16129 DEFINE_CROSS_COMPILE_ARCH="" 16130 fi 16131 16132 16133 # Convert openjdk platform names to hotspot names 16134 16135 HOTSPOT_TARGET_OS=${OPENJDK_TARGET_OS} 16136 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 16137 HOTSPOT_TARGET_OS=bsd 16138 fi 16139 16140 16141 HOTSPOT_TARGET_OS_TYPE=${OPENJDK_TARGET_OS_TYPE} 16142 if test "x$OPENJDK_TARGET_OS_TYPE" = xunix; then 16143 HOTSPOT_TARGET_OS_TYPE=posix 16144 fi 16145 16146 16147 HOTSPOT_TARGET_CPU=${OPENJDK_TARGET_CPU} 16148 if test "x$OPENJDK_TARGET_CPU" = xx86; then 16149 HOTSPOT_TARGET_CPU=x86_32 16150 elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then 16151 HOTSPOT_TARGET_CPU=sparc 16152 elif test "x$OPENJDK_TARGET_CPU" = xppc64; then 16153 HOTSPOT_TARGET_CPU=ppc_64 16154 elif test "x$OPENJDK_TARGET_CPU" = xppc64le; then 16155 HOTSPOT_TARGET_CPU=ppc_64 16156 fi 16157 16158 16159 # This is identical with OPENJDK_*, but define anyway for consistency. 16160 HOTSPOT_TARGET_CPU_ARCH=${OPENJDK_TARGET_CPU_ARCH} 16161 16162 16163 # Setup HOTSPOT_TARGET_CPU_DEFINE 16164 if test "x$OPENJDK_TARGET_CPU" = xx86; then 16165 HOTSPOT_TARGET_CPU_DEFINE=IA32 16166 elif test "x$OPENJDK_TARGET_CPU" = xx86_64; then 16167 HOTSPOT_TARGET_CPU_DEFINE=AMD64 16168 elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then 16169 HOTSPOT_TARGET_CPU_DEFINE=SPARC 16170 elif test "x$OPENJDK_TARGET_CPU" = xaarch64; then 16171 HOTSPOT_TARGET_CPU_DEFINE=AARCH64 16172 elif test "x$OPENJDK_TARGET_CPU" = xppc64; then 16173 HOTSPOT_TARGET_CPU_DEFINE=PPC64 16174 elif test "x$OPENJDK_TARGET_CPU" = xppc64le; then 16175 HOTSPOT_TARGET_CPU_DEFINE=PPC64 16176 16177 # The cpu defines below are for zero, we don't support them directly. 16178 elif test "x$OPENJDK_TARGET_CPU" = xsparc; then 16179 HOTSPOT_TARGET_CPU_DEFINE=SPARC 16180 elif test "x$OPENJDK_TARGET_CPU" = xppc; then 16181 HOTSPOT_TARGET_CPU_DEFINE=PPC32 16182 elif test "x$OPENJDK_TARGET_CPU" = xs390; then 16183 HOTSPOT_TARGET_CPU_DEFINE=S390 16184 elif test "x$OPENJDK_TARGET_CPU" = xs390x; then 16185 HOTSPOT_TARGET_CPU_DEFINE=S390 16186 elif test "x$OPENJDK_TARGET_CPU" != x; then 16187 HOTSPOT_TARGET_CPU_DEFINE=$(echo $OPENJDK_TARGET_CPU | tr a-z A-Z) 16188 fi 16189 16190 16191 16192 16193 # Also store the legacy naming of the cpu. 16194 # Ie i586 and amd64 instead of x86 and x86_64 16195 OPENJDK_BUILD_CPU_LEGACY="$OPENJDK_BUILD_CPU" 16196 if test "x$OPENJDK_BUILD_CPU" = xx86; then 16197 OPENJDK_BUILD_CPU_LEGACY="i586" 16198 elif test "x$OPENJDK_BUILD_OS" != xmacosx && test "x$OPENJDK_BUILD_CPU" = xx86_64; then 16199 # On all platforms except MacOSX replace x86_64 with amd64. 16200 OPENJDK_BUILD_CPU_LEGACY="amd64" 16201 fi 16202 16203 16204 # And the second legacy naming of the cpu. 16205 # Ie i386 and amd64 instead of x86 and x86_64. 16206 OPENJDK_BUILD_CPU_LEGACY_LIB="$OPENJDK_BUILD_CPU" 16207 if test "x$OPENJDK_BUILD_CPU" = xx86; then 16208 OPENJDK_BUILD_CPU_LEGACY_LIB="i386" 16209 elif test "x$OPENJDK_BUILD_CPU" = xx86_64; then 16210 OPENJDK_BUILD_CPU_LEGACY_LIB="amd64" 16211 fi 16212 16213 16214 # OPENJDK_BUILD_CPU_ISADIR is normally empty. On 64-bit Solaris systems, it is set to 16215 # /amd64 or /sparcv9. This string is appended to some library paths, like this: 16216 # /usr/lib${OPENJDK_BUILD_CPU_ISADIR}/libexample.so 16217 OPENJDK_BUILD_CPU_ISADIR="" 16218 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 16219 if test "x$OPENJDK_BUILD_CPU" = xx86_64; then 16220 OPENJDK_BUILD_CPU_ISADIR="/amd64" 16221 elif test "x$OPENJDK_BUILD_CPU" = xsparcv9; then 16222 OPENJDK_BUILD_CPU_ISADIR="/sparcv9" 16223 fi 16224 fi 16225 16226 16227 # Setup OPENJDK_BUILD_CPU_OSARCH, which is used to set the os.arch Java system property 16228 OPENJDK_BUILD_CPU_OSARCH="$OPENJDK_BUILD_CPU" 16229 if test "x$OPENJDK_BUILD_OS" = xlinux && test "x$OPENJDK_BUILD_CPU" = xx86; then 16230 # On linux only, we replace x86 with i386. 16231 OPENJDK_BUILD_CPU_OSARCH="i386" 16232 elif test "x$OPENJDK_BUILD_OS" != xmacosx && test "x$OPENJDK_BUILD_CPU" = xx86_64; then 16233 # On all platforms except macosx, we replace x86_64 with amd64. 16234 OPENJDK_BUILD_CPU_OSARCH="amd64" 16235 fi 16236 16237 16238 OPENJDK_BUILD_CPU_JLI="$OPENJDK_BUILD_CPU" 16239 if test "x$OPENJDK_BUILD_CPU" = xx86; then 16240 OPENJDK_BUILD_CPU_JLI="i386" 16241 elif test "x$OPENJDK_BUILD_OS" != xmacosx && test "x$OPENJDK_BUILD_CPU" = xx86_64; then 16242 # On all platforms except macosx, we replace x86_64 with amd64. 16243 OPENJDK_BUILD_CPU_JLI="amd64" 16244 fi 16245 16246 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 16247 OPENJDK_BUILD_OS_EXPORT_DIR=macosx 16248 else 16249 OPENJDK_BUILD_OS_EXPORT_DIR=${OPENJDK_BUILD_OS_TYPE} 16250 fi 16251 16252 16253 # The new version string in JDK 9 also defined new naming of OS and ARCH for bundles 16254 # Macosx is osx and x86_64 is x64 16255 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 16256 OPENJDK_BUILD_OS_BUNDLE="osx" 16257 else 16258 OPENJDK_BUILD_OS_BUNDLE="$OPENJDK_TARGET_OS" 16259 fi 16260 if test "x$OPENJDK_BUILD_CPU" = xx86_64; then 16261 OPENJDK_BUILD_CPU_BUNDLE="x64" 16262 else 16263 OPENJDK_BUILD_CPU_BUNDLE="$OPENJDK_BUILD_CPU" 16264 fi 16265 OPENJDK_BUILD_BUNDLE_PLATFORM="${OPENJDK_BUILD_OS_BUNDLE}-${OPENJDK_BUILD_CPU_BUNDLE}" 16266 16267 16268 if test "x$OPENJDK_BUILD_CPU_BITS" = x64; then 16269 # -D_LP64=1 is only set on linux and mac. Setting on windows causes diff in 16270 # unpack200.exe. This variable is used in 16271 # FLAGS_SETUP_COMPILER_FLAGS_FOR_JDK_HELPER. 16272 if test "x$OPENJDK_BUILD_OS" = xlinux || test "x$OPENJDK_BUILD_OS" = xmacosx; then 16273 OPENJDK_BUILD_ADD_LP64="-D_LP64=1" 16274 fi 16275 fi 16276 16277 if test "x$COMPILE_TYPE" = "xcross"; then 16278 # FIXME: ... or should this include reduced builds..? 16279 DEFINE_CROSS_COMPILE_ARCH="CROSS_COMPILE_ARCH:=$OPENJDK_BUILD_CPU_LEGACY" 16280 else 16281 DEFINE_CROSS_COMPILE_ARCH="" 16282 fi 16283 16284 16285 # Convert openjdk platform names to hotspot names 16286 16287 HOTSPOT_BUILD_OS=${OPENJDK_BUILD_OS} 16288 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 16289 HOTSPOT_BUILD_OS=bsd 16290 fi 16291 16292 16293 HOTSPOT_BUILD_OS_TYPE=${OPENJDK_BUILD_OS_TYPE} 16294 if test "x$OPENJDK_BUILD_OS_TYPE" = xunix; then 16295 HOTSPOT_BUILD_OS_TYPE=posix 16296 fi 16297 16298 16299 HOTSPOT_BUILD_CPU=${OPENJDK_BUILD_CPU} 16300 if test "x$OPENJDK_BUILD_CPU" = xx86; then 16301 HOTSPOT_BUILD_CPU=x86_32 16302 elif test "x$OPENJDK_BUILD_CPU" = xsparcv9; then 16303 HOTSPOT_BUILD_CPU=sparc 16304 elif test "x$OPENJDK_BUILD_CPU" = xppc64; then 16305 HOTSPOT_BUILD_CPU=ppc_64 16306 elif test "x$OPENJDK_BUILD_CPU" = xppc64le; then 16307 HOTSPOT_BUILD_CPU=ppc_64 16308 fi 16309 16310 16311 # This is identical with OPENJDK_*, but define anyway for consistency. 16312 HOTSPOT_BUILD_CPU_ARCH=${OPENJDK_BUILD_CPU_ARCH} 16313 16314 16315 # Setup HOTSPOT_BUILD_CPU_DEFINE 16316 if test "x$OPENJDK_BUILD_CPU" = xx86; then 16317 HOTSPOT_BUILD_CPU_DEFINE=IA32 16318 elif test "x$OPENJDK_BUILD_CPU" = xx86_64; then 16319 HOTSPOT_BUILD_CPU_DEFINE=AMD64 16320 elif test "x$OPENJDK_BUILD_CPU" = xsparcv9; then 16321 HOTSPOT_BUILD_CPU_DEFINE=SPARC 16322 elif test "x$OPENJDK_BUILD_CPU" = xaarch64; then 16323 HOTSPOT_BUILD_CPU_DEFINE=AARCH64 16324 elif test "x$OPENJDK_BUILD_CPU" = xppc64; then 16325 HOTSPOT_BUILD_CPU_DEFINE=PPC64 16326 elif test "x$OPENJDK_BUILD_CPU" = xppc64le; then 16327 HOTSPOT_BUILD_CPU_DEFINE=PPC64 16328 16329 # The cpu defines below are for zero, we don't support them directly. 16330 elif test "x$OPENJDK_BUILD_CPU" = xsparc; then 16331 HOTSPOT_BUILD_CPU_DEFINE=SPARC 16332 elif test "x$OPENJDK_BUILD_CPU" = xppc; then 16333 HOTSPOT_BUILD_CPU_DEFINE=PPC32 16334 elif test "x$OPENJDK_BUILD_CPU" = xs390; then 16335 HOTSPOT_BUILD_CPU_DEFINE=S390 16336 elif test "x$OPENJDK_BUILD_CPU" = xs390x; then 16337 HOTSPOT_BUILD_CPU_DEFINE=S390 16338 elif test "x$OPENJDK_BUILD_CPU" != x; then 16339 HOTSPOT_BUILD_CPU_DEFINE=$(echo $OPENJDK_BUILD_CPU | tr a-z A-Z) 16340 fi 16341 16342 16343 16344 16345 16346 16347 # Continue setting up basic stuff. Most remaining code require fundamental tools. 16348 16349 # Save the current directory this script was started from 16350 CURDIR="$PWD" 16351 16352 # We might need to rewrite ORIGINAL_PATH, if it includes "#", to quote them 16353 # for make. We couldn't do this when we retrieved ORIGINAL_PATH, since SED 16354 # was not available at that time. 16355 REWRITTEN_PATH=`$ECHO "$ORIGINAL_PATH" | $SED -e 's/#/\\\\#/g'` 16356 if test "x$REWRITTEN_PATH" != "x$ORIGINAL_PATH"; then 16357 ORIGINAL_PATH="$REWRITTEN_PATH" 16358 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting ORIGINAL_PATH to $REWRITTEN_PATH" >&5 16359 $as_echo "$as_me: Rewriting ORIGINAL_PATH to $REWRITTEN_PATH" >&6;} 16360 fi 16361 16362 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 16363 PATH_SEP=";" 16364 16365 SRC_ROOT_LENGTH=`$THEPWDCMD -L|$WC -m` 16366 if test $SRC_ROOT_LENGTH -gt 100; then 16367 as_fn_error $? "Your base path is too long. It is $SRC_ROOT_LENGTH characters long, but only 100 is supported" "$LINENO" 5 16368 fi 16369 16370 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16371 { $as_echo "$as_me:${as_lineno-$LINENO}: checking cygwin release" >&5 16372 $as_echo_n "checking cygwin release... " >&6; } 16373 CYGWIN_VERSION=`$UNAME -r` 16374 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_VERSION" >&5 16375 $as_echo "$CYGWIN_VERSION" >&6; } 16376 WINDOWS_ENV_VENDOR='cygwin' 16377 WINDOWS_ENV_VERSION="$CYGWIN_VERSION" 16378 16379 CYGWIN_VERSION_OLD=`$ECHO $CYGWIN_VERSION | $GREP -e '^1\.0-6'` 16380 if test "x$CYGWIN_VERSION_OLD" != x; then 16381 { $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 16382 $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;} 16383 as_fn_error $? "Cannot continue" "$LINENO" 5 16384 fi 16385 if test "x$CYGPATH" = x; then 16386 as_fn_error $? "Something is wrong with your cygwin installation since I cannot find cygpath.exe in your path" "$LINENO" 5 16387 fi 16388 { $as_echo "$as_me:${as_lineno-$LINENO}: checking cygwin root directory as unix-style path" >&5 16389 $as_echo_n "checking cygwin root directory as unix-style path... " >&6; } 16390 # The cmd output ends with Windows line endings (CR/LF) 16391 cygwin_winpath_root=`cd / ; cmd /c cd | $TR -d '\r\n'` 16392 # Force cygpath to report the proper root by including a trailing space, and then stripping it off again. 16393 CYGWIN_ROOT_PATH=`$CYGPATH -u "$cygwin_winpath_root " | $CUT -f 1 -d " "` 16394 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_ROOT_PATH" >&5 16395 $as_echo "$CYGWIN_ROOT_PATH" >&6; } 16396 WINDOWS_ENV_ROOT_PATH="$CYGWIN_ROOT_PATH" 16397 test_cygdrive_prefix=`$ECHO $CYGWIN_ROOT_PATH | $GREP ^/cygdrive/` 16398 if test "x$test_cygdrive_prefix" = x; then 16399 as_fn_error $? "Your cygdrive prefix is not /cygdrive. This is currently not supported. Change with mount -c." "$LINENO" 5 16400 fi 16401 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16402 { $as_echo "$as_me:${as_lineno-$LINENO}: checking msys release" >&5 16403 $as_echo_n "checking msys release... " >&6; } 16404 MSYS_VERSION=`$UNAME -r` 16405 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSYS_VERSION" >&5 16406 $as_echo "$MSYS_VERSION" >&6; } 16407 16408 WINDOWS_ENV_VENDOR='msys' 16409 WINDOWS_ENV_VERSION="$MSYS_VERSION" 16410 16411 { $as_echo "$as_me:${as_lineno-$LINENO}: checking msys root directory as unix-style path" >&5 16412 $as_echo_n "checking msys root directory as unix-style path... " >&6; } 16413 # The cmd output ends with Windows line endings (CR/LF), the grep command will strip that away 16414 MSYS_ROOT_PATH=`cd / ; cmd /c cd | $GREP ".*"` 16415 16416 windows_path="$MSYS_ROOT_PATH" 16417 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16418 unix_path=`$CYGPATH -u "$windows_path"` 16419 MSYS_ROOT_PATH="$unix_path" 16420 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16421 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16422 MSYS_ROOT_PATH="$unix_path" 16423 fi 16424 16425 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSYS_ROOT_PATH" >&5 16426 $as_echo "$MSYS_ROOT_PATH" >&6; } 16427 WINDOWS_ENV_ROOT_PATH="$MSYS_ROOT_PATH" 16428 else 16429 as_fn_error $? "Unknown Windows environment. Neither cygwin nor msys was detected." "$LINENO" 5 16430 fi 16431 16432 # Test if windows or unix (cygwin/msys) find is first in path. 16433 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what kind of 'find' is first on the PATH" >&5 16434 $as_echo_n "checking what kind of 'find' is first on the PATH... " >&6; } 16435 FIND_BINARY_OUTPUT=`find --version 2>&1` 16436 if test "x`echo $FIND_BINARY_OUTPUT | $GREP GNU`" != x; then 16437 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unix style" >&5 16438 $as_echo "unix style" >&6; } 16439 elif test "x`echo $FIND_BINARY_OUTPUT | $GREP FIND`" != x; then 16440 { $as_echo "$as_me:${as_lineno-$LINENO}: result: Windows" >&5 16441 $as_echo "Windows" >&6; } 16442 { $as_echo "$as_me:${as_lineno-$LINENO}: Your path contains Windows tools (C:\Windows\system32) before your unix (cygwin or msys) tools." >&5 16443 $as_echo "$as_me: Your path contains Windows tools (C:\Windows\system32) before your unix (cygwin or msys) tools." >&6;} 16444 { $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 16445 $as_echo "$as_me: This will not work. Please correct and make sure /usr/bin (or similar) is first in path." >&6;} 16446 as_fn_error $? "Cannot continue" "$LINENO" 5 16447 else 16448 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unknown" >&5 16449 $as_echo "unknown" >&6; } 16450 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: It seems that your find utility is non-standard." >&5 16451 $as_echo "$as_me: WARNING: It seems that your find utility is non-standard." >&2;} 16452 fi 16453 16454 else 16455 PATH_SEP=":" 16456 fi 16457 16458 16459 # We get the top-level directory from the supporting wrappers. 16460 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for top-level directory" >&5 16461 $as_echo_n "checking for top-level directory... " >&6; } 16462 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOPDIR" >&5 16463 $as_echo "$TOPDIR" >&6; } 16464 16465 16466 # Save the original version of TOPDIR for string comparisons 16467 ORIGINAL_TOPDIR="$TOPDIR" 16468 16469 16470 # We can only call BASIC_FIXUP_PATH after BASIC_CHECK_PATHS_WINDOWS. 16471 16472 # Only process if variable expands to non-empty 16473 16474 if test "x$CURDIR" != x; then 16475 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16476 16477 # Input might be given as Windows format, start by converting to 16478 # unix format. 16479 path="$CURDIR" 16480 new_path=`$CYGPATH -u "$path"` 16481 16482 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 16483 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 16484 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 16485 # "foo.exe" is OK but "foo" is an error. 16486 # 16487 # This test is therefore slightly more accurate than "test -f" to check for file precense. 16488 # It is also a way to make sure we got the proper file name for the real test later on. 16489 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 16490 if test "x$test_shortpath" = x; then 16491 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CURDIR, which resolves as \"$path\", is invalid." >&5 16492 $as_echo "$as_me: The path of CURDIR, which resolves as \"$path\", is invalid." >&6;} 16493 as_fn_error $? "Cannot locate the the path of CURDIR" "$LINENO" 5 16494 fi 16495 16496 # Call helper function which possibly converts this using DOS-style short mode. 16497 # If so, the updated path is stored in $new_path. 16498 16499 input_path="$new_path" 16500 # Check if we need to convert this using DOS-style short mode. If the path 16501 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16502 # take no chances and rewrite it. 16503 # Note: m4 eats our [], so we need to use [ and ] instead. 16504 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 16505 if test "x$has_forbidden_chars" != x; then 16506 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16507 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 16508 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 16509 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 16510 # Going to short mode and back again did indeed matter. Since short mode is 16511 # case insensitive, let's make it lowercase to improve readability. 16512 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16513 # Now convert it back to Unix-style (cygpath) 16514 input_path=`$CYGPATH -u "$shortmode_path"` 16515 new_path="$input_path" 16516 fi 16517 fi 16518 16519 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 16520 if test "x$test_cygdrive_prefix" = x; then 16521 # As a simple fix, exclude /usr/bin since it's not a real path. 16522 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 16523 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 16524 # a path prefixed by /cygdrive for fixpath to work. 16525 new_path="$CYGWIN_ROOT_PATH$input_path" 16526 fi 16527 fi 16528 16529 16530 if test "x$path" != "x$new_path"; then 16531 CURDIR="$new_path" 16532 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CURDIR to \"$new_path\"" >&5 16533 $as_echo "$as_me: Rewriting CURDIR to \"$new_path\"" >&6;} 16534 fi 16535 16536 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16537 16538 path="$CURDIR" 16539 has_colon=`$ECHO $path | $GREP ^.:` 16540 new_path="$path" 16541 if test "x$has_colon" = x; then 16542 # Not in mixed or Windows style, start by that. 16543 new_path=`cmd //c echo $path` 16544 fi 16545 16546 16547 input_path="$new_path" 16548 # Check if we need to convert this using DOS-style short mode. If the path 16549 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16550 # take no chances and rewrite it. 16551 # Note: m4 eats our [], so we need to use [ and ] instead. 16552 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 16553 if test "x$has_forbidden_chars" != x; then 16554 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16555 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16556 fi 16557 16558 16559 windows_path="$new_path" 16560 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16561 unix_path=`$CYGPATH -u "$windows_path"` 16562 new_path="$unix_path" 16563 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16564 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16565 new_path="$unix_path" 16566 fi 16567 16568 if test "x$path" != "x$new_path"; then 16569 CURDIR="$new_path" 16570 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CURDIR to \"$new_path\"" >&5 16571 $as_echo "$as_me: Rewriting CURDIR to \"$new_path\"" >&6;} 16572 fi 16573 16574 # Save the first 10 bytes of this path to the storage, so fixpath can work. 16575 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 16576 16577 else 16578 # We're on a unix platform. Hooray! :) 16579 path="$CURDIR" 16580 has_space=`$ECHO "$path" | $GREP " "` 16581 if test "x$has_space" != x; then 16582 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CURDIR, which resolves as \"$path\", is invalid." >&5 16583 $as_echo "$as_me: The path of CURDIR, which resolves as \"$path\", is invalid." >&6;} 16584 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 16585 fi 16586 16587 # Use eval to expand a potential ~ 16588 eval path="$path" 16589 if test ! -f "$path" && test ! -d "$path"; then 16590 as_fn_error $? "The path of CURDIR, which resolves as \"$path\", is not found." "$LINENO" 5 16591 fi 16592 16593 if test -d "$path"; then 16594 CURDIR="`cd "$path"; $THEPWDCMD -L`" 16595 else 16596 dir="`$DIRNAME "$path"`" 16597 base="`$BASENAME "$path"`" 16598 CURDIR="`cd "$dir"; $THEPWDCMD -L`/$base" 16599 fi 16600 fi 16601 fi 16602 16603 16604 # Only process if variable expands to non-empty 16605 16606 if test "x$TOPDIR" != x; then 16607 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16608 16609 # Input might be given as Windows format, start by converting to 16610 # unix format. 16611 path="$TOPDIR" 16612 new_path=`$CYGPATH -u "$path"` 16613 16614 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 16615 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 16616 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 16617 # "foo.exe" is OK but "foo" is an error. 16618 # 16619 # This test is therefore slightly more accurate than "test -f" to check for file precense. 16620 # It is also a way to make sure we got the proper file name for the real test later on. 16621 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 16622 if test "x$test_shortpath" = x; then 16623 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of TOPDIR, which resolves as \"$path\", is invalid." >&5 16624 $as_echo "$as_me: The path of TOPDIR, which resolves as \"$path\", is invalid." >&6;} 16625 as_fn_error $? "Cannot locate the the path of TOPDIR" "$LINENO" 5 16626 fi 16627 16628 # Call helper function which possibly converts this using DOS-style short mode. 16629 # If so, the updated path is stored in $new_path. 16630 16631 input_path="$new_path" 16632 # Check if we need to convert this using DOS-style short mode. If the path 16633 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16634 # take no chances and rewrite it. 16635 # Note: m4 eats our [], so we need to use [ and ] instead. 16636 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 16637 if test "x$has_forbidden_chars" != x; then 16638 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16639 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 16640 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 16641 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 16642 # Going to short mode and back again did indeed matter. Since short mode is 16643 # case insensitive, let's make it lowercase to improve readability. 16644 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16645 # Now convert it back to Unix-style (cygpath) 16646 input_path=`$CYGPATH -u "$shortmode_path"` 16647 new_path="$input_path" 16648 fi 16649 fi 16650 16651 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 16652 if test "x$test_cygdrive_prefix" = x; then 16653 # As a simple fix, exclude /usr/bin since it's not a real path. 16654 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 16655 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 16656 # a path prefixed by /cygdrive for fixpath to work. 16657 new_path="$CYGWIN_ROOT_PATH$input_path" 16658 fi 16659 fi 16660 16661 16662 if test "x$path" != "x$new_path"; then 16663 TOPDIR="$new_path" 16664 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting TOPDIR to \"$new_path\"" >&5 16665 $as_echo "$as_me: Rewriting TOPDIR to \"$new_path\"" >&6;} 16666 fi 16667 16668 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16669 16670 path="$TOPDIR" 16671 has_colon=`$ECHO $path | $GREP ^.:` 16672 new_path="$path" 16673 if test "x$has_colon" = x; then 16674 # Not in mixed or Windows style, start by that. 16675 new_path=`cmd //c echo $path` 16676 fi 16677 16678 16679 input_path="$new_path" 16680 # Check if we need to convert this using DOS-style short mode. If the path 16681 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16682 # take no chances and rewrite it. 16683 # Note: m4 eats our [], so we need to use [ and ] instead. 16684 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 16685 if test "x$has_forbidden_chars" != x; then 16686 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16687 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16688 fi 16689 16690 16691 windows_path="$new_path" 16692 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16693 unix_path=`$CYGPATH -u "$windows_path"` 16694 new_path="$unix_path" 16695 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16696 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16697 new_path="$unix_path" 16698 fi 16699 16700 if test "x$path" != "x$new_path"; then 16701 TOPDIR="$new_path" 16702 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting TOPDIR to \"$new_path\"" >&5 16703 $as_echo "$as_me: Rewriting TOPDIR to \"$new_path\"" >&6;} 16704 fi 16705 16706 # Save the first 10 bytes of this path to the storage, so fixpath can work. 16707 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 16708 16709 else 16710 # We're on a unix platform. Hooray! :) 16711 path="$TOPDIR" 16712 has_space=`$ECHO "$path" | $GREP " "` 16713 if test "x$has_space" != x; then 16714 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of TOPDIR, which resolves as \"$path\", is invalid." >&5 16715 $as_echo "$as_me: The path of TOPDIR, which resolves as \"$path\", is invalid." >&6;} 16716 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 16717 fi 16718 16719 # Use eval to expand a potential ~ 16720 eval path="$path" 16721 if test ! -f "$path" && test ! -d "$path"; then 16722 as_fn_error $? "The path of TOPDIR, which resolves as \"$path\", is not found." "$LINENO" 5 16723 fi 16724 16725 if test -d "$path"; then 16726 TOPDIR="`cd "$path"; $THEPWDCMD -L`" 16727 else 16728 dir="`$DIRNAME "$path"`" 16729 base="`$BASENAME "$path"`" 16730 TOPDIR="`cd "$dir"; $THEPWDCMD -L`/$base" 16731 fi 16732 fi 16733 fi 16734 16735 # SRC_ROOT is a traditional alias for TOPDIR. 16736 SRC_ROOT=$TOPDIR 16737 16738 # Calculate a canonical version of TOPDIR for string comparisons 16739 CANONICAL_TOPDIR=$TOPDIR 16740 16741 if test "x$OPENJDK_BUILD_OS" != xwindows; then 16742 # Follow a chain of symbolic links. Use readlink 16743 # where it exists, else fall back to horribly 16744 # complicated shell code. 16745 if test "x$READLINK_TESTED" != yes; then 16746 # On MacOSX there is a readlink tool with a different 16747 # purpose than the GNU readlink tool. Check the found readlink. 16748 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 16749 if test "x$ISGNU" = x; then 16750 # A readlink that we do not know how to use. 16751 # Are there other non-GNU readlinks out there? 16752 READLINK_TESTED=yes 16753 READLINK= 16754 fi 16755 fi 16756 16757 if test "x$READLINK" != x; then 16758 CANONICAL_TOPDIR=`$READLINK -f $CANONICAL_TOPDIR` 16759 else 16760 # Save the current directory for restoring afterwards 16761 STARTDIR=$PWD 16762 COUNTER=0 16763 sym_link_dir=`$DIRNAME $CANONICAL_TOPDIR` 16764 sym_link_file=`$BASENAME $CANONICAL_TOPDIR` 16765 cd $sym_link_dir 16766 # Use -P flag to resolve symlinks in directories. 16767 cd `$THEPWDCMD -P` 16768 sym_link_dir=`$THEPWDCMD -P` 16769 # Resolve file symlinks 16770 while test $COUNTER -lt 20; do 16771 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 16772 if test "x$ISLINK" == x; then 16773 # This is not a symbolic link! We are done! 16774 break 16775 fi 16776 # Again resolve directory symlinks since the target of the just found 16777 # link could be in a different directory 16778 cd `$DIRNAME $ISLINK` 16779 sym_link_dir=`$THEPWDCMD -P` 16780 sym_link_file=`$BASENAME $ISLINK` 16781 let COUNTER=COUNTER+1 16782 done 16783 cd $STARTDIR 16784 CANONICAL_TOPDIR=$sym_link_dir/$sym_link_file 16785 fi 16786 fi 16787 16788 16789 16790 # Locate the directory of this script. 16791 AUTOCONF_DIR=$TOPDIR/common/autoconf 16792 16793 # Setup username (for use in adhoc version strings etc) 16794 # Outer [ ] to quote m4. 16795 USERNAME=`$ECHO "$USER" | $TR -d -c '[a-z][A-Z][0-9]'` 16796 16797 16798 16799 # Check if it's a pure open build or if custom sources are to be used. 16800 16801 # Check whether --enable-openjdk-only was given. 16802 if test "${enable_openjdk_only+set}" = set; then : 16803 enableval=$enable_openjdk_only; 16804 else 16805 enable_openjdk_only="no" 16806 fi 16807 16808 16809 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if custom source is suppressed (openjdk-only)" >&5 16810 $as_echo_n "checking if custom source is suppressed (openjdk-only)... " >&6; } 16811 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_openjdk_only" >&5 16812 $as_echo "$enable_openjdk_only" >&6; } 16813 if test "x$enable_openjdk_only" = "xyes"; then 16814 SUPPRESS_CUSTOM_EXTENSIONS="true" 16815 elif test "x$enable_openjdk_only" = "xno"; then 16816 SUPPRESS_CUSTOM_EXTENSIONS="false" 16817 else 16818 as_fn_error $? "Invalid value for --enable-openjdk-only: $enable_openjdk_only" "$LINENO" 5 16819 fi 16820 16821 # custom-make-dir is deprecated. Please use your custom-hook.m4 to override 16822 # the IncludeCustomExtension macro. 16823 16824 16825 # Check whether --with-custom-make-dir was given. 16826 if test "${with_custom_make_dir+set}" = set; then : 16827 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 16828 $as_echo "$as_me: WARNING: Option --with-custom-make-dir is deprecated and will be ignored." >&2;} 16829 fi 16830 16831 16832 16833 16834 # These are needed to be able to create a configuration name (and thus the output directory) 16835 16836 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variant of the JDK to build" >&5 16837 $as_echo_n "checking which variant of the JDK to build... " >&6; } 16838 16839 # Check whether --with-jdk-variant was given. 16840 if test "${with_jdk_variant+set}" = set; then : 16841 withval=$with_jdk_variant; 16842 fi 16843 16844 16845 if test "x$with_jdk_variant" = xnormal || test "x$with_jdk_variant" = x; then 16846 JDK_VARIANT="normal" 16847 else 16848 as_fn_error $? "The available JDK variants are: normal" "$LINENO" 5 16849 fi 16850 16851 16852 16853 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JDK_VARIANT" >&5 16854 $as_echo "$JDK_VARIANT" >&6; } 16855 16856 16857 DEBUG_LEVEL="release" 16858 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which debug level to use" >&5 16859 $as_echo_n "checking which debug level to use... " >&6; } 16860 # Check whether --enable-debug was given. 16861 if test "${enable_debug+set}" = set; then : 16862 enableval=$enable_debug; 16863 ENABLE_DEBUG="${enableval}" 16864 DEBUG_LEVEL="fastdebug" 16865 16866 else 16867 ENABLE_DEBUG="no" 16868 fi 16869 16870 16871 16872 # Check whether --with-debug-level was given. 16873 if test "${with_debug_level+set}" = set; then : 16874 withval=$with_debug_level; 16875 DEBUG_LEVEL="${withval}" 16876 if test "x$ENABLE_DEBUG" = xyes; then 16877 as_fn_error $? "You cannot use both --enable-debug and --with-debug-level at the same time." "$LINENO" 5 16878 fi 16879 16880 fi 16881 16882 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEBUG_LEVEL" >&5 16883 $as_echo "$DEBUG_LEVEL" >&6; } 16884 16885 if test "x$DEBUG_LEVEL" != xrelease && \ 16886 test "x$DEBUG_LEVEL" != xoptimized && \ 16887 test "x$DEBUG_LEVEL" != xfastdebug && \ 16888 test "x$DEBUG_LEVEL" != xslowdebug; then 16889 as_fn_error $? "Allowed debug levels are: release, fastdebug, slowdebug and optimized" "$LINENO" 5 16890 fi 16891 16892 # Translate DEBUG_LEVEL to debug level used by Hotspot 16893 HOTSPOT_DEBUG_LEVEL="$DEBUG_LEVEL" 16894 if test "x$DEBUG_LEVEL" = xrelease; then 16895 HOTSPOT_DEBUG_LEVEL="product" 16896 elif test "x$DEBUG_LEVEL" = xslowdebug; then 16897 HOTSPOT_DEBUG_LEVEL="debug" 16898 fi 16899 16900 if test "x$DEBUG_LEVEL" = xoptimized; then 16901 # The debug level 'optimized' is a little special because it is currently only 16902 # applicable to the HotSpot build where it means to build a completely 16903 # optimized version of the VM without any debugging code (like for the 16904 # 'release' debug level which is called 'product' in the HotSpot build) but 16905 # with the exception that it can contain additional code which is otherwise 16906 # protected by '#ifndef PRODUCT' macros. These 'optimized' builds are used to 16907 # test new and/or experimental features which are not intended for customer 16908 # shipment. Because these new features need to be tested and benchmarked in 16909 # real world scenarios, we want to build the containing JDK at the 'release' 16910 # debug level. 16911 DEBUG_LEVEL="release" 16912 fi 16913 16914 16915 16916 16917 16918 16919 # Check whether --with-jvm-variants was given. 16920 if test "${with_jvm_variants+set}" = set; then : 16921 withval=$with_jvm_variants; 16922 fi 16923 16924 16925 16926 16927 # Check whether --with-cpu-port was given. 16928 if test "${with_cpu_port+set}" = set; then : 16929 withval=$with_cpu_port; 16930 fi 16931 16932 16933 if test "x$with_cpu_port" != x; then 16934 if test "x$OPENJDK_TARGET_CPU" != xaarch64; then 16935 as_fn_error $? "--with-cpu-port only available on aarch64" "$LINENO" 5 16936 fi 16937 if test "x$with_cpu_port" != xarm64 && \ 16938 test "x$with_cpu_port" != xaarch64; then 16939 as_fn_error $? "--with-cpu-port must specify arm64 or aarch64" "$LINENO" 5 16940 fi 16941 HOTSPOT_TARGET_CPU_PORT="$with_cpu_port" 16942 fi 16943 16944 16945 if test "x$with_jvm_variants" = x; then 16946 with_jvm_variants="server" 16947 fi 16948 JVM_VARIANTS_OPT="$with_jvm_variants" 16949 16950 # Has the user listed more than one variant? 16951 # Additional [] needed to keep m4 from mangling shell constructs. 16952 if [[ "$JVM_VARIANTS_OPT" =~ "," ]] ; then 16953 BUILDING_MULTIPLE_JVM_VARIANTS=true 16954 else 16955 BUILDING_MULTIPLE_JVM_VARIANTS=false 16956 fi 16957 # Replace the commas with AND for use in the build directory name. 16958 JVM_VARIANTS_WITH_AND=`$ECHO "$JVM_VARIANTS_OPT" | $SED -e 's/,/AND/g'` 16959 16960 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variants of the JVM to build" >&5 16961 $as_echo_n "checking which variants of the JVM to build... " >&6; } 16962 # JVM_VARIANTS is a space-separated list. 16963 # Also use minimal, not minimal1 (which is kept for backwards compatibility). 16964 JVM_VARIANTS=`$ECHO $JVM_VARIANTS_OPT | $SED -e 's/,/ /g' -e 's/minimal1/minimal/'` 16965 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JVM_VARIANTS" >&5 16966 $as_echo "$JVM_VARIANTS" >&6; } 16967 16968 # Check that the selected variants are valid 16969 16970 # grep filter function inspired by a comment to http://stackoverflow.com/a/1617326 16971 # Notice that the original variant failes on SLES 10 and 11 16972 NEEDLE=${VALID_JVM_VARIANTS// /$'\n'} 16973 STACK=${JVM_VARIANTS// /$'\n'} 16974 INVALID_VARIANTS=`$GREP -Fvx "${NEEDLE}" <<< "${STACK}"` 16975 if test "x$INVALID_VARIANTS" != x; then 16976 { $as_echo "$as_me:${as_lineno-$LINENO}: Unknown variant(s) specified: $INVALID_VARIANTS" >&5 16977 $as_echo "$as_me: Unknown variant(s) specified: $INVALID_VARIANTS" >&6;} 16978 as_fn_error $? "The available JVM variants are: $VALID_JVM_VARIANTS" "$LINENO" 5 16979 fi 16980 16981 # All "special" variants share the same output directory ("server") 16982 VALID_MULTIPLE_JVM_VARIANTS="server client minimal" 16983 NEEDLE=${VALID_MULTIPLE_JVM_VARIANTS// /$'\n'} 16984 STACK=${JVM_VARIANTS// /$'\n'} 16985 INVALID_MULTIPLE_VARIANTS=`$GREP -Fvx "${NEEDLE}" <<< "${STACK}"` 16986 if test "x$INVALID_MULTIPLE_VARIANTS" != x && test "x$BUILDING_MULTIPLE_JVM_VARIANTS" = xtrue; then 16987 as_fn_error $? "You cannot build multiple variants with anything else than $VALID_MULTIPLE_JVM_VARIANTS." "$LINENO" 5 16988 fi 16989 16990 # The "main" variant is the one used by other libs to link against during the 16991 # build. 16992 if test "x$BUILDING_MULTIPLE_JVM_VARIANTS" = "xtrue"; then 16993 MAIN_VARIANT_PRIO_ORDER="server client minimal" 16994 for variant in $MAIN_VARIANT_PRIO_ORDER; do 16995 if [[ " $JVM_VARIANTS " =~ " $variant " ]] ; then 16996 JVM_VARIANT_MAIN="$variant" 16997 break 16998 fi 16999 done 17000 else 17001 JVM_VARIANT_MAIN="$JVM_VARIANTS" 17002 fi 17003 17004 17005 17006 17007 17008 if [[ " $JVM_VARIANTS " =~ " zero " ]] || [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 17009 # zero behaves as a platform and rewrites these values. This is really weird. :( 17010 # We are guaranteed that we do not build any other variants when building zero. 17011 HOTSPOT_TARGET_CPU=zero 17012 HOTSPOT_TARGET_CPU_ARCH=zero 17013 fi 17014 17015 17016 # With basic setup done, call the custom early hook. 17017 17018 17019 # Check if we have devkits, extra paths or sysroot set. 17020 17021 17022 # Check whether --with-devkit was given. 17023 if test "${with_devkit+set}" = set; then : 17024 withval=$with_devkit; 17025 17026 # Only process if variable expands to non-empty 17027 17028 if test "x$with_devkit" != x; then 17029 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17030 17031 # Input might be given as Windows format, start by converting to 17032 # unix format. 17033 path="$with_devkit" 17034 new_path=`$CYGPATH -u "$path"` 17035 17036 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 17037 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 17038 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 17039 # "foo.exe" is OK but "foo" is an error. 17040 # 17041 # This test is therefore slightly more accurate than "test -f" to check for file precense. 17042 # It is also a way to make sure we got the proper file name for the real test later on. 17043 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 17044 if test "x$test_shortpath" = x; then 17045 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_devkit, which resolves as \"$path\", is invalid." >&5 17046 $as_echo "$as_me: The path of with_devkit, which resolves as \"$path\", is invalid." >&6;} 17047 as_fn_error $? "Cannot locate the the path of with_devkit" "$LINENO" 5 17048 fi 17049 17050 # Call helper function which possibly converts this using DOS-style short mode. 17051 # If so, the updated path is stored in $new_path. 17052 17053 input_path="$new_path" 17054 # Check if we need to convert this using DOS-style short mode. If the path 17055 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17056 # take no chances and rewrite it. 17057 # Note: m4 eats our [], so we need to use [ and ] instead. 17058 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 17059 if test "x$has_forbidden_chars" != x; then 17060 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17061 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 17062 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 17063 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 17064 # Going to short mode and back again did indeed matter. Since short mode is 17065 # case insensitive, let's make it lowercase to improve readability. 17066 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17067 # Now convert it back to Unix-style (cygpath) 17068 input_path=`$CYGPATH -u "$shortmode_path"` 17069 new_path="$input_path" 17070 fi 17071 fi 17072 17073 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 17074 if test "x$test_cygdrive_prefix" = x; then 17075 # As a simple fix, exclude /usr/bin since it's not a real path. 17076 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 17077 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 17078 # a path prefixed by /cygdrive for fixpath to work. 17079 new_path="$CYGWIN_ROOT_PATH$input_path" 17080 fi 17081 fi 17082 17083 17084 if test "x$path" != "x$new_path"; then 17085 with_devkit="$new_path" 17086 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_devkit to \"$new_path\"" >&5 17087 $as_echo "$as_me: Rewriting with_devkit to \"$new_path\"" >&6;} 17088 fi 17089 17090 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17091 17092 path="$with_devkit" 17093 has_colon=`$ECHO $path | $GREP ^.:` 17094 new_path="$path" 17095 if test "x$has_colon" = x; then 17096 # Not in mixed or Windows style, start by that. 17097 new_path=`cmd //c echo $path` 17098 fi 17099 17100 17101 input_path="$new_path" 17102 # Check if we need to convert this using DOS-style short mode. If the path 17103 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17104 # take no chances and rewrite it. 17105 # Note: m4 eats our [], so we need to use [ and ] instead. 17106 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 17107 if test "x$has_forbidden_chars" != x; then 17108 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17109 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17110 fi 17111 17112 17113 windows_path="$new_path" 17114 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17115 unix_path=`$CYGPATH -u "$windows_path"` 17116 new_path="$unix_path" 17117 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17118 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17119 new_path="$unix_path" 17120 fi 17121 17122 if test "x$path" != "x$new_path"; then 17123 with_devkit="$new_path" 17124 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_devkit to \"$new_path\"" >&5 17125 $as_echo "$as_me: Rewriting with_devkit to \"$new_path\"" >&6;} 17126 fi 17127 17128 # Save the first 10 bytes of this path to the storage, so fixpath can work. 17129 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 17130 17131 else 17132 # We're on a unix platform. Hooray! :) 17133 path="$with_devkit" 17134 has_space=`$ECHO "$path" | $GREP " "` 17135 if test "x$has_space" != x; then 17136 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_devkit, which resolves as \"$path\", is invalid." >&5 17137 $as_echo "$as_me: The path of with_devkit, which resolves as \"$path\", is invalid." >&6;} 17138 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 17139 fi 17140 17141 # Use eval to expand a potential ~ 17142 eval path="$path" 17143 if test ! -f "$path" && test ! -d "$path"; then 17144 as_fn_error $? "The path of with_devkit, which resolves as \"$path\", is not found." "$LINENO" 5 17145 fi 17146 17147 if test -d "$path"; then 17148 with_devkit="`cd "$path"; $THEPWDCMD -L`" 17149 else 17150 dir="`$DIRNAME "$path"`" 17151 base="`$BASENAME "$path"`" 17152 with_devkit="`cd "$dir"; $THEPWDCMD -L`/$base" 17153 fi 17154 fi 17155 fi 17156 17157 DEVKIT_ROOT="$with_devkit" 17158 # Check for a meta data info file in the root of the devkit 17159 if test -f "$DEVKIT_ROOT/devkit.info"; then 17160 . $DEVKIT_ROOT/devkit.info 17161 # This potentially sets the following: 17162 # A descriptive name of the devkit 17163 17164 if test "x$DEVKIT_NAME" = x; then 17165 eval DEVKIT_NAME="\${DEVKIT_NAME_${OPENJDK_TARGET_CPU}}" 17166 fi 17167 17168 # Corresponds to --with-extra-path 17169 17170 if test "x$DEVKIT_EXTRA_PATH" = x; then 17171 eval DEVKIT_EXTRA_PATH="\${DEVKIT_EXTRA_PATH_${OPENJDK_TARGET_CPU}}" 17172 fi 17173 17174 # Corresponds to --with-toolchain-path 17175 17176 if test "x$DEVKIT_TOOLCHAIN_PATH" = x; then 17177 eval DEVKIT_TOOLCHAIN_PATH="\${DEVKIT_TOOLCHAIN_PATH_${OPENJDK_TARGET_CPU}}" 17178 fi 17179 17180 # Corresponds to --with-sysroot 17181 17182 if test "x$DEVKIT_SYSROOT" = x; then 17183 eval DEVKIT_SYSROOT="\${DEVKIT_SYSROOT_${OPENJDK_TARGET_CPU}}" 17184 fi 17185 17186 17187 # Identifies the Visual Studio version in the devkit 17188 17189 if test "x$DEVKIT_VS_VERSION" = x; then 17190 eval DEVKIT_VS_VERSION="\${DEVKIT_VS_VERSION_${OPENJDK_TARGET_CPU}}" 17191 fi 17192 17193 # The Visual Studio include environment variable 17194 17195 if test "x$DEVKIT_VS_INCLUDE" = x; then 17196 eval DEVKIT_VS_INCLUDE="\${DEVKIT_VS_INCLUDE_${OPENJDK_TARGET_CPU}}" 17197 fi 17198 17199 # The Visual Studio lib environment variable 17200 17201 if test "x$DEVKIT_VS_LIB" = x; then 17202 eval DEVKIT_VS_LIB="\${DEVKIT_VS_LIB_${OPENJDK_TARGET_CPU}}" 17203 fi 17204 17205 # Corresponds to --with-msvcr-dll 17206 17207 if test "x$DEVKIT_MSVCR_DLL" = x; then 17208 eval DEVKIT_MSVCR_DLL="\${DEVKIT_MSVCR_DLL_${OPENJDK_TARGET_CPU}}" 17209 fi 17210 17211 # Corresponds to --with-msvcp-dll 17212 17213 if test "x$DEVKIT_MSVCP_DLL" = x; then 17214 eval DEVKIT_MSVCP_DLL="\${DEVKIT_MSVCP_DLL_${OPENJDK_TARGET_CPU}}" 17215 fi 17216 17217 fi 17218 17219 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for devkit" >&5 17220 $as_echo_n "checking for devkit... " >&6; } 17221 if test "x$DEVKIT_NAME" != x; then 17222 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEVKIT_NAME in $DEVKIT_ROOT" >&5 17223 $as_echo "$DEVKIT_NAME in $DEVKIT_ROOT" >&6; } 17224 else 17225 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEVKIT_ROOT" >&5 17226 $as_echo "$DEVKIT_ROOT" >&6; } 17227 fi 17228 17229 17230 if test "x$DEVKIT_EXTRA_PATH" != x; then 17231 if test "x$EXTRA_PATH" = x; then 17232 EXTRA_PATH="$DEVKIT_EXTRA_PATH" 17233 else 17234 EXTRA_PATH="$DEVKIT_EXTRA_PATH:$EXTRA_PATH" 17235 fi 17236 fi 17237 17238 17239 # Fallback default of just /bin if DEVKIT_PATH is not defined 17240 if test "x$DEVKIT_TOOLCHAIN_PATH" = x; then 17241 DEVKIT_TOOLCHAIN_PATH="$DEVKIT_ROOT/bin" 17242 fi 17243 17244 if test "x$DEVKIT_TOOLCHAIN_PATH" != x; then 17245 if test "x$TOOLCHAIN_PATH" = x; then 17246 TOOLCHAIN_PATH="$DEVKIT_TOOLCHAIN_PATH" 17247 else 17248 TOOLCHAIN_PATH="$DEVKIT_TOOLCHAIN_PATH:$TOOLCHAIN_PATH" 17249 fi 17250 fi 17251 17252 17253 # If DEVKIT_SYSROOT is set, use that, otherwise try a couple of known 17254 # places for backwards compatiblity. 17255 if test "x$DEVKIT_SYSROOT" != x; then 17256 SYSROOT="$DEVKIT_SYSROOT" 17257 elif test -d "$DEVKIT_ROOT/$host_alias/libc"; then 17258 SYSROOT="$DEVKIT_ROOT/$host_alias/libc" 17259 elif test -d "$DEVKIT_ROOT/$host/sys-root"; then 17260 SYSROOT="$DEVKIT_ROOT/$host/sys-root" 17261 fi 17262 17263 17264 fi 17265 17266 17267 # You can force the sysroot if the sysroot encoded into the compiler tools 17268 # is not correct. 17269 17270 # Check whether --with-sys-root was given. 17271 if test "${with_sys_root+set}" = set; then : 17272 withval=$with_sys_root; SYSROOT=$with_sys_root 17273 17274 fi 17275 17276 17277 17278 # Check whether --with-sysroot was given. 17279 if test "${with_sysroot+set}" = set; then : 17280 withval=$with_sysroot; SYSROOT=$with_sysroot 17281 17282 fi 17283 17284 17285 17286 # Check whether --with-tools-dir was given. 17287 if test "${with_tools_dir+set}" = set; then : 17288 withval=$with_tools_dir; 17289 if test "x$with_tools_dir" != x; then 17290 if test "x$TOOLCHAIN_PATH" = x; then 17291 TOOLCHAIN_PATH="$with_tools_dir" 17292 else 17293 TOOLCHAIN_PATH="$with_tools_dir:$TOOLCHAIN_PATH" 17294 fi 17295 fi 17296 17297 17298 fi 17299 17300 17301 17302 # Check whether --with-toolchain-path was given. 17303 if test "${with_toolchain_path+set}" = set; then : 17304 withval=$with_toolchain_path; 17305 if test "x$with_toolchain_path" != x; then 17306 if test "x$TOOLCHAIN_PATH" = x; then 17307 TOOLCHAIN_PATH="$with_toolchain_path" 17308 else 17309 TOOLCHAIN_PATH="$with_toolchain_path:$TOOLCHAIN_PATH" 17310 fi 17311 fi 17312 17313 17314 fi 17315 17316 17317 17318 # Check whether --with-extra-path was given. 17319 if test "${with_extra_path+set}" = set; then : 17320 withval=$with_extra_path; 17321 if test "x$with_extra_path" != x; then 17322 if test "x$EXTRA_PATH" = x; then 17323 EXTRA_PATH="$with_extra_path" 17324 else 17325 EXTRA_PATH="$with_extra_path:$EXTRA_PATH" 17326 fi 17327 fi 17328 17329 17330 fi 17331 17332 17333 if test "x$OPENJDK_BUILD_OS" = "xmacosx"; then 17334 # If a devkit has been supplied, find xcodebuild in the toolchain_path. 17335 # If not, detect if Xcode is installed by running xcodebuild -version 17336 # if no Xcode installed, xcodebuild exits with 1 17337 # if Xcode is installed, even if xcode-select is misconfigured, then it exits with 0 17338 if test "x$DEVKIT_ROOT" != x || /usr/bin/xcodebuild -version >/dev/null 2>&1; then 17339 # We need to use xcodebuild in the toolchain dir provided by the user, this will 17340 # fall back on the stub binary in /usr/bin/xcodebuild 17341 # Extract the first word of "xcodebuild", so it can be a program name with args. 17342 set dummy xcodebuild; ac_word=$2 17343 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 17344 $as_echo_n "checking for $ac_word... " >&6; } 17345 if ${ac_cv_path_XCODEBUILD+:} false; then : 17346 $as_echo_n "(cached) " >&6 17347 else 17348 case $XCODEBUILD in 17349 [\\/]* | ?:[\\/]*) 17350 ac_cv_path_XCODEBUILD="$XCODEBUILD" # Let the user override the test with a path. 17351 ;; 17352 *) 17353 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 17354 for as_dir in $TOOLCHAIN_PATH 17355 do 17356 IFS=$as_save_IFS 17357 test -z "$as_dir" && as_dir=. 17358 for ac_exec_ext in '' $ac_executable_extensions; do 17359 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 17360 ac_cv_path_XCODEBUILD="$as_dir/$ac_word$ac_exec_ext" 17361 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 17362 break 2 17363 fi 17364 done 17365 done 17366 IFS=$as_save_IFS 17367 17368 test -z "$ac_cv_path_XCODEBUILD" && ac_cv_path_XCODEBUILD="/usr/bin/xcodebuild" 17369 ;; 17370 esac 17371 fi 17372 XCODEBUILD=$ac_cv_path_XCODEBUILD 17373 if test -n "$XCODEBUILD"; then 17374 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XCODEBUILD" >&5 17375 $as_echo "$XCODEBUILD" >&6; } 17376 else 17377 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 17378 $as_echo "no" >&6; } 17379 fi 17380 17381 17382 else 17383 # this should result in SYSROOT being empty, unless --with-sysroot is provided 17384 # when only the command line tools are installed there are no SDKs, so headers 17385 # are copied into the system frameworks 17386 XCODEBUILD= 17387 17388 fi 17389 17390 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sdk name" >&5 17391 $as_echo_n "checking for sdk name... " >&6; } 17392 17393 # Check whether --with-sdk-name was given. 17394 if test "${with_sdk_name+set}" = set; then : 17395 withval=$with_sdk_name; SDKNAME=$with_sdk_name 17396 17397 fi 17398 17399 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SDKNAME" >&5 17400 $as_echo "$SDKNAME" >&6; } 17401 17402 # if toolchain path is specified then don't rely on system headers, they may not compile 17403 HAVE_SYSTEM_FRAMEWORK_HEADERS=0 17404 test -z "$TOOLCHAIN_PATH" && \ 17405 HAVE_SYSTEM_FRAMEWORK_HEADERS=`test ! -f /System/Library/Frameworks/Foundation.framework/Headers/Foundation.h; echo $?` 17406 17407 if test -z "$SYSROOT"; then 17408 if test -n "$XCODEBUILD"; then 17409 # if we don't have system headers, use default SDK name (last resort) 17410 if test -z "$SDKNAME" -a $HAVE_SYSTEM_FRAMEWORK_HEADERS -eq 0; then 17411 SDKNAME=${SDKNAME:-macosx} 17412 fi 17413 17414 if test -n "$SDKNAME"; then 17415 # Call xcodebuild to determine SYSROOT 17416 SYSROOT=`"$XCODEBUILD" -sdk $SDKNAME -version | $GREP '^Path: ' | $SED 's/Path: //'` 17417 fi 17418 else 17419 if test $HAVE_SYSTEM_FRAMEWORK_HEADERS -eq 0; then 17420 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 17421 fi 17422 fi 17423 else 17424 # warn user if --with-sdk-name was also set 17425 if test -n "$with_sdk_name"; then 17426 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Both SYSROOT and --with-sdk-name are set, only SYSROOT will be used" >&5 17427 $as_echo "$as_me: WARNING: Both SYSROOT and --with-sdk-name are set, only SYSROOT will be used" >&2;} 17428 fi 17429 fi 17430 17431 if test $HAVE_SYSTEM_FRAMEWORK_HEADERS -eq 0 -a -z "$SYSROOT"; then 17432 # If no system framework headers, then SYSROOT must be set, or we won't build 17433 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 17434 fi 17435 17436 # Perform a basic sanity test 17437 if test ! -f "$SYSROOT/System/Library/Frameworks/Foundation.framework/Headers/Foundation.h"; then 17438 if test -z "$SYSROOT"; then 17439 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 17440 else 17441 as_fn_error $? "Invalid SDK or SYSROOT path, dependent framework headers not found" "$LINENO" 5 17442 fi 17443 fi 17444 17445 # set SDKROOT too, Xcode tools will pick it up 17446 SDKROOT="$SYSROOT" 17447 17448 fi 17449 17450 # Prepend the extra path to the global path 17451 17452 if test "x$EXTRA_PATH" != x; then 17453 if test "x$PATH" = x; then 17454 PATH="$EXTRA_PATH" 17455 else 17456 PATH="$EXTRA_PATH:$PATH" 17457 fi 17458 fi 17459 17460 17461 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5 17462 $as_echo_n "checking for sysroot... " >&6; } 17463 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SYSROOT" >&5 17464 $as_echo "$SYSROOT" >&6; } 17465 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for toolchain path" >&5 17466 $as_echo_n "checking for toolchain path... " >&6; } 17467 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLCHAIN_PATH" >&5 17468 $as_echo "$TOOLCHAIN_PATH" >&6; } 17469 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for extra path" >&5 17470 $as_echo_n "checking for extra path... " >&6; } 17471 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXTRA_PATH" >&5 17472 $as_echo "$EXTRA_PATH" >&6; } 17473 17474 17475 # To properly create a configuration name, we need to have the OpenJDK target 17476 # and options (variants and debug level) parsed. 17477 17478 17479 17480 # Check whether --with-conf-name was given. 17481 if test "${with_conf_name+set}" = set; then : 17482 withval=$with_conf_name; CONF_NAME=${with_conf_name} 17483 fi 17484 17485 17486 # Test from where we are running configure, in or outside of src root. 17487 { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to store configuration" >&5 17488 $as_echo_n "checking where to store configuration... " >&6; } 17489 if test "x$CURDIR" = "x$SRC_ROOT" || test "x$CURDIR" = "x$SRC_ROOT/common" \ 17490 || test "x$CURDIR" = "x$SRC_ROOT/common/autoconf" \ 17491 || test "x$CURDIR" = "x$SRC_ROOT/make" ; then 17492 # We are running configure from the src root. 17493 # Create a default ./build/target-variant-debuglevel output root. 17494 if test "x${CONF_NAME}" = x; then 17495 { $as_echo "$as_me:${as_lineno-$LINENO}: result: in default location" >&5 17496 $as_echo "in default location" >&6; } 17497 CONF_NAME="${OPENJDK_TARGET_OS}-${OPENJDK_TARGET_CPU}-${JDK_VARIANT}-${JVM_VARIANTS_WITH_AND}-${DEBUG_LEVEL}" 17498 else 17499 { $as_echo "$as_me:${as_lineno-$LINENO}: result: in build directory with custom name" >&5 17500 $as_echo "in build directory with custom name" >&6; } 17501 fi 17502 OUTPUT_ROOT="$SRC_ROOT/build/${CONF_NAME}" 17503 $MKDIR -p "$OUTPUT_ROOT" 17504 if test ! -d "$OUTPUT_ROOT"; then 17505 as_fn_error $? "Could not create build directory $OUTPUT_ROOT" "$LINENO" 5 17506 fi 17507 else 17508 # We are running configure from outside of the src dir. 17509 # Then use the current directory as output dir! 17510 # If configuration is situated in normal build directory, just use the build 17511 # directory name as configuration name, otherwise use the complete path. 17512 if test "x${CONF_NAME}" = x; then 17513 CONF_NAME=`$ECHO $CURDIR | $SED -e "s!^${SRC_ROOT}/build/!!"` 17514 fi 17515 OUTPUT_ROOT="$CURDIR" 17516 { $as_echo "$as_me:${as_lineno-$LINENO}: result: in current directory" >&5 17517 $as_echo "in current directory" >&6; } 17518 17519 # WARNING: This might be a bad thing to do. You need to be sure you want to 17520 # have a configuration in this directory. Do some sanity checks! 17521 17522 if test ! -e "$OUTPUT_ROOT/spec.gmk"; then 17523 # If we have a spec.gmk, we have run here before and we are OK. Otherwise, check for 17524 # other files 17525 files_present=`$LS $OUTPUT_ROOT` 17526 # Configure has already touched config.log and confdefs.h in the current dir when this check 17527 # is performed. 17528 filtered_files=`$ECHO "$files_present" \ 17529 | $SED -e 's/config.log//g' \ 17530 -e 's/configure.log//g' \ 17531 -e 's/confdefs.h//g' \ 17532 -e 's/ //g' \ 17533 | $TR -d '\n'` 17534 if test "x$filtered_files" != x; then 17535 { $as_echo "$as_me:${as_lineno-$LINENO}: Current directory is $CURDIR." >&5 17536 $as_echo "$as_me: Current directory is $CURDIR." >&6;} 17537 { $as_echo "$as_me:${as_lineno-$LINENO}: Since this is not the source root, configure will output the configuration here" >&5 17538 $as_echo "$as_me: Since this is not the source root, configure will output the configuration here" >&6;} 17539 { $as_echo "$as_me:${as_lineno-$LINENO}: (as opposed to creating a configuration in <src_root>/build/<conf-name>)." >&5 17540 $as_echo "$as_me: (as opposed to creating a configuration in <src_root>/build/<conf-name>)." >&6;} 17541 { $as_echo "$as_me:${as_lineno-$LINENO}: However, this directory is not empty. This is not allowed, since it could" >&5 17542 $as_echo "$as_me: However, this directory is not empty. This is not allowed, since it could" >&6;} 17543 { $as_echo "$as_me:${as_lineno-$LINENO}: seriously mess up just about everything." >&5 17544 $as_echo "$as_me: seriously mess up just about everything." >&6;} 17545 { $as_echo "$as_me:${as_lineno-$LINENO}: Try 'cd $SRC_ROOT' and restart configure" >&5 17546 $as_echo "$as_me: Try 'cd $SRC_ROOT' and restart configure" >&6;} 17547 { $as_echo "$as_me:${as_lineno-$LINENO}: (or create a new empty directory and cd to it)." >&5 17548 $as_echo "$as_me: (or create a new empty directory and cd to it)." >&6;} 17549 as_fn_error $? "Will not continue creating configuration in $CURDIR" "$LINENO" 5 17550 fi 17551 fi 17552 fi 17553 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what configuration name to use" >&5 17554 $as_echo_n "checking what configuration name to use... " >&6; } 17555 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CONF_NAME" >&5 17556 $as_echo "$CONF_NAME" >&6; } 17557 17558 17559 # Only process if variable expands to non-empty 17560 17561 if test "x$OUTPUT_ROOT" != x; then 17562 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17563 17564 # Input might be given as Windows format, start by converting to 17565 # unix format. 17566 path="$OUTPUT_ROOT" 17567 new_path=`$CYGPATH -u "$path"` 17568 17569 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 17570 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 17571 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 17572 # "foo.exe" is OK but "foo" is an error. 17573 # 17574 # This test is therefore slightly more accurate than "test -f" to check for file precense. 17575 # It is also a way to make sure we got the proper file name for the real test later on. 17576 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 17577 if test "x$test_shortpath" = x; then 17578 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&5 17579 $as_echo "$as_me: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&6;} 17580 as_fn_error $? "Cannot locate the the path of OUTPUT_ROOT" "$LINENO" 5 17581 fi 17582 17583 # Call helper function which possibly converts this using DOS-style short mode. 17584 # If so, the updated path is stored in $new_path. 17585 17586 input_path="$new_path" 17587 # Check if we need to convert this using DOS-style short mode. If the path 17588 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17589 # take no chances and rewrite it. 17590 # Note: m4 eats our [], so we need to use [ and ] instead. 17591 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 17592 if test "x$has_forbidden_chars" != x; then 17593 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17594 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 17595 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 17596 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 17597 # Going to short mode and back again did indeed matter. Since short mode is 17598 # case insensitive, let's make it lowercase to improve readability. 17599 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17600 # Now convert it back to Unix-style (cygpath) 17601 input_path=`$CYGPATH -u "$shortmode_path"` 17602 new_path="$input_path" 17603 fi 17604 fi 17605 17606 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 17607 if test "x$test_cygdrive_prefix" = x; then 17608 # As a simple fix, exclude /usr/bin since it's not a real path. 17609 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 17610 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 17611 # a path prefixed by /cygdrive for fixpath to work. 17612 new_path="$CYGWIN_ROOT_PATH$input_path" 17613 fi 17614 fi 17615 17616 17617 if test "x$path" != "x$new_path"; then 17618 OUTPUT_ROOT="$new_path" 17619 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OUTPUT_ROOT to \"$new_path\"" >&5 17620 $as_echo "$as_me: Rewriting OUTPUT_ROOT to \"$new_path\"" >&6;} 17621 fi 17622 17623 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17624 17625 path="$OUTPUT_ROOT" 17626 has_colon=`$ECHO $path | $GREP ^.:` 17627 new_path="$path" 17628 if test "x$has_colon" = x; then 17629 # Not in mixed or Windows style, start by that. 17630 new_path=`cmd //c echo $path` 17631 fi 17632 17633 17634 input_path="$new_path" 17635 # Check if we need to convert this using DOS-style short mode. If the path 17636 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17637 # take no chances and rewrite it. 17638 # Note: m4 eats our [], so we need to use [ and ] instead. 17639 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 17640 if test "x$has_forbidden_chars" != x; then 17641 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17642 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17643 fi 17644 17645 17646 windows_path="$new_path" 17647 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17648 unix_path=`$CYGPATH -u "$windows_path"` 17649 new_path="$unix_path" 17650 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17651 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17652 new_path="$unix_path" 17653 fi 17654 17655 if test "x$path" != "x$new_path"; then 17656 OUTPUT_ROOT="$new_path" 17657 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OUTPUT_ROOT to \"$new_path\"" >&5 17658 $as_echo "$as_me: Rewriting OUTPUT_ROOT to \"$new_path\"" >&6;} 17659 fi 17660 17661 # Save the first 10 bytes of this path to the storage, so fixpath can work. 17662 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 17663 17664 else 17665 # We're on a unix platform. Hooray! :) 17666 path="$OUTPUT_ROOT" 17667 has_space=`$ECHO "$path" | $GREP " "` 17668 if test "x$has_space" != x; then 17669 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&5 17670 $as_echo "$as_me: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&6;} 17671 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 17672 fi 17673 17674 # Use eval to expand a potential ~ 17675 eval path="$path" 17676 if test ! -f "$path" && test ! -d "$path"; then 17677 as_fn_error $? "The path of OUTPUT_ROOT, which resolves as \"$path\", is not found." "$LINENO" 5 17678 fi 17679 17680 if test -d "$path"; then 17681 OUTPUT_ROOT="`cd "$path"; $THEPWDCMD -L`" 17682 else 17683 dir="`$DIRNAME "$path"`" 17684 base="`$BASENAME "$path"`" 17685 OUTPUT_ROOT="`cd "$dir"; $THEPWDCMD -L`/$base" 17686 fi 17687 fi 17688 fi 17689 17690 17691 CONFIGURESUPPORT_OUTPUTDIR="$OUTPUT_ROOT/configure-support" 17692 $MKDIR -p "$CONFIGURESUPPORT_OUTPUTDIR" 17693 17694 SPEC="$OUTPUT_ROOT/spec.gmk" 17695 17696 17697 17698 17699 17700 # The spec.gmk file contains all variables for the make system. 17701 ac_config_files="$ac_config_files $OUTPUT_ROOT/spec.gmk:$AUTOCONF_DIR/spec.gmk.in" 17702 17703 # The bootcycle-spec.gmk file contains support for boot cycle builds. 17704 ac_config_files="$ac_config_files $OUTPUT_ROOT/bootcycle-spec.gmk:$AUTOCONF_DIR/bootcycle-spec.gmk.in" 17705 17706 # The buildjdk-spec.gmk file contains support for building a buildjdk when cross compiling. 17707 ac_config_files="$ac_config_files $OUTPUT_ROOT/buildjdk-spec.gmk:$AUTOCONF_DIR/buildjdk-spec.gmk.in" 17708 17709 # The compare.sh is used to compare the build output to other builds. 17710 ac_config_files="$ac_config_files $OUTPUT_ROOT/compare.sh:$AUTOCONF_DIR/compare.sh.in" 17711 17712 # The generated Makefile knows where the spec.gmk is and where the source is. 17713 # You can run make from the OUTPUT_ROOT, or from the top-level Makefile 17714 # which will look for generated configurations 17715 ac_config_files="$ac_config_files $OUTPUT_ROOT/Makefile:$AUTOCONF_DIR/Makefile.in" 17716 17717 17718 17719 # Must be done before we can call HELP_MSG_MISSING_DEPENDENCY. 17720 17721 for ac_prog in apt-get yum brew port pkgutil pkgadd 17722 do 17723 # Extract the first word of "$ac_prog", so it can be a program name with args. 17724 set dummy $ac_prog; ac_word=$2 17725 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 17726 $as_echo_n "checking for $ac_word... " >&6; } 17727 if ${ac_cv_prog_PKGHANDLER+:} false; then : 17728 $as_echo_n "(cached) " >&6 17729 else 17730 if test -n "$PKGHANDLER"; then 17731 ac_cv_prog_PKGHANDLER="$PKGHANDLER" # Let the user override the test. 17732 else 17733 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 17734 for as_dir in $PATH 17735 do 17736 IFS=$as_save_IFS 17737 test -z "$as_dir" && as_dir=. 17738 for ac_exec_ext in '' $ac_executable_extensions; do 17739 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 17740 ac_cv_prog_PKGHANDLER="$ac_prog" 17741 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 17742 break 2 17743 fi 17744 done 17745 done 17746 IFS=$as_save_IFS 17747 17748 fi 17749 fi 17750 PKGHANDLER=$ac_cv_prog_PKGHANDLER 17751 if test -n "$PKGHANDLER"; then 17752 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGHANDLER" >&5 17753 $as_echo "$PKGHANDLER" >&6; } 17754 else 17755 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 17756 $as_echo "no" >&6; } 17757 fi 17758 17759 17760 test -n "$PKGHANDLER" && break 17761 done 17762 17763 17764 17765 # Setup tools that requires more complex handling, or that is not needed by the configure script. 17766 17767 17768 17769 # Publish this variable in the help. 17770 17771 17772 if [ -z "${MAKE+x}" ]; then 17773 # The variable is not set by user, try to locate tool using the code snippet 17774 17775 # Try our hardest to locate a correct version of GNU make 17776 for ac_prog in gmake 17777 do 17778 # Extract the first word of "$ac_prog", so it can be a program name with args. 17779 set dummy $ac_prog; ac_word=$2 17780 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 17781 $as_echo_n "checking for $ac_word... " >&6; } 17782 if ${ac_cv_path_CHECK_GMAKE+:} false; then : 17783 $as_echo_n "(cached) " >&6 17784 else 17785 case $CHECK_GMAKE in 17786 [\\/]* | ?:[\\/]*) 17787 ac_cv_path_CHECK_GMAKE="$CHECK_GMAKE" # Let the user override the test with a path. 17788 ;; 17789 *) 17790 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 17791 for as_dir in $PATH 17792 do 17793 IFS=$as_save_IFS 17794 test -z "$as_dir" && as_dir=. 17795 for ac_exec_ext in '' $ac_executable_extensions; do 17796 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 17797 ac_cv_path_CHECK_GMAKE="$as_dir/$ac_word$ac_exec_ext" 17798 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 17799 break 2 17800 fi 17801 done 17802 done 17803 IFS=$as_save_IFS 17804 17805 ;; 17806 esac 17807 fi 17808 CHECK_GMAKE=$ac_cv_path_CHECK_GMAKE 17809 if test -n "$CHECK_GMAKE"; then 17810 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_GMAKE" >&5 17811 $as_echo "$CHECK_GMAKE" >&6; } 17812 else 17813 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 17814 $as_echo "no" >&6; } 17815 fi 17816 17817 17818 test -n "$CHECK_GMAKE" && break 17819 done 17820 17821 17822 MAKE_CANDIDATE=""$CHECK_GMAKE"" 17823 DESCRIPTION="gmake in PATH" 17824 17825 # On Cygwin, we require a newer version of make than on other platforms 17826 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17827 MAKE_VERSION_EXPR="-e 4\." 17828 MAKE_REQUIRED_VERSION="4.0" 17829 else 17830 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 17831 MAKE_REQUIRED_VERSION="3.81" 17832 fi 17833 17834 if test "x$MAKE_CANDIDATE" != x; then 17835 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 17836 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 17837 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 17838 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 17839 if test "x$IS_GNU_MAKE" = x; then 17840 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 17841 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 17842 else 17843 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 17844 if test "x$IS_MODERN_MAKE" = x; then 17845 { $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 17846 $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;} 17847 else 17848 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 17849 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17850 MAKE_EXPECTED_ENV='cygwin' 17851 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17852 MAKE_EXPECTED_ENV='msys' 17853 else 17854 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 17855 fi 17856 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 17857 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 17858 else 17859 # Not relevant for non-Windows 17860 IS_MAKE_CORRECT_ENV=true 17861 fi 17862 if test "x$IS_MAKE_CORRECT_ENV" = x; then 17863 { $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 17864 $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;} 17865 else 17866 FOUND_MAKE=$MAKE_CANDIDATE 17867 17868 # Only process if variable expands to non-empty 17869 17870 if test "x$FOUND_MAKE" != x; then 17871 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17872 17873 # First separate the path from the arguments. This will split at the first 17874 # space. 17875 complete="$FOUND_MAKE" 17876 path="${complete%% *}" 17877 tmp="$complete EOL" 17878 arguments="${tmp#* }" 17879 17880 # Input might be given as Windows format, start by converting to 17881 # unix format. 17882 new_path=`$CYGPATH -u "$path"` 17883 17884 # Now try to locate executable using which 17885 new_path=`$WHICH "$new_path" 2> /dev/null` 17886 # bat and cmd files are not always considered executable in cygwin causing which 17887 # to not find them 17888 if test "x$new_path" = x \ 17889 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 17890 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 17891 new_path=`$CYGPATH -u "$path"` 17892 fi 17893 if test "x$new_path" = x; then 17894 # Oops. Which didn't find the executable. 17895 # The splitting of arguments from the executable at a space might have been incorrect, 17896 # since paths with space are more likely in Windows. Give it another try with the whole 17897 # argument. 17898 path="$complete" 17899 arguments="EOL" 17900 new_path=`$CYGPATH -u "$path"` 17901 new_path=`$WHICH "$new_path" 2> /dev/null` 17902 # bat and cmd files are not always considered executable in cygwin causing which 17903 # to not find them 17904 if test "x$new_path" = x \ 17905 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 17906 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 17907 new_path=`$CYGPATH -u "$path"` 17908 fi 17909 if test "x$new_path" = x; then 17910 # It's still not found. Now this is an unrecoverable error. 17911 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 17912 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 17913 has_space=`$ECHO "$complete" | $GREP " "` 17914 if test "x$has_space" != x; then 17915 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 17916 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 17917 fi 17918 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 17919 fi 17920 fi 17921 17922 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 17923 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 17924 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 17925 # "foo.exe" is OK but "foo" is an error. 17926 # 17927 # This test is therefore slightly more accurate than "test -f" to check for file presence. 17928 # It is also a way to make sure we got the proper file name for the real test later on. 17929 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 17930 if test "x$test_shortpath" = x; then 17931 # Short path failed, file does not exist as specified. 17932 # Try adding .exe or .cmd 17933 if test -f "${new_path}.exe"; then 17934 input_to_shortpath="${new_path}.exe" 17935 elif test -f "${new_path}.cmd"; then 17936 input_to_shortpath="${new_path}.cmd" 17937 else 17938 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 17939 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 17940 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 17941 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 17942 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 17943 fi 17944 else 17945 input_to_shortpath="$new_path" 17946 fi 17947 17948 # Call helper function which possibly converts this using DOS-style short mode. 17949 # If so, the updated path is stored in $new_path. 17950 new_path="$input_to_shortpath" 17951 17952 input_path="$input_to_shortpath" 17953 # Check if we need to convert this using DOS-style short mode. If the path 17954 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17955 # take no chances and rewrite it. 17956 # Note: m4 eats our [], so we need to use [ and ] instead. 17957 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 17958 if test "x$has_forbidden_chars" != x; then 17959 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17960 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 17961 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 17962 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 17963 # Going to short mode and back again did indeed matter. Since short mode is 17964 # case insensitive, let's make it lowercase to improve readability. 17965 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17966 # Now convert it back to Unix-style (cygpath) 17967 input_path=`$CYGPATH -u "$shortmode_path"` 17968 new_path="$input_path" 17969 fi 17970 fi 17971 17972 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 17973 if test "x$test_cygdrive_prefix" = x; then 17974 # As a simple fix, exclude /usr/bin since it's not a real path. 17975 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 17976 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 17977 # a path prefixed by /cygdrive for fixpath to work. 17978 new_path="$CYGWIN_ROOT_PATH$input_path" 17979 fi 17980 fi 17981 17982 # remove trailing .exe if any 17983 new_path="${new_path/%.exe/}" 17984 17985 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17986 17987 # First separate the path from the arguments. This will split at the first 17988 # space. 17989 complete="$FOUND_MAKE" 17990 path="${complete%% *}" 17991 tmp="$complete EOL" 17992 arguments="${tmp#* }" 17993 17994 # Input might be given as Windows format, start by converting to 17995 # unix format. 17996 new_path="$path" 17997 17998 windows_path="$new_path" 17999 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18000 unix_path=`$CYGPATH -u "$windows_path"` 18001 new_path="$unix_path" 18002 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18003 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18004 new_path="$unix_path" 18005 fi 18006 18007 18008 # Now try to locate executable using which 18009 new_path=`$WHICH "$new_path" 2> /dev/null` 18010 18011 if test "x$new_path" = x; then 18012 # Oops. Which didn't find the executable. 18013 # The splitting of arguments from the executable at a space might have been incorrect, 18014 # since paths with space are more likely in Windows. Give it another try with the whole 18015 # argument. 18016 path="$complete" 18017 arguments="EOL" 18018 new_path="$path" 18019 18020 windows_path="$new_path" 18021 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18022 unix_path=`$CYGPATH -u "$windows_path"` 18023 new_path="$unix_path" 18024 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18025 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18026 new_path="$unix_path" 18027 fi 18028 18029 18030 new_path=`$WHICH "$new_path" 2> /dev/null` 18031 # bat and cmd files are not always considered executable in MSYS causing which 18032 # to not find them 18033 if test "x$new_path" = x \ 18034 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18035 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18036 new_path="$path" 18037 18038 windows_path="$new_path" 18039 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18040 unix_path=`$CYGPATH -u "$windows_path"` 18041 new_path="$unix_path" 18042 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18043 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18044 new_path="$unix_path" 18045 fi 18046 18047 fi 18048 18049 if test "x$new_path" = x; then 18050 # It's still not found. Now this is an unrecoverable error. 18051 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18052 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18053 has_space=`$ECHO "$complete" | $GREP " "` 18054 if test "x$has_space" != x; then 18055 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18056 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18057 fi 18058 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18059 fi 18060 fi 18061 18062 # Now new_path has a complete unix path to the binary 18063 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 18064 # Keep paths in /bin as-is, but remove trailing .exe if any 18065 new_path="${new_path/%.exe/}" 18066 # Do not save /bin paths to all_fixpath_prefixes! 18067 else 18068 # Not in mixed or Windows style, start by that. 18069 new_path=`cmd //c echo $new_path` 18070 18071 input_path="$new_path" 18072 # Check if we need to convert this using DOS-style short mode. If the path 18073 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18074 # take no chances and rewrite it. 18075 # Note: m4 eats our [], so we need to use [ and ] instead. 18076 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 18077 if test "x$has_forbidden_chars" != x; then 18078 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18079 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18080 fi 18081 18082 # Output is in $new_path 18083 18084 windows_path="$new_path" 18085 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18086 unix_path=`$CYGPATH -u "$windows_path"` 18087 new_path="$unix_path" 18088 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18089 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18090 new_path="$unix_path" 18091 fi 18092 18093 # remove trailing .exe if any 18094 new_path="${new_path/%.exe/}" 18095 18096 # Save the first 10 bytes of this path to the storage, so fixpath can work. 18097 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 18098 fi 18099 18100 else 18101 # We're on a unix platform. Hooray! :) 18102 # First separate the path from the arguments. This will split at the first 18103 # space. 18104 complete="$FOUND_MAKE" 18105 path="${complete%% *}" 18106 tmp="$complete EOL" 18107 arguments="${tmp#* }" 18108 18109 # Cannot rely on the command "which" here since it doesn't always work. 18110 is_absolute_path=`$ECHO "$path" | $GREP ^/` 18111 if test -z "$is_absolute_path"; then 18112 # Path to executable is not absolute. Find it. 18113 IFS_save="$IFS" 18114 IFS=: 18115 for p in $PATH; do 18116 if test -f "$p/$path" && test -x "$p/$path"; then 18117 new_path="$p/$path" 18118 break 18119 fi 18120 done 18121 IFS="$IFS_save" 18122 else 18123 # This is an absolute path, we can use it without further modifications. 18124 new_path="$path" 18125 fi 18126 18127 if test "x$new_path" = x; then 18128 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18129 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18130 has_space=`$ECHO "$complete" | $GREP " "` 18131 if test "x$has_space" != x; then 18132 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 18133 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 18134 fi 18135 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18136 fi 18137 fi 18138 18139 # Now join together the path and the arguments once again 18140 if test "x$arguments" != xEOL; then 18141 new_complete="$new_path ${arguments% *}" 18142 else 18143 new_complete="$new_path" 18144 fi 18145 18146 if test "x$complete" != "x$new_complete"; then 18147 FOUND_MAKE="$new_complete" 18148 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 18149 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 18150 fi 18151 fi 18152 18153 fi 18154 fi 18155 fi 18156 fi 18157 18158 18159 if test "x$FOUND_MAKE" = x; then 18160 for ac_prog in make 18161 do 18162 # Extract the first word of "$ac_prog", so it can be a program name with args. 18163 set dummy $ac_prog; ac_word=$2 18164 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 18165 $as_echo_n "checking for $ac_word... " >&6; } 18166 if ${ac_cv_path_CHECK_MAKE+:} false; then : 18167 $as_echo_n "(cached) " >&6 18168 else 18169 case $CHECK_MAKE in 18170 [\\/]* | ?:[\\/]*) 18171 ac_cv_path_CHECK_MAKE="$CHECK_MAKE" # Let the user override the test with a path. 18172 ;; 18173 *) 18174 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 18175 for as_dir in $PATH 18176 do 18177 IFS=$as_save_IFS 18178 test -z "$as_dir" && as_dir=. 18179 for ac_exec_ext in '' $ac_executable_extensions; do 18180 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 18181 ac_cv_path_CHECK_MAKE="$as_dir/$ac_word$ac_exec_ext" 18182 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 18183 break 2 18184 fi 18185 done 18186 done 18187 IFS=$as_save_IFS 18188 18189 ;; 18190 esac 18191 fi 18192 CHECK_MAKE=$ac_cv_path_CHECK_MAKE 18193 if test -n "$CHECK_MAKE"; then 18194 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_MAKE" >&5 18195 $as_echo "$CHECK_MAKE" >&6; } 18196 else 18197 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 18198 $as_echo "no" >&6; } 18199 fi 18200 18201 18202 test -n "$CHECK_MAKE" && break 18203 done 18204 18205 18206 MAKE_CANDIDATE=""$CHECK_MAKE"" 18207 DESCRIPTION="make in PATH" 18208 18209 # On Cygwin, we require a newer version of make than on other platforms 18210 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18211 MAKE_VERSION_EXPR="-e 4\." 18212 MAKE_REQUIRED_VERSION="4.0" 18213 else 18214 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 18215 MAKE_REQUIRED_VERSION="3.81" 18216 fi 18217 18218 if test "x$MAKE_CANDIDATE" != x; then 18219 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 18220 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 18221 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 18222 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 18223 if test "x$IS_GNU_MAKE" = x; then 18224 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 18225 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 18226 else 18227 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 18228 if test "x$IS_MODERN_MAKE" = x; then 18229 { $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 18230 $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;} 18231 else 18232 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 18233 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18234 MAKE_EXPECTED_ENV='cygwin' 18235 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18236 MAKE_EXPECTED_ENV='msys' 18237 else 18238 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 18239 fi 18240 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 18241 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 18242 else 18243 # Not relevant for non-Windows 18244 IS_MAKE_CORRECT_ENV=true 18245 fi 18246 if test "x$IS_MAKE_CORRECT_ENV" = x; then 18247 { $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 18248 $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;} 18249 else 18250 FOUND_MAKE=$MAKE_CANDIDATE 18251 18252 # Only process if variable expands to non-empty 18253 18254 if test "x$FOUND_MAKE" != x; then 18255 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18256 18257 # First separate the path from the arguments. This will split at the first 18258 # space. 18259 complete="$FOUND_MAKE" 18260 path="${complete%% *}" 18261 tmp="$complete EOL" 18262 arguments="${tmp#* }" 18263 18264 # Input might be given as Windows format, start by converting to 18265 # unix format. 18266 new_path=`$CYGPATH -u "$path"` 18267 18268 # Now try to locate executable using which 18269 new_path=`$WHICH "$new_path" 2> /dev/null` 18270 # bat and cmd files are not always considered executable in cygwin causing which 18271 # to not find them 18272 if test "x$new_path" = x \ 18273 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18274 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18275 new_path=`$CYGPATH -u "$path"` 18276 fi 18277 if test "x$new_path" = x; then 18278 # Oops. Which didn't find the executable. 18279 # The splitting of arguments from the executable at a space might have been incorrect, 18280 # since paths with space are more likely in Windows. Give it another try with the whole 18281 # argument. 18282 path="$complete" 18283 arguments="EOL" 18284 new_path=`$CYGPATH -u "$path"` 18285 new_path=`$WHICH "$new_path" 2> /dev/null` 18286 # bat and cmd files are not always considered executable in cygwin causing which 18287 # to not find them 18288 if test "x$new_path" = x \ 18289 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18290 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18291 new_path=`$CYGPATH -u "$path"` 18292 fi 18293 if test "x$new_path" = x; then 18294 # It's still not found. Now this is an unrecoverable error. 18295 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18296 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18297 has_space=`$ECHO "$complete" | $GREP " "` 18298 if test "x$has_space" != x; then 18299 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18300 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18301 fi 18302 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18303 fi 18304 fi 18305 18306 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 18307 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 18308 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 18309 # "foo.exe" is OK but "foo" is an error. 18310 # 18311 # This test is therefore slightly more accurate than "test -f" to check for file presence. 18312 # It is also a way to make sure we got the proper file name for the real test later on. 18313 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 18314 if test "x$test_shortpath" = x; then 18315 # Short path failed, file does not exist as specified. 18316 # Try adding .exe or .cmd 18317 if test -f "${new_path}.exe"; then 18318 input_to_shortpath="${new_path}.exe" 18319 elif test -f "${new_path}.cmd"; then 18320 input_to_shortpath="${new_path}.cmd" 18321 else 18322 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 18323 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 18324 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 18325 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 18326 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18327 fi 18328 else 18329 input_to_shortpath="$new_path" 18330 fi 18331 18332 # Call helper function which possibly converts this using DOS-style short mode. 18333 # If so, the updated path is stored in $new_path. 18334 new_path="$input_to_shortpath" 18335 18336 input_path="$input_to_shortpath" 18337 # Check if we need to convert this using DOS-style short mode. If the path 18338 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18339 # take no chances and rewrite it. 18340 # Note: m4 eats our [], so we need to use [ and ] instead. 18341 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 18342 if test "x$has_forbidden_chars" != x; then 18343 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18344 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 18345 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 18346 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 18347 # Going to short mode and back again did indeed matter. Since short mode is 18348 # case insensitive, let's make it lowercase to improve readability. 18349 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18350 # Now convert it back to Unix-style (cygpath) 18351 input_path=`$CYGPATH -u "$shortmode_path"` 18352 new_path="$input_path" 18353 fi 18354 fi 18355 18356 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 18357 if test "x$test_cygdrive_prefix" = x; then 18358 # As a simple fix, exclude /usr/bin since it's not a real path. 18359 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 18360 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 18361 # a path prefixed by /cygdrive for fixpath to work. 18362 new_path="$CYGWIN_ROOT_PATH$input_path" 18363 fi 18364 fi 18365 18366 # remove trailing .exe if any 18367 new_path="${new_path/%.exe/}" 18368 18369 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18370 18371 # First separate the path from the arguments. This will split at the first 18372 # space. 18373 complete="$FOUND_MAKE" 18374 path="${complete%% *}" 18375 tmp="$complete EOL" 18376 arguments="${tmp#* }" 18377 18378 # Input might be given as Windows format, start by converting to 18379 # unix format. 18380 new_path="$path" 18381 18382 windows_path="$new_path" 18383 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18384 unix_path=`$CYGPATH -u "$windows_path"` 18385 new_path="$unix_path" 18386 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18387 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18388 new_path="$unix_path" 18389 fi 18390 18391 18392 # Now try to locate executable using which 18393 new_path=`$WHICH "$new_path" 2> /dev/null` 18394 18395 if test "x$new_path" = x; then 18396 # Oops. Which didn't find the executable. 18397 # The splitting of arguments from the executable at a space might have been incorrect, 18398 # since paths with space are more likely in Windows. Give it another try with the whole 18399 # argument. 18400 path="$complete" 18401 arguments="EOL" 18402 new_path="$path" 18403 18404 windows_path="$new_path" 18405 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18406 unix_path=`$CYGPATH -u "$windows_path"` 18407 new_path="$unix_path" 18408 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18409 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18410 new_path="$unix_path" 18411 fi 18412 18413 18414 new_path=`$WHICH "$new_path" 2> /dev/null` 18415 # bat and cmd files are not always considered executable in MSYS causing which 18416 # to not find them 18417 if test "x$new_path" = x \ 18418 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18419 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18420 new_path="$path" 18421 18422 windows_path="$new_path" 18423 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18424 unix_path=`$CYGPATH -u "$windows_path"` 18425 new_path="$unix_path" 18426 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18427 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18428 new_path="$unix_path" 18429 fi 18430 18431 fi 18432 18433 if test "x$new_path" = x; then 18434 # It's still not found. Now this is an unrecoverable error. 18435 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18436 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18437 has_space=`$ECHO "$complete" | $GREP " "` 18438 if test "x$has_space" != x; then 18439 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18440 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18441 fi 18442 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18443 fi 18444 fi 18445 18446 # Now new_path has a complete unix path to the binary 18447 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 18448 # Keep paths in /bin as-is, but remove trailing .exe if any 18449 new_path="${new_path/%.exe/}" 18450 # Do not save /bin paths to all_fixpath_prefixes! 18451 else 18452 # Not in mixed or Windows style, start by that. 18453 new_path=`cmd //c echo $new_path` 18454 18455 input_path="$new_path" 18456 # Check if we need to convert this using DOS-style short mode. If the path 18457 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18458 # take no chances and rewrite it. 18459 # Note: m4 eats our [], so we need to use [ and ] instead. 18460 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 18461 if test "x$has_forbidden_chars" != x; then 18462 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18463 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18464 fi 18465 18466 # Output is in $new_path 18467 18468 windows_path="$new_path" 18469 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18470 unix_path=`$CYGPATH -u "$windows_path"` 18471 new_path="$unix_path" 18472 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18473 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18474 new_path="$unix_path" 18475 fi 18476 18477 # remove trailing .exe if any 18478 new_path="${new_path/%.exe/}" 18479 18480 # Save the first 10 bytes of this path to the storage, so fixpath can work. 18481 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 18482 fi 18483 18484 else 18485 # We're on a unix platform. Hooray! :) 18486 # First separate the path from the arguments. This will split at the first 18487 # space. 18488 complete="$FOUND_MAKE" 18489 path="${complete%% *}" 18490 tmp="$complete EOL" 18491 arguments="${tmp#* }" 18492 18493 # Cannot rely on the command "which" here since it doesn't always work. 18494 is_absolute_path=`$ECHO "$path" | $GREP ^/` 18495 if test -z "$is_absolute_path"; then 18496 # Path to executable is not absolute. Find it. 18497 IFS_save="$IFS" 18498 IFS=: 18499 for p in $PATH; do 18500 if test -f "$p/$path" && test -x "$p/$path"; then 18501 new_path="$p/$path" 18502 break 18503 fi 18504 done 18505 IFS="$IFS_save" 18506 else 18507 # This is an absolute path, we can use it without further modifications. 18508 new_path="$path" 18509 fi 18510 18511 if test "x$new_path" = x; then 18512 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18513 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18514 has_space=`$ECHO "$complete" | $GREP " "` 18515 if test "x$has_space" != x; then 18516 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 18517 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 18518 fi 18519 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18520 fi 18521 fi 18522 18523 # Now join together the path and the arguments once again 18524 if test "x$arguments" != xEOL; then 18525 new_complete="$new_path ${arguments% *}" 18526 else 18527 new_complete="$new_path" 18528 fi 18529 18530 if test "x$complete" != "x$new_complete"; then 18531 FOUND_MAKE="$new_complete" 18532 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 18533 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 18534 fi 18535 fi 18536 18537 fi 18538 fi 18539 fi 18540 fi 18541 18542 fi 18543 18544 if test "x$FOUND_MAKE" = x; then 18545 if test "x$TOOLCHAIN_PATH" != x; then 18546 # We have a toolchain path, check that as well before giving up. 18547 OLD_PATH=$PATH 18548 PATH=$TOOLCHAIN_PATH:$PATH 18549 for ac_prog in gmake 18550 do 18551 # Extract the first word of "$ac_prog", so it can be a program name with args. 18552 set dummy $ac_prog; ac_word=$2 18553 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 18554 $as_echo_n "checking for $ac_word... " >&6; } 18555 if ${ac_cv_path_CHECK_TOOLSDIR_GMAKE+:} false; then : 18556 $as_echo_n "(cached) " >&6 18557 else 18558 case $CHECK_TOOLSDIR_GMAKE in 18559 [\\/]* | ?:[\\/]*) 18560 ac_cv_path_CHECK_TOOLSDIR_GMAKE="$CHECK_TOOLSDIR_GMAKE" # Let the user override the test with a path. 18561 ;; 18562 *) 18563 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 18564 for as_dir in $PATH 18565 do 18566 IFS=$as_save_IFS 18567 test -z "$as_dir" && as_dir=. 18568 for ac_exec_ext in '' $ac_executable_extensions; do 18569 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 18570 ac_cv_path_CHECK_TOOLSDIR_GMAKE="$as_dir/$ac_word$ac_exec_ext" 18571 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 18572 break 2 18573 fi 18574 done 18575 done 18576 IFS=$as_save_IFS 18577 18578 ;; 18579 esac 18580 fi 18581 CHECK_TOOLSDIR_GMAKE=$ac_cv_path_CHECK_TOOLSDIR_GMAKE 18582 if test -n "$CHECK_TOOLSDIR_GMAKE"; then 18583 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_GMAKE" >&5 18584 $as_echo "$CHECK_TOOLSDIR_GMAKE" >&6; } 18585 else 18586 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 18587 $as_echo "no" >&6; } 18588 fi 18589 18590 18591 test -n "$CHECK_TOOLSDIR_GMAKE" && break 18592 done 18593 18594 18595 MAKE_CANDIDATE=""$CHECK_TOOLSDIR_GMAKE"" 18596 DESCRIPTION="gmake in tools-dir" 18597 18598 # On Cygwin, we require a newer version of make than on other platforms 18599 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18600 MAKE_VERSION_EXPR="-e 4\." 18601 MAKE_REQUIRED_VERSION="4.0" 18602 else 18603 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 18604 MAKE_REQUIRED_VERSION="3.81" 18605 fi 18606 18607 if test "x$MAKE_CANDIDATE" != x; then 18608 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 18609 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 18610 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 18611 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 18612 if test "x$IS_GNU_MAKE" = x; then 18613 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 18614 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 18615 else 18616 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 18617 if test "x$IS_MODERN_MAKE" = x; then 18618 { $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 18619 $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;} 18620 else 18621 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 18622 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18623 MAKE_EXPECTED_ENV='cygwin' 18624 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18625 MAKE_EXPECTED_ENV='msys' 18626 else 18627 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 18628 fi 18629 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 18630 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 18631 else 18632 # Not relevant for non-Windows 18633 IS_MAKE_CORRECT_ENV=true 18634 fi 18635 if test "x$IS_MAKE_CORRECT_ENV" = x; then 18636 { $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 18637 $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;} 18638 else 18639 FOUND_MAKE=$MAKE_CANDIDATE 18640 18641 # Only process if variable expands to non-empty 18642 18643 if test "x$FOUND_MAKE" != x; then 18644 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18645 18646 # First separate the path from the arguments. This will split at the first 18647 # space. 18648 complete="$FOUND_MAKE" 18649 path="${complete%% *}" 18650 tmp="$complete EOL" 18651 arguments="${tmp#* }" 18652 18653 # Input might be given as Windows format, start by converting to 18654 # unix format. 18655 new_path=`$CYGPATH -u "$path"` 18656 18657 # Now try to locate executable using which 18658 new_path=`$WHICH "$new_path" 2> /dev/null` 18659 # bat and cmd files are not always considered executable in cygwin causing which 18660 # to not find them 18661 if test "x$new_path" = x \ 18662 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18663 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18664 new_path=`$CYGPATH -u "$path"` 18665 fi 18666 if test "x$new_path" = x; then 18667 # Oops. Which didn't find the executable. 18668 # The splitting of arguments from the executable at a space might have been incorrect, 18669 # since paths with space are more likely in Windows. Give it another try with the whole 18670 # argument. 18671 path="$complete" 18672 arguments="EOL" 18673 new_path=`$CYGPATH -u "$path"` 18674 new_path=`$WHICH "$new_path" 2> /dev/null` 18675 # bat and cmd files are not always considered executable in cygwin causing which 18676 # to not find them 18677 if test "x$new_path" = x \ 18678 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18679 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18680 new_path=`$CYGPATH -u "$path"` 18681 fi 18682 if test "x$new_path" = x; then 18683 # It's still not found. Now this is an unrecoverable error. 18684 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18685 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18686 has_space=`$ECHO "$complete" | $GREP " "` 18687 if test "x$has_space" != x; then 18688 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18689 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18690 fi 18691 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18692 fi 18693 fi 18694 18695 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 18696 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 18697 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 18698 # "foo.exe" is OK but "foo" is an error. 18699 # 18700 # This test is therefore slightly more accurate than "test -f" to check for file presence. 18701 # It is also a way to make sure we got the proper file name for the real test later on. 18702 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 18703 if test "x$test_shortpath" = x; then 18704 # Short path failed, file does not exist as specified. 18705 # Try adding .exe or .cmd 18706 if test -f "${new_path}.exe"; then 18707 input_to_shortpath="${new_path}.exe" 18708 elif test -f "${new_path}.cmd"; then 18709 input_to_shortpath="${new_path}.cmd" 18710 else 18711 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 18712 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 18713 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 18714 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 18715 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18716 fi 18717 else 18718 input_to_shortpath="$new_path" 18719 fi 18720 18721 # Call helper function which possibly converts this using DOS-style short mode. 18722 # If so, the updated path is stored in $new_path. 18723 new_path="$input_to_shortpath" 18724 18725 input_path="$input_to_shortpath" 18726 # Check if we need to convert this using DOS-style short mode. If the path 18727 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18728 # take no chances and rewrite it. 18729 # Note: m4 eats our [], so we need to use [ and ] instead. 18730 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 18731 if test "x$has_forbidden_chars" != x; then 18732 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18733 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 18734 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 18735 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 18736 # Going to short mode and back again did indeed matter. Since short mode is 18737 # case insensitive, let's make it lowercase to improve readability. 18738 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18739 # Now convert it back to Unix-style (cygpath) 18740 input_path=`$CYGPATH -u "$shortmode_path"` 18741 new_path="$input_path" 18742 fi 18743 fi 18744 18745 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 18746 if test "x$test_cygdrive_prefix" = x; then 18747 # As a simple fix, exclude /usr/bin since it's not a real path. 18748 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 18749 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 18750 # a path prefixed by /cygdrive for fixpath to work. 18751 new_path="$CYGWIN_ROOT_PATH$input_path" 18752 fi 18753 fi 18754 18755 # remove trailing .exe if any 18756 new_path="${new_path/%.exe/}" 18757 18758 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18759 18760 # First separate the path from the arguments. This will split at the first 18761 # space. 18762 complete="$FOUND_MAKE" 18763 path="${complete%% *}" 18764 tmp="$complete EOL" 18765 arguments="${tmp#* }" 18766 18767 # Input might be given as Windows format, start by converting to 18768 # unix format. 18769 new_path="$path" 18770 18771 windows_path="$new_path" 18772 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18773 unix_path=`$CYGPATH -u "$windows_path"` 18774 new_path="$unix_path" 18775 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18776 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18777 new_path="$unix_path" 18778 fi 18779 18780 18781 # Now try to locate executable using which 18782 new_path=`$WHICH "$new_path" 2> /dev/null` 18783 18784 if test "x$new_path" = x; then 18785 # Oops. Which didn't find the executable. 18786 # The splitting of arguments from the executable at a space might have been incorrect, 18787 # since paths with space are more likely in Windows. Give it another try with the whole 18788 # argument. 18789 path="$complete" 18790 arguments="EOL" 18791 new_path="$path" 18792 18793 windows_path="$new_path" 18794 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18795 unix_path=`$CYGPATH -u "$windows_path"` 18796 new_path="$unix_path" 18797 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18798 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18799 new_path="$unix_path" 18800 fi 18801 18802 18803 new_path=`$WHICH "$new_path" 2> /dev/null` 18804 # bat and cmd files are not always considered executable in MSYS causing which 18805 # to not find them 18806 if test "x$new_path" = x \ 18807 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18808 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18809 new_path="$path" 18810 18811 windows_path="$new_path" 18812 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18813 unix_path=`$CYGPATH -u "$windows_path"` 18814 new_path="$unix_path" 18815 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18816 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18817 new_path="$unix_path" 18818 fi 18819 18820 fi 18821 18822 if test "x$new_path" = x; then 18823 # It's still not found. Now this is an unrecoverable error. 18824 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18825 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18826 has_space=`$ECHO "$complete" | $GREP " "` 18827 if test "x$has_space" != x; then 18828 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18829 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18830 fi 18831 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18832 fi 18833 fi 18834 18835 # Now new_path has a complete unix path to the binary 18836 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 18837 # Keep paths in /bin as-is, but remove trailing .exe if any 18838 new_path="${new_path/%.exe/}" 18839 # Do not save /bin paths to all_fixpath_prefixes! 18840 else 18841 # Not in mixed or Windows style, start by that. 18842 new_path=`cmd //c echo $new_path` 18843 18844 input_path="$new_path" 18845 # Check if we need to convert this using DOS-style short mode. If the path 18846 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18847 # take no chances and rewrite it. 18848 # Note: m4 eats our [], so we need to use [ and ] instead. 18849 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 18850 if test "x$has_forbidden_chars" != x; then 18851 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18852 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18853 fi 18854 18855 # Output is in $new_path 18856 18857 windows_path="$new_path" 18858 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18859 unix_path=`$CYGPATH -u "$windows_path"` 18860 new_path="$unix_path" 18861 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18862 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18863 new_path="$unix_path" 18864 fi 18865 18866 # remove trailing .exe if any 18867 new_path="${new_path/%.exe/}" 18868 18869 # Save the first 10 bytes of this path to the storage, so fixpath can work. 18870 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 18871 fi 18872 18873 else 18874 # We're on a unix platform. Hooray! :) 18875 # First separate the path from the arguments. This will split at the first 18876 # space. 18877 complete="$FOUND_MAKE" 18878 path="${complete%% *}" 18879 tmp="$complete EOL" 18880 arguments="${tmp#* }" 18881 18882 # Cannot rely on the command "which" here since it doesn't always work. 18883 is_absolute_path=`$ECHO "$path" | $GREP ^/` 18884 if test -z "$is_absolute_path"; then 18885 # Path to executable is not absolute. Find it. 18886 IFS_save="$IFS" 18887 IFS=: 18888 for p in $PATH; do 18889 if test -f "$p/$path" && test -x "$p/$path"; then 18890 new_path="$p/$path" 18891 break 18892 fi 18893 done 18894 IFS="$IFS_save" 18895 else 18896 # This is an absolute path, we can use it without further modifications. 18897 new_path="$path" 18898 fi 18899 18900 if test "x$new_path" = x; then 18901 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18902 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18903 has_space=`$ECHO "$complete" | $GREP " "` 18904 if test "x$has_space" != x; then 18905 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 18906 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 18907 fi 18908 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18909 fi 18910 fi 18911 18912 # Now join together the path and the arguments once again 18913 if test "x$arguments" != xEOL; then 18914 new_complete="$new_path ${arguments% *}" 18915 else 18916 new_complete="$new_path" 18917 fi 18918 18919 if test "x$complete" != "x$new_complete"; then 18920 FOUND_MAKE="$new_complete" 18921 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 18922 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 18923 fi 18924 fi 18925 18926 fi 18927 fi 18928 fi 18929 fi 18930 18931 if test "x$FOUND_MAKE" = x; then 18932 for ac_prog in make 18933 do 18934 # Extract the first word of "$ac_prog", so it can be a program name with args. 18935 set dummy $ac_prog; ac_word=$2 18936 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 18937 $as_echo_n "checking for $ac_word... " >&6; } 18938 if ${ac_cv_path_CHECK_TOOLSDIR_MAKE+:} false; then : 18939 $as_echo_n "(cached) " >&6 18940 else 18941 case $CHECK_TOOLSDIR_MAKE in 18942 [\\/]* | ?:[\\/]*) 18943 ac_cv_path_CHECK_TOOLSDIR_MAKE="$CHECK_TOOLSDIR_MAKE" # Let the user override the test with a path. 18944 ;; 18945 *) 18946 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 18947 for as_dir in $PATH 18948 do 18949 IFS=$as_save_IFS 18950 test -z "$as_dir" && as_dir=. 18951 for ac_exec_ext in '' $ac_executable_extensions; do 18952 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 18953 ac_cv_path_CHECK_TOOLSDIR_MAKE="$as_dir/$ac_word$ac_exec_ext" 18954 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 18955 break 2 18956 fi 18957 done 18958 done 18959 IFS=$as_save_IFS 18960 18961 ;; 18962 esac 18963 fi 18964 CHECK_TOOLSDIR_MAKE=$ac_cv_path_CHECK_TOOLSDIR_MAKE 18965 if test -n "$CHECK_TOOLSDIR_MAKE"; then 18966 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_MAKE" >&5 18967 $as_echo "$CHECK_TOOLSDIR_MAKE" >&6; } 18968 else 18969 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 18970 $as_echo "no" >&6; } 18971 fi 18972 18973 18974 test -n "$CHECK_TOOLSDIR_MAKE" && break 18975 done 18976 18977 18978 MAKE_CANDIDATE=""$CHECK_TOOLSDIR_MAKE"" 18979 DESCRIPTION="make in tools-dir" 18980 18981 # On Cygwin, we require a newer version of make than on other platforms 18982 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18983 MAKE_VERSION_EXPR="-e 4\." 18984 MAKE_REQUIRED_VERSION="4.0" 18985 else 18986 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 18987 MAKE_REQUIRED_VERSION="3.81" 18988 fi 18989 18990 if test "x$MAKE_CANDIDATE" != x; then 18991 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 18992 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 18993 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 18994 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 18995 if test "x$IS_GNU_MAKE" = x; then 18996 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 18997 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 18998 else 18999 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 19000 if test "x$IS_MODERN_MAKE" = x; then 19001 { $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 19002 $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;} 19003 else 19004 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 19005 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19006 MAKE_EXPECTED_ENV='cygwin' 19007 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19008 MAKE_EXPECTED_ENV='msys' 19009 else 19010 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 19011 fi 19012 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 19013 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 19014 else 19015 # Not relevant for non-Windows 19016 IS_MAKE_CORRECT_ENV=true 19017 fi 19018 if test "x$IS_MAKE_CORRECT_ENV" = x; then 19019 { $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 19020 $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;} 19021 else 19022 FOUND_MAKE=$MAKE_CANDIDATE 19023 19024 # Only process if variable expands to non-empty 19025 19026 if test "x$FOUND_MAKE" != x; then 19027 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19028 19029 # First separate the path from the arguments. This will split at the first 19030 # space. 19031 complete="$FOUND_MAKE" 19032 path="${complete%% *}" 19033 tmp="$complete EOL" 19034 arguments="${tmp#* }" 19035 19036 # Input might be given as Windows format, start by converting to 19037 # unix format. 19038 new_path=`$CYGPATH -u "$path"` 19039 19040 # Now try to locate executable using which 19041 new_path=`$WHICH "$new_path" 2> /dev/null` 19042 # bat and cmd files are not always considered executable in cygwin causing which 19043 # to not find them 19044 if test "x$new_path" = x \ 19045 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19046 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19047 new_path=`$CYGPATH -u "$path"` 19048 fi 19049 if test "x$new_path" = x; then 19050 # Oops. Which didn't find the executable. 19051 # The splitting of arguments from the executable at a space might have been incorrect, 19052 # since paths with space are more likely in Windows. Give it another try with the whole 19053 # argument. 19054 path="$complete" 19055 arguments="EOL" 19056 new_path=`$CYGPATH -u "$path"` 19057 new_path=`$WHICH "$new_path" 2> /dev/null` 19058 # bat and cmd files are not always considered executable in cygwin causing which 19059 # to not find them 19060 if test "x$new_path" = x \ 19061 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19062 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19063 new_path=`$CYGPATH -u "$path"` 19064 fi 19065 if test "x$new_path" = x; then 19066 # It's still not found. Now this is an unrecoverable error. 19067 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19068 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19069 has_space=`$ECHO "$complete" | $GREP " "` 19070 if test "x$has_space" != x; then 19071 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19072 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19073 fi 19074 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19075 fi 19076 fi 19077 19078 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 19079 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 19080 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 19081 # "foo.exe" is OK but "foo" is an error. 19082 # 19083 # This test is therefore slightly more accurate than "test -f" to check for file presence. 19084 # It is also a way to make sure we got the proper file name for the real test later on. 19085 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 19086 if test "x$test_shortpath" = x; then 19087 # Short path failed, file does not exist as specified. 19088 # Try adding .exe or .cmd 19089 if test -f "${new_path}.exe"; then 19090 input_to_shortpath="${new_path}.exe" 19091 elif test -f "${new_path}.cmd"; then 19092 input_to_shortpath="${new_path}.cmd" 19093 else 19094 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 19095 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 19096 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 19097 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 19098 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19099 fi 19100 else 19101 input_to_shortpath="$new_path" 19102 fi 19103 19104 # Call helper function which possibly converts this using DOS-style short mode. 19105 # If so, the updated path is stored in $new_path. 19106 new_path="$input_to_shortpath" 19107 19108 input_path="$input_to_shortpath" 19109 # Check if we need to convert this using DOS-style short mode. If the path 19110 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19111 # take no chances and rewrite it. 19112 # Note: m4 eats our [], so we need to use [ and ] instead. 19113 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 19114 if test "x$has_forbidden_chars" != x; then 19115 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19116 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 19117 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 19118 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 19119 # Going to short mode and back again did indeed matter. Since short mode is 19120 # case insensitive, let's make it lowercase to improve readability. 19121 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19122 # Now convert it back to Unix-style (cygpath) 19123 input_path=`$CYGPATH -u "$shortmode_path"` 19124 new_path="$input_path" 19125 fi 19126 fi 19127 19128 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 19129 if test "x$test_cygdrive_prefix" = x; then 19130 # As a simple fix, exclude /usr/bin since it's not a real path. 19131 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 19132 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 19133 # a path prefixed by /cygdrive for fixpath to work. 19134 new_path="$CYGWIN_ROOT_PATH$input_path" 19135 fi 19136 fi 19137 19138 # remove trailing .exe if any 19139 new_path="${new_path/%.exe/}" 19140 19141 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19142 19143 # First separate the path from the arguments. This will split at the first 19144 # space. 19145 complete="$FOUND_MAKE" 19146 path="${complete%% *}" 19147 tmp="$complete EOL" 19148 arguments="${tmp#* }" 19149 19150 # Input might be given as Windows format, start by converting to 19151 # unix format. 19152 new_path="$path" 19153 19154 windows_path="$new_path" 19155 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19156 unix_path=`$CYGPATH -u "$windows_path"` 19157 new_path="$unix_path" 19158 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19159 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19160 new_path="$unix_path" 19161 fi 19162 19163 19164 # Now try to locate executable using which 19165 new_path=`$WHICH "$new_path" 2> /dev/null` 19166 19167 if test "x$new_path" = x; then 19168 # Oops. Which didn't find the executable. 19169 # The splitting of arguments from the executable at a space might have been incorrect, 19170 # since paths with space are more likely in Windows. Give it another try with the whole 19171 # argument. 19172 path="$complete" 19173 arguments="EOL" 19174 new_path="$path" 19175 19176 windows_path="$new_path" 19177 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19178 unix_path=`$CYGPATH -u "$windows_path"` 19179 new_path="$unix_path" 19180 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19181 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19182 new_path="$unix_path" 19183 fi 19184 19185 19186 new_path=`$WHICH "$new_path" 2> /dev/null` 19187 # bat and cmd files are not always considered executable in MSYS causing which 19188 # to not find them 19189 if test "x$new_path" = x \ 19190 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19191 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19192 new_path="$path" 19193 19194 windows_path="$new_path" 19195 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19196 unix_path=`$CYGPATH -u "$windows_path"` 19197 new_path="$unix_path" 19198 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19199 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19200 new_path="$unix_path" 19201 fi 19202 19203 fi 19204 19205 if test "x$new_path" = x; then 19206 # It's still not found. Now this is an unrecoverable error. 19207 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19208 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19209 has_space=`$ECHO "$complete" | $GREP " "` 19210 if test "x$has_space" != x; then 19211 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19212 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19213 fi 19214 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19215 fi 19216 fi 19217 19218 # Now new_path has a complete unix path to the binary 19219 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 19220 # Keep paths in /bin as-is, but remove trailing .exe if any 19221 new_path="${new_path/%.exe/}" 19222 # Do not save /bin paths to all_fixpath_prefixes! 19223 else 19224 # Not in mixed or Windows style, start by that. 19225 new_path=`cmd //c echo $new_path` 19226 19227 input_path="$new_path" 19228 # Check if we need to convert this using DOS-style short mode. If the path 19229 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19230 # take no chances and rewrite it. 19231 # Note: m4 eats our [], so we need to use [ and ] instead. 19232 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 19233 if test "x$has_forbidden_chars" != x; then 19234 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19235 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19236 fi 19237 19238 # Output is in $new_path 19239 19240 windows_path="$new_path" 19241 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19242 unix_path=`$CYGPATH -u "$windows_path"` 19243 new_path="$unix_path" 19244 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19245 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19246 new_path="$unix_path" 19247 fi 19248 19249 # remove trailing .exe if any 19250 new_path="${new_path/%.exe/}" 19251 19252 # Save the first 10 bytes of this path to the storage, so fixpath can work. 19253 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 19254 fi 19255 19256 else 19257 # We're on a unix platform. Hooray! :) 19258 # First separate the path from the arguments. This will split at the first 19259 # space. 19260 complete="$FOUND_MAKE" 19261 path="${complete%% *}" 19262 tmp="$complete EOL" 19263 arguments="${tmp#* }" 19264 19265 # Cannot rely on the command "which" here since it doesn't always work. 19266 is_absolute_path=`$ECHO "$path" | $GREP ^/` 19267 if test -z "$is_absolute_path"; then 19268 # Path to executable is not absolute. Find it. 19269 IFS_save="$IFS" 19270 IFS=: 19271 for p in $PATH; do 19272 if test -f "$p/$path" && test -x "$p/$path"; then 19273 new_path="$p/$path" 19274 break 19275 fi 19276 done 19277 IFS="$IFS_save" 19278 else 19279 # This is an absolute path, we can use it without further modifications. 19280 new_path="$path" 19281 fi 19282 19283 if test "x$new_path" = x; then 19284 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19285 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19286 has_space=`$ECHO "$complete" | $GREP " "` 19287 if test "x$has_space" != x; then 19288 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 19289 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 19290 fi 19291 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19292 fi 19293 fi 19294 19295 # Now join together the path and the arguments once again 19296 if test "x$arguments" != xEOL; then 19297 new_complete="$new_path ${arguments% *}" 19298 else 19299 new_complete="$new_path" 19300 fi 19301 19302 if test "x$complete" != "x$new_complete"; then 19303 FOUND_MAKE="$new_complete" 19304 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 19305 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 19306 fi 19307 fi 19308 19309 fi 19310 fi 19311 fi 19312 fi 19313 19314 fi 19315 PATH=$OLD_PATH 19316 fi 19317 fi 19318 19319 if test "x$FOUND_MAKE" = x; then 19320 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 19321 fi 19322 19323 else 19324 # The variable is set, but is it from the command line or the environment? 19325 19326 # Try to remove the string !MAKE! from our list. 19327 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MAKE!/} 19328 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 19329 # If it failed, the variable was not from the command line. Ignore it, 19330 # but warn the user (except for BASH, which is always set by the calling BASH). 19331 if test "xMAKE" != xBASH; then 19332 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MAKE from the environment. Use command line variables instead." >&5 19333 $as_echo "$as_me: WARNING: Ignoring value of MAKE from the environment. Use command line variables instead." >&2;} 19334 fi 19335 # Try to locate tool using the code snippet 19336 19337 # Try our hardest to locate a correct version of GNU make 19338 for ac_prog in gmake 19339 do 19340 # Extract the first word of "$ac_prog", so it can be a program name with args. 19341 set dummy $ac_prog; ac_word=$2 19342 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 19343 $as_echo_n "checking for $ac_word... " >&6; } 19344 if ${ac_cv_path_CHECK_GMAKE+:} false; then : 19345 $as_echo_n "(cached) " >&6 19346 else 19347 case $CHECK_GMAKE in 19348 [\\/]* | ?:[\\/]*) 19349 ac_cv_path_CHECK_GMAKE="$CHECK_GMAKE" # Let the user override the test with a path. 19350 ;; 19351 *) 19352 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 19353 for as_dir in $PATH 19354 do 19355 IFS=$as_save_IFS 19356 test -z "$as_dir" && as_dir=. 19357 for ac_exec_ext in '' $ac_executable_extensions; do 19358 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 19359 ac_cv_path_CHECK_GMAKE="$as_dir/$ac_word$ac_exec_ext" 19360 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 19361 break 2 19362 fi 19363 done 19364 done 19365 IFS=$as_save_IFS 19366 19367 ;; 19368 esac 19369 fi 19370 CHECK_GMAKE=$ac_cv_path_CHECK_GMAKE 19371 if test -n "$CHECK_GMAKE"; then 19372 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_GMAKE" >&5 19373 $as_echo "$CHECK_GMAKE" >&6; } 19374 else 19375 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 19376 $as_echo "no" >&6; } 19377 fi 19378 19379 19380 test -n "$CHECK_GMAKE" && break 19381 done 19382 19383 19384 MAKE_CANDIDATE=""$CHECK_GMAKE"" 19385 DESCRIPTION="gmake in PATH" 19386 19387 # On Cygwin, we require a newer version of make than on other platforms 19388 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19389 MAKE_VERSION_EXPR="-e 4\." 19390 MAKE_REQUIRED_VERSION="4.0" 19391 else 19392 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 19393 MAKE_REQUIRED_VERSION="3.81" 19394 fi 19395 19396 if test "x$MAKE_CANDIDATE" != x; then 19397 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 19398 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 19399 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 19400 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 19401 if test "x$IS_GNU_MAKE" = x; then 19402 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 19403 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 19404 else 19405 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 19406 if test "x$IS_MODERN_MAKE" = x; then 19407 { $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 19408 $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;} 19409 else 19410 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 19411 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19412 MAKE_EXPECTED_ENV='cygwin' 19413 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19414 MAKE_EXPECTED_ENV='msys' 19415 else 19416 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 19417 fi 19418 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 19419 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 19420 else 19421 # Not relevant for non-Windows 19422 IS_MAKE_CORRECT_ENV=true 19423 fi 19424 if test "x$IS_MAKE_CORRECT_ENV" = x; then 19425 { $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 19426 $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;} 19427 else 19428 FOUND_MAKE=$MAKE_CANDIDATE 19429 19430 # Only process if variable expands to non-empty 19431 19432 if test "x$FOUND_MAKE" != x; then 19433 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19434 19435 # First separate the path from the arguments. This will split at the first 19436 # space. 19437 complete="$FOUND_MAKE" 19438 path="${complete%% *}" 19439 tmp="$complete EOL" 19440 arguments="${tmp#* }" 19441 19442 # Input might be given as Windows format, start by converting to 19443 # unix format. 19444 new_path=`$CYGPATH -u "$path"` 19445 19446 # Now try to locate executable using which 19447 new_path=`$WHICH "$new_path" 2> /dev/null` 19448 # bat and cmd files are not always considered executable in cygwin causing which 19449 # to not find them 19450 if test "x$new_path" = x \ 19451 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19452 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19453 new_path=`$CYGPATH -u "$path"` 19454 fi 19455 if test "x$new_path" = x; then 19456 # Oops. Which didn't find the executable. 19457 # The splitting of arguments from the executable at a space might have been incorrect, 19458 # since paths with space are more likely in Windows. Give it another try with the whole 19459 # argument. 19460 path="$complete" 19461 arguments="EOL" 19462 new_path=`$CYGPATH -u "$path"` 19463 new_path=`$WHICH "$new_path" 2> /dev/null` 19464 # bat and cmd files are not always considered executable in cygwin causing which 19465 # to not find them 19466 if test "x$new_path" = x \ 19467 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19468 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19469 new_path=`$CYGPATH -u "$path"` 19470 fi 19471 if test "x$new_path" = x; then 19472 # It's still not found. Now this is an unrecoverable error. 19473 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19474 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19475 has_space=`$ECHO "$complete" | $GREP " "` 19476 if test "x$has_space" != x; then 19477 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19478 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19479 fi 19480 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19481 fi 19482 fi 19483 19484 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 19485 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 19486 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 19487 # "foo.exe" is OK but "foo" is an error. 19488 # 19489 # This test is therefore slightly more accurate than "test -f" to check for file presence. 19490 # It is also a way to make sure we got the proper file name for the real test later on. 19491 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 19492 if test "x$test_shortpath" = x; then 19493 # Short path failed, file does not exist as specified. 19494 # Try adding .exe or .cmd 19495 if test -f "${new_path}.exe"; then 19496 input_to_shortpath="${new_path}.exe" 19497 elif test -f "${new_path}.cmd"; then 19498 input_to_shortpath="${new_path}.cmd" 19499 else 19500 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 19501 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 19502 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 19503 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 19504 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19505 fi 19506 else 19507 input_to_shortpath="$new_path" 19508 fi 19509 19510 # Call helper function which possibly converts this using DOS-style short mode. 19511 # If so, the updated path is stored in $new_path. 19512 new_path="$input_to_shortpath" 19513 19514 input_path="$input_to_shortpath" 19515 # Check if we need to convert this using DOS-style short mode. If the path 19516 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19517 # take no chances and rewrite it. 19518 # Note: m4 eats our [], so we need to use [ and ] instead. 19519 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 19520 if test "x$has_forbidden_chars" != x; then 19521 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19522 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 19523 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 19524 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 19525 # Going to short mode and back again did indeed matter. Since short mode is 19526 # case insensitive, let's make it lowercase to improve readability. 19527 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19528 # Now convert it back to Unix-style (cygpath) 19529 input_path=`$CYGPATH -u "$shortmode_path"` 19530 new_path="$input_path" 19531 fi 19532 fi 19533 19534 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 19535 if test "x$test_cygdrive_prefix" = x; then 19536 # As a simple fix, exclude /usr/bin since it's not a real path. 19537 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 19538 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 19539 # a path prefixed by /cygdrive for fixpath to work. 19540 new_path="$CYGWIN_ROOT_PATH$input_path" 19541 fi 19542 fi 19543 19544 # remove trailing .exe if any 19545 new_path="${new_path/%.exe/}" 19546 19547 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19548 19549 # First separate the path from the arguments. This will split at the first 19550 # space. 19551 complete="$FOUND_MAKE" 19552 path="${complete%% *}" 19553 tmp="$complete EOL" 19554 arguments="${tmp#* }" 19555 19556 # Input might be given as Windows format, start by converting to 19557 # unix format. 19558 new_path="$path" 19559 19560 windows_path="$new_path" 19561 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19562 unix_path=`$CYGPATH -u "$windows_path"` 19563 new_path="$unix_path" 19564 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19565 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19566 new_path="$unix_path" 19567 fi 19568 19569 19570 # Now try to locate executable using which 19571 new_path=`$WHICH "$new_path" 2> /dev/null` 19572 19573 if test "x$new_path" = x; then 19574 # Oops. Which didn't find the executable. 19575 # The splitting of arguments from the executable at a space might have been incorrect, 19576 # since paths with space are more likely in Windows. Give it another try with the whole 19577 # argument. 19578 path="$complete" 19579 arguments="EOL" 19580 new_path="$path" 19581 19582 windows_path="$new_path" 19583 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19584 unix_path=`$CYGPATH -u "$windows_path"` 19585 new_path="$unix_path" 19586 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19587 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19588 new_path="$unix_path" 19589 fi 19590 19591 19592 new_path=`$WHICH "$new_path" 2> /dev/null` 19593 # bat and cmd files are not always considered executable in MSYS causing which 19594 # to not find them 19595 if test "x$new_path" = x \ 19596 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19597 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19598 new_path="$path" 19599 19600 windows_path="$new_path" 19601 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19602 unix_path=`$CYGPATH -u "$windows_path"` 19603 new_path="$unix_path" 19604 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19605 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19606 new_path="$unix_path" 19607 fi 19608 19609 fi 19610 19611 if test "x$new_path" = x; then 19612 # It's still not found. Now this is an unrecoverable error. 19613 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19614 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19615 has_space=`$ECHO "$complete" | $GREP " "` 19616 if test "x$has_space" != x; then 19617 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19618 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19619 fi 19620 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19621 fi 19622 fi 19623 19624 # Now new_path has a complete unix path to the binary 19625 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 19626 # Keep paths in /bin as-is, but remove trailing .exe if any 19627 new_path="${new_path/%.exe/}" 19628 # Do not save /bin paths to all_fixpath_prefixes! 19629 else 19630 # Not in mixed or Windows style, start by that. 19631 new_path=`cmd //c echo $new_path` 19632 19633 input_path="$new_path" 19634 # Check if we need to convert this using DOS-style short mode. If the path 19635 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19636 # take no chances and rewrite it. 19637 # Note: m4 eats our [], so we need to use [ and ] instead. 19638 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 19639 if test "x$has_forbidden_chars" != x; then 19640 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19641 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19642 fi 19643 19644 # Output is in $new_path 19645 19646 windows_path="$new_path" 19647 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19648 unix_path=`$CYGPATH -u "$windows_path"` 19649 new_path="$unix_path" 19650 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19651 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19652 new_path="$unix_path" 19653 fi 19654 19655 # remove trailing .exe if any 19656 new_path="${new_path/%.exe/}" 19657 19658 # Save the first 10 bytes of this path to the storage, so fixpath can work. 19659 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 19660 fi 19661 19662 else 19663 # We're on a unix platform. Hooray! :) 19664 # First separate the path from the arguments. This will split at the first 19665 # space. 19666 complete="$FOUND_MAKE" 19667 path="${complete%% *}" 19668 tmp="$complete EOL" 19669 arguments="${tmp#* }" 19670 19671 # Cannot rely on the command "which" here since it doesn't always work. 19672 is_absolute_path=`$ECHO "$path" | $GREP ^/` 19673 if test -z "$is_absolute_path"; then 19674 # Path to executable is not absolute. Find it. 19675 IFS_save="$IFS" 19676 IFS=: 19677 for p in $PATH; do 19678 if test -f "$p/$path" && test -x "$p/$path"; then 19679 new_path="$p/$path" 19680 break 19681 fi 19682 done 19683 IFS="$IFS_save" 19684 else 19685 # This is an absolute path, we can use it without further modifications. 19686 new_path="$path" 19687 fi 19688 19689 if test "x$new_path" = x; then 19690 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19691 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19692 has_space=`$ECHO "$complete" | $GREP " "` 19693 if test "x$has_space" != x; then 19694 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 19695 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 19696 fi 19697 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19698 fi 19699 fi 19700 19701 # Now join together the path and the arguments once again 19702 if test "x$arguments" != xEOL; then 19703 new_complete="$new_path ${arguments% *}" 19704 else 19705 new_complete="$new_path" 19706 fi 19707 19708 if test "x$complete" != "x$new_complete"; then 19709 FOUND_MAKE="$new_complete" 19710 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 19711 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 19712 fi 19713 fi 19714 19715 fi 19716 fi 19717 fi 19718 fi 19719 19720 19721 if test "x$FOUND_MAKE" = x; then 19722 for ac_prog in make 19723 do 19724 # Extract the first word of "$ac_prog", so it can be a program name with args. 19725 set dummy $ac_prog; ac_word=$2 19726 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 19727 $as_echo_n "checking for $ac_word... " >&6; } 19728 if ${ac_cv_path_CHECK_MAKE+:} false; then : 19729 $as_echo_n "(cached) " >&6 19730 else 19731 case $CHECK_MAKE in 19732 [\\/]* | ?:[\\/]*) 19733 ac_cv_path_CHECK_MAKE="$CHECK_MAKE" # Let the user override the test with a path. 19734 ;; 19735 *) 19736 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 19737 for as_dir in $PATH 19738 do 19739 IFS=$as_save_IFS 19740 test -z "$as_dir" && as_dir=. 19741 for ac_exec_ext in '' $ac_executable_extensions; do 19742 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 19743 ac_cv_path_CHECK_MAKE="$as_dir/$ac_word$ac_exec_ext" 19744 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 19745 break 2 19746 fi 19747 done 19748 done 19749 IFS=$as_save_IFS 19750 19751 ;; 19752 esac 19753 fi 19754 CHECK_MAKE=$ac_cv_path_CHECK_MAKE 19755 if test -n "$CHECK_MAKE"; then 19756 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_MAKE" >&5 19757 $as_echo "$CHECK_MAKE" >&6; } 19758 else 19759 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 19760 $as_echo "no" >&6; } 19761 fi 19762 19763 19764 test -n "$CHECK_MAKE" && break 19765 done 19766 19767 19768 MAKE_CANDIDATE=""$CHECK_MAKE"" 19769 DESCRIPTION="make in PATH" 19770 19771 # On Cygwin, we require a newer version of make than on other platforms 19772 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19773 MAKE_VERSION_EXPR="-e 4\." 19774 MAKE_REQUIRED_VERSION="4.0" 19775 else 19776 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 19777 MAKE_REQUIRED_VERSION="3.81" 19778 fi 19779 19780 if test "x$MAKE_CANDIDATE" != x; then 19781 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 19782 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 19783 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 19784 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 19785 if test "x$IS_GNU_MAKE" = x; then 19786 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 19787 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 19788 else 19789 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 19790 if test "x$IS_MODERN_MAKE" = x; then 19791 { $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 19792 $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;} 19793 else 19794 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 19795 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19796 MAKE_EXPECTED_ENV='cygwin' 19797 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19798 MAKE_EXPECTED_ENV='msys' 19799 else 19800 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 19801 fi 19802 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 19803 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 19804 else 19805 # Not relevant for non-Windows 19806 IS_MAKE_CORRECT_ENV=true 19807 fi 19808 if test "x$IS_MAKE_CORRECT_ENV" = x; then 19809 { $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 19810 $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;} 19811 else 19812 FOUND_MAKE=$MAKE_CANDIDATE 19813 19814 # Only process if variable expands to non-empty 19815 19816 if test "x$FOUND_MAKE" != x; then 19817 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19818 19819 # First separate the path from the arguments. This will split at the first 19820 # space. 19821 complete="$FOUND_MAKE" 19822 path="${complete%% *}" 19823 tmp="$complete EOL" 19824 arguments="${tmp#* }" 19825 19826 # Input might be given as Windows format, start by converting to 19827 # unix format. 19828 new_path=`$CYGPATH -u "$path"` 19829 19830 # Now try to locate executable using which 19831 new_path=`$WHICH "$new_path" 2> /dev/null` 19832 # bat and cmd files are not always considered executable in cygwin causing which 19833 # to not find them 19834 if test "x$new_path" = x \ 19835 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19836 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19837 new_path=`$CYGPATH -u "$path"` 19838 fi 19839 if test "x$new_path" = x; then 19840 # Oops. Which didn't find the executable. 19841 # The splitting of arguments from the executable at a space might have been incorrect, 19842 # since paths with space are more likely in Windows. Give it another try with the whole 19843 # argument. 19844 path="$complete" 19845 arguments="EOL" 19846 new_path=`$CYGPATH -u "$path"` 19847 new_path=`$WHICH "$new_path" 2> /dev/null` 19848 # bat and cmd files are not always considered executable in cygwin causing which 19849 # to not find them 19850 if test "x$new_path" = x \ 19851 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19852 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19853 new_path=`$CYGPATH -u "$path"` 19854 fi 19855 if test "x$new_path" = x; then 19856 # It's still not found. Now this is an unrecoverable error. 19857 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19858 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19859 has_space=`$ECHO "$complete" | $GREP " "` 19860 if test "x$has_space" != x; then 19861 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19862 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19863 fi 19864 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19865 fi 19866 fi 19867 19868 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 19869 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 19870 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 19871 # "foo.exe" is OK but "foo" is an error. 19872 # 19873 # This test is therefore slightly more accurate than "test -f" to check for file presence. 19874 # It is also a way to make sure we got the proper file name for the real test later on. 19875 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 19876 if test "x$test_shortpath" = x; then 19877 # Short path failed, file does not exist as specified. 19878 # Try adding .exe or .cmd 19879 if test -f "${new_path}.exe"; then 19880 input_to_shortpath="${new_path}.exe" 19881 elif test -f "${new_path}.cmd"; then 19882 input_to_shortpath="${new_path}.cmd" 19883 else 19884 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 19885 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 19886 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 19887 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 19888 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19889 fi 19890 else 19891 input_to_shortpath="$new_path" 19892 fi 19893 19894 # Call helper function which possibly converts this using DOS-style short mode. 19895 # If so, the updated path is stored in $new_path. 19896 new_path="$input_to_shortpath" 19897 19898 input_path="$input_to_shortpath" 19899 # Check if we need to convert this using DOS-style short mode. If the path 19900 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19901 # take no chances and rewrite it. 19902 # Note: m4 eats our [], so we need to use [ and ] instead. 19903 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 19904 if test "x$has_forbidden_chars" != x; then 19905 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19906 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 19907 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 19908 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 19909 # Going to short mode and back again did indeed matter. Since short mode is 19910 # case insensitive, let's make it lowercase to improve readability. 19911 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19912 # Now convert it back to Unix-style (cygpath) 19913 input_path=`$CYGPATH -u "$shortmode_path"` 19914 new_path="$input_path" 19915 fi 19916 fi 19917 19918 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 19919 if test "x$test_cygdrive_prefix" = x; then 19920 # As a simple fix, exclude /usr/bin since it's not a real path. 19921 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 19922 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 19923 # a path prefixed by /cygdrive for fixpath to work. 19924 new_path="$CYGWIN_ROOT_PATH$input_path" 19925 fi 19926 fi 19927 19928 # remove trailing .exe if any 19929 new_path="${new_path/%.exe/}" 19930 19931 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19932 19933 # First separate the path from the arguments. This will split at the first 19934 # space. 19935 complete="$FOUND_MAKE" 19936 path="${complete%% *}" 19937 tmp="$complete EOL" 19938 arguments="${tmp#* }" 19939 19940 # Input might be given as Windows format, start by converting to 19941 # unix format. 19942 new_path="$path" 19943 19944 windows_path="$new_path" 19945 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19946 unix_path=`$CYGPATH -u "$windows_path"` 19947 new_path="$unix_path" 19948 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19949 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19950 new_path="$unix_path" 19951 fi 19952 19953 19954 # Now try to locate executable using which 19955 new_path=`$WHICH "$new_path" 2> /dev/null` 19956 19957 if test "x$new_path" = x; then 19958 # Oops. Which didn't find the executable. 19959 # The splitting of arguments from the executable at a space might have been incorrect, 19960 # since paths with space are more likely in Windows. Give it another try with the whole 19961 # argument. 19962 path="$complete" 19963 arguments="EOL" 19964 new_path="$path" 19965 19966 windows_path="$new_path" 19967 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19968 unix_path=`$CYGPATH -u "$windows_path"` 19969 new_path="$unix_path" 19970 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19971 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19972 new_path="$unix_path" 19973 fi 19974 19975 19976 new_path=`$WHICH "$new_path" 2> /dev/null` 19977 # bat and cmd files are not always considered executable in MSYS causing which 19978 # to not find them 19979 if test "x$new_path" = x \ 19980 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19981 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19982 new_path="$path" 19983 19984 windows_path="$new_path" 19985 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19986 unix_path=`$CYGPATH -u "$windows_path"` 19987 new_path="$unix_path" 19988 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19989 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19990 new_path="$unix_path" 19991 fi 19992 19993 fi 19994 19995 if test "x$new_path" = x; then 19996 # It's still not found. Now this is an unrecoverable error. 19997 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19998 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19999 has_space=`$ECHO "$complete" | $GREP " "` 20000 if test "x$has_space" != x; then 20001 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20002 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20003 fi 20004 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20005 fi 20006 fi 20007 20008 # Now new_path has a complete unix path to the binary 20009 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 20010 # Keep paths in /bin as-is, but remove trailing .exe if any 20011 new_path="${new_path/%.exe/}" 20012 # Do not save /bin paths to all_fixpath_prefixes! 20013 else 20014 # Not in mixed or Windows style, start by that. 20015 new_path=`cmd //c echo $new_path` 20016 20017 input_path="$new_path" 20018 # Check if we need to convert this using DOS-style short mode. If the path 20019 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20020 # take no chances and rewrite it. 20021 # Note: m4 eats our [], so we need to use [ and ] instead. 20022 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 20023 if test "x$has_forbidden_chars" != x; then 20024 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20025 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20026 fi 20027 20028 # Output is in $new_path 20029 20030 windows_path="$new_path" 20031 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20032 unix_path=`$CYGPATH -u "$windows_path"` 20033 new_path="$unix_path" 20034 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20035 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20036 new_path="$unix_path" 20037 fi 20038 20039 # remove trailing .exe if any 20040 new_path="${new_path/%.exe/}" 20041 20042 # Save the first 10 bytes of this path to the storage, so fixpath can work. 20043 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 20044 fi 20045 20046 else 20047 # We're on a unix platform. Hooray! :) 20048 # First separate the path from the arguments. This will split at the first 20049 # space. 20050 complete="$FOUND_MAKE" 20051 path="${complete%% *}" 20052 tmp="$complete EOL" 20053 arguments="${tmp#* }" 20054 20055 # Cannot rely on the command "which" here since it doesn't always work. 20056 is_absolute_path=`$ECHO "$path" | $GREP ^/` 20057 if test -z "$is_absolute_path"; then 20058 # Path to executable is not absolute. Find it. 20059 IFS_save="$IFS" 20060 IFS=: 20061 for p in $PATH; do 20062 if test -f "$p/$path" && test -x "$p/$path"; then 20063 new_path="$p/$path" 20064 break 20065 fi 20066 done 20067 IFS="$IFS_save" 20068 else 20069 # This is an absolute path, we can use it without further modifications. 20070 new_path="$path" 20071 fi 20072 20073 if test "x$new_path" = x; then 20074 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20075 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20076 has_space=`$ECHO "$complete" | $GREP " "` 20077 if test "x$has_space" != x; then 20078 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 20079 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 20080 fi 20081 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20082 fi 20083 fi 20084 20085 # Now join together the path and the arguments once again 20086 if test "x$arguments" != xEOL; then 20087 new_complete="$new_path ${arguments% *}" 20088 else 20089 new_complete="$new_path" 20090 fi 20091 20092 if test "x$complete" != "x$new_complete"; then 20093 FOUND_MAKE="$new_complete" 20094 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 20095 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 20096 fi 20097 fi 20098 20099 fi 20100 fi 20101 fi 20102 fi 20103 20104 fi 20105 20106 if test "x$FOUND_MAKE" = x; then 20107 if test "x$TOOLCHAIN_PATH" != x; then 20108 # We have a toolchain path, check that as well before giving up. 20109 OLD_PATH=$PATH 20110 PATH=$TOOLCHAIN_PATH:$PATH 20111 for ac_prog in gmake 20112 do 20113 # Extract the first word of "$ac_prog", so it can be a program name with args. 20114 set dummy $ac_prog; ac_word=$2 20115 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 20116 $as_echo_n "checking for $ac_word... " >&6; } 20117 if ${ac_cv_path_CHECK_TOOLSDIR_GMAKE+:} false; then : 20118 $as_echo_n "(cached) " >&6 20119 else 20120 case $CHECK_TOOLSDIR_GMAKE in 20121 [\\/]* | ?:[\\/]*) 20122 ac_cv_path_CHECK_TOOLSDIR_GMAKE="$CHECK_TOOLSDIR_GMAKE" # Let the user override the test with a path. 20123 ;; 20124 *) 20125 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 20126 for as_dir in $PATH 20127 do 20128 IFS=$as_save_IFS 20129 test -z "$as_dir" && as_dir=. 20130 for ac_exec_ext in '' $ac_executable_extensions; do 20131 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 20132 ac_cv_path_CHECK_TOOLSDIR_GMAKE="$as_dir/$ac_word$ac_exec_ext" 20133 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 20134 break 2 20135 fi 20136 done 20137 done 20138 IFS=$as_save_IFS 20139 20140 ;; 20141 esac 20142 fi 20143 CHECK_TOOLSDIR_GMAKE=$ac_cv_path_CHECK_TOOLSDIR_GMAKE 20144 if test -n "$CHECK_TOOLSDIR_GMAKE"; then 20145 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_GMAKE" >&5 20146 $as_echo "$CHECK_TOOLSDIR_GMAKE" >&6; } 20147 else 20148 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 20149 $as_echo "no" >&6; } 20150 fi 20151 20152 20153 test -n "$CHECK_TOOLSDIR_GMAKE" && break 20154 done 20155 20156 20157 MAKE_CANDIDATE=""$CHECK_TOOLSDIR_GMAKE"" 20158 DESCRIPTION="gmake in tools-dir" 20159 20160 # On Cygwin, we require a newer version of make than on other platforms 20161 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20162 MAKE_VERSION_EXPR="-e 4\." 20163 MAKE_REQUIRED_VERSION="4.0" 20164 else 20165 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 20166 MAKE_REQUIRED_VERSION="3.81" 20167 fi 20168 20169 if test "x$MAKE_CANDIDATE" != x; then 20170 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 20171 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 20172 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 20173 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 20174 if test "x$IS_GNU_MAKE" = x; then 20175 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 20176 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 20177 else 20178 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 20179 if test "x$IS_MODERN_MAKE" = x; then 20180 { $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 20181 $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;} 20182 else 20183 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 20184 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20185 MAKE_EXPECTED_ENV='cygwin' 20186 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20187 MAKE_EXPECTED_ENV='msys' 20188 else 20189 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 20190 fi 20191 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 20192 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 20193 else 20194 # Not relevant for non-Windows 20195 IS_MAKE_CORRECT_ENV=true 20196 fi 20197 if test "x$IS_MAKE_CORRECT_ENV" = x; then 20198 { $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 20199 $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;} 20200 else 20201 FOUND_MAKE=$MAKE_CANDIDATE 20202 20203 # Only process if variable expands to non-empty 20204 20205 if test "x$FOUND_MAKE" != x; then 20206 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20207 20208 # First separate the path from the arguments. This will split at the first 20209 # space. 20210 complete="$FOUND_MAKE" 20211 path="${complete%% *}" 20212 tmp="$complete EOL" 20213 arguments="${tmp#* }" 20214 20215 # Input might be given as Windows format, start by converting to 20216 # unix format. 20217 new_path=`$CYGPATH -u "$path"` 20218 20219 # Now try to locate executable using which 20220 new_path=`$WHICH "$new_path" 2> /dev/null` 20221 # bat and cmd files are not always considered executable in cygwin causing which 20222 # to not find them 20223 if test "x$new_path" = x \ 20224 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20225 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20226 new_path=`$CYGPATH -u "$path"` 20227 fi 20228 if test "x$new_path" = x; then 20229 # Oops. Which didn't find the executable. 20230 # The splitting of arguments from the executable at a space might have been incorrect, 20231 # since paths with space are more likely in Windows. Give it another try with the whole 20232 # argument. 20233 path="$complete" 20234 arguments="EOL" 20235 new_path=`$CYGPATH -u "$path"` 20236 new_path=`$WHICH "$new_path" 2> /dev/null` 20237 # bat and cmd files are not always considered executable in cygwin causing which 20238 # to not find them 20239 if test "x$new_path" = x \ 20240 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20241 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20242 new_path=`$CYGPATH -u "$path"` 20243 fi 20244 if test "x$new_path" = x; then 20245 # It's still not found. Now this is an unrecoverable error. 20246 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20247 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20248 has_space=`$ECHO "$complete" | $GREP " "` 20249 if test "x$has_space" != x; then 20250 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20251 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20252 fi 20253 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20254 fi 20255 fi 20256 20257 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 20258 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 20259 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 20260 # "foo.exe" is OK but "foo" is an error. 20261 # 20262 # This test is therefore slightly more accurate than "test -f" to check for file presence. 20263 # It is also a way to make sure we got the proper file name for the real test later on. 20264 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 20265 if test "x$test_shortpath" = x; then 20266 # Short path failed, file does not exist as specified. 20267 # Try adding .exe or .cmd 20268 if test -f "${new_path}.exe"; then 20269 input_to_shortpath="${new_path}.exe" 20270 elif test -f "${new_path}.cmd"; then 20271 input_to_shortpath="${new_path}.cmd" 20272 else 20273 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 20274 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 20275 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 20276 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 20277 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20278 fi 20279 else 20280 input_to_shortpath="$new_path" 20281 fi 20282 20283 # Call helper function which possibly converts this using DOS-style short mode. 20284 # If so, the updated path is stored in $new_path. 20285 new_path="$input_to_shortpath" 20286 20287 input_path="$input_to_shortpath" 20288 # Check if we need to convert this using DOS-style short mode. If the path 20289 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20290 # take no chances and rewrite it. 20291 # Note: m4 eats our [], so we need to use [ and ] instead. 20292 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 20293 if test "x$has_forbidden_chars" != x; then 20294 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20295 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 20296 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 20297 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 20298 # Going to short mode and back again did indeed matter. Since short mode is 20299 # case insensitive, let's make it lowercase to improve readability. 20300 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20301 # Now convert it back to Unix-style (cygpath) 20302 input_path=`$CYGPATH -u "$shortmode_path"` 20303 new_path="$input_path" 20304 fi 20305 fi 20306 20307 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 20308 if test "x$test_cygdrive_prefix" = x; then 20309 # As a simple fix, exclude /usr/bin since it's not a real path. 20310 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 20311 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 20312 # a path prefixed by /cygdrive for fixpath to work. 20313 new_path="$CYGWIN_ROOT_PATH$input_path" 20314 fi 20315 fi 20316 20317 # remove trailing .exe if any 20318 new_path="${new_path/%.exe/}" 20319 20320 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20321 20322 # First separate the path from the arguments. This will split at the first 20323 # space. 20324 complete="$FOUND_MAKE" 20325 path="${complete%% *}" 20326 tmp="$complete EOL" 20327 arguments="${tmp#* }" 20328 20329 # Input might be given as Windows format, start by converting to 20330 # unix format. 20331 new_path="$path" 20332 20333 windows_path="$new_path" 20334 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20335 unix_path=`$CYGPATH -u "$windows_path"` 20336 new_path="$unix_path" 20337 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20338 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20339 new_path="$unix_path" 20340 fi 20341 20342 20343 # Now try to locate executable using which 20344 new_path=`$WHICH "$new_path" 2> /dev/null` 20345 20346 if test "x$new_path" = x; then 20347 # Oops. Which didn't find the executable. 20348 # The splitting of arguments from the executable at a space might have been incorrect, 20349 # since paths with space are more likely in Windows. Give it another try with the whole 20350 # argument. 20351 path="$complete" 20352 arguments="EOL" 20353 new_path="$path" 20354 20355 windows_path="$new_path" 20356 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20357 unix_path=`$CYGPATH -u "$windows_path"` 20358 new_path="$unix_path" 20359 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20360 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20361 new_path="$unix_path" 20362 fi 20363 20364 20365 new_path=`$WHICH "$new_path" 2> /dev/null` 20366 # bat and cmd files are not always considered executable in MSYS causing which 20367 # to not find them 20368 if test "x$new_path" = x \ 20369 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20370 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20371 new_path="$path" 20372 20373 windows_path="$new_path" 20374 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20375 unix_path=`$CYGPATH -u "$windows_path"` 20376 new_path="$unix_path" 20377 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20378 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20379 new_path="$unix_path" 20380 fi 20381 20382 fi 20383 20384 if test "x$new_path" = x; then 20385 # It's still not found. Now this is an unrecoverable error. 20386 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20387 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20388 has_space=`$ECHO "$complete" | $GREP " "` 20389 if test "x$has_space" != x; then 20390 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20391 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20392 fi 20393 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20394 fi 20395 fi 20396 20397 # Now new_path has a complete unix path to the binary 20398 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 20399 # Keep paths in /bin as-is, but remove trailing .exe if any 20400 new_path="${new_path/%.exe/}" 20401 # Do not save /bin paths to all_fixpath_prefixes! 20402 else 20403 # Not in mixed or Windows style, start by that. 20404 new_path=`cmd //c echo $new_path` 20405 20406 input_path="$new_path" 20407 # Check if we need to convert this using DOS-style short mode. If the path 20408 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20409 # take no chances and rewrite it. 20410 # Note: m4 eats our [], so we need to use [ and ] instead. 20411 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 20412 if test "x$has_forbidden_chars" != x; then 20413 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20414 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20415 fi 20416 20417 # Output is in $new_path 20418 20419 windows_path="$new_path" 20420 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20421 unix_path=`$CYGPATH -u "$windows_path"` 20422 new_path="$unix_path" 20423 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20424 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20425 new_path="$unix_path" 20426 fi 20427 20428 # remove trailing .exe if any 20429 new_path="${new_path/%.exe/}" 20430 20431 # Save the first 10 bytes of this path to the storage, so fixpath can work. 20432 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 20433 fi 20434 20435 else 20436 # We're on a unix platform. Hooray! :) 20437 # First separate the path from the arguments. This will split at the first 20438 # space. 20439 complete="$FOUND_MAKE" 20440 path="${complete%% *}" 20441 tmp="$complete EOL" 20442 arguments="${tmp#* }" 20443 20444 # Cannot rely on the command "which" here since it doesn't always work. 20445 is_absolute_path=`$ECHO "$path" | $GREP ^/` 20446 if test -z "$is_absolute_path"; then 20447 # Path to executable is not absolute. Find it. 20448 IFS_save="$IFS" 20449 IFS=: 20450 for p in $PATH; do 20451 if test -f "$p/$path" && test -x "$p/$path"; then 20452 new_path="$p/$path" 20453 break 20454 fi 20455 done 20456 IFS="$IFS_save" 20457 else 20458 # This is an absolute path, we can use it without further modifications. 20459 new_path="$path" 20460 fi 20461 20462 if test "x$new_path" = x; then 20463 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20464 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20465 has_space=`$ECHO "$complete" | $GREP " "` 20466 if test "x$has_space" != x; then 20467 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 20468 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 20469 fi 20470 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20471 fi 20472 fi 20473 20474 # Now join together the path and the arguments once again 20475 if test "x$arguments" != xEOL; then 20476 new_complete="$new_path ${arguments% *}" 20477 else 20478 new_complete="$new_path" 20479 fi 20480 20481 if test "x$complete" != "x$new_complete"; then 20482 FOUND_MAKE="$new_complete" 20483 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 20484 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 20485 fi 20486 fi 20487 20488 fi 20489 fi 20490 fi 20491 fi 20492 20493 if test "x$FOUND_MAKE" = x; then 20494 for ac_prog in make 20495 do 20496 # Extract the first word of "$ac_prog", so it can be a program name with args. 20497 set dummy $ac_prog; ac_word=$2 20498 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 20499 $as_echo_n "checking for $ac_word... " >&6; } 20500 if ${ac_cv_path_CHECK_TOOLSDIR_MAKE+:} false; then : 20501 $as_echo_n "(cached) " >&6 20502 else 20503 case $CHECK_TOOLSDIR_MAKE in 20504 [\\/]* | ?:[\\/]*) 20505 ac_cv_path_CHECK_TOOLSDIR_MAKE="$CHECK_TOOLSDIR_MAKE" # Let the user override the test with a path. 20506 ;; 20507 *) 20508 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 20509 for as_dir in $PATH 20510 do 20511 IFS=$as_save_IFS 20512 test -z "$as_dir" && as_dir=. 20513 for ac_exec_ext in '' $ac_executable_extensions; do 20514 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 20515 ac_cv_path_CHECK_TOOLSDIR_MAKE="$as_dir/$ac_word$ac_exec_ext" 20516 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 20517 break 2 20518 fi 20519 done 20520 done 20521 IFS=$as_save_IFS 20522 20523 ;; 20524 esac 20525 fi 20526 CHECK_TOOLSDIR_MAKE=$ac_cv_path_CHECK_TOOLSDIR_MAKE 20527 if test -n "$CHECK_TOOLSDIR_MAKE"; then 20528 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_MAKE" >&5 20529 $as_echo "$CHECK_TOOLSDIR_MAKE" >&6; } 20530 else 20531 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 20532 $as_echo "no" >&6; } 20533 fi 20534 20535 20536 test -n "$CHECK_TOOLSDIR_MAKE" && break 20537 done 20538 20539 20540 MAKE_CANDIDATE=""$CHECK_TOOLSDIR_MAKE"" 20541 DESCRIPTION="make in tools-dir" 20542 20543 # On Cygwin, we require a newer version of make than on other platforms 20544 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20545 MAKE_VERSION_EXPR="-e 4\." 20546 MAKE_REQUIRED_VERSION="4.0" 20547 else 20548 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 20549 MAKE_REQUIRED_VERSION="3.81" 20550 fi 20551 20552 if test "x$MAKE_CANDIDATE" != x; then 20553 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 20554 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 20555 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 20556 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 20557 if test "x$IS_GNU_MAKE" = x; then 20558 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 20559 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 20560 else 20561 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 20562 if test "x$IS_MODERN_MAKE" = x; then 20563 { $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 20564 $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;} 20565 else 20566 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 20567 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20568 MAKE_EXPECTED_ENV='cygwin' 20569 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20570 MAKE_EXPECTED_ENV='msys' 20571 else 20572 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 20573 fi 20574 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 20575 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 20576 else 20577 # Not relevant for non-Windows 20578 IS_MAKE_CORRECT_ENV=true 20579 fi 20580 if test "x$IS_MAKE_CORRECT_ENV" = x; then 20581 { $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 20582 $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;} 20583 else 20584 FOUND_MAKE=$MAKE_CANDIDATE 20585 20586 # Only process if variable expands to non-empty 20587 20588 if test "x$FOUND_MAKE" != x; then 20589 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20590 20591 # First separate the path from the arguments. This will split at the first 20592 # space. 20593 complete="$FOUND_MAKE" 20594 path="${complete%% *}" 20595 tmp="$complete EOL" 20596 arguments="${tmp#* }" 20597 20598 # Input might be given as Windows format, start by converting to 20599 # unix format. 20600 new_path=`$CYGPATH -u "$path"` 20601 20602 # Now try to locate executable using which 20603 new_path=`$WHICH "$new_path" 2> /dev/null` 20604 # bat and cmd files are not always considered executable in cygwin causing which 20605 # to not find them 20606 if test "x$new_path" = x \ 20607 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20608 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20609 new_path=`$CYGPATH -u "$path"` 20610 fi 20611 if test "x$new_path" = x; then 20612 # Oops. Which didn't find the executable. 20613 # The splitting of arguments from the executable at a space might have been incorrect, 20614 # since paths with space are more likely in Windows. Give it another try with the whole 20615 # argument. 20616 path="$complete" 20617 arguments="EOL" 20618 new_path=`$CYGPATH -u "$path"` 20619 new_path=`$WHICH "$new_path" 2> /dev/null` 20620 # bat and cmd files are not always considered executable in cygwin causing which 20621 # to not find them 20622 if test "x$new_path" = x \ 20623 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20624 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20625 new_path=`$CYGPATH -u "$path"` 20626 fi 20627 if test "x$new_path" = x; then 20628 # It's still not found. Now this is an unrecoverable error. 20629 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20630 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20631 has_space=`$ECHO "$complete" | $GREP " "` 20632 if test "x$has_space" != x; then 20633 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20634 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20635 fi 20636 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20637 fi 20638 fi 20639 20640 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 20641 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 20642 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 20643 # "foo.exe" is OK but "foo" is an error. 20644 # 20645 # This test is therefore slightly more accurate than "test -f" to check for file presence. 20646 # It is also a way to make sure we got the proper file name for the real test later on. 20647 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 20648 if test "x$test_shortpath" = x; then 20649 # Short path failed, file does not exist as specified. 20650 # Try adding .exe or .cmd 20651 if test -f "${new_path}.exe"; then 20652 input_to_shortpath="${new_path}.exe" 20653 elif test -f "${new_path}.cmd"; then 20654 input_to_shortpath="${new_path}.cmd" 20655 else 20656 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 20657 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 20658 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 20659 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 20660 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20661 fi 20662 else 20663 input_to_shortpath="$new_path" 20664 fi 20665 20666 # Call helper function which possibly converts this using DOS-style short mode. 20667 # If so, the updated path is stored in $new_path. 20668 new_path="$input_to_shortpath" 20669 20670 input_path="$input_to_shortpath" 20671 # Check if we need to convert this using DOS-style short mode. If the path 20672 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20673 # take no chances and rewrite it. 20674 # Note: m4 eats our [], so we need to use [ and ] instead. 20675 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 20676 if test "x$has_forbidden_chars" != x; then 20677 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20678 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 20679 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 20680 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 20681 # Going to short mode and back again did indeed matter. Since short mode is 20682 # case insensitive, let's make it lowercase to improve readability. 20683 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20684 # Now convert it back to Unix-style (cygpath) 20685 input_path=`$CYGPATH -u "$shortmode_path"` 20686 new_path="$input_path" 20687 fi 20688 fi 20689 20690 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 20691 if test "x$test_cygdrive_prefix" = x; then 20692 # As a simple fix, exclude /usr/bin since it's not a real path. 20693 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 20694 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 20695 # a path prefixed by /cygdrive for fixpath to work. 20696 new_path="$CYGWIN_ROOT_PATH$input_path" 20697 fi 20698 fi 20699 20700 # remove trailing .exe if any 20701 new_path="${new_path/%.exe/}" 20702 20703 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20704 20705 # First separate the path from the arguments. This will split at the first 20706 # space. 20707 complete="$FOUND_MAKE" 20708 path="${complete%% *}" 20709 tmp="$complete EOL" 20710 arguments="${tmp#* }" 20711 20712 # Input might be given as Windows format, start by converting to 20713 # unix format. 20714 new_path="$path" 20715 20716 windows_path="$new_path" 20717 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20718 unix_path=`$CYGPATH -u "$windows_path"` 20719 new_path="$unix_path" 20720 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20721 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20722 new_path="$unix_path" 20723 fi 20724 20725 20726 # Now try to locate executable using which 20727 new_path=`$WHICH "$new_path" 2> /dev/null` 20728 20729 if test "x$new_path" = x; then 20730 # Oops. Which didn't find the executable. 20731 # The splitting of arguments from the executable at a space might have been incorrect, 20732 # since paths with space are more likely in Windows. Give it another try with the whole 20733 # argument. 20734 path="$complete" 20735 arguments="EOL" 20736 new_path="$path" 20737 20738 windows_path="$new_path" 20739 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20740 unix_path=`$CYGPATH -u "$windows_path"` 20741 new_path="$unix_path" 20742 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20743 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20744 new_path="$unix_path" 20745 fi 20746 20747 20748 new_path=`$WHICH "$new_path" 2> /dev/null` 20749 # bat and cmd files are not always considered executable in MSYS causing which 20750 # to not find them 20751 if test "x$new_path" = x \ 20752 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20753 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20754 new_path="$path" 20755 20756 windows_path="$new_path" 20757 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20758 unix_path=`$CYGPATH -u "$windows_path"` 20759 new_path="$unix_path" 20760 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20761 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20762 new_path="$unix_path" 20763 fi 20764 20765 fi 20766 20767 if test "x$new_path" = x; then 20768 # It's still not found. Now this is an unrecoverable error. 20769 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20770 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20771 has_space=`$ECHO "$complete" | $GREP " "` 20772 if test "x$has_space" != x; then 20773 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20774 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20775 fi 20776 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20777 fi 20778 fi 20779 20780 # Now new_path has a complete unix path to the binary 20781 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 20782 # Keep paths in /bin as-is, but remove trailing .exe if any 20783 new_path="${new_path/%.exe/}" 20784 # Do not save /bin paths to all_fixpath_prefixes! 20785 else 20786 # Not in mixed or Windows style, start by that. 20787 new_path=`cmd //c echo $new_path` 20788 20789 input_path="$new_path" 20790 # Check if we need to convert this using DOS-style short mode. If the path 20791 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20792 # take no chances and rewrite it. 20793 # Note: m4 eats our [], so we need to use [ and ] instead. 20794 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 20795 if test "x$has_forbidden_chars" != x; then 20796 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20797 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20798 fi 20799 20800 # Output is in $new_path 20801 20802 windows_path="$new_path" 20803 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20804 unix_path=`$CYGPATH -u "$windows_path"` 20805 new_path="$unix_path" 20806 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20807 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20808 new_path="$unix_path" 20809 fi 20810 20811 # remove trailing .exe if any 20812 new_path="${new_path/%.exe/}" 20813 20814 # Save the first 10 bytes of this path to the storage, so fixpath can work. 20815 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 20816 fi 20817 20818 else 20819 # We're on a unix platform. Hooray! :) 20820 # First separate the path from the arguments. This will split at the first 20821 # space. 20822 complete="$FOUND_MAKE" 20823 path="${complete%% *}" 20824 tmp="$complete EOL" 20825 arguments="${tmp#* }" 20826 20827 # Cannot rely on the command "which" here since it doesn't always work. 20828 is_absolute_path=`$ECHO "$path" | $GREP ^/` 20829 if test -z "$is_absolute_path"; then 20830 # Path to executable is not absolute. Find it. 20831 IFS_save="$IFS" 20832 IFS=: 20833 for p in $PATH; do 20834 if test -f "$p/$path" && test -x "$p/$path"; then 20835 new_path="$p/$path" 20836 break 20837 fi 20838 done 20839 IFS="$IFS_save" 20840 else 20841 # This is an absolute path, we can use it without further modifications. 20842 new_path="$path" 20843 fi 20844 20845 if test "x$new_path" = x; then 20846 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20847 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20848 has_space=`$ECHO "$complete" | $GREP " "` 20849 if test "x$has_space" != x; then 20850 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 20851 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 20852 fi 20853 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20854 fi 20855 fi 20856 20857 # Now join together the path and the arguments once again 20858 if test "x$arguments" != xEOL; then 20859 new_complete="$new_path ${arguments% *}" 20860 else 20861 new_complete="$new_path" 20862 fi 20863 20864 if test "x$complete" != "x$new_complete"; then 20865 FOUND_MAKE="$new_complete" 20866 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 20867 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 20868 fi 20869 fi 20870 20871 fi 20872 fi 20873 fi 20874 fi 20875 20876 fi 20877 PATH=$OLD_PATH 20878 fi 20879 fi 20880 20881 if test "x$FOUND_MAKE" = x; then 20882 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 20883 fi 20884 20885 else 20886 # If it succeeded, then it was overridden by the user. We will use it 20887 # for the tool. 20888 20889 # First remove it from the list of overridden variables, so we can test 20890 # for unknown variables in the end. 20891 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 20892 20893 # Check if we try to supply an empty value 20894 if test "x$MAKE" = x; then 20895 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool MAKE= (no value)" >&5 20896 $as_echo "$as_me: Setting user supplied tool MAKE= (no value)" >&6;} 20897 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MAKE" >&5 20898 $as_echo_n "checking for MAKE... " >&6; } 20899 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 20900 $as_echo "disabled" >&6; } 20901 else 20902 # Check if the provided tool contains a complete path. 20903 tool_specified="$MAKE" 20904 tool_basename="${tool_specified##*/}" 20905 if test "x$tool_basename" = "x$tool_specified"; then 20906 # A command without a complete path is provided, search $PATH. 20907 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MAKE=$tool_basename" >&5 20908 $as_echo "$as_me: Will search for user supplied tool MAKE=$tool_basename" >&6;} 20909 # Extract the first word of "$tool_basename", so it can be a program name with args. 20910 set dummy $tool_basename; ac_word=$2 20911 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 20912 $as_echo_n "checking for $ac_word... " >&6; } 20913 if ${ac_cv_path_MAKE+:} false; then : 20914 $as_echo_n "(cached) " >&6 20915 else 20916 case $MAKE in 20917 [\\/]* | ?:[\\/]*) 20918 ac_cv_path_MAKE="$MAKE" # Let the user override the test with a path. 20919 ;; 20920 *) 20921 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 20922 for as_dir in $PATH 20923 do 20924 IFS=$as_save_IFS 20925 test -z "$as_dir" && as_dir=. 20926 for ac_exec_ext in '' $ac_executable_extensions; do 20927 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 20928 ac_cv_path_MAKE="$as_dir/$ac_word$ac_exec_ext" 20929 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 20930 break 2 20931 fi 20932 done 20933 done 20934 IFS=$as_save_IFS 20935 20936 ;; 20937 esac 20938 fi 20939 MAKE=$ac_cv_path_MAKE 20940 if test -n "$MAKE"; then 20941 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKE" >&5 20942 $as_echo "$MAKE" >&6; } 20943 else 20944 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 20945 $as_echo "no" >&6; } 20946 fi 20947 20948 20949 if test "x$MAKE" = x; then 20950 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 20951 fi 20952 else 20953 # Otherwise we believe it is a complete path. Use it as it is. 20954 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MAKE=$tool_specified" >&5 20955 $as_echo "$as_me: Will use user supplied tool MAKE=$tool_specified" >&6;} 20956 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MAKE" >&5 20957 $as_echo_n "checking for MAKE... " >&6; } 20958 if test ! -x "$tool_specified"; then 20959 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 20960 $as_echo "not found" >&6; } 20961 as_fn_error $? "User supplied tool MAKE=$tool_specified does not exist or is not executable" "$LINENO" 5 20962 fi 20963 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 20964 $as_echo "$tool_specified" >&6; } 20965 fi 20966 fi 20967 fi 20968 20969 # If MAKE was set by user, verify the version 20970 20971 MAKE_CANDIDATE=""$MAKE"" 20972 DESCRIPTION="user supplied MAKE=$MAKE" 20973 20974 # On Cygwin, we require a newer version of make than on other platforms 20975 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20976 MAKE_VERSION_EXPR="-e 4\." 20977 MAKE_REQUIRED_VERSION="4.0" 20978 else 20979 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 20980 MAKE_REQUIRED_VERSION="3.81" 20981 fi 20982 20983 if test "x$MAKE_CANDIDATE" != x; then 20984 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 20985 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 20986 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 20987 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 20988 if test "x$IS_GNU_MAKE" = x; then 20989 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 20990 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 20991 else 20992 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 20993 if test "x$IS_MODERN_MAKE" = x; then 20994 { $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 20995 $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;} 20996 else 20997 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 20998 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20999 MAKE_EXPECTED_ENV='cygwin' 21000 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 21001 MAKE_EXPECTED_ENV='msys' 21002 else 21003 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 21004 fi 21005 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 21006 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 21007 else 21008 # Not relevant for non-Windows 21009 IS_MAKE_CORRECT_ENV=true 21010 fi 21011 if test "x$IS_MAKE_CORRECT_ENV" = x; then 21012 { $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 21013 $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;} 21014 else 21015 FOUND_MAKE=$MAKE_CANDIDATE 21016 21017 # Only process if variable expands to non-empty 21018 21019 if test "x$FOUND_MAKE" != x; then 21020 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 21021 21022 # First separate the path from the arguments. This will split at the first 21023 # space. 21024 complete="$FOUND_MAKE" 21025 path="${complete%% *}" 21026 tmp="$complete EOL" 21027 arguments="${tmp#* }" 21028 21029 # Input might be given as Windows format, start by converting to 21030 # unix format. 21031 new_path=`$CYGPATH -u "$path"` 21032 21033 # Now try to locate executable using which 21034 new_path=`$WHICH "$new_path" 2> /dev/null` 21035 # bat and cmd files are not always considered executable in cygwin causing which 21036 # to not find them 21037 if test "x$new_path" = x \ 21038 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 21039 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 21040 new_path=`$CYGPATH -u "$path"` 21041 fi 21042 if test "x$new_path" = x; then 21043 # Oops. Which didn't find the executable. 21044 # The splitting of arguments from the executable at a space might have been incorrect, 21045 # since paths with space are more likely in Windows. Give it another try with the whole 21046 # argument. 21047 path="$complete" 21048 arguments="EOL" 21049 new_path=`$CYGPATH -u "$path"` 21050 new_path=`$WHICH "$new_path" 2> /dev/null` 21051 # bat and cmd files are not always considered executable in cygwin causing which 21052 # to not find them 21053 if test "x$new_path" = x \ 21054 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 21055 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 21056 new_path=`$CYGPATH -u "$path"` 21057 fi 21058 if test "x$new_path" = x; then 21059 # It's still not found. Now this is an unrecoverable error. 21060 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 21061 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 21062 has_space=`$ECHO "$complete" | $GREP " "` 21063 if test "x$has_space" != x; then 21064 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 21065 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 21066 fi 21067 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 21068 fi 21069 fi 21070 21071 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 21072 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 21073 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 21074 # "foo.exe" is OK but "foo" is an error. 21075 # 21076 # This test is therefore slightly more accurate than "test -f" to check for file presence. 21077 # It is also a way to make sure we got the proper file name for the real test later on. 21078 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 21079 if test "x$test_shortpath" = x; then 21080 # Short path failed, file does not exist as specified. 21081 # Try adding .exe or .cmd 21082 if test -f "${new_path}.exe"; then 21083 input_to_shortpath="${new_path}.exe" 21084 elif test -f "${new_path}.cmd"; then 21085 input_to_shortpath="${new_path}.cmd" 21086 else 21087 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 21088 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 21089 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 21090 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 21091 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 21092 fi 21093 else 21094 input_to_shortpath="$new_path" 21095 fi 21096 21097 # Call helper function which possibly converts this using DOS-style short mode. 21098 # If so, the updated path is stored in $new_path. 21099 new_path="$input_to_shortpath" 21100 21101 input_path="$input_to_shortpath" 21102 # Check if we need to convert this using DOS-style short mode. If the path 21103 # contains just simple characters, use it. Otherwise (spaces, weird characters), 21104 # take no chances and rewrite it. 21105 # Note: m4 eats our [], so we need to use [ and ] instead. 21106 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 21107 if test "x$has_forbidden_chars" != x; then 21108 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 21109 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 21110 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 21111 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 21112 # Going to short mode and back again did indeed matter. Since short mode is 21113 # case insensitive, let's make it lowercase to improve readability. 21114 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 21115 # Now convert it back to Unix-style (cygpath) 21116 input_path=`$CYGPATH -u "$shortmode_path"` 21117 new_path="$input_path" 21118 fi 21119 fi 21120 21121 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 21122 if test "x$test_cygdrive_prefix" = x; then 21123 # As a simple fix, exclude /usr/bin since it's not a real path. 21124 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 21125 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 21126 # a path prefixed by /cygdrive for fixpath to work. 21127 new_path="$CYGWIN_ROOT_PATH$input_path" 21128 fi 21129 fi 21130 21131 # remove trailing .exe if any 21132 new_path="${new_path/%.exe/}" 21133 21134 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 21135 21136 # First separate the path from the arguments. This will split at the first 21137 # space. 21138 complete="$FOUND_MAKE" 21139 path="${complete%% *}" 21140 tmp="$complete EOL" 21141 arguments="${tmp#* }" 21142 21143 # Input might be given as Windows format, start by converting to 21144 # unix format. 21145 new_path="$path" 21146 21147 windows_path="$new_path" 21148 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 21149 unix_path=`$CYGPATH -u "$windows_path"` 21150 new_path="$unix_path" 21151 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 21152 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 21153 new_path="$unix_path" 21154 fi 21155 21156 21157 # Now try to locate executable using which 21158 new_path=`$WHICH "$new_path" 2> /dev/null` 21159 21160 if test "x$new_path" = x; then 21161 # Oops. Which didn't find the executable. 21162 # The splitting of arguments from the executable at a space might have been incorrect, 21163 # since paths with space are more likely in Windows. Give it another try with the whole 21164 # argument. 21165 path="$complete" 21166 arguments="EOL" 21167 new_path="$path" 21168 21169 windows_path="$new_path" 21170 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 21171 unix_path=`$CYGPATH -u "$windows_path"` 21172 new_path="$unix_path" 21173 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 21174 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 21175 new_path="$unix_path" 21176 fi 21177 21178 21179 new_path=`$WHICH "$new_path" 2> /dev/null` 21180 # bat and cmd files are not always considered executable in MSYS causing which 21181 # to not find them 21182 if test "x$new_path" = x \ 21183 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 21184 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 21185 new_path="$path" 21186 21187 windows_path="$new_path" 21188 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 21189 unix_path=`$CYGPATH -u "$windows_path"` 21190 new_path="$unix_path" 21191 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 21192 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 21193 new_path="$unix_path" 21194 fi 21195 21196 fi 21197 21198 if test "x$new_path" = x; then 21199 # It's still not found. Now this is an unrecoverable error. 21200 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 21201 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 21202 has_space=`$ECHO "$complete" | $GREP " "` 21203 if test "x$has_space" != x; then 21204 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 21205 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 21206 fi 21207 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 21208 fi 21209 fi 21210 21211 # Now new_path has a complete unix path to the binary 21212 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 21213 # Keep paths in /bin as-is, but remove trailing .exe if any 21214 new_path="${new_path/%.exe/}" 21215 # Do not save /bin paths to all_fixpath_prefixes! 21216 else 21217 # Not in mixed or Windows style, start by that. 21218 new_path=`cmd //c echo $new_path` 21219 21220 input_path="$new_path" 21221 # Check if we need to convert this using DOS-style short mode. If the path 21222 # contains just simple characters, use it. Otherwise (spaces, weird characters), 21223 # take no chances and rewrite it. 21224 # Note: m4 eats our [], so we need to use [ and ] instead. 21225 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 21226 if test "x$has_forbidden_chars" != x; then 21227 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 21228 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 21229 fi 21230 21231 # Output is in $new_path 21232 21233 windows_path="$new_path" 21234 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 21235 unix_path=`$CYGPATH -u "$windows_path"` 21236 new_path="$unix_path" 21237 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 21238 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 21239 new_path="$unix_path" 21240 fi 21241 21242 # remove trailing .exe if any 21243 new_path="${new_path/%.exe/}" 21244 21245 # Save the first 10 bytes of this path to the storage, so fixpath can work. 21246 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 21247 fi 21248 21249 else 21250 # We're on a unix platform. Hooray! :) 21251 # First separate the path from the arguments. This will split at the first 21252 # space. 21253 complete="$FOUND_MAKE" 21254 path="${complete%% *}" 21255 tmp="$complete EOL" 21256 arguments="${tmp#* }" 21257 21258 # Cannot rely on the command "which" here since it doesn't always work. 21259 is_absolute_path=`$ECHO "$path" | $GREP ^/` 21260 if test -z "$is_absolute_path"; then 21261 # Path to executable is not absolute. Find it. 21262 IFS_save="$IFS" 21263 IFS=: 21264 for p in $PATH; do 21265 if test -f "$p/$path" && test -x "$p/$path"; then 21266 new_path="$p/$path" 21267 break 21268 fi 21269 done 21270 IFS="$IFS_save" 21271 else 21272 # This is an absolute path, we can use it without further modifications. 21273 new_path="$path" 21274 fi 21275 21276 if test "x$new_path" = x; then 21277 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 21278 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 21279 has_space=`$ECHO "$complete" | $GREP " "` 21280 if test "x$has_space" != x; then 21281 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 21282 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 21283 fi 21284 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 21285 fi 21286 fi 21287 21288 # Now join together the path and the arguments once again 21289 if test "x$arguments" != xEOL; then 21290 new_complete="$new_path ${arguments% *}" 21291 else 21292 new_complete="$new_path" 21293 fi 21294 21295 if test "x$complete" != "x$new_complete"; then 21296 FOUND_MAKE="$new_complete" 21297 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 21298 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 21299 fi 21300 fi 21301 21302 fi 21303 fi 21304 fi 21305 fi 21306 21307 if test "x$FOUND_MAKE" = x; then 21308 as_fn_error $? "The specified make (by MAKE=$MAKE) is not GNU make $MAKE_REQUIRED_VERSION or newer." "$LINENO" 5 21309 fi 21310 21311 fi 21312 21313 21314 MAKE=$FOUND_MAKE 21315 21316 { $as_echo "$as_me:${as_lineno-$LINENO}: Using GNU make at $FOUND_MAKE (version: $MAKE_VERSION_STRING)" >&5 21317 $as_echo "$as_me: Using GNU make at $FOUND_MAKE (version: $MAKE_VERSION_STRING)" >&6;} 21318 21319 21320 # Check if make supports the output sync option and if so, setup using it. 21321 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if make --output-sync is supported" >&5 21322 $as_echo_n "checking if make --output-sync is supported... " >&6; } 21323 if $MAKE --version -O > /dev/null 2>&1; then 21324 OUTPUT_SYNC_SUPPORTED=true 21325 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 21326 $as_echo "yes" >&6; } 21327 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for output-sync value" >&5 21328 $as_echo_n "checking for output-sync value... " >&6; } 21329 21330 # Check whether --with-output-sync was given. 21331 if test "${with_output_sync+set}" = set; then : 21332 withval=$with_output_sync; OUTPUT_SYNC=$with_output_sync 21333 fi 21334 21335 if test "x$OUTPUT_SYNC" = "x"; then 21336 OUTPUT_SYNC=none 21337 fi 21338 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OUTPUT_SYNC" >&5 21339 $as_echo "$OUTPUT_SYNC" >&6; } 21340 if ! $MAKE --version -O$OUTPUT_SYNC > /dev/null 2>&1; then 21341 as_fn_error $? "Make did not the support the value $OUTPUT_SYNC as output sync type." "$LINENO" 5 21342 fi 21343 else 21344 OUTPUT_SYNC_SUPPORTED=false 21345 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21346 $as_echo "no" >&6; } 21347 fi 21348 21349 21350 21351 21352 21353 21354 # Test if find supports -delete 21355 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if find supports -delete" >&5 21356 $as_echo_n "checking if find supports -delete... " >&6; } 21357 FIND_DELETE="-delete" 21358 21359 DELETEDIR=`$MKTEMP -d tmp.XXXXXXXXXX` || (echo Could not create temporary directory!; exit $?) 21360 21361 echo Hejsan > $DELETEDIR/TestIfFindSupportsDelete 21362 21363 TEST_DELETE=`$FIND "$DELETEDIR" -name TestIfFindSupportsDelete $FIND_DELETE 2>&1` 21364 if test -f $DELETEDIR/TestIfFindSupportsDelete; then 21365 # No, it does not. 21366 $RM $DELETEDIR/TestIfFindSupportsDelete 21367 if test "x$OPENJDK_TARGET_OS" = "xaix"; then 21368 # AIX 'find' is buggy if called with '-exec {} \+' and an empty file list 21369 FIND_DELETE="-print | $XARGS $RM" 21370 else 21371 FIND_DELETE="-exec $RM \{\} \+" 21372 fi 21373 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21374 $as_echo "no" >&6; } 21375 else 21376 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 21377 $as_echo "yes" >&6; } 21378 fi 21379 $RMDIR $DELETEDIR 21380 21381 21382 21383 # Test which kind of tar was found 21384 if test "x$($TAR --version | $GREP "GNU tar")" != "x"; then 21385 TAR_TYPE="gnu" 21386 elif test "x$($TAR --version | $GREP "bsdtar")" != "x"; then 21387 TAR_TYPE="bsd" 21388 elif test "x$($TAR -v | $GREP "bsdtar")" != "x"; then 21389 TAR_TYPE="bsd" 21390 elif test "x$OPENJDK_BUILD_OS" = "xsolaris"; then 21391 TAR_TYPE="solaris" 21392 fi 21393 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what type of tar was found" >&5 21394 $as_echo_n "checking what type of tar was found... " >&6; } 21395 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR_TYPE" >&5 21396 $as_echo "$TAR_TYPE" >&6; } 21397 21398 TAR_CREATE_FILE_PARAM="" 21399 21400 if test "x$TAR_TYPE" = "xgnu"; then 21401 TAR_INCLUDE_PARAM="T" 21402 TAR_SUPPORTS_TRANSFORM="true" 21403 if test "x$OPENJDK_TARGET_OS" = "xsolaris"; then 21404 # When using gnu tar for Solaris targets, need to use compatibility mode 21405 TAR_CREATE_EXTRA_PARAM="--format=ustar" 21406 fi 21407 else 21408 TAR_INCLUDE_PARAM="I" 21409 TAR_SUPPORTS_TRANSFORM="false" 21410 fi 21411 21412 21413 21414 21415 21416 21417 # Test that grep supports -Fx with a list of pattern which includes null pattern. 21418 # This is a problem for the grep resident on AIX. 21419 { $as_echo "$as_me:${as_lineno-$LINENO}: checking that grep ($GREP) -Fx handles empty lines in the pattern list correctly" >&5 21420 $as_echo_n "checking that grep ($GREP) -Fx handles empty lines in the pattern list correctly... " >&6; } 21421 # Multiple subsequent spaces.. 21422 STACK_SPACES='aaa bbb ccc' 21423 # ..converted to subsequent newlines, causes STACK_LIST to be a list with some empty 21424 # patterns in it. 21425 STACK_LIST=${STACK_SPACES// /$'\n'} 21426 NEEDLE_SPACES='ccc bbb aaa' 21427 NEEDLE_LIST=${NEEDLE_SPACES// /$'\n'} 21428 RESULT="$($GREP -Fvx "$STACK_LIST" <<< "$NEEDLE_LIST")" 21429 if test "x$RESULT" == "x"; then 21430 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 21431 $as_echo "yes" >&6; } 21432 else 21433 if test "x$OPENJDK_TARGET_OS" = "xaix"; then 21434 ADDINFO="Please make sure you use GNU grep, usually found at /opt/freeware/bin." 21435 fi 21436 as_fn_error $? "grep does not handle -Fx correctly. ${ADDINFO}" "$LINENO" 5 21437 fi 21438 21439 21440 # These tools might not be installed by default, 21441 # need hint on how to install them. 21442 21443 21444 21445 # Publish this variable in the help. 21446 21447 21448 if [ -z "${UNZIP+x}" ]; then 21449 # The variable is not set by user, try to locate tool using the code snippet 21450 for ac_prog in unzip 21451 do 21452 # Extract the first word of "$ac_prog", so it can be a program name with args. 21453 set dummy $ac_prog; ac_word=$2 21454 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21455 $as_echo_n "checking for $ac_word... " >&6; } 21456 if ${ac_cv_path_UNZIP+:} false; then : 21457 $as_echo_n "(cached) " >&6 21458 else 21459 case $UNZIP in 21460 [\\/]* | ?:[\\/]*) 21461 ac_cv_path_UNZIP="$UNZIP" # Let the user override the test with a path. 21462 ;; 21463 *) 21464 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21465 for as_dir in $PATH 21466 do 21467 IFS=$as_save_IFS 21468 test -z "$as_dir" && as_dir=. 21469 for ac_exec_ext in '' $ac_executable_extensions; do 21470 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21471 ac_cv_path_UNZIP="$as_dir/$ac_word$ac_exec_ext" 21472 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21473 break 2 21474 fi 21475 done 21476 done 21477 IFS=$as_save_IFS 21478 21479 ;; 21480 esac 21481 fi 21482 UNZIP=$ac_cv_path_UNZIP 21483 if test -n "$UNZIP"; then 21484 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNZIP" >&5 21485 $as_echo "$UNZIP" >&6; } 21486 else 21487 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21488 $as_echo "no" >&6; } 21489 fi 21490 21491 21492 test -n "$UNZIP" && break 21493 done 21494 21495 else 21496 # The variable is set, but is it from the command line or the environment? 21497 21498 # Try to remove the string !UNZIP! from our list. 21499 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!UNZIP!/} 21500 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 21501 # If it failed, the variable was not from the command line. Ignore it, 21502 # but warn the user (except for BASH, which is always set by the calling BASH). 21503 if test "xUNZIP" != xBASH; then 21504 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of UNZIP from the environment. Use command line variables instead." >&5 21505 $as_echo "$as_me: WARNING: Ignoring value of UNZIP from the environment. Use command line variables instead." >&2;} 21506 fi 21507 # Try to locate tool using the code snippet 21508 for ac_prog in unzip 21509 do 21510 # Extract the first word of "$ac_prog", so it can be a program name with args. 21511 set dummy $ac_prog; ac_word=$2 21512 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21513 $as_echo_n "checking for $ac_word... " >&6; } 21514 if ${ac_cv_path_UNZIP+:} false; then : 21515 $as_echo_n "(cached) " >&6 21516 else 21517 case $UNZIP in 21518 [\\/]* | ?:[\\/]*) 21519 ac_cv_path_UNZIP="$UNZIP" # Let the user override the test with a path. 21520 ;; 21521 *) 21522 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21523 for as_dir in $PATH 21524 do 21525 IFS=$as_save_IFS 21526 test -z "$as_dir" && as_dir=. 21527 for ac_exec_ext in '' $ac_executable_extensions; do 21528 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21529 ac_cv_path_UNZIP="$as_dir/$ac_word$ac_exec_ext" 21530 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21531 break 2 21532 fi 21533 done 21534 done 21535 IFS=$as_save_IFS 21536 21537 ;; 21538 esac 21539 fi 21540 UNZIP=$ac_cv_path_UNZIP 21541 if test -n "$UNZIP"; then 21542 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNZIP" >&5 21543 $as_echo "$UNZIP" >&6; } 21544 else 21545 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21546 $as_echo "no" >&6; } 21547 fi 21548 21549 21550 test -n "$UNZIP" && break 21551 done 21552 21553 else 21554 # If it succeeded, then it was overridden by the user. We will use it 21555 # for the tool. 21556 21557 # First remove it from the list of overridden variables, so we can test 21558 # for unknown variables in the end. 21559 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 21560 21561 # Check if we try to supply an empty value 21562 if test "x$UNZIP" = x; then 21563 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool UNZIP= (no value)" >&5 21564 $as_echo "$as_me: Setting user supplied tool UNZIP= (no value)" >&6;} 21565 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNZIP" >&5 21566 $as_echo_n "checking for UNZIP... " >&6; } 21567 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 21568 $as_echo "disabled" >&6; } 21569 else 21570 # Check if the provided tool contains a complete path. 21571 tool_specified="$UNZIP" 21572 tool_basename="${tool_specified##*/}" 21573 if test "x$tool_basename" = "x$tool_specified"; then 21574 # A command without a complete path is provided, search $PATH. 21575 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool UNZIP=$tool_basename" >&5 21576 $as_echo "$as_me: Will search for user supplied tool UNZIP=$tool_basename" >&6;} 21577 # Extract the first word of "$tool_basename", so it can be a program name with args. 21578 set dummy $tool_basename; ac_word=$2 21579 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21580 $as_echo_n "checking for $ac_word... " >&6; } 21581 if ${ac_cv_path_UNZIP+:} false; then : 21582 $as_echo_n "(cached) " >&6 21583 else 21584 case $UNZIP in 21585 [\\/]* | ?:[\\/]*) 21586 ac_cv_path_UNZIP="$UNZIP" # Let the user override the test with a path. 21587 ;; 21588 *) 21589 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21590 for as_dir in $PATH 21591 do 21592 IFS=$as_save_IFS 21593 test -z "$as_dir" && as_dir=. 21594 for ac_exec_ext in '' $ac_executable_extensions; do 21595 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21596 ac_cv_path_UNZIP="$as_dir/$ac_word$ac_exec_ext" 21597 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21598 break 2 21599 fi 21600 done 21601 done 21602 IFS=$as_save_IFS 21603 21604 ;; 21605 esac 21606 fi 21607 UNZIP=$ac_cv_path_UNZIP 21608 if test -n "$UNZIP"; then 21609 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNZIP" >&5 21610 $as_echo "$UNZIP" >&6; } 21611 else 21612 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21613 $as_echo "no" >&6; } 21614 fi 21615 21616 21617 if test "x$UNZIP" = x; then 21618 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 21619 fi 21620 else 21621 # Otherwise we believe it is a complete path. Use it as it is. 21622 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool UNZIP=$tool_specified" >&5 21623 $as_echo "$as_me: Will use user supplied tool UNZIP=$tool_specified" >&6;} 21624 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNZIP" >&5 21625 $as_echo_n "checking for UNZIP... " >&6; } 21626 if test ! -x "$tool_specified"; then 21627 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 21628 $as_echo "not found" >&6; } 21629 as_fn_error $? "User supplied tool UNZIP=$tool_specified does not exist or is not executable" "$LINENO" 5 21630 fi 21631 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 21632 $as_echo "$tool_specified" >&6; } 21633 fi 21634 fi 21635 fi 21636 21637 fi 21638 21639 21640 21641 if test "x$UNZIP" = x; then 21642 as_fn_error $? "Could not find required tool for UNZIP" "$LINENO" 5 21643 fi 21644 21645 21646 # Since zip uses "ZIP" as a environment variable for passing options, we need 21647 # to name our variable differently, hence ZIPEXE. 21648 21649 21650 21651 # Publish this variable in the help. 21652 21653 21654 if [ -z "${ZIPEXE+x}" ]; then 21655 # The variable is not set by user, try to locate tool using the code snippet 21656 for ac_prog in zip 21657 do 21658 # Extract the first word of "$ac_prog", so it can be a program name with args. 21659 set dummy $ac_prog; ac_word=$2 21660 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21661 $as_echo_n "checking for $ac_word... " >&6; } 21662 if ${ac_cv_path_ZIPEXE+:} false; then : 21663 $as_echo_n "(cached) " >&6 21664 else 21665 case $ZIPEXE in 21666 [\\/]* | ?:[\\/]*) 21667 ac_cv_path_ZIPEXE="$ZIPEXE" # Let the user override the test with a path. 21668 ;; 21669 *) 21670 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21671 for as_dir in $PATH 21672 do 21673 IFS=$as_save_IFS 21674 test -z "$as_dir" && as_dir=. 21675 for ac_exec_ext in '' $ac_executable_extensions; do 21676 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21677 ac_cv_path_ZIPEXE="$as_dir/$ac_word$ac_exec_ext" 21678 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21679 break 2 21680 fi 21681 done 21682 done 21683 IFS=$as_save_IFS 21684 21685 ;; 21686 esac 21687 fi 21688 ZIPEXE=$ac_cv_path_ZIPEXE 21689 if test -n "$ZIPEXE"; then 21690 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIPEXE" >&5 21691 $as_echo "$ZIPEXE" >&6; } 21692 else 21693 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21694 $as_echo "no" >&6; } 21695 fi 21696 21697 21698 test -n "$ZIPEXE" && break 21699 done 21700 21701 else 21702 # The variable is set, but is it from the command line or the environment? 21703 21704 # Try to remove the string !ZIPEXE! from our list. 21705 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ZIPEXE!/} 21706 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 21707 # If it failed, the variable was not from the command line. Ignore it, 21708 # but warn the user (except for BASH, which is always set by the calling BASH). 21709 if test "xZIPEXE" != xBASH; then 21710 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ZIPEXE from the environment. Use command line variables instead." >&5 21711 $as_echo "$as_me: WARNING: Ignoring value of ZIPEXE from the environment. Use command line variables instead." >&2;} 21712 fi 21713 # Try to locate tool using the code snippet 21714 for ac_prog in zip 21715 do 21716 # Extract the first word of "$ac_prog", so it can be a program name with args. 21717 set dummy $ac_prog; ac_word=$2 21718 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21719 $as_echo_n "checking for $ac_word... " >&6; } 21720 if ${ac_cv_path_ZIPEXE+:} false; then : 21721 $as_echo_n "(cached) " >&6 21722 else 21723 case $ZIPEXE in 21724 [\\/]* | ?:[\\/]*) 21725 ac_cv_path_ZIPEXE="$ZIPEXE" # Let the user override the test with a path. 21726 ;; 21727 *) 21728 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21729 for as_dir in $PATH 21730 do 21731 IFS=$as_save_IFS 21732 test -z "$as_dir" && as_dir=. 21733 for ac_exec_ext in '' $ac_executable_extensions; do 21734 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21735 ac_cv_path_ZIPEXE="$as_dir/$ac_word$ac_exec_ext" 21736 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21737 break 2 21738 fi 21739 done 21740 done 21741 IFS=$as_save_IFS 21742 21743 ;; 21744 esac 21745 fi 21746 ZIPEXE=$ac_cv_path_ZIPEXE 21747 if test -n "$ZIPEXE"; then 21748 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIPEXE" >&5 21749 $as_echo "$ZIPEXE" >&6; } 21750 else 21751 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21752 $as_echo "no" >&6; } 21753 fi 21754 21755 21756 test -n "$ZIPEXE" && break 21757 done 21758 21759 else 21760 # If it succeeded, then it was overridden by the user. We will use it 21761 # for the tool. 21762 21763 # First remove it from the list of overridden variables, so we can test 21764 # for unknown variables in the end. 21765 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 21766 21767 # Check if we try to supply an empty value 21768 if test "x$ZIPEXE" = x; then 21769 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ZIPEXE= (no value)" >&5 21770 $as_echo "$as_me: Setting user supplied tool ZIPEXE= (no value)" >&6;} 21771 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ZIPEXE" >&5 21772 $as_echo_n "checking for ZIPEXE... " >&6; } 21773 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 21774 $as_echo "disabled" >&6; } 21775 else 21776 # Check if the provided tool contains a complete path. 21777 tool_specified="$ZIPEXE" 21778 tool_basename="${tool_specified##*/}" 21779 if test "x$tool_basename" = "x$tool_specified"; then 21780 # A command without a complete path is provided, search $PATH. 21781 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ZIPEXE=$tool_basename" >&5 21782 $as_echo "$as_me: Will search for user supplied tool ZIPEXE=$tool_basename" >&6;} 21783 # Extract the first word of "$tool_basename", so it can be a program name with args. 21784 set dummy $tool_basename; ac_word=$2 21785 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21786 $as_echo_n "checking for $ac_word... " >&6; } 21787 if ${ac_cv_path_ZIPEXE+:} false; then : 21788 $as_echo_n "(cached) " >&6 21789 else 21790 case $ZIPEXE in 21791 [\\/]* | ?:[\\/]*) 21792 ac_cv_path_ZIPEXE="$ZIPEXE" # Let the user override the test with a path. 21793 ;; 21794 *) 21795 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21796 for as_dir in $PATH 21797 do 21798 IFS=$as_save_IFS 21799 test -z "$as_dir" && as_dir=. 21800 for ac_exec_ext in '' $ac_executable_extensions; do 21801 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21802 ac_cv_path_ZIPEXE="$as_dir/$ac_word$ac_exec_ext" 21803 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21804 break 2 21805 fi 21806 done 21807 done 21808 IFS=$as_save_IFS 21809 21810 ;; 21811 esac 21812 fi 21813 ZIPEXE=$ac_cv_path_ZIPEXE 21814 if test -n "$ZIPEXE"; then 21815 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIPEXE" >&5 21816 $as_echo "$ZIPEXE" >&6; } 21817 else 21818 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21819 $as_echo "no" >&6; } 21820 fi 21821 21822 21823 if test "x$ZIPEXE" = x; then 21824 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 21825 fi 21826 else 21827 # Otherwise we believe it is a complete path. Use it as it is. 21828 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ZIPEXE=$tool_specified" >&5 21829 $as_echo "$as_me: Will use user supplied tool ZIPEXE=$tool_specified" >&6;} 21830 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ZIPEXE" >&5 21831 $as_echo_n "checking for ZIPEXE... " >&6; } 21832 if test ! -x "$tool_specified"; then 21833 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 21834 $as_echo "not found" >&6; } 21835 as_fn_error $? "User supplied tool ZIPEXE=$tool_specified does not exist or is not executable" "$LINENO" 5 21836 fi 21837 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 21838 $as_echo "$tool_specified" >&6; } 21839 fi 21840 fi 21841 fi 21842 21843 fi 21844 21845 21846 21847 if test "x$ZIPEXE" = x; then 21848 as_fn_error $? "Could not find required tool for ZIPEXE" "$LINENO" 5 21849 fi 21850 21851 21852 21853 # Non-required basic tools 21854 21855 21856 21857 # Publish this variable in the help. 21858 21859 21860 if [ -z "${LDD+x}" ]; then 21861 # The variable is not set by user, try to locate tool using the code snippet 21862 for ac_prog in ldd 21863 do 21864 # Extract the first word of "$ac_prog", so it can be a program name with args. 21865 set dummy $ac_prog; ac_word=$2 21866 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21867 $as_echo_n "checking for $ac_word... " >&6; } 21868 if ${ac_cv_path_LDD+:} false; then : 21869 $as_echo_n "(cached) " >&6 21870 else 21871 case $LDD in 21872 [\\/]* | ?:[\\/]*) 21873 ac_cv_path_LDD="$LDD" # Let the user override the test with a path. 21874 ;; 21875 *) 21876 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21877 for as_dir in $PATH 21878 do 21879 IFS=$as_save_IFS 21880 test -z "$as_dir" && as_dir=. 21881 for ac_exec_ext in '' $ac_executable_extensions; do 21882 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21883 ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext" 21884 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21885 break 2 21886 fi 21887 done 21888 done 21889 IFS=$as_save_IFS 21890 21891 ;; 21892 esac 21893 fi 21894 LDD=$ac_cv_path_LDD 21895 if test -n "$LDD"; then 21896 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDD" >&5 21897 $as_echo "$LDD" >&6; } 21898 else 21899 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21900 $as_echo "no" >&6; } 21901 fi 21902 21903 21904 test -n "$LDD" && break 21905 done 21906 21907 else 21908 # The variable is set, but is it from the command line or the environment? 21909 21910 # Try to remove the string !LDD! from our list. 21911 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LDD!/} 21912 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 21913 # If it failed, the variable was not from the command line. Ignore it, 21914 # but warn the user (except for BASH, which is always set by the calling BASH). 21915 if test "xLDD" != xBASH; then 21916 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LDD from the environment. Use command line variables instead." >&5 21917 $as_echo "$as_me: WARNING: Ignoring value of LDD from the environment. Use command line variables instead." >&2;} 21918 fi 21919 # Try to locate tool using the code snippet 21920 for ac_prog in ldd 21921 do 21922 # Extract the first word of "$ac_prog", so it can be a program name with args. 21923 set dummy $ac_prog; ac_word=$2 21924 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21925 $as_echo_n "checking for $ac_word... " >&6; } 21926 if ${ac_cv_path_LDD+:} false; then : 21927 $as_echo_n "(cached) " >&6 21928 else 21929 case $LDD in 21930 [\\/]* | ?:[\\/]*) 21931 ac_cv_path_LDD="$LDD" # Let the user override the test with a path. 21932 ;; 21933 *) 21934 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21935 for as_dir in $PATH 21936 do 21937 IFS=$as_save_IFS 21938 test -z "$as_dir" && as_dir=. 21939 for ac_exec_ext in '' $ac_executable_extensions; do 21940 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21941 ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext" 21942 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21943 break 2 21944 fi 21945 done 21946 done 21947 IFS=$as_save_IFS 21948 21949 ;; 21950 esac 21951 fi 21952 LDD=$ac_cv_path_LDD 21953 if test -n "$LDD"; then 21954 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDD" >&5 21955 $as_echo "$LDD" >&6; } 21956 else 21957 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21958 $as_echo "no" >&6; } 21959 fi 21960 21961 21962 test -n "$LDD" && break 21963 done 21964 21965 else 21966 # If it succeeded, then it was overridden by the user. We will use it 21967 # for the tool. 21968 21969 # First remove it from the list of overridden variables, so we can test 21970 # for unknown variables in the end. 21971 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 21972 21973 # Check if we try to supply an empty value 21974 if test "x$LDD" = x; then 21975 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool LDD= (no value)" >&5 21976 $as_echo "$as_me: Setting user supplied tool LDD= (no value)" >&6;} 21977 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LDD" >&5 21978 $as_echo_n "checking for LDD... " >&6; } 21979 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 21980 $as_echo "disabled" >&6; } 21981 else 21982 # Check if the provided tool contains a complete path. 21983 tool_specified="$LDD" 21984 tool_basename="${tool_specified##*/}" 21985 if test "x$tool_basename" = "x$tool_specified"; then 21986 # A command without a complete path is provided, search $PATH. 21987 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LDD=$tool_basename" >&5 21988 $as_echo "$as_me: Will search for user supplied tool LDD=$tool_basename" >&6;} 21989 # Extract the first word of "$tool_basename", so it can be a program name with args. 21990 set dummy $tool_basename; ac_word=$2 21991 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21992 $as_echo_n "checking for $ac_word... " >&6; } 21993 if ${ac_cv_path_LDD+:} false; then : 21994 $as_echo_n "(cached) " >&6 21995 else 21996 case $LDD in 21997 [\\/]* | ?:[\\/]*) 21998 ac_cv_path_LDD="$LDD" # Let the user override the test with a path. 21999 ;; 22000 *) 22001 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22002 for as_dir in $PATH 22003 do 22004 IFS=$as_save_IFS 22005 test -z "$as_dir" && as_dir=. 22006 for ac_exec_ext in '' $ac_executable_extensions; do 22007 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22008 ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext" 22009 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22010 break 2 22011 fi 22012 done 22013 done 22014 IFS=$as_save_IFS 22015 22016 ;; 22017 esac 22018 fi 22019 LDD=$ac_cv_path_LDD 22020 if test -n "$LDD"; then 22021 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDD" >&5 22022 $as_echo "$LDD" >&6; } 22023 else 22024 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22025 $as_echo "no" >&6; } 22026 fi 22027 22028 22029 if test "x$LDD" = x; then 22030 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 22031 fi 22032 else 22033 # Otherwise we believe it is a complete path. Use it as it is. 22034 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LDD=$tool_specified" >&5 22035 $as_echo "$as_me: Will use user supplied tool LDD=$tool_specified" >&6;} 22036 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LDD" >&5 22037 $as_echo_n "checking for LDD... " >&6; } 22038 if test ! -x "$tool_specified"; then 22039 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 22040 $as_echo "not found" >&6; } 22041 as_fn_error $? "User supplied tool LDD=$tool_specified does not exist or is not executable" "$LINENO" 5 22042 fi 22043 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 22044 $as_echo "$tool_specified" >&6; } 22045 fi 22046 fi 22047 fi 22048 22049 fi 22050 22051 22052 if test "x$LDD" = "x"; then 22053 # List shared lib dependencies is used for 22054 # debug output and checking for forbidden dependencies. 22055 # We can build without it. 22056 LDD="true" 22057 fi 22058 22059 22060 # Publish this variable in the help. 22061 22062 22063 if [ -z "${OTOOL+x}" ]; then 22064 # The variable is not set by user, try to locate tool using the code snippet 22065 for ac_prog in otool 22066 do 22067 # Extract the first word of "$ac_prog", so it can be a program name with args. 22068 set dummy $ac_prog; ac_word=$2 22069 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22070 $as_echo_n "checking for $ac_word... " >&6; } 22071 if ${ac_cv_path_OTOOL+:} false; then : 22072 $as_echo_n "(cached) " >&6 22073 else 22074 case $OTOOL in 22075 [\\/]* | ?:[\\/]*) 22076 ac_cv_path_OTOOL="$OTOOL" # Let the user override the test with a path. 22077 ;; 22078 *) 22079 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22080 for as_dir in $PATH 22081 do 22082 IFS=$as_save_IFS 22083 test -z "$as_dir" && as_dir=. 22084 for ac_exec_ext in '' $ac_executable_extensions; do 22085 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22086 ac_cv_path_OTOOL="$as_dir/$ac_word$ac_exec_ext" 22087 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22088 break 2 22089 fi 22090 done 22091 done 22092 IFS=$as_save_IFS 22093 22094 ;; 22095 esac 22096 fi 22097 OTOOL=$ac_cv_path_OTOOL 22098 if test -n "$OTOOL"; then 22099 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 22100 $as_echo "$OTOOL" >&6; } 22101 else 22102 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22103 $as_echo "no" >&6; } 22104 fi 22105 22106 22107 test -n "$OTOOL" && break 22108 done 22109 22110 else 22111 # The variable is set, but is it from the command line or the environment? 22112 22113 # Try to remove the string !OTOOL! from our list. 22114 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!OTOOL!/} 22115 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 22116 # If it failed, the variable was not from the command line. Ignore it, 22117 # but warn the user (except for BASH, which is always set by the calling BASH). 22118 if test "xOTOOL" != xBASH; then 22119 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of OTOOL from the environment. Use command line variables instead." >&5 22120 $as_echo "$as_me: WARNING: Ignoring value of OTOOL from the environment. Use command line variables instead." >&2;} 22121 fi 22122 # Try to locate tool using the code snippet 22123 for ac_prog in otool 22124 do 22125 # Extract the first word of "$ac_prog", so it can be a program name with args. 22126 set dummy $ac_prog; ac_word=$2 22127 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22128 $as_echo_n "checking for $ac_word... " >&6; } 22129 if ${ac_cv_path_OTOOL+:} false; then : 22130 $as_echo_n "(cached) " >&6 22131 else 22132 case $OTOOL in 22133 [\\/]* | ?:[\\/]*) 22134 ac_cv_path_OTOOL="$OTOOL" # Let the user override the test with a path. 22135 ;; 22136 *) 22137 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22138 for as_dir in $PATH 22139 do 22140 IFS=$as_save_IFS 22141 test -z "$as_dir" && as_dir=. 22142 for ac_exec_ext in '' $ac_executable_extensions; do 22143 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22144 ac_cv_path_OTOOL="$as_dir/$ac_word$ac_exec_ext" 22145 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22146 break 2 22147 fi 22148 done 22149 done 22150 IFS=$as_save_IFS 22151 22152 ;; 22153 esac 22154 fi 22155 OTOOL=$ac_cv_path_OTOOL 22156 if test -n "$OTOOL"; then 22157 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 22158 $as_echo "$OTOOL" >&6; } 22159 else 22160 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22161 $as_echo "no" >&6; } 22162 fi 22163 22164 22165 test -n "$OTOOL" && break 22166 done 22167 22168 else 22169 # If it succeeded, then it was overridden by the user. We will use it 22170 # for the tool. 22171 22172 # First remove it from the list of overridden variables, so we can test 22173 # for unknown variables in the end. 22174 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 22175 22176 # Check if we try to supply an empty value 22177 if test "x$OTOOL" = x; then 22178 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool OTOOL= (no value)" >&5 22179 $as_echo "$as_me: Setting user supplied tool OTOOL= (no value)" >&6;} 22180 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTOOL" >&5 22181 $as_echo_n "checking for OTOOL... " >&6; } 22182 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 22183 $as_echo "disabled" >&6; } 22184 else 22185 # Check if the provided tool contains a complete path. 22186 tool_specified="$OTOOL" 22187 tool_basename="${tool_specified##*/}" 22188 if test "x$tool_basename" = "x$tool_specified"; then 22189 # A command without a complete path is provided, search $PATH. 22190 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool OTOOL=$tool_basename" >&5 22191 $as_echo "$as_me: Will search for user supplied tool OTOOL=$tool_basename" >&6;} 22192 # Extract the first word of "$tool_basename", so it can be a program name with args. 22193 set dummy $tool_basename; ac_word=$2 22194 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22195 $as_echo_n "checking for $ac_word... " >&6; } 22196 if ${ac_cv_path_OTOOL+:} false; then : 22197 $as_echo_n "(cached) " >&6 22198 else 22199 case $OTOOL in 22200 [\\/]* | ?:[\\/]*) 22201 ac_cv_path_OTOOL="$OTOOL" # Let the user override the test with a path. 22202 ;; 22203 *) 22204 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22205 for as_dir in $PATH 22206 do 22207 IFS=$as_save_IFS 22208 test -z "$as_dir" && as_dir=. 22209 for ac_exec_ext in '' $ac_executable_extensions; do 22210 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22211 ac_cv_path_OTOOL="$as_dir/$ac_word$ac_exec_ext" 22212 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22213 break 2 22214 fi 22215 done 22216 done 22217 IFS=$as_save_IFS 22218 22219 ;; 22220 esac 22221 fi 22222 OTOOL=$ac_cv_path_OTOOL 22223 if test -n "$OTOOL"; then 22224 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 22225 $as_echo "$OTOOL" >&6; } 22226 else 22227 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22228 $as_echo "no" >&6; } 22229 fi 22230 22231 22232 if test "x$OTOOL" = x; then 22233 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 22234 fi 22235 else 22236 # Otherwise we believe it is a complete path. Use it as it is. 22237 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool OTOOL=$tool_specified" >&5 22238 $as_echo "$as_me: Will use user supplied tool OTOOL=$tool_specified" >&6;} 22239 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTOOL" >&5 22240 $as_echo_n "checking for OTOOL... " >&6; } 22241 if test ! -x "$tool_specified"; then 22242 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 22243 $as_echo "not found" >&6; } 22244 as_fn_error $? "User supplied tool OTOOL=$tool_specified does not exist or is not executable" "$LINENO" 5 22245 fi 22246 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 22247 $as_echo "$tool_specified" >&6; } 22248 fi 22249 fi 22250 fi 22251 22252 fi 22253 22254 22255 if test "x$OTOOL" = "x"; then 22256 OTOOL="true" 22257 fi 22258 22259 22260 # Publish this variable in the help. 22261 22262 22263 if [ -z "${READELF+x}" ]; then 22264 # The variable is not set by user, try to locate tool using the code snippet 22265 for ac_prog in greadelf readelf 22266 do 22267 # Extract the first word of "$ac_prog", so it can be a program name with args. 22268 set dummy $ac_prog; ac_word=$2 22269 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22270 $as_echo_n "checking for $ac_word... " >&6; } 22271 if ${ac_cv_path_READELF+:} false; then : 22272 $as_echo_n "(cached) " >&6 22273 else 22274 case $READELF in 22275 [\\/]* | ?:[\\/]*) 22276 ac_cv_path_READELF="$READELF" # Let the user override the test with a path. 22277 ;; 22278 *) 22279 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22280 for as_dir in $PATH 22281 do 22282 IFS=$as_save_IFS 22283 test -z "$as_dir" && as_dir=. 22284 for ac_exec_ext in '' $ac_executable_extensions; do 22285 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22286 ac_cv_path_READELF="$as_dir/$ac_word$ac_exec_ext" 22287 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22288 break 2 22289 fi 22290 done 22291 done 22292 IFS=$as_save_IFS 22293 22294 ;; 22295 esac 22296 fi 22297 READELF=$ac_cv_path_READELF 22298 if test -n "$READELF"; then 22299 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5 22300 $as_echo "$READELF" >&6; } 22301 else 22302 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22303 $as_echo "no" >&6; } 22304 fi 22305 22306 22307 test -n "$READELF" && break 22308 done 22309 22310 else 22311 # The variable is set, but is it from the command line or the environment? 22312 22313 # Try to remove the string !READELF! from our list. 22314 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!READELF!/} 22315 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 22316 # If it failed, the variable was not from the command line. Ignore it, 22317 # but warn the user (except for BASH, which is always set by the calling BASH). 22318 if test "xREADELF" != xBASH; then 22319 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of READELF from the environment. Use command line variables instead." >&5 22320 $as_echo "$as_me: WARNING: Ignoring value of READELF from the environment. Use command line variables instead." >&2;} 22321 fi 22322 # Try to locate tool using the code snippet 22323 for ac_prog in greadelf readelf 22324 do 22325 # Extract the first word of "$ac_prog", so it can be a program name with args. 22326 set dummy $ac_prog; ac_word=$2 22327 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22328 $as_echo_n "checking for $ac_word... " >&6; } 22329 if ${ac_cv_path_READELF+:} false; then : 22330 $as_echo_n "(cached) " >&6 22331 else 22332 case $READELF in 22333 [\\/]* | ?:[\\/]*) 22334 ac_cv_path_READELF="$READELF" # Let the user override the test with a path. 22335 ;; 22336 *) 22337 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22338 for as_dir in $PATH 22339 do 22340 IFS=$as_save_IFS 22341 test -z "$as_dir" && as_dir=. 22342 for ac_exec_ext in '' $ac_executable_extensions; do 22343 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22344 ac_cv_path_READELF="$as_dir/$ac_word$ac_exec_ext" 22345 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22346 break 2 22347 fi 22348 done 22349 done 22350 IFS=$as_save_IFS 22351 22352 ;; 22353 esac 22354 fi 22355 READELF=$ac_cv_path_READELF 22356 if test -n "$READELF"; then 22357 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5 22358 $as_echo "$READELF" >&6; } 22359 else 22360 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22361 $as_echo "no" >&6; } 22362 fi 22363 22364 22365 test -n "$READELF" && break 22366 done 22367 22368 else 22369 # If it succeeded, then it was overridden by the user. We will use it 22370 # for the tool. 22371 22372 # First remove it from the list of overridden variables, so we can test 22373 # for unknown variables in the end. 22374 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 22375 22376 # Check if we try to supply an empty value 22377 if test "x$READELF" = x; then 22378 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool READELF= (no value)" >&5 22379 $as_echo "$as_me: Setting user supplied tool READELF= (no value)" >&6;} 22380 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READELF" >&5 22381 $as_echo_n "checking for READELF... " >&6; } 22382 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 22383 $as_echo "disabled" >&6; } 22384 else 22385 # Check if the provided tool contains a complete path. 22386 tool_specified="$READELF" 22387 tool_basename="${tool_specified##*/}" 22388 if test "x$tool_basename" = "x$tool_specified"; then 22389 # A command without a complete path is provided, search $PATH. 22390 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool READELF=$tool_basename" >&5 22391 $as_echo "$as_me: Will search for user supplied tool READELF=$tool_basename" >&6;} 22392 # Extract the first word of "$tool_basename", so it can be a program name with args. 22393 set dummy $tool_basename; ac_word=$2 22394 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22395 $as_echo_n "checking for $ac_word... " >&6; } 22396 if ${ac_cv_path_READELF+:} false; then : 22397 $as_echo_n "(cached) " >&6 22398 else 22399 case $READELF in 22400 [\\/]* | ?:[\\/]*) 22401 ac_cv_path_READELF="$READELF" # Let the user override the test with a path. 22402 ;; 22403 *) 22404 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22405 for as_dir in $PATH 22406 do 22407 IFS=$as_save_IFS 22408 test -z "$as_dir" && as_dir=. 22409 for ac_exec_ext in '' $ac_executable_extensions; do 22410 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22411 ac_cv_path_READELF="$as_dir/$ac_word$ac_exec_ext" 22412 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22413 break 2 22414 fi 22415 done 22416 done 22417 IFS=$as_save_IFS 22418 22419 ;; 22420 esac 22421 fi 22422 READELF=$ac_cv_path_READELF 22423 if test -n "$READELF"; then 22424 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5 22425 $as_echo "$READELF" >&6; } 22426 else 22427 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22428 $as_echo "no" >&6; } 22429 fi 22430 22431 22432 if test "x$READELF" = x; then 22433 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 22434 fi 22435 else 22436 # Otherwise we believe it is a complete path. Use it as it is. 22437 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool READELF=$tool_specified" >&5 22438 $as_echo "$as_me: Will use user supplied tool READELF=$tool_specified" >&6;} 22439 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READELF" >&5 22440 $as_echo_n "checking for READELF... " >&6; } 22441 if test ! -x "$tool_specified"; then 22442 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 22443 $as_echo "not found" >&6; } 22444 as_fn_error $? "User supplied tool READELF=$tool_specified does not exist or is not executable" "$LINENO" 5 22445 fi 22446 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 22447 $as_echo "$tool_specified" >&6; } 22448 fi 22449 fi 22450 fi 22451 22452 fi 22453 22454 22455 22456 22457 # Publish this variable in the help. 22458 22459 22460 if [ -z "${HG+x}" ]; then 22461 # The variable is not set by user, try to locate tool using the code snippet 22462 for ac_prog in hg 22463 do 22464 # Extract the first word of "$ac_prog", so it can be a program name with args. 22465 set dummy $ac_prog; ac_word=$2 22466 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22467 $as_echo_n "checking for $ac_word... " >&6; } 22468 if ${ac_cv_path_HG+:} false; then : 22469 $as_echo_n "(cached) " >&6 22470 else 22471 case $HG in 22472 [\\/]* | ?:[\\/]*) 22473 ac_cv_path_HG="$HG" # Let the user override the test with a path. 22474 ;; 22475 *) 22476 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22477 for as_dir in $PATH 22478 do 22479 IFS=$as_save_IFS 22480 test -z "$as_dir" && as_dir=. 22481 for ac_exec_ext in '' $ac_executable_extensions; do 22482 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22483 ac_cv_path_HG="$as_dir/$ac_word$ac_exec_ext" 22484 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22485 break 2 22486 fi 22487 done 22488 done 22489 IFS=$as_save_IFS 22490 22491 ;; 22492 esac 22493 fi 22494 HG=$ac_cv_path_HG 22495 if test -n "$HG"; then 22496 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HG" >&5 22497 $as_echo "$HG" >&6; } 22498 else 22499 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22500 $as_echo "no" >&6; } 22501 fi 22502 22503 22504 test -n "$HG" && break 22505 done 22506 22507 else 22508 # The variable is set, but is it from the command line or the environment? 22509 22510 # Try to remove the string !HG! from our list. 22511 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!HG!/} 22512 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 22513 # If it failed, the variable was not from the command line. Ignore it, 22514 # but warn the user (except for BASH, which is always set by the calling BASH). 22515 if test "xHG" != xBASH; then 22516 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of HG from the environment. Use command line variables instead." >&5 22517 $as_echo "$as_me: WARNING: Ignoring value of HG from the environment. Use command line variables instead." >&2;} 22518 fi 22519 # Try to locate tool using the code snippet 22520 for ac_prog in hg 22521 do 22522 # Extract the first word of "$ac_prog", so it can be a program name with args. 22523 set dummy $ac_prog; ac_word=$2 22524 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22525 $as_echo_n "checking for $ac_word... " >&6; } 22526 if ${ac_cv_path_HG+:} false; then : 22527 $as_echo_n "(cached) " >&6 22528 else 22529 case $HG in 22530 [\\/]* | ?:[\\/]*) 22531 ac_cv_path_HG="$HG" # Let the user override the test with a path. 22532 ;; 22533 *) 22534 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22535 for as_dir in $PATH 22536 do 22537 IFS=$as_save_IFS 22538 test -z "$as_dir" && as_dir=. 22539 for ac_exec_ext in '' $ac_executable_extensions; do 22540 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22541 ac_cv_path_HG="$as_dir/$ac_word$ac_exec_ext" 22542 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22543 break 2 22544 fi 22545 done 22546 done 22547 IFS=$as_save_IFS 22548 22549 ;; 22550 esac 22551 fi 22552 HG=$ac_cv_path_HG 22553 if test -n "$HG"; then 22554 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HG" >&5 22555 $as_echo "$HG" >&6; } 22556 else 22557 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22558 $as_echo "no" >&6; } 22559 fi 22560 22561 22562 test -n "$HG" && break 22563 done 22564 22565 else 22566 # If it succeeded, then it was overridden by the user. We will use it 22567 # for the tool. 22568 22569 # First remove it from the list of overridden variables, so we can test 22570 # for unknown variables in the end. 22571 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 22572 22573 # Check if we try to supply an empty value 22574 if test "x$HG" = x; then 22575 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool HG= (no value)" >&5 22576 $as_echo "$as_me: Setting user supplied tool HG= (no value)" >&6;} 22577 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HG" >&5 22578 $as_echo_n "checking for HG... " >&6; } 22579 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 22580 $as_echo "disabled" >&6; } 22581 else 22582 # Check if the provided tool contains a complete path. 22583 tool_specified="$HG" 22584 tool_basename="${tool_specified##*/}" 22585 if test "x$tool_basename" = "x$tool_specified"; then 22586 # A command without a complete path is provided, search $PATH. 22587 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool HG=$tool_basename" >&5 22588 $as_echo "$as_me: Will search for user supplied tool HG=$tool_basename" >&6;} 22589 # Extract the first word of "$tool_basename", so it can be a program name with args. 22590 set dummy $tool_basename; ac_word=$2 22591 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22592 $as_echo_n "checking for $ac_word... " >&6; } 22593 if ${ac_cv_path_HG+:} false; then : 22594 $as_echo_n "(cached) " >&6 22595 else 22596 case $HG in 22597 [\\/]* | ?:[\\/]*) 22598 ac_cv_path_HG="$HG" # Let the user override the test with a path. 22599 ;; 22600 *) 22601 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22602 for as_dir in $PATH 22603 do 22604 IFS=$as_save_IFS 22605 test -z "$as_dir" && as_dir=. 22606 for ac_exec_ext in '' $ac_executable_extensions; do 22607 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22608 ac_cv_path_HG="$as_dir/$ac_word$ac_exec_ext" 22609 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22610 break 2 22611 fi 22612 done 22613 done 22614 IFS=$as_save_IFS 22615 22616 ;; 22617 esac 22618 fi 22619 HG=$ac_cv_path_HG 22620 if test -n "$HG"; then 22621 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HG" >&5 22622 $as_echo "$HG" >&6; } 22623 else 22624 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22625 $as_echo "no" >&6; } 22626 fi 22627 22628 22629 if test "x$HG" = x; then 22630 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 22631 fi 22632 else 22633 # Otherwise we believe it is a complete path. Use it as it is. 22634 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool HG=$tool_specified" >&5 22635 $as_echo "$as_me: Will use user supplied tool HG=$tool_specified" >&6;} 22636 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HG" >&5 22637 $as_echo_n "checking for HG... " >&6; } 22638 if test ! -x "$tool_specified"; then 22639 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 22640 $as_echo "not found" >&6; } 22641 as_fn_error $? "User supplied tool HG=$tool_specified does not exist or is not executable" "$LINENO" 5 22642 fi 22643 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 22644 $as_echo "$tool_specified" >&6; } 22645 fi 22646 fi 22647 fi 22648 22649 fi 22650 22651 22652 22653 22654 # Publish this variable in the help. 22655 22656 22657 if [ -z "${STAT+x}" ]; then 22658 # The variable is not set by user, try to locate tool using the code snippet 22659 for ac_prog in stat 22660 do 22661 # Extract the first word of "$ac_prog", so it can be a program name with args. 22662 set dummy $ac_prog; ac_word=$2 22663 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22664 $as_echo_n "checking for $ac_word... " >&6; } 22665 if ${ac_cv_path_STAT+:} false; then : 22666 $as_echo_n "(cached) " >&6 22667 else 22668 case $STAT in 22669 [\\/]* | ?:[\\/]*) 22670 ac_cv_path_STAT="$STAT" # Let the user override the test with a path. 22671 ;; 22672 *) 22673 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22674 for as_dir in $PATH 22675 do 22676 IFS=$as_save_IFS 22677 test -z "$as_dir" && as_dir=. 22678 for ac_exec_ext in '' $ac_executable_extensions; do 22679 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22680 ac_cv_path_STAT="$as_dir/$ac_word$ac_exec_ext" 22681 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22682 break 2 22683 fi 22684 done 22685 done 22686 IFS=$as_save_IFS 22687 22688 ;; 22689 esac 22690 fi 22691 STAT=$ac_cv_path_STAT 22692 if test -n "$STAT"; then 22693 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAT" >&5 22694 $as_echo "$STAT" >&6; } 22695 else 22696 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22697 $as_echo "no" >&6; } 22698 fi 22699 22700 22701 test -n "$STAT" && break 22702 done 22703 22704 else 22705 # The variable is set, but is it from the command line or the environment? 22706 22707 # Try to remove the string !STAT! from our list. 22708 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!STAT!/} 22709 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 22710 # If it failed, the variable was not from the command line. Ignore it, 22711 # but warn the user (except for BASH, which is always set by the calling BASH). 22712 if test "xSTAT" != xBASH; then 22713 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of STAT from the environment. Use command line variables instead." >&5 22714 $as_echo "$as_me: WARNING: Ignoring value of STAT from the environment. Use command line variables instead." >&2;} 22715 fi 22716 # Try to locate tool using the code snippet 22717 for ac_prog in stat 22718 do 22719 # Extract the first word of "$ac_prog", so it can be a program name with args. 22720 set dummy $ac_prog; ac_word=$2 22721 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22722 $as_echo_n "checking for $ac_word... " >&6; } 22723 if ${ac_cv_path_STAT+:} false; then : 22724 $as_echo_n "(cached) " >&6 22725 else 22726 case $STAT in 22727 [\\/]* | ?:[\\/]*) 22728 ac_cv_path_STAT="$STAT" # Let the user override the test with a path. 22729 ;; 22730 *) 22731 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22732 for as_dir in $PATH 22733 do 22734 IFS=$as_save_IFS 22735 test -z "$as_dir" && as_dir=. 22736 for ac_exec_ext in '' $ac_executable_extensions; do 22737 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22738 ac_cv_path_STAT="$as_dir/$ac_word$ac_exec_ext" 22739 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22740 break 2 22741 fi 22742 done 22743 done 22744 IFS=$as_save_IFS 22745 22746 ;; 22747 esac 22748 fi 22749 STAT=$ac_cv_path_STAT 22750 if test -n "$STAT"; then 22751 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAT" >&5 22752 $as_echo "$STAT" >&6; } 22753 else 22754 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22755 $as_echo "no" >&6; } 22756 fi 22757 22758 22759 test -n "$STAT" && break 22760 done 22761 22762 else 22763 # If it succeeded, then it was overridden by the user. We will use it 22764 # for the tool. 22765 22766 # First remove it from the list of overridden variables, so we can test 22767 # for unknown variables in the end. 22768 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 22769 22770 # Check if we try to supply an empty value 22771 if test "x$STAT" = x; then 22772 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool STAT= (no value)" >&5 22773 $as_echo "$as_me: Setting user supplied tool STAT= (no value)" >&6;} 22774 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STAT" >&5 22775 $as_echo_n "checking for STAT... " >&6; } 22776 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 22777 $as_echo "disabled" >&6; } 22778 else 22779 # Check if the provided tool contains a complete path. 22780 tool_specified="$STAT" 22781 tool_basename="${tool_specified##*/}" 22782 if test "x$tool_basename" = "x$tool_specified"; then 22783 # A command without a complete path is provided, search $PATH. 22784 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool STAT=$tool_basename" >&5 22785 $as_echo "$as_me: Will search for user supplied tool STAT=$tool_basename" >&6;} 22786 # Extract the first word of "$tool_basename", so it can be a program name with args. 22787 set dummy $tool_basename; ac_word=$2 22788 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22789 $as_echo_n "checking for $ac_word... " >&6; } 22790 if ${ac_cv_path_STAT+:} false; then : 22791 $as_echo_n "(cached) " >&6 22792 else 22793 case $STAT in 22794 [\\/]* | ?:[\\/]*) 22795 ac_cv_path_STAT="$STAT" # Let the user override the test with a path. 22796 ;; 22797 *) 22798 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22799 for as_dir in $PATH 22800 do 22801 IFS=$as_save_IFS 22802 test -z "$as_dir" && as_dir=. 22803 for ac_exec_ext in '' $ac_executable_extensions; do 22804 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22805 ac_cv_path_STAT="$as_dir/$ac_word$ac_exec_ext" 22806 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22807 break 2 22808 fi 22809 done 22810 done 22811 IFS=$as_save_IFS 22812 22813 ;; 22814 esac 22815 fi 22816 STAT=$ac_cv_path_STAT 22817 if test -n "$STAT"; then 22818 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAT" >&5 22819 $as_echo "$STAT" >&6; } 22820 else 22821 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22822 $as_echo "no" >&6; } 22823 fi 22824 22825 22826 if test "x$STAT" = x; then 22827 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 22828 fi 22829 else 22830 # Otherwise we believe it is a complete path. Use it as it is. 22831 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool STAT=$tool_specified" >&5 22832 $as_echo "$as_me: Will use user supplied tool STAT=$tool_specified" >&6;} 22833 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STAT" >&5 22834 $as_echo_n "checking for STAT... " >&6; } 22835 if test ! -x "$tool_specified"; then 22836 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 22837 $as_echo "not found" >&6; } 22838 as_fn_error $? "User supplied tool STAT=$tool_specified does not exist or is not executable" "$LINENO" 5 22839 fi 22840 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 22841 $as_echo "$tool_specified" >&6; } 22842 fi 22843 fi 22844 fi 22845 22846 fi 22847 22848 22849 22850 22851 # Publish this variable in the help. 22852 22853 22854 if [ -z "${TIME+x}" ]; then 22855 # The variable is not set by user, try to locate tool using the code snippet 22856 for ac_prog in time 22857 do 22858 # Extract the first word of "$ac_prog", so it can be a program name with args. 22859 set dummy $ac_prog; ac_word=$2 22860 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22861 $as_echo_n "checking for $ac_word... " >&6; } 22862 if ${ac_cv_path_TIME+:} false; then : 22863 $as_echo_n "(cached) " >&6 22864 else 22865 case $TIME in 22866 [\\/]* | ?:[\\/]*) 22867 ac_cv_path_TIME="$TIME" # Let the user override the test with a path. 22868 ;; 22869 *) 22870 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22871 for as_dir in $PATH 22872 do 22873 IFS=$as_save_IFS 22874 test -z "$as_dir" && as_dir=. 22875 for ac_exec_ext in '' $ac_executable_extensions; do 22876 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22877 ac_cv_path_TIME="$as_dir/$ac_word$ac_exec_ext" 22878 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22879 break 2 22880 fi 22881 done 22882 done 22883 IFS=$as_save_IFS 22884 22885 ;; 22886 esac 22887 fi 22888 TIME=$ac_cv_path_TIME 22889 if test -n "$TIME"; then 22890 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TIME" >&5 22891 $as_echo "$TIME" >&6; } 22892 else 22893 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22894 $as_echo "no" >&6; } 22895 fi 22896 22897 22898 test -n "$TIME" && break 22899 done 22900 22901 else 22902 # The variable is set, but is it from the command line or the environment? 22903 22904 # Try to remove the string !TIME! from our list. 22905 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TIME!/} 22906 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 22907 # If it failed, the variable was not from the command line. Ignore it, 22908 # but warn the user (except for BASH, which is always set by the calling BASH). 22909 if test "xTIME" != xBASH; then 22910 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TIME from the environment. Use command line variables instead." >&5 22911 $as_echo "$as_me: WARNING: Ignoring value of TIME from the environment. Use command line variables instead." >&2;} 22912 fi 22913 # Try to locate tool using the code snippet 22914 for ac_prog in time 22915 do 22916 # Extract the first word of "$ac_prog", so it can be a program name with args. 22917 set dummy $ac_prog; ac_word=$2 22918 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22919 $as_echo_n "checking for $ac_word... " >&6; } 22920 if ${ac_cv_path_TIME+:} false; then : 22921 $as_echo_n "(cached) " >&6 22922 else 22923 case $TIME in 22924 [\\/]* | ?:[\\/]*) 22925 ac_cv_path_TIME="$TIME" # Let the user override the test with a path. 22926 ;; 22927 *) 22928 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22929 for as_dir in $PATH 22930 do 22931 IFS=$as_save_IFS 22932 test -z "$as_dir" && as_dir=. 22933 for ac_exec_ext in '' $ac_executable_extensions; do 22934 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22935 ac_cv_path_TIME="$as_dir/$ac_word$ac_exec_ext" 22936 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22937 break 2 22938 fi 22939 done 22940 done 22941 IFS=$as_save_IFS 22942 22943 ;; 22944 esac 22945 fi 22946 TIME=$ac_cv_path_TIME 22947 if test -n "$TIME"; then 22948 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TIME" >&5 22949 $as_echo "$TIME" >&6; } 22950 else 22951 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22952 $as_echo "no" >&6; } 22953 fi 22954 22955 22956 test -n "$TIME" && break 22957 done 22958 22959 else 22960 # If it succeeded, then it was overridden by the user. We will use it 22961 # for the tool. 22962 22963 # First remove it from the list of overridden variables, so we can test 22964 # for unknown variables in the end. 22965 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 22966 22967 # Check if we try to supply an empty value 22968 if test "x$TIME" = x; then 22969 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TIME= (no value)" >&5 22970 $as_echo "$as_me: Setting user supplied tool TIME= (no value)" >&6;} 22971 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIME" >&5 22972 $as_echo_n "checking for TIME... " >&6; } 22973 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 22974 $as_echo "disabled" >&6; } 22975 else 22976 # Check if the provided tool contains a complete path. 22977 tool_specified="$TIME" 22978 tool_basename="${tool_specified##*/}" 22979 if test "x$tool_basename" = "x$tool_specified"; then 22980 # A command without a complete path is provided, search $PATH. 22981 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TIME=$tool_basename" >&5 22982 $as_echo "$as_me: Will search for user supplied tool TIME=$tool_basename" >&6;} 22983 # Extract the first word of "$tool_basename", so it can be a program name with args. 22984 set dummy $tool_basename; ac_word=$2 22985 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22986 $as_echo_n "checking for $ac_word... " >&6; } 22987 if ${ac_cv_path_TIME+:} false; then : 22988 $as_echo_n "(cached) " >&6 22989 else 22990 case $TIME in 22991 [\\/]* | ?:[\\/]*) 22992 ac_cv_path_TIME="$TIME" # Let the user override the test with a path. 22993 ;; 22994 *) 22995 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22996 for as_dir in $PATH 22997 do 22998 IFS=$as_save_IFS 22999 test -z "$as_dir" && as_dir=. 23000 for ac_exec_ext in '' $ac_executable_extensions; do 23001 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23002 ac_cv_path_TIME="$as_dir/$ac_word$ac_exec_ext" 23003 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23004 break 2 23005 fi 23006 done 23007 done 23008 IFS=$as_save_IFS 23009 23010 ;; 23011 esac 23012 fi 23013 TIME=$ac_cv_path_TIME 23014 if test -n "$TIME"; then 23015 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TIME" >&5 23016 $as_echo "$TIME" >&6; } 23017 else 23018 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23019 $as_echo "no" >&6; } 23020 fi 23021 23022 23023 if test "x$TIME" = x; then 23024 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 23025 fi 23026 else 23027 # Otherwise we believe it is a complete path. Use it as it is. 23028 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TIME=$tool_specified" >&5 23029 $as_echo "$as_me: Will use user supplied tool TIME=$tool_specified" >&6;} 23030 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIME" >&5 23031 $as_echo_n "checking for TIME... " >&6; } 23032 if test ! -x "$tool_specified"; then 23033 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 23034 $as_echo "not found" >&6; } 23035 as_fn_error $? "User supplied tool TIME=$tool_specified does not exist or is not executable" "$LINENO" 5 23036 fi 23037 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 23038 $as_echo "$tool_specified" >&6; } 23039 fi 23040 fi 23041 fi 23042 23043 fi 23044 23045 23046 # Dtrace is usually found in /usr/sbin on Solaris, but that directory may not 23047 # be in the user path. 23048 23049 23050 # Publish this variable in the help. 23051 23052 23053 if [ -z "${DTRACE+x}" ]; then 23054 # The variable is not set by user, try to locate tool using the code snippet 23055 for ac_prog in dtrace 23056 do 23057 # Extract the first word of "$ac_prog", so it can be a program name with args. 23058 set dummy $ac_prog; ac_word=$2 23059 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23060 $as_echo_n "checking for $ac_word... " >&6; } 23061 if ${ac_cv_path_DTRACE+:} false; then : 23062 $as_echo_n "(cached) " >&6 23063 else 23064 case $DTRACE in 23065 [\\/]* | ?:[\\/]*) 23066 ac_cv_path_DTRACE="$DTRACE" # Let the user override the test with a path. 23067 ;; 23068 *) 23069 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23070 as_dummy="$PATH:/usr/sbin" 23071 for as_dir in $as_dummy 23072 do 23073 IFS=$as_save_IFS 23074 test -z "$as_dir" && as_dir=. 23075 for ac_exec_ext in '' $ac_executable_extensions; do 23076 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23077 ac_cv_path_DTRACE="$as_dir/$ac_word$ac_exec_ext" 23078 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23079 break 2 23080 fi 23081 done 23082 done 23083 IFS=$as_save_IFS 23084 23085 ;; 23086 esac 23087 fi 23088 DTRACE=$ac_cv_path_DTRACE 23089 if test -n "$DTRACE"; then 23090 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DTRACE" >&5 23091 $as_echo "$DTRACE" >&6; } 23092 else 23093 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23094 $as_echo "no" >&6; } 23095 fi 23096 23097 23098 test -n "$DTRACE" && break 23099 done 23100 23101 else 23102 # The variable is set, but is it from the command line or the environment? 23103 23104 # Try to remove the string !DTRACE! from our list. 23105 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DTRACE!/} 23106 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 23107 # If it failed, the variable was not from the command line. Ignore it, 23108 # but warn the user (except for BASH, which is always set by the calling BASH). 23109 if test "xDTRACE" != xBASH; then 23110 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DTRACE from the environment. Use command line variables instead." >&5 23111 $as_echo "$as_me: WARNING: Ignoring value of DTRACE from the environment. Use command line variables instead." >&2;} 23112 fi 23113 # Try to locate tool using the code snippet 23114 for ac_prog in dtrace 23115 do 23116 # Extract the first word of "$ac_prog", so it can be a program name with args. 23117 set dummy $ac_prog; ac_word=$2 23118 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23119 $as_echo_n "checking for $ac_word... " >&6; } 23120 if ${ac_cv_path_DTRACE+:} false; then : 23121 $as_echo_n "(cached) " >&6 23122 else 23123 case $DTRACE in 23124 [\\/]* | ?:[\\/]*) 23125 ac_cv_path_DTRACE="$DTRACE" # Let the user override the test with a path. 23126 ;; 23127 *) 23128 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23129 as_dummy="$PATH:/usr/sbin" 23130 for as_dir in $as_dummy 23131 do 23132 IFS=$as_save_IFS 23133 test -z "$as_dir" && as_dir=. 23134 for ac_exec_ext in '' $ac_executable_extensions; do 23135 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23136 ac_cv_path_DTRACE="$as_dir/$ac_word$ac_exec_ext" 23137 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23138 break 2 23139 fi 23140 done 23141 done 23142 IFS=$as_save_IFS 23143 23144 ;; 23145 esac 23146 fi 23147 DTRACE=$ac_cv_path_DTRACE 23148 if test -n "$DTRACE"; then 23149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DTRACE" >&5 23150 $as_echo "$DTRACE" >&6; } 23151 else 23152 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23153 $as_echo "no" >&6; } 23154 fi 23155 23156 23157 test -n "$DTRACE" && break 23158 done 23159 23160 else 23161 # If it succeeded, then it was overridden by the user. We will use it 23162 # for the tool. 23163 23164 # First remove it from the list of overridden variables, so we can test 23165 # for unknown variables in the end. 23166 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 23167 23168 # Check if we try to supply an empty value 23169 if test "x$DTRACE" = x; then 23170 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DTRACE= (no value)" >&5 23171 $as_echo "$as_me: Setting user supplied tool DTRACE= (no value)" >&6;} 23172 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DTRACE" >&5 23173 $as_echo_n "checking for DTRACE... " >&6; } 23174 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 23175 $as_echo "disabled" >&6; } 23176 else 23177 # Check if the provided tool contains a complete path. 23178 tool_specified="$DTRACE" 23179 tool_basename="${tool_specified##*/}" 23180 if test "x$tool_basename" = "x$tool_specified"; then 23181 # A command without a complete path is provided, search $PATH. 23182 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DTRACE=$tool_basename" >&5 23183 $as_echo "$as_me: Will search for user supplied tool DTRACE=$tool_basename" >&6;} 23184 # Extract the first word of "$tool_basename", so it can be a program name with args. 23185 set dummy $tool_basename; ac_word=$2 23186 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23187 $as_echo_n "checking for $ac_word... " >&6; } 23188 if ${ac_cv_path_DTRACE+:} false; then : 23189 $as_echo_n "(cached) " >&6 23190 else 23191 case $DTRACE in 23192 [\\/]* | ?:[\\/]*) 23193 ac_cv_path_DTRACE="$DTRACE" # Let the user override the test with a path. 23194 ;; 23195 *) 23196 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23197 for as_dir in $PATH 23198 do 23199 IFS=$as_save_IFS 23200 test -z "$as_dir" && as_dir=. 23201 for ac_exec_ext in '' $ac_executable_extensions; do 23202 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23203 ac_cv_path_DTRACE="$as_dir/$ac_word$ac_exec_ext" 23204 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23205 break 2 23206 fi 23207 done 23208 done 23209 IFS=$as_save_IFS 23210 23211 ;; 23212 esac 23213 fi 23214 DTRACE=$ac_cv_path_DTRACE 23215 if test -n "$DTRACE"; then 23216 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DTRACE" >&5 23217 $as_echo "$DTRACE" >&6; } 23218 else 23219 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23220 $as_echo "no" >&6; } 23221 fi 23222 23223 23224 if test "x$DTRACE" = x; then 23225 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 23226 fi 23227 else 23228 # Otherwise we believe it is a complete path. Use it as it is. 23229 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DTRACE=$tool_specified" >&5 23230 $as_echo "$as_me: Will use user supplied tool DTRACE=$tool_specified" >&6;} 23231 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DTRACE" >&5 23232 $as_echo_n "checking for DTRACE... " >&6; } 23233 if test ! -x "$tool_specified"; then 23234 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 23235 $as_echo "not found" >&6; } 23236 as_fn_error $? "User supplied tool DTRACE=$tool_specified does not exist or is not executable" "$LINENO" 5 23237 fi 23238 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 23239 $as_echo "$tool_specified" >&6; } 23240 fi 23241 fi 23242 fi 23243 23244 fi 23245 23246 23247 23248 23249 # Publish this variable in the help. 23250 23251 23252 if [ -z "${PATCH+x}" ]; then 23253 # The variable is not set by user, try to locate tool using the code snippet 23254 for ac_prog in gpatch patch 23255 do 23256 # Extract the first word of "$ac_prog", so it can be a program name with args. 23257 set dummy $ac_prog; ac_word=$2 23258 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23259 $as_echo_n "checking for $ac_word... " >&6; } 23260 if ${ac_cv_path_PATCH+:} false; then : 23261 $as_echo_n "(cached) " >&6 23262 else 23263 case $PATCH in 23264 [\\/]* | ?:[\\/]*) 23265 ac_cv_path_PATCH="$PATCH" # Let the user override the test with a path. 23266 ;; 23267 *) 23268 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23269 for as_dir in $PATH 23270 do 23271 IFS=$as_save_IFS 23272 test -z "$as_dir" && as_dir=. 23273 for ac_exec_ext in '' $ac_executable_extensions; do 23274 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23275 ac_cv_path_PATCH="$as_dir/$ac_word$ac_exec_ext" 23276 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23277 break 2 23278 fi 23279 done 23280 done 23281 IFS=$as_save_IFS 23282 23283 ;; 23284 esac 23285 fi 23286 PATCH=$ac_cv_path_PATCH 23287 if test -n "$PATCH"; then 23288 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATCH" >&5 23289 $as_echo "$PATCH" >&6; } 23290 else 23291 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23292 $as_echo "no" >&6; } 23293 fi 23294 23295 23296 test -n "$PATCH" && break 23297 done 23298 23299 else 23300 # The variable is set, but is it from the command line or the environment? 23301 23302 # Try to remove the string !PATCH! from our list. 23303 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!PATCH!/} 23304 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 23305 # If it failed, the variable was not from the command line. Ignore it, 23306 # but warn the user (except for BASH, which is always set by the calling BASH). 23307 if test "xPATCH" != xBASH; then 23308 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of PATCH from the environment. Use command line variables instead." >&5 23309 $as_echo "$as_me: WARNING: Ignoring value of PATCH from the environment. Use command line variables instead." >&2;} 23310 fi 23311 # Try to locate tool using the code snippet 23312 for ac_prog in gpatch patch 23313 do 23314 # Extract the first word of "$ac_prog", so it can be a program name with args. 23315 set dummy $ac_prog; ac_word=$2 23316 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23317 $as_echo_n "checking for $ac_word... " >&6; } 23318 if ${ac_cv_path_PATCH+:} false; then : 23319 $as_echo_n "(cached) " >&6 23320 else 23321 case $PATCH in 23322 [\\/]* | ?:[\\/]*) 23323 ac_cv_path_PATCH="$PATCH" # Let the user override the test with a path. 23324 ;; 23325 *) 23326 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23327 for as_dir in $PATH 23328 do 23329 IFS=$as_save_IFS 23330 test -z "$as_dir" && as_dir=. 23331 for ac_exec_ext in '' $ac_executable_extensions; do 23332 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23333 ac_cv_path_PATCH="$as_dir/$ac_word$ac_exec_ext" 23334 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23335 break 2 23336 fi 23337 done 23338 done 23339 IFS=$as_save_IFS 23340 23341 ;; 23342 esac 23343 fi 23344 PATCH=$ac_cv_path_PATCH 23345 if test -n "$PATCH"; then 23346 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATCH" >&5 23347 $as_echo "$PATCH" >&6; } 23348 else 23349 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23350 $as_echo "no" >&6; } 23351 fi 23352 23353 23354 test -n "$PATCH" && break 23355 done 23356 23357 else 23358 # If it succeeded, then it was overridden by the user. We will use it 23359 # for the tool. 23360 23361 # First remove it from the list of overridden variables, so we can test 23362 # for unknown variables in the end. 23363 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 23364 23365 # Check if we try to supply an empty value 23366 if test "x$PATCH" = x; then 23367 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool PATCH= (no value)" >&5 23368 $as_echo "$as_me: Setting user supplied tool PATCH= (no value)" >&6;} 23369 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PATCH" >&5 23370 $as_echo_n "checking for PATCH... " >&6; } 23371 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 23372 $as_echo "disabled" >&6; } 23373 else 23374 # Check if the provided tool contains a complete path. 23375 tool_specified="$PATCH" 23376 tool_basename="${tool_specified##*/}" 23377 if test "x$tool_basename" = "x$tool_specified"; then 23378 # A command without a complete path is provided, search $PATH. 23379 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool PATCH=$tool_basename" >&5 23380 $as_echo "$as_me: Will search for user supplied tool PATCH=$tool_basename" >&6;} 23381 # Extract the first word of "$tool_basename", so it can be a program name with args. 23382 set dummy $tool_basename; ac_word=$2 23383 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23384 $as_echo_n "checking for $ac_word... " >&6; } 23385 if ${ac_cv_path_PATCH+:} false; then : 23386 $as_echo_n "(cached) " >&6 23387 else 23388 case $PATCH in 23389 [\\/]* | ?:[\\/]*) 23390 ac_cv_path_PATCH="$PATCH" # Let the user override the test with a path. 23391 ;; 23392 *) 23393 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23394 for as_dir in $PATH 23395 do 23396 IFS=$as_save_IFS 23397 test -z "$as_dir" && as_dir=. 23398 for ac_exec_ext in '' $ac_executable_extensions; do 23399 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23400 ac_cv_path_PATCH="$as_dir/$ac_word$ac_exec_ext" 23401 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23402 break 2 23403 fi 23404 done 23405 done 23406 IFS=$as_save_IFS 23407 23408 ;; 23409 esac 23410 fi 23411 PATCH=$ac_cv_path_PATCH 23412 if test -n "$PATCH"; then 23413 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATCH" >&5 23414 $as_echo "$PATCH" >&6; } 23415 else 23416 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23417 $as_echo "no" >&6; } 23418 fi 23419 23420 23421 if test "x$PATCH" = x; then 23422 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 23423 fi 23424 else 23425 # Otherwise we believe it is a complete path. Use it as it is. 23426 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool PATCH=$tool_specified" >&5 23427 $as_echo "$as_me: Will use user supplied tool PATCH=$tool_specified" >&6;} 23428 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PATCH" >&5 23429 $as_echo_n "checking for PATCH... " >&6; } 23430 if test ! -x "$tool_specified"; then 23431 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 23432 $as_echo "not found" >&6; } 23433 as_fn_error $? "User supplied tool PATCH=$tool_specified does not exist or is not executable" "$LINENO" 5 23434 fi 23435 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 23436 $as_echo "$tool_specified" >&6; } 23437 fi 23438 fi 23439 fi 23440 23441 fi 23442 23443 23444 # Check if it's GNU time 23445 IS_GNU_TIME=`$TIME --version 2>&1 | $GREP 'GNU time'` 23446 if test "x$IS_GNU_TIME" != x; then 23447 IS_GNU_TIME=yes 23448 else 23449 IS_GNU_TIME=no 23450 fi 23451 23452 23453 if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then 23454 23455 23456 23457 # Publish this variable in the help. 23458 23459 23460 if [ -z "${DSYMUTIL+x}" ]; then 23461 # The variable is not set by user, try to locate tool using the code snippet 23462 for ac_prog in dsymutil 23463 do 23464 # Extract the first word of "$ac_prog", so it can be a program name with args. 23465 set dummy $ac_prog; ac_word=$2 23466 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23467 $as_echo_n "checking for $ac_word... " >&6; } 23468 if ${ac_cv_path_DSYMUTIL+:} false; then : 23469 $as_echo_n "(cached) " >&6 23470 else 23471 case $DSYMUTIL in 23472 [\\/]* | ?:[\\/]*) 23473 ac_cv_path_DSYMUTIL="$DSYMUTIL" # Let the user override the test with a path. 23474 ;; 23475 *) 23476 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23477 for as_dir in $PATH 23478 do 23479 IFS=$as_save_IFS 23480 test -z "$as_dir" && as_dir=. 23481 for ac_exec_ext in '' $ac_executable_extensions; do 23482 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23483 ac_cv_path_DSYMUTIL="$as_dir/$ac_word$ac_exec_ext" 23484 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23485 break 2 23486 fi 23487 done 23488 done 23489 IFS=$as_save_IFS 23490 23491 ;; 23492 esac 23493 fi 23494 DSYMUTIL=$ac_cv_path_DSYMUTIL 23495 if test -n "$DSYMUTIL"; then 23496 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 23497 $as_echo "$DSYMUTIL" >&6; } 23498 else 23499 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23500 $as_echo "no" >&6; } 23501 fi 23502 23503 23504 test -n "$DSYMUTIL" && break 23505 done 23506 23507 else 23508 # The variable is set, but is it from the command line or the environment? 23509 23510 # Try to remove the string !DSYMUTIL! from our list. 23511 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DSYMUTIL!/} 23512 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 23513 # If it failed, the variable was not from the command line. Ignore it, 23514 # but warn the user (except for BASH, which is always set by the calling BASH). 23515 if test "xDSYMUTIL" != xBASH; then 23516 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DSYMUTIL from the environment. Use command line variables instead." >&5 23517 $as_echo "$as_me: WARNING: Ignoring value of DSYMUTIL from the environment. Use command line variables instead." >&2;} 23518 fi 23519 # Try to locate tool using the code snippet 23520 for ac_prog in dsymutil 23521 do 23522 # Extract the first word of "$ac_prog", so it can be a program name with args. 23523 set dummy $ac_prog; ac_word=$2 23524 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23525 $as_echo_n "checking for $ac_word... " >&6; } 23526 if ${ac_cv_path_DSYMUTIL+:} false; then : 23527 $as_echo_n "(cached) " >&6 23528 else 23529 case $DSYMUTIL in 23530 [\\/]* | ?:[\\/]*) 23531 ac_cv_path_DSYMUTIL="$DSYMUTIL" # Let the user override the test with a path. 23532 ;; 23533 *) 23534 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23535 for as_dir in $PATH 23536 do 23537 IFS=$as_save_IFS 23538 test -z "$as_dir" && as_dir=. 23539 for ac_exec_ext in '' $ac_executable_extensions; do 23540 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23541 ac_cv_path_DSYMUTIL="$as_dir/$ac_word$ac_exec_ext" 23542 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23543 break 2 23544 fi 23545 done 23546 done 23547 IFS=$as_save_IFS 23548 23549 ;; 23550 esac 23551 fi 23552 DSYMUTIL=$ac_cv_path_DSYMUTIL 23553 if test -n "$DSYMUTIL"; then 23554 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 23555 $as_echo "$DSYMUTIL" >&6; } 23556 else 23557 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23558 $as_echo "no" >&6; } 23559 fi 23560 23561 23562 test -n "$DSYMUTIL" && break 23563 done 23564 23565 else 23566 # If it succeeded, then it was overridden by the user. We will use it 23567 # for the tool. 23568 23569 # First remove it from the list of overridden variables, so we can test 23570 # for unknown variables in the end. 23571 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 23572 23573 # Check if we try to supply an empty value 23574 if test "x$DSYMUTIL" = x; then 23575 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DSYMUTIL= (no value)" >&5 23576 $as_echo "$as_me: Setting user supplied tool DSYMUTIL= (no value)" >&6;} 23577 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DSYMUTIL" >&5 23578 $as_echo_n "checking for DSYMUTIL... " >&6; } 23579 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 23580 $as_echo "disabled" >&6; } 23581 else 23582 # Check if the provided tool contains a complete path. 23583 tool_specified="$DSYMUTIL" 23584 tool_basename="${tool_specified##*/}" 23585 if test "x$tool_basename" = "x$tool_specified"; then 23586 # A command without a complete path is provided, search $PATH. 23587 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DSYMUTIL=$tool_basename" >&5 23588 $as_echo "$as_me: Will search for user supplied tool DSYMUTIL=$tool_basename" >&6;} 23589 # Extract the first word of "$tool_basename", so it can be a program name with args. 23590 set dummy $tool_basename; ac_word=$2 23591 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23592 $as_echo_n "checking for $ac_word... " >&6; } 23593 if ${ac_cv_path_DSYMUTIL+:} false; then : 23594 $as_echo_n "(cached) " >&6 23595 else 23596 case $DSYMUTIL in 23597 [\\/]* | ?:[\\/]*) 23598 ac_cv_path_DSYMUTIL="$DSYMUTIL" # Let the user override the test with a path. 23599 ;; 23600 *) 23601 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23602 for as_dir in $PATH 23603 do 23604 IFS=$as_save_IFS 23605 test -z "$as_dir" && as_dir=. 23606 for ac_exec_ext in '' $ac_executable_extensions; do 23607 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23608 ac_cv_path_DSYMUTIL="$as_dir/$ac_word$ac_exec_ext" 23609 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23610 break 2 23611 fi 23612 done 23613 done 23614 IFS=$as_save_IFS 23615 23616 ;; 23617 esac 23618 fi 23619 DSYMUTIL=$ac_cv_path_DSYMUTIL 23620 if test -n "$DSYMUTIL"; then 23621 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 23622 $as_echo "$DSYMUTIL" >&6; } 23623 else 23624 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23625 $as_echo "no" >&6; } 23626 fi 23627 23628 23629 if test "x$DSYMUTIL" = x; then 23630 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 23631 fi 23632 else 23633 # Otherwise we believe it is a complete path. Use it as it is. 23634 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DSYMUTIL=$tool_specified" >&5 23635 $as_echo "$as_me: Will use user supplied tool DSYMUTIL=$tool_specified" >&6;} 23636 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DSYMUTIL" >&5 23637 $as_echo_n "checking for DSYMUTIL... " >&6; } 23638 if test ! -x "$tool_specified"; then 23639 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 23640 $as_echo "not found" >&6; } 23641 as_fn_error $? "User supplied tool DSYMUTIL=$tool_specified does not exist or is not executable" "$LINENO" 5 23642 fi 23643 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 23644 $as_echo "$tool_specified" >&6; } 23645 fi 23646 fi 23647 fi 23648 23649 fi 23650 23651 23652 23653 if test "x$DSYMUTIL" = x; then 23654 as_fn_error $? "Could not find required tool for DSYMUTIL" "$LINENO" 5 23655 fi 23656 23657 23658 23659 23660 23661 # Publish this variable in the help. 23662 23663 23664 if [ -z "${XATTR+x}" ]; then 23665 # The variable is not set by user, try to locate tool using the code snippet 23666 for ac_prog in xattr 23667 do 23668 # Extract the first word of "$ac_prog", so it can be a program name with args. 23669 set dummy $ac_prog; ac_word=$2 23670 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23671 $as_echo_n "checking for $ac_word... " >&6; } 23672 if ${ac_cv_path_XATTR+:} false; then : 23673 $as_echo_n "(cached) " >&6 23674 else 23675 case $XATTR in 23676 [\\/]* | ?:[\\/]*) 23677 ac_cv_path_XATTR="$XATTR" # Let the user override the test with a path. 23678 ;; 23679 *) 23680 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23681 for as_dir in $PATH 23682 do 23683 IFS=$as_save_IFS 23684 test -z "$as_dir" && as_dir=. 23685 for ac_exec_ext in '' $ac_executable_extensions; do 23686 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23687 ac_cv_path_XATTR="$as_dir/$ac_word$ac_exec_ext" 23688 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23689 break 2 23690 fi 23691 done 23692 done 23693 IFS=$as_save_IFS 23694 23695 ;; 23696 esac 23697 fi 23698 XATTR=$ac_cv_path_XATTR 23699 if test -n "$XATTR"; then 23700 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XATTR" >&5 23701 $as_echo "$XATTR" >&6; } 23702 else 23703 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23704 $as_echo "no" >&6; } 23705 fi 23706 23707 23708 test -n "$XATTR" && break 23709 done 23710 23711 else 23712 # The variable is set, but is it from the command line or the environment? 23713 23714 # Try to remove the string !XATTR! from our list. 23715 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!XATTR!/} 23716 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 23717 # If it failed, the variable was not from the command line. Ignore it, 23718 # but warn the user (except for BASH, which is always set by the calling BASH). 23719 if test "xXATTR" != xBASH; then 23720 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of XATTR from the environment. Use command line variables instead." >&5 23721 $as_echo "$as_me: WARNING: Ignoring value of XATTR from the environment. Use command line variables instead." >&2;} 23722 fi 23723 # Try to locate tool using the code snippet 23724 for ac_prog in xattr 23725 do 23726 # Extract the first word of "$ac_prog", so it can be a program name with args. 23727 set dummy $ac_prog; ac_word=$2 23728 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23729 $as_echo_n "checking for $ac_word... " >&6; } 23730 if ${ac_cv_path_XATTR+:} false; then : 23731 $as_echo_n "(cached) " >&6 23732 else 23733 case $XATTR in 23734 [\\/]* | ?:[\\/]*) 23735 ac_cv_path_XATTR="$XATTR" # Let the user override the test with a path. 23736 ;; 23737 *) 23738 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23739 for as_dir in $PATH 23740 do 23741 IFS=$as_save_IFS 23742 test -z "$as_dir" && as_dir=. 23743 for ac_exec_ext in '' $ac_executable_extensions; do 23744 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23745 ac_cv_path_XATTR="$as_dir/$ac_word$ac_exec_ext" 23746 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23747 break 2 23748 fi 23749 done 23750 done 23751 IFS=$as_save_IFS 23752 23753 ;; 23754 esac 23755 fi 23756 XATTR=$ac_cv_path_XATTR 23757 if test -n "$XATTR"; then 23758 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XATTR" >&5 23759 $as_echo "$XATTR" >&6; } 23760 else 23761 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23762 $as_echo "no" >&6; } 23763 fi 23764 23765 23766 test -n "$XATTR" && break 23767 done 23768 23769 else 23770 # If it succeeded, then it was overridden by the user. We will use it 23771 # for the tool. 23772 23773 # First remove it from the list of overridden variables, so we can test 23774 # for unknown variables in the end. 23775 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 23776 23777 # Check if we try to supply an empty value 23778 if test "x$XATTR" = x; then 23779 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool XATTR= (no value)" >&5 23780 $as_echo "$as_me: Setting user supplied tool XATTR= (no value)" >&6;} 23781 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XATTR" >&5 23782 $as_echo_n "checking for XATTR... " >&6; } 23783 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 23784 $as_echo "disabled" >&6; } 23785 else 23786 # Check if the provided tool contains a complete path. 23787 tool_specified="$XATTR" 23788 tool_basename="${tool_specified##*/}" 23789 if test "x$tool_basename" = "x$tool_specified"; then 23790 # A command without a complete path is provided, search $PATH. 23791 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool XATTR=$tool_basename" >&5 23792 $as_echo "$as_me: Will search for user supplied tool XATTR=$tool_basename" >&6;} 23793 # Extract the first word of "$tool_basename", so it can be a program name with args. 23794 set dummy $tool_basename; ac_word=$2 23795 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23796 $as_echo_n "checking for $ac_word... " >&6; } 23797 if ${ac_cv_path_XATTR+:} false; then : 23798 $as_echo_n "(cached) " >&6 23799 else 23800 case $XATTR in 23801 [\\/]* | ?:[\\/]*) 23802 ac_cv_path_XATTR="$XATTR" # Let the user override the test with a path. 23803 ;; 23804 *) 23805 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23806 for as_dir in $PATH 23807 do 23808 IFS=$as_save_IFS 23809 test -z "$as_dir" && as_dir=. 23810 for ac_exec_ext in '' $ac_executable_extensions; do 23811 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23812 ac_cv_path_XATTR="$as_dir/$ac_word$ac_exec_ext" 23813 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23814 break 2 23815 fi 23816 done 23817 done 23818 IFS=$as_save_IFS 23819 23820 ;; 23821 esac 23822 fi 23823 XATTR=$ac_cv_path_XATTR 23824 if test -n "$XATTR"; then 23825 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XATTR" >&5 23826 $as_echo "$XATTR" >&6; } 23827 else 23828 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23829 $as_echo "no" >&6; } 23830 fi 23831 23832 23833 if test "x$XATTR" = x; then 23834 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 23835 fi 23836 else 23837 # Otherwise we believe it is a complete path. Use it as it is. 23838 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool XATTR=$tool_specified" >&5 23839 $as_echo "$as_me: Will use user supplied tool XATTR=$tool_specified" >&6;} 23840 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XATTR" >&5 23841 $as_echo_n "checking for XATTR... " >&6; } 23842 if test ! -x "$tool_specified"; then 23843 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 23844 $as_echo "not found" >&6; } 23845 as_fn_error $? "User supplied tool XATTR=$tool_specified does not exist or is not executable" "$LINENO" 5 23846 fi 23847 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 23848 $as_echo "$tool_specified" >&6; } 23849 fi 23850 fi 23851 fi 23852 23853 fi 23854 23855 23856 23857 if test "x$XATTR" = x; then 23858 as_fn_error $? "Could not find required tool for XATTR" "$LINENO" 5 23859 fi 23860 23861 23862 23863 23864 # Publish this variable in the help. 23865 23866 23867 if [ -z "${CODESIGN+x}" ]; then 23868 # The variable is not set by user, try to locate tool using the code snippet 23869 for ac_prog in codesign 23870 do 23871 # Extract the first word of "$ac_prog", so it can be a program name with args. 23872 set dummy $ac_prog; ac_word=$2 23873 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23874 $as_echo_n "checking for $ac_word... " >&6; } 23875 if ${ac_cv_path_CODESIGN+:} false; then : 23876 $as_echo_n "(cached) " >&6 23877 else 23878 case $CODESIGN in 23879 [\\/]* | ?:[\\/]*) 23880 ac_cv_path_CODESIGN="$CODESIGN" # Let the user override the test with a path. 23881 ;; 23882 *) 23883 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23884 for as_dir in $PATH 23885 do 23886 IFS=$as_save_IFS 23887 test -z "$as_dir" && as_dir=. 23888 for ac_exec_ext in '' $ac_executable_extensions; do 23889 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23890 ac_cv_path_CODESIGN="$as_dir/$ac_word$ac_exec_ext" 23891 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23892 break 2 23893 fi 23894 done 23895 done 23896 IFS=$as_save_IFS 23897 23898 ;; 23899 esac 23900 fi 23901 CODESIGN=$ac_cv_path_CODESIGN 23902 if test -n "$CODESIGN"; then 23903 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CODESIGN" >&5 23904 $as_echo "$CODESIGN" >&6; } 23905 else 23906 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23907 $as_echo "no" >&6; } 23908 fi 23909 23910 23911 test -n "$CODESIGN" && break 23912 done 23913 23914 else 23915 # The variable is set, but is it from the command line or the environment? 23916 23917 # Try to remove the string !CODESIGN! from our list. 23918 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CODESIGN!/} 23919 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 23920 # If it failed, the variable was not from the command line. Ignore it, 23921 # but warn the user (except for BASH, which is always set by the calling BASH). 23922 if test "xCODESIGN" != xBASH; then 23923 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CODESIGN from the environment. Use command line variables instead." >&5 23924 $as_echo "$as_me: WARNING: Ignoring value of CODESIGN from the environment. Use command line variables instead." >&2;} 23925 fi 23926 # Try to locate tool using the code snippet 23927 for ac_prog in codesign 23928 do 23929 # Extract the first word of "$ac_prog", so it can be a program name with args. 23930 set dummy $ac_prog; ac_word=$2 23931 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23932 $as_echo_n "checking for $ac_word... " >&6; } 23933 if ${ac_cv_path_CODESIGN+:} false; then : 23934 $as_echo_n "(cached) " >&6 23935 else 23936 case $CODESIGN in 23937 [\\/]* | ?:[\\/]*) 23938 ac_cv_path_CODESIGN="$CODESIGN" # Let the user override the test with a path. 23939 ;; 23940 *) 23941 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23942 for as_dir in $PATH 23943 do 23944 IFS=$as_save_IFS 23945 test -z "$as_dir" && as_dir=. 23946 for ac_exec_ext in '' $ac_executable_extensions; do 23947 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23948 ac_cv_path_CODESIGN="$as_dir/$ac_word$ac_exec_ext" 23949 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23950 break 2 23951 fi 23952 done 23953 done 23954 IFS=$as_save_IFS 23955 23956 ;; 23957 esac 23958 fi 23959 CODESIGN=$ac_cv_path_CODESIGN 23960 if test -n "$CODESIGN"; then 23961 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CODESIGN" >&5 23962 $as_echo "$CODESIGN" >&6; } 23963 else 23964 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23965 $as_echo "no" >&6; } 23966 fi 23967 23968 23969 test -n "$CODESIGN" && break 23970 done 23971 23972 else 23973 # If it succeeded, then it was overridden by the user. We will use it 23974 # for the tool. 23975 23976 # First remove it from the list of overridden variables, so we can test 23977 # for unknown variables in the end. 23978 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 23979 23980 # Check if we try to supply an empty value 23981 if test "x$CODESIGN" = x; then 23982 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CODESIGN= (no value)" >&5 23983 $as_echo "$as_me: Setting user supplied tool CODESIGN= (no value)" >&6;} 23984 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CODESIGN" >&5 23985 $as_echo_n "checking for CODESIGN... " >&6; } 23986 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 23987 $as_echo "disabled" >&6; } 23988 else 23989 # Check if the provided tool contains a complete path. 23990 tool_specified="$CODESIGN" 23991 tool_basename="${tool_specified##*/}" 23992 if test "x$tool_basename" = "x$tool_specified"; then 23993 # A command without a complete path is provided, search $PATH. 23994 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CODESIGN=$tool_basename" >&5 23995 $as_echo "$as_me: Will search for user supplied tool CODESIGN=$tool_basename" >&6;} 23996 # Extract the first word of "$tool_basename", so it can be a program name with args. 23997 set dummy $tool_basename; ac_word=$2 23998 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23999 $as_echo_n "checking for $ac_word... " >&6; } 24000 if ${ac_cv_path_CODESIGN+:} false; then : 24001 $as_echo_n "(cached) " >&6 24002 else 24003 case $CODESIGN in 24004 [\\/]* | ?:[\\/]*) 24005 ac_cv_path_CODESIGN="$CODESIGN" # Let the user override the test with a path. 24006 ;; 24007 *) 24008 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24009 for as_dir in $PATH 24010 do 24011 IFS=$as_save_IFS 24012 test -z "$as_dir" && as_dir=. 24013 for ac_exec_ext in '' $ac_executable_extensions; do 24014 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24015 ac_cv_path_CODESIGN="$as_dir/$ac_word$ac_exec_ext" 24016 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24017 break 2 24018 fi 24019 done 24020 done 24021 IFS=$as_save_IFS 24022 24023 ;; 24024 esac 24025 fi 24026 CODESIGN=$ac_cv_path_CODESIGN 24027 if test -n "$CODESIGN"; then 24028 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CODESIGN" >&5 24029 $as_echo "$CODESIGN" >&6; } 24030 else 24031 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24032 $as_echo "no" >&6; } 24033 fi 24034 24035 24036 if test "x$CODESIGN" = x; then 24037 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 24038 fi 24039 else 24040 # Otherwise we believe it is a complete path. Use it as it is. 24041 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CODESIGN=$tool_specified" >&5 24042 $as_echo "$as_me: Will use user supplied tool CODESIGN=$tool_specified" >&6;} 24043 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CODESIGN" >&5 24044 $as_echo_n "checking for CODESIGN... " >&6; } 24045 if test ! -x "$tool_specified"; then 24046 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 24047 $as_echo "not found" >&6; } 24048 as_fn_error $? "User supplied tool CODESIGN=$tool_specified does not exist or is not executable" "$LINENO" 5 24049 fi 24050 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 24051 $as_echo "$tool_specified" >&6; } 24052 fi 24053 fi 24054 fi 24055 24056 fi 24057 24058 24059 if test "x$CODESIGN" != "x"; then 24060 # Verify that the openjdk_codesign certificate is present 24061 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if openjdk_codesign certificate is present" >&5 24062 $as_echo_n "checking if openjdk_codesign certificate is present... " >&6; } 24063 $RM codesign-testfile 24064 $TOUCH codesign-testfile 24065 $CODESIGN -s openjdk_codesign codesign-testfile 2>&5 >&5 || CODESIGN= 24066 $RM codesign-testfile 24067 if test "x$CODESIGN" = x; then 24068 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24069 $as_echo "no" >&6; } 24070 else 24071 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24072 $as_echo "yes" >&6; } 24073 fi 24074 fi 24075 24076 24077 24078 # Publish this variable in the help. 24079 24080 24081 if [ -z "${SETFILE+x}" ]; then 24082 # The variable is not set by user, try to locate tool using the code snippet 24083 for ac_prog in SetFile 24084 do 24085 # Extract the first word of "$ac_prog", so it can be a program name with args. 24086 set dummy $ac_prog; ac_word=$2 24087 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24088 $as_echo_n "checking for $ac_word... " >&6; } 24089 if ${ac_cv_path_SETFILE+:} false; then : 24090 $as_echo_n "(cached) " >&6 24091 else 24092 case $SETFILE in 24093 [\\/]* | ?:[\\/]*) 24094 ac_cv_path_SETFILE="$SETFILE" # Let the user override the test with a path. 24095 ;; 24096 *) 24097 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24098 for as_dir in $PATH 24099 do 24100 IFS=$as_save_IFS 24101 test -z "$as_dir" && as_dir=. 24102 for ac_exec_ext in '' $ac_executable_extensions; do 24103 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24104 ac_cv_path_SETFILE="$as_dir/$ac_word$ac_exec_ext" 24105 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24106 break 2 24107 fi 24108 done 24109 done 24110 IFS=$as_save_IFS 24111 24112 ;; 24113 esac 24114 fi 24115 SETFILE=$ac_cv_path_SETFILE 24116 if test -n "$SETFILE"; then 24117 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SETFILE" >&5 24118 $as_echo "$SETFILE" >&6; } 24119 else 24120 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24121 $as_echo "no" >&6; } 24122 fi 24123 24124 24125 test -n "$SETFILE" && break 24126 done 24127 24128 else 24129 # The variable is set, but is it from the command line or the environment? 24130 24131 # Try to remove the string !SETFILE! from our list. 24132 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SETFILE!/} 24133 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 24134 # If it failed, the variable was not from the command line. Ignore it, 24135 # but warn the user (except for BASH, which is always set by the calling BASH). 24136 if test "xSETFILE" != xBASH; then 24137 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SETFILE from the environment. Use command line variables instead." >&5 24138 $as_echo "$as_me: WARNING: Ignoring value of SETFILE from the environment. Use command line variables instead." >&2;} 24139 fi 24140 # Try to locate tool using the code snippet 24141 for ac_prog in SetFile 24142 do 24143 # Extract the first word of "$ac_prog", so it can be a program name with args. 24144 set dummy $ac_prog; ac_word=$2 24145 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24146 $as_echo_n "checking for $ac_word... " >&6; } 24147 if ${ac_cv_path_SETFILE+:} false; then : 24148 $as_echo_n "(cached) " >&6 24149 else 24150 case $SETFILE in 24151 [\\/]* | ?:[\\/]*) 24152 ac_cv_path_SETFILE="$SETFILE" # Let the user override the test with a path. 24153 ;; 24154 *) 24155 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24156 for as_dir in $PATH 24157 do 24158 IFS=$as_save_IFS 24159 test -z "$as_dir" && as_dir=. 24160 for ac_exec_ext in '' $ac_executable_extensions; do 24161 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24162 ac_cv_path_SETFILE="$as_dir/$ac_word$ac_exec_ext" 24163 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24164 break 2 24165 fi 24166 done 24167 done 24168 IFS=$as_save_IFS 24169 24170 ;; 24171 esac 24172 fi 24173 SETFILE=$ac_cv_path_SETFILE 24174 if test -n "$SETFILE"; then 24175 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SETFILE" >&5 24176 $as_echo "$SETFILE" >&6; } 24177 else 24178 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24179 $as_echo "no" >&6; } 24180 fi 24181 24182 24183 test -n "$SETFILE" && break 24184 done 24185 24186 else 24187 # If it succeeded, then it was overridden by the user. We will use it 24188 # for the tool. 24189 24190 # First remove it from the list of overridden variables, so we can test 24191 # for unknown variables in the end. 24192 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 24193 24194 # Check if we try to supply an empty value 24195 if test "x$SETFILE" = x; then 24196 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool SETFILE= (no value)" >&5 24197 $as_echo "$as_me: Setting user supplied tool SETFILE= (no value)" >&6;} 24198 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SETFILE" >&5 24199 $as_echo_n "checking for SETFILE... " >&6; } 24200 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 24201 $as_echo "disabled" >&6; } 24202 else 24203 # Check if the provided tool contains a complete path. 24204 tool_specified="$SETFILE" 24205 tool_basename="${tool_specified##*/}" 24206 if test "x$tool_basename" = "x$tool_specified"; then 24207 # A command without a complete path is provided, search $PATH. 24208 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SETFILE=$tool_basename" >&5 24209 $as_echo "$as_me: Will search for user supplied tool SETFILE=$tool_basename" >&6;} 24210 # Extract the first word of "$tool_basename", so it can be a program name with args. 24211 set dummy $tool_basename; ac_word=$2 24212 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24213 $as_echo_n "checking for $ac_word... " >&6; } 24214 if ${ac_cv_path_SETFILE+:} false; then : 24215 $as_echo_n "(cached) " >&6 24216 else 24217 case $SETFILE in 24218 [\\/]* | ?:[\\/]*) 24219 ac_cv_path_SETFILE="$SETFILE" # Let the user override the test with a path. 24220 ;; 24221 *) 24222 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24223 for as_dir in $PATH 24224 do 24225 IFS=$as_save_IFS 24226 test -z "$as_dir" && as_dir=. 24227 for ac_exec_ext in '' $ac_executable_extensions; do 24228 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24229 ac_cv_path_SETFILE="$as_dir/$ac_word$ac_exec_ext" 24230 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24231 break 2 24232 fi 24233 done 24234 done 24235 IFS=$as_save_IFS 24236 24237 ;; 24238 esac 24239 fi 24240 SETFILE=$ac_cv_path_SETFILE 24241 if test -n "$SETFILE"; then 24242 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SETFILE" >&5 24243 $as_echo "$SETFILE" >&6; } 24244 else 24245 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24246 $as_echo "no" >&6; } 24247 fi 24248 24249 24250 if test "x$SETFILE" = x; then 24251 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 24252 fi 24253 else 24254 # Otherwise we believe it is a complete path. Use it as it is. 24255 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SETFILE=$tool_specified" >&5 24256 $as_echo "$as_me: Will use user supplied tool SETFILE=$tool_specified" >&6;} 24257 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SETFILE" >&5 24258 $as_echo_n "checking for SETFILE... " >&6; } 24259 if test ! -x "$tool_specified"; then 24260 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 24261 $as_echo "not found" >&6; } 24262 as_fn_error $? "User supplied tool SETFILE=$tool_specified does not exist or is not executable" "$LINENO" 5 24263 fi 24264 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 24265 $as_echo "$tool_specified" >&6; } 24266 fi 24267 fi 24268 fi 24269 24270 fi 24271 24272 24273 24274 if test "x$SETFILE" = x; then 24275 as_fn_error $? "Could not find required tool for SETFILE" "$LINENO" 5 24276 fi 24277 24278 24279 fi 24280 24281 24282 # Check bash version 24283 # Extra [ ] to stop m4 mangling 24284 BASH_VER=`$BASH --version | $SED -n -e 's/^.*bash.*ersion *\([0-9.]*\).*$/\1/ p'` 24285 { $as_echo "$as_me:${as_lineno-$LINENO}: checking bash version" >&5 24286 $as_echo_n "checking bash version... " >&6; } 24287 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH_VER" >&5 24288 $as_echo "$BASH_VER" >&6; } 24289 24290 BASH_MAJOR=`$ECHO $BASH_VER | $CUT -d . -f 1` 24291 BASH_MINOR=`$ECHO $BASH_VER | $CUT -d . -f 2` 24292 if test $BASH_MAJOR -lt 3 || (test $BASH_MAJOR -eq 3 && test $BASH_MINOR -lt 2); then 24293 as_fn_error $? "bash version 3.2 or better is required" "$LINENO" 5 24294 fi 24295 24296 # Test if bash supports pipefail. 24297 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if bash supports pipefail" >&5 24298 $as_echo_n "checking if bash supports pipefail... " >&6; } 24299 if ${BASH} -c 'set -o pipefail'; then 24300 BASH_ARGS="$BASH_ARGS -o pipefail" 24301 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24302 $as_echo "yes" >&6; } 24303 else 24304 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24305 $as_echo "no" >&6; } 24306 fi 24307 24308 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if bash supports errexit (-e)" >&5 24309 $as_echo_n "checking if bash supports errexit (-e)... " >&6; } 24310 if ${BASH} -e -c 'true'; then 24311 BASH_ARGS="$BASH_ARGS -e" 24312 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24313 $as_echo "yes" >&6; } 24314 else 24315 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24316 $as_echo "no" >&6; } 24317 fi 24318 24319 24320 24321 24322 # Check if pkg-config is available. 24323 24324 24325 if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then 24326 if test -n "$ac_tool_prefix"; then 24327 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. 24328 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 24329 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24330 $as_echo_n "checking for $ac_word... " >&6; } 24331 if ${ac_cv_path_PKG_CONFIG+:} false; then : 24332 $as_echo_n "(cached) " >&6 24333 else 24334 case $PKG_CONFIG in 24335 [\\/]* | ?:[\\/]*) 24336 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. 24337 ;; 24338 *) 24339 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24340 for as_dir in $PATH 24341 do 24342 IFS=$as_save_IFS 24343 test -z "$as_dir" && as_dir=. 24344 for ac_exec_ext in '' $ac_executable_extensions; do 24345 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24346 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" 24347 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24348 break 2 24349 fi 24350 done 24351 done 24352 IFS=$as_save_IFS 24353 24354 ;; 24355 esac 24356 fi 24357 PKG_CONFIG=$ac_cv_path_PKG_CONFIG 24358 if test -n "$PKG_CONFIG"; then 24359 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 24360 $as_echo "$PKG_CONFIG" >&6; } 24361 else 24362 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24363 $as_echo "no" >&6; } 24364 fi 24365 24366 24367 fi 24368 if test -z "$ac_cv_path_PKG_CONFIG"; then 24369 ac_pt_PKG_CONFIG=$PKG_CONFIG 24370 # Extract the first word of "pkg-config", so it can be a program name with args. 24371 set dummy pkg-config; ac_word=$2 24372 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24373 $as_echo_n "checking for $ac_word... " >&6; } 24374 if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then : 24375 $as_echo_n "(cached) " >&6 24376 else 24377 case $ac_pt_PKG_CONFIG in 24378 [\\/]* | ?:[\\/]*) 24379 ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path. 24380 ;; 24381 *) 24382 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24383 for as_dir in $PATH 24384 do 24385 IFS=$as_save_IFS 24386 test -z "$as_dir" && as_dir=. 24387 for ac_exec_ext in '' $ac_executable_extensions; do 24388 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24389 ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" 24390 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24391 break 2 24392 fi 24393 done 24394 done 24395 IFS=$as_save_IFS 24396 24397 ;; 24398 esac 24399 fi 24400 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG 24401 if test -n "$ac_pt_PKG_CONFIG"; then 24402 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5 24403 $as_echo "$ac_pt_PKG_CONFIG" >&6; } 24404 else 24405 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24406 $as_echo "no" >&6; } 24407 fi 24408 24409 if test "x$ac_pt_PKG_CONFIG" = x; then 24410 PKG_CONFIG="" 24411 else 24412 case $cross_compiling:$ac_tool_warned in 24413 yes:) 24414 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 24415 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 24416 ac_tool_warned=yes ;; 24417 esac 24418 PKG_CONFIG=$ac_pt_PKG_CONFIG 24419 fi 24420 else 24421 PKG_CONFIG="$ac_cv_path_PKG_CONFIG" 24422 fi 24423 24424 fi 24425 if test -n "$PKG_CONFIG"; then 24426 _pkg_min_version=0.9.0 24427 { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5 24428 $as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; } 24429 if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then 24430 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24431 $as_echo "yes" >&6; } 24432 else 24433 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24434 $as_echo "no" >&6; } 24435 PKG_CONFIG="" 24436 fi 24437 24438 fi 24439 24440 # After basic tools have been setup, we can check build os specific details. 24441 24442 ############################################################################### 24443 24444 # Note that this is the build platform OS version! 24445 24446 OS_VERSION="`uname -r | ${SED} 's!\.! !g' | ${SED} 's!-! !g'`" 24447 OS_VERSION_MAJOR="`${ECHO} ${OS_VERSION} | ${CUT} -f 1 -d ' '`" 24448 OS_VERSION_MINOR="`${ECHO} ${OS_VERSION} | ${CUT} -f 2 -d ' '`" 24449 OS_VERSION_MICRO="`${ECHO} ${OS_VERSION} | ${CUT} -f 3 -d ' '`" 24450 24451 24452 24453 24454 24455 # Misc basic settings 24456 24457 24458 # Check whether --with-default-make-target was given. 24459 if test "${with_default_make_target+set}" = set; then : 24460 withval=$with_default_make_target; 24461 fi 24462 24463 if test "x$with_default_make_target" = "x" \ 24464 || test "x$with_default_make_target" = "xyes"; then 24465 DEFAULT_MAKE_TARGET="exploded-image" 24466 elif test "x$with_default_make_target" = "xno"; then 24467 as_fn_error $? "--without-default-make-target is not a valid option" "$LINENO" 5 24468 else 24469 DEFAULT_MAKE_TARGET="$with_default_make_target" 24470 fi 24471 24472 24473 24474 24475 ############################################################################### 24476 # 24477 # Determine OpenJDK variants, options and version numbers. 24478 # 24479 ############################################################################### 24480 24481 # We need build & target for this. 24482 24483 # Should we build a JDK without a graphical UI? 24484 { $as_echo "$as_me:${as_lineno-$LINENO}: checking headless only" >&5 24485 $as_echo_n "checking headless only... " >&6; } 24486 # Check whether --enable-headless-only was given. 24487 if test "${enable_headless_only+set}" = set; then : 24488 enableval=$enable_headless_only; 24489 fi 24490 24491 24492 if test "x$enable_headless_only" = "xyes"; then 24493 ENABLE_HEADLESS_ONLY="true" 24494 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24495 $as_echo "yes" >&6; } 24496 elif test "x$enable_headless_only" = "xno"; then 24497 ENABLE_HEADLESS_ONLY="false" 24498 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24499 $as_echo "no" >&6; } 24500 elif test "x$enable_headless_only" = "x"; then 24501 ENABLE_HEADLESS_ONLY="false" 24502 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24503 $as_echo "no" >&6; } 24504 else 24505 as_fn_error $? "--enable-headless-only can only take yes or no" "$LINENO" 5 24506 fi 24507 24508 24509 24510 # Choose cacerts source file 24511 24512 # Check whether --with-cacerts-file was given. 24513 if test "${with_cacerts_file+set}" = set; then : 24514 withval=$with_cacerts_file; 24515 fi 24516 24517 if test "x$with_cacerts_file" != x; then 24518 CACERTS_FILE=$with_cacerts_file 24519 fi 24520 24521 24522 # Enable or disable unlimited crypto 24523 # Check whether --enable-unlimited-crypto was given. 24524 if test "${enable_unlimited_crypto+set}" = set; then : 24525 enableval=$enable_unlimited_crypto; 24526 else 24527 enable_unlimited_crypto=yes 24528 fi 24529 24530 if test "x$enable_unlimited_crypto" = "xyes"; then 24531 UNLIMITED_CRYPTO=true 24532 else 24533 UNLIMITED_CRYPTO=false 24534 fi 24535 24536 24537 # Should we build the serviceability agent (SA)? 24538 INCLUDE_SA=true 24539 if [[ " $JVM_VARIANTS " =~ " zero " ]] || [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 24540 INCLUDE_SA=false 24541 fi 24542 if test "x$OPENJDK_TARGET_OS" = xaix ; then 24543 INCLUDE_SA=false 24544 fi 24545 24546 24547 # Compress jars 24548 COMPRESS_JARS=false 24549 24550 24551 24552 # Setup default copyright year. Mostly overridden when building close to a new year. 24553 24554 # Check whether --with-copyright-year was given. 24555 if test "${with_copyright_year+set}" = set; then : 24556 withval=$with_copyright_year; 24557 fi 24558 24559 if test "x$with_copyright_year" = xyes; then 24560 as_fn_error $? "Copyright year must have a value" "$LINENO" 5 24561 elif test "x$with_copyright_year" != x; then 24562 COPYRIGHT_YEAR="$with_copyright_year" 24563 else 24564 COPYRIGHT_YEAR=`$DATE +'%Y'` 24565 fi 24566 24567 24568 24569 # Check whether --enable-keep-packaged-modules was given. 24570 if test "${enable_keep_packaged_modules+set}" = set; then : 24571 enableval=$enable_keep_packaged_modules; 24572 fi 24573 24574 24575 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if packaged modules are kept" >&5 24576 $as_echo_n "checking if packaged modules are kept... " >&6; } 24577 if test "x$enable_keep_packaged_modules" = "xyes"; then 24578 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24579 $as_echo "yes" >&6; } 24580 JLINK_KEEP_PACKAGED_MODULES=true 24581 elif test "x$enable_keep_packaged_modules" = "xno"; then 24582 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24583 $as_echo "no" >&6; } 24584 JLINK_KEEP_PACKAGED_MODULES=false 24585 elif test "x$enable_keep_packaged_modules" = "x"; then 24586 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (default)" >&5 24587 $as_echo "yes (default)" >&6; } 24588 JLINK_KEEP_PACKAGED_MODULES=true 24589 else 24590 { $as_echo "$as_me:${as_lineno-$LINENO}: result: error" >&5 24591 $as_echo "error" >&6; } 24592 as_fn_error $? "--enable-keep-packaged-modules accepts no argument" "$LINENO" 5 24593 fi 24594 24595 24596 24597 24598 # Warn user that old version arguments are deprecated. 24599 24600 24601 # Check whether --with-milestone was given. 24602 if test "${with_milestone+set}" = set; then : 24603 withval=$with_milestone; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-milestone is deprecated and will be ignored." >&5 24604 $as_echo "$as_me: WARNING: Option --with-milestone is deprecated and will be ignored." >&2;} 24605 fi 24606 24607 24608 24609 24610 # Check whether --with-update-version was given. 24611 if test "${with_update_version+set}" = set; then : 24612 withval=$with_update_version; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-update-version is deprecated and will be ignored." >&5 24613 $as_echo "$as_me: WARNING: Option --with-update-version is deprecated and will be ignored." >&2;} 24614 fi 24615 24616 24617 24618 24619 # Check whether --with-user-release-suffix was given. 24620 if test "${with_user_release_suffix+set}" = set; then : 24621 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 24622 $as_echo "$as_me: WARNING: Option --with-user-release-suffix is deprecated and will be ignored." >&2;} 24623 fi 24624 24625 24626 24627 24628 # Check whether --with-build-number was given. 24629 if test "${with_build_number+set}" = set; then : 24630 withval=$with_build_number; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-build-number is deprecated and will be ignored." >&5 24631 $as_echo "$as_me: WARNING: Option --with-build-number is deprecated and will be ignored." >&2;} 24632 fi 24633 24634 24635 24636 # Source the version numbers file 24637 . $AUTOCONF_DIR/version-numbers 24638 24639 # Some non-version number information is set in that file 24640 24641 24642 24643 24644 24645 24646 24647 24648 24649 # Override version from arguments 24650 24651 # If --with-version-string is set, process it first. It is possible to 24652 # override parts with more specific flags, since these are processed later. 24653 24654 # Check whether --with-version-string was given. 24655 if test "${with_version_string+set}" = set; then : 24656 withval=$with_version_string; 24657 fi 24658 24659 if test "x$with_version_string" = xyes; then 24660 as_fn_error $? "--with-version-string must have a value" "$LINENO" 5 24661 elif test "x$with_version_string" != x; then 24662 # Additional [] needed to keep m4 from mangling shell constructs. 24663 if [[ $with_version_string =~ ^([0-9]+)(\.([0-9]+))?(\.([0-9]+))?(\.([0-9]+))?(-([a-zA-Z]+))?((\+)([0-9]+)?(-([-a-zA-Z0-9.]+))?)?$ ]] ; then 24664 VERSION_MAJOR=${BASH_REMATCH[1]} 24665 VERSION_MINOR=${BASH_REMATCH[3]} 24666 VERSION_SECURITY=${BASH_REMATCH[5]} 24667 VERSION_PATCH=${BASH_REMATCH[7]} 24668 VERSION_PRE=${BASH_REMATCH[9]} 24669 version_plus_separator=${BASH_REMATCH[11]} 24670 VERSION_BUILD=${BASH_REMATCH[12]} 24671 VERSION_OPT=${BASH_REMATCH[14]} 24672 # Unspecified numerical fields are interpreted as 0. 24673 if test "x$VERSION_MINOR" = x; then 24674 VERSION_MINOR=0 24675 fi 24676 if test "x$VERSION_SECURITY" = x; then 24677 VERSION_SECURITY=0 24678 fi 24679 if test "x$VERSION_PATCH" = x; then 24680 VERSION_PATCH=0 24681 fi 24682 if test "x$version_plus_separator" != x \ 24683 && test "x$VERSION_BUILD$VERSION_OPT" = x; then 24684 as_fn_error $? "Version string contains + but both 'BUILD' and 'OPT' are missing" "$LINENO" 5 24685 fi 24686 # Stop the version part process from setting default values. 24687 # We still allow them to explicitly override though. 24688 NO_DEFAULT_VERSION_PARTS=true 24689 else 24690 as_fn_error $? "--with-version-string fails to parse as a valid version string: $with_version_string" "$LINENO" 5 24691 fi 24692 fi 24693 24694 24695 # Check whether --with-version-pre was given. 24696 if test "${with_version_pre+set}" = set; then : 24697 withval=$with_version_pre; with_version_pre_present=true 24698 else 24699 with_version_pre_present=false 24700 fi 24701 24702 24703 if test "x$with_version_pre_present" = xtrue; then 24704 if test "x$with_version_pre" = xyes; then 24705 as_fn_error $? "--with-version-pre must have a value" "$LINENO" 5 24706 elif test "x$with_version_pre" = xno; then 24707 # Interpret --without-* as empty string instead of the literal "no" 24708 VERSION_PRE= 24709 else 24710 # Only [a-zA-Z] is allowed in the VERSION_PRE. Outer [ ] to quote m4. 24711 VERSION_PRE=`$ECHO "$with_version_pre" | $TR -c -d '[a-z][A-Z]'` 24712 if test "x$VERSION_PRE" != "x$with_version_pre"; then 24713 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-version-pre value has been sanitized from '$with_version_pre' to '$VERSION_PRE'" >&5 24714 $as_echo "$as_me: WARNING: --with-version-pre value has been sanitized from '$with_version_pre' to '$VERSION_PRE'" >&2;} 24715 fi 24716 fi 24717 else 24718 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 24719 # Default is to use "internal" as pre 24720 VERSION_PRE="internal" 24721 fi 24722 fi 24723 24724 24725 # Check whether --with-version-opt was given. 24726 if test "${with_version_opt+set}" = set; then : 24727 withval=$with_version_opt; with_version_opt_present=true 24728 else 24729 with_version_opt_present=false 24730 fi 24731 24732 24733 if test "x$with_version_opt_present" = xtrue; then 24734 if test "x$with_version_opt" = xyes; then 24735 as_fn_error $? "--with-version-opt must have a value" "$LINENO" 5 24736 elif test "x$with_version_opt" = xno; then 24737 # Interpret --without-* as empty string instead of the literal "no" 24738 VERSION_OPT= 24739 else 24740 # Only [-.a-zA-Z0-9] is allowed in the VERSION_OPT. Outer [ ] to quote m4. 24741 VERSION_OPT=`$ECHO "$with_version_opt" | $TR -c -d '[a-z][A-Z][0-9].-'` 24742 if test "x$VERSION_OPT" != "x$with_version_opt"; then 24743 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-version-opt value has been sanitized from '$with_version_opt' to '$VERSION_OPT'" >&5 24744 $as_echo "$as_me: WARNING: --with-version-opt value has been sanitized from '$with_version_opt' to '$VERSION_OPT'" >&2;} 24745 fi 24746 fi 24747 else 24748 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 24749 # Default is to calculate a string like this 'adhoc.<username>.<base dir name>' 24750 # Outer [ ] to quote m4. 24751 basedirname=`$BASENAME "$TOPDIR" | $TR -d -c '[a-z][A-Z][0-9].-'` 24752 VERSION_OPT="adhoc.$USERNAME.$basedirname" 24753 fi 24754 fi 24755 24756 24757 # Check whether --with-version-build was given. 24758 if test "${with_version_build+set}" = set; then : 24759 withval=$with_version_build; with_version_build_present=true 24760 else 24761 with_version_build_present=false 24762 fi 24763 24764 24765 if test "x$with_version_build_present" = xtrue; then 24766 if test "x$with_version_build" = xyes; then 24767 as_fn_error $? "--with-version-build must have a value" "$LINENO" 5 24768 elif test "x$with_version_build" = xno; then 24769 # Interpret --without-* as empty string instead of the literal "no" 24770 VERSION_BUILD= 24771 elif test "x$with_version_build" = x; then 24772 VERSION_BUILD= 24773 else 24774 24775 # Additional [] needed to keep m4 from mangling shell constructs. 24776 if ! [[ "$with_version_build" =~ ^0*([1-9][0-9]*)|(0)$ ]] ; then 24777 as_fn_error $? "\"$with_version_build\" is not a valid numerical value for VERSION_BUILD" "$LINENO" 5 24778 fi 24779 # Extract the version number without leading zeros. 24780 cleaned_value=${BASH_REMATCH[1]} 24781 if test "x$cleaned_value" = x; then 24782 # Special case for zero 24783 cleaned_value=${BASH_REMATCH[2]} 24784 fi 24785 24786 if test $cleaned_value -gt 255; then 24787 as_fn_error $? "VERSION_BUILD is given as $with_version_build. This is greater than 255 which is not allowed." "$LINENO" 5 24788 fi 24789 if test "x$cleaned_value" != "x$with_version_build"; then 24790 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Value for VERSION_BUILD has been sanitized from '$with_version_build' to '$cleaned_value'" >&5 24791 $as_echo "$as_me: WARNING: Value for VERSION_BUILD has been sanitized from '$with_version_build' to '$cleaned_value'" >&2;} 24792 fi 24793 VERSION_BUILD=$cleaned_value 24794 24795 fi 24796 else 24797 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 24798 # Default is to not have a build number. 24799 VERSION_BUILD="" 24800 # FIXME: Until all code can cope with an empty VERSION_BUILD, set it to 0. 24801 VERSION_BUILD=0 24802 fi 24803 fi 24804 24805 24806 # Check whether --with-version-major was given. 24807 if test "${with_version_major+set}" = set; then : 24808 withval=$with_version_major; with_version_major_present=true 24809 else 24810 with_version_major_present=false 24811 fi 24812 24813 24814 if test "x$with_version_major_present" = xtrue; then 24815 if test "x$with_version_major" = xyes; then 24816 as_fn_error $? "--with-version-major must have a value" "$LINENO" 5 24817 else 24818 24819 # Additional [] needed to keep m4 from mangling shell constructs. 24820 if ! [[ "$with_version_major" =~ ^0*([1-9][0-9]*)|(0)$ ]] ; then 24821 as_fn_error $? "\"$with_version_major\" is not a valid numerical value for VERSION_MAJOR" "$LINENO" 5 24822 fi 24823 # Extract the version number without leading zeros. 24824 cleaned_value=${BASH_REMATCH[1]} 24825 if test "x$cleaned_value" = x; then 24826 # Special case for zero 24827 cleaned_value=${BASH_REMATCH[2]} 24828 fi 24829 24830 if test $cleaned_value -gt 255; then 24831 as_fn_error $? "VERSION_MAJOR is given as $with_version_major. This is greater than 255 which is not allowed." "$LINENO" 5 24832 fi 24833 if test "x$cleaned_value" != "x$with_version_major"; then 24834 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Value for VERSION_MAJOR has been sanitized from '$with_version_major' to '$cleaned_value'" >&5 24835 $as_echo "$as_me: WARNING: Value for VERSION_MAJOR has been sanitized from '$with_version_major' to '$cleaned_value'" >&2;} 24836 fi 24837 VERSION_MAJOR=$cleaned_value 24838 24839 fi 24840 else 24841 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 24842 # Default is to get value from version-numbers 24843 VERSION_MAJOR="$DEFAULT_VERSION_MAJOR" 24844 fi 24845 fi 24846 24847 24848 # Check whether --with-version-minor was given. 24849 if test "${with_version_minor+set}" = set; then : 24850 withval=$with_version_minor; with_version_minor_present=true 24851 else 24852 with_version_minor_present=false 24853 fi 24854 24855 24856 if test "x$with_version_minor_present" = xtrue; then 24857 if test "x$with_version_minor" = xyes; then 24858 as_fn_error $? "--with-version-minor must have a value" "$LINENO" 5 24859 elif test "x$with_version_minor" = xno; then 24860 # Interpret --without-* as empty string (i.e. 0) instead of the literal "no" 24861 VERSION_MINOR=0 24862 elif test "x$with_version_minor" = x; then 24863 VERSION_MINOR=0 24864 else 24865 24866 # Additional [] needed to keep m4 from mangling shell constructs. 24867 if ! [[ "$with_version_minor" =~ ^0*([1-9][0-9]*)|(0)$ ]] ; then 24868 as_fn_error $? "\"$with_version_minor\" is not a valid numerical value for VERSION_MINOR" "$LINENO" 5 24869 fi 24870 # Extract the version number without leading zeros. 24871 cleaned_value=${BASH_REMATCH[1]} 24872 if test "x$cleaned_value" = x; then 24873 # Special case for zero 24874 cleaned_value=${BASH_REMATCH[2]} 24875 fi 24876 24877 if test $cleaned_value -gt 255; then 24878 as_fn_error $? "VERSION_MINOR is given as $with_version_minor. This is greater than 255 which is not allowed." "$LINENO" 5 24879 fi 24880 if test "x$cleaned_value" != "x$with_version_minor"; then 24881 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Value for VERSION_MINOR has been sanitized from '$with_version_minor' to '$cleaned_value'" >&5 24882 $as_echo "$as_me: WARNING: Value for VERSION_MINOR has been sanitized from '$with_version_minor' to '$cleaned_value'" >&2;} 24883 fi 24884 VERSION_MINOR=$cleaned_value 24885 24886 fi 24887 else 24888 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 24889 # Default is 0, if unspecified 24890 VERSION_MINOR=$DEFAULT_VERSION_MINOR 24891 fi 24892 fi 24893 24894 24895 # Check whether --with-version-security was given. 24896 if test "${with_version_security+set}" = set; then : 24897 withval=$with_version_security; with_version_security_present=true 24898 else 24899 with_version_security_present=false 24900 fi 24901 24902 24903 if test "x$with_version_security_present" = xtrue; then 24904 if test "x$with_version_security" = xyes; then 24905 as_fn_error $? "--with-version-security must have a value" "$LINENO" 5 24906 elif test "x$with_version_security" = xno; then 24907 # Interpret --without-* as empty string (i.e. 0) instead of the literal "no" 24908 VERSION_SECURITY=0 24909 elif test "x$with_version_security" = x; then 24910 VERSION_SECURITY=0 24911 else 24912 24913 # Additional [] needed to keep m4 from mangling shell constructs. 24914 if ! [[ "$with_version_security" =~ ^0*([1-9][0-9]*)|(0)$ ]] ; then 24915 as_fn_error $? "\"$with_version_security\" is not a valid numerical value for VERSION_SECURITY" "$LINENO" 5 24916 fi 24917 # Extract the version number without leading zeros. 24918 cleaned_value=${BASH_REMATCH[1]} 24919 if test "x$cleaned_value" = x; then 24920 # Special case for zero 24921 cleaned_value=${BASH_REMATCH[2]} 24922 fi 24923 24924 if test $cleaned_value -gt 255; then 24925 as_fn_error $? "VERSION_SECURITY is given as $with_version_security. This is greater than 255 which is not allowed." "$LINENO" 5 24926 fi 24927 if test "x$cleaned_value" != "x$with_version_security"; then 24928 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Value for VERSION_SECURITY has been sanitized from '$with_version_security' to '$cleaned_value'" >&5 24929 $as_echo "$as_me: WARNING: Value for VERSION_SECURITY has been sanitized from '$with_version_security' to '$cleaned_value'" >&2;} 24930 fi 24931 VERSION_SECURITY=$cleaned_value 24932 24933 fi 24934 else 24935 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 24936 # Default is 0, if unspecified 24937 VERSION_SECURITY=$DEFAULT_VERSION_SECURITY 24938 fi 24939 fi 24940 24941 24942 # Check whether --with-version-patch was given. 24943 if test "${with_version_patch+set}" = set; then : 24944 withval=$with_version_patch; with_version_patch_present=true 24945 else 24946 with_version_patch_present=false 24947 fi 24948 24949 24950 if test "x$with_version_patch_present" = xtrue; then 24951 if test "x$with_version_patch" = xyes; then 24952 as_fn_error $? "--with-version-patch must have a value" "$LINENO" 5 24953 elif test "x$with_version_patch" = xno; then 24954 # Interpret --without-* as empty string (i.e. 0) instead of the literal "no" 24955 VERSION_PATCH=0 24956 elif test "x$with_version_patch" = x; then 24957 VERSION_PATCH=0 24958 else 24959 24960 # Additional [] needed to keep m4 from mangling shell constructs. 24961 if ! [[ "$with_version_patch" =~ ^0*([1-9][0-9]*)|(0)$ ]] ; then 24962 as_fn_error $? "\"$with_version_patch\" is not a valid numerical value for VERSION_PATCH" "$LINENO" 5 24963 fi 24964 # Extract the version number without leading zeros. 24965 cleaned_value=${BASH_REMATCH[1]} 24966 if test "x$cleaned_value" = x; then 24967 # Special case for zero 24968 cleaned_value=${BASH_REMATCH[2]} 24969 fi 24970 24971 if test $cleaned_value -gt 255; then 24972 as_fn_error $? "VERSION_PATCH is given as $with_version_patch. This is greater than 255 which is not allowed." "$LINENO" 5 24973 fi 24974 if test "x$cleaned_value" != "x$with_version_patch"; then 24975 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Value for VERSION_PATCH has been sanitized from '$with_version_patch' to '$cleaned_value'" >&5 24976 $as_echo "$as_me: WARNING: Value for VERSION_PATCH has been sanitized from '$with_version_patch' to '$cleaned_value'" >&2;} 24977 fi 24978 VERSION_PATCH=$cleaned_value 24979 24980 fi 24981 else 24982 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 24983 # Default is 0, if unspecified 24984 VERSION_PATCH=$DEFAULT_VERSION_PATCH 24985 fi 24986 fi 24987 24988 # Calculate derived version properties 24989 24990 # Set VERSION_IS_GA based on if VERSION_PRE has a value 24991 if test "x$VERSION_PRE" = x; then 24992 VERSION_IS_GA=true 24993 else 24994 VERSION_IS_GA=false 24995 fi 24996 24997 # VERSION_NUMBER but always with exactly 4 positions, with 0 for empty positions. 24998 VERSION_NUMBER_FOUR_POSITIONS=$VERSION_MAJOR.$VERSION_MINOR.$VERSION_SECURITY.$VERSION_PATCH 24999 25000 stripped_version_number=$VERSION_NUMBER_FOUR_POSITIONS 25001 # Strip trailing zeroes from stripped_version_number 25002 for i in 1 2 3 ; do stripped_version_number=${stripped_version_number%.0} ; done 25003 VERSION_NUMBER=$stripped_version_number 25004 25005 # The complete version string, with additional build information 25006 if test "x$VERSION_BUILD$VERSION_OPT" = x; then 25007 VERSION_STRING=$VERSION_NUMBER${VERSION_PRE:+-$VERSION_PRE} 25008 else 25009 # If either build or opt is set, we need a + separator 25010 VERSION_STRING=$VERSION_NUMBER${VERSION_PRE:+-$VERSION_PRE}+$VERSION_BUILD${VERSION_OPT:+-$VERSION_OPT} 25011 fi 25012 25013 # The short version string, just VERSION_NUMBER and PRE, if present. 25014 VERSION_SHORT=$VERSION_NUMBER${VERSION_PRE:+-$VERSION_PRE} 25015 25016 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for version string" >&5 25017 $as_echo_n "checking for version string... " >&6; } 25018 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $VERSION_STRING" >&5 25019 $as_echo "$VERSION_STRING" >&6; } 25020 25021 25022 25023 25024 25025 25026 25027 25028 25029 25030 25031 25032 25033 25034 25035 ############################################################################### 25036 # 25037 # Setup BootJDK, used to bootstrap the build. 25038 # 25039 ############################################################################### 25040 25041 25042 BOOT_JDK_FOUND=no 25043 25044 # Check whether --with-boot-jdk was given. 25045 if test "${with_boot_jdk+set}" = set; then : 25046 withval=$with_boot_jdk; 25047 fi 25048 25049 25050 # We look for the Boot JDK through various means, going from more certain to 25051 # more of a guess-work. After each test, BOOT_JDK_FOUND is set to "yes" if 25052 # we detected something (if so, the path to the jdk is in BOOT_JDK). But we 25053 # must check if this is indeed valid; otherwise we'll continue looking. 25054 25055 # Test: Is bootjdk explicitly set by command line arguments? 25056 25057 if test "x$BOOT_JDK_FOUND" = xno; then 25058 # Now execute the test 25059 25060 if test "x$with_boot_jdk" != x; then 25061 BOOT_JDK=$with_boot_jdk 25062 BOOT_JDK_FOUND=maybe 25063 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using configure arguments" >&5 25064 $as_echo "$as_me: Found potential Boot JDK using configure arguments" >&6;} 25065 fi 25066 25067 25068 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 25069 if test "x$BOOT_JDK_FOUND" = xmaybe; then 25070 # Do we have a bin/java? 25071 if test ! -x "$BOOT_JDK/bin/java"; then 25072 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 25073 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 25074 BOOT_JDK_FOUND=no 25075 else 25076 # Do we have a bin/javac? 25077 if test ! -x "$BOOT_JDK/bin/javac"; then 25078 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 25079 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 25080 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 25081 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 25082 BOOT_JDK_FOUND=no 25083 else 25084 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 25085 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 25086 25087 # Extra M4 quote needed to protect [] in grep expression. 25088 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 25089 if test "x$FOUND_CORRECT_VERSION" = x; then 25090 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 25091 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 25092 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 25093 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 25094 BOOT_JDK_FOUND=no 25095 else 25096 # We're done! :-) 25097 BOOT_JDK_FOUND=yes 25098 25099 # Only process if variable expands to non-empty 25100 25101 if test "x$BOOT_JDK" != x; then 25102 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25103 25104 # Input might be given as Windows format, start by converting to 25105 # unix format. 25106 path="$BOOT_JDK" 25107 new_path=`$CYGPATH -u "$path"` 25108 25109 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 25110 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 25111 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 25112 # "foo.exe" is OK but "foo" is an error. 25113 # 25114 # This test is therefore slightly more accurate than "test -f" to check for file precense. 25115 # It is also a way to make sure we got the proper file name for the real test later on. 25116 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 25117 if test "x$test_shortpath" = x; then 25118 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25119 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25120 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 25121 fi 25122 25123 # Call helper function which possibly converts this using DOS-style short mode. 25124 # If so, the updated path is stored in $new_path. 25125 25126 input_path="$new_path" 25127 # Check if we need to convert this using DOS-style short mode. If the path 25128 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25129 # take no chances and rewrite it. 25130 # Note: m4 eats our [], so we need to use [ and ] instead. 25131 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 25132 if test "x$has_forbidden_chars" != x; then 25133 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25134 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 25135 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 25136 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 25137 # Going to short mode and back again did indeed matter. Since short mode is 25138 # case insensitive, let's make it lowercase to improve readability. 25139 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25140 # Now convert it back to Unix-style (cygpath) 25141 input_path=`$CYGPATH -u "$shortmode_path"` 25142 new_path="$input_path" 25143 fi 25144 fi 25145 25146 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 25147 if test "x$test_cygdrive_prefix" = x; then 25148 # As a simple fix, exclude /usr/bin since it's not a real path. 25149 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 25150 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 25151 # a path prefixed by /cygdrive for fixpath to work. 25152 new_path="$CYGWIN_ROOT_PATH$input_path" 25153 fi 25154 fi 25155 25156 25157 if test "x$path" != "x$new_path"; then 25158 BOOT_JDK="$new_path" 25159 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25160 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25161 fi 25162 25163 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25164 25165 path="$BOOT_JDK" 25166 has_colon=`$ECHO $path | $GREP ^.:` 25167 new_path="$path" 25168 if test "x$has_colon" = x; then 25169 # Not in mixed or Windows style, start by that. 25170 new_path=`cmd //c echo $path` 25171 fi 25172 25173 25174 input_path="$new_path" 25175 # Check if we need to convert this using DOS-style short mode. If the path 25176 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25177 # take no chances and rewrite it. 25178 # Note: m4 eats our [], so we need to use [ and ] instead. 25179 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 25180 if test "x$has_forbidden_chars" != x; then 25181 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25182 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25183 fi 25184 25185 25186 windows_path="$new_path" 25187 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25188 unix_path=`$CYGPATH -u "$windows_path"` 25189 new_path="$unix_path" 25190 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25191 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25192 new_path="$unix_path" 25193 fi 25194 25195 if test "x$path" != "x$new_path"; then 25196 BOOT_JDK="$new_path" 25197 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25198 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25199 fi 25200 25201 # Save the first 10 bytes of this path to the storage, so fixpath can work. 25202 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 25203 25204 else 25205 # We're on a unix platform. Hooray! :) 25206 path="$BOOT_JDK" 25207 has_space=`$ECHO "$path" | $GREP " "` 25208 if test "x$has_space" != x; then 25209 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25210 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25211 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 25212 fi 25213 25214 # Use eval to expand a potential ~ 25215 eval path="$path" 25216 if test ! -f "$path" && test ! -d "$path"; then 25217 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 25218 fi 25219 25220 if test -d "$path"; then 25221 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 25222 else 25223 dir="`$DIRNAME "$path"`" 25224 base="`$BASENAME "$path"`" 25225 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 25226 fi 25227 fi 25228 fi 25229 25230 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 25231 $as_echo_n "checking for Boot JDK... " >&6; } 25232 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 25233 $as_echo "$BOOT_JDK" >&6; } 25234 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 25235 $as_echo_n "checking Boot JDK version... " >&6; } 25236 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 25237 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 25238 $as_echo "$BOOT_JDK_VERSION" >&6; } 25239 fi # end check jdk version 25240 fi # end check javac 25241 fi # end check java 25242 fi # end check boot jdk found 25243 fi 25244 25245 if test "x$with_boot_jdk" != x && test "x$BOOT_JDK_FOUND" = xno; then 25246 # Having specified an argument which is incorrect will produce an instant failure; 25247 # we should not go on looking 25248 as_fn_error $? "The path given by --with-boot-jdk does not contain a valid Boot JDK" "$LINENO" 5 25249 fi 25250 25251 # Test: On MacOS X, can we find a boot jdk using /usr/libexec/java_home? 25252 25253 if test "x$BOOT_JDK_FOUND" = xno; then 25254 # Now execute the test 25255 25256 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 25257 # First check at user selected default 25258 25259 if test "x$BOOT_JDK_FOUND" = xno; then 25260 # Now execute the test 25261 25262 if test -x /usr/libexec/java_home; then 25263 BOOT_JDK=`/usr/libexec/java_home ` 25264 BOOT_JDK_FOUND=maybe 25265 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home " >&5 25266 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home " >&6;} 25267 fi 25268 25269 25270 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 25271 if test "x$BOOT_JDK_FOUND" = xmaybe; then 25272 # Do we have a bin/java? 25273 if test ! -x "$BOOT_JDK/bin/java"; then 25274 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 25275 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 25276 BOOT_JDK_FOUND=no 25277 else 25278 # Do we have a bin/javac? 25279 if test ! -x "$BOOT_JDK/bin/javac"; then 25280 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 25281 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 25282 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 25283 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 25284 BOOT_JDK_FOUND=no 25285 else 25286 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 25287 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 25288 25289 # Extra M4 quote needed to protect [] in grep expression. 25290 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 25291 if test "x$FOUND_CORRECT_VERSION" = x; then 25292 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 25293 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 25294 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 25295 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 25296 BOOT_JDK_FOUND=no 25297 else 25298 # We're done! :-) 25299 BOOT_JDK_FOUND=yes 25300 25301 # Only process if variable expands to non-empty 25302 25303 if test "x$BOOT_JDK" != x; then 25304 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25305 25306 # Input might be given as Windows format, start by converting to 25307 # unix format. 25308 path="$BOOT_JDK" 25309 new_path=`$CYGPATH -u "$path"` 25310 25311 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 25312 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 25313 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 25314 # "foo.exe" is OK but "foo" is an error. 25315 # 25316 # This test is therefore slightly more accurate than "test -f" to check for file precense. 25317 # It is also a way to make sure we got the proper file name for the real test later on. 25318 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 25319 if test "x$test_shortpath" = x; then 25320 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25321 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25322 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 25323 fi 25324 25325 # Call helper function which possibly converts this using DOS-style short mode. 25326 # If so, the updated path is stored in $new_path. 25327 25328 input_path="$new_path" 25329 # Check if we need to convert this using DOS-style short mode. If the path 25330 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25331 # take no chances and rewrite it. 25332 # Note: m4 eats our [], so we need to use [ and ] instead. 25333 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 25334 if test "x$has_forbidden_chars" != x; then 25335 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25336 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 25337 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 25338 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 25339 # Going to short mode and back again did indeed matter. Since short mode is 25340 # case insensitive, let's make it lowercase to improve readability. 25341 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25342 # Now convert it back to Unix-style (cygpath) 25343 input_path=`$CYGPATH -u "$shortmode_path"` 25344 new_path="$input_path" 25345 fi 25346 fi 25347 25348 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 25349 if test "x$test_cygdrive_prefix" = x; then 25350 # As a simple fix, exclude /usr/bin since it's not a real path. 25351 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 25352 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 25353 # a path prefixed by /cygdrive for fixpath to work. 25354 new_path="$CYGWIN_ROOT_PATH$input_path" 25355 fi 25356 fi 25357 25358 25359 if test "x$path" != "x$new_path"; then 25360 BOOT_JDK="$new_path" 25361 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25362 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25363 fi 25364 25365 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25366 25367 path="$BOOT_JDK" 25368 has_colon=`$ECHO $path | $GREP ^.:` 25369 new_path="$path" 25370 if test "x$has_colon" = x; then 25371 # Not in mixed or Windows style, start by that. 25372 new_path=`cmd //c echo $path` 25373 fi 25374 25375 25376 input_path="$new_path" 25377 # Check if we need to convert this using DOS-style short mode. If the path 25378 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25379 # take no chances and rewrite it. 25380 # Note: m4 eats our [], so we need to use [ and ] instead. 25381 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 25382 if test "x$has_forbidden_chars" != x; then 25383 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25384 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25385 fi 25386 25387 25388 windows_path="$new_path" 25389 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25390 unix_path=`$CYGPATH -u "$windows_path"` 25391 new_path="$unix_path" 25392 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25393 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25394 new_path="$unix_path" 25395 fi 25396 25397 if test "x$path" != "x$new_path"; then 25398 BOOT_JDK="$new_path" 25399 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25400 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25401 fi 25402 25403 # Save the first 10 bytes of this path to the storage, so fixpath can work. 25404 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 25405 25406 else 25407 # We're on a unix platform. Hooray! :) 25408 path="$BOOT_JDK" 25409 has_space=`$ECHO "$path" | $GREP " "` 25410 if test "x$has_space" != x; then 25411 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25412 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25413 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 25414 fi 25415 25416 # Use eval to expand a potential ~ 25417 eval path="$path" 25418 if test ! -f "$path" && test ! -d "$path"; then 25419 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 25420 fi 25421 25422 if test -d "$path"; then 25423 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 25424 else 25425 dir="`$DIRNAME "$path"`" 25426 base="`$BASENAME "$path"`" 25427 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 25428 fi 25429 fi 25430 fi 25431 25432 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 25433 $as_echo_n "checking for Boot JDK... " >&6; } 25434 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 25435 $as_echo "$BOOT_JDK" >&6; } 25436 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 25437 $as_echo_n "checking Boot JDK version... " >&6; } 25438 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 25439 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 25440 $as_echo "$BOOT_JDK_VERSION" >&6; } 25441 fi # end check jdk version 25442 fi # end check javac 25443 fi # end check java 25444 fi # end check boot jdk found 25445 fi 25446 25447 # If that did not work out (e.g. too old), try explicit versions instead 25448 25449 if test "x$BOOT_JDK_FOUND" = xno; then 25450 # Now execute the test 25451 25452 if test -x /usr/libexec/java_home; then 25453 BOOT_JDK=`/usr/libexec/java_home -v 1.9` 25454 BOOT_JDK_FOUND=maybe 25455 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home -v 1.9" >&5 25456 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home -v 1.9" >&6;} 25457 fi 25458 25459 25460 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 25461 if test "x$BOOT_JDK_FOUND" = xmaybe; then 25462 # Do we have a bin/java? 25463 if test ! -x "$BOOT_JDK/bin/java"; then 25464 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 25465 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 25466 BOOT_JDK_FOUND=no 25467 else 25468 # Do we have a bin/javac? 25469 if test ! -x "$BOOT_JDK/bin/javac"; then 25470 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 25471 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 25472 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 25473 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 25474 BOOT_JDK_FOUND=no 25475 else 25476 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 25477 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 25478 25479 # Extra M4 quote needed to protect [] in grep expression. 25480 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 25481 if test "x$FOUND_CORRECT_VERSION" = x; then 25482 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 25483 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 25484 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 25485 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 25486 BOOT_JDK_FOUND=no 25487 else 25488 # We're done! :-) 25489 BOOT_JDK_FOUND=yes 25490 25491 # Only process if variable expands to non-empty 25492 25493 if test "x$BOOT_JDK" != x; then 25494 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25495 25496 # Input might be given as Windows format, start by converting to 25497 # unix format. 25498 path="$BOOT_JDK" 25499 new_path=`$CYGPATH -u "$path"` 25500 25501 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 25502 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 25503 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 25504 # "foo.exe" is OK but "foo" is an error. 25505 # 25506 # This test is therefore slightly more accurate than "test -f" to check for file precense. 25507 # It is also a way to make sure we got the proper file name for the real test later on. 25508 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 25509 if test "x$test_shortpath" = x; then 25510 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25511 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25512 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 25513 fi 25514 25515 # Call helper function which possibly converts this using DOS-style short mode. 25516 # If so, the updated path is stored in $new_path. 25517 25518 input_path="$new_path" 25519 # Check if we need to convert this using DOS-style short mode. If the path 25520 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25521 # take no chances and rewrite it. 25522 # Note: m4 eats our [], so we need to use [ and ] instead. 25523 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 25524 if test "x$has_forbidden_chars" != x; then 25525 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25526 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 25527 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 25528 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 25529 # Going to short mode and back again did indeed matter. Since short mode is 25530 # case insensitive, let's make it lowercase to improve readability. 25531 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25532 # Now convert it back to Unix-style (cygpath) 25533 input_path=`$CYGPATH -u "$shortmode_path"` 25534 new_path="$input_path" 25535 fi 25536 fi 25537 25538 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 25539 if test "x$test_cygdrive_prefix" = x; then 25540 # As a simple fix, exclude /usr/bin since it's not a real path. 25541 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 25542 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 25543 # a path prefixed by /cygdrive for fixpath to work. 25544 new_path="$CYGWIN_ROOT_PATH$input_path" 25545 fi 25546 fi 25547 25548 25549 if test "x$path" != "x$new_path"; then 25550 BOOT_JDK="$new_path" 25551 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25552 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25553 fi 25554 25555 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25556 25557 path="$BOOT_JDK" 25558 has_colon=`$ECHO $path | $GREP ^.:` 25559 new_path="$path" 25560 if test "x$has_colon" = x; then 25561 # Not in mixed or Windows style, start by that. 25562 new_path=`cmd //c echo $path` 25563 fi 25564 25565 25566 input_path="$new_path" 25567 # Check if we need to convert this using DOS-style short mode. If the path 25568 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25569 # take no chances and rewrite it. 25570 # Note: m4 eats our [], so we need to use [ and ] instead. 25571 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 25572 if test "x$has_forbidden_chars" != x; then 25573 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25574 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25575 fi 25576 25577 25578 windows_path="$new_path" 25579 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25580 unix_path=`$CYGPATH -u "$windows_path"` 25581 new_path="$unix_path" 25582 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25583 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25584 new_path="$unix_path" 25585 fi 25586 25587 if test "x$path" != "x$new_path"; then 25588 BOOT_JDK="$new_path" 25589 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25590 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25591 fi 25592 25593 # Save the first 10 bytes of this path to the storage, so fixpath can work. 25594 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 25595 25596 else 25597 # We're on a unix platform. Hooray! :) 25598 path="$BOOT_JDK" 25599 has_space=`$ECHO "$path" | $GREP " "` 25600 if test "x$has_space" != x; then 25601 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25602 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25603 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 25604 fi 25605 25606 # Use eval to expand a potential ~ 25607 eval path="$path" 25608 if test ! -f "$path" && test ! -d "$path"; then 25609 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 25610 fi 25611 25612 if test -d "$path"; then 25613 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 25614 else 25615 dir="`$DIRNAME "$path"`" 25616 base="`$BASENAME "$path"`" 25617 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 25618 fi 25619 fi 25620 fi 25621 25622 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 25623 $as_echo_n "checking for Boot JDK... " >&6; } 25624 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 25625 $as_echo "$BOOT_JDK" >&6; } 25626 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 25627 $as_echo_n "checking Boot JDK version... " >&6; } 25628 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 25629 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 25630 $as_echo "$BOOT_JDK_VERSION" >&6; } 25631 fi # end check jdk version 25632 fi # end check javac 25633 fi # end check java 25634 fi # end check boot jdk found 25635 fi 25636 25637 25638 if test "x$BOOT_JDK_FOUND" = xno; then 25639 # Now execute the test 25640 25641 if test -x /usr/libexec/java_home; then 25642 BOOT_JDK=`/usr/libexec/java_home -v 1.8` 25643 BOOT_JDK_FOUND=maybe 25644 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home -v 1.8" >&5 25645 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home -v 1.8" >&6;} 25646 fi 25647 25648 25649 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 25650 if test "x$BOOT_JDK_FOUND" = xmaybe; then 25651 # Do we have a bin/java? 25652 if test ! -x "$BOOT_JDK/bin/java"; then 25653 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 25654 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 25655 BOOT_JDK_FOUND=no 25656 else 25657 # Do we have a bin/javac? 25658 if test ! -x "$BOOT_JDK/bin/javac"; then 25659 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 25660 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 25661 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 25662 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 25663 BOOT_JDK_FOUND=no 25664 else 25665 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 25666 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 25667 25668 # Extra M4 quote needed to protect [] in grep expression. 25669 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 25670 if test "x$FOUND_CORRECT_VERSION" = x; then 25671 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 25672 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 25673 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 25674 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 25675 BOOT_JDK_FOUND=no 25676 else 25677 # We're done! :-) 25678 BOOT_JDK_FOUND=yes 25679 25680 # Only process if variable expands to non-empty 25681 25682 if test "x$BOOT_JDK" != x; then 25683 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25684 25685 # Input might be given as Windows format, start by converting to 25686 # unix format. 25687 path="$BOOT_JDK" 25688 new_path=`$CYGPATH -u "$path"` 25689 25690 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 25691 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 25692 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 25693 # "foo.exe" is OK but "foo" is an error. 25694 # 25695 # This test is therefore slightly more accurate than "test -f" to check for file precense. 25696 # It is also a way to make sure we got the proper file name for the real test later on. 25697 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 25698 if test "x$test_shortpath" = x; then 25699 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25700 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25701 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 25702 fi 25703 25704 # Call helper function which possibly converts this using DOS-style short mode. 25705 # If so, the updated path is stored in $new_path. 25706 25707 input_path="$new_path" 25708 # Check if we need to convert this using DOS-style short mode. If the path 25709 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25710 # take no chances and rewrite it. 25711 # Note: m4 eats our [], so we need to use [ and ] instead. 25712 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 25713 if test "x$has_forbidden_chars" != x; then 25714 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25715 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 25716 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 25717 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 25718 # Going to short mode and back again did indeed matter. Since short mode is 25719 # case insensitive, let's make it lowercase to improve readability. 25720 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25721 # Now convert it back to Unix-style (cygpath) 25722 input_path=`$CYGPATH -u "$shortmode_path"` 25723 new_path="$input_path" 25724 fi 25725 fi 25726 25727 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 25728 if test "x$test_cygdrive_prefix" = x; then 25729 # As a simple fix, exclude /usr/bin since it's not a real path. 25730 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 25731 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 25732 # a path prefixed by /cygdrive for fixpath to work. 25733 new_path="$CYGWIN_ROOT_PATH$input_path" 25734 fi 25735 fi 25736 25737 25738 if test "x$path" != "x$new_path"; then 25739 BOOT_JDK="$new_path" 25740 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25741 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25742 fi 25743 25744 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25745 25746 path="$BOOT_JDK" 25747 has_colon=`$ECHO $path | $GREP ^.:` 25748 new_path="$path" 25749 if test "x$has_colon" = x; then 25750 # Not in mixed or Windows style, start by that. 25751 new_path=`cmd //c echo $path` 25752 fi 25753 25754 25755 input_path="$new_path" 25756 # Check if we need to convert this using DOS-style short mode. If the path 25757 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25758 # take no chances and rewrite it. 25759 # Note: m4 eats our [], so we need to use [ and ] instead. 25760 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 25761 if test "x$has_forbidden_chars" != x; then 25762 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25763 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25764 fi 25765 25766 25767 windows_path="$new_path" 25768 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25769 unix_path=`$CYGPATH -u "$windows_path"` 25770 new_path="$unix_path" 25771 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25772 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25773 new_path="$unix_path" 25774 fi 25775 25776 if test "x$path" != "x$new_path"; then 25777 BOOT_JDK="$new_path" 25778 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25779 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25780 fi 25781 25782 # Save the first 10 bytes of this path to the storage, so fixpath can work. 25783 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 25784 25785 else 25786 # We're on a unix platform. Hooray! :) 25787 path="$BOOT_JDK" 25788 has_space=`$ECHO "$path" | $GREP " "` 25789 if test "x$has_space" != x; then 25790 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25791 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25792 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 25793 fi 25794 25795 # Use eval to expand a potential ~ 25796 eval path="$path" 25797 if test ! -f "$path" && test ! -d "$path"; then 25798 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 25799 fi 25800 25801 if test -d "$path"; then 25802 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 25803 else 25804 dir="`$DIRNAME "$path"`" 25805 base="`$BASENAME "$path"`" 25806 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 25807 fi 25808 fi 25809 fi 25810 25811 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 25812 $as_echo_n "checking for Boot JDK... " >&6; } 25813 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 25814 $as_echo "$BOOT_JDK" >&6; } 25815 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 25816 $as_echo_n "checking Boot JDK version... " >&6; } 25817 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 25818 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 25819 $as_echo "$BOOT_JDK_VERSION" >&6; } 25820 fi # end check jdk version 25821 fi # end check javac 25822 fi # end check java 25823 fi # end check boot jdk found 25824 fi 25825 25826 25827 if test "x$BOOT_JDK_FOUND" = xno; then 25828 # Now execute the test 25829 25830 if test -x /usr/libexec/java_home; then 25831 BOOT_JDK=`/usr/libexec/java_home -v 1.7` 25832 BOOT_JDK_FOUND=maybe 25833 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home -v 1.7" >&5 25834 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home -v 1.7" >&6;} 25835 fi 25836 25837 25838 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 25839 if test "x$BOOT_JDK_FOUND" = xmaybe; then 25840 # Do we have a bin/java? 25841 if test ! -x "$BOOT_JDK/bin/java"; then 25842 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 25843 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 25844 BOOT_JDK_FOUND=no 25845 else 25846 # Do we have a bin/javac? 25847 if test ! -x "$BOOT_JDK/bin/javac"; then 25848 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 25849 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 25850 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 25851 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 25852 BOOT_JDK_FOUND=no 25853 else 25854 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 25855 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 25856 25857 # Extra M4 quote needed to protect [] in grep expression. 25858 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 25859 if test "x$FOUND_CORRECT_VERSION" = x; then 25860 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 25861 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 25862 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 25863 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 25864 BOOT_JDK_FOUND=no 25865 else 25866 # We're done! :-) 25867 BOOT_JDK_FOUND=yes 25868 25869 # Only process if variable expands to non-empty 25870 25871 if test "x$BOOT_JDK" != x; then 25872 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25873 25874 # Input might be given as Windows format, start by converting to 25875 # unix format. 25876 path="$BOOT_JDK" 25877 new_path=`$CYGPATH -u "$path"` 25878 25879 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 25880 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 25881 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 25882 # "foo.exe" is OK but "foo" is an error. 25883 # 25884 # This test is therefore slightly more accurate than "test -f" to check for file precense. 25885 # It is also a way to make sure we got the proper file name for the real test later on. 25886 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 25887 if test "x$test_shortpath" = x; then 25888 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25889 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25890 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 25891 fi 25892 25893 # Call helper function which possibly converts this using DOS-style short mode. 25894 # If so, the updated path is stored in $new_path. 25895 25896 input_path="$new_path" 25897 # Check if we need to convert this using DOS-style short mode. If the path 25898 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25899 # take no chances and rewrite it. 25900 # Note: m4 eats our [], so we need to use [ and ] instead. 25901 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 25902 if test "x$has_forbidden_chars" != x; then 25903 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25904 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 25905 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 25906 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 25907 # Going to short mode and back again did indeed matter. Since short mode is 25908 # case insensitive, let's make it lowercase to improve readability. 25909 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25910 # Now convert it back to Unix-style (cygpath) 25911 input_path=`$CYGPATH -u "$shortmode_path"` 25912 new_path="$input_path" 25913 fi 25914 fi 25915 25916 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 25917 if test "x$test_cygdrive_prefix" = x; then 25918 # As a simple fix, exclude /usr/bin since it's not a real path. 25919 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 25920 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 25921 # a path prefixed by /cygdrive for fixpath to work. 25922 new_path="$CYGWIN_ROOT_PATH$input_path" 25923 fi 25924 fi 25925 25926 25927 if test "x$path" != "x$new_path"; then 25928 BOOT_JDK="$new_path" 25929 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25930 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25931 fi 25932 25933 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25934 25935 path="$BOOT_JDK" 25936 has_colon=`$ECHO $path | $GREP ^.:` 25937 new_path="$path" 25938 if test "x$has_colon" = x; then 25939 # Not in mixed or Windows style, start by that. 25940 new_path=`cmd //c echo $path` 25941 fi 25942 25943 25944 input_path="$new_path" 25945 # Check if we need to convert this using DOS-style short mode. If the path 25946 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25947 # take no chances and rewrite it. 25948 # Note: m4 eats our [], so we need to use [ and ] instead. 25949 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 25950 if test "x$has_forbidden_chars" != x; then 25951 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25952 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25953 fi 25954 25955 25956 windows_path="$new_path" 25957 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25958 unix_path=`$CYGPATH -u "$windows_path"` 25959 new_path="$unix_path" 25960 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25961 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25962 new_path="$unix_path" 25963 fi 25964 25965 if test "x$path" != "x$new_path"; then 25966 BOOT_JDK="$new_path" 25967 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25968 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25969 fi 25970 25971 # Save the first 10 bytes of this path to the storage, so fixpath can work. 25972 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 25973 25974 else 25975 # We're on a unix platform. Hooray! :) 25976 path="$BOOT_JDK" 25977 has_space=`$ECHO "$path" | $GREP " "` 25978 if test "x$has_space" != x; then 25979 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25980 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25981 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 25982 fi 25983 25984 # Use eval to expand a potential ~ 25985 eval path="$path" 25986 if test ! -f "$path" && test ! -d "$path"; then 25987 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 25988 fi 25989 25990 if test -d "$path"; then 25991 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 25992 else 25993 dir="`$DIRNAME "$path"`" 25994 base="`$BASENAME "$path"`" 25995 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 25996 fi 25997 fi 25998 fi 25999 26000 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 26001 $as_echo_n "checking for Boot JDK... " >&6; } 26002 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 26003 $as_echo "$BOOT_JDK" >&6; } 26004 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 26005 $as_echo_n "checking Boot JDK version... " >&6; } 26006 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 26007 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 26008 $as_echo "$BOOT_JDK_VERSION" >&6; } 26009 fi # end check jdk version 26010 fi # end check javac 26011 fi # end check java 26012 fi # end check boot jdk found 26013 fi 26014 26015 fi 26016 26017 26018 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 26019 if test "x$BOOT_JDK_FOUND" = xmaybe; then 26020 # Do we have a bin/java? 26021 if test ! -x "$BOOT_JDK/bin/java"; then 26022 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 26023 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 26024 BOOT_JDK_FOUND=no 26025 else 26026 # Do we have a bin/javac? 26027 if test ! -x "$BOOT_JDK/bin/javac"; then 26028 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 26029 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 26030 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 26031 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 26032 BOOT_JDK_FOUND=no 26033 else 26034 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 26035 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 26036 26037 # Extra M4 quote needed to protect [] in grep expression. 26038 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 26039 if test "x$FOUND_CORRECT_VERSION" = x; then 26040 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 26041 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 26042 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 26043 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 26044 BOOT_JDK_FOUND=no 26045 else 26046 # We're done! :-) 26047 BOOT_JDK_FOUND=yes 26048 26049 # Only process if variable expands to non-empty 26050 26051 if test "x$BOOT_JDK" != x; then 26052 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26053 26054 # Input might be given as Windows format, start by converting to 26055 # unix format. 26056 path="$BOOT_JDK" 26057 new_path=`$CYGPATH -u "$path"` 26058 26059 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26060 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26061 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26062 # "foo.exe" is OK but "foo" is an error. 26063 # 26064 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26065 # It is also a way to make sure we got the proper file name for the real test later on. 26066 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26067 if test "x$test_shortpath" = x; then 26068 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26069 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26070 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 26071 fi 26072 26073 # Call helper function which possibly converts this using DOS-style short mode. 26074 # If so, the updated path is stored in $new_path. 26075 26076 input_path="$new_path" 26077 # Check if we need to convert this using DOS-style short mode. If the path 26078 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26079 # take no chances and rewrite it. 26080 # Note: m4 eats our [], so we need to use [ and ] instead. 26081 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26082 if test "x$has_forbidden_chars" != x; then 26083 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26084 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26085 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26086 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26087 # Going to short mode and back again did indeed matter. Since short mode is 26088 # case insensitive, let's make it lowercase to improve readability. 26089 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26090 # Now convert it back to Unix-style (cygpath) 26091 input_path=`$CYGPATH -u "$shortmode_path"` 26092 new_path="$input_path" 26093 fi 26094 fi 26095 26096 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26097 if test "x$test_cygdrive_prefix" = x; then 26098 # As a simple fix, exclude /usr/bin since it's not a real path. 26099 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 26100 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26101 # a path prefixed by /cygdrive for fixpath to work. 26102 new_path="$CYGWIN_ROOT_PATH$input_path" 26103 fi 26104 fi 26105 26106 26107 if test "x$path" != "x$new_path"; then 26108 BOOT_JDK="$new_path" 26109 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26110 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26111 fi 26112 26113 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26114 26115 path="$BOOT_JDK" 26116 has_colon=`$ECHO $path | $GREP ^.:` 26117 new_path="$path" 26118 if test "x$has_colon" = x; then 26119 # Not in mixed or Windows style, start by that. 26120 new_path=`cmd //c echo $path` 26121 fi 26122 26123 26124 input_path="$new_path" 26125 # Check if we need to convert this using DOS-style short mode. If the path 26126 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26127 # take no chances and rewrite it. 26128 # Note: m4 eats our [], so we need to use [ and ] instead. 26129 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26130 if test "x$has_forbidden_chars" != x; then 26131 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26132 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26133 fi 26134 26135 26136 windows_path="$new_path" 26137 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26138 unix_path=`$CYGPATH -u "$windows_path"` 26139 new_path="$unix_path" 26140 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26141 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26142 new_path="$unix_path" 26143 fi 26144 26145 if test "x$path" != "x$new_path"; then 26146 BOOT_JDK="$new_path" 26147 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26148 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26149 fi 26150 26151 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26152 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26153 26154 else 26155 # We're on a unix platform. Hooray! :) 26156 path="$BOOT_JDK" 26157 has_space=`$ECHO "$path" | $GREP " "` 26158 if test "x$has_space" != x; then 26159 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26160 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26161 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 26162 fi 26163 26164 # Use eval to expand a potential ~ 26165 eval path="$path" 26166 if test ! -f "$path" && test ! -d "$path"; then 26167 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 26168 fi 26169 26170 if test -d "$path"; then 26171 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 26172 else 26173 dir="`$DIRNAME "$path"`" 26174 base="`$BASENAME "$path"`" 26175 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 26176 fi 26177 fi 26178 fi 26179 26180 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 26181 $as_echo_n "checking for Boot JDK... " >&6; } 26182 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 26183 $as_echo "$BOOT_JDK" >&6; } 26184 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 26185 $as_echo_n "checking Boot JDK version... " >&6; } 26186 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 26187 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 26188 $as_echo "$BOOT_JDK_VERSION" >&6; } 26189 fi # end check jdk version 26190 fi # end check javac 26191 fi # end check java 26192 fi # end check boot jdk found 26193 fi 26194 26195 26196 # Test: Is $JAVA_HOME set? 26197 26198 if test "x$BOOT_JDK_FOUND" = xno; then 26199 # Now execute the test 26200 26201 if test "x$JAVA_HOME" != x; then 26202 JAVA_HOME_PROCESSED="$JAVA_HOME" 26203 26204 # Only process if variable expands to non-empty 26205 26206 if test "x$JAVA_HOME_PROCESSED" != x; then 26207 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26208 26209 # Input might be given as Windows format, start by converting to 26210 # unix format. 26211 path="$JAVA_HOME_PROCESSED" 26212 new_path=`$CYGPATH -u "$path"` 26213 26214 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26215 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26216 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26217 # "foo.exe" is OK but "foo" is an error. 26218 # 26219 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26220 # It is also a way to make sure we got the proper file name for the real test later on. 26221 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26222 if test "x$test_shortpath" = x; then 26223 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&5 26224 $as_echo "$as_me: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&6;} 26225 as_fn_error $? "Cannot locate the the path of JAVA_HOME_PROCESSED" "$LINENO" 5 26226 fi 26227 26228 # Call helper function which possibly converts this using DOS-style short mode. 26229 # If so, the updated path is stored in $new_path. 26230 26231 input_path="$new_path" 26232 # Check if we need to convert this using DOS-style short mode. If the path 26233 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26234 # take no chances and rewrite it. 26235 # Note: m4 eats our [], so we need to use [ and ] instead. 26236 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26237 if test "x$has_forbidden_chars" != x; then 26238 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26239 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26240 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26241 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26242 # Going to short mode and back again did indeed matter. Since short mode is 26243 # case insensitive, let's make it lowercase to improve readability. 26244 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26245 # Now convert it back to Unix-style (cygpath) 26246 input_path=`$CYGPATH -u "$shortmode_path"` 26247 new_path="$input_path" 26248 fi 26249 fi 26250 26251 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26252 if test "x$test_cygdrive_prefix" = x; then 26253 # As a simple fix, exclude /usr/bin since it's not a real path. 26254 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 26255 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26256 # a path prefixed by /cygdrive for fixpath to work. 26257 new_path="$CYGWIN_ROOT_PATH$input_path" 26258 fi 26259 fi 26260 26261 26262 if test "x$path" != "x$new_path"; then 26263 JAVA_HOME_PROCESSED="$new_path" 26264 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&5 26265 $as_echo "$as_me: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&6;} 26266 fi 26267 26268 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26269 26270 path="$JAVA_HOME_PROCESSED" 26271 has_colon=`$ECHO $path | $GREP ^.:` 26272 new_path="$path" 26273 if test "x$has_colon" = x; then 26274 # Not in mixed or Windows style, start by that. 26275 new_path=`cmd //c echo $path` 26276 fi 26277 26278 26279 input_path="$new_path" 26280 # Check if we need to convert this using DOS-style short mode. If the path 26281 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26282 # take no chances and rewrite it. 26283 # Note: m4 eats our [], so we need to use [ and ] instead. 26284 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26285 if test "x$has_forbidden_chars" != x; then 26286 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26287 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26288 fi 26289 26290 26291 windows_path="$new_path" 26292 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26293 unix_path=`$CYGPATH -u "$windows_path"` 26294 new_path="$unix_path" 26295 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26296 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26297 new_path="$unix_path" 26298 fi 26299 26300 if test "x$path" != "x$new_path"; then 26301 JAVA_HOME_PROCESSED="$new_path" 26302 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&5 26303 $as_echo "$as_me: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&6;} 26304 fi 26305 26306 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26307 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26308 26309 else 26310 # We're on a unix platform. Hooray! :) 26311 path="$JAVA_HOME_PROCESSED" 26312 has_space=`$ECHO "$path" | $GREP " "` 26313 if test "x$has_space" != x; then 26314 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&5 26315 $as_echo "$as_me: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&6;} 26316 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 26317 fi 26318 26319 # Use eval to expand a potential ~ 26320 eval path="$path" 26321 if test ! -f "$path" && test ! -d "$path"; then 26322 as_fn_error $? "The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is not found." "$LINENO" 5 26323 fi 26324 26325 if test -d "$path"; then 26326 JAVA_HOME_PROCESSED="`cd "$path"; $THEPWDCMD -L`" 26327 else 26328 dir="`$DIRNAME "$path"`" 26329 base="`$BASENAME "$path"`" 26330 JAVA_HOME_PROCESSED="`cd "$dir"; $THEPWDCMD -L`/$base" 26331 fi 26332 fi 26333 fi 26334 26335 if test ! -d "$JAVA_HOME_PROCESSED"; then 26336 { $as_echo "$as_me:${as_lineno-$LINENO}: Your JAVA_HOME points to a non-existing directory!" >&5 26337 $as_echo "$as_me: Your JAVA_HOME points to a non-existing directory!" >&6;} 26338 else 26339 # Aha, the user has set a JAVA_HOME 26340 # let us use that as the Boot JDK. 26341 BOOT_JDK="$JAVA_HOME_PROCESSED" 26342 BOOT_JDK_FOUND=maybe 26343 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using JAVA_HOME" >&5 26344 $as_echo "$as_me: Found potential Boot JDK using JAVA_HOME" >&6;} 26345 fi 26346 fi 26347 26348 26349 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 26350 if test "x$BOOT_JDK_FOUND" = xmaybe; then 26351 # Do we have a bin/java? 26352 if test ! -x "$BOOT_JDK/bin/java"; then 26353 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 26354 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 26355 BOOT_JDK_FOUND=no 26356 else 26357 # Do we have a bin/javac? 26358 if test ! -x "$BOOT_JDK/bin/javac"; then 26359 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 26360 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 26361 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 26362 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 26363 BOOT_JDK_FOUND=no 26364 else 26365 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 26366 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 26367 26368 # Extra M4 quote needed to protect [] in grep expression. 26369 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 26370 if test "x$FOUND_CORRECT_VERSION" = x; then 26371 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 26372 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 26373 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 26374 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 26375 BOOT_JDK_FOUND=no 26376 else 26377 # We're done! :-) 26378 BOOT_JDK_FOUND=yes 26379 26380 # Only process if variable expands to non-empty 26381 26382 if test "x$BOOT_JDK" != x; then 26383 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26384 26385 # Input might be given as Windows format, start by converting to 26386 # unix format. 26387 path="$BOOT_JDK" 26388 new_path=`$CYGPATH -u "$path"` 26389 26390 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26391 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26392 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26393 # "foo.exe" is OK but "foo" is an error. 26394 # 26395 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26396 # It is also a way to make sure we got the proper file name for the real test later on. 26397 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26398 if test "x$test_shortpath" = x; then 26399 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26400 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26401 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 26402 fi 26403 26404 # Call helper function which possibly converts this using DOS-style short mode. 26405 # If so, the updated path is stored in $new_path. 26406 26407 input_path="$new_path" 26408 # Check if we need to convert this using DOS-style short mode. If the path 26409 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26410 # take no chances and rewrite it. 26411 # Note: m4 eats our [], so we need to use [ and ] instead. 26412 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26413 if test "x$has_forbidden_chars" != x; then 26414 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26415 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26416 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26417 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26418 # Going to short mode and back again did indeed matter. Since short mode is 26419 # case insensitive, let's make it lowercase to improve readability. 26420 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26421 # Now convert it back to Unix-style (cygpath) 26422 input_path=`$CYGPATH -u "$shortmode_path"` 26423 new_path="$input_path" 26424 fi 26425 fi 26426 26427 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26428 if test "x$test_cygdrive_prefix" = x; then 26429 # As a simple fix, exclude /usr/bin since it's not a real path. 26430 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 26431 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26432 # a path prefixed by /cygdrive for fixpath to work. 26433 new_path="$CYGWIN_ROOT_PATH$input_path" 26434 fi 26435 fi 26436 26437 26438 if test "x$path" != "x$new_path"; then 26439 BOOT_JDK="$new_path" 26440 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26441 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26442 fi 26443 26444 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26445 26446 path="$BOOT_JDK" 26447 has_colon=`$ECHO $path | $GREP ^.:` 26448 new_path="$path" 26449 if test "x$has_colon" = x; then 26450 # Not in mixed or Windows style, start by that. 26451 new_path=`cmd //c echo $path` 26452 fi 26453 26454 26455 input_path="$new_path" 26456 # Check if we need to convert this using DOS-style short mode. If the path 26457 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26458 # take no chances and rewrite it. 26459 # Note: m4 eats our [], so we need to use [ and ] instead. 26460 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26461 if test "x$has_forbidden_chars" != x; then 26462 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26463 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26464 fi 26465 26466 26467 windows_path="$new_path" 26468 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26469 unix_path=`$CYGPATH -u "$windows_path"` 26470 new_path="$unix_path" 26471 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26472 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26473 new_path="$unix_path" 26474 fi 26475 26476 if test "x$path" != "x$new_path"; then 26477 BOOT_JDK="$new_path" 26478 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26479 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26480 fi 26481 26482 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26483 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26484 26485 else 26486 # We're on a unix platform. Hooray! :) 26487 path="$BOOT_JDK" 26488 has_space=`$ECHO "$path" | $GREP " "` 26489 if test "x$has_space" != x; then 26490 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26491 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26492 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 26493 fi 26494 26495 # Use eval to expand a potential ~ 26496 eval path="$path" 26497 if test ! -f "$path" && test ! -d "$path"; then 26498 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 26499 fi 26500 26501 if test -d "$path"; then 26502 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 26503 else 26504 dir="`$DIRNAME "$path"`" 26505 base="`$BASENAME "$path"`" 26506 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 26507 fi 26508 fi 26509 fi 26510 26511 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 26512 $as_echo_n "checking for Boot JDK... " >&6; } 26513 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 26514 $as_echo "$BOOT_JDK" >&6; } 26515 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 26516 $as_echo_n "checking Boot JDK version... " >&6; } 26517 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 26518 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 26519 $as_echo "$BOOT_JDK_VERSION" >&6; } 26520 fi # end check jdk version 26521 fi # end check javac 26522 fi # end check java 26523 fi # end check boot jdk found 26524 fi 26525 26526 26527 # Test: Is there a java or javac in the PATH, which is a symlink to the JDK? 26528 26529 if test "x$BOOT_JDK_FOUND" = xno; then 26530 # Now execute the test 26531 26532 # Extract the first word of "javac", so it can be a program name with args. 26533 set dummy javac; ac_word=$2 26534 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 26535 $as_echo_n "checking for $ac_word... " >&6; } 26536 if ${ac_cv_path_JAVAC_CHECK+:} false; then : 26537 $as_echo_n "(cached) " >&6 26538 else 26539 case $JAVAC_CHECK in 26540 [\\/]* | ?:[\\/]*) 26541 ac_cv_path_JAVAC_CHECK="$JAVAC_CHECK" # Let the user override the test with a path. 26542 ;; 26543 *) 26544 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 26545 for as_dir in $PATH 26546 do 26547 IFS=$as_save_IFS 26548 test -z "$as_dir" && as_dir=. 26549 for ac_exec_ext in '' $ac_executable_extensions; do 26550 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 26551 ac_cv_path_JAVAC_CHECK="$as_dir/$ac_word$ac_exec_ext" 26552 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 26553 break 2 26554 fi 26555 done 26556 done 26557 IFS=$as_save_IFS 26558 26559 ;; 26560 esac 26561 fi 26562 JAVAC_CHECK=$ac_cv_path_JAVAC_CHECK 26563 if test -n "$JAVAC_CHECK"; then 26564 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVAC_CHECK" >&5 26565 $as_echo "$JAVAC_CHECK" >&6; } 26566 else 26567 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 26568 $as_echo "no" >&6; } 26569 fi 26570 26571 26572 # Extract the first word of "java", so it can be a program name with args. 26573 set dummy java; ac_word=$2 26574 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 26575 $as_echo_n "checking for $ac_word... " >&6; } 26576 if ${ac_cv_path_JAVA_CHECK+:} false; then : 26577 $as_echo_n "(cached) " >&6 26578 else 26579 case $JAVA_CHECK in 26580 [\\/]* | ?:[\\/]*) 26581 ac_cv_path_JAVA_CHECK="$JAVA_CHECK" # Let the user override the test with a path. 26582 ;; 26583 *) 26584 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 26585 for as_dir in $PATH 26586 do 26587 IFS=$as_save_IFS 26588 test -z "$as_dir" && as_dir=. 26589 for ac_exec_ext in '' $ac_executable_extensions; do 26590 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 26591 ac_cv_path_JAVA_CHECK="$as_dir/$ac_word$ac_exec_ext" 26592 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 26593 break 2 26594 fi 26595 done 26596 done 26597 IFS=$as_save_IFS 26598 26599 ;; 26600 esac 26601 fi 26602 JAVA_CHECK=$ac_cv_path_JAVA_CHECK 26603 if test -n "$JAVA_CHECK"; then 26604 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVA_CHECK" >&5 26605 $as_echo "$JAVA_CHECK" >&6; } 26606 else 26607 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 26608 $as_echo "no" >&6; } 26609 fi 26610 26611 26612 BINARY="$JAVAC_CHECK" 26613 if test "x$JAVAC_CHECK" = x; then 26614 BINARY="$JAVA_CHECK" 26615 fi 26616 if test "x$BINARY" != x; then 26617 # So there is a java(c) binary, it might be part of a JDK. 26618 # Lets find the JDK/JRE directory by following symbolic links. 26619 # Linux/GNU systems often have links from /usr/bin/java to 26620 # /etc/alternatives/java to the real JDK binary. 26621 26622 if test "x$OPENJDK_BUILD_OS" != xwindows; then 26623 # Follow a chain of symbolic links. Use readlink 26624 # where it exists, else fall back to horribly 26625 # complicated shell code. 26626 if test "x$READLINK_TESTED" != yes; then 26627 # On MacOSX there is a readlink tool with a different 26628 # purpose than the GNU readlink tool. Check the found readlink. 26629 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 26630 if test "x$ISGNU" = x; then 26631 # A readlink that we do not know how to use. 26632 # Are there other non-GNU readlinks out there? 26633 READLINK_TESTED=yes 26634 READLINK= 26635 fi 26636 fi 26637 26638 if test "x$READLINK" != x; then 26639 BINARY=`$READLINK -f $BINARY` 26640 else 26641 # Save the current directory for restoring afterwards 26642 STARTDIR=$PWD 26643 COUNTER=0 26644 sym_link_dir=`$DIRNAME $BINARY` 26645 sym_link_file=`$BASENAME $BINARY` 26646 cd $sym_link_dir 26647 # Use -P flag to resolve symlinks in directories. 26648 cd `$THEPWDCMD -P` 26649 sym_link_dir=`$THEPWDCMD -P` 26650 # Resolve file symlinks 26651 while test $COUNTER -lt 20; do 26652 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 26653 if test "x$ISLINK" == x; then 26654 # This is not a symbolic link! We are done! 26655 break 26656 fi 26657 # Again resolve directory symlinks since the target of the just found 26658 # link could be in a different directory 26659 cd `$DIRNAME $ISLINK` 26660 sym_link_dir=`$THEPWDCMD -P` 26661 sym_link_file=`$BASENAME $ISLINK` 26662 let COUNTER=COUNTER+1 26663 done 26664 cd $STARTDIR 26665 BINARY=$sym_link_dir/$sym_link_file 26666 fi 26667 fi 26668 26669 BOOT_JDK=`dirname "$BINARY"` 26670 BOOT_JDK=`cd "$BOOT_JDK/.."; pwd` 26671 if test -x "$BOOT_JDK/bin/javac" && test -x "$BOOT_JDK/bin/java"; then 26672 # Looks like we found ourselves an JDK 26673 BOOT_JDK_FOUND=maybe 26674 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using java(c) in PATH" >&5 26675 $as_echo "$as_me: Found potential Boot JDK using java(c) in PATH" >&6;} 26676 fi 26677 fi 26678 26679 26680 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 26681 if test "x$BOOT_JDK_FOUND" = xmaybe; then 26682 # Do we have a bin/java? 26683 if test ! -x "$BOOT_JDK/bin/java"; then 26684 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 26685 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 26686 BOOT_JDK_FOUND=no 26687 else 26688 # Do we have a bin/javac? 26689 if test ! -x "$BOOT_JDK/bin/javac"; then 26690 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 26691 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 26692 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 26693 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 26694 BOOT_JDK_FOUND=no 26695 else 26696 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 26697 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 26698 26699 # Extra M4 quote needed to protect [] in grep expression. 26700 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 26701 if test "x$FOUND_CORRECT_VERSION" = x; then 26702 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 26703 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 26704 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 26705 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 26706 BOOT_JDK_FOUND=no 26707 else 26708 # We're done! :-) 26709 BOOT_JDK_FOUND=yes 26710 26711 # Only process if variable expands to non-empty 26712 26713 if test "x$BOOT_JDK" != x; then 26714 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26715 26716 # Input might be given as Windows format, start by converting to 26717 # unix format. 26718 path="$BOOT_JDK" 26719 new_path=`$CYGPATH -u "$path"` 26720 26721 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26722 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26723 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26724 # "foo.exe" is OK but "foo" is an error. 26725 # 26726 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26727 # It is also a way to make sure we got the proper file name for the real test later on. 26728 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26729 if test "x$test_shortpath" = x; then 26730 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26731 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26732 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 26733 fi 26734 26735 # Call helper function which possibly converts this using DOS-style short mode. 26736 # If so, the updated path is stored in $new_path. 26737 26738 input_path="$new_path" 26739 # Check if we need to convert this using DOS-style short mode. If the path 26740 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26741 # take no chances and rewrite it. 26742 # Note: m4 eats our [], so we need to use [ and ] instead. 26743 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26744 if test "x$has_forbidden_chars" != x; then 26745 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26746 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26747 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26748 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26749 # Going to short mode and back again did indeed matter. Since short mode is 26750 # case insensitive, let's make it lowercase to improve readability. 26751 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26752 # Now convert it back to Unix-style (cygpath) 26753 input_path=`$CYGPATH -u "$shortmode_path"` 26754 new_path="$input_path" 26755 fi 26756 fi 26757 26758 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26759 if test "x$test_cygdrive_prefix" = x; then 26760 # As a simple fix, exclude /usr/bin since it's not a real path. 26761 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 26762 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26763 # a path prefixed by /cygdrive for fixpath to work. 26764 new_path="$CYGWIN_ROOT_PATH$input_path" 26765 fi 26766 fi 26767 26768 26769 if test "x$path" != "x$new_path"; then 26770 BOOT_JDK="$new_path" 26771 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26772 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26773 fi 26774 26775 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26776 26777 path="$BOOT_JDK" 26778 has_colon=`$ECHO $path | $GREP ^.:` 26779 new_path="$path" 26780 if test "x$has_colon" = x; then 26781 # Not in mixed or Windows style, start by that. 26782 new_path=`cmd //c echo $path` 26783 fi 26784 26785 26786 input_path="$new_path" 26787 # Check if we need to convert this using DOS-style short mode. If the path 26788 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26789 # take no chances and rewrite it. 26790 # Note: m4 eats our [], so we need to use [ and ] instead. 26791 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26792 if test "x$has_forbidden_chars" != x; then 26793 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26794 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26795 fi 26796 26797 26798 windows_path="$new_path" 26799 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26800 unix_path=`$CYGPATH -u "$windows_path"` 26801 new_path="$unix_path" 26802 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26803 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26804 new_path="$unix_path" 26805 fi 26806 26807 if test "x$path" != "x$new_path"; then 26808 BOOT_JDK="$new_path" 26809 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26810 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26811 fi 26812 26813 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26814 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26815 26816 else 26817 # We're on a unix platform. Hooray! :) 26818 path="$BOOT_JDK" 26819 has_space=`$ECHO "$path" | $GREP " "` 26820 if test "x$has_space" != x; then 26821 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26822 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26823 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 26824 fi 26825 26826 # Use eval to expand a potential ~ 26827 eval path="$path" 26828 if test ! -f "$path" && test ! -d "$path"; then 26829 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 26830 fi 26831 26832 if test -d "$path"; then 26833 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 26834 else 26835 dir="`$DIRNAME "$path"`" 26836 base="`$BASENAME "$path"`" 26837 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 26838 fi 26839 fi 26840 fi 26841 26842 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 26843 $as_echo_n "checking for Boot JDK... " >&6; } 26844 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 26845 $as_echo "$BOOT_JDK" >&6; } 26846 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 26847 $as_echo_n "checking Boot JDK version... " >&6; } 26848 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 26849 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 26850 $as_echo "$BOOT_JDK_VERSION" >&6; } 26851 fi # end check jdk version 26852 fi # end check javac 26853 fi # end check java 26854 fi # end check boot jdk found 26855 fi 26856 26857 26858 # Test: Is there a JDK installed in default, well-known locations? 26859 26860 if test "x$BOOT_JDK_FOUND" = xno; then 26861 # Now execute the test 26862 26863 if test "x$OPENJDK_TARGET_OS" = xwindows; then 26864 26865 if test "x$BOOT_JDK_FOUND" = xno; then 26866 # Now execute the test 26867 26868 if test "x$ProgramW6432" != x; then 26869 VIRTUAL_DIR="$ProgramW6432/Java" 26870 26871 windows_path="$VIRTUAL_DIR" 26872 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26873 unix_path=`$CYGPATH -u "$windows_path"` 26874 VIRTUAL_DIR="$unix_path" 26875 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26876 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26877 VIRTUAL_DIR="$unix_path" 26878 fi 26879 26880 26881 BOOT_JDK_PREFIX="$VIRTUAL_DIR" 26882 BOOT_JDK_SUFFIX="" 26883 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 26884 if test "x$ALL_JDKS_FOUND" != x; then 26885 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 26886 26887 if test "x$BOOT_JDK_FOUND" = xno; then 26888 # Now execute the test 26889 26890 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 26891 if test -d "$BOOT_JDK"; then 26892 BOOT_JDK_FOUND=maybe 26893 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 26894 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 26895 fi 26896 26897 26898 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 26899 if test "x$BOOT_JDK_FOUND" = xmaybe; then 26900 # Do we have a bin/java? 26901 if test ! -x "$BOOT_JDK/bin/java"; then 26902 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 26903 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 26904 BOOT_JDK_FOUND=no 26905 else 26906 # Do we have a bin/javac? 26907 if test ! -x "$BOOT_JDK/bin/javac"; then 26908 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 26909 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 26910 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 26911 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 26912 BOOT_JDK_FOUND=no 26913 else 26914 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 26915 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 26916 26917 # Extra M4 quote needed to protect [] in grep expression. 26918 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 26919 if test "x$FOUND_CORRECT_VERSION" = x; then 26920 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 26921 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 26922 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 26923 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 26924 BOOT_JDK_FOUND=no 26925 else 26926 # We're done! :-) 26927 BOOT_JDK_FOUND=yes 26928 26929 # Only process if variable expands to non-empty 26930 26931 if test "x$BOOT_JDK" != x; then 26932 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26933 26934 # Input might be given as Windows format, start by converting to 26935 # unix format. 26936 path="$BOOT_JDK" 26937 new_path=`$CYGPATH -u "$path"` 26938 26939 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26940 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26941 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26942 # "foo.exe" is OK but "foo" is an error. 26943 # 26944 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26945 # It is also a way to make sure we got the proper file name for the real test later on. 26946 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26947 if test "x$test_shortpath" = x; then 26948 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26949 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26950 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 26951 fi 26952 26953 # Call helper function which possibly converts this using DOS-style short mode. 26954 # If so, the updated path is stored in $new_path. 26955 26956 input_path="$new_path" 26957 # Check if we need to convert this using DOS-style short mode. If the path 26958 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26959 # take no chances and rewrite it. 26960 # Note: m4 eats our [], so we need to use [ and ] instead. 26961 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26962 if test "x$has_forbidden_chars" != x; then 26963 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26964 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26965 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26966 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26967 # Going to short mode and back again did indeed matter. Since short mode is 26968 # case insensitive, let's make it lowercase to improve readability. 26969 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26970 # Now convert it back to Unix-style (cygpath) 26971 input_path=`$CYGPATH -u "$shortmode_path"` 26972 new_path="$input_path" 26973 fi 26974 fi 26975 26976 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26977 if test "x$test_cygdrive_prefix" = x; then 26978 # As a simple fix, exclude /usr/bin since it's not a real path. 26979 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 26980 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26981 # a path prefixed by /cygdrive for fixpath to work. 26982 new_path="$CYGWIN_ROOT_PATH$input_path" 26983 fi 26984 fi 26985 26986 26987 if test "x$path" != "x$new_path"; then 26988 BOOT_JDK="$new_path" 26989 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26990 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26991 fi 26992 26993 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26994 26995 path="$BOOT_JDK" 26996 has_colon=`$ECHO $path | $GREP ^.:` 26997 new_path="$path" 26998 if test "x$has_colon" = x; then 26999 # Not in mixed or Windows style, start by that. 27000 new_path=`cmd //c echo $path` 27001 fi 27002 27003 27004 input_path="$new_path" 27005 # Check if we need to convert this using DOS-style short mode. If the path 27006 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27007 # take no chances and rewrite it. 27008 # Note: m4 eats our [], so we need to use [ and ] instead. 27009 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27010 if test "x$has_forbidden_chars" != x; then 27011 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27012 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27013 fi 27014 27015 27016 windows_path="$new_path" 27017 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27018 unix_path=`$CYGPATH -u "$windows_path"` 27019 new_path="$unix_path" 27020 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27021 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27022 new_path="$unix_path" 27023 fi 27024 27025 if test "x$path" != "x$new_path"; then 27026 BOOT_JDK="$new_path" 27027 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27028 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27029 fi 27030 27031 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27032 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27033 27034 else 27035 # We're on a unix platform. Hooray! :) 27036 path="$BOOT_JDK" 27037 has_space=`$ECHO "$path" | $GREP " "` 27038 if test "x$has_space" != x; then 27039 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27040 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27041 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 27042 fi 27043 27044 # Use eval to expand a potential ~ 27045 eval path="$path" 27046 if test ! -f "$path" && test ! -d "$path"; then 27047 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 27048 fi 27049 27050 if test -d "$path"; then 27051 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 27052 else 27053 dir="`$DIRNAME "$path"`" 27054 base="`$BASENAME "$path"`" 27055 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 27056 fi 27057 fi 27058 fi 27059 27060 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 27061 $as_echo_n "checking for Boot JDK... " >&6; } 27062 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 27063 $as_echo "$BOOT_JDK" >&6; } 27064 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 27065 $as_echo_n "checking Boot JDK version... " >&6; } 27066 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 27067 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 27068 $as_echo "$BOOT_JDK_VERSION" >&6; } 27069 fi # end check jdk version 27070 fi # end check javac 27071 fi # end check java 27072 fi # end check boot jdk found 27073 fi 27074 27075 done 27076 fi 27077 27078 fi 27079 27080 27081 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 27082 if test "x$BOOT_JDK_FOUND" = xmaybe; then 27083 # Do we have a bin/java? 27084 if test ! -x "$BOOT_JDK/bin/java"; then 27085 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 27086 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 27087 BOOT_JDK_FOUND=no 27088 else 27089 # Do we have a bin/javac? 27090 if test ! -x "$BOOT_JDK/bin/javac"; then 27091 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 27092 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 27093 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 27094 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 27095 BOOT_JDK_FOUND=no 27096 else 27097 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 27098 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 27099 27100 # Extra M4 quote needed to protect [] in grep expression. 27101 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 27102 if test "x$FOUND_CORRECT_VERSION" = x; then 27103 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 27104 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 27105 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 27106 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 27107 BOOT_JDK_FOUND=no 27108 else 27109 # We're done! :-) 27110 BOOT_JDK_FOUND=yes 27111 27112 # Only process if variable expands to non-empty 27113 27114 if test "x$BOOT_JDK" != x; then 27115 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27116 27117 # Input might be given as Windows format, start by converting to 27118 # unix format. 27119 path="$BOOT_JDK" 27120 new_path=`$CYGPATH -u "$path"` 27121 27122 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27123 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27124 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27125 # "foo.exe" is OK but "foo" is an error. 27126 # 27127 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27128 # It is also a way to make sure we got the proper file name for the real test later on. 27129 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27130 if test "x$test_shortpath" = x; then 27131 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27132 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27133 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 27134 fi 27135 27136 # Call helper function which possibly converts this using DOS-style short mode. 27137 # If so, the updated path is stored in $new_path. 27138 27139 input_path="$new_path" 27140 # Check if we need to convert this using DOS-style short mode. If the path 27141 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27142 # take no chances and rewrite it. 27143 # Note: m4 eats our [], so we need to use [ and ] instead. 27144 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27145 if test "x$has_forbidden_chars" != x; then 27146 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27147 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27148 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27149 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27150 # Going to short mode and back again did indeed matter. Since short mode is 27151 # case insensitive, let's make it lowercase to improve readability. 27152 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27153 # Now convert it back to Unix-style (cygpath) 27154 input_path=`$CYGPATH -u "$shortmode_path"` 27155 new_path="$input_path" 27156 fi 27157 fi 27158 27159 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27160 if test "x$test_cygdrive_prefix" = x; then 27161 # As a simple fix, exclude /usr/bin since it's not a real path. 27162 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 27163 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27164 # a path prefixed by /cygdrive for fixpath to work. 27165 new_path="$CYGWIN_ROOT_PATH$input_path" 27166 fi 27167 fi 27168 27169 27170 if test "x$path" != "x$new_path"; then 27171 BOOT_JDK="$new_path" 27172 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27173 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27174 fi 27175 27176 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27177 27178 path="$BOOT_JDK" 27179 has_colon=`$ECHO $path | $GREP ^.:` 27180 new_path="$path" 27181 if test "x$has_colon" = x; then 27182 # Not in mixed or Windows style, start by that. 27183 new_path=`cmd //c echo $path` 27184 fi 27185 27186 27187 input_path="$new_path" 27188 # Check if we need to convert this using DOS-style short mode. If the path 27189 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27190 # take no chances and rewrite it. 27191 # Note: m4 eats our [], so we need to use [ and ] instead. 27192 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27193 if test "x$has_forbidden_chars" != x; then 27194 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27195 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27196 fi 27197 27198 27199 windows_path="$new_path" 27200 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27201 unix_path=`$CYGPATH -u "$windows_path"` 27202 new_path="$unix_path" 27203 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27204 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27205 new_path="$unix_path" 27206 fi 27207 27208 if test "x$path" != "x$new_path"; then 27209 BOOT_JDK="$new_path" 27210 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27211 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27212 fi 27213 27214 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27215 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27216 27217 else 27218 # We're on a unix platform. Hooray! :) 27219 path="$BOOT_JDK" 27220 has_space=`$ECHO "$path" | $GREP " "` 27221 if test "x$has_space" != x; then 27222 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27223 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27224 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 27225 fi 27226 27227 # Use eval to expand a potential ~ 27228 eval path="$path" 27229 if test ! -f "$path" && test ! -d "$path"; then 27230 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 27231 fi 27232 27233 if test -d "$path"; then 27234 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 27235 else 27236 dir="`$DIRNAME "$path"`" 27237 base="`$BASENAME "$path"`" 27238 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 27239 fi 27240 fi 27241 fi 27242 27243 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 27244 $as_echo_n "checking for Boot JDK... " >&6; } 27245 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 27246 $as_echo "$BOOT_JDK" >&6; } 27247 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 27248 $as_echo_n "checking Boot JDK version... " >&6; } 27249 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 27250 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 27251 $as_echo "$BOOT_JDK_VERSION" >&6; } 27252 fi # end check jdk version 27253 fi # end check javac 27254 fi # end check java 27255 fi # end check boot jdk found 27256 fi 27257 27258 27259 if test "x$BOOT_JDK_FOUND" = xno; then 27260 # Now execute the test 27261 27262 if test "x$PROGRAMW6432" != x; then 27263 VIRTUAL_DIR="$PROGRAMW6432/Java" 27264 27265 windows_path="$VIRTUAL_DIR" 27266 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27267 unix_path=`$CYGPATH -u "$windows_path"` 27268 VIRTUAL_DIR="$unix_path" 27269 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27270 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27271 VIRTUAL_DIR="$unix_path" 27272 fi 27273 27274 27275 BOOT_JDK_PREFIX="$VIRTUAL_DIR" 27276 BOOT_JDK_SUFFIX="" 27277 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 27278 if test "x$ALL_JDKS_FOUND" != x; then 27279 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 27280 27281 if test "x$BOOT_JDK_FOUND" = xno; then 27282 # Now execute the test 27283 27284 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 27285 if test -d "$BOOT_JDK"; then 27286 BOOT_JDK_FOUND=maybe 27287 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 27288 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 27289 fi 27290 27291 27292 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 27293 if test "x$BOOT_JDK_FOUND" = xmaybe; then 27294 # Do we have a bin/java? 27295 if test ! -x "$BOOT_JDK/bin/java"; then 27296 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 27297 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 27298 BOOT_JDK_FOUND=no 27299 else 27300 # Do we have a bin/javac? 27301 if test ! -x "$BOOT_JDK/bin/javac"; then 27302 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 27303 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 27304 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 27305 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 27306 BOOT_JDK_FOUND=no 27307 else 27308 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 27309 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 27310 27311 # Extra M4 quote needed to protect [] in grep expression. 27312 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 27313 if test "x$FOUND_CORRECT_VERSION" = x; then 27314 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 27315 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 27316 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 27317 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 27318 BOOT_JDK_FOUND=no 27319 else 27320 # We're done! :-) 27321 BOOT_JDK_FOUND=yes 27322 27323 # Only process if variable expands to non-empty 27324 27325 if test "x$BOOT_JDK" != x; then 27326 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27327 27328 # Input might be given as Windows format, start by converting to 27329 # unix format. 27330 path="$BOOT_JDK" 27331 new_path=`$CYGPATH -u "$path"` 27332 27333 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27334 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27335 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27336 # "foo.exe" is OK but "foo" is an error. 27337 # 27338 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27339 # It is also a way to make sure we got the proper file name for the real test later on. 27340 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27341 if test "x$test_shortpath" = x; then 27342 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27343 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27344 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 27345 fi 27346 27347 # Call helper function which possibly converts this using DOS-style short mode. 27348 # If so, the updated path is stored in $new_path. 27349 27350 input_path="$new_path" 27351 # Check if we need to convert this using DOS-style short mode. If the path 27352 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27353 # take no chances and rewrite it. 27354 # Note: m4 eats our [], so we need to use [ and ] instead. 27355 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27356 if test "x$has_forbidden_chars" != x; then 27357 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27358 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27359 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27360 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27361 # Going to short mode and back again did indeed matter. Since short mode is 27362 # case insensitive, let's make it lowercase to improve readability. 27363 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27364 # Now convert it back to Unix-style (cygpath) 27365 input_path=`$CYGPATH -u "$shortmode_path"` 27366 new_path="$input_path" 27367 fi 27368 fi 27369 27370 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27371 if test "x$test_cygdrive_prefix" = x; then 27372 # As a simple fix, exclude /usr/bin since it's not a real path. 27373 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 27374 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27375 # a path prefixed by /cygdrive for fixpath to work. 27376 new_path="$CYGWIN_ROOT_PATH$input_path" 27377 fi 27378 fi 27379 27380 27381 if test "x$path" != "x$new_path"; then 27382 BOOT_JDK="$new_path" 27383 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27384 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27385 fi 27386 27387 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27388 27389 path="$BOOT_JDK" 27390 has_colon=`$ECHO $path | $GREP ^.:` 27391 new_path="$path" 27392 if test "x$has_colon" = x; then 27393 # Not in mixed or Windows style, start by that. 27394 new_path=`cmd //c echo $path` 27395 fi 27396 27397 27398 input_path="$new_path" 27399 # Check if we need to convert this using DOS-style short mode. If the path 27400 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27401 # take no chances and rewrite it. 27402 # Note: m4 eats our [], so we need to use [ and ] instead. 27403 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27404 if test "x$has_forbidden_chars" != x; then 27405 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27406 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27407 fi 27408 27409 27410 windows_path="$new_path" 27411 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27412 unix_path=`$CYGPATH -u "$windows_path"` 27413 new_path="$unix_path" 27414 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27415 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27416 new_path="$unix_path" 27417 fi 27418 27419 if test "x$path" != "x$new_path"; then 27420 BOOT_JDK="$new_path" 27421 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27422 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27423 fi 27424 27425 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27426 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27427 27428 else 27429 # We're on a unix platform. Hooray! :) 27430 path="$BOOT_JDK" 27431 has_space=`$ECHO "$path" | $GREP " "` 27432 if test "x$has_space" != x; then 27433 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27434 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27435 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 27436 fi 27437 27438 # Use eval to expand a potential ~ 27439 eval path="$path" 27440 if test ! -f "$path" && test ! -d "$path"; then 27441 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 27442 fi 27443 27444 if test -d "$path"; then 27445 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 27446 else 27447 dir="`$DIRNAME "$path"`" 27448 base="`$BASENAME "$path"`" 27449 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 27450 fi 27451 fi 27452 fi 27453 27454 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 27455 $as_echo_n "checking for Boot JDK... " >&6; } 27456 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 27457 $as_echo "$BOOT_JDK" >&6; } 27458 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 27459 $as_echo_n "checking Boot JDK version... " >&6; } 27460 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 27461 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 27462 $as_echo "$BOOT_JDK_VERSION" >&6; } 27463 fi # end check jdk version 27464 fi # end check javac 27465 fi # end check java 27466 fi # end check boot jdk found 27467 fi 27468 27469 done 27470 fi 27471 27472 fi 27473 27474 27475 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 27476 if test "x$BOOT_JDK_FOUND" = xmaybe; then 27477 # Do we have a bin/java? 27478 if test ! -x "$BOOT_JDK/bin/java"; then 27479 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 27480 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 27481 BOOT_JDK_FOUND=no 27482 else 27483 # Do we have a bin/javac? 27484 if test ! -x "$BOOT_JDK/bin/javac"; then 27485 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 27486 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 27487 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 27488 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 27489 BOOT_JDK_FOUND=no 27490 else 27491 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 27492 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 27493 27494 # Extra M4 quote needed to protect [] in grep expression. 27495 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 27496 if test "x$FOUND_CORRECT_VERSION" = x; then 27497 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 27498 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 27499 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 27500 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 27501 BOOT_JDK_FOUND=no 27502 else 27503 # We're done! :-) 27504 BOOT_JDK_FOUND=yes 27505 27506 # Only process if variable expands to non-empty 27507 27508 if test "x$BOOT_JDK" != x; then 27509 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27510 27511 # Input might be given as Windows format, start by converting to 27512 # unix format. 27513 path="$BOOT_JDK" 27514 new_path=`$CYGPATH -u "$path"` 27515 27516 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27517 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27518 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27519 # "foo.exe" is OK but "foo" is an error. 27520 # 27521 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27522 # It is also a way to make sure we got the proper file name for the real test later on. 27523 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27524 if test "x$test_shortpath" = x; then 27525 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27526 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27527 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 27528 fi 27529 27530 # Call helper function which possibly converts this using DOS-style short mode. 27531 # If so, the updated path is stored in $new_path. 27532 27533 input_path="$new_path" 27534 # Check if we need to convert this using DOS-style short mode. If the path 27535 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27536 # take no chances and rewrite it. 27537 # Note: m4 eats our [], so we need to use [ and ] instead. 27538 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27539 if test "x$has_forbidden_chars" != x; then 27540 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27541 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27542 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27543 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27544 # Going to short mode and back again did indeed matter. Since short mode is 27545 # case insensitive, let's make it lowercase to improve readability. 27546 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27547 # Now convert it back to Unix-style (cygpath) 27548 input_path=`$CYGPATH -u "$shortmode_path"` 27549 new_path="$input_path" 27550 fi 27551 fi 27552 27553 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27554 if test "x$test_cygdrive_prefix" = x; then 27555 # As a simple fix, exclude /usr/bin since it's not a real path. 27556 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 27557 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27558 # a path prefixed by /cygdrive for fixpath to work. 27559 new_path="$CYGWIN_ROOT_PATH$input_path" 27560 fi 27561 fi 27562 27563 27564 if test "x$path" != "x$new_path"; then 27565 BOOT_JDK="$new_path" 27566 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27567 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27568 fi 27569 27570 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27571 27572 path="$BOOT_JDK" 27573 has_colon=`$ECHO $path | $GREP ^.:` 27574 new_path="$path" 27575 if test "x$has_colon" = x; then 27576 # Not in mixed or Windows style, start by that. 27577 new_path=`cmd //c echo $path` 27578 fi 27579 27580 27581 input_path="$new_path" 27582 # Check if we need to convert this using DOS-style short mode. If the path 27583 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27584 # take no chances and rewrite it. 27585 # Note: m4 eats our [], so we need to use [ and ] instead. 27586 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27587 if test "x$has_forbidden_chars" != x; then 27588 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27589 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27590 fi 27591 27592 27593 windows_path="$new_path" 27594 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27595 unix_path=`$CYGPATH -u "$windows_path"` 27596 new_path="$unix_path" 27597 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27598 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27599 new_path="$unix_path" 27600 fi 27601 27602 if test "x$path" != "x$new_path"; then 27603 BOOT_JDK="$new_path" 27604 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27605 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27606 fi 27607 27608 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27609 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27610 27611 else 27612 # We're on a unix platform. Hooray! :) 27613 path="$BOOT_JDK" 27614 has_space=`$ECHO "$path" | $GREP " "` 27615 if test "x$has_space" != x; then 27616 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27617 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27618 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 27619 fi 27620 27621 # Use eval to expand a potential ~ 27622 eval path="$path" 27623 if test ! -f "$path" && test ! -d "$path"; then 27624 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 27625 fi 27626 27627 if test -d "$path"; then 27628 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 27629 else 27630 dir="`$DIRNAME "$path"`" 27631 base="`$BASENAME "$path"`" 27632 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 27633 fi 27634 fi 27635 fi 27636 27637 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 27638 $as_echo_n "checking for Boot JDK... " >&6; } 27639 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 27640 $as_echo "$BOOT_JDK" >&6; } 27641 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 27642 $as_echo_n "checking Boot JDK version... " >&6; } 27643 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 27644 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 27645 $as_echo "$BOOT_JDK_VERSION" >&6; } 27646 fi # end check jdk version 27647 fi # end check javac 27648 fi # end check java 27649 fi # end check boot jdk found 27650 fi 27651 27652 27653 if test "x$BOOT_JDK_FOUND" = xno; then 27654 # Now execute the test 27655 27656 if test "x$PROGRAMFILES" != x; then 27657 VIRTUAL_DIR="$PROGRAMFILES/Java" 27658 27659 windows_path="$VIRTUAL_DIR" 27660 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27661 unix_path=`$CYGPATH -u "$windows_path"` 27662 VIRTUAL_DIR="$unix_path" 27663 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27664 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27665 VIRTUAL_DIR="$unix_path" 27666 fi 27667 27668 27669 BOOT_JDK_PREFIX="$VIRTUAL_DIR" 27670 BOOT_JDK_SUFFIX="" 27671 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 27672 if test "x$ALL_JDKS_FOUND" != x; then 27673 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 27674 27675 if test "x$BOOT_JDK_FOUND" = xno; then 27676 # Now execute the test 27677 27678 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 27679 if test -d "$BOOT_JDK"; then 27680 BOOT_JDK_FOUND=maybe 27681 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 27682 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 27683 fi 27684 27685 27686 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 27687 if test "x$BOOT_JDK_FOUND" = xmaybe; then 27688 # Do we have a bin/java? 27689 if test ! -x "$BOOT_JDK/bin/java"; then 27690 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 27691 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 27692 BOOT_JDK_FOUND=no 27693 else 27694 # Do we have a bin/javac? 27695 if test ! -x "$BOOT_JDK/bin/javac"; then 27696 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 27697 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 27698 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 27699 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 27700 BOOT_JDK_FOUND=no 27701 else 27702 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 27703 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 27704 27705 # Extra M4 quote needed to protect [] in grep expression. 27706 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 27707 if test "x$FOUND_CORRECT_VERSION" = x; then 27708 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 27709 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 27710 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 27711 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 27712 BOOT_JDK_FOUND=no 27713 else 27714 # We're done! :-) 27715 BOOT_JDK_FOUND=yes 27716 27717 # Only process if variable expands to non-empty 27718 27719 if test "x$BOOT_JDK" != x; then 27720 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27721 27722 # Input might be given as Windows format, start by converting to 27723 # unix format. 27724 path="$BOOT_JDK" 27725 new_path=`$CYGPATH -u "$path"` 27726 27727 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27728 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27729 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27730 # "foo.exe" is OK but "foo" is an error. 27731 # 27732 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27733 # It is also a way to make sure we got the proper file name for the real test later on. 27734 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27735 if test "x$test_shortpath" = x; then 27736 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27737 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27738 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 27739 fi 27740 27741 # Call helper function which possibly converts this using DOS-style short mode. 27742 # If so, the updated path is stored in $new_path. 27743 27744 input_path="$new_path" 27745 # Check if we need to convert this using DOS-style short mode. If the path 27746 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27747 # take no chances and rewrite it. 27748 # Note: m4 eats our [], so we need to use [ and ] instead. 27749 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27750 if test "x$has_forbidden_chars" != x; then 27751 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27752 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27753 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27754 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27755 # Going to short mode and back again did indeed matter. Since short mode is 27756 # case insensitive, let's make it lowercase to improve readability. 27757 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27758 # Now convert it back to Unix-style (cygpath) 27759 input_path=`$CYGPATH -u "$shortmode_path"` 27760 new_path="$input_path" 27761 fi 27762 fi 27763 27764 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27765 if test "x$test_cygdrive_prefix" = x; then 27766 # As a simple fix, exclude /usr/bin since it's not a real path. 27767 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 27768 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27769 # a path prefixed by /cygdrive for fixpath to work. 27770 new_path="$CYGWIN_ROOT_PATH$input_path" 27771 fi 27772 fi 27773 27774 27775 if test "x$path" != "x$new_path"; then 27776 BOOT_JDK="$new_path" 27777 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27778 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27779 fi 27780 27781 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27782 27783 path="$BOOT_JDK" 27784 has_colon=`$ECHO $path | $GREP ^.:` 27785 new_path="$path" 27786 if test "x$has_colon" = x; then 27787 # Not in mixed or Windows style, start by that. 27788 new_path=`cmd //c echo $path` 27789 fi 27790 27791 27792 input_path="$new_path" 27793 # Check if we need to convert this using DOS-style short mode. If the path 27794 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27795 # take no chances and rewrite it. 27796 # Note: m4 eats our [], so we need to use [ and ] instead. 27797 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27798 if test "x$has_forbidden_chars" != x; then 27799 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27800 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27801 fi 27802 27803 27804 windows_path="$new_path" 27805 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27806 unix_path=`$CYGPATH -u "$windows_path"` 27807 new_path="$unix_path" 27808 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27809 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27810 new_path="$unix_path" 27811 fi 27812 27813 if test "x$path" != "x$new_path"; then 27814 BOOT_JDK="$new_path" 27815 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27816 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27817 fi 27818 27819 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27820 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27821 27822 else 27823 # We're on a unix platform. Hooray! :) 27824 path="$BOOT_JDK" 27825 has_space=`$ECHO "$path" | $GREP " "` 27826 if test "x$has_space" != x; then 27827 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27828 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27829 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 27830 fi 27831 27832 # Use eval to expand a potential ~ 27833 eval path="$path" 27834 if test ! -f "$path" && test ! -d "$path"; then 27835 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 27836 fi 27837 27838 if test -d "$path"; then 27839 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 27840 else 27841 dir="`$DIRNAME "$path"`" 27842 base="`$BASENAME "$path"`" 27843 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 27844 fi 27845 fi 27846 fi 27847 27848 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 27849 $as_echo_n "checking for Boot JDK... " >&6; } 27850 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 27851 $as_echo "$BOOT_JDK" >&6; } 27852 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 27853 $as_echo_n "checking Boot JDK version... " >&6; } 27854 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 27855 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 27856 $as_echo "$BOOT_JDK_VERSION" >&6; } 27857 fi # end check jdk version 27858 fi # end check javac 27859 fi # end check java 27860 fi # end check boot jdk found 27861 fi 27862 27863 done 27864 fi 27865 27866 fi 27867 27868 27869 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 27870 if test "x$BOOT_JDK_FOUND" = xmaybe; then 27871 # Do we have a bin/java? 27872 if test ! -x "$BOOT_JDK/bin/java"; then 27873 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 27874 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 27875 BOOT_JDK_FOUND=no 27876 else 27877 # Do we have a bin/javac? 27878 if test ! -x "$BOOT_JDK/bin/javac"; then 27879 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 27880 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 27881 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 27882 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 27883 BOOT_JDK_FOUND=no 27884 else 27885 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 27886 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 27887 27888 # Extra M4 quote needed to protect [] in grep expression. 27889 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 27890 if test "x$FOUND_CORRECT_VERSION" = x; then 27891 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 27892 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 27893 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 27894 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 27895 BOOT_JDK_FOUND=no 27896 else 27897 # We're done! :-) 27898 BOOT_JDK_FOUND=yes 27899 27900 # Only process if variable expands to non-empty 27901 27902 if test "x$BOOT_JDK" != x; then 27903 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27904 27905 # Input might be given as Windows format, start by converting to 27906 # unix format. 27907 path="$BOOT_JDK" 27908 new_path=`$CYGPATH -u "$path"` 27909 27910 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27911 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27912 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27913 # "foo.exe" is OK but "foo" is an error. 27914 # 27915 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27916 # It is also a way to make sure we got the proper file name for the real test later on. 27917 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27918 if test "x$test_shortpath" = x; then 27919 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27920 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27921 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 27922 fi 27923 27924 # Call helper function which possibly converts this using DOS-style short mode. 27925 # If so, the updated path is stored in $new_path. 27926 27927 input_path="$new_path" 27928 # Check if we need to convert this using DOS-style short mode. If the path 27929 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27930 # take no chances and rewrite it. 27931 # Note: m4 eats our [], so we need to use [ and ] instead. 27932 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27933 if test "x$has_forbidden_chars" != x; then 27934 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27935 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27936 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27937 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27938 # Going to short mode and back again did indeed matter. Since short mode is 27939 # case insensitive, let's make it lowercase to improve readability. 27940 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27941 # Now convert it back to Unix-style (cygpath) 27942 input_path=`$CYGPATH -u "$shortmode_path"` 27943 new_path="$input_path" 27944 fi 27945 fi 27946 27947 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27948 if test "x$test_cygdrive_prefix" = x; then 27949 # As a simple fix, exclude /usr/bin since it's not a real path. 27950 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 27951 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27952 # a path prefixed by /cygdrive for fixpath to work. 27953 new_path="$CYGWIN_ROOT_PATH$input_path" 27954 fi 27955 fi 27956 27957 27958 if test "x$path" != "x$new_path"; then 27959 BOOT_JDK="$new_path" 27960 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27961 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27962 fi 27963 27964 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27965 27966 path="$BOOT_JDK" 27967 has_colon=`$ECHO $path | $GREP ^.:` 27968 new_path="$path" 27969 if test "x$has_colon" = x; then 27970 # Not in mixed or Windows style, start by that. 27971 new_path=`cmd //c echo $path` 27972 fi 27973 27974 27975 input_path="$new_path" 27976 # Check if we need to convert this using DOS-style short mode. If the path 27977 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27978 # take no chances and rewrite it. 27979 # Note: m4 eats our [], so we need to use [ and ] instead. 27980 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27981 if test "x$has_forbidden_chars" != x; then 27982 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27983 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27984 fi 27985 27986 27987 windows_path="$new_path" 27988 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27989 unix_path=`$CYGPATH -u "$windows_path"` 27990 new_path="$unix_path" 27991 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27992 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27993 new_path="$unix_path" 27994 fi 27995 27996 if test "x$path" != "x$new_path"; then 27997 BOOT_JDK="$new_path" 27998 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27999 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28000 fi 28001 28002 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28003 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28004 28005 else 28006 # We're on a unix platform. Hooray! :) 28007 path="$BOOT_JDK" 28008 has_space=`$ECHO "$path" | $GREP " "` 28009 if test "x$has_space" != x; then 28010 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28011 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28012 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28013 fi 28014 28015 # Use eval to expand a potential ~ 28016 eval path="$path" 28017 if test ! -f "$path" && test ! -d "$path"; then 28018 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28019 fi 28020 28021 if test -d "$path"; then 28022 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28023 else 28024 dir="`$DIRNAME "$path"`" 28025 base="`$BASENAME "$path"`" 28026 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28027 fi 28028 fi 28029 fi 28030 28031 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 28032 $as_echo_n "checking for Boot JDK... " >&6; } 28033 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 28034 $as_echo "$BOOT_JDK" >&6; } 28035 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 28036 $as_echo_n "checking Boot JDK version... " >&6; } 28037 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 28038 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 28039 $as_echo "$BOOT_JDK_VERSION" >&6; } 28040 fi # end check jdk version 28041 fi # end check javac 28042 fi # end check java 28043 fi # end check boot jdk found 28044 fi 28045 28046 28047 if test "x$BOOT_JDK_FOUND" = xno; then 28048 # Now execute the test 28049 28050 if test "x$ProgramFiles" != x; then 28051 VIRTUAL_DIR="$ProgramFiles/Java" 28052 28053 windows_path="$VIRTUAL_DIR" 28054 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28055 unix_path=`$CYGPATH -u "$windows_path"` 28056 VIRTUAL_DIR="$unix_path" 28057 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28058 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28059 VIRTUAL_DIR="$unix_path" 28060 fi 28061 28062 28063 BOOT_JDK_PREFIX="$VIRTUAL_DIR" 28064 BOOT_JDK_SUFFIX="" 28065 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 28066 if test "x$ALL_JDKS_FOUND" != x; then 28067 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 28068 28069 if test "x$BOOT_JDK_FOUND" = xno; then 28070 # Now execute the test 28071 28072 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 28073 if test -d "$BOOT_JDK"; then 28074 BOOT_JDK_FOUND=maybe 28075 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 28076 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 28077 fi 28078 28079 28080 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 28081 if test "x$BOOT_JDK_FOUND" = xmaybe; then 28082 # Do we have a bin/java? 28083 if test ! -x "$BOOT_JDK/bin/java"; then 28084 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 28085 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 28086 BOOT_JDK_FOUND=no 28087 else 28088 # Do we have a bin/javac? 28089 if test ! -x "$BOOT_JDK/bin/javac"; then 28090 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 28091 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 28092 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 28093 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 28094 BOOT_JDK_FOUND=no 28095 else 28096 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 28097 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 28098 28099 # Extra M4 quote needed to protect [] in grep expression. 28100 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 28101 if test "x$FOUND_CORRECT_VERSION" = x; then 28102 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 28103 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 28104 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 28105 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 28106 BOOT_JDK_FOUND=no 28107 else 28108 # We're done! :-) 28109 BOOT_JDK_FOUND=yes 28110 28111 # Only process if variable expands to non-empty 28112 28113 if test "x$BOOT_JDK" != x; then 28114 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28115 28116 # Input might be given as Windows format, start by converting to 28117 # unix format. 28118 path="$BOOT_JDK" 28119 new_path=`$CYGPATH -u "$path"` 28120 28121 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28122 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28123 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28124 # "foo.exe" is OK but "foo" is an error. 28125 # 28126 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28127 # It is also a way to make sure we got the proper file name for the real test later on. 28128 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28129 if test "x$test_shortpath" = x; then 28130 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28131 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28132 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28133 fi 28134 28135 # Call helper function which possibly converts this using DOS-style short mode. 28136 # If so, the updated path is stored in $new_path. 28137 28138 input_path="$new_path" 28139 # Check if we need to convert this using DOS-style short mode. If the path 28140 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28141 # take no chances and rewrite it. 28142 # Note: m4 eats our [], so we need to use [ and ] instead. 28143 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28144 if test "x$has_forbidden_chars" != x; then 28145 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28146 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28147 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28148 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28149 # Going to short mode and back again did indeed matter. Since short mode is 28150 # case insensitive, let's make it lowercase to improve readability. 28151 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28152 # Now convert it back to Unix-style (cygpath) 28153 input_path=`$CYGPATH -u "$shortmode_path"` 28154 new_path="$input_path" 28155 fi 28156 fi 28157 28158 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28159 if test "x$test_cygdrive_prefix" = x; then 28160 # As a simple fix, exclude /usr/bin since it's not a real path. 28161 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 28162 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28163 # a path prefixed by /cygdrive for fixpath to work. 28164 new_path="$CYGWIN_ROOT_PATH$input_path" 28165 fi 28166 fi 28167 28168 28169 if test "x$path" != "x$new_path"; then 28170 BOOT_JDK="$new_path" 28171 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28172 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28173 fi 28174 28175 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28176 28177 path="$BOOT_JDK" 28178 has_colon=`$ECHO $path | $GREP ^.:` 28179 new_path="$path" 28180 if test "x$has_colon" = x; then 28181 # Not in mixed or Windows style, start by that. 28182 new_path=`cmd //c echo $path` 28183 fi 28184 28185 28186 input_path="$new_path" 28187 # Check if we need to convert this using DOS-style short mode. If the path 28188 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28189 # take no chances and rewrite it. 28190 # Note: m4 eats our [], so we need to use [ and ] instead. 28191 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28192 if test "x$has_forbidden_chars" != x; then 28193 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28194 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28195 fi 28196 28197 28198 windows_path="$new_path" 28199 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28200 unix_path=`$CYGPATH -u "$windows_path"` 28201 new_path="$unix_path" 28202 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28203 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28204 new_path="$unix_path" 28205 fi 28206 28207 if test "x$path" != "x$new_path"; then 28208 BOOT_JDK="$new_path" 28209 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28210 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28211 fi 28212 28213 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28214 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28215 28216 else 28217 # We're on a unix platform. Hooray! :) 28218 path="$BOOT_JDK" 28219 has_space=`$ECHO "$path" | $GREP " "` 28220 if test "x$has_space" != x; then 28221 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28222 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28223 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28224 fi 28225 28226 # Use eval to expand a potential ~ 28227 eval path="$path" 28228 if test ! -f "$path" && test ! -d "$path"; then 28229 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28230 fi 28231 28232 if test -d "$path"; then 28233 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28234 else 28235 dir="`$DIRNAME "$path"`" 28236 base="`$BASENAME "$path"`" 28237 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28238 fi 28239 fi 28240 fi 28241 28242 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 28243 $as_echo_n "checking for Boot JDK... " >&6; } 28244 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 28245 $as_echo "$BOOT_JDK" >&6; } 28246 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 28247 $as_echo_n "checking Boot JDK version... " >&6; } 28248 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 28249 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 28250 $as_echo "$BOOT_JDK_VERSION" >&6; } 28251 fi # end check jdk version 28252 fi # end check javac 28253 fi # end check java 28254 fi # end check boot jdk found 28255 fi 28256 28257 done 28258 fi 28259 28260 fi 28261 28262 28263 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 28264 if test "x$BOOT_JDK_FOUND" = xmaybe; then 28265 # Do we have a bin/java? 28266 if test ! -x "$BOOT_JDK/bin/java"; then 28267 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 28268 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 28269 BOOT_JDK_FOUND=no 28270 else 28271 # Do we have a bin/javac? 28272 if test ! -x "$BOOT_JDK/bin/javac"; then 28273 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 28274 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 28275 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 28276 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 28277 BOOT_JDK_FOUND=no 28278 else 28279 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 28280 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 28281 28282 # Extra M4 quote needed to protect [] in grep expression. 28283 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 28284 if test "x$FOUND_CORRECT_VERSION" = x; then 28285 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 28286 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 28287 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 28288 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 28289 BOOT_JDK_FOUND=no 28290 else 28291 # We're done! :-) 28292 BOOT_JDK_FOUND=yes 28293 28294 # Only process if variable expands to non-empty 28295 28296 if test "x$BOOT_JDK" != x; then 28297 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28298 28299 # Input might be given as Windows format, start by converting to 28300 # unix format. 28301 path="$BOOT_JDK" 28302 new_path=`$CYGPATH -u "$path"` 28303 28304 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28305 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28306 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28307 # "foo.exe" is OK but "foo" is an error. 28308 # 28309 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28310 # It is also a way to make sure we got the proper file name for the real test later on. 28311 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28312 if test "x$test_shortpath" = x; then 28313 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28314 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28315 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28316 fi 28317 28318 # Call helper function which possibly converts this using DOS-style short mode. 28319 # If so, the updated path is stored in $new_path. 28320 28321 input_path="$new_path" 28322 # Check if we need to convert this using DOS-style short mode. If the path 28323 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28324 # take no chances and rewrite it. 28325 # Note: m4 eats our [], so we need to use [ and ] instead. 28326 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28327 if test "x$has_forbidden_chars" != x; then 28328 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28329 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28330 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28331 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28332 # Going to short mode and back again did indeed matter. Since short mode is 28333 # case insensitive, let's make it lowercase to improve readability. 28334 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28335 # Now convert it back to Unix-style (cygpath) 28336 input_path=`$CYGPATH -u "$shortmode_path"` 28337 new_path="$input_path" 28338 fi 28339 fi 28340 28341 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28342 if test "x$test_cygdrive_prefix" = x; then 28343 # As a simple fix, exclude /usr/bin since it's not a real path. 28344 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 28345 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28346 # a path prefixed by /cygdrive for fixpath to work. 28347 new_path="$CYGWIN_ROOT_PATH$input_path" 28348 fi 28349 fi 28350 28351 28352 if test "x$path" != "x$new_path"; then 28353 BOOT_JDK="$new_path" 28354 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28355 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28356 fi 28357 28358 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28359 28360 path="$BOOT_JDK" 28361 has_colon=`$ECHO $path | $GREP ^.:` 28362 new_path="$path" 28363 if test "x$has_colon" = x; then 28364 # Not in mixed or Windows style, start by that. 28365 new_path=`cmd //c echo $path` 28366 fi 28367 28368 28369 input_path="$new_path" 28370 # Check if we need to convert this using DOS-style short mode. If the path 28371 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28372 # take no chances and rewrite it. 28373 # Note: m4 eats our [], so we need to use [ and ] instead. 28374 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28375 if test "x$has_forbidden_chars" != x; then 28376 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28377 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28378 fi 28379 28380 28381 windows_path="$new_path" 28382 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28383 unix_path=`$CYGPATH -u "$windows_path"` 28384 new_path="$unix_path" 28385 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28386 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28387 new_path="$unix_path" 28388 fi 28389 28390 if test "x$path" != "x$new_path"; then 28391 BOOT_JDK="$new_path" 28392 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28393 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28394 fi 28395 28396 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28397 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28398 28399 else 28400 # We're on a unix platform. Hooray! :) 28401 path="$BOOT_JDK" 28402 has_space=`$ECHO "$path" | $GREP " "` 28403 if test "x$has_space" != x; then 28404 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28405 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28406 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28407 fi 28408 28409 # Use eval to expand a potential ~ 28410 eval path="$path" 28411 if test ! -f "$path" && test ! -d "$path"; then 28412 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28413 fi 28414 28415 if test -d "$path"; then 28416 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28417 else 28418 dir="`$DIRNAME "$path"`" 28419 base="`$BASENAME "$path"`" 28420 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28421 fi 28422 fi 28423 fi 28424 28425 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 28426 $as_echo_n "checking for Boot JDK... " >&6; } 28427 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 28428 $as_echo "$BOOT_JDK" >&6; } 28429 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 28430 $as_echo_n "checking Boot JDK version... " >&6; } 28431 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 28432 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 28433 $as_echo "$BOOT_JDK_VERSION" >&6; } 28434 fi # end check jdk version 28435 fi # end check javac 28436 fi # end check java 28437 fi # end check boot jdk found 28438 fi 28439 28440 28441 if test "x$BOOT_JDK_FOUND" = xno; then 28442 # Now execute the test 28443 28444 BOOT_JDK_PREFIX="/cygdrive/c/Program Files/Java" 28445 BOOT_JDK_SUFFIX="" 28446 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 28447 if test "x$ALL_JDKS_FOUND" != x; then 28448 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 28449 28450 if test "x$BOOT_JDK_FOUND" = xno; then 28451 # Now execute the test 28452 28453 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 28454 if test -d "$BOOT_JDK"; then 28455 BOOT_JDK_FOUND=maybe 28456 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 28457 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 28458 fi 28459 28460 28461 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 28462 if test "x$BOOT_JDK_FOUND" = xmaybe; then 28463 # Do we have a bin/java? 28464 if test ! -x "$BOOT_JDK/bin/java"; then 28465 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 28466 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 28467 BOOT_JDK_FOUND=no 28468 else 28469 # Do we have a bin/javac? 28470 if test ! -x "$BOOT_JDK/bin/javac"; then 28471 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 28472 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 28473 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 28474 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 28475 BOOT_JDK_FOUND=no 28476 else 28477 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 28478 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 28479 28480 # Extra M4 quote needed to protect [] in grep expression. 28481 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 28482 if test "x$FOUND_CORRECT_VERSION" = x; then 28483 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 28484 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 28485 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 28486 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 28487 BOOT_JDK_FOUND=no 28488 else 28489 # We're done! :-) 28490 BOOT_JDK_FOUND=yes 28491 28492 # Only process if variable expands to non-empty 28493 28494 if test "x$BOOT_JDK" != x; then 28495 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28496 28497 # Input might be given as Windows format, start by converting to 28498 # unix format. 28499 path="$BOOT_JDK" 28500 new_path=`$CYGPATH -u "$path"` 28501 28502 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28503 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28504 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28505 # "foo.exe" is OK but "foo" is an error. 28506 # 28507 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28508 # It is also a way to make sure we got the proper file name for the real test later on. 28509 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28510 if test "x$test_shortpath" = x; then 28511 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28512 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28513 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28514 fi 28515 28516 # Call helper function which possibly converts this using DOS-style short mode. 28517 # If so, the updated path is stored in $new_path. 28518 28519 input_path="$new_path" 28520 # Check if we need to convert this using DOS-style short mode. If the path 28521 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28522 # take no chances and rewrite it. 28523 # Note: m4 eats our [], so we need to use [ and ] instead. 28524 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28525 if test "x$has_forbidden_chars" != x; then 28526 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28527 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28528 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28529 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28530 # Going to short mode and back again did indeed matter. Since short mode is 28531 # case insensitive, let's make it lowercase to improve readability. 28532 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28533 # Now convert it back to Unix-style (cygpath) 28534 input_path=`$CYGPATH -u "$shortmode_path"` 28535 new_path="$input_path" 28536 fi 28537 fi 28538 28539 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28540 if test "x$test_cygdrive_prefix" = x; then 28541 # As a simple fix, exclude /usr/bin since it's not a real path. 28542 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 28543 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28544 # a path prefixed by /cygdrive for fixpath to work. 28545 new_path="$CYGWIN_ROOT_PATH$input_path" 28546 fi 28547 fi 28548 28549 28550 if test "x$path" != "x$new_path"; then 28551 BOOT_JDK="$new_path" 28552 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28553 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28554 fi 28555 28556 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28557 28558 path="$BOOT_JDK" 28559 has_colon=`$ECHO $path | $GREP ^.:` 28560 new_path="$path" 28561 if test "x$has_colon" = x; then 28562 # Not in mixed or Windows style, start by that. 28563 new_path=`cmd //c echo $path` 28564 fi 28565 28566 28567 input_path="$new_path" 28568 # Check if we need to convert this using DOS-style short mode. If the path 28569 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28570 # take no chances and rewrite it. 28571 # Note: m4 eats our [], so we need to use [ and ] instead. 28572 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28573 if test "x$has_forbidden_chars" != x; then 28574 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28575 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28576 fi 28577 28578 28579 windows_path="$new_path" 28580 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28581 unix_path=`$CYGPATH -u "$windows_path"` 28582 new_path="$unix_path" 28583 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28584 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28585 new_path="$unix_path" 28586 fi 28587 28588 if test "x$path" != "x$new_path"; then 28589 BOOT_JDK="$new_path" 28590 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28591 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28592 fi 28593 28594 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28595 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28596 28597 else 28598 # We're on a unix platform. Hooray! :) 28599 path="$BOOT_JDK" 28600 has_space=`$ECHO "$path" | $GREP " "` 28601 if test "x$has_space" != x; then 28602 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28603 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28604 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28605 fi 28606 28607 # Use eval to expand a potential ~ 28608 eval path="$path" 28609 if test ! -f "$path" && test ! -d "$path"; then 28610 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28611 fi 28612 28613 if test -d "$path"; then 28614 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28615 else 28616 dir="`$DIRNAME "$path"`" 28617 base="`$BASENAME "$path"`" 28618 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28619 fi 28620 fi 28621 fi 28622 28623 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 28624 $as_echo_n "checking for Boot JDK... " >&6; } 28625 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 28626 $as_echo "$BOOT_JDK" >&6; } 28627 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 28628 $as_echo_n "checking Boot JDK version... " >&6; } 28629 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 28630 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 28631 $as_echo "$BOOT_JDK_VERSION" >&6; } 28632 fi # end check jdk version 28633 fi # end check javac 28634 fi # end check java 28635 fi # end check boot jdk found 28636 fi 28637 28638 done 28639 fi 28640 28641 28642 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 28643 if test "x$BOOT_JDK_FOUND" = xmaybe; then 28644 # Do we have a bin/java? 28645 if test ! -x "$BOOT_JDK/bin/java"; then 28646 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 28647 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 28648 BOOT_JDK_FOUND=no 28649 else 28650 # Do we have a bin/javac? 28651 if test ! -x "$BOOT_JDK/bin/javac"; then 28652 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 28653 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 28654 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 28655 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 28656 BOOT_JDK_FOUND=no 28657 else 28658 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 28659 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 28660 28661 # Extra M4 quote needed to protect [] in grep expression. 28662 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 28663 if test "x$FOUND_CORRECT_VERSION" = x; then 28664 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 28665 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 28666 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 28667 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 28668 BOOT_JDK_FOUND=no 28669 else 28670 # We're done! :-) 28671 BOOT_JDK_FOUND=yes 28672 28673 # Only process if variable expands to non-empty 28674 28675 if test "x$BOOT_JDK" != x; then 28676 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28677 28678 # Input might be given as Windows format, start by converting to 28679 # unix format. 28680 path="$BOOT_JDK" 28681 new_path=`$CYGPATH -u "$path"` 28682 28683 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28684 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28685 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28686 # "foo.exe" is OK but "foo" is an error. 28687 # 28688 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28689 # It is also a way to make sure we got the proper file name for the real test later on. 28690 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28691 if test "x$test_shortpath" = x; then 28692 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28693 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28694 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28695 fi 28696 28697 # Call helper function which possibly converts this using DOS-style short mode. 28698 # If so, the updated path is stored in $new_path. 28699 28700 input_path="$new_path" 28701 # Check if we need to convert this using DOS-style short mode. If the path 28702 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28703 # take no chances and rewrite it. 28704 # Note: m4 eats our [], so we need to use [ and ] instead. 28705 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28706 if test "x$has_forbidden_chars" != x; then 28707 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28708 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28709 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28710 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28711 # Going to short mode and back again did indeed matter. Since short mode is 28712 # case insensitive, let's make it lowercase to improve readability. 28713 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28714 # Now convert it back to Unix-style (cygpath) 28715 input_path=`$CYGPATH -u "$shortmode_path"` 28716 new_path="$input_path" 28717 fi 28718 fi 28719 28720 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28721 if test "x$test_cygdrive_prefix" = x; then 28722 # As a simple fix, exclude /usr/bin since it's not a real path. 28723 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 28724 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28725 # a path prefixed by /cygdrive for fixpath to work. 28726 new_path="$CYGWIN_ROOT_PATH$input_path" 28727 fi 28728 fi 28729 28730 28731 if test "x$path" != "x$new_path"; then 28732 BOOT_JDK="$new_path" 28733 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28734 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28735 fi 28736 28737 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28738 28739 path="$BOOT_JDK" 28740 has_colon=`$ECHO $path | $GREP ^.:` 28741 new_path="$path" 28742 if test "x$has_colon" = x; then 28743 # Not in mixed or Windows style, start by that. 28744 new_path=`cmd //c echo $path` 28745 fi 28746 28747 28748 input_path="$new_path" 28749 # Check if we need to convert this using DOS-style short mode. If the path 28750 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28751 # take no chances and rewrite it. 28752 # Note: m4 eats our [], so we need to use [ and ] instead. 28753 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28754 if test "x$has_forbidden_chars" != x; then 28755 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28756 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28757 fi 28758 28759 28760 windows_path="$new_path" 28761 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28762 unix_path=`$CYGPATH -u "$windows_path"` 28763 new_path="$unix_path" 28764 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28765 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28766 new_path="$unix_path" 28767 fi 28768 28769 if test "x$path" != "x$new_path"; then 28770 BOOT_JDK="$new_path" 28771 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28772 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28773 fi 28774 28775 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28776 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28777 28778 else 28779 # We're on a unix platform. Hooray! :) 28780 path="$BOOT_JDK" 28781 has_space=`$ECHO "$path" | $GREP " "` 28782 if test "x$has_space" != x; then 28783 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28784 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28785 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28786 fi 28787 28788 # Use eval to expand a potential ~ 28789 eval path="$path" 28790 if test ! -f "$path" && test ! -d "$path"; then 28791 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28792 fi 28793 28794 if test -d "$path"; then 28795 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28796 else 28797 dir="`$DIRNAME "$path"`" 28798 base="`$BASENAME "$path"`" 28799 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28800 fi 28801 fi 28802 fi 28803 28804 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 28805 $as_echo_n "checking for Boot JDK... " >&6; } 28806 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 28807 $as_echo "$BOOT_JDK" >&6; } 28808 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 28809 $as_echo_n "checking Boot JDK version... " >&6; } 28810 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 28811 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 28812 $as_echo "$BOOT_JDK_VERSION" >&6; } 28813 fi # end check jdk version 28814 fi # end check javac 28815 fi # end check java 28816 fi # end check boot jdk found 28817 fi 28818 28819 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 28820 28821 if test "x$BOOT_JDK_FOUND" = xno; then 28822 # Now execute the test 28823 28824 BOOT_JDK_PREFIX="/Library/Java/JavaVirtualMachines" 28825 BOOT_JDK_SUFFIX="/Contents/Home" 28826 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 28827 if test "x$ALL_JDKS_FOUND" != x; then 28828 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 28829 28830 if test "x$BOOT_JDK_FOUND" = xno; then 28831 # Now execute the test 28832 28833 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 28834 if test -d "$BOOT_JDK"; then 28835 BOOT_JDK_FOUND=maybe 28836 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 28837 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 28838 fi 28839 28840 28841 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 28842 if test "x$BOOT_JDK_FOUND" = xmaybe; then 28843 # Do we have a bin/java? 28844 if test ! -x "$BOOT_JDK/bin/java"; then 28845 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 28846 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 28847 BOOT_JDK_FOUND=no 28848 else 28849 # Do we have a bin/javac? 28850 if test ! -x "$BOOT_JDK/bin/javac"; then 28851 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 28852 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 28853 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 28854 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 28855 BOOT_JDK_FOUND=no 28856 else 28857 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 28858 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 28859 28860 # Extra M4 quote needed to protect [] in grep expression. 28861 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 28862 if test "x$FOUND_CORRECT_VERSION" = x; then 28863 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 28864 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 28865 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 28866 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 28867 BOOT_JDK_FOUND=no 28868 else 28869 # We're done! :-) 28870 BOOT_JDK_FOUND=yes 28871 28872 # Only process if variable expands to non-empty 28873 28874 if test "x$BOOT_JDK" != x; then 28875 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28876 28877 # Input might be given as Windows format, start by converting to 28878 # unix format. 28879 path="$BOOT_JDK" 28880 new_path=`$CYGPATH -u "$path"` 28881 28882 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28883 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28884 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28885 # "foo.exe" is OK but "foo" is an error. 28886 # 28887 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28888 # It is also a way to make sure we got the proper file name for the real test later on. 28889 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28890 if test "x$test_shortpath" = x; then 28891 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28892 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28893 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28894 fi 28895 28896 # Call helper function which possibly converts this using DOS-style short mode. 28897 # If so, the updated path is stored in $new_path. 28898 28899 input_path="$new_path" 28900 # Check if we need to convert this using DOS-style short mode. If the path 28901 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28902 # take no chances and rewrite it. 28903 # Note: m4 eats our [], so we need to use [ and ] instead. 28904 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28905 if test "x$has_forbidden_chars" != x; then 28906 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28907 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28908 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28909 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28910 # Going to short mode and back again did indeed matter. Since short mode is 28911 # case insensitive, let's make it lowercase to improve readability. 28912 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28913 # Now convert it back to Unix-style (cygpath) 28914 input_path=`$CYGPATH -u "$shortmode_path"` 28915 new_path="$input_path" 28916 fi 28917 fi 28918 28919 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28920 if test "x$test_cygdrive_prefix" = x; then 28921 # As a simple fix, exclude /usr/bin since it's not a real path. 28922 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 28923 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28924 # a path prefixed by /cygdrive for fixpath to work. 28925 new_path="$CYGWIN_ROOT_PATH$input_path" 28926 fi 28927 fi 28928 28929 28930 if test "x$path" != "x$new_path"; then 28931 BOOT_JDK="$new_path" 28932 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28933 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28934 fi 28935 28936 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28937 28938 path="$BOOT_JDK" 28939 has_colon=`$ECHO $path | $GREP ^.:` 28940 new_path="$path" 28941 if test "x$has_colon" = x; then 28942 # Not in mixed or Windows style, start by that. 28943 new_path=`cmd //c echo $path` 28944 fi 28945 28946 28947 input_path="$new_path" 28948 # Check if we need to convert this using DOS-style short mode. If the path 28949 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28950 # take no chances and rewrite it. 28951 # Note: m4 eats our [], so we need to use [ and ] instead. 28952 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28953 if test "x$has_forbidden_chars" != x; then 28954 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28955 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28956 fi 28957 28958 28959 windows_path="$new_path" 28960 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28961 unix_path=`$CYGPATH -u "$windows_path"` 28962 new_path="$unix_path" 28963 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28964 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28965 new_path="$unix_path" 28966 fi 28967 28968 if test "x$path" != "x$new_path"; then 28969 BOOT_JDK="$new_path" 28970 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28971 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28972 fi 28973 28974 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28975 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28976 28977 else 28978 # We're on a unix platform. Hooray! :) 28979 path="$BOOT_JDK" 28980 has_space=`$ECHO "$path" | $GREP " "` 28981 if test "x$has_space" != x; then 28982 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28983 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28984 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28985 fi 28986 28987 # Use eval to expand a potential ~ 28988 eval path="$path" 28989 if test ! -f "$path" && test ! -d "$path"; then 28990 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28991 fi 28992 28993 if test -d "$path"; then 28994 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28995 else 28996 dir="`$DIRNAME "$path"`" 28997 base="`$BASENAME "$path"`" 28998 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28999 fi 29000 fi 29001 fi 29002 29003 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 29004 $as_echo_n "checking for Boot JDK... " >&6; } 29005 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 29006 $as_echo "$BOOT_JDK" >&6; } 29007 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 29008 $as_echo_n "checking Boot JDK version... " >&6; } 29009 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 29010 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 29011 $as_echo "$BOOT_JDK_VERSION" >&6; } 29012 fi # end check jdk version 29013 fi # end check javac 29014 fi # end check java 29015 fi # end check boot jdk found 29016 fi 29017 29018 done 29019 fi 29020 29021 29022 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 29023 if test "x$BOOT_JDK_FOUND" = xmaybe; then 29024 # Do we have a bin/java? 29025 if test ! -x "$BOOT_JDK/bin/java"; then 29026 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 29027 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 29028 BOOT_JDK_FOUND=no 29029 else 29030 # Do we have a bin/javac? 29031 if test ! -x "$BOOT_JDK/bin/javac"; then 29032 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 29033 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 29034 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 29035 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 29036 BOOT_JDK_FOUND=no 29037 else 29038 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 29039 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 29040 29041 # Extra M4 quote needed to protect [] in grep expression. 29042 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 29043 if test "x$FOUND_CORRECT_VERSION" = x; then 29044 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 29045 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 29046 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 29047 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 29048 BOOT_JDK_FOUND=no 29049 else 29050 # We're done! :-) 29051 BOOT_JDK_FOUND=yes 29052 29053 # Only process if variable expands to non-empty 29054 29055 if test "x$BOOT_JDK" != x; then 29056 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29057 29058 # Input might be given as Windows format, start by converting to 29059 # unix format. 29060 path="$BOOT_JDK" 29061 new_path=`$CYGPATH -u "$path"` 29062 29063 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 29064 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 29065 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 29066 # "foo.exe" is OK but "foo" is an error. 29067 # 29068 # This test is therefore slightly more accurate than "test -f" to check for file precense. 29069 # It is also a way to make sure we got the proper file name for the real test later on. 29070 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 29071 if test "x$test_shortpath" = x; then 29072 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29073 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29074 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 29075 fi 29076 29077 # Call helper function which possibly converts this using DOS-style short mode. 29078 # If so, the updated path is stored in $new_path. 29079 29080 input_path="$new_path" 29081 # Check if we need to convert this using DOS-style short mode. If the path 29082 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29083 # take no chances and rewrite it. 29084 # Note: m4 eats our [], so we need to use [ and ] instead. 29085 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 29086 if test "x$has_forbidden_chars" != x; then 29087 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29088 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 29089 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 29090 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 29091 # Going to short mode and back again did indeed matter. Since short mode is 29092 # case insensitive, let's make it lowercase to improve readability. 29093 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29094 # Now convert it back to Unix-style (cygpath) 29095 input_path=`$CYGPATH -u "$shortmode_path"` 29096 new_path="$input_path" 29097 fi 29098 fi 29099 29100 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 29101 if test "x$test_cygdrive_prefix" = x; then 29102 # As a simple fix, exclude /usr/bin since it's not a real path. 29103 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 29104 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 29105 # a path prefixed by /cygdrive for fixpath to work. 29106 new_path="$CYGWIN_ROOT_PATH$input_path" 29107 fi 29108 fi 29109 29110 29111 if test "x$path" != "x$new_path"; then 29112 BOOT_JDK="$new_path" 29113 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29114 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29115 fi 29116 29117 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29118 29119 path="$BOOT_JDK" 29120 has_colon=`$ECHO $path | $GREP ^.:` 29121 new_path="$path" 29122 if test "x$has_colon" = x; then 29123 # Not in mixed or Windows style, start by that. 29124 new_path=`cmd //c echo $path` 29125 fi 29126 29127 29128 input_path="$new_path" 29129 # Check if we need to convert this using DOS-style short mode. If the path 29130 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29131 # take no chances and rewrite it. 29132 # Note: m4 eats our [], so we need to use [ and ] instead. 29133 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 29134 if test "x$has_forbidden_chars" != x; then 29135 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29136 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29137 fi 29138 29139 29140 windows_path="$new_path" 29141 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29142 unix_path=`$CYGPATH -u "$windows_path"` 29143 new_path="$unix_path" 29144 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29145 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 29146 new_path="$unix_path" 29147 fi 29148 29149 if test "x$path" != "x$new_path"; then 29150 BOOT_JDK="$new_path" 29151 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29152 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29153 fi 29154 29155 # Save the first 10 bytes of this path to the storage, so fixpath can work. 29156 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 29157 29158 else 29159 # We're on a unix platform. Hooray! :) 29160 path="$BOOT_JDK" 29161 has_space=`$ECHO "$path" | $GREP " "` 29162 if test "x$has_space" != x; then 29163 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29164 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29165 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 29166 fi 29167 29168 # Use eval to expand a potential ~ 29169 eval path="$path" 29170 if test ! -f "$path" && test ! -d "$path"; then 29171 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 29172 fi 29173 29174 if test -d "$path"; then 29175 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 29176 else 29177 dir="`$DIRNAME "$path"`" 29178 base="`$BASENAME "$path"`" 29179 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 29180 fi 29181 fi 29182 fi 29183 29184 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 29185 $as_echo_n "checking for Boot JDK... " >&6; } 29186 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 29187 $as_echo "$BOOT_JDK" >&6; } 29188 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 29189 $as_echo_n "checking Boot JDK version... " >&6; } 29190 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 29191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 29192 $as_echo "$BOOT_JDK_VERSION" >&6; } 29193 fi # end check jdk version 29194 fi # end check javac 29195 fi # end check java 29196 fi # end check boot jdk found 29197 fi 29198 29199 29200 if test "x$BOOT_JDK_FOUND" = xno; then 29201 # Now execute the test 29202 29203 BOOT_JDK_PREFIX="/System/Library/Java/JavaVirtualMachines" 29204 BOOT_JDK_SUFFIX="/Contents/Home" 29205 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 29206 if test "x$ALL_JDKS_FOUND" != x; then 29207 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 29208 29209 if test "x$BOOT_JDK_FOUND" = xno; then 29210 # Now execute the test 29211 29212 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 29213 if test -d "$BOOT_JDK"; then 29214 BOOT_JDK_FOUND=maybe 29215 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 29216 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 29217 fi 29218 29219 29220 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 29221 if test "x$BOOT_JDK_FOUND" = xmaybe; then 29222 # Do we have a bin/java? 29223 if test ! -x "$BOOT_JDK/bin/java"; then 29224 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 29225 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 29226 BOOT_JDK_FOUND=no 29227 else 29228 # Do we have a bin/javac? 29229 if test ! -x "$BOOT_JDK/bin/javac"; then 29230 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 29231 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 29232 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 29233 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 29234 BOOT_JDK_FOUND=no 29235 else 29236 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 29237 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 29238 29239 # Extra M4 quote needed to protect [] in grep expression. 29240 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 29241 if test "x$FOUND_CORRECT_VERSION" = x; then 29242 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 29243 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 29244 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 29245 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 29246 BOOT_JDK_FOUND=no 29247 else 29248 # We're done! :-) 29249 BOOT_JDK_FOUND=yes 29250 29251 # Only process if variable expands to non-empty 29252 29253 if test "x$BOOT_JDK" != x; then 29254 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29255 29256 # Input might be given as Windows format, start by converting to 29257 # unix format. 29258 path="$BOOT_JDK" 29259 new_path=`$CYGPATH -u "$path"` 29260 29261 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 29262 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 29263 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 29264 # "foo.exe" is OK but "foo" is an error. 29265 # 29266 # This test is therefore slightly more accurate than "test -f" to check for file precense. 29267 # It is also a way to make sure we got the proper file name for the real test later on. 29268 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 29269 if test "x$test_shortpath" = x; then 29270 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29271 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29272 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 29273 fi 29274 29275 # Call helper function which possibly converts this using DOS-style short mode. 29276 # If so, the updated path is stored in $new_path. 29277 29278 input_path="$new_path" 29279 # Check if we need to convert this using DOS-style short mode. If the path 29280 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29281 # take no chances and rewrite it. 29282 # Note: m4 eats our [], so we need to use [ and ] instead. 29283 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 29284 if test "x$has_forbidden_chars" != x; then 29285 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29286 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 29287 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 29288 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 29289 # Going to short mode and back again did indeed matter. Since short mode is 29290 # case insensitive, let's make it lowercase to improve readability. 29291 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29292 # Now convert it back to Unix-style (cygpath) 29293 input_path=`$CYGPATH -u "$shortmode_path"` 29294 new_path="$input_path" 29295 fi 29296 fi 29297 29298 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 29299 if test "x$test_cygdrive_prefix" = x; then 29300 # As a simple fix, exclude /usr/bin since it's not a real path. 29301 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 29302 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 29303 # a path prefixed by /cygdrive for fixpath to work. 29304 new_path="$CYGWIN_ROOT_PATH$input_path" 29305 fi 29306 fi 29307 29308 29309 if test "x$path" != "x$new_path"; then 29310 BOOT_JDK="$new_path" 29311 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29312 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29313 fi 29314 29315 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29316 29317 path="$BOOT_JDK" 29318 has_colon=`$ECHO $path | $GREP ^.:` 29319 new_path="$path" 29320 if test "x$has_colon" = x; then 29321 # Not in mixed or Windows style, start by that. 29322 new_path=`cmd //c echo $path` 29323 fi 29324 29325 29326 input_path="$new_path" 29327 # Check if we need to convert this using DOS-style short mode. If the path 29328 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29329 # take no chances and rewrite it. 29330 # Note: m4 eats our [], so we need to use [ and ] instead. 29331 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 29332 if test "x$has_forbidden_chars" != x; then 29333 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29334 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29335 fi 29336 29337 29338 windows_path="$new_path" 29339 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29340 unix_path=`$CYGPATH -u "$windows_path"` 29341 new_path="$unix_path" 29342 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29343 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 29344 new_path="$unix_path" 29345 fi 29346 29347 if test "x$path" != "x$new_path"; then 29348 BOOT_JDK="$new_path" 29349 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29350 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29351 fi 29352 29353 # Save the first 10 bytes of this path to the storage, so fixpath can work. 29354 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 29355 29356 else 29357 # We're on a unix platform. Hooray! :) 29358 path="$BOOT_JDK" 29359 has_space=`$ECHO "$path" | $GREP " "` 29360 if test "x$has_space" != x; then 29361 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29362 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29363 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 29364 fi 29365 29366 # Use eval to expand a potential ~ 29367 eval path="$path" 29368 if test ! -f "$path" && test ! -d "$path"; then 29369 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 29370 fi 29371 29372 if test -d "$path"; then 29373 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 29374 else 29375 dir="`$DIRNAME "$path"`" 29376 base="`$BASENAME "$path"`" 29377 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 29378 fi 29379 fi 29380 fi 29381 29382 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 29383 $as_echo_n "checking for Boot JDK... " >&6; } 29384 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 29385 $as_echo "$BOOT_JDK" >&6; } 29386 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 29387 $as_echo_n "checking Boot JDK version... " >&6; } 29388 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 29389 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 29390 $as_echo "$BOOT_JDK_VERSION" >&6; } 29391 fi # end check jdk version 29392 fi # end check javac 29393 fi # end check java 29394 fi # end check boot jdk found 29395 fi 29396 29397 done 29398 fi 29399 29400 29401 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 29402 if test "x$BOOT_JDK_FOUND" = xmaybe; then 29403 # Do we have a bin/java? 29404 if test ! -x "$BOOT_JDK/bin/java"; then 29405 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 29406 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 29407 BOOT_JDK_FOUND=no 29408 else 29409 # Do we have a bin/javac? 29410 if test ! -x "$BOOT_JDK/bin/javac"; then 29411 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 29412 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 29413 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 29414 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 29415 BOOT_JDK_FOUND=no 29416 else 29417 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 29418 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 29419 29420 # Extra M4 quote needed to protect [] in grep expression. 29421 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 29422 if test "x$FOUND_CORRECT_VERSION" = x; then 29423 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 29424 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 29425 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 29426 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 29427 BOOT_JDK_FOUND=no 29428 else 29429 # We're done! :-) 29430 BOOT_JDK_FOUND=yes 29431 29432 # Only process if variable expands to non-empty 29433 29434 if test "x$BOOT_JDK" != x; then 29435 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29436 29437 # Input might be given as Windows format, start by converting to 29438 # unix format. 29439 path="$BOOT_JDK" 29440 new_path=`$CYGPATH -u "$path"` 29441 29442 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 29443 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 29444 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 29445 # "foo.exe" is OK but "foo" is an error. 29446 # 29447 # This test is therefore slightly more accurate than "test -f" to check for file precense. 29448 # It is also a way to make sure we got the proper file name for the real test later on. 29449 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 29450 if test "x$test_shortpath" = x; then 29451 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29452 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29453 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 29454 fi 29455 29456 # Call helper function which possibly converts this using DOS-style short mode. 29457 # If so, the updated path is stored in $new_path. 29458 29459 input_path="$new_path" 29460 # Check if we need to convert this using DOS-style short mode. If the path 29461 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29462 # take no chances and rewrite it. 29463 # Note: m4 eats our [], so we need to use [ and ] instead. 29464 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 29465 if test "x$has_forbidden_chars" != x; then 29466 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29467 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 29468 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 29469 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 29470 # Going to short mode and back again did indeed matter. Since short mode is 29471 # case insensitive, let's make it lowercase to improve readability. 29472 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29473 # Now convert it back to Unix-style (cygpath) 29474 input_path=`$CYGPATH -u "$shortmode_path"` 29475 new_path="$input_path" 29476 fi 29477 fi 29478 29479 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 29480 if test "x$test_cygdrive_prefix" = x; then 29481 # As a simple fix, exclude /usr/bin since it's not a real path. 29482 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 29483 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 29484 # a path prefixed by /cygdrive for fixpath to work. 29485 new_path="$CYGWIN_ROOT_PATH$input_path" 29486 fi 29487 fi 29488 29489 29490 if test "x$path" != "x$new_path"; then 29491 BOOT_JDK="$new_path" 29492 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29493 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29494 fi 29495 29496 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29497 29498 path="$BOOT_JDK" 29499 has_colon=`$ECHO $path | $GREP ^.:` 29500 new_path="$path" 29501 if test "x$has_colon" = x; then 29502 # Not in mixed or Windows style, start by that. 29503 new_path=`cmd //c echo $path` 29504 fi 29505 29506 29507 input_path="$new_path" 29508 # Check if we need to convert this using DOS-style short mode. If the path 29509 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29510 # take no chances and rewrite it. 29511 # Note: m4 eats our [], so we need to use [ and ] instead. 29512 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 29513 if test "x$has_forbidden_chars" != x; then 29514 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29515 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29516 fi 29517 29518 29519 windows_path="$new_path" 29520 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29521 unix_path=`$CYGPATH -u "$windows_path"` 29522 new_path="$unix_path" 29523 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29524 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 29525 new_path="$unix_path" 29526 fi 29527 29528 if test "x$path" != "x$new_path"; then 29529 BOOT_JDK="$new_path" 29530 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29531 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29532 fi 29533 29534 # Save the first 10 bytes of this path to the storage, so fixpath can work. 29535 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 29536 29537 else 29538 # We're on a unix platform. Hooray! :) 29539 path="$BOOT_JDK" 29540 has_space=`$ECHO "$path" | $GREP " "` 29541 if test "x$has_space" != x; then 29542 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29543 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29544 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 29545 fi 29546 29547 # Use eval to expand a potential ~ 29548 eval path="$path" 29549 if test ! -f "$path" && test ! -d "$path"; then 29550 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 29551 fi 29552 29553 if test -d "$path"; then 29554 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 29555 else 29556 dir="`$DIRNAME "$path"`" 29557 base="`$BASENAME "$path"`" 29558 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 29559 fi 29560 fi 29561 fi 29562 29563 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 29564 $as_echo_n "checking for Boot JDK... " >&6; } 29565 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 29566 $as_echo "$BOOT_JDK" >&6; } 29567 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 29568 $as_echo_n "checking Boot JDK version... " >&6; } 29569 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 29570 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 29571 $as_echo "$BOOT_JDK_VERSION" >&6; } 29572 fi # end check jdk version 29573 fi # end check javac 29574 fi # end check java 29575 fi # end check boot jdk found 29576 fi 29577 29578 elif test "x$OPENJDK_TARGET_OS" = xlinux; then 29579 29580 if test "x$BOOT_JDK_FOUND" = xno; then 29581 # Now execute the test 29582 29583 BOOT_JDK_PREFIX="/usr/lib/jvm" 29584 BOOT_JDK_SUFFIX="" 29585 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 29586 if test "x$ALL_JDKS_FOUND" != x; then 29587 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 29588 29589 if test "x$BOOT_JDK_FOUND" = xno; then 29590 # Now execute the test 29591 29592 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 29593 if test -d "$BOOT_JDK"; then 29594 BOOT_JDK_FOUND=maybe 29595 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 29596 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 29597 fi 29598 29599 29600 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 29601 if test "x$BOOT_JDK_FOUND" = xmaybe; then 29602 # Do we have a bin/java? 29603 if test ! -x "$BOOT_JDK/bin/java"; then 29604 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 29605 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 29606 BOOT_JDK_FOUND=no 29607 else 29608 # Do we have a bin/javac? 29609 if test ! -x "$BOOT_JDK/bin/javac"; then 29610 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 29611 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 29612 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 29613 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 29614 BOOT_JDK_FOUND=no 29615 else 29616 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 29617 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 29618 29619 # Extra M4 quote needed to protect [] in grep expression. 29620 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 29621 if test "x$FOUND_CORRECT_VERSION" = x; then 29622 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 29623 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 29624 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 29625 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 29626 BOOT_JDK_FOUND=no 29627 else 29628 # We're done! :-) 29629 BOOT_JDK_FOUND=yes 29630 29631 # Only process if variable expands to non-empty 29632 29633 if test "x$BOOT_JDK" != x; then 29634 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29635 29636 # Input might be given as Windows format, start by converting to 29637 # unix format. 29638 path="$BOOT_JDK" 29639 new_path=`$CYGPATH -u "$path"` 29640 29641 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 29642 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 29643 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 29644 # "foo.exe" is OK but "foo" is an error. 29645 # 29646 # This test is therefore slightly more accurate than "test -f" to check for file precense. 29647 # It is also a way to make sure we got the proper file name for the real test later on. 29648 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 29649 if test "x$test_shortpath" = x; then 29650 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29651 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29652 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 29653 fi 29654 29655 # Call helper function which possibly converts this using DOS-style short mode. 29656 # If so, the updated path is stored in $new_path. 29657 29658 input_path="$new_path" 29659 # Check if we need to convert this using DOS-style short mode. If the path 29660 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29661 # take no chances and rewrite it. 29662 # Note: m4 eats our [], so we need to use [ and ] instead. 29663 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 29664 if test "x$has_forbidden_chars" != x; then 29665 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29666 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 29667 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 29668 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 29669 # Going to short mode and back again did indeed matter. Since short mode is 29670 # case insensitive, let's make it lowercase to improve readability. 29671 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29672 # Now convert it back to Unix-style (cygpath) 29673 input_path=`$CYGPATH -u "$shortmode_path"` 29674 new_path="$input_path" 29675 fi 29676 fi 29677 29678 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 29679 if test "x$test_cygdrive_prefix" = x; then 29680 # As a simple fix, exclude /usr/bin since it's not a real path. 29681 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 29682 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 29683 # a path prefixed by /cygdrive for fixpath to work. 29684 new_path="$CYGWIN_ROOT_PATH$input_path" 29685 fi 29686 fi 29687 29688 29689 if test "x$path" != "x$new_path"; then 29690 BOOT_JDK="$new_path" 29691 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29692 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29693 fi 29694 29695 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29696 29697 path="$BOOT_JDK" 29698 has_colon=`$ECHO $path | $GREP ^.:` 29699 new_path="$path" 29700 if test "x$has_colon" = x; then 29701 # Not in mixed or Windows style, start by that. 29702 new_path=`cmd //c echo $path` 29703 fi 29704 29705 29706 input_path="$new_path" 29707 # Check if we need to convert this using DOS-style short mode. If the path 29708 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29709 # take no chances and rewrite it. 29710 # Note: m4 eats our [], so we need to use [ and ] instead. 29711 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 29712 if test "x$has_forbidden_chars" != x; then 29713 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29714 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29715 fi 29716 29717 29718 windows_path="$new_path" 29719 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29720 unix_path=`$CYGPATH -u "$windows_path"` 29721 new_path="$unix_path" 29722 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29723 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 29724 new_path="$unix_path" 29725 fi 29726 29727 if test "x$path" != "x$new_path"; then 29728 BOOT_JDK="$new_path" 29729 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29730 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29731 fi 29732 29733 # Save the first 10 bytes of this path to the storage, so fixpath can work. 29734 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 29735 29736 else 29737 # We're on a unix platform. Hooray! :) 29738 path="$BOOT_JDK" 29739 has_space=`$ECHO "$path" | $GREP " "` 29740 if test "x$has_space" != x; then 29741 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29742 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29743 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 29744 fi 29745 29746 # Use eval to expand a potential ~ 29747 eval path="$path" 29748 if test ! -f "$path" && test ! -d "$path"; then 29749 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 29750 fi 29751 29752 if test -d "$path"; then 29753 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 29754 else 29755 dir="`$DIRNAME "$path"`" 29756 base="`$BASENAME "$path"`" 29757 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 29758 fi 29759 fi 29760 fi 29761 29762 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 29763 $as_echo_n "checking for Boot JDK... " >&6; } 29764 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 29765 $as_echo "$BOOT_JDK" >&6; } 29766 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 29767 $as_echo_n "checking Boot JDK version... " >&6; } 29768 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 29769 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 29770 $as_echo "$BOOT_JDK_VERSION" >&6; } 29771 fi # end check jdk version 29772 fi # end check javac 29773 fi # end check java 29774 fi # end check boot jdk found 29775 fi 29776 29777 done 29778 fi 29779 29780 29781 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 29782 if test "x$BOOT_JDK_FOUND" = xmaybe; then 29783 # Do we have a bin/java? 29784 if test ! -x "$BOOT_JDK/bin/java"; then 29785 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 29786 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 29787 BOOT_JDK_FOUND=no 29788 else 29789 # Do we have a bin/javac? 29790 if test ! -x "$BOOT_JDK/bin/javac"; then 29791 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 29792 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 29793 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 29794 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 29795 BOOT_JDK_FOUND=no 29796 else 29797 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 29798 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 29799 29800 # Extra M4 quote needed to protect [] in grep expression. 29801 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 29802 if test "x$FOUND_CORRECT_VERSION" = x; then 29803 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 29804 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 29805 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 29806 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 29807 BOOT_JDK_FOUND=no 29808 else 29809 # We're done! :-) 29810 BOOT_JDK_FOUND=yes 29811 29812 # Only process if variable expands to non-empty 29813 29814 if test "x$BOOT_JDK" != x; then 29815 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29816 29817 # Input might be given as Windows format, start by converting to 29818 # unix format. 29819 path="$BOOT_JDK" 29820 new_path=`$CYGPATH -u "$path"` 29821 29822 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 29823 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 29824 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 29825 # "foo.exe" is OK but "foo" is an error. 29826 # 29827 # This test is therefore slightly more accurate than "test -f" to check for file precense. 29828 # It is also a way to make sure we got the proper file name for the real test later on. 29829 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 29830 if test "x$test_shortpath" = x; then 29831 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29832 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29833 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 29834 fi 29835 29836 # Call helper function which possibly converts this using DOS-style short mode. 29837 # If so, the updated path is stored in $new_path. 29838 29839 input_path="$new_path" 29840 # Check if we need to convert this using DOS-style short mode. If the path 29841 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29842 # take no chances and rewrite it. 29843 # Note: m4 eats our [], so we need to use [ and ] instead. 29844 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 29845 if test "x$has_forbidden_chars" != x; then 29846 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29847 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 29848 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 29849 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 29850 # Going to short mode and back again did indeed matter. Since short mode is 29851 # case insensitive, let's make it lowercase to improve readability. 29852 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29853 # Now convert it back to Unix-style (cygpath) 29854 input_path=`$CYGPATH -u "$shortmode_path"` 29855 new_path="$input_path" 29856 fi 29857 fi 29858 29859 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 29860 if test "x$test_cygdrive_prefix" = x; then 29861 # As a simple fix, exclude /usr/bin since it's not a real path. 29862 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 29863 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 29864 # a path prefixed by /cygdrive for fixpath to work. 29865 new_path="$CYGWIN_ROOT_PATH$input_path" 29866 fi 29867 fi 29868 29869 29870 if test "x$path" != "x$new_path"; then 29871 BOOT_JDK="$new_path" 29872 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29873 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29874 fi 29875 29876 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29877 29878 path="$BOOT_JDK" 29879 has_colon=`$ECHO $path | $GREP ^.:` 29880 new_path="$path" 29881 if test "x$has_colon" = x; then 29882 # Not in mixed or Windows style, start by that. 29883 new_path=`cmd //c echo $path` 29884 fi 29885 29886 29887 input_path="$new_path" 29888 # Check if we need to convert this using DOS-style short mode. If the path 29889 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29890 # take no chances and rewrite it. 29891 # Note: m4 eats our [], so we need to use [ and ] instead. 29892 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 29893 if test "x$has_forbidden_chars" != x; then 29894 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29895 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29896 fi 29897 29898 29899 windows_path="$new_path" 29900 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29901 unix_path=`$CYGPATH -u "$windows_path"` 29902 new_path="$unix_path" 29903 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29904 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 29905 new_path="$unix_path" 29906 fi 29907 29908 if test "x$path" != "x$new_path"; then 29909 BOOT_JDK="$new_path" 29910 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29911 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29912 fi 29913 29914 # Save the first 10 bytes of this path to the storage, so fixpath can work. 29915 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 29916 29917 else 29918 # We're on a unix platform. Hooray! :) 29919 path="$BOOT_JDK" 29920 has_space=`$ECHO "$path" | $GREP " "` 29921 if test "x$has_space" != x; then 29922 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29923 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29924 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 29925 fi 29926 29927 # Use eval to expand a potential ~ 29928 eval path="$path" 29929 if test ! -f "$path" && test ! -d "$path"; then 29930 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 29931 fi 29932 29933 if test -d "$path"; then 29934 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 29935 else 29936 dir="`$DIRNAME "$path"`" 29937 base="`$BASENAME "$path"`" 29938 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 29939 fi 29940 fi 29941 fi 29942 29943 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 29944 $as_echo_n "checking for Boot JDK... " >&6; } 29945 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 29946 $as_echo "$BOOT_JDK" >&6; } 29947 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 29948 $as_echo_n "checking Boot JDK version... " >&6; } 29949 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 29950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 29951 $as_echo "$BOOT_JDK_VERSION" >&6; } 29952 fi # end check jdk version 29953 fi # end check javac 29954 fi # end check java 29955 fi # end check boot jdk found 29956 fi 29957 29958 fi 29959 29960 29961 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 29962 if test "x$BOOT_JDK_FOUND" = xmaybe; then 29963 # Do we have a bin/java? 29964 if test ! -x "$BOOT_JDK/bin/java"; then 29965 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 29966 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 29967 BOOT_JDK_FOUND=no 29968 else 29969 # Do we have a bin/javac? 29970 if test ! -x "$BOOT_JDK/bin/javac"; then 29971 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 29972 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 29973 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 29974 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 29975 BOOT_JDK_FOUND=no 29976 else 29977 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 29978 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 29979 29980 # Extra M4 quote needed to protect [] in grep expression. 29981 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 29982 if test "x$FOUND_CORRECT_VERSION" = x; then 29983 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 29984 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 29985 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 29986 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 29987 BOOT_JDK_FOUND=no 29988 else 29989 # We're done! :-) 29990 BOOT_JDK_FOUND=yes 29991 29992 # Only process if variable expands to non-empty 29993 29994 if test "x$BOOT_JDK" != x; then 29995 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29996 29997 # Input might be given as Windows format, start by converting to 29998 # unix format. 29999 path="$BOOT_JDK" 30000 new_path=`$CYGPATH -u "$path"` 30001 30002 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 30003 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 30004 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 30005 # "foo.exe" is OK but "foo" is an error. 30006 # 30007 # This test is therefore slightly more accurate than "test -f" to check for file precense. 30008 # It is also a way to make sure we got the proper file name for the real test later on. 30009 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 30010 if test "x$test_shortpath" = x; then 30011 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 30012 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 30013 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 30014 fi 30015 30016 # Call helper function which possibly converts this using DOS-style short mode. 30017 # If so, the updated path is stored in $new_path. 30018 30019 input_path="$new_path" 30020 # Check if we need to convert this using DOS-style short mode. If the path 30021 # contains just simple characters, use it. Otherwise (spaces, weird characters), 30022 # take no chances and rewrite it. 30023 # Note: m4 eats our [], so we need to use [ and ] instead. 30024 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 30025 if test "x$has_forbidden_chars" != x; then 30026 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 30027 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 30028 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 30029 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 30030 # Going to short mode and back again did indeed matter. Since short mode is 30031 # case insensitive, let's make it lowercase to improve readability. 30032 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 30033 # Now convert it back to Unix-style (cygpath) 30034 input_path=`$CYGPATH -u "$shortmode_path"` 30035 new_path="$input_path" 30036 fi 30037 fi 30038 30039 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 30040 if test "x$test_cygdrive_prefix" = x; then 30041 # As a simple fix, exclude /usr/bin since it's not a real path. 30042 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 30043 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 30044 # a path prefixed by /cygdrive for fixpath to work. 30045 new_path="$CYGWIN_ROOT_PATH$input_path" 30046 fi 30047 fi 30048 30049 30050 if test "x$path" != "x$new_path"; then 30051 BOOT_JDK="$new_path" 30052 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 30053 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 30054 fi 30055 30056 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30057 30058 path="$BOOT_JDK" 30059 has_colon=`$ECHO $path | $GREP ^.:` 30060 new_path="$path" 30061 if test "x$has_colon" = x; then 30062 # Not in mixed or Windows style, start by that. 30063 new_path=`cmd //c echo $path` 30064 fi 30065 30066 30067 input_path="$new_path" 30068 # Check if we need to convert this using DOS-style short mode. If the path 30069 # contains just simple characters, use it. Otherwise (spaces, weird characters), 30070 # take no chances and rewrite it. 30071 # Note: m4 eats our [], so we need to use [ and ] instead. 30072 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 30073 if test "x$has_forbidden_chars" != x; then 30074 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 30075 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 30076 fi 30077 30078 30079 windows_path="$new_path" 30080 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30081 unix_path=`$CYGPATH -u "$windows_path"` 30082 new_path="$unix_path" 30083 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30084 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 30085 new_path="$unix_path" 30086 fi 30087 30088 if test "x$path" != "x$new_path"; then 30089 BOOT_JDK="$new_path" 30090 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 30091 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 30092 fi 30093 30094 # Save the first 10 bytes of this path to the storage, so fixpath can work. 30095 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 30096 30097 else 30098 # We're on a unix platform. Hooray! :) 30099 path="$BOOT_JDK" 30100 has_space=`$ECHO "$path" | $GREP " "` 30101 if test "x$has_space" != x; then 30102 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 30103 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 30104 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 30105 fi 30106 30107 # Use eval to expand a potential ~ 30108 eval path="$path" 30109 if test ! -f "$path" && test ! -d "$path"; then 30110 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 30111 fi 30112 30113 if test -d "$path"; then 30114 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 30115 else 30116 dir="`$DIRNAME "$path"`" 30117 base="`$BASENAME "$path"`" 30118 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 30119 fi 30120 fi 30121 fi 30122 30123 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 30124 $as_echo_n "checking for Boot JDK... " >&6; } 30125 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 30126 $as_echo "$BOOT_JDK" >&6; } 30127 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 30128 $as_echo_n "checking Boot JDK version... " >&6; } 30129 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 30130 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 30131 $as_echo "$BOOT_JDK_VERSION" >&6; } 30132 fi # end check jdk version 30133 fi # end check javac 30134 fi # end check java 30135 fi # end check boot jdk found 30136 fi 30137 30138 30139 # If we haven't found anything yet, we've truly lost. Give up. 30140 if test "x$BOOT_JDK_FOUND" = xno; then 30141 30142 # Print a helpful message on how to acquire the necessary build dependency. 30143 # openjdk is the help tag: freetype, cups, alsa etc 30144 MISSING_DEPENDENCY=openjdk 30145 30146 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30147 cygwin_help $MISSING_DEPENDENCY 30148 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30149 msys_help $MISSING_DEPENDENCY 30150 else 30151 PKGHANDLER_COMMAND= 30152 30153 case $PKGHANDLER in 30154 apt-get) 30155 apt_help $MISSING_DEPENDENCY ;; 30156 yum) 30157 yum_help $MISSING_DEPENDENCY ;; 30158 brew) 30159 brew_help $MISSING_DEPENDENCY ;; 30160 port) 30161 port_help $MISSING_DEPENDENCY ;; 30162 pkgutil) 30163 pkgutil_help $MISSING_DEPENDENCY ;; 30164 pkgadd) 30165 pkgadd_help $MISSING_DEPENDENCY ;; 30166 esac 30167 30168 if test "x$PKGHANDLER_COMMAND" != x; then 30169 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 30170 fi 30171 fi 30172 30173 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find a valid Boot JDK. $HELP_MSG" >&5 30174 $as_echo "$as_me: Could not find a valid Boot JDK. $HELP_MSG" >&6;} 30175 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be fixed by explicitly setting --with-boot-jdk" >&5 30176 $as_echo "$as_me: This might be fixed by explicitly setting --with-boot-jdk" >&6;} 30177 as_fn_error $? "Cannot continue" "$LINENO" 5 30178 fi 30179 30180 30181 30182 # Setup tools from the Boot JDK. 30183 30184 # Use user overridden value if available, otherwise locate tool in the Boot JDK. 30185 30186 # Publish this variable in the help. 30187 30188 30189 if [ -z "${JAVA+x}" ]; then 30190 # The variable is not set by user, try to locate tool using the code snippet 30191 30192 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for java in Boot JDK" >&5 30193 $as_echo_n "checking for java in Boot JDK... " >&6; } 30194 JAVA=$BOOT_JDK/bin/java 30195 if test ! -x $JAVA; then 30196 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30197 $as_echo "not found" >&6; } 30198 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 30199 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 30200 as_fn_error $? "Could not find java in the Boot JDK" "$LINENO" 5 30201 fi 30202 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30203 $as_echo "ok" >&6; } 30204 30205 30206 else 30207 # The variable is set, but is it from the command line or the environment? 30208 30209 # Try to remove the string !JAVA! from our list. 30210 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAVA!/} 30211 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 30212 # If it failed, the variable was not from the command line. Ignore it, 30213 # but warn the user (except for BASH, which is always set by the calling BASH). 30214 if test "xJAVA" != xBASH; then 30215 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAVA from the environment. Use command line variables instead." >&5 30216 $as_echo "$as_me: WARNING: Ignoring value of JAVA from the environment. Use command line variables instead." >&2;} 30217 fi 30218 # Try to locate tool using the code snippet 30219 30220 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for java in Boot JDK" >&5 30221 $as_echo_n "checking for java in Boot JDK... " >&6; } 30222 JAVA=$BOOT_JDK/bin/java 30223 if test ! -x $JAVA; then 30224 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30225 $as_echo "not found" >&6; } 30226 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 30227 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 30228 as_fn_error $? "Could not find java in the Boot JDK" "$LINENO" 5 30229 fi 30230 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30231 $as_echo "ok" >&6; } 30232 30233 30234 else 30235 # If it succeeded, then it was overridden by the user. We will use it 30236 # for the tool. 30237 30238 # First remove it from the list of overridden variables, so we can test 30239 # for unknown variables in the end. 30240 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 30241 30242 # Check if we try to supply an empty value 30243 if test "x$JAVA" = x; then 30244 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JAVA= (no value)" >&5 30245 $as_echo "$as_me: Setting user supplied tool JAVA= (no value)" >&6;} 30246 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVA" >&5 30247 $as_echo_n "checking for JAVA... " >&6; } 30248 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 30249 $as_echo "disabled" >&6; } 30250 else 30251 # Check if the provided tool contains a complete path. 30252 tool_specified="$JAVA" 30253 tool_basename="${tool_specified##*/}" 30254 if test "x$tool_basename" = "x$tool_specified"; then 30255 # A command without a complete path is provided, search $PATH. 30256 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAVA=$tool_basename" >&5 30257 $as_echo "$as_me: Will search for user supplied tool JAVA=$tool_basename" >&6;} 30258 # Extract the first word of "$tool_basename", so it can be a program name with args. 30259 set dummy $tool_basename; ac_word=$2 30260 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 30261 $as_echo_n "checking for $ac_word... " >&6; } 30262 if ${ac_cv_path_JAVA+:} false; then : 30263 $as_echo_n "(cached) " >&6 30264 else 30265 case $JAVA in 30266 [\\/]* | ?:[\\/]*) 30267 ac_cv_path_JAVA="$JAVA" # Let the user override the test with a path. 30268 ;; 30269 *) 30270 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 30271 for as_dir in $PATH 30272 do 30273 IFS=$as_save_IFS 30274 test -z "$as_dir" && as_dir=. 30275 for ac_exec_ext in '' $ac_executable_extensions; do 30276 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 30277 ac_cv_path_JAVA="$as_dir/$ac_word$ac_exec_ext" 30278 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 30279 break 2 30280 fi 30281 done 30282 done 30283 IFS=$as_save_IFS 30284 30285 ;; 30286 esac 30287 fi 30288 JAVA=$ac_cv_path_JAVA 30289 if test -n "$JAVA"; then 30290 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVA" >&5 30291 $as_echo "$JAVA" >&6; } 30292 else 30293 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 30294 $as_echo "no" >&6; } 30295 fi 30296 30297 30298 if test "x$JAVA" = x; then 30299 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 30300 fi 30301 else 30302 # Otherwise we believe it is a complete path. Use it as it is. 30303 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAVA=$tool_specified" >&5 30304 $as_echo "$as_me: Will use user supplied tool JAVA=$tool_specified" >&6;} 30305 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVA" >&5 30306 $as_echo_n "checking for JAVA... " >&6; } 30307 if test ! -x "$tool_specified"; then 30308 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30309 $as_echo "not found" >&6; } 30310 as_fn_error $? "User supplied tool JAVA=$tool_specified does not exist or is not executable" "$LINENO" 5 30311 fi 30312 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 30313 $as_echo "$tool_specified" >&6; } 30314 fi 30315 fi 30316 fi 30317 30318 fi 30319 30320 30321 30322 # Use user overridden value if available, otherwise locate tool in the Boot JDK. 30323 30324 # Publish this variable in the help. 30325 30326 30327 if [ -z "${JAVAC+x}" ]; then 30328 # The variable is not set by user, try to locate tool using the code snippet 30329 30330 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javac in Boot JDK" >&5 30331 $as_echo_n "checking for javac in Boot JDK... " >&6; } 30332 JAVAC=$BOOT_JDK/bin/javac 30333 if test ! -x $JAVAC; then 30334 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30335 $as_echo "not found" >&6; } 30336 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 30337 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 30338 as_fn_error $? "Could not find javac in the Boot JDK" "$LINENO" 5 30339 fi 30340 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30341 $as_echo "ok" >&6; } 30342 30343 30344 else 30345 # The variable is set, but is it from the command line or the environment? 30346 30347 # Try to remove the string !JAVAC! from our list. 30348 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAVAC!/} 30349 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 30350 # If it failed, the variable was not from the command line. Ignore it, 30351 # but warn the user (except for BASH, which is always set by the calling BASH). 30352 if test "xJAVAC" != xBASH; then 30353 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAVAC from the environment. Use command line variables instead." >&5 30354 $as_echo "$as_me: WARNING: Ignoring value of JAVAC from the environment. Use command line variables instead." >&2;} 30355 fi 30356 # Try to locate tool using the code snippet 30357 30358 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javac in Boot JDK" >&5 30359 $as_echo_n "checking for javac in Boot JDK... " >&6; } 30360 JAVAC=$BOOT_JDK/bin/javac 30361 if test ! -x $JAVAC; then 30362 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30363 $as_echo "not found" >&6; } 30364 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 30365 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 30366 as_fn_error $? "Could not find javac in the Boot JDK" "$LINENO" 5 30367 fi 30368 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30369 $as_echo "ok" >&6; } 30370 30371 30372 else 30373 # If it succeeded, then it was overridden by the user. We will use it 30374 # for the tool. 30375 30376 # First remove it from the list of overridden variables, so we can test 30377 # for unknown variables in the end. 30378 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 30379 30380 # Check if we try to supply an empty value 30381 if test "x$JAVAC" = x; then 30382 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JAVAC= (no value)" >&5 30383 $as_echo "$as_me: Setting user supplied tool JAVAC= (no value)" >&6;} 30384 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAC" >&5 30385 $as_echo_n "checking for JAVAC... " >&6; } 30386 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 30387 $as_echo "disabled" >&6; } 30388 else 30389 # Check if the provided tool contains a complete path. 30390 tool_specified="$JAVAC" 30391 tool_basename="${tool_specified##*/}" 30392 if test "x$tool_basename" = "x$tool_specified"; then 30393 # A command without a complete path is provided, search $PATH. 30394 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAVAC=$tool_basename" >&5 30395 $as_echo "$as_me: Will search for user supplied tool JAVAC=$tool_basename" >&6;} 30396 # Extract the first word of "$tool_basename", so it can be a program name with args. 30397 set dummy $tool_basename; ac_word=$2 30398 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 30399 $as_echo_n "checking for $ac_word... " >&6; } 30400 if ${ac_cv_path_JAVAC+:} false; then : 30401 $as_echo_n "(cached) " >&6 30402 else 30403 case $JAVAC in 30404 [\\/]* | ?:[\\/]*) 30405 ac_cv_path_JAVAC="$JAVAC" # Let the user override the test with a path. 30406 ;; 30407 *) 30408 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 30409 for as_dir in $PATH 30410 do 30411 IFS=$as_save_IFS 30412 test -z "$as_dir" && as_dir=. 30413 for ac_exec_ext in '' $ac_executable_extensions; do 30414 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 30415 ac_cv_path_JAVAC="$as_dir/$ac_word$ac_exec_ext" 30416 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 30417 break 2 30418 fi 30419 done 30420 done 30421 IFS=$as_save_IFS 30422 30423 ;; 30424 esac 30425 fi 30426 JAVAC=$ac_cv_path_JAVAC 30427 if test -n "$JAVAC"; then 30428 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVAC" >&5 30429 $as_echo "$JAVAC" >&6; } 30430 else 30431 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 30432 $as_echo "no" >&6; } 30433 fi 30434 30435 30436 if test "x$JAVAC" = x; then 30437 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 30438 fi 30439 else 30440 # Otherwise we believe it is a complete path. Use it as it is. 30441 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAVAC=$tool_specified" >&5 30442 $as_echo "$as_me: Will use user supplied tool JAVAC=$tool_specified" >&6;} 30443 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAC" >&5 30444 $as_echo_n "checking for JAVAC... " >&6; } 30445 if test ! -x "$tool_specified"; then 30446 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30447 $as_echo "not found" >&6; } 30448 as_fn_error $? "User supplied tool JAVAC=$tool_specified does not exist or is not executable" "$LINENO" 5 30449 fi 30450 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 30451 $as_echo "$tool_specified" >&6; } 30452 fi 30453 fi 30454 fi 30455 30456 fi 30457 30458 30459 30460 # Use user overridden value if available, otherwise locate tool in the Boot JDK. 30461 30462 # Publish this variable in the help. 30463 30464 30465 if [ -z "${JAVAH+x}" ]; then 30466 # The variable is not set by user, try to locate tool using the code snippet 30467 30468 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javah in Boot JDK" >&5 30469 $as_echo_n "checking for javah in Boot JDK... " >&6; } 30470 JAVAH=$BOOT_JDK/bin/javah 30471 if test ! -x $JAVAH; then 30472 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30473 $as_echo "not found" >&6; } 30474 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 30475 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 30476 as_fn_error $? "Could not find javah in the Boot JDK" "$LINENO" 5 30477 fi 30478 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30479 $as_echo "ok" >&6; } 30480 30481 30482 else 30483 # The variable is set, but is it from the command line or the environment? 30484 30485 # Try to remove the string !JAVAH! from our list. 30486 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAVAH!/} 30487 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 30488 # If it failed, the variable was not from the command line. Ignore it, 30489 # but warn the user (except for BASH, which is always set by the calling BASH). 30490 if test "xJAVAH" != xBASH; then 30491 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAVAH from the environment. Use command line variables instead." >&5 30492 $as_echo "$as_me: WARNING: Ignoring value of JAVAH from the environment. Use command line variables instead." >&2;} 30493 fi 30494 # Try to locate tool using the code snippet 30495 30496 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javah in Boot JDK" >&5 30497 $as_echo_n "checking for javah in Boot JDK... " >&6; } 30498 JAVAH=$BOOT_JDK/bin/javah 30499 if test ! -x $JAVAH; then 30500 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30501 $as_echo "not found" >&6; } 30502 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 30503 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 30504 as_fn_error $? "Could not find javah in the Boot JDK" "$LINENO" 5 30505 fi 30506 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30507 $as_echo "ok" >&6; } 30508 30509 30510 else 30511 # If it succeeded, then it was overridden by the user. We will use it 30512 # for the tool. 30513 30514 # First remove it from the list of overridden variables, so we can test 30515 # for unknown variables in the end. 30516 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 30517 30518 # Check if we try to supply an empty value 30519 if test "x$JAVAH" = x; then 30520 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JAVAH= (no value)" >&5 30521 $as_echo "$as_me: Setting user supplied tool JAVAH= (no value)" >&6;} 30522 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAH" >&5 30523 $as_echo_n "checking for JAVAH... " >&6; } 30524 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 30525 $as_echo "disabled" >&6; } 30526 else 30527 # Check if the provided tool contains a complete path. 30528 tool_specified="$JAVAH" 30529 tool_basename="${tool_specified##*/}" 30530 if test "x$tool_basename" = "x$tool_specified"; then 30531 # A command without a complete path is provided, search $PATH. 30532 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAVAH=$tool_basename" >&5 30533 $as_echo "$as_me: Will search for user supplied tool JAVAH=$tool_basename" >&6;} 30534 # Extract the first word of "$tool_basename", so it can be a program name with args. 30535 set dummy $tool_basename; ac_word=$2 30536 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 30537 $as_echo_n "checking for $ac_word... " >&6; } 30538 if ${ac_cv_path_JAVAH+:} false; then : 30539 $as_echo_n "(cached) " >&6 30540 else 30541 case $JAVAH in 30542 [\\/]* | ?:[\\/]*) 30543 ac_cv_path_JAVAH="$JAVAH" # Let the user override the test with a path. 30544 ;; 30545 *) 30546 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 30547 for as_dir in $PATH 30548 do 30549 IFS=$as_save_IFS 30550 test -z "$as_dir" && as_dir=. 30551 for ac_exec_ext in '' $ac_executable_extensions; do 30552 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 30553 ac_cv_path_JAVAH="$as_dir/$ac_word$ac_exec_ext" 30554 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 30555 break 2 30556 fi 30557 done 30558 done 30559 IFS=$as_save_IFS 30560 30561 ;; 30562 esac 30563 fi 30564 JAVAH=$ac_cv_path_JAVAH 30565 if test -n "$JAVAH"; then 30566 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVAH" >&5 30567 $as_echo "$JAVAH" >&6; } 30568 else 30569 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 30570 $as_echo "no" >&6; } 30571 fi 30572 30573 30574 if test "x$JAVAH" = x; then 30575 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 30576 fi 30577 else 30578 # Otherwise we believe it is a complete path. Use it as it is. 30579 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAVAH=$tool_specified" >&5 30580 $as_echo "$as_me: Will use user supplied tool JAVAH=$tool_specified" >&6;} 30581 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAH" >&5 30582 $as_echo_n "checking for JAVAH... " >&6; } 30583 if test ! -x "$tool_specified"; then 30584 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30585 $as_echo "not found" >&6; } 30586 as_fn_error $? "User supplied tool JAVAH=$tool_specified does not exist or is not executable" "$LINENO" 5 30587 fi 30588 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 30589 $as_echo "$tool_specified" >&6; } 30590 fi 30591 fi 30592 fi 30593 30594 fi 30595 30596 30597 30598 # Use user overridden value if available, otherwise locate tool in the Boot JDK. 30599 30600 # Publish this variable in the help. 30601 30602 30603 if [ -z "${JAR+x}" ]; then 30604 # The variable is not set by user, try to locate tool using the code snippet 30605 30606 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jar in Boot JDK" >&5 30607 $as_echo_n "checking for jar in Boot JDK... " >&6; } 30608 JAR=$BOOT_JDK/bin/jar 30609 if test ! -x $JAR; then 30610 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30611 $as_echo "not found" >&6; } 30612 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 30613 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 30614 as_fn_error $? "Could not find jar in the Boot JDK" "$LINENO" 5 30615 fi 30616 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30617 $as_echo "ok" >&6; } 30618 30619 30620 else 30621 # The variable is set, but is it from the command line or the environment? 30622 30623 # Try to remove the string !JAR! from our list. 30624 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAR!/} 30625 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 30626 # If it failed, the variable was not from the command line. Ignore it, 30627 # but warn the user (except for BASH, which is always set by the calling BASH). 30628 if test "xJAR" != xBASH; then 30629 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAR from the environment. Use command line variables instead." >&5 30630 $as_echo "$as_me: WARNING: Ignoring value of JAR from the environment. Use command line variables instead." >&2;} 30631 fi 30632 # Try to locate tool using the code snippet 30633 30634 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jar in Boot JDK" >&5 30635 $as_echo_n "checking for jar in Boot JDK... " >&6; } 30636 JAR=$BOOT_JDK/bin/jar 30637 if test ! -x $JAR; then 30638 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30639 $as_echo "not found" >&6; } 30640 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 30641 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 30642 as_fn_error $? "Could not find jar in the Boot JDK" "$LINENO" 5 30643 fi 30644 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30645 $as_echo "ok" >&6; } 30646 30647 30648 else 30649 # If it succeeded, then it was overridden by the user. We will use it 30650 # for the tool. 30651 30652 # First remove it from the list of overridden variables, so we can test 30653 # for unknown variables in the end. 30654 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 30655 30656 # Check if we try to supply an empty value 30657 if test "x$JAR" = x; then 30658 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JAR= (no value)" >&5 30659 $as_echo "$as_me: Setting user supplied tool JAR= (no value)" >&6;} 30660 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAR" >&5 30661 $as_echo_n "checking for JAR... " >&6; } 30662 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 30663 $as_echo "disabled" >&6; } 30664 else 30665 # Check if the provided tool contains a complete path. 30666 tool_specified="$JAR" 30667 tool_basename="${tool_specified##*/}" 30668 if test "x$tool_basename" = "x$tool_specified"; then 30669 # A command without a complete path is provided, search $PATH. 30670 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAR=$tool_basename" >&5 30671 $as_echo "$as_me: Will search for user supplied tool JAR=$tool_basename" >&6;} 30672 # Extract the first word of "$tool_basename", so it can be a program name with args. 30673 set dummy $tool_basename; ac_word=$2 30674 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 30675 $as_echo_n "checking for $ac_word... " >&6; } 30676 if ${ac_cv_path_JAR+:} false; then : 30677 $as_echo_n "(cached) " >&6 30678 else 30679 case $JAR in 30680 [\\/]* | ?:[\\/]*) 30681 ac_cv_path_JAR="$JAR" # Let the user override the test with a path. 30682 ;; 30683 *) 30684 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 30685 for as_dir in $PATH 30686 do 30687 IFS=$as_save_IFS 30688 test -z "$as_dir" && as_dir=. 30689 for ac_exec_ext in '' $ac_executable_extensions; do 30690 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 30691 ac_cv_path_JAR="$as_dir/$ac_word$ac_exec_ext" 30692 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 30693 break 2 30694 fi 30695 done 30696 done 30697 IFS=$as_save_IFS 30698 30699 ;; 30700 esac 30701 fi 30702 JAR=$ac_cv_path_JAR 30703 if test -n "$JAR"; then 30704 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAR" >&5 30705 $as_echo "$JAR" >&6; } 30706 else 30707 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 30708 $as_echo "no" >&6; } 30709 fi 30710 30711 30712 if test "x$JAR" = x; then 30713 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 30714 fi 30715 else 30716 # Otherwise we believe it is a complete path. Use it as it is. 30717 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAR=$tool_specified" >&5 30718 $as_echo "$as_me: Will use user supplied tool JAR=$tool_specified" >&6;} 30719 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAR" >&5 30720 $as_echo_n "checking for JAR... " >&6; } 30721 if test ! -x "$tool_specified"; then 30722 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30723 $as_echo "not found" >&6; } 30724 as_fn_error $? "User supplied tool JAR=$tool_specified does not exist or is not executable" "$LINENO" 5 30725 fi 30726 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 30727 $as_echo "$tool_specified" >&6; } 30728 fi 30729 fi 30730 fi 30731 30732 fi 30733 30734 30735 30736 # Use user overridden value if available, otherwise locate tool in the Boot JDK. 30737 30738 # Publish this variable in the help. 30739 30740 30741 if [ -z "${JARSIGNER+x}" ]; then 30742 # The variable is not set by user, try to locate tool using the code snippet 30743 30744 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jarsigner in Boot JDK" >&5 30745 $as_echo_n "checking for jarsigner in Boot JDK... " >&6; } 30746 JARSIGNER=$BOOT_JDK/bin/jarsigner 30747 if test ! -x $JARSIGNER; then 30748 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30749 $as_echo "not found" >&6; } 30750 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 30751 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 30752 as_fn_error $? "Could not find jarsigner in the Boot JDK" "$LINENO" 5 30753 fi 30754 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30755 $as_echo "ok" >&6; } 30756 30757 30758 else 30759 # The variable is set, but is it from the command line or the environment? 30760 30761 # Try to remove the string !JARSIGNER! from our list. 30762 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JARSIGNER!/} 30763 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 30764 # If it failed, the variable was not from the command line. Ignore it, 30765 # but warn the user (except for BASH, which is always set by the calling BASH). 30766 if test "xJARSIGNER" != xBASH; then 30767 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JARSIGNER from the environment. Use command line variables instead." >&5 30768 $as_echo "$as_me: WARNING: Ignoring value of JARSIGNER from the environment. Use command line variables instead." >&2;} 30769 fi 30770 # Try to locate tool using the code snippet 30771 30772 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jarsigner in Boot JDK" >&5 30773 $as_echo_n "checking for jarsigner in Boot JDK... " >&6; } 30774 JARSIGNER=$BOOT_JDK/bin/jarsigner 30775 if test ! -x $JARSIGNER; then 30776 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30777 $as_echo "not found" >&6; } 30778 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&5 30779 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitly setting --with-boot-jdk" >&6;} 30780 as_fn_error $? "Could not find jarsigner in the Boot JDK" "$LINENO" 5 30781 fi 30782 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30783 $as_echo "ok" >&6; } 30784 30785 30786 else 30787 # If it succeeded, then it was overridden by the user. We will use it 30788 # for the tool. 30789 30790 # First remove it from the list of overridden variables, so we can test 30791 # for unknown variables in the end. 30792 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 30793 30794 # Check if we try to supply an empty value 30795 if test "x$JARSIGNER" = x; then 30796 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JARSIGNER= (no value)" >&5 30797 $as_echo "$as_me: Setting user supplied tool JARSIGNER= (no value)" >&6;} 30798 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JARSIGNER" >&5 30799 $as_echo_n "checking for JARSIGNER... " >&6; } 30800 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 30801 $as_echo "disabled" >&6; } 30802 else 30803 # Check if the provided tool contains a complete path. 30804 tool_specified="$JARSIGNER" 30805 tool_basename="${tool_specified##*/}" 30806 if test "x$tool_basename" = "x$tool_specified"; then 30807 # A command without a complete path is provided, search $PATH. 30808 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JARSIGNER=$tool_basename" >&5 30809 $as_echo "$as_me: Will search for user supplied tool JARSIGNER=$tool_basename" >&6;} 30810 # Extract the first word of "$tool_basename", so it can be a program name with args. 30811 set dummy $tool_basename; ac_word=$2 30812 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 30813 $as_echo_n "checking for $ac_word... " >&6; } 30814 if ${ac_cv_path_JARSIGNER+:} false; then : 30815 $as_echo_n "(cached) " >&6 30816 else 30817 case $JARSIGNER in 30818 [\\/]* | ?:[\\/]*) 30819 ac_cv_path_JARSIGNER="$JARSIGNER" # Let the user override the test with a path. 30820 ;; 30821 *) 30822 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 30823 for as_dir in $PATH 30824 do 30825 IFS=$as_save_IFS 30826 test -z "$as_dir" && as_dir=. 30827 for ac_exec_ext in '' $ac_executable_extensions; do 30828 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 30829 ac_cv_path_JARSIGNER="$as_dir/$ac_word$ac_exec_ext" 30830 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 30831 break 2 30832 fi 30833 done 30834 done 30835 IFS=$as_save_IFS 30836 30837 ;; 30838 esac 30839 fi 30840 JARSIGNER=$ac_cv_path_JARSIGNER 30841 if test -n "$JARSIGNER"; then 30842 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JARSIGNER" >&5 30843 $as_echo "$JARSIGNER" >&6; } 30844 else 30845 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 30846 $as_echo "no" >&6; } 30847 fi 30848 30849 30850 if test "x$JARSIGNER" = x; then 30851 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 30852 fi 30853 else 30854 # Otherwise we believe it is a complete path. Use it as it is. 30855 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JARSIGNER=$tool_specified" >&5 30856 $as_echo "$as_me: Will use user supplied tool JARSIGNER=$tool_specified" >&6;} 30857 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JARSIGNER" >&5 30858 $as_echo_n "checking for JARSIGNER... " >&6; } 30859 if test ! -x "$tool_specified"; then 30860 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30861 $as_echo "not found" >&6; } 30862 as_fn_error $? "User supplied tool JARSIGNER=$tool_specified does not exist or is not executable" "$LINENO" 5 30863 fi 30864 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 30865 $as_echo "$tool_specified" >&6; } 30866 fi 30867 fi 30868 fi 30869 30870 fi 30871 30872 30873 30874 # Finally, set some other options... 30875 30876 # When compiling code to be executed by the Boot JDK, force jdk8 compatibility. 30877 BOOT_JDK_SOURCETARGET="-source 8 -target 8" 30878 30879 30880 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if Boot JDK supports modules" >&5 30881 $as_echo_n "checking if Boot JDK supports modules... " >&6; } 30882 if "$JAVA" --list-modules > /dev/null 2>&1; then 30883 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 30884 $as_echo "yes" >&6; } 30885 BOOT_JDK_MODULAR="true" 30886 else 30887 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 30888 $as_echo "no" >&6; } 30889 BOOT_JDK_MODULAR="false" 30890 fi 30891 30892 30893 30894 30895 # Check if the boot jdk is 32 or 64 bit 30896 if "$JAVA" -d64 -version > /dev/null 2>&1; then 30897 BOOT_JDK_BITS="64" 30898 else 30899 BOOT_JDK_BITS="32" 30900 fi 30901 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if Boot JDK is 32 or 64 bits" >&5 30902 $as_echo_n "checking if Boot JDK is 32 or 64 bits... " >&6; } 30903 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_BITS" >&5 30904 $as_echo "$BOOT_JDK_BITS" >&6; } 30905 30906 30907 30908 # Check whether --with-build-jdk was given. 30909 if test "${with_build_jdk+set}" = set; then : 30910 withval=$with_build_jdk; 30911 fi 30912 30913 30914 CREATE_BUILDJDK=false 30915 EXTERNAL_BUILDJDK=false 30916 BUILD_JDK_FOUND="no" 30917 if test "x$with_build_jdk" != "x"; then 30918 30919 if test "x$BUILD_JDK_FOUND" = xno; then 30920 # Execute the test 30921 30922 if test "x$with_build_jdk" != x; then 30923 BUILD_JDK=$with_build_jdk 30924 BUILD_JDK_FOUND=maybe 30925 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Build JDK using configure arguments" >&5 30926 $as_echo "$as_me: Found potential Build JDK using configure arguments" >&6;} 30927 fi 30928 30929 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 30930 if test "x$BUILD_JDK_FOUND" = xmaybe; then 30931 # Do we have a bin/java? 30932 if test ! -x "$BUILD_JDK/bin/java"; then 30933 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Build JDK found at $BUILD_JDK did not contain bin/java; ignoring" >&5 30934 $as_echo "$as_me: Potential Build JDK found at $BUILD_JDK did not contain bin/java; ignoring" >&6;} 30935 BUILD_JDK_FOUND=no 30936 elif test ! -x "$BUILD_JDK/bin/jlink"; then 30937 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Build JDK found at $BUILD_JDK did not contain bin/jlink; ignoring" >&5 30938 $as_echo "$as_me: Potential Build JDK found at $BUILD_JDK did not contain bin/jlink; ignoring" >&6;} 30939 BUILD_JDK_FOUND=no 30940 elif test ! -x "$BUILD_JDK/bin/jmod"; then 30941 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Build JDK found at $BUILD_JDK did not contain bin/jmod; ignoring" >&5 30942 $as_echo "$as_me: Potential Build JDK found at $BUILD_JDK did not contain bin/jmod; ignoring" >&6;} 30943 BUILD_JDK_FOUND=no 30944 elif test ! -x "$BUILD_JDK/bin/javac"; then 30945 # Do we have a bin/javac? 30946 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Build JDK found at $BUILD_JDK did not contain bin/javac; ignoring" >&5 30947 $as_echo "$as_me: Potential Build JDK found at $BUILD_JDK did not contain bin/javac; ignoring" >&6;} 30948 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be a JRE instead of an JDK)" >&5 30949 $as_echo "$as_me: (This might be a JRE instead of an JDK)" >&6;} 30950 BUILD_JDK_FOUND=no 30951 else 30952 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 30953 BUILD_JDK_VERSION=`"$BUILD_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 30954 30955 # Extra M4 quote needed to protect [] in grep expression. 30956 FOUND_CORRECT_VERSION=`echo $BUILD_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"'` 30957 if test "x$FOUND_CORRECT_VERSION" = x; then 30958 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Build JDK found at $BUILD_JDK is incorrect JDK version ($BUILD_JDK_VERSION); ignoring" >&5 30959 $as_echo "$as_me: Potential Build JDK found at $BUILD_JDK is incorrect JDK version ($BUILD_JDK_VERSION); ignoring" >&6;} 30960 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Build JDK must be version 9)" >&5 30961 $as_echo "$as_me: (Your Build JDK must be version 9)" >&6;} 30962 BUILD_JDK_FOUND=no 30963 else 30964 # We're done! 30965 BUILD_JDK_FOUND=yes 30966 30967 # Only process if variable expands to non-empty 30968 30969 if test "x$BUILD_JDK" != x; then 30970 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30971 30972 # Input might be given as Windows format, start by converting to 30973 # unix format. 30974 path="$BUILD_JDK" 30975 new_path=`$CYGPATH -u "$path"` 30976 30977 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 30978 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 30979 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 30980 # "foo.exe" is OK but "foo" is an error. 30981 # 30982 # This test is therefore slightly more accurate than "test -f" to check for file precense. 30983 # It is also a way to make sure we got the proper file name for the real test later on. 30984 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 30985 if test "x$test_shortpath" = x; then 30986 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_JDK, which resolves as \"$path\", is invalid." >&5 30987 $as_echo "$as_me: The path of BUILD_JDK, which resolves as \"$path\", is invalid." >&6;} 30988 as_fn_error $? "Cannot locate the the path of BUILD_JDK" "$LINENO" 5 30989 fi 30990 30991 # Call helper function which possibly converts this using DOS-style short mode. 30992 # If so, the updated path is stored in $new_path. 30993 30994 input_path="$new_path" 30995 # Check if we need to convert this using DOS-style short mode. If the path 30996 # contains just simple characters, use it. Otherwise (spaces, weird characters), 30997 # take no chances and rewrite it. 30998 # Note: m4 eats our [], so we need to use [ and ] instead. 30999 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 31000 if test "x$has_forbidden_chars" != x; then 31001 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 31002 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 31003 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 31004 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 31005 # Going to short mode and back again did indeed matter. Since short mode is 31006 # case insensitive, let's make it lowercase to improve readability. 31007 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 31008 # Now convert it back to Unix-style (cygpath) 31009 input_path=`$CYGPATH -u "$shortmode_path"` 31010 new_path="$input_path" 31011 fi 31012 fi 31013 31014 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 31015 if test "x$test_cygdrive_prefix" = x; then 31016 # As a simple fix, exclude /usr/bin since it's not a real path. 31017 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 31018 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 31019 # a path prefixed by /cygdrive for fixpath to work. 31020 new_path="$CYGWIN_ROOT_PATH$input_path" 31021 fi 31022 fi 31023 31024 31025 if test "x$path" != "x$new_path"; then 31026 BUILD_JDK="$new_path" 31027 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_JDK to \"$new_path\"" >&5 31028 $as_echo "$as_me: Rewriting BUILD_JDK to \"$new_path\"" >&6;} 31029 fi 31030 31031 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31032 31033 path="$BUILD_JDK" 31034 has_colon=`$ECHO $path | $GREP ^.:` 31035 new_path="$path" 31036 if test "x$has_colon" = x; then 31037 # Not in mixed or Windows style, start by that. 31038 new_path=`cmd //c echo $path` 31039 fi 31040 31041 31042 input_path="$new_path" 31043 # Check if we need to convert this using DOS-style short mode. If the path 31044 # contains just simple characters, use it. Otherwise (spaces, weird characters), 31045 # take no chances and rewrite it. 31046 # Note: m4 eats our [], so we need to use [ and ] instead. 31047 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 31048 if test "x$has_forbidden_chars" != x; then 31049 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 31050 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 31051 fi 31052 31053 31054 windows_path="$new_path" 31055 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31056 unix_path=`$CYGPATH -u "$windows_path"` 31057 new_path="$unix_path" 31058 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31059 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31060 new_path="$unix_path" 31061 fi 31062 31063 if test "x$path" != "x$new_path"; then 31064 BUILD_JDK="$new_path" 31065 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_JDK to \"$new_path\"" >&5 31066 $as_echo "$as_me: Rewriting BUILD_JDK to \"$new_path\"" >&6;} 31067 fi 31068 31069 # Save the first 10 bytes of this path to the storage, so fixpath can work. 31070 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 31071 31072 else 31073 # We're on a unix platform. Hooray! :) 31074 path="$BUILD_JDK" 31075 has_space=`$ECHO "$path" | $GREP " "` 31076 if test "x$has_space" != x; then 31077 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_JDK, which resolves as \"$path\", is invalid." >&5 31078 $as_echo "$as_me: The path of BUILD_JDK, which resolves as \"$path\", is invalid." >&6;} 31079 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 31080 fi 31081 31082 # Use eval to expand a potential ~ 31083 eval path="$path" 31084 if test ! -f "$path" && test ! -d "$path"; then 31085 as_fn_error $? "The path of BUILD_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 31086 fi 31087 31088 if test -d "$path"; then 31089 BUILD_JDK="`cd "$path"; $THEPWDCMD -L`" 31090 else 31091 dir="`$DIRNAME "$path"`" 31092 base="`$BASENAME "$path"`" 31093 BUILD_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 31094 fi 31095 fi 31096 fi 31097 31098 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Build JDK" >&5 31099 $as_echo_n "checking for Build JDK... " >&6; } 31100 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_JDK" >&5 31101 $as_echo "$BUILD_JDK" >&6; } 31102 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Build JDK version" >&5 31103 $as_echo_n "checking Build JDK version... " >&6; } 31104 BUILD_JDK_VERSION=`"$BUILD_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 31105 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_JDK_VERSION" >&5 31106 $as_echo "$BUILD_JDK_VERSION" >&6; } 31107 fi # end check jdk version 31108 fi # end check java 31109 fi # end check build jdk found 31110 fi 31111 31112 EXTERNAL_BUILDJDK=true 31113 else 31114 if test "x$COMPILE_TYPE" = "xcross"; then 31115 BUILD_JDK="\$(BUILDJDK_OUTPUTDIR)/jdk" 31116 BUILD_JDK_FOUND=yes 31117 CREATE_BUILDJDK=true 31118 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Build JDK" >&5 31119 $as_echo_n "checking for Build JDK... " >&6; } 31120 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, will build it for the host platform" >&5 31121 $as_echo "yes, will build it for the host platform" >&6; } 31122 else 31123 BUILD_JDK="\$(JDK_OUTPUTDIR)" 31124 BUILD_JDK_FOUND=yes 31125 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Build JDK" >&5 31126 $as_echo_n "checking for Build JDK... " >&6; } 31127 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, will use output dir" >&5 31128 $as_echo "yes, will use output dir" >&6; } 31129 fi 31130 fi 31131 31132 JMOD="$BUILD_JDK/bin/jmod" 31133 JLINK="$BUILD_JDK/bin/jlink" 31134 31135 31136 31137 if test "x$BUILD_JDK_FOUND" != "xyes"; then 31138 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Build JDK" >&5 31139 $as_echo_n "checking for Build JDK... " >&6; } 31140 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 31141 $as_echo "no" >&6; } 31142 as_fn_error $? "Could not find a suitable Build JDK" "$LINENO" 5 31143 fi 31144 31145 31146 31147 31148 31149 31150 ############################################################################### 31151 # 31152 # Configure the sources to use. We can add or override individual directories. 31153 # 31154 ############################################################################### 31155 31156 31157 # Where are the sources. 31158 LANGTOOLS_TOPDIR="$SRC_ROOT/langtools" 31159 CORBA_TOPDIR="$SRC_ROOT/corba" 31160 JAXP_TOPDIR="$SRC_ROOT/jaxp" 31161 JAXWS_TOPDIR="$SRC_ROOT/jaxws" 31162 HOTSPOT_TOPDIR="$SRC_ROOT/hotspot" 31163 NASHORN_TOPDIR="$SRC_ROOT/nashorn" 31164 JDK_TOPDIR="$SRC_ROOT/jdk" 31165 31166 31167 31168 31169 31170 31171 31172 31173 31174 # This feature is no longer supported. 31175 31176 31177 31178 # Check whether --with-add-source-root was given. 31179 if test "${with_add_source_root+set}" = set; then : 31180 withval=$with_add_source_root; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-add-source-root is deprecated and will be ignored." >&5 31181 $as_echo "$as_me: WARNING: Option --with-add-source-root is deprecated and will be ignored." >&2;} 31182 fi 31183 31184 31185 31186 31187 # Check whether --with-override-source-root was given. 31188 if test "${with_override_source_root+set}" = set; then : 31189 withval=$with_override_source_root; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-override-source-root is deprecated and will be ignored." >&5 31190 $as_echo "$as_me: WARNING: Option --with-override-source-root is deprecated and will be ignored." >&2;} 31191 fi 31192 31193 31194 31195 31196 # Check whether --with-adds-and-overrides was given. 31197 if test "${with_adds_and_overrides+set}" = set; then : 31198 withval=$with_adds_and_overrides; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-adds-and-overrides is deprecated and will be ignored." >&5 31199 $as_echo "$as_me: WARNING: Option --with-adds-and-overrides is deprecated and will be ignored." >&2;} 31200 fi 31201 31202 31203 31204 31205 # Check whether --with-override-langtools was given. 31206 if test "${with_override_langtools+set}" = set; then : 31207 withval=$with_override_langtools; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-override-langtools is deprecated and will be ignored." >&5 31208 $as_echo "$as_me: WARNING: Option --with-override-langtools is deprecated and will be ignored." >&2;} 31209 fi 31210 31211 31212 31213 31214 # Check whether --with-override-corba was given. 31215 if test "${with_override_corba+set}" = set; then : 31216 withval=$with_override_corba; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-override-corba is deprecated and will be ignored." >&5 31217 $as_echo "$as_me: WARNING: Option --with-override-corba is deprecated and will be ignored." >&2;} 31218 fi 31219 31220 31221 31222 31223 # Check whether --with-override-jaxp was given. 31224 if test "${with_override_jaxp+set}" = set; then : 31225 withval=$with_override_jaxp; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-override-jaxp is deprecated and will be ignored." >&5 31226 $as_echo "$as_me: WARNING: Option --with-override-jaxp is deprecated and will be ignored." >&2;} 31227 fi 31228 31229 31230 31231 31232 # Check whether --with-override-jaxws was given. 31233 if test "${with_override_jaxws+set}" = set; then : 31234 withval=$with_override_jaxws; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-override-jaxws is deprecated and will be ignored." >&5 31235 $as_echo "$as_me: WARNING: Option --with-override-jaxws is deprecated and will be ignored." >&2;} 31236 fi 31237 31238 31239 31240 31241 # Check whether --with-override-hotspot was given. 31242 if test "${with_override_hotspot+set}" = set; then : 31243 withval=$with_override_hotspot; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-override-hotspot is deprecated and will be ignored." >&5 31244 $as_echo "$as_me: WARNING: Option --with-override-hotspot is deprecated and will be ignored." >&2;} 31245 fi 31246 31247 31248 31249 31250 # Check whether --with-override-nashorn was given. 31251 if test "${with_override_nashorn+set}" = set; then : 31252 withval=$with_override_nashorn; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-override-nashorn is deprecated and will be ignored." >&5 31253 $as_echo "$as_me: WARNING: Option --with-override-nashorn is deprecated and will be ignored." >&2;} 31254 fi 31255 31256 31257 31258 31259 # Check whether --with-override-jdk was given. 31260 if test "${with_override_jdk+set}" = set; then : 31261 withval=$with_override_jdk; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-override-jdk is deprecated and will be ignored." >&5 31262 $as_echo "$as_me: WARNING: Option --with-override-jdk is deprecated and will be ignored." >&2;} 31263 fi 31264 31265 31266 31267 31268 BUILD_OUTPUT="$OUTPUT_ROOT" 31269 31270 JDK_OUTPUTDIR="$OUTPUT_ROOT/jdk" 31271 31272 31273 31274 # Check whether --with-import_hotspot was given. 31275 if test "${with_import_hotspot+set}" = set; then : 31276 withval=$with_import_hotspot; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-import_hotspot is deprecated and will be ignored." >&5 31277 $as_echo "$as_me: WARNING: Option --with-import_hotspot is deprecated and will be ignored." >&2;} 31278 fi 31279 31280 31281 31282 31283 31284 31285 # Check whether --with-import-modules was given. 31286 if test "${with_import_modules+set}" = set; then : 31287 withval=$with_import_modules; 31288 fi 31289 31290 31291 if test "x$with_import_modules" != x \ 31292 && test "x$with_import_modules" != "xno"; then 31293 if test -d "$with_import_modules"; then 31294 IMPORT_MODULES_TOPDIR="$with_import_modules" 31295 31296 # Only process if variable expands to non-empty 31297 31298 if test "x$IMPORT_MODULES_TOPDIR" != x; then 31299 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31300 31301 # Input might be given as Windows format, start by converting to 31302 # unix format. 31303 path="$IMPORT_MODULES_TOPDIR" 31304 new_path=`$CYGPATH -u "$path"` 31305 31306 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 31307 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 31308 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 31309 # "foo.exe" is OK but "foo" is an error. 31310 # 31311 # This test is therefore slightly more accurate than "test -f" to check for file precense. 31312 # It is also a way to make sure we got the proper file name for the real test later on. 31313 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 31314 if test "x$test_shortpath" = x; then 31315 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of IMPORT_MODULES_TOPDIR, which resolves as \"$path\", is invalid." >&5 31316 $as_echo "$as_me: The path of IMPORT_MODULES_TOPDIR, which resolves as \"$path\", is invalid." >&6;} 31317 as_fn_error $? "Cannot locate the the path of IMPORT_MODULES_TOPDIR" "$LINENO" 5 31318 fi 31319 31320 # Call helper function which possibly converts this using DOS-style short mode. 31321 # If so, the updated path is stored in $new_path. 31322 31323 input_path="$new_path" 31324 # Check if we need to convert this using DOS-style short mode. If the path 31325 # contains just simple characters, use it. Otherwise (spaces, weird characters), 31326 # take no chances and rewrite it. 31327 # Note: m4 eats our [], so we need to use [ and ] instead. 31328 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 31329 if test "x$has_forbidden_chars" != x; then 31330 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 31331 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 31332 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 31333 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 31334 # Going to short mode and back again did indeed matter. Since short mode is 31335 # case insensitive, let's make it lowercase to improve readability. 31336 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 31337 # Now convert it back to Unix-style (cygpath) 31338 input_path=`$CYGPATH -u "$shortmode_path"` 31339 new_path="$input_path" 31340 fi 31341 fi 31342 31343 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 31344 if test "x$test_cygdrive_prefix" = x; then 31345 # As a simple fix, exclude /usr/bin since it's not a real path. 31346 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 31347 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 31348 # a path prefixed by /cygdrive for fixpath to work. 31349 new_path="$CYGWIN_ROOT_PATH$input_path" 31350 fi 31351 fi 31352 31353 31354 if test "x$path" != "x$new_path"; then 31355 IMPORT_MODULES_TOPDIR="$new_path" 31356 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting IMPORT_MODULES_TOPDIR to \"$new_path\"" >&5 31357 $as_echo "$as_me: Rewriting IMPORT_MODULES_TOPDIR to \"$new_path\"" >&6;} 31358 fi 31359 31360 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31361 31362 path="$IMPORT_MODULES_TOPDIR" 31363 has_colon=`$ECHO $path | $GREP ^.:` 31364 new_path="$path" 31365 if test "x$has_colon" = x; then 31366 # Not in mixed or Windows style, start by that. 31367 new_path=`cmd //c echo $path` 31368 fi 31369 31370 31371 input_path="$new_path" 31372 # Check if we need to convert this using DOS-style short mode. If the path 31373 # contains just simple characters, use it. Otherwise (spaces, weird characters), 31374 # take no chances and rewrite it. 31375 # Note: m4 eats our [], so we need to use [ and ] instead. 31376 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 31377 if test "x$has_forbidden_chars" != x; then 31378 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 31379 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 31380 fi 31381 31382 31383 windows_path="$new_path" 31384 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31385 unix_path=`$CYGPATH -u "$windows_path"` 31386 new_path="$unix_path" 31387 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31388 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31389 new_path="$unix_path" 31390 fi 31391 31392 if test "x$path" != "x$new_path"; then 31393 IMPORT_MODULES_TOPDIR="$new_path" 31394 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting IMPORT_MODULES_TOPDIR to \"$new_path\"" >&5 31395 $as_echo "$as_me: Rewriting IMPORT_MODULES_TOPDIR to \"$new_path\"" >&6;} 31396 fi 31397 31398 # Save the first 10 bytes of this path to the storage, so fixpath can work. 31399 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 31400 31401 else 31402 # We're on a unix platform. Hooray! :) 31403 path="$IMPORT_MODULES_TOPDIR" 31404 has_space=`$ECHO "$path" | $GREP " "` 31405 if test "x$has_space" != x; then 31406 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of IMPORT_MODULES_TOPDIR, which resolves as \"$path\", is invalid." >&5 31407 $as_echo "$as_me: The path of IMPORT_MODULES_TOPDIR, which resolves as \"$path\", is invalid." >&6;} 31408 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 31409 fi 31410 31411 # Use eval to expand a potential ~ 31412 eval path="$path" 31413 if test ! -f "$path" && test ! -d "$path"; then 31414 as_fn_error $? "The path of IMPORT_MODULES_TOPDIR, which resolves as \"$path\", is not found." "$LINENO" 5 31415 fi 31416 31417 if test -d "$path"; then 31418 IMPORT_MODULES_TOPDIR="`cd "$path"; $THEPWDCMD -L`" 31419 else 31420 dir="`$DIRNAME "$path"`" 31421 base="`$BASENAME "$path"`" 31422 IMPORT_MODULES_TOPDIR="`cd "$dir"; $THEPWDCMD -L`/$base" 31423 fi 31424 fi 31425 fi 31426 31427 elif test -e "$with_import_modules"; then 31428 IMPORT_MODULES_TOPDIR="$CONFIGURESUPPORT_OUTPUTDIR/import-modules" 31429 $RM -rf "$IMPORT_MODULES_TOPDIR" 31430 $MKDIR -p "$IMPORT_MODULES_TOPDIR" 31431 if ! $UNZIP -q "$with_import_modules" -d "$IMPORT_MODULES_TOPDIR"; then 31432 as_fn_error $? "--with-import-modules=\"$with_import_modules\" must point to a dir or a zip file" "$LINENO" 5 31433 fi 31434 else 31435 as_fn_error $? "--with-import-modules=\"$with_import_modules\" must point to a dir or a zip file" "$LINENO" 5 31436 fi 31437 fi 31438 31439 if test -d "$IMPORT_MODULES_TOPDIR/modules"; then 31440 IMPORT_MODULES_CLASSES="$IMPORT_MODULES_TOPDIR/modules" 31441 fi 31442 if test -d "$IMPORT_MODULES_TOPDIR/modules_cmds"; then 31443 IMPORT_MODULES_CMDS="$IMPORT_MODULES_TOPDIR/modules_cmds" 31444 fi 31445 if test -d "$IMPORT_MODULES_TOPDIR/modules_libs"; then 31446 IMPORT_MODULES_LIBS="$IMPORT_MODULES_TOPDIR/modules_libs" 31447 fi 31448 if test -d "$IMPORT_MODULES_TOPDIR/modules_conf"; then 31449 IMPORT_MODULES_CONF="$IMPORT_MODULES_TOPDIR/modules_conf" 31450 fi 31451 if test -d "$IMPORT_MODULES_TOPDIR/modules_legal"; then 31452 IMPORT_MODULES_LEGAL="$IMPORT_MODULES_TOPDIR/modules_legal" 31453 fi 31454 if test -d "$IMPORT_MODULES_TOPDIR/modules_man"; then 31455 IMPORT_MODULES_MAN="$IMPORT_MODULES_TOPDIR/modules_man" 31456 fi 31457 if test -d "$IMPORT_MODULES_TOPDIR/modules_src"; then 31458 IMPORT_MODULES_SRC="$IMPORT_MODULES_TOPDIR/modules_src" 31459 fi 31460 if test -d "$IMPORT_MODULES_TOPDIR/make"; then 31461 IMPORT_MODULES_MAKE="$IMPORT_MODULES_TOPDIR/make" 31462 fi 31463 31464 31465 31466 31467 31468 31469 31470 31471 31472 31473 31474 ############################################################################### 31475 # 31476 # Setup the toolchain (compilers etc), i.e. tools used to compile and process 31477 # native code. 31478 # 31479 ############################################################################### 31480 31481 # See if we are doing a complete static build or not 31482 31483 # Check whether --enable-static-build was given. 31484 if test "${enable_static_build+set}" = set; then : 31485 enableval=$enable_static_build; 31486 fi 31487 31488 STATIC_BUILD=false 31489 if test "x$enable_static_build" = "xyes"; then 31490 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if static build is enabled" >&5 31491 $as_echo_n "checking if static build is enabled... " >&6; } 31492 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 31493 $as_echo "yes" >&6; } 31494 if test "x$OPENJDK_TARGET_OS" != "xmacosx"; then 31495 as_fn_error $? "--enable-static-build is only supported for macosx builds" "$LINENO" 5 31496 fi 31497 STATIC_BUILD_CFLAGS="-DSTATIC_BUILD=1" 31498 CFLAGS_JDKLIB_EXTRA="$CFLAGS_JDKLIB_EXTRA $STATIC_BUILD_CFLAGS" 31499 CXXFLAGS_JDKLIB_EXTRA="$CXXFLAGS_JDKLIB_EXTRA $STATIC_BUILD_CFLAGS" 31500 STATIC_BUILD=true 31501 elif test "x$enable_static_build" = "xno"; then 31502 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if static build is enabled" >&5 31503 $as_echo_n "checking if static build is enabled... " >&6; } 31504 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 31505 $as_echo "no" >&6; } 31506 elif test "x$enable_static_build" != "x"; then 31507 as_fn_error $? "--enable-static-build can only be assigned \"yes\" or \"no\"" "$LINENO" 5 31508 fi 31509 31510 31511 31512 31513 # First determine the toolchain type (compiler family) 31514 31515 31516 # Check whether --with-toolchain-type was given. 31517 if test "${with_toolchain_type+set}" = set; then : 31518 withval=$with_toolchain_type; 31519 fi 31520 31521 31522 # Use indirect variable referencing 31523 toolchain_var_name=VALID_TOOLCHAINS_$OPENJDK_BUILD_OS 31524 VALID_TOOLCHAINS=${!toolchain_var_name} 31525 31526 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 31527 if test -n "$XCODEBUILD"; then 31528 # On Mac OS X, default toolchain to clang after Xcode 5 31529 XCODE_VERSION_OUTPUT=`"$XCODEBUILD" -version 2>&1 | $HEAD -n 1` 31530 $ECHO "$XCODE_VERSION_OUTPUT" | $GREP "Xcode " > /dev/null 31531 if test $? -ne 0; then 31532 as_fn_error $? "Failed to determine Xcode version." "$LINENO" 5 31533 fi 31534 XCODE_MAJOR_VERSION=`$ECHO $XCODE_VERSION_OUTPUT | \ 31535 $SED -e 's/^Xcode \([1-9][0-9.]*\)/\1/' | \ 31536 $CUT -f 1 -d .` 31537 { $as_echo "$as_me:${as_lineno-$LINENO}: Xcode major version: $XCODE_MAJOR_VERSION" >&5 31538 $as_echo "$as_me: Xcode major version: $XCODE_MAJOR_VERSION" >&6;} 31539 if test $XCODE_MAJOR_VERSION -ge 5; then 31540 DEFAULT_TOOLCHAIN="clang" 31541 else 31542 DEFAULT_TOOLCHAIN="gcc" 31543 fi 31544 else 31545 # If Xcode is not installed, but the command line tools are 31546 # then we can't run xcodebuild. On these systems we should 31547 # default to clang 31548 DEFAULT_TOOLCHAIN="clang" 31549 fi 31550 else 31551 # First toolchain type in the list is the default 31552 DEFAULT_TOOLCHAIN=${VALID_TOOLCHAINS%% *} 31553 fi 31554 31555 if test "x$with_toolchain_type" = xlist; then 31556 # List all toolchains 31557 { $as_echo "$as_me:${as_lineno-$LINENO}: The following toolchains are valid on this platform:" >&5 31558 $as_echo "$as_me: The following toolchains are valid on this platform:" >&6;} 31559 for toolchain in $VALID_TOOLCHAINS; do 31560 toolchain_var_name=TOOLCHAIN_DESCRIPTION_$toolchain 31561 TOOLCHAIN_DESCRIPTION=${!toolchain_var_name} 31562 $PRINTF " %-10s %s\n" $toolchain "$TOOLCHAIN_DESCRIPTION" 31563 done 31564 31565 exit 0 31566 elif test "x$with_toolchain_type" != x; then 31567 # User override; check that it is valid 31568 if test "x${VALID_TOOLCHAINS/$with_toolchain_type/}" = "x${VALID_TOOLCHAINS}"; then 31569 { $as_echo "$as_me:${as_lineno-$LINENO}: Toolchain type $with_toolchain_type is not valid on this platform." >&5 31570 $as_echo "$as_me: Toolchain type $with_toolchain_type is not valid on this platform." >&6;} 31571 { $as_echo "$as_me:${as_lineno-$LINENO}: Valid toolchains: $VALID_TOOLCHAINS." >&5 31572 $as_echo "$as_me: Valid toolchains: $VALID_TOOLCHAINS." >&6;} 31573 as_fn_error $? "Cannot continue." "$LINENO" 5 31574 fi 31575 TOOLCHAIN_TYPE=$with_toolchain_type 31576 else 31577 # No flag given, use default 31578 TOOLCHAIN_TYPE=$DEFAULT_TOOLCHAIN 31579 fi 31580 31581 31582 TOOLCHAIN_CC_BINARY_clang="clang" 31583 TOOLCHAIN_CC_BINARY_gcc="gcc" 31584 TOOLCHAIN_CC_BINARY_microsoft="cl" 31585 TOOLCHAIN_CC_BINARY_solstudio="cc" 31586 TOOLCHAIN_CC_BINARY_xlc="xlc_r" 31587 31588 TOOLCHAIN_CXX_BINARY_clang="clang++" 31589 TOOLCHAIN_CXX_BINARY_gcc="g++" 31590 TOOLCHAIN_CXX_BINARY_microsoft="cl" 31591 TOOLCHAIN_CXX_BINARY_solstudio="CC" 31592 TOOLCHAIN_CXX_BINARY_xlc="xlC_r" 31593 31594 # Use indirect variable referencing 31595 toolchain_var_name=TOOLCHAIN_DESCRIPTION_$TOOLCHAIN_TYPE 31596 TOOLCHAIN_DESCRIPTION=${!toolchain_var_name} 31597 toolchain_var_name=TOOLCHAIN_MINIMUM_VERSION_$TOOLCHAIN_TYPE 31598 TOOLCHAIN_MINIMUM_VERSION=${!toolchain_var_name} 31599 toolchain_var_name=TOOLCHAIN_CC_BINARY_$TOOLCHAIN_TYPE 31600 TOOLCHAIN_CC_BINARY=${!toolchain_var_name} 31601 toolchain_var_name=TOOLCHAIN_CXX_BINARY_$TOOLCHAIN_TYPE 31602 TOOLCHAIN_CXX_BINARY=${!toolchain_var_name} 31603 31604 31605 # Define filename patterns 31606 if test "x$OPENJDK_TARGET_OS" = xwindows; then 31607 LIBRARY_PREFIX= 31608 SHARED_LIBRARY_SUFFIX='.dll' 31609 STATIC_LIBRARY_SUFFIX='.lib' 31610 SHARED_LIBRARY='$1.dll' 31611 STATIC_LIBRARY='$1.lib' 31612 OBJ_SUFFIX='.obj' 31613 EXE_SUFFIX='.exe' 31614 else 31615 LIBRARY_PREFIX=lib 31616 SHARED_LIBRARY_SUFFIX='.so' 31617 STATIC_LIBRARY_SUFFIX='.a' 31618 SHARED_LIBRARY='lib$1.so' 31619 STATIC_LIBRARY='lib$1.a' 31620 OBJ_SUFFIX='.o' 31621 EXE_SUFFIX='' 31622 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 31623 # For full static builds, we're overloading the SHARED_LIBRARY 31624 # variables in order to limit the amount of changes required. 31625 # It would be better to remove SHARED and just use LIBRARY and 31626 # LIBRARY_SUFFIX for libraries that can be built either 31627 # shared or static and use STATIC_* for libraries that are 31628 # always built statically. 31629 if test "x$STATIC_BUILD" = xtrue; then 31630 SHARED_LIBRARY='lib$1.a' 31631 SHARED_LIBRARY_SUFFIX='.a' 31632 else 31633 SHARED_LIBRARY='lib$1.dylib' 31634 SHARED_LIBRARY_SUFFIX='.dylib' 31635 fi 31636 fi 31637 fi 31638 31639 31640 31641 31642 31643 31644 31645 31646 31647 31648 if test "x$TOOLCHAIN_TYPE" = "x$DEFAULT_TOOLCHAIN"; then 31649 { $as_echo "$as_me:${as_lineno-$LINENO}: Using default toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION)" >&5 31650 $as_echo "$as_me: Using default toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION)" >&6;} 31651 else 31652 { $as_echo "$as_me:${as_lineno-$LINENO}: Using user selected toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION). Default toolchain is $DEFAULT_TOOLCHAIN." >&5 31653 $as_echo "$as_me: Using user selected toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION). Default toolchain is $DEFAULT_TOOLCHAIN." >&6;} 31654 fi 31655 31656 31657 # User supplied flags should be used when configure detects compilers 31658 31659 if test "x$CFLAGS" != "x${ADDED_CFLAGS}"; then 31660 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring CFLAGS($CFLAGS) found in environment. Use --with-extra-cflags" >&5 31661 $as_echo "$as_me: WARNING: Ignoring CFLAGS($CFLAGS) found in environment. Use --with-extra-cflags" >&2;} 31662 fi 31663 31664 if test "x$CXXFLAGS" != "x${ADDED_CXXFLAGS}"; then 31665 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring CXXFLAGS($CXXFLAGS) found in environment. Use --with-extra-cxxflags" >&5 31666 $as_echo "$as_me: WARNING: Ignoring CXXFLAGS($CXXFLAGS) found in environment. Use --with-extra-cxxflags" >&2;} 31667 fi 31668 31669 if test "x$LDFLAGS" != "x${ADDED_LDFLAGS}"; then 31670 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring LDFLAGS($LDFLAGS) found in environment. Use --with-extra-ldflags" >&5 31671 $as_echo "$as_me: WARNING: Ignoring LDFLAGS($LDFLAGS) found in environment. Use --with-extra-ldflags" >&2;} 31672 fi 31673 31674 31675 # Check whether --with-extra-cflags was given. 31676 if test "${with_extra_cflags+set}" = set; then : 31677 withval=$with_extra_cflags; 31678 fi 31679 31680 31681 31682 # Check whether --with-extra-cxxflags was given. 31683 if test "${with_extra_cxxflags+set}" = set; then : 31684 withval=$with_extra_cxxflags; 31685 fi 31686 31687 31688 31689 # Check whether --with-extra-ldflags was given. 31690 if test "${with_extra_ldflags+set}" = set; then : 31691 withval=$with_extra_ldflags; 31692 fi 31693 31694 31695 EXTRA_CFLAGS="$with_extra_cflags" 31696 EXTRA_CXXFLAGS="$with_extra_cxxflags" 31697 EXTRA_LDFLAGS="$with_extra_ldflags" 31698 31699 31700 31701 31702 31703 # The global CFLAGS and LDLAGS variables are used by configure tests and 31704 # should include the extra parameters 31705 CFLAGS="$EXTRA_CFLAGS" 31706 CXXFLAGS="$EXTRA_CXXFLAGS" 31707 LDFLAGS="$EXTRA_LDFLAGS" 31708 CPPFLAGS="" 31709 31710 # The sysroot cflags are needed for configure to be able to run the compilers 31711 31712 if test "x$SYSROOT" != "x"; then 31713 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 31714 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 31715 # Solaris Studio does not have a concept of sysroot. Instead we must 31716 # make sure the default include and lib dirs are appended to each 31717 # compile and link command line. Must also add -I-xbuiltin to enable 31718 # inlining of system functions and intrinsics. 31719 SYSROOT_CFLAGS="-I-xbuiltin -I$SYSROOT/usr/include" 31720 SYSROOT_LDFLAGS="-L$SYSROOT/usr/lib$OPENJDK_TARGET_CPU_ISADIR \ 31721 -L$SYSROOT/lib$OPENJDK_TARGET_CPU_ISADIR" 31722 fi 31723 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 31724 SYSROOT_CFLAGS="--sysroot=$SYSROOT" 31725 SYSROOT_LDFLAGS="--sysroot=$SYSROOT" 31726 elif test "x$TOOLCHAIN_TYPE" = xclang; then 31727 SYSROOT_CFLAGS="-isysroot $SYSROOT" 31728 SYSROOT_LDFLAGS="-isysroot $SYSROOT" 31729 fi 31730 # The global CFLAGS and LDFLAGS variables need these for configure to function 31731 CFLAGS="$CFLAGS $SYSROOT_CFLAGS" 31732 CPPFLAGS="$CPPFLAGS $SYSROOT_CFLAGS" 31733 CXXFLAGS="$CXXFLAGS $SYSROOT_CFLAGS" 31734 LDFLAGS="$LDFLAGS $SYSROOT_LDFLAGS" 31735 fi 31736 31737 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 31738 # We also need -iframework<path>/System/Library/Frameworks 31739 SYSROOT_CFLAGS="$SYSROOT_CFLAGS -iframework $SYSROOT/System/Library/Frameworks" 31740 SYSROOT_LDFLAGS="$SYSROOT_LDFLAGS -iframework $SYSROOT/System/Library/Frameworks" 31741 # These always need to be set, or we can't find the frameworks embedded in JavaVM.framework 31742 # set this here so it doesn't have to be peppered throughout the forest 31743 SYSROOT_CFLAGS="$SYSROOT_CFLAGS -F $SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks" 31744 SYSROOT_LDFLAGS="$SYSROOT_LDFLAGS -F $SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks" 31745 fi 31746 31747 31748 31749 31750 31751 # Then detect the actual binaries needed 31752 31753 # FIXME: Is this needed? 31754 ac_ext=cpp 31755 ac_cpp='$CXXCPP $CPPFLAGS' 31756 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 31757 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 31758 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 31759 31760 31761 # Store the CFLAGS etc passed to the configure script. 31762 ORG_CFLAGS="$CFLAGS" 31763 ORG_CXXFLAGS="$CXXFLAGS" 31764 31765 # autoconf magic only relies on PATH, so update it if tools dir is specified 31766 OLD_PATH="$PATH" 31767 31768 # On Windows, we need to detect the visual studio installation first. 31769 # This will change the PATH, but we need to keep that new PATH even 31770 # after toolchain detection is done, since the compiler (on x86) uses 31771 # it for DLL resolution in runtime. 31772 if test "x$OPENJDK_BUILD_OS" = "xwindows" \ 31773 && test "x$TOOLCHAIN_TYPE" = "xmicrosoft"; then 31774 31775 # Store path to cygwin link.exe to help excluding it when searching for 31776 # VS linker. This must be done before changing the PATH when looking for VS. 31777 # Extract the first word of "link", so it can be a program name with args. 31778 set dummy link; ac_word=$2 31779 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 31780 $as_echo_n "checking for $ac_word... " >&6; } 31781 if ${ac_cv_path_CYGWIN_LINK+:} false; then : 31782 $as_echo_n "(cached) " >&6 31783 else 31784 case $CYGWIN_LINK in 31785 [\\/]* | ?:[\\/]*) 31786 ac_cv_path_CYGWIN_LINK="$CYGWIN_LINK" # Let the user override the test with a path. 31787 ;; 31788 *) 31789 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 31790 for as_dir in $PATH 31791 do 31792 IFS=$as_save_IFS 31793 test -z "$as_dir" && as_dir=. 31794 for ac_exec_ext in '' $ac_executable_extensions; do 31795 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 31796 ac_cv_path_CYGWIN_LINK="$as_dir/$ac_word$ac_exec_ext" 31797 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 31798 break 2 31799 fi 31800 done 31801 done 31802 IFS=$as_save_IFS 31803 31804 ;; 31805 esac 31806 fi 31807 CYGWIN_LINK=$ac_cv_path_CYGWIN_LINK 31808 if test -n "$CYGWIN_LINK"; then 31809 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_LINK" >&5 31810 $as_echo "$CYGWIN_LINK" >&6; } 31811 else 31812 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 31813 $as_echo "no" >&6; } 31814 fi 31815 31816 31817 if test "x$CYGWIN_LINK" != x; then 31818 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the first found link.exe is actually the Cygwin link tool" >&5 31819 $as_echo_n "checking if the first found link.exe is actually the Cygwin link tool... " >&6; } 31820 "$CYGWIN_LINK" --version > /dev/null 31821 if test $? -eq 0 ; then 31822 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 31823 $as_echo "yes" >&6; } 31824 else 31825 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 31826 $as_echo "no" >&6; } 31827 # This might be the VS linker. Don't exclude it later on. 31828 CYGWIN_LINK="" 31829 fi 31830 fi 31831 31832 # First-hand choice is to locate and run the vsvars bat file. 31833 31834 31835 # Check whether --with-toolchain-version was given. 31836 if test "${with_toolchain_version+set}" = set; then : 31837 withval=$with_toolchain_version; 31838 fi 31839 31840 31841 if test "x$with_toolchain_version" = xlist; then 31842 # List all toolchains 31843 { $as_echo "$as_me:${as_lineno-$LINENO}: The following toolchain versions are valid on this platform:" >&5 31844 $as_echo "$as_me: The following toolchain versions are valid on this platform:" >&6;} 31845 for version in $VALID_VS_VERSIONS; do 31846 eval VS_DESCRIPTION=\${VS_DESCRIPTION_$version} 31847 $PRINTF " %-10s %s\n" $version "$VS_DESCRIPTION" 31848 done 31849 31850 exit 0 31851 elif test "x$DEVKIT_VS_VERSION" != x; then 31852 VS_VERSION=$DEVKIT_VS_VERSION 31853 TOOLCHAIN_VERSION=$VS_VERSION 31854 eval VS_DESCRIPTION="\${VS_DESCRIPTION_${VS_VERSION}}" 31855 eval VS_VERSION_INTERNAL="\${VS_VERSION_INTERNAL_${VS_VERSION}}" 31856 eval MSVCR_NAME="\${VS_MSVCR_${VS_VERSION}}" 31857 eval MSVCP_NAME="\${VS_MSVCP_${VS_VERSION}}" 31858 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 31859 VS_PATH="$TOOLCHAIN_PATH:$PATH" 31860 31861 # Convert DEVKIT_VS_INCLUDE into windows style VS_INCLUDE so that it 31862 # can still be exported as INCLUDE for compiler invocations without 31863 # SYSROOT_CFLAGS 31864 OLDIFS="$IFS" 31865 IFS=";" 31866 for i in $DEVKIT_VS_INCLUDE; do 31867 ipath=$i 31868 31869 unix_path="$ipath" 31870 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31871 windows_path=`$CYGPATH -m "$unix_path"` 31872 ipath="$windows_path" 31873 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31874 windows_path=`cmd //c echo $unix_path` 31875 ipath="$windows_path" 31876 fi 31877 31878 VS_INCLUDE="$VS_INCLUDE;$ipath" 31879 done 31880 # Convert DEVKIT_VS_LIB into VS_LIB so that it can still be exported 31881 # as LIB for compiler invocations without SYSROOT_LDFLAGS 31882 for i in $DEVKIT_VS_LIB; do 31883 libpath=$i 31884 31885 unix_path="$libpath" 31886 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31887 windows_path=`$CYGPATH -m "$unix_path"` 31888 libpath="$windows_path" 31889 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31890 windows_path=`cmd //c echo $unix_path` 31891 libpath="$windows_path" 31892 fi 31893 31894 VS_LIB="$VS_LIB;$libpath" 31895 done 31896 IFS="$OLDIFS" 31897 31898 { $as_echo "$as_me:${as_lineno-$LINENO}: Found devkit $VS_DESCRIPTION" >&5 31899 $as_echo "$as_me: Found devkit $VS_DESCRIPTION" >&6;} 31900 31901 elif test "x$with_toolchain_version" != x; then 31902 # User override; check that it is valid 31903 if test "x${VALID_VS_VERSIONS/$with_toolchain_version/}" = "x${VALID_VS_VERSIONS}"; then 31904 { $as_echo "$as_me:${as_lineno-$LINENO}: Visual Studio version $with_toolchain_version is not valid." >&5 31905 $as_echo "$as_me: Visual Studio version $with_toolchain_version is not valid." >&6;} 31906 { $as_echo "$as_me:${as_lineno-$LINENO}: Valid Visual Studio versions: $VALID_VS_VERSIONS." >&5 31907 $as_echo "$as_me: Valid Visual Studio versions: $VALID_VS_VERSIONS." >&6;} 31908 as_fn_error $? "Cannot continue." "$LINENO" 5 31909 fi 31910 VS_VERSIONS_PROBE_LIST="$with_toolchain_version" 31911 else 31912 # No flag given, use default 31913 VS_VERSIONS_PROBE_LIST="$VALID_VS_VERSIONS" 31914 fi 31915 31916 for VS_VERSION in $VS_VERSIONS_PROBE_LIST; do 31917 31918 VS_VERSION="$VS_VERSION" 31919 eval VS_COMNTOOLS_VAR="\${VS_ENVVAR_${VS_VERSION}}" 31920 eval VS_COMNTOOLS="\$${VS_COMNTOOLS_VAR}" 31921 eval VS_INSTALL_DIR="\${VS_VS_INSTALLDIR_${VS_VERSION}}" 31922 eval SDK_INSTALL_DIR="\${VS_SDK_INSTALLDIR_${VS_VERSION}}" 31923 31924 # When using --with-tools-dir, assume it points to the correct and default 31925 # version of Visual Studio or that --with-toolchain-version was also set. 31926 if test "x$with_tools_dir" != x; then 31927 31928 if test "x$VS_ENV_CMD" = x; then 31929 VS_VERSION="${VS_VERSION}" 31930 VS_BASE="$with_tools_dir/../.." 31931 METHOD="--with-tools-dir" 31932 31933 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 31934 VCVARSFILE="vc/bin/vcvars32.bat" 31935 else 31936 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 31937 fi 31938 31939 31940 windows_path="$VS_BASE" 31941 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31942 unix_path=`$CYGPATH -u "$windows_path"` 31943 VS_BASE="$unix_path" 31944 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31945 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31946 VS_BASE="$unix_path" 31947 fi 31948 31949 if test -d "$VS_BASE"; then 31950 if test -f "$VS_BASE/$VCVARSFILE"; then 31951 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31952 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31953 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 31954 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 31955 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 31956 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 31957 else 31958 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31959 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31960 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 31961 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 31962 fi 31963 fi 31964 fi 31965 31966 31967 if test "x$VS_ENV_CMD" = x; then 31968 VS_VERSION="${VS_VERSION}" 31969 VS_BASE="$with_tools_dir/../../.." 31970 METHOD="--with-tools-dir" 31971 31972 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 31973 VCVARSFILE="vc/bin/vcvars32.bat" 31974 else 31975 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 31976 fi 31977 31978 31979 windows_path="$VS_BASE" 31980 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31981 unix_path=`$CYGPATH -u "$windows_path"` 31982 VS_BASE="$unix_path" 31983 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31984 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31985 VS_BASE="$unix_path" 31986 fi 31987 31988 if test -d "$VS_BASE"; then 31989 if test -f "$VS_BASE/$VCVARSFILE"; then 31990 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31991 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31992 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 31993 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 31994 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 31995 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 31996 else 31997 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31998 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31999 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 32000 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 32001 fi 32002 fi 32003 fi 32004 32005 if test "x$VS_ENV_CMD" = x; then 32006 # Having specified an argument which is incorrect will produce an instant failure; 32007 # we should not go on looking 32008 { $as_echo "$as_me:${as_lineno-$LINENO}: The path given by --with-tools-dir does not contain a valid" >&5 32009 $as_echo "$as_me: The path given by --with-tools-dir does not contain a valid" >&6;} 32010 { $as_echo "$as_me:${as_lineno-$LINENO}: Visual Studio installation. Please point to the VC/bin or VC/bin/amd64" >&5 32011 $as_echo "$as_me: Visual Studio installation. Please point to the VC/bin or VC/bin/amd64" >&6;} 32012 { $as_echo "$as_me:${as_lineno-$LINENO}: directory within the Visual Studio installation" >&5 32013 $as_echo "$as_me: directory within the Visual Studio installation" >&6;} 32014 as_fn_error $? "Cannot locate a valid Visual Studio installation" "$LINENO" 5 32015 fi 32016 fi 32017 32018 VS_ENV_CMD="" 32019 VS_ENV_ARGS="" 32020 32021 if test "x$VS_COMNTOOLS" != x; then 32022 32023 if test "x$VS_ENV_CMD" = x; then 32024 VS_VERSION="${VS_VERSION}" 32025 VS_BASE="$VS_COMNTOOLS/../.." 32026 METHOD="$VS_COMNTOOLS_VAR variable" 32027 32028 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32029 VCVARSFILE="vc/bin/vcvars32.bat" 32030 else 32031 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 32032 fi 32033 32034 32035 windows_path="$VS_BASE" 32036 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32037 unix_path=`$CYGPATH -u "$windows_path"` 32038 VS_BASE="$unix_path" 32039 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32040 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32041 VS_BASE="$unix_path" 32042 fi 32043 32044 if test -d "$VS_BASE"; then 32045 if test -f "$VS_BASE/$VCVARSFILE"; then 32046 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32047 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32048 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 32049 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32050 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 32051 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 32052 else 32053 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32054 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32055 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 32056 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 32057 fi 32058 fi 32059 fi 32060 32061 fi 32062 if test "x$PROGRAMFILES" != x; then 32063 32064 if test "x$VS_ENV_CMD" = x; then 32065 VS_VERSION="${VS_VERSION}" 32066 VS_BASE="$PROGRAMFILES/$VS_INSTALL_DIR" 32067 METHOD="well-known name" 32068 32069 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32070 VCVARSFILE="vc/bin/vcvars32.bat" 32071 else 32072 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 32073 fi 32074 32075 32076 windows_path="$VS_BASE" 32077 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32078 unix_path=`$CYGPATH -u "$windows_path"` 32079 VS_BASE="$unix_path" 32080 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32081 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32082 VS_BASE="$unix_path" 32083 fi 32084 32085 if test -d "$VS_BASE"; then 32086 if test -f "$VS_BASE/$VCVARSFILE"; then 32087 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32088 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32089 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 32090 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32091 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 32092 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 32093 else 32094 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32095 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32096 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 32097 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 32098 fi 32099 fi 32100 fi 32101 32102 fi 32103 # Work around the insanely named ProgramFiles(x86) env variable 32104 PROGRAMFILES_X86="`env | $SED -n 's/^ProgramFiles(x86)=//p'`" 32105 if test "x$PROGRAMFILES_X86" != x; then 32106 32107 if test "x$VS_ENV_CMD" = x; then 32108 VS_VERSION="${VS_VERSION}" 32109 VS_BASE="$PROGRAMFILES_X86/$VS_INSTALL_DIR" 32110 METHOD="well-known name" 32111 32112 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32113 VCVARSFILE="vc/bin/vcvars32.bat" 32114 else 32115 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 32116 fi 32117 32118 32119 windows_path="$VS_BASE" 32120 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32121 unix_path=`$CYGPATH -u "$windows_path"` 32122 VS_BASE="$unix_path" 32123 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32124 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32125 VS_BASE="$unix_path" 32126 fi 32127 32128 if test -d "$VS_BASE"; then 32129 if test -f "$VS_BASE/$VCVARSFILE"; then 32130 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32131 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32132 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 32133 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32134 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 32135 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 32136 else 32137 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32138 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32139 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 32140 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 32141 fi 32142 fi 32143 fi 32144 32145 fi 32146 32147 if test "x$VS_ENV_CMD" = x; then 32148 VS_VERSION="${VS_VERSION}" 32149 VS_BASE="C:/Program Files/$VS_INSTALL_DIR" 32150 METHOD="well-known name" 32151 32152 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32153 VCVARSFILE="vc/bin/vcvars32.bat" 32154 else 32155 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 32156 fi 32157 32158 32159 windows_path="$VS_BASE" 32160 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32161 unix_path=`$CYGPATH -u "$windows_path"` 32162 VS_BASE="$unix_path" 32163 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32164 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32165 VS_BASE="$unix_path" 32166 fi 32167 32168 if test -d "$VS_BASE"; then 32169 if test -f "$VS_BASE/$VCVARSFILE"; then 32170 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32171 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32172 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 32173 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32174 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 32175 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 32176 else 32177 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32178 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32179 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 32180 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 32181 fi 32182 fi 32183 fi 32184 32185 32186 if test "x$VS_ENV_CMD" = x; then 32187 VS_VERSION="${VS_VERSION}" 32188 VS_BASE="C:/Program Files (x86)/$VS_INSTALL_DIR" 32189 METHOD="well-known name" 32190 32191 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32192 VCVARSFILE="vc/bin/vcvars32.bat" 32193 else 32194 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 32195 fi 32196 32197 32198 windows_path="$VS_BASE" 32199 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32200 unix_path=`$CYGPATH -u "$windows_path"` 32201 VS_BASE="$unix_path" 32202 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32203 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32204 VS_BASE="$unix_path" 32205 fi 32206 32207 if test -d "$VS_BASE"; then 32208 if test -f "$VS_BASE/$VCVARSFILE"; then 32209 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32210 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32211 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 32212 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32213 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 32214 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 32215 else 32216 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 32217 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 32218 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 32219 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 32220 fi 32221 fi 32222 fi 32223 32224 32225 if test "x$SDK_INSTALL_DIR" != x; then 32226 if test "x$ProgramW6432" != x; then 32227 32228 if test "x$VS_ENV_CMD" = x; then 32229 VS_VERSION="${VS_VERSION}" 32230 WIN_SDK_BASE="$ProgramW6432/$SDK_INSTALL_DIR" 32231 METHOD="well-known name" 32232 32233 windows_path="$WIN_SDK_BASE" 32234 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32235 unix_path=`$CYGPATH -u "$windows_path"` 32236 WIN_SDK_BASE="$unix_path" 32237 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32238 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32239 WIN_SDK_BASE="$unix_path" 32240 fi 32241 32242 if test -d "$WIN_SDK_BASE"; then 32243 # There have been cases of partial or broken SDK installations. A missing 32244 # lib dir is not going to work. 32245 if test ! -d "$WIN_SDK_BASE/lib"; then 32246 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32247 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32248 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 32249 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 32250 elif test -f "$WIN_SDK_BASE/Bin/SetEnv.Cmd"; then 32251 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32252 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32253 VS_ENV_CMD="$WIN_SDK_BASE/Bin/SetEnv.Cmd" 32254 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32255 VS_ENV_ARGS="/x86" 32256 else 32257 VS_ENV_ARGS="/x64" 32258 fi 32259 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32260 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK 32261 # TODO: improve detection for other versions of SDK 32262 eval PLATFORM_TOOLSET="\${VS_SDK_PLATFORM_NAME_${VS_VERSION}}" 32263 else 32264 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32265 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32266 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 32267 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 32268 fi 32269 fi 32270 fi 32271 32272 fi 32273 if test "x$PROGRAMW6432" != x; then 32274 32275 if test "x$VS_ENV_CMD" = x; then 32276 VS_VERSION="${VS_VERSION}" 32277 WIN_SDK_BASE="$PROGRAMW6432/$SDK_INSTALL_DIR" 32278 METHOD="well-known name" 32279 32280 windows_path="$WIN_SDK_BASE" 32281 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32282 unix_path=`$CYGPATH -u "$windows_path"` 32283 WIN_SDK_BASE="$unix_path" 32284 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32285 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32286 WIN_SDK_BASE="$unix_path" 32287 fi 32288 32289 if test -d "$WIN_SDK_BASE"; then 32290 # There have been cases of partial or broken SDK installations. A missing 32291 # lib dir is not going to work. 32292 if test ! -d "$WIN_SDK_BASE/lib"; then 32293 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32294 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32295 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 32296 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 32297 elif test -f "$WIN_SDK_BASE/Bin/SetEnv.Cmd"; then 32298 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32299 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32300 VS_ENV_CMD="$WIN_SDK_BASE/Bin/SetEnv.Cmd" 32301 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32302 VS_ENV_ARGS="/x86" 32303 else 32304 VS_ENV_ARGS="/x64" 32305 fi 32306 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32307 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK 32308 # TODO: improve detection for other versions of SDK 32309 eval PLATFORM_TOOLSET="\${VS_SDK_PLATFORM_NAME_${VS_VERSION}}" 32310 else 32311 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32312 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32313 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 32314 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 32315 fi 32316 fi 32317 fi 32318 32319 fi 32320 if test "x$PROGRAMFILES" != x; then 32321 32322 if test "x$VS_ENV_CMD" = x; then 32323 VS_VERSION="${VS_VERSION}" 32324 WIN_SDK_BASE="$PROGRAMFILES/$SDK_INSTALL_DIR" 32325 METHOD="well-known name" 32326 32327 windows_path="$WIN_SDK_BASE" 32328 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32329 unix_path=`$CYGPATH -u "$windows_path"` 32330 WIN_SDK_BASE="$unix_path" 32331 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32332 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32333 WIN_SDK_BASE="$unix_path" 32334 fi 32335 32336 if test -d "$WIN_SDK_BASE"; then 32337 # There have been cases of partial or broken SDK installations. A missing 32338 # lib dir is not going to work. 32339 if test ! -d "$WIN_SDK_BASE/lib"; then 32340 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32341 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32342 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 32343 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 32344 elif test -f "$WIN_SDK_BASE/Bin/SetEnv.Cmd"; then 32345 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32346 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32347 VS_ENV_CMD="$WIN_SDK_BASE/Bin/SetEnv.Cmd" 32348 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32349 VS_ENV_ARGS="/x86" 32350 else 32351 VS_ENV_ARGS="/x64" 32352 fi 32353 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32354 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK 32355 # TODO: improve detection for other versions of SDK 32356 eval PLATFORM_TOOLSET="\${VS_SDK_PLATFORM_NAME_${VS_VERSION}}" 32357 else 32358 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32359 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32360 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 32361 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 32362 fi 32363 fi 32364 fi 32365 32366 fi 32367 32368 if test "x$VS_ENV_CMD" = x; then 32369 VS_VERSION="${VS_VERSION}" 32370 WIN_SDK_BASE="C:/Program Files/$SDK_INSTALL_DIR" 32371 METHOD="well-known name" 32372 32373 windows_path="$WIN_SDK_BASE" 32374 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32375 unix_path=`$CYGPATH -u "$windows_path"` 32376 WIN_SDK_BASE="$unix_path" 32377 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32378 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32379 WIN_SDK_BASE="$unix_path" 32380 fi 32381 32382 if test -d "$WIN_SDK_BASE"; then 32383 # There have been cases of partial or broken SDK installations. A missing 32384 # lib dir is not going to work. 32385 if test ! -d "$WIN_SDK_BASE/lib"; then 32386 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32387 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32388 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 32389 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 32390 elif test -f "$WIN_SDK_BASE/Bin/SetEnv.Cmd"; then 32391 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32392 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32393 VS_ENV_CMD="$WIN_SDK_BASE/Bin/SetEnv.Cmd" 32394 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32395 VS_ENV_ARGS="/x86" 32396 else 32397 VS_ENV_ARGS="/x64" 32398 fi 32399 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32400 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK 32401 # TODO: improve detection for other versions of SDK 32402 eval PLATFORM_TOOLSET="\${VS_SDK_PLATFORM_NAME_${VS_VERSION}}" 32403 else 32404 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32405 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32406 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 32407 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 32408 fi 32409 fi 32410 fi 32411 32412 32413 if test "x$VS_ENV_CMD" = x; then 32414 VS_VERSION="${VS_VERSION}" 32415 WIN_SDK_BASE="C:/Program Files (x86)/$SDK_INSTALL_DIR" 32416 METHOD="well-known name" 32417 32418 windows_path="$WIN_SDK_BASE" 32419 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32420 unix_path=`$CYGPATH -u "$windows_path"` 32421 WIN_SDK_BASE="$unix_path" 32422 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32423 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32424 WIN_SDK_BASE="$unix_path" 32425 fi 32426 32427 if test -d "$WIN_SDK_BASE"; then 32428 # There have been cases of partial or broken SDK installations. A missing 32429 # lib dir is not going to work. 32430 if test ! -d "$WIN_SDK_BASE/lib"; then 32431 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32432 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32433 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 32434 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 32435 elif test -f "$WIN_SDK_BASE/Bin/SetEnv.Cmd"; then 32436 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32437 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32438 VS_ENV_CMD="$WIN_SDK_BASE/Bin/SetEnv.Cmd" 32439 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32440 VS_ENV_ARGS="/x86" 32441 else 32442 VS_ENV_ARGS="/x64" 32443 fi 32444 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32445 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK 32446 # TODO: improve detection for other versions of SDK 32447 eval PLATFORM_TOOLSET="\${VS_SDK_PLATFORM_NAME_${VS_VERSION}}" 32448 else 32449 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32450 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32451 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 32452 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 32453 fi 32454 fi 32455 fi 32456 32457 fi 32458 32459 if test "x$VS_ENV_CMD" != x; then 32460 TOOLCHAIN_VERSION=$VS_VERSION 32461 eval VS_DESCRIPTION="\${VS_DESCRIPTION_${VS_VERSION}}" 32462 eval VS_VERSION_INTERNAL="\${VS_VERSION_INTERNAL_${VS_VERSION}}" 32463 eval MSVCR_NAME="\${VS_MSVCR_${VS_VERSION}}" 32464 eval MSVCP_NAME="\${VS_MSVCP_${VS_VERSION}}" 32465 # The rest of the variables are already evaled while probing 32466 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $VS_DESCRIPTION" >&5 32467 $as_echo "$as_me: Found $VS_DESCRIPTION" >&6;} 32468 break 32469 fi 32470 done 32471 32472 32473 # If we have a devkit, skip all of the below. 32474 if test "x$DEVKIT_VS_VERSION" = x; then 32475 if test "x$VS_ENV_CMD" != x; then 32476 # We have found a Visual Studio environment on disk, let's extract variables from the vsvars bat file. 32477 32478 # Only process if variable expands to non-empty 32479 32480 if test "x$VS_ENV_CMD" != x; then 32481 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32482 32483 # First separate the path from the arguments. This will split at the first 32484 # space. 32485 complete="$VS_ENV_CMD" 32486 path="${complete%% *}" 32487 tmp="$complete EOL" 32488 arguments="${tmp#* }" 32489 32490 # Input might be given as Windows format, start by converting to 32491 # unix format. 32492 new_path=`$CYGPATH -u "$path"` 32493 32494 # Now try to locate executable using which 32495 new_path=`$WHICH "$new_path" 2> /dev/null` 32496 # bat and cmd files are not always considered executable in cygwin causing which 32497 # to not find them 32498 if test "x$new_path" = x \ 32499 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 32500 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 32501 new_path=`$CYGPATH -u "$path"` 32502 fi 32503 if test "x$new_path" = x; then 32504 # Oops. Which didn't find the executable. 32505 # The splitting of arguments from the executable at a space might have been incorrect, 32506 # since paths with space are more likely in Windows. Give it another try with the whole 32507 # argument. 32508 path="$complete" 32509 arguments="EOL" 32510 new_path=`$CYGPATH -u "$path"` 32511 new_path=`$WHICH "$new_path" 2> /dev/null` 32512 # bat and cmd files are not always considered executable in cygwin causing which 32513 # to not find them 32514 if test "x$new_path" = x \ 32515 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 32516 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 32517 new_path=`$CYGPATH -u "$path"` 32518 fi 32519 if test "x$new_path" = x; then 32520 # It's still not found. Now this is an unrecoverable error. 32521 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5 32522 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;} 32523 has_space=`$ECHO "$complete" | $GREP " "` 32524 if test "x$has_space" != x; then 32525 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 32526 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 32527 fi 32528 as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5 32529 fi 32530 fi 32531 32532 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 32533 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 32534 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 32535 # "foo.exe" is OK but "foo" is an error. 32536 # 32537 # This test is therefore slightly more accurate than "test -f" to check for file presence. 32538 # It is also a way to make sure we got the proper file name for the real test later on. 32539 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 32540 if test "x$test_shortpath" = x; then 32541 # Short path failed, file does not exist as specified. 32542 # Try adding .exe or .cmd 32543 if test -f "${new_path}.exe"; then 32544 input_to_shortpath="${new_path}.exe" 32545 elif test -f "${new_path}.cmd"; then 32546 input_to_shortpath="${new_path}.cmd" 32547 else 32548 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$new_path\", is invalid." >&5 32549 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$new_path\", is invalid." >&6;} 32550 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 32551 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 32552 as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5 32553 fi 32554 else 32555 input_to_shortpath="$new_path" 32556 fi 32557 32558 # Call helper function which possibly converts this using DOS-style short mode. 32559 # If so, the updated path is stored in $new_path. 32560 new_path="$input_to_shortpath" 32561 32562 input_path="$input_to_shortpath" 32563 # Check if we need to convert this using DOS-style short mode. If the path 32564 # contains just simple characters, use it. Otherwise (spaces, weird characters), 32565 # take no chances and rewrite it. 32566 # Note: m4 eats our [], so we need to use [ and ] instead. 32567 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 32568 if test "x$has_forbidden_chars" != x; then 32569 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 32570 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 32571 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 32572 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 32573 # Going to short mode and back again did indeed matter. Since short mode is 32574 # case insensitive, let's make it lowercase to improve readability. 32575 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 32576 # Now convert it back to Unix-style (cygpath) 32577 input_path=`$CYGPATH -u "$shortmode_path"` 32578 new_path="$input_path" 32579 fi 32580 fi 32581 32582 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 32583 if test "x$test_cygdrive_prefix" = x; then 32584 # As a simple fix, exclude /usr/bin since it's not a real path. 32585 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 32586 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 32587 # a path prefixed by /cygdrive for fixpath to work. 32588 new_path="$CYGWIN_ROOT_PATH$input_path" 32589 fi 32590 fi 32591 32592 # remove trailing .exe if any 32593 new_path="${new_path/%.exe/}" 32594 32595 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32596 32597 # First separate the path from the arguments. This will split at the first 32598 # space. 32599 complete="$VS_ENV_CMD" 32600 path="${complete%% *}" 32601 tmp="$complete EOL" 32602 arguments="${tmp#* }" 32603 32604 # Input might be given as Windows format, start by converting to 32605 # unix format. 32606 new_path="$path" 32607 32608 windows_path="$new_path" 32609 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32610 unix_path=`$CYGPATH -u "$windows_path"` 32611 new_path="$unix_path" 32612 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32613 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32614 new_path="$unix_path" 32615 fi 32616 32617 32618 # Now try to locate executable using which 32619 new_path=`$WHICH "$new_path" 2> /dev/null` 32620 32621 if test "x$new_path" = x; then 32622 # Oops. Which didn't find the executable. 32623 # The splitting of arguments from the executable at a space might have been incorrect, 32624 # since paths with space are more likely in Windows. Give it another try with the whole 32625 # argument. 32626 path="$complete" 32627 arguments="EOL" 32628 new_path="$path" 32629 32630 windows_path="$new_path" 32631 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32632 unix_path=`$CYGPATH -u "$windows_path"` 32633 new_path="$unix_path" 32634 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32635 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32636 new_path="$unix_path" 32637 fi 32638 32639 32640 new_path=`$WHICH "$new_path" 2> /dev/null` 32641 # bat and cmd files are not always considered executable in MSYS causing which 32642 # to not find them 32643 if test "x$new_path" = x \ 32644 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 32645 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 32646 new_path="$path" 32647 32648 windows_path="$new_path" 32649 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32650 unix_path=`$CYGPATH -u "$windows_path"` 32651 new_path="$unix_path" 32652 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32653 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32654 new_path="$unix_path" 32655 fi 32656 32657 fi 32658 32659 if test "x$new_path" = x; then 32660 # It's still not found. Now this is an unrecoverable error. 32661 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5 32662 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;} 32663 has_space=`$ECHO "$complete" | $GREP " "` 32664 if test "x$has_space" != x; then 32665 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 32666 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 32667 fi 32668 as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5 32669 fi 32670 fi 32671 32672 # Now new_path has a complete unix path to the binary 32673 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 32674 # Keep paths in /bin as-is, but remove trailing .exe if any 32675 new_path="${new_path/%.exe/}" 32676 # Do not save /bin paths to all_fixpath_prefixes! 32677 else 32678 # Not in mixed or Windows style, start by that. 32679 new_path=`cmd //c echo $new_path` 32680 32681 input_path="$new_path" 32682 # Check if we need to convert this using DOS-style short mode. If the path 32683 # contains just simple characters, use it. Otherwise (spaces, weird characters), 32684 # take no chances and rewrite it. 32685 # Note: m4 eats our [], so we need to use [ and ] instead. 32686 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 32687 if test "x$has_forbidden_chars" != x; then 32688 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 32689 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 32690 fi 32691 32692 # Output is in $new_path 32693 32694 windows_path="$new_path" 32695 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32696 unix_path=`$CYGPATH -u "$windows_path"` 32697 new_path="$unix_path" 32698 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32699 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32700 new_path="$unix_path" 32701 fi 32702 32703 # remove trailing .exe if any 32704 new_path="${new_path/%.exe/}" 32705 32706 # Save the first 10 bytes of this path to the storage, so fixpath can work. 32707 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 32708 fi 32709 32710 else 32711 # We're on a unix platform. Hooray! :) 32712 # First separate the path from the arguments. This will split at the first 32713 # space. 32714 complete="$VS_ENV_CMD" 32715 path="${complete%% *}" 32716 tmp="$complete EOL" 32717 arguments="${tmp#* }" 32718 32719 # Cannot rely on the command "which" here since it doesn't always work. 32720 is_absolute_path=`$ECHO "$path" | $GREP ^/` 32721 if test -z "$is_absolute_path"; then 32722 # Path to executable is not absolute. Find it. 32723 IFS_save="$IFS" 32724 IFS=: 32725 for p in $PATH; do 32726 if test -f "$p/$path" && test -x "$p/$path"; then 32727 new_path="$p/$path" 32728 break 32729 fi 32730 done 32731 IFS="$IFS_save" 32732 else 32733 # This is an absolute path, we can use it without further modifications. 32734 new_path="$path" 32735 fi 32736 32737 if test "x$new_path" = x; then 32738 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5 32739 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;} 32740 has_space=`$ECHO "$complete" | $GREP " "` 32741 if test "x$has_space" != x; then 32742 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 32743 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 32744 fi 32745 as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5 32746 fi 32747 fi 32748 32749 # Now join together the path and the arguments once again 32750 if test "x$arguments" != xEOL; then 32751 new_complete="$new_path ${arguments% *}" 32752 else 32753 new_complete="$new_path" 32754 fi 32755 32756 if test "x$complete" != "x$new_complete"; then 32757 VS_ENV_CMD="$new_complete" 32758 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting VS_ENV_CMD to \"$new_complete\"" >&5 32759 $as_echo "$as_me: Rewriting VS_ENV_CMD to \"$new_complete\"" >&6;} 32760 fi 32761 fi 32762 32763 32764 # Lets extract the variables that are set by vcvarsall.bat/vsvars32.bat/vsvars64.bat 32765 { $as_echo "$as_me:${as_lineno-$LINENO}: Trying to extract Visual Studio environment variables" >&5 32766 $as_echo "$as_me: Trying to extract Visual Studio environment variables" >&6;} 32767 32768 # We need to create a couple of temporary files. 32769 VS_ENV_TMP_DIR="$CONFIGURESUPPORT_OUTPUTDIR/vs-env" 32770 $MKDIR -p $VS_ENV_TMP_DIR 32771 32772 # Cannot use the VS10 setup script directly (since it only updates the DOS subshell environment). 32773 # Instead create a shell script which will set the relevant variables when run. 32774 WINPATH_VS_ENV_CMD="$VS_ENV_CMD" 32775 32776 unix_path="$WINPATH_VS_ENV_CMD" 32777 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32778 windows_path=`$CYGPATH -m "$unix_path"` 32779 WINPATH_VS_ENV_CMD="$windows_path" 32780 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32781 windows_path=`cmd //c echo $unix_path` 32782 WINPATH_VS_ENV_CMD="$windows_path" 32783 fi 32784 32785 WINPATH_BASH="$BASH" 32786 32787 unix_path="$WINPATH_BASH" 32788 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32789 windows_path=`$CYGPATH -m "$unix_path"` 32790 WINPATH_BASH="$windows_path" 32791 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32792 windows_path=`cmd //c echo $unix_path` 32793 WINPATH_BASH="$windows_path" 32794 fi 32795 32796 32797 # Generate a DOS batch file which runs $VS_ENV_CMD, and then creates a shell 32798 # script (executable by bash) that will setup the important variables. 32799 EXTRACT_VC_ENV_BAT_FILE="$VS_ENV_TMP_DIR/extract-vs-env.bat" 32800 $ECHO "@echo off" > $EXTRACT_VC_ENV_BAT_FILE 32801 # This will end up something like: 32802 # call C:/progra~2/micros~2.0/vc/bin/amd64/vcvars64.bat 32803 $ECHO "call $WINPATH_VS_ENV_CMD $VS_ENV_ARGS" >> $EXTRACT_VC_ENV_BAT_FILE 32804 # These will end up something like: 32805 # C:/CygWin/bin/bash -c 'echo VS_PATH=\"$PATH\" > localdevenv.sh 32806 # The trailing space for everyone except PATH is no typo, but is needed due 32807 # to trailing \ in the Windows paths. These will be stripped later. 32808 $ECHO "$WINPATH_BASH -c 'echo VS_PATH="'\"$PATH\" > set-vs-env.sh' \ 32809 >> $EXTRACT_VC_ENV_BAT_FILE 32810 $ECHO "$WINPATH_BASH -c 'echo VS_INCLUDE="'\"$INCLUDE\;$include \" >> set-vs-env.sh' \ 32811 >> $EXTRACT_VC_ENV_BAT_FILE 32812 $ECHO "$WINPATH_BASH -c 'echo VS_LIB="'\"$LIB\;$lib \" >> set-vs-env.sh' \ 32813 >> $EXTRACT_VC_ENV_BAT_FILE 32814 $ECHO "$WINPATH_BASH -c 'echo VCINSTALLDIR="'\"$VCINSTALLDIR \" >> set-vs-env.sh' \ 32815 >> $EXTRACT_VC_ENV_BAT_FILE 32816 $ECHO "$WINPATH_BASH -c 'echo WindowsSdkDir="'\"$WindowsSdkDir \" >> set-vs-env.sh' \ 32817 >> $EXTRACT_VC_ENV_BAT_FILE 32818 $ECHO "$WINPATH_BASH -c 'echo WINDOWSSDKDIR="'\"$WINDOWSSDKDIR \" >> set-vs-env.sh' \ 32819 >> $EXTRACT_VC_ENV_BAT_FILE 32820 32821 # Now execute the newly created bat file. 32822 # The | cat is to stop SetEnv.Cmd to mess with system colors on msys. 32823 # Change directory so we don't need to mess with Windows paths in redirects. 32824 cd $VS_ENV_TMP_DIR 32825 cmd /c extract-vs-env.bat | $CAT 32826 cd $CURDIR 32827 32828 if test ! -s $VS_ENV_TMP_DIR/set-vs-env.sh; then 32829 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not succesfully extract the envionment variables needed for the VS setup." >&5 32830 $as_echo "$as_me: Could not succesfully extract the envionment variables needed for the VS setup." >&6;} 32831 { $as_echo "$as_me:${as_lineno-$LINENO}: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&5 32832 $as_echo "$as_me: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&6;} 32833 { $as_echo "$as_me:${as_lineno-$LINENO}: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&5 32834 $as_echo "$as_me: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&6;} 32835 as_fn_error $? "Cannot continue" "$LINENO" 5 32836 fi 32837 32838 # Now set all paths and other env variables. This will allow the rest of 32839 # the configure script to find and run the compiler in the proper way. 32840 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting extracted environment variables" >&5 32841 $as_echo "$as_me: Setting extracted environment variables" >&6;} 32842 . $VS_ENV_TMP_DIR/set-vs-env.sh 32843 # Now we have VS_PATH, VS_INCLUDE, VS_LIB. For further checking, we 32844 # also define VCINSTALLDIR, WindowsSdkDir and WINDOWSSDKDIR. 32845 else 32846 # We did not find a vsvars bat file, let's hope we are run from a VS command prompt. 32847 { $as_echo "$as_me:${as_lineno-$LINENO}: Cannot locate a valid Visual Studio installation, checking current environment" >&5 32848 $as_echo "$as_me: Cannot locate a valid Visual Studio installation, checking current environment" >&6;} 32849 fi 32850 fi 32851 32852 # At this point, we should have correct variables in the environment, or we can't continue. 32853 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Visual Studio variables" >&5 32854 $as_echo_n "checking for Visual Studio variables... " >&6; } 32855 32856 if test "x$VCINSTALLDIR" != x || test "x$WindowsSDKDir" != x \ 32857 || test "x$WINDOWSSDKDIR" != x || test "x$DEVKIT_NAME" != x; then 32858 if test "x$VS_INCLUDE" = x || test "x$VS_LIB" = x; then 32859 { $as_echo "$as_me:${as_lineno-$LINENO}: result: present but broken" >&5 32860 $as_echo "present but broken" >&6; } 32861 as_fn_error $? "Your VC command prompt seems broken, INCLUDE and/or LIB is missing." "$LINENO" 5 32862 else 32863 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 32864 $as_echo "ok" >&6; } 32865 # Remove any trailing "\" ";" and " " from the variables. 32866 VS_INCLUDE=`$ECHO "$VS_INCLUDE" | $SED -e 's/\\\\*;* *$//'` 32867 VS_LIB=`$ECHO "$VS_LIB" | $SED 's/\\\\*;* *$//'` 32868 VCINSTALLDIR=`$ECHO "$VCINSTALLDIR" | $SED 's/\\\\* *$//'` 32869 WindowsSDKDir=`$ECHO "$WindowsSDKDir" | $SED 's/\\\\* *$//'` 32870 WINDOWSSDKDIR=`$ECHO "$WINDOWSSDKDIR" | $SED 's/\\\\* *$//'` 32871 # Remove any paths containing # (typically F#) as that messes up make. This 32872 # is needed if visual studio was installed with F# support. 32873 VS_PATH=`$ECHO "$VS_PATH" | $SED 's/[^:#]*#[^:]*://g'` 32874 32875 32876 32877 32878 32879 # Convert VS_INCLUDE into SYSROOT_CFLAGS 32880 OLDIFS="$IFS" 32881 IFS=";" 32882 for i in $VS_INCLUDE; do 32883 ipath=$i 32884 # Only process non-empty elements 32885 if test "x$ipath" != x; then 32886 IFS="$OLDIFS" 32887 # Check that directory exists before calling fixup_path 32888 testpath=$ipath 32889 32890 windows_path="$testpath" 32891 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32892 unix_path=`$CYGPATH -u "$windows_path"` 32893 testpath="$unix_path" 32894 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32895 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32896 testpath="$unix_path" 32897 fi 32898 32899 if test -d "$testpath"; then 32900 32901 # Only process if variable expands to non-empty 32902 32903 if test "x$ipath" != x; then 32904 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32905 32906 # Input might be given as Windows format, start by converting to 32907 # unix format. 32908 path="$ipath" 32909 new_path=`$CYGPATH -u "$path"` 32910 32911 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 32912 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 32913 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 32914 # "foo.exe" is OK but "foo" is an error. 32915 # 32916 # This test is therefore slightly more accurate than "test -f" to check for file precense. 32917 # It is also a way to make sure we got the proper file name for the real test later on. 32918 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 32919 if test "x$test_shortpath" = x; then 32920 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of ipath, which resolves as \"$path\", is invalid." >&5 32921 $as_echo "$as_me: The path of ipath, which resolves as \"$path\", is invalid." >&6;} 32922 as_fn_error $? "Cannot locate the the path of ipath" "$LINENO" 5 32923 fi 32924 32925 # Call helper function which possibly converts this using DOS-style short mode. 32926 # If so, the updated path is stored in $new_path. 32927 32928 input_path="$new_path" 32929 # Check if we need to convert this using DOS-style short mode. If the path 32930 # contains just simple characters, use it. Otherwise (spaces, weird characters), 32931 # take no chances and rewrite it. 32932 # Note: m4 eats our [], so we need to use [ and ] instead. 32933 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 32934 if test "x$has_forbidden_chars" != x; then 32935 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 32936 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 32937 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 32938 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 32939 # Going to short mode and back again did indeed matter. Since short mode is 32940 # case insensitive, let's make it lowercase to improve readability. 32941 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 32942 # Now convert it back to Unix-style (cygpath) 32943 input_path=`$CYGPATH -u "$shortmode_path"` 32944 new_path="$input_path" 32945 fi 32946 fi 32947 32948 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 32949 if test "x$test_cygdrive_prefix" = x; then 32950 # As a simple fix, exclude /usr/bin since it's not a real path. 32951 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 32952 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 32953 # a path prefixed by /cygdrive for fixpath to work. 32954 new_path="$CYGWIN_ROOT_PATH$input_path" 32955 fi 32956 fi 32957 32958 32959 if test "x$path" != "x$new_path"; then 32960 ipath="$new_path" 32961 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting ipath to \"$new_path\"" >&5 32962 $as_echo "$as_me: Rewriting ipath to \"$new_path\"" >&6;} 32963 fi 32964 32965 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32966 32967 path="$ipath" 32968 has_colon=`$ECHO $path | $GREP ^.:` 32969 new_path="$path" 32970 if test "x$has_colon" = x; then 32971 # Not in mixed or Windows style, start by that. 32972 new_path=`cmd //c echo $path` 32973 fi 32974 32975 32976 input_path="$new_path" 32977 # Check if we need to convert this using DOS-style short mode. If the path 32978 # contains just simple characters, use it. Otherwise (spaces, weird characters), 32979 # take no chances and rewrite it. 32980 # Note: m4 eats our [], so we need to use [ and ] instead. 32981 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 32982 if test "x$has_forbidden_chars" != x; then 32983 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 32984 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 32985 fi 32986 32987 32988 windows_path="$new_path" 32989 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32990 unix_path=`$CYGPATH -u "$windows_path"` 32991 new_path="$unix_path" 32992 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32993 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32994 new_path="$unix_path" 32995 fi 32996 32997 if test "x$path" != "x$new_path"; then 32998 ipath="$new_path" 32999 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting ipath to \"$new_path\"" >&5 33000 $as_echo "$as_me: Rewriting ipath to \"$new_path\"" >&6;} 33001 fi 33002 33003 # Save the first 10 bytes of this path to the storage, so fixpath can work. 33004 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 33005 33006 else 33007 # We're on a unix platform. Hooray! :) 33008 path="$ipath" 33009 has_space=`$ECHO "$path" | $GREP " "` 33010 if test "x$has_space" != x; then 33011 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of ipath, which resolves as \"$path\", is invalid." >&5 33012 $as_echo "$as_me: The path of ipath, which resolves as \"$path\", is invalid." >&6;} 33013 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 33014 fi 33015 33016 # Use eval to expand a potential ~ 33017 eval path="$path" 33018 if test ! -f "$path" && test ! -d "$path"; then 33019 as_fn_error $? "The path of ipath, which resolves as \"$path\", is not found." "$LINENO" 5 33020 fi 33021 33022 if test -d "$path"; then 33023 ipath="`cd "$path"; $THEPWDCMD -L`" 33024 else 33025 dir="`$DIRNAME "$path"`" 33026 base="`$BASENAME "$path"`" 33027 ipath="`cd "$dir"; $THEPWDCMD -L`/$base" 33028 fi 33029 fi 33030 fi 33031 33032 SYSROOT_CFLAGS="$SYSROOT_CFLAGS -I$ipath" 33033 fi 33034 IFS=";" 33035 fi 33036 done 33037 # Convert VS_LIB into SYSROOT_LDFLAGS 33038 for i in $VS_LIB; do 33039 libpath=$i 33040 # Only process non-empty elements 33041 if test "x$libpath" != x; then 33042 IFS="$OLDIFS" 33043 # Check that directory exists before calling fixup_path 33044 testpath=$libpath 33045 33046 windows_path="$testpath" 33047 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33048 unix_path=`$CYGPATH -u "$windows_path"` 33049 testpath="$unix_path" 33050 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33051 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33052 testpath="$unix_path" 33053 fi 33054 33055 if test -d "$testpath"; then 33056 33057 # Only process if variable expands to non-empty 33058 33059 if test "x$libpath" != x; then 33060 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33061 33062 # Input might be given as Windows format, start by converting to 33063 # unix format. 33064 path="$libpath" 33065 new_path=`$CYGPATH -u "$path"` 33066 33067 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 33068 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 33069 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 33070 # "foo.exe" is OK but "foo" is an error. 33071 # 33072 # This test is therefore slightly more accurate than "test -f" to check for file precense. 33073 # It is also a way to make sure we got the proper file name for the real test later on. 33074 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 33075 if test "x$test_shortpath" = x; then 33076 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of libpath, which resolves as \"$path\", is invalid." >&5 33077 $as_echo "$as_me: The path of libpath, which resolves as \"$path\", is invalid." >&6;} 33078 as_fn_error $? "Cannot locate the the path of libpath" "$LINENO" 5 33079 fi 33080 33081 # Call helper function which possibly converts this using DOS-style short mode. 33082 # If so, the updated path is stored in $new_path. 33083 33084 input_path="$new_path" 33085 # Check if we need to convert this using DOS-style short mode. If the path 33086 # contains just simple characters, use it. Otherwise (spaces, weird characters), 33087 # take no chances and rewrite it. 33088 # Note: m4 eats our [], so we need to use [ and ] instead. 33089 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 33090 if test "x$has_forbidden_chars" != x; then 33091 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 33092 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 33093 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 33094 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 33095 # Going to short mode and back again did indeed matter. Since short mode is 33096 # case insensitive, let's make it lowercase to improve readability. 33097 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 33098 # Now convert it back to Unix-style (cygpath) 33099 input_path=`$CYGPATH -u "$shortmode_path"` 33100 new_path="$input_path" 33101 fi 33102 fi 33103 33104 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 33105 if test "x$test_cygdrive_prefix" = x; then 33106 # As a simple fix, exclude /usr/bin since it's not a real path. 33107 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 33108 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 33109 # a path prefixed by /cygdrive for fixpath to work. 33110 new_path="$CYGWIN_ROOT_PATH$input_path" 33111 fi 33112 fi 33113 33114 33115 if test "x$path" != "x$new_path"; then 33116 libpath="$new_path" 33117 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting libpath to \"$new_path\"" >&5 33118 $as_echo "$as_me: Rewriting libpath to \"$new_path\"" >&6;} 33119 fi 33120 33121 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33122 33123 path="$libpath" 33124 has_colon=`$ECHO $path | $GREP ^.:` 33125 new_path="$path" 33126 if test "x$has_colon" = x; then 33127 # Not in mixed or Windows style, start by that. 33128 new_path=`cmd //c echo $path` 33129 fi 33130 33131 33132 input_path="$new_path" 33133 # Check if we need to convert this using DOS-style short mode. If the path 33134 # contains just simple characters, use it. Otherwise (spaces, weird characters), 33135 # take no chances and rewrite it. 33136 # Note: m4 eats our [], so we need to use [ and ] instead. 33137 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 33138 if test "x$has_forbidden_chars" != x; then 33139 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 33140 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 33141 fi 33142 33143 33144 windows_path="$new_path" 33145 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33146 unix_path=`$CYGPATH -u "$windows_path"` 33147 new_path="$unix_path" 33148 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33149 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33150 new_path="$unix_path" 33151 fi 33152 33153 if test "x$path" != "x$new_path"; then 33154 libpath="$new_path" 33155 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting libpath to \"$new_path\"" >&5 33156 $as_echo "$as_me: Rewriting libpath to \"$new_path\"" >&6;} 33157 fi 33158 33159 # Save the first 10 bytes of this path to the storage, so fixpath can work. 33160 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 33161 33162 else 33163 # We're on a unix platform. Hooray! :) 33164 path="$libpath" 33165 has_space=`$ECHO "$path" | $GREP " "` 33166 if test "x$has_space" != x; then 33167 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of libpath, which resolves as \"$path\", is invalid." >&5 33168 $as_echo "$as_me: The path of libpath, which resolves as \"$path\", is invalid." >&6;} 33169 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 33170 fi 33171 33172 # Use eval to expand a potential ~ 33173 eval path="$path" 33174 if test ! -f "$path" && test ! -d "$path"; then 33175 as_fn_error $? "The path of libpath, which resolves as \"$path\", is not found." "$LINENO" 5 33176 fi 33177 33178 if test -d "$path"; then 33179 libpath="`cd "$path"; $THEPWDCMD -L`" 33180 else 33181 dir="`$DIRNAME "$path"`" 33182 base="`$BASENAME "$path"`" 33183 libpath="`cd "$dir"; $THEPWDCMD -L`/$base" 33184 fi 33185 fi 33186 fi 33187 33188 SYSROOT_LDFLAGS="$SYSROOT_LDFLAGS -libpath:$libpath" 33189 fi 33190 IFS=";" 33191 fi 33192 done 33193 IFS="$OLDIFS" 33194 fi 33195 else 33196 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 33197 $as_echo "not found" >&6; } 33198 33199 if test "x$VS_ENV_CMD" = x; then 33200 { $as_echo "$as_me:${as_lineno-$LINENO}: Cannot locate a valid Visual Studio or Windows SDK installation on disk," >&5 33201 $as_echo "$as_me: Cannot locate a valid Visual Studio or Windows SDK installation on disk," >&6;} 33202 { $as_echo "$as_me:${as_lineno-$LINENO}: nor is this script run from a Visual Studio command prompt." >&5 33203 $as_echo "$as_me: nor is this script run from a Visual Studio command prompt." >&6;} 33204 else 33205 { $as_echo "$as_me:${as_lineno-$LINENO}: Running the extraction script failed." >&5 33206 $as_echo "$as_me: Running the extraction script failed." >&6;} 33207 fi 33208 { $as_echo "$as_me:${as_lineno-$LINENO}: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&5 33209 $as_echo "$as_me: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&6;} 33210 { $as_echo "$as_me:${as_lineno-$LINENO}: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&5 33211 $as_echo "$as_me: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&6;} 33212 as_fn_error $? "Cannot continue" "$LINENO" 5 33213 fi 33214 33215 # Reset path to VS_PATH. It will include everything that was on PATH at the time we 33216 # ran TOOLCHAIN_SETUP_VISUAL_STUDIO_ENV. 33217 PATH="$VS_PATH" 33218 # The microsoft toolchain also requires INCLUDE and LIB to be set. 33219 export INCLUDE="$VS_INCLUDE" 33220 export LIB="$VS_LIB" 33221 else 33222 if test "x$XCODE_VERSION_OUTPUT" != x; then 33223 # For Xcode, we set the Xcode version as TOOLCHAIN_VERSION 33224 TOOLCHAIN_VERSION=`$ECHO $XCODE_VERSION_OUTPUT | $CUT -f 2 -d ' '` 33225 TOOLCHAIN_DESCRIPTION="$TOOLCHAIN_DESCRIPTION from Xcode" 33226 else 33227 # Currently we do not define this for other toolchains. This might change as the need arise. 33228 TOOLCHAIN_VERSION= 33229 fi 33230 fi 33231 33232 33233 # Finally add TOOLCHAIN_PATH at the beginning, to allow --with-tools-dir to 33234 # override all other locations. 33235 if test "x$TOOLCHAIN_PATH" != x; then 33236 PATH=$TOOLCHAIN_PATH:$PATH 33237 fi 33238 33239 33240 # 33241 # Setup the compilers (CC and CXX) 33242 # 33243 33244 COMPILER_NAME=C 33245 SEARCH_LIST="$TOOLCHAIN_CC_BINARY" 33246 33247 if test "x$CC" != x; then 33248 # User has supplied compiler name already, always let that override. 33249 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied compiler CC=$CC" >&5 33250 $as_echo "$as_me: Will use user supplied compiler CC=$CC" >&6;} 33251 if test "x`basename $CC`" = "x$CC"; then 33252 # A command without a complete path is provided, search $PATH. 33253 33254 for ac_prog in $CC 33255 do 33256 # Extract the first word of "$ac_prog", so it can be a program name with args. 33257 set dummy $ac_prog; ac_word=$2 33258 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33259 $as_echo_n "checking for $ac_word... " >&6; } 33260 if ${ac_cv_path_POTENTIAL_CC+:} false; then : 33261 $as_echo_n "(cached) " >&6 33262 else 33263 case $POTENTIAL_CC in 33264 [\\/]* | ?:[\\/]*) 33265 ac_cv_path_POTENTIAL_CC="$POTENTIAL_CC" # Let the user override the test with a path. 33266 ;; 33267 *) 33268 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33269 for as_dir in $PATH 33270 do 33271 IFS=$as_save_IFS 33272 test -z "$as_dir" && as_dir=. 33273 for ac_exec_ext in '' $ac_executable_extensions; do 33274 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 33275 ac_cv_path_POTENTIAL_CC="$as_dir/$ac_word$ac_exec_ext" 33276 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 33277 break 2 33278 fi 33279 done 33280 done 33281 IFS=$as_save_IFS 33282 33283 ;; 33284 esac 33285 fi 33286 POTENTIAL_CC=$ac_cv_path_POTENTIAL_CC 33287 if test -n "$POTENTIAL_CC"; then 33288 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CC" >&5 33289 $as_echo "$POTENTIAL_CC" >&6; } 33290 else 33291 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33292 $as_echo "no" >&6; } 33293 fi 33294 33295 33296 test -n "$POTENTIAL_CC" && break 33297 done 33298 33299 if test "x$POTENTIAL_CC" != x; then 33300 CC=$POTENTIAL_CC 33301 else 33302 as_fn_error $? "User supplied compiler CC=$CC could not be found" "$LINENO" 5 33303 fi 33304 else 33305 # Otherwise it might already be a complete path 33306 if test ! -x "$CC"; then 33307 as_fn_error $? "User supplied compiler CC=$CC does not exist" "$LINENO" 5 33308 fi 33309 fi 33310 else 33311 # No user supplied value. Locate compiler ourselves. 33312 33313 # If we are cross compiling, assume cross compilation tools follows the 33314 # cross compilation standard where they are prefixed with the autoconf 33315 # standard name for the target. For example the binary 33316 # i686-sun-solaris2.10-gcc will cross compile for i686-sun-solaris2.10. 33317 # If we are not cross compiling, then the default compiler name will be 33318 # used. 33319 33320 CC= 33321 # If TOOLCHAIN_PATH is set, check for all compiler names in there first 33322 # before checking the rest of the PATH. 33323 # FIXME: Now that we prefix the TOOLS_DIR to the PATH in the PRE_DETECTION 33324 # step, this should not be necessary. 33325 if test -n "$TOOLCHAIN_PATH"; then 33326 PATH_save="$PATH" 33327 PATH="$TOOLCHAIN_PATH" 33328 if test -n "$ac_tool_prefix"; then 33329 # Extract the first word of "${ac_tool_prefix}$SEARCH_LIST", so it can be a program name with args. 33330 set dummy ${ac_tool_prefix}$SEARCH_LIST; ac_word=$2 33331 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33332 $as_echo_n "checking for $ac_word... " >&6; } 33333 if ${ac_cv_path_TOOLCHAIN_PATH_CC+:} false; then : 33334 $as_echo_n "(cached) " >&6 33335 else 33336 case $TOOLCHAIN_PATH_CC in 33337 [\\/]* | ?:[\\/]*) 33338 ac_cv_path_TOOLCHAIN_PATH_CC="$TOOLCHAIN_PATH_CC" # Let the user override the test with a path. 33339 ;; 33340 *) 33341 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33342 for as_dir in $PATH 33343 do 33344 IFS=$as_save_IFS 33345 test -z "$as_dir" && as_dir=. 33346 for ac_exec_ext in '' $ac_executable_extensions; do 33347 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 33348 ac_cv_path_TOOLCHAIN_PATH_CC="$as_dir/$ac_word$ac_exec_ext" 33349 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 33350 break 2 33351 fi 33352 done 33353 done 33354 IFS=$as_save_IFS 33355 33356 ;; 33357 esac 33358 fi 33359 TOOLCHAIN_PATH_CC=$ac_cv_path_TOOLCHAIN_PATH_CC 33360 if test -n "$TOOLCHAIN_PATH_CC"; then 33361 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLCHAIN_PATH_CC" >&5 33362 $as_echo "$TOOLCHAIN_PATH_CC" >&6; } 33363 else 33364 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33365 $as_echo "no" >&6; } 33366 fi 33367 33368 33369 fi 33370 if test -z "$ac_cv_path_TOOLCHAIN_PATH_CC"; then 33371 ac_pt_TOOLCHAIN_PATH_CC=$TOOLCHAIN_PATH_CC 33372 # Extract the first word of "$SEARCH_LIST", so it can be a program name with args. 33373 set dummy $SEARCH_LIST; ac_word=$2 33374 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33375 $as_echo_n "checking for $ac_word... " >&6; } 33376 if ${ac_cv_path_ac_pt_TOOLCHAIN_PATH_CC+:} false; then : 33377 $as_echo_n "(cached) " >&6 33378 else 33379 case $ac_pt_TOOLCHAIN_PATH_CC in 33380 [\\/]* | ?:[\\/]*) 33381 ac_cv_path_ac_pt_TOOLCHAIN_PATH_CC="$ac_pt_TOOLCHAIN_PATH_CC" # Let the user override the test with a path. 33382 ;; 33383 *) 33384 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33385 for as_dir in $PATH 33386 do 33387 IFS=$as_save_IFS 33388 test -z "$as_dir" && as_dir=. 33389 for ac_exec_ext in '' $ac_executable_extensions; do 33390 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 33391 ac_cv_path_ac_pt_TOOLCHAIN_PATH_CC="$as_dir/$ac_word$ac_exec_ext" 33392 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 33393 break 2 33394 fi 33395 done 33396 done 33397 IFS=$as_save_IFS 33398 33399 ;; 33400 esac 33401 fi 33402 ac_pt_TOOLCHAIN_PATH_CC=$ac_cv_path_ac_pt_TOOLCHAIN_PATH_CC 33403 if test -n "$ac_pt_TOOLCHAIN_PATH_CC"; then 33404 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_TOOLCHAIN_PATH_CC" >&5 33405 $as_echo "$ac_pt_TOOLCHAIN_PATH_CC" >&6; } 33406 else 33407 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33408 $as_echo "no" >&6; } 33409 fi 33410 33411 if test "x$ac_pt_TOOLCHAIN_PATH_CC" = x; then 33412 TOOLCHAIN_PATH_CC="" 33413 else 33414 case $cross_compiling:$ac_tool_warned in 33415 yes:) 33416 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 33417 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 33418 ac_tool_warned=yes ;; 33419 esac 33420 TOOLCHAIN_PATH_CC=$ac_pt_TOOLCHAIN_PATH_CC 33421 fi 33422 else 33423 TOOLCHAIN_PATH_CC="$ac_cv_path_TOOLCHAIN_PATH_CC" 33424 fi 33425 33426 CC=$TOOLCHAIN_PATH_CC 33427 PATH="$PATH_save" 33428 fi 33429 33430 # AC_PATH_TOOL can't be run multiple times with the same variable, 33431 # so create a new name for this run. 33432 if test "x$CC" = x; then 33433 if test -n "$ac_tool_prefix"; then 33434 # Extract the first word of "${ac_tool_prefix}$SEARCH_LIST", so it can be a program name with args. 33435 set dummy ${ac_tool_prefix}$SEARCH_LIST; ac_word=$2 33436 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33437 $as_echo_n "checking for $ac_word... " >&6; } 33438 if ${ac_cv_path_POTENTIAL_CC+:} false; then : 33439 $as_echo_n "(cached) " >&6 33440 else 33441 case $POTENTIAL_CC in 33442 [\\/]* | ?:[\\/]*) 33443 ac_cv_path_POTENTIAL_CC="$POTENTIAL_CC" # Let the user override the test with a path. 33444 ;; 33445 *) 33446 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33447 for as_dir in $PATH 33448 do 33449 IFS=$as_save_IFS 33450 test -z "$as_dir" && as_dir=. 33451 for ac_exec_ext in '' $ac_executable_extensions; do 33452 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 33453 ac_cv_path_POTENTIAL_CC="$as_dir/$ac_word$ac_exec_ext" 33454 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 33455 break 2 33456 fi 33457 done 33458 done 33459 IFS=$as_save_IFS 33460 33461 ;; 33462 esac 33463 fi 33464 POTENTIAL_CC=$ac_cv_path_POTENTIAL_CC 33465 if test -n "$POTENTIAL_CC"; then 33466 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CC" >&5 33467 $as_echo "$POTENTIAL_CC" >&6; } 33468 else 33469 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33470 $as_echo "no" >&6; } 33471 fi 33472 33473 33474 fi 33475 if test -z "$ac_cv_path_POTENTIAL_CC"; then 33476 ac_pt_POTENTIAL_CC=$POTENTIAL_CC 33477 # Extract the first word of "$SEARCH_LIST", so it can be a program name with args. 33478 set dummy $SEARCH_LIST; ac_word=$2 33479 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33480 $as_echo_n "checking for $ac_word... " >&6; } 33481 if ${ac_cv_path_ac_pt_POTENTIAL_CC+:} false; then : 33482 $as_echo_n "(cached) " >&6 33483 else 33484 case $ac_pt_POTENTIAL_CC in 33485 [\\/]* | ?:[\\/]*) 33486 ac_cv_path_ac_pt_POTENTIAL_CC="$ac_pt_POTENTIAL_CC" # Let the user override the test with a path. 33487 ;; 33488 *) 33489 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33490 for as_dir in $PATH 33491 do 33492 IFS=$as_save_IFS 33493 test -z "$as_dir" && as_dir=. 33494 for ac_exec_ext in '' $ac_executable_extensions; do 33495 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 33496 ac_cv_path_ac_pt_POTENTIAL_CC="$as_dir/$ac_word$ac_exec_ext" 33497 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 33498 break 2 33499 fi 33500 done 33501 done 33502 IFS=$as_save_IFS 33503 33504 ;; 33505 esac 33506 fi 33507 ac_pt_POTENTIAL_CC=$ac_cv_path_ac_pt_POTENTIAL_CC 33508 if test -n "$ac_pt_POTENTIAL_CC"; then 33509 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_POTENTIAL_CC" >&5 33510 $as_echo "$ac_pt_POTENTIAL_CC" >&6; } 33511 else 33512 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33513 $as_echo "no" >&6; } 33514 fi 33515 33516 if test "x$ac_pt_POTENTIAL_CC" = x; then 33517 POTENTIAL_CC="" 33518 else 33519 case $cross_compiling:$ac_tool_warned in 33520 yes:) 33521 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 33522 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 33523 ac_tool_warned=yes ;; 33524 esac 33525 POTENTIAL_CC=$ac_pt_POTENTIAL_CC 33526 fi 33527 else 33528 POTENTIAL_CC="$ac_cv_path_POTENTIAL_CC" 33529 fi 33530 33531 CC=$POTENTIAL_CC 33532 fi 33533 33534 if test "x$CC" = x; then 33535 33536 # Print a helpful message on how to acquire the necessary build dependency. 33537 # devkit is the help tag: freetype, cups, alsa etc 33538 MISSING_DEPENDENCY=devkit 33539 33540 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33541 cygwin_help $MISSING_DEPENDENCY 33542 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33543 msys_help $MISSING_DEPENDENCY 33544 else 33545 PKGHANDLER_COMMAND= 33546 33547 case $PKGHANDLER in 33548 apt-get) 33549 apt_help $MISSING_DEPENDENCY ;; 33550 yum) 33551 yum_help $MISSING_DEPENDENCY ;; 33552 brew) 33553 brew_help $MISSING_DEPENDENCY ;; 33554 port) 33555 port_help $MISSING_DEPENDENCY ;; 33556 pkgutil) 33557 pkgutil_help $MISSING_DEPENDENCY ;; 33558 pkgadd) 33559 pkgadd_help $MISSING_DEPENDENCY ;; 33560 esac 33561 33562 if test "x$PKGHANDLER_COMMAND" != x; then 33563 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 33564 fi 33565 fi 33566 33567 as_fn_error $? "Could not find a $COMPILER_NAME compiler. $HELP_MSG" "$LINENO" 5 33568 fi 33569 fi 33570 33571 # Now we have a compiler binary in CC. Make sure it's okay. 33572 33573 # Only process if variable expands to non-empty 33574 33575 if test "x$CC" != x; then 33576 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33577 33578 # First separate the path from the arguments. This will split at the first 33579 # space. 33580 complete="$CC" 33581 path="${complete%% *}" 33582 tmp="$complete EOL" 33583 arguments="${tmp#* }" 33584 33585 # Input might be given as Windows format, start by converting to 33586 # unix format. 33587 new_path=`$CYGPATH -u "$path"` 33588 33589 # Now try to locate executable using which 33590 new_path=`$WHICH "$new_path" 2> /dev/null` 33591 # bat and cmd files are not always considered executable in cygwin causing which 33592 # to not find them 33593 if test "x$new_path" = x \ 33594 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 33595 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 33596 new_path=`$CYGPATH -u "$path"` 33597 fi 33598 if test "x$new_path" = x; then 33599 # Oops. Which didn't find the executable. 33600 # The splitting of arguments from the executable at a space might have been incorrect, 33601 # since paths with space are more likely in Windows. Give it another try with the whole 33602 # argument. 33603 path="$complete" 33604 arguments="EOL" 33605 new_path=`$CYGPATH -u "$path"` 33606 new_path=`$WHICH "$new_path" 2> /dev/null` 33607 # bat and cmd files are not always considered executable in cygwin causing which 33608 # to not find them 33609 if test "x$new_path" = x \ 33610 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 33611 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 33612 new_path=`$CYGPATH -u "$path"` 33613 fi 33614 if test "x$new_path" = x; then 33615 # It's still not found. Now this is an unrecoverable error. 33616 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5 33617 $as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;} 33618 has_space=`$ECHO "$complete" | $GREP " "` 33619 if test "x$has_space" != x; then 33620 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 33621 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 33622 fi 33623 as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5 33624 fi 33625 fi 33626 33627 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 33628 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 33629 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 33630 # "foo.exe" is OK but "foo" is an error. 33631 # 33632 # This test is therefore slightly more accurate than "test -f" to check for file presence. 33633 # It is also a way to make sure we got the proper file name for the real test later on. 33634 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 33635 if test "x$test_shortpath" = x; then 33636 # Short path failed, file does not exist as specified. 33637 # Try adding .exe or .cmd 33638 if test -f "${new_path}.exe"; then 33639 input_to_shortpath="${new_path}.exe" 33640 elif test -f "${new_path}.cmd"; then 33641 input_to_shortpath="${new_path}.cmd" 33642 else 33643 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$new_path\", is invalid." >&5 33644 $as_echo "$as_me: The path of CC, which resolves as \"$new_path\", is invalid." >&6;} 33645 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 33646 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 33647 as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5 33648 fi 33649 else 33650 input_to_shortpath="$new_path" 33651 fi 33652 33653 # Call helper function which possibly converts this using DOS-style short mode. 33654 # If so, the updated path is stored in $new_path. 33655 new_path="$input_to_shortpath" 33656 33657 input_path="$input_to_shortpath" 33658 # Check if we need to convert this using DOS-style short mode. If the path 33659 # contains just simple characters, use it. Otherwise (spaces, weird characters), 33660 # take no chances and rewrite it. 33661 # Note: m4 eats our [], so we need to use [ and ] instead. 33662 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 33663 if test "x$has_forbidden_chars" != x; then 33664 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 33665 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 33666 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 33667 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 33668 # Going to short mode and back again did indeed matter. Since short mode is 33669 # case insensitive, let's make it lowercase to improve readability. 33670 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 33671 # Now convert it back to Unix-style (cygpath) 33672 input_path=`$CYGPATH -u "$shortmode_path"` 33673 new_path="$input_path" 33674 fi 33675 fi 33676 33677 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 33678 if test "x$test_cygdrive_prefix" = x; then 33679 # As a simple fix, exclude /usr/bin since it's not a real path. 33680 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 33681 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 33682 # a path prefixed by /cygdrive for fixpath to work. 33683 new_path="$CYGWIN_ROOT_PATH$input_path" 33684 fi 33685 fi 33686 33687 # remove trailing .exe if any 33688 new_path="${new_path/%.exe/}" 33689 33690 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33691 33692 # First separate the path from the arguments. This will split at the first 33693 # space. 33694 complete="$CC" 33695 path="${complete%% *}" 33696 tmp="$complete EOL" 33697 arguments="${tmp#* }" 33698 33699 # Input might be given as Windows format, start by converting to 33700 # unix format. 33701 new_path="$path" 33702 33703 windows_path="$new_path" 33704 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33705 unix_path=`$CYGPATH -u "$windows_path"` 33706 new_path="$unix_path" 33707 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33708 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33709 new_path="$unix_path" 33710 fi 33711 33712 33713 # Now try to locate executable using which 33714 new_path=`$WHICH "$new_path" 2> /dev/null` 33715 33716 if test "x$new_path" = x; then 33717 # Oops. Which didn't find the executable. 33718 # The splitting of arguments from the executable at a space might have been incorrect, 33719 # since paths with space are more likely in Windows. Give it another try with the whole 33720 # argument. 33721 path="$complete" 33722 arguments="EOL" 33723 new_path="$path" 33724 33725 windows_path="$new_path" 33726 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33727 unix_path=`$CYGPATH -u "$windows_path"` 33728 new_path="$unix_path" 33729 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33730 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33731 new_path="$unix_path" 33732 fi 33733 33734 33735 new_path=`$WHICH "$new_path" 2> /dev/null` 33736 # bat and cmd files are not always considered executable in MSYS causing which 33737 # to not find them 33738 if test "x$new_path" = x \ 33739 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 33740 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 33741 new_path="$path" 33742 33743 windows_path="$new_path" 33744 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33745 unix_path=`$CYGPATH -u "$windows_path"` 33746 new_path="$unix_path" 33747 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33748 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33749 new_path="$unix_path" 33750 fi 33751 33752 fi 33753 33754 if test "x$new_path" = x; then 33755 # It's still not found. Now this is an unrecoverable error. 33756 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5 33757 $as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;} 33758 has_space=`$ECHO "$complete" | $GREP " "` 33759 if test "x$has_space" != x; then 33760 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 33761 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 33762 fi 33763 as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5 33764 fi 33765 fi 33766 33767 # Now new_path has a complete unix path to the binary 33768 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 33769 # Keep paths in /bin as-is, but remove trailing .exe if any 33770 new_path="${new_path/%.exe/}" 33771 # Do not save /bin paths to all_fixpath_prefixes! 33772 else 33773 # Not in mixed or Windows style, start by that. 33774 new_path=`cmd //c echo $new_path` 33775 33776 input_path="$new_path" 33777 # Check if we need to convert this using DOS-style short mode. If the path 33778 # contains just simple characters, use it. Otherwise (spaces, weird characters), 33779 # take no chances and rewrite it. 33780 # Note: m4 eats our [], so we need to use [ and ] instead. 33781 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 33782 if test "x$has_forbidden_chars" != x; then 33783 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 33784 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 33785 fi 33786 33787 # Output is in $new_path 33788 33789 windows_path="$new_path" 33790 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33791 unix_path=`$CYGPATH -u "$windows_path"` 33792 new_path="$unix_path" 33793 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33794 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33795 new_path="$unix_path" 33796 fi 33797 33798 # remove trailing .exe if any 33799 new_path="${new_path/%.exe/}" 33800 33801 # Save the first 10 bytes of this path to the storage, so fixpath can work. 33802 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 33803 fi 33804 33805 else 33806 # We're on a unix platform. Hooray! :) 33807 # First separate the path from the arguments. This will split at the first 33808 # space. 33809 complete="$CC" 33810 path="${complete%% *}" 33811 tmp="$complete EOL" 33812 arguments="${tmp#* }" 33813 33814 # Cannot rely on the command "which" here since it doesn't always work. 33815 is_absolute_path=`$ECHO "$path" | $GREP ^/` 33816 if test -z "$is_absolute_path"; then 33817 # Path to executable is not absolute. Find it. 33818 IFS_save="$IFS" 33819 IFS=: 33820 for p in $PATH; do 33821 if test -f "$p/$path" && test -x "$p/$path"; then 33822 new_path="$p/$path" 33823 break 33824 fi 33825 done 33826 IFS="$IFS_save" 33827 else 33828 # This is an absolute path, we can use it without further modifications. 33829 new_path="$path" 33830 fi 33831 33832 if test "x$new_path" = x; then 33833 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5 33834 $as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;} 33835 has_space=`$ECHO "$complete" | $GREP " "` 33836 if test "x$has_space" != x; then 33837 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 33838 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 33839 fi 33840 as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5 33841 fi 33842 fi 33843 33844 # Now join together the path and the arguments once again 33845 if test "x$arguments" != xEOL; then 33846 new_complete="$new_path ${arguments% *}" 33847 else 33848 new_complete="$new_path" 33849 fi 33850 33851 if test "x$complete" != "x$new_complete"; then 33852 CC="$new_complete" 33853 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CC to \"$new_complete\"" >&5 33854 $as_echo "$as_me: Rewriting CC to \"$new_complete\"" >&6;} 33855 fi 33856 fi 33857 33858 TEST_COMPILER="$CC" 33859 33860 { $as_echo "$as_me:${as_lineno-$LINENO}: checking resolved symbolic links for CC" >&5 33861 $as_echo_n "checking resolved symbolic links for CC... " >&6; } 33862 SYMLINK_ORIGINAL="$TEST_COMPILER" 33863 33864 if test "x$OPENJDK_BUILD_OS" != xwindows; then 33865 # Follow a chain of symbolic links. Use readlink 33866 # where it exists, else fall back to horribly 33867 # complicated shell code. 33868 if test "x$READLINK_TESTED" != yes; then 33869 # On MacOSX there is a readlink tool with a different 33870 # purpose than the GNU readlink tool. Check the found readlink. 33871 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 33872 if test "x$ISGNU" = x; then 33873 # A readlink that we do not know how to use. 33874 # Are there other non-GNU readlinks out there? 33875 READLINK_TESTED=yes 33876 READLINK= 33877 fi 33878 fi 33879 33880 if test "x$READLINK" != x; then 33881 SYMLINK_ORIGINAL=`$READLINK -f $SYMLINK_ORIGINAL` 33882 else 33883 # Save the current directory for restoring afterwards 33884 STARTDIR=$PWD 33885 COUNTER=0 33886 sym_link_dir=`$DIRNAME $SYMLINK_ORIGINAL` 33887 sym_link_file=`$BASENAME $SYMLINK_ORIGINAL` 33888 cd $sym_link_dir 33889 # Use -P flag to resolve symlinks in directories. 33890 cd `$THEPWDCMD -P` 33891 sym_link_dir=`$THEPWDCMD -P` 33892 # Resolve file symlinks 33893 while test $COUNTER -lt 20; do 33894 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 33895 if test "x$ISLINK" == x; then 33896 # This is not a symbolic link! We are done! 33897 break 33898 fi 33899 # Again resolve directory symlinks since the target of the just found 33900 # link could be in a different directory 33901 cd `$DIRNAME $ISLINK` 33902 sym_link_dir=`$THEPWDCMD -P` 33903 sym_link_file=`$BASENAME $ISLINK` 33904 let COUNTER=COUNTER+1 33905 done 33906 cd $STARTDIR 33907 SYMLINK_ORIGINAL=$sym_link_dir/$sym_link_file 33908 fi 33909 fi 33910 33911 if test "x$TEST_COMPILER" = "x$SYMLINK_ORIGINAL"; then 33912 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no symlink" >&5 33913 $as_echo "no symlink" >&6; } 33914 else 33915 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SYMLINK_ORIGINAL" >&5 33916 $as_echo "$SYMLINK_ORIGINAL" >&6; } 33917 33918 # We can't handle ccache by gcc wrappers, since we need to know if we're 33919 # using ccache. Instead ccache usage must be controlled by a configure option. 33920 COMPILER_BASENAME=`$BASENAME "$SYMLINK_ORIGINAL"` 33921 if test "x$COMPILER_BASENAME" = "xccache"; then 33922 { $as_echo "$as_me:${as_lineno-$LINENO}: Please use --enable-ccache instead of providing a wrapped compiler." >&5 33923 $as_echo "$as_me: Please use --enable-ccache instead of providing a wrapped compiler." >&6;} 33924 as_fn_error $? "$TEST_COMPILER is a symbolic link to ccache. This is not supported." "$LINENO" 5 33925 fi 33926 fi 33927 33928 33929 COMPILER=$CC 33930 COMPILER_NAME=$COMPILER_NAME 33931 33932 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 33933 # cc -V output typically looks like 33934 # cc: Sun C 5.12 Linux_i386 2011/11/16 33935 # or 33936 # cc: Studio 12.5 Sun C 5.14 SunOS_sparc 2016/05/31 33937 COMPILER_VERSION_OUTPUT=`$COMPILER -V 2>&1` 33938 # Check that this is likely to be the Solaris Studio cc. 33939 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "^.* Sun $COMPILER_NAME" > /dev/null 33940 if test $? -ne 0; then 33941 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 33942 { $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 33943 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 33944 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&5 33945 $as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 33946 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 33947 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 33948 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 33949 fi 33950 # Remove usage instructions (if present), and 33951 # collapse compiler output into a single line 33952 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 33953 $SED -e 's/ *[Uu]sage:.*//'` 33954 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 33955 $SED -e "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/"` 33956 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 33957 # xlc -qversion output typically looks like 33958 # IBM XL C/C++ for AIX, V11.1 (5724-X13) 33959 # Version: 11.01.0000.0015 33960 COMPILER_VERSION_OUTPUT=`$COMPILER -qversion 2>&1` 33961 # Check that this is likely to be the IBM XL C compiler. 33962 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "IBM XL C" > /dev/null 33963 if test $? -ne 0; then 33964 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 33965 { $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 33966 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 33967 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&5 33968 $as_echo "$as_me: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 33969 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 33970 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 33971 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 33972 fi 33973 # Collapse compiler output into a single line 33974 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 33975 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 33976 $SED -e 's/^.*, V\([1-9][0-9.]*\).*$/\1/'` 33977 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 33978 # There is no specific version flag, but all output starts with a version string. 33979 # First line typically looks something like: 33980 # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86 33981 COMPILER_VERSION_OUTPUT=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'` 33982 # Check that this is likely to be Microsoft CL.EXE. 33983 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Microsoft.*Compiler" > /dev/null 33984 if test $? -ne 0; then 33985 { $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 33986 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 33987 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&5 33988 $as_echo "$as_me: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 33989 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 33990 fi 33991 # Collapse compiler output into a single line 33992 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 33993 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 33994 $SED -e 's/^.*ersion.\([1-9][0-9.]*\) .*$/\1/'` 33995 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 33996 # gcc --version output typically looks like 33997 # gcc (Ubuntu/Linaro 4.8.1-10ubuntu9) 4.8.1 33998 # Copyright (C) 2013 Free Software Foundation, Inc. 33999 # This is free software; see the source for copying conditions. There is NO 34000 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 34001 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 34002 # Check that this is likely to be GCC. 34003 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Free Software Foundation" > /dev/null 34004 if test $? -ne 0; then 34005 { $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 34006 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 34007 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION\"" >&5 34008 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION\"" >&6;} 34009 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 34010 fi 34011 # Remove Copyright and legalese from version string, and 34012 # collapse into a single line 34013 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34014 $SED -e 's/ *Copyright .*//'` 34015 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34016 $SED -e 's/^.* \([1-9]\.[0-9.]*\)[^0-9.].*$/\1/'` 34017 elif test "x$TOOLCHAIN_TYPE" = xclang; then 34018 # clang --version output typically looks like 34019 # Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn) 34020 # clang version 3.3 (tags/RELEASE_33/final) 34021 # or 34022 # Debian clang version 3.2-7ubuntu1 (tags/RELEASE_32/final) (based on LLVM 3.2) 34023 # Target: x86_64-pc-linux-gnu 34024 # Thread model: posix 34025 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 34026 # Check that this is likely to be clang 34027 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "clang" > /dev/null 34028 if test $? -ne 0; then 34029 { $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 34030 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 34031 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&5 34032 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 34033 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 34034 fi 34035 # Collapse compiler output into a single line 34036 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 34037 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34038 $SED -e 's/^.* version \([1-9][0-9.]*\).*$/\1/'` 34039 else 34040 as_fn_error $? "Unknown toolchain type $TOOLCHAIN_TYPE." "$LINENO" 5 34041 fi 34042 # This sets CC_VERSION_NUMBER or CXX_VERSION_NUMBER. (This comment is a grep marker) 34043 CC_VERSION_NUMBER="$COMPILER_VERSION_NUMBER" 34044 # This sets CC_VERSION_STRING or CXX_VERSION_STRING. (This comment is a grep marker) 34045 CC_VERSION_STRING="$COMPILER_VERSION_STRING" 34046 34047 { $as_echo "$as_me:${as_lineno-$LINENO}: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&5 34048 $as_echo "$as_me: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&6;} 34049 34050 34051 # Now that we have resolved CC ourself, let autoconf have its go at it 34052 ac_ext=c 34053 ac_cpp='$CPP $CPPFLAGS' 34054 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 34055 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 34056 ac_compiler_gnu=$ac_cv_c_compiler_gnu 34057 if test -n "$ac_tool_prefix"; then 34058 for ac_prog in $CC 34059 do 34060 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 34061 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 34062 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 34063 $as_echo_n "checking for $ac_word... " >&6; } 34064 if ${ac_cv_prog_CC+:} false; then : 34065 $as_echo_n "(cached) " >&6 34066 else 34067 if test -n "$CC"; then 34068 ac_cv_prog_CC="$CC" # Let the user override the test. 34069 else 34070 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 34071 for as_dir in $PATH 34072 do 34073 IFS=$as_save_IFS 34074 test -z "$as_dir" && as_dir=. 34075 for ac_exec_ext in '' $ac_executable_extensions; do 34076 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 34077 ac_cv_prog_CC="$ac_tool_prefix$ac_prog" 34078 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 34079 break 2 34080 fi 34081 done 34082 done 34083 IFS=$as_save_IFS 34084 34085 fi 34086 fi 34087 CC=$ac_cv_prog_CC 34088 if test -n "$CC"; then 34089 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 34090 $as_echo "$CC" >&6; } 34091 else 34092 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 34093 $as_echo "no" >&6; } 34094 fi 34095 34096 34097 test -n "$CC" && break 34098 done 34099 fi 34100 if test -z "$CC"; then 34101 ac_ct_CC=$CC 34102 for ac_prog in $CC 34103 do 34104 # Extract the first word of "$ac_prog", so it can be a program name with args. 34105 set dummy $ac_prog; ac_word=$2 34106 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 34107 $as_echo_n "checking for $ac_word... " >&6; } 34108 if ${ac_cv_prog_ac_ct_CC+:} false; then : 34109 $as_echo_n "(cached) " >&6 34110 else 34111 if test -n "$ac_ct_CC"; then 34112 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. 34113 else 34114 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 34115 for as_dir in $PATH 34116 do 34117 IFS=$as_save_IFS 34118 test -z "$as_dir" && as_dir=. 34119 for ac_exec_ext in '' $ac_executable_extensions; do 34120 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 34121 ac_cv_prog_ac_ct_CC="$ac_prog" 34122 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 34123 break 2 34124 fi 34125 done 34126 done 34127 IFS=$as_save_IFS 34128 34129 fi 34130 fi 34131 ac_ct_CC=$ac_cv_prog_ac_ct_CC 34132 if test -n "$ac_ct_CC"; then 34133 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 34134 $as_echo "$ac_ct_CC" >&6; } 34135 else 34136 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 34137 $as_echo "no" >&6; } 34138 fi 34139 34140 34141 test -n "$ac_ct_CC" && break 34142 done 34143 34144 if test "x$ac_ct_CC" = x; then 34145 CC="" 34146 else 34147 case $cross_compiling:$ac_tool_warned in 34148 yes:) 34149 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 34150 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 34151 ac_tool_warned=yes ;; 34152 esac 34153 CC=$ac_ct_CC 34154 fi 34155 fi 34156 34157 34158 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 34159 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 34160 as_fn_error $? "no acceptable C compiler found in \$PATH 34161 See \`config.log' for more details" "$LINENO" 5; } 34162 34163 # Provide some information about the compiler. 34164 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 34165 set X $ac_compile 34166 ac_compiler=$2 34167 for ac_option in --version -v -V -qversion; do 34168 { { ac_try="$ac_compiler $ac_option >&5" 34169 case "(($ac_try" in 34170 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 34171 *) ac_try_echo=$ac_try;; 34172 esac 34173 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 34174 $as_echo "$ac_try_echo"; } >&5 34175 (eval "$ac_compiler $ac_option >&5") 2>conftest.err 34176 ac_status=$? 34177 if test -s conftest.err; then 34178 sed '10a\ 34179 ... rest of stderr output deleted ... 34180 10q' conftest.err >conftest.er1 34181 cat conftest.er1 >&5 34182 fi 34183 rm -f conftest.er1 conftest.err 34184 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 34185 test $ac_status = 0; } 34186 done 34187 34188 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34189 /* end confdefs.h. */ 34190 34191 int 34192 main () 34193 { 34194 34195 ; 34196 return 0; 34197 } 34198 _ACEOF 34199 ac_clean_files_save=$ac_clean_files 34200 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" 34201 # Try to create an executable without -o first, disregard a.out. 34202 # It will help us diagnose broken compilers, and finding out an intuition 34203 # of exeext. 34204 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 34205 $as_echo_n "checking whether the C compiler works... " >&6; } 34206 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` 34207 34208 # The possible output files: 34209 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" 34210 34211 ac_rmfiles= 34212 for ac_file in $ac_files 34213 do 34214 case $ac_file in 34215 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; 34216 * ) ac_rmfiles="$ac_rmfiles $ac_file";; 34217 esac 34218 done 34219 rm -f $ac_rmfiles 34220 34221 if { { ac_try="$ac_link_default" 34222 case "(($ac_try" in 34223 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 34224 *) ac_try_echo=$ac_try;; 34225 esac 34226 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 34227 $as_echo "$ac_try_echo"; } >&5 34228 (eval "$ac_link_default") 2>&5 34229 ac_status=$? 34230 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 34231 test $ac_status = 0; }; then : 34232 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. 34233 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no' 34234 # in a Makefile. We should not override ac_cv_exeext if it was cached, 34235 # so that the user can short-circuit this test for compilers unknown to 34236 # Autoconf. 34237 for ac_file in $ac_files '' 34238 do 34239 test -f "$ac_file" || continue 34240 case $ac_file in 34241 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) 34242 ;; 34243 [ab].out ) 34244 # We found the default executable, but exeext='' is most 34245 # certainly right. 34246 break;; 34247 *.* ) 34248 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; 34249 then :; else 34250 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` 34251 fi 34252 # We set ac_cv_exeext here because the later test for it is not 34253 # safe: cross compilers may not add the suffix if given an `-o' 34254 # argument, so we may need to know it at that point already. 34255 # Even if this section looks crufty: it has the advantage of 34256 # actually working. 34257 break;; 34258 * ) 34259 break;; 34260 esac 34261 done 34262 test "$ac_cv_exeext" = no && ac_cv_exeext= 34263 34264 else 34265 ac_file='' 34266 fi 34267 if test -z "$ac_file"; then : 34268 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 34269 $as_echo "no" >&6; } 34270 $as_echo "$as_me: failed program was:" >&5 34271 sed 's/^/| /' conftest.$ac_ext >&5 34272 34273 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 34274 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 34275 as_fn_error 77 "C compiler cannot create executables 34276 See \`config.log' for more details" "$LINENO" 5; } 34277 else 34278 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 34279 $as_echo "yes" >&6; } 34280 fi 34281 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 34282 $as_echo_n "checking for C compiler default output file name... " >&6; } 34283 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 34284 $as_echo "$ac_file" >&6; } 34285 ac_exeext=$ac_cv_exeext 34286 34287 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out 34288 ac_clean_files=$ac_clean_files_save 34289 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 34290 $as_echo_n "checking for suffix of executables... " >&6; } 34291 if { { ac_try="$ac_link" 34292 case "(($ac_try" in 34293 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 34294 *) ac_try_echo=$ac_try;; 34295 esac 34296 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 34297 $as_echo "$ac_try_echo"; } >&5 34298 (eval "$ac_link") 2>&5 34299 ac_status=$? 34300 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 34301 test $ac_status = 0; }; then : 34302 # If both `conftest.exe' and `conftest' are `present' (well, observable) 34303 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will 34304 # work properly (i.e., refer to `conftest.exe'), while it won't with 34305 # `rm'. 34306 for ac_file in conftest.exe conftest conftest.*; do 34307 test -f "$ac_file" || continue 34308 case $ac_file in 34309 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; 34310 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` 34311 break;; 34312 * ) break;; 34313 esac 34314 done 34315 else 34316 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 34317 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 34318 as_fn_error $? "cannot compute suffix of executables: cannot compile and link 34319 See \`config.log' for more details" "$LINENO" 5; } 34320 fi 34321 rm -f conftest conftest$ac_cv_exeext 34322 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 34323 $as_echo "$ac_cv_exeext" >&6; } 34324 34325 rm -f conftest.$ac_ext 34326 EXEEXT=$ac_cv_exeext 34327 ac_exeext=$EXEEXT 34328 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34329 /* end confdefs.h. */ 34330 #include <stdio.h> 34331 int 34332 main () 34333 { 34334 FILE *f = fopen ("conftest.out", "w"); 34335 return ferror (f) || fclose (f) != 0; 34336 34337 ; 34338 return 0; 34339 } 34340 _ACEOF 34341 ac_clean_files="$ac_clean_files conftest.out" 34342 # Check that the compiler produces executables we can run. If not, either 34343 # the compiler is broken, or we cross compile. 34344 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 34345 $as_echo_n "checking whether we are cross compiling... " >&6; } 34346 if test "$cross_compiling" != yes; then 34347 { { ac_try="$ac_link" 34348 case "(($ac_try" in 34349 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 34350 *) ac_try_echo=$ac_try;; 34351 esac 34352 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 34353 $as_echo "$ac_try_echo"; } >&5 34354 (eval "$ac_link") 2>&5 34355 ac_status=$? 34356 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 34357 test $ac_status = 0; } 34358 if { ac_try='./conftest$ac_cv_exeext' 34359 { { case "(($ac_try" in 34360 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 34361 *) ac_try_echo=$ac_try;; 34362 esac 34363 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 34364 $as_echo "$ac_try_echo"; } >&5 34365 (eval "$ac_try") 2>&5 34366 ac_status=$? 34367 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 34368 test $ac_status = 0; }; }; then 34369 cross_compiling=no 34370 else 34371 if test "$cross_compiling" = maybe; then 34372 cross_compiling=yes 34373 else 34374 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 34375 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 34376 as_fn_error $? "cannot run C compiled programs. 34377 If you meant to cross compile, use \`--host'. 34378 See \`config.log' for more details" "$LINENO" 5; } 34379 fi 34380 fi 34381 fi 34382 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 34383 $as_echo "$cross_compiling" >&6; } 34384 34385 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out 34386 ac_clean_files=$ac_clean_files_save 34387 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 34388 $as_echo_n "checking for suffix of object files... " >&6; } 34389 if ${ac_cv_objext+:} false; then : 34390 $as_echo_n "(cached) " >&6 34391 else 34392 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34393 /* end confdefs.h. */ 34394 34395 int 34396 main () 34397 { 34398 34399 ; 34400 return 0; 34401 } 34402 _ACEOF 34403 rm -f conftest.o conftest.obj 34404 if { { ac_try="$ac_compile" 34405 case "(($ac_try" in 34406 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 34407 *) ac_try_echo=$ac_try;; 34408 esac 34409 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 34410 $as_echo "$ac_try_echo"; } >&5 34411 (eval "$ac_compile") 2>&5 34412 ac_status=$? 34413 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 34414 test $ac_status = 0; }; then : 34415 for ac_file in conftest.o conftest.obj conftest.*; do 34416 test -f "$ac_file" || continue; 34417 case $ac_file in 34418 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; 34419 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` 34420 break;; 34421 esac 34422 done 34423 else 34424 $as_echo "$as_me: failed program was:" >&5 34425 sed 's/^/| /' conftest.$ac_ext >&5 34426 34427 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 34428 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 34429 as_fn_error $? "cannot compute suffix of object files: cannot compile 34430 See \`config.log' for more details" "$LINENO" 5; } 34431 fi 34432 rm -f conftest.$ac_cv_objext conftest.$ac_ext 34433 fi 34434 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 34435 $as_echo "$ac_cv_objext" >&6; } 34436 OBJEXT=$ac_cv_objext 34437 ac_objext=$OBJEXT 34438 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 34439 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; } 34440 if ${ac_cv_c_compiler_gnu+:} false; then : 34441 $as_echo_n "(cached) " >&6 34442 else 34443 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34444 /* end confdefs.h. */ 34445 34446 int 34447 main () 34448 { 34449 #ifndef __GNUC__ 34450 choke me 34451 #endif 34452 34453 ; 34454 return 0; 34455 } 34456 _ACEOF 34457 if ac_fn_c_try_compile "$LINENO"; then : 34458 ac_compiler_gnu=yes 34459 else 34460 ac_compiler_gnu=no 34461 fi 34462 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 34463 ac_cv_c_compiler_gnu=$ac_compiler_gnu 34464 34465 fi 34466 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 34467 $as_echo "$ac_cv_c_compiler_gnu" >&6; } 34468 if test $ac_compiler_gnu = yes; then 34469 GCC=yes 34470 else 34471 GCC= 34472 fi 34473 ac_test_CFLAGS=${CFLAGS+set} 34474 ac_save_CFLAGS=$CFLAGS 34475 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 34476 $as_echo_n "checking whether $CC accepts -g... " >&6; } 34477 if ${ac_cv_prog_cc_g+:} false; then : 34478 $as_echo_n "(cached) " >&6 34479 else 34480 ac_save_c_werror_flag=$ac_c_werror_flag 34481 ac_c_werror_flag=yes 34482 ac_cv_prog_cc_g=no 34483 CFLAGS="-g" 34484 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34485 /* end confdefs.h. */ 34486 34487 int 34488 main () 34489 { 34490 34491 ; 34492 return 0; 34493 } 34494 _ACEOF 34495 if ac_fn_c_try_compile "$LINENO"; then : 34496 ac_cv_prog_cc_g=yes 34497 else 34498 CFLAGS="" 34499 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34500 /* end confdefs.h. */ 34501 34502 int 34503 main () 34504 { 34505 34506 ; 34507 return 0; 34508 } 34509 _ACEOF 34510 if ac_fn_c_try_compile "$LINENO"; then : 34511 34512 else 34513 ac_c_werror_flag=$ac_save_c_werror_flag 34514 CFLAGS="-g" 34515 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34516 /* end confdefs.h. */ 34517 34518 int 34519 main () 34520 { 34521 34522 ; 34523 return 0; 34524 } 34525 _ACEOF 34526 if ac_fn_c_try_compile "$LINENO"; then : 34527 ac_cv_prog_cc_g=yes 34528 fi 34529 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 34530 fi 34531 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 34532 fi 34533 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 34534 ac_c_werror_flag=$ac_save_c_werror_flag 34535 fi 34536 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 34537 $as_echo "$ac_cv_prog_cc_g" >&6; } 34538 if test "$ac_test_CFLAGS" = set; then 34539 CFLAGS=$ac_save_CFLAGS 34540 elif test $ac_cv_prog_cc_g = yes; then 34541 if test "$GCC" = yes; then 34542 CFLAGS="-g -O2" 34543 else 34544 CFLAGS="-g" 34545 fi 34546 else 34547 if test "$GCC" = yes; then 34548 CFLAGS="-O2" 34549 else 34550 CFLAGS= 34551 fi 34552 fi 34553 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 34554 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; } 34555 if ${ac_cv_prog_cc_c89+:} false; then : 34556 $as_echo_n "(cached) " >&6 34557 else 34558 ac_cv_prog_cc_c89=no 34559 ac_save_CC=$CC 34560 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34561 /* end confdefs.h. */ 34562 #include <stdarg.h> 34563 #include <stdio.h> 34564 struct stat; 34565 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ 34566 struct buf { int x; }; 34567 FILE * (*rcsopen) (struct buf *, struct stat *, int); 34568 static char *e (p, i) 34569 char **p; 34570 int i; 34571 { 34572 return p[i]; 34573 } 34574 static char *f (char * (*g) (char **, int), char **p, ...) 34575 { 34576 char *s; 34577 va_list v; 34578 va_start (v,p); 34579 s = g (p, va_arg (v,int)); 34580 va_end (v); 34581 return s; 34582 } 34583 34584 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has 34585 function prototypes and stuff, but not '\xHH' hex character constants. 34586 These don't provoke an error unfortunately, instead are silently treated 34587 as 'x'. The following induces an error, until -std is added to get 34588 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an 34589 array size at least. It's necessary to write '\x00'==0 to get something 34590 that's true only with -std. */ 34591 int osf4_cc_array ['\x00' == 0 ? 1 : -1]; 34592 34593 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters 34594 inside strings and character constants. */ 34595 #define FOO(x) 'x' 34596 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; 34597 34598 int test (int i, double x); 34599 struct s1 {int (*f) (int a);}; 34600 struct s2 {int (*f) (double a);}; 34601 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); 34602 int argc; 34603 char **argv; 34604 int 34605 main () 34606 { 34607 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; 34608 ; 34609 return 0; 34610 } 34611 _ACEOF 34612 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ 34613 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" 34614 do 34615 CC="$ac_save_CC $ac_arg" 34616 if ac_fn_c_try_compile "$LINENO"; then : 34617 ac_cv_prog_cc_c89=$ac_arg 34618 fi 34619 rm -f core conftest.err conftest.$ac_objext 34620 test "x$ac_cv_prog_cc_c89" != "xno" && break 34621 done 34622 rm -f conftest.$ac_ext 34623 CC=$ac_save_CC 34624 34625 fi 34626 # AC_CACHE_VAL 34627 case "x$ac_cv_prog_cc_c89" in 34628 x) 34629 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 34630 $as_echo "none needed" >&6; } ;; 34631 xno) 34632 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 34633 $as_echo "unsupported" >&6; } ;; 34634 *) 34635 CC="$CC $ac_cv_prog_cc_c89" 34636 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 34637 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;; 34638 esac 34639 if test "x$ac_cv_prog_cc_c89" != xno; then : 34640 34641 fi 34642 34643 ac_ext=cpp 34644 ac_cpp='$CXXCPP $CPPFLAGS' 34645 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 34646 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 34647 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 34648 34649 34650 34651 COMPILER_NAME=C++ 34652 SEARCH_LIST="$TOOLCHAIN_CXX_BINARY" 34653 34654 if test "x$CXX" != x; then 34655 # User has supplied compiler name already, always let that override. 34656 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied compiler CXX=$CXX" >&5 34657 $as_echo "$as_me: Will use user supplied compiler CXX=$CXX" >&6;} 34658 if test "x`basename $CXX`" = "x$CXX"; then 34659 # A command without a complete path is provided, search $PATH. 34660 34661 for ac_prog in $CXX 34662 do 34663 # Extract the first word of "$ac_prog", so it can be a program name with args. 34664 set dummy $ac_prog; ac_word=$2 34665 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 34666 $as_echo_n "checking for $ac_word... " >&6; } 34667 if ${ac_cv_path_POTENTIAL_CXX+:} false; then : 34668 $as_echo_n "(cached) " >&6 34669 else 34670 case $POTENTIAL_CXX in 34671 [\\/]* | ?:[\\/]*) 34672 ac_cv_path_POTENTIAL_CXX="$POTENTIAL_CXX" # Let the user override the test with a path. 34673 ;; 34674 *) 34675 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 34676 for as_dir in $PATH 34677 do 34678 IFS=$as_save_IFS 34679 test -z "$as_dir" && as_dir=. 34680 for ac_exec_ext in '' $ac_executable_extensions; do 34681 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 34682 ac_cv_path_POTENTIAL_CXX="$as_dir/$ac_word$ac_exec_ext" 34683 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 34684 break 2 34685 fi 34686 done 34687 done 34688 IFS=$as_save_IFS 34689 34690 ;; 34691 esac 34692 fi 34693 POTENTIAL_CXX=$ac_cv_path_POTENTIAL_CXX 34694 if test -n "$POTENTIAL_CXX"; then 34695 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CXX" >&5 34696 $as_echo "$POTENTIAL_CXX" >&6; } 34697 else 34698 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 34699 $as_echo "no" >&6; } 34700 fi 34701 34702 34703 test -n "$POTENTIAL_CXX" && break 34704 done 34705 34706 if test "x$POTENTIAL_CXX" != x; then 34707 CXX=$POTENTIAL_CXX 34708 else 34709 as_fn_error $? "User supplied compiler CXX=$CXX could not be found" "$LINENO" 5 34710 fi 34711 else 34712 # Otherwise it might already be a complete path 34713 if test ! -x "$CXX"; then 34714 as_fn_error $? "User supplied compiler CXX=$CXX does not exist" "$LINENO" 5 34715 fi 34716 fi 34717 else 34718 # No user supplied value. Locate compiler ourselves. 34719 34720 # If we are cross compiling, assume cross compilation tools follows the 34721 # cross compilation standard where they are prefixed with the autoconf 34722 # standard name for the target. For example the binary 34723 # i686-sun-solaris2.10-gcc will cross compile for i686-sun-solaris2.10. 34724 # If we are not cross compiling, then the default compiler name will be 34725 # used. 34726 34727 CXX= 34728 # If TOOLCHAIN_PATH is set, check for all compiler names in there first 34729 # before checking the rest of the PATH. 34730 # FIXME: Now that we prefix the TOOLS_DIR to the PATH in the PRE_DETECTION 34731 # step, this should not be necessary. 34732 if test -n "$TOOLCHAIN_PATH"; then 34733 PATH_save="$PATH" 34734 PATH="$TOOLCHAIN_PATH" 34735 if test -n "$ac_tool_prefix"; then 34736 # Extract the first word of "${ac_tool_prefix}$SEARCH_LIST", so it can be a program name with args. 34737 set dummy ${ac_tool_prefix}$SEARCH_LIST; ac_word=$2 34738 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 34739 $as_echo_n "checking for $ac_word... " >&6; } 34740 if ${ac_cv_path_TOOLCHAIN_PATH_CXX+:} false; then : 34741 $as_echo_n "(cached) " >&6 34742 else 34743 case $TOOLCHAIN_PATH_CXX in 34744 [\\/]* | ?:[\\/]*) 34745 ac_cv_path_TOOLCHAIN_PATH_CXX="$TOOLCHAIN_PATH_CXX" # Let the user override the test with a path. 34746 ;; 34747 *) 34748 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 34749 for as_dir in $PATH 34750 do 34751 IFS=$as_save_IFS 34752 test -z "$as_dir" && as_dir=. 34753 for ac_exec_ext in '' $ac_executable_extensions; do 34754 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 34755 ac_cv_path_TOOLCHAIN_PATH_CXX="$as_dir/$ac_word$ac_exec_ext" 34756 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 34757 break 2 34758 fi 34759 done 34760 done 34761 IFS=$as_save_IFS 34762 34763 ;; 34764 esac 34765 fi 34766 TOOLCHAIN_PATH_CXX=$ac_cv_path_TOOLCHAIN_PATH_CXX 34767 if test -n "$TOOLCHAIN_PATH_CXX"; then 34768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLCHAIN_PATH_CXX" >&5 34769 $as_echo "$TOOLCHAIN_PATH_CXX" >&6; } 34770 else 34771 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 34772 $as_echo "no" >&6; } 34773 fi 34774 34775 34776 fi 34777 if test -z "$ac_cv_path_TOOLCHAIN_PATH_CXX"; then 34778 ac_pt_TOOLCHAIN_PATH_CXX=$TOOLCHAIN_PATH_CXX 34779 # Extract the first word of "$SEARCH_LIST", so it can be a program name with args. 34780 set dummy $SEARCH_LIST; ac_word=$2 34781 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 34782 $as_echo_n "checking for $ac_word... " >&6; } 34783 if ${ac_cv_path_ac_pt_TOOLCHAIN_PATH_CXX+:} false; then : 34784 $as_echo_n "(cached) " >&6 34785 else 34786 case $ac_pt_TOOLCHAIN_PATH_CXX in 34787 [\\/]* | ?:[\\/]*) 34788 ac_cv_path_ac_pt_TOOLCHAIN_PATH_CXX="$ac_pt_TOOLCHAIN_PATH_CXX" # Let the user override the test with a path. 34789 ;; 34790 *) 34791 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 34792 for as_dir in $PATH 34793 do 34794 IFS=$as_save_IFS 34795 test -z "$as_dir" && as_dir=. 34796 for ac_exec_ext in '' $ac_executable_extensions; do 34797 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 34798 ac_cv_path_ac_pt_TOOLCHAIN_PATH_CXX="$as_dir/$ac_word$ac_exec_ext" 34799 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 34800 break 2 34801 fi 34802 done 34803 done 34804 IFS=$as_save_IFS 34805 34806 ;; 34807 esac 34808 fi 34809 ac_pt_TOOLCHAIN_PATH_CXX=$ac_cv_path_ac_pt_TOOLCHAIN_PATH_CXX 34810 if test -n "$ac_pt_TOOLCHAIN_PATH_CXX"; then 34811 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_TOOLCHAIN_PATH_CXX" >&5 34812 $as_echo "$ac_pt_TOOLCHAIN_PATH_CXX" >&6; } 34813 else 34814 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 34815 $as_echo "no" >&6; } 34816 fi 34817 34818 if test "x$ac_pt_TOOLCHAIN_PATH_CXX" = x; then 34819 TOOLCHAIN_PATH_CXX="" 34820 else 34821 case $cross_compiling:$ac_tool_warned in 34822 yes:) 34823 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 34824 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 34825 ac_tool_warned=yes ;; 34826 esac 34827 TOOLCHAIN_PATH_CXX=$ac_pt_TOOLCHAIN_PATH_CXX 34828 fi 34829 else 34830 TOOLCHAIN_PATH_CXX="$ac_cv_path_TOOLCHAIN_PATH_CXX" 34831 fi 34832 34833 CXX=$TOOLCHAIN_PATH_CXX 34834 PATH="$PATH_save" 34835 fi 34836 34837 # AC_PATH_TOOL can't be run multiple times with the same variable, 34838 # so create a new name for this run. 34839 if test "x$CXX" = x; then 34840 if test -n "$ac_tool_prefix"; then 34841 # Extract the first word of "${ac_tool_prefix}$SEARCH_LIST", so it can be a program name with args. 34842 set dummy ${ac_tool_prefix}$SEARCH_LIST; ac_word=$2 34843 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 34844 $as_echo_n "checking for $ac_word... " >&6; } 34845 if ${ac_cv_path_POTENTIAL_CXX+:} false; then : 34846 $as_echo_n "(cached) " >&6 34847 else 34848 case $POTENTIAL_CXX in 34849 [\\/]* | ?:[\\/]*) 34850 ac_cv_path_POTENTIAL_CXX="$POTENTIAL_CXX" # Let the user override the test with a path. 34851 ;; 34852 *) 34853 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 34854 for as_dir in $PATH 34855 do 34856 IFS=$as_save_IFS 34857 test -z "$as_dir" && as_dir=. 34858 for ac_exec_ext in '' $ac_executable_extensions; do 34859 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 34860 ac_cv_path_POTENTIAL_CXX="$as_dir/$ac_word$ac_exec_ext" 34861 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 34862 break 2 34863 fi 34864 done 34865 done 34866 IFS=$as_save_IFS 34867 34868 ;; 34869 esac 34870 fi 34871 POTENTIAL_CXX=$ac_cv_path_POTENTIAL_CXX 34872 if test -n "$POTENTIAL_CXX"; then 34873 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CXX" >&5 34874 $as_echo "$POTENTIAL_CXX" >&6; } 34875 else 34876 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 34877 $as_echo "no" >&6; } 34878 fi 34879 34880 34881 fi 34882 if test -z "$ac_cv_path_POTENTIAL_CXX"; then 34883 ac_pt_POTENTIAL_CXX=$POTENTIAL_CXX 34884 # Extract the first word of "$SEARCH_LIST", so it can be a program name with args. 34885 set dummy $SEARCH_LIST; ac_word=$2 34886 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 34887 $as_echo_n "checking for $ac_word... " >&6; } 34888 if ${ac_cv_path_ac_pt_POTENTIAL_CXX+:} false; then : 34889 $as_echo_n "(cached) " >&6 34890 else 34891 case $ac_pt_POTENTIAL_CXX in 34892 [\\/]* | ?:[\\/]*) 34893 ac_cv_path_ac_pt_POTENTIAL_CXX="$ac_pt_POTENTIAL_CXX" # Let the user override the test with a path. 34894 ;; 34895 *) 34896 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 34897 for as_dir in $PATH 34898 do 34899 IFS=$as_save_IFS 34900 test -z "$as_dir" && as_dir=. 34901 for ac_exec_ext in '' $ac_executable_extensions; do 34902 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 34903 ac_cv_path_ac_pt_POTENTIAL_CXX="$as_dir/$ac_word$ac_exec_ext" 34904 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 34905 break 2 34906 fi 34907 done 34908 done 34909 IFS=$as_save_IFS 34910 34911 ;; 34912 esac 34913 fi 34914 ac_pt_POTENTIAL_CXX=$ac_cv_path_ac_pt_POTENTIAL_CXX 34915 if test -n "$ac_pt_POTENTIAL_CXX"; then 34916 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_POTENTIAL_CXX" >&5 34917 $as_echo "$ac_pt_POTENTIAL_CXX" >&6; } 34918 else 34919 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 34920 $as_echo "no" >&6; } 34921 fi 34922 34923 if test "x$ac_pt_POTENTIAL_CXX" = x; then 34924 POTENTIAL_CXX="" 34925 else 34926 case $cross_compiling:$ac_tool_warned in 34927 yes:) 34928 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 34929 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 34930 ac_tool_warned=yes ;; 34931 esac 34932 POTENTIAL_CXX=$ac_pt_POTENTIAL_CXX 34933 fi 34934 else 34935 POTENTIAL_CXX="$ac_cv_path_POTENTIAL_CXX" 34936 fi 34937 34938 CXX=$POTENTIAL_CXX 34939 fi 34940 34941 if test "x$CXX" = x; then 34942 34943 # Print a helpful message on how to acquire the necessary build dependency. 34944 # devkit is the help tag: freetype, cups, alsa etc 34945 MISSING_DEPENDENCY=devkit 34946 34947 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34948 cygwin_help $MISSING_DEPENDENCY 34949 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34950 msys_help $MISSING_DEPENDENCY 34951 else 34952 PKGHANDLER_COMMAND= 34953 34954 case $PKGHANDLER in 34955 apt-get) 34956 apt_help $MISSING_DEPENDENCY ;; 34957 yum) 34958 yum_help $MISSING_DEPENDENCY ;; 34959 brew) 34960 brew_help $MISSING_DEPENDENCY ;; 34961 port) 34962 port_help $MISSING_DEPENDENCY ;; 34963 pkgutil) 34964 pkgutil_help $MISSING_DEPENDENCY ;; 34965 pkgadd) 34966 pkgadd_help $MISSING_DEPENDENCY ;; 34967 esac 34968 34969 if test "x$PKGHANDLER_COMMAND" != x; then 34970 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 34971 fi 34972 fi 34973 34974 as_fn_error $? "Could not find a $COMPILER_NAME compiler. $HELP_MSG" "$LINENO" 5 34975 fi 34976 fi 34977 34978 # Now we have a compiler binary in CXX. Make sure it's okay. 34979 34980 # Only process if variable expands to non-empty 34981 34982 if test "x$CXX" != x; then 34983 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34984 34985 # First separate the path from the arguments. This will split at the first 34986 # space. 34987 complete="$CXX" 34988 path="${complete%% *}" 34989 tmp="$complete EOL" 34990 arguments="${tmp#* }" 34991 34992 # Input might be given as Windows format, start by converting to 34993 # unix format. 34994 new_path=`$CYGPATH -u "$path"` 34995 34996 # Now try to locate executable using which 34997 new_path=`$WHICH "$new_path" 2> /dev/null` 34998 # bat and cmd files are not always considered executable in cygwin causing which 34999 # to not find them 35000 if test "x$new_path" = x \ 35001 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 35002 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 35003 new_path=`$CYGPATH -u "$path"` 35004 fi 35005 if test "x$new_path" = x; then 35006 # Oops. Which didn't find the executable. 35007 # The splitting of arguments from the executable at a space might have been incorrect, 35008 # since paths with space are more likely in Windows. Give it another try with the whole 35009 # argument. 35010 path="$complete" 35011 arguments="EOL" 35012 new_path=`$CYGPATH -u "$path"` 35013 new_path=`$WHICH "$new_path" 2> /dev/null` 35014 # bat and cmd files are not always considered executable in cygwin causing which 35015 # to not find them 35016 if test "x$new_path" = x \ 35017 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 35018 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 35019 new_path=`$CYGPATH -u "$path"` 35020 fi 35021 if test "x$new_path" = x; then 35022 # It's still not found. Now this is an unrecoverable error. 35023 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5 35024 $as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;} 35025 has_space=`$ECHO "$complete" | $GREP " "` 35026 if test "x$has_space" != x; then 35027 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 35028 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 35029 fi 35030 as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5 35031 fi 35032 fi 35033 35034 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 35035 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 35036 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 35037 # "foo.exe" is OK but "foo" is an error. 35038 # 35039 # This test is therefore slightly more accurate than "test -f" to check for file presence. 35040 # It is also a way to make sure we got the proper file name for the real test later on. 35041 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 35042 if test "x$test_shortpath" = x; then 35043 # Short path failed, file does not exist as specified. 35044 # Try adding .exe or .cmd 35045 if test -f "${new_path}.exe"; then 35046 input_to_shortpath="${new_path}.exe" 35047 elif test -f "${new_path}.cmd"; then 35048 input_to_shortpath="${new_path}.cmd" 35049 else 35050 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$new_path\", is invalid." >&5 35051 $as_echo "$as_me: The path of CXX, which resolves as \"$new_path\", is invalid." >&6;} 35052 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 35053 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 35054 as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5 35055 fi 35056 else 35057 input_to_shortpath="$new_path" 35058 fi 35059 35060 # Call helper function which possibly converts this using DOS-style short mode. 35061 # If so, the updated path is stored in $new_path. 35062 new_path="$input_to_shortpath" 35063 35064 input_path="$input_to_shortpath" 35065 # Check if we need to convert this using DOS-style short mode. If the path 35066 # contains just simple characters, use it. Otherwise (spaces, weird characters), 35067 # take no chances and rewrite it. 35068 # Note: m4 eats our [], so we need to use [ and ] instead. 35069 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 35070 if test "x$has_forbidden_chars" != x; then 35071 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 35072 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 35073 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 35074 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 35075 # Going to short mode and back again did indeed matter. Since short mode is 35076 # case insensitive, let's make it lowercase to improve readability. 35077 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 35078 # Now convert it back to Unix-style (cygpath) 35079 input_path=`$CYGPATH -u "$shortmode_path"` 35080 new_path="$input_path" 35081 fi 35082 fi 35083 35084 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 35085 if test "x$test_cygdrive_prefix" = x; then 35086 # As a simple fix, exclude /usr/bin since it's not a real path. 35087 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 35088 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 35089 # a path prefixed by /cygdrive for fixpath to work. 35090 new_path="$CYGWIN_ROOT_PATH$input_path" 35091 fi 35092 fi 35093 35094 # remove trailing .exe if any 35095 new_path="${new_path/%.exe/}" 35096 35097 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35098 35099 # First separate the path from the arguments. This will split at the first 35100 # space. 35101 complete="$CXX" 35102 path="${complete%% *}" 35103 tmp="$complete EOL" 35104 arguments="${tmp#* }" 35105 35106 # Input might be given as Windows format, start by converting to 35107 # unix format. 35108 new_path="$path" 35109 35110 windows_path="$new_path" 35111 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35112 unix_path=`$CYGPATH -u "$windows_path"` 35113 new_path="$unix_path" 35114 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35115 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 35116 new_path="$unix_path" 35117 fi 35118 35119 35120 # Now try to locate executable using which 35121 new_path=`$WHICH "$new_path" 2> /dev/null` 35122 35123 if test "x$new_path" = x; then 35124 # Oops. Which didn't find the executable. 35125 # The splitting of arguments from the executable at a space might have been incorrect, 35126 # since paths with space are more likely in Windows. Give it another try with the whole 35127 # argument. 35128 path="$complete" 35129 arguments="EOL" 35130 new_path="$path" 35131 35132 windows_path="$new_path" 35133 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35134 unix_path=`$CYGPATH -u "$windows_path"` 35135 new_path="$unix_path" 35136 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35137 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 35138 new_path="$unix_path" 35139 fi 35140 35141 35142 new_path=`$WHICH "$new_path" 2> /dev/null` 35143 # bat and cmd files are not always considered executable in MSYS causing which 35144 # to not find them 35145 if test "x$new_path" = x \ 35146 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 35147 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 35148 new_path="$path" 35149 35150 windows_path="$new_path" 35151 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35152 unix_path=`$CYGPATH -u "$windows_path"` 35153 new_path="$unix_path" 35154 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35155 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 35156 new_path="$unix_path" 35157 fi 35158 35159 fi 35160 35161 if test "x$new_path" = x; then 35162 # It's still not found. Now this is an unrecoverable error. 35163 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5 35164 $as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;} 35165 has_space=`$ECHO "$complete" | $GREP " "` 35166 if test "x$has_space" != x; then 35167 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 35168 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 35169 fi 35170 as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5 35171 fi 35172 fi 35173 35174 # Now new_path has a complete unix path to the binary 35175 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 35176 # Keep paths in /bin as-is, but remove trailing .exe if any 35177 new_path="${new_path/%.exe/}" 35178 # Do not save /bin paths to all_fixpath_prefixes! 35179 else 35180 # Not in mixed or Windows style, start by that. 35181 new_path=`cmd //c echo $new_path` 35182 35183 input_path="$new_path" 35184 # Check if we need to convert this using DOS-style short mode. If the path 35185 # contains just simple characters, use it. Otherwise (spaces, weird characters), 35186 # take no chances and rewrite it. 35187 # Note: m4 eats our [], so we need to use [ and ] instead. 35188 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 35189 if test "x$has_forbidden_chars" != x; then 35190 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 35191 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 35192 fi 35193 35194 # Output is in $new_path 35195 35196 windows_path="$new_path" 35197 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35198 unix_path=`$CYGPATH -u "$windows_path"` 35199 new_path="$unix_path" 35200 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35201 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 35202 new_path="$unix_path" 35203 fi 35204 35205 # remove trailing .exe if any 35206 new_path="${new_path/%.exe/}" 35207 35208 # Save the first 10 bytes of this path to the storage, so fixpath can work. 35209 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 35210 fi 35211 35212 else 35213 # We're on a unix platform. Hooray! :) 35214 # First separate the path from the arguments. This will split at the first 35215 # space. 35216 complete="$CXX" 35217 path="${complete%% *}" 35218 tmp="$complete EOL" 35219 arguments="${tmp#* }" 35220 35221 # Cannot rely on the command "which" here since it doesn't always work. 35222 is_absolute_path=`$ECHO "$path" | $GREP ^/` 35223 if test -z "$is_absolute_path"; then 35224 # Path to executable is not absolute. Find it. 35225 IFS_save="$IFS" 35226 IFS=: 35227 for p in $PATH; do 35228 if test -f "$p/$path" && test -x "$p/$path"; then 35229 new_path="$p/$path" 35230 break 35231 fi 35232 done 35233 IFS="$IFS_save" 35234 else 35235 # This is an absolute path, we can use it without further modifications. 35236 new_path="$path" 35237 fi 35238 35239 if test "x$new_path" = x; then 35240 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5 35241 $as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;} 35242 has_space=`$ECHO "$complete" | $GREP " "` 35243 if test "x$has_space" != x; then 35244 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 35245 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 35246 fi 35247 as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5 35248 fi 35249 fi 35250 35251 # Now join together the path and the arguments once again 35252 if test "x$arguments" != xEOL; then 35253 new_complete="$new_path ${arguments% *}" 35254 else 35255 new_complete="$new_path" 35256 fi 35257 35258 if test "x$complete" != "x$new_complete"; then 35259 CXX="$new_complete" 35260 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CXX to \"$new_complete\"" >&5 35261 $as_echo "$as_me: Rewriting CXX to \"$new_complete\"" >&6;} 35262 fi 35263 fi 35264 35265 TEST_COMPILER="$CXX" 35266 35267 { $as_echo "$as_me:${as_lineno-$LINENO}: checking resolved symbolic links for CXX" >&5 35268 $as_echo_n "checking resolved symbolic links for CXX... " >&6; } 35269 SYMLINK_ORIGINAL="$TEST_COMPILER" 35270 35271 if test "x$OPENJDK_BUILD_OS" != xwindows; then 35272 # Follow a chain of symbolic links. Use readlink 35273 # where it exists, else fall back to horribly 35274 # complicated shell code. 35275 if test "x$READLINK_TESTED" != yes; then 35276 # On MacOSX there is a readlink tool with a different 35277 # purpose than the GNU readlink tool. Check the found readlink. 35278 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 35279 if test "x$ISGNU" = x; then 35280 # A readlink that we do not know how to use. 35281 # Are there other non-GNU readlinks out there? 35282 READLINK_TESTED=yes 35283 READLINK= 35284 fi 35285 fi 35286 35287 if test "x$READLINK" != x; then 35288 SYMLINK_ORIGINAL=`$READLINK -f $SYMLINK_ORIGINAL` 35289 else 35290 # Save the current directory for restoring afterwards 35291 STARTDIR=$PWD 35292 COUNTER=0 35293 sym_link_dir=`$DIRNAME $SYMLINK_ORIGINAL` 35294 sym_link_file=`$BASENAME $SYMLINK_ORIGINAL` 35295 cd $sym_link_dir 35296 # Use -P flag to resolve symlinks in directories. 35297 cd `$THEPWDCMD -P` 35298 sym_link_dir=`$THEPWDCMD -P` 35299 # Resolve file symlinks 35300 while test $COUNTER -lt 20; do 35301 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 35302 if test "x$ISLINK" == x; then 35303 # This is not a symbolic link! We are done! 35304 break 35305 fi 35306 # Again resolve directory symlinks since the target of the just found 35307 # link could be in a different directory 35308 cd `$DIRNAME $ISLINK` 35309 sym_link_dir=`$THEPWDCMD -P` 35310 sym_link_file=`$BASENAME $ISLINK` 35311 let COUNTER=COUNTER+1 35312 done 35313 cd $STARTDIR 35314 SYMLINK_ORIGINAL=$sym_link_dir/$sym_link_file 35315 fi 35316 fi 35317 35318 if test "x$TEST_COMPILER" = "x$SYMLINK_ORIGINAL"; then 35319 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no symlink" >&5 35320 $as_echo "no symlink" >&6; } 35321 else 35322 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SYMLINK_ORIGINAL" >&5 35323 $as_echo "$SYMLINK_ORIGINAL" >&6; } 35324 35325 # We can't handle ccache by gcc wrappers, since we need to know if we're 35326 # using ccache. Instead ccache usage must be controlled by a configure option. 35327 COMPILER_BASENAME=`$BASENAME "$SYMLINK_ORIGINAL"` 35328 if test "x$COMPILER_BASENAME" = "xccache"; then 35329 { $as_echo "$as_me:${as_lineno-$LINENO}: Please use --enable-ccache instead of providing a wrapped compiler." >&5 35330 $as_echo "$as_me: Please use --enable-ccache instead of providing a wrapped compiler." >&6;} 35331 as_fn_error $? "$TEST_COMPILER is a symbolic link to ccache. This is not supported." "$LINENO" 5 35332 fi 35333 fi 35334 35335 35336 COMPILER=$CXX 35337 COMPILER_NAME=$COMPILER_NAME 35338 35339 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 35340 # cc -V output typically looks like 35341 # cc: Sun C 5.12 Linux_i386 2011/11/16 35342 # or 35343 # cc: Studio 12.5 Sun C 5.14 SunOS_sparc 2016/05/31 35344 COMPILER_VERSION_OUTPUT=`$COMPILER -V 2>&1` 35345 # Check that this is likely to be the Solaris Studio cc. 35346 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "^.* Sun $COMPILER_NAME" > /dev/null 35347 if test $? -ne 0; then 35348 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 35349 { $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 35350 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 35351 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&5 35352 $as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 35353 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 35354 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 35355 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 35356 fi 35357 # Remove usage instructions (if present), and 35358 # collapse compiler output into a single line 35359 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 35360 $SED -e 's/ *[Uu]sage:.*//'` 35361 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 35362 $SED -e "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/"` 35363 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 35364 # xlc -qversion output typically looks like 35365 # IBM XL C/C++ for AIX, V11.1 (5724-X13) 35366 # Version: 11.01.0000.0015 35367 COMPILER_VERSION_OUTPUT=`$COMPILER -qversion 2>&1` 35368 # Check that this is likely to be the IBM XL C compiler. 35369 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "IBM XL C" > /dev/null 35370 if test $? -ne 0; then 35371 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 35372 { $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 35373 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 35374 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&5 35375 $as_echo "$as_me: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 35376 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 35377 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 35378 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 35379 fi 35380 # Collapse compiler output into a single line 35381 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 35382 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 35383 $SED -e 's/^.*, V\([1-9][0-9.]*\).*$/\1/'` 35384 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 35385 # There is no specific version flag, but all output starts with a version string. 35386 # First line typically looks something like: 35387 # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86 35388 COMPILER_VERSION_OUTPUT=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'` 35389 # Check that this is likely to be Microsoft CL.EXE. 35390 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Microsoft.*Compiler" > /dev/null 35391 if test $? -ne 0; then 35392 { $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 35393 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 35394 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&5 35395 $as_echo "$as_me: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 35396 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 35397 fi 35398 # Collapse compiler output into a single line 35399 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 35400 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 35401 $SED -e 's/^.*ersion.\([1-9][0-9.]*\) .*$/\1/'` 35402 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 35403 # gcc --version output typically looks like 35404 # gcc (Ubuntu/Linaro 4.8.1-10ubuntu9) 4.8.1 35405 # Copyright (C) 2013 Free Software Foundation, Inc. 35406 # This is free software; see the source for copying conditions. There is NO 35407 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 35408 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 35409 # Check that this is likely to be GCC. 35410 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Free Software Foundation" > /dev/null 35411 if test $? -ne 0; then 35412 { $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 35413 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 35414 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION\"" >&5 35415 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION\"" >&6;} 35416 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 35417 fi 35418 # Remove Copyright and legalese from version string, and 35419 # collapse into a single line 35420 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 35421 $SED -e 's/ *Copyright .*//'` 35422 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 35423 $SED -e 's/^.* \([1-9]\.[0-9.]*\)[^0-9.].*$/\1/'` 35424 elif test "x$TOOLCHAIN_TYPE" = xclang; then 35425 # clang --version output typically looks like 35426 # Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn) 35427 # clang version 3.3 (tags/RELEASE_33/final) 35428 # or 35429 # Debian clang version 3.2-7ubuntu1 (tags/RELEASE_32/final) (based on LLVM 3.2) 35430 # Target: x86_64-pc-linux-gnu 35431 # Thread model: posix 35432 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 35433 # Check that this is likely to be clang 35434 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "clang" > /dev/null 35435 if test $? -ne 0; then 35436 { $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 35437 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 35438 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&5 35439 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 35440 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 35441 fi 35442 # Collapse compiler output into a single line 35443 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 35444 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 35445 $SED -e 's/^.* version \([1-9][0-9.]*\).*$/\1/'` 35446 else 35447 as_fn_error $? "Unknown toolchain type $TOOLCHAIN_TYPE." "$LINENO" 5 35448 fi 35449 # This sets CC_VERSION_NUMBER or CXX_VERSION_NUMBER. (This comment is a grep marker) 35450 CXX_VERSION_NUMBER="$COMPILER_VERSION_NUMBER" 35451 # This sets CC_VERSION_STRING or CXX_VERSION_STRING. (This comment is a grep marker) 35452 CXX_VERSION_STRING="$COMPILER_VERSION_STRING" 35453 35454 { $as_echo "$as_me:${as_lineno-$LINENO}: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&5 35455 $as_echo "$as_me: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&6;} 35456 35457 35458 # Now that we have resolved CXX ourself, let autoconf have its go at it 35459 ac_ext=cpp 35460 ac_cpp='$CXXCPP $CPPFLAGS' 35461 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 35462 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 35463 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 35464 if test -z "$CXX"; then 35465 if test -n "$CCC"; then 35466 CXX=$CCC 35467 else 35468 if test -n "$ac_tool_prefix"; then 35469 for ac_prog in $CXX 35470 do 35471 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 35472 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 35473 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 35474 $as_echo_n "checking for $ac_word... " >&6; } 35475 if ${ac_cv_prog_CXX+:} false; then : 35476 $as_echo_n "(cached) " >&6 35477 else 35478 if test -n "$CXX"; then 35479 ac_cv_prog_CXX="$CXX" # Let the user override the test. 35480 else 35481 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 35482 for as_dir in $PATH 35483 do 35484 IFS=$as_save_IFS 35485 test -z "$as_dir" && as_dir=. 35486 for ac_exec_ext in '' $ac_executable_extensions; do 35487 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 35488 ac_cv_prog_CXX="$ac_tool_prefix$ac_prog" 35489 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 35490 break 2 35491 fi 35492 done 35493 done 35494 IFS=$as_save_IFS 35495 35496 fi 35497 fi 35498 CXX=$ac_cv_prog_CXX 35499 if test -n "$CXX"; then 35500 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 35501 $as_echo "$CXX" >&6; } 35502 else 35503 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 35504 $as_echo "no" >&6; } 35505 fi 35506 35507 35508 test -n "$CXX" && break 35509 done 35510 fi 35511 if test -z "$CXX"; then 35512 ac_ct_CXX=$CXX 35513 for ac_prog in $CXX 35514 do 35515 # Extract the first word of "$ac_prog", so it can be a program name with args. 35516 set dummy $ac_prog; ac_word=$2 35517 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 35518 $as_echo_n "checking for $ac_word... " >&6; } 35519 if ${ac_cv_prog_ac_ct_CXX+:} false; then : 35520 $as_echo_n "(cached) " >&6 35521 else 35522 if test -n "$ac_ct_CXX"; then 35523 ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test. 35524 else 35525 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 35526 for as_dir in $PATH 35527 do 35528 IFS=$as_save_IFS 35529 test -z "$as_dir" && as_dir=. 35530 for ac_exec_ext in '' $ac_executable_extensions; do 35531 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 35532 ac_cv_prog_ac_ct_CXX="$ac_prog" 35533 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 35534 break 2 35535 fi 35536 done 35537 done 35538 IFS=$as_save_IFS 35539 35540 fi 35541 fi 35542 ac_ct_CXX=$ac_cv_prog_ac_ct_CXX 35543 if test -n "$ac_ct_CXX"; then 35544 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5 35545 $as_echo "$ac_ct_CXX" >&6; } 35546 else 35547 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 35548 $as_echo "no" >&6; } 35549 fi 35550 35551 35552 test -n "$ac_ct_CXX" && break 35553 done 35554 35555 if test "x$ac_ct_CXX" = x; then 35556 CXX="g++" 35557 else 35558 case $cross_compiling:$ac_tool_warned in 35559 yes:) 35560 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 35561 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 35562 ac_tool_warned=yes ;; 35563 esac 35564 CXX=$ac_ct_CXX 35565 fi 35566 fi 35567 35568 fi 35569 fi 35570 # Provide some information about the compiler. 35571 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5 35572 set X $ac_compile 35573 ac_compiler=$2 35574 for ac_option in --version -v -V -qversion; do 35575 { { ac_try="$ac_compiler $ac_option >&5" 35576 case "(($ac_try" in 35577 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 35578 *) ac_try_echo=$ac_try;; 35579 esac 35580 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 35581 $as_echo "$ac_try_echo"; } >&5 35582 (eval "$ac_compiler $ac_option >&5") 2>conftest.err 35583 ac_status=$? 35584 if test -s conftest.err; then 35585 sed '10a\ 35586 ... rest of stderr output deleted ... 35587 10q' conftest.err >conftest.er1 35588 cat conftest.er1 >&5 35589 fi 35590 rm -f conftest.er1 conftest.err 35591 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 35592 test $ac_status = 0; } 35593 done 35594 35595 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5 35596 $as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; } 35597 if ${ac_cv_cxx_compiler_gnu+:} false; then : 35598 $as_echo_n "(cached) " >&6 35599 else 35600 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35601 /* end confdefs.h. */ 35602 35603 int 35604 main () 35605 { 35606 #ifndef __GNUC__ 35607 choke me 35608 #endif 35609 35610 ; 35611 return 0; 35612 } 35613 _ACEOF 35614 if ac_fn_cxx_try_compile "$LINENO"; then : 35615 ac_compiler_gnu=yes 35616 else 35617 ac_compiler_gnu=no 35618 fi 35619 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 35620 ac_cv_cxx_compiler_gnu=$ac_compiler_gnu 35621 35622 fi 35623 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5 35624 $as_echo "$ac_cv_cxx_compiler_gnu" >&6; } 35625 if test $ac_compiler_gnu = yes; then 35626 GXX=yes 35627 else 35628 GXX= 35629 fi 35630 ac_test_CXXFLAGS=${CXXFLAGS+set} 35631 ac_save_CXXFLAGS=$CXXFLAGS 35632 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5 35633 $as_echo_n "checking whether $CXX accepts -g... " >&6; } 35634 if ${ac_cv_prog_cxx_g+:} false; then : 35635 $as_echo_n "(cached) " >&6 35636 else 35637 ac_save_cxx_werror_flag=$ac_cxx_werror_flag 35638 ac_cxx_werror_flag=yes 35639 ac_cv_prog_cxx_g=no 35640 CXXFLAGS="-g" 35641 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35642 /* end confdefs.h. */ 35643 35644 int 35645 main () 35646 { 35647 35648 ; 35649 return 0; 35650 } 35651 _ACEOF 35652 if ac_fn_cxx_try_compile "$LINENO"; then : 35653 ac_cv_prog_cxx_g=yes 35654 else 35655 CXXFLAGS="" 35656 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35657 /* end confdefs.h. */ 35658 35659 int 35660 main () 35661 { 35662 35663 ; 35664 return 0; 35665 } 35666 _ACEOF 35667 if ac_fn_cxx_try_compile "$LINENO"; then : 35668 35669 else 35670 ac_cxx_werror_flag=$ac_save_cxx_werror_flag 35671 CXXFLAGS="-g" 35672 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35673 /* end confdefs.h. */ 35674 35675 int 35676 main () 35677 { 35678 35679 ; 35680 return 0; 35681 } 35682 _ACEOF 35683 if ac_fn_cxx_try_compile "$LINENO"; then : 35684 ac_cv_prog_cxx_g=yes 35685 fi 35686 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 35687 fi 35688 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 35689 fi 35690 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 35691 ac_cxx_werror_flag=$ac_save_cxx_werror_flag 35692 fi 35693 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5 35694 $as_echo "$ac_cv_prog_cxx_g" >&6; } 35695 if test "$ac_test_CXXFLAGS" = set; then 35696 CXXFLAGS=$ac_save_CXXFLAGS 35697 elif test $ac_cv_prog_cxx_g = yes; then 35698 if test "$GXX" = yes; then 35699 CXXFLAGS="-g -O2" 35700 else 35701 CXXFLAGS="-g" 35702 fi 35703 else 35704 if test "$GXX" = yes; then 35705 CXXFLAGS="-O2" 35706 else 35707 CXXFLAGS= 35708 fi 35709 fi 35710 ac_ext=cpp 35711 ac_cpp='$CXXCPP $CPPFLAGS' 35712 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 35713 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 35714 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 35715 35716 35717 # This is the compiler version number on the form X.Y[.Z] 35718 35719 35720 35721 35722 if test "x$CC_VERSION_NUMBER" != "x$CXX_VERSION_NUMBER"; then 35723 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: C and C++ compiler have different version numbers, $CC_VERSION_NUMBER vs $CXX_VERSION_NUMBER." >&5 35724 $as_echo "$as_me: WARNING: C and C++ compiler have different version numbers, $CC_VERSION_NUMBER vs $CXX_VERSION_NUMBER." >&2;} 35725 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This typically indicates a broken setup, and is not supported" >&5 35726 $as_echo "$as_me: WARNING: This typically indicates a broken setup, and is not supported" >&2;} 35727 fi 35728 35729 # We only check CC_VERSION_NUMBER since we assume CXX_VERSION_NUMBER is equal. 35730 if [[ "[$]CC_VERSION_NUMBER" =~ (.*\.){4} ]] ; then 35731 { $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 35732 $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;} 35733 fi 35734 35735 if [[ "[$]CC_VERSION_NUMBER" =~ [0-9]{6} ]] ; then 35736 { $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 35737 $as_echo "$as_me: WARNING: C compiler version number has a part larger than 99999: $CC_VERSION_NUMBER. Comparisons might be wrong." >&2;} 35738 fi 35739 35740 COMPARABLE_ACTUAL_VERSION=`$AWK -F. '{ printf("%05d%05d%05d%05d\n", $1, $2, $3, $4) }' <<< "$CC_VERSION_NUMBER"` 35741 35742 35743 if test "x$TOOLCHAIN_MINIMUM_VERSION" != x; then 35744 35745 35746 35747 35748 35749 35750 35751 35752 35753 35754 35755 35756 35757 35758 35759 35760 35761 35762 35763 35764 35765 35766 35767 35768 35769 35770 35771 35772 35773 35774 35775 35776 35777 35778 35779 35780 35781 35782 35783 35784 35785 35786 35787 35788 35789 35790 35791 35792 35793 # Execute function body 35794 35795 # Need to assign to a variable since m4 is blocked from modifying parts in []. 35796 REFERENCE_VERSION=$TOOLCHAIN_MINIMUM_VERSION 35797 35798 if [[ "$REFERENCE_VERSION" =~ (.*\.){4} ]] ; then 35799 as_fn_error $? "Internal error: Cannot compare to $TOOLCHAIN_MINIMUM_VERSION, only four parts (W.X.Y.Z) is supported" "$LINENO" 5 35800 fi 35801 35802 if [[ "$REFERENCE_VERSION" =~ [0-9]{6} ]] ; then 35803 as_fn_error $? "Internal error: Cannot compare to $TOOLCHAIN_MINIMUM_VERSION, only parts < 99999 is supported" "$LINENO" 5 35804 fi 35805 35806 # Version comparison method inspired by http://stackoverflow.com/a/24067243 35807 COMPARABLE_REFERENCE_VERSION=`$AWK -F. '{ printf("%05d%05d%05d%05d\n", $1, $2, $3, $4) }' <<< "$REFERENCE_VERSION"` 35808 35809 if test $COMPARABLE_ACTUAL_VERSION -ge $COMPARABLE_REFERENCE_VERSION ; then 35810 : 35811 35812 else 35813 : 35814 35815 { $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 35816 $as_echo "$as_me: WARNING: You are using $TOOLCHAIN_TYPE older than $TOOLCHAIN_MINIMUM_VERSION. This is not a supported configuration." >&2;} 35817 35818 35819 fi 35820 35821 35822 35823 35824 35825 35826 35827 35828 35829 35830 35831 35832 35833 35834 fi 35835 35836 # 35837 # Setup the preprocessor (CPP and CXXCPP) 35838 # 35839 ac_ext=c 35840 ac_cpp='$CPP $CPPFLAGS' 35841 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 35842 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 35843 ac_compiler_gnu=$ac_cv_c_compiler_gnu 35844 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 35845 $as_echo_n "checking how to run the C preprocessor... " >&6; } 35846 # On Suns, sometimes $CPP names a directory. 35847 if test -n "$CPP" && test -d "$CPP"; then 35848 CPP= 35849 fi 35850 if test -z "$CPP"; then 35851 if ${ac_cv_prog_CPP+:} false; then : 35852 $as_echo_n "(cached) " >&6 35853 else 35854 # Double quotes because CPP needs to be expanded 35855 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" 35856 do 35857 ac_preproc_ok=false 35858 for ac_c_preproc_warn_flag in '' yes 35859 do 35860 # Use a header file that comes with gcc, so configuring glibc 35861 # with a fresh cross-compiler works. 35862 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 35863 # <limits.h> exists even on freestanding compilers. 35864 # On the NeXT, cc -E runs the code through the compiler's parser, 35865 # not just through cpp. "Syntax error" is here to catch this case. 35866 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35867 /* end confdefs.h. */ 35868 #ifdef __STDC__ 35869 # include <limits.h> 35870 #else 35871 # include <assert.h> 35872 #endif 35873 Syntax error 35874 _ACEOF 35875 if ac_fn_c_try_cpp "$LINENO"; then : 35876 35877 else 35878 # Broken: fails on valid input. 35879 continue 35880 fi 35881 rm -f conftest.err conftest.i conftest.$ac_ext 35882 35883 # OK, works on sane cases. Now check whether nonexistent headers 35884 # can be detected and how. 35885 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35886 /* end confdefs.h. */ 35887 #include <ac_nonexistent.h> 35888 _ACEOF 35889 if ac_fn_c_try_cpp "$LINENO"; then : 35890 # Broken: success on invalid input. 35891 continue 35892 else 35893 # Passes both tests. 35894 ac_preproc_ok=: 35895 break 35896 fi 35897 rm -f conftest.err conftest.i conftest.$ac_ext 35898 35899 done 35900 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 35901 rm -f conftest.i conftest.err conftest.$ac_ext 35902 if $ac_preproc_ok; then : 35903 break 35904 fi 35905 35906 done 35907 ac_cv_prog_CPP=$CPP 35908 35909 fi 35910 CPP=$ac_cv_prog_CPP 35911 else 35912 ac_cv_prog_CPP=$CPP 35913 fi 35914 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 35915 $as_echo "$CPP" >&6; } 35916 ac_preproc_ok=false 35917 for ac_c_preproc_warn_flag in '' yes 35918 do 35919 # Use a header file that comes with gcc, so configuring glibc 35920 # with a fresh cross-compiler works. 35921 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 35922 # <limits.h> exists even on freestanding compilers. 35923 # On the NeXT, cc -E runs the code through the compiler's parser, 35924 # not just through cpp. "Syntax error" is here to catch this case. 35925 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35926 /* end confdefs.h. */ 35927 #ifdef __STDC__ 35928 # include <limits.h> 35929 #else 35930 # include <assert.h> 35931 #endif 35932 Syntax error 35933 _ACEOF 35934 if ac_fn_c_try_cpp "$LINENO"; then : 35935 35936 else 35937 # Broken: fails on valid input. 35938 continue 35939 fi 35940 rm -f conftest.err conftest.i conftest.$ac_ext 35941 35942 # OK, works on sane cases. Now check whether nonexistent headers 35943 # can be detected and how. 35944 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35945 /* end confdefs.h. */ 35946 #include <ac_nonexistent.h> 35947 _ACEOF 35948 if ac_fn_c_try_cpp "$LINENO"; then : 35949 # Broken: success on invalid input. 35950 continue 35951 else 35952 # Passes both tests. 35953 ac_preproc_ok=: 35954 break 35955 fi 35956 rm -f conftest.err conftest.i conftest.$ac_ext 35957 35958 done 35959 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 35960 rm -f conftest.i conftest.err conftest.$ac_ext 35961 if $ac_preproc_ok; then : 35962 35963 else 35964 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 35965 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 35966 as_fn_error $? "C preprocessor \"$CPP\" fails sanity check 35967 See \`config.log' for more details" "$LINENO" 5; } 35968 fi 35969 35970 ac_ext=cpp 35971 ac_cpp='$CXXCPP $CPPFLAGS' 35972 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 35973 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 35974 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 35975 35976 35977 # Only process if variable expands to non-empty 35978 35979 if test "x$CPP" != x; then 35980 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35981 35982 # First separate the path from the arguments. This will split at the first 35983 # space. 35984 complete="$CPP" 35985 path="${complete%% *}" 35986 tmp="$complete EOL" 35987 arguments="${tmp#* }" 35988 35989 # Input might be given as Windows format, start by converting to 35990 # unix format. 35991 new_path=`$CYGPATH -u "$path"` 35992 35993 # Now try to locate executable using which 35994 new_path=`$WHICH "$new_path" 2> /dev/null` 35995 # bat and cmd files are not always considered executable in cygwin causing which 35996 # to not find them 35997 if test "x$new_path" = x \ 35998 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 35999 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36000 new_path=`$CYGPATH -u "$path"` 36001 fi 36002 if test "x$new_path" = x; then 36003 # Oops. Which didn't find the executable. 36004 # The splitting of arguments from the executable at a space might have been incorrect, 36005 # since paths with space are more likely in Windows. Give it another try with the whole 36006 # argument. 36007 path="$complete" 36008 arguments="EOL" 36009 new_path=`$CYGPATH -u "$path"` 36010 new_path=`$WHICH "$new_path" 2> /dev/null` 36011 # bat and cmd files are not always considered executable in cygwin causing which 36012 # to not find them 36013 if test "x$new_path" = x \ 36014 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36015 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36016 new_path=`$CYGPATH -u "$path"` 36017 fi 36018 if test "x$new_path" = x; then 36019 # It's still not found. Now this is an unrecoverable error. 36020 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5 36021 $as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;} 36022 has_space=`$ECHO "$complete" | $GREP " "` 36023 if test "x$has_space" != x; then 36024 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 36025 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 36026 fi 36027 as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5 36028 fi 36029 fi 36030 36031 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 36032 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 36033 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 36034 # "foo.exe" is OK but "foo" is an error. 36035 # 36036 # This test is therefore slightly more accurate than "test -f" to check for file presence. 36037 # It is also a way to make sure we got the proper file name for the real test later on. 36038 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 36039 if test "x$test_shortpath" = x; then 36040 # Short path failed, file does not exist as specified. 36041 # Try adding .exe or .cmd 36042 if test -f "${new_path}.exe"; then 36043 input_to_shortpath="${new_path}.exe" 36044 elif test -f "${new_path}.cmd"; then 36045 input_to_shortpath="${new_path}.cmd" 36046 else 36047 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$new_path\", is invalid." >&5 36048 $as_echo "$as_me: The path of CPP, which resolves as \"$new_path\", is invalid." >&6;} 36049 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 36050 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 36051 as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5 36052 fi 36053 else 36054 input_to_shortpath="$new_path" 36055 fi 36056 36057 # Call helper function which possibly converts this using DOS-style short mode. 36058 # If so, the updated path is stored in $new_path. 36059 new_path="$input_to_shortpath" 36060 36061 input_path="$input_to_shortpath" 36062 # Check if we need to convert this using DOS-style short mode. If the path 36063 # contains just simple characters, use it. Otherwise (spaces, weird characters), 36064 # take no chances and rewrite it. 36065 # Note: m4 eats our [], so we need to use [ and ] instead. 36066 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 36067 if test "x$has_forbidden_chars" != x; then 36068 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 36069 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 36070 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 36071 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 36072 # Going to short mode and back again did indeed matter. Since short mode is 36073 # case insensitive, let's make it lowercase to improve readability. 36074 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 36075 # Now convert it back to Unix-style (cygpath) 36076 input_path=`$CYGPATH -u "$shortmode_path"` 36077 new_path="$input_path" 36078 fi 36079 fi 36080 36081 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 36082 if test "x$test_cygdrive_prefix" = x; then 36083 # As a simple fix, exclude /usr/bin since it's not a real path. 36084 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 36085 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 36086 # a path prefixed by /cygdrive for fixpath to work. 36087 new_path="$CYGWIN_ROOT_PATH$input_path" 36088 fi 36089 fi 36090 36091 # remove trailing .exe if any 36092 new_path="${new_path/%.exe/}" 36093 36094 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36095 36096 # First separate the path from the arguments. This will split at the first 36097 # space. 36098 complete="$CPP" 36099 path="${complete%% *}" 36100 tmp="$complete EOL" 36101 arguments="${tmp#* }" 36102 36103 # Input might be given as Windows format, start by converting to 36104 # unix format. 36105 new_path="$path" 36106 36107 windows_path="$new_path" 36108 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36109 unix_path=`$CYGPATH -u "$windows_path"` 36110 new_path="$unix_path" 36111 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36112 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36113 new_path="$unix_path" 36114 fi 36115 36116 36117 # Now try to locate executable using which 36118 new_path=`$WHICH "$new_path" 2> /dev/null` 36119 36120 if test "x$new_path" = x; then 36121 # Oops. Which didn't find the executable. 36122 # The splitting of arguments from the executable at a space might have been incorrect, 36123 # since paths with space are more likely in Windows. Give it another try with the whole 36124 # argument. 36125 path="$complete" 36126 arguments="EOL" 36127 new_path="$path" 36128 36129 windows_path="$new_path" 36130 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36131 unix_path=`$CYGPATH -u "$windows_path"` 36132 new_path="$unix_path" 36133 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36134 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36135 new_path="$unix_path" 36136 fi 36137 36138 36139 new_path=`$WHICH "$new_path" 2> /dev/null` 36140 # bat and cmd files are not always considered executable in MSYS causing which 36141 # to not find them 36142 if test "x$new_path" = x \ 36143 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36144 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36145 new_path="$path" 36146 36147 windows_path="$new_path" 36148 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36149 unix_path=`$CYGPATH -u "$windows_path"` 36150 new_path="$unix_path" 36151 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36152 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36153 new_path="$unix_path" 36154 fi 36155 36156 fi 36157 36158 if test "x$new_path" = x; then 36159 # It's still not found. Now this is an unrecoverable error. 36160 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5 36161 $as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;} 36162 has_space=`$ECHO "$complete" | $GREP " "` 36163 if test "x$has_space" != x; then 36164 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 36165 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 36166 fi 36167 as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5 36168 fi 36169 fi 36170 36171 # Now new_path has a complete unix path to the binary 36172 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 36173 # Keep paths in /bin as-is, but remove trailing .exe if any 36174 new_path="${new_path/%.exe/}" 36175 # Do not save /bin paths to all_fixpath_prefixes! 36176 else 36177 # Not in mixed or Windows style, start by that. 36178 new_path=`cmd //c echo $new_path` 36179 36180 input_path="$new_path" 36181 # Check if we need to convert this using DOS-style short mode. If the path 36182 # contains just simple characters, use it. Otherwise (spaces, weird characters), 36183 # take no chances and rewrite it. 36184 # Note: m4 eats our [], so we need to use [ and ] instead. 36185 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 36186 if test "x$has_forbidden_chars" != x; then 36187 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 36188 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 36189 fi 36190 36191 # Output is in $new_path 36192 36193 windows_path="$new_path" 36194 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36195 unix_path=`$CYGPATH -u "$windows_path"` 36196 new_path="$unix_path" 36197 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36198 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36199 new_path="$unix_path" 36200 fi 36201 36202 # remove trailing .exe if any 36203 new_path="${new_path/%.exe/}" 36204 36205 # Save the first 10 bytes of this path to the storage, so fixpath can work. 36206 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 36207 fi 36208 36209 else 36210 # We're on a unix platform. Hooray! :) 36211 # First separate the path from the arguments. This will split at the first 36212 # space. 36213 complete="$CPP" 36214 path="${complete%% *}" 36215 tmp="$complete EOL" 36216 arguments="${tmp#* }" 36217 36218 # Cannot rely on the command "which" here since it doesn't always work. 36219 is_absolute_path=`$ECHO "$path" | $GREP ^/` 36220 if test -z "$is_absolute_path"; then 36221 # Path to executable is not absolute. Find it. 36222 IFS_save="$IFS" 36223 IFS=: 36224 for p in $PATH; do 36225 if test -f "$p/$path" && test -x "$p/$path"; then 36226 new_path="$p/$path" 36227 break 36228 fi 36229 done 36230 IFS="$IFS_save" 36231 else 36232 # This is an absolute path, we can use it without further modifications. 36233 new_path="$path" 36234 fi 36235 36236 if test "x$new_path" = x; then 36237 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5 36238 $as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;} 36239 has_space=`$ECHO "$complete" | $GREP " "` 36240 if test "x$has_space" != x; then 36241 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 36242 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 36243 fi 36244 as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5 36245 fi 36246 fi 36247 36248 # Now join together the path and the arguments once again 36249 if test "x$arguments" != xEOL; then 36250 new_complete="$new_path ${arguments% *}" 36251 else 36252 new_complete="$new_path" 36253 fi 36254 36255 if test "x$complete" != "x$new_complete"; then 36256 CPP="$new_complete" 36257 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CPP to \"$new_complete\"" >&5 36258 $as_echo "$as_me: Rewriting CPP to \"$new_complete\"" >&6;} 36259 fi 36260 fi 36261 36262 ac_ext=cpp 36263 ac_cpp='$CXXCPP $CPPFLAGS' 36264 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 36265 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 36266 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 36267 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C++ preprocessor" >&5 36268 $as_echo_n "checking how to run the C++ preprocessor... " >&6; } 36269 if test -z "$CXXCPP"; then 36270 if ${ac_cv_prog_CXXCPP+:} false; then : 36271 $as_echo_n "(cached) " >&6 36272 else 36273 # Double quotes because CXXCPP needs to be expanded 36274 for CXXCPP in "$CXX -E" "/lib/cpp" 36275 do 36276 ac_preproc_ok=false 36277 for ac_cxx_preproc_warn_flag in '' yes 36278 do 36279 # Use a header file that comes with gcc, so configuring glibc 36280 # with a fresh cross-compiler works. 36281 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 36282 # <limits.h> exists even on freestanding compilers. 36283 # On the NeXT, cc -E runs the code through the compiler's parser, 36284 # not just through cpp. "Syntax error" is here to catch this case. 36285 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 36286 /* end confdefs.h. */ 36287 #ifdef __STDC__ 36288 # include <limits.h> 36289 #else 36290 # include <assert.h> 36291 #endif 36292 Syntax error 36293 _ACEOF 36294 if ac_fn_cxx_try_cpp "$LINENO"; then : 36295 36296 else 36297 # Broken: fails on valid input. 36298 continue 36299 fi 36300 rm -f conftest.err conftest.i conftest.$ac_ext 36301 36302 # OK, works on sane cases. Now check whether nonexistent headers 36303 # can be detected and how. 36304 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 36305 /* end confdefs.h. */ 36306 #include <ac_nonexistent.h> 36307 _ACEOF 36308 if ac_fn_cxx_try_cpp "$LINENO"; then : 36309 # Broken: success on invalid input. 36310 continue 36311 else 36312 # Passes both tests. 36313 ac_preproc_ok=: 36314 break 36315 fi 36316 rm -f conftest.err conftest.i conftest.$ac_ext 36317 36318 done 36319 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 36320 rm -f conftest.i conftest.err conftest.$ac_ext 36321 if $ac_preproc_ok; then : 36322 break 36323 fi 36324 36325 done 36326 ac_cv_prog_CXXCPP=$CXXCPP 36327 36328 fi 36329 CXXCPP=$ac_cv_prog_CXXCPP 36330 else 36331 ac_cv_prog_CXXCPP=$CXXCPP 36332 fi 36333 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXXCPP" >&5 36334 $as_echo "$CXXCPP" >&6; } 36335 ac_preproc_ok=false 36336 for ac_cxx_preproc_warn_flag in '' yes 36337 do 36338 # Use a header file that comes with gcc, so configuring glibc 36339 # with a fresh cross-compiler works. 36340 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 36341 # <limits.h> exists even on freestanding compilers. 36342 # On the NeXT, cc -E runs the code through the compiler's parser, 36343 # not just through cpp. "Syntax error" is here to catch this case. 36344 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 36345 /* end confdefs.h. */ 36346 #ifdef __STDC__ 36347 # include <limits.h> 36348 #else 36349 # include <assert.h> 36350 #endif 36351 Syntax error 36352 _ACEOF 36353 if ac_fn_cxx_try_cpp "$LINENO"; then : 36354 36355 else 36356 # Broken: fails on valid input. 36357 continue 36358 fi 36359 rm -f conftest.err conftest.i conftest.$ac_ext 36360 36361 # OK, works on sane cases. Now check whether nonexistent headers 36362 # can be detected and how. 36363 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 36364 /* end confdefs.h. */ 36365 #include <ac_nonexistent.h> 36366 _ACEOF 36367 if ac_fn_cxx_try_cpp "$LINENO"; then : 36368 # Broken: success on invalid input. 36369 continue 36370 else 36371 # Passes both tests. 36372 ac_preproc_ok=: 36373 break 36374 fi 36375 rm -f conftest.err conftest.i conftest.$ac_ext 36376 36377 done 36378 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 36379 rm -f conftest.i conftest.err conftest.$ac_ext 36380 if $ac_preproc_ok; then : 36381 36382 else 36383 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 36384 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 36385 as_fn_error $? "C++ preprocessor \"$CXXCPP\" fails sanity check 36386 See \`config.log' for more details" "$LINENO" 5; } 36387 fi 36388 36389 ac_ext=cpp 36390 ac_cpp='$CXXCPP $CPPFLAGS' 36391 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 36392 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 36393 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 36394 36395 36396 # Only process if variable expands to non-empty 36397 36398 if test "x$CXXCPP" != x; then 36399 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36400 36401 # First separate the path from the arguments. This will split at the first 36402 # space. 36403 complete="$CXXCPP" 36404 path="${complete%% *}" 36405 tmp="$complete EOL" 36406 arguments="${tmp#* }" 36407 36408 # Input might be given as Windows format, start by converting to 36409 # unix format. 36410 new_path=`$CYGPATH -u "$path"` 36411 36412 # Now try to locate executable using which 36413 new_path=`$WHICH "$new_path" 2> /dev/null` 36414 # bat and cmd files are not always considered executable in cygwin causing which 36415 # to not find them 36416 if test "x$new_path" = x \ 36417 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36418 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36419 new_path=`$CYGPATH -u "$path"` 36420 fi 36421 if test "x$new_path" = x; then 36422 # Oops. Which didn't find the executable. 36423 # The splitting of arguments from the executable at a space might have been incorrect, 36424 # since paths with space are more likely in Windows. Give it another try with the whole 36425 # argument. 36426 path="$complete" 36427 arguments="EOL" 36428 new_path=`$CYGPATH -u "$path"` 36429 new_path=`$WHICH "$new_path" 2> /dev/null` 36430 # bat and cmd files are not always considered executable in cygwin causing which 36431 # to not find them 36432 if test "x$new_path" = x \ 36433 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36434 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36435 new_path=`$CYGPATH -u "$path"` 36436 fi 36437 if test "x$new_path" = x; then 36438 # It's still not found. Now this is an unrecoverable error. 36439 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5 36440 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;} 36441 has_space=`$ECHO "$complete" | $GREP " "` 36442 if test "x$has_space" != x; then 36443 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 36444 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 36445 fi 36446 as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5 36447 fi 36448 fi 36449 36450 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 36451 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 36452 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 36453 # "foo.exe" is OK but "foo" is an error. 36454 # 36455 # This test is therefore slightly more accurate than "test -f" to check for file presence. 36456 # It is also a way to make sure we got the proper file name for the real test later on. 36457 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 36458 if test "x$test_shortpath" = x; then 36459 # Short path failed, file does not exist as specified. 36460 # Try adding .exe or .cmd 36461 if test -f "${new_path}.exe"; then 36462 input_to_shortpath="${new_path}.exe" 36463 elif test -f "${new_path}.cmd"; then 36464 input_to_shortpath="${new_path}.cmd" 36465 else 36466 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$new_path\", is invalid." >&5 36467 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$new_path\", is invalid." >&6;} 36468 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 36469 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 36470 as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5 36471 fi 36472 else 36473 input_to_shortpath="$new_path" 36474 fi 36475 36476 # Call helper function which possibly converts this using DOS-style short mode. 36477 # If so, the updated path is stored in $new_path. 36478 new_path="$input_to_shortpath" 36479 36480 input_path="$input_to_shortpath" 36481 # Check if we need to convert this using DOS-style short mode. If the path 36482 # contains just simple characters, use it. Otherwise (spaces, weird characters), 36483 # take no chances and rewrite it. 36484 # Note: m4 eats our [], so we need to use [ and ] instead. 36485 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 36486 if test "x$has_forbidden_chars" != x; then 36487 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 36488 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 36489 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 36490 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 36491 # Going to short mode and back again did indeed matter. Since short mode is 36492 # case insensitive, let's make it lowercase to improve readability. 36493 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 36494 # Now convert it back to Unix-style (cygpath) 36495 input_path=`$CYGPATH -u "$shortmode_path"` 36496 new_path="$input_path" 36497 fi 36498 fi 36499 36500 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 36501 if test "x$test_cygdrive_prefix" = x; then 36502 # As a simple fix, exclude /usr/bin since it's not a real path. 36503 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 36504 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 36505 # a path prefixed by /cygdrive for fixpath to work. 36506 new_path="$CYGWIN_ROOT_PATH$input_path" 36507 fi 36508 fi 36509 36510 # remove trailing .exe if any 36511 new_path="${new_path/%.exe/}" 36512 36513 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36514 36515 # First separate the path from the arguments. This will split at the first 36516 # space. 36517 complete="$CXXCPP" 36518 path="${complete%% *}" 36519 tmp="$complete EOL" 36520 arguments="${tmp#* }" 36521 36522 # Input might be given as Windows format, start by converting to 36523 # unix format. 36524 new_path="$path" 36525 36526 windows_path="$new_path" 36527 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36528 unix_path=`$CYGPATH -u "$windows_path"` 36529 new_path="$unix_path" 36530 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36531 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36532 new_path="$unix_path" 36533 fi 36534 36535 36536 # Now try to locate executable using which 36537 new_path=`$WHICH "$new_path" 2> /dev/null` 36538 36539 if test "x$new_path" = x; then 36540 # Oops. Which didn't find the executable. 36541 # The splitting of arguments from the executable at a space might have been incorrect, 36542 # since paths with space are more likely in Windows. Give it another try with the whole 36543 # argument. 36544 path="$complete" 36545 arguments="EOL" 36546 new_path="$path" 36547 36548 windows_path="$new_path" 36549 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36550 unix_path=`$CYGPATH -u "$windows_path"` 36551 new_path="$unix_path" 36552 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36553 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36554 new_path="$unix_path" 36555 fi 36556 36557 36558 new_path=`$WHICH "$new_path" 2> /dev/null` 36559 # bat and cmd files are not always considered executable in MSYS causing which 36560 # to not find them 36561 if test "x$new_path" = x \ 36562 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36563 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36564 new_path="$path" 36565 36566 windows_path="$new_path" 36567 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36568 unix_path=`$CYGPATH -u "$windows_path"` 36569 new_path="$unix_path" 36570 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36571 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36572 new_path="$unix_path" 36573 fi 36574 36575 fi 36576 36577 if test "x$new_path" = x; then 36578 # It's still not found. Now this is an unrecoverable error. 36579 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5 36580 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;} 36581 has_space=`$ECHO "$complete" | $GREP " "` 36582 if test "x$has_space" != x; then 36583 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 36584 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 36585 fi 36586 as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5 36587 fi 36588 fi 36589 36590 # Now new_path has a complete unix path to the binary 36591 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 36592 # Keep paths in /bin as-is, but remove trailing .exe if any 36593 new_path="${new_path/%.exe/}" 36594 # Do not save /bin paths to all_fixpath_prefixes! 36595 else 36596 # Not in mixed or Windows style, start by that. 36597 new_path=`cmd //c echo $new_path` 36598 36599 input_path="$new_path" 36600 # Check if we need to convert this using DOS-style short mode. If the path 36601 # contains just simple characters, use it. Otherwise (spaces, weird characters), 36602 # take no chances and rewrite it. 36603 # Note: m4 eats our [], so we need to use [ and ] instead. 36604 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 36605 if test "x$has_forbidden_chars" != x; then 36606 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 36607 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 36608 fi 36609 36610 # Output is in $new_path 36611 36612 windows_path="$new_path" 36613 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36614 unix_path=`$CYGPATH -u "$windows_path"` 36615 new_path="$unix_path" 36616 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36617 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36618 new_path="$unix_path" 36619 fi 36620 36621 # remove trailing .exe if any 36622 new_path="${new_path/%.exe/}" 36623 36624 # Save the first 10 bytes of this path to the storage, so fixpath can work. 36625 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 36626 fi 36627 36628 else 36629 # We're on a unix platform. Hooray! :) 36630 # First separate the path from the arguments. This will split at the first 36631 # space. 36632 complete="$CXXCPP" 36633 path="${complete%% *}" 36634 tmp="$complete EOL" 36635 arguments="${tmp#* }" 36636 36637 # Cannot rely on the command "which" here since it doesn't always work. 36638 is_absolute_path=`$ECHO "$path" | $GREP ^/` 36639 if test -z "$is_absolute_path"; then 36640 # Path to executable is not absolute. Find it. 36641 IFS_save="$IFS" 36642 IFS=: 36643 for p in $PATH; do 36644 if test -f "$p/$path" && test -x "$p/$path"; then 36645 new_path="$p/$path" 36646 break 36647 fi 36648 done 36649 IFS="$IFS_save" 36650 else 36651 # This is an absolute path, we can use it without further modifications. 36652 new_path="$path" 36653 fi 36654 36655 if test "x$new_path" = x; then 36656 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5 36657 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;} 36658 has_space=`$ECHO "$complete" | $GREP " "` 36659 if test "x$has_space" != x; then 36660 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 36661 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 36662 fi 36663 as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5 36664 fi 36665 fi 36666 36667 # Now join together the path and the arguments once again 36668 if test "x$arguments" != xEOL; then 36669 new_complete="$new_path ${arguments% *}" 36670 else 36671 new_complete="$new_path" 36672 fi 36673 36674 if test "x$complete" != "x$new_complete"; then 36675 CXXCPP="$new_complete" 36676 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CXXCPP to \"$new_complete\"" >&5 36677 $as_echo "$as_me: Rewriting CXXCPP to \"$new_complete\"" >&6;} 36678 fi 36679 fi 36680 36681 36682 # 36683 # Setup the linker (LD) 36684 # 36685 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 36686 # In the Microsoft toolchain we have a separate LD command "link". 36687 # Make sure we reject /usr/bin/link (as determined in CYGWIN_LINK), which is 36688 # a cygwin program for something completely different. 36689 # Extract the first word of "link", so it can be a program name with args. 36690 set dummy link; ac_word=$2 36691 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 36692 $as_echo_n "checking for $ac_word... " >&6; } 36693 if ${ac_cv_prog_LD+:} false; then : 36694 $as_echo_n "(cached) " >&6 36695 else 36696 if test -n "$LD"; then 36697 ac_cv_prog_LD="$LD" # Let the user override the test. 36698 else 36699 ac_prog_rejected=no 36700 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 36701 for as_dir in $PATH 36702 do 36703 IFS=$as_save_IFS 36704 test -z "$as_dir" && as_dir=. 36705 for ac_exec_ext in '' $ac_executable_extensions; do 36706 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 36707 if test "$as_dir/$ac_word$ac_exec_ext" = "$CYGWIN_LINK"; then 36708 ac_prog_rejected=yes 36709 continue 36710 fi 36711 ac_cv_prog_LD="link" 36712 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 36713 break 2 36714 fi 36715 done 36716 done 36717 IFS=$as_save_IFS 36718 36719 if test $ac_prog_rejected = yes; then 36720 # We found a bogon in the path, so make sure we never use it. 36721 set dummy $ac_cv_prog_LD 36722 shift 36723 if test $# != 0; then 36724 # We chose a different compiler from the bogus one. 36725 # However, it has the same basename, so the bogon will be chosen 36726 # first if we set LD to just the basename; use the full file name. 36727 shift 36728 ac_cv_prog_LD="$as_dir/$ac_word${1+' '}$@" 36729 fi 36730 fi 36731 fi 36732 fi 36733 LD=$ac_cv_prog_LD 36734 if test -n "$LD"; then 36735 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5 36736 $as_echo "$LD" >&6; } 36737 else 36738 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 36739 $as_echo "no" >&6; } 36740 fi 36741 36742 36743 36744 # Only process if variable expands to non-empty 36745 36746 if test "x$LD" != x; then 36747 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36748 36749 # First separate the path from the arguments. This will split at the first 36750 # space. 36751 complete="$LD" 36752 path="${complete%% *}" 36753 tmp="$complete EOL" 36754 arguments="${tmp#* }" 36755 36756 # Input might be given as Windows format, start by converting to 36757 # unix format. 36758 new_path=`$CYGPATH -u "$path"` 36759 36760 # Now try to locate executable using which 36761 new_path=`$WHICH "$new_path" 2> /dev/null` 36762 # bat and cmd files are not always considered executable in cygwin causing which 36763 # to not find them 36764 if test "x$new_path" = x \ 36765 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36766 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36767 new_path=`$CYGPATH -u "$path"` 36768 fi 36769 if test "x$new_path" = x; then 36770 # Oops. Which didn't find the executable. 36771 # The splitting of arguments from the executable at a space might have been incorrect, 36772 # since paths with space are more likely in Windows. Give it another try with the whole 36773 # argument. 36774 path="$complete" 36775 arguments="EOL" 36776 new_path=`$CYGPATH -u "$path"` 36777 new_path=`$WHICH "$new_path" 2> /dev/null` 36778 # bat and cmd files are not always considered executable in cygwin causing which 36779 # to not find them 36780 if test "x$new_path" = x \ 36781 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36782 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36783 new_path=`$CYGPATH -u "$path"` 36784 fi 36785 if test "x$new_path" = x; then 36786 # It's still not found. Now this is an unrecoverable error. 36787 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$complete\", is not found." >&5 36788 $as_echo "$as_me: The path of LD, which resolves as \"$complete\", is not found." >&6;} 36789 has_space=`$ECHO "$complete" | $GREP " "` 36790 if test "x$has_space" != x; then 36791 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 36792 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 36793 fi 36794 as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5 36795 fi 36796 fi 36797 36798 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 36799 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 36800 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 36801 # "foo.exe" is OK but "foo" is an error. 36802 # 36803 # This test is therefore slightly more accurate than "test -f" to check for file presence. 36804 # It is also a way to make sure we got the proper file name for the real test later on. 36805 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 36806 if test "x$test_shortpath" = x; then 36807 # Short path failed, file does not exist as specified. 36808 # Try adding .exe or .cmd 36809 if test -f "${new_path}.exe"; then 36810 input_to_shortpath="${new_path}.exe" 36811 elif test -f "${new_path}.cmd"; then 36812 input_to_shortpath="${new_path}.cmd" 36813 else 36814 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$new_path\", is invalid." >&5 36815 $as_echo "$as_me: The path of LD, which resolves as \"$new_path\", is invalid." >&6;} 36816 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 36817 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 36818 as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5 36819 fi 36820 else 36821 input_to_shortpath="$new_path" 36822 fi 36823 36824 # Call helper function which possibly converts this using DOS-style short mode. 36825 # If so, the updated path is stored in $new_path. 36826 new_path="$input_to_shortpath" 36827 36828 input_path="$input_to_shortpath" 36829 # Check if we need to convert this using DOS-style short mode. If the path 36830 # contains just simple characters, use it. Otherwise (spaces, weird characters), 36831 # take no chances and rewrite it. 36832 # Note: m4 eats our [], so we need to use [ and ] instead. 36833 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 36834 if test "x$has_forbidden_chars" != x; then 36835 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 36836 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 36837 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 36838 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 36839 # Going to short mode and back again did indeed matter. Since short mode is 36840 # case insensitive, let's make it lowercase to improve readability. 36841 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 36842 # Now convert it back to Unix-style (cygpath) 36843 input_path=`$CYGPATH -u "$shortmode_path"` 36844 new_path="$input_path" 36845 fi 36846 fi 36847 36848 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 36849 if test "x$test_cygdrive_prefix" = x; then 36850 # As a simple fix, exclude /usr/bin since it's not a real path. 36851 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 36852 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 36853 # a path prefixed by /cygdrive for fixpath to work. 36854 new_path="$CYGWIN_ROOT_PATH$input_path" 36855 fi 36856 fi 36857 36858 # remove trailing .exe if any 36859 new_path="${new_path/%.exe/}" 36860 36861 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36862 36863 # First separate the path from the arguments. This will split at the first 36864 # space. 36865 complete="$LD" 36866 path="${complete%% *}" 36867 tmp="$complete EOL" 36868 arguments="${tmp#* }" 36869 36870 # Input might be given as Windows format, start by converting to 36871 # unix format. 36872 new_path="$path" 36873 36874 windows_path="$new_path" 36875 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36876 unix_path=`$CYGPATH -u "$windows_path"` 36877 new_path="$unix_path" 36878 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36879 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36880 new_path="$unix_path" 36881 fi 36882 36883 36884 # Now try to locate executable using which 36885 new_path=`$WHICH "$new_path" 2> /dev/null` 36886 36887 if test "x$new_path" = x; then 36888 # Oops. Which didn't find the executable. 36889 # The splitting of arguments from the executable at a space might have been incorrect, 36890 # since paths with space are more likely in Windows. Give it another try with the whole 36891 # argument. 36892 path="$complete" 36893 arguments="EOL" 36894 new_path="$path" 36895 36896 windows_path="$new_path" 36897 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36898 unix_path=`$CYGPATH -u "$windows_path"` 36899 new_path="$unix_path" 36900 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36901 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36902 new_path="$unix_path" 36903 fi 36904 36905 36906 new_path=`$WHICH "$new_path" 2> /dev/null` 36907 # bat and cmd files are not always considered executable in MSYS causing which 36908 # to not find them 36909 if test "x$new_path" = x \ 36910 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36911 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36912 new_path="$path" 36913 36914 windows_path="$new_path" 36915 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36916 unix_path=`$CYGPATH -u "$windows_path"` 36917 new_path="$unix_path" 36918 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36919 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36920 new_path="$unix_path" 36921 fi 36922 36923 fi 36924 36925 if test "x$new_path" = x; then 36926 # It's still not found. Now this is an unrecoverable error. 36927 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$complete\", is not found." >&5 36928 $as_echo "$as_me: The path of LD, which resolves as \"$complete\", is not found." >&6;} 36929 has_space=`$ECHO "$complete" | $GREP " "` 36930 if test "x$has_space" != x; then 36931 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 36932 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 36933 fi 36934 as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5 36935 fi 36936 fi 36937 36938 # Now new_path has a complete unix path to the binary 36939 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 36940 # Keep paths in /bin as-is, but remove trailing .exe if any 36941 new_path="${new_path/%.exe/}" 36942 # Do not save /bin paths to all_fixpath_prefixes! 36943 else 36944 # Not in mixed or Windows style, start by that. 36945 new_path=`cmd //c echo $new_path` 36946 36947 input_path="$new_path" 36948 # Check if we need to convert this using DOS-style short mode. If the path 36949 # contains just simple characters, use it. Otherwise (spaces, weird characters), 36950 # take no chances and rewrite it. 36951 # Note: m4 eats our [], so we need to use [ and ] instead. 36952 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 36953 if test "x$has_forbidden_chars" != x; then 36954 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 36955 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 36956 fi 36957 36958 # Output is in $new_path 36959 36960 windows_path="$new_path" 36961 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36962 unix_path=`$CYGPATH -u "$windows_path"` 36963 new_path="$unix_path" 36964 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36965 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36966 new_path="$unix_path" 36967 fi 36968 36969 # remove trailing .exe if any 36970 new_path="${new_path/%.exe/}" 36971 36972 # Save the first 10 bytes of this path to the storage, so fixpath can work. 36973 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 36974 fi 36975 36976 else 36977 # We're on a unix platform. Hooray! :) 36978 # First separate the path from the arguments. This will split at the first 36979 # space. 36980 complete="$LD" 36981 path="${complete%% *}" 36982 tmp="$complete EOL" 36983 arguments="${tmp#* }" 36984 36985 # Cannot rely on the command "which" here since it doesn't always work. 36986 is_absolute_path=`$ECHO "$path" | $GREP ^/` 36987 if test -z "$is_absolute_path"; then 36988 # Path to executable is not absolute. Find it. 36989 IFS_save="$IFS" 36990 IFS=: 36991 for p in $PATH; do 36992 if test -f "$p/$path" && test -x "$p/$path"; then 36993 new_path="$p/$path" 36994 break 36995 fi 36996 done 36997 IFS="$IFS_save" 36998 else 36999 # This is an absolute path, we can use it without further modifications. 37000 new_path="$path" 37001 fi 37002 37003 if test "x$new_path" = x; then 37004 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$complete\", is not found." >&5 37005 $as_echo "$as_me: The path of LD, which resolves as \"$complete\", is not found." >&6;} 37006 has_space=`$ECHO "$complete" | $GREP " "` 37007 if test "x$has_space" != x; then 37008 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 37009 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 37010 fi 37011 as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5 37012 fi 37013 fi 37014 37015 # Now join together the path and the arguments once again 37016 if test "x$arguments" != xEOL; then 37017 new_complete="$new_path ${arguments% *}" 37018 else 37019 new_complete="$new_path" 37020 fi 37021 37022 if test "x$complete" != "x$new_complete"; then 37023 LD="$new_complete" 37024 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting LD to \"$new_complete\"" >&5 37025 $as_echo "$as_me: Rewriting LD to \"$new_complete\"" >&6;} 37026 fi 37027 fi 37028 37029 # Verify that we indeed succeeded with this trick. 37030 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the found link.exe is actually the Visual Studio linker" >&5 37031 $as_echo_n "checking if the found link.exe is actually the Visual Studio linker... " >&6; } 37032 "$LD" --version > /dev/null 37033 if test $? -eq 0 ; then 37034 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37035 $as_echo "no" >&6; } 37036 as_fn_error $? "This is the Cygwin link tool. Please check your PATH and rerun configure." "$LINENO" 5 37037 else 37038 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 37039 $as_echo "yes" >&6; } 37040 fi 37041 LDCXX="$LD" 37042 else 37043 # All other toolchains use the compiler to link. 37044 LD="$CC" 37045 LDCXX="$CXX" 37046 fi 37047 37048 # FIXME: it should be CXXLD, according to standard (cf CXXCPP) 37049 37050 37051 # 37052 # Setup the assembler (AS) 37053 # 37054 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 37055 37056 37057 # Publish this variable in the help. 37058 37059 37060 if [ -z "${AS+x}" ]; then 37061 # The variable is not set by user, try to locate tool using the code snippet 37062 for ac_prog in as 37063 do 37064 # Extract the first word of "$ac_prog", so it can be a program name with args. 37065 set dummy $ac_prog; ac_word=$2 37066 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37067 $as_echo_n "checking for $ac_word... " >&6; } 37068 if ${ac_cv_path_AS+:} false; then : 37069 $as_echo_n "(cached) " >&6 37070 else 37071 case $AS in 37072 [\\/]* | ?:[\\/]*) 37073 ac_cv_path_AS="$AS" # Let the user override the test with a path. 37074 ;; 37075 *) 37076 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37077 for as_dir in $PATH 37078 do 37079 IFS=$as_save_IFS 37080 test -z "$as_dir" && as_dir=. 37081 for ac_exec_ext in '' $ac_executable_extensions; do 37082 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37083 ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext" 37084 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37085 break 2 37086 fi 37087 done 37088 done 37089 IFS=$as_save_IFS 37090 37091 ;; 37092 esac 37093 fi 37094 AS=$ac_cv_path_AS 37095 if test -n "$AS"; then 37096 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5 37097 $as_echo "$AS" >&6; } 37098 else 37099 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37100 $as_echo "no" >&6; } 37101 fi 37102 37103 37104 test -n "$AS" && break 37105 done 37106 37107 else 37108 # The variable is set, but is it from the command line or the environment? 37109 37110 # Try to remove the string !AS! from our list. 37111 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AS!/} 37112 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 37113 # If it failed, the variable was not from the command line. Ignore it, 37114 # but warn the user (except for BASH, which is always set by the calling BASH). 37115 if test "xAS" != xBASH; then 37116 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AS from the environment. Use command line variables instead." >&5 37117 $as_echo "$as_me: WARNING: Ignoring value of AS from the environment. Use command line variables instead." >&2;} 37118 fi 37119 # Try to locate tool using the code snippet 37120 for ac_prog in as 37121 do 37122 # Extract the first word of "$ac_prog", so it can be a program name with args. 37123 set dummy $ac_prog; ac_word=$2 37124 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37125 $as_echo_n "checking for $ac_word... " >&6; } 37126 if ${ac_cv_path_AS+:} false; then : 37127 $as_echo_n "(cached) " >&6 37128 else 37129 case $AS in 37130 [\\/]* | ?:[\\/]*) 37131 ac_cv_path_AS="$AS" # Let the user override the test with a path. 37132 ;; 37133 *) 37134 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37135 for as_dir in $PATH 37136 do 37137 IFS=$as_save_IFS 37138 test -z "$as_dir" && as_dir=. 37139 for ac_exec_ext in '' $ac_executable_extensions; do 37140 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37141 ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext" 37142 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37143 break 2 37144 fi 37145 done 37146 done 37147 IFS=$as_save_IFS 37148 37149 ;; 37150 esac 37151 fi 37152 AS=$ac_cv_path_AS 37153 if test -n "$AS"; then 37154 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5 37155 $as_echo "$AS" >&6; } 37156 else 37157 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37158 $as_echo "no" >&6; } 37159 fi 37160 37161 37162 test -n "$AS" && break 37163 done 37164 37165 else 37166 # If it succeeded, then it was overridden by the user. We will use it 37167 # for the tool. 37168 37169 # First remove it from the list of overridden variables, so we can test 37170 # for unknown variables in the end. 37171 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 37172 37173 # Check if we try to supply an empty value 37174 if test "x$AS" = x; then 37175 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool AS= (no value)" >&5 37176 $as_echo "$as_me: Setting user supplied tool AS= (no value)" >&6;} 37177 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AS" >&5 37178 $as_echo_n "checking for AS... " >&6; } 37179 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 37180 $as_echo "disabled" >&6; } 37181 else 37182 # Check if the provided tool contains a complete path. 37183 tool_specified="$AS" 37184 tool_basename="${tool_specified##*/}" 37185 if test "x$tool_basename" = "x$tool_specified"; then 37186 # A command without a complete path is provided, search $PATH. 37187 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AS=$tool_basename" >&5 37188 $as_echo "$as_me: Will search for user supplied tool AS=$tool_basename" >&6;} 37189 # Extract the first word of "$tool_basename", so it can be a program name with args. 37190 set dummy $tool_basename; ac_word=$2 37191 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37192 $as_echo_n "checking for $ac_word... " >&6; } 37193 if ${ac_cv_path_AS+:} false; then : 37194 $as_echo_n "(cached) " >&6 37195 else 37196 case $AS in 37197 [\\/]* | ?:[\\/]*) 37198 ac_cv_path_AS="$AS" # Let the user override the test with a path. 37199 ;; 37200 *) 37201 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37202 for as_dir in $PATH 37203 do 37204 IFS=$as_save_IFS 37205 test -z "$as_dir" && as_dir=. 37206 for ac_exec_ext in '' $ac_executable_extensions; do 37207 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37208 ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext" 37209 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37210 break 2 37211 fi 37212 done 37213 done 37214 IFS=$as_save_IFS 37215 37216 ;; 37217 esac 37218 fi 37219 AS=$ac_cv_path_AS 37220 if test -n "$AS"; then 37221 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5 37222 $as_echo "$AS" >&6; } 37223 else 37224 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37225 $as_echo "no" >&6; } 37226 fi 37227 37228 37229 if test "x$AS" = x; then 37230 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 37231 fi 37232 else 37233 # Otherwise we believe it is a complete path. Use it as it is. 37234 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AS=$tool_specified" >&5 37235 $as_echo "$as_me: Will use user supplied tool AS=$tool_specified" >&6;} 37236 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AS" >&5 37237 $as_echo_n "checking for AS... " >&6; } 37238 if test ! -x "$tool_specified"; then 37239 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 37240 $as_echo "not found" >&6; } 37241 as_fn_error $? "User supplied tool AS=$tool_specified does not exist or is not executable" "$LINENO" 5 37242 fi 37243 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 37244 $as_echo "$tool_specified" >&6; } 37245 fi 37246 fi 37247 fi 37248 37249 fi 37250 37251 37252 37253 # Only process if variable expands to non-empty 37254 37255 if test "x$AS" != x; then 37256 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37257 37258 # First separate the path from the arguments. This will split at the first 37259 # space. 37260 complete="$AS" 37261 path="${complete%% *}" 37262 tmp="$complete EOL" 37263 arguments="${tmp#* }" 37264 37265 # Input might be given as Windows format, start by converting to 37266 # unix format. 37267 new_path=`$CYGPATH -u "$path"` 37268 37269 # Now try to locate executable using which 37270 new_path=`$WHICH "$new_path" 2> /dev/null` 37271 # bat and cmd files are not always considered executable in cygwin causing which 37272 # to not find them 37273 if test "x$new_path" = x \ 37274 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37275 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 37276 new_path=`$CYGPATH -u "$path"` 37277 fi 37278 if test "x$new_path" = x; then 37279 # Oops. Which didn't find the executable. 37280 # The splitting of arguments from the executable at a space might have been incorrect, 37281 # since paths with space are more likely in Windows. Give it another try with the whole 37282 # argument. 37283 path="$complete" 37284 arguments="EOL" 37285 new_path=`$CYGPATH -u "$path"` 37286 new_path=`$WHICH "$new_path" 2> /dev/null` 37287 # bat and cmd files are not always considered executable in cygwin causing which 37288 # to not find them 37289 if test "x$new_path" = x \ 37290 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37291 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 37292 new_path=`$CYGPATH -u "$path"` 37293 fi 37294 if test "x$new_path" = x; then 37295 # It's still not found. Now this is an unrecoverable error. 37296 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5 37297 $as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;} 37298 has_space=`$ECHO "$complete" | $GREP " "` 37299 if test "x$has_space" != x; then 37300 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 37301 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 37302 fi 37303 as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5 37304 fi 37305 fi 37306 37307 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 37308 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 37309 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 37310 # "foo.exe" is OK but "foo" is an error. 37311 # 37312 # This test is therefore slightly more accurate than "test -f" to check for file presence. 37313 # It is also a way to make sure we got the proper file name for the real test later on. 37314 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 37315 if test "x$test_shortpath" = x; then 37316 # Short path failed, file does not exist as specified. 37317 # Try adding .exe or .cmd 37318 if test -f "${new_path}.exe"; then 37319 input_to_shortpath="${new_path}.exe" 37320 elif test -f "${new_path}.cmd"; then 37321 input_to_shortpath="${new_path}.cmd" 37322 else 37323 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$new_path\", is invalid." >&5 37324 $as_echo "$as_me: The path of AS, which resolves as \"$new_path\", is invalid." >&6;} 37325 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 37326 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 37327 as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5 37328 fi 37329 else 37330 input_to_shortpath="$new_path" 37331 fi 37332 37333 # Call helper function which possibly converts this using DOS-style short mode. 37334 # If so, the updated path is stored in $new_path. 37335 new_path="$input_to_shortpath" 37336 37337 input_path="$input_to_shortpath" 37338 # Check if we need to convert this using DOS-style short mode. If the path 37339 # contains just simple characters, use it. Otherwise (spaces, weird characters), 37340 # take no chances and rewrite it. 37341 # Note: m4 eats our [], so we need to use [ and ] instead. 37342 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 37343 if test "x$has_forbidden_chars" != x; then 37344 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 37345 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 37346 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 37347 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 37348 # Going to short mode and back again did indeed matter. Since short mode is 37349 # case insensitive, let's make it lowercase to improve readability. 37350 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 37351 # Now convert it back to Unix-style (cygpath) 37352 input_path=`$CYGPATH -u "$shortmode_path"` 37353 new_path="$input_path" 37354 fi 37355 fi 37356 37357 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 37358 if test "x$test_cygdrive_prefix" = x; then 37359 # As a simple fix, exclude /usr/bin since it's not a real path. 37360 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 37361 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 37362 # a path prefixed by /cygdrive for fixpath to work. 37363 new_path="$CYGWIN_ROOT_PATH$input_path" 37364 fi 37365 fi 37366 37367 # remove trailing .exe if any 37368 new_path="${new_path/%.exe/}" 37369 37370 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37371 37372 # First separate the path from the arguments. This will split at the first 37373 # space. 37374 complete="$AS" 37375 path="${complete%% *}" 37376 tmp="$complete EOL" 37377 arguments="${tmp#* }" 37378 37379 # Input might be given as Windows format, start by converting to 37380 # unix format. 37381 new_path="$path" 37382 37383 windows_path="$new_path" 37384 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37385 unix_path=`$CYGPATH -u "$windows_path"` 37386 new_path="$unix_path" 37387 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37388 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37389 new_path="$unix_path" 37390 fi 37391 37392 37393 # Now try to locate executable using which 37394 new_path=`$WHICH "$new_path" 2> /dev/null` 37395 37396 if test "x$new_path" = x; then 37397 # Oops. Which didn't find the executable. 37398 # The splitting of arguments from the executable at a space might have been incorrect, 37399 # since paths with space are more likely in Windows. Give it another try with the whole 37400 # argument. 37401 path="$complete" 37402 arguments="EOL" 37403 new_path="$path" 37404 37405 windows_path="$new_path" 37406 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37407 unix_path=`$CYGPATH -u "$windows_path"` 37408 new_path="$unix_path" 37409 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37410 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37411 new_path="$unix_path" 37412 fi 37413 37414 37415 new_path=`$WHICH "$new_path" 2> /dev/null` 37416 # bat and cmd files are not always considered executable in MSYS causing which 37417 # to not find them 37418 if test "x$new_path" = x \ 37419 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37420 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 37421 new_path="$path" 37422 37423 windows_path="$new_path" 37424 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37425 unix_path=`$CYGPATH -u "$windows_path"` 37426 new_path="$unix_path" 37427 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37428 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37429 new_path="$unix_path" 37430 fi 37431 37432 fi 37433 37434 if test "x$new_path" = x; then 37435 # It's still not found. Now this is an unrecoverable error. 37436 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5 37437 $as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;} 37438 has_space=`$ECHO "$complete" | $GREP " "` 37439 if test "x$has_space" != x; then 37440 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 37441 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 37442 fi 37443 as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5 37444 fi 37445 fi 37446 37447 # Now new_path has a complete unix path to the binary 37448 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 37449 # Keep paths in /bin as-is, but remove trailing .exe if any 37450 new_path="${new_path/%.exe/}" 37451 # Do not save /bin paths to all_fixpath_prefixes! 37452 else 37453 # Not in mixed or Windows style, start by that. 37454 new_path=`cmd //c echo $new_path` 37455 37456 input_path="$new_path" 37457 # Check if we need to convert this using DOS-style short mode. If the path 37458 # contains just simple characters, use it. Otherwise (spaces, weird characters), 37459 # take no chances and rewrite it. 37460 # Note: m4 eats our [], so we need to use [ and ] instead. 37461 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 37462 if test "x$has_forbidden_chars" != x; then 37463 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 37464 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 37465 fi 37466 37467 # Output is in $new_path 37468 37469 windows_path="$new_path" 37470 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37471 unix_path=`$CYGPATH -u "$windows_path"` 37472 new_path="$unix_path" 37473 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37474 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37475 new_path="$unix_path" 37476 fi 37477 37478 # remove trailing .exe if any 37479 new_path="${new_path/%.exe/}" 37480 37481 # Save the first 10 bytes of this path to the storage, so fixpath can work. 37482 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 37483 fi 37484 37485 else 37486 # We're on a unix platform. Hooray! :) 37487 # First separate the path from the arguments. This will split at the first 37488 # space. 37489 complete="$AS" 37490 path="${complete%% *}" 37491 tmp="$complete EOL" 37492 arguments="${tmp#* }" 37493 37494 # Cannot rely on the command "which" here since it doesn't always work. 37495 is_absolute_path=`$ECHO "$path" | $GREP ^/` 37496 if test -z "$is_absolute_path"; then 37497 # Path to executable is not absolute. Find it. 37498 IFS_save="$IFS" 37499 IFS=: 37500 for p in $PATH; do 37501 if test -f "$p/$path" && test -x "$p/$path"; then 37502 new_path="$p/$path" 37503 break 37504 fi 37505 done 37506 IFS="$IFS_save" 37507 else 37508 # This is an absolute path, we can use it without further modifications. 37509 new_path="$path" 37510 fi 37511 37512 if test "x$new_path" = x; then 37513 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5 37514 $as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;} 37515 has_space=`$ECHO "$complete" | $GREP " "` 37516 if test "x$has_space" != x; then 37517 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 37518 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 37519 fi 37520 as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5 37521 fi 37522 fi 37523 37524 # Now join together the path and the arguments once again 37525 if test "x$arguments" != xEOL; then 37526 new_complete="$new_path ${arguments% *}" 37527 else 37528 new_complete="$new_path" 37529 fi 37530 37531 if test "x$complete" != "x$new_complete"; then 37532 AS="$new_complete" 37533 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting AS to \"$new_complete\"" >&5 37534 $as_echo "$as_me: Rewriting AS to \"$new_complete\"" >&6;} 37535 fi 37536 fi 37537 37538 if test "x$AS" = x; then 37539 as_fn_error $? "Solaris assembler (as) is required. Please install via \"pkg install pkg:/developer/assembler\"." "$LINENO" 5 37540 fi 37541 else 37542 # FIXME: is this correct for microsoft? 37543 AS="$CC -c" 37544 fi 37545 37546 37547 # 37548 # Setup the archiver (AR) 37549 # 37550 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 37551 # The corresponding ar tool is lib.exe (used to create static libraries) 37552 # Extract the first word of "lib", so it can be a program name with args. 37553 set dummy lib; ac_word=$2 37554 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37555 $as_echo_n "checking for $ac_word... " >&6; } 37556 if ${ac_cv_prog_AR+:} false; then : 37557 $as_echo_n "(cached) " >&6 37558 else 37559 if test -n "$AR"; then 37560 ac_cv_prog_AR="$AR" # Let the user override the test. 37561 else 37562 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37563 for as_dir in $PATH 37564 do 37565 IFS=$as_save_IFS 37566 test -z "$as_dir" && as_dir=. 37567 for ac_exec_ext in '' $ac_executable_extensions; do 37568 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37569 ac_cv_prog_AR="lib" 37570 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37571 break 2 37572 fi 37573 done 37574 done 37575 IFS=$as_save_IFS 37576 37577 fi 37578 fi 37579 AR=$ac_cv_prog_AR 37580 if test -n "$AR"; then 37581 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 37582 $as_echo "$AR" >&6; } 37583 else 37584 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37585 $as_echo "no" >&6; } 37586 fi 37587 37588 37589 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 37590 37591 37592 # Publish this variable in the help. 37593 37594 37595 if [ -z "${AR+x}" ]; then 37596 # The variable is not set by user, try to locate tool using the code snippet 37597 if test -n "$ac_tool_prefix"; then 37598 for ac_prog in ar gcc-ar 37599 do 37600 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 37601 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 37602 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37603 $as_echo_n "checking for $ac_word... " >&6; } 37604 if ${ac_cv_prog_AR+:} false; then : 37605 $as_echo_n "(cached) " >&6 37606 else 37607 if test -n "$AR"; then 37608 ac_cv_prog_AR="$AR" # Let the user override the test. 37609 else 37610 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37611 for as_dir in $PATH 37612 do 37613 IFS=$as_save_IFS 37614 test -z "$as_dir" && as_dir=. 37615 for ac_exec_ext in '' $ac_executable_extensions; do 37616 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37617 ac_cv_prog_AR="$ac_tool_prefix$ac_prog" 37618 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37619 break 2 37620 fi 37621 done 37622 done 37623 IFS=$as_save_IFS 37624 37625 fi 37626 fi 37627 AR=$ac_cv_prog_AR 37628 if test -n "$AR"; then 37629 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 37630 $as_echo "$AR" >&6; } 37631 else 37632 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37633 $as_echo "no" >&6; } 37634 fi 37635 37636 37637 test -n "$AR" && break 37638 done 37639 fi 37640 if test -z "$AR"; then 37641 ac_ct_AR=$AR 37642 for ac_prog in ar gcc-ar 37643 do 37644 # Extract the first word of "$ac_prog", so it can be a program name with args. 37645 set dummy $ac_prog; ac_word=$2 37646 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37647 $as_echo_n "checking for $ac_word... " >&6; } 37648 if ${ac_cv_prog_ac_ct_AR+:} false; then : 37649 $as_echo_n "(cached) " >&6 37650 else 37651 if test -n "$ac_ct_AR"; then 37652 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. 37653 else 37654 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37655 for as_dir in $PATH 37656 do 37657 IFS=$as_save_IFS 37658 test -z "$as_dir" && as_dir=. 37659 for ac_exec_ext in '' $ac_executable_extensions; do 37660 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37661 ac_cv_prog_ac_ct_AR="$ac_prog" 37662 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37663 break 2 37664 fi 37665 done 37666 done 37667 IFS=$as_save_IFS 37668 37669 fi 37670 fi 37671 ac_ct_AR=$ac_cv_prog_ac_ct_AR 37672 if test -n "$ac_ct_AR"; then 37673 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 37674 $as_echo "$ac_ct_AR" >&6; } 37675 else 37676 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37677 $as_echo "no" >&6; } 37678 fi 37679 37680 37681 test -n "$ac_ct_AR" && break 37682 done 37683 37684 if test "x$ac_ct_AR" = x; then 37685 AR="" 37686 else 37687 case $cross_compiling:$ac_tool_warned in 37688 yes:) 37689 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 37690 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 37691 ac_tool_warned=yes ;; 37692 esac 37693 AR=$ac_ct_AR 37694 fi 37695 fi 37696 37697 else 37698 # The variable is set, but is it from the command line or the environment? 37699 37700 # Try to remove the string !AR! from our list. 37701 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AR!/} 37702 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 37703 # If it failed, the variable was not from the command line. Ignore it, 37704 # but warn the user (except for BASH, which is always set by the calling BASH). 37705 if test "xAR" != xBASH; then 37706 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&5 37707 $as_echo "$as_me: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&2;} 37708 fi 37709 # Try to locate tool using the code snippet 37710 if test -n "$ac_tool_prefix"; then 37711 for ac_prog in ar gcc-ar 37712 do 37713 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 37714 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 37715 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37716 $as_echo_n "checking for $ac_word... " >&6; } 37717 if ${ac_cv_prog_AR+:} false; then : 37718 $as_echo_n "(cached) " >&6 37719 else 37720 if test -n "$AR"; then 37721 ac_cv_prog_AR="$AR" # Let the user override the test. 37722 else 37723 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37724 for as_dir in $PATH 37725 do 37726 IFS=$as_save_IFS 37727 test -z "$as_dir" && as_dir=. 37728 for ac_exec_ext in '' $ac_executable_extensions; do 37729 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37730 ac_cv_prog_AR="$ac_tool_prefix$ac_prog" 37731 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37732 break 2 37733 fi 37734 done 37735 done 37736 IFS=$as_save_IFS 37737 37738 fi 37739 fi 37740 AR=$ac_cv_prog_AR 37741 if test -n "$AR"; then 37742 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 37743 $as_echo "$AR" >&6; } 37744 else 37745 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37746 $as_echo "no" >&6; } 37747 fi 37748 37749 37750 test -n "$AR" && break 37751 done 37752 fi 37753 if test -z "$AR"; then 37754 ac_ct_AR=$AR 37755 for ac_prog in ar gcc-ar 37756 do 37757 # Extract the first word of "$ac_prog", so it can be a program name with args. 37758 set dummy $ac_prog; ac_word=$2 37759 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37760 $as_echo_n "checking for $ac_word... " >&6; } 37761 if ${ac_cv_prog_ac_ct_AR+:} false; then : 37762 $as_echo_n "(cached) " >&6 37763 else 37764 if test -n "$ac_ct_AR"; then 37765 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. 37766 else 37767 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37768 for as_dir in $PATH 37769 do 37770 IFS=$as_save_IFS 37771 test -z "$as_dir" && as_dir=. 37772 for ac_exec_ext in '' $ac_executable_extensions; do 37773 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37774 ac_cv_prog_ac_ct_AR="$ac_prog" 37775 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37776 break 2 37777 fi 37778 done 37779 done 37780 IFS=$as_save_IFS 37781 37782 fi 37783 fi 37784 ac_ct_AR=$ac_cv_prog_ac_ct_AR 37785 if test -n "$ac_ct_AR"; then 37786 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 37787 $as_echo "$ac_ct_AR" >&6; } 37788 else 37789 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37790 $as_echo "no" >&6; } 37791 fi 37792 37793 37794 test -n "$ac_ct_AR" && break 37795 done 37796 37797 if test "x$ac_ct_AR" = x; then 37798 AR="" 37799 else 37800 case $cross_compiling:$ac_tool_warned in 37801 yes:) 37802 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 37803 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 37804 ac_tool_warned=yes ;; 37805 esac 37806 AR=$ac_ct_AR 37807 fi 37808 fi 37809 37810 else 37811 # If it succeeded, then it was overridden by the user. We will use it 37812 # for the tool. 37813 37814 # First remove it from the list of overridden variables, so we can test 37815 # for unknown variables in the end. 37816 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 37817 37818 # Check if we try to supply an empty value 37819 if test "x$AR" = x; then 37820 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool AR= (no value)" >&5 37821 $as_echo "$as_me: Setting user supplied tool AR= (no value)" >&6;} 37822 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AR" >&5 37823 $as_echo_n "checking for AR... " >&6; } 37824 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 37825 $as_echo "disabled" >&6; } 37826 else 37827 # Check if the provided tool contains a complete path. 37828 tool_specified="$AR" 37829 tool_basename="${tool_specified##*/}" 37830 if test "x$tool_basename" = "x$tool_specified"; then 37831 # A command without a complete path is provided, search $PATH. 37832 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AR=$tool_basename" >&5 37833 $as_echo "$as_me: Will search for user supplied tool AR=$tool_basename" >&6;} 37834 # Extract the first word of "$tool_basename", so it can be a program name with args. 37835 set dummy $tool_basename; ac_word=$2 37836 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37837 $as_echo_n "checking for $ac_word... " >&6; } 37838 if ${ac_cv_path_AR+:} false; then : 37839 $as_echo_n "(cached) " >&6 37840 else 37841 case $AR in 37842 [\\/]* | ?:[\\/]*) 37843 ac_cv_path_AR="$AR" # Let the user override the test with a path. 37844 ;; 37845 *) 37846 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37847 for as_dir in $PATH 37848 do 37849 IFS=$as_save_IFS 37850 test -z "$as_dir" && as_dir=. 37851 for ac_exec_ext in '' $ac_executable_extensions; do 37852 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37853 ac_cv_path_AR="$as_dir/$ac_word$ac_exec_ext" 37854 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37855 break 2 37856 fi 37857 done 37858 done 37859 IFS=$as_save_IFS 37860 37861 ;; 37862 esac 37863 fi 37864 AR=$ac_cv_path_AR 37865 if test -n "$AR"; then 37866 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 37867 $as_echo "$AR" >&6; } 37868 else 37869 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37870 $as_echo "no" >&6; } 37871 fi 37872 37873 37874 if test "x$AR" = x; then 37875 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 37876 fi 37877 else 37878 # Otherwise we believe it is a complete path. Use it as it is. 37879 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AR=$tool_specified" >&5 37880 $as_echo "$as_me: Will use user supplied tool AR=$tool_specified" >&6;} 37881 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AR" >&5 37882 $as_echo_n "checking for AR... " >&6; } 37883 if test ! -x "$tool_specified"; then 37884 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 37885 $as_echo "not found" >&6; } 37886 as_fn_error $? "User supplied tool AR=$tool_specified does not exist or is not executable" "$LINENO" 5 37887 fi 37888 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 37889 $as_echo "$tool_specified" >&6; } 37890 fi 37891 fi 37892 fi 37893 37894 fi 37895 37896 37897 else 37898 37899 37900 # Publish this variable in the help. 37901 37902 37903 if [ -z "${AR+x}" ]; then 37904 # The variable is not set by user, try to locate tool using the code snippet 37905 if test -n "$ac_tool_prefix"; then 37906 for ac_prog in ar 37907 do 37908 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 37909 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 37910 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37911 $as_echo_n "checking for $ac_word... " >&6; } 37912 if ${ac_cv_prog_AR+:} false; then : 37913 $as_echo_n "(cached) " >&6 37914 else 37915 if test -n "$AR"; then 37916 ac_cv_prog_AR="$AR" # Let the user override the test. 37917 else 37918 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37919 for as_dir in $PATH 37920 do 37921 IFS=$as_save_IFS 37922 test -z "$as_dir" && as_dir=. 37923 for ac_exec_ext in '' $ac_executable_extensions; do 37924 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37925 ac_cv_prog_AR="$ac_tool_prefix$ac_prog" 37926 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37927 break 2 37928 fi 37929 done 37930 done 37931 IFS=$as_save_IFS 37932 37933 fi 37934 fi 37935 AR=$ac_cv_prog_AR 37936 if test -n "$AR"; then 37937 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 37938 $as_echo "$AR" >&6; } 37939 else 37940 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37941 $as_echo "no" >&6; } 37942 fi 37943 37944 37945 test -n "$AR" && break 37946 done 37947 fi 37948 if test -z "$AR"; then 37949 ac_ct_AR=$AR 37950 for ac_prog in ar 37951 do 37952 # Extract the first word of "$ac_prog", so it can be a program name with args. 37953 set dummy $ac_prog; ac_word=$2 37954 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37955 $as_echo_n "checking for $ac_word... " >&6; } 37956 if ${ac_cv_prog_ac_ct_AR+:} false; then : 37957 $as_echo_n "(cached) " >&6 37958 else 37959 if test -n "$ac_ct_AR"; then 37960 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. 37961 else 37962 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37963 for as_dir in $PATH 37964 do 37965 IFS=$as_save_IFS 37966 test -z "$as_dir" && as_dir=. 37967 for ac_exec_ext in '' $ac_executable_extensions; do 37968 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37969 ac_cv_prog_ac_ct_AR="$ac_prog" 37970 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37971 break 2 37972 fi 37973 done 37974 done 37975 IFS=$as_save_IFS 37976 37977 fi 37978 fi 37979 ac_ct_AR=$ac_cv_prog_ac_ct_AR 37980 if test -n "$ac_ct_AR"; then 37981 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 37982 $as_echo "$ac_ct_AR" >&6; } 37983 else 37984 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37985 $as_echo "no" >&6; } 37986 fi 37987 37988 37989 test -n "$ac_ct_AR" && break 37990 done 37991 37992 if test "x$ac_ct_AR" = x; then 37993 AR="" 37994 else 37995 case $cross_compiling:$ac_tool_warned in 37996 yes:) 37997 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 37998 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 37999 ac_tool_warned=yes ;; 38000 esac 38001 AR=$ac_ct_AR 38002 fi 38003 fi 38004 38005 else 38006 # The variable is set, but is it from the command line or the environment? 38007 38008 # Try to remove the string !AR! from our list. 38009 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AR!/} 38010 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 38011 # If it failed, the variable was not from the command line. Ignore it, 38012 # but warn the user (except for BASH, which is always set by the calling BASH). 38013 if test "xAR" != xBASH; then 38014 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&5 38015 $as_echo "$as_me: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&2;} 38016 fi 38017 # Try to locate tool using the code snippet 38018 if test -n "$ac_tool_prefix"; then 38019 for ac_prog in ar 38020 do 38021 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 38022 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 38023 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38024 $as_echo_n "checking for $ac_word... " >&6; } 38025 if ${ac_cv_prog_AR+:} false; then : 38026 $as_echo_n "(cached) " >&6 38027 else 38028 if test -n "$AR"; then 38029 ac_cv_prog_AR="$AR" # Let the user override the test. 38030 else 38031 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38032 for as_dir in $PATH 38033 do 38034 IFS=$as_save_IFS 38035 test -z "$as_dir" && as_dir=. 38036 for ac_exec_ext in '' $ac_executable_extensions; do 38037 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38038 ac_cv_prog_AR="$ac_tool_prefix$ac_prog" 38039 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38040 break 2 38041 fi 38042 done 38043 done 38044 IFS=$as_save_IFS 38045 38046 fi 38047 fi 38048 AR=$ac_cv_prog_AR 38049 if test -n "$AR"; then 38050 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 38051 $as_echo "$AR" >&6; } 38052 else 38053 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38054 $as_echo "no" >&6; } 38055 fi 38056 38057 38058 test -n "$AR" && break 38059 done 38060 fi 38061 if test -z "$AR"; then 38062 ac_ct_AR=$AR 38063 for ac_prog in ar 38064 do 38065 # Extract the first word of "$ac_prog", so it can be a program name with args. 38066 set dummy $ac_prog; ac_word=$2 38067 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38068 $as_echo_n "checking for $ac_word... " >&6; } 38069 if ${ac_cv_prog_ac_ct_AR+:} false; then : 38070 $as_echo_n "(cached) " >&6 38071 else 38072 if test -n "$ac_ct_AR"; then 38073 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. 38074 else 38075 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38076 for as_dir in $PATH 38077 do 38078 IFS=$as_save_IFS 38079 test -z "$as_dir" && as_dir=. 38080 for ac_exec_ext in '' $ac_executable_extensions; do 38081 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38082 ac_cv_prog_ac_ct_AR="$ac_prog" 38083 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38084 break 2 38085 fi 38086 done 38087 done 38088 IFS=$as_save_IFS 38089 38090 fi 38091 fi 38092 ac_ct_AR=$ac_cv_prog_ac_ct_AR 38093 if test -n "$ac_ct_AR"; then 38094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 38095 $as_echo "$ac_ct_AR" >&6; } 38096 else 38097 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38098 $as_echo "no" >&6; } 38099 fi 38100 38101 38102 test -n "$ac_ct_AR" && break 38103 done 38104 38105 if test "x$ac_ct_AR" = x; then 38106 AR="" 38107 else 38108 case $cross_compiling:$ac_tool_warned in 38109 yes:) 38110 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 38111 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 38112 ac_tool_warned=yes ;; 38113 esac 38114 AR=$ac_ct_AR 38115 fi 38116 fi 38117 38118 else 38119 # If it succeeded, then it was overridden by the user. We will use it 38120 # for the tool. 38121 38122 # First remove it from the list of overridden variables, so we can test 38123 # for unknown variables in the end. 38124 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 38125 38126 # Check if we try to supply an empty value 38127 if test "x$AR" = x; then 38128 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool AR= (no value)" >&5 38129 $as_echo "$as_me: Setting user supplied tool AR= (no value)" >&6;} 38130 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AR" >&5 38131 $as_echo_n "checking for AR... " >&6; } 38132 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 38133 $as_echo "disabled" >&6; } 38134 else 38135 # Check if the provided tool contains a complete path. 38136 tool_specified="$AR" 38137 tool_basename="${tool_specified##*/}" 38138 if test "x$tool_basename" = "x$tool_specified"; then 38139 # A command without a complete path is provided, search $PATH. 38140 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AR=$tool_basename" >&5 38141 $as_echo "$as_me: Will search for user supplied tool AR=$tool_basename" >&6;} 38142 # Extract the first word of "$tool_basename", so it can be a program name with args. 38143 set dummy $tool_basename; ac_word=$2 38144 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38145 $as_echo_n "checking for $ac_word... " >&6; } 38146 if ${ac_cv_path_AR+:} false; then : 38147 $as_echo_n "(cached) " >&6 38148 else 38149 case $AR in 38150 [\\/]* | ?:[\\/]*) 38151 ac_cv_path_AR="$AR" # Let the user override the test with a path. 38152 ;; 38153 *) 38154 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38155 for as_dir in $PATH 38156 do 38157 IFS=$as_save_IFS 38158 test -z "$as_dir" && as_dir=. 38159 for ac_exec_ext in '' $ac_executable_extensions; do 38160 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38161 ac_cv_path_AR="$as_dir/$ac_word$ac_exec_ext" 38162 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38163 break 2 38164 fi 38165 done 38166 done 38167 IFS=$as_save_IFS 38168 38169 ;; 38170 esac 38171 fi 38172 AR=$ac_cv_path_AR 38173 if test -n "$AR"; then 38174 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 38175 $as_echo "$AR" >&6; } 38176 else 38177 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38178 $as_echo "no" >&6; } 38179 fi 38180 38181 38182 if test "x$AR" = x; then 38183 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 38184 fi 38185 else 38186 # Otherwise we believe it is a complete path. Use it as it is. 38187 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AR=$tool_specified" >&5 38188 $as_echo "$as_me: Will use user supplied tool AR=$tool_specified" >&6;} 38189 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AR" >&5 38190 $as_echo_n "checking for AR... " >&6; } 38191 if test ! -x "$tool_specified"; then 38192 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 38193 $as_echo "not found" >&6; } 38194 as_fn_error $? "User supplied tool AR=$tool_specified does not exist or is not executable" "$LINENO" 5 38195 fi 38196 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 38197 $as_echo "$tool_specified" >&6; } 38198 fi 38199 fi 38200 fi 38201 38202 fi 38203 38204 38205 fi 38206 38207 # Only process if variable expands to non-empty 38208 38209 if test "x$AR" != x; then 38210 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38211 38212 # First separate the path from the arguments. This will split at the first 38213 # space. 38214 complete="$AR" 38215 path="${complete%% *}" 38216 tmp="$complete EOL" 38217 arguments="${tmp#* }" 38218 38219 # Input might be given as Windows format, start by converting to 38220 # unix format. 38221 new_path=`$CYGPATH -u "$path"` 38222 38223 # Now try to locate executable using which 38224 new_path=`$WHICH "$new_path" 2> /dev/null` 38225 # bat and cmd files are not always considered executable in cygwin causing which 38226 # to not find them 38227 if test "x$new_path" = x \ 38228 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38229 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38230 new_path=`$CYGPATH -u "$path"` 38231 fi 38232 if test "x$new_path" = x; then 38233 # Oops. Which didn't find the executable. 38234 # The splitting of arguments from the executable at a space might have been incorrect, 38235 # since paths with space are more likely in Windows. Give it another try with the whole 38236 # argument. 38237 path="$complete" 38238 arguments="EOL" 38239 new_path=`$CYGPATH -u "$path"` 38240 new_path=`$WHICH "$new_path" 2> /dev/null` 38241 # bat and cmd files are not always considered executable in cygwin causing which 38242 # to not find them 38243 if test "x$new_path" = x \ 38244 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38245 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38246 new_path=`$CYGPATH -u "$path"` 38247 fi 38248 if test "x$new_path" = x; then 38249 # It's still not found. Now this is an unrecoverable error. 38250 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5 38251 $as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;} 38252 has_space=`$ECHO "$complete" | $GREP " "` 38253 if test "x$has_space" != x; then 38254 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 38255 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 38256 fi 38257 as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5 38258 fi 38259 fi 38260 38261 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 38262 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 38263 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 38264 # "foo.exe" is OK but "foo" is an error. 38265 # 38266 # This test is therefore slightly more accurate than "test -f" to check for file presence. 38267 # It is also a way to make sure we got the proper file name for the real test later on. 38268 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 38269 if test "x$test_shortpath" = x; then 38270 # Short path failed, file does not exist as specified. 38271 # Try adding .exe or .cmd 38272 if test -f "${new_path}.exe"; then 38273 input_to_shortpath="${new_path}.exe" 38274 elif test -f "${new_path}.cmd"; then 38275 input_to_shortpath="${new_path}.cmd" 38276 else 38277 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$new_path\", is invalid." >&5 38278 $as_echo "$as_me: The path of AR, which resolves as \"$new_path\", is invalid." >&6;} 38279 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 38280 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 38281 as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5 38282 fi 38283 else 38284 input_to_shortpath="$new_path" 38285 fi 38286 38287 # Call helper function which possibly converts this using DOS-style short mode. 38288 # If so, the updated path is stored in $new_path. 38289 new_path="$input_to_shortpath" 38290 38291 input_path="$input_to_shortpath" 38292 # Check if we need to convert this using DOS-style short mode. If the path 38293 # contains just simple characters, use it. Otherwise (spaces, weird characters), 38294 # take no chances and rewrite it. 38295 # Note: m4 eats our [], so we need to use [ and ] instead. 38296 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 38297 if test "x$has_forbidden_chars" != x; then 38298 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 38299 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 38300 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 38301 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 38302 # Going to short mode and back again did indeed matter. Since short mode is 38303 # case insensitive, let's make it lowercase to improve readability. 38304 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 38305 # Now convert it back to Unix-style (cygpath) 38306 input_path=`$CYGPATH -u "$shortmode_path"` 38307 new_path="$input_path" 38308 fi 38309 fi 38310 38311 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 38312 if test "x$test_cygdrive_prefix" = x; then 38313 # As a simple fix, exclude /usr/bin since it's not a real path. 38314 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 38315 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 38316 # a path prefixed by /cygdrive for fixpath to work. 38317 new_path="$CYGWIN_ROOT_PATH$input_path" 38318 fi 38319 fi 38320 38321 # remove trailing .exe if any 38322 new_path="${new_path/%.exe/}" 38323 38324 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38325 38326 # First separate the path from the arguments. This will split at the first 38327 # space. 38328 complete="$AR" 38329 path="${complete%% *}" 38330 tmp="$complete EOL" 38331 arguments="${tmp#* }" 38332 38333 # Input might be given as Windows format, start by converting to 38334 # unix format. 38335 new_path="$path" 38336 38337 windows_path="$new_path" 38338 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38339 unix_path=`$CYGPATH -u "$windows_path"` 38340 new_path="$unix_path" 38341 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38342 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38343 new_path="$unix_path" 38344 fi 38345 38346 38347 # Now try to locate executable using which 38348 new_path=`$WHICH "$new_path" 2> /dev/null` 38349 38350 if test "x$new_path" = x; then 38351 # Oops. Which didn't find the executable. 38352 # The splitting of arguments from the executable at a space might have been incorrect, 38353 # since paths with space are more likely in Windows. Give it another try with the whole 38354 # argument. 38355 path="$complete" 38356 arguments="EOL" 38357 new_path="$path" 38358 38359 windows_path="$new_path" 38360 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38361 unix_path=`$CYGPATH -u "$windows_path"` 38362 new_path="$unix_path" 38363 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38364 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38365 new_path="$unix_path" 38366 fi 38367 38368 38369 new_path=`$WHICH "$new_path" 2> /dev/null` 38370 # bat and cmd files are not always considered executable in MSYS causing which 38371 # to not find them 38372 if test "x$new_path" = x \ 38373 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38374 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38375 new_path="$path" 38376 38377 windows_path="$new_path" 38378 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38379 unix_path=`$CYGPATH -u "$windows_path"` 38380 new_path="$unix_path" 38381 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38382 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38383 new_path="$unix_path" 38384 fi 38385 38386 fi 38387 38388 if test "x$new_path" = x; then 38389 # It's still not found. Now this is an unrecoverable error. 38390 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5 38391 $as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;} 38392 has_space=`$ECHO "$complete" | $GREP " "` 38393 if test "x$has_space" != x; then 38394 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 38395 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 38396 fi 38397 as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5 38398 fi 38399 fi 38400 38401 # Now new_path has a complete unix path to the binary 38402 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 38403 # Keep paths in /bin as-is, but remove trailing .exe if any 38404 new_path="${new_path/%.exe/}" 38405 # Do not save /bin paths to all_fixpath_prefixes! 38406 else 38407 # Not in mixed or Windows style, start by that. 38408 new_path=`cmd //c echo $new_path` 38409 38410 input_path="$new_path" 38411 # Check if we need to convert this using DOS-style short mode. If the path 38412 # contains just simple characters, use it. Otherwise (spaces, weird characters), 38413 # take no chances and rewrite it. 38414 # Note: m4 eats our [], so we need to use [ and ] instead. 38415 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 38416 if test "x$has_forbidden_chars" != x; then 38417 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 38418 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 38419 fi 38420 38421 # Output is in $new_path 38422 38423 windows_path="$new_path" 38424 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38425 unix_path=`$CYGPATH -u "$windows_path"` 38426 new_path="$unix_path" 38427 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38428 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38429 new_path="$unix_path" 38430 fi 38431 38432 # remove trailing .exe if any 38433 new_path="${new_path/%.exe/}" 38434 38435 # Save the first 10 bytes of this path to the storage, so fixpath can work. 38436 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 38437 fi 38438 38439 else 38440 # We're on a unix platform. Hooray! :) 38441 # First separate the path from the arguments. This will split at the first 38442 # space. 38443 complete="$AR" 38444 path="${complete%% *}" 38445 tmp="$complete EOL" 38446 arguments="${tmp#* }" 38447 38448 # Cannot rely on the command "which" here since it doesn't always work. 38449 is_absolute_path=`$ECHO "$path" | $GREP ^/` 38450 if test -z "$is_absolute_path"; then 38451 # Path to executable is not absolute. Find it. 38452 IFS_save="$IFS" 38453 IFS=: 38454 for p in $PATH; do 38455 if test -f "$p/$path" && test -x "$p/$path"; then 38456 new_path="$p/$path" 38457 break 38458 fi 38459 done 38460 IFS="$IFS_save" 38461 else 38462 # This is an absolute path, we can use it without further modifications. 38463 new_path="$path" 38464 fi 38465 38466 if test "x$new_path" = x; then 38467 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5 38468 $as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;} 38469 has_space=`$ECHO "$complete" | $GREP " "` 38470 if test "x$has_space" != x; then 38471 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 38472 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 38473 fi 38474 as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5 38475 fi 38476 fi 38477 38478 # Now join together the path and the arguments once again 38479 if test "x$arguments" != xEOL; then 38480 new_complete="$new_path ${arguments% *}" 38481 else 38482 new_complete="$new_path" 38483 fi 38484 38485 if test "x$complete" != "x$new_complete"; then 38486 AR="$new_complete" 38487 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting AR to \"$new_complete\"" >&5 38488 $as_echo "$as_me: Rewriting AR to \"$new_complete\"" >&6;} 38489 fi 38490 fi 38491 38492 38493 38494 if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then 38495 38496 38497 # Publish this variable in the help. 38498 38499 38500 if [ -z "${LIPO+x}" ]; then 38501 # The variable is not set by user, try to locate tool using the code snippet 38502 for ac_prog in lipo 38503 do 38504 # Extract the first word of "$ac_prog", so it can be a program name with args. 38505 set dummy $ac_prog; ac_word=$2 38506 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38507 $as_echo_n "checking for $ac_word... " >&6; } 38508 if ${ac_cv_path_LIPO+:} false; then : 38509 $as_echo_n "(cached) " >&6 38510 else 38511 case $LIPO in 38512 [\\/]* | ?:[\\/]*) 38513 ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path. 38514 ;; 38515 *) 38516 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38517 for as_dir in $PATH 38518 do 38519 IFS=$as_save_IFS 38520 test -z "$as_dir" && as_dir=. 38521 for ac_exec_ext in '' $ac_executable_extensions; do 38522 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38523 ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext" 38524 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38525 break 2 38526 fi 38527 done 38528 done 38529 IFS=$as_save_IFS 38530 38531 ;; 38532 esac 38533 fi 38534 LIPO=$ac_cv_path_LIPO 38535 if test -n "$LIPO"; then 38536 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 38537 $as_echo "$LIPO" >&6; } 38538 else 38539 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38540 $as_echo "no" >&6; } 38541 fi 38542 38543 38544 test -n "$LIPO" && break 38545 done 38546 38547 else 38548 # The variable is set, but is it from the command line or the environment? 38549 38550 # Try to remove the string !LIPO! from our list. 38551 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LIPO!/} 38552 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 38553 # If it failed, the variable was not from the command line. Ignore it, 38554 # but warn the user (except for BASH, which is always set by the calling BASH). 38555 if test "xLIPO" != xBASH; then 38556 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LIPO from the environment. Use command line variables instead." >&5 38557 $as_echo "$as_me: WARNING: Ignoring value of LIPO from the environment. Use command line variables instead." >&2;} 38558 fi 38559 # Try to locate tool using the code snippet 38560 for ac_prog in lipo 38561 do 38562 # Extract the first word of "$ac_prog", so it can be a program name with args. 38563 set dummy $ac_prog; ac_word=$2 38564 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38565 $as_echo_n "checking for $ac_word... " >&6; } 38566 if ${ac_cv_path_LIPO+:} false; then : 38567 $as_echo_n "(cached) " >&6 38568 else 38569 case $LIPO in 38570 [\\/]* | ?:[\\/]*) 38571 ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path. 38572 ;; 38573 *) 38574 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38575 for as_dir in $PATH 38576 do 38577 IFS=$as_save_IFS 38578 test -z "$as_dir" && as_dir=. 38579 for ac_exec_ext in '' $ac_executable_extensions; do 38580 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38581 ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext" 38582 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38583 break 2 38584 fi 38585 done 38586 done 38587 IFS=$as_save_IFS 38588 38589 ;; 38590 esac 38591 fi 38592 LIPO=$ac_cv_path_LIPO 38593 if test -n "$LIPO"; then 38594 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 38595 $as_echo "$LIPO" >&6; } 38596 else 38597 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38598 $as_echo "no" >&6; } 38599 fi 38600 38601 38602 test -n "$LIPO" && break 38603 done 38604 38605 else 38606 # If it succeeded, then it was overridden by the user. We will use it 38607 # for the tool. 38608 38609 # First remove it from the list of overridden variables, so we can test 38610 # for unknown variables in the end. 38611 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 38612 38613 # Check if we try to supply an empty value 38614 if test "x$LIPO" = x; then 38615 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool LIPO= (no value)" >&5 38616 $as_echo "$as_me: Setting user supplied tool LIPO= (no value)" >&6;} 38617 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIPO" >&5 38618 $as_echo_n "checking for LIPO... " >&6; } 38619 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 38620 $as_echo "disabled" >&6; } 38621 else 38622 # Check if the provided tool contains a complete path. 38623 tool_specified="$LIPO" 38624 tool_basename="${tool_specified##*/}" 38625 if test "x$tool_basename" = "x$tool_specified"; then 38626 # A command without a complete path is provided, search $PATH. 38627 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LIPO=$tool_basename" >&5 38628 $as_echo "$as_me: Will search for user supplied tool LIPO=$tool_basename" >&6;} 38629 # Extract the first word of "$tool_basename", so it can be a program name with args. 38630 set dummy $tool_basename; ac_word=$2 38631 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38632 $as_echo_n "checking for $ac_word... " >&6; } 38633 if ${ac_cv_path_LIPO+:} false; then : 38634 $as_echo_n "(cached) " >&6 38635 else 38636 case $LIPO in 38637 [\\/]* | ?:[\\/]*) 38638 ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path. 38639 ;; 38640 *) 38641 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38642 for as_dir in $PATH 38643 do 38644 IFS=$as_save_IFS 38645 test -z "$as_dir" && as_dir=. 38646 for ac_exec_ext in '' $ac_executable_extensions; do 38647 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38648 ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext" 38649 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38650 break 2 38651 fi 38652 done 38653 done 38654 IFS=$as_save_IFS 38655 38656 ;; 38657 esac 38658 fi 38659 LIPO=$ac_cv_path_LIPO 38660 if test -n "$LIPO"; then 38661 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 38662 $as_echo "$LIPO" >&6; } 38663 else 38664 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38665 $as_echo "no" >&6; } 38666 fi 38667 38668 38669 if test "x$LIPO" = x; then 38670 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 38671 fi 38672 else 38673 # Otherwise we believe it is a complete path. Use it as it is. 38674 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LIPO=$tool_specified" >&5 38675 $as_echo "$as_me: Will use user supplied tool LIPO=$tool_specified" >&6;} 38676 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIPO" >&5 38677 $as_echo_n "checking for LIPO... " >&6; } 38678 if test ! -x "$tool_specified"; then 38679 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 38680 $as_echo "not found" >&6; } 38681 as_fn_error $? "User supplied tool LIPO=$tool_specified does not exist or is not executable" "$LINENO" 5 38682 fi 38683 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 38684 $as_echo "$tool_specified" >&6; } 38685 fi 38686 fi 38687 fi 38688 38689 fi 38690 38691 38692 38693 # Only process if variable expands to non-empty 38694 38695 if test "x$LIPO" != x; then 38696 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38697 38698 # First separate the path from the arguments. This will split at the first 38699 # space. 38700 complete="$LIPO" 38701 path="${complete%% *}" 38702 tmp="$complete EOL" 38703 arguments="${tmp#* }" 38704 38705 # Input might be given as Windows format, start by converting to 38706 # unix format. 38707 new_path=`$CYGPATH -u "$path"` 38708 38709 # Now try to locate executable using which 38710 new_path=`$WHICH "$new_path" 2> /dev/null` 38711 # bat and cmd files are not always considered executable in cygwin causing which 38712 # to not find them 38713 if test "x$new_path" = x \ 38714 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38715 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38716 new_path=`$CYGPATH -u "$path"` 38717 fi 38718 if test "x$new_path" = x; then 38719 # Oops. Which didn't find the executable. 38720 # The splitting of arguments from the executable at a space might have been incorrect, 38721 # since paths with space are more likely in Windows. Give it another try with the whole 38722 # argument. 38723 path="$complete" 38724 arguments="EOL" 38725 new_path=`$CYGPATH -u "$path"` 38726 new_path=`$WHICH "$new_path" 2> /dev/null` 38727 # bat and cmd files are not always considered executable in cygwin causing which 38728 # to not find them 38729 if test "x$new_path" = x \ 38730 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38731 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38732 new_path=`$CYGPATH -u "$path"` 38733 fi 38734 if test "x$new_path" = x; then 38735 # It's still not found. Now this is an unrecoverable error. 38736 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5 38737 $as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;} 38738 has_space=`$ECHO "$complete" | $GREP " "` 38739 if test "x$has_space" != x; then 38740 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 38741 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 38742 fi 38743 as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5 38744 fi 38745 fi 38746 38747 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 38748 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 38749 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 38750 # "foo.exe" is OK but "foo" is an error. 38751 # 38752 # This test is therefore slightly more accurate than "test -f" to check for file presence. 38753 # It is also a way to make sure we got the proper file name for the real test later on. 38754 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 38755 if test "x$test_shortpath" = x; then 38756 # Short path failed, file does not exist as specified. 38757 # Try adding .exe or .cmd 38758 if test -f "${new_path}.exe"; then 38759 input_to_shortpath="${new_path}.exe" 38760 elif test -f "${new_path}.cmd"; then 38761 input_to_shortpath="${new_path}.cmd" 38762 else 38763 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$new_path\", is invalid." >&5 38764 $as_echo "$as_me: The path of LIPO, which resolves as \"$new_path\", is invalid." >&6;} 38765 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 38766 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 38767 as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5 38768 fi 38769 else 38770 input_to_shortpath="$new_path" 38771 fi 38772 38773 # Call helper function which possibly converts this using DOS-style short mode. 38774 # If so, the updated path is stored in $new_path. 38775 new_path="$input_to_shortpath" 38776 38777 input_path="$input_to_shortpath" 38778 # Check if we need to convert this using DOS-style short mode. If the path 38779 # contains just simple characters, use it. Otherwise (spaces, weird characters), 38780 # take no chances and rewrite it. 38781 # Note: m4 eats our [], so we need to use [ and ] instead. 38782 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 38783 if test "x$has_forbidden_chars" != x; then 38784 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 38785 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 38786 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 38787 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 38788 # Going to short mode and back again did indeed matter. Since short mode is 38789 # case insensitive, let's make it lowercase to improve readability. 38790 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 38791 # Now convert it back to Unix-style (cygpath) 38792 input_path=`$CYGPATH -u "$shortmode_path"` 38793 new_path="$input_path" 38794 fi 38795 fi 38796 38797 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 38798 if test "x$test_cygdrive_prefix" = x; then 38799 # As a simple fix, exclude /usr/bin since it's not a real path. 38800 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 38801 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 38802 # a path prefixed by /cygdrive for fixpath to work. 38803 new_path="$CYGWIN_ROOT_PATH$input_path" 38804 fi 38805 fi 38806 38807 # remove trailing .exe if any 38808 new_path="${new_path/%.exe/}" 38809 38810 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38811 38812 # First separate the path from the arguments. This will split at the first 38813 # space. 38814 complete="$LIPO" 38815 path="${complete%% *}" 38816 tmp="$complete EOL" 38817 arguments="${tmp#* }" 38818 38819 # Input might be given as Windows format, start by converting to 38820 # unix format. 38821 new_path="$path" 38822 38823 windows_path="$new_path" 38824 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38825 unix_path=`$CYGPATH -u "$windows_path"` 38826 new_path="$unix_path" 38827 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38828 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38829 new_path="$unix_path" 38830 fi 38831 38832 38833 # Now try to locate executable using which 38834 new_path=`$WHICH "$new_path" 2> /dev/null` 38835 38836 if test "x$new_path" = x; then 38837 # Oops. Which didn't find the executable. 38838 # The splitting of arguments from the executable at a space might have been incorrect, 38839 # since paths with space are more likely in Windows. Give it another try with the whole 38840 # argument. 38841 path="$complete" 38842 arguments="EOL" 38843 new_path="$path" 38844 38845 windows_path="$new_path" 38846 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38847 unix_path=`$CYGPATH -u "$windows_path"` 38848 new_path="$unix_path" 38849 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38850 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38851 new_path="$unix_path" 38852 fi 38853 38854 38855 new_path=`$WHICH "$new_path" 2> /dev/null` 38856 # bat and cmd files are not always considered executable in MSYS causing which 38857 # to not find them 38858 if test "x$new_path" = x \ 38859 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38860 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38861 new_path="$path" 38862 38863 windows_path="$new_path" 38864 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38865 unix_path=`$CYGPATH -u "$windows_path"` 38866 new_path="$unix_path" 38867 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38868 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38869 new_path="$unix_path" 38870 fi 38871 38872 fi 38873 38874 if test "x$new_path" = x; then 38875 # It's still not found. Now this is an unrecoverable error. 38876 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5 38877 $as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;} 38878 has_space=`$ECHO "$complete" | $GREP " "` 38879 if test "x$has_space" != x; then 38880 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 38881 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 38882 fi 38883 as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5 38884 fi 38885 fi 38886 38887 # Now new_path has a complete unix path to the binary 38888 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 38889 # Keep paths in /bin as-is, but remove trailing .exe if any 38890 new_path="${new_path/%.exe/}" 38891 # Do not save /bin paths to all_fixpath_prefixes! 38892 else 38893 # Not in mixed or Windows style, start by that. 38894 new_path=`cmd //c echo $new_path` 38895 38896 input_path="$new_path" 38897 # Check if we need to convert this using DOS-style short mode. If the path 38898 # contains just simple characters, use it. Otherwise (spaces, weird characters), 38899 # take no chances and rewrite it. 38900 # Note: m4 eats our [], so we need to use [ and ] instead. 38901 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 38902 if test "x$has_forbidden_chars" != x; then 38903 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 38904 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 38905 fi 38906 38907 # Output is in $new_path 38908 38909 windows_path="$new_path" 38910 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38911 unix_path=`$CYGPATH -u "$windows_path"` 38912 new_path="$unix_path" 38913 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38914 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38915 new_path="$unix_path" 38916 fi 38917 38918 # remove trailing .exe if any 38919 new_path="${new_path/%.exe/}" 38920 38921 # Save the first 10 bytes of this path to the storage, so fixpath can work. 38922 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 38923 fi 38924 38925 else 38926 # We're on a unix platform. Hooray! :) 38927 # First separate the path from the arguments. This will split at the first 38928 # space. 38929 complete="$LIPO" 38930 path="${complete%% *}" 38931 tmp="$complete EOL" 38932 arguments="${tmp#* }" 38933 38934 # Cannot rely on the command "which" here since it doesn't always work. 38935 is_absolute_path=`$ECHO "$path" | $GREP ^/` 38936 if test -z "$is_absolute_path"; then 38937 # Path to executable is not absolute. Find it. 38938 IFS_save="$IFS" 38939 IFS=: 38940 for p in $PATH; do 38941 if test -f "$p/$path" && test -x "$p/$path"; then 38942 new_path="$p/$path" 38943 break 38944 fi 38945 done 38946 IFS="$IFS_save" 38947 else 38948 # This is an absolute path, we can use it without further modifications. 38949 new_path="$path" 38950 fi 38951 38952 if test "x$new_path" = x; then 38953 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5 38954 $as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;} 38955 has_space=`$ECHO "$complete" | $GREP " "` 38956 if test "x$has_space" != x; then 38957 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 38958 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 38959 fi 38960 as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5 38961 fi 38962 fi 38963 38964 # Now join together the path and the arguments once again 38965 if test "x$arguments" != xEOL; then 38966 new_complete="$new_path ${arguments% *}" 38967 else 38968 new_complete="$new_path" 38969 fi 38970 38971 if test "x$complete" != "x$new_complete"; then 38972 LIPO="$new_complete" 38973 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting LIPO to \"$new_complete\"" >&5 38974 $as_echo "$as_me: Rewriting LIPO to \"$new_complete\"" >&6;} 38975 fi 38976 fi 38977 38978 fi 38979 38980 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 38981 # Extract the first word of "mt", so it can be a program name with args. 38982 set dummy mt; ac_word=$2 38983 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38984 $as_echo_n "checking for $ac_word... " >&6; } 38985 if ${ac_cv_prog_MT+:} false; then : 38986 $as_echo_n "(cached) " >&6 38987 else 38988 if test -n "$MT"; then 38989 ac_cv_prog_MT="$MT" # Let the user override the test. 38990 else 38991 ac_prog_rejected=no 38992 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38993 for as_dir in $PATH 38994 do 38995 IFS=$as_save_IFS 38996 test -z "$as_dir" && as_dir=. 38997 for ac_exec_ext in '' $ac_executable_extensions; do 38998 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38999 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/bin/mt"; then 39000 ac_prog_rejected=yes 39001 continue 39002 fi 39003 ac_cv_prog_MT="mt" 39004 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 39005 break 2 39006 fi 39007 done 39008 done 39009 IFS=$as_save_IFS 39010 39011 if test $ac_prog_rejected = yes; then 39012 # We found a bogon in the path, so make sure we never use it. 39013 set dummy $ac_cv_prog_MT 39014 shift 39015 if test $# != 0; then 39016 # We chose a different compiler from the bogus one. 39017 # However, it has the same basename, so the bogon will be chosen 39018 # first if we set MT to just the basename; use the full file name. 39019 shift 39020 ac_cv_prog_MT="$as_dir/$ac_word${1+' '}$@" 39021 fi 39022 fi 39023 fi 39024 fi 39025 MT=$ac_cv_prog_MT 39026 if test -n "$MT"; then 39027 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MT" >&5 39028 $as_echo "$MT" >&6; } 39029 else 39030 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 39031 $as_echo "no" >&6; } 39032 fi 39033 39034 39035 39036 # Only process if variable expands to non-empty 39037 39038 if test "x$MT" != x; then 39039 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39040 39041 # First separate the path from the arguments. This will split at the first 39042 # space. 39043 complete="$MT" 39044 path="${complete%% *}" 39045 tmp="$complete EOL" 39046 arguments="${tmp#* }" 39047 39048 # Input might be given as Windows format, start by converting to 39049 # unix format. 39050 new_path=`$CYGPATH -u "$path"` 39051 39052 # Now try to locate executable using which 39053 new_path=`$WHICH "$new_path" 2> /dev/null` 39054 # bat and cmd files are not always considered executable in cygwin causing which 39055 # to not find them 39056 if test "x$new_path" = x \ 39057 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39058 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39059 new_path=`$CYGPATH -u "$path"` 39060 fi 39061 if test "x$new_path" = x; then 39062 # Oops. Which didn't find the executable. 39063 # The splitting of arguments from the executable at a space might have been incorrect, 39064 # since paths with space are more likely in Windows. Give it another try with the whole 39065 # argument. 39066 path="$complete" 39067 arguments="EOL" 39068 new_path=`$CYGPATH -u "$path"` 39069 new_path=`$WHICH "$new_path" 2> /dev/null` 39070 # bat and cmd files are not always considered executable in cygwin causing which 39071 # to not find them 39072 if test "x$new_path" = x \ 39073 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39074 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39075 new_path=`$CYGPATH -u "$path"` 39076 fi 39077 if test "x$new_path" = x; then 39078 # It's still not found. Now this is an unrecoverable error. 39079 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5 39080 $as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;} 39081 has_space=`$ECHO "$complete" | $GREP " "` 39082 if test "x$has_space" != x; then 39083 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 39084 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 39085 fi 39086 as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5 39087 fi 39088 fi 39089 39090 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 39091 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 39092 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 39093 # "foo.exe" is OK but "foo" is an error. 39094 # 39095 # This test is therefore slightly more accurate than "test -f" to check for file presence. 39096 # It is also a way to make sure we got the proper file name for the real test later on. 39097 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 39098 if test "x$test_shortpath" = x; then 39099 # Short path failed, file does not exist as specified. 39100 # Try adding .exe or .cmd 39101 if test -f "${new_path}.exe"; then 39102 input_to_shortpath="${new_path}.exe" 39103 elif test -f "${new_path}.cmd"; then 39104 input_to_shortpath="${new_path}.cmd" 39105 else 39106 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$new_path\", is invalid." >&5 39107 $as_echo "$as_me: The path of MT, which resolves as \"$new_path\", is invalid." >&6;} 39108 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 39109 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 39110 as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5 39111 fi 39112 else 39113 input_to_shortpath="$new_path" 39114 fi 39115 39116 # Call helper function which possibly converts this using DOS-style short mode. 39117 # If so, the updated path is stored in $new_path. 39118 new_path="$input_to_shortpath" 39119 39120 input_path="$input_to_shortpath" 39121 # Check if we need to convert this using DOS-style short mode. If the path 39122 # contains just simple characters, use it. Otherwise (spaces, weird characters), 39123 # take no chances and rewrite it. 39124 # Note: m4 eats our [], so we need to use [ and ] instead. 39125 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 39126 if test "x$has_forbidden_chars" != x; then 39127 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 39128 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 39129 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 39130 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 39131 # Going to short mode and back again did indeed matter. Since short mode is 39132 # case insensitive, let's make it lowercase to improve readability. 39133 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39134 # Now convert it back to Unix-style (cygpath) 39135 input_path=`$CYGPATH -u "$shortmode_path"` 39136 new_path="$input_path" 39137 fi 39138 fi 39139 39140 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 39141 if test "x$test_cygdrive_prefix" = x; then 39142 # As a simple fix, exclude /usr/bin since it's not a real path. 39143 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 39144 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 39145 # a path prefixed by /cygdrive for fixpath to work. 39146 new_path="$CYGWIN_ROOT_PATH$input_path" 39147 fi 39148 fi 39149 39150 # remove trailing .exe if any 39151 new_path="${new_path/%.exe/}" 39152 39153 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39154 39155 # First separate the path from the arguments. This will split at the first 39156 # space. 39157 complete="$MT" 39158 path="${complete%% *}" 39159 tmp="$complete EOL" 39160 arguments="${tmp#* }" 39161 39162 # Input might be given as Windows format, start by converting to 39163 # unix format. 39164 new_path="$path" 39165 39166 windows_path="$new_path" 39167 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39168 unix_path=`$CYGPATH -u "$windows_path"` 39169 new_path="$unix_path" 39170 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39171 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39172 new_path="$unix_path" 39173 fi 39174 39175 39176 # Now try to locate executable using which 39177 new_path=`$WHICH "$new_path" 2> /dev/null` 39178 39179 if test "x$new_path" = x; then 39180 # Oops. Which didn't find the executable. 39181 # The splitting of arguments from the executable at a space might have been incorrect, 39182 # since paths with space are more likely in Windows. Give it another try with the whole 39183 # argument. 39184 path="$complete" 39185 arguments="EOL" 39186 new_path="$path" 39187 39188 windows_path="$new_path" 39189 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39190 unix_path=`$CYGPATH -u "$windows_path"` 39191 new_path="$unix_path" 39192 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39193 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39194 new_path="$unix_path" 39195 fi 39196 39197 39198 new_path=`$WHICH "$new_path" 2> /dev/null` 39199 # bat and cmd files are not always considered executable in MSYS causing which 39200 # to not find them 39201 if test "x$new_path" = x \ 39202 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39203 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39204 new_path="$path" 39205 39206 windows_path="$new_path" 39207 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39208 unix_path=`$CYGPATH -u "$windows_path"` 39209 new_path="$unix_path" 39210 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39211 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39212 new_path="$unix_path" 39213 fi 39214 39215 fi 39216 39217 if test "x$new_path" = x; then 39218 # It's still not found. Now this is an unrecoverable error. 39219 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5 39220 $as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;} 39221 has_space=`$ECHO "$complete" | $GREP " "` 39222 if test "x$has_space" != x; then 39223 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 39224 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 39225 fi 39226 as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5 39227 fi 39228 fi 39229 39230 # Now new_path has a complete unix path to the binary 39231 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 39232 # Keep paths in /bin as-is, but remove trailing .exe if any 39233 new_path="${new_path/%.exe/}" 39234 # Do not save /bin paths to all_fixpath_prefixes! 39235 else 39236 # Not in mixed or Windows style, start by that. 39237 new_path=`cmd //c echo $new_path` 39238 39239 input_path="$new_path" 39240 # Check if we need to convert this using DOS-style short mode. If the path 39241 # contains just simple characters, use it. Otherwise (spaces, weird characters), 39242 # take no chances and rewrite it. 39243 # Note: m4 eats our [], so we need to use [ and ] instead. 39244 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 39245 if test "x$has_forbidden_chars" != x; then 39246 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 39247 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39248 fi 39249 39250 # Output is in $new_path 39251 39252 windows_path="$new_path" 39253 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39254 unix_path=`$CYGPATH -u "$windows_path"` 39255 new_path="$unix_path" 39256 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39257 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39258 new_path="$unix_path" 39259 fi 39260 39261 # remove trailing .exe if any 39262 new_path="${new_path/%.exe/}" 39263 39264 # Save the first 10 bytes of this path to the storage, so fixpath can work. 39265 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 39266 fi 39267 39268 else 39269 # We're on a unix platform. Hooray! :) 39270 # First separate the path from the arguments. This will split at the first 39271 # space. 39272 complete="$MT" 39273 path="${complete%% *}" 39274 tmp="$complete EOL" 39275 arguments="${tmp#* }" 39276 39277 # Cannot rely on the command "which" here since it doesn't always work. 39278 is_absolute_path=`$ECHO "$path" | $GREP ^/` 39279 if test -z "$is_absolute_path"; then 39280 # Path to executable is not absolute. Find it. 39281 IFS_save="$IFS" 39282 IFS=: 39283 for p in $PATH; do 39284 if test -f "$p/$path" && test -x "$p/$path"; then 39285 new_path="$p/$path" 39286 break 39287 fi 39288 done 39289 IFS="$IFS_save" 39290 else 39291 # This is an absolute path, we can use it without further modifications. 39292 new_path="$path" 39293 fi 39294 39295 if test "x$new_path" = x; then 39296 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5 39297 $as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;} 39298 has_space=`$ECHO "$complete" | $GREP " "` 39299 if test "x$has_space" != x; then 39300 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 39301 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 39302 fi 39303 as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5 39304 fi 39305 fi 39306 39307 # Now join together the path and the arguments once again 39308 if test "x$arguments" != xEOL; then 39309 new_complete="$new_path ${arguments% *}" 39310 else 39311 new_complete="$new_path" 39312 fi 39313 39314 if test "x$complete" != "x$new_complete"; then 39315 MT="$new_complete" 39316 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MT to \"$new_complete\"" >&5 39317 $as_echo "$as_me: Rewriting MT to \"$new_complete\"" >&6;} 39318 fi 39319 fi 39320 39321 # Setup the resource compiler (RC) 39322 # Extract the first word of "rc", so it can be a program name with args. 39323 set dummy rc; ac_word=$2 39324 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 39325 $as_echo_n "checking for $ac_word... " >&6; } 39326 if ${ac_cv_prog_RC+:} false; then : 39327 $as_echo_n "(cached) " >&6 39328 else 39329 if test -n "$RC"; then 39330 ac_cv_prog_RC="$RC" # Let the user override the test. 39331 else 39332 ac_prog_rejected=no 39333 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 39334 for as_dir in $PATH 39335 do 39336 IFS=$as_save_IFS 39337 test -z "$as_dir" && as_dir=. 39338 for ac_exec_ext in '' $ac_executable_extensions; do 39339 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 39340 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/bin/rc"; then 39341 ac_prog_rejected=yes 39342 continue 39343 fi 39344 ac_cv_prog_RC="rc" 39345 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 39346 break 2 39347 fi 39348 done 39349 done 39350 IFS=$as_save_IFS 39351 39352 if test $ac_prog_rejected = yes; then 39353 # We found a bogon in the path, so make sure we never use it. 39354 set dummy $ac_cv_prog_RC 39355 shift 39356 if test $# != 0; then 39357 # We chose a different compiler from the bogus one. 39358 # However, it has the same basename, so the bogon will be chosen 39359 # first if we set RC to just the basename; use the full file name. 39360 shift 39361 ac_cv_prog_RC="$as_dir/$ac_word${1+' '}$@" 39362 fi 39363 fi 39364 fi 39365 fi 39366 RC=$ac_cv_prog_RC 39367 if test -n "$RC"; then 39368 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RC" >&5 39369 $as_echo "$RC" >&6; } 39370 else 39371 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 39372 $as_echo "no" >&6; } 39373 fi 39374 39375 39376 39377 # Only process if variable expands to non-empty 39378 39379 if test "x$RC" != x; then 39380 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39381 39382 # First separate the path from the arguments. This will split at the first 39383 # space. 39384 complete="$RC" 39385 path="${complete%% *}" 39386 tmp="$complete EOL" 39387 arguments="${tmp#* }" 39388 39389 # Input might be given as Windows format, start by converting to 39390 # unix format. 39391 new_path=`$CYGPATH -u "$path"` 39392 39393 # Now try to locate executable using which 39394 new_path=`$WHICH "$new_path" 2> /dev/null` 39395 # bat and cmd files are not always considered executable in cygwin causing which 39396 # to not find them 39397 if test "x$new_path" = x \ 39398 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39399 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39400 new_path=`$CYGPATH -u "$path"` 39401 fi 39402 if test "x$new_path" = x; then 39403 # Oops. Which didn't find the executable. 39404 # The splitting of arguments from the executable at a space might have been incorrect, 39405 # since paths with space are more likely in Windows. Give it another try with the whole 39406 # argument. 39407 path="$complete" 39408 arguments="EOL" 39409 new_path=`$CYGPATH -u "$path"` 39410 new_path=`$WHICH "$new_path" 2> /dev/null` 39411 # bat and cmd files are not always considered executable in cygwin causing which 39412 # to not find them 39413 if test "x$new_path" = x \ 39414 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39415 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39416 new_path=`$CYGPATH -u "$path"` 39417 fi 39418 if test "x$new_path" = x; then 39419 # It's still not found. Now this is an unrecoverable error. 39420 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5 39421 $as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;} 39422 has_space=`$ECHO "$complete" | $GREP " "` 39423 if test "x$has_space" != x; then 39424 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 39425 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 39426 fi 39427 as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5 39428 fi 39429 fi 39430 39431 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 39432 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 39433 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 39434 # "foo.exe" is OK but "foo" is an error. 39435 # 39436 # This test is therefore slightly more accurate than "test -f" to check for file presence. 39437 # It is also a way to make sure we got the proper file name for the real test later on. 39438 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 39439 if test "x$test_shortpath" = x; then 39440 # Short path failed, file does not exist as specified. 39441 # Try adding .exe or .cmd 39442 if test -f "${new_path}.exe"; then 39443 input_to_shortpath="${new_path}.exe" 39444 elif test -f "${new_path}.cmd"; then 39445 input_to_shortpath="${new_path}.cmd" 39446 else 39447 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$new_path\", is invalid." >&5 39448 $as_echo "$as_me: The path of RC, which resolves as \"$new_path\", is invalid." >&6;} 39449 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 39450 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 39451 as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5 39452 fi 39453 else 39454 input_to_shortpath="$new_path" 39455 fi 39456 39457 # Call helper function which possibly converts this using DOS-style short mode. 39458 # If so, the updated path is stored in $new_path. 39459 new_path="$input_to_shortpath" 39460 39461 input_path="$input_to_shortpath" 39462 # Check if we need to convert this using DOS-style short mode. If the path 39463 # contains just simple characters, use it. Otherwise (spaces, weird characters), 39464 # take no chances and rewrite it. 39465 # Note: m4 eats our [], so we need to use [ and ] instead. 39466 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 39467 if test "x$has_forbidden_chars" != x; then 39468 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 39469 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 39470 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 39471 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 39472 # Going to short mode and back again did indeed matter. Since short mode is 39473 # case insensitive, let's make it lowercase to improve readability. 39474 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39475 # Now convert it back to Unix-style (cygpath) 39476 input_path=`$CYGPATH -u "$shortmode_path"` 39477 new_path="$input_path" 39478 fi 39479 fi 39480 39481 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 39482 if test "x$test_cygdrive_prefix" = x; then 39483 # As a simple fix, exclude /usr/bin since it's not a real path. 39484 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 39485 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 39486 # a path prefixed by /cygdrive for fixpath to work. 39487 new_path="$CYGWIN_ROOT_PATH$input_path" 39488 fi 39489 fi 39490 39491 # remove trailing .exe if any 39492 new_path="${new_path/%.exe/}" 39493 39494 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39495 39496 # First separate the path from the arguments. This will split at the first 39497 # space. 39498 complete="$RC" 39499 path="${complete%% *}" 39500 tmp="$complete EOL" 39501 arguments="${tmp#* }" 39502 39503 # Input might be given as Windows format, start by converting to 39504 # unix format. 39505 new_path="$path" 39506 39507 windows_path="$new_path" 39508 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39509 unix_path=`$CYGPATH -u "$windows_path"` 39510 new_path="$unix_path" 39511 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39512 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39513 new_path="$unix_path" 39514 fi 39515 39516 39517 # Now try to locate executable using which 39518 new_path=`$WHICH "$new_path" 2> /dev/null` 39519 39520 if test "x$new_path" = x; then 39521 # Oops. Which didn't find the executable. 39522 # The splitting of arguments from the executable at a space might have been incorrect, 39523 # since paths with space are more likely in Windows. Give it another try with the whole 39524 # argument. 39525 path="$complete" 39526 arguments="EOL" 39527 new_path="$path" 39528 39529 windows_path="$new_path" 39530 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39531 unix_path=`$CYGPATH -u "$windows_path"` 39532 new_path="$unix_path" 39533 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39534 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39535 new_path="$unix_path" 39536 fi 39537 39538 39539 new_path=`$WHICH "$new_path" 2> /dev/null` 39540 # bat and cmd files are not always considered executable in MSYS causing which 39541 # to not find them 39542 if test "x$new_path" = x \ 39543 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39544 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39545 new_path="$path" 39546 39547 windows_path="$new_path" 39548 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39549 unix_path=`$CYGPATH -u "$windows_path"` 39550 new_path="$unix_path" 39551 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39552 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39553 new_path="$unix_path" 39554 fi 39555 39556 fi 39557 39558 if test "x$new_path" = x; then 39559 # It's still not found. Now this is an unrecoverable error. 39560 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5 39561 $as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;} 39562 has_space=`$ECHO "$complete" | $GREP " "` 39563 if test "x$has_space" != x; then 39564 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 39565 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 39566 fi 39567 as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5 39568 fi 39569 fi 39570 39571 # Now new_path has a complete unix path to the binary 39572 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 39573 # Keep paths in /bin as-is, but remove trailing .exe if any 39574 new_path="${new_path/%.exe/}" 39575 # Do not save /bin paths to all_fixpath_prefixes! 39576 else 39577 # Not in mixed or Windows style, start by that. 39578 new_path=`cmd //c echo $new_path` 39579 39580 input_path="$new_path" 39581 # Check if we need to convert this using DOS-style short mode. If the path 39582 # contains just simple characters, use it. Otherwise (spaces, weird characters), 39583 # take no chances and rewrite it. 39584 # Note: m4 eats our [], so we need to use [ and ] instead. 39585 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 39586 if test "x$has_forbidden_chars" != x; then 39587 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 39588 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39589 fi 39590 39591 # Output is in $new_path 39592 39593 windows_path="$new_path" 39594 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39595 unix_path=`$CYGPATH -u "$windows_path"` 39596 new_path="$unix_path" 39597 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39598 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39599 new_path="$unix_path" 39600 fi 39601 39602 # remove trailing .exe if any 39603 new_path="${new_path/%.exe/}" 39604 39605 # Save the first 10 bytes of this path to the storage, so fixpath can work. 39606 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 39607 fi 39608 39609 else 39610 # We're on a unix platform. Hooray! :) 39611 # First separate the path from the arguments. This will split at the first 39612 # space. 39613 complete="$RC" 39614 path="${complete%% *}" 39615 tmp="$complete EOL" 39616 arguments="${tmp#* }" 39617 39618 # Cannot rely on the command "which" here since it doesn't always work. 39619 is_absolute_path=`$ECHO "$path" | $GREP ^/` 39620 if test -z "$is_absolute_path"; then 39621 # Path to executable is not absolute. Find it. 39622 IFS_save="$IFS" 39623 IFS=: 39624 for p in $PATH; do 39625 if test -f "$p/$path" && test -x "$p/$path"; then 39626 new_path="$p/$path" 39627 break 39628 fi 39629 done 39630 IFS="$IFS_save" 39631 else 39632 # This is an absolute path, we can use it without further modifications. 39633 new_path="$path" 39634 fi 39635 39636 if test "x$new_path" = x; then 39637 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5 39638 $as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;} 39639 has_space=`$ECHO "$complete" | $GREP " "` 39640 if test "x$has_space" != x; then 39641 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 39642 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 39643 fi 39644 as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5 39645 fi 39646 fi 39647 39648 # Now join together the path and the arguments once again 39649 if test "x$arguments" != xEOL; then 39650 new_complete="$new_path ${arguments% *}" 39651 else 39652 new_complete="$new_path" 39653 fi 39654 39655 if test "x$complete" != "x$new_complete"; then 39656 RC="$new_complete" 39657 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting RC to \"$new_complete\"" >&5 39658 $as_echo "$as_me: Rewriting RC to \"$new_complete\"" >&6;} 39659 fi 39660 fi 39661 39662 # Extract the first word of "dumpbin", so it can be a program name with args. 39663 set dummy dumpbin; ac_word=$2 39664 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 39665 $as_echo_n "checking for $ac_word... " >&6; } 39666 if ${ac_cv_prog_DUMPBIN+:} false; then : 39667 $as_echo_n "(cached) " >&6 39668 else 39669 if test -n "$DUMPBIN"; then 39670 ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test. 39671 else 39672 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 39673 for as_dir in $PATH 39674 do 39675 IFS=$as_save_IFS 39676 test -z "$as_dir" && as_dir=. 39677 for ac_exec_ext in '' $ac_executable_extensions; do 39678 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 39679 ac_cv_prog_DUMPBIN="dumpbin" 39680 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 39681 break 2 39682 fi 39683 done 39684 done 39685 IFS=$as_save_IFS 39686 39687 fi 39688 fi 39689 DUMPBIN=$ac_cv_prog_DUMPBIN 39690 if test -n "$DUMPBIN"; then 39691 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5 39692 $as_echo "$DUMPBIN" >&6; } 39693 else 39694 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 39695 $as_echo "no" >&6; } 39696 fi 39697 39698 39699 39700 # Only process if variable expands to non-empty 39701 39702 if test "x$DUMPBIN" != x; then 39703 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39704 39705 # First separate the path from the arguments. This will split at the first 39706 # space. 39707 complete="$DUMPBIN" 39708 path="${complete%% *}" 39709 tmp="$complete EOL" 39710 arguments="${tmp#* }" 39711 39712 # Input might be given as Windows format, start by converting to 39713 # unix format. 39714 new_path=`$CYGPATH -u "$path"` 39715 39716 # Now try to locate executable using which 39717 new_path=`$WHICH "$new_path" 2> /dev/null` 39718 # bat and cmd files are not always considered executable in cygwin causing which 39719 # to not find them 39720 if test "x$new_path" = x \ 39721 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39722 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39723 new_path=`$CYGPATH -u "$path"` 39724 fi 39725 if test "x$new_path" = x; then 39726 # Oops. Which didn't find the executable. 39727 # The splitting of arguments from the executable at a space might have been incorrect, 39728 # since paths with space are more likely in Windows. Give it another try with the whole 39729 # argument. 39730 path="$complete" 39731 arguments="EOL" 39732 new_path=`$CYGPATH -u "$path"` 39733 new_path=`$WHICH "$new_path" 2> /dev/null` 39734 # bat and cmd files are not always considered executable in cygwin causing which 39735 # to not find them 39736 if test "x$new_path" = x \ 39737 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39738 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39739 new_path=`$CYGPATH -u "$path"` 39740 fi 39741 if test "x$new_path" = x; then 39742 # It's still not found. Now this is an unrecoverable error. 39743 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5 39744 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;} 39745 has_space=`$ECHO "$complete" | $GREP " "` 39746 if test "x$has_space" != x; then 39747 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 39748 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 39749 fi 39750 as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5 39751 fi 39752 fi 39753 39754 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 39755 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 39756 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 39757 # "foo.exe" is OK but "foo" is an error. 39758 # 39759 # This test is therefore slightly more accurate than "test -f" to check for file presence. 39760 # It is also a way to make sure we got the proper file name for the real test later on. 39761 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 39762 if test "x$test_shortpath" = x; then 39763 # Short path failed, file does not exist as specified. 39764 # Try adding .exe or .cmd 39765 if test -f "${new_path}.exe"; then 39766 input_to_shortpath="${new_path}.exe" 39767 elif test -f "${new_path}.cmd"; then 39768 input_to_shortpath="${new_path}.cmd" 39769 else 39770 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$new_path\", is invalid." >&5 39771 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$new_path\", is invalid." >&6;} 39772 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 39773 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 39774 as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5 39775 fi 39776 else 39777 input_to_shortpath="$new_path" 39778 fi 39779 39780 # Call helper function which possibly converts this using DOS-style short mode. 39781 # If so, the updated path is stored in $new_path. 39782 new_path="$input_to_shortpath" 39783 39784 input_path="$input_to_shortpath" 39785 # Check if we need to convert this using DOS-style short mode. If the path 39786 # contains just simple characters, use it. Otherwise (spaces, weird characters), 39787 # take no chances and rewrite it. 39788 # Note: m4 eats our [], so we need to use [ and ] instead. 39789 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 39790 if test "x$has_forbidden_chars" != x; then 39791 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 39792 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 39793 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 39794 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 39795 # Going to short mode and back again did indeed matter. Since short mode is 39796 # case insensitive, let's make it lowercase to improve readability. 39797 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39798 # Now convert it back to Unix-style (cygpath) 39799 input_path=`$CYGPATH -u "$shortmode_path"` 39800 new_path="$input_path" 39801 fi 39802 fi 39803 39804 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 39805 if test "x$test_cygdrive_prefix" = x; then 39806 # As a simple fix, exclude /usr/bin since it's not a real path. 39807 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 39808 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 39809 # a path prefixed by /cygdrive for fixpath to work. 39810 new_path="$CYGWIN_ROOT_PATH$input_path" 39811 fi 39812 fi 39813 39814 # remove trailing .exe if any 39815 new_path="${new_path/%.exe/}" 39816 39817 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39818 39819 # First separate the path from the arguments. This will split at the first 39820 # space. 39821 complete="$DUMPBIN" 39822 path="${complete%% *}" 39823 tmp="$complete EOL" 39824 arguments="${tmp#* }" 39825 39826 # Input might be given as Windows format, start by converting to 39827 # unix format. 39828 new_path="$path" 39829 39830 windows_path="$new_path" 39831 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39832 unix_path=`$CYGPATH -u "$windows_path"` 39833 new_path="$unix_path" 39834 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39835 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39836 new_path="$unix_path" 39837 fi 39838 39839 39840 # Now try to locate executable using which 39841 new_path=`$WHICH "$new_path" 2> /dev/null` 39842 39843 if test "x$new_path" = x; then 39844 # Oops. Which didn't find the executable. 39845 # The splitting of arguments from the executable at a space might have been incorrect, 39846 # since paths with space are more likely in Windows. Give it another try with the whole 39847 # argument. 39848 path="$complete" 39849 arguments="EOL" 39850 new_path="$path" 39851 39852 windows_path="$new_path" 39853 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39854 unix_path=`$CYGPATH -u "$windows_path"` 39855 new_path="$unix_path" 39856 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39857 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39858 new_path="$unix_path" 39859 fi 39860 39861 39862 new_path=`$WHICH "$new_path" 2> /dev/null` 39863 # bat and cmd files are not always considered executable in MSYS causing which 39864 # to not find them 39865 if test "x$new_path" = x \ 39866 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39867 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39868 new_path="$path" 39869 39870 windows_path="$new_path" 39871 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39872 unix_path=`$CYGPATH -u "$windows_path"` 39873 new_path="$unix_path" 39874 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39875 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39876 new_path="$unix_path" 39877 fi 39878 39879 fi 39880 39881 if test "x$new_path" = x; then 39882 # It's still not found. Now this is an unrecoverable error. 39883 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5 39884 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;} 39885 has_space=`$ECHO "$complete" | $GREP " "` 39886 if test "x$has_space" != x; then 39887 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 39888 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 39889 fi 39890 as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5 39891 fi 39892 fi 39893 39894 # Now new_path has a complete unix path to the binary 39895 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 39896 # Keep paths in /bin as-is, but remove trailing .exe if any 39897 new_path="${new_path/%.exe/}" 39898 # Do not save /bin paths to all_fixpath_prefixes! 39899 else 39900 # Not in mixed or Windows style, start by that. 39901 new_path=`cmd //c echo $new_path` 39902 39903 input_path="$new_path" 39904 # Check if we need to convert this using DOS-style short mode. If the path 39905 # contains just simple characters, use it. Otherwise (spaces, weird characters), 39906 # take no chances and rewrite it. 39907 # Note: m4 eats our [], so we need to use [ and ] instead. 39908 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 39909 if test "x$has_forbidden_chars" != x; then 39910 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 39911 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39912 fi 39913 39914 # Output is in $new_path 39915 39916 windows_path="$new_path" 39917 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39918 unix_path=`$CYGPATH -u "$windows_path"` 39919 new_path="$unix_path" 39920 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39921 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39922 new_path="$unix_path" 39923 fi 39924 39925 # remove trailing .exe if any 39926 new_path="${new_path/%.exe/}" 39927 39928 # Save the first 10 bytes of this path to the storage, so fixpath can work. 39929 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 39930 fi 39931 39932 else 39933 # We're on a unix platform. Hooray! :) 39934 # First separate the path from the arguments. This will split at the first 39935 # space. 39936 complete="$DUMPBIN" 39937 path="${complete%% *}" 39938 tmp="$complete EOL" 39939 arguments="${tmp#* }" 39940 39941 # Cannot rely on the command "which" here since it doesn't always work. 39942 is_absolute_path=`$ECHO "$path" | $GREP ^/` 39943 if test -z "$is_absolute_path"; then 39944 # Path to executable is not absolute. Find it. 39945 IFS_save="$IFS" 39946 IFS=: 39947 for p in $PATH; do 39948 if test -f "$p/$path" && test -x "$p/$path"; then 39949 new_path="$p/$path" 39950 break 39951 fi 39952 done 39953 IFS="$IFS_save" 39954 else 39955 # This is an absolute path, we can use it without further modifications. 39956 new_path="$path" 39957 fi 39958 39959 if test "x$new_path" = x; then 39960 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5 39961 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;} 39962 has_space=`$ECHO "$complete" | $GREP " "` 39963 if test "x$has_space" != x; then 39964 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 39965 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 39966 fi 39967 as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5 39968 fi 39969 fi 39970 39971 # Now join together the path and the arguments once again 39972 if test "x$arguments" != xEOL; then 39973 new_complete="$new_path ${arguments% *}" 39974 else 39975 new_complete="$new_path" 39976 fi 39977 39978 if test "x$complete" != "x$new_complete"; then 39979 DUMPBIN="$new_complete" 39980 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting DUMPBIN to \"$new_complete\"" >&5 39981 $as_echo "$as_me: Rewriting DUMPBIN to \"$new_complete\"" >&6;} 39982 fi 39983 fi 39984 39985 # We need to check for 'msbuild.exe' because at the place where we expect to 39986 # find 'msbuild.exe' there's also a directory called 'msbuild' and configure 39987 # won't find the 'msbuild.exe' executable in that case (and the 39988 # 'ac_executable_extensions' is unusable due to performance reasons). 39989 # Notice that we intentionally don't fix up the path to MSBUILD because we 39990 # will call it in a DOS shell during freetype detection on Windows (see 39991 # 'LIB_SETUP_FREETYPE' in "libraries.m4" 39992 # Extract the first word of "msbuild.exe", so it can be a program name with args. 39993 set dummy msbuild.exe; ac_word=$2 39994 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 39995 $as_echo_n "checking for $ac_word... " >&6; } 39996 if ${ac_cv_prog_MSBUILD+:} false; then : 39997 $as_echo_n "(cached) " >&6 39998 else 39999 if test -n "$MSBUILD"; then 40000 ac_cv_prog_MSBUILD="$MSBUILD" # Let the user override the test. 40001 else 40002 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40003 for as_dir in $PATH 40004 do 40005 IFS=$as_save_IFS 40006 test -z "$as_dir" && as_dir=. 40007 for ac_exec_ext in '' $ac_executable_extensions; do 40008 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40009 ac_cv_prog_MSBUILD="msbuild.exe" 40010 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40011 break 2 40012 fi 40013 done 40014 done 40015 IFS=$as_save_IFS 40016 40017 fi 40018 fi 40019 MSBUILD=$ac_cv_prog_MSBUILD 40020 if test -n "$MSBUILD"; then 40021 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSBUILD" >&5 40022 $as_echo "$MSBUILD" >&6; } 40023 else 40024 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40025 $as_echo "no" >&6; } 40026 fi 40027 40028 40029 fi 40030 40031 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 40032 40033 40034 # Publish this variable in the help. 40035 40036 40037 if [ -z "${STRIP+x}" ]; then 40038 # The variable is not set by user, try to locate tool using the code snippet 40039 for ac_prog in strip 40040 do 40041 # Extract the first word of "$ac_prog", so it can be a program name with args. 40042 set dummy $ac_prog; ac_word=$2 40043 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40044 $as_echo_n "checking for $ac_word... " >&6; } 40045 if ${ac_cv_path_STRIP+:} false; then : 40046 $as_echo_n "(cached) " >&6 40047 else 40048 case $STRIP in 40049 [\\/]* | ?:[\\/]*) 40050 ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path. 40051 ;; 40052 *) 40053 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40054 for as_dir in $PATH 40055 do 40056 IFS=$as_save_IFS 40057 test -z "$as_dir" && as_dir=. 40058 for ac_exec_ext in '' $ac_executable_extensions; do 40059 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40060 ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext" 40061 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40062 break 2 40063 fi 40064 done 40065 done 40066 IFS=$as_save_IFS 40067 40068 ;; 40069 esac 40070 fi 40071 STRIP=$ac_cv_path_STRIP 40072 if test -n "$STRIP"; then 40073 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 40074 $as_echo "$STRIP" >&6; } 40075 else 40076 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40077 $as_echo "no" >&6; } 40078 fi 40079 40080 40081 test -n "$STRIP" && break 40082 done 40083 40084 else 40085 # The variable is set, but is it from the command line or the environment? 40086 40087 # Try to remove the string !STRIP! from our list. 40088 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!STRIP!/} 40089 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 40090 # If it failed, the variable was not from the command line. Ignore it, 40091 # but warn the user (except for BASH, which is always set by the calling BASH). 40092 if test "xSTRIP" != xBASH; then 40093 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&5 40094 $as_echo "$as_me: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&2;} 40095 fi 40096 # Try to locate tool using the code snippet 40097 for ac_prog in strip 40098 do 40099 # Extract the first word of "$ac_prog", so it can be a program name with args. 40100 set dummy $ac_prog; ac_word=$2 40101 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40102 $as_echo_n "checking for $ac_word... " >&6; } 40103 if ${ac_cv_path_STRIP+:} false; then : 40104 $as_echo_n "(cached) " >&6 40105 else 40106 case $STRIP in 40107 [\\/]* | ?:[\\/]*) 40108 ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path. 40109 ;; 40110 *) 40111 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40112 for as_dir in $PATH 40113 do 40114 IFS=$as_save_IFS 40115 test -z "$as_dir" && as_dir=. 40116 for ac_exec_ext in '' $ac_executable_extensions; do 40117 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40118 ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext" 40119 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40120 break 2 40121 fi 40122 done 40123 done 40124 IFS=$as_save_IFS 40125 40126 ;; 40127 esac 40128 fi 40129 STRIP=$ac_cv_path_STRIP 40130 if test -n "$STRIP"; then 40131 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 40132 $as_echo "$STRIP" >&6; } 40133 else 40134 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40135 $as_echo "no" >&6; } 40136 fi 40137 40138 40139 test -n "$STRIP" && break 40140 done 40141 40142 else 40143 # If it succeeded, then it was overridden by the user. We will use it 40144 # for the tool. 40145 40146 # First remove it from the list of overridden variables, so we can test 40147 # for unknown variables in the end. 40148 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 40149 40150 # Check if we try to supply an empty value 40151 if test "x$STRIP" = x; then 40152 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool STRIP= (no value)" >&5 40153 $as_echo "$as_me: Setting user supplied tool STRIP= (no value)" >&6;} 40154 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5 40155 $as_echo_n "checking for STRIP... " >&6; } 40156 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 40157 $as_echo "disabled" >&6; } 40158 else 40159 # Check if the provided tool contains a complete path. 40160 tool_specified="$STRIP" 40161 tool_basename="${tool_specified##*/}" 40162 if test "x$tool_basename" = "x$tool_specified"; then 40163 # A command without a complete path is provided, search $PATH. 40164 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool STRIP=$tool_basename" >&5 40165 $as_echo "$as_me: Will search for user supplied tool STRIP=$tool_basename" >&6;} 40166 # Extract the first word of "$tool_basename", so it can be a program name with args. 40167 set dummy $tool_basename; ac_word=$2 40168 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40169 $as_echo_n "checking for $ac_word... " >&6; } 40170 if ${ac_cv_path_STRIP+:} false; then : 40171 $as_echo_n "(cached) " >&6 40172 else 40173 case $STRIP in 40174 [\\/]* | ?:[\\/]*) 40175 ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path. 40176 ;; 40177 *) 40178 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40179 for as_dir in $PATH 40180 do 40181 IFS=$as_save_IFS 40182 test -z "$as_dir" && as_dir=. 40183 for ac_exec_ext in '' $ac_executable_extensions; do 40184 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40185 ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext" 40186 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40187 break 2 40188 fi 40189 done 40190 done 40191 IFS=$as_save_IFS 40192 40193 ;; 40194 esac 40195 fi 40196 STRIP=$ac_cv_path_STRIP 40197 if test -n "$STRIP"; then 40198 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 40199 $as_echo "$STRIP" >&6; } 40200 else 40201 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40202 $as_echo "no" >&6; } 40203 fi 40204 40205 40206 if test "x$STRIP" = x; then 40207 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 40208 fi 40209 else 40210 # Otherwise we believe it is a complete path. Use it as it is. 40211 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool STRIP=$tool_specified" >&5 40212 $as_echo "$as_me: Will use user supplied tool STRIP=$tool_specified" >&6;} 40213 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5 40214 $as_echo_n "checking for STRIP... " >&6; } 40215 if test ! -x "$tool_specified"; then 40216 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 40217 $as_echo "not found" >&6; } 40218 as_fn_error $? "User supplied tool STRIP=$tool_specified does not exist or is not executable" "$LINENO" 5 40219 fi 40220 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 40221 $as_echo "$tool_specified" >&6; } 40222 fi 40223 fi 40224 fi 40225 40226 fi 40227 40228 40229 40230 # Only process if variable expands to non-empty 40231 40232 if test "x$STRIP" != x; then 40233 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40234 40235 # First separate the path from the arguments. This will split at the first 40236 # space. 40237 complete="$STRIP" 40238 path="${complete%% *}" 40239 tmp="$complete EOL" 40240 arguments="${tmp#* }" 40241 40242 # Input might be given as Windows format, start by converting to 40243 # unix format. 40244 new_path=`$CYGPATH -u "$path"` 40245 40246 # Now try to locate executable using which 40247 new_path=`$WHICH "$new_path" 2> /dev/null` 40248 # bat and cmd files are not always considered executable in cygwin causing which 40249 # to not find them 40250 if test "x$new_path" = x \ 40251 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40252 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40253 new_path=`$CYGPATH -u "$path"` 40254 fi 40255 if test "x$new_path" = x; then 40256 # Oops. Which didn't find the executable. 40257 # The splitting of arguments from the executable at a space might have been incorrect, 40258 # since paths with space are more likely in Windows. Give it another try with the whole 40259 # argument. 40260 path="$complete" 40261 arguments="EOL" 40262 new_path=`$CYGPATH -u "$path"` 40263 new_path=`$WHICH "$new_path" 2> /dev/null` 40264 # bat and cmd files are not always considered executable in cygwin causing which 40265 # to not find them 40266 if test "x$new_path" = x \ 40267 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40268 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40269 new_path=`$CYGPATH -u "$path"` 40270 fi 40271 if test "x$new_path" = x; then 40272 # It's still not found. Now this is an unrecoverable error. 40273 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 40274 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 40275 has_space=`$ECHO "$complete" | $GREP " "` 40276 if test "x$has_space" != x; then 40277 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 40278 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 40279 fi 40280 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 40281 fi 40282 fi 40283 40284 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 40285 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 40286 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 40287 # "foo.exe" is OK but "foo" is an error. 40288 # 40289 # This test is therefore slightly more accurate than "test -f" to check for file presence. 40290 # It is also a way to make sure we got the proper file name for the real test later on. 40291 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 40292 if test "x$test_shortpath" = x; then 40293 # Short path failed, file does not exist as specified. 40294 # Try adding .exe or .cmd 40295 if test -f "${new_path}.exe"; then 40296 input_to_shortpath="${new_path}.exe" 40297 elif test -f "${new_path}.cmd"; then 40298 input_to_shortpath="${new_path}.cmd" 40299 else 40300 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$new_path\", is invalid." >&5 40301 $as_echo "$as_me: The path of STRIP, which resolves as \"$new_path\", is invalid." >&6;} 40302 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 40303 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 40304 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 40305 fi 40306 else 40307 input_to_shortpath="$new_path" 40308 fi 40309 40310 # Call helper function which possibly converts this using DOS-style short mode. 40311 # If so, the updated path is stored in $new_path. 40312 new_path="$input_to_shortpath" 40313 40314 input_path="$input_to_shortpath" 40315 # Check if we need to convert this using DOS-style short mode. If the path 40316 # contains just simple characters, use it. Otherwise (spaces, weird characters), 40317 # take no chances and rewrite it. 40318 # Note: m4 eats our [], so we need to use [ and ] instead. 40319 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 40320 if test "x$has_forbidden_chars" != x; then 40321 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 40322 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 40323 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 40324 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 40325 # Going to short mode and back again did indeed matter. Since short mode is 40326 # case insensitive, let's make it lowercase to improve readability. 40327 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 40328 # Now convert it back to Unix-style (cygpath) 40329 input_path=`$CYGPATH -u "$shortmode_path"` 40330 new_path="$input_path" 40331 fi 40332 fi 40333 40334 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 40335 if test "x$test_cygdrive_prefix" = x; then 40336 # As a simple fix, exclude /usr/bin since it's not a real path. 40337 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 40338 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 40339 # a path prefixed by /cygdrive for fixpath to work. 40340 new_path="$CYGWIN_ROOT_PATH$input_path" 40341 fi 40342 fi 40343 40344 # remove trailing .exe if any 40345 new_path="${new_path/%.exe/}" 40346 40347 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40348 40349 # First separate the path from the arguments. This will split at the first 40350 # space. 40351 complete="$STRIP" 40352 path="${complete%% *}" 40353 tmp="$complete EOL" 40354 arguments="${tmp#* }" 40355 40356 # Input might be given as Windows format, start by converting to 40357 # unix format. 40358 new_path="$path" 40359 40360 windows_path="$new_path" 40361 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40362 unix_path=`$CYGPATH -u "$windows_path"` 40363 new_path="$unix_path" 40364 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40365 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40366 new_path="$unix_path" 40367 fi 40368 40369 40370 # Now try to locate executable using which 40371 new_path=`$WHICH "$new_path" 2> /dev/null` 40372 40373 if test "x$new_path" = x; then 40374 # Oops. Which didn't find the executable. 40375 # The splitting of arguments from the executable at a space might have been incorrect, 40376 # since paths with space are more likely in Windows. Give it another try with the whole 40377 # argument. 40378 path="$complete" 40379 arguments="EOL" 40380 new_path="$path" 40381 40382 windows_path="$new_path" 40383 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40384 unix_path=`$CYGPATH -u "$windows_path"` 40385 new_path="$unix_path" 40386 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40387 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40388 new_path="$unix_path" 40389 fi 40390 40391 40392 new_path=`$WHICH "$new_path" 2> /dev/null` 40393 # bat and cmd files are not always considered executable in MSYS causing which 40394 # to not find them 40395 if test "x$new_path" = x \ 40396 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40397 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40398 new_path="$path" 40399 40400 windows_path="$new_path" 40401 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40402 unix_path=`$CYGPATH -u "$windows_path"` 40403 new_path="$unix_path" 40404 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40405 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40406 new_path="$unix_path" 40407 fi 40408 40409 fi 40410 40411 if test "x$new_path" = x; then 40412 # It's still not found. Now this is an unrecoverable error. 40413 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 40414 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 40415 has_space=`$ECHO "$complete" | $GREP " "` 40416 if test "x$has_space" != x; then 40417 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 40418 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 40419 fi 40420 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 40421 fi 40422 fi 40423 40424 # Now new_path has a complete unix path to the binary 40425 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 40426 # Keep paths in /bin as-is, but remove trailing .exe if any 40427 new_path="${new_path/%.exe/}" 40428 # Do not save /bin paths to all_fixpath_prefixes! 40429 else 40430 # Not in mixed or Windows style, start by that. 40431 new_path=`cmd //c echo $new_path` 40432 40433 input_path="$new_path" 40434 # Check if we need to convert this using DOS-style short mode. If the path 40435 # contains just simple characters, use it. Otherwise (spaces, weird characters), 40436 # take no chances and rewrite it. 40437 # Note: m4 eats our [], so we need to use [ and ] instead. 40438 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 40439 if test "x$has_forbidden_chars" != x; then 40440 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 40441 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 40442 fi 40443 40444 # Output is in $new_path 40445 40446 windows_path="$new_path" 40447 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40448 unix_path=`$CYGPATH -u "$windows_path"` 40449 new_path="$unix_path" 40450 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40451 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40452 new_path="$unix_path" 40453 fi 40454 40455 # remove trailing .exe if any 40456 new_path="${new_path/%.exe/}" 40457 40458 # Save the first 10 bytes of this path to the storage, so fixpath can work. 40459 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 40460 fi 40461 40462 else 40463 # We're on a unix platform. Hooray! :) 40464 # First separate the path from the arguments. This will split at the first 40465 # space. 40466 complete="$STRIP" 40467 path="${complete%% *}" 40468 tmp="$complete EOL" 40469 arguments="${tmp#* }" 40470 40471 # Cannot rely on the command "which" here since it doesn't always work. 40472 is_absolute_path=`$ECHO "$path" | $GREP ^/` 40473 if test -z "$is_absolute_path"; then 40474 # Path to executable is not absolute. Find it. 40475 IFS_save="$IFS" 40476 IFS=: 40477 for p in $PATH; do 40478 if test -f "$p/$path" && test -x "$p/$path"; then 40479 new_path="$p/$path" 40480 break 40481 fi 40482 done 40483 IFS="$IFS_save" 40484 else 40485 # This is an absolute path, we can use it without further modifications. 40486 new_path="$path" 40487 fi 40488 40489 if test "x$new_path" = x; then 40490 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 40491 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 40492 has_space=`$ECHO "$complete" | $GREP " "` 40493 if test "x$has_space" != x; then 40494 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 40495 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 40496 fi 40497 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 40498 fi 40499 fi 40500 40501 # Now join together the path and the arguments once again 40502 if test "x$arguments" != xEOL; then 40503 new_complete="$new_path ${arguments% *}" 40504 else 40505 new_complete="$new_path" 40506 fi 40507 40508 if test "x$complete" != "x$new_complete"; then 40509 STRIP="$new_complete" 40510 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STRIP to \"$new_complete\"" >&5 40511 $as_echo "$as_me: Rewriting STRIP to \"$new_complete\"" >&6;} 40512 fi 40513 fi 40514 40515 40516 40517 # Publish this variable in the help. 40518 40519 40520 if [ -z "${NM+x}" ]; then 40521 # The variable is not set by user, try to locate tool using the code snippet 40522 for ac_prog in nm 40523 do 40524 # Extract the first word of "$ac_prog", so it can be a program name with args. 40525 set dummy $ac_prog; ac_word=$2 40526 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40527 $as_echo_n "checking for $ac_word... " >&6; } 40528 if ${ac_cv_path_NM+:} false; then : 40529 $as_echo_n "(cached) " >&6 40530 else 40531 case $NM in 40532 [\\/]* | ?:[\\/]*) 40533 ac_cv_path_NM="$NM" # Let the user override the test with a path. 40534 ;; 40535 *) 40536 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40537 for as_dir in $PATH 40538 do 40539 IFS=$as_save_IFS 40540 test -z "$as_dir" && as_dir=. 40541 for ac_exec_ext in '' $ac_executable_extensions; do 40542 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40543 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 40544 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40545 break 2 40546 fi 40547 done 40548 done 40549 IFS=$as_save_IFS 40550 40551 ;; 40552 esac 40553 fi 40554 NM=$ac_cv_path_NM 40555 if test -n "$NM"; then 40556 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 40557 $as_echo "$NM" >&6; } 40558 else 40559 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40560 $as_echo "no" >&6; } 40561 fi 40562 40563 40564 test -n "$NM" && break 40565 done 40566 40567 else 40568 # The variable is set, but is it from the command line or the environment? 40569 40570 # Try to remove the string !NM! from our list. 40571 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NM!/} 40572 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 40573 # If it failed, the variable was not from the command line. Ignore it, 40574 # but warn the user (except for BASH, which is always set by the calling BASH). 40575 if test "xNM" != xBASH; then 40576 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&5 40577 $as_echo "$as_me: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&2;} 40578 fi 40579 # Try to locate tool using the code snippet 40580 for ac_prog in nm 40581 do 40582 # Extract the first word of "$ac_prog", so it can be a program name with args. 40583 set dummy $ac_prog; ac_word=$2 40584 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40585 $as_echo_n "checking for $ac_word... " >&6; } 40586 if ${ac_cv_path_NM+:} false; then : 40587 $as_echo_n "(cached) " >&6 40588 else 40589 case $NM in 40590 [\\/]* | ?:[\\/]*) 40591 ac_cv_path_NM="$NM" # Let the user override the test with a path. 40592 ;; 40593 *) 40594 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40595 for as_dir in $PATH 40596 do 40597 IFS=$as_save_IFS 40598 test -z "$as_dir" && as_dir=. 40599 for ac_exec_ext in '' $ac_executable_extensions; do 40600 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40601 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 40602 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40603 break 2 40604 fi 40605 done 40606 done 40607 IFS=$as_save_IFS 40608 40609 ;; 40610 esac 40611 fi 40612 NM=$ac_cv_path_NM 40613 if test -n "$NM"; then 40614 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 40615 $as_echo "$NM" >&6; } 40616 else 40617 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40618 $as_echo "no" >&6; } 40619 fi 40620 40621 40622 test -n "$NM" && break 40623 done 40624 40625 else 40626 # If it succeeded, then it was overridden by the user. We will use it 40627 # for the tool. 40628 40629 # First remove it from the list of overridden variables, so we can test 40630 # for unknown variables in the end. 40631 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 40632 40633 # Check if we try to supply an empty value 40634 if test "x$NM" = x; then 40635 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool NM= (no value)" >&5 40636 $as_echo "$as_me: Setting user supplied tool NM= (no value)" >&6;} 40637 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 40638 $as_echo_n "checking for NM... " >&6; } 40639 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 40640 $as_echo "disabled" >&6; } 40641 else 40642 # Check if the provided tool contains a complete path. 40643 tool_specified="$NM" 40644 tool_basename="${tool_specified##*/}" 40645 if test "x$tool_basename" = "x$tool_specified"; then 40646 # A command without a complete path is provided, search $PATH. 40647 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NM=$tool_basename" >&5 40648 $as_echo "$as_me: Will search for user supplied tool NM=$tool_basename" >&6;} 40649 # Extract the first word of "$tool_basename", so it can be a program name with args. 40650 set dummy $tool_basename; ac_word=$2 40651 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40652 $as_echo_n "checking for $ac_word... " >&6; } 40653 if ${ac_cv_path_NM+:} false; then : 40654 $as_echo_n "(cached) " >&6 40655 else 40656 case $NM in 40657 [\\/]* | ?:[\\/]*) 40658 ac_cv_path_NM="$NM" # Let the user override the test with a path. 40659 ;; 40660 *) 40661 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40662 for as_dir in $PATH 40663 do 40664 IFS=$as_save_IFS 40665 test -z "$as_dir" && as_dir=. 40666 for ac_exec_ext in '' $ac_executable_extensions; do 40667 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40668 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 40669 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40670 break 2 40671 fi 40672 done 40673 done 40674 IFS=$as_save_IFS 40675 40676 ;; 40677 esac 40678 fi 40679 NM=$ac_cv_path_NM 40680 if test -n "$NM"; then 40681 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 40682 $as_echo "$NM" >&6; } 40683 else 40684 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40685 $as_echo "no" >&6; } 40686 fi 40687 40688 40689 if test "x$NM" = x; then 40690 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 40691 fi 40692 else 40693 # Otherwise we believe it is a complete path. Use it as it is. 40694 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NM=$tool_specified" >&5 40695 $as_echo "$as_me: Will use user supplied tool NM=$tool_specified" >&6;} 40696 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 40697 $as_echo_n "checking for NM... " >&6; } 40698 if test ! -x "$tool_specified"; then 40699 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 40700 $as_echo "not found" >&6; } 40701 as_fn_error $? "User supplied tool NM=$tool_specified does not exist or is not executable" "$LINENO" 5 40702 fi 40703 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 40704 $as_echo "$tool_specified" >&6; } 40705 fi 40706 fi 40707 fi 40708 40709 fi 40710 40711 40712 40713 # Only process if variable expands to non-empty 40714 40715 if test "x$NM" != x; then 40716 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40717 40718 # First separate the path from the arguments. This will split at the first 40719 # space. 40720 complete="$NM" 40721 path="${complete%% *}" 40722 tmp="$complete EOL" 40723 arguments="${tmp#* }" 40724 40725 # Input might be given as Windows format, start by converting to 40726 # unix format. 40727 new_path=`$CYGPATH -u "$path"` 40728 40729 # Now try to locate executable using which 40730 new_path=`$WHICH "$new_path" 2> /dev/null` 40731 # bat and cmd files are not always considered executable in cygwin causing which 40732 # to not find them 40733 if test "x$new_path" = x \ 40734 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40735 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40736 new_path=`$CYGPATH -u "$path"` 40737 fi 40738 if test "x$new_path" = x; then 40739 # Oops. Which didn't find the executable. 40740 # The splitting of arguments from the executable at a space might have been incorrect, 40741 # since paths with space are more likely in Windows. Give it another try with the whole 40742 # argument. 40743 path="$complete" 40744 arguments="EOL" 40745 new_path=`$CYGPATH -u "$path"` 40746 new_path=`$WHICH "$new_path" 2> /dev/null` 40747 # bat and cmd files are not always considered executable in cygwin causing which 40748 # to not find them 40749 if test "x$new_path" = x \ 40750 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40751 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40752 new_path=`$CYGPATH -u "$path"` 40753 fi 40754 if test "x$new_path" = x; then 40755 # It's still not found. Now this is an unrecoverable error. 40756 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 40757 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 40758 has_space=`$ECHO "$complete" | $GREP " "` 40759 if test "x$has_space" != x; then 40760 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 40761 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 40762 fi 40763 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 40764 fi 40765 fi 40766 40767 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 40768 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 40769 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 40770 # "foo.exe" is OK but "foo" is an error. 40771 # 40772 # This test is therefore slightly more accurate than "test -f" to check for file presence. 40773 # It is also a way to make sure we got the proper file name for the real test later on. 40774 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 40775 if test "x$test_shortpath" = x; then 40776 # Short path failed, file does not exist as specified. 40777 # Try adding .exe or .cmd 40778 if test -f "${new_path}.exe"; then 40779 input_to_shortpath="${new_path}.exe" 40780 elif test -f "${new_path}.cmd"; then 40781 input_to_shortpath="${new_path}.cmd" 40782 else 40783 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$new_path\", is invalid." >&5 40784 $as_echo "$as_me: The path of NM, which resolves as \"$new_path\", is invalid." >&6;} 40785 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 40786 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 40787 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 40788 fi 40789 else 40790 input_to_shortpath="$new_path" 40791 fi 40792 40793 # Call helper function which possibly converts this using DOS-style short mode. 40794 # If so, the updated path is stored in $new_path. 40795 new_path="$input_to_shortpath" 40796 40797 input_path="$input_to_shortpath" 40798 # Check if we need to convert this using DOS-style short mode. If the path 40799 # contains just simple characters, use it. Otherwise (spaces, weird characters), 40800 # take no chances and rewrite it. 40801 # Note: m4 eats our [], so we need to use [ and ] instead. 40802 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 40803 if test "x$has_forbidden_chars" != x; then 40804 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 40805 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 40806 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 40807 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 40808 # Going to short mode and back again did indeed matter. Since short mode is 40809 # case insensitive, let's make it lowercase to improve readability. 40810 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 40811 # Now convert it back to Unix-style (cygpath) 40812 input_path=`$CYGPATH -u "$shortmode_path"` 40813 new_path="$input_path" 40814 fi 40815 fi 40816 40817 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 40818 if test "x$test_cygdrive_prefix" = x; then 40819 # As a simple fix, exclude /usr/bin since it's not a real path. 40820 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 40821 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 40822 # a path prefixed by /cygdrive for fixpath to work. 40823 new_path="$CYGWIN_ROOT_PATH$input_path" 40824 fi 40825 fi 40826 40827 # remove trailing .exe if any 40828 new_path="${new_path/%.exe/}" 40829 40830 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40831 40832 # First separate the path from the arguments. This will split at the first 40833 # space. 40834 complete="$NM" 40835 path="${complete%% *}" 40836 tmp="$complete EOL" 40837 arguments="${tmp#* }" 40838 40839 # Input might be given as Windows format, start by converting to 40840 # unix format. 40841 new_path="$path" 40842 40843 windows_path="$new_path" 40844 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40845 unix_path=`$CYGPATH -u "$windows_path"` 40846 new_path="$unix_path" 40847 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40848 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40849 new_path="$unix_path" 40850 fi 40851 40852 40853 # Now try to locate executable using which 40854 new_path=`$WHICH "$new_path" 2> /dev/null` 40855 40856 if test "x$new_path" = x; then 40857 # Oops. Which didn't find the executable. 40858 # The splitting of arguments from the executable at a space might have been incorrect, 40859 # since paths with space are more likely in Windows. Give it another try with the whole 40860 # argument. 40861 path="$complete" 40862 arguments="EOL" 40863 new_path="$path" 40864 40865 windows_path="$new_path" 40866 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40867 unix_path=`$CYGPATH -u "$windows_path"` 40868 new_path="$unix_path" 40869 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40870 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40871 new_path="$unix_path" 40872 fi 40873 40874 40875 new_path=`$WHICH "$new_path" 2> /dev/null` 40876 # bat and cmd files are not always considered executable in MSYS causing which 40877 # to not find them 40878 if test "x$new_path" = x \ 40879 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40880 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40881 new_path="$path" 40882 40883 windows_path="$new_path" 40884 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40885 unix_path=`$CYGPATH -u "$windows_path"` 40886 new_path="$unix_path" 40887 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40888 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40889 new_path="$unix_path" 40890 fi 40891 40892 fi 40893 40894 if test "x$new_path" = x; then 40895 # It's still not found. Now this is an unrecoverable error. 40896 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 40897 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 40898 has_space=`$ECHO "$complete" | $GREP " "` 40899 if test "x$has_space" != x; then 40900 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 40901 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 40902 fi 40903 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 40904 fi 40905 fi 40906 40907 # Now new_path has a complete unix path to the binary 40908 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 40909 # Keep paths in /bin as-is, but remove trailing .exe if any 40910 new_path="${new_path/%.exe/}" 40911 # Do not save /bin paths to all_fixpath_prefixes! 40912 else 40913 # Not in mixed or Windows style, start by that. 40914 new_path=`cmd //c echo $new_path` 40915 40916 input_path="$new_path" 40917 # Check if we need to convert this using DOS-style short mode. If the path 40918 # contains just simple characters, use it. Otherwise (spaces, weird characters), 40919 # take no chances and rewrite it. 40920 # Note: m4 eats our [], so we need to use [ and ] instead. 40921 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 40922 if test "x$has_forbidden_chars" != x; then 40923 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 40924 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 40925 fi 40926 40927 # Output is in $new_path 40928 40929 windows_path="$new_path" 40930 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40931 unix_path=`$CYGPATH -u "$windows_path"` 40932 new_path="$unix_path" 40933 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40934 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40935 new_path="$unix_path" 40936 fi 40937 40938 # remove trailing .exe if any 40939 new_path="${new_path/%.exe/}" 40940 40941 # Save the first 10 bytes of this path to the storage, so fixpath can work. 40942 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 40943 fi 40944 40945 else 40946 # We're on a unix platform. Hooray! :) 40947 # First separate the path from the arguments. This will split at the first 40948 # space. 40949 complete="$NM" 40950 path="${complete%% *}" 40951 tmp="$complete EOL" 40952 arguments="${tmp#* }" 40953 40954 # Cannot rely on the command "which" here since it doesn't always work. 40955 is_absolute_path=`$ECHO "$path" | $GREP ^/` 40956 if test -z "$is_absolute_path"; then 40957 # Path to executable is not absolute. Find it. 40958 IFS_save="$IFS" 40959 IFS=: 40960 for p in $PATH; do 40961 if test -f "$p/$path" && test -x "$p/$path"; then 40962 new_path="$p/$path" 40963 break 40964 fi 40965 done 40966 IFS="$IFS_save" 40967 else 40968 # This is an absolute path, we can use it without further modifications. 40969 new_path="$path" 40970 fi 40971 40972 if test "x$new_path" = x; then 40973 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 40974 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 40975 has_space=`$ECHO "$complete" | $GREP " "` 40976 if test "x$has_space" != x; then 40977 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 40978 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 40979 fi 40980 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 40981 fi 40982 fi 40983 40984 # Now join together the path and the arguments once again 40985 if test "x$arguments" != xEOL; then 40986 new_complete="$new_path ${arguments% *}" 40987 else 40988 new_complete="$new_path" 40989 fi 40990 40991 if test "x$complete" != "x$new_complete"; then 40992 NM="$new_complete" 40993 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting NM to \"$new_complete\"" >&5 40994 $as_echo "$as_me: Rewriting NM to \"$new_complete\"" >&6;} 40995 fi 40996 fi 40997 40998 40999 41000 # Publish this variable in the help. 41001 41002 41003 if [ -z "${GNM+x}" ]; then 41004 # The variable is not set by user, try to locate tool using the code snippet 41005 for ac_prog in gnm 41006 do 41007 # Extract the first word of "$ac_prog", so it can be a program name with args. 41008 set dummy $ac_prog; ac_word=$2 41009 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41010 $as_echo_n "checking for $ac_word... " >&6; } 41011 if ${ac_cv_path_GNM+:} false; then : 41012 $as_echo_n "(cached) " >&6 41013 else 41014 case $GNM in 41015 [\\/]* | ?:[\\/]*) 41016 ac_cv_path_GNM="$GNM" # Let the user override the test with a path. 41017 ;; 41018 *) 41019 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41020 for as_dir in $PATH 41021 do 41022 IFS=$as_save_IFS 41023 test -z "$as_dir" && as_dir=. 41024 for ac_exec_ext in '' $ac_executable_extensions; do 41025 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41026 ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext" 41027 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41028 break 2 41029 fi 41030 done 41031 done 41032 IFS=$as_save_IFS 41033 41034 ;; 41035 esac 41036 fi 41037 GNM=$ac_cv_path_GNM 41038 if test -n "$GNM"; then 41039 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5 41040 $as_echo "$GNM" >&6; } 41041 else 41042 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41043 $as_echo "no" >&6; } 41044 fi 41045 41046 41047 test -n "$GNM" && break 41048 done 41049 41050 else 41051 # The variable is set, but is it from the command line or the environment? 41052 41053 # Try to remove the string !GNM! from our list. 41054 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!GNM!/} 41055 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 41056 # If it failed, the variable was not from the command line. Ignore it, 41057 # but warn the user (except for BASH, which is always set by the calling BASH). 41058 if test "xGNM" != xBASH; then 41059 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of GNM from the environment. Use command line variables instead." >&5 41060 $as_echo "$as_me: WARNING: Ignoring value of GNM from the environment. Use command line variables instead." >&2;} 41061 fi 41062 # Try to locate tool using the code snippet 41063 for ac_prog in gnm 41064 do 41065 # Extract the first word of "$ac_prog", so it can be a program name with args. 41066 set dummy $ac_prog; ac_word=$2 41067 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41068 $as_echo_n "checking for $ac_word... " >&6; } 41069 if ${ac_cv_path_GNM+:} false; then : 41070 $as_echo_n "(cached) " >&6 41071 else 41072 case $GNM in 41073 [\\/]* | ?:[\\/]*) 41074 ac_cv_path_GNM="$GNM" # Let the user override the test with a path. 41075 ;; 41076 *) 41077 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41078 for as_dir in $PATH 41079 do 41080 IFS=$as_save_IFS 41081 test -z "$as_dir" && as_dir=. 41082 for ac_exec_ext in '' $ac_executable_extensions; do 41083 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41084 ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext" 41085 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41086 break 2 41087 fi 41088 done 41089 done 41090 IFS=$as_save_IFS 41091 41092 ;; 41093 esac 41094 fi 41095 GNM=$ac_cv_path_GNM 41096 if test -n "$GNM"; then 41097 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5 41098 $as_echo "$GNM" >&6; } 41099 else 41100 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41101 $as_echo "no" >&6; } 41102 fi 41103 41104 41105 test -n "$GNM" && break 41106 done 41107 41108 else 41109 # If it succeeded, then it was overridden by the user. We will use it 41110 # for the tool. 41111 41112 # First remove it from the list of overridden variables, so we can test 41113 # for unknown variables in the end. 41114 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 41115 41116 # Check if we try to supply an empty value 41117 if test "x$GNM" = x; then 41118 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool GNM= (no value)" >&5 41119 $as_echo "$as_me: Setting user supplied tool GNM= (no value)" >&6;} 41120 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNM" >&5 41121 $as_echo_n "checking for GNM... " >&6; } 41122 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 41123 $as_echo "disabled" >&6; } 41124 else 41125 # Check if the provided tool contains a complete path. 41126 tool_specified="$GNM" 41127 tool_basename="${tool_specified##*/}" 41128 if test "x$tool_basename" = "x$tool_specified"; then 41129 # A command without a complete path is provided, search $PATH. 41130 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool GNM=$tool_basename" >&5 41131 $as_echo "$as_me: Will search for user supplied tool GNM=$tool_basename" >&6;} 41132 # Extract the first word of "$tool_basename", so it can be a program name with args. 41133 set dummy $tool_basename; ac_word=$2 41134 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41135 $as_echo_n "checking for $ac_word... " >&6; } 41136 if ${ac_cv_path_GNM+:} false; then : 41137 $as_echo_n "(cached) " >&6 41138 else 41139 case $GNM in 41140 [\\/]* | ?:[\\/]*) 41141 ac_cv_path_GNM="$GNM" # Let the user override the test with a path. 41142 ;; 41143 *) 41144 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41145 for as_dir in $PATH 41146 do 41147 IFS=$as_save_IFS 41148 test -z "$as_dir" && as_dir=. 41149 for ac_exec_ext in '' $ac_executable_extensions; do 41150 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41151 ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext" 41152 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41153 break 2 41154 fi 41155 done 41156 done 41157 IFS=$as_save_IFS 41158 41159 ;; 41160 esac 41161 fi 41162 GNM=$ac_cv_path_GNM 41163 if test -n "$GNM"; then 41164 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5 41165 $as_echo "$GNM" >&6; } 41166 else 41167 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41168 $as_echo "no" >&6; } 41169 fi 41170 41171 41172 if test "x$GNM" = x; then 41173 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 41174 fi 41175 else 41176 # Otherwise we believe it is a complete path. Use it as it is. 41177 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool GNM=$tool_specified" >&5 41178 $as_echo "$as_me: Will use user supplied tool GNM=$tool_specified" >&6;} 41179 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNM" >&5 41180 $as_echo_n "checking for GNM... " >&6; } 41181 if test ! -x "$tool_specified"; then 41182 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 41183 $as_echo "not found" >&6; } 41184 as_fn_error $? "User supplied tool GNM=$tool_specified does not exist or is not executable" "$LINENO" 5 41185 fi 41186 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 41187 $as_echo "$tool_specified" >&6; } 41188 fi 41189 fi 41190 fi 41191 41192 fi 41193 41194 41195 41196 # Only process if variable expands to non-empty 41197 41198 if test "x$GNM" != x; then 41199 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41200 41201 # First separate the path from the arguments. This will split at the first 41202 # space. 41203 complete="$GNM" 41204 path="${complete%% *}" 41205 tmp="$complete EOL" 41206 arguments="${tmp#* }" 41207 41208 # Input might be given as Windows format, start by converting to 41209 # unix format. 41210 new_path=`$CYGPATH -u "$path"` 41211 41212 # Now try to locate executable using which 41213 new_path=`$WHICH "$new_path" 2> /dev/null` 41214 # bat and cmd files are not always considered executable in cygwin causing which 41215 # to not find them 41216 if test "x$new_path" = x \ 41217 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 41218 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 41219 new_path=`$CYGPATH -u "$path"` 41220 fi 41221 if test "x$new_path" = x; then 41222 # Oops. Which didn't find the executable. 41223 # The splitting of arguments from the executable at a space might have been incorrect, 41224 # since paths with space are more likely in Windows. Give it another try with the whole 41225 # argument. 41226 path="$complete" 41227 arguments="EOL" 41228 new_path=`$CYGPATH -u "$path"` 41229 new_path=`$WHICH "$new_path" 2> /dev/null` 41230 # bat and cmd files are not always considered executable in cygwin causing which 41231 # to not find them 41232 if test "x$new_path" = x \ 41233 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 41234 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 41235 new_path=`$CYGPATH -u "$path"` 41236 fi 41237 if test "x$new_path" = x; then 41238 # It's still not found. Now this is an unrecoverable error. 41239 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5 41240 $as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;} 41241 has_space=`$ECHO "$complete" | $GREP " "` 41242 if test "x$has_space" != x; then 41243 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 41244 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 41245 fi 41246 as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5 41247 fi 41248 fi 41249 41250 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 41251 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 41252 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 41253 # "foo.exe" is OK but "foo" is an error. 41254 # 41255 # This test is therefore slightly more accurate than "test -f" to check for file presence. 41256 # It is also a way to make sure we got the proper file name for the real test later on. 41257 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 41258 if test "x$test_shortpath" = x; then 41259 # Short path failed, file does not exist as specified. 41260 # Try adding .exe or .cmd 41261 if test -f "${new_path}.exe"; then 41262 input_to_shortpath="${new_path}.exe" 41263 elif test -f "${new_path}.cmd"; then 41264 input_to_shortpath="${new_path}.cmd" 41265 else 41266 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$new_path\", is invalid." >&5 41267 $as_echo "$as_me: The path of GNM, which resolves as \"$new_path\", is invalid." >&6;} 41268 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 41269 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 41270 as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5 41271 fi 41272 else 41273 input_to_shortpath="$new_path" 41274 fi 41275 41276 # Call helper function which possibly converts this using DOS-style short mode. 41277 # If so, the updated path is stored in $new_path. 41278 new_path="$input_to_shortpath" 41279 41280 input_path="$input_to_shortpath" 41281 # Check if we need to convert this using DOS-style short mode. If the path 41282 # contains just simple characters, use it. Otherwise (spaces, weird characters), 41283 # take no chances and rewrite it. 41284 # Note: m4 eats our [], so we need to use [ and ] instead. 41285 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 41286 if test "x$has_forbidden_chars" != x; then 41287 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 41288 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 41289 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 41290 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 41291 # Going to short mode and back again did indeed matter. Since short mode is 41292 # case insensitive, let's make it lowercase to improve readability. 41293 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 41294 # Now convert it back to Unix-style (cygpath) 41295 input_path=`$CYGPATH -u "$shortmode_path"` 41296 new_path="$input_path" 41297 fi 41298 fi 41299 41300 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 41301 if test "x$test_cygdrive_prefix" = x; then 41302 # As a simple fix, exclude /usr/bin since it's not a real path. 41303 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 41304 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 41305 # a path prefixed by /cygdrive for fixpath to work. 41306 new_path="$CYGWIN_ROOT_PATH$input_path" 41307 fi 41308 fi 41309 41310 # remove trailing .exe if any 41311 new_path="${new_path/%.exe/}" 41312 41313 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41314 41315 # First separate the path from the arguments. This will split at the first 41316 # space. 41317 complete="$GNM" 41318 path="${complete%% *}" 41319 tmp="$complete EOL" 41320 arguments="${tmp#* }" 41321 41322 # Input might be given as Windows format, start by converting to 41323 # unix format. 41324 new_path="$path" 41325 41326 windows_path="$new_path" 41327 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41328 unix_path=`$CYGPATH -u "$windows_path"` 41329 new_path="$unix_path" 41330 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41331 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41332 new_path="$unix_path" 41333 fi 41334 41335 41336 # Now try to locate executable using which 41337 new_path=`$WHICH "$new_path" 2> /dev/null` 41338 41339 if test "x$new_path" = x; then 41340 # Oops. Which didn't find the executable. 41341 # The splitting of arguments from the executable at a space might have been incorrect, 41342 # since paths with space are more likely in Windows. Give it another try with the whole 41343 # argument. 41344 path="$complete" 41345 arguments="EOL" 41346 new_path="$path" 41347 41348 windows_path="$new_path" 41349 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41350 unix_path=`$CYGPATH -u "$windows_path"` 41351 new_path="$unix_path" 41352 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41353 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41354 new_path="$unix_path" 41355 fi 41356 41357 41358 new_path=`$WHICH "$new_path" 2> /dev/null` 41359 # bat and cmd files are not always considered executable in MSYS causing which 41360 # to not find them 41361 if test "x$new_path" = x \ 41362 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 41363 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 41364 new_path="$path" 41365 41366 windows_path="$new_path" 41367 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41368 unix_path=`$CYGPATH -u "$windows_path"` 41369 new_path="$unix_path" 41370 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41371 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41372 new_path="$unix_path" 41373 fi 41374 41375 fi 41376 41377 if test "x$new_path" = x; then 41378 # It's still not found. Now this is an unrecoverable error. 41379 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5 41380 $as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;} 41381 has_space=`$ECHO "$complete" | $GREP " "` 41382 if test "x$has_space" != x; then 41383 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 41384 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 41385 fi 41386 as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5 41387 fi 41388 fi 41389 41390 # Now new_path has a complete unix path to the binary 41391 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 41392 # Keep paths in /bin as-is, but remove trailing .exe if any 41393 new_path="${new_path/%.exe/}" 41394 # Do not save /bin paths to all_fixpath_prefixes! 41395 else 41396 # Not in mixed or Windows style, start by that. 41397 new_path=`cmd //c echo $new_path` 41398 41399 input_path="$new_path" 41400 # Check if we need to convert this using DOS-style short mode. If the path 41401 # contains just simple characters, use it. Otherwise (spaces, weird characters), 41402 # take no chances and rewrite it. 41403 # Note: m4 eats our [], so we need to use [ and ] instead. 41404 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 41405 if test "x$has_forbidden_chars" != x; then 41406 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 41407 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 41408 fi 41409 41410 # Output is in $new_path 41411 41412 windows_path="$new_path" 41413 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41414 unix_path=`$CYGPATH -u "$windows_path"` 41415 new_path="$unix_path" 41416 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41417 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41418 new_path="$unix_path" 41419 fi 41420 41421 # remove trailing .exe if any 41422 new_path="${new_path/%.exe/}" 41423 41424 # Save the first 10 bytes of this path to the storage, so fixpath can work. 41425 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 41426 fi 41427 41428 else 41429 # We're on a unix platform. Hooray! :) 41430 # First separate the path from the arguments. This will split at the first 41431 # space. 41432 complete="$GNM" 41433 path="${complete%% *}" 41434 tmp="$complete EOL" 41435 arguments="${tmp#* }" 41436 41437 # Cannot rely on the command "which" here since it doesn't always work. 41438 is_absolute_path=`$ECHO "$path" | $GREP ^/` 41439 if test -z "$is_absolute_path"; then 41440 # Path to executable is not absolute. Find it. 41441 IFS_save="$IFS" 41442 IFS=: 41443 for p in $PATH; do 41444 if test -f "$p/$path" && test -x "$p/$path"; then 41445 new_path="$p/$path" 41446 break 41447 fi 41448 done 41449 IFS="$IFS_save" 41450 else 41451 # This is an absolute path, we can use it without further modifications. 41452 new_path="$path" 41453 fi 41454 41455 if test "x$new_path" = x; then 41456 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5 41457 $as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;} 41458 has_space=`$ECHO "$complete" | $GREP " "` 41459 if test "x$has_space" != x; then 41460 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 41461 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 41462 fi 41463 as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5 41464 fi 41465 fi 41466 41467 # Now join together the path and the arguments once again 41468 if test "x$arguments" != xEOL; then 41469 new_complete="$new_path ${arguments% *}" 41470 else 41471 new_complete="$new_path" 41472 fi 41473 41474 if test "x$complete" != "x$new_complete"; then 41475 GNM="$new_complete" 41476 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting GNM to \"$new_complete\"" >&5 41477 $as_echo "$as_me: Rewriting GNM to \"$new_complete\"" >&6;} 41478 fi 41479 fi 41480 41481 elif test "x$OPENJDK_TARGET_OS" != xwindows; then 41482 # FIXME: we should unify this with the solaris case above. 41483 41484 41485 # Publish this variable in the help. 41486 41487 41488 if [ -z "${STRIP+x}" ]; then 41489 # The variable is not set by user, try to locate tool using the code snippet 41490 if test -n "$ac_tool_prefix"; then 41491 for ac_prog in strip 41492 do 41493 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 41494 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 41495 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41496 $as_echo_n "checking for $ac_word... " >&6; } 41497 if ${ac_cv_prog_STRIP+:} false; then : 41498 $as_echo_n "(cached) " >&6 41499 else 41500 if test -n "$STRIP"; then 41501 ac_cv_prog_STRIP="$STRIP" # Let the user override the test. 41502 else 41503 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41504 for as_dir in $PATH 41505 do 41506 IFS=$as_save_IFS 41507 test -z "$as_dir" && as_dir=. 41508 for ac_exec_ext in '' $ac_executable_extensions; do 41509 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41510 ac_cv_prog_STRIP="$ac_tool_prefix$ac_prog" 41511 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41512 break 2 41513 fi 41514 done 41515 done 41516 IFS=$as_save_IFS 41517 41518 fi 41519 fi 41520 STRIP=$ac_cv_prog_STRIP 41521 if test -n "$STRIP"; then 41522 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 41523 $as_echo "$STRIP" >&6; } 41524 else 41525 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41526 $as_echo "no" >&6; } 41527 fi 41528 41529 41530 test -n "$STRIP" && break 41531 done 41532 fi 41533 if test -z "$STRIP"; then 41534 ac_ct_STRIP=$STRIP 41535 for ac_prog in strip 41536 do 41537 # Extract the first word of "$ac_prog", so it can be a program name with args. 41538 set dummy $ac_prog; ac_word=$2 41539 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41540 $as_echo_n "checking for $ac_word... " >&6; } 41541 if ${ac_cv_prog_ac_ct_STRIP+:} false; then : 41542 $as_echo_n "(cached) " >&6 41543 else 41544 if test -n "$ac_ct_STRIP"; then 41545 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. 41546 else 41547 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41548 for as_dir in $PATH 41549 do 41550 IFS=$as_save_IFS 41551 test -z "$as_dir" && as_dir=. 41552 for ac_exec_ext in '' $ac_executable_extensions; do 41553 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41554 ac_cv_prog_ac_ct_STRIP="$ac_prog" 41555 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41556 break 2 41557 fi 41558 done 41559 done 41560 IFS=$as_save_IFS 41561 41562 fi 41563 fi 41564 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP 41565 if test -n "$ac_ct_STRIP"; then 41566 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 41567 $as_echo "$ac_ct_STRIP" >&6; } 41568 else 41569 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41570 $as_echo "no" >&6; } 41571 fi 41572 41573 41574 test -n "$ac_ct_STRIP" && break 41575 done 41576 41577 if test "x$ac_ct_STRIP" = x; then 41578 STRIP="" 41579 else 41580 case $cross_compiling:$ac_tool_warned in 41581 yes:) 41582 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 41583 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 41584 ac_tool_warned=yes ;; 41585 esac 41586 STRIP=$ac_ct_STRIP 41587 fi 41588 fi 41589 41590 else 41591 # The variable is set, but is it from the command line or the environment? 41592 41593 # Try to remove the string !STRIP! from our list. 41594 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!STRIP!/} 41595 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 41596 # If it failed, the variable was not from the command line. Ignore it, 41597 # but warn the user (except for BASH, which is always set by the calling BASH). 41598 if test "xSTRIP" != xBASH; then 41599 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&5 41600 $as_echo "$as_me: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&2;} 41601 fi 41602 # Try to locate tool using the code snippet 41603 if test -n "$ac_tool_prefix"; then 41604 for ac_prog in strip 41605 do 41606 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 41607 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 41608 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41609 $as_echo_n "checking for $ac_word... " >&6; } 41610 if ${ac_cv_prog_STRIP+:} false; then : 41611 $as_echo_n "(cached) " >&6 41612 else 41613 if test -n "$STRIP"; then 41614 ac_cv_prog_STRIP="$STRIP" # Let the user override the test. 41615 else 41616 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41617 for as_dir in $PATH 41618 do 41619 IFS=$as_save_IFS 41620 test -z "$as_dir" && as_dir=. 41621 for ac_exec_ext in '' $ac_executable_extensions; do 41622 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41623 ac_cv_prog_STRIP="$ac_tool_prefix$ac_prog" 41624 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41625 break 2 41626 fi 41627 done 41628 done 41629 IFS=$as_save_IFS 41630 41631 fi 41632 fi 41633 STRIP=$ac_cv_prog_STRIP 41634 if test -n "$STRIP"; then 41635 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 41636 $as_echo "$STRIP" >&6; } 41637 else 41638 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41639 $as_echo "no" >&6; } 41640 fi 41641 41642 41643 test -n "$STRIP" && break 41644 done 41645 fi 41646 if test -z "$STRIP"; then 41647 ac_ct_STRIP=$STRIP 41648 for ac_prog in strip 41649 do 41650 # Extract the first word of "$ac_prog", so it can be a program name with args. 41651 set dummy $ac_prog; ac_word=$2 41652 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41653 $as_echo_n "checking for $ac_word... " >&6; } 41654 if ${ac_cv_prog_ac_ct_STRIP+:} false; then : 41655 $as_echo_n "(cached) " >&6 41656 else 41657 if test -n "$ac_ct_STRIP"; then 41658 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. 41659 else 41660 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41661 for as_dir in $PATH 41662 do 41663 IFS=$as_save_IFS 41664 test -z "$as_dir" && as_dir=. 41665 for ac_exec_ext in '' $ac_executable_extensions; do 41666 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41667 ac_cv_prog_ac_ct_STRIP="$ac_prog" 41668 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41669 break 2 41670 fi 41671 done 41672 done 41673 IFS=$as_save_IFS 41674 41675 fi 41676 fi 41677 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP 41678 if test -n "$ac_ct_STRIP"; then 41679 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 41680 $as_echo "$ac_ct_STRIP" >&6; } 41681 else 41682 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41683 $as_echo "no" >&6; } 41684 fi 41685 41686 41687 test -n "$ac_ct_STRIP" && break 41688 done 41689 41690 if test "x$ac_ct_STRIP" = x; then 41691 STRIP="" 41692 else 41693 case $cross_compiling:$ac_tool_warned in 41694 yes:) 41695 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 41696 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 41697 ac_tool_warned=yes ;; 41698 esac 41699 STRIP=$ac_ct_STRIP 41700 fi 41701 fi 41702 41703 else 41704 # If it succeeded, then it was overridden by the user. We will use it 41705 # for the tool. 41706 41707 # First remove it from the list of overridden variables, so we can test 41708 # for unknown variables in the end. 41709 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 41710 41711 # Check if we try to supply an empty value 41712 if test "x$STRIP" = x; then 41713 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool STRIP= (no value)" >&5 41714 $as_echo "$as_me: Setting user supplied tool STRIP= (no value)" >&6;} 41715 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5 41716 $as_echo_n "checking for STRIP... " >&6; } 41717 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 41718 $as_echo "disabled" >&6; } 41719 else 41720 # Check if the provided tool contains a complete path. 41721 tool_specified="$STRIP" 41722 tool_basename="${tool_specified##*/}" 41723 if test "x$tool_basename" = "x$tool_specified"; then 41724 # A command without a complete path is provided, search $PATH. 41725 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool STRIP=$tool_basename" >&5 41726 $as_echo "$as_me: Will search for user supplied tool STRIP=$tool_basename" >&6;} 41727 # Extract the first word of "$tool_basename", so it can be a program name with args. 41728 set dummy $tool_basename; ac_word=$2 41729 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41730 $as_echo_n "checking for $ac_word... " >&6; } 41731 if ${ac_cv_path_STRIP+:} false; then : 41732 $as_echo_n "(cached) " >&6 41733 else 41734 case $STRIP in 41735 [\\/]* | ?:[\\/]*) 41736 ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path. 41737 ;; 41738 *) 41739 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41740 for as_dir in $PATH 41741 do 41742 IFS=$as_save_IFS 41743 test -z "$as_dir" && as_dir=. 41744 for ac_exec_ext in '' $ac_executable_extensions; do 41745 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41746 ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext" 41747 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41748 break 2 41749 fi 41750 done 41751 done 41752 IFS=$as_save_IFS 41753 41754 ;; 41755 esac 41756 fi 41757 STRIP=$ac_cv_path_STRIP 41758 if test -n "$STRIP"; then 41759 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 41760 $as_echo "$STRIP" >&6; } 41761 else 41762 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41763 $as_echo "no" >&6; } 41764 fi 41765 41766 41767 if test "x$STRIP" = x; then 41768 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 41769 fi 41770 else 41771 # Otherwise we believe it is a complete path. Use it as it is. 41772 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool STRIP=$tool_specified" >&5 41773 $as_echo "$as_me: Will use user supplied tool STRIP=$tool_specified" >&6;} 41774 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5 41775 $as_echo_n "checking for STRIP... " >&6; } 41776 if test ! -x "$tool_specified"; then 41777 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 41778 $as_echo "not found" >&6; } 41779 as_fn_error $? "User supplied tool STRIP=$tool_specified does not exist or is not executable" "$LINENO" 5 41780 fi 41781 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 41782 $as_echo "$tool_specified" >&6; } 41783 fi 41784 fi 41785 fi 41786 41787 fi 41788 41789 41790 41791 # Only process if variable expands to non-empty 41792 41793 if test "x$STRIP" != x; then 41794 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41795 41796 # First separate the path from the arguments. This will split at the first 41797 # space. 41798 complete="$STRIP" 41799 path="${complete%% *}" 41800 tmp="$complete EOL" 41801 arguments="${tmp#* }" 41802 41803 # Input might be given as Windows format, start by converting to 41804 # unix format. 41805 new_path=`$CYGPATH -u "$path"` 41806 41807 # Now try to locate executable using which 41808 new_path=`$WHICH "$new_path" 2> /dev/null` 41809 # bat and cmd files are not always considered executable in cygwin causing which 41810 # to not find them 41811 if test "x$new_path" = x \ 41812 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 41813 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 41814 new_path=`$CYGPATH -u "$path"` 41815 fi 41816 if test "x$new_path" = x; then 41817 # Oops. Which didn't find the executable. 41818 # The splitting of arguments from the executable at a space might have been incorrect, 41819 # since paths with space are more likely in Windows. Give it another try with the whole 41820 # argument. 41821 path="$complete" 41822 arguments="EOL" 41823 new_path=`$CYGPATH -u "$path"` 41824 new_path=`$WHICH "$new_path" 2> /dev/null` 41825 # bat and cmd files are not always considered executable in cygwin causing which 41826 # to not find them 41827 if test "x$new_path" = x \ 41828 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 41829 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 41830 new_path=`$CYGPATH -u "$path"` 41831 fi 41832 if test "x$new_path" = x; then 41833 # It's still not found. Now this is an unrecoverable error. 41834 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 41835 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 41836 has_space=`$ECHO "$complete" | $GREP " "` 41837 if test "x$has_space" != x; then 41838 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 41839 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 41840 fi 41841 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 41842 fi 41843 fi 41844 41845 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 41846 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 41847 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 41848 # "foo.exe" is OK but "foo" is an error. 41849 # 41850 # This test is therefore slightly more accurate than "test -f" to check for file presence. 41851 # It is also a way to make sure we got the proper file name for the real test later on. 41852 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 41853 if test "x$test_shortpath" = x; then 41854 # Short path failed, file does not exist as specified. 41855 # Try adding .exe or .cmd 41856 if test -f "${new_path}.exe"; then 41857 input_to_shortpath="${new_path}.exe" 41858 elif test -f "${new_path}.cmd"; then 41859 input_to_shortpath="${new_path}.cmd" 41860 else 41861 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$new_path\", is invalid." >&5 41862 $as_echo "$as_me: The path of STRIP, which resolves as \"$new_path\", is invalid." >&6;} 41863 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 41864 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 41865 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 41866 fi 41867 else 41868 input_to_shortpath="$new_path" 41869 fi 41870 41871 # Call helper function which possibly converts this using DOS-style short mode. 41872 # If so, the updated path is stored in $new_path. 41873 new_path="$input_to_shortpath" 41874 41875 input_path="$input_to_shortpath" 41876 # Check if we need to convert this using DOS-style short mode. If the path 41877 # contains just simple characters, use it. Otherwise (spaces, weird characters), 41878 # take no chances and rewrite it. 41879 # Note: m4 eats our [], so we need to use [ and ] instead. 41880 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 41881 if test "x$has_forbidden_chars" != x; then 41882 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 41883 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 41884 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 41885 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 41886 # Going to short mode and back again did indeed matter. Since short mode is 41887 # case insensitive, let's make it lowercase to improve readability. 41888 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 41889 # Now convert it back to Unix-style (cygpath) 41890 input_path=`$CYGPATH -u "$shortmode_path"` 41891 new_path="$input_path" 41892 fi 41893 fi 41894 41895 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 41896 if test "x$test_cygdrive_prefix" = x; then 41897 # As a simple fix, exclude /usr/bin since it's not a real path. 41898 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 41899 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 41900 # a path prefixed by /cygdrive for fixpath to work. 41901 new_path="$CYGWIN_ROOT_PATH$input_path" 41902 fi 41903 fi 41904 41905 # remove trailing .exe if any 41906 new_path="${new_path/%.exe/}" 41907 41908 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41909 41910 # First separate the path from the arguments. This will split at the first 41911 # space. 41912 complete="$STRIP" 41913 path="${complete%% *}" 41914 tmp="$complete EOL" 41915 arguments="${tmp#* }" 41916 41917 # Input might be given as Windows format, start by converting to 41918 # unix format. 41919 new_path="$path" 41920 41921 windows_path="$new_path" 41922 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41923 unix_path=`$CYGPATH -u "$windows_path"` 41924 new_path="$unix_path" 41925 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41926 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41927 new_path="$unix_path" 41928 fi 41929 41930 41931 # Now try to locate executable using which 41932 new_path=`$WHICH "$new_path" 2> /dev/null` 41933 41934 if test "x$new_path" = x; then 41935 # Oops. Which didn't find the executable. 41936 # The splitting of arguments from the executable at a space might have been incorrect, 41937 # since paths with space are more likely in Windows. Give it another try with the whole 41938 # argument. 41939 path="$complete" 41940 arguments="EOL" 41941 new_path="$path" 41942 41943 windows_path="$new_path" 41944 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41945 unix_path=`$CYGPATH -u "$windows_path"` 41946 new_path="$unix_path" 41947 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41948 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41949 new_path="$unix_path" 41950 fi 41951 41952 41953 new_path=`$WHICH "$new_path" 2> /dev/null` 41954 # bat and cmd files are not always considered executable in MSYS causing which 41955 # to not find them 41956 if test "x$new_path" = x \ 41957 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 41958 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 41959 new_path="$path" 41960 41961 windows_path="$new_path" 41962 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41963 unix_path=`$CYGPATH -u "$windows_path"` 41964 new_path="$unix_path" 41965 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41966 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41967 new_path="$unix_path" 41968 fi 41969 41970 fi 41971 41972 if test "x$new_path" = x; then 41973 # It's still not found. Now this is an unrecoverable error. 41974 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 41975 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 41976 has_space=`$ECHO "$complete" | $GREP " "` 41977 if test "x$has_space" != x; then 41978 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 41979 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 41980 fi 41981 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 41982 fi 41983 fi 41984 41985 # Now new_path has a complete unix path to the binary 41986 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 41987 # Keep paths in /bin as-is, but remove trailing .exe if any 41988 new_path="${new_path/%.exe/}" 41989 # Do not save /bin paths to all_fixpath_prefixes! 41990 else 41991 # Not in mixed or Windows style, start by that. 41992 new_path=`cmd //c echo $new_path` 41993 41994 input_path="$new_path" 41995 # Check if we need to convert this using DOS-style short mode. If the path 41996 # contains just simple characters, use it. Otherwise (spaces, weird characters), 41997 # take no chances and rewrite it. 41998 # Note: m4 eats our [], so we need to use [ and ] instead. 41999 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 42000 if test "x$has_forbidden_chars" != x; then 42001 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 42002 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 42003 fi 42004 42005 # Output is in $new_path 42006 42007 windows_path="$new_path" 42008 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42009 unix_path=`$CYGPATH -u "$windows_path"` 42010 new_path="$unix_path" 42011 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42012 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42013 new_path="$unix_path" 42014 fi 42015 42016 # remove trailing .exe if any 42017 new_path="${new_path/%.exe/}" 42018 42019 # Save the first 10 bytes of this path to the storage, so fixpath can work. 42020 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 42021 fi 42022 42023 else 42024 # We're on a unix platform. Hooray! :) 42025 # First separate the path from the arguments. This will split at the first 42026 # space. 42027 complete="$STRIP" 42028 path="${complete%% *}" 42029 tmp="$complete EOL" 42030 arguments="${tmp#* }" 42031 42032 # Cannot rely on the command "which" here since it doesn't always work. 42033 is_absolute_path=`$ECHO "$path" | $GREP ^/` 42034 if test -z "$is_absolute_path"; then 42035 # Path to executable is not absolute. Find it. 42036 IFS_save="$IFS" 42037 IFS=: 42038 for p in $PATH; do 42039 if test -f "$p/$path" && test -x "$p/$path"; then 42040 new_path="$p/$path" 42041 break 42042 fi 42043 done 42044 IFS="$IFS_save" 42045 else 42046 # This is an absolute path, we can use it without further modifications. 42047 new_path="$path" 42048 fi 42049 42050 if test "x$new_path" = x; then 42051 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 42052 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 42053 has_space=`$ECHO "$complete" | $GREP " "` 42054 if test "x$has_space" != x; then 42055 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 42056 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 42057 fi 42058 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 42059 fi 42060 fi 42061 42062 # Now join together the path and the arguments once again 42063 if test "x$arguments" != xEOL; then 42064 new_complete="$new_path ${arguments% *}" 42065 else 42066 new_complete="$new_path" 42067 fi 42068 42069 if test "x$complete" != "x$new_complete"; then 42070 STRIP="$new_complete" 42071 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STRIP to \"$new_complete\"" >&5 42072 $as_echo "$as_me: Rewriting STRIP to \"$new_complete\"" >&6;} 42073 fi 42074 fi 42075 42076 if test "x$TOOLCHAIN_TYPE" = xgcc; then 42077 42078 42079 # Publish this variable in the help. 42080 42081 42082 if [ -z "${NM+x}" ]; then 42083 # The variable is not set by user, try to locate tool using the code snippet 42084 if test -n "$ac_tool_prefix"; then 42085 for ac_prog in nm gcc-nm 42086 do 42087 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 42088 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 42089 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42090 $as_echo_n "checking for $ac_word... " >&6; } 42091 if ${ac_cv_prog_NM+:} false; then : 42092 $as_echo_n "(cached) " >&6 42093 else 42094 if test -n "$NM"; then 42095 ac_cv_prog_NM="$NM" # Let the user override the test. 42096 else 42097 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42098 for as_dir in $PATH 42099 do 42100 IFS=$as_save_IFS 42101 test -z "$as_dir" && as_dir=. 42102 for ac_exec_ext in '' $ac_executable_extensions; do 42103 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42104 ac_cv_prog_NM="$ac_tool_prefix$ac_prog" 42105 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42106 break 2 42107 fi 42108 done 42109 done 42110 IFS=$as_save_IFS 42111 42112 fi 42113 fi 42114 NM=$ac_cv_prog_NM 42115 if test -n "$NM"; then 42116 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 42117 $as_echo "$NM" >&6; } 42118 else 42119 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42120 $as_echo "no" >&6; } 42121 fi 42122 42123 42124 test -n "$NM" && break 42125 done 42126 fi 42127 if test -z "$NM"; then 42128 ac_ct_NM=$NM 42129 for ac_prog in nm gcc-nm 42130 do 42131 # Extract the first word of "$ac_prog", so it can be a program name with args. 42132 set dummy $ac_prog; ac_word=$2 42133 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42134 $as_echo_n "checking for $ac_word... " >&6; } 42135 if ${ac_cv_prog_ac_ct_NM+:} false; then : 42136 $as_echo_n "(cached) " >&6 42137 else 42138 if test -n "$ac_ct_NM"; then 42139 ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test. 42140 else 42141 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42142 for as_dir in $PATH 42143 do 42144 IFS=$as_save_IFS 42145 test -z "$as_dir" && as_dir=. 42146 for ac_exec_ext in '' $ac_executable_extensions; do 42147 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42148 ac_cv_prog_ac_ct_NM="$ac_prog" 42149 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42150 break 2 42151 fi 42152 done 42153 done 42154 IFS=$as_save_IFS 42155 42156 fi 42157 fi 42158 ac_ct_NM=$ac_cv_prog_ac_ct_NM 42159 if test -n "$ac_ct_NM"; then 42160 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5 42161 $as_echo "$ac_ct_NM" >&6; } 42162 else 42163 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42164 $as_echo "no" >&6; } 42165 fi 42166 42167 42168 test -n "$ac_ct_NM" && break 42169 done 42170 42171 if test "x$ac_ct_NM" = x; then 42172 NM="" 42173 else 42174 case $cross_compiling:$ac_tool_warned in 42175 yes:) 42176 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 42177 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 42178 ac_tool_warned=yes ;; 42179 esac 42180 NM=$ac_ct_NM 42181 fi 42182 fi 42183 42184 else 42185 # The variable is set, but is it from the command line or the environment? 42186 42187 # Try to remove the string !NM! from our list. 42188 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NM!/} 42189 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 42190 # If it failed, the variable was not from the command line. Ignore it, 42191 # but warn the user (except for BASH, which is always set by the calling BASH). 42192 if test "xNM" != xBASH; then 42193 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&5 42194 $as_echo "$as_me: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&2;} 42195 fi 42196 # Try to locate tool using the code snippet 42197 if test -n "$ac_tool_prefix"; then 42198 for ac_prog in nm gcc-nm 42199 do 42200 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 42201 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 42202 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42203 $as_echo_n "checking for $ac_word... " >&6; } 42204 if ${ac_cv_prog_NM+:} false; then : 42205 $as_echo_n "(cached) " >&6 42206 else 42207 if test -n "$NM"; then 42208 ac_cv_prog_NM="$NM" # Let the user override the test. 42209 else 42210 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42211 for as_dir in $PATH 42212 do 42213 IFS=$as_save_IFS 42214 test -z "$as_dir" && as_dir=. 42215 for ac_exec_ext in '' $ac_executable_extensions; do 42216 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42217 ac_cv_prog_NM="$ac_tool_prefix$ac_prog" 42218 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42219 break 2 42220 fi 42221 done 42222 done 42223 IFS=$as_save_IFS 42224 42225 fi 42226 fi 42227 NM=$ac_cv_prog_NM 42228 if test -n "$NM"; then 42229 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 42230 $as_echo "$NM" >&6; } 42231 else 42232 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42233 $as_echo "no" >&6; } 42234 fi 42235 42236 42237 test -n "$NM" && break 42238 done 42239 fi 42240 if test -z "$NM"; then 42241 ac_ct_NM=$NM 42242 for ac_prog in nm gcc-nm 42243 do 42244 # Extract the first word of "$ac_prog", so it can be a program name with args. 42245 set dummy $ac_prog; ac_word=$2 42246 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42247 $as_echo_n "checking for $ac_word... " >&6; } 42248 if ${ac_cv_prog_ac_ct_NM+:} false; then : 42249 $as_echo_n "(cached) " >&6 42250 else 42251 if test -n "$ac_ct_NM"; then 42252 ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test. 42253 else 42254 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42255 for as_dir in $PATH 42256 do 42257 IFS=$as_save_IFS 42258 test -z "$as_dir" && as_dir=. 42259 for ac_exec_ext in '' $ac_executable_extensions; do 42260 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42261 ac_cv_prog_ac_ct_NM="$ac_prog" 42262 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42263 break 2 42264 fi 42265 done 42266 done 42267 IFS=$as_save_IFS 42268 42269 fi 42270 fi 42271 ac_ct_NM=$ac_cv_prog_ac_ct_NM 42272 if test -n "$ac_ct_NM"; then 42273 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5 42274 $as_echo "$ac_ct_NM" >&6; } 42275 else 42276 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42277 $as_echo "no" >&6; } 42278 fi 42279 42280 42281 test -n "$ac_ct_NM" && break 42282 done 42283 42284 if test "x$ac_ct_NM" = x; then 42285 NM="" 42286 else 42287 case $cross_compiling:$ac_tool_warned in 42288 yes:) 42289 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 42290 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 42291 ac_tool_warned=yes ;; 42292 esac 42293 NM=$ac_ct_NM 42294 fi 42295 fi 42296 42297 else 42298 # If it succeeded, then it was overridden by the user. We will use it 42299 # for the tool. 42300 42301 # First remove it from the list of overridden variables, so we can test 42302 # for unknown variables in the end. 42303 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 42304 42305 # Check if we try to supply an empty value 42306 if test "x$NM" = x; then 42307 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool NM= (no value)" >&5 42308 $as_echo "$as_me: Setting user supplied tool NM= (no value)" >&6;} 42309 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 42310 $as_echo_n "checking for NM... " >&6; } 42311 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 42312 $as_echo "disabled" >&6; } 42313 else 42314 # Check if the provided tool contains a complete path. 42315 tool_specified="$NM" 42316 tool_basename="${tool_specified##*/}" 42317 if test "x$tool_basename" = "x$tool_specified"; then 42318 # A command without a complete path is provided, search $PATH. 42319 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NM=$tool_basename" >&5 42320 $as_echo "$as_me: Will search for user supplied tool NM=$tool_basename" >&6;} 42321 # Extract the first word of "$tool_basename", so it can be a program name with args. 42322 set dummy $tool_basename; ac_word=$2 42323 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42324 $as_echo_n "checking for $ac_word... " >&6; } 42325 if ${ac_cv_path_NM+:} false; then : 42326 $as_echo_n "(cached) " >&6 42327 else 42328 case $NM in 42329 [\\/]* | ?:[\\/]*) 42330 ac_cv_path_NM="$NM" # Let the user override the test with a path. 42331 ;; 42332 *) 42333 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42334 for as_dir in $PATH 42335 do 42336 IFS=$as_save_IFS 42337 test -z "$as_dir" && as_dir=. 42338 for ac_exec_ext in '' $ac_executable_extensions; do 42339 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42340 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 42341 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42342 break 2 42343 fi 42344 done 42345 done 42346 IFS=$as_save_IFS 42347 42348 ;; 42349 esac 42350 fi 42351 NM=$ac_cv_path_NM 42352 if test -n "$NM"; then 42353 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 42354 $as_echo "$NM" >&6; } 42355 else 42356 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42357 $as_echo "no" >&6; } 42358 fi 42359 42360 42361 if test "x$NM" = x; then 42362 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 42363 fi 42364 else 42365 # Otherwise we believe it is a complete path. Use it as it is. 42366 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NM=$tool_specified" >&5 42367 $as_echo "$as_me: Will use user supplied tool NM=$tool_specified" >&6;} 42368 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 42369 $as_echo_n "checking for NM... " >&6; } 42370 if test ! -x "$tool_specified"; then 42371 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 42372 $as_echo "not found" >&6; } 42373 as_fn_error $? "User supplied tool NM=$tool_specified does not exist or is not executable" "$LINENO" 5 42374 fi 42375 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 42376 $as_echo "$tool_specified" >&6; } 42377 fi 42378 fi 42379 fi 42380 42381 fi 42382 42383 42384 else 42385 42386 42387 # Publish this variable in the help. 42388 42389 42390 if [ -z "${NM+x}" ]; then 42391 # The variable is not set by user, try to locate tool using the code snippet 42392 if test -n "$ac_tool_prefix"; then 42393 for ac_prog in nm 42394 do 42395 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 42396 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 42397 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42398 $as_echo_n "checking for $ac_word... " >&6; } 42399 if ${ac_cv_prog_NM+:} false; then : 42400 $as_echo_n "(cached) " >&6 42401 else 42402 if test -n "$NM"; then 42403 ac_cv_prog_NM="$NM" # Let the user override the test. 42404 else 42405 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42406 for as_dir in $PATH 42407 do 42408 IFS=$as_save_IFS 42409 test -z "$as_dir" && as_dir=. 42410 for ac_exec_ext in '' $ac_executable_extensions; do 42411 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42412 ac_cv_prog_NM="$ac_tool_prefix$ac_prog" 42413 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42414 break 2 42415 fi 42416 done 42417 done 42418 IFS=$as_save_IFS 42419 42420 fi 42421 fi 42422 NM=$ac_cv_prog_NM 42423 if test -n "$NM"; then 42424 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 42425 $as_echo "$NM" >&6; } 42426 else 42427 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42428 $as_echo "no" >&6; } 42429 fi 42430 42431 42432 test -n "$NM" && break 42433 done 42434 fi 42435 if test -z "$NM"; then 42436 ac_ct_NM=$NM 42437 for ac_prog in nm 42438 do 42439 # Extract the first word of "$ac_prog", so it can be a program name with args. 42440 set dummy $ac_prog; ac_word=$2 42441 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42442 $as_echo_n "checking for $ac_word... " >&6; } 42443 if ${ac_cv_prog_ac_ct_NM+:} false; then : 42444 $as_echo_n "(cached) " >&6 42445 else 42446 if test -n "$ac_ct_NM"; then 42447 ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test. 42448 else 42449 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42450 for as_dir in $PATH 42451 do 42452 IFS=$as_save_IFS 42453 test -z "$as_dir" && as_dir=. 42454 for ac_exec_ext in '' $ac_executable_extensions; do 42455 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42456 ac_cv_prog_ac_ct_NM="$ac_prog" 42457 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42458 break 2 42459 fi 42460 done 42461 done 42462 IFS=$as_save_IFS 42463 42464 fi 42465 fi 42466 ac_ct_NM=$ac_cv_prog_ac_ct_NM 42467 if test -n "$ac_ct_NM"; then 42468 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5 42469 $as_echo "$ac_ct_NM" >&6; } 42470 else 42471 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42472 $as_echo "no" >&6; } 42473 fi 42474 42475 42476 test -n "$ac_ct_NM" && break 42477 done 42478 42479 if test "x$ac_ct_NM" = x; then 42480 NM="" 42481 else 42482 case $cross_compiling:$ac_tool_warned in 42483 yes:) 42484 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 42485 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 42486 ac_tool_warned=yes ;; 42487 esac 42488 NM=$ac_ct_NM 42489 fi 42490 fi 42491 42492 else 42493 # The variable is set, but is it from the command line or the environment? 42494 42495 # Try to remove the string !NM! from our list. 42496 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NM!/} 42497 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 42498 # If it failed, the variable was not from the command line. Ignore it, 42499 # but warn the user (except for BASH, which is always set by the calling BASH). 42500 if test "xNM" != xBASH; then 42501 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&5 42502 $as_echo "$as_me: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&2;} 42503 fi 42504 # Try to locate tool using the code snippet 42505 if test -n "$ac_tool_prefix"; then 42506 for ac_prog in nm 42507 do 42508 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 42509 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 42510 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42511 $as_echo_n "checking for $ac_word... " >&6; } 42512 if ${ac_cv_prog_NM+:} false; then : 42513 $as_echo_n "(cached) " >&6 42514 else 42515 if test -n "$NM"; then 42516 ac_cv_prog_NM="$NM" # Let the user override the test. 42517 else 42518 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42519 for as_dir in $PATH 42520 do 42521 IFS=$as_save_IFS 42522 test -z "$as_dir" && as_dir=. 42523 for ac_exec_ext in '' $ac_executable_extensions; do 42524 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42525 ac_cv_prog_NM="$ac_tool_prefix$ac_prog" 42526 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42527 break 2 42528 fi 42529 done 42530 done 42531 IFS=$as_save_IFS 42532 42533 fi 42534 fi 42535 NM=$ac_cv_prog_NM 42536 if test -n "$NM"; then 42537 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 42538 $as_echo "$NM" >&6; } 42539 else 42540 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42541 $as_echo "no" >&6; } 42542 fi 42543 42544 42545 test -n "$NM" && break 42546 done 42547 fi 42548 if test -z "$NM"; then 42549 ac_ct_NM=$NM 42550 for ac_prog in nm 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_prog_ac_ct_NM+:} false; then : 42557 $as_echo_n "(cached) " >&6 42558 else 42559 if test -n "$ac_ct_NM"; then 42560 ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test. 42561 else 42562 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42563 for as_dir in $PATH 42564 do 42565 IFS=$as_save_IFS 42566 test -z "$as_dir" && as_dir=. 42567 for ac_exec_ext in '' $ac_executable_extensions; do 42568 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42569 ac_cv_prog_ac_ct_NM="$ac_prog" 42570 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42571 break 2 42572 fi 42573 done 42574 done 42575 IFS=$as_save_IFS 42576 42577 fi 42578 fi 42579 ac_ct_NM=$ac_cv_prog_ac_ct_NM 42580 if test -n "$ac_ct_NM"; then 42581 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5 42582 $as_echo "$ac_ct_NM" >&6; } 42583 else 42584 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42585 $as_echo "no" >&6; } 42586 fi 42587 42588 42589 test -n "$ac_ct_NM" && break 42590 done 42591 42592 if test "x$ac_ct_NM" = x; then 42593 NM="" 42594 else 42595 case $cross_compiling:$ac_tool_warned in 42596 yes:) 42597 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 42598 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 42599 ac_tool_warned=yes ;; 42600 esac 42601 NM=$ac_ct_NM 42602 fi 42603 fi 42604 42605 else 42606 # If it succeeded, then it was overridden by the user. We will use it 42607 # for the tool. 42608 42609 # First remove it from the list of overridden variables, so we can test 42610 # for unknown variables in the end. 42611 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 42612 42613 # Check if we try to supply an empty value 42614 if test "x$NM" = x; then 42615 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool NM= (no value)" >&5 42616 $as_echo "$as_me: Setting user supplied tool NM= (no value)" >&6;} 42617 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 42618 $as_echo_n "checking for NM... " >&6; } 42619 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 42620 $as_echo "disabled" >&6; } 42621 else 42622 # Check if the provided tool contains a complete path. 42623 tool_specified="$NM" 42624 tool_basename="${tool_specified##*/}" 42625 if test "x$tool_basename" = "x$tool_specified"; then 42626 # A command without a complete path is provided, search $PATH. 42627 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NM=$tool_basename" >&5 42628 $as_echo "$as_me: Will search for user supplied tool NM=$tool_basename" >&6;} 42629 # Extract the first word of "$tool_basename", so it can be a program name with args. 42630 set dummy $tool_basename; ac_word=$2 42631 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42632 $as_echo_n "checking for $ac_word... " >&6; } 42633 if ${ac_cv_path_NM+:} false; then : 42634 $as_echo_n "(cached) " >&6 42635 else 42636 case $NM in 42637 [\\/]* | ?:[\\/]*) 42638 ac_cv_path_NM="$NM" # Let the user override the test with a path. 42639 ;; 42640 *) 42641 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42642 for as_dir in $PATH 42643 do 42644 IFS=$as_save_IFS 42645 test -z "$as_dir" && as_dir=. 42646 for ac_exec_ext in '' $ac_executable_extensions; do 42647 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42648 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 42649 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42650 break 2 42651 fi 42652 done 42653 done 42654 IFS=$as_save_IFS 42655 42656 ;; 42657 esac 42658 fi 42659 NM=$ac_cv_path_NM 42660 if test -n "$NM"; then 42661 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 42662 $as_echo "$NM" >&6; } 42663 else 42664 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42665 $as_echo "no" >&6; } 42666 fi 42667 42668 42669 if test "x$NM" = x; then 42670 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 42671 fi 42672 else 42673 # Otherwise we believe it is a complete path. Use it as it is. 42674 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NM=$tool_specified" >&5 42675 $as_echo "$as_me: Will use user supplied tool NM=$tool_specified" >&6;} 42676 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 42677 $as_echo_n "checking for NM... " >&6; } 42678 if test ! -x "$tool_specified"; then 42679 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 42680 $as_echo "not found" >&6; } 42681 as_fn_error $? "User supplied tool NM=$tool_specified does not exist or is not executable" "$LINENO" 5 42682 fi 42683 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 42684 $as_echo "$tool_specified" >&6; } 42685 fi 42686 fi 42687 fi 42688 42689 fi 42690 42691 42692 fi 42693 42694 # Only process if variable expands to non-empty 42695 42696 if test "x$NM" != x; then 42697 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42698 42699 # First separate the path from the arguments. This will split at the first 42700 # space. 42701 complete="$NM" 42702 path="${complete%% *}" 42703 tmp="$complete EOL" 42704 arguments="${tmp#* }" 42705 42706 # Input might be given as Windows format, start by converting to 42707 # unix format. 42708 new_path=`$CYGPATH -u "$path"` 42709 42710 # Now try to locate executable using which 42711 new_path=`$WHICH "$new_path" 2> /dev/null` 42712 # bat and cmd files are not always considered executable in cygwin causing which 42713 # to not find them 42714 if test "x$new_path" = x \ 42715 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 42716 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 42717 new_path=`$CYGPATH -u "$path"` 42718 fi 42719 if test "x$new_path" = x; then 42720 # Oops. Which didn't find the executable. 42721 # The splitting of arguments from the executable at a space might have been incorrect, 42722 # since paths with space are more likely in Windows. Give it another try with the whole 42723 # argument. 42724 path="$complete" 42725 arguments="EOL" 42726 new_path=`$CYGPATH -u "$path"` 42727 new_path=`$WHICH "$new_path" 2> /dev/null` 42728 # bat and cmd files are not always considered executable in cygwin causing which 42729 # to not find them 42730 if test "x$new_path" = x \ 42731 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 42732 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 42733 new_path=`$CYGPATH -u "$path"` 42734 fi 42735 if test "x$new_path" = x; then 42736 # It's still not found. Now this is an unrecoverable error. 42737 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 42738 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 42739 has_space=`$ECHO "$complete" | $GREP " "` 42740 if test "x$has_space" != x; then 42741 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 42742 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 42743 fi 42744 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 42745 fi 42746 fi 42747 42748 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 42749 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 42750 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 42751 # "foo.exe" is OK but "foo" is an error. 42752 # 42753 # This test is therefore slightly more accurate than "test -f" to check for file presence. 42754 # It is also a way to make sure we got the proper file name for the real test later on. 42755 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 42756 if test "x$test_shortpath" = x; then 42757 # Short path failed, file does not exist as specified. 42758 # Try adding .exe or .cmd 42759 if test -f "${new_path}.exe"; then 42760 input_to_shortpath="${new_path}.exe" 42761 elif test -f "${new_path}.cmd"; then 42762 input_to_shortpath="${new_path}.cmd" 42763 else 42764 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$new_path\", is invalid." >&5 42765 $as_echo "$as_me: The path of NM, which resolves as \"$new_path\", is invalid." >&6;} 42766 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 42767 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 42768 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 42769 fi 42770 else 42771 input_to_shortpath="$new_path" 42772 fi 42773 42774 # Call helper function which possibly converts this using DOS-style short mode. 42775 # If so, the updated path is stored in $new_path. 42776 new_path="$input_to_shortpath" 42777 42778 input_path="$input_to_shortpath" 42779 # Check if we need to convert this using DOS-style short mode. If the path 42780 # contains just simple characters, use it. Otherwise (spaces, weird characters), 42781 # take no chances and rewrite it. 42782 # Note: m4 eats our [], so we need to use [ and ] instead. 42783 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 42784 if test "x$has_forbidden_chars" != x; then 42785 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 42786 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 42787 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 42788 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 42789 # Going to short mode and back again did indeed matter. Since short mode is 42790 # case insensitive, let's make it lowercase to improve readability. 42791 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 42792 # Now convert it back to Unix-style (cygpath) 42793 input_path=`$CYGPATH -u "$shortmode_path"` 42794 new_path="$input_path" 42795 fi 42796 fi 42797 42798 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 42799 if test "x$test_cygdrive_prefix" = x; then 42800 # As a simple fix, exclude /usr/bin since it's not a real path. 42801 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 42802 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 42803 # a path prefixed by /cygdrive for fixpath to work. 42804 new_path="$CYGWIN_ROOT_PATH$input_path" 42805 fi 42806 fi 42807 42808 # remove trailing .exe if any 42809 new_path="${new_path/%.exe/}" 42810 42811 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42812 42813 # First separate the path from the arguments. This will split at the first 42814 # space. 42815 complete="$NM" 42816 path="${complete%% *}" 42817 tmp="$complete EOL" 42818 arguments="${tmp#* }" 42819 42820 # Input might be given as Windows format, start by converting to 42821 # unix format. 42822 new_path="$path" 42823 42824 windows_path="$new_path" 42825 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42826 unix_path=`$CYGPATH -u "$windows_path"` 42827 new_path="$unix_path" 42828 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42829 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42830 new_path="$unix_path" 42831 fi 42832 42833 42834 # Now try to locate executable using which 42835 new_path=`$WHICH "$new_path" 2> /dev/null` 42836 42837 if test "x$new_path" = x; then 42838 # Oops. Which didn't find the executable. 42839 # The splitting of arguments from the executable at a space might have been incorrect, 42840 # since paths with space are more likely in Windows. Give it another try with the whole 42841 # argument. 42842 path="$complete" 42843 arguments="EOL" 42844 new_path="$path" 42845 42846 windows_path="$new_path" 42847 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42848 unix_path=`$CYGPATH -u "$windows_path"` 42849 new_path="$unix_path" 42850 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42851 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42852 new_path="$unix_path" 42853 fi 42854 42855 42856 new_path=`$WHICH "$new_path" 2> /dev/null` 42857 # bat and cmd files are not always considered executable in MSYS causing which 42858 # to not find them 42859 if test "x$new_path" = x \ 42860 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 42861 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 42862 new_path="$path" 42863 42864 windows_path="$new_path" 42865 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42866 unix_path=`$CYGPATH -u "$windows_path"` 42867 new_path="$unix_path" 42868 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42869 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42870 new_path="$unix_path" 42871 fi 42872 42873 fi 42874 42875 if test "x$new_path" = x; then 42876 # It's still not found. Now this is an unrecoverable error. 42877 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 42878 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 42879 has_space=`$ECHO "$complete" | $GREP " "` 42880 if test "x$has_space" != x; then 42881 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 42882 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 42883 fi 42884 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 42885 fi 42886 fi 42887 42888 # Now new_path has a complete unix path to the binary 42889 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 42890 # Keep paths in /bin as-is, but remove trailing .exe if any 42891 new_path="${new_path/%.exe/}" 42892 # Do not save /bin paths to all_fixpath_prefixes! 42893 else 42894 # Not in mixed or Windows style, start by that. 42895 new_path=`cmd //c echo $new_path` 42896 42897 input_path="$new_path" 42898 # Check if we need to convert this using DOS-style short mode. If the path 42899 # contains just simple characters, use it. Otherwise (spaces, weird characters), 42900 # take no chances and rewrite it. 42901 # Note: m4 eats our [], so we need to use [ and ] instead. 42902 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 42903 if test "x$has_forbidden_chars" != x; then 42904 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 42905 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 42906 fi 42907 42908 # Output is in $new_path 42909 42910 windows_path="$new_path" 42911 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42912 unix_path=`$CYGPATH -u "$windows_path"` 42913 new_path="$unix_path" 42914 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42915 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42916 new_path="$unix_path" 42917 fi 42918 42919 # remove trailing .exe if any 42920 new_path="${new_path/%.exe/}" 42921 42922 # Save the first 10 bytes of this path to the storage, so fixpath can work. 42923 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 42924 fi 42925 42926 else 42927 # We're on a unix platform. Hooray! :) 42928 # First separate the path from the arguments. This will split at the first 42929 # space. 42930 complete="$NM" 42931 path="${complete%% *}" 42932 tmp="$complete EOL" 42933 arguments="${tmp#* }" 42934 42935 # Cannot rely on the command "which" here since it doesn't always work. 42936 is_absolute_path=`$ECHO "$path" | $GREP ^/` 42937 if test -z "$is_absolute_path"; then 42938 # Path to executable is not absolute. Find it. 42939 IFS_save="$IFS" 42940 IFS=: 42941 for p in $PATH; do 42942 if test -f "$p/$path" && test -x "$p/$path"; then 42943 new_path="$p/$path" 42944 break 42945 fi 42946 done 42947 IFS="$IFS_save" 42948 else 42949 # This is an absolute path, we can use it without further modifications. 42950 new_path="$path" 42951 fi 42952 42953 if test "x$new_path" = x; then 42954 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 42955 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 42956 has_space=`$ECHO "$complete" | $GREP " "` 42957 if test "x$has_space" != x; then 42958 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 42959 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 42960 fi 42961 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 42962 fi 42963 fi 42964 42965 # Now join together the path and the arguments once again 42966 if test "x$arguments" != xEOL; then 42967 new_complete="$new_path ${arguments% *}" 42968 else 42969 new_complete="$new_path" 42970 fi 42971 42972 if test "x$complete" != "x$new_complete"; then 42973 NM="$new_complete" 42974 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting NM to \"$new_complete\"" >&5 42975 $as_echo "$as_me: Rewriting NM to \"$new_complete\"" >&6;} 42976 fi 42977 fi 42978 42979 GNM="$NM" 42980 42981 fi 42982 42983 # objcopy is used for moving debug symbols to separate files when 42984 # full debug symbols are enabled. 42985 if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xlinux; then 42986 42987 42988 # Publish this variable in the help. 42989 42990 42991 if [ -z "${OBJCOPY+x}" ]; then 42992 # The variable is not set by user, try to locate tool using the code snippet 42993 if test -n "$ac_tool_prefix"; then 42994 for ac_prog in gobjcopy objcopy 42995 do 42996 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 42997 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 42998 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42999 $as_echo_n "checking for $ac_word... " >&6; } 43000 if ${ac_cv_prog_OBJCOPY+:} false; then : 43001 $as_echo_n "(cached) " >&6 43002 else 43003 if test -n "$OBJCOPY"; then 43004 ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test. 43005 else 43006 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43007 for as_dir in $PATH 43008 do 43009 IFS=$as_save_IFS 43010 test -z "$as_dir" && as_dir=. 43011 for ac_exec_ext in '' $ac_executable_extensions; do 43012 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43013 ac_cv_prog_OBJCOPY="$ac_tool_prefix$ac_prog" 43014 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43015 break 2 43016 fi 43017 done 43018 done 43019 IFS=$as_save_IFS 43020 43021 fi 43022 fi 43023 OBJCOPY=$ac_cv_prog_OBJCOPY 43024 if test -n "$OBJCOPY"; then 43025 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5 43026 $as_echo "$OBJCOPY" >&6; } 43027 else 43028 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43029 $as_echo "no" >&6; } 43030 fi 43031 43032 43033 test -n "$OBJCOPY" && break 43034 done 43035 fi 43036 if test -z "$OBJCOPY"; then 43037 ac_ct_OBJCOPY=$OBJCOPY 43038 for ac_prog in gobjcopy objcopy 43039 do 43040 # Extract the first word of "$ac_prog", so it can be a program name with args. 43041 set dummy $ac_prog; ac_word=$2 43042 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43043 $as_echo_n "checking for $ac_word... " >&6; } 43044 if ${ac_cv_prog_ac_ct_OBJCOPY+:} false; then : 43045 $as_echo_n "(cached) " >&6 43046 else 43047 if test -n "$ac_ct_OBJCOPY"; then 43048 ac_cv_prog_ac_ct_OBJCOPY="$ac_ct_OBJCOPY" # Let the user override the test. 43049 else 43050 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43051 for as_dir in $PATH 43052 do 43053 IFS=$as_save_IFS 43054 test -z "$as_dir" && as_dir=. 43055 for ac_exec_ext in '' $ac_executable_extensions; do 43056 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43057 ac_cv_prog_ac_ct_OBJCOPY="$ac_prog" 43058 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43059 break 2 43060 fi 43061 done 43062 done 43063 IFS=$as_save_IFS 43064 43065 fi 43066 fi 43067 ac_ct_OBJCOPY=$ac_cv_prog_ac_ct_OBJCOPY 43068 if test -n "$ac_ct_OBJCOPY"; then 43069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJCOPY" >&5 43070 $as_echo "$ac_ct_OBJCOPY" >&6; } 43071 else 43072 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43073 $as_echo "no" >&6; } 43074 fi 43075 43076 43077 test -n "$ac_ct_OBJCOPY" && break 43078 done 43079 43080 if test "x$ac_ct_OBJCOPY" = x; then 43081 OBJCOPY="" 43082 else 43083 case $cross_compiling:$ac_tool_warned in 43084 yes:) 43085 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 43086 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 43087 ac_tool_warned=yes ;; 43088 esac 43089 OBJCOPY=$ac_ct_OBJCOPY 43090 fi 43091 fi 43092 43093 else 43094 # The variable is set, but is it from the command line or the environment? 43095 43096 # Try to remove the string !OBJCOPY! from our list. 43097 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!OBJCOPY!/} 43098 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 43099 # If it failed, the variable was not from the command line. Ignore it, 43100 # but warn the user (except for BASH, which is always set by the calling BASH). 43101 if test "xOBJCOPY" != xBASH; then 43102 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of OBJCOPY from the environment. Use command line variables instead." >&5 43103 $as_echo "$as_me: WARNING: Ignoring value of OBJCOPY from the environment. Use command line variables instead." >&2;} 43104 fi 43105 # Try to locate tool using the code snippet 43106 if test -n "$ac_tool_prefix"; then 43107 for ac_prog in gobjcopy objcopy 43108 do 43109 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 43110 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 43111 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43112 $as_echo_n "checking for $ac_word... " >&6; } 43113 if ${ac_cv_prog_OBJCOPY+:} false; then : 43114 $as_echo_n "(cached) " >&6 43115 else 43116 if test -n "$OBJCOPY"; then 43117 ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test. 43118 else 43119 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43120 for as_dir in $PATH 43121 do 43122 IFS=$as_save_IFS 43123 test -z "$as_dir" && as_dir=. 43124 for ac_exec_ext in '' $ac_executable_extensions; do 43125 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43126 ac_cv_prog_OBJCOPY="$ac_tool_prefix$ac_prog" 43127 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43128 break 2 43129 fi 43130 done 43131 done 43132 IFS=$as_save_IFS 43133 43134 fi 43135 fi 43136 OBJCOPY=$ac_cv_prog_OBJCOPY 43137 if test -n "$OBJCOPY"; then 43138 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5 43139 $as_echo "$OBJCOPY" >&6; } 43140 else 43141 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43142 $as_echo "no" >&6; } 43143 fi 43144 43145 43146 test -n "$OBJCOPY" && break 43147 done 43148 fi 43149 if test -z "$OBJCOPY"; then 43150 ac_ct_OBJCOPY=$OBJCOPY 43151 for ac_prog in gobjcopy objcopy 43152 do 43153 # Extract the first word of "$ac_prog", so it can be a program name with args. 43154 set dummy $ac_prog; ac_word=$2 43155 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43156 $as_echo_n "checking for $ac_word... " >&6; } 43157 if ${ac_cv_prog_ac_ct_OBJCOPY+:} false; then : 43158 $as_echo_n "(cached) " >&6 43159 else 43160 if test -n "$ac_ct_OBJCOPY"; then 43161 ac_cv_prog_ac_ct_OBJCOPY="$ac_ct_OBJCOPY" # Let the user override the test. 43162 else 43163 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43164 for as_dir in $PATH 43165 do 43166 IFS=$as_save_IFS 43167 test -z "$as_dir" && as_dir=. 43168 for ac_exec_ext in '' $ac_executable_extensions; do 43169 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43170 ac_cv_prog_ac_ct_OBJCOPY="$ac_prog" 43171 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43172 break 2 43173 fi 43174 done 43175 done 43176 IFS=$as_save_IFS 43177 43178 fi 43179 fi 43180 ac_ct_OBJCOPY=$ac_cv_prog_ac_ct_OBJCOPY 43181 if test -n "$ac_ct_OBJCOPY"; then 43182 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJCOPY" >&5 43183 $as_echo "$ac_ct_OBJCOPY" >&6; } 43184 else 43185 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43186 $as_echo "no" >&6; } 43187 fi 43188 43189 43190 test -n "$ac_ct_OBJCOPY" && break 43191 done 43192 43193 if test "x$ac_ct_OBJCOPY" = x; then 43194 OBJCOPY="" 43195 else 43196 case $cross_compiling:$ac_tool_warned in 43197 yes:) 43198 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 43199 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 43200 ac_tool_warned=yes ;; 43201 esac 43202 OBJCOPY=$ac_ct_OBJCOPY 43203 fi 43204 fi 43205 43206 else 43207 # If it succeeded, then it was overridden by the user. We will use it 43208 # for the tool. 43209 43210 # First remove it from the list of overridden variables, so we can test 43211 # for unknown variables in the end. 43212 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 43213 43214 # Check if we try to supply an empty value 43215 if test "x$OBJCOPY" = x; then 43216 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool OBJCOPY= (no value)" >&5 43217 $as_echo "$as_me: Setting user supplied tool OBJCOPY= (no value)" >&6;} 43218 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJCOPY" >&5 43219 $as_echo_n "checking for OBJCOPY... " >&6; } 43220 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 43221 $as_echo "disabled" >&6; } 43222 else 43223 # Check if the provided tool contains a complete path. 43224 tool_specified="$OBJCOPY" 43225 tool_basename="${tool_specified##*/}" 43226 if test "x$tool_basename" = "x$tool_specified"; then 43227 # A command without a complete path is provided, search $PATH. 43228 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool OBJCOPY=$tool_basename" >&5 43229 $as_echo "$as_me: Will search for user supplied tool OBJCOPY=$tool_basename" >&6;} 43230 # Extract the first word of "$tool_basename", so it can be a program name with args. 43231 set dummy $tool_basename; ac_word=$2 43232 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43233 $as_echo_n "checking for $ac_word... " >&6; } 43234 if ${ac_cv_path_OBJCOPY+:} false; then : 43235 $as_echo_n "(cached) " >&6 43236 else 43237 case $OBJCOPY in 43238 [\\/]* | ?:[\\/]*) 43239 ac_cv_path_OBJCOPY="$OBJCOPY" # Let the user override the test with a path. 43240 ;; 43241 *) 43242 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43243 for as_dir in $PATH 43244 do 43245 IFS=$as_save_IFS 43246 test -z "$as_dir" && as_dir=. 43247 for ac_exec_ext in '' $ac_executable_extensions; do 43248 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43249 ac_cv_path_OBJCOPY="$as_dir/$ac_word$ac_exec_ext" 43250 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43251 break 2 43252 fi 43253 done 43254 done 43255 IFS=$as_save_IFS 43256 43257 ;; 43258 esac 43259 fi 43260 OBJCOPY=$ac_cv_path_OBJCOPY 43261 if test -n "$OBJCOPY"; then 43262 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5 43263 $as_echo "$OBJCOPY" >&6; } 43264 else 43265 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43266 $as_echo "no" >&6; } 43267 fi 43268 43269 43270 if test "x$OBJCOPY" = x; then 43271 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 43272 fi 43273 else 43274 # Otherwise we believe it is a complete path. Use it as it is. 43275 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool OBJCOPY=$tool_specified" >&5 43276 $as_echo "$as_me: Will use user supplied tool OBJCOPY=$tool_specified" >&6;} 43277 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJCOPY" >&5 43278 $as_echo_n "checking for OBJCOPY... " >&6; } 43279 if test ! -x "$tool_specified"; then 43280 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 43281 $as_echo "not found" >&6; } 43282 as_fn_error $? "User supplied tool OBJCOPY=$tool_specified does not exist or is not executable" "$LINENO" 5 43283 fi 43284 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 43285 $as_echo "$tool_specified" >&6; } 43286 fi 43287 fi 43288 fi 43289 43290 fi 43291 43292 43293 # Only call fixup if objcopy was found. 43294 if test -n "$OBJCOPY"; then 43295 43296 # Only process if variable expands to non-empty 43297 43298 if test "x$OBJCOPY" != x; then 43299 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43300 43301 # First separate the path from the arguments. This will split at the first 43302 # space. 43303 complete="$OBJCOPY" 43304 path="${complete%% *}" 43305 tmp="$complete EOL" 43306 arguments="${tmp#* }" 43307 43308 # Input might be given as Windows format, start by converting to 43309 # unix format. 43310 new_path=`$CYGPATH -u "$path"` 43311 43312 # Now try to locate executable using which 43313 new_path=`$WHICH "$new_path" 2> /dev/null` 43314 # bat and cmd files are not always considered executable in cygwin causing which 43315 # to not find them 43316 if test "x$new_path" = x \ 43317 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 43318 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 43319 new_path=`$CYGPATH -u "$path"` 43320 fi 43321 if test "x$new_path" = x; then 43322 # Oops. Which didn't find the executable. 43323 # The splitting of arguments from the executable at a space might have been incorrect, 43324 # since paths with space are more likely in Windows. Give it another try with the whole 43325 # argument. 43326 path="$complete" 43327 arguments="EOL" 43328 new_path=`$CYGPATH -u "$path"` 43329 new_path=`$WHICH "$new_path" 2> /dev/null` 43330 # bat and cmd files are not always considered executable in cygwin causing which 43331 # to not find them 43332 if test "x$new_path" = x \ 43333 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 43334 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 43335 new_path=`$CYGPATH -u "$path"` 43336 fi 43337 if test "x$new_path" = x; then 43338 # It's still not found. Now this is an unrecoverable error. 43339 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5 43340 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 43341 has_space=`$ECHO "$complete" | $GREP " "` 43342 if test "x$has_space" != x; then 43343 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 43344 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 43345 fi 43346 as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5 43347 fi 43348 fi 43349 43350 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 43351 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 43352 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 43353 # "foo.exe" is OK but "foo" is an error. 43354 # 43355 # This test is therefore slightly more accurate than "test -f" to check for file presence. 43356 # It is also a way to make sure we got the proper file name for the real test later on. 43357 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 43358 if test "x$test_shortpath" = x; then 43359 # Short path failed, file does not exist as specified. 43360 # Try adding .exe or .cmd 43361 if test -f "${new_path}.exe"; then 43362 input_to_shortpath="${new_path}.exe" 43363 elif test -f "${new_path}.cmd"; then 43364 input_to_shortpath="${new_path}.cmd" 43365 else 43366 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$new_path\", is invalid." >&5 43367 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$new_path\", is invalid." >&6;} 43368 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 43369 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 43370 as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5 43371 fi 43372 else 43373 input_to_shortpath="$new_path" 43374 fi 43375 43376 # Call helper function which possibly converts this using DOS-style short mode. 43377 # If so, the updated path is stored in $new_path. 43378 new_path="$input_to_shortpath" 43379 43380 input_path="$input_to_shortpath" 43381 # Check if we need to convert this using DOS-style short mode. If the path 43382 # contains just simple characters, use it. Otherwise (spaces, weird characters), 43383 # take no chances and rewrite it. 43384 # Note: m4 eats our [], so we need to use [ and ] instead. 43385 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 43386 if test "x$has_forbidden_chars" != x; then 43387 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 43388 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 43389 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 43390 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 43391 # Going to short mode and back again did indeed matter. Since short mode is 43392 # case insensitive, let's make it lowercase to improve readability. 43393 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 43394 # Now convert it back to Unix-style (cygpath) 43395 input_path=`$CYGPATH -u "$shortmode_path"` 43396 new_path="$input_path" 43397 fi 43398 fi 43399 43400 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 43401 if test "x$test_cygdrive_prefix" = x; then 43402 # As a simple fix, exclude /usr/bin since it's not a real path. 43403 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 43404 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 43405 # a path prefixed by /cygdrive for fixpath to work. 43406 new_path="$CYGWIN_ROOT_PATH$input_path" 43407 fi 43408 fi 43409 43410 # remove trailing .exe if any 43411 new_path="${new_path/%.exe/}" 43412 43413 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43414 43415 # First separate the path from the arguments. This will split at the first 43416 # space. 43417 complete="$OBJCOPY" 43418 path="${complete%% *}" 43419 tmp="$complete EOL" 43420 arguments="${tmp#* }" 43421 43422 # Input might be given as Windows format, start by converting to 43423 # unix format. 43424 new_path="$path" 43425 43426 windows_path="$new_path" 43427 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43428 unix_path=`$CYGPATH -u "$windows_path"` 43429 new_path="$unix_path" 43430 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43431 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43432 new_path="$unix_path" 43433 fi 43434 43435 43436 # Now try to locate executable using which 43437 new_path=`$WHICH "$new_path" 2> /dev/null` 43438 43439 if test "x$new_path" = x; then 43440 # Oops. Which didn't find the executable. 43441 # The splitting of arguments from the executable at a space might have been incorrect, 43442 # since paths with space are more likely in Windows. Give it another try with the whole 43443 # argument. 43444 path="$complete" 43445 arguments="EOL" 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 43458 new_path=`$WHICH "$new_path" 2> /dev/null` 43459 # bat and cmd files are not always considered executable in MSYS causing which 43460 # to not find them 43461 if test "x$new_path" = x \ 43462 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 43463 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 43464 new_path="$path" 43465 43466 windows_path="$new_path" 43467 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43468 unix_path=`$CYGPATH -u "$windows_path"` 43469 new_path="$unix_path" 43470 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43471 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43472 new_path="$unix_path" 43473 fi 43474 43475 fi 43476 43477 if test "x$new_path" = x; then 43478 # It's still not found. Now this is an unrecoverable error. 43479 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5 43480 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 43481 has_space=`$ECHO "$complete" | $GREP " "` 43482 if test "x$has_space" != x; then 43483 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 43484 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 43485 fi 43486 as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5 43487 fi 43488 fi 43489 43490 # Now new_path has a complete unix path to the binary 43491 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 43492 # Keep paths in /bin as-is, but remove trailing .exe if any 43493 new_path="${new_path/%.exe/}" 43494 # Do not save /bin paths to all_fixpath_prefixes! 43495 else 43496 # Not in mixed or Windows style, start by that. 43497 new_path=`cmd //c echo $new_path` 43498 43499 input_path="$new_path" 43500 # Check if we need to convert this using DOS-style short mode. If the path 43501 # contains just simple characters, use it. Otherwise (spaces, weird characters), 43502 # take no chances and rewrite it. 43503 # Note: m4 eats our [], so we need to use [ and ] instead. 43504 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 43505 if test "x$has_forbidden_chars" != x; then 43506 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 43507 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 43508 fi 43509 43510 # Output is in $new_path 43511 43512 windows_path="$new_path" 43513 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43514 unix_path=`$CYGPATH -u "$windows_path"` 43515 new_path="$unix_path" 43516 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43517 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43518 new_path="$unix_path" 43519 fi 43520 43521 # remove trailing .exe if any 43522 new_path="${new_path/%.exe/}" 43523 43524 # Save the first 10 bytes of this path to the storage, so fixpath can work. 43525 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 43526 fi 43527 43528 else 43529 # We're on a unix platform. Hooray! :) 43530 # First separate the path from the arguments. This will split at the first 43531 # space. 43532 complete="$OBJCOPY" 43533 path="${complete%% *}" 43534 tmp="$complete EOL" 43535 arguments="${tmp#* }" 43536 43537 # Cannot rely on the command "which" here since it doesn't always work. 43538 is_absolute_path=`$ECHO "$path" | $GREP ^/` 43539 if test -z "$is_absolute_path"; then 43540 # Path to executable is not absolute. Find it. 43541 IFS_save="$IFS" 43542 IFS=: 43543 for p in $PATH; do 43544 if test -f "$p/$path" && test -x "$p/$path"; then 43545 new_path="$p/$path" 43546 break 43547 fi 43548 done 43549 IFS="$IFS_save" 43550 else 43551 # This is an absolute path, we can use it without further modifications. 43552 new_path="$path" 43553 fi 43554 43555 if test "x$new_path" = x; then 43556 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5 43557 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 43558 has_space=`$ECHO "$complete" | $GREP " "` 43559 if test "x$has_space" != x; then 43560 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 43561 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 43562 fi 43563 as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5 43564 fi 43565 fi 43566 43567 # Now join together the path and the arguments once again 43568 if test "x$arguments" != xEOL; then 43569 new_complete="$new_path ${arguments% *}" 43570 else 43571 new_complete="$new_path" 43572 fi 43573 43574 if test "x$complete" != "x$new_complete"; then 43575 OBJCOPY="$new_complete" 43576 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OBJCOPY to \"$new_complete\"" >&5 43577 $as_echo "$as_me: Rewriting OBJCOPY to \"$new_complete\"" >&6;} 43578 fi 43579 fi 43580 43581 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 43582 # objcopy prior to 2.21.1 on solaris is broken and is not usable. 43583 # Rewrite objcopy version output to VALID_VERSION or BAD_VERSION. 43584 # - version number is last blank separate word on first line 43585 # - version number formats that have been seen: 43586 # - <major>.<minor> 43587 # - <major>.<minor>.<micro> 43588 OBJCOPY_VERSION=`$OBJCOPY --version | $HEAD -n 1` 43589 # The outer [ ] is to prevent m4 from eating the [] in the sed expression. 43590 OBJCOPY_VERSION_CHECK=`$ECHO $OBJCOPY_VERSION | $SED -n \ 43591 -e 's/.* //' \ 43592 -e '/^[01]\./b bad' \ 43593 -e '/^2\./{' \ 43594 -e ' s/^2\.//' \ 43595 -e ' /^[0-9]$/b bad' \ 43596 -e ' /^[0-9]\./b bad' \ 43597 -e ' /^1[0-9]$/b bad' \ 43598 -e ' /^1[0-9]\./b bad' \ 43599 -e ' /^20\./b bad' \ 43600 -e ' /^21\.0$/b bad' \ 43601 -e ' /^21\.0\./b bad' \ 43602 -e '}' \ 43603 -e ':good' \ 43604 -e 's/.*/VALID_VERSION/p' \ 43605 -e 'q' \ 43606 -e ':bad' \ 43607 -e 's/.*/BAD_VERSION/p' \ 43608 -e 'q'` 43609 if test "x$OBJCOPY_VERSION_CHECK" = xBAD_VERSION; then 43610 OBJCOPY= 43611 { $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 43612 $as_echo "$as_me: WARNING: Ignoring found objcopy since it is broken (prior to 2.21.1). No debug symbols will be generated." >&2;} 43613 { $as_echo "$as_me:${as_lineno-$LINENO}: objcopy reports version $OBJCOPY_VERSION" >&5 43614 $as_echo "$as_me: objcopy reports version $OBJCOPY_VERSION" >&6;} 43615 { $as_echo "$as_me:${as_lineno-$LINENO}: Note: patch 149063-01 or newer contains the correct Solaris 10 SPARC version" >&5 43616 $as_echo "$as_me: Note: patch 149063-01 or newer contains the correct Solaris 10 SPARC version" >&6;} 43617 { $as_echo "$as_me:${as_lineno-$LINENO}: Note: patch 149064-01 or newer contains the correct Solaris 10 X86 version" >&5 43618 $as_echo "$as_me: Note: patch 149064-01 or newer contains the correct Solaris 10 X86 version" >&6;} 43619 { $as_echo "$as_me:${as_lineno-$LINENO}: Note: Solaris 11 Update 1 contains the correct version" >&5 43620 $as_echo "$as_me: Note: Solaris 11 Update 1 contains the correct version" >&6;} 43621 fi 43622 fi 43623 fi 43624 fi 43625 43626 43627 43628 # Publish this variable in the help. 43629 43630 43631 if [ -z "${OBJDUMP+x}" ]; then 43632 # The variable is not set by user, try to locate tool using the code snippet 43633 if test -n "$ac_tool_prefix"; then 43634 for ac_prog in gobjdump objdump 43635 do 43636 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 43637 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 43638 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43639 $as_echo_n "checking for $ac_word... " >&6; } 43640 if ${ac_cv_prog_OBJDUMP+:} false; then : 43641 $as_echo_n "(cached) " >&6 43642 else 43643 if test -n "$OBJDUMP"; then 43644 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. 43645 else 43646 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43647 for as_dir in $PATH 43648 do 43649 IFS=$as_save_IFS 43650 test -z "$as_dir" && as_dir=. 43651 for ac_exec_ext in '' $ac_executable_extensions; do 43652 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43653 ac_cv_prog_OBJDUMP="$ac_tool_prefix$ac_prog" 43654 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43655 break 2 43656 fi 43657 done 43658 done 43659 IFS=$as_save_IFS 43660 43661 fi 43662 fi 43663 OBJDUMP=$ac_cv_prog_OBJDUMP 43664 if test -n "$OBJDUMP"; then 43665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 43666 $as_echo "$OBJDUMP" >&6; } 43667 else 43668 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43669 $as_echo "no" >&6; } 43670 fi 43671 43672 43673 test -n "$OBJDUMP" && break 43674 done 43675 fi 43676 if test -z "$OBJDUMP"; then 43677 ac_ct_OBJDUMP=$OBJDUMP 43678 for ac_prog in gobjdump objdump 43679 do 43680 # Extract the first word of "$ac_prog", so it can be a program name with args. 43681 set dummy $ac_prog; ac_word=$2 43682 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43683 $as_echo_n "checking for $ac_word... " >&6; } 43684 if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then : 43685 $as_echo_n "(cached) " >&6 43686 else 43687 if test -n "$ac_ct_OBJDUMP"; then 43688 ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. 43689 else 43690 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43691 for as_dir in $PATH 43692 do 43693 IFS=$as_save_IFS 43694 test -z "$as_dir" && as_dir=. 43695 for ac_exec_ext in '' $ac_executable_extensions; do 43696 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43697 ac_cv_prog_ac_ct_OBJDUMP="$ac_prog" 43698 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43699 break 2 43700 fi 43701 done 43702 done 43703 IFS=$as_save_IFS 43704 43705 fi 43706 fi 43707 ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP 43708 if test -n "$ac_ct_OBJDUMP"; then 43709 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 43710 $as_echo "$ac_ct_OBJDUMP" >&6; } 43711 else 43712 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43713 $as_echo "no" >&6; } 43714 fi 43715 43716 43717 test -n "$ac_ct_OBJDUMP" && break 43718 done 43719 43720 if test "x$ac_ct_OBJDUMP" = x; then 43721 OBJDUMP="" 43722 else 43723 case $cross_compiling:$ac_tool_warned in 43724 yes:) 43725 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 43726 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 43727 ac_tool_warned=yes ;; 43728 esac 43729 OBJDUMP=$ac_ct_OBJDUMP 43730 fi 43731 fi 43732 43733 else 43734 # The variable is set, but is it from the command line or the environment? 43735 43736 # Try to remove the string !OBJDUMP! from our list. 43737 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!OBJDUMP!/} 43738 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 43739 # If it failed, the variable was not from the command line. Ignore it, 43740 # but warn the user (except for BASH, which is always set by the calling BASH). 43741 if test "xOBJDUMP" != xBASH; then 43742 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of OBJDUMP from the environment. Use command line variables instead." >&5 43743 $as_echo "$as_me: WARNING: Ignoring value of OBJDUMP from the environment. Use command line variables instead." >&2;} 43744 fi 43745 # Try to locate tool using the code snippet 43746 if test -n "$ac_tool_prefix"; then 43747 for ac_prog in gobjdump objdump 43748 do 43749 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 43750 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 43751 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43752 $as_echo_n "checking for $ac_word... " >&6; } 43753 if ${ac_cv_prog_OBJDUMP+:} false; then : 43754 $as_echo_n "(cached) " >&6 43755 else 43756 if test -n "$OBJDUMP"; then 43757 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. 43758 else 43759 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43760 for as_dir in $PATH 43761 do 43762 IFS=$as_save_IFS 43763 test -z "$as_dir" && as_dir=. 43764 for ac_exec_ext in '' $ac_executable_extensions; do 43765 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43766 ac_cv_prog_OBJDUMP="$ac_tool_prefix$ac_prog" 43767 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43768 break 2 43769 fi 43770 done 43771 done 43772 IFS=$as_save_IFS 43773 43774 fi 43775 fi 43776 OBJDUMP=$ac_cv_prog_OBJDUMP 43777 if test -n "$OBJDUMP"; then 43778 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 43779 $as_echo "$OBJDUMP" >&6; } 43780 else 43781 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43782 $as_echo "no" >&6; } 43783 fi 43784 43785 43786 test -n "$OBJDUMP" && break 43787 done 43788 fi 43789 if test -z "$OBJDUMP"; then 43790 ac_ct_OBJDUMP=$OBJDUMP 43791 for ac_prog in gobjdump objdump 43792 do 43793 # Extract the first word of "$ac_prog", so it can be a program name with args. 43794 set dummy $ac_prog; ac_word=$2 43795 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43796 $as_echo_n "checking for $ac_word... " >&6; } 43797 if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then : 43798 $as_echo_n "(cached) " >&6 43799 else 43800 if test -n "$ac_ct_OBJDUMP"; then 43801 ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. 43802 else 43803 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43804 for as_dir in $PATH 43805 do 43806 IFS=$as_save_IFS 43807 test -z "$as_dir" && as_dir=. 43808 for ac_exec_ext in '' $ac_executable_extensions; do 43809 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43810 ac_cv_prog_ac_ct_OBJDUMP="$ac_prog" 43811 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43812 break 2 43813 fi 43814 done 43815 done 43816 IFS=$as_save_IFS 43817 43818 fi 43819 fi 43820 ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP 43821 if test -n "$ac_ct_OBJDUMP"; then 43822 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 43823 $as_echo "$ac_ct_OBJDUMP" >&6; } 43824 else 43825 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43826 $as_echo "no" >&6; } 43827 fi 43828 43829 43830 test -n "$ac_ct_OBJDUMP" && break 43831 done 43832 43833 if test "x$ac_ct_OBJDUMP" = x; then 43834 OBJDUMP="" 43835 else 43836 case $cross_compiling:$ac_tool_warned in 43837 yes:) 43838 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 43839 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 43840 ac_tool_warned=yes ;; 43841 esac 43842 OBJDUMP=$ac_ct_OBJDUMP 43843 fi 43844 fi 43845 43846 else 43847 # If it succeeded, then it was overridden by the user. We will use it 43848 # for the tool. 43849 43850 # First remove it from the list of overridden variables, so we can test 43851 # for unknown variables in the end. 43852 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 43853 43854 # Check if we try to supply an empty value 43855 if test "x$OBJDUMP" = x; then 43856 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool OBJDUMP= (no value)" >&5 43857 $as_echo "$as_me: Setting user supplied tool OBJDUMP= (no value)" >&6;} 43858 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJDUMP" >&5 43859 $as_echo_n "checking for OBJDUMP... " >&6; } 43860 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 43861 $as_echo "disabled" >&6; } 43862 else 43863 # Check if the provided tool contains a complete path. 43864 tool_specified="$OBJDUMP" 43865 tool_basename="${tool_specified##*/}" 43866 if test "x$tool_basename" = "x$tool_specified"; then 43867 # A command without a complete path is provided, search $PATH. 43868 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool OBJDUMP=$tool_basename" >&5 43869 $as_echo "$as_me: Will search for user supplied tool OBJDUMP=$tool_basename" >&6;} 43870 # Extract the first word of "$tool_basename", so it can be a program name with args. 43871 set dummy $tool_basename; ac_word=$2 43872 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43873 $as_echo_n "checking for $ac_word... " >&6; } 43874 if ${ac_cv_path_OBJDUMP+:} false; then : 43875 $as_echo_n "(cached) " >&6 43876 else 43877 case $OBJDUMP in 43878 [\\/]* | ?:[\\/]*) 43879 ac_cv_path_OBJDUMP="$OBJDUMP" # Let the user override the test with a path. 43880 ;; 43881 *) 43882 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43883 for as_dir in $PATH 43884 do 43885 IFS=$as_save_IFS 43886 test -z "$as_dir" && as_dir=. 43887 for ac_exec_ext in '' $ac_executable_extensions; do 43888 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43889 ac_cv_path_OBJDUMP="$as_dir/$ac_word$ac_exec_ext" 43890 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43891 break 2 43892 fi 43893 done 43894 done 43895 IFS=$as_save_IFS 43896 43897 ;; 43898 esac 43899 fi 43900 OBJDUMP=$ac_cv_path_OBJDUMP 43901 if test -n "$OBJDUMP"; then 43902 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 43903 $as_echo "$OBJDUMP" >&6; } 43904 else 43905 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43906 $as_echo "no" >&6; } 43907 fi 43908 43909 43910 if test "x$OBJDUMP" = x; then 43911 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 43912 fi 43913 else 43914 # Otherwise we believe it is a complete path. Use it as it is. 43915 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool OBJDUMP=$tool_specified" >&5 43916 $as_echo "$as_me: Will use user supplied tool OBJDUMP=$tool_specified" >&6;} 43917 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJDUMP" >&5 43918 $as_echo_n "checking for OBJDUMP... " >&6; } 43919 if test ! -x "$tool_specified"; then 43920 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 43921 $as_echo "not found" >&6; } 43922 as_fn_error $? "User supplied tool OBJDUMP=$tool_specified does not exist or is not executable" "$LINENO" 5 43923 fi 43924 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 43925 $as_echo "$tool_specified" >&6; } 43926 fi 43927 fi 43928 fi 43929 43930 fi 43931 43932 43933 if test "x$OBJDUMP" != x; then 43934 # Only used for compare.sh; we can live without it. BASIC_FIXUP_EXECUTABLE 43935 # bails if argument is missing. 43936 43937 # Only process if variable expands to non-empty 43938 43939 if test "x$OBJDUMP" != x; then 43940 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43941 43942 # First separate the path from the arguments. This will split at the first 43943 # space. 43944 complete="$OBJDUMP" 43945 path="${complete%% *}" 43946 tmp="$complete EOL" 43947 arguments="${tmp#* }" 43948 43949 # Input might be given as Windows format, start by converting to 43950 # unix format. 43951 new_path=`$CYGPATH -u "$path"` 43952 43953 # Now try to locate executable using which 43954 new_path=`$WHICH "$new_path" 2> /dev/null` 43955 # bat and cmd files are not always considered executable in cygwin causing which 43956 # to not find them 43957 if test "x$new_path" = x \ 43958 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 43959 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 43960 new_path=`$CYGPATH -u "$path"` 43961 fi 43962 if test "x$new_path" = x; then 43963 # Oops. Which didn't find the executable. 43964 # The splitting of arguments from the executable at a space might have been incorrect, 43965 # since paths with space are more likely in Windows. Give it another try with the whole 43966 # argument. 43967 path="$complete" 43968 arguments="EOL" 43969 new_path=`$CYGPATH -u "$path"` 43970 new_path=`$WHICH "$new_path" 2> /dev/null` 43971 # bat and cmd files are not always considered executable in cygwin causing which 43972 # to not find them 43973 if test "x$new_path" = x \ 43974 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 43975 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 43976 new_path=`$CYGPATH -u "$path"` 43977 fi 43978 if test "x$new_path" = x; then 43979 # It's still not found. Now this is an unrecoverable error. 43980 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5 43981 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;} 43982 has_space=`$ECHO "$complete" | $GREP " "` 43983 if test "x$has_space" != x; then 43984 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 43985 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 43986 fi 43987 as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5 43988 fi 43989 fi 43990 43991 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 43992 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 43993 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 43994 # "foo.exe" is OK but "foo" is an error. 43995 # 43996 # This test is therefore slightly more accurate than "test -f" to check for file presence. 43997 # It is also a way to make sure we got the proper file name for the real test later on. 43998 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 43999 if test "x$test_shortpath" = x; then 44000 # Short path failed, file does not exist as specified. 44001 # Try adding .exe or .cmd 44002 if test -f "${new_path}.exe"; then 44003 input_to_shortpath="${new_path}.exe" 44004 elif test -f "${new_path}.cmd"; then 44005 input_to_shortpath="${new_path}.cmd" 44006 else 44007 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$new_path\", is invalid." >&5 44008 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$new_path\", is invalid." >&6;} 44009 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 44010 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 44011 as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5 44012 fi 44013 else 44014 input_to_shortpath="$new_path" 44015 fi 44016 44017 # Call helper function which possibly converts this using DOS-style short mode. 44018 # If so, the updated path is stored in $new_path. 44019 new_path="$input_to_shortpath" 44020 44021 input_path="$input_to_shortpath" 44022 # Check if we need to convert this using DOS-style short mode. If the path 44023 # contains just simple characters, use it. Otherwise (spaces, weird characters), 44024 # take no chances and rewrite it. 44025 # Note: m4 eats our [], so we need to use [ and ] instead. 44026 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 44027 if test "x$has_forbidden_chars" != x; then 44028 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 44029 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 44030 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 44031 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 44032 # Going to short mode and back again did indeed matter. Since short mode is 44033 # case insensitive, let's make it lowercase to improve readability. 44034 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 44035 # Now convert it back to Unix-style (cygpath) 44036 input_path=`$CYGPATH -u "$shortmode_path"` 44037 new_path="$input_path" 44038 fi 44039 fi 44040 44041 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 44042 if test "x$test_cygdrive_prefix" = x; then 44043 # As a simple fix, exclude /usr/bin since it's not a real path. 44044 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 44045 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 44046 # a path prefixed by /cygdrive for fixpath to work. 44047 new_path="$CYGWIN_ROOT_PATH$input_path" 44048 fi 44049 fi 44050 44051 # remove trailing .exe if any 44052 new_path="${new_path/%.exe/}" 44053 44054 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44055 44056 # First separate the path from the arguments. This will split at the first 44057 # space. 44058 complete="$OBJDUMP" 44059 path="${complete%% *}" 44060 tmp="$complete EOL" 44061 arguments="${tmp#* }" 44062 44063 # Input might be given as Windows format, start by converting to 44064 # unix format. 44065 new_path="$path" 44066 44067 windows_path="$new_path" 44068 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44069 unix_path=`$CYGPATH -u "$windows_path"` 44070 new_path="$unix_path" 44071 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44072 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44073 new_path="$unix_path" 44074 fi 44075 44076 44077 # Now try to locate executable using which 44078 new_path=`$WHICH "$new_path" 2> /dev/null` 44079 44080 if test "x$new_path" = x; then 44081 # Oops. Which didn't find the executable. 44082 # The splitting of arguments from the executable at a space might have been incorrect, 44083 # since paths with space are more likely in Windows. Give it another try with the whole 44084 # argument. 44085 path="$complete" 44086 arguments="EOL" 44087 new_path="$path" 44088 44089 windows_path="$new_path" 44090 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44091 unix_path=`$CYGPATH -u "$windows_path"` 44092 new_path="$unix_path" 44093 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44094 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44095 new_path="$unix_path" 44096 fi 44097 44098 44099 new_path=`$WHICH "$new_path" 2> /dev/null` 44100 # bat and cmd files are not always considered executable in MSYS causing which 44101 # to not find them 44102 if test "x$new_path" = x \ 44103 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44104 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44105 new_path="$path" 44106 44107 windows_path="$new_path" 44108 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44109 unix_path=`$CYGPATH -u "$windows_path"` 44110 new_path="$unix_path" 44111 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44112 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44113 new_path="$unix_path" 44114 fi 44115 44116 fi 44117 44118 if test "x$new_path" = x; then 44119 # It's still not found. Now this is an unrecoverable error. 44120 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5 44121 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;} 44122 has_space=`$ECHO "$complete" | $GREP " "` 44123 if test "x$has_space" != x; then 44124 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 44125 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 44126 fi 44127 as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5 44128 fi 44129 fi 44130 44131 # Now new_path has a complete unix path to the binary 44132 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 44133 # Keep paths in /bin as-is, but remove trailing .exe if any 44134 new_path="${new_path/%.exe/}" 44135 # Do not save /bin paths to all_fixpath_prefixes! 44136 else 44137 # Not in mixed or Windows style, start by that. 44138 new_path=`cmd //c echo $new_path` 44139 44140 input_path="$new_path" 44141 # Check if we need to convert this using DOS-style short mode. If the path 44142 # contains just simple characters, use it. Otherwise (spaces, weird characters), 44143 # take no chances and rewrite it. 44144 # Note: m4 eats our [], so we need to use [ and ] instead. 44145 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 44146 if test "x$has_forbidden_chars" != x; then 44147 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 44148 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 44149 fi 44150 44151 # Output is in $new_path 44152 44153 windows_path="$new_path" 44154 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44155 unix_path=`$CYGPATH -u "$windows_path"` 44156 new_path="$unix_path" 44157 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44158 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44159 new_path="$unix_path" 44160 fi 44161 44162 # remove trailing .exe if any 44163 new_path="${new_path/%.exe/}" 44164 44165 # Save the first 10 bytes of this path to the storage, so fixpath can work. 44166 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 44167 fi 44168 44169 else 44170 # We're on a unix platform. Hooray! :) 44171 # First separate the path from the arguments. This will split at the first 44172 # space. 44173 complete="$OBJDUMP" 44174 path="${complete%% *}" 44175 tmp="$complete EOL" 44176 arguments="${tmp#* }" 44177 44178 # Cannot rely on the command "which" here since it doesn't always work. 44179 is_absolute_path=`$ECHO "$path" | $GREP ^/` 44180 if test -z "$is_absolute_path"; then 44181 # Path to executable is not absolute. Find it. 44182 IFS_save="$IFS" 44183 IFS=: 44184 for p in $PATH; do 44185 if test -f "$p/$path" && test -x "$p/$path"; then 44186 new_path="$p/$path" 44187 break 44188 fi 44189 done 44190 IFS="$IFS_save" 44191 else 44192 # This is an absolute path, we can use it without further modifications. 44193 new_path="$path" 44194 fi 44195 44196 if test "x$new_path" = x; then 44197 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5 44198 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;} 44199 has_space=`$ECHO "$complete" | $GREP " "` 44200 if test "x$has_space" != x; then 44201 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 44202 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 44203 fi 44204 as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5 44205 fi 44206 fi 44207 44208 # Now join together the path and the arguments once again 44209 if test "x$arguments" != xEOL; then 44210 new_complete="$new_path ${arguments% *}" 44211 else 44212 new_complete="$new_path" 44213 fi 44214 44215 if test "x$complete" != "x$new_complete"; then 44216 OBJDUMP="$new_complete" 44217 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OBJDUMP to \"$new_complete\"" >&5 44218 $as_echo "$as_me: Rewriting OBJDUMP to \"$new_complete\"" >&6;} 44219 fi 44220 fi 44221 44222 fi 44223 44224 44225 # Restore old path, except for the microsoft toolchain, which requires VS_PATH 44226 # to remain in place. Otherwise the compiler will not work in some siutations 44227 # in later configure checks. 44228 if test "x$TOOLCHAIN_TYPE" != "xmicrosoft"; then 44229 PATH="$OLD_PATH" 44230 fi 44231 44232 # Restore the flags to the user specified values. 44233 # This is necessary since AC_PROG_CC defaults CFLAGS to "-g -O2" 44234 CFLAGS="$ORG_CFLAGS" 44235 CXXFLAGS="$ORG_CXXFLAGS" 44236 44237 44238 # Finally do some processing after the detection phase 44239 44240 if test "x$COMPILE_TYPE" = "xcross"; then 44241 # Now we need to find a C/C++ compiler that can build executables for the 44242 # build platform. We can't use the AC_PROG_CC macro, since it can only be 44243 # used once. Also, we need to do this without adding a tools dir to the 44244 # path, otherwise we might pick up cross-compilers which don't use standard 44245 # naming. 44246 44247 OLDPATH="$PATH" 44248 44249 44250 # Check whether --with-build-devkit was given. 44251 if test "${with_build_devkit+set}" = set; then : 44252 withval=$with_build_devkit; 44253 fi 44254 44255 if test "x$with_build_devkit" = "xyes"; then 44256 as_fn_error $? "--with-build-devkit must have a value" "$LINENO" 5 44257 elif test -n "$with_build_devkit"; then 44258 if test ! -d "$with_build_devkit"; then 44259 as_fn_error $? "--with-build-devkit points to non existing dir: $with_build_devkit" "$LINENO" 5 44260 else 44261 44262 # Only process if variable expands to non-empty 44263 44264 if test "x$with_build_devkit" != x; then 44265 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44266 44267 # Input might be given as Windows format, start by converting to 44268 # unix format. 44269 path="$with_build_devkit" 44270 new_path=`$CYGPATH -u "$path"` 44271 44272 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 44273 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 44274 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 44275 # "foo.exe" is OK but "foo" is an error. 44276 # 44277 # This test is therefore slightly more accurate than "test -f" to check for file precense. 44278 # It is also a way to make sure we got the proper file name for the real test later on. 44279 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 44280 if test "x$test_shortpath" = x; then 44281 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_build_devkit, which resolves as \"$path\", is invalid." >&5 44282 $as_echo "$as_me: The path of with_build_devkit, which resolves as \"$path\", is invalid." >&6;} 44283 as_fn_error $? "Cannot locate the the path of with_build_devkit" "$LINENO" 5 44284 fi 44285 44286 # Call helper function which possibly converts this using DOS-style short mode. 44287 # If so, the updated path is stored in $new_path. 44288 44289 input_path="$new_path" 44290 # Check if we need to convert this using DOS-style short mode. If the path 44291 # contains just simple characters, use it. Otherwise (spaces, weird characters), 44292 # take no chances and rewrite it. 44293 # Note: m4 eats our [], so we need to use [ and ] instead. 44294 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 44295 if test "x$has_forbidden_chars" != x; then 44296 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 44297 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 44298 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 44299 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 44300 # Going to short mode and back again did indeed matter. Since short mode is 44301 # case insensitive, let's make it lowercase to improve readability. 44302 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 44303 # Now convert it back to Unix-style (cygpath) 44304 input_path=`$CYGPATH -u "$shortmode_path"` 44305 new_path="$input_path" 44306 fi 44307 fi 44308 44309 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 44310 if test "x$test_cygdrive_prefix" = x; then 44311 # As a simple fix, exclude /usr/bin since it's not a real path. 44312 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 44313 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 44314 # a path prefixed by /cygdrive for fixpath to work. 44315 new_path="$CYGWIN_ROOT_PATH$input_path" 44316 fi 44317 fi 44318 44319 44320 if test "x$path" != "x$new_path"; then 44321 with_build_devkit="$new_path" 44322 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_build_devkit to \"$new_path\"" >&5 44323 $as_echo "$as_me: Rewriting with_build_devkit to \"$new_path\"" >&6;} 44324 fi 44325 44326 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44327 44328 path="$with_build_devkit" 44329 has_colon=`$ECHO $path | $GREP ^.:` 44330 new_path="$path" 44331 if test "x$has_colon" = x; then 44332 # Not in mixed or Windows style, start by that. 44333 new_path=`cmd //c echo $path` 44334 fi 44335 44336 44337 input_path="$new_path" 44338 # Check if we need to convert this using DOS-style short mode. If the path 44339 # contains just simple characters, use it. Otherwise (spaces, weird characters), 44340 # take no chances and rewrite it. 44341 # Note: m4 eats our [], so we need to use [ and ] instead. 44342 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 44343 if test "x$has_forbidden_chars" != x; then 44344 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 44345 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 44346 fi 44347 44348 44349 windows_path="$new_path" 44350 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44351 unix_path=`$CYGPATH -u "$windows_path"` 44352 new_path="$unix_path" 44353 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44354 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44355 new_path="$unix_path" 44356 fi 44357 44358 if test "x$path" != "x$new_path"; then 44359 with_build_devkit="$new_path" 44360 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_build_devkit to \"$new_path\"" >&5 44361 $as_echo "$as_me: Rewriting with_build_devkit to \"$new_path\"" >&6;} 44362 fi 44363 44364 # Save the first 10 bytes of this path to the storage, so fixpath can work. 44365 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 44366 44367 else 44368 # We're on a unix platform. Hooray! :) 44369 path="$with_build_devkit" 44370 has_space=`$ECHO "$path" | $GREP " "` 44371 if test "x$has_space" != x; then 44372 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_build_devkit, which resolves as \"$path\", is invalid." >&5 44373 $as_echo "$as_me: The path of with_build_devkit, which resolves as \"$path\", is invalid." >&6;} 44374 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 44375 fi 44376 44377 # Use eval to expand a potential ~ 44378 eval path="$path" 44379 if test ! -f "$path" && test ! -d "$path"; then 44380 as_fn_error $? "The path of with_build_devkit, which resolves as \"$path\", is not found." "$LINENO" 5 44381 fi 44382 44383 if test -d "$path"; then 44384 with_build_devkit="`cd "$path"; $THEPWDCMD -L`" 44385 else 44386 dir="`$DIRNAME "$path"`" 44387 base="`$BASENAME "$path"`" 44388 with_build_devkit="`cd "$dir"; $THEPWDCMD -L`/$base" 44389 fi 44390 fi 44391 fi 44392 44393 BUILD_DEVKIT_ROOT="$with_build_devkit" 44394 # Check for a meta data info file in the root of the devkit 44395 if test -f "$BUILD_DEVKIT_ROOT/devkit.info"; then 44396 # Process devkit.info so that existing devkit variables are not 44397 # modified by this 44398 $SED -e "s/^DEVKIT_/BUILD_DEVKIT_/g" \ 44399 -e "s/\$DEVKIT_ROOT/\$BUILD_DEVKIT_ROOT/g" \ 44400 -e "s/\$host/\$build/g" \ 44401 $BUILD_DEVKIT_ROOT/devkit.info \ 44402 > $CONFIGURESUPPORT_OUTPUTDIR/build-devkit.info 44403 . $CONFIGURESUPPORT_OUTPUTDIR/build-devkit.info 44404 # This potentially sets the following: 44405 # A descriptive name of the devkit 44406 44407 if test "x$BUILD_DEVKIT_NAME" = x; then 44408 eval BUILD_DEVKIT_NAME="\${BUILD_DEVKIT_NAME_${OPENJDK_TARGET_CPU}}" 44409 fi 44410 44411 # Corresponds to --with-extra-path 44412 44413 if test "x$BUILD_DEVKIT_EXTRA_PATH" = x; then 44414 eval BUILD_DEVKIT_EXTRA_PATH="\${BUILD_DEVKIT_EXTRA_PATH_${OPENJDK_TARGET_CPU}}" 44415 fi 44416 44417 # Corresponds to --with-toolchain-path 44418 44419 if test "x$BUILD_DEVKIT_TOOLCHAIN_PATH" = x; then 44420 eval BUILD_DEVKIT_TOOLCHAIN_PATH="\${BUILD_DEVKIT_TOOLCHAIN_PATH_${OPENJDK_TARGET_CPU}}" 44421 fi 44422 44423 # Corresponds to --with-sysroot 44424 44425 if test "x$BUILD_DEVKIT_SYSROOT" = x; then 44426 eval BUILD_DEVKIT_SYSROOT="\${BUILD_DEVKIT_SYSROOT_${OPENJDK_TARGET_CPU}}" 44427 fi 44428 44429 # Skip the Window specific parts 44430 fi 44431 44432 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for build platform devkit" >&5 44433 $as_echo_n "checking for build platform devkit... " >&6; } 44434 if test "x$BUILD_DEVKIT_NAME" != x; then 44435 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_DEVKIT_NAME in $BUILD_DEVKIT_ROOT" >&5 44436 $as_echo "$BUILD_DEVKIT_NAME in $BUILD_DEVKIT_ROOT" >&6; } 44437 else 44438 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_DEVKIT_ROOT" >&5 44439 $as_echo "$BUILD_DEVKIT_ROOT" >&6; } 44440 fi 44441 44442 BUILD_SYSROOT="$BUILD_DEVKIT_SYSROOT" 44443 44444 if test "x$BUILD_SYSROOT" != "x"; then 44445 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 44446 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 44447 # Solaris Studio does not have a concept of sysroot. Instead we must 44448 # make sure the default include and lib dirs are appended to each 44449 # compile and link command line. Must also add -I-xbuiltin to enable 44450 # inlining of system functions and intrinsics. 44451 BUILD_SYSROOT_CFLAGS="-I-xbuiltin -I$BUILD_SYSROOT/usr/include" 44452 BUILD_SYSROOT_LDFLAGS="-L$BUILD_SYSROOT/usr/lib$OPENJDK_TARGET_CPU_ISADIR \ 44453 -L$BUILD_SYSROOT/lib$OPENJDK_TARGET_CPU_ISADIR" 44454 fi 44455 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 44456 BUILD_SYSROOT_CFLAGS="--sysroot=$BUILD_SYSROOT" 44457 BUILD_SYSROOT_LDFLAGS="--sysroot=$BUILD_SYSROOT" 44458 elif test "x$TOOLCHAIN_TYPE" = xclang; then 44459 BUILD_SYSROOT_CFLAGS="-isysroot $BUILD_SYSROOT" 44460 BUILD_SYSROOT_LDFLAGS="-isysroot $BUILD_SYSROOT" 44461 fi 44462 # The global CFLAGS and LDFLAGS variables need these for configure to function 44463 BUILD_CFLAGS="$BUILD_CFLAGS $BUILD_SYSROOT_CFLAGS" 44464 BUILD_CPPFLAGS="$BUILD_CPPFLAGS $BUILD_SYSROOT_CFLAGS" 44465 BUILD_CXXFLAGS="$BUILD_CXXFLAGS $BUILD_SYSROOT_CFLAGS" 44466 BUILD_LDFLAGS="$BUILD_LDFLAGS $BUILD_SYSROOT_LDFLAGS" 44467 fi 44468 44469 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 44470 # We also need -iframework<path>/System/Library/Frameworks 44471 BUILD_SYSROOT_CFLAGS="$BUILD_SYSROOT_CFLAGS -iframework $BUILD_SYSROOT/System/Library/Frameworks" 44472 BUILD_SYSROOT_LDFLAGS="$BUILD_SYSROOT_LDFLAGS -iframework $BUILD_SYSROOT/System/Library/Frameworks" 44473 # These always need to be set, or we can't find the frameworks embedded in JavaVM.framework 44474 # set this here so it doesn't have to be peppered throughout the forest 44475 BUILD_SYSROOT_CFLAGS="$BUILD_SYSROOT_CFLAGS -F $BUILD_SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks" 44476 BUILD_SYSROOT_LDFLAGS="$BUILD_SYSROOT_LDFLAGS -F $BUILD_SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks" 44477 fi 44478 44479 44480 44481 44482 44483 # Fallback default of just /bin if DEVKIT_PATH is not defined 44484 if test "x$BUILD_DEVKIT_TOOLCHAIN_PATH" = x; then 44485 BUILD_DEVKIT_TOOLCHAIN_PATH="$BUILD_DEVKIT_ROOT/bin" 44486 fi 44487 PATH="$BUILD_DEVKIT_TOOLCHAIN_PATH:$BUILD_DEVKIT_EXTRA_PATH" 44488 fi 44489 fi 44490 44491 # FIXME: we should list the discovered compilers as an exclude pattern! 44492 # If we do that, we can do this detection before POST_DETECTION, and still 44493 # find the build compilers in the tools dir, if needed. 44494 44495 44496 44497 # Publish this variable in the help. 44498 44499 44500 if [ -z "${BUILD_CC+x}" ]; then 44501 # The variable is not set by user, try to locate tool using the code snippet 44502 for ac_prog in cl cc gcc 44503 do 44504 # Extract the first word of "$ac_prog", so it can be a program name with args. 44505 set dummy $ac_prog; ac_word=$2 44506 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44507 $as_echo_n "checking for $ac_word... " >&6; } 44508 if ${ac_cv_path_BUILD_CC+:} false; then : 44509 $as_echo_n "(cached) " >&6 44510 else 44511 case $BUILD_CC in 44512 [\\/]* | ?:[\\/]*) 44513 ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path. 44514 ;; 44515 *) 44516 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44517 for as_dir in $PATH 44518 do 44519 IFS=$as_save_IFS 44520 test -z "$as_dir" && as_dir=. 44521 for ac_exec_ext in '' $ac_executable_extensions; do 44522 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44523 ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext" 44524 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44525 break 2 44526 fi 44527 done 44528 done 44529 IFS=$as_save_IFS 44530 44531 ;; 44532 esac 44533 fi 44534 BUILD_CC=$ac_cv_path_BUILD_CC 44535 if test -n "$BUILD_CC"; then 44536 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5 44537 $as_echo "$BUILD_CC" >&6; } 44538 else 44539 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44540 $as_echo "no" >&6; } 44541 fi 44542 44543 44544 test -n "$BUILD_CC" && break 44545 done 44546 44547 else 44548 # The variable is set, but is it from the command line or the environment? 44549 44550 # Try to remove the string !BUILD_CC! from our list. 44551 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_CC!/} 44552 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 44553 # If it failed, the variable was not from the command line. Ignore it, 44554 # but warn the user (except for BASH, which is always set by the calling BASH). 44555 if test "xBUILD_CC" != xBASH; then 44556 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_CC from the environment. Use command line variables instead." >&5 44557 $as_echo "$as_me: WARNING: Ignoring value of BUILD_CC from the environment. Use command line variables instead." >&2;} 44558 fi 44559 # Try to locate tool using the code snippet 44560 for ac_prog in cl cc gcc 44561 do 44562 # Extract the first word of "$ac_prog", so it can be a program name with args. 44563 set dummy $ac_prog; ac_word=$2 44564 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44565 $as_echo_n "checking for $ac_word... " >&6; } 44566 if ${ac_cv_path_BUILD_CC+:} false; then : 44567 $as_echo_n "(cached) " >&6 44568 else 44569 case $BUILD_CC in 44570 [\\/]* | ?:[\\/]*) 44571 ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path. 44572 ;; 44573 *) 44574 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44575 for as_dir in $PATH 44576 do 44577 IFS=$as_save_IFS 44578 test -z "$as_dir" && as_dir=. 44579 for ac_exec_ext in '' $ac_executable_extensions; do 44580 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44581 ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext" 44582 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44583 break 2 44584 fi 44585 done 44586 done 44587 IFS=$as_save_IFS 44588 44589 ;; 44590 esac 44591 fi 44592 BUILD_CC=$ac_cv_path_BUILD_CC 44593 if test -n "$BUILD_CC"; then 44594 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5 44595 $as_echo "$BUILD_CC" >&6; } 44596 else 44597 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44598 $as_echo "no" >&6; } 44599 fi 44600 44601 44602 test -n "$BUILD_CC" && break 44603 done 44604 44605 else 44606 # If it succeeded, then it was overridden by the user. We will use it 44607 # for the tool. 44608 44609 # First remove it from the list of overridden variables, so we can test 44610 # for unknown variables in the end. 44611 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 44612 44613 # Check if we try to supply an empty value 44614 if test "x$BUILD_CC" = x; then 44615 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_CC= (no value)" >&5 44616 $as_echo "$as_me: Setting user supplied tool BUILD_CC= (no value)" >&6;} 44617 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CC" >&5 44618 $as_echo_n "checking for BUILD_CC... " >&6; } 44619 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 44620 $as_echo "disabled" >&6; } 44621 else 44622 # Check if the provided tool contains a complete path. 44623 tool_specified="$BUILD_CC" 44624 tool_basename="${tool_specified##*/}" 44625 if test "x$tool_basename" = "x$tool_specified"; then 44626 # A command without a complete path is provided, search $PATH. 44627 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_CC=$tool_basename" >&5 44628 $as_echo "$as_me: Will search for user supplied tool BUILD_CC=$tool_basename" >&6;} 44629 # Extract the first word of "$tool_basename", so it can be a program name with args. 44630 set dummy $tool_basename; ac_word=$2 44631 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44632 $as_echo_n "checking for $ac_word... " >&6; } 44633 if ${ac_cv_path_BUILD_CC+:} false; then : 44634 $as_echo_n "(cached) " >&6 44635 else 44636 case $BUILD_CC in 44637 [\\/]* | ?:[\\/]*) 44638 ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path. 44639 ;; 44640 *) 44641 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44642 for as_dir in $PATH 44643 do 44644 IFS=$as_save_IFS 44645 test -z "$as_dir" && as_dir=. 44646 for ac_exec_ext in '' $ac_executable_extensions; do 44647 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44648 ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext" 44649 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44650 break 2 44651 fi 44652 done 44653 done 44654 IFS=$as_save_IFS 44655 44656 ;; 44657 esac 44658 fi 44659 BUILD_CC=$ac_cv_path_BUILD_CC 44660 if test -n "$BUILD_CC"; then 44661 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5 44662 $as_echo "$BUILD_CC" >&6; } 44663 else 44664 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44665 $as_echo "no" >&6; } 44666 fi 44667 44668 44669 if test "x$BUILD_CC" = x; then 44670 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 44671 fi 44672 else 44673 # Otherwise we believe it is a complete path. Use it as it is. 44674 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_CC=$tool_specified" >&5 44675 $as_echo "$as_me: Will use user supplied tool BUILD_CC=$tool_specified" >&6;} 44676 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CC" >&5 44677 $as_echo_n "checking for BUILD_CC... " >&6; } 44678 if test ! -x "$tool_specified"; then 44679 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 44680 $as_echo "not found" >&6; } 44681 as_fn_error $? "User supplied tool BUILD_CC=$tool_specified does not exist or is not executable" "$LINENO" 5 44682 fi 44683 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 44684 $as_echo "$tool_specified" >&6; } 44685 fi 44686 fi 44687 fi 44688 44689 fi 44690 44691 44692 44693 if test "x$BUILD_CC" = x; then 44694 as_fn_error $? "Could not find required tool for BUILD_CC" "$LINENO" 5 44695 fi 44696 44697 44698 44699 # Only process if variable expands to non-empty 44700 44701 if test "x$BUILD_CC" != x; then 44702 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44703 44704 # First separate the path from the arguments. This will split at the first 44705 # space. 44706 complete="$BUILD_CC" 44707 path="${complete%% *}" 44708 tmp="$complete EOL" 44709 arguments="${tmp#* }" 44710 44711 # Input might be given as Windows format, start by converting to 44712 # unix format. 44713 new_path=`$CYGPATH -u "$path"` 44714 44715 # Now try to locate executable using which 44716 new_path=`$WHICH "$new_path" 2> /dev/null` 44717 # bat and cmd files are not always considered executable in cygwin causing which 44718 # to not find them 44719 if test "x$new_path" = x \ 44720 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44721 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44722 new_path=`$CYGPATH -u "$path"` 44723 fi 44724 if test "x$new_path" = x; then 44725 # Oops. Which didn't find the executable. 44726 # The splitting of arguments from the executable at a space might have been incorrect, 44727 # since paths with space are more likely in Windows. Give it another try with the whole 44728 # argument. 44729 path="$complete" 44730 arguments="EOL" 44731 new_path=`$CYGPATH -u "$path"` 44732 new_path=`$WHICH "$new_path" 2> /dev/null` 44733 # bat and cmd files are not always considered executable in cygwin causing which 44734 # to not find them 44735 if test "x$new_path" = x \ 44736 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44737 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44738 new_path=`$CYGPATH -u "$path"` 44739 fi 44740 if test "x$new_path" = x; then 44741 # It's still not found. Now this is an unrecoverable error. 44742 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5 44743 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;} 44744 has_space=`$ECHO "$complete" | $GREP " "` 44745 if test "x$has_space" != x; then 44746 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 44747 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 44748 fi 44749 as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5 44750 fi 44751 fi 44752 44753 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 44754 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 44755 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 44756 # "foo.exe" is OK but "foo" is an error. 44757 # 44758 # This test is therefore slightly more accurate than "test -f" to check for file presence. 44759 # It is also a way to make sure we got the proper file name for the real test later on. 44760 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 44761 if test "x$test_shortpath" = x; then 44762 # Short path failed, file does not exist as specified. 44763 # Try adding .exe or .cmd 44764 if test -f "${new_path}.exe"; then 44765 input_to_shortpath="${new_path}.exe" 44766 elif test -f "${new_path}.cmd"; then 44767 input_to_shortpath="${new_path}.cmd" 44768 else 44769 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$new_path\", is invalid." >&5 44770 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$new_path\", is invalid." >&6;} 44771 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 44772 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 44773 as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5 44774 fi 44775 else 44776 input_to_shortpath="$new_path" 44777 fi 44778 44779 # Call helper function which possibly converts this using DOS-style short mode. 44780 # If so, the updated path is stored in $new_path. 44781 new_path="$input_to_shortpath" 44782 44783 input_path="$input_to_shortpath" 44784 # Check if we need to convert this using DOS-style short mode. If the path 44785 # contains just simple characters, use it. Otherwise (spaces, weird characters), 44786 # take no chances and rewrite it. 44787 # Note: m4 eats our [], so we need to use [ and ] instead. 44788 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 44789 if test "x$has_forbidden_chars" != x; then 44790 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 44791 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 44792 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 44793 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 44794 # Going to short mode and back again did indeed matter. Since short mode is 44795 # case insensitive, let's make it lowercase to improve readability. 44796 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 44797 # Now convert it back to Unix-style (cygpath) 44798 input_path=`$CYGPATH -u "$shortmode_path"` 44799 new_path="$input_path" 44800 fi 44801 fi 44802 44803 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 44804 if test "x$test_cygdrive_prefix" = x; then 44805 # As a simple fix, exclude /usr/bin since it's not a real path. 44806 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 44807 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 44808 # a path prefixed by /cygdrive for fixpath to work. 44809 new_path="$CYGWIN_ROOT_PATH$input_path" 44810 fi 44811 fi 44812 44813 # remove trailing .exe if any 44814 new_path="${new_path/%.exe/}" 44815 44816 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44817 44818 # First separate the path from the arguments. This will split at the first 44819 # space. 44820 complete="$BUILD_CC" 44821 path="${complete%% *}" 44822 tmp="$complete EOL" 44823 arguments="${tmp#* }" 44824 44825 # Input might be given as Windows format, start by converting to 44826 # unix format. 44827 new_path="$path" 44828 44829 windows_path="$new_path" 44830 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44831 unix_path=`$CYGPATH -u "$windows_path"` 44832 new_path="$unix_path" 44833 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44834 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44835 new_path="$unix_path" 44836 fi 44837 44838 44839 # Now try to locate executable using which 44840 new_path=`$WHICH "$new_path" 2> /dev/null` 44841 44842 if test "x$new_path" = x; then 44843 # Oops. Which didn't find the executable. 44844 # The splitting of arguments from the executable at a space might have been incorrect, 44845 # since paths with space are more likely in Windows. Give it another try with the whole 44846 # argument. 44847 path="$complete" 44848 arguments="EOL" 44849 new_path="$path" 44850 44851 windows_path="$new_path" 44852 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44853 unix_path=`$CYGPATH -u "$windows_path"` 44854 new_path="$unix_path" 44855 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44856 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44857 new_path="$unix_path" 44858 fi 44859 44860 44861 new_path=`$WHICH "$new_path" 2> /dev/null` 44862 # bat and cmd files are not always considered executable in MSYS causing which 44863 # to not find them 44864 if test "x$new_path" = x \ 44865 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44866 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44867 new_path="$path" 44868 44869 windows_path="$new_path" 44870 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44871 unix_path=`$CYGPATH -u "$windows_path"` 44872 new_path="$unix_path" 44873 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44874 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44875 new_path="$unix_path" 44876 fi 44877 44878 fi 44879 44880 if test "x$new_path" = x; then 44881 # It's still not found. Now this is an unrecoverable error. 44882 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5 44883 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;} 44884 has_space=`$ECHO "$complete" | $GREP " "` 44885 if test "x$has_space" != x; then 44886 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 44887 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 44888 fi 44889 as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5 44890 fi 44891 fi 44892 44893 # Now new_path has a complete unix path to the binary 44894 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 44895 # Keep paths in /bin as-is, but remove trailing .exe if any 44896 new_path="${new_path/%.exe/}" 44897 # Do not save /bin paths to all_fixpath_prefixes! 44898 else 44899 # Not in mixed or Windows style, start by that. 44900 new_path=`cmd //c echo $new_path` 44901 44902 input_path="$new_path" 44903 # Check if we need to convert this using DOS-style short mode. If the path 44904 # contains just simple characters, use it. Otherwise (spaces, weird characters), 44905 # take no chances and rewrite it. 44906 # Note: m4 eats our [], so we need to use [ and ] instead. 44907 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 44908 if test "x$has_forbidden_chars" != x; then 44909 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 44910 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 44911 fi 44912 44913 # Output is in $new_path 44914 44915 windows_path="$new_path" 44916 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44917 unix_path=`$CYGPATH -u "$windows_path"` 44918 new_path="$unix_path" 44919 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44920 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44921 new_path="$unix_path" 44922 fi 44923 44924 # remove trailing .exe if any 44925 new_path="${new_path/%.exe/}" 44926 44927 # Save the first 10 bytes of this path to the storage, so fixpath can work. 44928 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 44929 fi 44930 44931 else 44932 # We're on a unix platform. Hooray! :) 44933 # First separate the path from the arguments. This will split at the first 44934 # space. 44935 complete="$BUILD_CC" 44936 path="${complete%% *}" 44937 tmp="$complete EOL" 44938 arguments="${tmp#* }" 44939 44940 # Cannot rely on the command "which" here since it doesn't always work. 44941 is_absolute_path=`$ECHO "$path" | $GREP ^/` 44942 if test -z "$is_absolute_path"; then 44943 # Path to executable is not absolute. Find it. 44944 IFS_save="$IFS" 44945 IFS=: 44946 for p in $PATH; do 44947 if test -f "$p/$path" && test -x "$p/$path"; then 44948 new_path="$p/$path" 44949 break 44950 fi 44951 done 44952 IFS="$IFS_save" 44953 else 44954 # This is an absolute path, we can use it without further modifications. 44955 new_path="$path" 44956 fi 44957 44958 if test "x$new_path" = x; then 44959 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5 44960 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;} 44961 has_space=`$ECHO "$complete" | $GREP " "` 44962 if test "x$has_space" != x; then 44963 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 44964 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 44965 fi 44966 as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5 44967 fi 44968 fi 44969 44970 # Now join together the path and the arguments once again 44971 if test "x$arguments" != xEOL; then 44972 new_complete="$new_path ${arguments% *}" 44973 else 44974 new_complete="$new_path" 44975 fi 44976 44977 if test "x$complete" != "x$new_complete"; then 44978 BUILD_CC="$new_complete" 44979 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_CC to \"$new_complete\"" >&5 44980 $as_echo "$as_me: Rewriting BUILD_CC to \"$new_complete\"" >&6;} 44981 fi 44982 fi 44983 44984 44985 44986 44987 # Publish this variable in the help. 44988 44989 44990 if [ -z "${BUILD_CXX+x}" ]; then 44991 # The variable is not set by user, try to locate tool using the code snippet 44992 for ac_prog in cl CC g++ 44993 do 44994 # Extract the first word of "$ac_prog", so it can be a program name with args. 44995 set dummy $ac_prog; ac_word=$2 44996 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44997 $as_echo_n "checking for $ac_word... " >&6; } 44998 if ${ac_cv_path_BUILD_CXX+:} false; then : 44999 $as_echo_n "(cached) " >&6 45000 else 45001 case $BUILD_CXX in 45002 [\\/]* | ?:[\\/]*) 45003 ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path. 45004 ;; 45005 *) 45006 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45007 for as_dir in $PATH 45008 do 45009 IFS=$as_save_IFS 45010 test -z "$as_dir" && as_dir=. 45011 for ac_exec_ext in '' $ac_executable_extensions; do 45012 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45013 ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext" 45014 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45015 break 2 45016 fi 45017 done 45018 done 45019 IFS=$as_save_IFS 45020 45021 ;; 45022 esac 45023 fi 45024 BUILD_CXX=$ac_cv_path_BUILD_CXX 45025 if test -n "$BUILD_CXX"; then 45026 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5 45027 $as_echo "$BUILD_CXX" >&6; } 45028 else 45029 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45030 $as_echo "no" >&6; } 45031 fi 45032 45033 45034 test -n "$BUILD_CXX" && break 45035 done 45036 45037 else 45038 # The variable is set, but is it from the command line or the environment? 45039 45040 # Try to remove the string !BUILD_CXX! from our list. 45041 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_CXX!/} 45042 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 45043 # If it failed, the variable was not from the command line. Ignore it, 45044 # but warn the user (except for BASH, which is always set by the calling BASH). 45045 if test "xBUILD_CXX" != xBASH; then 45046 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_CXX from the environment. Use command line variables instead." >&5 45047 $as_echo "$as_me: WARNING: Ignoring value of BUILD_CXX from the environment. Use command line variables instead." >&2;} 45048 fi 45049 # Try to locate tool using the code snippet 45050 for ac_prog in cl CC g++ 45051 do 45052 # Extract the first word of "$ac_prog", so it can be a program name with args. 45053 set dummy $ac_prog; ac_word=$2 45054 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45055 $as_echo_n "checking for $ac_word... " >&6; } 45056 if ${ac_cv_path_BUILD_CXX+:} false; then : 45057 $as_echo_n "(cached) " >&6 45058 else 45059 case $BUILD_CXX in 45060 [\\/]* | ?:[\\/]*) 45061 ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path. 45062 ;; 45063 *) 45064 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45065 for as_dir in $PATH 45066 do 45067 IFS=$as_save_IFS 45068 test -z "$as_dir" && as_dir=. 45069 for ac_exec_ext in '' $ac_executable_extensions; do 45070 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45071 ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext" 45072 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45073 break 2 45074 fi 45075 done 45076 done 45077 IFS=$as_save_IFS 45078 45079 ;; 45080 esac 45081 fi 45082 BUILD_CXX=$ac_cv_path_BUILD_CXX 45083 if test -n "$BUILD_CXX"; then 45084 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5 45085 $as_echo "$BUILD_CXX" >&6; } 45086 else 45087 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45088 $as_echo "no" >&6; } 45089 fi 45090 45091 45092 test -n "$BUILD_CXX" && break 45093 done 45094 45095 else 45096 # If it succeeded, then it was overridden by the user. We will use it 45097 # for the tool. 45098 45099 # First remove it from the list of overridden variables, so we can test 45100 # for unknown variables in the end. 45101 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 45102 45103 # Check if we try to supply an empty value 45104 if test "x$BUILD_CXX" = x; then 45105 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_CXX= (no value)" >&5 45106 $as_echo "$as_me: Setting user supplied tool BUILD_CXX= (no value)" >&6;} 45107 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CXX" >&5 45108 $as_echo_n "checking for BUILD_CXX... " >&6; } 45109 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 45110 $as_echo "disabled" >&6; } 45111 else 45112 # Check if the provided tool contains a complete path. 45113 tool_specified="$BUILD_CXX" 45114 tool_basename="${tool_specified##*/}" 45115 if test "x$tool_basename" = "x$tool_specified"; then 45116 # A command without a complete path is provided, search $PATH. 45117 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_CXX=$tool_basename" >&5 45118 $as_echo "$as_me: Will search for user supplied tool BUILD_CXX=$tool_basename" >&6;} 45119 # Extract the first word of "$tool_basename", so it can be a program name with args. 45120 set dummy $tool_basename; ac_word=$2 45121 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45122 $as_echo_n "checking for $ac_word... " >&6; } 45123 if ${ac_cv_path_BUILD_CXX+:} false; then : 45124 $as_echo_n "(cached) " >&6 45125 else 45126 case $BUILD_CXX in 45127 [\\/]* | ?:[\\/]*) 45128 ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path. 45129 ;; 45130 *) 45131 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45132 for as_dir in $PATH 45133 do 45134 IFS=$as_save_IFS 45135 test -z "$as_dir" && as_dir=. 45136 for ac_exec_ext in '' $ac_executable_extensions; do 45137 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45138 ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext" 45139 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45140 break 2 45141 fi 45142 done 45143 done 45144 IFS=$as_save_IFS 45145 45146 ;; 45147 esac 45148 fi 45149 BUILD_CXX=$ac_cv_path_BUILD_CXX 45150 if test -n "$BUILD_CXX"; then 45151 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5 45152 $as_echo "$BUILD_CXX" >&6; } 45153 else 45154 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45155 $as_echo "no" >&6; } 45156 fi 45157 45158 45159 if test "x$BUILD_CXX" = x; then 45160 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 45161 fi 45162 else 45163 # Otherwise we believe it is a complete path. Use it as it is. 45164 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_CXX=$tool_specified" >&5 45165 $as_echo "$as_me: Will use user supplied tool BUILD_CXX=$tool_specified" >&6;} 45166 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CXX" >&5 45167 $as_echo_n "checking for BUILD_CXX... " >&6; } 45168 if test ! -x "$tool_specified"; then 45169 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 45170 $as_echo "not found" >&6; } 45171 as_fn_error $? "User supplied tool BUILD_CXX=$tool_specified does not exist or is not executable" "$LINENO" 5 45172 fi 45173 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 45174 $as_echo "$tool_specified" >&6; } 45175 fi 45176 fi 45177 fi 45178 45179 fi 45180 45181 45182 45183 if test "x$BUILD_CXX" = x; then 45184 as_fn_error $? "Could not find required tool for BUILD_CXX" "$LINENO" 5 45185 fi 45186 45187 45188 45189 # Only process if variable expands to non-empty 45190 45191 if test "x$BUILD_CXX" != x; then 45192 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45193 45194 # First separate the path from the arguments. This will split at the first 45195 # space. 45196 complete="$BUILD_CXX" 45197 path="${complete%% *}" 45198 tmp="$complete EOL" 45199 arguments="${tmp#* }" 45200 45201 # Input might be given as Windows format, start by converting to 45202 # unix format. 45203 new_path=`$CYGPATH -u "$path"` 45204 45205 # Now try to locate executable using which 45206 new_path=`$WHICH "$new_path" 2> /dev/null` 45207 # bat and cmd files are not always considered executable in cygwin causing which 45208 # to not find them 45209 if test "x$new_path" = x \ 45210 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 45211 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 45212 new_path=`$CYGPATH -u "$path"` 45213 fi 45214 if test "x$new_path" = x; then 45215 # Oops. Which didn't find the executable. 45216 # The splitting of arguments from the executable at a space might have been incorrect, 45217 # since paths with space are more likely in Windows. Give it another try with the whole 45218 # argument. 45219 path="$complete" 45220 arguments="EOL" 45221 new_path=`$CYGPATH -u "$path"` 45222 new_path=`$WHICH "$new_path" 2> /dev/null` 45223 # bat and cmd files are not always considered executable in cygwin causing which 45224 # to not find them 45225 if test "x$new_path" = x \ 45226 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 45227 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 45228 new_path=`$CYGPATH -u "$path"` 45229 fi 45230 if test "x$new_path" = x; then 45231 # It's still not found. Now this is an unrecoverable error. 45232 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5 45233 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;} 45234 has_space=`$ECHO "$complete" | $GREP " "` 45235 if test "x$has_space" != x; then 45236 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 45237 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 45238 fi 45239 as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5 45240 fi 45241 fi 45242 45243 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 45244 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 45245 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 45246 # "foo.exe" is OK but "foo" is an error. 45247 # 45248 # This test is therefore slightly more accurate than "test -f" to check for file presence. 45249 # It is also a way to make sure we got the proper file name for the real test later on. 45250 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 45251 if test "x$test_shortpath" = x; then 45252 # Short path failed, file does not exist as specified. 45253 # Try adding .exe or .cmd 45254 if test -f "${new_path}.exe"; then 45255 input_to_shortpath="${new_path}.exe" 45256 elif test -f "${new_path}.cmd"; then 45257 input_to_shortpath="${new_path}.cmd" 45258 else 45259 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$new_path\", is invalid." >&5 45260 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$new_path\", is invalid." >&6;} 45261 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 45262 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 45263 as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5 45264 fi 45265 else 45266 input_to_shortpath="$new_path" 45267 fi 45268 45269 # Call helper function which possibly converts this using DOS-style short mode. 45270 # If so, the updated path is stored in $new_path. 45271 new_path="$input_to_shortpath" 45272 45273 input_path="$input_to_shortpath" 45274 # Check if we need to convert this using DOS-style short mode. If the path 45275 # contains just simple characters, use it. Otherwise (spaces, weird characters), 45276 # take no chances and rewrite it. 45277 # Note: m4 eats our [], so we need to use [ and ] instead. 45278 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 45279 if test "x$has_forbidden_chars" != x; then 45280 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 45281 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 45282 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 45283 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 45284 # Going to short mode and back again did indeed matter. Since short mode is 45285 # case insensitive, let's make it lowercase to improve readability. 45286 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 45287 # Now convert it back to Unix-style (cygpath) 45288 input_path=`$CYGPATH -u "$shortmode_path"` 45289 new_path="$input_path" 45290 fi 45291 fi 45292 45293 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 45294 if test "x$test_cygdrive_prefix" = x; then 45295 # As a simple fix, exclude /usr/bin since it's not a real path. 45296 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 45297 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 45298 # a path prefixed by /cygdrive for fixpath to work. 45299 new_path="$CYGWIN_ROOT_PATH$input_path" 45300 fi 45301 fi 45302 45303 # remove trailing .exe if any 45304 new_path="${new_path/%.exe/}" 45305 45306 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45307 45308 # First separate the path from the arguments. This will split at the first 45309 # space. 45310 complete="$BUILD_CXX" 45311 path="${complete%% *}" 45312 tmp="$complete EOL" 45313 arguments="${tmp#* }" 45314 45315 # Input might be given as Windows format, start by converting to 45316 # unix format. 45317 new_path="$path" 45318 45319 windows_path="$new_path" 45320 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45321 unix_path=`$CYGPATH -u "$windows_path"` 45322 new_path="$unix_path" 45323 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45324 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45325 new_path="$unix_path" 45326 fi 45327 45328 45329 # Now try to locate executable using which 45330 new_path=`$WHICH "$new_path" 2> /dev/null` 45331 45332 if test "x$new_path" = x; then 45333 # Oops. Which didn't find the executable. 45334 # The splitting of arguments from the executable at a space might have been incorrect, 45335 # since paths with space are more likely in Windows. Give it another try with the whole 45336 # argument. 45337 path="$complete" 45338 arguments="EOL" 45339 new_path="$path" 45340 45341 windows_path="$new_path" 45342 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45343 unix_path=`$CYGPATH -u "$windows_path"` 45344 new_path="$unix_path" 45345 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45346 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45347 new_path="$unix_path" 45348 fi 45349 45350 45351 new_path=`$WHICH "$new_path" 2> /dev/null` 45352 # bat and cmd files are not always considered executable in MSYS causing which 45353 # to not find them 45354 if test "x$new_path" = x \ 45355 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 45356 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 45357 new_path="$path" 45358 45359 windows_path="$new_path" 45360 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45361 unix_path=`$CYGPATH -u "$windows_path"` 45362 new_path="$unix_path" 45363 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45364 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45365 new_path="$unix_path" 45366 fi 45367 45368 fi 45369 45370 if test "x$new_path" = x; then 45371 # It's still not found. Now this is an unrecoverable error. 45372 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5 45373 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;} 45374 has_space=`$ECHO "$complete" | $GREP " "` 45375 if test "x$has_space" != x; then 45376 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 45377 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 45378 fi 45379 as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5 45380 fi 45381 fi 45382 45383 # Now new_path has a complete unix path to the binary 45384 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 45385 # Keep paths in /bin as-is, but remove trailing .exe if any 45386 new_path="${new_path/%.exe/}" 45387 # Do not save /bin paths to all_fixpath_prefixes! 45388 else 45389 # Not in mixed or Windows style, start by that. 45390 new_path=`cmd //c echo $new_path` 45391 45392 input_path="$new_path" 45393 # Check if we need to convert this using DOS-style short mode. If the path 45394 # contains just simple characters, use it. Otherwise (spaces, weird characters), 45395 # take no chances and rewrite it. 45396 # Note: m4 eats our [], so we need to use [ and ] instead. 45397 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 45398 if test "x$has_forbidden_chars" != x; then 45399 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 45400 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 45401 fi 45402 45403 # Output is in $new_path 45404 45405 windows_path="$new_path" 45406 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45407 unix_path=`$CYGPATH -u "$windows_path"` 45408 new_path="$unix_path" 45409 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45410 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45411 new_path="$unix_path" 45412 fi 45413 45414 # remove trailing .exe if any 45415 new_path="${new_path/%.exe/}" 45416 45417 # Save the first 10 bytes of this path to the storage, so fixpath can work. 45418 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 45419 fi 45420 45421 else 45422 # We're on a unix platform. Hooray! :) 45423 # First separate the path from the arguments. This will split at the first 45424 # space. 45425 complete="$BUILD_CXX" 45426 path="${complete%% *}" 45427 tmp="$complete EOL" 45428 arguments="${tmp#* }" 45429 45430 # Cannot rely on the command "which" here since it doesn't always work. 45431 is_absolute_path=`$ECHO "$path" | $GREP ^/` 45432 if test -z "$is_absolute_path"; then 45433 # Path to executable is not absolute. Find it. 45434 IFS_save="$IFS" 45435 IFS=: 45436 for p in $PATH; do 45437 if test -f "$p/$path" && test -x "$p/$path"; then 45438 new_path="$p/$path" 45439 break 45440 fi 45441 done 45442 IFS="$IFS_save" 45443 else 45444 # This is an absolute path, we can use it without further modifications. 45445 new_path="$path" 45446 fi 45447 45448 if test "x$new_path" = x; then 45449 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5 45450 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;} 45451 has_space=`$ECHO "$complete" | $GREP " "` 45452 if test "x$has_space" != x; then 45453 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 45454 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 45455 fi 45456 as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5 45457 fi 45458 fi 45459 45460 # Now join together the path and the arguments once again 45461 if test "x$arguments" != xEOL; then 45462 new_complete="$new_path ${arguments% *}" 45463 else 45464 new_complete="$new_path" 45465 fi 45466 45467 if test "x$complete" != "x$new_complete"; then 45468 BUILD_CXX="$new_complete" 45469 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_CXX to \"$new_complete\"" >&5 45470 $as_echo "$as_me: Rewriting BUILD_CXX to \"$new_complete\"" >&6;} 45471 fi 45472 fi 45473 45474 45475 45476 # Publish this variable in the help. 45477 45478 45479 if [ -z "${BUILD_NM+x}" ]; then 45480 # The variable is not set by user, try to locate tool using the code snippet 45481 for ac_prog in nm gcc-nm 45482 do 45483 # Extract the first word of "$ac_prog", so it can be a program name with args. 45484 set dummy $ac_prog; ac_word=$2 45485 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45486 $as_echo_n "checking for $ac_word... " >&6; } 45487 if ${ac_cv_path_BUILD_NM+:} false; then : 45488 $as_echo_n "(cached) " >&6 45489 else 45490 case $BUILD_NM in 45491 [\\/]* | ?:[\\/]*) 45492 ac_cv_path_BUILD_NM="$BUILD_NM" # Let the user override the test with a path. 45493 ;; 45494 *) 45495 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45496 for as_dir in $PATH 45497 do 45498 IFS=$as_save_IFS 45499 test -z "$as_dir" && as_dir=. 45500 for ac_exec_ext in '' $ac_executable_extensions; do 45501 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45502 ac_cv_path_BUILD_NM="$as_dir/$ac_word$ac_exec_ext" 45503 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45504 break 2 45505 fi 45506 done 45507 done 45508 IFS=$as_save_IFS 45509 45510 ;; 45511 esac 45512 fi 45513 BUILD_NM=$ac_cv_path_BUILD_NM 45514 if test -n "$BUILD_NM"; then 45515 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_NM" >&5 45516 $as_echo "$BUILD_NM" >&6; } 45517 else 45518 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45519 $as_echo "no" >&6; } 45520 fi 45521 45522 45523 test -n "$BUILD_NM" && break 45524 done 45525 45526 else 45527 # The variable is set, but is it from the command line or the environment? 45528 45529 # Try to remove the string !BUILD_NM! from our list. 45530 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_NM!/} 45531 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 45532 # If it failed, the variable was not from the command line. Ignore it, 45533 # but warn the user (except for BASH, which is always set by the calling BASH). 45534 if test "xBUILD_NM" != xBASH; then 45535 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_NM from the environment. Use command line variables instead." >&5 45536 $as_echo "$as_me: WARNING: Ignoring value of BUILD_NM from the environment. Use command line variables instead." >&2;} 45537 fi 45538 # Try to locate tool using the code snippet 45539 for ac_prog in nm gcc-nm 45540 do 45541 # Extract the first word of "$ac_prog", so it can be a program name with args. 45542 set dummy $ac_prog; ac_word=$2 45543 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45544 $as_echo_n "checking for $ac_word... " >&6; } 45545 if ${ac_cv_path_BUILD_NM+:} false; then : 45546 $as_echo_n "(cached) " >&6 45547 else 45548 case $BUILD_NM in 45549 [\\/]* | ?:[\\/]*) 45550 ac_cv_path_BUILD_NM="$BUILD_NM" # Let the user override the test with a path. 45551 ;; 45552 *) 45553 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45554 for as_dir in $PATH 45555 do 45556 IFS=$as_save_IFS 45557 test -z "$as_dir" && as_dir=. 45558 for ac_exec_ext in '' $ac_executable_extensions; do 45559 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45560 ac_cv_path_BUILD_NM="$as_dir/$ac_word$ac_exec_ext" 45561 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45562 break 2 45563 fi 45564 done 45565 done 45566 IFS=$as_save_IFS 45567 45568 ;; 45569 esac 45570 fi 45571 BUILD_NM=$ac_cv_path_BUILD_NM 45572 if test -n "$BUILD_NM"; then 45573 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_NM" >&5 45574 $as_echo "$BUILD_NM" >&6; } 45575 else 45576 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45577 $as_echo "no" >&6; } 45578 fi 45579 45580 45581 test -n "$BUILD_NM" && break 45582 done 45583 45584 else 45585 # If it succeeded, then it was overridden by the user. We will use it 45586 # for the tool. 45587 45588 # First remove it from the list of overridden variables, so we can test 45589 # for unknown variables in the end. 45590 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 45591 45592 # Check if we try to supply an empty value 45593 if test "x$BUILD_NM" = x; then 45594 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_NM= (no value)" >&5 45595 $as_echo "$as_me: Setting user supplied tool BUILD_NM= (no value)" >&6;} 45596 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_NM" >&5 45597 $as_echo_n "checking for BUILD_NM... " >&6; } 45598 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 45599 $as_echo "disabled" >&6; } 45600 else 45601 # Check if the provided tool contains a complete path. 45602 tool_specified="$BUILD_NM" 45603 tool_basename="${tool_specified##*/}" 45604 if test "x$tool_basename" = "x$tool_specified"; then 45605 # A command without a complete path is provided, search $PATH. 45606 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_NM=$tool_basename" >&5 45607 $as_echo "$as_me: Will search for user supplied tool BUILD_NM=$tool_basename" >&6;} 45608 # Extract the first word of "$tool_basename", so it can be a program name with args. 45609 set dummy $tool_basename; ac_word=$2 45610 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45611 $as_echo_n "checking for $ac_word... " >&6; } 45612 if ${ac_cv_path_BUILD_NM+:} false; then : 45613 $as_echo_n "(cached) " >&6 45614 else 45615 case $BUILD_NM in 45616 [\\/]* | ?:[\\/]*) 45617 ac_cv_path_BUILD_NM="$BUILD_NM" # Let the user override the test with a path. 45618 ;; 45619 *) 45620 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45621 for as_dir in $PATH 45622 do 45623 IFS=$as_save_IFS 45624 test -z "$as_dir" && as_dir=. 45625 for ac_exec_ext in '' $ac_executable_extensions; do 45626 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45627 ac_cv_path_BUILD_NM="$as_dir/$ac_word$ac_exec_ext" 45628 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45629 break 2 45630 fi 45631 done 45632 done 45633 IFS=$as_save_IFS 45634 45635 ;; 45636 esac 45637 fi 45638 BUILD_NM=$ac_cv_path_BUILD_NM 45639 if test -n "$BUILD_NM"; then 45640 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_NM" >&5 45641 $as_echo "$BUILD_NM" >&6; } 45642 else 45643 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45644 $as_echo "no" >&6; } 45645 fi 45646 45647 45648 if test "x$BUILD_NM" = x; then 45649 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 45650 fi 45651 else 45652 # Otherwise we believe it is a complete path. Use it as it is. 45653 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_NM=$tool_specified" >&5 45654 $as_echo "$as_me: Will use user supplied tool BUILD_NM=$tool_specified" >&6;} 45655 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_NM" >&5 45656 $as_echo_n "checking for BUILD_NM... " >&6; } 45657 if test ! -x "$tool_specified"; then 45658 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 45659 $as_echo "not found" >&6; } 45660 as_fn_error $? "User supplied tool BUILD_NM=$tool_specified does not exist or is not executable" "$LINENO" 5 45661 fi 45662 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 45663 $as_echo "$tool_specified" >&6; } 45664 fi 45665 fi 45666 fi 45667 45668 fi 45669 45670 45671 45672 # Only process if variable expands to non-empty 45673 45674 if test "x$BUILD_NM" != x; then 45675 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45676 45677 # First separate the path from the arguments. This will split at the first 45678 # space. 45679 complete="$BUILD_NM" 45680 path="${complete%% *}" 45681 tmp="$complete EOL" 45682 arguments="${tmp#* }" 45683 45684 # Input might be given as Windows format, start by converting to 45685 # unix format. 45686 new_path=`$CYGPATH -u "$path"` 45687 45688 # Now try to locate executable using which 45689 new_path=`$WHICH "$new_path" 2> /dev/null` 45690 # bat and cmd files are not always considered executable in cygwin causing which 45691 # to not find them 45692 if test "x$new_path" = x \ 45693 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 45694 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 45695 new_path=`$CYGPATH -u "$path"` 45696 fi 45697 if test "x$new_path" = x; then 45698 # Oops. Which didn't find the executable. 45699 # The splitting of arguments from the executable at a space might have been incorrect, 45700 # since paths with space are more likely in Windows. Give it another try with the whole 45701 # argument. 45702 path="$complete" 45703 arguments="EOL" 45704 new_path=`$CYGPATH -u "$path"` 45705 new_path=`$WHICH "$new_path" 2> /dev/null` 45706 # bat and cmd files are not always considered executable in cygwin causing which 45707 # to not find them 45708 if test "x$new_path" = x \ 45709 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 45710 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 45711 new_path=`$CYGPATH -u "$path"` 45712 fi 45713 if test "x$new_path" = x; then 45714 # It's still not found. Now this is an unrecoverable error. 45715 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&5 45716 $as_echo "$as_me: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&6;} 45717 has_space=`$ECHO "$complete" | $GREP " "` 45718 if test "x$has_space" != x; then 45719 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 45720 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 45721 fi 45722 as_fn_error $? "Cannot locate the the path of BUILD_NM" "$LINENO" 5 45723 fi 45724 fi 45725 45726 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 45727 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 45728 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 45729 # "foo.exe" is OK but "foo" is an error. 45730 # 45731 # This test is therefore slightly more accurate than "test -f" to check for file presence. 45732 # It is also a way to make sure we got the proper file name for the real test later on. 45733 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 45734 if test "x$test_shortpath" = x; then 45735 # Short path failed, file does not exist as specified. 45736 # Try adding .exe or .cmd 45737 if test -f "${new_path}.exe"; then 45738 input_to_shortpath="${new_path}.exe" 45739 elif test -f "${new_path}.cmd"; then 45740 input_to_shortpath="${new_path}.cmd" 45741 else 45742 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_NM, which resolves as \"$new_path\", is invalid." >&5 45743 $as_echo "$as_me: The path of BUILD_NM, which resolves as \"$new_path\", is invalid." >&6;} 45744 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 45745 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 45746 as_fn_error $? "Cannot locate the the path of BUILD_NM" "$LINENO" 5 45747 fi 45748 else 45749 input_to_shortpath="$new_path" 45750 fi 45751 45752 # Call helper function which possibly converts this using DOS-style short mode. 45753 # If so, the updated path is stored in $new_path. 45754 new_path="$input_to_shortpath" 45755 45756 input_path="$input_to_shortpath" 45757 # Check if we need to convert this using DOS-style short mode. If the path 45758 # contains just simple characters, use it. Otherwise (spaces, weird characters), 45759 # take no chances and rewrite it. 45760 # Note: m4 eats our [], so we need to use [ and ] instead. 45761 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 45762 if test "x$has_forbidden_chars" != x; then 45763 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 45764 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 45765 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 45766 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 45767 # Going to short mode and back again did indeed matter. Since short mode is 45768 # case insensitive, let's make it lowercase to improve readability. 45769 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 45770 # Now convert it back to Unix-style (cygpath) 45771 input_path=`$CYGPATH -u "$shortmode_path"` 45772 new_path="$input_path" 45773 fi 45774 fi 45775 45776 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 45777 if test "x$test_cygdrive_prefix" = x; then 45778 # As a simple fix, exclude /usr/bin since it's not a real path. 45779 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 45780 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 45781 # a path prefixed by /cygdrive for fixpath to work. 45782 new_path="$CYGWIN_ROOT_PATH$input_path" 45783 fi 45784 fi 45785 45786 # remove trailing .exe if any 45787 new_path="${new_path/%.exe/}" 45788 45789 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45790 45791 # First separate the path from the arguments. This will split at the first 45792 # space. 45793 complete="$BUILD_NM" 45794 path="${complete%% *}" 45795 tmp="$complete EOL" 45796 arguments="${tmp#* }" 45797 45798 # Input might be given as Windows format, start by converting to 45799 # unix format. 45800 new_path="$path" 45801 45802 windows_path="$new_path" 45803 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45804 unix_path=`$CYGPATH -u "$windows_path"` 45805 new_path="$unix_path" 45806 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45807 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45808 new_path="$unix_path" 45809 fi 45810 45811 45812 # Now try to locate executable using which 45813 new_path=`$WHICH "$new_path" 2> /dev/null` 45814 45815 if test "x$new_path" = x; then 45816 # Oops. Which didn't find the executable. 45817 # The splitting of arguments from the executable at a space might have been incorrect, 45818 # since paths with space are more likely in Windows. Give it another try with the whole 45819 # argument. 45820 path="$complete" 45821 arguments="EOL" 45822 new_path="$path" 45823 45824 windows_path="$new_path" 45825 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45826 unix_path=`$CYGPATH -u "$windows_path"` 45827 new_path="$unix_path" 45828 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45829 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45830 new_path="$unix_path" 45831 fi 45832 45833 45834 new_path=`$WHICH "$new_path" 2> /dev/null` 45835 # bat and cmd files are not always considered executable in MSYS causing which 45836 # to not find them 45837 if test "x$new_path" = x \ 45838 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 45839 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 45840 new_path="$path" 45841 45842 windows_path="$new_path" 45843 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45844 unix_path=`$CYGPATH -u "$windows_path"` 45845 new_path="$unix_path" 45846 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45847 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45848 new_path="$unix_path" 45849 fi 45850 45851 fi 45852 45853 if test "x$new_path" = x; then 45854 # It's still not found. Now this is an unrecoverable error. 45855 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&5 45856 $as_echo "$as_me: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&6;} 45857 has_space=`$ECHO "$complete" | $GREP " "` 45858 if test "x$has_space" != x; then 45859 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 45860 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 45861 fi 45862 as_fn_error $? "Cannot locate the the path of BUILD_NM" "$LINENO" 5 45863 fi 45864 fi 45865 45866 # Now new_path has a complete unix path to the binary 45867 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 45868 # Keep paths in /bin as-is, but remove trailing .exe if any 45869 new_path="${new_path/%.exe/}" 45870 # Do not save /bin paths to all_fixpath_prefixes! 45871 else 45872 # Not in mixed or Windows style, start by that. 45873 new_path=`cmd //c echo $new_path` 45874 45875 input_path="$new_path" 45876 # Check if we need to convert this using DOS-style short mode. If the path 45877 # contains just simple characters, use it. Otherwise (spaces, weird characters), 45878 # take no chances and rewrite it. 45879 # Note: m4 eats our [], so we need to use [ and ] instead. 45880 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 45881 if test "x$has_forbidden_chars" != x; then 45882 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 45883 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 45884 fi 45885 45886 # Output is in $new_path 45887 45888 windows_path="$new_path" 45889 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45890 unix_path=`$CYGPATH -u "$windows_path"` 45891 new_path="$unix_path" 45892 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45893 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45894 new_path="$unix_path" 45895 fi 45896 45897 # remove trailing .exe if any 45898 new_path="${new_path/%.exe/}" 45899 45900 # Save the first 10 bytes of this path to the storage, so fixpath can work. 45901 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 45902 fi 45903 45904 else 45905 # We're on a unix platform. Hooray! :) 45906 # First separate the path from the arguments. This will split at the first 45907 # space. 45908 complete="$BUILD_NM" 45909 path="${complete%% *}" 45910 tmp="$complete EOL" 45911 arguments="${tmp#* }" 45912 45913 # Cannot rely on the command "which" here since it doesn't always work. 45914 is_absolute_path=`$ECHO "$path" | $GREP ^/` 45915 if test -z "$is_absolute_path"; then 45916 # Path to executable is not absolute. Find it. 45917 IFS_save="$IFS" 45918 IFS=: 45919 for p in $PATH; do 45920 if test -f "$p/$path" && test -x "$p/$path"; then 45921 new_path="$p/$path" 45922 break 45923 fi 45924 done 45925 IFS="$IFS_save" 45926 else 45927 # This is an absolute path, we can use it without further modifications. 45928 new_path="$path" 45929 fi 45930 45931 if test "x$new_path" = x; then 45932 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&5 45933 $as_echo "$as_me: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&6;} 45934 has_space=`$ECHO "$complete" | $GREP " "` 45935 if test "x$has_space" != x; then 45936 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 45937 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 45938 fi 45939 as_fn_error $? "Cannot locate the the path of BUILD_NM" "$LINENO" 5 45940 fi 45941 fi 45942 45943 # Now join together the path and the arguments once again 45944 if test "x$arguments" != xEOL; then 45945 new_complete="$new_path ${arguments% *}" 45946 else 45947 new_complete="$new_path" 45948 fi 45949 45950 if test "x$complete" != "x$new_complete"; then 45951 BUILD_NM="$new_complete" 45952 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_NM to \"$new_complete\"" >&5 45953 $as_echo "$as_me: Rewriting BUILD_NM to \"$new_complete\"" >&6;} 45954 fi 45955 fi 45956 45957 45958 45959 # Publish this variable in the help. 45960 45961 45962 if [ -z "${BUILD_AR+x}" ]; then 45963 # The variable is not set by user, try to locate tool using the code snippet 45964 for ac_prog in ar gcc-ar 45965 do 45966 # Extract the first word of "$ac_prog", so it can be a program name with args. 45967 set dummy $ac_prog; ac_word=$2 45968 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45969 $as_echo_n "checking for $ac_word... " >&6; } 45970 if ${ac_cv_path_BUILD_AR+:} false; then : 45971 $as_echo_n "(cached) " >&6 45972 else 45973 case $BUILD_AR in 45974 [\\/]* | ?:[\\/]*) 45975 ac_cv_path_BUILD_AR="$BUILD_AR" # Let the user override the test with a path. 45976 ;; 45977 *) 45978 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45979 for as_dir in $PATH 45980 do 45981 IFS=$as_save_IFS 45982 test -z "$as_dir" && as_dir=. 45983 for ac_exec_ext in '' $ac_executable_extensions; do 45984 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45985 ac_cv_path_BUILD_AR="$as_dir/$ac_word$ac_exec_ext" 45986 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45987 break 2 45988 fi 45989 done 45990 done 45991 IFS=$as_save_IFS 45992 45993 ;; 45994 esac 45995 fi 45996 BUILD_AR=$ac_cv_path_BUILD_AR 45997 if test -n "$BUILD_AR"; then 45998 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_AR" >&5 45999 $as_echo "$BUILD_AR" >&6; } 46000 else 46001 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46002 $as_echo "no" >&6; } 46003 fi 46004 46005 46006 test -n "$BUILD_AR" && break 46007 done 46008 46009 else 46010 # The variable is set, but is it from the command line or the environment? 46011 46012 # Try to remove the string !BUILD_AR! from our list. 46013 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_AR!/} 46014 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 46015 # If it failed, the variable was not from the command line. Ignore it, 46016 # but warn the user (except for BASH, which is always set by the calling BASH). 46017 if test "xBUILD_AR" != xBASH; then 46018 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_AR from the environment. Use command line variables instead." >&5 46019 $as_echo "$as_me: WARNING: Ignoring value of BUILD_AR from the environment. Use command line variables instead." >&2;} 46020 fi 46021 # Try to locate tool using the code snippet 46022 for ac_prog in ar gcc-ar 46023 do 46024 # Extract the first word of "$ac_prog", so it can be a program name with args. 46025 set dummy $ac_prog; ac_word=$2 46026 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 46027 $as_echo_n "checking for $ac_word... " >&6; } 46028 if ${ac_cv_path_BUILD_AR+:} false; then : 46029 $as_echo_n "(cached) " >&6 46030 else 46031 case $BUILD_AR in 46032 [\\/]* | ?:[\\/]*) 46033 ac_cv_path_BUILD_AR="$BUILD_AR" # Let the user override the test with a path. 46034 ;; 46035 *) 46036 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46037 for as_dir in $PATH 46038 do 46039 IFS=$as_save_IFS 46040 test -z "$as_dir" && as_dir=. 46041 for ac_exec_ext in '' $ac_executable_extensions; do 46042 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46043 ac_cv_path_BUILD_AR="$as_dir/$ac_word$ac_exec_ext" 46044 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46045 break 2 46046 fi 46047 done 46048 done 46049 IFS=$as_save_IFS 46050 46051 ;; 46052 esac 46053 fi 46054 BUILD_AR=$ac_cv_path_BUILD_AR 46055 if test -n "$BUILD_AR"; then 46056 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_AR" >&5 46057 $as_echo "$BUILD_AR" >&6; } 46058 else 46059 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46060 $as_echo "no" >&6; } 46061 fi 46062 46063 46064 test -n "$BUILD_AR" && break 46065 done 46066 46067 else 46068 # If it succeeded, then it was overridden by the user. We will use it 46069 # for the tool. 46070 46071 # First remove it from the list of overridden variables, so we can test 46072 # for unknown variables in the end. 46073 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 46074 46075 # Check if we try to supply an empty value 46076 if test "x$BUILD_AR" = x; then 46077 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_AR= (no value)" >&5 46078 $as_echo "$as_me: Setting user supplied tool BUILD_AR= (no value)" >&6;} 46079 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_AR" >&5 46080 $as_echo_n "checking for BUILD_AR... " >&6; } 46081 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 46082 $as_echo "disabled" >&6; } 46083 else 46084 # Check if the provided tool contains a complete path. 46085 tool_specified="$BUILD_AR" 46086 tool_basename="${tool_specified##*/}" 46087 if test "x$tool_basename" = "x$tool_specified"; then 46088 # A command without a complete path is provided, search $PATH. 46089 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_AR=$tool_basename" >&5 46090 $as_echo "$as_me: Will search for user supplied tool BUILD_AR=$tool_basename" >&6;} 46091 # Extract the first word of "$tool_basename", so it can be a program name with args. 46092 set dummy $tool_basename; ac_word=$2 46093 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 46094 $as_echo_n "checking for $ac_word... " >&6; } 46095 if ${ac_cv_path_BUILD_AR+:} false; then : 46096 $as_echo_n "(cached) " >&6 46097 else 46098 case $BUILD_AR in 46099 [\\/]* | ?:[\\/]*) 46100 ac_cv_path_BUILD_AR="$BUILD_AR" # Let the user override the test with a path. 46101 ;; 46102 *) 46103 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46104 for as_dir in $PATH 46105 do 46106 IFS=$as_save_IFS 46107 test -z "$as_dir" && as_dir=. 46108 for ac_exec_ext in '' $ac_executable_extensions; do 46109 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46110 ac_cv_path_BUILD_AR="$as_dir/$ac_word$ac_exec_ext" 46111 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46112 break 2 46113 fi 46114 done 46115 done 46116 IFS=$as_save_IFS 46117 46118 ;; 46119 esac 46120 fi 46121 BUILD_AR=$ac_cv_path_BUILD_AR 46122 if test -n "$BUILD_AR"; then 46123 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_AR" >&5 46124 $as_echo "$BUILD_AR" >&6; } 46125 else 46126 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46127 $as_echo "no" >&6; } 46128 fi 46129 46130 46131 if test "x$BUILD_AR" = x; then 46132 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 46133 fi 46134 else 46135 # Otherwise we believe it is a complete path. Use it as it is. 46136 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_AR=$tool_specified" >&5 46137 $as_echo "$as_me: Will use user supplied tool BUILD_AR=$tool_specified" >&6;} 46138 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_AR" >&5 46139 $as_echo_n "checking for BUILD_AR... " >&6; } 46140 if test ! -x "$tool_specified"; then 46141 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 46142 $as_echo "not found" >&6; } 46143 as_fn_error $? "User supplied tool BUILD_AR=$tool_specified does not exist or is not executable" "$LINENO" 5 46144 fi 46145 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 46146 $as_echo "$tool_specified" >&6; } 46147 fi 46148 fi 46149 fi 46150 46151 fi 46152 46153 46154 46155 # Only process if variable expands to non-empty 46156 46157 if test "x$BUILD_AR" != x; then 46158 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46159 46160 # First separate the path from the arguments. This will split at the first 46161 # space. 46162 complete="$BUILD_AR" 46163 path="${complete%% *}" 46164 tmp="$complete EOL" 46165 arguments="${tmp#* }" 46166 46167 # Input might be given as Windows format, start by converting to 46168 # unix format. 46169 new_path=`$CYGPATH -u "$path"` 46170 46171 # Now try to locate executable using which 46172 new_path=`$WHICH "$new_path" 2> /dev/null` 46173 # bat and cmd files are not always considered executable in cygwin causing which 46174 # to not find them 46175 if test "x$new_path" = x \ 46176 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46177 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46178 new_path=`$CYGPATH -u "$path"` 46179 fi 46180 if test "x$new_path" = x; then 46181 # Oops. Which didn't find the executable. 46182 # The splitting of arguments from the executable at a space might have been incorrect, 46183 # since paths with space are more likely in Windows. Give it another try with the whole 46184 # argument. 46185 path="$complete" 46186 arguments="EOL" 46187 new_path=`$CYGPATH -u "$path"` 46188 new_path=`$WHICH "$new_path" 2> /dev/null` 46189 # bat and cmd files are not always considered executable in cygwin causing which 46190 # to not find them 46191 if test "x$new_path" = x \ 46192 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46193 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46194 new_path=`$CYGPATH -u "$path"` 46195 fi 46196 if test "x$new_path" = x; then 46197 # It's still not found. Now this is an unrecoverable error. 46198 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&5 46199 $as_echo "$as_me: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&6;} 46200 has_space=`$ECHO "$complete" | $GREP " "` 46201 if test "x$has_space" != x; then 46202 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 46203 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 46204 fi 46205 as_fn_error $? "Cannot locate the the path of BUILD_AR" "$LINENO" 5 46206 fi 46207 fi 46208 46209 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 46210 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 46211 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 46212 # "foo.exe" is OK but "foo" is an error. 46213 # 46214 # This test is therefore slightly more accurate than "test -f" to check for file presence. 46215 # It is also a way to make sure we got the proper file name for the real test later on. 46216 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 46217 if test "x$test_shortpath" = x; then 46218 # Short path failed, file does not exist as specified. 46219 # Try adding .exe or .cmd 46220 if test -f "${new_path}.exe"; then 46221 input_to_shortpath="${new_path}.exe" 46222 elif test -f "${new_path}.cmd"; then 46223 input_to_shortpath="${new_path}.cmd" 46224 else 46225 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_AR, which resolves as \"$new_path\", is invalid." >&5 46226 $as_echo "$as_me: The path of BUILD_AR, which resolves as \"$new_path\", is invalid." >&6;} 46227 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 46228 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 46229 as_fn_error $? "Cannot locate the the path of BUILD_AR" "$LINENO" 5 46230 fi 46231 else 46232 input_to_shortpath="$new_path" 46233 fi 46234 46235 # Call helper function which possibly converts this using DOS-style short mode. 46236 # If so, the updated path is stored in $new_path. 46237 new_path="$input_to_shortpath" 46238 46239 input_path="$input_to_shortpath" 46240 # Check if we need to convert this using DOS-style short mode. If the path 46241 # contains just simple characters, use it. Otherwise (spaces, weird characters), 46242 # take no chances and rewrite it. 46243 # Note: m4 eats our [], so we need to use [ and ] instead. 46244 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 46245 if test "x$has_forbidden_chars" != x; then 46246 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 46247 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 46248 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 46249 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 46250 # Going to short mode and back again did indeed matter. Since short mode is 46251 # case insensitive, let's make it lowercase to improve readability. 46252 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 46253 # Now convert it back to Unix-style (cygpath) 46254 input_path=`$CYGPATH -u "$shortmode_path"` 46255 new_path="$input_path" 46256 fi 46257 fi 46258 46259 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 46260 if test "x$test_cygdrive_prefix" = x; then 46261 # As a simple fix, exclude /usr/bin since it's not a real path. 46262 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 46263 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 46264 # a path prefixed by /cygdrive for fixpath to work. 46265 new_path="$CYGWIN_ROOT_PATH$input_path" 46266 fi 46267 fi 46268 46269 # remove trailing .exe if any 46270 new_path="${new_path/%.exe/}" 46271 46272 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46273 46274 # First separate the path from the arguments. This will split at the first 46275 # space. 46276 complete="$BUILD_AR" 46277 path="${complete%% *}" 46278 tmp="$complete EOL" 46279 arguments="${tmp#* }" 46280 46281 # Input might be given as Windows format, start by converting to 46282 # unix format. 46283 new_path="$path" 46284 46285 windows_path="$new_path" 46286 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46287 unix_path=`$CYGPATH -u "$windows_path"` 46288 new_path="$unix_path" 46289 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46290 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46291 new_path="$unix_path" 46292 fi 46293 46294 46295 # Now try to locate executable using which 46296 new_path=`$WHICH "$new_path" 2> /dev/null` 46297 46298 if test "x$new_path" = x; then 46299 # Oops. Which didn't find the executable. 46300 # The splitting of arguments from the executable at a space might have been incorrect, 46301 # since paths with space are more likely in Windows. Give it another try with the whole 46302 # argument. 46303 path="$complete" 46304 arguments="EOL" 46305 new_path="$path" 46306 46307 windows_path="$new_path" 46308 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46309 unix_path=`$CYGPATH -u "$windows_path"` 46310 new_path="$unix_path" 46311 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46312 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46313 new_path="$unix_path" 46314 fi 46315 46316 46317 new_path=`$WHICH "$new_path" 2> /dev/null` 46318 # bat and cmd files are not always considered executable in MSYS causing which 46319 # to not find them 46320 if test "x$new_path" = x \ 46321 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46322 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46323 new_path="$path" 46324 46325 windows_path="$new_path" 46326 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46327 unix_path=`$CYGPATH -u "$windows_path"` 46328 new_path="$unix_path" 46329 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46330 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46331 new_path="$unix_path" 46332 fi 46333 46334 fi 46335 46336 if test "x$new_path" = x; then 46337 # It's still not found. Now this is an unrecoverable error. 46338 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&5 46339 $as_echo "$as_me: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&6;} 46340 has_space=`$ECHO "$complete" | $GREP " "` 46341 if test "x$has_space" != x; then 46342 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 46343 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 46344 fi 46345 as_fn_error $? "Cannot locate the the path of BUILD_AR" "$LINENO" 5 46346 fi 46347 fi 46348 46349 # Now new_path has a complete unix path to the binary 46350 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 46351 # Keep paths in /bin as-is, but remove trailing .exe if any 46352 new_path="${new_path/%.exe/}" 46353 # Do not save /bin paths to all_fixpath_prefixes! 46354 else 46355 # Not in mixed or Windows style, start by that. 46356 new_path=`cmd //c echo $new_path` 46357 46358 input_path="$new_path" 46359 # Check if we need to convert this using DOS-style short mode. If the path 46360 # contains just simple characters, use it. Otherwise (spaces, weird characters), 46361 # take no chances and rewrite it. 46362 # Note: m4 eats our [], so we need to use [ and ] instead. 46363 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 46364 if test "x$has_forbidden_chars" != x; then 46365 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 46366 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 46367 fi 46368 46369 # Output is in $new_path 46370 46371 windows_path="$new_path" 46372 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46373 unix_path=`$CYGPATH -u "$windows_path"` 46374 new_path="$unix_path" 46375 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46376 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46377 new_path="$unix_path" 46378 fi 46379 46380 # remove trailing .exe if any 46381 new_path="${new_path/%.exe/}" 46382 46383 # Save the first 10 bytes of this path to the storage, so fixpath can work. 46384 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 46385 fi 46386 46387 else 46388 # We're on a unix platform. Hooray! :) 46389 # First separate the path from the arguments. This will split at the first 46390 # space. 46391 complete="$BUILD_AR" 46392 path="${complete%% *}" 46393 tmp="$complete EOL" 46394 arguments="${tmp#* }" 46395 46396 # Cannot rely on the command "which" here since it doesn't always work. 46397 is_absolute_path=`$ECHO "$path" | $GREP ^/` 46398 if test -z "$is_absolute_path"; then 46399 # Path to executable is not absolute. Find it. 46400 IFS_save="$IFS" 46401 IFS=: 46402 for p in $PATH; do 46403 if test -f "$p/$path" && test -x "$p/$path"; then 46404 new_path="$p/$path" 46405 break 46406 fi 46407 done 46408 IFS="$IFS_save" 46409 else 46410 # This is an absolute path, we can use it without further modifications. 46411 new_path="$path" 46412 fi 46413 46414 if test "x$new_path" = x; then 46415 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&5 46416 $as_echo "$as_me: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&6;} 46417 has_space=`$ECHO "$complete" | $GREP " "` 46418 if test "x$has_space" != x; then 46419 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 46420 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 46421 fi 46422 as_fn_error $? "Cannot locate the the path of BUILD_AR" "$LINENO" 5 46423 fi 46424 fi 46425 46426 # Now join together the path and the arguments once again 46427 if test "x$arguments" != xEOL; then 46428 new_complete="$new_path ${arguments% *}" 46429 else 46430 new_complete="$new_path" 46431 fi 46432 46433 if test "x$complete" != "x$new_complete"; then 46434 BUILD_AR="$new_complete" 46435 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_AR to \"$new_complete\"" >&5 46436 $as_echo "$as_me: Rewriting BUILD_AR to \"$new_complete\"" >&6;} 46437 fi 46438 fi 46439 46440 46441 46442 # Publish this variable in the help. 46443 46444 46445 if [ -z "${BUILD_OBJCOPY+x}" ]; then 46446 # The variable is not set by user, try to locate tool using the code snippet 46447 for ac_prog in objcopy 46448 do 46449 # Extract the first word of "$ac_prog", so it can be a program name with args. 46450 set dummy $ac_prog; ac_word=$2 46451 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 46452 $as_echo_n "checking for $ac_word... " >&6; } 46453 if ${ac_cv_path_BUILD_OBJCOPY+:} false; then : 46454 $as_echo_n "(cached) " >&6 46455 else 46456 case $BUILD_OBJCOPY in 46457 [\\/]* | ?:[\\/]*) 46458 ac_cv_path_BUILD_OBJCOPY="$BUILD_OBJCOPY" # Let the user override the test with a path. 46459 ;; 46460 *) 46461 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46462 for as_dir in $PATH 46463 do 46464 IFS=$as_save_IFS 46465 test -z "$as_dir" && as_dir=. 46466 for ac_exec_ext in '' $ac_executable_extensions; do 46467 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46468 ac_cv_path_BUILD_OBJCOPY="$as_dir/$ac_word$ac_exec_ext" 46469 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46470 break 2 46471 fi 46472 done 46473 done 46474 IFS=$as_save_IFS 46475 46476 ;; 46477 esac 46478 fi 46479 BUILD_OBJCOPY=$ac_cv_path_BUILD_OBJCOPY 46480 if test -n "$BUILD_OBJCOPY"; then 46481 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_OBJCOPY" >&5 46482 $as_echo "$BUILD_OBJCOPY" >&6; } 46483 else 46484 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46485 $as_echo "no" >&6; } 46486 fi 46487 46488 46489 test -n "$BUILD_OBJCOPY" && break 46490 done 46491 46492 else 46493 # The variable is set, but is it from the command line or the environment? 46494 46495 # Try to remove the string !BUILD_OBJCOPY! from our list. 46496 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_OBJCOPY!/} 46497 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 46498 # If it failed, the variable was not from the command line. Ignore it, 46499 # but warn the user (except for BASH, which is always set by the calling BASH). 46500 if test "xBUILD_OBJCOPY" != xBASH; then 46501 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_OBJCOPY from the environment. Use command line variables instead." >&5 46502 $as_echo "$as_me: WARNING: Ignoring value of BUILD_OBJCOPY from the environment. Use command line variables instead." >&2;} 46503 fi 46504 # Try to locate tool using the code snippet 46505 for ac_prog in objcopy 46506 do 46507 # Extract the first word of "$ac_prog", so it can be a program name with args. 46508 set dummy $ac_prog; ac_word=$2 46509 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 46510 $as_echo_n "checking for $ac_word... " >&6; } 46511 if ${ac_cv_path_BUILD_OBJCOPY+:} false; then : 46512 $as_echo_n "(cached) " >&6 46513 else 46514 case $BUILD_OBJCOPY in 46515 [\\/]* | ?:[\\/]*) 46516 ac_cv_path_BUILD_OBJCOPY="$BUILD_OBJCOPY" # Let the user override the test with a path. 46517 ;; 46518 *) 46519 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46520 for as_dir in $PATH 46521 do 46522 IFS=$as_save_IFS 46523 test -z "$as_dir" && as_dir=. 46524 for ac_exec_ext in '' $ac_executable_extensions; do 46525 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46526 ac_cv_path_BUILD_OBJCOPY="$as_dir/$ac_word$ac_exec_ext" 46527 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46528 break 2 46529 fi 46530 done 46531 done 46532 IFS=$as_save_IFS 46533 46534 ;; 46535 esac 46536 fi 46537 BUILD_OBJCOPY=$ac_cv_path_BUILD_OBJCOPY 46538 if test -n "$BUILD_OBJCOPY"; then 46539 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_OBJCOPY" >&5 46540 $as_echo "$BUILD_OBJCOPY" >&6; } 46541 else 46542 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46543 $as_echo "no" >&6; } 46544 fi 46545 46546 46547 test -n "$BUILD_OBJCOPY" && break 46548 done 46549 46550 else 46551 # If it succeeded, then it was overridden by the user. We will use it 46552 # for the tool. 46553 46554 # First remove it from the list of overridden variables, so we can test 46555 # for unknown variables in the end. 46556 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 46557 46558 # Check if we try to supply an empty value 46559 if test "x$BUILD_OBJCOPY" = x; then 46560 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_OBJCOPY= (no value)" >&5 46561 $as_echo "$as_me: Setting user supplied tool BUILD_OBJCOPY= (no value)" >&6;} 46562 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_OBJCOPY" >&5 46563 $as_echo_n "checking for BUILD_OBJCOPY... " >&6; } 46564 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 46565 $as_echo "disabled" >&6; } 46566 else 46567 # Check if the provided tool contains a complete path. 46568 tool_specified="$BUILD_OBJCOPY" 46569 tool_basename="${tool_specified##*/}" 46570 if test "x$tool_basename" = "x$tool_specified"; then 46571 # A command without a complete path is provided, search $PATH. 46572 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_OBJCOPY=$tool_basename" >&5 46573 $as_echo "$as_me: Will search for user supplied tool BUILD_OBJCOPY=$tool_basename" >&6;} 46574 # Extract the first word of "$tool_basename", so it can be a program name with args. 46575 set dummy $tool_basename; ac_word=$2 46576 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 46577 $as_echo_n "checking for $ac_word... " >&6; } 46578 if ${ac_cv_path_BUILD_OBJCOPY+:} false; then : 46579 $as_echo_n "(cached) " >&6 46580 else 46581 case $BUILD_OBJCOPY in 46582 [\\/]* | ?:[\\/]*) 46583 ac_cv_path_BUILD_OBJCOPY="$BUILD_OBJCOPY" # Let the user override the test with a path. 46584 ;; 46585 *) 46586 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46587 for as_dir in $PATH 46588 do 46589 IFS=$as_save_IFS 46590 test -z "$as_dir" && as_dir=. 46591 for ac_exec_ext in '' $ac_executable_extensions; do 46592 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46593 ac_cv_path_BUILD_OBJCOPY="$as_dir/$ac_word$ac_exec_ext" 46594 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46595 break 2 46596 fi 46597 done 46598 done 46599 IFS=$as_save_IFS 46600 46601 ;; 46602 esac 46603 fi 46604 BUILD_OBJCOPY=$ac_cv_path_BUILD_OBJCOPY 46605 if test -n "$BUILD_OBJCOPY"; then 46606 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_OBJCOPY" >&5 46607 $as_echo "$BUILD_OBJCOPY" >&6; } 46608 else 46609 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46610 $as_echo "no" >&6; } 46611 fi 46612 46613 46614 if test "x$BUILD_OBJCOPY" = x; then 46615 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 46616 fi 46617 else 46618 # Otherwise we believe it is a complete path. Use it as it is. 46619 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_OBJCOPY=$tool_specified" >&5 46620 $as_echo "$as_me: Will use user supplied tool BUILD_OBJCOPY=$tool_specified" >&6;} 46621 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_OBJCOPY" >&5 46622 $as_echo_n "checking for BUILD_OBJCOPY... " >&6; } 46623 if test ! -x "$tool_specified"; then 46624 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 46625 $as_echo "not found" >&6; } 46626 as_fn_error $? "User supplied tool BUILD_OBJCOPY=$tool_specified does not exist or is not executable" "$LINENO" 5 46627 fi 46628 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 46629 $as_echo "$tool_specified" >&6; } 46630 fi 46631 fi 46632 fi 46633 46634 fi 46635 46636 46637 46638 # Only process if variable expands to non-empty 46639 46640 if test "x$BUILD_OBJCOPY" != x; then 46641 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46642 46643 # First separate the path from the arguments. This will split at the first 46644 # space. 46645 complete="$BUILD_OBJCOPY" 46646 path="${complete%% *}" 46647 tmp="$complete EOL" 46648 arguments="${tmp#* }" 46649 46650 # Input might be given as Windows format, start by converting to 46651 # unix format. 46652 new_path=`$CYGPATH -u "$path"` 46653 46654 # Now try to locate executable using which 46655 new_path=`$WHICH "$new_path" 2> /dev/null` 46656 # bat and cmd files are not always considered executable in cygwin causing which 46657 # to not find them 46658 if test "x$new_path" = x \ 46659 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46660 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46661 new_path=`$CYGPATH -u "$path"` 46662 fi 46663 if test "x$new_path" = x; then 46664 # Oops. Which didn't find the executable. 46665 # The splitting of arguments from the executable at a space might have been incorrect, 46666 # since paths with space are more likely in Windows. Give it another try with the whole 46667 # argument. 46668 path="$complete" 46669 arguments="EOL" 46670 new_path=`$CYGPATH -u "$path"` 46671 new_path=`$WHICH "$new_path" 2> /dev/null` 46672 # bat and cmd files are not always considered executable in cygwin causing which 46673 # to not find them 46674 if test "x$new_path" = x \ 46675 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46676 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46677 new_path=`$CYGPATH -u "$path"` 46678 fi 46679 if test "x$new_path" = x; then 46680 # It's still not found. Now this is an unrecoverable error. 46681 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&5 46682 $as_echo "$as_me: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 46683 has_space=`$ECHO "$complete" | $GREP " "` 46684 if test "x$has_space" != x; then 46685 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 46686 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 46687 fi 46688 as_fn_error $? "Cannot locate the the path of BUILD_OBJCOPY" "$LINENO" 5 46689 fi 46690 fi 46691 46692 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 46693 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 46694 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 46695 # "foo.exe" is OK but "foo" is an error. 46696 # 46697 # This test is therefore slightly more accurate than "test -f" to check for file presence. 46698 # It is also a way to make sure we got the proper file name for the real test later on. 46699 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 46700 if test "x$test_shortpath" = x; then 46701 # Short path failed, file does not exist as specified. 46702 # Try adding .exe or .cmd 46703 if test -f "${new_path}.exe"; then 46704 input_to_shortpath="${new_path}.exe" 46705 elif test -f "${new_path}.cmd"; then 46706 input_to_shortpath="${new_path}.cmd" 46707 else 46708 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_OBJCOPY, which resolves as \"$new_path\", is invalid." >&5 46709 $as_echo "$as_me: The path of BUILD_OBJCOPY, which resolves as \"$new_path\", is invalid." >&6;} 46710 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 46711 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 46712 as_fn_error $? "Cannot locate the the path of BUILD_OBJCOPY" "$LINENO" 5 46713 fi 46714 else 46715 input_to_shortpath="$new_path" 46716 fi 46717 46718 # Call helper function which possibly converts this using DOS-style short mode. 46719 # If so, the updated path is stored in $new_path. 46720 new_path="$input_to_shortpath" 46721 46722 input_path="$input_to_shortpath" 46723 # Check if we need to convert this using DOS-style short mode. If the path 46724 # contains just simple characters, use it. Otherwise (spaces, weird characters), 46725 # take no chances and rewrite it. 46726 # Note: m4 eats our [], so we need to use [ and ] instead. 46727 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 46728 if test "x$has_forbidden_chars" != x; then 46729 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 46730 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 46731 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 46732 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 46733 # Going to short mode and back again did indeed matter. Since short mode is 46734 # case insensitive, let's make it lowercase to improve readability. 46735 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 46736 # Now convert it back to Unix-style (cygpath) 46737 input_path=`$CYGPATH -u "$shortmode_path"` 46738 new_path="$input_path" 46739 fi 46740 fi 46741 46742 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 46743 if test "x$test_cygdrive_prefix" = x; then 46744 # As a simple fix, exclude /usr/bin since it's not a real path. 46745 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 46746 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 46747 # a path prefixed by /cygdrive for fixpath to work. 46748 new_path="$CYGWIN_ROOT_PATH$input_path" 46749 fi 46750 fi 46751 46752 # remove trailing .exe if any 46753 new_path="${new_path/%.exe/}" 46754 46755 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46756 46757 # First separate the path from the arguments. This will split at the first 46758 # space. 46759 complete="$BUILD_OBJCOPY" 46760 path="${complete%% *}" 46761 tmp="$complete EOL" 46762 arguments="${tmp#* }" 46763 46764 # Input might be given as Windows format, start by converting to 46765 # unix format. 46766 new_path="$path" 46767 46768 windows_path="$new_path" 46769 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46770 unix_path=`$CYGPATH -u "$windows_path"` 46771 new_path="$unix_path" 46772 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46773 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46774 new_path="$unix_path" 46775 fi 46776 46777 46778 # Now try to locate executable using which 46779 new_path=`$WHICH "$new_path" 2> /dev/null` 46780 46781 if test "x$new_path" = x; then 46782 # Oops. Which didn't find the executable. 46783 # The splitting of arguments from the executable at a space might have been incorrect, 46784 # since paths with space are more likely in Windows. Give it another try with the whole 46785 # argument. 46786 path="$complete" 46787 arguments="EOL" 46788 new_path="$path" 46789 46790 windows_path="$new_path" 46791 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46792 unix_path=`$CYGPATH -u "$windows_path"` 46793 new_path="$unix_path" 46794 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46795 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46796 new_path="$unix_path" 46797 fi 46798 46799 46800 new_path=`$WHICH "$new_path" 2> /dev/null` 46801 # bat and cmd files are not always considered executable in MSYS causing which 46802 # to not find them 46803 if test "x$new_path" = x \ 46804 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46805 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46806 new_path="$path" 46807 46808 windows_path="$new_path" 46809 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46810 unix_path=`$CYGPATH -u "$windows_path"` 46811 new_path="$unix_path" 46812 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46813 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46814 new_path="$unix_path" 46815 fi 46816 46817 fi 46818 46819 if test "x$new_path" = x; then 46820 # It's still not found. Now this is an unrecoverable error. 46821 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&5 46822 $as_echo "$as_me: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 46823 has_space=`$ECHO "$complete" | $GREP " "` 46824 if test "x$has_space" != x; then 46825 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 46826 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 46827 fi 46828 as_fn_error $? "Cannot locate the the path of BUILD_OBJCOPY" "$LINENO" 5 46829 fi 46830 fi 46831 46832 # Now new_path has a complete unix path to the binary 46833 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 46834 # Keep paths in /bin as-is, but remove trailing .exe if any 46835 new_path="${new_path/%.exe/}" 46836 # Do not save /bin paths to all_fixpath_prefixes! 46837 else 46838 # Not in mixed or Windows style, start by that. 46839 new_path=`cmd //c echo $new_path` 46840 46841 input_path="$new_path" 46842 # Check if we need to convert this using DOS-style short mode. If the path 46843 # contains just simple characters, use it. Otherwise (spaces, weird characters), 46844 # take no chances and rewrite it. 46845 # Note: m4 eats our [], so we need to use [ and ] instead. 46846 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 46847 if test "x$has_forbidden_chars" != x; then 46848 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 46849 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 46850 fi 46851 46852 # Output is in $new_path 46853 46854 windows_path="$new_path" 46855 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46856 unix_path=`$CYGPATH -u "$windows_path"` 46857 new_path="$unix_path" 46858 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46859 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46860 new_path="$unix_path" 46861 fi 46862 46863 # remove trailing .exe if any 46864 new_path="${new_path/%.exe/}" 46865 46866 # Save the first 10 bytes of this path to the storage, so fixpath can work. 46867 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 46868 fi 46869 46870 else 46871 # We're on a unix platform. Hooray! :) 46872 # First separate the path from the arguments. This will split at the first 46873 # space. 46874 complete="$BUILD_OBJCOPY" 46875 path="${complete%% *}" 46876 tmp="$complete EOL" 46877 arguments="${tmp#* }" 46878 46879 # Cannot rely on the command "which" here since it doesn't always work. 46880 is_absolute_path=`$ECHO "$path" | $GREP ^/` 46881 if test -z "$is_absolute_path"; then 46882 # Path to executable is not absolute. Find it. 46883 IFS_save="$IFS" 46884 IFS=: 46885 for p in $PATH; do 46886 if test -f "$p/$path" && test -x "$p/$path"; then 46887 new_path="$p/$path" 46888 break 46889 fi 46890 done 46891 IFS="$IFS_save" 46892 else 46893 # This is an absolute path, we can use it without further modifications. 46894 new_path="$path" 46895 fi 46896 46897 if test "x$new_path" = x; then 46898 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&5 46899 $as_echo "$as_me: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 46900 has_space=`$ECHO "$complete" | $GREP " "` 46901 if test "x$has_space" != x; then 46902 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 46903 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 46904 fi 46905 as_fn_error $? "Cannot locate the the path of BUILD_OBJCOPY" "$LINENO" 5 46906 fi 46907 fi 46908 46909 # Now join together the path and the arguments once again 46910 if test "x$arguments" != xEOL; then 46911 new_complete="$new_path ${arguments% *}" 46912 else 46913 new_complete="$new_path" 46914 fi 46915 46916 if test "x$complete" != "x$new_complete"; then 46917 BUILD_OBJCOPY="$new_complete" 46918 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_OBJCOPY to \"$new_complete\"" >&5 46919 $as_echo "$as_me: Rewriting BUILD_OBJCOPY to \"$new_complete\"" >&6;} 46920 fi 46921 fi 46922 46923 46924 46925 # Publish this variable in the help. 46926 46927 46928 if [ -z "${BUILD_STRIP+x}" ]; then 46929 # The variable is not set by user, try to locate tool using the code snippet 46930 for ac_prog in strip 46931 do 46932 # Extract the first word of "$ac_prog", so it can be a program name with args. 46933 set dummy $ac_prog; ac_word=$2 46934 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 46935 $as_echo_n "checking for $ac_word... " >&6; } 46936 if ${ac_cv_path_BUILD_STRIP+:} false; then : 46937 $as_echo_n "(cached) " >&6 46938 else 46939 case $BUILD_STRIP in 46940 [\\/]* | ?:[\\/]*) 46941 ac_cv_path_BUILD_STRIP="$BUILD_STRIP" # Let the user override the test with a path. 46942 ;; 46943 *) 46944 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46945 for as_dir in $PATH 46946 do 46947 IFS=$as_save_IFS 46948 test -z "$as_dir" && as_dir=. 46949 for ac_exec_ext in '' $ac_executable_extensions; do 46950 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46951 ac_cv_path_BUILD_STRIP="$as_dir/$ac_word$ac_exec_ext" 46952 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46953 break 2 46954 fi 46955 done 46956 done 46957 IFS=$as_save_IFS 46958 46959 ;; 46960 esac 46961 fi 46962 BUILD_STRIP=$ac_cv_path_BUILD_STRIP 46963 if test -n "$BUILD_STRIP"; then 46964 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_STRIP" >&5 46965 $as_echo "$BUILD_STRIP" >&6; } 46966 else 46967 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46968 $as_echo "no" >&6; } 46969 fi 46970 46971 46972 test -n "$BUILD_STRIP" && break 46973 done 46974 46975 else 46976 # The variable is set, but is it from the command line or the environment? 46977 46978 # Try to remove the string !BUILD_STRIP! from our list. 46979 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_STRIP!/} 46980 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 46981 # If it failed, the variable was not from the command line. Ignore it, 46982 # but warn the user (except for BASH, which is always set by the calling BASH). 46983 if test "xBUILD_STRIP" != xBASH; then 46984 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_STRIP from the environment. Use command line variables instead." >&5 46985 $as_echo "$as_me: WARNING: Ignoring value of BUILD_STRIP from the environment. Use command line variables instead." >&2;} 46986 fi 46987 # Try to locate tool using the code snippet 46988 for ac_prog in strip 46989 do 46990 # Extract the first word of "$ac_prog", so it can be a program name with args. 46991 set dummy $ac_prog; ac_word=$2 46992 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 46993 $as_echo_n "checking for $ac_word... " >&6; } 46994 if ${ac_cv_path_BUILD_STRIP+:} false; then : 46995 $as_echo_n "(cached) " >&6 46996 else 46997 case $BUILD_STRIP in 46998 [\\/]* | ?:[\\/]*) 46999 ac_cv_path_BUILD_STRIP="$BUILD_STRIP" # Let the user override the test with a path. 47000 ;; 47001 *) 47002 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 47003 for as_dir in $PATH 47004 do 47005 IFS=$as_save_IFS 47006 test -z "$as_dir" && as_dir=. 47007 for ac_exec_ext in '' $ac_executable_extensions; do 47008 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 47009 ac_cv_path_BUILD_STRIP="$as_dir/$ac_word$ac_exec_ext" 47010 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 47011 break 2 47012 fi 47013 done 47014 done 47015 IFS=$as_save_IFS 47016 47017 ;; 47018 esac 47019 fi 47020 BUILD_STRIP=$ac_cv_path_BUILD_STRIP 47021 if test -n "$BUILD_STRIP"; then 47022 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_STRIP" >&5 47023 $as_echo "$BUILD_STRIP" >&6; } 47024 else 47025 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 47026 $as_echo "no" >&6; } 47027 fi 47028 47029 47030 test -n "$BUILD_STRIP" && break 47031 done 47032 47033 else 47034 # If it succeeded, then it was overridden by the user. We will use it 47035 # for the tool. 47036 47037 # First remove it from the list of overridden variables, so we can test 47038 # for unknown variables in the end. 47039 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 47040 47041 # Check if we try to supply an empty value 47042 if test "x$BUILD_STRIP" = x; then 47043 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_STRIP= (no value)" >&5 47044 $as_echo "$as_me: Setting user supplied tool BUILD_STRIP= (no value)" >&6;} 47045 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_STRIP" >&5 47046 $as_echo_n "checking for BUILD_STRIP... " >&6; } 47047 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 47048 $as_echo "disabled" >&6; } 47049 else 47050 # Check if the provided tool contains a complete path. 47051 tool_specified="$BUILD_STRIP" 47052 tool_basename="${tool_specified##*/}" 47053 if test "x$tool_basename" = "x$tool_specified"; then 47054 # A command without a complete path is provided, search $PATH. 47055 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_STRIP=$tool_basename" >&5 47056 $as_echo "$as_me: Will search for user supplied tool BUILD_STRIP=$tool_basename" >&6;} 47057 # Extract the first word of "$tool_basename", so it can be a program name with args. 47058 set dummy $tool_basename; ac_word=$2 47059 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 47060 $as_echo_n "checking for $ac_word... " >&6; } 47061 if ${ac_cv_path_BUILD_STRIP+:} false; then : 47062 $as_echo_n "(cached) " >&6 47063 else 47064 case $BUILD_STRIP in 47065 [\\/]* | ?:[\\/]*) 47066 ac_cv_path_BUILD_STRIP="$BUILD_STRIP" # Let the user override the test with a path. 47067 ;; 47068 *) 47069 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 47070 for as_dir in $PATH 47071 do 47072 IFS=$as_save_IFS 47073 test -z "$as_dir" && as_dir=. 47074 for ac_exec_ext in '' $ac_executable_extensions; do 47075 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 47076 ac_cv_path_BUILD_STRIP="$as_dir/$ac_word$ac_exec_ext" 47077 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 47078 break 2 47079 fi 47080 done 47081 done 47082 IFS=$as_save_IFS 47083 47084 ;; 47085 esac 47086 fi 47087 BUILD_STRIP=$ac_cv_path_BUILD_STRIP 47088 if test -n "$BUILD_STRIP"; then 47089 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_STRIP" >&5 47090 $as_echo "$BUILD_STRIP" >&6; } 47091 else 47092 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 47093 $as_echo "no" >&6; } 47094 fi 47095 47096 47097 if test "x$BUILD_STRIP" = x; then 47098 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 47099 fi 47100 else 47101 # Otherwise we believe it is a complete path. Use it as it is. 47102 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_STRIP=$tool_specified" >&5 47103 $as_echo "$as_me: Will use user supplied tool BUILD_STRIP=$tool_specified" >&6;} 47104 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_STRIP" >&5 47105 $as_echo_n "checking for BUILD_STRIP... " >&6; } 47106 if test ! -x "$tool_specified"; then 47107 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 47108 $as_echo "not found" >&6; } 47109 as_fn_error $? "User supplied tool BUILD_STRIP=$tool_specified does not exist or is not executable" "$LINENO" 5 47110 fi 47111 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 47112 $as_echo "$tool_specified" >&6; } 47113 fi 47114 fi 47115 fi 47116 47117 fi 47118 47119 47120 47121 # Only process if variable expands to non-empty 47122 47123 if test "x$BUILD_STRIP" != x; then 47124 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47125 47126 # First separate the path from the arguments. This will split at the first 47127 # space. 47128 complete="$BUILD_STRIP" 47129 path="${complete%% *}" 47130 tmp="$complete EOL" 47131 arguments="${tmp#* }" 47132 47133 # Input might be given as Windows format, start by converting to 47134 # unix format. 47135 new_path=`$CYGPATH -u "$path"` 47136 47137 # Now try to locate executable using which 47138 new_path=`$WHICH "$new_path" 2> /dev/null` 47139 # bat and cmd files are not always considered executable in cygwin causing which 47140 # to not find them 47141 if test "x$new_path" = x \ 47142 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 47143 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 47144 new_path=`$CYGPATH -u "$path"` 47145 fi 47146 if test "x$new_path" = x; then 47147 # Oops. Which didn't find the executable. 47148 # The splitting of arguments from the executable at a space might have been incorrect, 47149 # since paths with space are more likely in Windows. Give it another try with the whole 47150 # argument. 47151 path="$complete" 47152 arguments="EOL" 47153 new_path=`$CYGPATH -u "$path"` 47154 new_path=`$WHICH "$new_path" 2> /dev/null` 47155 # bat and cmd files are not always considered executable in cygwin causing which 47156 # to not find them 47157 if test "x$new_path" = x \ 47158 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 47159 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 47160 new_path=`$CYGPATH -u "$path"` 47161 fi 47162 if test "x$new_path" = x; then 47163 # It's still not found. Now this is an unrecoverable error. 47164 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&5 47165 $as_echo "$as_me: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&6;} 47166 has_space=`$ECHO "$complete" | $GREP " "` 47167 if test "x$has_space" != x; then 47168 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 47169 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 47170 fi 47171 as_fn_error $? "Cannot locate the the path of BUILD_STRIP" "$LINENO" 5 47172 fi 47173 fi 47174 47175 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 47176 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 47177 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 47178 # "foo.exe" is OK but "foo" is an error. 47179 # 47180 # This test is therefore slightly more accurate than "test -f" to check for file presence. 47181 # It is also a way to make sure we got the proper file name for the real test later on. 47182 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 47183 if test "x$test_shortpath" = x; then 47184 # Short path failed, file does not exist as specified. 47185 # Try adding .exe or .cmd 47186 if test -f "${new_path}.exe"; then 47187 input_to_shortpath="${new_path}.exe" 47188 elif test -f "${new_path}.cmd"; then 47189 input_to_shortpath="${new_path}.cmd" 47190 else 47191 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_STRIP, which resolves as \"$new_path\", is invalid." >&5 47192 $as_echo "$as_me: The path of BUILD_STRIP, which resolves as \"$new_path\", is invalid." >&6;} 47193 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 47194 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 47195 as_fn_error $? "Cannot locate the the path of BUILD_STRIP" "$LINENO" 5 47196 fi 47197 else 47198 input_to_shortpath="$new_path" 47199 fi 47200 47201 # Call helper function which possibly converts this using DOS-style short mode. 47202 # If so, the updated path is stored in $new_path. 47203 new_path="$input_to_shortpath" 47204 47205 input_path="$input_to_shortpath" 47206 # Check if we need to convert this using DOS-style short mode. If the path 47207 # contains just simple characters, use it. Otherwise (spaces, weird characters), 47208 # take no chances and rewrite it. 47209 # Note: m4 eats our [], so we need to use [ and ] instead. 47210 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 47211 if test "x$has_forbidden_chars" != x; then 47212 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 47213 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 47214 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 47215 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 47216 # Going to short mode and back again did indeed matter. Since short mode is 47217 # case insensitive, let's make it lowercase to improve readability. 47218 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 47219 # Now convert it back to Unix-style (cygpath) 47220 input_path=`$CYGPATH -u "$shortmode_path"` 47221 new_path="$input_path" 47222 fi 47223 fi 47224 47225 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 47226 if test "x$test_cygdrive_prefix" = x; then 47227 # As a simple fix, exclude /usr/bin since it's not a real path. 47228 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 47229 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 47230 # a path prefixed by /cygdrive for fixpath to work. 47231 new_path="$CYGWIN_ROOT_PATH$input_path" 47232 fi 47233 fi 47234 47235 # remove trailing .exe if any 47236 new_path="${new_path/%.exe/}" 47237 47238 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47239 47240 # First separate the path from the arguments. This will split at the first 47241 # space. 47242 complete="$BUILD_STRIP" 47243 path="${complete%% *}" 47244 tmp="$complete EOL" 47245 arguments="${tmp#* }" 47246 47247 # Input might be given as Windows format, start by converting to 47248 # unix format. 47249 new_path="$path" 47250 47251 windows_path="$new_path" 47252 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47253 unix_path=`$CYGPATH -u "$windows_path"` 47254 new_path="$unix_path" 47255 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47256 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 47257 new_path="$unix_path" 47258 fi 47259 47260 47261 # Now try to locate executable using which 47262 new_path=`$WHICH "$new_path" 2> /dev/null` 47263 47264 if test "x$new_path" = x; then 47265 # Oops. Which didn't find the executable. 47266 # The splitting of arguments from the executable at a space might have been incorrect, 47267 # since paths with space are more likely in Windows. Give it another try with the whole 47268 # argument. 47269 path="$complete" 47270 arguments="EOL" 47271 new_path="$path" 47272 47273 windows_path="$new_path" 47274 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47275 unix_path=`$CYGPATH -u "$windows_path"` 47276 new_path="$unix_path" 47277 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47278 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 47279 new_path="$unix_path" 47280 fi 47281 47282 47283 new_path=`$WHICH "$new_path" 2> /dev/null` 47284 # bat and cmd files are not always considered executable in MSYS causing which 47285 # to not find them 47286 if test "x$new_path" = x \ 47287 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 47288 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 47289 new_path="$path" 47290 47291 windows_path="$new_path" 47292 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47293 unix_path=`$CYGPATH -u "$windows_path"` 47294 new_path="$unix_path" 47295 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47296 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 47297 new_path="$unix_path" 47298 fi 47299 47300 fi 47301 47302 if test "x$new_path" = x; then 47303 # It's still not found. Now this is an unrecoverable error. 47304 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&5 47305 $as_echo "$as_me: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&6;} 47306 has_space=`$ECHO "$complete" | $GREP " "` 47307 if test "x$has_space" != x; then 47308 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 47309 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 47310 fi 47311 as_fn_error $? "Cannot locate the the path of BUILD_STRIP" "$LINENO" 5 47312 fi 47313 fi 47314 47315 # Now new_path has a complete unix path to the binary 47316 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 47317 # Keep paths in /bin as-is, but remove trailing .exe if any 47318 new_path="${new_path/%.exe/}" 47319 # Do not save /bin paths to all_fixpath_prefixes! 47320 else 47321 # Not in mixed or Windows style, start by that. 47322 new_path=`cmd //c echo $new_path` 47323 47324 input_path="$new_path" 47325 # Check if we need to convert this using DOS-style short mode. If the path 47326 # contains just simple characters, use it. Otherwise (spaces, weird characters), 47327 # take no chances and rewrite it. 47328 # Note: m4 eats our [], so we need to use [ and ] instead. 47329 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 47330 if test "x$has_forbidden_chars" != x; then 47331 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 47332 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 47333 fi 47334 47335 # Output is in $new_path 47336 47337 windows_path="$new_path" 47338 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47339 unix_path=`$CYGPATH -u "$windows_path"` 47340 new_path="$unix_path" 47341 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47342 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 47343 new_path="$unix_path" 47344 fi 47345 47346 # remove trailing .exe if any 47347 new_path="${new_path/%.exe/}" 47348 47349 # Save the first 10 bytes of this path to the storage, so fixpath can work. 47350 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 47351 fi 47352 47353 else 47354 # We're on a unix platform. Hooray! :) 47355 # First separate the path from the arguments. This will split at the first 47356 # space. 47357 complete="$BUILD_STRIP" 47358 path="${complete%% *}" 47359 tmp="$complete EOL" 47360 arguments="${tmp#* }" 47361 47362 # Cannot rely on the command "which" here since it doesn't always work. 47363 is_absolute_path=`$ECHO "$path" | $GREP ^/` 47364 if test -z "$is_absolute_path"; then 47365 # Path to executable is not absolute. Find it. 47366 IFS_save="$IFS" 47367 IFS=: 47368 for p in $PATH; do 47369 if test -f "$p/$path" && test -x "$p/$path"; then 47370 new_path="$p/$path" 47371 break 47372 fi 47373 done 47374 IFS="$IFS_save" 47375 else 47376 # This is an absolute path, we can use it without further modifications. 47377 new_path="$path" 47378 fi 47379 47380 if test "x$new_path" = x; then 47381 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&5 47382 $as_echo "$as_me: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&6;} 47383 has_space=`$ECHO "$complete" | $GREP " "` 47384 if test "x$has_space" != x; then 47385 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 47386 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 47387 fi 47388 as_fn_error $? "Cannot locate the the path of BUILD_STRIP" "$LINENO" 5 47389 fi 47390 fi 47391 47392 # Now join together the path and the arguments once again 47393 if test "x$arguments" != xEOL; then 47394 new_complete="$new_path ${arguments% *}" 47395 else 47396 new_complete="$new_path" 47397 fi 47398 47399 if test "x$complete" != "x$new_complete"; then 47400 BUILD_STRIP="$new_complete" 47401 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_STRIP to \"$new_complete\"" >&5 47402 $as_echo "$as_me: Rewriting BUILD_STRIP to \"$new_complete\"" >&6;} 47403 fi 47404 fi 47405 47406 # Assume the C compiler is the assembler 47407 BUILD_AS="$BUILD_CC -c" 47408 # Just like for the target compiler, use the compiler as linker 47409 BUILD_LD="$BUILD_CC" 47410 BUILD_LDCXX="$BUILD_CXX" 47411 47412 PATH="$OLDPATH" 47413 47414 47415 COMPILER=$BUILD_CC 47416 COMPILER_NAME=BuildC 47417 47418 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 47419 # cc -V output typically looks like 47420 # cc: Sun C 5.12 Linux_i386 2011/11/16 47421 # or 47422 # cc: Studio 12.5 Sun C 5.14 SunOS_sparc 2016/05/31 47423 COMPILER_VERSION_OUTPUT=`$COMPILER -V 2>&1` 47424 # Check that this is likely to be the Solaris Studio cc. 47425 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "^.* Sun $COMPILER_NAME" > /dev/null 47426 if test $? -ne 0; then 47427 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 47428 { $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 47429 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47430 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&5 47431 $as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 47432 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 47433 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 47434 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47435 fi 47436 # Remove usage instructions (if present), and 47437 # collapse compiler output into a single line 47438 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47439 $SED -e 's/ *[Uu]sage:.*//'` 47440 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47441 $SED -e "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/"` 47442 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 47443 # xlc -qversion output typically looks like 47444 # IBM XL C/C++ for AIX, V11.1 (5724-X13) 47445 # Version: 11.01.0000.0015 47446 COMPILER_VERSION_OUTPUT=`$COMPILER -qversion 2>&1` 47447 # Check that this is likely to be the IBM XL C compiler. 47448 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "IBM XL C" > /dev/null 47449 if test $? -ne 0; then 47450 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 47451 { $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 47452 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47453 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&5 47454 $as_echo "$as_me: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 47455 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 47456 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 47457 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47458 fi 47459 # Collapse compiler output into a single line 47460 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 47461 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47462 $SED -e 's/^.*, V\([1-9][0-9.]*\).*$/\1/'` 47463 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 47464 # There is no specific version flag, but all output starts with a version string. 47465 # First line typically looks something like: 47466 # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86 47467 COMPILER_VERSION_OUTPUT=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'` 47468 # Check that this is likely to be Microsoft CL.EXE. 47469 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Microsoft.*Compiler" > /dev/null 47470 if test $? -ne 0; then 47471 { $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 47472 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47473 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&5 47474 $as_echo "$as_me: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 47475 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47476 fi 47477 # Collapse compiler output into a single line 47478 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 47479 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47480 $SED -e 's/^.*ersion.\([1-9][0-9.]*\) .*$/\1/'` 47481 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 47482 # gcc --version output typically looks like 47483 # gcc (Ubuntu/Linaro 4.8.1-10ubuntu9) 4.8.1 47484 # Copyright (C) 2013 Free Software Foundation, Inc. 47485 # This is free software; see the source for copying conditions. There is NO 47486 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 47487 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 47488 # Check that this is likely to be GCC. 47489 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Free Software Foundation" > /dev/null 47490 if test $? -ne 0; then 47491 { $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 47492 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47493 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION\"" >&5 47494 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION\"" >&6;} 47495 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47496 fi 47497 # Remove Copyright and legalese from version string, and 47498 # collapse into a single line 47499 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47500 $SED -e 's/ *Copyright .*//'` 47501 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47502 $SED -e 's/^.* \([1-9]\.[0-9.]*\)[^0-9.].*$/\1/'` 47503 elif test "x$TOOLCHAIN_TYPE" = xclang; then 47504 # clang --version output typically looks like 47505 # Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn) 47506 # clang version 3.3 (tags/RELEASE_33/final) 47507 # or 47508 # Debian clang version 3.2-7ubuntu1 (tags/RELEASE_32/final) (based on LLVM 3.2) 47509 # Target: x86_64-pc-linux-gnu 47510 # Thread model: posix 47511 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 47512 # Check that this is likely to be clang 47513 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "clang" > /dev/null 47514 if test $? -ne 0; then 47515 { $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 47516 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47517 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&5 47518 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 47519 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47520 fi 47521 # Collapse compiler output into a single line 47522 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 47523 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47524 $SED -e 's/^.* version \([1-9][0-9.]*\).*$/\1/'` 47525 else 47526 as_fn_error $? "Unknown toolchain type $TOOLCHAIN_TYPE." "$LINENO" 5 47527 fi 47528 # This sets CC_VERSION_NUMBER or CXX_VERSION_NUMBER. (This comment is a grep marker) 47529 BUILD_CC_VERSION_NUMBER="$COMPILER_VERSION_NUMBER" 47530 # This sets CC_VERSION_STRING or CXX_VERSION_STRING. (This comment is a grep marker) 47531 BUILD_CC_VERSION_STRING="$COMPILER_VERSION_STRING" 47532 47533 { $as_echo "$as_me:${as_lineno-$LINENO}: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&5 47534 $as_echo "$as_me: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&6;} 47535 47536 47537 COMPILER=$BUILD_CXX 47538 COMPILER_NAME=BuildC++ 47539 47540 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 47541 # cc -V output typically looks like 47542 # cc: Sun C 5.12 Linux_i386 2011/11/16 47543 # or 47544 # cc: Studio 12.5 Sun C 5.14 SunOS_sparc 2016/05/31 47545 COMPILER_VERSION_OUTPUT=`$COMPILER -V 2>&1` 47546 # Check that this is likely to be the Solaris Studio cc. 47547 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "^.* Sun $COMPILER_NAME" > /dev/null 47548 if test $? -ne 0; then 47549 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 47550 { $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 47551 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47552 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&5 47553 $as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 47554 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 47555 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 47556 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47557 fi 47558 # Remove usage instructions (if present), and 47559 # collapse compiler output into a single line 47560 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47561 $SED -e 's/ *[Uu]sage:.*//'` 47562 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47563 $SED -e "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/"` 47564 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 47565 # xlc -qversion output typically looks like 47566 # IBM XL C/C++ for AIX, V11.1 (5724-X13) 47567 # Version: 11.01.0000.0015 47568 COMPILER_VERSION_OUTPUT=`$COMPILER -qversion 2>&1` 47569 # Check that this is likely to be the IBM XL C compiler. 47570 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "IBM XL C" > /dev/null 47571 if test $? -ne 0; then 47572 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 47573 { $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 47574 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47575 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&5 47576 $as_echo "$as_me: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 47577 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 47578 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 47579 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47580 fi 47581 # Collapse compiler output into a single line 47582 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 47583 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47584 $SED -e 's/^.*, V\([1-9][0-9.]*\).*$/\1/'` 47585 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 47586 # There is no specific version flag, but all output starts with a version string. 47587 # First line typically looks something like: 47588 # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86 47589 COMPILER_VERSION_OUTPUT=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'` 47590 # Check that this is likely to be Microsoft CL.EXE. 47591 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Microsoft.*Compiler" > /dev/null 47592 if test $? -ne 0; then 47593 { $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 47594 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47595 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&5 47596 $as_echo "$as_me: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 47597 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47598 fi 47599 # Collapse compiler output into a single line 47600 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 47601 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47602 $SED -e 's/^.*ersion.\([1-9][0-9.]*\) .*$/\1/'` 47603 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 47604 # gcc --version output typically looks like 47605 # gcc (Ubuntu/Linaro 4.8.1-10ubuntu9) 4.8.1 47606 # Copyright (C) 2013 Free Software Foundation, Inc. 47607 # This is free software; see the source for copying conditions. There is NO 47608 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 47609 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 47610 # Check that this is likely to be GCC. 47611 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Free Software Foundation" > /dev/null 47612 if test $? -ne 0; then 47613 { $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 47614 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47615 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION\"" >&5 47616 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION\"" >&6;} 47617 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47618 fi 47619 # Remove Copyright and legalese from version string, and 47620 # collapse into a single line 47621 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47622 $SED -e 's/ *Copyright .*//'` 47623 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47624 $SED -e 's/^.* \([1-9]\.[0-9.]*\)[^0-9.].*$/\1/'` 47625 elif test "x$TOOLCHAIN_TYPE" = xclang; then 47626 # clang --version output typically looks like 47627 # Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn) 47628 # clang version 3.3 (tags/RELEASE_33/final) 47629 # or 47630 # Debian clang version 3.2-7ubuntu1 (tags/RELEASE_32/final) (based on LLVM 3.2) 47631 # Target: x86_64-pc-linux-gnu 47632 # Thread model: posix 47633 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 47634 # Check that this is likely to be clang 47635 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "clang" > /dev/null 47636 if test $? -ne 0; then 47637 { $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 47638 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47639 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&5 47640 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 47641 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47642 fi 47643 # Collapse compiler output into a single line 47644 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 47645 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47646 $SED -e 's/^.* version \([1-9][0-9.]*\).*$/\1/'` 47647 else 47648 as_fn_error $? "Unknown toolchain type $TOOLCHAIN_TYPE." "$LINENO" 5 47649 fi 47650 # This sets CC_VERSION_NUMBER or CXX_VERSION_NUMBER. (This comment is a grep marker) 47651 BUILD_CXX_VERSION_NUMBER="$COMPILER_VERSION_NUMBER" 47652 # This sets CC_VERSION_STRING or CXX_VERSION_STRING. (This comment is a grep marker) 47653 BUILD_CXX_VERSION_STRING="$COMPILER_VERSION_STRING" 47654 47655 { $as_echo "$as_me:${as_lineno-$LINENO}: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&5 47656 $as_echo "$as_me: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&6;} 47657 47658 47659 if test "x$BUILD_CC_VERSION_NUMBER" != "x$BUILD_CXX_VERSION_NUMBER"; then 47660 { $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 47661 $as_echo "$as_me: WARNING: C and C++ compiler have different version numbers, $BUILD_CC_VERSION_NUMBER vs $BUILD_CXX_VERSION_NUMBER." >&2;} 47662 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This typically indicates a broken setup, and is not supported" >&5 47663 $as_echo "$as_me: WARNING: This typically indicates a broken setup, and is not supported" >&2;} 47664 fi 47665 47666 # We only check CC_VERSION_NUMBER since we assume CXX_VERSION_NUMBER is equal. 47667 if [[ "[$]BUILD_CC_VERSION_NUMBER" =~ (.*\.){4} ]] ; then 47668 { $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 47669 $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;} 47670 fi 47671 47672 if [[ "[$]BUILD_CC_VERSION_NUMBER" =~ [0-9]{6} ]] ; then 47673 { $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 47674 $as_echo "$as_me: WARNING: C compiler version number has a part larger than 99999: $BUILD_CC_VERSION_NUMBER. Comparisons might be wrong." >&2;} 47675 fi 47676 47677 OPENJDK_BUILD_COMPARABLE_ACTUAL_VERSION=`$AWK -F. '{ printf("%05d%05d%05d%05d\n", $1, $2, $3, $4) }' <<< "$BUILD_CC_VERSION_NUMBER"` 47678 47679 else 47680 # If we are not cross compiling, use the normal target compilers for 47681 # building the build platform executables. 47682 BUILD_CC="$CC" 47683 BUILD_CXX="$CXX" 47684 BUILD_LD="$LD" 47685 BUILD_LDCXX="$LDCXX" 47686 BUILD_NM="$NM" 47687 BUILD_AS="$AS" 47688 BUILD_OBJCOPY="$OBJCOPY" 47689 BUILD_STRIP="$STRIP" 47690 BUILD_SYSROOT_CFLAGS="$SYSROOT_CFLAGS" 47691 BUILD_SYSROOT_LDFLAGS="$SYSROOT_LDFLAGS" 47692 BUILD_AR="$AR" 47693 47694 47695 if test "x$CC_VERSION_NUMBER" != "x$CXX_VERSION_NUMBER"; then 47696 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: C and C++ compiler have different version numbers, $CC_VERSION_NUMBER vs $CXX_VERSION_NUMBER." >&5 47697 $as_echo "$as_me: WARNING: C and C++ compiler have different version numbers, $CC_VERSION_NUMBER vs $CXX_VERSION_NUMBER." >&2;} 47698 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This typically indicates a broken setup, and is not supported" >&5 47699 $as_echo "$as_me: WARNING: This typically indicates a broken setup, and is not supported" >&2;} 47700 fi 47701 47702 # We only check CC_VERSION_NUMBER since we assume CXX_VERSION_NUMBER is equal. 47703 if [[ "[$]CC_VERSION_NUMBER" =~ (.*\.){4} ]] ; then 47704 { $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 47705 $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;} 47706 fi 47707 47708 if [[ "[$]CC_VERSION_NUMBER" =~ [0-9]{6} ]] ; then 47709 { $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 47710 $as_echo "$as_me: WARNING: C compiler version number has a part larger than 99999: $CC_VERSION_NUMBER. Comparisons might be wrong." >&2;} 47711 fi 47712 47713 OPENJDK_BUILD_COMPARABLE_ACTUAL_VERSION=`$AWK -F. '{ printf("%05d%05d%05d%05d\n", $1, $2, $3, $4) }' <<< "$CC_VERSION_NUMBER"` 47714 47715 fi 47716 47717 47718 47719 47720 47721 47722 47723 47724 47725 47726 47727 47728 47729 47730 # The package path is used only on macosx? 47731 # FIXME: clean this up, and/or move it elsewhere. 47732 PACKAGE_PATH=/opt/local 47733 47734 47735 # Check for extra potential brokenness. 47736 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 47737 # On Windows, double-check that we got the right compiler. 47738 CC_VERSION_OUTPUT=`$CC 2>&1 | $HEAD -n 1 | $TR -d '\r'` 47739 COMPILER_CPU_TEST=`$ECHO $CC_VERSION_OUTPUT | $SED -n "s/^.* \(.*\)$/\1/p"` 47740 if test "x$OPENJDK_TARGET_CPU" = "xx86"; then 47741 if test "x$COMPILER_CPU_TEST" != "x80x86" -a "x$COMPILER_CPU_TEST" != "xx86"; then 47742 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 47743 fi 47744 elif test "x$OPENJDK_TARGET_CPU" = "xx86_64"; then 47745 if test "x$COMPILER_CPU_TEST" != "xx64"; then 47746 as_fn_error $? "Target CPU mismatch. We are building for $OPENJDK_TARGET_CPU but CL is for \"$COMPILER_CPU_TEST\"; expected \"x64\"." "$LINENO" 5 47747 fi 47748 fi 47749 fi 47750 47751 if test "x$TOOLCHAIN_TYPE" = xgcc; then 47752 # If this is a --hash-style=gnu system, use --hash-style=both, why? 47753 HAS_GNU_HASH=`$CC -dumpspecs 2>/dev/null | $GREP 'hash-style=gnu'` 47754 # This is later checked when setting flags. 47755 47756 # "-Og" suppported for GCC 4.8 and later 47757 CFLAG_OPTIMIZE_DEBUG_FLAG="-Og" 47758 47759 47760 47761 47762 47763 47764 47765 47766 47767 47768 47769 47770 47771 47772 47773 47774 47775 47776 47777 47778 47779 47780 47781 47782 47783 47784 47785 47786 47787 47788 47789 47790 47791 47792 47793 47794 47795 47796 47797 47798 47799 47800 47801 47802 47803 47804 47805 # Execute function body 47806 47807 47808 47809 47810 47811 47812 47813 47814 47815 47816 47817 47818 47819 47820 47821 47822 47823 47824 47825 47826 47827 47828 47829 47830 47831 47832 47833 47834 47835 47836 47837 47838 47839 47840 47841 47842 47843 47844 47845 47846 47847 47848 47849 47850 47851 47852 47853 47854 # Execute function body 47855 47856 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler supports \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"" >&5 47857 $as_echo_n "checking if the C compiler supports \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"... " >&6; } 47858 supports=yes 47859 47860 saved_cflags="$CFLAGS" 47861 CFLAGS="$CFLAGS $CFLAG_OPTIMIZE_DEBUG_FLAG" 47862 ac_ext=c 47863 ac_cpp='$CPP $CPPFLAGS' 47864 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47865 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47866 ac_compiler_gnu=$ac_cv_c_compiler_gnu 47867 47868 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 47869 /* end confdefs.h. */ 47870 int i; 47871 _ACEOF 47872 if ac_fn_c_try_compile "$LINENO"; then : 47873 47874 else 47875 supports=no 47876 fi 47877 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 47878 ac_ext=cpp 47879 ac_cpp='$CXXCPP $CPPFLAGS' 47880 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47881 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47882 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 47883 47884 CFLAGS="$saved_cflags" 47885 47886 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 47887 $as_echo "$supports" >&6; } 47888 if test "x$supports" = "xyes" ; then 47889 : 47890 C_COMP_SUPPORTS="yes" 47891 else 47892 : 47893 C_COMP_SUPPORTS="no" 47894 fi 47895 47896 47897 47898 47899 47900 47901 47902 47903 47904 47905 47906 47907 47908 47909 47910 47911 47912 47913 47914 47915 47916 47917 47918 47919 47920 47921 47922 47923 47924 47925 47926 47927 47928 47929 47930 47931 47932 47933 47934 47935 47936 47937 47938 47939 47940 47941 47942 47943 47944 47945 47946 47947 47948 47949 47950 47951 47952 47953 47954 # Execute function body 47955 47956 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"" >&5 47957 $as_echo_n "checking if the C++ compiler supports \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"... " >&6; } 47958 supports=yes 47959 47960 saved_cxxflags="$CXXFLAGS" 47961 CXXFLAGS="$CXXFLAG $CFLAG_OPTIMIZE_DEBUG_FLAG" 47962 ac_ext=cpp 47963 ac_cpp='$CXXCPP $CPPFLAGS' 47964 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47965 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47966 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 47967 47968 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 47969 /* end confdefs.h. */ 47970 int i; 47971 _ACEOF 47972 if ac_fn_cxx_try_compile "$LINENO"; then : 47973 47974 else 47975 supports=no 47976 fi 47977 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 47978 ac_ext=cpp 47979 ac_cpp='$CXXCPP $CPPFLAGS' 47980 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47981 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47982 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 47983 47984 CXXFLAGS="$saved_cxxflags" 47985 47986 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 47987 $as_echo "$supports" >&6; } 47988 if test "x$supports" = "xyes" ; then 47989 : 47990 CXX_COMP_SUPPORTS="yes" 47991 else 47992 : 47993 CXX_COMP_SUPPORTS="no" 47994 fi 47995 47996 47997 47998 47999 48000 48001 48002 48003 48004 48005 48006 48007 48008 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"" >&5 48009 $as_echo_n "checking if both compilers support \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"... " >&6; } 48010 supports=no 48011 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 48012 48013 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 48014 $as_echo "$supports" >&6; } 48015 if test "x$supports" = "xyes" ; then 48016 : 48017 HAS_CFLAG_OPTIMIZE_DEBUG=true 48018 else 48019 : 48020 HAS_CFLAG_OPTIMIZE_DEBUG=false 48021 fi 48022 48023 48024 48025 48026 48027 48028 48029 # "-z relro" supported in GNU binutils 2.17 and later 48030 LINKER_RELRO_FLAG="-Wl,-z,relro" 48031 48032 48033 48034 48035 48036 48037 48038 48039 48040 48041 48042 48043 48044 48045 48046 48047 48048 48049 48050 48051 48052 48053 48054 48055 48056 48057 48058 48059 48060 48061 48062 48063 48064 48065 48066 48067 48068 48069 48070 48071 48072 48073 48074 48075 48076 48077 48078 # Execute function body 48079 48080 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if linker supports \"$LINKER_RELRO_FLAG\"" >&5 48081 $as_echo_n "checking if linker supports \"$LINKER_RELRO_FLAG\"... " >&6; } 48082 supports=yes 48083 48084 saved_ldflags="$LDFLAGS" 48085 LDFLAGS="$LDFLAGS $LINKER_RELRO_FLAG" 48086 ac_ext=c 48087 ac_cpp='$CPP $CPPFLAGS' 48088 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 48089 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 48090 ac_compiler_gnu=$ac_cv_c_compiler_gnu 48091 48092 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48093 /* end confdefs.h. */ 48094 48095 int 48096 main () 48097 { 48098 48099 ; 48100 return 0; 48101 } 48102 _ACEOF 48103 if ac_fn_c_try_link "$LINENO"; then : 48104 48105 else 48106 supports=no 48107 fi 48108 rm -f core conftest.err conftest.$ac_objext \ 48109 conftest$ac_exeext conftest.$ac_ext 48110 ac_ext=cpp 48111 ac_cpp='$CXXCPP $CPPFLAGS' 48112 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 48113 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 48114 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 48115 48116 LDFLAGS="$saved_ldflags" 48117 48118 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 48119 $as_echo "$supports" >&6; } 48120 if test "x$supports" = "xyes" ; then 48121 : 48122 HAS_LINKER_RELRO=true 48123 else 48124 : 48125 HAS_LINKER_RELRO=false 48126 fi 48127 48128 48129 48130 48131 48132 48133 48134 48135 48136 48137 48138 48139 48140 # "-z now" supported in GNU binutils 2.11 and later 48141 LINKER_NOW_FLAG="-Wl,-z,now" 48142 48143 48144 48145 48146 48147 48148 48149 48150 48151 48152 48153 48154 48155 48156 48157 48158 48159 48160 48161 48162 48163 48164 48165 48166 48167 48168 48169 48170 48171 48172 48173 48174 48175 48176 48177 48178 48179 48180 48181 48182 48183 48184 48185 48186 48187 48188 48189 # Execute function body 48190 48191 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if linker supports \"$LINKER_NOW_FLAG\"" >&5 48192 $as_echo_n "checking if linker supports \"$LINKER_NOW_FLAG\"... " >&6; } 48193 supports=yes 48194 48195 saved_ldflags="$LDFLAGS" 48196 LDFLAGS="$LDFLAGS $LINKER_NOW_FLAG" 48197 ac_ext=c 48198 ac_cpp='$CPP $CPPFLAGS' 48199 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 48200 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 48201 ac_compiler_gnu=$ac_cv_c_compiler_gnu 48202 48203 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48204 /* end confdefs.h. */ 48205 48206 int 48207 main () 48208 { 48209 48210 ; 48211 return 0; 48212 } 48213 _ACEOF 48214 if ac_fn_c_try_link "$LINENO"; then : 48215 48216 else 48217 supports=no 48218 fi 48219 rm -f core conftest.err conftest.$ac_objext \ 48220 conftest$ac_exeext conftest.$ac_ext 48221 ac_ext=cpp 48222 ac_cpp='$CXXCPP $CPPFLAGS' 48223 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 48224 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 48225 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 48226 48227 LDFLAGS="$saved_ldflags" 48228 48229 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 48230 $as_echo "$supports" >&6; } 48231 if test "x$supports" = "xyes" ; then 48232 : 48233 HAS_LINKER_NOW=true 48234 else 48235 : 48236 HAS_LINKER_NOW=false 48237 fi 48238 48239 48240 48241 48242 48243 48244 48245 48246 48247 48248 48249 48250 fi 48251 48252 # Check for broken SuSE 'ld' for which 'Only anonymous version tag is allowed 48253 # in executable.' 48254 USING_BROKEN_SUSE_LD=no 48255 if test "x$OPENJDK_TARGET_OS" = xlinux && test "x$TOOLCHAIN_TYPE" = xgcc; then 48256 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken SuSE 'ld' which only understands anonymous version tags in executables" >&5 48257 $as_echo_n "checking for broken SuSE 'ld' which only understands anonymous version tags in executables... " >&6; } 48258 $ECHO "SUNWprivate_1.1 { local: *; };" > version-script.map 48259 $ECHO "int main() { }" > main.c 48260 if $CXX -Wl,-version-script=version-script.map main.c 2>&5 >&5; then 48261 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 48262 $as_echo "no" >&6; } 48263 USING_BROKEN_SUSE_LD=no 48264 else 48265 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 48266 $as_echo "yes" >&6; } 48267 USING_BROKEN_SUSE_LD=yes 48268 fi 48269 $RM version-script.map main.c a.out 48270 fi 48271 48272 48273 # Setup hotspot lecagy names for toolchains 48274 HOTSPOT_TOOLCHAIN_TYPE=$TOOLCHAIN_TYPE 48275 if test "x$TOOLCHAIN_TYPE" = xclang; then 48276 HOTSPOT_TOOLCHAIN_TYPE=gcc 48277 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 48278 HOTSPOT_TOOLCHAIN_TYPE=sparcWorks 48279 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 48280 HOTSPOT_TOOLCHAIN_TYPE=visCPP 48281 fi 48282 48283 48284 48285 # Setup the JTReg Regression Test Harness. 48286 48287 48288 # Check whether --with-jtreg was given. 48289 if test "${with_jtreg+set}" = set; then : 48290 withval=$with_jtreg; 48291 else 48292 with_jtreg=no 48293 fi 48294 48295 48296 if test "x$with_jtreg" = xno; then 48297 # jtreg disabled 48298 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jtreg" >&5 48299 $as_echo_n "checking for jtreg... " >&6; } 48300 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 48301 $as_echo "no" >&6; } 48302 else 48303 if test "x$with_jtreg" != xyes; then 48304 # with path specified. 48305 JT_HOME="$with_jtreg" 48306 fi 48307 48308 if test "x$JT_HOME" != x; then 48309 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jtreg" >&5 48310 $as_echo_n "checking for jtreg... " >&6; } 48311 48312 # use JT_HOME enviroment var. 48313 48314 # Only process if variable expands to non-empty 48315 48316 if test "x$JT_HOME" != x; then 48317 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 48318 48319 # Input might be given as Windows format, start by converting to 48320 # unix format. 48321 path="$JT_HOME" 48322 new_path=`$CYGPATH -u "$path"` 48323 48324 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 48325 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 48326 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 48327 # "foo.exe" is OK but "foo" is an error. 48328 # 48329 # This test is therefore slightly more accurate than "test -f" to check for file precense. 48330 # It is also a way to make sure we got the proper file name for the real test later on. 48331 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 48332 if test "x$test_shortpath" = x; then 48333 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JT_HOME, which resolves as \"$path\", is invalid." >&5 48334 $as_echo "$as_me: The path of JT_HOME, which resolves as \"$path\", is invalid." >&6;} 48335 as_fn_error $? "Cannot locate the the path of JT_HOME" "$LINENO" 5 48336 fi 48337 48338 # Call helper function which possibly converts this using DOS-style short mode. 48339 # If so, the updated path is stored in $new_path. 48340 48341 input_path="$new_path" 48342 # Check if we need to convert this using DOS-style short mode. If the path 48343 # contains just simple characters, use it. Otherwise (spaces, weird characters), 48344 # take no chances and rewrite it. 48345 # Note: m4 eats our [], so we need to use [ and ] instead. 48346 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 48347 if test "x$has_forbidden_chars" != x; then 48348 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 48349 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 48350 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 48351 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 48352 # Going to short mode and back again did indeed matter. Since short mode is 48353 # case insensitive, let's make it lowercase to improve readability. 48354 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 48355 # Now convert it back to Unix-style (cygpath) 48356 input_path=`$CYGPATH -u "$shortmode_path"` 48357 new_path="$input_path" 48358 fi 48359 fi 48360 48361 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 48362 if test "x$test_cygdrive_prefix" = x; then 48363 # As a simple fix, exclude /usr/bin since it's not a real path. 48364 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 48365 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 48366 # a path prefixed by /cygdrive for fixpath to work. 48367 new_path="$CYGWIN_ROOT_PATH$input_path" 48368 fi 48369 fi 48370 48371 48372 if test "x$path" != "x$new_path"; then 48373 JT_HOME="$new_path" 48374 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JT_HOME to \"$new_path\"" >&5 48375 $as_echo "$as_me: Rewriting JT_HOME to \"$new_path\"" >&6;} 48376 fi 48377 48378 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 48379 48380 path="$JT_HOME" 48381 has_colon=`$ECHO $path | $GREP ^.:` 48382 new_path="$path" 48383 if test "x$has_colon" = x; then 48384 # Not in mixed or Windows style, start by that. 48385 new_path=`cmd //c echo $path` 48386 fi 48387 48388 48389 input_path="$new_path" 48390 # Check if we need to convert this using DOS-style short mode. If the path 48391 # contains just simple characters, use it. Otherwise (spaces, weird characters), 48392 # take no chances and rewrite it. 48393 # Note: m4 eats our [], so we need to use [ and ] instead. 48394 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 48395 if test "x$has_forbidden_chars" != x; then 48396 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 48397 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 48398 fi 48399 48400 48401 windows_path="$new_path" 48402 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 48403 unix_path=`$CYGPATH -u "$windows_path"` 48404 new_path="$unix_path" 48405 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 48406 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 48407 new_path="$unix_path" 48408 fi 48409 48410 if test "x$path" != "x$new_path"; then 48411 JT_HOME="$new_path" 48412 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JT_HOME to \"$new_path\"" >&5 48413 $as_echo "$as_me: Rewriting JT_HOME to \"$new_path\"" >&6;} 48414 fi 48415 48416 # Save the first 10 bytes of this path to the storage, so fixpath can work. 48417 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 48418 48419 else 48420 # We're on a unix platform. Hooray! :) 48421 path="$JT_HOME" 48422 has_space=`$ECHO "$path" | $GREP " "` 48423 if test "x$has_space" != x; then 48424 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JT_HOME, which resolves as \"$path\", is invalid." >&5 48425 $as_echo "$as_me: The path of JT_HOME, which resolves as \"$path\", is invalid." >&6;} 48426 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 48427 fi 48428 48429 # Use eval to expand a potential ~ 48430 eval path="$path" 48431 if test ! -f "$path" && test ! -d "$path"; then 48432 as_fn_error $? "The path of JT_HOME, which resolves as \"$path\", is not found." "$LINENO" 5 48433 fi 48434 48435 if test -d "$path"; then 48436 JT_HOME="`cd "$path"; $THEPWDCMD -L`" 48437 else 48438 dir="`$DIRNAME "$path"`" 48439 base="`$BASENAME "$path"`" 48440 JT_HOME="`cd "$dir"; $THEPWDCMD -L`/$base" 48441 fi 48442 fi 48443 fi 48444 48445 48446 # jtreg win32 script works for everybody 48447 JTREGEXE="$JT_HOME/bin/jtreg" 48448 48449 if test ! -f "$JTREGEXE"; then 48450 as_fn_error $? "JTReg executable does not exist: $JTREGEXE" "$LINENO" 5 48451 fi 48452 48453 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5 48454 $as_echo "$JTREGEXE" >&6; } 48455 else 48456 # try to find jtreg on path 48457 48458 48459 48460 # Publish this variable in the help. 48461 48462 48463 if [ -z "${JTREGEXE+x}" ]; then 48464 # The variable is not set by user, try to locate tool using the code snippet 48465 for ac_prog in jtreg 48466 do 48467 # Extract the first word of "$ac_prog", so it can be a program name with args. 48468 set dummy $ac_prog; ac_word=$2 48469 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 48470 $as_echo_n "checking for $ac_word... " >&6; } 48471 if ${ac_cv_path_JTREGEXE+:} false; then : 48472 $as_echo_n "(cached) " >&6 48473 else 48474 case $JTREGEXE in 48475 [\\/]* | ?:[\\/]*) 48476 ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path. 48477 ;; 48478 *) 48479 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 48480 for as_dir in $PATH 48481 do 48482 IFS=$as_save_IFS 48483 test -z "$as_dir" && as_dir=. 48484 for ac_exec_ext in '' $ac_executable_extensions; do 48485 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 48486 ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext" 48487 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 48488 break 2 48489 fi 48490 done 48491 done 48492 IFS=$as_save_IFS 48493 48494 ;; 48495 esac 48496 fi 48497 JTREGEXE=$ac_cv_path_JTREGEXE 48498 if test -n "$JTREGEXE"; then 48499 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5 48500 $as_echo "$JTREGEXE" >&6; } 48501 else 48502 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 48503 $as_echo "no" >&6; } 48504 fi 48505 48506 48507 test -n "$JTREGEXE" && break 48508 done 48509 48510 else 48511 # The variable is set, but is it from the command line or the environment? 48512 48513 # Try to remove the string !JTREGEXE! from our list. 48514 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JTREGEXE!/} 48515 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 48516 # If it failed, the variable was not from the command line. Ignore it, 48517 # but warn the user (except for BASH, which is always set by the calling BASH). 48518 if test "xJTREGEXE" != xBASH; then 48519 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JTREGEXE from the environment. Use command line variables instead." >&5 48520 $as_echo "$as_me: WARNING: Ignoring value of JTREGEXE from the environment. Use command line variables instead." >&2;} 48521 fi 48522 # Try to locate tool using the code snippet 48523 for ac_prog in jtreg 48524 do 48525 # Extract the first word of "$ac_prog", so it can be a program name with args. 48526 set dummy $ac_prog; ac_word=$2 48527 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 48528 $as_echo_n "checking for $ac_word... " >&6; } 48529 if ${ac_cv_path_JTREGEXE+:} false; then : 48530 $as_echo_n "(cached) " >&6 48531 else 48532 case $JTREGEXE in 48533 [\\/]* | ?:[\\/]*) 48534 ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path. 48535 ;; 48536 *) 48537 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 48538 for as_dir in $PATH 48539 do 48540 IFS=$as_save_IFS 48541 test -z "$as_dir" && as_dir=. 48542 for ac_exec_ext in '' $ac_executable_extensions; do 48543 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 48544 ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext" 48545 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 48546 break 2 48547 fi 48548 done 48549 done 48550 IFS=$as_save_IFS 48551 48552 ;; 48553 esac 48554 fi 48555 JTREGEXE=$ac_cv_path_JTREGEXE 48556 if test -n "$JTREGEXE"; then 48557 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5 48558 $as_echo "$JTREGEXE" >&6; } 48559 else 48560 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 48561 $as_echo "no" >&6; } 48562 fi 48563 48564 48565 test -n "$JTREGEXE" && break 48566 done 48567 48568 else 48569 # If it succeeded, then it was overridden by the user. We will use it 48570 # for the tool. 48571 48572 # First remove it from the list of overridden variables, so we can test 48573 # for unknown variables in the end. 48574 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 48575 48576 # Check if we try to supply an empty value 48577 if test "x$JTREGEXE" = x; then 48578 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JTREGEXE= (no value)" >&5 48579 $as_echo "$as_me: Setting user supplied tool JTREGEXE= (no value)" >&6;} 48580 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JTREGEXE" >&5 48581 $as_echo_n "checking for JTREGEXE... " >&6; } 48582 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 48583 $as_echo "disabled" >&6; } 48584 else 48585 # Check if the provided tool contains a complete path. 48586 tool_specified="$JTREGEXE" 48587 tool_basename="${tool_specified##*/}" 48588 if test "x$tool_basename" = "x$tool_specified"; then 48589 # A command without a complete path is provided, search $PATH. 48590 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JTREGEXE=$tool_basename" >&5 48591 $as_echo "$as_me: Will search for user supplied tool JTREGEXE=$tool_basename" >&6;} 48592 # Extract the first word of "$tool_basename", so it can be a program name with args. 48593 set dummy $tool_basename; ac_word=$2 48594 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 48595 $as_echo_n "checking for $ac_word... " >&6; } 48596 if ${ac_cv_path_JTREGEXE+:} false; then : 48597 $as_echo_n "(cached) " >&6 48598 else 48599 case $JTREGEXE in 48600 [\\/]* | ?:[\\/]*) 48601 ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path. 48602 ;; 48603 *) 48604 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 48605 for as_dir in $PATH 48606 do 48607 IFS=$as_save_IFS 48608 test -z "$as_dir" && as_dir=. 48609 for ac_exec_ext in '' $ac_executable_extensions; do 48610 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 48611 ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext" 48612 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 48613 break 2 48614 fi 48615 done 48616 done 48617 IFS=$as_save_IFS 48618 48619 ;; 48620 esac 48621 fi 48622 JTREGEXE=$ac_cv_path_JTREGEXE 48623 if test -n "$JTREGEXE"; then 48624 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5 48625 $as_echo "$JTREGEXE" >&6; } 48626 else 48627 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 48628 $as_echo "no" >&6; } 48629 fi 48630 48631 48632 if test "x$JTREGEXE" = x; then 48633 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 48634 fi 48635 else 48636 # Otherwise we believe it is a complete path. Use it as it is. 48637 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JTREGEXE=$tool_specified" >&5 48638 $as_echo "$as_me: Will use user supplied tool JTREGEXE=$tool_specified" >&6;} 48639 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JTREGEXE" >&5 48640 $as_echo_n "checking for JTREGEXE... " >&6; } 48641 if test ! -x "$tool_specified"; then 48642 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 48643 $as_echo "not found" >&6; } 48644 as_fn_error $? "User supplied tool JTREGEXE=$tool_specified does not exist or is not executable" "$LINENO" 5 48645 fi 48646 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 48647 $as_echo "$tool_specified" >&6; } 48648 fi 48649 fi 48650 fi 48651 48652 fi 48653 48654 48655 48656 if test "x$JTREGEXE" = x; then 48657 as_fn_error $? "Could not find required tool for JTREGEXE" "$LINENO" 5 48658 fi 48659 48660 48661 JT_HOME="`$DIRNAME $JTREGEXE`" 48662 fi 48663 fi 48664 48665 48666 48667 48668 48669 48670 # COMPILER_TARGET_BITS_FLAG : option for selecting 32- or 64-bit output 48671 # COMPILER_COMMAND_FILE_FLAG : option for passing a command file to the compiler 48672 # COMPILER_BINDCMD_FILE_FLAG : option for specifying a file which saves the binder 48673 # commands produced by the link step (currently AIX only) 48674 if test "x$TOOLCHAIN_TYPE" = xxlc; then 48675 COMPILER_TARGET_BITS_FLAG="-q" 48676 COMPILER_COMMAND_FILE_FLAG="-f" 48677 COMPILER_BINDCMD_FILE_FLAG="-bloadmap:" 48678 else 48679 COMPILER_TARGET_BITS_FLAG="-m" 48680 COMPILER_COMMAND_FILE_FLAG="@" 48681 COMPILER_BINDCMD_FILE_FLAG="" 48682 48683 # The solstudio linker does not support @-files. 48684 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 48685 COMPILER_COMMAND_FILE_FLAG= 48686 fi 48687 48688 # Check if @file is supported by gcc 48689 if test "x$TOOLCHAIN_TYPE" = xgcc; then 48690 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if @file is supported by gcc" >&5 48691 $as_echo_n "checking if @file is supported by gcc... " >&6; } 48692 # Extra emtpy "" to prevent ECHO from interpreting '--version' as argument 48693 $ECHO "" "--version" > command.file 48694 if $CXX @command.file 2>&5 >&5; then 48695 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 48696 $as_echo "yes" >&6; } 48697 COMPILER_COMMAND_FILE_FLAG="@" 48698 else 48699 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 48700 $as_echo "no" >&6; } 48701 COMPILER_COMMAND_FILE_FLAG= 48702 fi 48703 $RM command.file 48704 fi 48705 fi 48706 48707 48708 48709 48710 # FIXME: figure out if we should select AR flags depending on OS or toolchain. 48711 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 48712 ARFLAGS="-r" 48713 elif test "x$OPENJDK_TARGET_OS" = xaix; then 48714 ARFLAGS="-X64" 48715 elif test "x$OPENJDK_TARGET_OS" = xwindows; then 48716 # lib.exe is used as AR to create static libraries. 48717 ARFLAGS="-nologo -NODEFAULTLIB:MSVCRT" 48718 else 48719 ARFLAGS="" 48720 fi 48721 48722 48723 ## Setup strip. 48724 # FIXME: should this really be per platform, or should it be per toolchain type? 48725 # strip is not provided by clang or solstudio; so guessing platform makes most sense. 48726 # FIXME: we should really only export STRIPFLAGS from here, not POST_STRIP_CMD. 48727 if test "x$OPENJDK_TARGET_OS" = xlinux; then 48728 STRIPFLAGS="-g" 48729 elif test "x$OPENJDK_TARGET_OS" = xsolaris; then 48730 STRIPFLAGS="-x" 48731 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 48732 STRIPFLAGS="-S" 48733 elif test "x$OPENJDK_TARGET_OS" = xaix; then 48734 STRIPFLAGS="-X32_64" 48735 fi 48736 48737 48738 48739 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 48740 CC_OUT_OPTION=-Fo 48741 EXE_OUT_OPTION=-out: 48742 LD_OUT_OPTION=-out: 48743 AR_OUT_OPTION=-out: 48744 else 48745 # The option used to specify the target .o,.a or .so file. 48746 # When compiling, how to specify the to be created object file. 48747 CC_OUT_OPTION='-o$(SPACE)' 48748 # When linking, how to specify the to be created executable. 48749 EXE_OUT_OPTION='-o$(SPACE)' 48750 # When linking, how to specify the to be created dynamically linkable library. 48751 LD_OUT_OPTION='-o$(SPACE)' 48752 # When archiving, how to specify the to be create static archive for object files. 48753 AR_OUT_OPTION='rcs$(SPACE)' 48754 fi 48755 48756 48757 48758 48759 48760 # On Windows, we need to set RC flags. 48761 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 48762 RC_FLAGS="-nologo -l0x409" 48763 JVM_RCFLAGS="-nologo" 48764 if test "x$DEBUG_LEVEL" = xrelease; then 48765 RC_FLAGS="$RC_FLAGS -DNDEBUG" 48766 JVM_RCFLAGS="$JVM_RCFLAGS -DNDEBUG" 48767 fi 48768 48769 # The version variables used to create RC_FLAGS may be overridden 48770 # in a custom configure script, or possibly the command line. 48771 # Let those variables be expanded at make time in spec.gmk. 48772 # The \$ are escaped to the shell, and the $(...) variables 48773 # are evaluated by make. 48774 RC_FLAGS="$RC_FLAGS \ 48775 -D\"JDK_VERSION_STRING=\$(VERSION_STRING)\" \ 48776 -D\"JDK_COMPANY=\$(COMPANY_NAME)\" \ 48777 -D\"JDK_COMPONENT=\$(PRODUCT_NAME) \$(JDK_RC_PLATFORM_NAME) binary\" \ 48778 -D\"JDK_VER=\$(VERSION_NUMBER)\" \ 48779 -D\"JDK_COPYRIGHT=Copyright \xA9 $COPYRIGHT_YEAR\" \ 48780 -D\"JDK_NAME=\$(PRODUCT_NAME) \$(JDK_RC_PLATFORM_NAME) \$(VERSION_MAJOR)\" \ 48781 -D\"JDK_FVER=\$(subst .,\$(COMMA),\$(VERSION_NUMBER_FOUR_POSITIONS))\"" 48782 48783 JVM_RCFLAGS="$JVM_RCFLAGS \ 48784 -D\"HS_BUILD_ID=\$(VERSION_STRING)\" \ 48785 -D\"HS_COMPANY=\$(COMPANY_NAME)\" \ 48786 -D\"JDK_DOTVER=\$(VERSION_NUMBER_FOUR_POSITIONS)\" \ 48787 -D\"HS_COPYRIGHT=Copyright $COPYRIGHT_YEAR\" \ 48788 -D\"HS_NAME=\$(PRODUCT_NAME) \$(VERSION_SHORT)\" \ 48789 -D\"JDK_VER=\$(subst .,\$(COMMA),\$(VERSION_NUMBER_FOUR_POSITIONS))\" \ 48790 -D\"HS_FNAME=jvm.dll\" \ 48791 -D\"HS_INTERNAL_NAME=jvm\"" 48792 fi 48793 48794 48795 48796 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 48797 # silence copyright notice and other headers. 48798 COMMON_CCXXFLAGS="$COMMON_CCXXFLAGS -nologo" 48799 fi 48800 48801 48802 # Now we can test some aspects on the target using configure macros. 48803 48804 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 48805 $as_echo_n "checking for ANSI C header files... " >&6; } 48806 if ${ac_cv_header_stdc+:} false; then : 48807 $as_echo_n "(cached) " >&6 48808 else 48809 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48810 /* end confdefs.h. */ 48811 #include <stdlib.h> 48812 #include <stdarg.h> 48813 #include <string.h> 48814 #include <float.h> 48815 48816 int 48817 main () 48818 { 48819 48820 ; 48821 return 0; 48822 } 48823 _ACEOF 48824 if ac_fn_cxx_try_compile "$LINENO"; then : 48825 ac_cv_header_stdc=yes 48826 else 48827 ac_cv_header_stdc=no 48828 fi 48829 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 48830 48831 if test $ac_cv_header_stdc = yes; then 48832 # SunOS 4.x string.h does not declare mem*, contrary to ANSI. 48833 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48834 /* end confdefs.h. */ 48835 #include <string.h> 48836 48837 _ACEOF 48838 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 48839 $EGREP "memchr" >/dev/null 2>&1; then : 48840 48841 else 48842 ac_cv_header_stdc=no 48843 fi 48844 rm -f conftest* 48845 48846 fi 48847 48848 if test $ac_cv_header_stdc = yes; then 48849 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. 48850 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48851 /* end confdefs.h. */ 48852 #include <stdlib.h> 48853 48854 _ACEOF 48855 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 48856 $EGREP "free" >/dev/null 2>&1; then : 48857 48858 else 48859 ac_cv_header_stdc=no 48860 fi 48861 rm -f conftest* 48862 48863 fi 48864 48865 if test $ac_cv_header_stdc = yes; then 48866 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. 48867 if test "$cross_compiling" = yes; then : 48868 : 48869 else 48870 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48871 /* end confdefs.h. */ 48872 #include <ctype.h> 48873 #include <stdlib.h> 48874 #if ((' ' & 0x0FF) == 0x020) 48875 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') 48876 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) 48877 #else 48878 # define ISLOWER(c) \ 48879 (('a' <= (c) && (c) <= 'i') \ 48880 || ('j' <= (c) && (c) <= 'r') \ 48881 || ('s' <= (c) && (c) <= 'z')) 48882 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) 48883 #endif 48884 48885 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) 48886 int 48887 main () 48888 { 48889 int i; 48890 for (i = 0; i < 256; i++) 48891 if (XOR (islower (i), ISLOWER (i)) 48892 || toupper (i) != TOUPPER (i)) 48893 return 2; 48894 return 0; 48895 } 48896 _ACEOF 48897 if ac_fn_cxx_try_run "$LINENO"; then : 48898 48899 else 48900 ac_cv_header_stdc=no 48901 fi 48902 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 48903 conftest.$ac_objext conftest.beam conftest.$ac_ext 48904 fi 48905 48906 fi 48907 fi 48908 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 48909 $as_echo "$ac_cv_header_stdc" >&6; } 48910 if test $ac_cv_header_stdc = yes; then 48911 48912 $as_echo "#define STDC_HEADERS 1" >>confdefs.h 48913 48914 fi 48915 48916 # On IRIX 5.3, sys/types and inttypes.h are conflicting. 48917 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ 48918 inttypes.h stdint.h unistd.h 48919 do : 48920 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` 48921 ac_fn_cxx_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default 48922 " 48923 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : 48924 cat >>confdefs.h <<_ACEOF 48925 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 48926 _ACEOF 48927 48928 fi 48929 48930 done 48931 48932 48933 48934 ############################################################################### 48935 # 48936 # Now we check if libjvm.so will use 32 or 64 bit pointers for the C/C++ code. 48937 # (The JVM can use 32 or 64 bit Java pointers but that decision 48938 # is made at runtime.) 48939 # 48940 48941 if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xaix; then 48942 # Always specify -m flag on Solaris 48943 # And -q on AIX because otherwise the compiler produces 32-bit objects by default 48944 48945 # When we add flags to the "official" CFLAGS etc, we need to 48946 # keep track of these additions in ADDED_CFLAGS etc. These 48947 # will later be checked to make sure only controlled additions 48948 # have been made to CFLAGS etc. 48949 ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48950 ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48951 ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48952 48953 CFLAGS="${CFLAGS}${ADDED_CFLAGS}" 48954 CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}" 48955 LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}" 48956 48957 CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}" 48958 CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}" 48959 LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}" 48960 48961 JVM_CFLAGS="$JVM_CFLAGS $ADDED_CFLAGS" 48962 JVM_LDFLAGS="$JVM_LDFLAGS $ADDED_LDFLAGS" 48963 JVM_ASFLAGS="$JVM_ASFLAGS $ADDED_CFLAGS" 48964 48965 elif test "x$COMPILE_TYPE" = xreduced; then 48966 if test "x$OPENJDK_TARGET_OS_TYPE" = xunix; then 48967 # Specify -m if running reduced on unix platforms 48968 48969 # When we add flags to the "official" CFLAGS etc, we need to 48970 # keep track of these additions in ADDED_CFLAGS etc. These 48971 # will later be checked to make sure only controlled additions 48972 # have been made to CFLAGS etc. 48973 ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48974 ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48975 ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48976 48977 CFLAGS="${CFLAGS}${ADDED_CFLAGS}" 48978 CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}" 48979 LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}" 48980 48981 CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}" 48982 CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}" 48983 LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}" 48984 48985 JVM_CFLAGS="$JVM_CFLAGS $ADDED_CFLAGS" 48986 JVM_LDFLAGS="$JVM_LDFLAGS $ADDED_LDFLAGS" 48987 JVM_ASFLAGS="$JVM_ASFLAGS $ADDED_CFLAGS" 48988 48989 fi 48990 fi 48991 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 48992 JVM_CFLAGS="$JVM_CFLAGS ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48993 JVM_LDFLAGS="$JVM_LDFLAGS ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48994 JVM_ASFLAGS="$JVM_ASFLAGS ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48995 fi 48996 48997 # Make compilation sanity check 48998 for ac_header in stdio.h 48999 do : 49000 ac_fn_cxx_check_header_mongrel "$LINENO" "stdio.h" "ac_cv_header_stdio_h" "$ac_includes_default" 49001 if test "x$ac_cv_header_stdio_h" = xyes; then : 49002 cat >>confdefs.h <<_ACEOF 49003 #define HAVE_STDIO_H 1 49004 _ACEOF 49005 49006 else 49007 49008 { $as_echo "$as_me:${as_lineno-$LINENO}: Failed to compile stdio.h. This likely implies missing compile dependencies." >&5 49009 $as_echo "$as_me: Failed to compile stdio.h. This likely implies missing compile dependencies." >&6;} 49010 if test "x$COMPILE_TYPE" = xreduced; then 49011 49012 # Print a helpful message on how to acquire the necessary build dependency. 49013 # reduced is the help tag: freetype, cups, alsa etc 49014 MISSING_DEPENDENCY=reduced 49015 49016 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 49017 cygwin_help $MISSING_DEPENDENCY 49018 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 49019 msys_help $MISSING_DEPENDENCY 49020 else 49021 PKGHANDLER_COMMAND= 49022 49023 case $PKGHANDLER in 49024 apt-get) 49025 apt_help $MISSING_DEPENDENCY ;; 49026 yum) 49027 yum_help $MISSING_DEPENDENCY ;; 49028 brew) 49029 brew_help $MISSING_DEPENDENCY ;; 49030 port) 49031 port_help $MISSING_DEPENDENCY ;; 49032 pkgutil) 49033 pkgutil_help $MISSING_DEPENDENCY ;; 49034 pkgadd) 49035 pkgadd_help $MISSING_DEPENDENCY ;; 49036 esac 49037 49038 if test "x$PKGHANDLER_COMMAND" != x; then 49039 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 49040 fi 49041 fi 49042 49043 { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a reduced build. Check that you have 32-bit libraries installed. $HELP_MSG" >&5 49044 $as_echo "$as_me: You are doing a reduced build. Check that you have 32-bit libraries installed. $HELP_MSG" >&6;} 49045 elif test "x$COMPILE_TYPE" = xcross; then 49046 { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&5 49047 $as_echo "$as_me: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&6;} 49048 fi 49049 as_fn_error $? "Cannot continue." "$LINENO" 5 49050 49051 fi 49052 49053 done 49054 49055 49056 # The cast to long int works around a bug in the HP C Compiler 49057 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects 49058 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. 49059 # This bug is HP SR number 8606223364. 49060 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int *" >&5 49061 $as_echo_n "checking size of int *... " >&6; } 49062 if ${ac_cv_sizeof_int_p+:} false; then : 49063 $as_echo_n "(cached) " >&6 49064 else 49065 if ac_fn_cxx_compute_int "$LINENO" "(long int) (sizeof (int *))" "ac_cv_sizeof_int_p" "$ac_includes_default"; then : 49066 49067 else 49068 if test "$ac_cv_type_int_p" = yes; then 49069 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 49070 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 49071 as_fn_error 77 "cannot compute sizeof (int *) 49072 See \`config.log' for more details" "$LINENO" 5; } 49073 else 49074 ac_cv_sizeof_int_p=0 49075 fi 49076 fi 49077 49078 fi 49079 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int_p" >&5 49080 $as_echo "$ac_cv_sizeof_int_p" >&6; } 49081 49082 49083 49084 cat >>confdefs.h <<_ACEOF 49085 #define SIZEOF_INT_P $ac_cv_sizeof_int_p 49086 _ACEOF 49087 49088 49089 49090 # AC_CHECK_SIZEOF defines 'ac_cv_sizeof_int_p' to hold the number of bytes used by an 'int*' 49091 if test "x$ac_cv_sizeof_int_p" = x; then 49092 # The test failed, lets stick to the assumed value. 49093 { $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 49094 $as_echo "$as_me: WARNING: The number of bits in the target could not be determined, using $OPENJDK_TARGET_CPU_BITS." >&2;} 49095 else 49096 TESTED_TARGET_CPU_BITS=`expr 8 \* $ac_cv_sizeof_int_p` 49097 49098 if test "x$TESTED_TARGET_CPU_BITS" != "x$OPENJDK_TARGET_CPU_BITS"; then 49099 # This situation may happen on 64-bit platforms where the compiler by default only generates 32-bit objects 49100 # Let's try to implicitely set the compilers target architecture and retry the test 49101 { $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 49102 $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;} 49103 { $as_echo "$as_me:${as_lineno-$LINENO}: Retrying with platforms compiler target bits flag to ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" >&5 49104 $as_echo "$as_me: Retrying with platforms compiler target bits flag to ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" >&6;} 49105 49106 # When we add flags to the "official" CFLAGS etc, we need to 49107 # keep track of these additions in ADDED_CFLAGS etc. These 49108 # will later be checked to make sure only controlled additions 49109 # have been made to CFLAGS etc. 49110 ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 49111 ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 49112 ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 49113 49114 CFLAGS="${CFLAGS}${ADDED_CFLAGS}" 49115 CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}" 49116 LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}" 49117 49118 CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}" 49119 CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}" 49120 LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}" 49121 49122 JVM_CFLAGS="$JVM_CFLAGS $ADDED_CFLAGS" 49123 JVM_LDFLAGS="$JVM_LDFLAGS $ADDED_LDFLAGS" 49124 JVM_ASFLAGS="$JVM_ASFLAGS $ADDED_CFLAGS" 49125 49126 49127 # We have to unset 'ac_cv_sizeof_int_p' first, otherwise AC_CHECK_SIZEOF will use the previously cached value! 49128 unset ac_cv_sizeof_int_p 49129 # And we have to undef the definition of SIZEOF_INT_P in confdefs.h by the previous invocation of AC_CHECK_SIZEOF 49130 cat >>confdefs.h <<_ACEOF 49131 #undef SIZEOF_INT_P 49132 _ACEOF 49133 49134 # The cast to long int works around a bug in the HP C Compiler 49135 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects 49136 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. 49137 # This bug is HP SR number 8606223364. 49138 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int *" >&5 49139 $as_echo_n "checking size of int *... " >&6; } 49140 if ${ac_cv_sizeof_int_p+:} false; then : 49141 $as_echo_n "(cached) " >&6 49142 else 49143 if ac_fn_cxx_compute_int "$LINENO" "(long int) (sizeof (int *))" "ac_cv_sizeof_int_p" "$ac_includes_default"; then : 49144 49145 else 49146 if test "$ac_cv_type_int_p" = yes; then 49147 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 49148 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 49149 as_fn_error 77 "cannot compute sizeof (int *) 49150 See \`config.log' for more details" "$LINENO" 5; } 49151 else 49152 ac_cv_sizeof_int_p=0 49153 fi 49154 fi 49155 49156 fi 49157 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int_p" >&5 49158 $as_echo "$ac_cv_sizeof_int_p" >&6; } 49159 49160 49161 49162 cat >>confdefs.h <<_ACEOF 49163 #define SIZEOF_INT_P $ac_cv_sizeof_int_p 49164 _ACEOF 49165 49166 49167 49168 TESTED_TARGET_CPU_BITS=`expr 8 \* $ac_cv_sizeof_int_p` 49169 49170 if test "x$TESTED_TARGET_CPU_BITS" != "x$OPENJDK_TARGET_CPU_BITS"; then 49171 { $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 49172 $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;} 49173 if test "x$COMPILE_TYPE" = xreduced; then 49174 49175 # Print a helpful message on how to acquire the necessary build dependency. 49176 # reduced is the help tag: freetype, cups, alsa etc 49177 MISSING_DEPENDENCY=reduced 49178 49179 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 49180 cygwin_help $MISSING_DEPENDENCY 49181 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 49182 msys_help $MISSING_DEPENDENCY 49183 else 49184 PKGHANDLER_COMMAND= 49185 49186 case $PKGHANDLER in 49187 apt-get) 49188 apt_help $MISSING_DEPENDENCY ;; 49189 yum) 49190 yum_help $MISSING_DEPENDENCY ;; 49191 brew) 49192 brew_help $MISSING_DEPENDENCY ;; 49193 port) 49194 port_help $MISSING_DEPENDENCY ;; 49195 pkgutil) 49196 pkgutil_help $MISSING_DEPENDENCY ;; 49197 pkgadd) 49198 pkgadd_help $MISSING_DEPENDENCY ;; 49199 esac 49200 49201 if test "x$PKGHANDLER_COMMAND" != x; then 49202 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 49203 fi 49204 fi 49205 49206 { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a reduced build. Check that you have 32-bit libraries installed. $HELP_MSG" >&5 49207 $as_echo "$as_me: You are doing a reduced build. Check that you have 32-bit libraries installed. $HELP_MSG" >&6;} 49208 elif test "x$COMPILE_TYPE" = xcross; then 49209 { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&5 49210 $as_echo "$as_me: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&6;} 49211 fi 49212 as_fn_error $? "Cannot continue." "$LINENO" 5 49213 fi 49214 fi 49215 fi 49216 49217 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for target address size" >&5 49218 $as_echo_n "checking for target address size... " >&6; } 49219 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_TARGET_CPU_BITS bits" >&5 49220 $as_echo "$OPENJDK_TARGET_CPU_BITS bits" >&6; } 49221 49222 49223 ############################################################################### 49224 # 49225 # Is the target little of big endian? 49226 # 49227 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5 49228 $as_echo_n "checking whether byte ordering is bigendian... " >&6; } 49229 if ${ac_cv_c_bigendian+:} false; then : 49230 $as_echo_n "(cached) " >&6 49231 else 49232 ac_cv_c_bigendian=unknown 49233 # See if we're dealing with a universal compiler. 49234 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 49235 /* end confdefs.h. */ 49236 #ifndef __APPLE_CC__ 49237 not a universal capable compiler 49238 #endif 49239 typedef int dummy; 49240 49241 _ACEOF 49242 if ac_fn_cxx_try_compile "$LINENO"; then : 49243 49244 # Check for potential -arch flags. It is not universal unless 49245 # there are at least two -arch flags with different values. 49246 ac_arch= 49247 ac_prev= 49248 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do 49249 if test -n "$ac_prev"; then 49250 case $ac_word in 49251 i?86 | x86_64 | ppc | ppc64) 49252 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then 49253 ac_arch=$ac_word 49254 else 49255 ac_cv_c_bigendian=universal 49256 break 49257 fi 49258 ;; 49259 esac 49260 ac_prev= 49261 elif test "x$ac_word" = "x-arch"; then 49262 ac_prev=arch 49263 fi 49264 done 49265 fi 49266 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 49267 if test $ac_cv_c_bigendian = unknown; then 49268 # See if sys/param.h defines the BYTE_ORDER macro. 49269 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 49270 /* end confdefs.h. */ 49271 #include <sys/types.h> 49272 #include <sys/param.h> 49273 49274 int 49275 main () 49276 { 49277 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \ 49278 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \ 49279 && LITTLE_ENDIAN) 49280 bogus endian macros 49281 #endif 49282 49283 ; 49284 return 0; 49285 } 49286 _ACEOF 49287 if ac_fn_cxx_try_compile "$LINENO"; then : 49288 # It does; now see whether it defined to BIG_ENDIAN or not. 49289 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 49290 /* end confdefs.h. */ 49291 #include <sys/types.h> 49292 #include <sys/param.h> 49293 49294 int 49295 main () 49296 { 49297 #if BYTE_ORDER != BIG_ENDIAN 49298 not big endian 49299 #endif 49300 49301 ; 49302 return 0; 49303 } 49304 _ACEOF 49305 if ac_fn_cxx_try_compile "$LINENO"; then : 49306 ac_cv_c_bigendian=yes 49307 else 49308 ac_cv_c_bigendian=no 49309 fi 49310 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 49311 fi 49312 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 49313 fi 49314 if test $ac_cv_c_bigendian = unknown; then 49315 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris). 49316 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 49317 /* end confdefs.h. */ 49318 #include <limits.h> 49319 49320 int 49321 main () 49322 { 49323 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN) 49324 bogus endian macros 49325 #endif 49326 49327 ; 49328 return 0; 49329 } 49330 _ACEOF 49331 if ac_fn_cxx_try_compile "$LINENO"; then : 49332 # It does; now see whether it defined to _BIG_ENDIAN or not. 49333 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 49334 /* end confdefs.h. */ 49335 #include <limits.h> 49336 49337 int 49338 main () 49339 { 49340 #ifndef _BIG_ENDIAN 49341 not big endian 49342 #endif 49343 49344 ; 49345 return 0; 49346 } 49347 _ACEOF 49348 if ac_fn_cxx_try_compile "$LINENO"; then : 49349 ac_cv_c_bigendian=yes 49350 else 49351 ac_cv_c_bigendian=no 49352 fi 49353 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 49354 fi 49355 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 49356 fi 49357 if test $ac_cv_c_bigendian = unknown; then 49358 # Compile a test program. 49359 if test "$cross_compiling" = yes; then : 49360 # Try to guess by grepping values from an object file. 49361 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 49362 /* end confdefs.h. */ 49363 short int ascii_mm[] = 49364 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 }; 49365 short int ascii_ii[] = 49366 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 }; 49367 int use_ascii (int i) { 49368 return ascii_mm[i] + ascii_ii[i]; 49369 } 49370 short int ebcdic_ii[] = 49371 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 }; 49372 short int ebcdic_mm[] = 49373 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 }; 49374 int use_ebcdic (int i) { 49375 return ebcdic_mm[i] + ebcdic_ii[i]; 49376 } 49377 extern int foo; 49378 49379 int 49380 main () 49381 { 49382 return use_ascii (foo) == use_ebcdic (foo); 49383 ; 49384 return 0; 49385 } 49386 _ACEOF 49387 if ac_fn_cxx_try_compile "$LINENO"; then : 49388 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then 49389 ac_cv_c_bigendian=yes 49390 fi 49391 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then 49392 if test "$ac_cv_c_bigendian" = unknown; then 49393 ac_cv_c_bigendian=no 49394 else 49395 # finding both strings is unlikely to happen, but who knows? 49396 ac_cv_c_bigendian=unknown 49397 fi 49398 fi 49399 fi 49400 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 49401 else 49402 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 49403 /* end confdefs.h. */ 49404 $ac_includes_default 49405 int 49406 main () 49407 { 49408 49409 /* Are we little or big endian? From Harbison&Steele. */ 49410 union 49411 { 49412 long int l; 49413 char c[sizeof (long int)]; 49414 } u; 49415 u.l = 1; 49416 return u.c[sizeof (long int) - 1] == 1; 49417 49418 ; 49419 return 0; 49420 } 49421 _ACEOF 49422 if ac_fn_cxx_try_run "$LINENO"; then : 49423 ac_cv_c_bigendian=no 49424 else 49425 ac_cv_c_bigendian=yes 49426 fi 49427 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 49428 conftest.$ac_objext conftest.beam conftest.$ac_ext 49429 fi 49430 49431 fi 49432 fi 49433 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5 49434 $as_echo "$ac_cv_c_bigendian" >&6; } 49435 case $ac_cv_c_bigendian in #( 49436 yes) 49437 ENDIAN="big";; #( 49438 no) 49439 ENDIAN="little" ;; #( 49440 universal) 49441 ENDIAN="universal_endianness" 49442 ;; #( 49443 *) 49444 ENDIAN="unknown" ;; 49445 esac 49446 49447 49448 if test "x$ENDIAN" = xuniversal_endianness; then 49449 as_fn_error $? "Building with both big and little endianness is not supported" "$LINENO" 5 49450 fi 49451 if test "x$ENDIAN" != "x$OPENJDK_TARGET_CPU_ENDIAN"; then 49452 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 49453 fi 49454 49455 49456 # Configure flags for the tools 49457 49458 ############################################################################### 49459 # 49460 # How to compile shared libraries. 49461 # 49462 49463 if test "x$TOOLCHAIN_TYPE" = xgcc; then 49464 PICFLAG="-fPIC" 49465 C_FLAG_REORDER='' 49466 CXX_FLAG_REORDER='' 49467 49468 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 49469 # Linking is different on MacOSX 49470 if test "x$STATIC_BUILD" = xtrue; then 49471 SHARED_LIBRARY_FLAGS ='-undefined dynamic_lookup' 49472 else 49473 SHARED_LIBRARY_FLAGS="-dynamiclib -compatibility_version 1.0.0 -current_version 1.0.0 $PICFLAG" 49474 JVM_CFLAGS="$JVM_CFLAGS $PICFLAG" 49475 fi 49476 SET_EXECUTABLE_ORIGIN='-Wl,-rpath,@loader_path$(or $1,/.)' 49477 SET_SHARED_LIBRARY_ORIGIN="$SET_EXECUTABLE_ORIGIN" 49478 SET_SHARED_LIBRARY_NAME='-Wl,-install_name,@rpath/$1' 49479 SET_SHARED_LIBRARY_MAPFILE='-Wl,-exported_symbols_list,$1' 49480 else 49481 # Default works for linux, might work on other platforms as well. 49482 SHARED_LIBRARY_FLAGS='-shared' 49483 SET_EXECUTABLE_ORIGIN='-Wl,-rpath,\$$ORIGIN$1' 49484 SET_SHARED_LIBRARY_ORIGIN="-Wl,-z,origin $SET_EXECUTABLE_ORIGIN" 49485 SET_SHARED_LIBRARY_NAME='-Wl,-soname=$1' 49486 SET_SHARED_LIBRARY_MAPFILE='-Wl,-version-script=$1' 49487 fi 49488 elif test "x$TOOLCHAIN_TYPE" = xclang; then 49489 C_FLAG_REORDER='' 49490 CXX_FLAG_REORDER='' 49491 49492 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 49493 # Linking is different on MacOSX 49494 PICFLAG='' 49495 SHARED_LIBRARY_FLAGS="-dynamiclib -compatibility_version 1.0.0 -current_version 1.0.0 $PICFLAG" 49496 SET_EXECUTABLE_ORIGIN='-Wl,-rpath,@loader_path$(or $1,/.)' 49497 SET_SHARED_LIBRARY_ORIGIN="$SET_EXECUTABLE_ORIGIN" 49498 SET_SHARED_LIBRARY_NAME='-Wl,-install_name,@rpath/$1' 49499 SET_SHARED_LIBRARY_MAPFILE='-Wl,-exported_symbols_list,$1' 49500 49501 if test "x$STATIC_BUILD" = xfalse; then 49502 JVM_CFLAGS="$JVM_CFLAGS -fPIC" 49503 fi 49504 else 49505 # Default works for linux, might work on other platforms as well. 49506 PICFLAG='-fPIC' 49507 SHARED_LIBRARY_FLAGS='-shared' 49508 SET_EXECUTABLE_ORIGIN='-Wl,-rpath,\$$ORIGIN$1' 49509 SET_SHARED_LIBRARY_NAME='-Wl,-soname=$1' 49510 SET_SHARED_LIBRARY_MAPFILE='-Wl,-version-script=$1' 49511 49512 # arm specific settings 49513 if test "x$OPENJDK_TARGET_CPU" = "xarm"; then 49514 # '-Wl,-z,origin' isn't used on arm. 49515 SET_SHARED_LIBRARY_ORIGIN='-Wl,-rpath,\$$$$ORIGIN$1' 49516 else 49517 SET_SHARED_LIBRARY_ORIGIN="-Wl,-z,origin $SET_EXECUTABLE_ORIGIN" 49518 fi 49519 49520 fi 49521 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 49522 if test "x$OPENJDK_TARGET_CPU" = xsparcv9; then 49523 PICFLAG="-xcode=pic32" 49524 else 49525 PICFLAG="-KPIC" 49526 fi 49527 C_FLAG_REORDER='-xF' 49528 CXX_FLAG_REORDER='-xF' 49529 SHARED_LIBRARY_FLAGS="-G" 49530 SET_EXECUTABLE_ORIGIN='-R\$$ORIGIN$1' 49531 SET_SHARED_LIBRARY_ORIGIN="$SET_EXECUTABLE_ORIGIN" 49532 SET_SHARED_LIBRARY_NAME='-h $1' 49533 SET_SHARED_LIBRARY_MAPFILE='-M$1' 49534 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 49535 # '-qpic' defaults to 'qpic=small'. This means that the compiler generates only 49536 # one instruction for accessing the TOC. If the TOC grows larger than 64K, the linker 49537 # will have to patch this single instruction with a call to some out-of-order code which 49538 # does the load from the TOC. This is of course slow. But in that case we also would have 49539 # to use '-bbigtoc' for linking anyway so we could also change the PICFLAG to 'qpic=large'. 49540 # With 'qpic=large' the compiler will by default generate a two-instruction sequence which 49541 # can be patched directly by the linker and does not require a jump to out-of-order code. 49542 # Another alternative instead of using 'qpic=large -bbigtoc' may be to use '-qminimaltoc' 49543 # instead. This creates a distinct TOC for every compilation unit (and thus requires two 49544 # loads for accessing a global variable). But there are rumors that this may be seen as a 49545 # 'performance feature' because of improved code locality of the symbols used in a 49546 # compilation unit. 49547 PICFLAG="-qpic" 49548 JVM_CFLAGS="$JVM_CFLAGS $PICFLAG" 49549 C_FLAG_REORDER='' 49550 CXX_FLAG_REORDER='' 49551 SHARED_LIBRARY_FLAGS="-qmkshrobj -bM:SRE -bnoentry" 49552 SET_EXECUTABLE_ORIGIN="" 49553 SET_SHARED_LIBRARY_ORIGIN='' 49554 SET_SHARED_LIBRARY_NAME='' 49555 SET_SHARED_LIBRARY_MAPFILE='' 49556 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 49557 PICFLAG="" 49558 C_FLAG_REORDER='' 49559 CXX_FLAG_REORDER='' 49560 SHARED_LIBRARY_FLAGS="-dll" 49561 SET_EXECUTABLE_ORIGIN='' 49562 SET_SHARED_LIBRARY_ORIGIN='' 49563 SET_SHARED_LIBRARY_NAME='' 49564 SET_SHARED_LIBRARY_MAPFILE='-def:$1' 49565 fi 49566 49567 49568 49569 49570 49571 49572 49573 49574 49575 # The (cross) compiler is now configured, we can now test capabilities 49576 # of the target platform. 49577 49578 49579 49580 ############################################################################### 49581 # 49582 # Setup the opt flags for different compilers 49583 # and different operating systems. 49584 # 49585 49586 # FIXME: this was indirectly the old default, but just inherited. 49587 # if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 49588 # C_FLAG_DEPS="-MMD -MF" 49589 # fi 49590 49591 # Generate make dependency files 49592 if test "x$TOOLCHAIN_TYPE" = xgcc; then 49593 C_FLAG_DEPS="-MMD -MF" 49594 elif test "x$TOOLCHAIN_TYPE" = xclang; then 49595 C_FLAG_DEPS="-MMD -MF" 49596 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 49597 C_FLAG_DEPS="-xMMD -xMF" 49598 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 49599 C_FLAG_DEPS="-qmakedep=gcc -MF" 49600 fi 49601 CXX_FLAG_DEPS="$C_FLAG_DEPS" 49602 49603 49604 49605 # Debug symbols 49606 if test "x$TOOLCHAIN_TYPE" = xgcc; then 49607 if test "x$OPENJDK_TARGET_CPU_BITS" = "x64" && test "x$DEBUG_LEVEL" = "xfastdebug"; then 49608 # reduce from default "-g2" option to save space 49609 CFLAGS_DEBUG_SYMBOLS="-g1" 49610 CXXFLAGS_DEBUG_SYMBOLS="-g1" 49611 else 49612 CFLAGS_DEBUG_SYMBOLS="-g" 49613 CXXFLAGS_DEBUG_SYMBOLS="-g" 49614 fi 49615 elif test "x$TOOLCHAIN_TYPE" = xclang; then 49616 CFLAGS_DEBUG_SYMBOLS="-g" 49617 CXXFLAGS_DEBUG_SYMBOLS="-g" 49618 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 49619 CFLAGS_DEBUG_SYMBOLS="-g -xs" 49620 # -g0 enables debug symbols without disabling inlining. 49621 CXXFLAGS_DEBUG_SYMBOLS="-g0 -xs" 49622 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 49623 CFLAGS_DEBUG_SYMBOLS="-g" 49624 CXXFLAGS_DEBUG_SYMBOLS="-g" 49625 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 49626 CFLAGS_DEBUG_SYMBOLS="-Zi" 49627 CXXFLAGS_DEBUG_SYMBOLS="-Zi" 49628 fi 49629 49630 49631 49632 # Debug symbols for JVM_CFLAGS 49633 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 49634 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS -xs" 49635 if test "x$DEBUG_LEVEL" = xslowdebug; then 49636 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS -g" 49637 else 49638 # -g0 does not disable inlining, which -g does. 49639 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS -g0" 49640 fi 49641 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 49642 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS -Z7 -d2Zi+" 49643 else 49644 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS -g" 49645 fi 49646 49647 49648 # bounds, memory and behavior checking options 49649 if test "x$TOOLCHAIN_TYPE" = xgcc; then 49650 case $DEBUG_LEVEL in 49651 release ) 49652 # no adjustment 49653 ;; 49654 fastdebug ) 49655 # no adjustment 49656 ;; 49657 slowdebug ) 49658 # FIXME: By adding this to C(XX)FLAGS_DEBUG_OPTIONS/JVM_CFLAGS_SYMBOLS it 49659 # get's added conditionally on whether we produce debug symbols or not. 49660 # This is most likely not really correct. 49661 49662 # Add runtime stack smashing and undefined behavior checks. 49663 # Not all versions of gcc support -fstack-protector 49664 STACK_PROTECTOR_CFLAG="-fstack-protector-all" 49665 49666 49667 49668 49669 49670 49671 49672 49673 49674 49675 49676 49677 49678 49679 49680 49681 49682 49683 49684 49685 49686 49687 49688 49689 49690 49691 49692 49693 49694 49695 49696 49697 49698 49699 49700 49701 49702 49703 49704 49705 49706 49707 # Execute function body 49708 49709 49710 49711 49712 49713 49714 49715 49716 49717 49718 49719 49720 49721 49722 49723 49724 49725 49726 49727 49728 49729 49730 49731 49732 49733 49734 49735 49736 49737 49738 49739 49740 49741 49742 49743 49744 49745 49746 49747 49748 49749 49750 49751 49752 49753 49754 49755 49756 # Execute function body 49757 49758 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler supports \"$STACK_PROTECTOR_CFLAG -Werror\"" >&5 49759 $as_echo_n "checking if the C compiler supports \"$STACK_PROTECTOR_CFLAG -Werror\"... " >&6; } 49760 supports=yes 49761 49762 saved_cflags="$CFLAGS" 49763 CFLAGS="$CFLAGS $STACK_PROTECTOR_CFLAG -Werror" 49764 ac_ext=c 49765 ac_cpp='$CPP $CPPFLAGS' 49766 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 49767 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 49768 ac_compiler_gnu=$ac_cv_c_compiler_gnu 49769 49770 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 49771 /* end confdefs.h. */ 49772 int i; 49773 _ACEOF 49774 if ac_fn_c_try_compile "$LINENO"; then : 49775 49776 else 49777 supports=no 49778 fi 49779 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 49780 ac_ext=cpp 49781 ac_cpp='$CXXCPP $CPPFLAGS' 49782 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 49783 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 49784 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 49785 49786 CFLAGS="$saved_cflags" 49787 49788 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 49789 $as_echo "$supports" >&6; } 49790 if test "x$supports" = "xyes" ; then 49791 : 49792 C_COMP_SUPPORTS="yes" 49793 else 49794 : 49795 C_COMP_SUPPORTS="no" 49796 fi 49797 49798 49799 49800 49801 49802 49803 49804 49805 49806 49807 49808 49809 49810 49811 49812 49813 49814 49815 49816 49817 49818 49819 49820 49821 49822 49823 49824 49825 49826 49827 49828 49829 49830 49831 49832 49833 49834 49835 49836 49837 49838 49839 49840 49841 49842 49843 49844 49845 49846 49847 49848 49849 49850 49851 49852 49853 49854 49855 49856 # Execute function body 49857 49858 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"$STACK_PROTECTOR_CFLAG -Werror\"" >&5 49859 $as_echo_n "checking if the C++ compiler supports \"$STACK_PROTECTOR_CFLAG -Werror\"... " >&6; } 49860 supports=yes 49861 49862 saved_cxxflags="$CXXFLAGS" 49863 CXXFLAGS="$CXXFLAG $STACK_PROTECTOR_CFLAG -Werror" 49864 ac_ext=cpp 49865 ac_cpp='$CXXCPP $CPPFLAGS' 49866 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 49867 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 49868 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 49869 49870 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 49871 /* end confdefs.h. */ 49872 int i; 49873 _ACEOF 49874 if ac_fn_cxx_try_compile "$LINENO"; then : 49875 49876 else 49877 supports=no 49878 fi 49879 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 49880 ac_ext=cpp 49881 ac_cpp='$CXXCPP $CPPFLAGS' 49882 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 49883 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 49884 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 49885 49886 CXXFLAGS="$saved_cxxflags" 49887 49888 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 49889 $as_echo "$supports" >&6; } 49890 if test "x$supports" = "xyes" ; then 49891 : 49892 CXX_COMP_SUPPORTS="yes" 49893 else 49894 : 49895 CXX_COMP_SUPPORTS="no" 49896 fi 49897 49898 49899 49900 49901 49902 49903 49904 49905 49906 49907 49908 49909 49910 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"$STACK_PROTECTOR_CFLAG -Werror\"" >&5 49911 $as_echo_n "checking if both compilers support \"$STACK_PROTECTOR_CFLAG -Werror\"... " >&6; } 49912 supports=no 49913 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 49914 49915 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 49916 $as_echo "$supports" >&6; } 49917 if test "x$supports" = "xyes" ; then 49918 : 49919 49920 else 49921 : 49922 STACK_PROTECTOR_CFLAG="" 49923 fi 49924 49925 49926 49927 49928 49929 49930 49931 CFLAGS_DEBUG_OPTIONS="$STACK_PROTECTOR_CFLAG --param ssp-buffer-size=1" 49932 CXXFLAGS_DEBUG_OPTIONS="$STACK_PROTECTOR_CFLAG --param ssp-buffer-size=1" 49933 if test "x$STACK_PROTECTOR_CFLAG" != x; then 49934 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS $STACK_PROTECTOR_CFLAG --param ssp-buffer-size=1" 49935 fi 49936 ;; 49937 esac 49938 fi 49939 49940 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 49941 if test "x$DEBUG_LEVEL" != xrelease; then 49942 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 49943 JVM_CFLAGS="$JVM_CFLAGS -homeparams" 49944 fi 49945 fi 49946 fi 49947 49948 # Optimization levels 49949 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 49950 CC_HIGHEST="$CC_HIGHEST -fns -fsimple -fsingle -xbuiltin=%all -xdepend -xrestrict -xlibmil" 49951 49952 if test "x$OPENJDK_TARGET_CPU_ARCH" = "xx86"; then 49953 # FIXME: seems we always set -xregs=no%frameptr; put it elsewhere more global? 49954 C_O_FLAG_HIGHEST_JVM="-xO4" 49955 C_O_FLAG_HIGHEST="-xO4 -Wu,-O4~yz $CC_HIGHEST -xalias_level=basic -xregs=no%frameptr" 49956 C_O_FLAG_HI="-xO4 -Wu,-O4~yz -xregs=no%frameptr" 49957 C_O_FLAG_NORM="-xO2 -Wu,-O2~yz -xregs=no%frameptr" 49958 C_O_FLAG_DEBUG="-xregs=no%frameptr" 49959 C_O_FLAG_DEBUG_JVM="" 49960 C_O_FLAG_NONE="-xregs=no%frameptr" 49961 CXX_O_FLAG_HIGHEST_JVM="-xO4" 49962 CXX_O_FLAG_HIGHEST="-xO4 -Qoption ube -O4~yz $CC_HIGHEST -xregs=no%frameptr" 49963 CXX_O_FLAG_HI="-xO4 -Qoption ube -O4~yz -xregs=no%frameptr" 49964 CXX_O_FLAG_NORM="-xO2 -Qoption ube -O2~yz -xregs=no%frameptr" 49965 CXX_O_FLAG_DEBUG="-xregs=no%frameptr" 49966 CXX_O_FLAG_DEBUG_JVM="" 49967 CXX_O_FLAG_NONE="-xregs=no%frameptr" 49968 if test "x$OPENJDK_TARGET_CPU_BITS" = "x32"; then 49969 C_O_FLAG_HIGHEST="$C_O_FLAG_HIGHEST -xchip=pentium" 49970 CXX_O_FLAG_HIGHEST="$CXX_O_FLAG_HIGHEST -xchip=pentium" 49971 fi 49972 elif test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then 49973 C_O_FLAG_HIGHEST_JVM="-xO4" 49974 C_O_FLAG_HIGHEST="-xO4 -Wc,-Qrm-s -Wc,-Qiselect-T0 $CC_HIGHEST -xalias_level=basic -xprefetch=auto,explicit -xchip=ultra" 49975 C_O_FLAG_HI="-xO4 -Wc,-Qrm-s -Wc,-Qiselect-T0" 49976 C_O_FLAG_NORM="-xO2 -Wc,-Qrm-s -Wc,-Qiselect-T0" 49977 C_O_FLAG_DEBUG="" 49978 C_O_FLAG_DEBUG_JVM="" 49979 C_O_FLAG_NONE="" 49980 CXX_O_FLAG_HIGHEST_JVM="-xO4" 49981 CXX_O_FLAG_HIGHEST="-xO4 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0 $CC_HIGHEST -xprefetch=auto,explicit -xchip=ultra" 49982 CXX_O_FLAG_HI="-xO4 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0" 49983 CXX_O_FLAG_NORM="-xO2 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0" 49984 CXX_O_FLAG_DEBUG="" 49985 CXX_O_FLAG_DEBUG_JVM="" 49986 CXX_O_FLAG_NONE="" 49987 fi 49988 else 49989 # The remaining toolchains share opt flags between CC and CXX; 49990 # setup for C and duplicate afterwards. 49991 if test "x$TOOLCHAIN_TYPE" = xgcc; then 49992 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 49993 # On MacOSX we optimize for size, something 49994 # we should do for all platforms? 49995 C_O_FLAG_HIGHEST_JVM="-Os" 49996 C_O_FLAG_HIGHEST="-Os" 49997 C_O_FLAG_HI="-Os" 49998 C_O_FLAG_NORM="-Os" 49999 C_O_FLAG_SIZE="-Os" 50000 else 50001 C_O_FLAG_HIGHEST_JVM="-O3" 50002 C_O_FLAG_HIGHEST="-O3" 50003 C_O_FLAG_HI="-O3" 50004 C_O_FLAG_NORM="-O2" 50005 C_O_FLAG_SIZE="-Os" 50006 fi 50007 C_O_FLAG_DEBUG="-O0" 50008 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 50009 C_O_FLAG_DEBUG_JVM="" 50010 elif test "x$OPENJDK_TARGET_OS" = xlinux; then 50011 C_O_FLAG_DEBUG_JVM="-O0" 50012 fi 50013 C_O_FLAG_NONE="-O0" 50014 elif test "x$TOOLCHAIN_TYPE" = xclang; then 50015 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 50016 # On MacOSX we optimize for size, something 50017 # we should do for all platforms? 50018 C_O_FLAG_HIGHEST_JVM="-Os" 50019 C_O_FLAG_HIGHEST="-Os" 50020 C_O_FLAG_HI="-Os" 50021 C_O_FLAG_NORM="-Os" 50022 C_O_FLAG_SIZE="-Os" 50023 else 50024 C_O_FLAG_HIGHEST_JVM="-O3" 50025 C_O_FLAG_HIGHEST="-O3" 50026 C_O_FLAG_HI="-O3" 50027 C_O_FLAG_NORM="-O2" 50028 C_O_FLAG_SIZE="-Os" 50029 fi 50030 C_O_FLAG_DEBUG="-O0" 50031 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 50032 C_O_FLAG_DEBUG_JVM="" 50033 elif test "x$OPENJDK_TARGET_OS" = xlinux; then 50034 C_O_FLAG_DEBUG_JVM="-O0" 50035 fi 50036 C_O_FLAG_NONE="-O0" 50037 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 50038 C_O_FLAG_HIGHEST_JVM="-O3 -qhot=level=1 -qinline -qinlglue" 50039 C_O_FLAG_HIGHEST="-O3 -qhot=level=1 -qinline -qinlglue" 50040 C_O_FLAG_HI="-O3 -qinline -qinlglue" 50041 C_O_FLAG_NORM="-O2" 50042 C_O_FLAG_DEBUG="-qnoopt" 50043 # FIXME: Value below not verified. 50044 C_O_FLAG_DEBUG_JVM="" 50045 C_O_FLAG_NONE="-qnoopt" 50046 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 50047 C_O_FLAG_HIGHEST_JVM="-O2 -Oy-" 50048 C_O_FLAG_HIGHEST="-O2" 50049 C_O_FLAG_HI="-O1" 50050 C_O_FLAG_NORM="-O1" 50051 C_O_FLAG_DEBUG="-Od" 50052 C_O_FLAG_DEBUG_JVM="" 50053 C_O_FLAG_NONE="-Od" 50054 C_O_FLAG_SIZE="-Os" 50055 fi 50056 CXX_O_FLAG_HIGHEST_JVM="$C_O_FLAG_HIGHEST_JVM" 50057 CXX_O_FLAG_HIGHEST="$C_O_FLAG_HIGHEST" 50058 CXX_O_FLAG_HI="$C_O_FLAG_HI" 50059 CXX_O_FLAG_NORM="$C_O_FLAG_NORM" 50060 CXX_O_FLAG_DEBUG="$C_O_FLAG_DEBUG" 50061 CXX_O_FLAG_DEBUG_JVM="$C_O_FLAG_DEBUG_JVM" 50062 CXX_O_FLAG_NONE="$C_O_FLAG_NONE" 50063 CXX_O_FLAG_SIZE="$C_O_FLAG_SIZE" 50064 fi 50065 50066 # Adjust optimization flags according to debug level. 50067 case $DEBUG_LEVEL in 50068 release ) 50069 # no adjustment 50070 ;; 50071 fastdebug ) 50072 # Not quite so much optimization 50073 C_O_FLAG_HI="$C_O_FLAG_NORM" 50074 CXX_O_FLAG_HI="$CXX_O_FLAG_NORM" 50075 ;; 50076 slowdebug ) 50077 # Disable optimization 50078 C_O_FLAG_HIGHEST_JVM="$C_O_FLAG_DEBUG_JVM" 50079 C_O_FLAG_HIGHEST="$C_O_FLAG_DEBUG" 50080 C_O_FLAG_HI="$C_O_FLAG_DEBUG" 50081 C_O_FLAG_NORM="$C_O_FLAG_DEBUG" 50082 C_O_FLAG_SIZE="$C_O_FLAG_DEBUG" 50083 CXX_O_FLAG_HIGHEST_JVM="$CXX_O_FLAG_DEBUG_JVM" 50084 CXX_O_FLAG_HIGHEST="$CXX_O_FLAG_DEBUG" 50085 CXX_O_FLAG_HI="$CXX_O_FLAG_DEBUG" 50086 CXX_O_FLAG_NORM="$CXX_O_FLAG_DEBUG" 50087 CXX_O_FLAG_SIZE="$CXX_O_FLAG_DEBUG" 50088 ;; 50089 esac 50090 50091 50092 50093 50094 50095 50096 50097 50098 50099 50100 50101 50102 50103 50104 50105 50106 50107 50108 50109 50110 # Check whether --with-abi-profile was given. 50111 if test "${with_abi_profile+set}" = set; then : 50112 withval=$with_abi_profile; 50113 fi 50114 50115 50116 if test "x$with_abi_profile" != x; then 50117 if test "x$OPENJDK_TARGET_CPU" != xarm && \ 50118 test "x$OPENJDK_TARGET_CPU" != xaarch64; then 50119 as_fn_error $? "--with-abi-profile only available on arm/aarch64" "$LINENO" 5 50120 fi 50121 50122 OPENJDK_TARGET_ABI_PROFILE=$with_abi_profile 50123 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ABI profle" >&5 50124 $as_echo_n "checking for ABI profle... " >&6; } 50125 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_TARGET_ABI_PROFILE" >&5 50126 $as_echo "$OPENJDK_TARGET_ABI_PROFILE" >&6; } 50127 50128 if test "x$OPENJDK_TARGET_ABI_PROFILE" = xarm-vfp-sflt; then 50129 ARM_FLOAT_TYPE=vfp-sflt 50130 ARM_ARCH_TYPE_FLAGS='-march=armv7-a -mthumb' 50131 elif test "x$OPENJDK_TARGET_ABI_PROFILE" = xarm-vfp-hflt; then 50132 ARM_FLOAT_TYPE=vfp-hflt 50133 ARM_ARCH_TYPE_FLAGS='-march=armv7-a -mthumb' 50134 elif test "x$OPENJDK_TARGET_ABI_PROFILE" = xarm-sflt; then 50135 ARM_FLOAT_TYPE=sflt 50136 ARM_ARCH_TYPE_FLAGS='-march=armv5t -marm' 50137 elif test "x$OPENJDK_TARGET_ABI_PROFILE" = xarmv5-vfp-sflt; then 50138 ARM_FLOAT_TYPE=vfp-sflt 50139 ARM_ARCH_TYPE_FLAGS='-march=armv5t -marm' 50140 elif test "x$OPENJDK_TARGET_ABI_PROFILE" = xarmv6-vfp-hflt; then 50141 ARM_FLOAT_TYPE=vfp-hflt 50142 ARM_ARCH_TYPE_FLAGS='-march=armv6 -marm' 50143 elif test "x$OPENJDK_TARGET_ABI_PROFILE" = xarm64; then 50144 # No special flags, just need to trigger setting JDK_ARCH_ABI_PROP_NAME 50145 ARM_FLOAT_TYPE= 50146 ARM_ARCH_TYPE_FLAGS= 50147 elif test "x$OPENJDK_TARGET_ABI_PROFILE" = xaarch64; then 50148 # No special flags, just need to trigger setting JDK_ARCH_ABI_PROP_NAME 50149 ARM_FLOAT_TYPE= 50150 ARM_ARCH_TYPE_FLAGS= 50151 else 50152 as_fn_error $? "Invalid ABI profile: \"$OPENJDK_TARGET_ABI_PROFILE\"" "$LINENO" 5 50153 fi 50154 50155 if test "x$ARM_FLOAT_TYPE" = xvfp-sflt; then 50156 ARM_FLOAT_TYPE_FLAGS='-mfloat-abi=softfp -mfpu=vfp -DFLOAT_ARCH=-vfp-sflt' 50157 elif test "x$ARM_FLOAT_TYPE" = xvfp-hflt; then 50158 ARM_FLOAT_TYPE_FLAGS='-mfloat-abi=hard -mfpu=vfp -DFLOAT_ARCH=-vfp-hflt' 50159 elif test "x$ARM_FLOAT_TYPE" = xsflt; then 50160 ARM_FLOAT_TYPE_FLAGS='-msoft-float -mfpu=vfp' 50161 fi 50162 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ARM_FLOAT_TYPE floating point flags" >&5 50163 $as_echo_n "checking for $ARM_FLOAT_TYPE floating point flags... " >&6; } 50164 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ARM_FLOAT_TYPE_FLAGS" >&5 50165 $as_echo "$ARM_FLOAT_TYPE_FLAGS" >&6; } 50166 50167 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for arch type flags" >&5 50168 $as_echo_n "checking for arch type flags... " >&6; } 50169 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ARM_ARCH_TYPE_FLAGS" >&5 50170 $as_echo "$ARM_ARCH_TYPE_FLAGS" >&6; } 50171 50172 # Now set JDK_ARCH_ABI_PROP_NAME. This is equivalent to the last part of the 50173 # autoconf target triplet. 50174 JDK_ARCH_ABI_PROP_NAME=`$ECHO $OPENJDK_TARGET_AUTOCONF_NAME | $SED -e 's/.*-\([^-]*\)$/\1/'` 50175 # Sanity check that it is a known ABI. 50176 if test "x$JDK_ARCH_ABI_PROP_NAME" != xgnu && \ 50177 test "x$JDK_ARCH_ABI_PROP_NAME" != xgnueabi && \ 50178 test "x$JDK_ARCH_ABI_PROP_NAME" != xgnueabihf; then 50179 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Unknown autoconf target triplet ABI: \"$JDK_ARCH_ABI_PROP_NAME\"" >&5 50180 $as_echo "$as_me: WARNING: Unknown autoconf target triplet ABI: \"$JDK_ARCH_ABI_PROP_NAME\"" >&2;} 50181 fi 50182 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ABI property name" >&5 50183 $as_echo_n "checking for ABI property name... " >&6; } 50184 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JDK_ARCH_ABI_PROP_NAME" >&5 50185 $as_echo "$JDK_ARCH_ABI_PROP_NAME" >&6; } 50186 50187 50188 # Pass these on to the open part of configure as if they were set using 50189 # --with-extra-c[xx]flags. 50190 EXTRA_CFLAGS="$EXTRA_CFLAGS $ARM_ARCH_TYPE_FLAGS $ARM_FLOAT_TYPE_FLAGS" 50191 EXTRA_CXXFLAGS="$EXTRA_CXXFLAGS $ARM_ARCH_TYPE_FLAGS $ARM_FLOAT_TYPE_FLAGS" 50192 # Get rid of annoying "note: the mangling of 'va_list' has changed in GCC 4.4" 50193 # FIXME: This should not really be set using extra_cflags. 50194 if test "x$OPENJDK_TARGET_CPU" = xarm; then 50195 EXTRA_CFLAGS="$EXTRA_CFLAGS -Wno-psabi" 50196 EXTRA_CXXFLAGS="$EXTRA_CXXFLAGS -Wno-psabi" 50197 fi 50198 # Also add JDK_ARCH_ABI_PROP_NAME define, but only to CFLAGS. 50199 EXTRA_CFLAGS="$EXTRA_CFLAGS -DJDK_ARCH_ABI_PROP_NAME='\"\$(JDK_ARCH_ABI_PROP_NAME)\"'" 50200 # And pass the architecture flags to the linker as well 50201 EXTRA_LDFLAGS="$EXTRA_LDFLAGS $ARM_ARCH_TYPE_FLAGS $ARM_FLOAT_TYPE_FLAGS" 50202 fi 50203 50204 # When building with an abi profile, the name of that profile is appended on the 50205 # bundle platform, which is used in bundle names. 50206 if test "x$OPENJDK_TARGET_ABI_PROFILE" != x; then 50207 OPENJDK_TARGET_BUNDLE_PLATFORM="$OPENJDK_TARGET_OS_BUNDLE-$OPENJDK_TARGET_ABI_PROFILE" 50208 fi 50209 50210 50211 # Special extras... 50212 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 50213 if test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then 50214 CFLAGS_JDKLIB_EXTRA="${CFLAGS_JDKLIB_EXTRA} -xregs=no%appl" 50215 CXXFLAGS_JDKLIB_EXTRA="${CXXFLAGS_JDKLIB_EXTRA} -xregs=no%appl" 50216 fi 50217 CFLAGS_JDKLIB_EXTRA="${CFLAGS_JDKLIB_EXTRA} -errtags=yes -errfmt" 50218 CXXFLAGS_JDKLIB_EXTRA="${CXXFLAGS_JDKLIB_EXTRA} -errtags=yes -errfmt" 50219 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 50220 CFLAGS_JDK="${CFLAGS_JDK} -qchars=signed -qfullpath -qsaveopt" 50221 CXXFLAGS_JDK="${CXXFLAGS_JDK} -qchars=signed -qfullpath -qsaveopt" 50222 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 50223 CXXSTD_CXXFLAG="-std=gnu++98" 50224 50225 50226 50227 50228 50229 50230 50231 50232 50233 50234 50235 50236 50237 50238 50239 50240 50241 50242 50243 50244 50245 50246 50247 50248 50249 50250 50251 50252 50253 50254 50255 50256 50257 50258 50259 50260 50261 50262 50263 50264 50265 50266 # Execute function body 50267 50268 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"$CXXSTD_CXXFLAG -Werror\"" >&5 50269 $as_echo_n "checking if the C++ compiler supports \"$CXXSTD_CXXFLAG -Werror\"... " >&6; } 50270 supports=yes 50271 50272 saved_cxxflags="$CXXFLAGS" 50273 CXXFLAGS="$CXXFLAG $CXXSTD_CXXFLAG -Werror" 50274 ac_ext=cpp 50275 ac_cpp='$CXXCPP $CPPFLAGS' 50276 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 50277 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 50278 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 50279 50280 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 50281 /* end confdefs.h. */ 50282 int i; 50283 _ACEOF 50284 if ac_fn_cxx_try_compile "$LINENO"; then : 50285 50286 else 50287 supports=no 50288 fi 50289 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 50290 ac_ext=cpp 50291 ac_cpp='$CXXCPP $CPPFLAGS' 50292 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 50293 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 50294 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 50295 50296 CXXFLAGS="$saved_cxxflags" 50297 50298 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 50299 $as_echo "$supports" >&6; } 50300 if test "x$supports" = "xyes" ; then 50301 : 50302 50303 else 50304 : 50305 CXXSTD_CXXFLAG="" 50306 fi 50307 50308 50309 50310 50311 50312 50313 50314 50315 50316 50317 50318 50319 CXXFLAGS_JDK="${CXXFLAGS_JDK} ${CXXSTD_CXXFLAG}" 50320 JVM_CFLAGS="${JVM_CFLAGS} ${CXXSTD_CXXFLAG}" 50321 50322 fi 50323 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 50324 CFLAGS_JDK="${CFLAGS_JDK} -D__solaris__" 50325 CXXFLAGS_JDK="${CXXFLAGS_JDK} -D__solaris__" 50326 fi 50327 50328 CFLAGS_JDK="${CFLAGS_JDK} ${EXTRA_CFLAGS}" 50329 CXXFLAGS_JDK="${CXXFLAGS_JDK} ${EXTRA_CXXFLAGS}" 50330 LDFLAGS_JDK="${LDFLAGS_JDK} ${EXTRA_LDFLAGS}" 50331 50332 ############################################################################### 50333 # 50334 # Now setup the CFLAGS and LDFLAGS for the JDK build. 50335 # Later we will also have CFLAGS and LDFLAGS for the hotspot subrepo build. 50336 # 50337 50338 # Setup compiler/platform specific flags into 50339 # CFLAGS_JDK - C Compiler flags 50340 # CXXFLAGS_JDK - C++ Compiler flags 50341 # COMMON_CCXXFLAGS_JDK - common to C and C++ 50342 if test "x$TOOLCHAIN_TYPE" = xgcc; then 50343 JVM_CFLAGS="$JVM_CFLAGS -D_GNU_SOURCE" 50344 JVM_CFLAGS="$JVM_CFLAGS -D_REENTRANT" 50345 JVM_CFLAGS="$JVM_CFLAGS -fcheck-new" 50346 if test "x$OPENJDK_TARGET_CPU" = xx86; then 50347 # Force compatibility with i586 on 32 bit intel platforms. 50348 COMMON_CCXXFLAGS="${COMMON_CCXXFLAGS} -march=i586" 50349 JVM_CFLAGS="$JVM_CFLAGS -march=i586" 50350 fi 50351 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS $COMMON_CCXXFLAGS_JDK -Wall -Wextra -Wno-unused -Wno-unused-parameter -Wformat=2 \ 50352 -pipe -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE" 50353 case $OPENJDK_TARGET_CPU_ARCH in 50354 arm ) 50355 # on arm we don't prevent gcc to omit frame pointer but do prevent strict aliasing 50356 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 50357 COMMON_CCXXFLAGS_JDK="${COMMON_CCXXFLAGS_JDK} -fsigned-char" 50358 ;; 50359 ppc ) 50360 # on ppc we don't prevent gcc to omit frame pointer but do prevent strict aliasing 50361 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 50362 ;; 50363 s390 ) 50364 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer -mbackchain -march=z10" 50365 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 50366 ;; 50367 * ) 50368 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer" 50369 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 50370 ;; 50371 esac 50372 50373 50374 50375 50376 50377 50378 50379 50380 50381 50382 50383 50384 50385 50386 50387 50388 50389 50390 50391 50392 50393 50394 50395 50396 50397 50398 50399 50400 50401 50402 50403 50404 50405 50406 50407 50408 50409 50410 50411 50412 50413 50414 50415 50416 50417 50418 50419 50420 50421 50422 50423 50424 50425 50426 # Execute function body 50427 50428 # Need to assign to a variable since m4 is blocked from modifying parts in []. 50429 REFERENCE_VERSION=6 50430 50431 if [[ "$REFERENCE_VERSION" =~ (.*\.){4} ]] ; then 50432 as_fn_error $? "Internal error: Cannot compare to 6, only four parts (W.X.Y.Z) is supported" "$LINENO" 5 50433 fi 50434 50435 if [[ "$REFERENCE_VERSION" =~ [0-9]{6} ]] ; then 50436 as_fn_error $? "Internal error: Cannot compare to 6, only parts < 99999 is supported" "$LINENO" 5 50437 fi 50438 50439 # Version comparison method inspired by http://stackoverflow.com/a/24067243 50440 COMPARABLE_REFERENCE_VERSION=`$AWK -F. '{ printf("%05d%05d%05d%05d\n", $1, $2, $3, $4) }' <<< "$REFERENCE_VERSION"` 50441 50442 if test $COMPARABLE_ACTUAL_VERSION -ge $COMPARABLE_REFERENCE_VERSION ; then 50443 : 50444 50445 # These flags are required for GCC 6 builds as undefined behaviour in OpenJDK code 50446 # runs afoul of the more aggressive versions of these optimisations. 50447 # Notably, value range propagation now assumes that the this pointer of C++ 50448 # member functions is non-null. 50449 NO_DELETE_NULL_POINTER_CHECKS_CFLAG="-fno-delete-null-pointer-checks" 50450 NO_LIFETIME_DSE_CFLAG="-fno-lifetime-dse" 50451 { $as_echo "$as_me:${as_lineno-$LINENO}: GCC >= 6 detected; adding ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} and ${NO_LIFETIME_DSE_CFLAG}" >&5 50452 $as_echo "$as_me: GCC >= 6 detected; adding ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} and ${NO_LIFETIME_DSE_CFLAG}" >&6;} 50453 CFLAGS_JDK="$CFLAGS_JDK ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} ${NO_LIFETIME_DSE_CFLAG}" 50454 JVM_CFLAGS="$JVM_CFLAGS ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} ${NO_LIFETIME_DSE_CFLAG}" 50455 50456 else 50457 : 50458 50459 fi 50460 50461 50462 50463 50464 50465 50466 50467 50468 50469 50470 50471 50472 50473 50474 elif test "x$TOOLCHAIN_TYPE" = xclang; then 50475 JVM_CFLAGS="$JVM_CFLAGS -D_GNU_SOURCE" 50476 50477 # Restrict the debug information created by Clang to avoid 50478 # too big object files and speed the build up a little bit 50479 # (see http://llvm.org/bugs/show_bug.cgi?id=7554) 50480 JVM_CFLAGS="$JVM_CFLAGS -flimit-debug-info" 50481 if test "x$OPENJDK_TARGET_OS" = xlinux; then 50482 if test "x$OPENJDK_TARGET_CPU" = xx86; then 50483 # Force compatibility with i586 on 32 bit intel platforms. 50484 COMMON_CCXXFLAGS="${COMMON_CCXXFLAGS} -march=i586" 50485 JVM_CFLAGS="$JVM_CFLAGS -march=i586" 50486 fi 50487 JVM_CFLAGS="$JVM_CFLAGS -Wno-sometimes-uninitialized" 50488 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS $COMMON_CCXXFLAGS_JDK -Wall -Wextra -Wno-unused -Wno-unused-parameter -Wformat=2 \ 50489 -pipe -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE" 50490 case $OPENJDK_TARGET_CPU_ARCH in 50491 ppc ) 50492 # on ppc we don't prevent gcc to omit frame pointer but do prevent strict aliasing 50493 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 50494 ;; 50495 * ) 50496 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer" 50497 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 50498 ;; 50499 esac 50500 fi 50501 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 50502 JVM_CFLAGS="$JVM_CFLAGS -DSPARC_WORKS" 50503 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS $COMMON_CCXXFLAGS_JDK -DTRACING -DMACRO_MEMSYS_OPS -DBREAKPTS" 50504 if test "x$OPENJDK_TARGET_CPU_ARCH" = xx86; then 50505 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DcpuIntel -Di586 -D$OPENJDK_TARGET_CPU_LEGACY_LIB" 50506 fi 50507 50508 CFLAGS_JDK="$CFLAGS_JDK -xc99=%none -xCC -errshort=tags -Xa -v -mt -W0,-noglobal" 50509 CXXFLAGS_JDK="$CXXFLAGS_JDK -errtags=yes +w -mt -features=no%except -DCC_NOEX -norunpath -xnolib" 50510 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 50511 JVM_CFLAGS="$JVM_CFLAGS -D_REENTRANT -D__STDC_FORMAT_MACROS" 50512 CFLAGS_JDK="$CFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC" 50513 CXXFLAGS_JDK="$CXXFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC" 50514 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 50515 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS $COMMON_CCXXFLAGS_JDK \ 50516 -MD -Zc:wchar_t- -W3 -wd4800 \ 50517 -DWIN32_LEAN_AND_MEAN \ 50518 -D_CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE \ 50519 -D_WINSOCK_DEPRECATED_NO_WARNINGS \ 50520 -DWIN32 -DIAL" 50521 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 50522 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_AMD64_ -Damd64" 50523 else 50524 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_X86_ -Dx86" 50525 fi 50526 # If building with Visual Studio 2010, we can still use _STATIC_CPPLIB to 50527 # avoid bundling msvcpNNN.dll. Doesn't work with newer versions of visual 50528 # studio. 50529 if test "x$TOOLCHAIN_VERSION" = "x2010"; then 50530 STATIC_CPPLIB_FLAGS="-D_STATIC_CPPLIB -D_DISABLE_DEPRECATE_STATIC_CPPLIB" 50531 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK $STATIC_CPPLIB_FLAGS" 50532 JVM_CFLAGS="$JVM_CFLAGS $STATIC_CPPLIB_FLAGS" 50533 fi 50534 fi 50535 50536 ############################################################################### 50537 50538 # Adjust flags according to debug level. 50539 case $DEBUG_LEVEL in 50540 fastdebug | slowdebug ) 50541 CFLAGS_JDK="$CFLAGS_JDK $CFLAGS_DEBUG_SYMBOLS $CFLAGS_DEBUG_OPTIONS" 50542 CXXFLAGS_JDK="$CXXFLAGS_JDK $CXXFLAGS_DEBUG_SYMBOLS $CXXFLAGS_DEBUG_OPTIONS" 50543 ;; 50544 release ) 50545 ;; 50546 * ) 50547 as_fn_error $? "Unrecognized \$DEBUG_LEVEL: $DEBUG_LEVEL" "$LINENO" 5 50548 ;; 50549 esac 50550 50551 # Set some common defines. These works for all compilers, but assume 50552 # -D is universally accepted. 50553 50554 # Setup endianness 50555 if test "x$OPENJDK_TARGET_CPU_ENDIAN" = xlittle; then 50556 # The macro _LITTLE_ENDIAN needs to be defined the same to avoid the 50557 # Sun C compiler warning message: warning: macro redefined: _LITTLE_ENDIAN 50558 # (The Solaris X86 system defines this in file /usr/include/sys/isa_defs.h). 50559 # Note: -Dmacro is the same as #define macro 1 50560 # -Dmacro= is the same as #define macro 50561 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 50562 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_LITTLE_ENDIAN=" 50563 else 50564 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_LITTLE_ENDIAN" 50565 fi 50566 else 50567 # Same goes for _BIG_ENDIAN. Do we really need to set *ENDIAN on Solaris if they 50568 # are defined in the system? 50569 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 50570 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_BIG_ENDIAN=" 50571 else 50572 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_BIG_ENDIAN" 50573 fi 50574 fi 50575 50576 # Setup target OS define. Use OS target name but in upper case. 50577 OPENJDK_TARGET_OS_UPPERCASE=`$ECHO $OPENJDK_TARGET_OS | $TR 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` 50578 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D$OPENJDK_TARGET_OS_UPPERCASE" 50579 50580 # Setup target CPU 50581 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK \ 50582 $OPENJDK_TARGET_ADD_LP64 \ 50583 -DARCH='\"$OPENJDK_TARGET_CPU_LEGACY\"' -D$OPENJDK_TARGET_CPU_LEGACY" 50584 50585 # Setup debug/release defines 50586 if test "x$DEBUG_LEVEL" = xrelease; then 50587 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DNDEBUG" 50588 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 50589 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DTRIMMED" 50590 fi 50591 else 50592 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DDEBUG" 50593 fi 50594 50595 # Set some additional per-OS defines. 50596 if test "x$OPENJDK_TARGET_OS" = xlinux; then 50597 JVM_CFLAGS="$JVM_CFLAGS -DLINUX" 50598 JVM_CFLAGS="$JVM_CFLAGS -pipe $PICFLAG -fno-rtti -fno-exceptions \ 50599 -fvisibility=hidden -fno-strict-aliasing -fno-omit-frame-pointer" 50600 elif test "x$OPENJDK_TARGET_OS" = xsolaris; then 50601 JVM_CFLAGS="$JVM_CFLAGS -DSOLARIS" 50602 JVM_CFLAGS="$JVM_CFLAGS -template=no%extdef -features=no%split_init \ 50603 -D_Crun_inline_placement -library=%none $PICFLAG -mt -features=no%except" 50604 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 50605 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE -D_DARWIN_UNLIMITED_SELECT" 50606 JVM_CFLAGS="$JVM_CFLAGS -D_ALLBSD_SOURCE" 50607 JVM_CFLAGS="$JVM_CFLAGS -D_DARWIN_C_SOURCE -D_XOPEN_SOURCE" 50608 JVM_CFLAGS="$JVM_CFLAGS -fno-rtti -fno-exceptions -fvisibility=hidden \ 50609 -mno-omit-leaf-frame-pointer -mstack-alignment=16 -pipe -fno-strict-aliasing \ 50610 -DMAC_OS_X_VERSION_MAX_ALLOWED=1070 -mmacosx-version-min=10.7.0 \ 50611 -fno-omit-frame-pointer" 50612 elif test "x$OPENJDK_TARGET_OS" = xaix; then 50613 JVM_CFLAGS="$JVM_CFLAGS -DAIX" 50614 # We may need '-qminimaltoc' or '-qpic=large -bbigtoc' if the TOC overflows. 50615 JVM_CFLAGS="$JVM_CFLAGS -qtune=balanced \ 50616 -qalias=noansi -qstrict -qtls=default -qlanglvl=c99vla \ 50617 -qlanglvl=noredefmac -qnortti -qnoeh -qignerrno" 50618 elif test "x$OPENJDK_TARGET_OS" = xbsd; then 50619 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE" 50620 elif test "x$OPENJDK_TARGET_OS" = xwindows; then 50621 JVM_CFLAGS="$JVM_CFLAGS -D_WINDOWS -DWIN32 -D_JNI_IMPLEMENTATION_" 50622 JVM_CFLAGS="$JVM_CFLAGS -nologo -W3 -MD -MP" 50623 fi 50624 50625 # Set some additional per-CPU defines. 50626 if test "x$OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" = xwindows-x86; then 50627 JVM_CFLAGS="$JVM_CFLAGS -arch:IA32" 50628 elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then 50629 JVM_CFLAGS="$JVM_CFLAGS -xarch=sparc" 50630 elif test "x$OPENJDK_TARGET_CPU" = xppc64; then 50631 if test "x$OPENJDK_TARGET_OS" = xlinux; then 50632 JVM_CFLAGS="$JVM_CFLAGS -minsert-sched-nops=regroup_exact -mno-multiple -mno-string" 50633 # fixes `relocation truncated to fit' error for gcc 4.1. 50634 JVM_CFLAGS="$JVM_CFLAGS -mminimal-toc" 50635 # Use ppc64 instructions, but schedule for power5 50636 JVM_CFLAGS="$JVM_CFLAGS -mcpu=powerpc64 -mtune=power5" 50637 elif test "x$OPENJDK_TARGET_OS" = xaix; then 50638 JVM_CFLAGS="$JVM_CFLAGS -qarch=ppc64" 50639 fi 50640 elif test "x$OPENJDK_TARGET_CPU" = xppc64le; then 50641 if test "x$OPENJDK_TARGET_OS" = xlinux; then 50642 JVM_CFLAGS="$JVM_CFLAGS -minsert-sched-nops=regroup_exact -mno-multiple -mno-string" 50643 # Little endian machine uses ELFv2 ABI. 50644 JVM_CFLAGS="$JVM_CFLAGS -DABI_ELFv2" 50645 # Use Power8, this is the first CPU to support PPC64 LE with ELFv2 ABI. 50646 JVM_CFLAGS="$JVM_CFLAGS -mcpu=power8 -mtune=power8" 50647 fi 50648 elif test "x$OPENJDK_TARGET_CPU" = xs390x; then 50649 if test "x$OPENJDK_TARGET_OS" = xlinux; then 50650 JVM_CFLAGS="$JVM_CFLAGS -mbackchain -march=z10" 50651 fi 50652 fi 50653 50654 if test "x$OPENJDK_TARGET_CPU_ENDIAN" = xlittle; then 50655 JVM_CFLAGS="$JVM_CFLAGS -DVM_LITTLE_ENDIAN" 50656 fi 50657 50658 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 50659 if test "x$OPENJDK_TARGET_OS" != xsolaris && test "x$OPENJDK_TARGET_OS" != xaix; then 50660 # Solaris does not have _LP64=1 in the old build. 50661 # xlc on AIX defines _LP64=1 by default and issues a warning if we redefine it. 50662 JVM_CFLAGS="$JVM_CFLAGS -D_LP64=1" 50663 fi 50664 fi 50665 50666 # Set JVM_CFLAGS warning handling 50667 if test "x$OPENJDK_TARGET_OS" = xlinux; then 50668 JVM_CFLAGS="$JVM_CFLAGS -Wpointer-arith -Wsign-compare -Wunused-function \ 50669 -Wunused-value -Woverloaded-virtual" 50670 50671 if test "x$TOOLCHAIN_TYPE" = xgcc; then 50672 50673 50674 50675 50676 50677 50678 50679 50680 50681 50682 50683 50684 50685 50686 50687 50688 50689 50690 50691 50692 50693 50694 50695 50696 50697 50698 50699 50700 50701 50702 50703 50704 50705 50706 50707 50708 50709 50710 50711 50712 50713 50714 50715 50716 50717 50718 50719 50720 50721 50722 50723 50724 50725 50726 # Execute function body 50727 50728 # Need to assign to a variable since m4 is blocked from modifying parts in []. 50729 REFERENCE_VERSION=4.8 50730 50731 if [[ "$REFERENCE_VERSION" =~ (.*\.){4} ]] ; then 50732 as_fn_error $? "Internal error: Cannot compare to 4.8, only four parts (W.X.Y.Z) is supported" "$LINENO" 5 50733 fi 50734 50735 if [[ "$REFERENCE_VERSION" =~ [0-9]{6} ]] ; then 50736 as_fn_error $? "Internal error: Cannot compare to 4.8, only parts < 99999 is supported" "$LINENO" 5 50737 fi 50738 50739 # Version comparison method inspired by http://stackoverflow.com/a/24067243 50740 COMPARABLE_REFERENCE_VERSION=`$AWK -F. '{ printf("%05d%05d%05d%05d\n", $1, $2, $3, $4) }' <<< "$REFERENCE_VERSION"` 50741 50742 if test $COMPARABLE_ACTUAL_VERSION -ge $COMPARABLE_REFERENCE_VERSION ; then 50743 : 50744 50745 # These flags either do not work or give spurious warnings prior to gcc 4.8. 50746 JVM_CFLAGS="$JVM_CFLAGS -Wno-format-zero-length -Wtype-limits -Wuninitialized" 50747 50748 50749 else 50750 : 50751 50752 fi 50753 50754 50755 50756 50757 50758 50759 50760 50761 50762 50763 50764 50765 50766 50767 fi 50768 if ! [[ " $JVM_VARIANTS " =~ " zero " ]] && ! [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 50769 # Non-zero builds have stricter warnings 50770 JVM_CFLAGS="$JVM_CFLAGS -Wreturn-type -Wundef -Wformat=2" 50771 else 50772 if test "x$TOOLCHAIN_TYPE" = xclang; then 50773 # Some versions of llvm do not like -Wundef 50774 JVM_CFLAGS="$JVM_CFLAGS -Wno-undef" 50775 fi 50776 fi 50777 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 50778 JVM_CFLAGS="$JVM_CFLAGS -Wno-deprecated -Wpointer-arith \ 50779 -Wsign-compare -Wundef -Wunused-function -Wformat=2" 50780 fi 50781 50782 # Additional macosx handling 50783 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 50784 # Setting these parameters makes it an error to link to macosx APIs that are 50785 # newer than the given OS version and makes the linked binaries compatible 50786 # even if built on a newer version of the OS. 50787 # The expected format is X.Y.Z 50788 MACOSX_VERSION_MIN=10.7.0 50789 50790 50791 # The macro takes the version with no dots, ex: 1070 50792 # Let the flags variables get resolved in make for easier override on make 50793 # command line. 50794 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DMAC_OS_X_VERSION_MAX_ALLOWED=\$(subst .,,\$(MACOSX_VERSION_MIN)) -mmacosx-version-min=\$(MACOSX_VERSION_MIN)" 50795 LDFLAGS_JDK="$LDFLAGS_JDK -mmacosx-version-min=\$(MACOSX_VERSION_MIN)" 50796 fi 50797 50798 # Setup some hard coded includes 50799 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK \ 50800 -I\$(SUPPORT_OUTPUTDIR)/modules_include/java.base \ 50801 -I${JDK_TOPDIR}/src/java.base/share/native/include \ 50802 -I${JDK_TOPDIR}/src/java.base/$OPENJDK_TARGET_OS/native/include \ 50803 -I${JDK_TOPDIR}/src/java.base/$OPENJDK_TARGET_OS_TYPE/native/include \ 50804 -I${JDK_TOPDIR}/src/java.base/share/native/libjava \ 50805 -I${JDK_TOPDIR}/src/java.base/$OPENJDK_TARGET_OS_TYPE/native/libjava" 50806 50807 # The shared libraries are compiled using the picflag. 50808 CFLAGS_JDKLIB="$COMMON_CCXXFLAGS_JDK \ 50809 $CFLAGS_JDK $EXTRA_CFLAGS_JDK $PICFLAG $CFLAGS_JDKLIB_EXTRA" 50810 CXXFLAGS_JDKLIB="$COMMON_CCXXFLAGS_JDK \ 50811 $CXXFLAGS_JDK $EXTRA_CXXFLAGS_JDK $PICFLAG $CXXFLAGS_JDKLIB_EXTRA" 50812 50813 # Executable flags 50814 CFLAGS_JDKEXE="$COMMON_CCXXFLAGS_JDK $CFLAGS_JDK $EXTRA_CFLAGS_JDK" 50815 CXXFLAGS_JDKEXE="$COMMON_CCXXFLAGS_JDK $CXXFLAGS_JDK $EXTRA_CXXFLAGS_JDK" 50816 50817 50818 50819 50820 50821 50822 # Setup LDFLAGS et al. 50823 # 50824 50825 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 50826 LDFLAGS_MICROSOFT="-nologo -opt:ref" 50827 LDFLAGS_JDK="$LDFLAGS_JDK $LDFLAGS_MICROSOFT -incremental:no" 50828 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_MICROSOFT -opt:icf,8 -subsystem:windows -base:0x8000000" 50829 if test "x$OPENJDK_TARGET_CPU_BITS" = "x32"; then 50830 LDFLAGS_SAFESH="-safeseh" 50831 LDFLAGS_JDK="$LDFLAGS_JDK $LDFLAGS_SAFESH" 50832 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_SAFESH" 50833 # NOTE: Old build added -machine. Probably not needed. 50834 JVM_LDFLAGS="$JVM_LDFLAGS -machine:I386" 50835 else 50836 JVM_LDFLAGS="$JVM_LDFLAGS -machine:AMD64" 50837 fi 50838 elif test "x$TOOLCHAIN_TYPE" = xclang; then 50839 JVM_LDFLAGS="$JVM_LDFLAGS -mno-omit-leaf-frame-pointer -mstack-alignment=16 -stdlib=libstdc++ -fPIC" 50840 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 50841 # FIXME: We should really generalize SET_SHARED_LIBRARY_ORIGIN instead. 50842 JVM_LDFLAGS="$JVM_LDFLAGS -Wl,-rpath,@loader_path/. -Wl,-rpath,@loader_path/.." 50843 fi 50844 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 50845 # If this is a --hash-style=gnu system, use --hash-style=both, why? 50846 # We have previously set HAS_GNU_HASH if this is the case 50847 if test -n "$HAS_GNU_HASH"; then 50848 LDFLAGS_HASH_STYLE="-Wl,--hash-style=both" 50849 LDFLAGS_JDK="${LDFLAGS_JDK} $LDFLAGS_HASH_STYLE" 50850 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_HASH_STYLE" 50851 fi 50852 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 50853 JVM_LDFLAGS="$JVM_LDFLAGS -Wl,-rpath,@loader_path/. -Wl,-rpath,@loader_path/.." 50854 fi 50855 if test "x$OPENJDK_TARGET_OS" = xlinux; then 50856 # And since we now know that the linker is gnu, then add -z defs, to forbid 50857 # undefined symbols in object files. 50858 LDFLAGS_NO_UNDEF_SYM="-Wl,-z,defs" 50859 LDFLAGS_JDK="${LDFLAGS_JDK} $LDFLAGS_NO_UNDEF_SYM" 50860 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_NO_UNDEF_SYM" 50861 LDFLAGS_NO_EXEC_STACK="-Wl,-z,noexecstack" 50862 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_NO_EXEC_STACK" 50863 if test "x$OPENJDK_TARGET_CPU" = xx86; then 50864 JVM_LDFLAGS="$JVM_LDFLAGS -march=i586" 50865 fi 50866 case $DEBUG_LEVEL in 50867 release ) 50868 # tell linker to optimize libraries. 50869 # Should this be supplied to the OSS linker as well? 50870 LDFLAGS_DEBUGLEVEL_release="-Wl,-O1" 50871 LDFLAGS_JDK="${LDFLAGS_JDK} $LDFLAGS_DEBUGLEVEL_release" 50872 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_DEBUGLEVEL_release" 50873 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 50874 JVM_LDFLAGS="$JVM_LDFLAGS $LINKER_RELRO_FLAG" 50875 fi 50876 ;; 50877 slowdebug ) 50878 # Hotspot always let the linker optimize 50879 JVM_LDFLAGS="$JVM_LDFLAGS -Wl,-O1" 50880 if test "x$HAS_LINKER_NOW" = "xtrue"; then 50881 # do relocations at load 50882 LDFLAGS_JDK="$LDFLAGS_JDK $LINKER_NOW_FLAG" 50883 LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK $LINKER_NOW_FLAG" 50884 JVM_LDFLAGS="$JVM_LDFLAGS $LINKER_NOW_FLAG" 50885 fi 50886 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 50887 # mark relocations read only 50888 LDFLAGS_JDK="$LDFLAGS_JDK $LINKER_RELRO_FLAG" 50889 LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK $LINKER_RELRO_FLAG" 50890 JVM_LDFLAGS="$JVM_LDFLAGS $LINKER_RELRO_FLAG" 50891 fi 50892 ;; 50893 fastdebug ) 50894 # Hotspot always let the linker optimize 50895 JVM_LDFLAGS="$JVM_LDFLAGS -Wl,-O1" 50896 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 50897 # mark relocations read only 50898 LDFLAGS_JDK="$LDFLAGS_JDK $LINKER_RELRO_FLAG" 50899 LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK $LINKER_RELRO_FLAG" 50900 JVM_LDFLAGS="$JVM_LDFLAGS $LINKER_RELRO_FLAG" 50901 fi 50902 ;; 50903 * ) 50904 as_fn_error $? "Unrecognized \$DEBUG_LEVEL: $DEBUG_LEVEL" "$LINENO" 5 50905 ;; 50906 esac 50907 fi 50908 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 50909 LDFLAGS_SOLSTUDIO="-Wl,-z,defs" 50910 LDFLAGS_JDK="$LDFLAGS_JDK $LDFLAGS_SOLSTUDIO -ztext" 50911 LDFLAGS_CXX_SOLSTUDIO="-norunpath" 50912 LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK $LDFLAGS_CXX_SOLSTUDIO -xnolib" 50913 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_SOLSTUDIO -library=%none -mt $LDFLAGS_CXX_SOLSTUDIO -z noversion" 50914 if test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then 50915 JVM_LDFLAGS="$JVM_LDFLAGS -xarch=sparc" 50916 fi 50917 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 50918 LDFLAGS_XLC="-b64 -brtl -bnolibpath -bexpall -bernotok" 50919 LDFLAGS_JDK="${LDFLAGS_JDK} $LDFLAGS_XLC" 50920 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_XLC" 50921 fi 50922 50923 # Customize LDFLAGS for executables 50924 50925 LDFLAGS_JDKEXE="${LDFLAGS_JDK}" 50926 50927 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 50928 if test "x$OPENJDK_TARGET_CPU_BITS" = "x64"; then 50929 LDFLAGS_STACK_SIZE=1048576 50930 else 50931 LDFLAGS_STACK_SIZE=327680 50932 fi 50933 LDFLAGS_JDKEXE="${LDFLAGS_JDKEXE} /STACK:$LDFLAGS_STACK_SIZE" 50934 elif test "x$OPENJDK_TARGET_OS" = xlinux; then 50935 LDFLAGS_JDKEXE="$LDFLAGS_JDKEXE -Wl,--allow-shlib-undefined" 50936 fi 50937 50938 LDFLAGS_JDKEXE="${LDFLAGS_JDKEXE} ${EXTRA_LDFLAGS_JDK}" 50939 50940 # Customize LDFLAGS for libs 50941 LDFLAGS_JDKLIB="${LDFLAGS_JDK}" 50942 50943 LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} ${SHARED_LIBRARY_FLAGS}" 50944 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 50945 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} \ 50946 -libpath:${OUTPUT_ROOT}/support/modules_libs/java.base" 50947 JDKLIB_LIBS="" 50948 else 50949 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} \ 50950 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base" 50951 50952 if test "xTARGET" = "xTARGET"; then 50953 # On some platforms (mac) the linker warns about non existing -L dirs. 50954 # For any of the variants server, client or minimal, the dir matches the 50955 # variant name. The "main" variant should be used for linking. For the 50956 # rest, the dir is just server. 50957 if [[ " $JVM_VARIANTS " =~ " server " ]] || [[ " $JVM_VARIANTS " =~ " client " ]] \ 50958 || [[ " $JVM_VARIANTS " =~ " minimal " ]] ; then 50959 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} \ 50960 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base/$JVM_VARIANT_MAIN" 50961 else 50962 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} \ 50963 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base/server" 50964 fi 50965 elif test "xTARGET" = "xBUILD"; then 50966 # When building a buildjdk, it's always only the server variant 50967 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} \ 50968 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base/server" 50969 fi 50970 50971 JDKLIB_LIBS="-ljava -ljvm" 50972 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 50973 JDKLIB_LIBS="$JDKLIB_LIBS -lc" 50974 fi 50975 50976 fi 50977 50978 LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} ${JAVA_BASE_LDFLAGS}" 50979 50980 # Set JVM_LIBS (per os) 50981 if test "x$OPENJDK_TARGET_OS" = xlinux; then 50982 JVM_LIBS="$JVM_LIBS -lm -ldl -lpthread" 50983 elif test "x$OPENJDK_TARGET_OS" = xsolaris; then 50984 # FIXME: This hard-coded path is not really proper. 50985 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 50986 SOLARIS_LIBM_LIBS="/usr/lib/amd64/libm.so.1" 50987 elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then 50988 SOLARIS_LIBM_LIBS="/usr/lib/sparcv9/libm.so.1" 50989 fi 50990 JVM_LIBS="$JVM_LIBS -lsocket -lsched -ldl $SOLARIS_LIBM_LIBS -lCrun \ 50991 -lthread -ldoor -lc -ldemangle -lnsl -lkstat -lrt" 50992 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 50993 JVM_LIBS="$JVM_LIBS -lm" 50994 elif test "x$OPENJDK_TARGET_OS" = xaix; then 50995 JVM_LIBS="$JVM_LIBS -Wl,-lC_r -lm -ldl -lpthread" 50996 elif test "x$OPENJDK_TARGET_OS" = xbsd; then 50997 JVM_LIBS="$JVM_LIBS -lm" 50998 elif test "x$OPENJDK_TARGET_OS" = xwindows; then 50999 JVM_LIBS="$JVM_LIBS kernel32.lib user32.lib gdi32.lib winspool.lib \ 51000 comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib \ 51001 wsock32.lib winmm.lib version.lib psapi.lib" 51002 fi 51003 51004 # Set JVM_ASFLAGS 51005 if test "x$OPENJDK_TARGET_OS" = xlinux; then 51006 if test "x$OPENJDK_TARGET_CPU" = xx86; then 51007 JVM_ASFLAGS="$JVM_ASFLAGS -march=i586" 51008 fi 51009 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 51010 JVM_ASFLAGS="$JVM_ASFLAGS -x assembler-with-cpp -mno-omit-leaf-frame-pointer -mstack-alignment=16" 51011 fi 51012 51013 LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} ${EXTRA_LDFLAGS_JDK}" 51014 51015 51016 51017 51018 51019 51020 51021 51022 51023 51024 51025 51026 51027 51028 51029 # Special extras... 51030 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 51031 if test "x$OPENJDK_BUILD_CPU_ARCH" = "xsparc"; then 51032 OPENJDK_BUILD_CFLAGS_JDKLIB_EXTRA="${OPENJDK_BUILD_CFLAGS_JDKLIB_EXTRA} -xregs=no%appl" 51033 OPENJDK_BUILD_CXXFLAGS_JDKLIB_EXTRA="${OPENJDK_BUILD_CXXFLAGS_JDKLIB_EXTRA} -xregs=no%appl" 51034 fi 51035 OPENJDK_BUILD_CFLAGS_JDKLIB_EXTRA="${OPENJDK_BUILD_CFLAGS_JDKLIB_EXTRA} -errtags=yes -errfmt" 51036 OPENJDK_BUILD_CXXFLAGS_JDKLIB_EXTRA="${OPENJDK_BUILD_CXXFLAGS_JDKLIB_EXTRA} -errtags=yes -errfmt" 51037 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 51038 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -qchars=signed -qfullpath -qsaveopt" 51039 OPENJDK_BUILD_CXXFLAGS_JDK="${OPENJDK_BUILD_CXXFLAGS_JDK} -qchars=signed -qfullpath -qsaveopt" 51040 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 51041 OPENJDK_BUILD_CXXSTD_CXXFLAG="-std=gnu++98" 51042 51043 51044 51045 51046 51047 51048 51049 51050 51051 51052 51053 51054 51055 51056 51057 51058 51059 51060 51061 51062 51063 51064 51065 51066 51067 51068 51069 51070 51071 51072 51073 51074 51075 51076 51077 51078 51079 51080 51081 51082 51083 51084 # Execute function body 51085 51086 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"$OPENJDK_BUILD_CXXSTD_CXXFLAG -Werror\"" >&5 51087 $as_echo_n "checking if the C++ compiler supports \"$OPENJDK_BUILD_CXXSTD_CXXFLAG -Werror\"... " >&6; } 51088 supports=yes 51089 51090 saved_cxxflags="$CXXFLAGS" 51091 CXXFLAGS="$CXXFLAG $OPENJDK_BUILD_CXXSTD_CXXFLAG -Werror" 51092 ac_ext=cpp 51093 ac_cpp='$CXXCPP $CPPFLAGS' 51094 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51095 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51096 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 51097 51098 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51099 /* end confdefs.h. */ 51100 int i; 51101 _ACEOF 51102 if ac_fn_cxx_try_compile "$LINENO"; then : 51103 51104 else 51105 supports=no 51106 fi 51107 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 51108 ac_ext=cpp 51109 ac_cpp='$CXXCPP $CPPFLAGS' 51110 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51111 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51112 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 51113 51114 CXXFLAGS="$saved_cxxflags" 51115 51116 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 51117 $as_echo "$supports" >&6; } 51118 if test "x$supports" = "xyes" ; then 51119 : 51120 51121 else 51122 : 51123 OPENJDK_BUILD_CXXSTD_CXXFLAG="" 51124 fi 51125 51126 51127 51128 51129 51130 51131 51132 51133 51134 51135 51136 51137 OPENJDK_BUILD_CXXFLAGS_JDK="${OPENJDK_BUILD_CXXFLAGS_JDK} ${OPENJDK_BUILD_CXXSTD_CXXFLAG}" 51138 OPENJDK_BUILD_JVM_CFLAGS="${OPENJDK_BUILD_JVM_CFLAGS} ${OPENJDK_BUILD_CXXSTD_CXXFLAG}" 51139 51140 fi 51141 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 51142 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -D__solaris__" 51143 OPENJDK_BUILD_CXXFLAGS_JDK="${OPENJDK_BUILD_CXXFLAGS_JDK} -D__solaris__" 51144 fi 51145 51146 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} ${OPENJDK_BUILD_EXTRA_CFLAGS}" 51147 OPENJDK_BUILD_CXXFLAGS_JDK="${OPENJDK_BUILD_CXXFLAGS_JDK} ${OPENJDK_BUILD_EXTRA_CXXFLAGS}" 51148 OPENJDK_BUILD_LDFLAGS_JDK="${OPENJDK_BUILD_LDFLAGS_JDK} ${OPENJDK_BUILD_EXTRA_LDFLAGS}" 51149 51150 ############################################################################### 51151 # 51152 # Now setup the CFLAGS and LDFLAGS for the JDK build. 51153 # Later we will also have CFLAGS and LDFLAGS for the hotspot subrepo build. 51154 # 51155 51156 # Setup compiler/platform specific flags into 51157 # OPENJDK_BUILD_CFLAGS_JDK - C Compiler flags 51158 # OPENJDK_BUILD_CXXFLAGS_JDK - C++ Compiler flags 51159 # OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK - common to C and C++ 51160 if test "x$TOOLCHAIN_TYPE" = xgcc; then 51161 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_GNU_SOURCE" 51162 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_REENTRANT" 51163 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -fcheck-new" 51164 if test "x$OPENJDK_BUILD_CPU" = xx86; then 51165 # Force compatibility with i586 on 32 bit intel platforms. 51166 OPENJDK_BUILD_COMMON_CCXXFLAGS="${OPENJDK_BUILD_COMMON_CCXXFLAGS} -march=i586" 51167 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -march=i586" 51168 fi 51169 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS $OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -Wall -Wextra -Wno-unused -Wno-unused-parameter -Wformat=2 \ 51170 -pipe -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE" 51171 case $OPENJDK_BUILD_CPU_ARCH in 51172 arm ) 51173 # on arm we don't prevent gcc to omit frame pointer but do prevent strict aliasing 51174 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 51175 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="${OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK} -fsigned-char" 51176 ;; 51177 ppc ) 51178 # on ppc we don't prevent gcc to omit frame pointer but do prevent strict aliasing 51179 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 51180 ;; 51181 s390 ) 51182 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer -mbackchain -march=z10" 51183 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 51184 ;; 51185 * ) 51186 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer" 51187 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 51188 ;; 51189 esac 51190 51191 51192 51193 51194 51195 51196 51197 51198 51199 51200 51201 51202 51203 51204 51205 51206 51207 51208 51209 51210 51211 51212 51213 51214 51215 51216 51217 51218 51219 51220 51221 51222 51223 51224 51225 51226 51227 51228 51229 51230 51231 51232 51233 51234 51235 51236 51237 51238 51239 51240 51241 51242 51243 51244 # Execute function body 51245 51246 # Need to assign to a variable since m4 is blocked from modifying parts in []. 51247 REFERENCE_VERSION=6 51248 51249 if [[ "$REFERENCE_VERSION" =~ (.*\.){4} ]] ; then 51250 as_fn_error $? "Internal error: Cannot compare to 6, only four parts (W.X.Y.Z) is supported" "$LINENO" 5 51251 fi 51252 51253 if [[ "$REFERENCE_VERSION" =~ [0-9]{6} ]] ; then 51254 as_fn_error $? "Internal error: Cannot compare to 6, only parts < 99999 is supported" "$LINENO" 5 51255 fi 51256 51257 # Version comparison method inspired by http://stackoverflow.com/a/24067243 51258 COMPARABLE_REFERENCE_VERSION=`$AWK -F. '{ printf("%05d%05d%05d%05d\n", $1, $2, $3, $4) }' <<< "$REFERENCE_VERSION"` 51259 51260 if test $OPENJDK_BUILD_COMPARABLE_ACTUAL_VERSION -ge $COMPARABLE_REFERENCE_VERSION ; then 51261 : 51262 51263 # These flags are required for GCC 6 builds as undefined behaviour in OpenJDK code 51264 # runs afoul of the more aggressive versions of these optimisations. 51265 # Notably, value range propagation now assumes that the this pointer of C++ 51266 # member functions is non-null. 51267 NO_DELETE_NULL_POINTER_CHECKS_CFLAG="-fno-delete-null-pointer-checks" 51268 NO_LIFETIME_DSE_CFLAG="-fno-lifetime-dse" 51269 { $as_echo "$as_me:${as_lineno-$LINENO}: GCC >= 6 detected; adding ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} and ${NO_LIFETIME_DSE_CFLAG}" >&5 51270 $as_echo "$as_me: GCC >= 6 detected; adding ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} and ${NO_LIFETIME_DSE_CFLAG}" >&6;} 51271 OPENJDK_BUILD_CFLAGS_JDK="$OPENJDK_BUILD_CFLAGS_JDK ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} ${NO_LIFETIME_DSE_CFLAG}" 51272 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} ${NO_LIFETIME_DSE_CFLAG}" 51273 51274 else 51275 : 51276 51277 fi 51278 51279 51280 51281 51282 51283 51284 51285 51286 51287 51288 51289 51290 51291 51292 elif test "x$TOOLCHAIN_TYPE" = xclang; then 51293 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_GNU_SOURCE" 51294 51295 # Restrict the debug information created by Clang to avoid 51296 # too big object files and speed the build up a little bit 51297 # (see http://llvm.org/bugs/show_bug.cgi?id=7554) 51298 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -flimit-debug-info" 51299 if test "x$OPENJDK_BUILD_OS" = xlinux; then 51300 if test "x$OPENJDK_BUILD_CPU" = xx86; then 51301 # Force compatibility with i586 on 32 bit intel platforms. 51302 OPENJDK_BUILD_COMMON_CCXXFLAGS="${OPENJDK_BUILD_COMMON_CCXXFLAGS} -march=i586" 51303 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -march=i586" 51304 fi 51305 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wno-sometimes-uninitialized" 51306 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS $OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -Wall -Wextra -Wno-unused -Wno-unused-parameter -Wformat=2 \ 51307 -pipe -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE" 51308 case $OPENJDK_BUILD_CPU_ARCH in 51309 ppc ) 51310 # on ppc we don't prevent gcc to omit frame pointer but do prevent strict aliasing 51311 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 51312 ;; 51313 * ) 51314 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer" 51315 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 51316 ;; 51317 esac 51318 fi 51319 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 51320 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DSPARC_WORKS" 51321 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS $OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DTRACING -DMACRO_MEMSYS_OPS -DBREAKPTS" 51322 if test "x$OPENJDK_BUILD_CPU_ARCH" = xx86; then 51323 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DcpuIntel -Di586 -D$OPENJDK_BUILD_CPU_LEGACY_LIB" 51324 fi 51325 51326 OPENJDK_BUILD_CFLAGS_JDK="$OPENJDK_BUILD_CFLAGS_JDK -xc99=%none -xCC -errshort=tags -Xa -v -mt -W0,-noglobal" 51327 OPENJDK_BUILD_CXXFLAGS_JDK="$OPENJDK_BUILD_CXXFLAGS_JDK -errtags=yes +w -mt -features=no%except -DCC_NOEX -norunpath -xnolib" 51328 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 51329 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_REENTRANT -D__STDC_FORMAT_MACROS" 51330 OPENJDK_BUILD_CFLAGS_JDK="$OPENJDK_BUILD_CFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC" 51331 OPENJDK_BUILD_CXXFLAGS_JDK="$OPENJDK_BUILD_CXXFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC" 51332 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 51333 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS $OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 51334 -MD -Zc:wchar_t- -W3 -wd4800 \ 51335 -DWIN32_LEAN_AND_MEAN \ 51336 -D_CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE \ 51337 -D_WINSOCK_DEPRECATED_NO_WARNINGS \ 51338 -DWIN32 -DIAL" 51339 if test "x$OPENJDK_BUILD_CPU" = xx86_64; then 51340 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_AMD64_ -Damd64" 51341 else 51342 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_X86_ -Dx86" 51343 fi 51344 # If building with Visual Studio 2010, we can still use _STATIC_CPPLIB to 51345 # avoid bundling msvcpNNN.dll. Doesn't work with newer versions of visual 51346 # studio. 51347 if test "x$TOOLCHAIN_VERSION" = "x2010"; then 51348 STATIC_CPPLIB_FLAGS="-D_STATIC_CPPLIB -D_DISABLE_DEPRECATE_STATIC_CPPLIB" 51349 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK $STATIC_CPPLIB_FLAGS" 51350 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS $STATIC_CPPLIB_FLAGS" 51351 fi 51352 fi 51353 51354 ############################################################################### 51355 51356 # Adjust flags according to debug level. 51357 case $DEBUG_LEVEL in 51358 fastdebug | slowdebug ) 51359 OPENJDK_BUILD_CFLAGS_JDK="$OPENJDK_BUILD_CFLAGS_JDK $CFLAGS_DEBUG_SYMBOLS $CFLAGS_DEBUG_OPTIONS" 51360 OPENJDK_BUILD_CXXFLAGS_JDK="$OPENJDK_BUILD_CXXFLAGS_JDK $CXXFLAGS_DEBUG_SYMBOLS $CXXFLAGS_DEBUG_OPTIONS" 51361 ;; 51362 release ) 51363 ;; 51364 * ) 51365 as_fn_error $? "Unrecognized \$DEBUG_LEVEL: $DEBUG_LEVEL" "$LINENO" 5 51366 ;; 51367 esac 51368 51369 # Set some common defines. These works for all compilers, but assume 51370 # -D is universally accepted. 51371 51372 # Setup endianness 51373 if test "x$OPENJDK_BUILD_CPU_ENDIAN" = xlittle; then 51374 # The macro _LITTLE_ENDIAN needs to be defined the same to avoid the 51375 # Sun C compiler warning message: warning: macro redefined: _LITTLE_ENDIAN 51376 # (The Solaris X86 system defines this in file /usr/include/sys/isa_defs.h). 51377 # Note: -Dmacro is the same as #define macro 1 51378 # -Dmacro= is the same as #define macro 51379 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 51380 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_LITTLE_ENDIAN=" 51381 else 51382 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_LITTLE_ENDIAN" 51383 fi 51384 else 51385 # Same goes for _BIG_ENDIAN. Do we really need to set *ENDIAN on Solaris if they 51386 # are defined in the system? 51387 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 51388 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_BIG_ENDIAN=" 51389 else 51390 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_BIG_ENDIAN" 51391 fi 51392 fi 51393 51394 # Setup target OS define. Use OS target name but in upper case. 51395 OPENJDK_BUILD_OS_UPPERCASE=`$ECHO $OPENJDK_BUILD_OS | $TR 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` 51396 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D$OPENJDK_BUILD_OS_UPPERCASE" 51397 51398 # Setup target CPU 51399 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 51400 $OPENJDK_BUILD_ADD_LP64 \ 51401 -DARCH='\"$OPENJDK_BUILD_CPU_LEGACY\"' -D$OPENJDK_BUILD_CPU_LEGACY" 51402 51403 # Setup debug/release defines 51404 if test "x$DEBUG_LEVEL" = xrelease; then 51405 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DNDEBUG" 51406 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 51407 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DTRIMMED" 51408 fi 51409 else 51410 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DDEBUG" 51411 fi 51412 51413 # Set some additional per-OS defines. 51414 if test "x$OPENJDK_BUILD_OS" = xlinux; then 51415 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DLINUX" 51416 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -pipe $PICFLAG -fno-rtti -fno-exceptions \ 51417 -fvisibility=hidden -fno-strict-aliasing -fno-omit-frame-pointer" 51418 elif test "x$OPENJDK_BUILD_OS" = xsolaris; then 51419 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DSOLARIS" 51420 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -template=no%extdef -features=no%split_init \ 51421 -D_Crun_inline_placement -library=%none $PICFLAG -mt -features=no%except" 51422 elif test "x$OPENJDK_BUILD_OS" = xmacosx; then 51423 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE -D_DARWIN_UNLIMITED_SELECT" 51424 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_ALLBSD_SOURCE" 51425 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_DARWIN_C_SOURCE -D_XOPEN_SOURCE" 51426 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -fno-rtti -fno-exceptions -fvisibility=hidden \ 51427 -mno-omit-leaf-frame-pointer -mstack-alignment=16 -pipe -fno-strict-aliasing \ 51428 -DMAC_OS_X_VERSION_MAX_ALLOWED=1070 -mmacosx-version-min=10.7.0 \ 51429 -fno-omit-frame-pointer" 51430 elif test "x$OPENJDK_BUILD_OS" = xaix; then 51431 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DAIX" 51432 # We may need '-qminimaltoc' or '-qpic=large -bbigtoc' if the TOC overflows. 51433 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -qtune=balanced \ 51434 -qalias=noansi -qstrict -qtls=default -qlanglvl=c99vla \ 51435 -qlanglvl=noredefmac -qnortti -qnoeh -qignerrno" 51436 elif test "x$OPENJDK_BUILD_OS" = xbsd; then 51437 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE" 51438 elif test "x$OPENJDK_BUILD_OS" = xwindows; then 51439 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_WINDOWS -DWIN32 -D_JNI_IMPLEMENTATION_" 51440 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -nologo -W3 -MD -MP" 51441 fi 51442 51443 # Set some additional per-CPU defines. 51444 if test "x$OPENJDK_BUILD_OS-$OPENJDK_BUILD_CPU" = xwindows-x86; then 51445 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -arch:IA32" 51446 elif test "x$OPENJDK_BUILD_CPU" = xsparcv9; then 51447 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -xarch=sparc" 51448 elif test "x$OPENJDK_BUILD_CPU" = xppc64; then 51449 if test "x$OPENJDK_BUILD_OS" = xlinux; then 51450 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -minsert-sched-nops=regroup_exact -mno-multiple -mno-string" 51451 # fixes `relocation truncated to fit' error for gcc 4.1. 51452 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -mminimal-toc" 51453 # Use ppc64 instructions, but schedule for power5 51454 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -mcpu=powerpc64 -mtune=power5" 51455 elif test "x$OPENJDK_BUILD_OS" = xaix; then 51456 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -qarch=ppc64" 51457 fi 51458 elif test "x$OPENJDK_BUILD_CPU" = xppc64le; then 51459 if test "x$OPENJDK_BUILD_OS" = xlinux; then 51460 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -minsert-sched-nops=regroup_exact -mno-multiple -mno-string" 51461 # Little endian machine uses ELFv2 ABI. 51462 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DABI_ELFv2" 51463 # Use Power8, this is the first CPU to support PPC64 LE with ELFv2 ABI. 51464 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -mcpu=power8 -mtune=power8" 51465 fi 51466 elif test "x$OPENJDK_BUILD_CPU" = xs390x; then 51467 if test "x$OPENJDK_BUILD_OS" = xlinux; then 51468 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -mbackchain -march=z10" 51469 fi 51470 fi 51471 51472 if test "x$OPENJDK_BUILD_CPU_ENDIAN" = xlittle; then 51473 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DVM_LITTLE_ENDIAN" 51474 fi 51475 51476 if test "x$OPENJDK_BUILD_CPU_BITS" = x64; then 51477 if test "x$OPENJDK_BUILD_OS" != xsolaris && test "x$OPENJDK_BUILD_OS" != xaix; then 51478 # Solaris does not have _LP64=1 in the old build. 51479 # xlc on AIX defines _LP64=1 by default and issues a warning if we redefine it. 51480 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_LP64=1" 51481 fi 51482 fi 51483 51484 # Set OPENJDK_BUILD_JVM_CFLAGS warning handling 51485 if test "x$OPENJDK_BUILD_OS" = xlinux; then 51486 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wpointer-arith -Wsign-compare -Wunused-function \ 51487 -Wunused-value -Woverloaded-virtual" 51488 51489 if test "x$TOOLCHAIN_TYPE" = xgcc; then 51490 51491 51492 51493 51494 51495 51496 51497 51498 51499 51500 51501 51502 51503 51504 51505 51506 51507 51508 51509 51510 51511 51512 51513 51514 51515 51516 51517 51518 51519 51520 51521 51522 51523 51524 51525 51526 51527 51528 51529 51530 51531 51532 51533 51534 51535 51536 51537 51538 51539 51540 51541 51542 51543 51544 # Execute function body 51545 51546 # Need to assign to a variable since m4 is blocked from modifying parts in []. 51547 REFERENCE_VERSION=4.8 51548 51549 if [[ "$REFERENCE_VERSION" =~ (.*\.){4} ]] ; then 51550 as_fn_error $? "Internal error: Cannot compare to 4.8, only four parts (W.X.Y.Z) is supported" "$LINENO" 5 51551 fi 51552 51553 if [[ "$REFERENCE_VERSION" =~ [0-9]{6} ]] ; then 51554 as_fn_error $? "Internal error: Cannot compare to 4.8, only parts < 99999 is supported" "$LINENO" 5 51555 fi 51556 51557 # Version comparison method inspired by http://stackoverflow.com/a/24067243 51558 COMPARABLE_REFERENCE_VERSION=`$AWK -F. '{ printf("%05d%05d%05d%05d\n", $1, $2, $3, $4) }' <<< "$REFERENCE_VERSION"` 51559 51560 if test $OPENJDK_BUILD_COMPARABLE_ACTUAL_VERSION -ge $COMPARABLE_REFERENCE_VERSION ; then 51561 : 51562 51563 # These flags either do not work or give spurious warnings prior to gcc 4.8. 51564 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wno-format-zero-length -Wtype-limits -Wuninitialized" 51565 51566 51567 else 51568 : 51569 51570 fi 51571 51572 51573 51574 51575 51576 51577 51578 51579 51580 51581 51582 51583 51584 51585 fi 51586 if ! [[ " $JVM_VARIANTS " =~ " zero " ]] && ! [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 51587 # Non-zero builds have stricter warnings 51588 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wreturn-type -Wundef -Wformat=2" 51589 else 51590 if test "x$TOOLCHAIN_TYPE" = xclang; then 51591 # Some versions of llvm do not like -Wundef 51592 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wno-undef" 51593 fi 51594 fi 51595 elif test "x$OPENJDK_BUILD_OS" = xmacosx; then 51596 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wno-deprecated -Wpointer-arith \ 51597 -Wsign-compare -Wundef -Wunused-function -Wformat=2" 51598 fi 51599 51600 # Additional macosx handling 51601 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 51602 # Setting these parameters makes it an error to link to macosx APIs that are 51603 # newer than the given OS version and makes the linked binaries compatible 51604 # even if built on a newer version of the OS. 51605 # The expected format is X.Y.Z 51606 MACOSX_VERSION_MIN=10.7.0 51607 51608 51609 # The macro takes the version with no dots, ex: 1070 51610 # Let the flags variables get resolved in make for easier override on make 51611 # command line. 51612 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DMAC_OS_X_VERSION_MAX_ALLOWED=\$(subst .,,\$(MACOSX_VERSION_MIN)) -mmacosx-version-min=\$(MACOSX_VERSION_MIN)" 51613 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK -mmacosx-version-min=\$(MACOSX_VERSION_MIN)" 51614 fi 51615 51616 # Setup some hard coded includes 51617 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 51618 -I\$(SUPPORT_OUTPUTDIR)/modules_include/java.base \ 51619 -I${JDK_TOPDIR}/src/java.base/share/native/include \ 51620 -I${JDK_TOPDIR}/src/java.base/$OPENJDK_BUILD_OS/native/include \ 51621 -I${JDK_TOPDIR}/src/java.base/$OPENJDK_BUILD_OS_TYPE/native/include \ 51622 -I${JDK_TOPDIR}/src/java.base/share/native/libjava \ 51623 -I${JDK_TOPDIR}/src/java.base/$OPENJDK_BUILD_OS_TYPE/native/libjava" 51624 51625 # The shared libraries are compiled using the picflag. 51626 OPENJDK_BUILD_CFLAGS_JDKLIB="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 51627 $OPENJDK_BUILD_CFLAGS_JDK $OPENJDK_BUILD_EXTRA_CFLAGS_JDK $PICFLAG $OPENJDK_BUILD_CFLAGS_JDKLIB_EXTRA" 51628 OPENJDK_BUILD_CXXFLAGS_JDKLIB="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 51629 $OPENJDK_BUILD_CXXFLAGS_JDK $OPENJDK_BUILD_EXTRA_CXXFLAGS_JDK $PICFLAG $OPENJDK_BUILD_CXXFLAGS_JDKLIB_EXTRA" 51630 51631 # Executable flags 51632 OPENJDK_BUILD_CFLAGS_JDKEXE="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK $OPENJDK_BUILD_CFLAGS_JDK $OPENJDK_BUILD_EXTRA_CFLAGS_JDK" 51633 OPENJDK_BUILD_CXXFLAGS_JDKEXE="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK $OPENJDK_BUILD_CXXFLAGS_JDK $OPENJDK_BUILD_EXTRA_CXXFLAGS_JDK" 51634 51635 51636 51637 51638 51639 51640 # Setup LDFLAGS et al. 51641 # 51642 51643 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 51644 LDFLAGS_MICROSOFT="-nologo -opt:ref" 51645 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LDFLAGS_MICROSOFT -incremental:no" 51646 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_MICROSOFT -opt:icf,8 -subsystem:windows -base:0x8000000" 51647 if test "x$OPENJDK_BUILD_CPU_BITS" = "x32"; then 51648 LDFLAGS_SAFESH="-safeseh" 51649 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LDFLAGS_SAFESH" 51650 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_SAFESH" 51651 # NOTE: Old build added -machine. Probably not needed. 51652 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -machine:I386" 51653 else 51654 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -machine:AMD64" 51655 fi 51656 elif test "x$TOOLCHAIN_TYPE" = xclang; then 51657 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -mno-omit-leaf-frame-pointer -mstack-alignment=16 -stdlib=libstdc++ -fPIC" 51658 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 51659 # FIXME: We should really generalize SET_SHARED_LIBRARY_ORIGIN instead. 51660 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -Wl,-rpath,@loader_path/. -Wl,-rpath,@loader_path/.." 51661 fi 51662 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 51663 # If this is a --hash-style=gnu system, use --hash-style=both, why? 51664 # We have previously set HAS_GNU_HASH if this is the case 51665 if test -n "$HAS_GNU_HASH"; then 51666 OPENJDK_BUILD_LDFLAGS_HASH_STYLE="-Wl,--hash-style=both" 51667 OPENJDK_BUILD_LDFLAGS_JDK="${OPENJDK_BUILD_LDFLAGS_JDK} $OPENJDK_BUILD_LDFLAGS_HASH_STYLE" 51668 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $OPENJDK_BUILD_LDFLAGS_HASH_STYLE" 51669 fi 51670 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 51671 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -Wl,-rpath,@loader_path/. -Wl,-rpath,@loader_path/.." 51672 fi 51673 if test "x$OPENJDK_BUILD_OS" = xlinux; then 51674 # And since we now know that the linker is gnu, then add -z defs, to forbid 51675 # undefined symbols in object files. 51676 LDFLAGS_NO_UNDEF_SYM="-Wl,-z,defs" 51677 OPENJDK_BUILD_LDFLAGS_JDK="${OPENJDK_BUILD_LDFLAGS_JDK} $LDFLAGS_NO_UNDEF_SYM" 51678 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_NO_UNDEF_SYM" 51679 LDFLAGS_NO_EXEC_STACK="-Wl,-z,noexecstack" 51680 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_NO_EXEC_STACK" 51681 if test "x$OPENJDK_BUILD_CPU" = xx86; then 51682 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -march=i586" 51683 fi 51684 case $DEBUG_LEVEL in 51685 release ) 51686 # tell linker to optimize libraries. 51687 # Should this be supplied to the OSS linker as well? 51688 LDFLAGS_DEBUGLEVEL_release="-Wl,-O1" 51689 OPENJDK_BUILD_LDFLAGS_JDK="${OPENJDK_BUILD_LDFLAGS_JDK} $LDFLAGS_DEBUGLEVEL_release" 51690 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_DEBUGLEVEL_release" 51691 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 51692 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LINKER_RELRO_FLAG" 51693 fi 51694 ;; 51695 slowdebug ) 51696 # Hotspot always let the linker optimize 51697 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -Wl,-O1" 51698 if test "x$HAS_LINKER_NOW" = "xtrue"; then 51699 # do relocations at load 51700 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LINKER_NOW_FLAG" 51701 OPENJDK_BUILD_LDFLAGS_CXX_JDK="$OPENJDK_BUILD_LDFLAGS_CXX_JDK $LINKER_NOW_FLAG" 51702 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LINKER_NOW_FLAG" 51703 fi 51704 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 51705 # mark relocations read only 51706 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LINKER_RELRO_FLAG" 51707 OPENJDK_BUILD_LDFLAGS_CXX_JDK="$OPENJDK_BUILD_LDFLAGS_CXX_JDK $LINKER_RELRO_FLAG" 51708 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LINKER_RELRO_FLAG" 51709 fi 51710 ;; 51711 fastdebug ) 51712 # Hotspot always let the linker optimize 51713 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -Wl,-O1" 51714 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 51715 # mark relocations read only 51716 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LINKER_RELRO_FLAG" 51717 OPENJDK_BUILD_LDFLAGS_CXX_JDK="$OPENJDK_BUILD_LDFLAGS_CXX_JDK $LINKER_RELRO_FLAG" 51718 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LINKER_RELRO_FLAG" 51719 fi 51720 ;; 51721 * ) 51722 as_fn_error $? "Unrecognized \$DEBUG_LEVEL: $DEBUG_LEVEL" "$LINENO" 5 51723 ;; 51724 esac 51725 fi 51726 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 51727 LDFLAGS_SOLSTUDIO="-Wl,-z,defs" 51728 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LDFLAGS_SOLSTUDIO -ztext" 51729 LDFLAGS_CXX_SOLSTUDIO="-norunpath" 51730 OPENJDK_BUILD_LDFLAGS_CXX_JDK="$OPENJDK_BUILD_LDFLAGS_CXX_JDK $LDFLAGS_CXX_SOLSTUDIO -xnolib" 51731 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_SOLSTUDIO -library=%none -mt $LDFLAGS_CXX_SOLSTUDIO -z noversion" 51732 if test "x$OPENJDK_BUILD_CPU_ARCH" = "xsparc"; then 51733 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -xarch=sparc" 51734 fi 51735 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 51736 LDFLAGS_XLC="-b64 -brtl -bnolibpath -bexpall -bernotok" 51737 OPENJDK_BUILD_LDFLAGS_JDK="${OPENJDK_BUILD_LDFLAGS_JDK} $LDFLAGS_XLC" 51738 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_XLC" 51739 fi 51740 51741 # Customize LDFLAGS for executables 51742 51743 OPENJDK_BUILD_LDFLAGS_JDKEXE="${OPENJDK_BUILD_LDFLAGS_JDK}" 51744 51745 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 51746 if test "x$OPENJDK_BUILD_CPU_BITS" = "x64"; then 51747 LDFLAGS_STACK_SIZE=1048576 51748 else 51749 LDFLAGS_STACK_SIZE=327680 51750 fi 51751 OPENJDK_BUILD_LDFLAGS_JDKEXE="${OPENJDK_BUILD_LDFLAGS_JDKEXE} /STACK:$LDFLAGS_STACK_SIZE" 51752 elif test "x$OPENJDK_BUILD_OS" = xlinux; then 51753 OPENJDK_BUILD_LDFLAGS_JDKEXE="$OPENJDK_BUILD_LDFLAGS_JDKEXE -Wl,--allow-shlib-undefined" 51754 fi 51755 51756 OPENJDK_BUILD_LDFLAGS_JDKEXE="${OPENJDK_BUILD_LDFLAGS_JDKEXE} ${OPENJDK_BUILD_EXTRA_LDFLAGS_JDK}" 51757 51758 # Customize LDFLAGS for libs 51759 OPENJDK_BUILD_LDFLAGS_JDKLIB="${OPENJDK_BUILD_LDFLAGS_JDK}" 51760 51761 OPENJDK_BUILD_LDFLAGS_JDKLIB="${OPENJDK_BUILD_LDFLAGS_JDKLIB} ${SHARED_LIBRARY_FLAGS}" 51762 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 51763 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} \ 51764 -libpath:${OUTPUT_ROOT}/support/modules_libs/java.base" 51765 OPENJDK_BUILD_JDKLIB_LIBS="" 51766 else 51767 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} \ 51768 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base" 51769 51770 if test "xBUILD" = "xTARGET"; then 51771 # On some platforms (mac) the linker warns about non existing -L dirs. 51772 # For any of the variants server, client or minimal, the dir matches the 51773 # variant name. The "main" variant should be used for linking. For the 51774 # rest, the dir is just server. 51775 if [[ " $JVM_VARIANTS " =~ " server " ]] || [[ " $JVM_VARIANTS " =~ " client " ]] \ 51776 || [[ " $JVM_VARIANTS " =~ " minimal " ]] ; then 51777 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} \ 51778 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base/$JVM_VARIANT_MAIN" 51779 else 51780 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} \ 51781 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base/server" 51782 fi 51783 elif test "xBUILD" = "xBUILD"; then 51784 # When building a buildjdk, it's always only the server variant 51785 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} \ 51786 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base/server" 51787 fi 51788 51789 OPENJDK_BUILD_JDKLIB_LIBS="-ljava -ljvm" 51790 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 51791 OPENJDK_BUILD_JDKLIB_LIBS="$OPENJDK_BUILD_JDKLIB_LIBS -lc" 51792 fi 51793 51794 fi 51795 51796 OPENJDK_BUILD_LDFLAGS_JDKLIB="${OPENJDK_BUILD_LDFLAGS_JDKLIB} ${OPENJDK_BUILD_JAVA_BASE_LDFLAGS}" 51797 51798 # Set OPENJDK_BUILD_JVM_LIBS (per os) 51799 if test "x$OPENJDK_BUILD_OS" = xlinux; then 51800 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS -lm -ldl -lpthread" 51801 elif test "x$OPENJDK_BUILD_OS" = xsolaris; then 51802 # FIXME: This hard-coded path is not really proper. 51803 if test "x$OPENJDK_BUILD_CPU" = xx86_64; then 51804 OPENJDK_BUILD_SOLARIS_LIBM_LIBS="/usr/lib/amd64/libm.so.1" 51805 elif test "x$OPENJDK_BUILD_CPU" = xsparcv9; then 51806 OPENJDK_BUILD_SOLARIS_LIBM_LIBS="/usr/lib/sparcv9/libm.so.1" 51807 fi 51808 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS -lsocket -lsched -ldl $SOLARIS_LIBM_LIBS -lCrun \ 51809 -lthread -ldoor -lc -ldemangle -lnsl -lkstat -lrt" 51810 elif test "x$OPENJDK_BUILD_OS" = xmacosx; then 51811 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS -lm" 51812 elif test "x$OPENJDK_BUILD_OS" = xaix; then 51813 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS -Wl,-lC_r -lm -ldl -lpthread" 51814 elif test "x$OPENJDK_BUILD_OS" = xbsd; then 51815 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS -lm" 51816 elif test "x$OPENJDK_BUILD_OS" = xwindows; then 51817 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS kernel32.lib user32.lib gdi32.lib winspool.lib \ 51818 comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib \ 51819 wsock32.lib winmm.lib version.lib psapi.lib" 51820 fi 51821 51822 # Set OPENJDK_BUILD_JVM_ASFLAGS 51823 if test "x$OPENJDK_BUILD_OS" = xlinux; then 51824 if test "x$OPENJDK_BUILD_CPU" = xx86; then 51825 OPENJDK_BUILD_JVM_ASFLAGS="$OPENJDK_BUILD_JVM_ASFLAGS -march=i586" 51826 fi 51827 elif test "x$OPENJDK_BUILD_OS" = xmacosx; then 51828 OPENJDK_BUILD_JVM_ASFLAGS="$OPENJDK_BUILD_JVM_ASFLAGS -x assembler-with-cpp -mno-omit-leaf-frame-pointer -mstack-alignment=16" 51829 fi 51830 51831 OPENJDK_BUILD_LDFLAGS_JDKLIB="${OPENJDK_BUILD_LDFLAGS_JDKLIB} ${OPENJDK_BUILD_EXTRA_LDFLAGS_JDK}" 51832 51833 51834 51835 51836 51837 51838 51839 51840 51841 51842 51843 51844 51845 51846 51847 # Tests are only ever compiled for TARGET 51848 # Flags for compiling test libraries 51849 CFLAGS_TESTLIB="$COMMON_CCXXFLAGS_JDK $CFLAGS_JDK $PICFLAG $CFLAGS_JDKLIB_EXTRA" 51850 CXXFLAGS_TESTLIB="$COMMON_CCXXFLAGS_JDK $CXXFLAGS_JDK $PICFLAG $CXXFLAGS_JDKLIB_EXTRA" 51851 51852 # Flags for compiling test executables 51853 CFLAGS_TESTEXE="$COMMON_CCXXFLAGS_JDK $CFLAGS_JDK" 51854 CXXFLAGS_TESTEXE="$COMMON_CCXXFLAGS_JDK $CXXFLAGS_JDK" 51855 51856 51857 51858 51859 51860 51861 LDFLAGS_TESTLIB="$LDFLAGS_JDKLIB" 51862 LDFLAGS_TESTEXE="$LDFLAGS_JDKEXE $JAVA_BASE_LDFLAGS" 51863 51864 51865 51866 51867 51868 51869 # Check that the compiler supports -mX (or -qX on AIX) flags 51870 # Set COMPILER_SUPPORTS_TARGET_BITS_FLAG to 'true' if it does 51871 51872 51873 51874 51875 51876 51877 51878 51879 51880 51881 51882 51883 51884 51885 51886 51887 51888 51889 51890 51891 51892 51893 51894 51895 51896 51897 51898 51899 51900 51901 51902 51903 51904 51905 51906 51907 51908 51909 51910 51911 51912 51913 51914 51915 51916 51917 51918 # Execute function body 51919 51920 51921 51922 51923 51924 51925 51926 51927 51928 51929 51930 51931 51932 51933 51934 51935 51936 51937 51938 51939 51940 51941 51942 51943 51944 51945 51946 51947 51948 51949 51950 51951 51952 51953 51954 51955 51956 51957 51958 51959 51960 51961 51962 51963 51964 51965 51966 51967 # Execute function body 51968 51969 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"" >&5 51970 $as_echo_n "checking if the C compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"... " >&6; } 51971 supports=yes 51972 51973 saved_cflags="$CFLAGS" 51974 CFLAGS="$CFLAGS ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 51975 ac_ext=c 51976 ac_cpp='$CPP $CPPFLAGS' 51977 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51978 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51979 ac_compiler_gnu=$ac_cv_c_compiler_gnu 51980 51981 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51982 /* end confdefs.h. */ 51983 int i; 51984 _ACEOF 51985 if ac_fn_c_try_compile "$LINENO"; then : 51986 51987 else 51988 supports=no 51989 fi 51990 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 51991 ac_ext=cpp 51992 ac_cpp='$CXXCPP $CPPFLAGS' 51993 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51994 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51995 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 51996 51997 CFLAGS="$saved_cflags" 51998 51999 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 52000 $as_echo "$supports" >&6; } 52001 if test "x$supports" = "xyes" ; then 52002 : 52003 C_COMP_SUPPORTS="yes" 52004 else 52005 : 52006 C_COMP_SUPPORTS="no" 52007 fi 52008 52009 52010 52011 52012 52013 52014 52015 52016 52017 52018 52019 52020 52021 52022 52023 52024 52025 52026 52027 52028 52029 52030 52031 52032 52033 52034 52035 52036 52037 52038 52039 52040 52041 52042 52043 52044 52045 52046 52047 52048 52049 52050 52051 52052 52053 52054 52055 52056 52057 52058 52059 52060 52061 52062 52063 52064 52065 52066 52067 # Execute function body 52068 52069 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"" >&5 52070 $as_echo_n "checking if the C++ compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"... " >&6; } 52071 supports=yes 52072 52073 saved_cxxflags="$CXXFLAGS" 52074 CXXFLAGS="$CXXFLAG ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 52075 ac_ext=cpp 52076 ac_cpp='$CXXCPP $CPPFLAGS' 52077 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52078 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52079 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 52080 52081 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 52082 /* end confdefs.h. */ 52083 int i; 52084 _ACEOF 52085 if ac_fn_cxx_try_compile "$LINENO"; then : 52086 52087 else 52088 supports=no 52089 fi 52090 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 52091 ac_ext=cpp 52092 ac_cpp='$CXXCPP $CPPFLAGS' 52093 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52094 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52095 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 52096 52097 CXXFLAGS="$saved_cxxflags" 52098 52099 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 52100 $as_echo "$supports" >&6; } 52101 if test "x$supports" = "xyes" ; then 52102 : 52103 CXX_COMP_SUPPORTS="yes" 52104 else 52105 : 52106 CXX_COMP_SUPPORTS="no" 52107 fi 52108 52109 52110 52111 52112 52113 52114 52115 52116 52117 52118 52119 52120 52121 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"" >&5 52122 $as_echo_n "checking if both compilers support \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"... " >&6; } 52123 supports=no 52124 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 52125 52126 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 52127 $as_echo "$supports" >&6; } 52128 if test "x$supports" = "xyes" ; then 52129 : 52130 COMPILER_SUPPORTS_TARGET_BITS_FLAG=true 52131 else 52132 : 52133 COMPILER_SUPPORTS_TARGET_BITS_FLAG=false 52134 fi 52135 52136 52137 52138 52139 52140 52141 52142 52143 # Check whether --enable-warnings-as-errors was given. 52144 if test "${enable_warnings_as_errors+set}" = set; then : 52145 enableval=$enable_warnings_as_errors; 52146 fi 52147 52148 52149 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if native warnings are errors" >&5 52150 $as_echo_n "checking if native warnings are errors... " >&6; } 52151 if test "x$enable_warnings_as_errors" = "xyes"; then 52152 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (explicitly set)" >&5 52153 $as_echo "yes (explicitly set)" >&6; } 52154 WARNINGS_AS_ERRORS=true 52155 elif test "x$enable_warnings_as_errors" = "xno"; then 52156 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 52157 $as_echo "no" >&6; } 52158 WARNINGS_AS_ERRORS=false 52159 elif test "x$enable_warnings_as_errors" = "x"; then 52160 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (default)" >&5 52161 $as_echo "yes (default)" >&6; } 52162 WARNINGS_AS_ERRORS=true 52163 else 52164 as_fn_error $? "--enable-warnings-as-errors accepts no argument" "$LINENO" 5 52165 fi 52166 52167 52168 52169 case "${TOOLCHAIN_TYPE}" in 52170 microsoft) 52171 DISABLE_WARNING_PREFIX="-wd" 52172 CFLAGS_WARNINGS_ARE_ERRORS="-WX" 52173 ;; 52174 solstudio) 52175 DISABLE_WARNING_PREFIX="-erroff=" 52176 CFLAGS_WARNINGS_ARE_ERRORS="-errtags -errwarn=%all" 52177 ;; 52178 gcc) 52179 # Prior to gcc 4.4, a -Wno-X where X is unknown for that version of gcc will cause an error 52180 52181 52182 52183 52184 52185 52186 52187 52188 52189 52190 52191 52192 52193 52194 52195 52196 52197 52198 52199 52200 52201 52202 52203 52204 52205 52206 52207 52208 52209 52210 52211 52212 52213 52214 52215 52216 52217 52218 52219 52220 52221 52222 52223 52224 52225 52226 52227 # Execute function body 52228 52229 52230 52231 52232 52233 52234 52235 52236 52237 52238 52239 52240 52241 52242 52243 52244 52245 52246 52247 52248 52249 52250 52251 52252 52253 52254 52255 52256 52257 52258 52259 52260 52261 52262 52263 52264 52265 52266 52267 52268 52269 52270 52271 52272 52273 52274 52275 52276 # Execute function body 52277 52278 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 52279 $as_echo_n "checking if the C compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 52280 supports=yes 52281 52282 saved_cflags="$CFLAGS" 52283 CFLAGS="$CFLAGS -Wno-this-is-a-warning-that-do-not-exist" 52284 ac_ext=c 52285 ac_cpp='$CPP $CPPFLAGS' 52286 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52287 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52288 ac_compiler_gnu=$ac_cv_c_compiler_gnu 52289 52290 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 52291 /* end confdefs.h. */ 52292 int i; 52293 _ACEOF 52294 if ac_fn_c_try_compile "$LINENO"; then : 52295 52296 else 52297 supports=no 52298 fi 52299 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 52300 ac_ext=cpp 52301 ac_cpp='$CXXCPP $CPPFLAGS' 52302 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52303 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52304 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 52305 52306 CFLAGS="$saved_cflags" 52307 52308 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 52309 $as_echo "$supports" >&6; } 52310 if test "x$supports" = "xyes" ; then 52311 : 52312 C_COMP_SUPPORTS="yes" 52313 else 52314 : 52315 C_COMP_SUPPORTS="no" 52316 fi 52317 52318 52319 52320 52321 52322 52323 52324 52325 52326 52327 52328 52329 52330 52331 52332 52333 52334 52335 52336 52337 52338 52339 52340 52341 52342 52343 52344 52345 52346 52347 52348 52349 52350 52351 52352 52353 52354 52355 52356 52357 52358 52359 52360 52361 52362 52363 52364 52365 52366 52367 52368 52369 52370 52371 52372 52373 52374 52375 52376 # Execute function body 52377 52378 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 52379 $as_echo_n "checking if the C++ compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 52380 supports=yes 52381 52382 saved_cxxflags="$CXXFLAGS" 52383 CXXFLAGS="$CXXFLAG -Wno-this-is-a-warning-that-do-not-exist" 52384 ac_ext=cpp 52385 ac_cpp='$CXXCPP $CPPFLAGS' 52386 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52387 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52388 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 52389 52390 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 52391 /* end confdefs.h. */ 52392 int i; 52393 _ACEOF 52394 if ac_fn_cxx_try_compile "$LINENO"; then : 52395 52396 else 52397 supports=no 52398 fi 52399 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 52400 ac_ext=cpp 52401 ac_cpp='$CXXCPP $CPPFLAGS' 52402 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52403 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52404 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 52405 52406 CXXFLAGS="$saved_cxxflags" 52407 52408 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 52409 $as_echo "$supports" >&6; } 52410 if test "x$supports" = "xyes" ; then 52411 : 52412 CXX_COMP_SUPPORTS="yes" 52413 else 52414 : 52415 CXX_COMP_SUPPORTS="no" 52416 fi 52417 52418 52419 52420 52421 52422 52423 52424 52425 52426 52427 52428 52429 52430 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 52431 $as_echo_n "checking if both compilers support \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 52432 supports=no 52433 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 52434 52435 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 52436 $as_echo "$supports" >&6; } 52437 if test "x$supports" = "xyes" ; then 52438 : 52439 GCC_CAN_DISABLE_WARNINGS=true 52440 else 52441 : 52442 GCC_CAN_DISABLE_WARNINGS=false 52443 52444 fi 52445 52446 52447 52448 52449 52450 52451 if test "x$GCC_CAN_DISABLE_WARNINGS" = "xtrue"; then 52452 DISABLE_WARNING_PREFIX="-Wno-" 52453 else 52454 DISABLE_WARNING_PREFIX= 52455 fi 52456 CFLAGS_WARNINGS_ARE_ERRORS="-Werror" 52457 # Repeate the check for the BUILD_CC and BUILD_CXX. Need to also reset 52458 # CFLAGS since any target specific flags will likely not work with the 52459 # build compiler 52460 CC_OLD="$CC" 52461 CXX_OLD="$CXX" 52462 CC="$BUILD_CC" 52463 CXX="$BUILD_CXX" 52464 CFLAGS_OLD="$CFLAGS" 52465 CFLAGS="" 52466 52467 52468 52469 52470 52471 52472 52473 52474 52475 52476 52477 52478 52479 52480 52481 52482 52483 52484 52485 52486 52487 52488 52489 52490 52491 52492 52493 52494 52495 52496 52497 52498 52499 52500 52501 52502 52503 52504 52505 52506 52507 52508 52509 52510 52511 52512 52513 # Execute function body 52514 52515 52516 52517 52518 52519 52520 52521 52522 52523 52524 52525 52526 52527 52528 52529 52530 52531 52532 52533 52534 52535 52536 52537 52538 52539 52540 52541 52542 52543 52544 52545 52546 52547 52548 52549 52550 52551 52552 52553 52554 52555 52556 52557 52558 52559 52560 52561 52562 # Execute function body 52563 52564 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 52565 $as_echo_n "checking if the C compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 52566 supports=yes 52567 52568 saved_cflags="$CFLAGS" 52569 CFLAGS="$CFLAGS -Wno-this-is-a-warning-that-do-not-exist" 52570 ac_ext=c 52571 ac_cpp='$CPP $CPPFLAGS' 52572 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52573 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52574 ac_compiler_gnu=$ac_cv_c_compiler_gnu 52575 52576 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 52577 /* end confdefs.h. */ 52578 int i; 52579 _ACEOF 52580 if ac_fn_c_try_compile "$LINENO"; then : 52581 52582 else 52583 supports=no 52584 fi 52585 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 52586 ac_ext=cpp 52587 ac_cpp='$CXXCPP $CPPFLAGS' 52588 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52589 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52590 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 52591 52592 CFLAGS="$saved_cflags" 52593 52594 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 52595 $as_echo "$supports" >&6; } 52596 if test "x$supports" = "xyes" ; then 52597 : 52598 C_COMP_SUPPORTS="yes" 52599 else 52600 : 52601 C_COMP_SUPPORTS="no" 52602 fi 52603 52604 52605 52606 52607 52608 52609 52610 52611 52612 52613 52614 52615 52616 52617 52618 52619 52620 52621 52622 52623 52624 52625 52626 52627 52628 52629 52630 52631 52632 52633 52634 52635 52636 52637 52638 52639 52640 52641 52642 52643 52644 52645 52646 52647 52648 52649 52650 52651 52652 52653 52654 52655 52656 52657 52658 52659 52660 52661 52662 # Execute function body 52663 52664 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 52665 $as_echo_n "checking if the C++ compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 52666 supports=yes 52667 52668 saved_cxxflags="$CXXFLAGS" 52669 CXXFLAGS="$CXXFLAG -Wno-this-is-a-warning-that-do-not-exist" 52670 ac_ext=cpp 52671 ac_cpp='$CXXCPP $CPPFLAGS' 52672 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52673 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52674 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 52675 52676 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 52677 /* end confdefs.h. */ 52678 int i; 52679 _ACEOF 52680 if ac_fn_cxx_try_compile "$LINENO"; then : 52681 52682 else 52683 supports=no 52684 fi 52685 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 52686 ac_ext=cpp 52687 ac_cpp='$CXXCPP $CPPFLAGS' 52688 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52689 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52690 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 52691 52692 CXXFLAGS="$saved_cxxflags" 52693 52694 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 52695 $as_echo "$supports" >&6; } 52696 if test "x$supports" = "xyes" ; then 52697 : 52698 CXX_COMP_SUPPORTS="yes" 52699 else 52700 : 52701 CXX_COMP_SUPPORTS="no" 52702 fi 52703 52704 52705 52706 52707 52708 52709 52710 52711 52712 52713 52714 52715 52716 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 52717 $as_echo_n "checking if both compilers support \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 52718 supports=no 52719 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 52720 52721 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 52722 $as_echo "$supports" >&6; } 52723 if test "x$supports" = "xyes" ; then 52724 : 52725 BUILD_CC_CAN_DISABLE_WARNINGS=true 52726 else 52727 : 52728 BUILD_CC_CAN_DISABLE_WARNINGS=false 52729 52730 fi 52731 52732 52733 52734 52735 52736 52737 if test "x$BUILD_CC_CAN_DISABLE_WARNINGS" = "xtrue"; then 52738 BUILD_CC_DISABLE_WARNING_PREFIX="-Wno-" 52739 else 52740 BUILD_CC_DISABLE_WARNING_PREFIX= 52741 fi 52742 CC="$CC_OLD" 52743 CXX="$CXX_OLD" 52744 CFLAGS="$CFLAGS_OLD" 52745 ;; 52746 clang) 52747 DISABLE_WARNING_PREFIX="-Wno-" 52748 CFLAGS_WARNINGS_ARE_ERRORS="-Werror" 52749 ;; 52750 xlc) 52751 DISABLE_WARNING_PREFIX="-qsuppress=" 52752 CFLAGS_WARNINGS_ARE_ERRORS="-qhalt=w" 52753 ;; 52754 esac 52755 52756 52757 52758 52759 52760 # Setup debug symbols (need objcopy from the toolchain for that) 52761 52762 # 52763 # NATIVE_DEBUG_SYMBOLS 52764 # This must be done after the toolchain is setup, since we're looking at objcopy. 52765 # 52766 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what type of native debug symbols to use" >&5 52767 $as_echo_n "checking what type of native debug symbols to use... " >&6; } 52768 52769 # Check whether --with-native-debug-symbols was given. 52770 if test "${with_native_debug_symbols+set}" = set; then : 52771 withval=$with_native_debug_symbols; 52772 if test "x$OPENJDK_TARGET_OS" = xaix; then 52773 if test "x$withval" = xexternal || test "x$withval" = xzipped; then 52774 as_fn_error $? "AIX only supports the parameters 'none' and 'internal' for --with-native-debug-symbols" "$LINENO" 5 52775 fi 52776 fi 52777 52778 else 52779 52780 if test "x$OPENJDK_TARGET_OS" = xaix; then 52781 # AIX doesn't support 'zipped' so use 'internal' as default 52782 with_native_debug_symbols="internal" 52783 else 52784 if test "x$STATIC_BUILD" = xtrue; then 52785 with_native_debug_symbols="none" 52786 else 52787 with_native_debug_symbols="zipped" 52788 fi 52789 fi 52790 52791 fi 52792 52793 NATIVE_DEBUG_SYMBOLS=$with_native_debug_symbols 52794 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NATIVE_DEBUG_SYMBOLS" >&5 52795 $as_echo "$NATIVE_DEBUG_SYMBOLS" >&6; } 52796 52797 if test "x$NATIVE_DEBUG_SYMBOLS" = xzipped; then 52798 52799 if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xlinux; then 52800 if test "x$OBJCOPY" = x; then 52801 # enabling of enable-debug-symbols and can't find objcopy 52802 # this is an error 52803 as_fn_error $? "Unable to find objcopy, cannot enable native debug symbols" "$LINENO" 5 52804 fi 52805 fi 52806 52807 COMPILE_WITH_DEBUG_SYMBOLS=true 52808 COPY_DEBUG_SYMBOLS=true 52809 ZIP_EXTERNAL_DEBUG_SYMBOLS=true 52810 elif test "x$NATIVE_DEBUG_SYMBOLS" = xnone; then 52811 COMPILE_WITH_DEBUG_SYMBOLS=false 52812 COPY_DEBUG_SYMBOLS=false 52813 ZIP_EXTERNAL_DEBUG_SYMBOLS=false 52814 elif test "x$NATIVE_DEBUG_SYMBOLS" = xinternal; then 52815 COMPILE_WITH_DEBUG_SYMBOLS=true 52816 COPY_DEBUG_SYMBOLS=false 52817 ZIP_EXTERNAL_DEBUG_SYMBOLS=false 52818 elif test "x$NATIVE_DEBUG_SYMBOLS" = xexternal; then 52819 52820 if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xlinux; then 52821 if test "x$OBJCOPY" = x; then 52822 # enabling of enable-debug-symbols and can't find objcopy 52823 # this is an error 52824 as_fn_error $? "Unable to find objcopy, cannot enable native debug symbols" "$LINENO" 5 52825 fi 52826 fi 52827 52828 COMPILE_WITH_DEBUG_SYMBOLS=true 52829 COPY_DEBUG_SYMBOLS=true 52830 ZIP_EXTERNAL_DEBUG_SYMBOLS=false 52831 else 52832 as_fn_error $? "Allowed native debug symbols are: none, internal, external, zipped" "$LINENO" 5 52833 fi 52834 52835 # --enable-debug-symbols is deprecated. 52836 # Please use --with-native-debug-symbols=[internal,external,zipped] . 52837 52838 # Check whether --enable-debug-symbols was given. 52839 if test "${enable_debug_symbols+set}" = set; then : 52840 enableval=$enable_debug_symbols; 52841 fi 52842 52843 if test "x$enable_debug_symbols" != x; then 52844 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --enable-debug-symbols is deprecated and will be ignored." >&5 52845 $as_echo "$as_me: WARNING: Option --enable-debug-symbols is deprecated and will be ignored." >&2;} 52846 52847 if test "xPlease use --with-native-debug-symbols=[internal,external,zipped] ." != x; then 52848 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Please use --with-native-debug-symbols=[internal,external,zipped] ." >&5 52849 $as_echo "$as_me: WARNING: Please use --with-native-debug-symbols=[internal,external,zipped] ." >&2;} 52850 fi 52851 52852 fi 52853 52854 52855 # --enable-zip-debug-info is deprecated. 52856 # Please use --with-native-debug-symbols=zipped . 52857 52858 # Check whether --enable-zip-debug-info was given. 52859 if test "${enable_zip_debug_info+set}" = set; then : 52860 enableval=$enable_zip_debug_info; 52861 fi 52862 52863 if test "x$enable_zip_debug_info" != x; then 52864 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --enable-zip-debug-info is deprecated and will be ignored." >&5 52865 $as_echo "$as_me: WARNING: Option --enable-zip-debug-info is deprecated and will be ignored." >&2;} 52866 52867 if test "xPlease use --with-native-debug-symbols=zipped ." != x; then 52868 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Please use --with-native-debug-symbols=zipped ." >&5 52869 $as_echo "$as_me: WARNING: Please use --with-native-debug-symbols=zipped ." >&2;} 52870 fi 52871 52872 fi 52873 52874 52875 52876 52877 52878 52879 52880 # Check whether --enable-native-coverage was given. 52881 if test "${enable_native_coverage+set}" = set; then : 52882 enableval=$enable_native_coverage; 52883 fi 52884 52885 GCOV_ENABLED="false" 52886 if test "x$enable_native_coverage" = "xyes"; then 52887 if test "x$TOOLCHAIN_TYPE" = "xgcc"; then 52888 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if native coverage is enabled" >&5 52889 $as_echo_n "checking if native coverage is enabled... " >&6; } 52890 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 52891 $as_echo "yes" >&6; } 52892 GCOV_CFLAGS="-fprofile-arcs -ftest-coverage -fno-inline" 52893 GCOV_LDFLAGS="-fprofile-arcs" 52894 JVM_CFLAGS="$JVM_CFLAGS $GCOV_CFLAGS" 52895 JVM_LDFLAGS="$JVM_LDFLAGS $GCOV_LDFLAGS" 52896 CFLAGS_JDKLIB="$CFLAGS_JDKLIB $GCOV_CFLAGS" 52897 CFLAGS_JDKEXE="$CFLAGS_JDKEXE $GCOV_CFLAGS" 52898 CXXFLAGS_JDKLIB="$CXXFLAGS_JDKLIB $GCOV_CFLAGS" 52899 CXXFLAGS_JDKEXE="$CXXFLAGS_JDKEXE $GCOV_CFLAGS" 52900 LDFLAGS_JDKLIB="$LDFLAGS_JDKLIB $GCOV_LDFLAGS" 52901 LDFLAGS_JDKEXE="$LDFLAGS_JDKEXE $GCOV_LDFLAGS" 52902 GCOV_ENABLED="true" 52903 else 52904 as_fn_error $? "--enable-native-coverage only works with toolchain type gcc" "$LINENO" 5 52905 fi 52906 elif test "x$enable_native_coverage" = "xno"; then 52907 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if native coverage is enabled" >&5 52908 $as_echo_n "checking if native coverage is enabled... " >&6; } 52909 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 52910 $as_echo "no" >&6; } 52911 elif test "x$enable_native_coverage" != "x"; then 52912 as_fn_error $? "--enable-native-coverage can only be assigned \"yes\" or \"no\"" "$LINENO" 5 52913 fi 52914 52915 52916 52917 52918 # Need toolchain to setup dtrace 52919 52920 # Test for dtrace dependencies 52921 # Check whether --enable-dtrace was given. 52922 if test "${enable_dtrace+set}" = set; then : 52923 enableval=$enable_dtrace; 52924 fi 52925 52926 52927 DTRACE_DEP_MISSING=false 52928 52929 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dtrace tool" >&5 52930 $as_echo_n "checking for dtrace tool... " >&6; } 52931 if test "x$DTRACE" != "x" && test -x "$DTRACE"; then 52932 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DTRACE" >&5 52933 $as_echo "$DTRACE" >&6; } 52934 else 52935 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found, cannot build dtrace" >&5 52936 $as_echo "not found, cannot build dtrace" >&6; } 52937 DTRACE_DEP_MISSING=true 52938 fi 52939 52940 for ac_header in sys/sdt.h 52941 do : 52942 ac_fn_cxx_check_header_mongrel "$LINENO" "sys/sdt.h" "ac_cv_header_sys_sdt_h" "$ac_includes_default" 52943 if test "x$ac_cv_header_sys_sdt_h" = xyes; then : 52944 cat >>confdefs.h <<_ACEOF 52945 #define HAVE_SYS_SDT_H 1 52946 _ACEOF 52947 DTRACE_HEADERS_OK=yes 52948 else 52949 DTRACE_HEADERS_OK=no 52950 fi 52951 52952 done 52953 52954 if test "x$DTRACE_HEADERS_OK" != "xyes"; then 52955 DTRACE_DEP_MISSING=true 52956 fi 52957 52958 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if dtrace should be built" >&5 52959 $as_echo_n "checking if dtrace should be built... " >&6; } 52960 if test "x$enable_dtrace" = "xyes"; then 52961 if test "x$DTRACE_DEP_MISSING" = "xtrue"; then 52962 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, missing dependencies" >&5 52963 $as_echo "no, missing dependencies" >&6; } 52964 52965 # Print a helpful message on how to acquire the necessary build dependency. 52966 # dtrace is the help tag: freetype, cups, alsa etc 52967 MISSING_DEPENDENCY=dtrace 52968 52969 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 52970 cygwin_help $MISSING_DEPENDENCY 52971 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 52972 msys_help $MISSING_DEPENDENCY 52973 else 52974 PKGHANDLER_COMMAND= 52975 52976 case $PKGHANDLER in 52977 apt-get) 52978 apt_help $MISSING_DEPENDENCY ;; 52979 yum) 52980 yum_help $MISSING_DEPENDENCY ;; 52981 brew) 52982 brew_help $MISSING_DEPENDENCY ;; 52983 port) 52984 port_help $MISSING_DEPENDENCY ;; 52985 pkgutil) 52986 pkgutil_help $MISSING_DEPENDENCY ;; 52987 pkgadd) 52988 pkgadd_help $MISSING_DEPENDENCY ;; 52989 esac 52990 52991 if test "x$PKGHANDLER_COMMAND" != x; then 52992 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 52993 fi 52994 fi 52995 52996 as_fn_error $? "Cannot enable dtrace with missing dependencies. See above. $HELP_MSG" "$LINENO" 5 52997 else 52998 INCLUDE_DTRACE=true 52999 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 53000 $as_echo "yes, forced" >&6; } 53001 fi 53002 elif test "x$enable_dtrace" = "xno"; then 53003 INCLUDE_DTRACE=false 53004 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 53005 $as_echo "no, forced" >&6; } 53006 elif test "x$enable_dtrace" = "xauto" || test "x$enable_dtrace" = "x"; then 53007 if test "x$DTRACE_DEP_MISSING" = "xtrue"; then 53008 INCLUDE_DTRACE=false 53009 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, missing dependencies" >&5 53010 $as_echo "no, missing dependencies" >&6; } 53011 else 53012 INCLUDE_DTRACE=true 53013 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, dependencies present" >&5 53014 $as_echo "yes, dependencies present" >&6; } 53015 fi 53016 else 53017 as_fn_error $? "Invalid value for --enable-dtrace: $enable_dtrace" "$LINENO" 5 53018 fi 53019 53020 53021 # Check whether --enable-aot was given. 53022 if test "${enable_aot+set}" = set; then : 53023 enableval=$enable_aot; 53024 fi 53025 53026 53027 if test "x$enable_aot" = "x" || test "x$enable_aot" = "xauto"; then 53028 ENABLE_AOT="true" 53029 elif test "x$enable_aot" = "xyes"; then 53030 ENABLE_AOT="true" 53031 elif test "x$enable_aot" = "xno"; then 53032 ENABLE_AOT="false" 53033 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if aot should be enabled" >&5 53034 $as_echo_n "checking if aot should be enabled... " >&6; } 53035 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 53036 $as_echo "no, forced" >&6; } 53037 else 53038 as_fn_error $? "Invalid value for --enable-aot: $enable_aot" "$LINENO" 5 53039 fi 53040 53041 if test "x$ENABLE_AOT" = "xtrue"; then 53042 # Only enable AOT on linux-X64. 53043 if test "x$OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" = "xlinux-x86_64"; then 53044 if test -e "$HOTSPOT_TOPDIR/src/jdk.aot"; then 53045 if test -e "$HOTSPOT_TOPDIR/src/jdk.internal.vm.compiler"; then 53046 ENABLE_AOT="true" 53047 else 53048 ENABLE_AOT="false" 53049 if test "x$enable_aot" = "xyes"; then 53050 as_fn_error $? "Cannot build AOT without hotspot/src/jdk.internal.vm.compiler sources. Remove --enable-aot." "$LINENO" 5 53051 fi 53052 fi 53053 else 53054 ENABLE_AOT="false" 53055 if test "x$enable_aot" = "xyes"; then 53056 as_fn_error $? "Cannot build AOT without hotspot/src/jdk.aot sources. Remove --enable-aot." "$LINENO" 5 53057 fi 53058 fi 53059 else 53060 ENABLE_AOT="false" 53061 if test "x$enable_aot" = "xyes"; then 53062 as_fn_error $? "AOT is currently only supported on Linux-x86_64. Remove --enable-aot." "$LINENO" 5 53063 fi 53064 fi 53065 fi 53066 53067 53068 53069 53070 # Check whether --enable-hotspot-gtest was given. 53071 if test "${enable_hotspot_gtest+set}" = set; then : 53072 enableval=$enable_hotspot_gtest; 53073 fi 53074 53075 53076 if test -e "$HOTSPOT_TOPDIR/test/native"; then 53077 GTEST_DIR_EXISTS="true" 53078 else 53079 GTEST_DIR_EXISTS="false" 53080 fi 53081 53082 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if Hotspot gtest unit tests should be built" >&5 53083 $as_echo_n "checking if Hotspot gtest unit tests should be built... " >&6; } 53084 if test "x$enable_hotspot_gtest" = "xyes"; then 53085 if test "x$GTEST_DIR_EXISTS" = "xtrue"; then 53086 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 53087 $as_echo "yes, forced" >&6; } 53088 BUILD_GTEST="true" 53089 else 53090 as_fn_error $? "Cannot build gtest without the test source" "$LINENO" 5 53091 fi 53092 elif test "x$enable_hotspot_gtest" = "xno"; then 53093 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 53094 $as_echo "no, forced" >&6; } 53095 BUILD_GTEST="false" 53096 elif test "x$enable_hotspot_gtest" = "x"; then 53097 if test "x$GTEST_DIR_EXISTS" = "xtrue"; then 53098 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 53099 $as_echo "yes" >&6; } 53100 BUILD_GTEST="true" 53101 else 53102 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 53103 $as_echo "no" >&6; } 53104 BUILD_GTEST="false" 53105 fi 53106 else 53107 as_fn_error $? "--enable-gtest must be either yes or no" "$LINENO" 5 53108 fi 53109 53110 53111 53112 53113 ############################################################################### 53114 # 53115 # Check dependencies for external and internal libraries. 53116 # 53117 ############################################################################### 53118 53119 # After we have toolchain, we can compile fixpath. It's needed by the lib checks. 53120 53121 # When using cygwin or msys, we need a wrapper binary that renames 53122 # /cygdrive/c/ arguments into c:/ arguments and peeks into 53123 # @files and rewrites these too! This wrapper binary is 53124 # called fixpath. 53125 FIXPATH= 53126 if test "x$OPENJDK_BUILD_OS" = xwindows; then 53127 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fixpath can be created" >&5 53128 $as_echo_n "checking if fixpath can be created... " >&6; } 53129 FIXPATH_SRC="$SRC_ROOT/common/src/fixpath.c" 53130 FIXPATH_BIN="$CONFIGURESUPPORT_OUTPUTDIR/bin/fixpath.exe" 53131 FIXPATH_DIR="$CONFIGURESUPPORT_OUTPUTDIR/fixpath" 53132 if test "x$OPENJDK_BUILD_OS_ENV" = xwindows.cygwin; then 53133 # Important to keep the .exe suffix on Cygwin for Hotspot makefiles 53134 FIXPATH="$FIXPATH_BIN -c" 53135 elif test "x$OPENJDK_BUILD_OS_ENV" = xwindows.msys; then 53136 # Take all collected prefixes and turn them into a -m/c/foo@/c/bar@... command line 53137 # @ was chosen as separator to minimize risk of other tools messing around with it 53138 all_unique_prefixes=`echo "${all_fixpath_prefixes[@]}" \ 53139 | tr ' ' '\n' | $GREP '^/./' | $SORT | $UNIQ` 53140 fixpath_argument_list=`echo $all_unique_prefixes | tr ' ' '@'` 53141 FIXPATH="$FIXPATH_BIN -m$fixpath_argument_list" 53142 fi 53143 FIXPATH_SRC_W="$FIXPATH_SRC" 53144 FIXPATH_BIN_W="$FIXPATH_BIN" 53145 53146 unix_path="$FIXPATH_SRC_W" 53147 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53148 windows_path=`$CYGPATH -m "$unix_path"` 53149 FIXPATH_SRC_W="$windows_path" 53150 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53151 windows_path=`cmd //c echo $unix_path` 53152 FIXPATH_SRC_W="$windows_path" 53153 fi 53154 53155 53156 unix_path="$FIXPATH_BIN_W" 53157 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53158 windows_path=`$CYGPATH -m "$unix_path"` 53159 FIXPATH_BIN_W="$windows_path" 53160 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53161 windows_path=`cmd //c echo $unix_path` 53162 FIXPATH_BIN_W="$windows_path" 53163 fi 53164 53165 $RM -rf $FIXPATH_BIN $FIXPATH_DIR 53166 $MKDIR -p $FIXPATH_DIR $CONFIGURESUPPORT_OUTPUTDIR/bin 53167 cd $FIXPATH_DIR 53168 $CC $FIXPATH_SRC_W -Fe$FIXPATH_BIN_W > $FIXPATH_DIR/fixpath1.log 2>&1 53169 cd $CURDIR 53170 53171 if test ! -x $FIXPATH_BIN; then 53172 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 53173 $as_echo "no" >&6; } 53174 cat $FIXPATH_DIR/fixpath1.log 53175 as_fn_error $? "Could not create $FIXPATH_BIN" "$LINENO" 5 53176 fi 53177 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 53178 $as_echo "yes" >&6; } 53179 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fixpath.exe works" >&5 53180 $as_echo_n "checking if fixpath.exe works... " >&6; } 53181 cd $FIXPATH_DIR 53182 $FIXPATH $CC $FIXPATH_SRC -Fe$FIXPATH_DIR/fixpath2.exe \ 53183 > $FIXPATH_DIR/fixpath2.log 2>&1 53184 cd $CURDIR 53185 if test ! -x $FIXPATH_DIR/fixpath2.exe; then 53186 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 53187 $as_echo "no" >&6; } 53188 cat $FIXPATH_DIR/fixpath2.log 53189 as_fn_error $? "fixpath did not work!" "$LINENO" 5 53190 fi 53191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 53192 $as_echo "yes" >&6; } 53193 53194 FIXPATH_DETACH_FLAG="--detach" 53195 fi 53196 53197 53198 53199 53200 53201 53202 # Check if X11 is needed 53203 if test "x$OPENJDK_TARGET_OS" = xwindows || test "x$OPENJDK_TARGET_OS" = xmacosx; then 53204 # No X11 support on windows or macosx 53205 NEEDS_LIB_X11=false 53206 else 53207 # All other instances need X11, even if building headless only, libawt still 53208 # needs X11 headers. 53209 NEEDS_LIB_X11=true 53210 fi 53211 53212 # Check if cups is needed 53213 if test "x$OPENJDK_TARGET_OS" = xwindows; then 53214 # Windows have a separate print system 53215 NEEDS_LIB_CUPS=false 53216 else 53217 NEEDS_LIB_CUPS=true 53218 fi 53219 53220 # A custom hook may have set this already 53221 if test "x$NEEDS_LIB_FREETYPE" = "x"; then 53222 NEEDS_LIB_FREETYPE=true 53223 fi 53224 53225 # Check if alsa is needed 53226 if test "x$OPENJDK_TARGET_OS" = xlinux; then 53227 NEEDS_LIB_ALSA=true 53228 else 53229 NEEDS_LIB_ALSA=false 53230 fi 53231 53232 # Check if ffi is needed 53233 if [[ " $JVM_VARIANTS " =~ " zero " ]] || [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 53234 NEEDS_LIB_FFI=true 53235 else 53236 NEEDS_LIB_FFI=false 53237 fi 53238 53239 53240 # statically link libstdc++ before C++ ABI is stablized on Linux unless 53241 # dynamic build is configured on command line. 53242 53243 # Check whether --with-stdc++lib was given. 53244 if test "${with_stdc__lib+set}" = set; then : 53245 withval=$with_stdc__lib; 53246 if test "x$with_stdc__lib" != xdynamic && test "x$with_stdc__lib" != xstatic \ 53247 && test "x$with_stdc__lib" != xdefault; then 53248 as_fn_error $? "Bad parameter value --with-stdc++lib=$with_stdc__lib!" "$LINENO" 5 53249 fi 53250 53251 else 53252 with_stdc__lib=default 53253 53254 fi 53255 53256 53257 if test "x$OPENJDK_TARGET_OS" = xlinux; then 53258 # Test if stdc++ can be linked statically. 53259 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if static link of stdc++ is possible" >&5 53260 $as_echo_n "checking if static link of stdc++ is possible... " >&6; } 53261 STATIC_STDCXX_FLAGS="-static-libstdc++ -static-libgcc" 53262 ac_ext=cpp 53263 ac_cpp='$CXXCPP $CPPFLAGS' 53264 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 53265 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 53266 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 53267 53268 OLD_LIBS="$LIBS" 53269 LIBS="$STATIC_STDCXX_FLAGS" 53270 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 53271 /* end confdefs.h. */ 53272 53273 int 53274 main () 53275 { 53276 return 0; 53277 ; 53278 return 0; 53279 } 53280 _ACEOF 53281 if ac_fn_cxx_try_link "$LINENO"; then : 53282 has_static_libstdcxx=yes 53283 else 53284 has_static_libstdcxx=no 53285 fi 53286 rm -f core conftest.err conftest.$ac_objext \ 53287 conftest$ac_exeext conftest.$ac_ext 53288 LIBS="$OLD_LIBS" 53289 ac_ext=cpp 53290 ac_cpp='$CXXCPP $CPPFLAGS' 53291 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 53292 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 53293 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 53294 53295 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_static_libstdcxx" >&5 53296 $as_echo "$has_static_libstdcxx" >&6; } 53297 53298 if test "x$with_stdc__lib" = xstatic && test "x$has_static_libstdcxx" = xno; then 53299 as_fn_error $? "Static linking of libstdc++ was not possible!" "$LINENO" 5 53300 fi 53301 53302 # If dynamic was requested, it's available since it would fail above otherwise. 53303 # If dynamic wasn't requested, go with static unless it isn't available. 53304 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libstdc++" >&5 53305 $as_echo_n "checking how to link with libstdc++... " >&6; } 53306 if test "x$with_stdc__lib" = xdynamic || test "x$has_static_libstdcxx" = xno \ 53307 || [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 53308 { $as_echo "$as_me:${as_lineno-$LINENO}: result: dynamic" >&5 53309 $as_echo "dynamic" >&6; } 53310 else 53311 LIBCXX="$LIBCXX $STATIC_STDCXX_FLAGS" 53312 JVM_LDFLAGS="$JVM_LDFLAGS $STATIC_STDCXX_FLAGS" 53313 # Ideally, we should test stdc++ for the BUILD toolchain separately. For now 53314 # just use the same setting as for the TARGET toolchain. 53315 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $STATIC_STDCXX_FLAGS" 53316 { $as_echo "$as_me:${as_lineno-$LINENO}: result: static" >&5 53317 $as_echo "static" >&6; } 53318 fi 53319 fi 53320 53321 # libCrun is the c++ runtime-library with SunStudio (roughly the equivalent of gcc's libstdc++.so) 53322 if test "x$TOOLCHAIN_TYPE" = xsolstudio && test "x$LIBCXX" = x; then 53323 LIBCXX="${SYSROOT}/usr/lib${OPENJDK_TARGET_CPU_ISADIR}/libCrun.so.1" 53324 fi 53325 53326 53327 53328 # Setup Windows runtime dlls 53329 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 53330 53331 53332 # Check whether --with-msvcr-dll was given. 53333 if test "${with_msvcr_dll+set}" = set; then : 53334 withval=$with_msvcr_dll; 53335 fi 53336 53337 53338 if test "x$with_msvcr_dll" != x; then 53339 # If given explicitly by user, do not probe. If not present, fail directly. 53340 53341 DLL_NAME="$MSVCR_NAME" 53342 POSSIBLE_MSVC_DLL="$with_msvcr_dll" 53343 METHOD="--with-msvcr-dll" 53344 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 53345 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 53346 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 53347 53348 # Need to check if the found msvcr is correct architecture 53349 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 53350 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 53351 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 53352 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53353 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 53354 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 53355 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53356 CORRECT_MSVCR_ARCH="PE32 executable" 53357 else 53358 CORRECT_MSVCR_ARCH="PE32+ executable" 53359 fi 53360 else 53361 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53362 CORRECT_MSVCR_ARCH=386 53363 else 53364 CORRECT_MSVCR_ARCH=x86-64 53365 fi 53366 fi 53367 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 53368 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 53369 $as_echo "ok" >&6; } 53370 MSVC_DLL="$POSSIBLE_MSVC_DLL" 53371 53372 # Only process if variable expands to non-empty 53373 53374 if test "x$MSVC_DLL" != x; then 53375 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53376 53377 # Input might be given as Windows format, start by converting to 53378 # unix format. 53379 path="$MSVC_DLL" 53380 new_path=`$CYGPATH -u "$path"` 53381 53382 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 53383 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 53384 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 53385 # "foo.exe" is OK but "foo" is an error. 53386 # 53387 # This test is therefore slightly more accurate than "test -f" to check for file precense. 53388 # It is also a way to make sure we got the proper file name for the real test later on. 53389 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 53390 if test "x$test_shortpath" = x; then 53391 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 53392 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 53393 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 53394 fi 53395 53396 # Call helper function which possibly converts this using DOS-style short mode. 53397 # If so, the updated path is stored in $new_path. 53398 53399 input_path="$new_path" 53400 # Check if we need to convert this using DOS-style short mode. If the path 53401 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53402 # take no chances and rewrite it. 53403 # Note: m4 eats our [], so we need to use [ and ] instead. 53404 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 53405 if test "x$has_forbidden_chars" != x; then 53406 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53407 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 53408 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 53409 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 53410 # Going to short mode and back again did indeed matter. Since short mode is 53411 # case insensitive, let's make it lowercase to improve readability. 53412 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53413 # Now convert it back to Unix-style (cygpath) 53414 input_path=`$CYGPATH -u "$shortmode_path"` 53415 new_path="$input_path" 53416 fi 53417 fi 53418 53419 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 53420 if test "x$test_cygdrive_prefix" = x; then 53421 # As a simple fix, exclude /usr/bin since it's not a real path. 53422 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 53423 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 53424 # a path prefixed by /cygdrive for fixpath to work. 53425 new_path="$CYGWIN_ROOT_PATH$input_path" 53426 fi 53427 fi 53428 53429 53430 if test "x$path" != "x$new_path"; then 53431 MSVC_DLL="$new_path" 53432 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 53433 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 53434 fi 53435 53436 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53437 53438 path="$MSVC_DLL" 53439 has_colon=`$ECHO $path | $GREP ^.:` 53440 new_path="$path" 53441 if test "x$has_colon" = x; then 53442 # Not in mixed or Windows style, start by that. 53443 new_path=`cmd //c echo $path` 53444 fi 53445 53446 53447 input_path="$new_path" 53448 # Check if we need to convert this using DOS-style short mode. If the path 53449 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53450 # take no chances and rewrite it. 53451 # Note: m4 eats our [], so we need to use [ and ] instead. 53452 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 53453 if test "x$has_forbidden_chars" != x; then 53454 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53455 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53456 fi 53457 53458 53459 windows_path="$new_path" 53460 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53461 unix_path=`$CYGPATH -u "$windows_path"` 53462 new_path="$unix_path" 53463 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53464 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 53465 new_path="$unix_path" 53466 fi 53467 53468 if test "x$path" != "x$new_path"; then 53469 MSVC_DLL="$new_path" 53470 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 53471 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 53472 fi 53473 53474 # Save the first 10 bytes of this path to the storage, so fixpath can work. 53475 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 53476 53477 else 53478 # We're on a unix platform. Hooray! :) 53479 path="$MSVC_DLL" 53480 has_space=`$ECHO "$path" | $GREP " "` 53481 if test "x$has_space" != x; then 53482 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 53483 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 53484 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 53485 fi 53486 53487 # Use eval to expand a potential ~ 53488 eval path="$path" 53489 if test ! -f "$path" && test ! -d "$path"; then 53490 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 53491 fi 53492 53493 if test -d "$path"; then 53494 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 53495 else 53496 dir="`$DIRNAME "$path"`" 53497 base="`$BASENAME "$path"`" 53498 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 53499 fi 53500 fi 53501 fi 53502 53503 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 53504 $as_echo_n "checking for $DLL_NAME... " >&6; } 53505 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 53506 $as_echo "$MSVC_DLL" >&6; } 53507 else 53508 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 53509 $as_echo "incorrect, ignoring" >&6; } 53510 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 53511 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 53512 fi 53513 fi 53514 53515 if test "x$MSVC_DLL" = x; then 53516 as_fn_error $? "Could not find a proper $MSVCR_NAME as specified by --with-msvcr-dll" "$LINENO" 5 53517 fi 53518 MSVCR_DLL="$MSVC_DLL" 53519 elif test "x$DEVKIT_MSVCR_DLL" != x; then 53520 53521 DLL_NAME="$MSVCR_NAME" 53522 POSSIBLE_MSVC_DLL="$DEVKIT_MSVCR_DLL" 53523 METHOD="devkit" 53524 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 53525 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 53526 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 53527 53528 # Need to check if the found msvcr is correct architecture 53529 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 53530 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 53531 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 53532 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53533 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 53534 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 53535 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53536 CORRECT_MSVCR_ARCH="PE32 executable" 53537 else 53538 CORRECT_MSVCR_ARCH="PE32+ executable" 53539 fi 53540 else 53541 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53542 CORRECT_MSVCR_ARCH=386 53543 else 53544 CORRECT_MSVCR_ARCH=x86-64 53545 fi 53546 fi 53547 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 53548 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 53549 $as_echo "ok" >&6; } 53550 MSVC_DLL="$POSSIBLE_MSVC_DLL" 53551 53552 # Only process if variable expands to non-empty 53553 53554 if test "x$MSVC_DLL" != x; then 53555 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53556 53557 # Input might be given as Windows format, start by converting to 53558 # unix format. 53559 path="$MSVC_DLL" 53560 new_path=`$CYGPATH -u "$path"` 53561 53562 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 53563 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 53564 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 53565 # "foo.exe" is OK but "foo" is an error. 53566 # 53567 # This test is therefore slightly more accurate than "test -f" to check for file precense. 53568 # It is also a way to make sure we got the proper file name for the real test later on. 53569 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 53570 if test "x$test_shortpath" = x; then 53571 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 53572 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 53573 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 53574 fi 53575 53576 # Call helper function which possibly converts this using DOS-style short mode. 53577 # If so, the updated path is stored in $new_path. 53578 53579 input_path="$new_path" 53580 # Check if we need to convert this using DOS-style short mode. If the path 53581 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53582 # take no chances and rewrite it. 53583 # Note: m4 eats our [], so we need to use [ and ] instead. 53584 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 53585 if test "x$has_forbidden_chars" != x; then 53586 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53587 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 53588 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 53589 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 53590 # Going to short mode and back again did indeed matter. Since short mode is 53591 # case insensitive, let's make it lowercase to improve readability. 53592 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53593 # Now convert it back to Unix-style (cygpath) 53594 input_path=`$CYGPATH -u "$shortmode_path"` 53595 new_path="$input_path" 53596 fi 53597 fi 53598 53599 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 53600 if test "x$test_cygdrive_prefix" = x; then 53601 # As a simple fix, exclude /usr/bin since it's not a real path. 53602 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 53603 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 53604 # a path prefixed by /cygdrive for fixpath to work. 53605 new_path="$CYGWIN_ROOT_PATH$input_path" 53606 fi 53607 fi 53608 53609 53610 if test "x$path" != "x$new_path"; then 53611 MSVC_DLL="$new_path" 53612 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 53613 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 53614 fi 53615 53616 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53617 53618 path="$MSVC_DLL" 53619 has_colon=`$ECHO $path | $GREP ^.:` 53620 new_path="$path" 53621 if test "x$has_colon" = x; then 53622 # Not in mixed or Windows style, start by that. 53623 new_path=`cmd //c echo $path` 53624 fi 53625 53626 53627 input_path="$new_path" 53628 # Check if we need to convert this using DOS-style short mode. If the path 53629 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53630 # take no chances and rewrite it. 53631 # Note: m4 eats our [], so we need to use [ and ] instead. 53632 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 53633 if test "x$has_forbidden_chars" != x; then 53634 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53635 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53636 fi 53637 53638 53639 windows_path="$new_path" 53640 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53641 unix_path=`$CYGPATH -u "$windows_path"` 53642 new_path="$unix_path" 53643 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53644 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 53645 new_path="$unix_path" 53646 fi 53647 53648 if test "x$path" != "x$new_path"; then 53649 MSVC_DLL="$new_path" 53650 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 53651 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 53652 fi 53653 53654 # Save the first 10 bytes of this path to the storage, so fixpath can work. 53655 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 53656 53657 else 53658 # We're on a unix platform. Hooray! :) 53659 path="$MSVC_DLL" 53660 has_space=`$ECHO "$path" | $GREP " "` 53661 if test "x$has_space" != x; then 53662 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 53663 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 53664 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 53665 fi 53666 53667 # Use eval to expand a potential ~ 53668 eval path="$path" 53669 if test ! -f "$path" && test ! -d "$path"; then 53670 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 53671 fi 53672 53673 if test -d "$path"; then 53674 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 53675 else 53676 dir="`$DIRNAME "$path"`" 53677 base="`$BASENAME "$path"`" 53678 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 53679 fi 53680 fi 53681 fi 53682 53683 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 53684 $as_echo_n "checking for $DLL_NAME... " >&6; } 53685 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 53686 $as_echo "$MSVC_DLL" >&6; } 53687 else 53688 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 53689 $as_echo "incorrect, ignoring" >&6; } 53690 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 53691 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 53692 fi 53693 fi 53694 53695 if test "x$MSVC_DLL" = x; then 53696 as_fn_error $? "Could not find a proper $MSVCR_NAME as specified by devkit" "$LINENO" 5 53697 fi 53698 MSVCR_DLL="$MSVC_DLL" 53699 else 53700 53701 DLL_NAME="${MSVCR_NAME}" 53702 MSVC_DLL= 53703 53704 if test "x$MSVC_DLL" = x; then 53705 # Probe: Using well-known location from Visual Studio 10.0 53706 if test "x$VCINSTALLDIR" != x; then 53707 CYGWIN_VC_INSTALL_DIR="$VCINSTALLDIR" 53708 53709 windows_path="$CYGWIN_VC_INSTALL_DIR" 53710 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53711 unix_path=`$CYGPATH -u "$windows_path"` 53712 CYGWIN_VC_INSTALL_DIR="$unix_path" 53713 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53714 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 53715 CYGWIN_VC_INSTALL_DIR="$unix_path" 53716 fi 53717 53718 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 53719 POSSIBLE_MSVC_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x64/Microsoft.VC${VS_VERSION_INTERNAL}.CRT/$DLL_NAME" 53720 else 53721 POSSIBLE_MSVC_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x86/Microsoft.VC${VS_VERSION_INTERNAL}.CRT/$DLL_NAME" 53722 fi 53723 $ECHO "POSSIBLE_MSVC_DLL $POSSIBLEMSVC_DLL" 53724 53725 DLL_NAME="$DLL_NAME" 53726 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 53727 METHOD="well-known location in VCINSTALLDIR" 53728 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 53729 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 53730 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 53731 53732 # Need to check if the found msvcr is correct architecture 53733 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 53734 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 53735 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 53736 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53737 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 53738 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 53739 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53740 CORRECT_MSVCR_ARCH="PE32 executable" 53741 else 53742 CORRECT_MSVCR_ARCH="PE32+ executable" 53743 fi 53744 else 53745 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53746 CORRECT_MSVCR_ARCH=386 53747 else 53748 CORRECT_MSVCR_ARCH=x86-64 53749 fi 53750 fi 53751 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 53752 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 53753 $as_echo "ok" >&6; } 53754 MSVC_DLL="$POSSIBLE_MSVC_DLL" 53755 53756 # Only process if variable expands to non-empty 53757 53758 if test "x$MSVC_DLL" != x; then 53759 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53760 53761 # Input might be given as Windows format, start by converting to 53762 # unix format. 53763 path="$MSVC_DLL" 53764 new_path=`$CYGPATH -u "$path"` 53765 53766 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 53767 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 53768 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 53769 # "foo.exe" is OK but "foo" is an error. 53770 # 53771 # This test is therefore slightly more accurate than "test -f" to check for file precense. 53772 # It is also a way to make sure we got the proper file name for the real test later on. 53773 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 53774 if test "x$test_shortpath" = x; then 53775 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 53776 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 53777 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 53778 fi 53779 53780 # Call helper function which possibly converts this using DOS-style short mode. 53781 # If so, the updated path is stored in $new_path. 53782 53783 input_path="$new_path" 53784 # Check if we need to convert this using DOS-style short mode. If the path 53785 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53786 # take no chances and rewrite it. 53787 # Note: m4 eats our [], so we need to use [ and ] instead. 53788 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 53789 if test "x$has_forbidden_chars" != x; then 53790 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53791 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 53792 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 53793 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 53794 # Going to short mode and back again did indeed matter. Since short mode is 53795 # case insensitive, let's make it lowercase to improve readability. 53796 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53797 # Now convert it back to Unix-style (cygpath) 53798 input_path=`$CYGPATH -u "$shortmode_path"` 53799 new_path="$input_path" 53800 fi 53801 fi 53802 53803 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 53804 if test "x$test_cygdrive_prefix" = x; then 53805 # As a simple fix, exclude /usr/bin since it's not a real path. 53806 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 53807 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 53808 # a path prefixed by /cygdrive for fixpath to work. 53809 new_path="$CYGWIN_ROOT_PATH$input_path" 53810 fi 53811 fi 53812 53813 53814 if test "x$path" != "x$new_path"; then 53815 MSVC_DLL="$new_path" 53816 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 53817 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 53818 fi 53819 53820 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53821 53822 path="$MSVC_DLL" 53823 has_colon=`$ECHO $path | $GREP ^.:` 53824 new_path="$path" 53825 if test "x$has_colon" = x; then 53826 # Not in mixed or Windows style, start by that. 53827 new_path=`cmd //c echo $path` 53828 fi 53829 53830 53831 input_path="$new_path" 53832 # Check if we need to convert this using DOS-style short mode. If the path 53833 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53834 # take no chances and rewrite it. 53835 # Note: m4 eats our [], so we need to use [ and ] instead. 53836 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 53837 if test "x$has_forbidden_chars" != x; then 53838 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53839 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53840 fi 53841 53842 53843 windows_path="$new_path" 53844 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53845 unix_path=`$CYGPATH -u "$windows_path"` 53846 new_path="$unix_path" 53847 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53848 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 53849 new_path="$unix_path" 53850 fi 53851 53852 if test "x$path" != "x$new_path"; then 53853 MSVC_DLL="$new_path" 53854 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 53855 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 53856 fi 53857 53858 # Save the first 10 bytes of this path to the storage, so fixpath can work. 53859 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 53860 53861 else 53862 # We're on a unix platform. Hooray! :) 53863 path="$MSVC_DLL" 53864 has_space=`$ECHO "$path" | $GREP " "` 53865 if test "x$has_space" != x; then 53866 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 53867 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 53868 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 53869 fi 53870 53871 # Use eval to expand a potential ~ 53872 eval path="$path" 53873 if test ! -f "$path" && test ! -d "$path"; then 53874 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 53875 fi 53876 53877 if test -d "$path"; then 53878 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 53879 else 53880 dir="`$DIRNAME "$path"`" 53881 base="`$BASENAME "$path"`" 53882 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 53883 fi 53884 fi 53885 fi 53886 53887 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 53888 $as_echo_n "checking for $DLL_NAME... " >&6; } 53889 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 53890 $as_echo "$MSVC_DLL" >&6; } 53891 else 53892 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 53893 $as_echo "incorrect, ignoring" >&6; } 53894 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 53895 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 53896 fi 53897 fi 53898 53899 fi 53900 fi 53901 53902 if test "x$MSVC_DLL" = x; then 53903 # Probe: Check in the Boot JDK directory. 53904 POSSIBLE_MSVC_DLL="$BOOT_JDK/bin/$DLL_NAME" 53905 53906 DLL_NAME="$DLL_NAME" 53907 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 53908 METHOD="well-known location in Boot JDK" 53909 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 53910 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 53911 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 53912 53913 # Need to check if the found msvcr is correct architecture 53914 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 53915 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 53916 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 53917 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53918 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 53919 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 53920 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53921 CORRECT_MSVCR_ARCH="PE32 executable" 53922 else 53923 CORRECT_MSVCR_ARCH="PE32+ executable" 53924 fi 53925 else 53926 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53927 CORRECT_MSVCR_ARCH=386 53928 else 53929 CORRECT_MSVCR_ARCH=x86-64 53930 fi 53931 fi 53932 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 53933 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 53934 $as_echo "ok" >&6; } 53935 MSVC_DLL="$POSSIBLE_MSVC_DLL" 53936 53937 # Only process if variable expands to non-empty 53938 53939 if test "x$MSVC_DLL" != x; then 53940 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53941 53942 # Input might be given as Windows format, start by converting to 53943 # unix format. 53944 path="$MSVC_DLL" 53945 new_path=`$CYGPATH -u "$path"` 53946 53947 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 53948 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 53949 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 53950 # "foo.exe" is OK but "foo" is an error. 53951 # 53952 # This test is therefore slightly more accurate than "test -f" to check for file precense. 53953 # It is also a way to make sure we got the proper file name for the real test later on. 53954 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 53955 if test "x$test_shortpath" = x; then 53956 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 53957 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 53958 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 53959 fi 53960 53961 # Call helper function which possibly converts this using DOS-style short mode. 53962 # If so, the updated path is stored in $new_path. 53963 53964 input_path="$new_path" 53965 # Check if we need to convert this using DOS-style short mode. If the path 53966 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53967 # take no chances and rewrite it. 53968 # Note: m4 eats our [], so we need to use [ and ] instead. 53969 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 53970 if test "x$has_forbidden_chars" != x; then 53971 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53972 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 53973 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 53974 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 53975 # Going to short mode and back again did indeed matter. Since short mode is 53976 # case insensitive, let's make it lowercase to improve readability. 53977 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53978 # Now convert it back to Unix-style (cygpath) 53979 input_path=`$CYGPATH -u "$shortmode_path"` 53980 new_path="$input_path" 53981 fi 53982 fi 53983 53984 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 53985 if test "x$test_cygdrive_prefix" = x; then 53986 # As a simple fix, exclude /usr/bin since it's not a real path. 53987 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 53988 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 53989 # a path prefixed by /cygdrive for fixpath to work. 53990 new_path="$CYGWIN_ROOT_PATH$input_path" 53991 fi 53992 fi 53993 53994 53995 if test "x$path" != "x$new_path"; then 53996 MSVC_DLL="$new_path" 53997 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 53998 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 53999 fi 54000 54001 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54002 54003 path="$MSVC_DLL" 54004 has_colon=`$ECHO $path | $GREP ^.:` 54005 new_path="$path" 54006 if test "x$has_colon" = x; then 54007 # Not in mixed or Windows style, start by that. 54008 new_path=`cmd //c echo $path` 54009 fi 54010 54011 54012 input_path="$new_path" 54013 # Check if we need to convert this using DOS-style short mode. If the path 54014 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54015 # take no chances and rewrite it. 54016 # Note: m4 eats our [], so we need to use [ and ] instead. 54017 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 54018 if test "x$has_forbidden_chars" != x; then 54019 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54020 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54021 fi 54022 54023 54024 windows_path="$new_path" 54025 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54026 unix_path=`$CYGPATH -u "$windows_path"` 54027 new_path="$unix_path" 54028 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54029 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54030 new_path="$unix_path" 54031 fi 54032 54033 if test "x$path" != "x$new_path"; then 54034 MSVC_DLL="$new_path" 54035 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54036 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54037 fi 54038 54039 # Save the first 10 bytes of this path to the storage, so fixpath can work. 54040 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 54041 54042 else 54043 # We're on a unix platform. Hooray! :) 54044 path="$MSVC_DLL" 54045 has_space=`$ECHO "$path" | $GREP " "` 54046 if test "x$has_space" != x; then 54047 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54048 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54049 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 54050 fi 54051 54052 # Use eval to expand a potential ~ 54053 eval path="$path" 54054 if test ! -f "$path" && test ! -d "$path"; then 54055 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 54056 fi 54057 54058 if test -d "$path"; then 54059 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 54060 else 54061 dir="`$DIRNAME "$path"`" 54062 base="`$BASENAME "$path"`" 54063 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 54064 fi 54065 fi 54066 fi 54067 54068 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 54069 $as_echo_n "checking for $DLL_NAME... " >&6; } 54070 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 54071 $as_echo "$MSVC_DLL" >&6; } 54072 else 54073 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 54074 $as_echo "incorrect, ignoring" >&6; } 54075 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 54076 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 54077 fi 54078 fi 54079 54080 fi 54081 54082 if test "x$MSVC_DLL" = x; then 54083 # Probe: Look in the Windows system32 directory 54084 CYGWIN_SYSTEMROOT="$SYSTEMROOT" 54085 54086 windows_path="$CYGWIN_SYSTEMROOT" 54087 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54088 unix_path=`$CYGPATH -u "$windows_path"` 54089 CYGWIN_SYSTEMROOT="$unix_path" 54090 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54091 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54092 CYGWIN_SYSTEMROOT="$unix_path" 54093 fi 54094 54095 POSSIBLE_MSVC_DLL="$CYGWIN_SYSTEMROOT/system32/$DLL_NAME" 54096 54097 DLL_NAME="$DLL_NAME" 54098 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 54099 METHOD="well-known location in SYSTEMROOT" 54100 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 54101 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 54102 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 54103 54104 # Need to check if the found msvcr is correct architecture 54105 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 54106 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 54107 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 54108 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54109 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 54110 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 54111 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54112 CORRECT_MSVCR_ARCH="PE32 executable" 54113 else 54114 CORRECT_MSVCR_ARCH="PE32+ executable" 54115 fi 54116 else 54117 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54118 CORRECT_MSVCR_ARCH=386 54119 else 54120 CORRECT_MSVCR_ARCH=x86-64 54121 fi 54122 fi 54123 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 54124 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 54125 $as_echo "ok" >&6; } 54126 MSVC_DLL="$POSSIBLE_MSVC_DLL" 54127 54128 # Only process if variable expands to non-empty 54129 54130 if test "x$MSVC_DLL" != x; then 54131 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54132 54133 # Input might be given as Windows format, start by converting to 54134 # unix format. 54135 path="$MSVC_DLL" 54136 new_path=`$CYGPATH -u "$path"` 54137 54138 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 54139 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 54140 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 54141 # "foo.exe" is OK but "foo" is an error. 54142 # 54143 # This test is therefore slightly more accurate than "test -f" to check for file precense. 54144 # It is also a way to make sure we got the proper file name for the real test later on. 54145 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 54146 if test "x$test_shortpath" = x; then 54147 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54148 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54149 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 54150 fi 54151 54152 # Call helper function which possibly converts this using DOS-style short mode. 54153 # If so, the updated path is stored in $new_path. 54154 54155 input_path="$new_path" 54156 # Check if we need to convert this using DOS-style short mode. If the path 54157 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54158 # take no chances and rewrite it. 54159 # Note: m4 eats our [], so we need to use [ and ] instead. 54160 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 54161 if test "x$has_forbidden_chars" != x; then 54162 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54163 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 54164 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 54165 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 54166 # Going to short mode and back again did indeed matter. Since short mode is 54167 # case insensitive, let's make it lowercase to improve readability. 54168 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54169 # Now convert it back to Unix-style (cygpath) 54170 input_path=`$CYGPATH -u "$shortmode_path"` 54171 new_path="$input_path" 54172 fi 54173 fi 54174 54175 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 54176 if test "x$test_cygdrive_prefix" = x; then 54177 # As a simple fix, exclude /usr/bin since it's not a real path. 54178 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 54179 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 54180 # a path prefixed by /cygdrive for fixpath to work. 54181 new_path="$CYGWIN_ROOT_PATH$input_path" 54182 fi 54183 fi 54184 54185 54186 if test "x$path" != "x$new_path"; then 54187 MSVC_DLL="$new_path" 54188 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54189 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54190 fi 54191 54192 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54193 54194 path="$MSVC_DLL" 54195 has_colon=`$ECHO $path | $GREP ^.:` 54196 new_path="$path" 54197 if test "x$has_colon" = x; then 54198 # Not in mixed or Windows style, start by that. 54199 new_path=`cmd //c echo $path` 54200 fi 54201 54202 54203 input_path="$new_path" 54204 # Check if we need to convert this using DOS-style short mode. If the path 54205 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54206 # take no chances and rewrite it. 54207 # Note: m4 eats our [], so we need to use [ and ] instead. 54208 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 54209 if test "x$has_forbidden_chars" != x; then 54210 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54211 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54212 fi 54213 54214 54215 windows_path="$new_path" 54216 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54217 unix_path=`$CYGPATH -u "$windows_path"` 54218 new_path="$unix_path" 54219 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54220 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54221 new_path="$unix_path" 54222 fi 54223 54224 if test "x$path" != "x$new_path"; then 54225 MSVC_DLL="$new_path" 54226 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54227 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54228 fi 54229 54230 # Save the first 10 bytes of this path to the storage, so fixpath can work. 54231 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 54232 54233 else 54234 # We're on a unix platform. Hooray! :) 54235 path="$MSVC_DLL" 54236 has_space=`$ECHO "$path" | $GREP " "` 54237 if test "x$has_space" != x; then 54238 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54239 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54240 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 54241 fi 54242 54243 # Use eval to expand a potential ~ 54244 eval path="$path" 54245 if test ! -f "$path" && test ! -d "$path"; then 54246 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 54247 fi 54248 54249 if test -d "$path"; then 54250 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 54251 else 54252 dir="`$DIRNAME "$path"`" 54253 base="`$BASENAME "$path"`" 54254 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 54255 fi 54256 fi 54257 fi 54258 54259 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 54260 $as_echo_n "checking for $DLL_NAME... " >&6; } 54261 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 54262 $as_echo "$MSVC_DLL" >&6; } 54263 else 54264 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 54265 $as_echo "incorrect, ignoring" >&6; } 54266 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 54267 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 54268 fi 54269 fi 54270 54271 fi 54272 54273 if test "x$MSVC_DLL" = x; then 54274 # Probe: If Visual Studio Express is installed, there is usually one with the debugger 54275 if test "x$VS100COMNTOOLS" != x; then 54276 CYGWIN_VS_TOOLS_DIR="$VS100COMNTOOLS/.." 54277 54278 windows_path="$CYGWIN_VS_TOOLS_DIR" 54279 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54280 unix_path=`$CYGPATH -u "$windows_path"` 54281 CYGWIN_VS_TOOLS_DIR="$unix_path" 54282 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54283 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54284 CYGWIN_VS_TOOLS_DIR="$unix_path" 54285 fi 54286 54287 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 54288 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name $DLL_NAME \ 54289 | $GREP -i /x64/ | $HEAD --lines 1` 54290 else 54291 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name $DLL_NAME \ 54292 | $GREP -i /x86/ | $HEAD --lines 1` 54293 fi 54294 54295 DLL_NAME="$DLL_NAME" 54296 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 54297 METHOD="search of VS100COMNTOOLS" 54298 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 54299 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 54300 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 54301 54302 # Need to check if the found msvcr is correct architecture 54303 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 54304 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 54305 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 54306 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54307 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 54308 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 54309 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54310 CORRECT_MSVCR_ARCH="PE32 executable" 54311 else 54312 CORRECT_MSVCR_ARCH="PE32+ executable" 54313 fi 54314 else 54315 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54316 CORRECT_MSVCR_ARCH=386 54317 else 54318 CORRECT_MSVCR_ARCH=x86-64 54319 fi 54320 fi 54321 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 54322 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 54323 $as_echo "ok" >&6; } 54324 MSVC_DLL="$POSSIBLE_MSVC_DLL" 54325 54326 # Only process if variable expands to non-empty 54327 54328 if test "x$MSVC_DLL" != x; then 54329 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54330 54331 # Input might be given as Windows format, start by converting to 54332 # unix format. 54333 path="$MSVC_DLL" 54334 new_path=`$CYGPATH -u "$path"` 54335 54336 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 54337 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 54338 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 54339 # "foo.exe" is OK but "foo" is an error. 54340 # 54341 # This test is therefore slightly more accurate than "test -f" to check for file precense. 54342 # It is also a way to make sure we got the proper file name for the real test later on. 54343 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 54344 if test "x$test_shortpath" = x; then 54345 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54346 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54347 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 54348 fi 54349 54350 # Call helper function which possibly converts this using DOS-style short mode. 54351 # If so, the updated path is stored in $new_path. 54352 54353 input_path="$new_path" 54354 # Check if we need to convert this using DOS-style short mode. If the path 54355 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54356 # take no chances and rewrite it. 54357 # Note: m4 eats our [], so we need to use [ and ] instead. 54358 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 54359 if test "x$has_forbidden_chars" != x; then 54360 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54361 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 54362 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 54363 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 54364 # Going to short mode and back again did indeed matter. Since short mode is 54365 # case insensitive, let's make it lowercase to improve readability. 54366 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54367 # Now convert it back to Unix-style (cygpath) 54368 input_path=`$CYGPATH -u "$shortmode_path"` 54369 new_path="$input_path" 54370 fi 54371 fi 54372 54373 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 54374 if test "x$test_cygdrive_prefix" = x; then 54375 # As a simple fix, exclude /usr/bin since it's not a real path. 54376 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 54377 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 54378 # a path prefixed by /cygdrive for fixpath to work. 54379 new_path="$CYGWIN_ROOT_PATH$input_path" 54380 fi 54381 fi 54382 54383 54384 if test "x$path" != "x$new_path"; then 54385 MSVC_DLL="$new_path" 54386 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54387 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54388 fi 54389 54390 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54391 54392 path="$MSVC_DLL" 54393 has_colon=`$ECHO $path | $GREP ^.:` 54394 new_path="$path" 54395 if test "x$has_colon" = x; then 54396 # Not in mixed or Windows style, start by that. 54397 new_path=`cmd //c echo $path` 54398 fi 54399 54400 54401 input_path="$new_path" 54402 # Check if we need to convert this using DOS-style short mode. If the path 54403 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54404 # take no chances and rewrite it. 54405 # Note: m4 eats our [], so we need to use [ and ] instead. 54406 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 54407 if test "x$has_forbidden_chars" != x; then 54408 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54409 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54410 fi 54411 54412 54413 windows_path="$new_path" 54414 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54415 unix_path=`$CYGPATH -u "$windows_path"` 54416 new_path="$unix_path" 54417 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54418 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54419 new_path="$unix_path" 54420 fi 54421 54422 if test "x$path" != "x$new_path"; then 54423 MSVC_DLL="$new_path" 54424 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54425 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54426 fi 54427 54428 # Save the first 10 bytes of this path to the storage, so fixpath can work. 54429 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 54430 54431 else 54432 # We're on a unix platform. Hooray! :) 54433 path="$MSVC_DLL" 54434 has_space=`$ECHO "$path" | $GREP " "` 54435 if test "x$has_space" != x; then 54436 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54437 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54438 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 54439 fi 54440 54441 # Use eval to expand a potential ~ 54442 eval path="$path" 54443 if test ! -f "$path" && test ! -d "$path"; then 54444 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 54445 fi 54446 54447 if test -d "$path"; then 54448 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 54449 else 54450 dir="`$DIRNAME "$path"`" 54451 base="`$BASENAME "$path"`" 54452 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 54453 fi 54454 fi 54455 fi 54456 54457 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 54458 $as_echo_n "checking for $DLL_NAME... " >&6; } 54459 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 54460 $as_echo "$MSVC_DLL" >&6; } 54461 else 54462 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 54463 $as_echo "incorrect, ignoring" >&6; } 54464 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 54465 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 54466 fi 54467 fi 54468 54469 fi 54470 fi 54471 54472 if test "x$MSVC_DLL" = x; then 54473 # Probe: Search wildly in the VCINSTALLDIR. We've probably lost by now. 54474 # (This was the original behaviour; kept since it might turn something up) 54475 if test "x$CYGWIN_VC_INSTALL_DIR" != x; then 54476 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 54477 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 54478 | $GREP x64 | $HEAD --lines 1` 54479 else 54480 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 54481 | $GREP x86 | $GREP -v ia64 | $GREP -v x64 | $HEAD --lines 1` 54482 if test "x$POSSIBLE_MSVC_DLL" = x; then 54483 # We're grasping at straws now... 54484 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 54485 | $HEAD --lines 1` 54486 fi 54487 fi 54488 54489 54490 DLL_NAME="$DLL_NAME" 54491 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 54492 METHOD="search of VCINSTALLDIR" 54493 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 54494 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 54495 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 54496 54497 # Need to check if the found msvcr is correct architecture 54498 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 54499 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 54500 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 54501 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54502 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 54503 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 54504 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54505 CORRECT_MSVCR_ARCH="PE32 executable" 54506 else 54507 CORRECT_MSVCR_ARCH="PE32+ executable" 54508 fi 54509 else 54510 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54511 CORRECT_MSVCR_ARCH=386 54512 else 54513 CORRECT_MSVCR_ARCH=x86-64 54514 fi 54515 fi 54516 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 54517 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 54518 $as_echo "ok" >&6; } 54519 MSVC_DLL="$POSSIBLE_MSVC_DLL" 54520 54521 # Only process if variable expands to non-empty 54522 54523 if test "x$MSVC_DLL" != x; then 54524 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54525 54526 # Input might be given as Windows format, start by converting to 54527 # unix format. 54528 path="$MSVC_DLL" 54529 new_path=`$CYGPATH -u "$path"` 54530 54531 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 54532 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 54533 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 54534 # "foo.exe" is OK but "foo" is an error. 54535 # 54536 # This test is therefore slightly more accurate than "test -f" to check for file precense. 54537 # It is also a way to make sure we got the proper file name for the real test later on. 54538 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 54539 if test "x$test_shortpath" = x; then 54540 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54541 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54542 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 54543 fi 54544 54545 # Call helper function which possibly converts this using DOS-style short mode. 54546 # If so, the updated path is stored in $new_path. 54547 54548 input_path="$new_path" 54549 # Check if we need to convert this using DOS-style short mode. If the path 54550 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54551 # take no chances and rewrite it. 54552 # Note: m4 eats our [], so we need to use [ and ] instead. 54553 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 54554 if test "x$has_forbidden_chars" != x; then 54555 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54556 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 54557 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 54558 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 54559 # Going to short mode and back again did indeed matter. Since short mode is 54560 # case insensitive, let's make it lowercase to improve readability. 54561 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54562 # Now convert it back to Unix-style (cygpath) 54563 input_path=`$CYGPATH -u "$shortmode_path"` 54564 new_path="$input_path" 54565 fi 54566 fi 54567 54568 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 54569 if test "x$test_cygdrive_prefix" = x; then 54570 # As a simple fix, exclude /usr/bin since it's not a real path. 54571 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 54572 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 54573 # a path prefixed by /cygdrive for fixpath to work. 54574 new_path="$CYGWIN_ROOT_PATH$input_path" 54575 fi 54576 fi 54577 54578 54579 if test "x$path" != "x$new_path"; then 54580 MSVC_DLL="$new_path" 54581 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54582 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54583 fi 54584 54585 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54586 54587 path="$MSVC_DLL" 54588 has_colon=`$ECHO $path | $GREP ^.:` 54589 new_path="$path" 54590 if test "x$has_colon" = x; then 54591 # Not in mixed or Windows style, start by that. 54592 new_path=`cmd //c echo $path` 54593 fi 54594 54595 54596 input_path="$new_path" 54597 # Check if we need to convert this using DOS-style short mode. If the path 54598 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54599 # take no chances and rewrite it. 54600 # Note: m4 eats our [], so we need to use [ and ] instead. 54601 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 54602 if test "x$has_forbidden_chars" != x; then 54603 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54604 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54605 fi 54606 54607 54608 windows_path="$new_path" 54609 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54610 unix_path=`$CYGPATH -u "$windows_path"` 54611 new_path="$unix_path" 54612 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54613 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54614 new_path="$unix_path" 54615 fi 54616 54617 if test "x$path" != "x$new_path"; then 54618 MSVC_DLL="$new_path" 54619 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54620 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54621 fi 54622 54623 # Save the first 10 bytes of this path to the storage, so fixpath can work. 54624 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 54625 54626 else 54627 # We're on a unix platform. Hooray! :) 54628 path="$MSVC_DLL" 54629 has_space=`$ECHO "$path" | $GREP " "` 54630 if test "x$has_space" != x; then 54631 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54632 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54633 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 54634 fi 54635 54636 # Use eval to expand a potential ~ 54637 eval path="$path" 54638 if test ! -f "$path" && test ! -d "$path"; then 54639 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 54640 fi 54641 54642 if test -d "$path"; then 54643 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 54644 else 54645 dir="`$DIRNAME "$path"`" 54646 base="`$BASENAME "$path"`" 54647 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 54648 fi 54649 fi 54650 fi 54651 54652 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 54653 $as_echo_n "checking for $DLL_NAME... " >&6; } 54654 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 54655 $as_echo "$MSVC_DLL" >&6; } 54656 else 54657 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 54658 $as_echo "incorrect, ignoring" >&6; } 54659 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 54660 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 54661 fi 54662 fi 54663 54664 fi 54665 fi 54666 54667 if test "x$MSVC_DLL" = x; then 54668 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 54669 $as_echo_n "checking for $DLL_NAME... " >&6; } 54670 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 54671 $as_echo "no" >&6; } 54672 as_fn_error $? "Could not find $DLL_NAME. Please specify using --with-msvcr-dll." "$LINENO" 5 54673 fi 54674 54675 MSVCR_DLL="$MSVC_DLL" 54676 fi 54677 54678 54679 54680 # Check whether --with-msvcp-dll was given. 54681 if test "${with_msvcp_dll+set}" = set; then : 54682 withval=$with_msvcp_dll; 54683 fi 54684 54685 54686 if test "x$MSVCP_NAME" != "x"; then 54687 if test "x$with_msvcp_dll" != x; then 54688 # If given explicitly by user, do not probe. If not present, fail directly. 54689 54690 DLL_NAME="$MSVCP_NAME" 54691 POSSIBLE_MSVC_DLL="$with_msvcp_dll" 54692 METHOD="--with-msvcp-dll" 54693 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 54694 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 54695 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 54696 54697 # Need to check if the found msvcr is correct architecture 54698 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 54699 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 54700 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 54701 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54702 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 54703 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 54704 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54705 CORRECT_MSVCR_ARCH="PE32 executable" 54706 else 54707 CORRECT_MSVCR_ARCH="PE32+ executable" 54708 fi 54709 else 54710 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54711 CORRECT_MSVCR_ARCH=386 54712 else 54713 CORRECT_MSVCR_ARCH=x86-64 54714 fi 54715 fi 54716 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 54717 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 54718 $as_echo "ok" >&6; } 54719 MSVC_DLL="$POSSIBLE_MSVC_DLL" 54720 54721 # Only process if variable expands to non-empty 54722 54723 if test "x$MSVC_DLL" != x; then 54724 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54725 54726 # Input might be given as Windows format, start by converting to 54727 # unix format. 54728 path="$MSVC_DLL" 54729 new_path=`$CYGPATH -u "$path"` 54730 54731 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 54732 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 54733 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 54734 # "foo.exe" is OK but "foo" is an error. 54735 # 54736 # This test is therefore slightly more accurate than "test -f" to check for file precense. 54737 # It is also a way to make sure we got the proper file name for the real test later on. 54738 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 54739 if test "x$test_shortpath" = x; then 54740 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54741 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54742 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 54743 fi 54744 54745 # Call helper function which possibly converts this using DOS-style short mode. 54746 # If so, the updated path is stored in $new_path. 54747 54748 input_path="$new_path" 54749 # Check if we need to convert this using DOS-style short mode. If the path 54750 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54751 # take no chances and rewrite it. 54752 # Note: m4 eats our [], so we need to use [ and ] instead. 54753 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 54754 if test "x$has_forbidden_chars" != x; then 54755 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54756 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 54757 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 54758 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 54759 # Going to short mode and back again did indeed matter. Since short mode is 54760 # case insensitive, let's make it lowercase to improve readability. 54761 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54762 # Now convert it back to Unix-style (cygpath) 54763 input_path=`$CYGPATH -u "$shortmode_path"` 54764 new_path="$input_path" 54765 fi 54766 fi 54767 54768 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 54769 if test "x$test_cygdrive_prefix" = x; then 54770 # As a simple fix, exclude /usr/bin since it's not a real path. 54771 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 54772 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 54773 # a path prefixed by /cygdrive for fixpath to work. 54774 new_path="$CYGWIN_ROOT_PATH$input_path" 54775 fi 54776 fi 54777 54778 54779 if test "x$path" != "x$new_path"; then 54780 MSVC_DLL="$new_path" 54781 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54782 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54783 fi 54784 54785 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54786 54787 path="$MSVC_DLL" 54788 has_colon=`$ECHO $path | $GREP ^.:` 54789 new_path="$path" 54790 if test "x$has_colon" = x; then 54791 # Not in mixed or Windows style, start by that. 54792 new_path=`cmd //c echo $path` 54793 fi 54794 54795 54796 input_path="$new_path" 54797 # Check if we need to convert this using DOS-style short mode. If the path 54798 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54799 # take no chances and rewrite it. 54800 # Note: m4 eats our [], so we need to use [ and ] instead. 54801 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 54802 if test "x$has_forbidden_chars" != x; then 54803 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54804 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54805 fi 54806 54807 54808 windows_path="$new_path" 54809 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54810 unix_path=`$CYGPATH -u "$windows_path"` 54811 new_path="$unix_path" 54812 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54813 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54814 new_path="$unix_path" 54815 fi 54816 54817 if test "x$path" != "x$new_path"; then 54818 MSVC_DLL="$new_path" 54819 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54820 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54821 fi 54822 54823 # Save the first 10 bytes of this path to the storage, so fixpath can work. 54824 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 54825 54826 else 54827 # We're on a unix platform. Hooray! :) 54828 path="$MSVC_DLL" 54829 has_space=`$ECHO "$path" | $GREP " "` 54830 if test "x$has_space" != x; then 54831 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54832 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54833 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 54834 fi 54835 54836 # Use eval to expand a potential ~ 54837 eval path="$path" 54838 if test ! -f "$path" && test ! -d "$path"; then 54839 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 54840 fi 54841 54842 if test -d "$path"; then 54843 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 54844 else 54845 dir="`$DIRNAME "$path"`" 54846 base="`$BASENAME "$path"`" 54847 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 54848 fi 54849 fi 54850 fi 54851 54852 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 54853 $as_echo_n "checking for $DLL_NAME... " >&6; } 54854 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 54855 $as_echo "$MSVC_DLL" >&6; } 54856 else 54857 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 54858 $as_echo "incorrect, ignoring" >&6; } 54859 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 54860 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 54861 fi 54862 fi 54863 54864 if test "x$MSVC_DLL" = x; then 54865 as_fn_error $? "Could not find a proper $MSVCP_NAME as specified by --with-msvcp-dll" "$LINENO" 5 54866 fi 54867 MSVCP_DLL="$MSVC_DLL" 54868 elif test "x$DEVKIT_MSVCP_DLL" != x; then 54869 54870 DLL_NAME="$MSVCP_NAME" 54871 POSSIBLE_MSVC_DLL="$DEVKIT_MSVCP_DLL" 54872 METHOD="devkit" 54873 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 54874 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 54875 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 54876 54877 # Need to check if the found msvcr is correct architecture 54878 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 54879 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 54880 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 54881 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54882 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 54883 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 54884 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54885 CORRECT_MSVCR_ARCH="PE32 executable" 54886 else 54887 CORRECT_MSVCR_ARCH="PE32+ executable" 54888 fi 54889 else 54890 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54891 CORRECT_MSVCR_ARCH=386 54892 else 54893 CORRECT_MSVCR_ARCH=x86-64 54894 fi 54895 fi 54896 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 54897 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 54898 $as_echo "ok" >&6; } 54899 MSVC_DLL="$POSSIBLE_MSVC_DLL" 54900 54901 # Only process if variable expands to non-empty 54902 54903 if test "x$MSVC_DLL" != x; then 54904 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54905 54906 # Input might be given as Windows format, start by converting to 54907 # unix format. 54908 path="$MSVC_DLL" 54909 new_path=`$CYGPATH -u "$path"` 54910 54911 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 54912 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 54913 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 54914 # "foo.exe" is OK but "foo" is an error. 54915 # 54916 # This test is therefore slightly more accurate than "test -f" to check for file precense. 54917 # It is also a way to make sure we got the proper file name for the real test later on. 54918 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 54919 if test "x$test_shortpath" = x; then 54920 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54921 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54922 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 54923 fi 54924 54925 # Call helper function which possibly converts this using DOS-style short mode. 54926 # If so, the updated path is stored in $new_path. 54927 54928 input_path="$new_path" 54929 # Check if we need to convert this using DOS-style short mode. If the path 54930 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54931 # take no chances and rewrite it. 54932 # Note: m4 eats our [], so we need to use [ and ] instead. 54933 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 54934 if test "x$has_forbidden_chars" != x; then 54935 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54936 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 54937 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 54938 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 54939 # Going to short mode and back again did indeed matter. Since short mode is 54940 # case insensitive, let's make it lowercase to improve readability. 54941 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54942 # Now convert it back to Unix-style (cygpath) 54943 input_path=`$CYGPATH -u "$shortmode_path"` 54944 new_path="$input_path" 54945 fi 54946 fi 54947 54948 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 54949 if test "x$test_cygdrive_prefix" = x; then 54950 # As a simple fix, exclude /usr/bin since it's not a real path. 54951 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 54952 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 54953 # a path prefixed by /cygdrive for fixpath to work. 54954 new_path="$CYGWIN_ROOT_PATH$input_path" 54955 fi 54956 fi 54957 54958 54959 if test "x$path" != "x$new_path"; then 54960 MSVC_DLL="$new_path" 54961 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54962 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54963 fi 54964 54965 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54966 54967 path="$MSVC_DLL" 54968 has_colon=`$ECHO $path | $GREP ^.:` 54969 new_path="$path" 54970 if test "x$has_colon" = x; then 54971 # Not in mixed or Windows style, start by that. 54972 new_path=`cmd //c echo $path` 54973 fi 54974 54975 54976 input_path="$new_path" 54977 # Check if we need to convert this using DOS-style short mode. If the path 54978 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54979 # take no chances and rewrite it. 54980 # Note: m4 eats our [], so we need to use [ and ] instead. 54981 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 54982 if test "x$has_forbidden_chars" != x; then 54983 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54984 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54985 fi 54986 54987 54988 windows_path="$new_path" 54989 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54990 unix_path=`$CYGPATH -u "$windows_path"` 54991 new_path="$unix_path" 54992 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54993 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54994 new_path="$unix_path" 54995 fi 54996 54997 if test "x$path" != "x$new_path"; then 54998 MSVC_DLL="$new_path" 54999 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55000 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55001 fi 55002 55003 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55004 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55005 55006 else 55007 # We're on a unix platform. Hooray! :) 55008 path="$MSVC_DLL" 55009 has_space=`$ECHO "$path" | $GREP " "` 55010 if test "x$has_space" != x; then 55011 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55012 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55013 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55014 fi 55015 55016 # Use eval to expand a potential ~ 55017 eval path="$path" 55018 if test ! -f "$path" && test ! -d "$path"; then 55019 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 55020 fi 55021 55022 if test -d "$path"; then 55023 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 55024 else 55025 dir="`$DIRNAME "$path"`" 55026 base="`$BASENAME "$path"`" 55027 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 55028 fi 55029 fi 55030 fi 55031 55032 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55033 $as_echo_n "checking for $DLL_NAME... " >&6; } 55034 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 55035 $as_echo "$MSVC_DLL" >&6; } 55036 else 55037 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 55038 $as_echo "incorrect, ignoring" >&6; } 55039 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 55040 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 55041 fi 55042 fi 55043 55044 if test "x$MSVC_DLL" = x; then 55045 as_fn_error $? "Could not find a proper $MSVCP_NAME as specified by devkit" "$LINENO" 5 55046 fi 55047 MSVCP_DLL="$MSVC_DLL" 55048 else 55049 55050 DLL_NAME="${MSVCP_NAME}" 55051 MSVC_DLL= 55052 55053 if test "x$MSVC_DLL" = x; then 55054 # Probe: Using well-known location from Visual Studio 10.0 55055 if test "x$VCINSTALLDIR" != x; then 55056 CYGWIN_VC_INSTALL_DIR="$VCINSTALLDIR" 55057 55058 windows_path="$CYGWIN_VC_INSTALL_DIR" 55059 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55060 unix_path=`$CYGPATH -u "$windows_path"` 55061 CYGWIN_VC_INSTALL_DIR="$unix_path" 55062 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55063 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55064 CYGWIN_VC_INSTALL_DIR="$unix_path" 55065 fi 55066 55067 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 55068 POSSIBLE_MSVC_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x64/Microsoft.VC${VS_VERSION_INTERNAL}.CRT/$DLL_NAME" 55069 else 55070 POSSIBLE_MSVC_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x86/Microsoft.VC${VS_VERSION_INTERNAL}.CRT/$DLL_NAME" 55071 fi 55072 $ECHO "POSSIBLE_MSVC_DLL $POSSIBLEMSVC_DLL" 55073 55074 DLL_NAME="$DLL_NAME" 55075 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 55076 METHOD="well-known location in VCINSTALLDIR" 55077 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 55078 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 55079 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 55080 55081 # Need to check if the found msvcr is correct architecture 55082 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 55083 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 55084 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 55085 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55086 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 55087 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 55088 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55089 CORRECT_MSVCR_ARCH="PE32 executable" 55090 else 55091 CORRECT_MSVCR_ARCH="PE32+ executable" 55092 fi 55093 else 55094 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55095 CORRECT_MSVCR_ARCH=386 55096 else 55097 CORRECT_MSVCR_ARCH=x86-64 55098 fi 55099 fi 55100 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 55101 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 55102 $as_echo "ok" >&6; } 55103 MSVC_DLL="$POSSIBLE_MSVC_DLL" 55104 55105 # Only process if variable expands to non-empty 55106 55107 if test "x$MSVC_DLL" != x; then 55108 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55109 55110 # Input might be given as Windows format, start by converting to 55111 # unix format. 55112 path="$MSVC_DLL" 55113 new_path=`$CYGPATH -u "$path"` 55114 55115 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55116 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55117 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55118 # "foo.exe" is OK but "foo" is an error. 55119 # 55120 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55121 # It is also a way to make sure we got the proper file name for the real test later on. 55122 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55123 if test "x$test_shortpath" = x; then 55124 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55125 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55126 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 55127 fi 55128 55129 # Call helper function which possibly converts this using DOS-style short mode. 55130 # If so, the updated path is stored in $new_path. 55131 55132 input_path="$new_path" 55133 # Check if we need to convert this using DOS-style short mode. If the path 55134 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55135 # take no chances and rewrite it. 55136 # Note: m4 eats our [], so we need to use [ and ] instead. 55137 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55138 if test "x$has_forbidden_chars" != x; then 55139 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55140 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55141 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55142 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55143 # Going to short mode and back again did indeed matter. Since short mode is 55144 # case insensitive, let's make it lowercase to improve readability. 55145 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55146 # Now convert it back to Unix-style (cygpath) 55147 input_path=`$CYGPATH -u "$shortmode_path"` 55148 new_path="$input_path" 55149 fi 55150 fi 55151 55152 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55153 if test "x$test_cygdrive_prefix" = x; then 55154 # As a simple fix, exclude /usr/bin since it's not a real path. 55155 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55156 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55157 # a path prefixed by /cygdrive for fixpath to work. 55158 new_path="$CYGWIN_ROOT_PATH$input_path" 55159 fi 55160 fi 55161 55162 55163 if test "x$path" != "x$new_path"; then 55164 MSVC_DLL="$new_path" 55165 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55166 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55167 fi 55168 55169 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55170 55171 path="$MSVC_DLL" 55172 has_colon=`$ECHO $path | $GREP ^.:` 55173 new_path="$path" 55174 if test "x$has_colon" = x; then 55175 # Not in mixed or Windows style, start by that. 55176 new_path=`cmd //c echo $path` 55177 fi 55178 55179 55180 input_path="$new_path" 55181 # Check if we need to convert this using DOS-style short mode. If the path 55182 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55183 # take no chances and rewrite it. 55184 # Note: m4 eats our [], so we need to use [ and ] instead. 55185 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55186 if test "x$has_forbidden_chars" != x; then 55187 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55188 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55189 fi 55190 55191 55192 windows_path="$new_path" 55193 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55194 unix_path=`$CYGPATH -u "$windows_path"` 55195 new_path="$unix_path" 55196 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55197 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55198 new_path="$unix_path" 55199 fi 55200 55201 if test "x$path" != "x$new_path"; then 55202 MSVC_DLL="$new_path" 55203 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55204 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55205 fi 55206 55207 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55208 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55209 55210 else 55211 # We're on a unix platform. Hooray! :) 55212 path="$MSVC_DLL" 55213 has_space=`$ECHO "$path" | $GREP " "` 55214 if test "x$has_space" != x; then 55215 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55216 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55217 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55218 fi 55219 55220 # Use eval to expand a potential ~ 55221 eval path="$path" 55222 if test ! -f "$path" && test ! -d "$path"; then 55223 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 55224 fi 55225 55226 if test -d "$path"; then 55227 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 55228 else 55229 dir="`$DIRNAME "$path"`" 55230 base="`$BASENAME "$path"`" 55231 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 55232 fi 55233 fi 55234 fi 55235 55236 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55237 $as_echo_n "checking for $DLL_NAME... " >&6; } 55238 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 55239 $as_echo "$MSVC_DLL" >&6; } 55240 else 55241 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 55242 $as_echo "incorrect, ignoring" >&6; } 55243 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 55244 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 55245 fi 55246 fi 55247 55248 fi 55249 fi 55250 55251 if test "x$MSVC_DLL" = x; then 55252 # Probe: Check in the Boot JDK directory. 55253 POSSIBLE_MSVC_DLL="$BOOT_JDK/bin/$DLL_NAME" 55254 55255 DLL_NAME="$DLL_NAME" 55256 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 55257 METHOD="well-known location in Boot JDK" 55258 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 55259 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 55260 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 55261 55262 # Need to check if the found msvcr is correct architecture 55263 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 55264 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 55265 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 55266 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55267 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 55268 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 55269 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55270 CORRECT_MSVCR_ARCH="PE32 executable" 55271 else 55272 CORRECT_MSVCR_ARCH="PE32+ executable" 55273 fi 55274 else 55275 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55276 CORRECT_MSVCR_ARCH=386 55277 else 55278 CORRECT_MSVCR_ARCH=x86-64 55279 fi 55280 fi 55281 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 55282 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 55283 $as_echo "ok" >&6; } 55284 MSVC_DLL="$POSSIBLE_MSVC_DLL" 55285 55286 # Only process if variable expands to non-empty 55287 55288 if test "x$MSVC_DLL" != x; then 55289 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55290 55291 # Input might be given as Windows format, start by converting to 55292 # unix format. 55293 path="$MSVC_DLL" 55294 new_path=`$CYGPATH -u "$path"` 55295 55296 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55297 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55298 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55299 # "foo.exe" is OK but "foo" is an error. 55300 # 55301 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55302 # It is also a way to make sure we got the proper file name for the real test later on. 55303 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55304 if test "x$test_shortpath" = x; then 55305 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55306 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55307 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 55308 fi 55309 55310 # Call helper function which possibly converts this using DOS-style short mode. 55311 # If so, the updated path is stored in $new_path. 55312 55313 input_path="$new_path" 55314 # Check if we need to convert this using DOS-style short mode. If the path 55315 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55316 # take no chances and rewrite it. 55317 # Note: m4 eats our [], so we need to use [ and ] instead. 55318 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55319 if test "x$has_forbidden_chars" != x; then 55320 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55321 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55322 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55323 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55324 # Going to short mode and back again did indeed matter. Since short mode is 55325 # case insensitive, let's make it lowercase to improve readability. 55326 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55327 # Now convert it back to Unix-style (cygpath) 55328 input_path=`$CYGPATH -u "$shortmode_path"` 55329 new_path="$input_path" 55330 fi 55331 fi 55332 55333 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55334 if test "x$test_cygdrive_prefix" = x; then 55335 # As a simple fix, exclude /usr/bin since it's not a real path. 55336 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55337 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55338 # a path prefixed by /cygdrive for fixpath to work. 55339 new_path="$CYGWIN_ROOT_PATH$input_path" 55340 fi 55341 fi 55342 55343 55344 if test "x$path" != "x$new_path"; then 55345 MSVC_DLL="$new_path" 55346 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55347 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55348 fi 55349 55350 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55351 55352 path="$MSVC_DLL" 55353 has_colon=`$ECHO $path | $GREP ^.:` 55354 new_path="$path" 55355 if test "x$has_colon" = x; then 55356 # Not in mixed or Windows style, start by that. 55357 new_path=`cmd //c echo $path` 55358 fi 55359 55360 55361 input_path="$new_path" 55362 # Check if we need to convert this using DOS-style short mode. If the path 55363 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55364 # take no chances and rewrite it. 55365 # Note: m4 eats our [], so we need to use [ and ] instead. 55366 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55367 if test "x$has_forbidden_chars" != x; then 55368 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55369 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55370 fi 55371 55372 55373 windows_path="$new_path" 55374 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55375 unix_path=`$CYGPATH -u "$windows_path"` 55376 new_path="$unix_path" 55377 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55378 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55379 new_path="$unix_path" 55380 fi 55381 55382 if test "x$path" != "x$new_path"; then 55383 MSVC_DLL="$new_path" 55384 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55385 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55386 fi 55387 55388 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55389 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55390 55391 else 55392 # We're on a unix platform. Hooray! :) 55393 path="$MSVC_DLL" 55394 has_space=`$ECHO "$path" | $GREP " "` 55395 if test "x$has_space" != x; then 55396 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55397 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55398 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55399 fi 55400 55401 # Use eval to expand a potential ~ 55402 eval path="$path" 55403 if test ! -f "$path" && test ! -d "$path"; then 55404 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 55405 fi 55406 55407 if test -d "$path"; then 55408 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 55409 else 55410 dir="`$DIRNAME "$path"`" 55411 base="`$BASENAME "$path"`" 55412 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 55413 fi 55414 fi 55415 fi 55416 55417 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55418 $as_echo_n "checking for $DLL_NAME... " >&6; } 55419 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 55420 $as_echo "$MSVC_DLL" >&6; } 55421 else 55422 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 55423 $as_echo "incorrect, ignoring" >&6; } 55424 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 55425 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 55426 fi 55427 fi 55428 55429 fi 55430 55431 if test "x$MSVC_DLL" = x; then 55432 # Probe: Look in the Windows system32 directory 55433 CYGWIN_SYSTEMROOT="$SYSTEMROOT" 55434 55435 windows_path="$CYGWIN_SYSTEMROOT" 55436 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55437 unix_path=`$CYGPATH -u "$windows_path"` 55438 CYGWIN_SYSTEMROOT="$unix_path" 55439 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55440 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55441 CYGWIN_SYSTEMROOT="$unix_path" 55442 fi 55443 55444 POSSIBLE_MSVC_DLL="$CYGWIN_SYSTEMROOT/system32/$DLL_NAME" 55445 55446 DLL_NAME="$DLL_NAME" 55447 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 55448 METHOD="well-known location in SYSTEMROOT" 55449 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 55450 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 55451 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 55452 55453 # Need to check if the found msvcr is correct architecture 55454 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 55455 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 55456 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 55457 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55458 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 55459 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 55460 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55461 CORRECT_MSVCR_ARCH="PE32 executable" 55462 else 55463 CORRECT_MSVCR_ARCH="PE32+ executable" 55464 fi 55465 else 55466 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55467 CORRECT_MSVCR_ARCH=386 55468 else 55469 CORRECT_MSVCR_ARCH=x86-64 55470 fi 55471 fi 55472 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 55473 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 55474 $as_echo "ok" >&6; } 55475 MSVC_DLL="$POSSIBLE_MSVC_DLL" 55476 55477 # Only process if variable expands to non-empty 55478 55479 if test "x$MSVC_DLL" != x; then 55480 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55481 55482 # Input might be given as Windows format, start by converting to 55483 # unix format. 55484 path="$MSVC_DLL" 55485 new_path=`$CYGPATH -u "$path"` 55486 55487 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55488 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55489 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55490 # "foo.exe" is OK but "foo" is an error. 55491 # 55492 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55493 # It is also a way to make sure we got the proper file name for the real test later on. 55494 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55495 if test "x$test_shortpath" = x; then 55496 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55497 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55498 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 55499 fi 55500 55501 # Call helper function which possibly converts this using DOS-style short mode. 55502 # If so, the updated path is stored in $new_path. 55503 55504 input_path="$new_path" 55505 # Check if we need to convert this using DOS-style short mode. If the path 55506 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55507 # take no chances and rewrite it. 55508 # Note: m4 eats our [], so we need to use [ and ] instead. 55509 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55510 if test "x$has_forbidden_chars" != x; then 55511 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55512 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55513 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55514 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55515 # Going to short mode and back again did indeed matter. Since short mode is 55516 # case insensitive, let's make it lowercase to improve readability. 55517 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55518 # Now convert it back to Unix-style (cygpath) 55519 input_path=`$CYGPATH -u "$shortmode_path"` 55520 new_path="$input_path" 55521 fi 55522 fi 55523 55524 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55525 if test "x$test_cygdrive_prefix" = x; then 55526 # As a simple fix, exclude /usr/bin since it's not a real path. 55527 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55528 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55529 # a path prefixed by /cygdrive for fixpath to work. 55530 new_path="$CYGWIN_ROOT_PATH$input_path" 55531 fi 55532 fi 55533 55534 55535 if test "x$path" != "x$new_path"; then 55536 MSVC_DLL="$new_path" 55537 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55538 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55539 fi 55540 55541 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55542 55543 path="$MSVC_DLL" 55544 has_colon=`$ECHO $path | $GREP ^.:` 55545 new_path="$path" 55546 if test "x$has_colon" = x; then 55547 # Not in mixed or Windows style, start by that. 55548 new_path=`cmd //c echo $path` 55549 fi 55550 55551 55552 input_path="$new_path" 55553 # Check if we need to convert this using DOS-style short mode. If the path 55554 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55555 # take no chances and rewrite it. 55556 # Note: m4 eats our [], so we need to use [ and ] instead. 55557 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55558 if test "x$has_forbidden_chars" != x; then 55559 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55560 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55561 fi 55562 55563 55564 windows_path="$new_path" 55565 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55566 unix_path=`$CYGPATH -u "$windows_path"` 55567 new_path="$unix_path" 55568 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55569 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55570 new_path="$unix_path" 55571 fi 55572 55573 if test "x$path" != "x$new_path"; then 55574 MSVC_DLL="$new_path" 55575 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55576 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55577 fi 55578 55579 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55580 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55581 55582 else 55583 # We're on a unix platform. Hooray! :) 55584 path="$MSVC_DLL" 55585 has_space=`$ECHO "$path" | $GREP " "` 55586 if test "x$has_space" != x; then 55587 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55588 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55589 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55590 fi 55591 55592 # Use eval to expand a potential ~ 55593 eval path="$path" 55594 if test ! -f "$path" && test ! -d "$path"; then 55595 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 55596 fi 55597 55598 if test -d "$path"; then 55599 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 55600 else 55601 dir="`$DIRNAME "$path"`" 55602 base="`$BASENAME "$path"`" 55603 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 55604 fi 55605 fi 55606 fi 55607 55608 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55609 $as_echo_n "checking for $DLL_NAME... " >&6; } 55610 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 55611 $as_echo "$MSVC_DLL" >&6; } 55612 else 55613 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 55614 $as_echo "incorrect, ignoring" >&6; } 55615 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 55616 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 55617 fi 55618 fi 55619 55620 fi 55621 55622 if test "x$MSVC_DLL" = x; then 55623 # Probe: If Visual Studio Express is installed, there is usually one with the debugger 55624 if test "x$VS100COMNTOOLS" != x; then 55625 CYGWIN_VS_TOOLS_DIR="$VS100COMNTOOLS/.." 55626 55627 windows_path="$CYGWIN_VS_TOOLS_DIR" 55628 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55629 unix_path=`$CYGPATH -u "$windows_path"` 55630 CYGWIN_VS_TOOLS_DIR="$unix_path" 55631 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55632 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55633 CYGWIN_VS_TOOLS_DIR="$unix_path" 55634 fi 55635 55636 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 55637 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name $DLL_NAME \ 55638 | $GREP -i /x64/ | $HEAD --lines 1` 55639 else 55640 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name $DLL_NAME \ 55641 | $GREP -i /x86/ | $HEAD --lines 1` 55642 fi 55643 55644 DLL_NAME="$DLL_NAME" 55645 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 55646 METHOD="search of VS100COMNTOOLS" 55647 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 55648 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 55649 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 55650 55651 # Need to check if the found msvcr is correct architecture 55652 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 55653 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 55654 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 55655 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55656 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 55657 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 55658 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55659 CORRECT_MSVCR_ARCH="PE32 executable" 55660 else 55661 CORRECT_MSVCR_ARCH="PE32+ executable" 55662 fi 55663 else 55664 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55665 CORRECT_MSVCR_ARCH=386 55666 else 55667 CORRECT_MSVCR_ARCH=x86-64 55668 fi 55669 fi 55670 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 55671 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 55672 $as_echo "ok" >&6; } 55673 MSVC_DLL="$POSSIBLE_MSVC_DLL" 55674 55675 # Only process if variable expands to non-empty 55676 55677 if test "x$MSVC_DLL" != x; then 55678 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55679 55680 # Input might be given as Windows format, start by converting to 55681 # unix format. 55682 path="$MSVC_DLL" 55683 new_path=`$CYGPATH -u "$path"` 55684 55685 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55686 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55687 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55688 # "foo.exe" is OK but "foo" is an error. 55689 # 55690 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55691 # It is also a way to make sure we got the proper file name for the real test later on. 55692 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55693 if test "x$test_shortpath" = x; then 55694 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55695 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55696 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 55697 fi 55698 55699 # Call helper function which possibly converts this using DOS-style short mode. 55700 # If so, the updated path is stored in $new_path. 55701 55702 input_path="$new_path" 55703 # Check if we need to convert this using DOS-style short mode. If the path 55704 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55705 # take no chances and rewrite it. 55706 # Note: m4 eats our [], so we need to use [ and ] instead. 55707 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55708 if test "x$has_forbidden_chars" != x; then 55709 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55710 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55711 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55712 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55713 # Going to short mode and back again did indeed matter. Since short mode is 55714 # case insensitive, let's make it lowercase to improve readability. 55715 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55716 # Now convert it back to Unix-style (cygpath) 55717 input_path=`$CYGPATH -u "$shortmode_path"` 55718 new_path="$input_path" 55719 fi 55720 fi 55721 55722 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55723 if test "x$test_cygdrive_prefix" = x; then 55724 # As a simple fix, exclude /usr/bin since it's not a real path. 55725 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55726 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55727 # a path prefixed by /cygdrive for fixpath to work. 55728 new_path="$CYGWIN_ROOT_PATH$input_path" 55729 fi 55730 fi 55731 55732 55733 if test "x$path" != "x$new_path"; then 55734 MSVC_DLL="$new_path" 55735 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55736 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55737 fi 55738 55739 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55740 55741 path="$MSVC_DLL" 55742 has_colon=`$ECHO $path | $GREP ^.:` 55743 new_path="$path" 55744 if test "x$has_colon" = x; then 55745 # Not in mixed or Windows style, start by that. 55746 new_path=`cmd //c echo $path` 55747 fi 55748 55749 55750 input_path="$new_path" 55751 # Check if we need to convert this using DOS-style short mode. If the path 55752 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55753 # take no chances and rewrite it. 55754 # Note: m4 eats our [], so we need to use [ and ] instead. 55755 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55756 if test "x$has_forbidden_chars" != x; then 55757 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55758 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55759 fi 55760 55761 55762 windows_path="$new_path" 55763 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55764 unix_path=`$CYGPATH -u "$windows_path"` 55765 new_path="$unix_path" 55766 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55767 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55768 new_path="$unix_path" 55769 fi 55770 55771 if test "x$path" != "x$new_path"; then 55772 MSVC_DLL="$new_path" 55773 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55774 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55775 fi 55776 55777 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55778 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55779 55780 else 55781 # We're on a unix platform. Hooray! :) 55782 path="$MSVC_DLL" 55783 has_space=`$ECHO "$path" | $GREP " "` 55784 if test "x$has_space" != x; then 55785 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55786 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55787 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55788 fi 55789 55790 # Use eval to expand a potential ~ 55791 eval path="$path" 55792 if test ! -f "$path" && test ! -d "$path"; then 55793 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 55794 fi 55795 55796 if test -d "$path"; then 55797 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 55798 else 55799 dir="`$DIRNAME "$path"`" 55800 base="`$BASENAME "$path"`" 55801 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 55802 fi 55803 fi 55804 fi 55805 55806 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55807 $as_echo_n "checking for $DLL_NAME... " >&6; } 55808 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 55809 $as_echo "$MSVC_DLL" >&6; } 55810 else 55811 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 55812 $as_echo "incorrect, ignoring" >&6; } 55813 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 55814 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 55815 fi 55816 fi 55817 55818 fi 55819 fi 55820 55821 if test "x$MSVC_DLL" = x; then 55822 # Probe: Search wildly in the VCINSTALLDIR. We've probably lost by now. 55823 # (This was the original behaviour; kept since it might turn something up) 55824 if test "x$CYGWIN_VC_INSTALL_DIR" != x; then 55825 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 55826 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 55827 | $GREP x64 | $HEAD --lines 1` 55828 else 55829 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 55830 | $GREP x86 | $GREP -v ia64 | $GREP -v x64 | $HEAD --lines 1` 55831 if test "x$POSSIBLE_MSVC_DLL" = x; then 55832 # We're grasping at straws now... 55833 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 55834 | $HEAD --lines 1` 55835 fi 55836 fi 55837 55838 55839 DLL_NAME="$DLL_NAME" 55840 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 55841 METHOD="search of VCINSTALLDIR" 55842 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 55843 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 55844 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 55845 55846 # Need to check if the found msvcr is correct architecture 55847 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 55848 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 55849 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 55850 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55851 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 55852 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 55853 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55854 CORRECT_MSVCR_ARCH="PE32 executable" 55855 else 55856 CORRECT_MSVCR_ARCH="PE32+ executable" 55857 fi 55858 else 55859 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55860 CORRECT_MSVCR_ARCH=386 55861 else 55862 CORRECT_MSVCR_ARCH=x86-64 55863 fi 55864 fi 55865 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 55866 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 55867 $as_echo "ok" >&6; } 55868 MSVC_DLL="$POSSIBLE_MSVC_DLL" 55869 55870 # Only process if variable expands to non-empty 55871 55872 if test "x$MSVC_DLL" != x; then 55873 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55874 55875 # Input might be given as Windows format, start by converting to 55876 # unix format. 55877 path="$MSVC_DLL" 55878 new_path=`$CYGPATH -u "$path"` 55879 55880 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55881 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55882 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55883 # "foo.exe" is OK but "foo" is an error. 55884 # 55885 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55886 # It is also a way to make sure we got the proper file name for the real test later on. 55887 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55888 if test "x$test_shortpath" = x; then 55889 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55890 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55891 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 55892 fi 55893 55894 # Call helper function which possibly converts this using DOS-style short mode. 55895 # If so, the updated path is stored in $new_path. 55896 55897 input_path="$new_path" 55898 # Check if we need to convert this using DOS-style short mode. If the path 55899 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55900 # take no chances and rewrite it. 55901 # Note: m4 eats our [], so we need to use [ and ] instead. 55902 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55903 if test "x$has_forbidden_chars" != x; then 55904 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55905 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55906 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55907 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55908 # Going to short mode and back again did indeed matter. Since short mode is 55909 # case insensitive, let's make it lowercase to improve readability. 55910 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55911 # Now convert it back to Unix-style (cygpath) 55912 input_path=`$CYGPATH -u "$shortmode_path"` 55913 new_path="$input_path" 55914 fi 55915 fi 55916 55917 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55918 if test "x$test_cygdrive_prefix" = x; then 55919 # As a simple fix, exclude /usr/bin since it's not a real path. 55920 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55921 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55922 # a path prefixed by /cygdrive for fixpath to work. 55923 new_path="$CYGWIN_ROOT_PATH$input_path" 55924 fi 55925 fi 55926 55927 55928 if test "x$path" != "x$new_path"; then 55929 MSVC_DLL="$new_path" 55930 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55931 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55932 fi 55933 55934 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55935 55936 path="$MSVC_DLL" 55937 has_colon=`$ECHO $path | $GREP ^.:` 55938 new_path="$path" 55939 if test "x$has_colon" = x; then 55940 # Not in mixed or Windows style, start by that. 55941 new_path=`cmd //c echo $path` 55942 fi 55943 55944 55945 input_path="$new_path" 55946 # Check if we need to convert this using DOS-style short mode. If the path 55947 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55948 # take no chances and rewrite it. 55949 # Note: m4 eats our [], so we need to use [ and ] instead. 55950 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55951 if test "x$has_forbidden_chars" != x; then 55952 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55953 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55954 fi 55955 55956 55957 windows_path="$new_path" 55958 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55959 unix_path=`$CYGPATH -u "$windows_path"` 55960 new_path="$unix_path" 55961 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55962 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55963 new_path="$unix_path" 55964 fi 55965 55966 if test "x$path" != "x$new_path"; then 55967 MSVC_DLL="$new_path" 55968 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55969 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55970 fi 55971 55972 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55973 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55974 55975 else 55976 # We're on a unix platform. Hooray! :) 55977 path="$MSVC_DLL" 55978 has_space=`$ECHO "$path" | $GREP " "` 55979 if test "x$has_space" != x; then 55980 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55981 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55982 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55983 fi 55984 55985 # Use eval to expand a potential ~ 55986 eval path="$path" 55987 if test ! -f "$path" && test ! -d "$path"; then 55988 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 55989 fi 55990 55991 if test -d "$path"; then 55992 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 55993 else 55994 dir="`$DIRNAME "$path"`" 55995 base="`$BASENAME "$path"`" 55996 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 55997 fi 55998 fi 55999 fi 56000 56001 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 56002 $as_echo_n "checking for $DLL_NAME... " >&6; } 56003 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 56004 $as_echo "$MSVC_DLL" >&6; } 56005 else 56006 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 56007 $as_echo "incorrect, ignoring" >&6; } 56008 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 56009 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 56010 fi 56011 fi 56012 56013 fi 56014 fi 56015 56016 if test "x$MSVC_DLL" = x; then 56017 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 56018 $as_echo_n "checking for $DLL_NAME... " >&6; } 56019 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 56020 $as_echo "no" >&6; } 56021 as_fn_error $? "Could not find $DLL_NAME. Please specify using --with-msvcr-dll." "$LINENO" 5 56022 fi 56023 56024 MSVCP_DLL="$MSVC_DLL" 56025 fi 56026 56027 fi 56028 56029 fi 56030 56031 56032 if test "x$NEEDS_LIB_X11" = xfalse; then 56033 if (test "x${with_x}" != x && test "x${with_x}" != xno); then 56034 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: X11 is not used, so --with-x is ignored" >&5 56035 $as_echo "$as_me: WARNING: X11 is not used, so --with-x is ignored" >&2;} 56036 fi 56037 X_CFLAGS= 56038 X_LIBS= 56039 else 56040 56041 if test "x${with_x}" = xno; then 56042 as_fn_error $? "It is not possible to disable the use of X11. Remove the --without-x option." "$LINENO" 5 56043 fi 56044 56045 if test "x${with_x}" != x && test "x${with_x}" != xyes; then 56046 # The user has specified a X11 base directory. Use it for includes and 56047 # libraries, unless explicitly overridden. 56048 if test "x$x_includes" = xNONE; then 56049 x_includes="${with_x}/include" 56050 fi 56051 if test "x$x_libraries" = xNONE; then 56052 x_libraries="${with_x}/lib" 56053 fi 56054 else 56055 # Check if the user has specified sysroot, but not --with-x, --x-includes or --x-libraries. 56056 # Make a simple check for the libraries at the sysroot, and setup --x-includes and 56057 # --x-libraries for the sysroot, if that seems to be correct. 56058 if test "x$SYSROOT" != "x"; then 56059 if test "x$x_includes" = xNONE; then 56060 if test -f "$SYSROOT/usr/X11R6/include/X11/Xlib.h"; then 56061 x_includes="$SYSROOT/usr/X11R6/include" 56062 elif test -f "$SYSROOT/usr/include/X11/Xlib.h"; then 56063 x_includes="$SYSROOT/usr/include" 56064 fi 56065 fi 56066 if test "x$x_libraries" = xNONE; then 56067 if test -f "$SYSROOT/usr/X11R6/lib/libX11.so"; then 56068 x_libraries="$SYSROOT/usr/X11R6/lib" 56069 elif test -f "$SYSROOT/usr/lib64/libX11.so" && test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 56070 x_libraries="$SYSROOT/usr/lib64" 56071 elif test -f "$SYSROOT/usr/lib/libX11.so"; then 56072 x_libraries="$SYSROOT/usr/lib" 56073 fi 56074 fi 56075 fi 56076 fi 56077 56078 # Now let autoconf do it's magic 56079 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5 56080 $as_echo_n "checking for X... " >&6; } 56081 56082 56083 # Check whether --with-x was given. 56084 if test "${with_x+set}" = set; then : 56085 withval=$with_x; 56086 fi 56087 56088 # $have_x is `yes', `no', `disabled', or empty when we do not yet know. 56089 if test "x$with_x" = xno; then 56090 # The user explicitly disabled X. 56091 have_x=disabled 56092 else 56093 case $x_includes,$x_libraries in #( 56094 *\'*) as_fn_error $? "cannot use X directory names containing '" "$LINENO" 5;; #( 56095 *,NONE | NONE,*) if ${ac_cv_have_x+:} false; then : 56096 $as_echo_n "(cached) " >&6 56097 else 56098 # One or both of the vars are not set, and there is no cached value. 56099 ac_x_includes=no ac_x_libraries=no 56100 rm -f -r conftest.dir 56101 if mkdir conftest.dir; then 56102 cd conftest.dir 56103 cat >Imakefile <<'_ACEOF' 56104 incroot: 56105 @echo incroot='${INCROOT}' 56106 usrlibdir: 56107 @echo usrlibdir='${USRLIBDIR}' 56108 libdir: 56109 @echo libdir='${LIBDIR}' 56110 _ACEOF 56111 if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then 56112 # GNU make sometimes prints "make[1]: Entering ...", which would confuse us. 56113 for ac_var in incroot usrlibdir libdir; do 56114 eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`" 56115 done 56116 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR. 56117 for ac_extension in a so sl dylib la dll; do 56118 if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" && 56119 test -f "$ac_im_libdir/libX11.$ac_extension"; then 56120 ac_im_usrlibdir=$ac_im_libdir; break 56121 fi 56122 done 56123 # Screen out bogus values from the imake configuration. They are 56124 # bogus both because they are the default anyway, and because 56125 # using them would break gcc on systems where it needs fixed includes. 56126 case $ac_im_incroot in 56127 /usr/include) ac_x_includes= ;; 56128 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;; 56129 esac 56130 case $ac_im_usrlibdir in 56131 /usr/lib | /usr/lib64 | /lib | /lib64) ;; 56132 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;; 56133 esac 56134 fi 56135 cd .. 56136 rm -f -r conftest.dir 56137 fi 56138 56139 # Standard set of common directories for X headers. 56140 # Check X11 before X11Rn because it is often a symlink to the current release. 56141 ac_x_header_dirs=' 56142 /usr/X11/include 56143 /usr/X11R7/include 56144 /usr/X11R6/include 56145 /usr/X11R5/include 56146 /usr/X11R4/include 56147 56148 /usr/include/X11 56149 /usr/include/X11R7 56150 /usr/include/X11R6 56151 /usr/include/X11R5 56152 /usr/include/X11R4 56153 56154 /usr/local/X11/include 56155 /usr/local/X11R7/include 56156 /usr/local/X11R6/include 56157 /usr/local/X11R5/include 56158 /usr/local/X11R4/include 56159 56160 /usr/local/include/X11 56161 /usr/local/include/X11R7 56162 /usr/local/include/X11R6 56163 /usr/local/include/X11R5 56164 /usr/local/include/X11R4 56165 56166 /usr/X386/include 56167 /usr/x386/include 56168 /usr/XFree86/include/X11 56169 56170 /usr/include 56171 /usr/local/include 56172 /usr/unsupported/include 56173 /usr/athena/include 56174 /usr/local/x11r5/include 56175 /usr/lpp/Xamples/include 56176 56177 /usr/openwin/include 56178 /usr/openwin/share/include' 56179 56180 if test "$ac_x_includes" = no; then 56181 # Guess where to find include files, by looking for Xlib.h. 56182 # First, try using that file with no special directory specified. 56183 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56184 /* end confdefs.h. */ 56185 #include <X11/Xlib.h> 56186 _ACEOF 56187 if ac_fn_cxx_try_cpp "$LINENO"; then : 56188 # We can compile using X headers with no special include directory. 56189 ac_x_includes= 56190 else 56191 for ac_dir in $ac_x_header_dirs; do 56192 if test -r "$ac_dir/X11/Xlib.h"; then 56193 ac_x_includes=$ac_dir 56194 break 56195 fi 56196 done 56197 fi 56198 rm -f conftest.err conftest.i conftest.$ac_ext 56199 fi # $ac_x_includes = no 56200 56201 if test "$ac_x_libraries" = no; then 56202 # Check for the libraries. 56203 # See if we find them without any special options. 56204 # Don't add to $LIBS permanently. 56205 ac_save_LIBS=$LIBS 56206 LIBS="-lX11 $LIBS" 56207 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56208 /* end confdefs.h. */ 56209 #include <X11/Xlib.h> 56210 int 56211 main () 56212 { 56213 XrmInitialize () 56214 ; 56215 return 0; 56216 } 56217 _ACEOF 56218 if ac_fn_cxx_try_link "$LINENO"; then : 56219 LIBS=$ac_save_LIBS 56220 # We can link X programs with no special library path. 56221 ac_x_libraries= 56222 else 56223 LIBS=$ac_save_LIBS 56224 for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g` 56225 do 56226 # Don't even attempt the hair of trying to link an X program! 56227 for ac_extension in a so sl dylib la dll; do 56228 if test -r "$ac_dir/libX11.$ac_extension"; then 56229 ac_x_libraries=$ac_dir 56230 break 2 56231 fi 56232 done 56233 done 56234 fi 56235 rm -f core conftest.err conftest.$ac_objext \ 56236 conftest$ac_exeext conftest.$ac_ext 56237 fi # $ac_x_libraries = no 56238 56239 case $ac_x_includes,$ac_x_libraries in #( 56240 no,* | *,no | *\'*) 56241 # Didn't find X, or a directory has "'" in its name. 56242 ac_cv_have_x="have_x=no";; #( 56243 *) 56244 # Record where we found X for the cache. 56245 ac_cv_have_x="have_x=yes\ 56246 ac_x_includes='$ac_x_includes'\ 56247 ac_x_libraries='$ac_x_libraries'" 56248 esac 56249 fi 56250 ;; #( 56251 *) have_x=yes;; 56252 esac 56253 eval "$ac_cv_have_x" 56254 fi # $with_x != no 56255 56256 if test "$have_x" != yes; then 56257 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5 56258 $as_echo "$have_x" >&6; } 56259 no_x=yes 56260 else 56261 # If each of the values was on the command line, it overrides each guess. 56262 test "x$x_includes" = xNONE && x_includes=$ac_x_includes 56263 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries 56264 # Update the cache value to reflect the command line values. 56265 ac_cv_have_x="have_x=yes\ 56266 ac_x_includes='$x_includes'\ 56267 ac_x_libraries='$x_libraries'" 56268 { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5 56269 $as_echo "libraries $x_libraries, headers $x_includes" >&6; } 56270 fi 56271 56272 if test "$no_x" = yes; then 56273 # Not all programs may use this symbol, but it does not hurt to define it. 56274 56275 $as_echo "#define X_DISPLAY_MISSING 1" >>confdefs.h 56276 56277 X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS= 56278 else 56279 if test -n "$x_includes"; then 56280 X_CFLAGS="$X_CFLAGS -I$x_includes" 56281 fi 56282 56283 # It would also be nice to do this for all -L options, not just this one. 56284 if test -n "$x_libraries"; then 56285 X_LIBS="$X_LIBS -L$x_libraries" 56286 # For Solaris; some versions of Sun CC require a space after -R and 56287 # others require no space. Words are not sufficient . . . . 56288 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -R must be followed by a space" >&5 56289 $as_echo_n "checking whether -R must be followed by a space... " >&6; } 56290 ac_xsave_LIBS=$LIBS; LIBS="$LIBS -R$x_libraries" 56291 ac_xsave_cxx_werror_flag=$ac_cxx_werror_flag 56292 ac_cxx_werror_flag=yes 56293 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56294 /* end confdefs.h. */ 56295 56296 int 56297 main () 56298 { 56299 56300 ; 56301 return 0; 56302 } 56303 _ACEOF 56304 if ac_fn_cxx_try_link "$LINENO"; then : 56305 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 56306 $as_echo "no" >&6; } 56307 X_LIBS="$X_LIBS -R$x_libraries" 56308 else 56309 LIBS="$ac_xsave_LIBS -R $x_libraries" 56310 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56311 /* end confdefs.h. */ 56312 56313 int 56314 main () 56315 { 56316 56317 ; 56318 return 0; 56319 } 56320 _ACEOF 56321 if ac_fn_cxx_try_link "$LINENO"; then : 56322 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 56323 $as_echo "yes" >&6; } 56324 X_LIBS="$X_LIBS -R $x_libraries" 56325 else 56326 { $as_echo "$as_me:${as_lineno-$LINENO}: result: neither works" >&5 56327 $as_echo "neither works" >&6; } 56328 fi 56329 rm -f core conftest.err conftest.$ac_objext \ 56330 conftest$ac_exeext conftest.$ac_ext 56331 fi 56332 rm -f core conftest.err conftest.$ac_objext \ 56333 conftest$ac_exeext conftest.$ac_ext 56334 ac_cxx_werror_flag=$ac_xsave_cxx_werror_flag 56335 LIBS=$ac_xsave_LIBS 56336 fi 56337 56338 # Check for system-dependent libraries X programs must link with. 56339 # Do this before checking for the system-independent R6 libraries 56340 # (-lICE), since we may need -lsocket or whatever for X linking. 56341 56342 if test "$ISC" = yes; then 56343 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet" 56344 else 56345 # Martyn Johnson says this is needed for Ultrix, if the X 56346 # libraries were built with DECnet support. And Karl Berry says 56347 # the Alpha needs dnet_stub (dnet does not exist). 56348 ac_xsave_LIBS="$LIBS"; LIBS="$LIBS $X_LIBS -lX11" 56349 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56350 /* end confdefs.h. */ 56351 56352 /* Override any GCC internal prototype to avoid an error. 56353 Use char because int might match the return type of a GCC 56354 builtin and then its argument prototype would still apply. */ 56355 #ifdef __cplusplus 56356 extern "C" 56357 #endif 56358 char XOpenDisplay (); 56359 int 56360 main () 56361 { 56362 return XOpenDisplay (); 56363 ; 56364 return 0; 56365 } 56366 _ACEOF 56367 if ac_fn_cxx_try_link "$LINENO"; then : 56368 56369 else 56370 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet" >&5 56371 $as_echo_n "checking for dnet_ntoa in -ldnet... " >&6; } 56372 if ${ac_cv_lib_dnet_dnet_ntoa+:} false; then : 56373 $as_echo_n "(cached) " >&6 56374 else 56375 ac_check_lib_save_LIBS=$LIBS 56376 LIBS="-ldnet $LIBS" 56377 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56378 /* end confdefs.h. */ 56379 56380 /* Override any GCC internal prototype to avoid an error. 56381 Use char because int might match the return type of a GCC 56382 builtin and then its argument prototype would still apply. */ 56383 #ifdef __cplusplus 56384 extern "C" 56385 #endif 56386 char dnet_ntoa (); 56387 int 56388 main () 56389 { 56390 return dnet_ntoa (); 56391 ; 56392 return 0; 56393 } 56394 _ACEOF 56395 if ac_fn_cxx_try_link "$LINENO"; then : 56396 ac_cv_lib_dnet_dnet_ntoa=yes 56397 else 56398 ac_cv_lib_dnet_dnet_ntoa=no 56399 fi 56400 rm -f core conftest.err conftest.$ac_objext \ 56401 conftest$ac_exeext conftest.$ac_ext 56402 LIBS=$ac_check_lib_save_LIBS 56403 fi 56404 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_dnet_ntoa" >&5 56405 $as_echo "$ac_cv_lib_dnet_dnet_ntoa" >&6; } 56406 if test "x$ac_cv_lib_dnet_dnet_ntoa" = xyes; then : 56407 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet" 56408 fi 56409 56410 if test $ac_cv_lib_dnet_dnet_ntoa = no; then 56411 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet_stub" >&5 56412 $as_echo_n "checking for dnet_ntoa in -ldnet_stub... " >&6; } 56413 if ${ac_cv_lib_dnet_stub_dnet_ntoa+:} false; then : 56414 $as_echo_n "(cached) " >&6 56415 else 56416 ac_check_lib_save_LIBS=$LIBS 56417 LIBS="-ldnet_stub $LIBS" 56418 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56419 /* end confdefs.h. */ 56420 56421 /* Override any GCC internal prototype to avoid an error. 56422 Use char because int might match the return type of a GCC 56423 builtin and then its argument prototype would still apply. */ 56424 #ifdef __cplusplus 56425 extern "C" 56426 #endif 56427 char dnet_ntoa (); 56428 int 56429 main () 56430 { 56431 return dnet_ntoa (); 56432 ; 56433 return 0; 56434 } 56435 _ACEOF 56436 if ac_fn_cxx_try_link "$LINENO"; then : 56437 ac_cv_lib_dnet_stub_dnet_ntoa=yes 56438 else 56439 ac_cv_lib_dnet_stub_dnet_ntoa=no 56440 fi 56441 rm -f core conftest.err conftest.$ac_objext \ 56442 conftest$ac_exeext conftest.$ac_ext 56443 LIBS=$ac_check_lib_save_LIBS 56444 fi 56445 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_stub_dnet_ntoa" >&5 56446 $as_echo "$ac_cv_lib_dnet_stub_dnet_ntoa" >&6; } 56447 if test "x$ac_cv_lib_dnet_stub_dnet_ntoa" = xyes; then : 56448 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub" 56449 fi 56450 56451 fi 56452 fi 56453 rm -f core conftest.err conftest.$ac_objext \ 56454 conftest$ac_exeext conftest.$ac_ext 56455 LIBS="$ac_xsave_LIBS" 56456 56457 # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT, 56458 # to get the SysV transport functions. 56459 # Chad R. Larson says the Pyramis MIS-ES running DC/OSx (SVR4) 56460 # needs -lnsl. 56461 # The nsl library prevents programs from opening the X display 56462 # on Irix 5.2, according to T.E. Dickey. 56463 # The functions gethostbyname, getservbyname, and inet_addr are 56464 # in -lbsd on LynxOS 3.0.1/i386, according to Lars Hecking. 56465 ac_fn_cxx_check_func "$LINENO" "gethostbyname" "ac_cv_func_gethostbyname" 56466 if test "x$ac_cv_func_gethostbyname" = xyes; then : 56467 56468 fi 56469 56470 if test $ac_cv_func_gethostbyname = no; then 56471 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lnsl" >&5 56472 $as_echo_n "checking for gethostbyname in -lnsl... " >&6; } 56473 if ${ac_cv_lib_nsl_gethostbyname+:} false; then : 56474 $as_echo_n "(cached) " >&6 56475 else 56476 ac_check_lib_save_LIBS=$LIBS 56477 LIBS="-lnsl $LIBS" 56478 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56479 /* end confdefs.h. */ 56480 56481 /* Override any GCC internal prototype to avoid an error. 56482 Use char because int might match the return type of a GCC 56483 builtin and then its argument prototype would still apply. */ 56484 #ifdef __cplusplus 56485 extern "C" 56486 #endif 56487 char gethostbyname (); 56488 int 56489 main () 56490 { 56491 return gethostbyname (); 56492 ; 56493 return 0; 56494 } 56495 _ACEOF 56496 if ac_fn_cxx_try_link "$LINENO"; then : 56497 ac_cv_lib_nsl_gethostbyname=yes 56498 else 56499 ac_cv_lib_nsl_gethostbyname=no 56500 fi 56501 rm -f core conftest.err conftest.$ac_objext \ 56502 conftest$ac_exeext conftest.$ac_ext 56503 LIBS=$ac_check_lib_save_LIBS 56504 fi 56505 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_gethostbyname" >&5 56506 $as_echo "$ac_cv_lib_nsl_gethostbyname" >&6; } 56507 if test "x$ac_cv_lib_nsl_gethostbyname" = xyes; then : 56508 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl" 56509 fi 56510 56511 if test $ac_cv_lib_nsl_gethostbyname = no; then 56512 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lbsd" >&5 56513 $as_echo_n "checking for gethostbyname in -lbsd... " >&6; } 56514 if ${ac_cv_lib_bsd_gethostbyname+:} false; then : 56515 $as_echo_n "(cached) " >&6 56516 else 56517 ac_check_lib_save_LIBS=$LIBS 56518 LIBS="-lbsd $LIBS" 56519 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56520 /* end confdefs.h. */ 56521 56522 /* Override any GCC internal prototype to avoid an error. 56523 Use char because int might match the return type of a GCC 56524 builtin and then its argument prototype would still apply. */ 56525 #ifdef __cplusplus 56526 extern "C" 56527 #endif 56528 char gethostbyname (); 56529 int 56530 main () 56531 { 56532 return gethostbyname (); 56533 ; 56534 return 0; 56535 } 56536 _ACEOF 56537 if ac_fn_cxx_try_link "$LINENO"; then : 56538 ac_cv_lib_bsd_gethostbyname=yes 56539 else 56540 ac_cv_lib_bsd_gethostbyname=no 56541 fi 56542 rm -f core conftest.err conftest.$ac_objext \ 56543 conftest$ac_exeext conftest.$ac_ext 56544 LIBS=$ac_check_lib_save_LIBS 56545 fi 56546 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_gethostbyname" >&5 56547 $as_echo "$ac_cv_lib_bsd_gethostbyname" >&6; } 56548 if test "x$ac_cv_lib_bsd_gethostbyname" = xyes; then : 56549 X_EXTRA_LIBS="$X_EXTRA_LIBS -lbsd" 56550 fi 56551 56552 fi 56553 fi 56554 56555 # lieder@skyler.mavd.honeywell.com says without -lsocket, 56556 # socket/setsockopt and other routines are undefined under SCO ODT 56557 # 2.0. But -lsocket is broken on IRIX 5.2 (and is not necessary 56558 # on later versions), says Simon Leinen: it contains gethostby* 56559 # variants that don't use the name server (or something). -lsocket 56560 # must be given before -lnsl if both are needed. We assume that 56561 # if connect needs -lnsl, so does gethostbyname. 56562 ac_fn_cxx_check_func "$LINENO" "connect" "ac_cv_func_connect" 56563 if test "x$ac_cv_func_connect" = xyes; then : 56564 56565 fi 56566 56567 if test $ac_cv_func_connect = no; then 56568 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for connect in -lsocket" >&5 56569 $as_echo_n "checking for connect in -lsocket... " >&6; } 56570 if ${ac_cv_lib_socket_connect+:} false; then : 56571 $as_echo_n "(cached) " >&6 56572 else 56573 ac_check_lib_save_LIBS=$LIBS 56574 LIBS="-lsocket $X_EXTRA_LIBS $LIBS" 56575 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56576 /* end confdefs.h. */ 56577 56578 /* Override any GCC internal prototype to avoid an error. 56579 Use char because int might match the return type of a GCC 56580 builtin and then its argument prototype would still apply. */ 56581 #ifdef __cplusplus 56582 extern "C" 56583 #endif 56584 char connect (); 56585 int 56586 main () 56587 { 56588 return connect (); 56589 ; 56590 return 0; 56591 } 56592 _ACEOF 56593 if ac_fn_cxx_try_link "$LINENO"; then : 56594 ac_cv_lib_socket_connect=yes 56595 else 56596 ac_cv_lib_socket_connect=no 56597 fi 56598 rm -f core conftest.err conftest.$ac_objext \ 56599 conftest$ac_exeext conftest.$ac_ext 56600 LIBS=$ac_check_lib_save_LIBS 56601 fi 56602 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_connect" >&5 56603 $as_echo "$ac_cv_lib_socket_connect" >&6; } 56604 if test "x$ac_cv_lib_socket_connect" = xyes; then : 56605 X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS" 56606 fi 56607 56608 fi 56609 56610 # Guillermo Gomez says -lposix is necessary on A/UX. 56611 ac_fn_cxx_check_func "$LINENO" "remove" "ac_cv_func_remove" 56612 if test "x$ac_cv_func_remove" = xyes; then : 56613 56614 fi 56615 56616 if test $ac_cv_func_remove = no; then 56617 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for remove in -lposix" >&5 56618 $as_echo_n "checking for remove in -lposix... " >&6; } 56619 if ${ac_cv_lib_posix_remove+:} false; then : 56620 $as_echo_n "(cached) " >&6 56621 else 56622 ac_check_lib_save_LIBS=$LIBS 56623 LIBS="-lposix $LIBS" 56624 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56625 /* end confdefs.h. */ 56626 56627 /* Override any GCC internal prototype to avoid an error. 56628 Use char because int might match the return type of a GCC 56629 builtin and then its argument prototype would still apply. */ 56630 #ifdef __cplusplus 56631 extern "C" 56632 #endif 56633 char remove (); 56634 int 56635 main () 56636 { 56637 return remove (); 56638 ; 56639 return 0; 56640 } 56641 _ACEOF 56642 if ac_fn_cxx_try_link "$LINENO"; then : 56643 ac_cv_lib_posix_remove=yes 56644 else 56645 ac_cv_lib_posix_remove=no 56646 fi 56647 rm -f core conftest.err conftest.$ac_objext \ 56648 conftest$ac_exeext conftest.$ac_ext 56649 LIBS=$ac_check_lib_save_LIBS 56650 fi 56651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_posix_remove" >&5 56652 $as_echo "$ac_cv_lib_posix_remove" >&6; } 56653 if test "x$ac_cv_lib_posix_remove" = xyes; then : 56654 X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix" 56655 fi 56656 56657 fi 56658 56659 # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay. 56660 ac_fn_cxx_check_func "$LINENO" "shmat" "ac_cv_func_shmat" 56661 if test "x$ac_cv_func_shmat" = xyes; then : 56662 56663 fi 56664 56665 if test $ac_cv_func_shmat = no; then 56666 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shmat in -lipc" >&5 56667 $as_echo_n "checking for shmat in -lipc... " >&6; } 56668 if ${ac_cv_lib_ipc_shmat+:} false; then : 56669 $as_echo_n "(cached) " >&6 56670 else 56671 ac_check_lib_save_LIBS=$LIBS 56672 LIBS="-lipc $LIBS" 56673 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56674 /* end confdefs.h. */ 56675 56676 /* Override any GCC internal prototype to avoid an error. 56677 Use char because int might match the return type of a GCC 56678 builtin and then its argument prototype would still apply. */ 56679 #ifdef __cplusplus 56680 extern "C" 56681 #endif 56682 char shmat (); 56683 int 56684 main () 56685 { 56686 return shmat (); 56687 ; 56688 return 0; 56689 } 56690 _ACEOF 56691 if ac_fn_cxx_try_link "$LINENO"; then : 56692 ac_cv_lib_ipc_shmat=yes 56693 else 56694 ac_cv_lib_ipc_shmat=no 56695 fi 56696 rm -f core conftest.err conftest.$ac_objext \ 56697 conftest$ac_exeext conftest.$ac_ext 56698 LIBS=$ac_check_lib_save_LIBS 56699 fi 56700 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ipc_shmat" >&5 56701 $as_echo "$ac_cv_lib_ipc_shmat" >&6; } 56702 if test "x$ac_cv_lib_ipc_shmat" = xyes; then : 56703 X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc" 56704 fi 56705 56706 fi 56707 fi 56708 56709 # Check for libraries that X11R6 Xt/Xaw programs need. 56710 ac_save_LDFLAGS=$LDFLAGS 56711 test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries" 56712 # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to 56713 # check for ICE first), but we must link in the order -lSM -lICE or 56714 # we get undefined symbols. So assume we have SM if we have ICE. 56715 # These have to be linked with before -lX11, unlike the other 56716 # libraries we check for below, so use a different variable. 56717 # John Interrante, Karl Berry 56718 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for IceConnectionNumber in -lICE" >&5 56719 $as_echo_n "checking for IceConnectionNumber in -lICE... " >&6; } 56720 if ${ac_cv_lib_ICE_IceConnectionNumber+:} false; then : 56721 $as_echo_n "(cached) " >&6 56722 else 56723 ac_check_lib_save_LIBS=$LIBS 56724 LIBS="-lICE $X_EXTRA_LIBS $LIBS" 56725 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56726 /* end confdefs.h. */ 56727 56728 /* Override any GCC internal prototype to avoid an error. 56729 Use char because int might match the return type of a GCC 56730 builtin and then its argument prototype would still apply. */ 56731 #ifdef __cplusplus 56732 extern "C" 56733 #endif 56734 char IceConnectionNumber (); 56735 int 56736 main () 56737 { 56738 return IceConnectionNumber (); 56739 ; 56740 return 0; 56741 } 56742 _ACEOF 56743 if ac_fn_cxx_try_link "$LINENO"; then : 56744 ac_cv_lib_ICE_IceConnectionNumber=yes 56745 else 56746 ac_cv_lib_ICE_IceConnectionNumber=no 56747 fi 56748 rm -f core conftest.err conftest.$ac_objext \ 56749 conftest$ac_exeext conftest.$ac_ext 56750 LIBS=$ac_check_lib_save_LIBS 56751 fi 56752 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ICE_IceConnectionNumber" >&5 56753 $as_echo "$ac_cv_lib_ICE_IceConnectionNumber" >&6; } 56754 if test "x$ac_cv_lib_ICE_IceConnectionNumber" = xyes; then : 56755 X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE" 56756 fi 56757 56758 LDFLAGS=$ac_save_LDFLAGS 56759 56760 fi 56761 56762 56763 # AC_PATH_XTRA creates X_LIBS and sometimes adds -R flags. When cross compiling 56764 # this doesn't make sense so we remove it. 56765 if test "x$COMPILE_TYPE" = xcross; then 56766 X_LIBS=`$ECHO $X_LIBS | $SED 's/-R \{0,1\}[^ ]*//g'` 56767 fi 56768 56769 if test "x$no_x" = xyes; then 56770 56771 # Print a helpful message on how to acquire the necessary build dependency. 56772 # x11 is the help tag: freetype, cups, alsa etc 56773 MISSING_DEPENDENCY=x11 56774 56775 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56776 cygwin_help $MISSING_DEPENDENCY 56777 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56778 msys_help $MISSING_DEPENDENCY 56779 else 56780 PKGHANDLER_COMMAND= 56781 56782 case $PKGHANDLER in 56783 apt-get) 56784 apt_help $MISSING_DEPENDENCY ;; 56785 yum) 56786 yum_help $MISSING_DEPENDENCY ;; 56787 brew) 56788 brew_help $MISSING_DEPENDENCY ;; 56789 port) 56790 port_help $MISSING_DEPENDENCY ;; 56791 pkgutil) 56792 pkgutil_help $MISSING_DEPENDENCY ;; 56793 pkgadd) 56794 pkgadd_help $MISSING_DEPENDENCY ;; 56795 esac 56796 56797 if test "x$PKGHANDLER_COMMAND" != x; then 56798 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 56799 fi 56800 fi 56801 56802 as_fn_error $? "Could not find X11 libraries. $HELP_MSG" "$LINENO" 5 56803 fi 56804 56805 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 56806 OPENWIN_HOME="/usr/openwin" 56807 X_CFLAGS="-I$SYSROOT$OPENWIN_HOME/include -I$SYSROOT$OPENWIN_HOME/include/X11/extensions" 56808 X_LIBS="-L$SYSROOT$OPENWIN_HOME/lib$OPENJDK_TARGET_CPU_ISADIR \ 56809 -R$OPENWIN_HOME/lib$OPENJDK_TARGET_CPU_ISADIR" 56810 fi 56811 56812 ac_ext=c 56813 ac_cpp='$CPP $CPPFLAGS' 56814 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 56815 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 56816 ac_compiler_gnu=$ac_cv_c_compiler_gnu 56817 56818 OLD_CFLAGS="$CFLAGS" 56819 CFLAGS="$CFLAGS $SYSROOT_CFLAGS $X_CFLAGS" 56820 56821 # Need to include Xlib.h and Xutil.h to avoid "present but cannot be compiled" warnings on Solaris 10 56822 for ac_header in X11/extensions/shape.h X11/extensions/Xrender.h X11/extensions/XTest.h X11/Intrinsic.h 56823 do : 56824 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` 56825 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" " 56826 # include <X11/Xlib.h> 56827 # include <X11/Xutil.h> 56828 56829 56830 " 56831 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : 56832 cat >>confdefs.h <<_ACEOF 56833 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 56834 _ACEOF 56835 X11_HEADERS_OK=yes 56836 else 56837 X11_HEADERS_OK=no; break 56838 fi 56839 56840 done 56841 56842 56843 if test "x$X11_HEADERS_OK" = xno; then 56844 56845 # Print a helpful message on how to acquire the necessary build dependency. 56846 # x11 is the help tag: freetype, cups, alsa etc 56847 MISSING_DEPENDENCY=x11 56848 56849 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56850 cygwin_help $MISSING_DEPENDENCY 56851 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56852 msys_help $MISSING_DEPENDENCY 56853 else 56854 PKGHANDLER_COMMAND= 56855 56856 case $PKGHANDLER in 56857 apt-get) 56858 apt_help $MISSING_DEPENDENCY ;; 56859 yum) 56860 yum_help $MISSING_DEPENDENCY ;; 56861 brew) 56862 brew_help $MISSING_DEPENDENCY ;; 56863 port) 56864 port_help $MISSING_DEPENDENCY ;; 56865 pkgutil) 56866 pkgutil_help $MISSING_DEPENDENCY ;; 56867 pkgadd) 56868 pkgadd_help $MISSING_DEPENDENCY ;; 56869 esac 56870 56871 if test "x$PKGHANDLER_COMMAND" != x; then 56872 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 56873 fi 56874 fi 56875 56876 as_fn_error $? "Could not find all X11 headers (shape.h Xrender.h XTest.h Intrinsic.h). $HELP_MSG" "$LINENO" 5 56877 fi 56878 56879 # If XLinearGradient isn't available in Xrender.h, signal that it needs to be 56880 # defined in libawt_xawt. 56881 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if XlinearGradient is defined in Xrender.h" >&5 56882 $as_echo_n "checking if XlinearGradient is defined in Xrender.h... " >&6; } 56883 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56884 /* end confdefs.h. */ 56885 #include <X11/extensions/Xrender.h> 56886 int 56887 main () 56888 { 56889 XLinearGradient x; 56890 ; 56891 return 0; 56892 } 56893 _ACEOF 56894 if ac_fn_c_try_compile "$LINENO"; then : 56895 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 56896 $as_echo "yes" >&6; } 56897 else 56898 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 56899 $as_echo "no" >&6; } 56900 X_CFLAGS="$X_CFLAGS -DSOLARIS10_NO_XRENDER_STRUCTS" 56901 fi 56902 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 56903 56904 CFLAGS="$OLD_CFLAGS" 56905 ac_ext=cpp 56906 ac_cpp='$CXXCPP $CPPFLAGS' 56907 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 56908 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 56909 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 56910 56911 fi # NEEDS_LIB_X11 56912 56913 56914 56915 56916 56917 56918 # Check whether --with-cups was given. 56919 if test "${with_cups+set}" = set; then : 56920 withval=$with_cups; 56921 fi 56922 56923 56924 # Check whether --with-cups-include was given. 56925 if test "${with_cups_include+set}" = set; then : 56926 withval=$with_cups_include; 56927 fi 56928 56929 56930 if test "x$NEEDS_LIB_CUPS" = xfalse; then 56931 if (test "x${with_cups}" != x && test "x${with_cups}" != xno) || \ 56932 (test "x${with_cups_include}" != x && test "x${with_cups_include}" != xno); then 56933 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cups not used, so --with-cups[-*] is ignored" >&5 56934 $as_echo "$as_me: WARNING: cups not used, so --with-cups[-*] is ignored" >&2;} 56935 fi 56936 CUPS_CFLAGS= 56937 else 56938 CUPS_FOUND=no 56939 56940 if test "x${with_cups}" = xno || test "x${with_cups_include}" = xno; then 56941 as_fn_error $? "It is not possible to disable the use of cups. Remove the --without-cups option." "$LINENO" 5 56942 fi 56943 56944 if test "x${with_cups}" != x; then 56945 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cups headers" >&5 56946 $as_echo_n "checking for cups headers... " >&6; } 56947 if test -s "${with_cups}/include/cups/cups.h"; then 56948 CUPS_CFLAGS="-I${with_cups}/include" 56949 CUPS_FOUND=yes 56950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUPS_FOUND" >&5 56951 $as_echo "$CUPS_FOUND" >&6; } 56952 else 56953 as_fn_error $? "Can't find 'include/cups/cups.h' under ${with_cups} given with the --with-cups option." "$LINENO" 5 56954 fi 56955 fi 56956 if test "x${with_cups_include}" != x; then 56957 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cups headers" >&5 56958 $as_echo_n "checking for cups headers... " >&6; } 56959 if test -s "${with_cups_include}/cups/cups.h"; then 56960 CUPS_CFLAGS="-I${with_cups_include}" 56961 CUPS_FOUND=yes 56962 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUPS_FOUND" >&5 56963 $as_echo "$CUPS_FOUND" >&6; } 56964 else 56965 as_fn_error $? "Can't find 'cups/cups.h' under ${with_cups_include} given with the --with-cups-include option." "$LINENO" 5 56966 fi 56967 fi 56968 if test "x$CUPS_FOUND" = xno; then 56969 # Are the cups headers installed in the default /usr/include location? 56970 for ac_header in cups/cups.h cups/ppd.h 56971 do : 56972 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` 56973 ac_fn_cxx_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" 56974 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : 56975 cat >>confdefs.h <<_ACEOF 56976 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 56977 _ACEOF 56978 56979 CUPS_FOUND=yes 56980 CUPS_CFLAGS= 56981 DEFAULT_CUPS=yes 56982 56983 fi 56984 56985 done 56986 56987 fi 56988 if test "x$CUPS_FOUND" = xno; then 56989 56990 # Print a helpful message on how to acquire the necessary build dependency. 56991 # cups is the help tag: freetype, cups, alsa etc 56992 MISSING_DEPENDENCY=cups 56993 56994 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56995 cygwin_help $MISSING_DEPENDENCY 56996 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56997 msys_help $MISSING_DEPENDENCY 56998 else 56999 PKGHANDLER_COMMAND= 57000 57001 case $PKGHANDLER in 57002 apt-get) 57003 apt_help $MISSING_DEPENDENCY ;; 57004 yum) 57005 yum_help $MISSING_DEPENDENCY ;; 57006 brew) 57007 brew_help $MISSING_DEPENDENCY ;; 57008 port) 57009 port_help $MISSING_DEPENDENCY ;; 57010 pkgutil) 57011 pkgutil_help $MISSING_DEPENDENCY ;; 57012 pkgadd) 57013 pkgadd_help $MISSING_DEPENDENCY ;; 57014 esac 57015 57016 if test "x$PKGHANDLER_COMMAND" != x; then 57017 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 57018 fi 57019 fi 57020 57021 as_fn_error $? "Could not find cups! $HELP_MSG " "$LINENO" 5 57022 fi 57023 fi 57024 57025 57026 57027 57028 57029 # Check whether --with-freetype was given. 57030 if test "${with_freetype+set}" = set; then : 57031 withval=$with_freetype; 57032 fi 57033 57034 57035 # Check whether --with-freetype-include was given. 57036 if test "${with_freetype_include+set}" = set; then : 57037 withval=$with_freetype_include; 57038 fi 57039 57040 57041 # Check whether --with-freetype-lib was given. 57042 if test "${with_freetype_lib+set}" = set; then : 57043 withval=$with_freetype_lib; 57044 fi 57045 57046 57047 # Check whether --with-freetype-src was given. 57048 if test "${with_freetype_src+set}" = set; then : 57049 withval=$with_freetype_src; 57050 fi 57051 57052 # Check whether --enable-freetype-bundling was given. 57053 if test "${enable_freetype_bundling+set}" = set; then : 57054 enableval=$enable_freetype_bundling; 57055 fi 57056 57057 57058 # Need to specify explicitly since it needs to be overridden on some versions of macosx 57059 FREETYPE_BASE_NAME=freetype 57060 FREETYPE_CFLAGS= 57061 FREETYPE_LIBS= 57062 FREETYPE_BUNDLE_LIB_PATH= 57063 57064 if test "x$NEEDS_LIB_FREETYPE" = xfalse; then 57065 if (test "x$with_freetype" != x && test "x$with_freetype" != xno) || \ 57066 (test "x$with_freetype_include" != x && test "x$with_freetype_include" != xno) || \ 57067 (test "x$with_freetype_lib" != x && test "x$with_freetype_lib" != xno) || \ 57068 (test "x$with_freetype_src" != x && test "x$with_freetype_src" != xno); then 57069 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: freetype not used, so --with-freetype[-*] is ignored" >&5 57070 $as_echo "$as_me: WARNING: freetype not used, so --with-freetype[-*] is ignored" >&2;} 57071 fi 57072 if (test "x$enable_freetype_bundling" != x && test "x$enable_freetype_bundling" != xno); then 57073 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: freetype not used, so --enable-freetype-bundling is ignored" >&5 57074 $as_echo "$as_me: WARNING: freetype not used, so --enable-freetype-bundling is ignored" >&2;} 57075 fi 57076 else 57077 # freetype is needed to build; go get it! 57078 57079 BUNDLE_FREETYPE="$enable_freetype_bundling" 57080 57081 if test "x$with_freetype_src" != x; then 57082 if test "x$OPENJDK_TARGET_OS" = xwindows; then 57083 # Try to build freetype if --with-freetype-src was given on Windows 57084 57085 FREETYPE_SRC_PATH="$with_freetype_src" 57086 BUILD_FREETYPE=yes 57087 57088 # Check if the freetype sources are acessible.. 57089 if ! test -d $FREETYPE_SRC_PATH; then 57090 { $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 57091 $as_echo "$as_me: WARNING: --with-freetype-src specified, but can not find path \"$FREETYPE_SRC_PATH\" - ignoring --with-freetype-src" >&2;} 57092 BUILD_FREETYPE=no 57093 fi 57094 # ..and contain a vc2010 project file 57095 vcxproj_path="$FREETYPE_SRC_PATH/builds/windows/vc2010/freetype.vcxproj" 57096 if test "x$BUILD_FREETYPE" = xyes && ! test -s $vcxproj_path; then 57097 { $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 57098 $as_echo "$as_me: WARNING: Can not find project file $vcxproj_path (you may try a newer freetype version) - ignoring --with-freetype-src" >&2;} 57099 BUILD_FREETYPE=no 57100 fi 57101 # Now check if configure found a version of 'msbuild.exe' 57102 if test "x$BUILD_FREETYPE" = xyes && test "x$MSBUILD" == x ; then 57103 { $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 57104 $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;} 57105 BUILD_FREETYPE=no 57106 fi 57107 57108 # Ready to go.. 57109 if test "x$BUILD_FREETYPE" = xyes; then 57110 # msbuild requires trailing slashes for output directories 57111 freetype_lib_path="$FREETYPE_SRC_PATH/lib$OPENJDK_TARGET_CPU_BITS/" 57112 freetype_lib_path_unix="$freetype_lib_path" 57113 freetype_obj_path="$FREETYPE_SRC_PATH/obj$OPENJDK_TARGET_CPU_BITS/" 57114 57115 unix_path="$vcxproj_path" 57116 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57117 windows_path=`$CYGPATH -m "$unix_path"` 57118 vcxproj_path="$windows_path" 57119 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57120 windows_path=`cmd //c echo $unix_path` 57121 vcxproj_path="$windows_path" 57122 fi 57123 57124 57125 unix_path="$freetype_lib_path" 57126 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57127 windows_path=`$CYGPATH -m "$unix_path"` 57128 freetype_lib_path="$windows_path" 57129 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57130 windows_path=`cmd //c echo $unix_path` 57131 freetype_lib_path="$windows_path" 57132 fi 57133 57134 57135 unix_path="$freetype_obj_path" 57136 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57137 windows_path=`$CYGPATH -m "$unix_path"` 57138 freetype_obj_path="$windows_path" 57139 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57140 windows_path=`cmd //c echo $unix_path` 57141 freetype_obj_path="$windows_path" 57142 fi 57143 57144 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 57145 freetype_platform=x64 57146 else 57147 freetype_platform=win32 57148 fi 57149 57150 # The original freetype project file is for VS 2010 (i.e. 'v100'), 57151 # so we have to adapt the toolset if building with any other toolsed (i.e. SDK). 57152 # Currently 'PLATFORM_TOOLSET' is set in 'TOOLCHAIN_CHECK_POSSIBLE_VISUAL_STUDIO_ROOT'/ 57153 # 'TOOLCHAIN_CHECK_POSSIBLE_WIN_SDK_ROOT' in toolchain_windows.m4 57154 { $as_echo "$as_me:${as_lineno-$LINENO}: Trying to compile freetype sources with PlatformToolset=$PLATFORM_TOOLSET to $freetype_lib_path_unix ..." >&5 57155 $as_echo "$as_me: Trying to compile freetype sources with PlatformToolset=$PLATFORM_TOOLSET to $freetype_lib_path_unix ..." >&6;} 57156 57157 # First we try to build the freetype.dll 57158 $ECHO -e "@echo off\n"\ 57159 "$MSBUILD $vcxproj_path "\ 57160 "/p:PlatformToolset=$PLATFORM_TOOLSET "\ 57161 "/p:Configuration=\"Release Multithreaded\" "\ 57162 "/p:Platform=$freetype_platform "\ 57163 "/p:ConfigurationType=DynamicLibrary "\ 57164 "/p:TargetName=freetype "\ 57165 "/p:OutDir=\"$freetype_lib_path\" "\ 57166 "/p:IntDir=\"$freetype_obj_path\" > freetype.log" > freetype.bat 57167 cmd /c freetype.bat 57168 57169 if test -s "$freetype_lib_path_unix/freetype.dll"; then 57170 # If that succeeds we also build freetype.lib 57171 $ECHO -e "@echo off\n"\ 57172 "$MSBUILD $vcxproj_path "\ 57173 "/p:PlatformToolset=$PLATFORM_TOOLSET "\ 57174 "/p:Configuration=\"Release Multithreaded\" "\ 57175 "/p:Platform=$freetype_platform "\ 57176 "/p:ConfigurationType=StaticLibrary "\ 57177 "/p:TargetName=freetype "\ 57178 "/p:OutDir=\"$freetype_lib_path\" "\ 57179 "/p:IntDir=\"$freetype_obj_path\" >> freetype.log" > freetype.bat 57180 cmd /c freetype.bat 57181 57182 if test -s "$freetype_lib_path_unix/freetype.lib"; then 57183 # Once we build both, lib and dll, set freetype lib and include path appropriately 57184 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_SRC_PATH/include" 57185 POTENTIAL_FREETYPE_LIB_PATH="$freetype_lib_path_unix" 57186 { $as_echo "$as_me:${as_lineno-$LINENO}: Compiling freetype sources succeeded! (see freetype.log for build results)" >&5 57187 $as_echo "$as_me: Compiling freetype sources succeeded! (see freetype.log for build results)" >&6;} 57188 else 57189 BUILD_FREETYPE=no 57190 fi 57191 else 57192 BUILD_FREETYPE=no 57193 fi 57194 fi 57195 57196 if test "x$BUILD_FREETYPE" = xyes; then 57197 # Okay, we built it. Check that it works. 57198 57199 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57200 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 57201 METHOD="--with-freetype-src" 57202 57203 # Let's start with an optimistic view of the world :-) 57204 FOUND_FREETYPE=yes 57205 57206 # First look for the canonical freetype main include file ft2build.h. 57207 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 57208 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 57209 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 57210 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 57211 # Fail. 57212 FOUND_FREETYPE=no 57213 fi 57214 fi 57215 57216 if test "x$FOUND_FREETYPE" = xyes; then 57217 # Include file found, let's continue the sanity check. 57218 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 57219 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 57220 57221 # Reset to default value 57222 FREETYPE_BASE_NAME=freetype 57223 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 57224 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 57225 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 57226 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 57227 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 57228 # for the .6 version explicitly. 57229 FREETYPE_BASE_NAME=freetype.6 57230 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 57231 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 57232 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 57233 else 57234 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 57235 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 57236 FOUND_FREETYPE=no 57237 fi 57238 else 57239 if test "x$OPENJDK_TARGET_OS" = xwindows; then 57240 # On Windows, we will need both .lib and .dll file. 57241 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 57242 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 57243 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 57244 FOUND_FREETYPE=no 57245 fi 57246 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 57247 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 57248 # Found lib in isa dir, use that instead. 57249 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 57250 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 57251 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 57252 fi 57253 fi 57254 fi 57255 57256 if test "x$FOUND_FREETYPE" = xyes; then 57257 57258 # Only process if variable expands to non-empty 57259 57260 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 57261 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57262 57263 # Input might be given as Windows format, start by converting to 57264 # unix format. 57265 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57266 new_path=`$CYGPATH -u "$path"` 57267 57268 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 57269 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 57270 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 57271 # "foo.exe" is OK but "foo" is an error. 57272 # 57273 # This test is therefore slightly more accurate than "test -f" to check for file precense. 57274 # It is also a way to make sure we got the proper file name for the real test later on. 57275 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 57276 if test "x$test_shortpath" = x; then 57277 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 57278 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 57279 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 57280 fi 57281 57282 # Call helper function which possibly converts this using DOS-style short mode. 57283 # If so, the updated path is stored in $new_path. 57284 57285 input_path="$new_path" 57286 # Check if we need to convert this using DOS-style short mode. If the path 57287 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57288 # take no chances and rewrite it. 57289 # Note: m4 eats our [], so we need to use [ and ] instead. 57290 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 57291 if test "x$has_forbidden_chars" != x; then 57292 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57293 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 57294 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 57295 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 57296 # Going to short mode and back again did indeed matter. Since short mode is 57297 # case insensitive, let's make it lowercase to improve readability. 57298 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57299 # Now convert it back to Unix-style (cygpath) 57300 input_path=`$CYGPATH -u "$shortmode_path"` 57301 new_path="$input_path" 57302 fi 57303 fi 57304 57305 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 57306 if test "x$test_cygdrive_prefix" = x; then 57307 # As a simple fix, exclude /usr/bin since it's not a real path. 57308 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 57309 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 57310 # a path prefixed by /cygdrive for fixpath to work. 57311 new_path="$CYGWIN_ROOT_PATH$input_path" 57312 fi 57313 fi 57314 57315 57316 if test "x$path" != "x$new_path"; then 57317 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 57318 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 57319 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 57320 fi 57321 57322 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57323 57324 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57325 has_colon=`$ECHO $path | $GREP ^.:` 57326 new_path="$path" 57327 if test "x$has_colon" = x; then 57328 # Not in mixed or Windows style, start by that. 57329 new_path=`cmd //c echo $path` 57330 fi 57331 57332 57333 input_path="$new_path" 57334 # Check if we need to convert this using DOS-style short mode. If the path 57335 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57336 # take no chances and rewrite it. 57337 # Note: m4 eats our [], so we need to use [ and ] instead. 57338 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 57339 if test "x$has_forbidden_chars" != x; then 57340 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57341 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57342 fi 57343 57344 57345 windows_path="$new_path" 57346 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57347 unix_path=`$CYGPATH -u "$windows_path"` 57348 new_path="$unix_path" 57349 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57350 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 57351 new_path="$unix_path" 57352 fi 57353 57354 if test "x$path" != "x$new_path"; then 57355 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 57356 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 57357 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 57358 fi 57359 57360 # Save the first 10 bytes of this path to the storage, so fixpath can work. 57361 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 57362 57363 else 57364 # We're on a unix platform. Hooray! :) 57365 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57366 has_space=`$ECHO "$path" | $GREP " "` 57367 if test "x$has_space" != x; then 57368 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 57369 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 57370 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 57371 fi 57372 57373 # Use eval to expand a potential ~ 57374 eval path="$path" 57375 if test ! -f "$path" && test ! -d "$path"; then 57376 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 57377 fi 57378 57379 if test -d "$path"; then 57380 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 57381 else 57382 dir="`$DIRNAME "$path"`" 57383 base="`$BASENAME "$path"`" 57384 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 57385 fi 57386 fi 57387 fi 57388 57389 57390 # Only process if variable expands to non-empty 57391 57392 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 57393 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57394 57395 # Input might be given as Windows format, start by converting to 57396 # unix format. 57397 path="$POTENTIAL_FREETYPE_LIB_PATH" 57398 new_path=`$CYGPATH -u "$path"` 57399 57400 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 57401 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 57402 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 57403 # "foo.exe" is OK but "foo" is an error. 57404 # 57405 # This test is therefore slightly more accurate than "test -f" to check for file precense. 57406 # It is also a way to make sure we got the proper file name for the real test later on. 57407 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 57408 if test "x$test_shortpath" = x; then 57409 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 57410 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 57411 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 57412 fi 57413 57414 # Call helper function which possibly converts this using DOS-style short mode. 57415 # If so, the updated path is stored in $new_path. 57416 57417 input_path="$new_path" 57418 # Check if we need to convert this using DOS-style short mode. If the path 57419 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57420 # take no chances and rewrite it. 57421 # Note: m4 eats our [], so we need to use [ and ] instead. 57422 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 57423 if test "x$has_forbidden_chars" != x; then 57424 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57425 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 57426 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 57427 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 57428 # Going to short mode and back again did indeed matter. Since short mode is 57429 # case insensitive, let's make it lowercase to improve readability. 57430 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57431 # Now convert it back to Unix-style (cygpath) 57432 input_path=`$CYGPATH -u "$shortmode_path"` 57433 new_path="$input_path" 57434 fi 57435 fi 57436 57437 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 57438 if test "x$test_cygdrive_prefix" = x; then 57439 # As a simple fix, exclude /usr/bin since it's not a real path. 57440 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 57441 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 57442 # a path prefixed by /cygdrive for fixpath to work. 57443 new_path="$CYGWIN_ROOT_PATH$input_path" 57444 fi 57445 fi 57446 57447 57448 if test "x$path" != "x$new_path"; then 57449 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 57450 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 57451 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 57452 fi 57453 57454 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57455 57456 path="$POTENTIAL_FREETYPE_LIB_PATH" 57457 has_colon=`$ECHO $path | $GREP ^.:` 57458 new_path="$path" 57459 if test "x$has_colon" = x; then 57460 # Not in mixed or Windows style, start by that. 57461 new_path=`cmd //c echo $path` 57462 fi 57463 57464 57465 input_path="$new_path" 57466 # Check if we need to convert this using DOS-style short mode. If the path 57467 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57468 # take no chances and rewrite it. 57469 # Note: m4 eats our [], so we need to use [ and ] instead. 57470 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 57471 if test "x$has_forbidden_chars" != x; then 57472 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57473 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57474 fi 57475 57476 57477 windows_path="$new_path" 57478 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57479 unix_path=`$CYGPATH -u "$windows_path"` 57480 new_path="$unix_path" 57481 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57482 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 57483 new_path="$unix_path" 57484 fi 57485 57486 if test "x$path" != "x$new_path"; then 57487 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 57488 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 57489 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 57490 fi 57491 57492 # Save the first 10 bytes of this path to the storage, so fixpath can work. 57493 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 57494 57495 else 57496 # We're on a unix platform. Hooray! :) 57497 path="$POTENTIAL_FREETYPE_LIB_PATH" 57498 has_space=`$ECHO "$path" | $GREP " "` 57499 if test "x$has_space" != x; then 57500 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 57501 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 57502 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 57503 fi 57504 57505 # Use eval to expand a potential ~ 57506 eval path="$path" 57507 if test ! -f "$path" && test ! -d "$path"; then 57508 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 57509 fi 57510 57511 if test -d "$path"; then 57512 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 57513 else 57514 dir="`$DIRNAME "$path"`" 57515 base="`$BASENAME "$path"`" 57516 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 57517 fi 57518 fi 57519 fi 57520 57521 57522 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57523 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 57524 $as_echo_n "checking for freetype includes... " >&6; } 57525 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 57526 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 57527 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 57528 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 57529 $as_echo_n "checking for freetype libraries... " >&6; } 57530 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 57531 $as_echo "$FREETYPE_LIB_PATH" >&6; } 57532 fi 57533 57534 if test "x$FOUND_FREETYPE" != xyes; then 57535 as_fn_error $? "Can not use the built freetype at location given by --with-freetype-src" "$LINENO" 5 57536 fi 57537 else 57538 { $as_echo "$as_me:${as_lineno-$LINENO}: User specified --with-freetype-src but building freetype failed. (see freetype.log for build results)" >&5 57539 $as_echo "$as_me: User specified --with-freetype-src but building freetype failed. (see freetype.log for build results)" >&6;} 57540 as_fn_error $? "Consider building freetype manually and using --with-freetype instead." "$LINENO" 5 57541 fi 57542 else 57543 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-freetype-src is currently only supported on Windows - ignoring" >&5 57544 $as_echo "$as_me: WARNING: --with-freetype-src is currently only supported on Windows - ignoring" >&2;} 57545 fi 57546 fi 57547 57548 if test "x$with_freetype" != x || test "x$with_freetype_include" != x || test "x$with_freetype_lib" != x; then 57549 # User has specified settings 57550 57551 if test "x$BUNDLE_FREETYPE" = x; then 57552 # If not specified, default is to bundle freetype 57553 BUNDLE_FREETYPE=yes 57554 fi 57555 57556 if test "x$with_freetype" != x; then 57557 POTENTIAL_FREETYPE_INCLUDE_PATH="$with_freetype/include" 57558 POTENTIAL_FREETYPE_LIB_PATH="$with_freetype/lib" 57559 fi 57560 57561 # Allow --with-freetype-lib and --with-freetype-include to override 57562 if test "x$with_freetype_include" != x; then 57563 POTENTIAL_FREETYPE_INCLUDE_PATH="$with_freetype_include" 57564 fi 57565 if test "x$with_freetype_lib" != x; then 57566 POTENTIAL_FREETYPE_LIB_PATH="$with_freetype_lib" 57567 fi 57568 57569 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x && test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 57570 # Okay, we got it. Check that it works. 57571 57572 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57573 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 57574 METHOD="--with-freetype" 57575 57576 # Let's start with an optimistic view of the world :-) 57577 FOUND_FREETYPE=yes 57578 57579 # First look for the canonical freetype main include file ft2build.h. 57580 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 57581 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 57582 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 57583 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 57584 # Fail. 57585 FOUND_FREETYPE=no 57586 fi 57587 fi 57588 57589 if test "x$FOUND_FREETYPE" = xyes; then 57590 # Include file found, let's continue the sanity check. 57591 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 57592 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 57593 57594 # Reset to default value 57595 FREETYPE_BASE_NAME=freetype 57596 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 57597 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 57598 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 57599 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 57600 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 57601 # for the .6 version explicitly. 57602 FREETYPE_BASE_NAME=freetype.6 57603 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 57604 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 57605 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 57606 else 57607 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 57608 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 57609 FOUND_FREETYPE=no 57610 fi 57611 else 57612 if test "x$OPENJDK_TARGET_OS" = xwindows; then 57613 # On Windows, we will need both .lib and .dll file. 57614 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 57615 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 57616 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 57617 FOUND_FREETYPE=no 57618 fi 57619 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 57620 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 57621 # Found lib in isa dir, use that instead. 57622 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 57623 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 57624 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 57625 fi 57626 fi 57627 fi 57628 57629 if test "x$FOUND_FREETYPE" = xyes; then 57630 57631 # Only process if variable expands to non-empty 57632 57633 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 57634 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57635 57636 # Input might be given as Windows format, start by converting to 57637 # unix format. 57638 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57639 new_path=`$CYGPATH -u "$path"` 57640 57641 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 57642 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 57643 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 57644 # "foo.exe" is OK but "foo" is an error. 57645 # 57646 # This test is therefore slightly more accurate than "test -f" to check for file precense. 57647 # It is also a way to make sure we got the proper file name for the real test later on. 57648 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 57649 if test "x$test_shortpath" = x; then 57650 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 57651 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 57652 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 57653 fi 57654 57655 # Call helper function which possibly converts this using DOS-style short mode. 57656 # If so, the updated path is stored in $new_path. 57657 57658 input_path="$new_path" 57659 # Check if we need to convert this using DOS-style short mode. If the path 57660 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57661 # take no chances and rewrite it. 57662 # Note: m4 eats our [], so we need to use [ and ] instead. 57663 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 57664 if test "x$has_forbidden_chars" != x; then 57665 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57666 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 57667 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 57668 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 57669 # Going to short mode and back again did indeed matter. Since short mode is 57670 # case insensitive, let's make it lowercase to improve readability. 57671 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57672 # Now convert it back to Unix-style (cygpath) 57673 input_path=`$CYGPATH -u "$shortmode_path"` 57674 new_path="$input_path" 57675 fi 57676 fi 57677 57678 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 57679 if test "x$test_cygdrive_prefix" = x; then 57680 # As a simple fix, exclude /usr/bin since it's not a real path. 57681 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 57682 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 57683 # a path prefixed by /cygdrive for fixpath to work. 57684 new_path="$CYGWIN_ROOT_PATH$input_path" 57685 fi 57686 fi 57687 57688 57689 if test "x$path" != "x$new_path"; then 57690 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 57691 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 57692 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 57693 fi 57694 57695 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57696 57697 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57698 has_colon=`$ECHO $path | $GREP ^.:` 57699 new_path="$path" 57700 if test "x$has_colon" = x; then 57701 # Not in mixed or Windows style, start by that. 57702 new_path=`cmd //c echo $path` 57703 fi 57704 57705 57706 input_path="$new_path" 57707 # Check if we need to convert this using DOS-style short mode. If the path 57708 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57709 # take no chances and rewrite it. 57710 # Note: m4 eats our [], so we need to use [ and ] instead. 57711 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 57712 if test "x$has_forbidden_chars" != x; then 57713 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57714 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57715 fi 57716 57717 57718 windows_path="$new_path" 57719 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57720 unix_path=`$CYGPATH -u "$windows_path"` 57721 new_path="$unix_path" 57722 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57723 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 57724 new_path="$unix_path" 57725 fi 57726 57727 if test "x$path" != "x$new_path"; then 57728 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 57729 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 57730 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 57731 fi 57732 57733 # Save the first 10 bytes of this path to the storage, so fixpath can work. 57734 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 57735 57736 else 57737 # We're on a unix platform. Hooray! :) 57738 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57739 has_space=`$ECHO "$path" | $GREP " "` 57740 if test "x$has_space" != x; then 57741 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 57742 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 57743 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 57744 fi 57745 57746 # Use eval to expand a potential ~ 57747 eval path="$path" 57748 if test ! -f "$path" && test ! -d "$path"; then 57749 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 57750 fi 57751 57752 if test -d "$path"; then 57753 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 57754 else 57755 dir="`$DIRNAME "$path"`" 57756 base="`$BASENAME "$path"`" 57757 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 57758 fi 57759 fi 57760 fi 57761 57762 57763 # Only process if variable expands to non-empty 57764 57765 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 57766 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57767 57768 # Input might be given as Windows format, start by converting to 57769 # unix format. 57770 path="$POTENTIAL_FREETYPE_LIB_PATH" 57771 new_path=`$CYGPATH -u "$path"` 57772 57773 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 57774 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 57775 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 57776 # "foo.exe" is OK but "foo" is an error. 57777 # 57778 # This test is therefore slightly more accurate than "test -f" to check for file precense. 57779 # It is also a way to make sure we got the proper file name for the real test later on. 57780 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 57781 if test "x$test_shortpath" = x; then 57782 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 57783 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 57784 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 57785 fi 57786 57787 # Call helper function which possibly converts this using DOS-style short mode. 57788 # If so, the updated path is stored in $new_path. 57789 57790 input_path="$new_path" 57791 # Check if we need to convert this using DOS-style short mode. If the path 57792 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57793 # take no chances and rewrite it. 57794 # Note: m4 eats our [], so we need to use [ and ] instead. 57795 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 57796 if test "x$has_forbidden_chars" != x; then 57797 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57798 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 57799 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 57800 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 57801 # Going to short mode and back again did indeed matter. Since short mode is 57802 # case insensitive, let's make it lowercase to improve readability. 57803 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57804 # Now convert it back to Unix-style (cygpath) 57805 input_path=`$CYGPATH -u "$shortmode_path"` 57806 new_path="$input_path" 57807 fi 57808 fi 57809 57810 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 57811 if test "x$test_cygdrive_prefix" = x; then 57812 # As a simple fix, exclude /usr/bin since it's not a real path. 57813 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 57814 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 57815 # a path prefixed by /cygdrive for fixpath to work. 57816 new_path="$CYGWIN_ROOT_PATH$input_path" 57817 fi 57818 fi 57819 57820 57821 if test "x$path" != "x$new_path"; then 57822 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 57823 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 57824 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 57825 fi 57826 57827 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57828 57829 path="$POTENTIAL_FREETYPE_LIB_PATH" 57830 has_colon=`$ECHO $path | $GREP ^.:` 57831 new_path="$path" 57832 if test "x$has_colon" = x; then 57833 # Not in mixed or Windows style, start by that. 57834 new_path=`cmd //c echo $path` 57835 fi 57836 57837 57838 input_path="$new_path" 57839 # Check if we need to convert this using DOS-style short mode. If the path 57840 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57841 # take no chances and rewrite it. 57842 # Note: m4 eats our [], so we need to use [ and ] instead. 57843 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 57844 if test "x$has_forbidden_chars" != x; then 57845 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57846 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57847 fi 57848 57849 57850 windows_path="$new_path" 57851 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57852 unix_path=`$CYGPATH -u "$windows_path"` 57853 new_path="$unix_path" 57854 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57855 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 57856 new_path="$unix_path" 57857 fi 57858 57859 if test "x$path" != "x$new_path"; then 57860 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 57861 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 57862 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 57863 fi 57864 57865 # Save the first 10 bytes of this path to the storage, so fixpath can work. 57866 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 57867 57868 else 57869 # We're on a unix platform. Hooray! :) 57870 path="$POTENTIAL_FREETYPE_LIB_PATH" 57871 has_space=`$ECHO "$path" | $GREP " "` 57872 if test "x$has_space" != x; then 57873 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 57874 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 57875 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 57876 fi 57877 57878 # Use eval to expand a potential ~ 57879 eval path="$path" 57880 if test ! -f "$path" && test ! -d "$path"; then 57881 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 57882 fi 57883 57884 if test -d "$path"; then 57885 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 57886 else 57887 dir="`$DIRNAME "$path"`" 57888 base="`$BASENAME "$path"`" 57889 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 57890 fi 57891 fi 57892 fi 57893 57894 57895 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57896 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 57897 $as_echo_n "checking for freetype includes... " >&6; } 57898 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 57899 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 57900 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 57901 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 57902 $as_echo_n "checking for freetype libraries... " >&6; } 57903 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 57904 $as_echo "$FREETYPE_LIB_PATH" >&6; } 57905 fi 57906 57907 if test "x$FOUND_FREETYPE" != xyes; then 57908 as_fn_error $? "Can not find or use freetype at location given by --with-freetype" "$LINENO" 5 57909 fi 57910 else 57911 # User specified only one of lib or include. This is an error. 57912 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" = x ; then 57913 { $as_echo "$as_me:${as_lineno-$LINENO}: User specified --with-freetype-lib but not --with-freetype-include" >&5 57914 $as_echo "$as_me: User specified --with-freetype-lib but not --with-freetype-include" >&6;} 57915 as_fn_error $? "Need both freetype lib and include paths. Consider using --with-freetype instead." "$LINENO" 5 57916 else 57917 { $as_echo "$as_me:${as_lineno-$LINENO}: User specified --with-freetype-include but not --with-freetype-lib" >&5 57918 $as_echo "$as_me: User specified --with-freetype-include but not --with-freetype-lib" >&6;} 57919 as_fn_error $? "Need both freetype lib and include paths. Consider using --with-freetype instead." "$LINENO" 5 57920 fi 57921 fi 57922 else 57923 # User did not specify settings, but we need freetype. Try to locate it. 57924 57925 if test "x$BUNDLE_FREETYPE" = x; then 57926 # If not specified, default is to bundle freetype only on windows 57927 if test "x$OPENJDK_TARGET_OS" = xwindows; then 57928 BUNDLE_FREETYPE=yes 57929 else 57930 BUNDLE_FREETYPE=no 57931 fi 57932 fi 57933 57934 # If we have a sysroot, assume that's where we are supposed to look and skip pkg-config. 57935 if test "x$SYSROOT" = x; then 57936 if test "x$FOUND_FREETYPE" != xyes; then 57937 # Check modules using pkg-config, but only if we have it (ugly output results otherwise) 57938 if test "x$PKG_CONFIG" != x; then 57939 57940 pkg_failed=no 57941 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FREETYPE" >&5 57942 $as_echo_n "checking for FREETYPE... " >&6; } 57943 57944 if test -n "$FREETYPE_CFLAGS"; then 57945 pkg_cv_FREETYPE_CFLAGS="$FREETYPE_CFLAGS" 57946 elif test -n "$PKG_CONFIG"; then 57947 if test -n "$PKG_CONFIG" && \ 57948 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"freetype2\""; } >&5 57949 ($PKG_CONFIG --exists --print-errors "freetype2") 2>&5 57950 ac_status=$? 57951 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 57952 test $ac_status = 0; }; then 57953 pkg_cv_FREETYPE_CFLAGS=`$PKG_CONFIG --cflags "freetype2" 2>/dev/null` 57954 else 57955 pkg_failed=yes 57956 fi 57957 else 57958 pkg_failed=untried 57959 fi 57960 if test -n "$FREETYPE_LIBS"; then 57961 pkg_cv_FREETYPE_LIBS="$FREETYPE_LIBS" 57962 elif test -n "$PKG_CONFIG"; then 57963 if test -n "$PKG_CONFIG" && \ 57964 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"freetype2\""; } >&5 57965 ($PKG_CONFIG --exists --print-errors "freetype2") 2>&5 57966 ac_status=$? 57967 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 57968 test $ac_status = 0; }; then 57969 pkg_cv_FREETYPE_LIBS=`$PKG_CONFIG --libs "freetype2" 2>/dev/null` 57970 else 57971 pkg_failed=yes 57972 fi 57973 else 57974 pkg_failed=untried 57975 fi 57976 57977 57978 57979 if test $pkg_failed = yes; then 57980 57981 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 57982 _pkg_short_errors_supported=yes 57983 else 57984 _pkg_short_errors_supported=no 57985 fi 57986 if test $_pkg_short_errors_supported = yes; then 57987 FREETYPE_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "freetype2" 2>&1` 57988 else 57989 FREETYPE_PKG_ERRORS=`$PKG_CONFIG --print-errors "freetype2" 2>&1` 57990 fi 57991 # Put the nasty error message in config.log where it belongs 57992 echo "$FREETYPE_PKG_ERRORS" >&5 57993 57994 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 57995 $as_echo "no" >&6; } 57996 FOUND_FREETYPE=no 57997 elif test $pkg_failed = untried; then 57998 FOUND_FREETYPE=no 57999 else 58000 FREETYPE_CFLAGS=$pkg_cv_FREETYPE_CFLAGS 58001 FREETYPE_LIBS=$pkg_cv_FREETYPE_LIBS 58002 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 58003 $as_echo "yes" >&6; } 58004 FOUND_FREETYPE=yes 58005 fi 58006 if test "x$FOUND_FREETYPE" = xyes; then 58007 # On solaris, pkg_check adds -lz to freetype libs, which isn't necessary for us. 58008 FREETYPE_LIBS=`$ECHO $FREETYPE_LIBS | $SED 's/-lz//g'` 58009 # 64-bit libs for Solaris x86 are installed in the amd64 subdirectory, change lib to lib/amd64 58010 if test "x$OPENJDK_TARGET_OS" = xsolaris && test "x$OPENJDK_TARGET_CPU" = xx86_64; then 58011 FREETYPE_LIBS=`$ECHO $FREETYPE_LIBS | $SED 's?/lib?/lib/amd64?g'` 58012 fi 58013 # PKG_CHECK_MODULES will set FREETYPE_CFLAGS and _LIBS, but we don't get a lib path for bundling. 58014 if test "x$BUNDLE_FREETYPE" = xyes; then 58015 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype using pkg-config, but ignoring since we can not bundle that" >&5 58016 $as_echo "$as_me: Found freetype using pkg-config, but ignoring since we can not bundle that" >&6;} 58017 FOUND_FREETYPE=no 58018 else 58019 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype" >&5 58020 $as_echo_n "checking for freetype... " >&6; } 58021 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (using pkg-config)" >&5 58022 $as_echo "yes (using pkg-config)" >&6; } 58023 fi 58024 fi 58025 fi 58026 fi 58027 fi 58028 58029 if test "x$FOUND_FREETYPE" != xyes; then 58030 # Check in well-known locations 58031 if test "x$OPENJDK_TARGET_OS" = xwindows; then 58032 FREETYPE_BASE_DIR="$PROGRAMFILES/GnuWin32" 58033 58034 windows_path="$FREETYPE_BASE_DIR" 58035 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58036 unix_path=`$CYGPATH -u "$windows_path"` 58037 FREETYPE_BASE_DIR="$unix_path" 58038 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58039 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58040 FREETYPE_BASE_DIR="$unix_path" 58041 fi 58042 58043 58044 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 58045 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 58046 METHOD="well-known location" 58047 58048 # Let's start with an optimistic view of the world :-) 58049 FOUND_FREETYPE=yes 58050 58051 # First look for the canonical freetype main include file ft2build.h. 58052 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 58053 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 58054 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 58055 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 58056 # Fail. 58057 FOUND_FREETYPE=no 58058 fi 58059 fi 58060 58061 if test "x$FOUND_FREETYPE" = xyes; then 58062 # Include file found, let's continue the sanity check. 58063 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 58064 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 58065 58066 # Reset to default value 58067 FREETYPE_BASE_NAME=freetype 58068 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 58069 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 58070 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 58071 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 58072 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 58073 # for the .6 version explicitly. 58074 FREETYPE_BASE_NAME=freetype.6 58075 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 58076 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 58077 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 58078 else 58079 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 58080 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 58081 FOUND_FREETYPE=no 58082 fi 58083 else 58084 if test "x$OPENJDK_TARGET_OS" = xwindows; then 58085 # On Windows, we will need both .lib and .dll file. 58086 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 58087 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 58088 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 58089 FOUND_FREETYPE=no 58090 fi 58091 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 58092 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 58093 # Found lib in isa dir, use that instead. 58094 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 58095 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 58096 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 58097 fi 58098 fi 58099 fi 58100 58101 if test "x$FOUND_FREETYPE" = xyes; then 58102 58103 # Only process if variable expands to non-empty 58104 58105 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 58106 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58107 58108 # Input might be given as Windows format, start by converting to 58109 # unix format. 58110 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58111 new_path=`$CYGPATH -u "$path"` 58112 58113 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 58114 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 58115 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 58116 # "foo.exe" is OK but "foo" is an error. 58117 # 58118 # This test is therefore slightly more accurate than "test -f" to check for file precense. 58119 # It is also a way to make sure we got the proper file name for the real test later on. 58120 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 58121 if test "x$test_shortpath" = x; then 58122 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 58123 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 58124 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 58125 fi 58126 58127 # Call helper function which possibly converts this using DOS-style short mode. 58128 # If so, the updated path is stored in $new_path. 58129 58130 input_path="$new_path" 58131 # Check if we need to convert this using DOS-style short mode. If the path 58132 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58133 # take no chances and rewrite it. 58134 # Note: m4 eats our [], so we need to use [ and ] instead. 58135 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 58136 if test "x$has_forbidden_chars" != x; then 58137 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58138 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 58139 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 58140 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 58141 # Going to short mode and back again did indeed matter. Since short mode is 58142 # case insensitive, let's make it lowercase to improve readability. 58143 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58144 # Now convert it back to Unix-style (cygpath) 58145 input_path=`$CYGPATH -u "$shortmode_path"` 58146 new_path="$input_path" 58147 fi 58148 fi 58149 58150 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 58151 if test "x$test_cygdrive_prefix" = x; then 58152 # As a simple fix, exclude /usr/bin since it's not a real path. 58153 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 58154 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 58155 # a path prefixed by /cygdrive for fixpath to work. 58156 new_path="$CYGWIN_ROOT_PATH$input_path" 58157 fi 58158 fi 58159 58160 58161 if test "x$path" != "x$new_path"; then 58162 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 58163 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 58164 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 58165 fi 58166 58167 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58168 58169 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58170 has_colon=`$ECHO $path | $GREP ^.:` 58171 new_path="$path" 58172 if test "x$has_colon" = x; then 58173 # Not in mixed or Windows style, start by that. 58174 new_path=`cmd //c echo $path` 58175 fi 58176 58177 58178 input_path="$new_path" 58179 # Check if we need to convert this using DOS-style short mode. If the path 58180 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58181 # take no chances and rewrite it. 58182 # Note: m4 eats our [], so we need to use [ and ] instead. 58183 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 58184 if test "x$has_forbidden_chars" != x; then 58185 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58186 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58187 fi 58188 58189 58190 windows_path="$new_path" 58191 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58192 unix_path=`$CYGPATH -u "$windows_path"` 58193 new_path="$unix_path" 58194 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58195 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58196 new_path="$unix_path" 58197 fi 58198 58199 if test "x$path" != "x$new_path"; then 58200 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 58201 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 58202 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 58203 fi 58204 58205 # Save the first 10 bytes of this path to the storage, so fixpath can work. 58206 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 58207 58208 else 58209 # We're on a unix platform. Hooray! :) 58210 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58211 has_space=`$ECHO "$path" | $GREP " "` 58212 if test "x$has_space" != x; then 58213 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 58214 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 58215 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 58216 fi 58217 58218 # Use eval to expand a potential ~ 58219 eval path="$path" 58220 if test ! -f "$path" && test ! -d "$path"; then 58221 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 58222 fi 58223 58224 if test -d "$path"; then 58225 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 58226 else 58227 dir="`$DIRNAME "$path"`" 58228 base="`$BASENAME "$path"`" 58229 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 58230 fi 58231 fi 58232 fi 58233 58234 58235 # Only process if variable expands to non-empty 58236 58237 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 58238 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58239 58240 # Input might be given as Windows format, start by converting to 58241 # unix format. 58242 path="$POTENTIAL_FREETYPE_LIB_PATH" 58243 new_path=`$CYGPATH -u "$path"` 58244 58245 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 58246 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 58247 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 58248 # "foo.exe" is OK but "foo" is an error. 58249 # 58250 # This test is therefore slightly more accurate than "test -f" to check for file precense. 58251 # It is also a way to make sure we got the proper file name for the real test later on. 58252 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 58253 if test "x$test_shortpath" = x; then 58254 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 58255 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 58256 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 58257 fi 58258 58259 # Call helper function which possibly converts this using DOS-style short mode. 58260 # If so, the updated path is stored in $new_path. 58261 58262 input_path="$new_path" 58263 # Check if we need to convert this using DOS-style short mode. If the path 58264 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58265 # take no chances and rewrite it. 58266 # Note: m4 eats our [], so we need to use [ and ] instead. 58267 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 58268 if test "x$has_forbidden_chars" != x; then 58269 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58270 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 58271 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 58272 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 58273 # Going to short mode and back again did indeed matter. Since short mode is 58274 # case insensitive, let's make it lowercase to improve readability. 58275 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58276 # Now convert it back to Unix-style (cygpath) 58277 input_path=`$CYGPATH -u "$shortmode_path"` 58278 new_path="$input_path" 58279 fi 58280 fi 58281 58282 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 58283 if test "x$test_cygdrive_prefix" = x; then 58284 # As a simple fix, exclude /usr/bin since it's not a real path. 58285 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 58286 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 58287 # a path prefixed by /cygdrive for fixpath to work. 58288 new_path="$CYGWIN_ROOT_PATH$input_path" 58289 fi 58290 fi 58291 58292 58293 if test "x$path" != "x$new_path"; then 58294 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 58295 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 58296 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 58297 fi 58298 58299 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58300 58301 path="$POTENTIAL_FREETYPE_LIB_PATH" 58302 has_colon=`$ECHO $path | $GREP ^.:` 58303 new_path="$path" 58304 if test "x$has_colon" = x; then 58305 # Not in mixed or Windows style, start by that. 58306 new_path=`cmd //c echo $path` 58307 fi 58308 58309 58310 input_path="$new_path" 58311 # Check if we need to convert this using DOS-style short mode. If the path 58312 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58313 # take no chances and rewrite it. 58314 # Note: m4 eats our [], so we need to use [ and ] instead. 58315 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 58316 if test "x$has_forbidden_chars" != x; then 58317 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58318 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58319 fi 58320 58321 58322 windows_path="$new_path" 58323 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58324 unix_path=`$CYGPATH -u "$windows_path"` 58325 new_path="$unix_path" 58326 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58327 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58328 new_path="$unix_path" 58329 fi 58330 58331 if test "x$path" != "x$new_path"; then 58332 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 58333 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 58334 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 58335 fi 58336 58337 # Save the first 10 bytes of this path to the storage, so fixpath can work. 58338 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 58339 58340 else 58341 # We're on a unix platform. Hooray! :) 58342 path="$POTENTIAL_FREETYPE_LIB_PATH" 58343 has_space=`$ECHO "$path" | $GREP " "` 58344 if test "x$has_space" != x; then 58345 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 58346 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 58347 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 58348 fi 58349 58350 # Use eval to expand a potential ~ 58351 eval path="$path" 58352 if test ! -f "$path" && test ! -d "$path"; then 58353 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 58354 fi 58355 58356 if test -d "$path"; then 58357 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 58358 else 58359 dir="`$DIRNAME "$path"`" 58360 base="`$BASENAME "$path"`" 58361 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 58362 fi 58363 fi 58364 fi 58365 58366 58367 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58368 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 58369 $as_echo_n "checking for freetype includes... " >&6; } 58370 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 58371 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 58372 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 58373 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 58374 $as_echo_n "checking for freetype libraries... " >&6; } 58375 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 58376 $as_echo "$FREETYPE_LIB_PATH" >&6; } 58377 fi 58378 58379 if test "x$FOUND_FREETYPE" != xyes; then 58380 FREETYPE_BASE_DIR="$ProgramW6432/GnuWin32" 58381 58382 windows_path="$FREETYPE_BASE_DIR" 58383 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58384 unix_path=`$CYGPATH -u "$windows_path"` 58385 FREETYPE_BASE_DIR="$unix_path" 58386 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58387 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58388 FREETYPE_BASE_DIR="$unix_path" 58389 fi 58390 58391 58392 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 58393 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 58394 METHOD="well-known location" 58395 58396 # Let's start with an optimistic view of the world :-) 58397 FOUND_FREETYPE=yes 58398 58399 # First look for the canonical freetype main include file ft2build.h. 58400 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 58401 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 58402 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 58403 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 58404 # Fail. 58405 FOUND_FREETYPE=no 58406 fi 58407 fi 58408 58409 if test "x$FOUND_FREETYPE" = xyes; then 58410 # Include file found, let's continue the sanity check. 58411 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 58412 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 58413 58414 # Reset to default value 58415 FREETYPE_BASE_NAME=freetype 58416 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 58417 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 58418 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 58419 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 58420 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 58421 # for the .6 version explicitly. 58422 FREETYPE_BASE_NAME=freetype.6 58423 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 58424 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 58425 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 58426 else 58427 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 58428 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 58429 FOUND_FREETYPE=no 58430 fi 58431 else 58432 if test "x$OPENJDK_TARGET_OS" = xwindows; then 58433 # On Windows, we will need both .lib and .dll file. 58434 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 58435 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 58436 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 58437 FOUND_FREETYPE=no 58438 fi 58439 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 58440 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 58441 # Found lib in isa dir, use that instead. 58442 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 58443 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 58444 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 58445 fi 58446 fi 58447 fi 58448 58449 if test "x$FOUND_FREETYPE" = xyes; then 58450 58451 # Only process if variable expands to non-empty 58452 58453 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 58454 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58455 58456 # Input might be given as Windows format, start by converting to 58457 # unix format. 58458 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58459 new_path=`$CYGPATH -u "$path"` 58460 58461 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 58462 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 58463 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 58464 # "foo.exe" is OK but "foo" is an error. 58465 # 58466 # This test is therefore slightly more accurate than "test -f" to check for file precense. 58467 # It is also a way to make sure we got the proper file name for the real test later on. 58468 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 58469 if test "x$test_shortpath" = x; then 58470 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 58471 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 58472 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 58473 fi 58474 58475 # Call helper function which possibly converts this using DOS-style short mode. 58476 # If so, the updated path is stored in $new_path. 58477 58478 input_path="$new_path" 58479 # Check if we need to convert this using DOS-style short mode. If the path 58480 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58481 # take no chances and rewrite it. 58482 # Note: m4 eats our [], so we need to use [ and ] instead. 58483 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 58484 if test "x$has_forbidden_chars" != x; then 58485 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58486 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 58487 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 58488 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 58489 # Going to short mode and back again did indeed matter. Since short mode is 58490 # case insensitive, let's make it lowercase to improve readability. 58491 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58492 # Now convert it back to Unix-style (cygpath) 58493 input_path=`$CYGPATH -u "$shortmode_path"` 58494 new_path="$input_path" 58495 fi 58496 fi 58497 58498 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 58499 if test "x$test_cygdrive_prefix" = x; then 58500 # As a simple fix, exclude /usr/bin since it's not a real path. 58501 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 58502 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 58503 # a path prefixed by /cygdrive for fixpath to work. 58504 new_path="$CYGWIN_ROOT_PATH$input_path" 58505 fi 58506 fi 58507 58508 58509 if test "x$path" != "x$new_path"; then 58510 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 58511 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 58512 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 58513 fi 58514 58515 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58516 58517 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58518 has_colon=`$ECHO $path | $GREP ^.:` 58519 new_path="$path" 58520 if test "x$has_colon" = x; then 58521 # Not in mixed or Windows style, start by that. 58522 new_path=`cmd //c echo $path` 58523 fi 58524 58525 58526 input_path="$new_path" 58527 # Check if we need to convert this using DOS-style short mode. If the path 58528 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58529 # take no chances and rewrite it. 58530 # Note: m4 eats our [], so we need to use [ and ] instead. 58531 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 58532 if test "x$has_forbidden_chars" != x; then 58533 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58534 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58535 fi 58536 58537 58538 windows_path="$new_path" 58539 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58540 unix_path=`$CYGPATH -u "$windows_path"` 58541 new_path="$unix_path" 58542 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58543 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58544 new_path="$unix_path" 58545 fi 58546 58547 if test "x$path" != "x$new_path"; then 58548 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 58549 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 58550 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 58551 fi 58552 58553 # Save the first 10 bytes of this path to the storage, so fixpath can work. 58554 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 58555 58556 else 58557 # We're on a unix platform. Hooray! :) 58558 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58559 has_space=`$ECHO "$path" | $GREP " "` 58560 if test "x$has_space" != x; then 58561 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 58562 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 58563 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 58564 fi 58565 58566 # Use eval to expand a potential ~ 58567 eval path="$path" 58568 if test ! -f "$path" && test ! -d "$path"; then 58569 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 58570 fi 58571 58572 if test -d "$path"; then 58573 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 58574 else 58575 dir="`$DIRNAME "$path"`" 58576 base="`$BASENAME "$path"`" 58577 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 58578 fi 58579 fi 58580 fi 58581 58582 58583 # Only process if variable expands to non-empty 58584 58585 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 58586 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58587 58588 # Input might be given as Windows format, start by converting to 58589 # unix format. 58590 path="$POTENTIAL_FREETYPE_LIB_PATH" 58591 new_path=`$CYGPATH -u "$path"` 58592 58593 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 58594 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 58595 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 58596 # "foo.exe" is OK but "foo" is an error. 58597 # 58598 # This test is therefore slightly more accurate than "test -f" to check for file precense. 58599 # It is also a way to make sure we got the proper file name for the real test later on. 58600 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 58601 if test "x$test_shortpath" = x; then 58602 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 58603 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 58604 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 58605 fi 58606 58607 # Call helper function which possibly converts this using DOS-style short mode. 58608 # If so, the updated path is stored in $new_path. 58609 58610 input_path="$new_path" 58611 # Check if we need to convert this using DOS-style short mode. If the path 58612 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58613 # take no chances and rewrite it. 58614 # Note: m4 eats our [], so we need to use [ and ] instead. 58615 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 58616 if test "x$has_forbidden_chars" != x; then 58617 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58618 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 58619 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 58620 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 58621 # Going to short mode and back again did indeed matter. Since short mode is 58622 # case insensitive, let's make it lowercase to improve readability. 58623 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58624 # Now convert it back to Unix-style (cygpath) 58625 input_path=`$CYGPATH -u "$shortmode_path"` 58626 new_path="$input_path" 58627 fi 58628 fi 58629 58630 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 58631 if test "x$test_cygdrive_prefix" = x; then 58632 # As a simple fix, exclude /usr/bin since it's not a real path. 58633 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 58634 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 58635 # a path prefixed by /cygdrive for fixpath to work. 58636 new_path="$CYGWIN_ROOT_PATH$input_path" 58637 fi 58638 fi 58639 58640 58641 if test "x$path" != "x$new_path"; then 58642 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 58643 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 58644 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 58645 fi 58646 58647 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58648 58649 path="$POTENTIAL_FREETYPE_LIB_PATH" 58650 has_colon=`$ECHO $path | $GREP ^.:` 58651 new_path="$path" 58652 if test "x$has_colon" = x; then 58653 # Not in mixed or Windows style, start by that. 58654 new_path=`cmd //c echo $path` 58655 fi 58656 58657 58658 input_path="$new_path" 58659 # Check if we need to convert this using DOS-style short mode. If the path 58660 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58661 # take no chances and rewrite it. 58662 # Note: m4 eats our [], so we need to use [ and ] instead. 58663 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 58664 if test "x$has_forbidden_chars" != x; then 58665 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58666 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58667 fi 58668 58669 58670 windows_path="$new_path" 58671 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58672 unix_path=`$CYGPATH -u "$windows_path"` 58673 new_path="$unix_path" 58674 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58675 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58676 new_path="$unix_path" 58677 fi 58678 58679 if test "x$path" != "x$new_path"; then 58680 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 58681 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 58682 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 58683 fi 58684 58685 # Save the first 10 bytes of this path to the storage, so fixpath can work. 58686 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 58687 58688 else 58689 # We're on a unix platform. Hooray! :) 58690 path="$POTENTIAL_FREETYPE_LIB_PATH" 58691 has_space=`$ECHO "$path" | $GREP " "` 58692 if test "x$has_space" != x; then 58693 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 58694 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 58695 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 58696 fi 58697 58698 # Use eval to expand a potential ~ 58699 eval path="$path" 58700 if test ! -f "$path" && test ! -d "$path"; then 58701 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 58702 fi 58703 58704 if test -d "$path"; then 58705 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 58706 else 58707 dir="`$DIRNAME "$path"`" 58708 base="`$BASENAME "$path"`" 58709 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 58710 fi 58711 fi 58712 fi 58713 58714 58715 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58716 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 58717 $as_echo_n "checking for freetype includes... " >&6; } 58718 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 58719 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 58720 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 58721 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 58722 $as_echo_n "checking for freetype libraries... " >&6; } 58723 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 58724 $as_echo "$FREETYPE_LIB_PATH" >&6; } 58725 fi 58726 58727 fi 58728 if test "x$FOUND_FREETYPE" != xyes; then 58729 FREETYPE_BASE_DIR="$HOME/freetype" 58730 58731 windows_path="$FREETYPE_BASE_DIR" 58732 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58733 unix_path=`$CYGPATH -u "$windows_path"` 58734 FREETYPE_BASE_DIR="$unix_path" 58735 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58736 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58737 FREETYPE_BASE_DIR="$unix_path" 58738 fi 58739 58740 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 58741 58742 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 58743 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib64" 58744 METHOD="well-known location" 58745 58746 # Let's start with an optimistic view of the world :-) 58747 FOUND_FREETYPE=yes 58748 58749 # First look for the canonical freetype main include file ft2build.h. 58750 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 58751 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 58752 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 58753 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 58754 # Fail. 58755 FOUND_FREETYPE=no 58756 fi 58757 fi 58758 58759 if test "x$FOUND_FREETYPE" = xyes; then 58760 # Include file found, let's continue the sanity check. 58761 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 58762 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 58763 58764 # Reset to default value 58765 FREETYPE_BASE_NAME=freetype 58766 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 58767 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 58768 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 58769 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 58770 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 58771 # for the .6 version explicitly. 58772 FREETYPE_BASE_NAME=freetype.6 58773 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 58774 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 58775 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 58776 else 58777 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 58778 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 58779 FOUND_FREETYPE=no 58780 fi 58781 else 58782 if test "x$OPENJDK_TARGET_OS" = xwindows; then 58783 # On Windows, we will need both .lib and .dll file. 58784 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 58785 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 58786 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 58787 FOUND_FREETYPE=no 58788 fi 58789 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 58790 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 58791 # Found lib in isa dir, use that instead. 58792 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 58793 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 58794 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 58795 fi 58796 fi 58797 fi 58798 58799 if test "x$FOUND_FREETYPE" = xyes; then 58800 58801 # Only process if variable expands to non-empty 58802 58803 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 58804 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58805 58806 # Input might be given as Windows format, start by converting to 58807 # unix format. 58808 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58809 new_path=`$CYGPATH -u "$path"` 58810 58811 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 58812 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 58813 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 58814 # "foo.exe" is OK but "foo" is an error. 58815 # 58816 # This test is therefore slightly more accurate than "test -f" to check for file precense. 58817 # It is also a way to make sure we got the proper file name for the real test later on. 58818 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 58819 if test "x$test_shortpath" = x; then 58820 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 58821 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 58822 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 58823 fi 58824 58825 # Call helper function which possibly converts this using DOS-style short mode. 58826 # If so, the updated path is stored in $new_path. 58827 58828 input_path="$new_path" 58829 # Check if we need to convert this using DOS-style short mode. If the path 58830 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58831 # take no chances and rewrite it. 58832 # Note: m4 eats our [], so we need to use [ and ] instead. 58833 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 58834 if test "x$has_forbidden_chars" != x; then 58835 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58836 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 58837 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 58838 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 58839 # Going to short mode and back again did indeed matter. Since short mode is 58840 # case insensitive, let's make it lowercase to improve readability. 58841 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58842 # Now convert it back to Unix-style (cygpath) 58843 input_path=`$CYGPATH -u "$shortmode_path"` 58844 new_path="$input_path" 58845 fi 58846 fi 58847 58848 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 58849 if test "x$test_cygdrive_prefix" = x; then 58850 # As a simple fix, exclude /usr/bin since it's not a real path. 58851 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 58852 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 58853 # a path prefixed by /cygdrive for fixpath to work. 58854 new_path="$CYGWIN_ROOT_PATH$input_path" 58855 fi 58856 fi 58857 58858 58859 if test "x$path" != "x$new_path"; then 58860 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 58861 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 58862 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 58863 fi 58864 58865 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58866 58867 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58868 has_colon=`$ECHO $path | $GREP ^.:` 58869 new_path="$path" 58870 if test "x$has_colon" = x; then 58871 # Not in mixed or Windows style, start by that. 58872 new_path=`cmd //c echo $path` 58873 fi 58874 58875 58876 input_path="$new_path" 58877 # Check if we need to convert this using DOS-style short mode. If the path 58878 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58879 # take no chances and rewrite it. 58880 # Note: m4 eats our [], so we need to use [ and ] instead. 58881 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 58882 if test "x$has_forbidden_chars" != x; then 58883 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58884 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58885 fi 58886 58887 58888 windows_path="$new_path" 58889 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58890 unix_path=`$CYGPATH -u "$windows_path"` 58891 new_path="$unix_path" 58892 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58893 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58894 new_path="$unix_path" 58895 fi 58896 58897 if test "x$path" != "x$new_path"; then 58898 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 58899 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 58900 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 58901 fi 58902 58903 # Save the first 10 bytes of this path to the storage, so fixpath can work. 58904 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 58905 58906 else 58907 # We're on a unix platform. Hooray! :) 58908 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58909 has_space=`$ECHO "$path" | $GREP " "` 58910 if test "x$has_space" != x; then 58911 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 58912 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 58913 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 58914 fi 58915 58916 # Use eval to expand a potential ~ 58917 eval path="$path" 58918 if test ! -f "$path" && test ! -d "$path"; then 58919 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 58920 fi 58921 58922 if test -d "$path"; then 58923 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 58924 else 58925 dir="`$DIRNAME "$path"`" 58926 base="`$BASENAME "$path"`" 58927 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 58928 fi 58929 fi 58930 fi 58931 58932 58933 # Only process if variable expands to non-empty 58934 58935 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 58936 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58937 58938 # Input might be given as Windows format, start by converting to 58939 # unix format. 58940 path="$POTENTIAL_FREETYPE_LIB_PATH" 58941 new_path=`$CYGPATH -u "$path"` 58942 58943 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 58944 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 58945 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 58946 # "foo.exe" is OK but "foo" is an error. 58947 # 58948 # This test is therefore slightly more accurate than "test -f" to check for file precense. 58949 # It is also a way to make sure we got the proper file name for the real test later on. 58950 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 58951 if test "x$test_shortpath" = x; then 58952 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 58953 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 58954 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 58955 fi 58956 58957 # Call helper function which possibly converts this using DOS-style short mode. 58958 # If so, the updated path is stored in $new_path. 58959 58960 input_path="$new_path" 58961 # Check if we need to convert this using DOS-style short mode. If the path 58962 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58963 # take no chances and rewrite it. 58964 # Note: m4 eats our [], so we need to use [ and ] instead. 58965 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 58966 if test "x$has_forbidden_chars" != x; then 58967 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58968 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 58969 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 58970 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 58971 # Going to short mode and back again did indeed matter. Since short mode is 58972 # case insensitive, let's make it lowercase to improve readability. 58973 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58974 # Now convert it back to Unix-style (cygpath) 58975 input_path=`$CYGPATH -u "$shortmode_path"` 58976 new_path="$input_path" 58977 fi 58978 fi 58979 58980 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 58981 if test "x$test_cygdrive_prefix" = x; then 58982 # As a simple fix, exclude /usr/bin since it's not a real path. 58983 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 58984 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 58985 # a path prefixed by /cygdrive for fixpath to work. 58986 new_path="$CYGWIN_ROOT_PATH$input_path" 58987 fi 58988 fi 58989 58990 58991 if test "x$path" != "x$new_path"; then 58992 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 58993 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 58994 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 58995 fi 58996 58997 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58998 58999 path="$POTENTIAL_FREETYPE_LIB_PATH" 59000 has_colon=`$ECHO $path | $GREP ^.:` 59001 new_path="$path" 59002 if test "x$has_colon" = x; then 59003 # Not in mixed or Windows style, start by that. 59004 new_path=`cmd //c echo $path` 59005 fi 59006 59007 59008 input_path="$new_path" 59009 # Check if we need to convert this using DOS-style short mode. If the path 59010 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59011 # take no chances and rewrite it. 59012 # Note: m4 eats our [], so we need to use [ and ] instead. 59013 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 59014 if test "x$has_forbidden_chars" != x; then 59015 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59016 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59017 fi 59018 59019 59020 windows_path="$new_path" 59021 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59022 unix_path=`$CYGPATH -u "$windows_path"` 59023 new_path="$unix_path" 59024 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59025 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59026 new_path="$unix_path" 59027 fi 59028 59029 if test "x$path" != "x$new_path"; then 59030 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 59031 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 59032 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 59033 fi 59034 59035 # Save the first 10 bytes of this path to the storage, so fixpath can work. 59036 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 59037 59038 else 59039 # We're on a unix platform. Hooray! :) 59040 path="$POTENTIAL_FREETYPE_LIB_PATH" 59041 has_space=`$ECHO "$path" | $GREP " "` 59042 if test "x$has_space" != x; then 59043 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 59044 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 59045 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 59046 fi 59047 59048 # Use eval to expand a potential ~ 59049 eval path="$path" 59050 if test ! -f "$path" && test ! -d "$path"; then 59051 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 59052 fi 59053 59054 if test -d "$path"; then 59055 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 59056 else 59057 dir="`$DIRNAME "$path"`" 59058 base="`$BASENAME "$path"`" 59059 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 59060 fi 59061 fi 59062 fi 59063 59064 59065 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59066 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 59067 $as_echo_n "checking for freetype includes... " >&6; } 59068 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 59069 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 59070 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 59071 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 59072 $as_echo_n "checking for freetype libraries... " >&6; } 59073 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 59074 $as_echo "$FREETYPE_LIB_PATH" >&6; } 59075 fi 59076 59077 else 59078 59079 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 59080 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib32" 59081 METHOD="well-known location" 59082 59083 # Let's start with an optimistic view of the world :-) 59084 FOUND_FREETYPE=yes 59085 59086 # First look for the canonical freetype main include file ft2build.h. 59087 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59088 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 59089 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 59090 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59091 # Fail. 59092 FOUND_FREETYPE=no 59093 fi 59094 fi 59095 59096 if test "x$FOUND_FREETYPE" = xyes; then 59097 # Include file found, let's continue the sanity check. 59098 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 59099 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 59100 59101 # Reset to default value 59102 FREETYPE_BASE_NAME=freetype 59103 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59104 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 59105 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 59106 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 59107 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 59108 # for the .6 version explicitly. 59109 FREETYPE_BASE_NAME=freetype.6 59110 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59111 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 59112 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 59113 else 59114 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 59115 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 59116 FOUND_FREETYPE=no 59117 fi 59118 else 59119 if test "x$OPENJDK_TARGET_OS" = xwindows; then 59120 # On Windows, we will need both .lib and .dll file. 59121 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 59122 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 59123 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 59124 FOUND_FREETYPE=no 59125 fi 59126 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 59127 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 59128 # Found lib in isa dir, use that instead. 59129 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 59130 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 59131 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 59132 fi 59133 fi 59134 fi 59135 59136 if test "x$FOUND_FREETYPE" = xyes; then 59137 59138 # Only process if variable expands to non-empty 59139 59140 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 59141 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59142 59143 # Input might be given as Windows format, start by converting to 59144 # unix format. 59145 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59146 new_path=`$CYGPATH -u "$path"` 59147 59148 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 59149 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 59150 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 59151 # "foo.exe" is OK but "foo" is an error. 59152 # 59153 # This test is therefore slightly more accurate than "test -f" to check for file precense. 59154 # It is also a way to make sure we got the proper file name for the real test later on. 59155 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 59156 if test "x$test_shortpath" = x; then 59157 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 59158 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 59159 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 59160 fi 59161 59162 # Call helper function which possibly converts this using DOS-style short mode. 59163 # If so, the updated path is stored in $new_path. 59164 59165 input_path="$new_path" 59166 # Check if we need to convert this using DOS-style short mode. If the path 59167 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59168 # take no chances and rewrite it. 59169 # Note: m4 eats our [], so we need to use [ and ] instead. 59170 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 59171 if test "x$has_forbidden_chars" != x; then 59172 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59173 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 59174 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 59175 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 59176 # Going to short mode and back again did indeed matter. Since short mode is 59177 # case insensitive, let's make it lowercase to improve readability. 59178 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59179 # Now convert it back to Unix-style (cygpath) 59180 input_path=`$CYGPATH -u "$shortmode_path"` 59181 new_path="$input_path" 59182 fi 59183 fi 59184 59185 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 59186 if test "x$test_cygdrive_prefix" = x; then 59187 # As a simple fix, exclude /usr/bin since it's not a real path. 59188 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 59189 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 59190 # a path prefixed by /cygdrive for fixpath to work. 59191 new_path="$CYGWIN_ROOT_PATH$input_path" 59192 fi 59193 fi 59194 59195 59196 if test "x$path" != "x$new_path"; then 59197 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 59198 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 59199 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 59200 fi 59201 59202 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59203 59204 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59205 has_colon=`$ECHO $path | $GREP ^.:` 59206 new_path="$path" 59207 if test "x$has_colon" = x; then 59208 # Not in mixed or Windows style, start by that. 59209 new_path=`cmd //c echo $path` 59210 fi 59211 59212 59213 input_path="$new_path" 59214 # Check if we need to convert this using DOS-style short mode. If the path 59215 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59216 # take no chances and rewrite it. 59217 # Note: m4 eats our [], so we need to use [ and ] instead. 59218 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 59219 if test "x$has_forbidden_chars" != x; then 59220 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59221 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59222 fi 59223 59224 59225 windows_path="$new_path" 59226 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59227 unix_path=`$CYGPATH -u "$windows_path"` 59228 new_path="$unix_path" 59229 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59230 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59231 new_path="$unix_path" 59232 fi 59233 59234 if test "x$path" != "x$new_path"; then 59235 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 59236 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 59237 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 59238 fi 59239 59240 # Save the first 10 bytes of this path to the storage, so fixpath can work. 59241 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 59242 59243 else 59244 # We're on a unix platform. Hooray! :) 59245 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59246 has_space=`$ECHO "$path" | $GREP " "` 59247 if test "x$has_space" != x; then 59248 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 59249 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 59250 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 59251 fi 59252 59253 # Use eval to expand a potential ~ 59254 eval path="$path" 59255 if test ! -f "$path" && test ! -d "$path"; then 59256 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 59257 fi 59258 59259 if test -d "$path"; then 59260 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 59261 else 59262 dir="`$DIRNAME "$path"`" 59263 base="`$BASENAME "$path"`" 59264 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 59265 fi 59266 fi 59267 fi 59268 59269 59270 # Only process if variable expands to non-empty 59271 59272 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 59273 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59274 59275 # Input might be given as Windows format, start by converting to 59276 # unix format. 59277 path="$POTENTIAL_FREETYPE_LIB_PATH" 59278 new_path=`$CYGPATH -u "$path"` 59279 59280 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 59281 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 59282 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 59283 # "foo.exe" is OK but "foo" is an error. 59284 # 59285 # This test is therefore slightly more accurate than "test -f" to check for file precense. 59286 # It is also a way to make sure we got the proper file name for the real test later on. 59287 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 59288 if test "x$test_shortpath" = x; then 59289 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 59290 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 59291 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 59292 fi 59293 59294 # Call helper function which possibly converts this using DOS-style short mode. 59295 # If so, the updated path is stored in $new_path. 59296 59297 input_path="$new_path" 59298 # Check if we need to convert this using DOS-style short mode. If the path 59299 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59300 # take no chances and rewrite it. 59301 # Note: m4 eats our [], so we need to use [ and ] instead. 59302 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 59303 if test "x$has_forbidden_chars" != x; then 59304 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59305 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 59306 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 59307 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 59308 # Going to short mode and back again did indeed matter. Since short mode is 59309 # case insensitive, let's make it lowercase to improve readability. 59310 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59311 # Now convert it back to Unix-style (cygpath) 59312 input_path=`$CYGPATH -u "$shortmode_path"` 59313 new_path="$input_path" 59314 fi 59315 fi 59316 59317 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 59318 if test "x$test_cygdrive_prefix" = x; then 59319 # As a simple fix, exclude /usr/bin since it's not a real path. 59320 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 59321 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 59322 # a path prefixed by /cygdrive for fixpath to work. 59323 new_path="$CYGWIN_ROOT_PATH$input_path" 59324 fi 59325 fi 59326 59327 59328 if test "x$path" != "x$new_path"; then 59329 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 59330 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 59331 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 59332 fi 59333 59334 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59335 59336 path="$POTENTIAL_FREETYPE_LIB_PATH" 59337 has_colon=`$ECHO $path | $GREP ^.:` 59338 new_path="$path" 59339 if test "x$has_colon" = x; then 59340 # Not in mixed or Windows style, start by that. 59341 new_path=`cmd //c echo $path` 59342 fi 59343 59344 59345 input_path="$new_path" 59346 # Check if we need to convert this using DOS-style short mode. If the path 59347 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59348 # take no chances and rewrite it. 59349 # Note: m4 eats our [], so we need to use [ and ] instead. 59350 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 59351 if test "x$has_forbidden_chars" != x; then 59352 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59353 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59354 fi 59355 59356 59357 windows_path="$new_path" 59358 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59359 unix_path=`$CYGPATH -u "$windows_path"` 59360 new_path="$unix_path" 59361 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59362 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59363 new_path="$unix_path" 59364 fi 59365 59366 if test "x$path" != "x$new_path"; then 59367 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 59368 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 59369 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 59370 fi 59371 59372 # Save the first 10 bytes of this path to the storage, so fixpath can work. 59373 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 59374 59375 else 59376 # We're on a unix platform. Hooray! :) 59377 path="$POTENTIAL_FREETYPE_LIB_PATH" 59378 has_space=`$ECHO "$path" | $GREP " "` 59379 if test "x$has_space" != x; then 59380 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 59381 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 59382 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 59383 fi 59384 59385 # Use eval to expand a potential ~ 59386 eval path="$path" 59387 if test ! -f "$path" && test ! -d "$path"; then 59388 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 59389 fi 59390 59391 if test -d "$path"; then 59392 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 59393 else 59394 dir="`$DIRNAME "$path"`" 59395 base="`$BASENAME "$path"`" 59396 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 59397 fi 59398 fi 59399 fi 59400 59401 59402 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59403 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 59404 $as_echo_n "checking for freetype includes... " >&6; } 59405 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 59406 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 59407 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 59408 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 59409 $as_echo_n "checking for freetype libraries... " >&6; } 59410 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 59411 $as_echo "$FREETYPE_LIB_PATH" >&6; } 59412 fi 59413 59414 fi 59415 if test "x$FOUND_FREETYPE" != xyes && test -d $FREETYPE_BASE_DIR \ 59416 && test -s "$FREETYPE_BASE_DIR/builds/windows/vc2010/freetype.vcxproj" && test "x$MSBUILD" != x; then 59417 # Source is available, as a last resort try to build freetype in default location 59418 59419 FREETYPE_SRC_PATH="$FREETYPE_BASE_DIR" 59420 BUILD_FREETYPE=yes 59421 59422 # Check if the freetype sources are acessible.. 59423 if ! test -d $FREETYPE_SRC_PATH; then 59424 { $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 59425 $as_echo "$as_me: WARNING: --with-freetype-src specified, but can not find path \"$FREETYPE_SRC_PATH\" - ignoring --with-freetype-src" >&2;} 59426 BUILD_FREETYPE=no 59427 fi 59428 # ..and contain a vc2010 project file 59429 vcxproj_path="$FREETYPE_SRC_PATH/builds/windows/vc2010/freetype.vcxproj" 59430 if test "x$BUILD_FREETYPE" = xyes && ! test -s $vcxproj_path; then 59431 { $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 59432 $as_echo "$as_me: WARNING: Can not find project file $vcxproj_path (you may try a newer freetype version) - ignoring --with-freetype-src" >&2;} 59433 BUILD_FREETYPE=no 59434 fi 59435 # Now check if configure found a version of 'msbuild.exe' 59436 if test "x$BUILD_FREETYPE" = xyes && test "x$MSBUILD" == x ; then 59437 { $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 59438 $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;} 59439 BUILD_FREETYPE=no 59440 fi 59441 59442 # Ready to go.. 59443 if test "x$BUILD_FREETYPE" = xyes; then 59444 # msbuild requires trailing slashes for output directories 59445 freetype_lib_path="$FREETYPE_SRC_PATH/lib$OPENJDK_TARGET_CPU_BITS/" 59446 freetype_lib_path_unix="$freetype_lib_path" 59447 freetype_obj_path="$FREETYPE_SRC_PATH/obj$OPENJDK_TARGET_CPU_BITS/" 59448 59449 unix_path="$vcxproj_path" 59450 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59451 windows_path=`$CYGPATH -m "$unix_path"` 59452 vcxproj_path="$windows_path" 59453 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59454 windows_path=`cmd //c echo $unix_path` 59455 vcxproj_path="$windows_path" 59456 fi 59457 59458 59459 unix_path="$freetype_lib_path" 59460 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59461 windows_path=`$CYGPATH -m "$unix_path"` 59462 freetype_lib_path="$windows_path" 59463 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59464 windows_path=`cmd //c echo $unix_path` 59465 freetype_lib_path="$windows_path" 59466 fi 59467 59468 59469 unix_path="$freetype_obj_path" 59470 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59471 windows_path=`$CYGPATH -m "$unix_path"` 59472 freetype_obj_path="$windows_path" 59473 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59474 windows_path=`cmd //c echo $unix_path` 59475 freetype_obj_path="$windows_path" 59476 fi 59477 59478 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 59479 freetype_platform=x64 59480 else 59481 freetype_platform=win32 59482 fi 59483 59484 # The original freetype project file is for VS 2010 (i.e. 'v100'), 59485 # so we have to adapt the toolset if building with any other toolsed (i.e. SDK). 59486 # Currently 'PLATFORM_TOOLSET' is set in 'TOOLCHAIN_CHECK_POSSIBLE_VISUAL_STUDIO_ROOT'/ 59487 # 'TOOLCHAIN_CHECK_POSSIBLE_WIN_SDK_ROOT' in toolchain_windows.m4 59488 { $as_echo "$as_me:${as_lineno-$LINENO}: Trying to compile freetype sources with PlatformToolset=$PLATFORM_TOOLSET to $freetype_lib_path_unix ..." >&5 59489 $as_echo "$as_me: Trying to compile freetype sources with PlatformToolset=$PLATFORM_TOOLSET to $freetype_lib_path_unix ..." >&6;} 59490 59491 # First we try to build the freetype.dll 59492 $ECHO -e "@echo off\n"\ 59493 "$MSBUILD $vcxproj_path "\ 59494 "/p:PlatformToolset=$PLATFORM_TOOLSET "\ 59495 "/p:Configuration=\"Release Multithreaded\" "\ 59496 "/p:Platform=$freetype_platform "\ 59497 "/p:ConfigurationType=DynamicLibrary "\ 59498 "/p:TargetName=freetype "\ 59499 "/p:OutDir=\"$freetype_lib_path\" "\ 59500 "/p:IntDir=\"$freetype_obj_path\" > freetype.log" > freetype.bat 59501 cmd /c freetype.bat 59502 59503 if test -s "$freetype_lib_path_unix/freetype.dll"; then 59504 # If that succeeds we also build freetype.lib 59505 $ECHO -e "@echo off\n"\ 59506 "$MSBUILD $vcxproj_path "\ 59507 "/p:PlatformToolset=$PLATFORM_TOOLSET "\ 59508 "/p:Configuration=\"Release Multithreaded\" "\ 59509 "/p:Platform=$freetype_platform "\ 59510 "/p:ConfigurationType=StaticLibrary "\ 59511 "/p:TargetName=freetype "\ 59512 "/p:OutDir=\"$freetype_lib_path\" "\ 59513 "/p:IntDir=\"$freetype_obj_path\" >> freetype.log" > freetype.bat 59514 cmd /c freetype.bat 59515 59516 if test -s "$freetype_lib_path_unix/freetype.lib"; then 59517 # Once we build both, lib and dll, set freetype lib and include path appropriately 59518 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_SRC_PATH/include" 59519 POTENTIAL_FREETYPE_LIB_PATH="$freetype_lib_path_unix" 59520 { $as_echo "$as_me:${as_lineno-$LINENO}: Compiling freetype sources succeeded! (see freetype.log for build results)" >&5 59521 $as_echo "$as_me: Compiling freetype sources succeeded! (see freetype.log for build results)" >&6;} 59522 else 59523 BUILD_FREETYPE=no 59524 fi 59525 else 59526 BUILD_FREETYPE=no 59527 fi 59528 fi 59529 59530 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 59531 59532 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 59533 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib64" 59534 METHOD="well-known location" 59535 59536 # Let's start with an optimistic view of the world :-) 59537 FOUND_FREETYPE=yes 59538 59539 # First look for the canonical freetype main include file ft2build.h. 59540 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59541 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 59542 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 59543 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59544 # Fail. 59545 FOUND_FREETYPE=no 59546 fi 59547 fi 59548 59549 if test "x$FOUND_FREETYPE" = xyes; then 59550 # Include file found, let's continue the sanity check. 59551 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 59552 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 59553 59554 # Reset to default value 59555 FREETYPE_BASE_NAME=freetype 59556 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59557 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 59558 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 59559 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 59560 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 59561 # for the .6 version explicitly. 59562 FREETYPE_BASE_NAME=freetype.6 59563 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59564 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 59565 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 59566 else 59567 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 59568 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 59569 FOUND_FREETYPE=no 59570 fi 59571 else 59572 if test "x$OPENJDK_TARGET_OS" = xwindows; then 59573 # On Windows, we will need both .lib and .dll file. 59574 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 59575 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 59576 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 59577 FOUND_FREETYPE=no 59578 fi 59579 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 59580 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 59581 # Found lib in isa dir, use that instead. 59582 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 59583 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 59584 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 59585 fi 59586 fi 59587 fi 59588 59589 if test "x$FOUND_FREETYPE" = xyes; then 59590 59591 # Only process if variable expands to non-empty 59592 59593 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 59594 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59595 59596 # Input might be given as Windows format, start by converting to 59597 # unix format. 59598 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59599 new_path=`$CYGPATH -u "$path"` 59600 59601 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 59602 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 59603 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 59604 # "foo.exe" is OK but "foo" is an error. 59605 # 59606 # This test is therefore slightly more accurate than "test -f" to check for file precense. 59607 # It is also a way to make sure we got the proper file name for the real test later on. 59608 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 59609 if test "x$test_shortpath" = x; then 59610 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 59611 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 59612 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 59613 fi 59614 59615 # Call helper function which possibly converts this using DOS-style short mode. 59616 # If so, the updated path is stored in $new_path. 59617 59618 input_path="$new_path" 59619 # Check if we need to convert this using DOS-style short mode. If the path 59620 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59621 # take no chances and rewrite it. 59622 # Note: m4 eats our [], so we need to use [ and ] instead. 59623 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 59624 if test "x$has_forbidden_chars" != x; then 59625 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59626 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 59627 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 59628 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 59629 # Going to short mode and back again did indeed matter. Since short mode is 59630 # case insensitive, let's make it lowercase to improve readability. 59631 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59632 # Now convert it back to Unix-style (cygpath) 59633 input_path=`$CYGPATH -u "$shortmode_path"` 59634 new_path="$input_path" 59635 fi 59636 fi 59637 59638 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 59639 if test "x$test_cygdrive_prefix" = x; then 59640 # As a simple fix, exclude /usr/bin since it's not a real path. 59641 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 59642 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 59643 # a path prefixed by /cygdrive for fixpath to work. 59644 new_path="$CYGWIN_ROOT_PATH$input_path" 59645 fi 59646 fi 59647 59648 59649 if test "x$path" != "x$new_path"; then 59650 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 59651 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 59652 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 59653 fi 59654 59655 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59656 59657 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59658 has_colon=`$ECHO $path | $GREP ^.:` 59659 new_path="$path" 59660 if test "x$has_colon" = x; then 59661 # Not in mixed or Windows style, start by that. 59662 new_path=`cmd //c echo $path` 59663 fi 59664 59665 59666 input_path="$new_path" 59667 # Check if we need to convert this using DOS-style short mode. If the path 59668 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59669 # take no chances and rewrite it. 59670 # Note: m4 eats our [], so we need to use [ and ] instead. 59671 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 59672 if test "x$has_forbidden_chars" != x; then 59673 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59674 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59675 fi 59676 59677 59678 windows_path="$new_path" 59679 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59680 unix_path=`$CYGPATH -u "$windows_path"` 59681 new_path="$unix_path" 59682 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59683 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59684 new_path="$unix_path" 59685 fi 59686 59687 if test "x$path" != "x$new_path"; then 59688 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 59689 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 59690 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 59691 fi 59692 59693 # Save the first 10 bytes of this path to the storage, so fixpath can work. 59694 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 59695 59696 else 59697 # We're on a unix platform. Hooray! :) 59698 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59699 has_space=`$ECHO "$path" | $GREP " "` 59700 if test "x$has_space" != x; then 59701 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 59702 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 59703 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 59704 fi 59705 59706 # Use eval to expand a potential ~ 59707 eval path="$path" 59708 if test ! -f "$path" && test ! -d "$path"; then 59709 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 59710 fi 59711 59712 if test -d "$path"; then 59713 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 59714 else 59715 dir="`$DIRNAME "$path"`" 59716 base="`$BASENAME "$path"`" 59717 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 59718 fi 59719 fi 59720 fi 59721 59722 59723 # Only process if variable expands to non-empty 59724 59725 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 59726 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59727 59728 # Input might be given as Windows format, start by converting to 59729 # unix format. 59730 path="$POTENTIAL_FREETYPE_LIB_PATH" 59731 new_path=`$CYGPATH -u "$path"` 59732 59733 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 59734 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 59735 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 59736 # "foo.exe" is OK but "foo" is an error. 59737 # 59738 # This test is therefore slightly more accurate than "test -f" to check for file precense. 59739 # It is also a way to make sure we got the proper file name for the real test later on. 59740 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 59741 if test "x$test_shortpath" = x; then 59742 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 59743 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 59744 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 59745 fi 59746 59747 # Call helper function which possibly converts this using DOS-style short mode. 59748 # If so, the updated path is stored in $new_path. 59749 59750 input_path="$new_path" 59751 # Check if we need to convert this using DOS-style short mode. If the path 59752 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59753 # take no chances and rewrite it. 59754 # Note: m4 eats our [], so we need to use [ and ] instead. 59755 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 59756 if test "x$has_forbidden_chars" != x; then 59757 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59758 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 59759 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 59760 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 59761 # Going to short mode and back again did indeed matter. Since short mode is 59762 # case insensitive, let's make it lowercase to improve readability. 59763 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59764 # Now convert it back to Unix-style (cygpath) 59765 input_path=`$CYGPATH -u "$shortmode_path"` 59766 new_path="$input_path" 59767 fi 59768 fi 59769 59770 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 59771 if test "x$test_cygdrive_prefix" = x; then 59772 # As a simple fix, exclude /usr/bin since it's not a real path. 59773 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 59774 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 59775 # a path prefixed by /cygdrive for fixpath to work. 59776 new_path="$CYGWIN_ROOT_PATH$input_path" 59777 fi 59778 fi 59779 59780 59781 if test "x$path" != "x$new_path"; then 59782 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 59783 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 59784 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 59785 fi 59786 59787 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59788 59789 path="$POTENTIAL_FREETYPE_LIB_PATH" 59790 has_colon=`$ECHO $path | $GREP ^.:` 59791 new_path="$path" 59792 if test "x$has_colon" = x; then 59793 # Not in mixed or Windows style, start by that. 59794 new_path=`cmd //c echo $path` 59795 fi 59796 59797 59798 input_path="$new_path" 59799 # Check if we need to convert this using DOS-style short mode. If the path 59800 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59801 # take no chances and rewrite it. 59802 # Note: m4 eats our [], so we need to use [ and ] instead. 59803 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 59804 if test "x$has_forbidden_chars" != x; then 59805 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59806 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59807 fi 59808 59809 59810 windows_path="$new_path" 59811 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59812 unix_path=`$CYGPATH -u "$windows_path"` 59813 new_path="$unix_path" 59814 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59815 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59816 new_path="$unix_path" 59817 fi 59818 59819 if test "x$path" != "x$new_path"; then 59820 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 59821 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 59822 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 59823 fi 59824 59825 # Save the first 10 bytes of this path to the storage, so fixpath can work. 59826 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 59827 59828 else 59829 # We're on a unix platform. Hooray! :) 59830 path="$POTENTIAL_FREETYPE_LIB_PATH" 59831 has_space=`$ECHO "$path" | $GREP " "` 59832 if test "x$has_space" != x; then 59833 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 59834 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 59835 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 59836 fi 59837 59838 # Use eval to expand a potential ~ 59839 eval path="$path" 59840 if test ! -f "$path" && test ! -d "$path"; then 59841 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 59842 fi 59843 59844 if test -d "$path"; then 59845 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 59846 else 59847 dir="`$DIRNAME "$path"`" 59848 base="`$BASENAME "$path"`" 59849 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 59850 fi 59851 fi 59852 fi 59853 59854 59855 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59856 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 59857 $as_echo_n "checking for freetype includes... " >&6; } 59858 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 59859 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 59860 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 59861 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 59862 $as_echo_n "checking for freetype libraries... " >&6; } 59863 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 59864 $as_echo "$FREETYPE_LIB_PATH" >&6; } 59865 fi 59866 59867 else 59868 59869 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 59870 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib32" 59871 METHOD="well-known location" 59872 59873 # Let's start with an optimistic view of the world :-) 59874 FOUND_FREETYPE=yes 59875 59876 # First look for the canonical freetype main include file ft2build.h. 59877 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59878 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 59879 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 59880 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59881 # Fail. 59882 FOUND_FREETYPE=no 59883 fi 59884 fi 59885 59886 if test "x$FOUND_FREETYPE" = xyes; then 59887 # Include file found, let's continue the sanity check. 59888 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 59889 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 59890 59891 # Reset to default value 59892 FREETYPE_BASE_NAME=freetype 59893 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59894 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 59895 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 59896 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 59897 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 59898 # for the .6 version explicitly. 59899 FREETYPE_BASE_NAME=freetype.6 59900 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59901 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 59902 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 59903 else 59904 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 59905 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 59906 FOUND_FREETYPE=no 59907 fi 59908 else 59909 if test "x$OPENJDK_TARGET_OS" = xwindows; then 59910 # On Windows, we will need both .lib and .dll file. 59911 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 59912 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 59913 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 59914 FOUND_FREETYPE=no 59915 fi 59916 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 59917 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 59918 # Found lib in isa dir, use that instead. 59919 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 59920 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 59921 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 59922 fi 59923 fi 59924 fi 59925 59926 if test "x$FOUND_FREETYPE" = xyes; then 59927 59928 # Only process if variable expands to non-empty 59929 59930 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 59931 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59932 59933 # Input might be given as Windows format, start by converting to 59934 # unix format. 59935 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59936 new_path=`$CYGPATH -u "$path"` 59937 59938 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 59939 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 59940 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 59941 # "foo.exe" is OK but "foo" is an error. 59942 # 59943 # This test is therefore slightly more accurate than "test -f" to check for file precense. 59944 # It is also a way to make sure we got the proper file name for the real test later on. 59945 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 59946 if test "x$test_shortpath" = x; then 59947 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 59948 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 59949 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 59950 fi 59951 59952 # Call helper function which possibly converts this using DOS-style short mode. 59953 # If so, the updated path is stored in $new_path. 59954 59955 input_path="$new_path" 59956 # Check if we need to convert this using DOS-style short mode. If the path 59957 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59958 # take no chances and rewrite it. 59959 # Note: m4 eats our [], so we need to use [ and ] instead. 59960 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 59961 if test "x$has_forbidden_chars" != x; then 59962 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59963 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 59964 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 59965 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 59966 # Going to short mode and back again did indeed matter. Since short mode is 59967 # case insensitive, let's make it lowercase to improve readability. 59968 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59969 # Now convert it back to Unix-style (cygpath) 59970 input_path=`$CYGPATH -u "$shortmode_path"` 59971 new_path="$input_path" 59972 fi 59973 fi 59974 59975 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 59976 if test "x$test_cygdrive_prefix" = x; then 59977 # As a simple fix, exclude /usr/bin since it's not a real path. 59978 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 59979 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 59980 # a path prefixed by /cygdrive for fixpath to work. 59981 new_path="$CYGWIN_ROOT_PATH$input_path" 59982 fi 59983 fi 59984 59985 59986 if test "x$path" != "x$new_path"; then 59987 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 59988 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 59989 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 59990 fi 59991 59992 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59993 59994 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59995 has_colon=`$ECHO $path | $GREP ^.:` 59996 new_path="$path" 59997 if test "x$has_colon" = x; then 59998 # Not in mixed or Windows style, start by that. 59999 new_path=`cmd //c echo $path` 60000 fi 60001 60002 60003 input_path="$new_path" 60004 # Check if we need to convert this using DOS-style short mode. If the path 60005 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60006 # take no chances and rewrite it. 60007 # Note: m4 eats our [], so we need to use [ and ] instead. 60008 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60009 if test "x$has_forbidden_chars" != x; then 60010 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60011 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60012 fi 60013 60014 60015 windows_path="$new_path" 60016 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60017 unix_path=`$CYGPATH -u "$windows_path"` 60018 new_path="$unix_path" 60019 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60020 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60021 new_path="$unix_path" 60022 fi 60023 60024 if test "x$path" != "x$new_path"; then 60025 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60026 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60027 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60028 fi 60029 60030 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60031 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60032 60033 else 60034 # We're on a unix platform. Hooray! :) 60035 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60036 has_space=`$ECHO "$path" | $GREP " "` 60037 if test "x$has_space" != x; then 60038 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60039 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60040 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60041 fi 60042 60043 # Use eval to expand a potential ~ 60044 eval path="$path" 60045 if test ! -f "$path" && test ! -d "$path"; then 60046 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60047 fi 60048 60049 if test -d "$path"; then 60050 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 60051 else 60052 dir="`$DIRNAME "$path"`" 60053 base="`$BASENAME "$path"`" 60054 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60055 fi 60056 fi 60057 fi 60058 60059 60060 # Only process if variable expands to non-empty 60061 60062 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 60063 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60064 60065 # Input might be given as Windows format, start by converting to 60066 # unix format. 60067 path="$POTENTIAL_FREETYPE_LIB_PATH" 60068 new_path=`$CYGPATH -u "$path"` 60069 60070 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60071 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60072 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60073 # "foo.exe" is OK but "foo" is an error. 60074 # 60075 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60076 # It is also a way to make sure we got the proper file name for the real test later on. 60077 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60078 if test "x$test_shortpath" = x; then 60079 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60080 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60081 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 60082 fi 60083 60084 # Call helper function which possibly converts this using DOS-style short mode. 60085 # If so, the updated path is stored in $new_path. 60086 60087 input_path="$new_path" 60088 # Check if we need to convert this using DOS-style short mode. If the path 60089 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60090 # take no chances and rewrite it. 60091 # Note: m4 eats our [], so we need to use [ and ] instead. 60092 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60093 if test "x$has_forbidden_chars" != x; then 60094 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60095 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60096 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60097 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60098 # Going to short mode and back again did indeed matter. Since short mode is 60099 # case insensitive, let's make it lowercase to improve readability. 60100 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60101 # Now convert it back to Unix-style (cygpath) 60102 input_path=`$CYGPATH -u "$shortmode_path"` 60103 new_path="$input_path" 60104 fi 60105 fi 60106 60107 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60108 if test "x$test_cygdrive_prefix" = x; then 60109 # As a simple fix, exclude /usr/bin since it's not a real path. 60110 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60111 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60112 # a path prefixed by /cygdrive for fixpath to work. 60113 new_path="$CYGWIN_ROOT_PATH$input_path" 60114 fi 60115 fi 60116 60117 60118 if test "x$path" != "x$new_path"; then 60119 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60120 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60121 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60122 fi 60123 60124 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60125 60126 path="$POTENTIAL_FREETYPE_LIB_PATH" 60127 has_colon=`$ECHO $path | $GREP ^.:` 60128 new_path="$path" 60129 if test "x$has_colon" = x; then 60130 # Not in mixed or Windows style, start by that. 60131 new_path=`cmd //c echo $path` 60132 fi 60133 60134 60135 input_path="$new_path" 60136 # Check if we need to convert this using DOS-style short mode. If the path 60137 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60138 # take no chances and rewrite it. 60139 # Note: m4 eats our [], so we need to use [ and ] instead. 60140 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60141 if test "x$has_forbidden_chars" != x; then 60142 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60143 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60144 fi 60145 60146 60147 windows_path="$new_path" 60148 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60149 unix_path=`$CYGPATH -u "$windows_path"` 60150 new_path="$unix_path" 60151 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60152 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60153 new_path="$unix_path" 60154 fi 60155 60156 if test "x$path" != "x$new_path"; then 60157 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60158 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60159 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60160 fi 60161 60162 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60163 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60164 60165 else 60166 # We're on a unix platform. Hooray! :) 60167 path="$POTENTIAL_FREETYPE_LIB_PATH" 60168 has_space=`$ECHO "$path" | $GREP " "` 60169 if test "x$has_space" != x; then 60170 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60171 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60172 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60173 fi 60174 60175 # Use eval to expand a potential ~ 60176 eval path="$path" 60177 if test ! -f "$path" && test ! -d "$path"; then 60178 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60179 fi 60180 60181 if test -d "$path"; then 60182 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 60183 else 60184 dir="`$DIRNAME "$path"`" 60185 base="`$BASENAME "$path"`" 60186 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60187 fi 60188 fi 60189 fi 60190 60191 60192 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60193 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 60194 $as_echo_n "checking for freetype includes... " >&6; } 60195 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 60196 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 60197 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 60198 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 60199 $as_echo_n "checking for freetype libraries... " >&6; } 60200 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 60201 $as_echo "$FREETYPE_LIB_PATH" >&6; } 60202 fi 60203 60204 fi 60205 fi 60206 fi 60207 else 60208 FREETYPE_BASE_DIR="$SYSROOT/usr" 60209 60210 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 60211 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 60212 METHOD="well-known location" 60213 60214 # Let's start with an optimistic view of the world :-) 60215 FOUND_FREETYPE=yes 60216 60217 # First look for the canonical freetype main include file ft2build.h. 60218 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60219 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 60220 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 60221 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60222 # Fail. 60223 FOUND_FREETYPE=no 60224 fi 60225 fi 60226 60227 if test "x$FOUND_FREETYPE" = xyes; then 60228 # Include file found, let's continue the sanity check. 60229 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 60230 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 60231 60232 # Reset to default value 60233 FREETYPE_BASE_NAME=freetype 60234 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60235 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 60236 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 60237 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 60238 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 60239 # for the .6 version explicitly. 60240 FREETYPE_BASE_NAME=freetype.6 60241 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60242 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 60243 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 60244 else 60245 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 60246 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 60247 FOUND_FREETYPE=no 60248 fi 60249 else 60250 if test "x$OPENJDK_TARGET_OS" = xwindows; then 60251 # On Windows, we will need both .lib and .dll file. 60252 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 60253 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 60254 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 60255 FOUND_FREETYPE=no 60256 fi 60257 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 60258 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 60259 # Found lib in isa dir, use that instead. 60260 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 60261 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 60262 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 60263 fi 60264 fi 60265 fi 60266 60267 if test "x$FOUND_FREETYPE" = xyes; then 60268 60269 # Only process if variable expands to non-empty 60270 60271 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 60272 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60273 60274 # Input might be given as Windows format, start by converting to 60275 # unix format. 60276 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60277 new_path=`$CYGPATH -u "$path"` 60278 60279 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60280 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60281 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60282 # "foo.exe" is OK but "foo" is an error. 60283 # 60284 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60285 # It is also a way to make sure we got the proper file name for the real test later on. 60286 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60287 if test "x$test_shortpath" = x; then 60288 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60289 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60290 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 60291 fi 60292 60293 # Call helper function which possibly converts this using DOS-style short mode. 60294 # If so, the updated path is stored in $new_path. 60295 60296 input_path="$new_path" 60297 # Check if we need to convert this using DOS-style short mode. If the path 60298 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60299 # take no chances and rewrite it. 60300 # Note: m4 eats our [], so we need to use [ and ] instead. 60301 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60302 if test "x$has_forbidden_chars" != x; then 60303 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60304 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60305 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60306 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60307 # Going to short mode and back again did indeed matter. Since short mode is 60308 # case insensitive, let's make it lowercase to improve readability. 60309 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60310 # Now convert it back to Unix-style (cygpath) 60311 input_path=`$CYGPATH -u "$shortmode_path"` 60312 new_path="$input_path" 60313 fi 60314 fi 60315 60316 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60317 if test "x$test_cygdrive_prefix" = x; then 60318 # As a simple fix, exclude /usr/bin since it's not a real path. 60319 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60320 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60321 # a path prefixed by /cygdrive for fixpath to work. 60322 new_path="$CYGWIN_ROOT_PATH$input_path" 60323 fi 60324 fi 60325 60326 60327 if test "x$path" != "x$new_path"; then 60328 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60329 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60330 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60331 fi 60332 60333 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60334 60335 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60336 has_colon=`$ECHO $path | $GREP ^.:` 60337 new_path="$path" 60338 if test "x$has_colon" = x; then 60339 # Not in mixed or Windows style, start by that. 60340 new_path=`cmd //c echo $path` 60341 fi 60342 60343 60344 input_path="$new_path" 60345 # Check if we need to convert this using DOS-style short mode. If the path 60346 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60347 # take no chances and rewrite it. 60348 # Note: m4 eats our [], so we need to use [ and ] instead. 60349 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60350 if test "x$has_forbidden_chars" != x; then 60351 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60352 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60353 fi 60354 60355 60356 windows_path="$new_path" 60357 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60358 unix_path=`$CYGPATH -u "$windows_path"` 60359 new_path="$unix_path" 60360 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60361 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60362 new_path="$unix_path" 60363 fi 60364 60365 if test "x$path" != "x$new_path"; then 60366 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60367 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60368 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60369 fi 60370 60371 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60372 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60373 60374 else 60375 # We're on a unix platform. Hooray! :) 60376 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60377 has_space=`$ECHO "$path" | $GREP " "` 60378 if test "x$has_space" != x; then 60379 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60380 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60381 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60382 fi 60383 60384 # Use eval to expand a potential ~ 60385 eval path="$path" 60386 if test ! -f "$path" && test ! -d "$path"; then 60387 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60388 fi 60389 60390 if test -d "$path"; then 60391 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 60392 else 60393 dir="`$DIRNAME "$path"`" 60394 base="`$BASENAME "$path"`" 60395 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60396 fi 60397 fi 60398 fi 60399 60400 60401 # Only process if variable expands to non-empty 60402 60403 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 60404 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60405 60406 # Input might be given as Windows format, start by converting to 60407 # unix format. 60408 path="$POTENTIAL_FREETYPE_LIB_PATH" 60409 new_path=`$CYGPATH -u "$path"` 60410 60411 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60412 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60413 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60414 # "foo.exe" is OK but "foo" is an error. 60415 # 60416 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60417 # It is also a way to make sure we got the proper file name for the real test later on. 60418 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60419 if test "x$test_shortpath" = x; then 60420 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60421 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60422 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 60423 fi 60424 60425 # Call helper function which possibly converts this using DOS-style short mode. 60426 # If so, the updated path is stored in $new_path. 60427 60428 input_path="$new_path" 60429 # Check if we need to convert this using DOS-style short mode. If the path 60430 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60431 # take no chances and rewrite it. 60432 # Note: m4 eats our [], so we need to use [ and ] instead. 60433 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60434 if test "x$has_forbidden_chars" != x; then 60435 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60436 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60437 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60438 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60439 # Going to short mode and back again did indeed matter. Since short mode is 60440 # case insensitive, let's make it lowercase to improve readability. 60441 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60442 # Now convert it back to Unix-style (cygpath) 60443 input_path=`$CYGPATH -u "$shortmode_path"` 60444 new_path="$input_path" 60445 fi 60446 fi 60447 60448 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60449 if test "x$test_cygdrive_prefix" = x; then 60450 # As a simple fix, exclude /usr/bin since it's not a real path. 60451 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60452 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60453 # a path prefixed by /cygdrive for fixpath to work. 60454 new_path="$CYGWIN_ROOT_PATH$input_path" 60455 fi 60456 fi 60457 60458 60459 if test "x$path" != "x$new_path"; then 60460 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60461 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60462 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60463 fi 60464 60465 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60466 60467 path="$POTENTIAL_FREETYPE_LIB_PATH" 60468 has_colon=`$ECHO $path | $GREP ^.:` 60469 new_path="$path" 60470 if test "x$has_colon" = x; then 60471 # Not in mixed or Windows style, start by that. 60472 new_path=`cmd //c echo $path` 60473 fi 60474 60475 60476 input_path="$new_path" 60477 # Check if we need to convert this using DOS-style short mode. If the path 60478 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60479 # take no chances and rewrite it. 60480 # Note: m4 eats our [], so we need to use [ and ] instead. 60481 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60482 if test "x$has_forbidden_chars" != x; then 60483 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60484 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60485 fi 60486 60487 60488 windows_path="$new_path" 60489 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60490 unix_path=`$CYGPATH -u "$windows_path"` 60491 new_path="$unix_path" 60492 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60493 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60494 new_path="$unix_path" 60495 fi 60496 60497 if test "x$path" != "x$new_path"; then 60498 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60499 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60500 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60501 fi 60502 60503 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60504 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60505 60506 else 60507 # We're on a unix platform. Hooray! :) 60508 path="$POTENTIAL_FREETYPE_LIB_PATH" 60509 has_space=`$ECHO "$path" | $GREP " "` 60510 if test "x$has_space" != x; then 60511 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60512 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60513 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60514 fi 60515 60516 # Use eval to expand a potential ~ 60517 eval path="$path" 60518 if test ! -f "$path" && test ! -d "$path"; then 60519 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60520 fi 60521 60522 if test -d "$path"; then 60523 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 60524 else 60525 dir="`$DIRNAME "$path"`" 60526 base="`$BASENAME "$path"`" 60527 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60528 fi 60529 fi 60530 fi 60531 60532 60533 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60534 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 60535 $as_echo_n "checking for freetype includes... " >&6; } 60536 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 60537 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 60538 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 60539 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 60540 $as_echo_n "checking for freetype libraries... " >&6; } 60541 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 60542 $as_echo "$FREETYPE_LIB_PATH" >&6; } 60543 fi 60544 60545 60546 if test "x$FOUND_FREETYPE" != xyes; then 60547 FREETYPE_BASE_DIR="$SYSROOT/usr/X11" 60548 60549 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 60550 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 60551 METHOD="well-known location" 60552 60553 # Let's start with an optimistic view of the world :-) 60554 FOUND_FREETYPE=yes 60555 60556 # First look for the canonical freetype main include file ft2build.h. 60557 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60558 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 60559 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 60560 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60561 # Fail. 60562 FOUND_FREETYPE=no 60563 fi 60564 fi 60565 60566 if test "x$FOUND_FREETYPE" = xyes; then 60567 # Include file found, let's continue the sanity check. 60568 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 60569 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 60570 60571 # Reset to default value 60572 FREETYPE_BASE_NAME=freetype 60573 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60574 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 60575 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 60576 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 60577 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 60578 # for the .6 version explicitly. 60579 FREETYPE_BASE_NAME=freetype.6 60580 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60581 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 60582 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 60583 else 60584 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 60585 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 60586 FOUND_FREETYPE=no 60587 fi 60588 else 60589 if test "x$OPENJDK_TARGET_OS" = xwindows; then 60590 # On Windows, we will need both .lib and .dll file. 60591 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 60592 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 60593 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 60594 FOUND_FREETYPE=no 60595 fi 60596 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 60597 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 60598 # Found lib in isa dir, use that instead. 60599 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 60600 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 60601 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 60602 fi 60603 fi 60604 fi 60605 60606 if test "x$FOUND_FREETYPE" = xyes; then 60607 60608 # Only process if variable expands to non-empty 60609 60610 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 60611 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60612 60613 # Input might be given as Windows format, start by converting to 60614 # unix format. 60615 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60616 new_path=`$CYGPATH -u "$path"` 60617 60618 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60619 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60620 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60621 # "foo.exe" is OK but "foo" is an error. 60622 # 60623 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60624 # It is also a way to make sure we got the proper file name for the real test later on. 60625 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60626 if test "x$test_shortpath" = x; then 60627 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60628 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60629 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 60630 fi 60631 60632 # Call helper function which possibly converts this using DOS-style short mode. 60633 # If so, the updated path is stored in $new_path. 60634 60635 input_path="$new_path" 60636 # Check if we need to convert this using DOS-style short mode. If the path 60637 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60638 # take no chances and rewrite it. 60639 # Note: m4 eats our [], so we need to use [ and ] instead. 60640 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60641 if test "x$has_forbidden_chars" != x; then 60642 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60643 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60644 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60645 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60646 # Going to short mode and back again did indeed matter. Since short mode is 60647 # case insensitive, let's make it lowercase to improve readability. 60648 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60649 # Now convert it back to Unix-style (cygpath) 60650 input_path=`$CYGPATH -u "$shortmode_path"` 60651 new_path="$input_path" 60652 fi 60653 fi 60654 60655 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60656 if test "x$test_cygdrive_prefix" = x; then 60657 # As a simple fix, exclude /usr/bin since it's not a real path. 60658 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60659 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60660 # a path prefixed by /cygdrive for fixpath to work. 60661 new_path="$CYGWIN_ROOT_PATH$input_path" 60662 fi 60663 fi 60664 60665 60666 if test "x$path" != "x$new_path"; then 60667 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60668 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60669 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60670 fi 60671 60672 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60673 60674 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60675 has_colon=`$ECHO $path | $GREP ^.:` 60676 new_path="$path" 60677 if test "x$has_colon" = x; then 60678 # Not in mixed or Windows style, start by that. 60679 new_path=`cmd //c echo $path` 60680 fi 60681 60682 60683 input_path="$new_path" 60684 # Check if we need to convert this using DOS-style short mode. If the path 60685 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60686 # take no chances and rewrite it. 60687 # Note: m4 eats our [], so we need to use [ and ] instead. 60688 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60689 if test "x$has_forbidden_chars" != x; then 60690 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60691 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60692 fi 60693 60694 60695 windows_path="$new_path" 60696 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60697 unix_path=`$CYGPATH -u "$windows_path"` 60698 new_path="$unix_path" 60699 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60700 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60701 new_path="$unix_path" 60702 fi 60703 60704 if test "x$path" != "x$new_path"; then 60705 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60706 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60707 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60708 fi 60709 60710 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60711 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60712 60713 else 60714 # We're on a unix platform. Hooray! :) 60715 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60716 has_space=`$ECHO "$path" | $GREP " "` 60717 if test "x$has_space" != x; then 60718 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60719 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60720 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60721 fi 60722 60723 # Use eval to expand a potential ~ 60724 eval path="$path" 60725 if test ! -f "$path" && test ! -d "$path"; then 60726 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60727 fi 60728 60729 if test -d "$path"; then 60730 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 60731 else 60732 dir="`$DIRNAME "$path"`" 60733 base="`$BASENAME "$path"`" 60734 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60735 fi 60736 fi 60737 fi 60738 60739 60740 # Only process if variable expands to non-empty 60741 60742 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 60743 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60744 60745 # Input might be given as Windows format, start by converting to 60746 # unix format. 60747 path="$POTENTIAL_FREETYPE_LIB_PATH" 60748 new_path=`$CYGPATH -u "$path"` 60749 60750 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60751 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60752 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60753 # "foo.exe" is OK but "foo" is an error. 60754 # 60755 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60756 # It is also a way to make sure we got the proper file name for the real test later on. 60757 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60758 if test "x$test_shortpath" = x; then 60759 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60760 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60761 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 60762 fi 60763 60764 # Call helper function which possibly converts this using DOS-style short mode. 60765 # If so, the updated path is stored in $new_path. 60766 60767 input_path="$new_path" 60768 # Check if we need to convert this using DOS-style short mode. If the path 60769 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60770 # take no chances and rewrite it. 60771 # Note: m4 eats our [], so we need to use [ and ] instead. 60772 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60773 if test "x$has_forbidden_chars" != x; then 60774 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60775 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60776 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60777 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60778 # Going to short mode and back again did indeed matter. Since short mode is 60779 # case insensitive, let's make it lowercase to improve readability. 60780 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60781 # Now convert it back to Unix-style (cygpath) 60782 input_path=`$CYGPATH -u "$shortmode_path"` 60783 new_path="$input_path" 60784 fi 60785 fi 60786 60787 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60788 if test "x$test_cygdrive_prefix" = x; then 60789 # As a simple fix, exclude /usr/bin since it's not a real path. 60790 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60791 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60792 # a path prefixed by /cygdrive for fixpath to work. 60793 new_path="$CYGWIN_ROOT_PATH$input_path" 60794 fi 60795 fi 60796 60797 60798 if test "x$path" != "x$new_path"; then 60799 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60800 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60801 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60802 fi 60803 60804 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60805 60806 path="$POTENTIAL_FREETYPE_LIB_PATH" 60807 has_colon=`$ECHO $path | $GREP ^.:` 60808 new_path="$path" 60809 if test "x$has_colon" = x; then 60810 # Not in mixed or Windows style, start by that. 60811 new_path=`cmd //c echo $path` 60812 fi 60813 60814 60815 input_path="$new_path" 60816 # Check if we need to convert this using DOS-style short mode. If the path 60817 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60818 # take no chances and rewrite it. 60819 # Note: m4 eats our [], so we need to use [ and ] instead. 60820 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60821 if test "x$has_forbidden_chars" != x; then 60822 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60823 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60824 fi 60825 60826 60827 windows_path="$new_path" 60828 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60829 unix_path=`$CYGPATH -u "$windows_path"` 60830 new_path="$unix_path" 60831 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60832 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60833 new_path="$unix_path" 60834 fi 60835 60836 if test "x$path" != "x$new_path"; then 60837 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60838 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60839 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60840 fi 60841 60842 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60843 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60844 60845 else 60846 # We're on a unix platform. Hooray! :) 60847 path="$POTENTIAL_FREETYPE_LIB_PATH" 60848 has_space=`$ECHO "$path" | $GREP " "` 60849 if test "x$has_space" != x; then 60850 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60851 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60852 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60853 fi 60854 60855 # Use eval to expand a potential ~ 60856 eval path="$path" 60857 if test ! -f "$path" && test ! -d "$path"; then 60858 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60859 fi 60860 60861 if test -d "$path"; then 60862 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 60863 else 60864 dir="`$DIRNAME "$path"`" 60865 base="`$BASENAME "$path"`" 60866 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60867 fi 60868 fi 60869 fi 60870 60871 60872 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60873 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 60874 $as_echo_n "checking for freetype includes... " >&6; } 60875 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 60876 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 60877 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 60878 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 60879 $as_echo_n "checking for freetype libraries... " >&6; } 60880 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 60881 $as_echo "$FREETYPE_LIB_PATH" >&6; } 60882 fi 60883 60884 fi 60885 if test "x$FOUND_FREETYPE" != xyes; then 60886 FREETYPE_BASE_DIR="$SYSROOT/usr/local" 60887 60888 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 60889 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 60890 METHOD="well-known location" 60891 60892 # Let's start with an optimistic view of the world :-) 60893 FOUND_FREETYPE=yes 60894 60895 # First look for the canonical freetype main include file ft2build.h. 60896 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60897 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 60898 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 60899 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60900 # Fail. 60901 FOUND_FREETYPE=no 60902 fi 60903 fi 60904 60905 if test "x$FOUND_FREETYPE" = xyes; then 60906 # Include file found, let's continue the sanity check. 60907 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 60908 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 60909 60910 # Reset to default value 60911 FREETYPE_BASE_NAME=freetype 60912 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60913 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 60914 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 60915 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 60916 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 60917 # for the .6 version explicitly. 60918 FREETYPE_BASE_NAME=freetype.6 60919 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60920 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 60921 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 60922 else 60923 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 60924 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 60925 FOUND_FREETYPE=no 60926 fi 60927 else 60928 if test "x$OPENJDK_TARGET_OS" = xwindows; then 60929 # On Windows, we will need both .lib and .dll file. 60930 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 60931 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 60932 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 60933 FOUND_FREETYPE=no 60934 fi 60935 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 60936 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 60937 # Found lib in isa dir, use that instead. 60938 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 60939 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 60940 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 60941 fi 60942 fi 60943 fi 60944 60945 if test "x$FOUND_FREETYPE" = xyes; then 60946 60947 # Only process if variable expands to non-empty 60948 60949 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 60950 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60951 60952 # Input might be given as Windows format, start by converting to 60953 # unix format. 60954 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60955 new_path=`$CYGPATH -u "$path"` 60956 60957 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60958 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60959 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60960 # "foo.exe" is OK but "foo" is an error. 60961 # 60962 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60963 # It is also a way to make sure we got the proper file name for the real test later on. 60964 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60965 if test "x$test_shortpath" = x; then 60966 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60967 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60968 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 60969 fi 60970 60971 # Call helper function which possibly converts this using DOS-style short mode. 60972 # If so, the updated path is stored in $new_path. 60973 60974 input_path="$new_path" 60975 # Check if we need to convert this using DOS-style short mode. If the path 60976 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60977 # take no chances and rewrite it. 60978 # Note: m4 eats our [], so we need to use [ and ] instead. 60979 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60980 if test "x$has_forbidden_chars" != x; then 60981 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60982 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60983 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60984 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60985 # Going to short mode and back again did indeed matter. Since short mode is 60986 # case insensitive, let's make it lowercase to improve readability. 60987 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60988 # Now convert it back to Unix-style (cygpath) 60989 input_path=`$CYGPATH -u "$shortmode_path"` 60990 new_path="$input_path" 60991 fi 60992 fi 60993 60994 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60995 if test "x$test_cygdrive_prefix" = x; then 60996 # As a simple fix, exclude /usr/bin since it's not a real path. 60997 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60998 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60999 # a path prefixed by /cygdrive for fixpath to work. 61000 new_path="$CYGWIN_ROOT_PATH$input_path" 61001 fi 61002 fi 61003 61004 61005 if test "x$path" != "x$new_path"; then 61006 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61007 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61008 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61009 fi 61010 61011 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61012 61013 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61014 has_colon=`$ECHO $path | $GREP ^.:` 61015 new_path="$path" 61016 if test "x$has_colon" = x; then 61017 # Not in mixed or Windows style, start by that. 61018 new_path=`cmd //c echo $path` 61019 fi 61020 61021 61022 input_path="$new_path" 61023 # Check if we need to convert this using DOS-style short mode. If the path 61024 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61025 # take no chances and rewrite it. 61026 # Note: m4 eats our [], so we need to use [ and ] instead. 61027 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 61028 if test "x$has_forbidden_chars" != x; then 61029 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61030 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61031 fi 61032 61033 61034 windows_path="$new_path" 61035 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61036 unix_path=`$CYGPATH -u "$windows_path"` 61037 new_path="$unix_path" 61038 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61039 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61040 new_path="$unix_path" 61041 fi 61042 61043 if test "x$path" != "x$new_path"; then 61044 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61045 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61046 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61047 fi 61048 61049 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61050 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61051 61052 else 61053 # We're on a unix platform. Hooray! :) 61054 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61055 has_space=`$ECHO "$path" | $GREP " "` 61056 if test "x$has_space" != x; then 61057 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61058 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61059 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61060 fi 61061 61062 # Use eval to expand a potential ~ 61063 eval path="$path" 61064 if test ! -f "$path" && test ! -d "$path"; then 61065 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61066 fi 61067 61068 if test -d "$path"; then 61069 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 61070 else 61071 dir="`$DIRNAME "$path"`" 61072 base="`$BASENAME "$path"`" 61073 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61074 fi 61075 fi 61076 fi 61077 61078 61079 # Only process if variable expands to non-empty 61080 61081 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 61082 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61083 61084 # Input might be given as Windows format, start by converting to 61085 # unix format. 61086 path="$POTENTIAL_FREETYPE_LIB_PATH" 61087 new_path=`$CYGPATH -u "$path"` 61088 61089 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61090 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61091 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61092 # "foo.exe" is OK but "foo" is an error. 61093 # 61094 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61095 # It is also a way to make sure we got the proper file name for the real test later on. 61096 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61097 if test "x$test_shortpath" = x; then 61098 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61099 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61100 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 61101 fi 61102 61103 # Call helper function which possibly converts this using DOS-style short mode. 61104 # If so, the updated path is stored in $new_path. 61105 61106 input_path="$new_path" 61107 # Check if we need to convert this using DOS-style short mode. If the path 61108 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61109 # take no chances and rewrite it. 61110 # Note: m4 eats our [], so we need to use [ and ] instead. 61111 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61112 if test "x$has_forbidden_chars" != x; then 61113 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61114 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61115 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61116 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61117 # Going to short mode and back again did indeed matter. Since short mode is 61118 # case insensitive, let's make it lowercase to improve readability. 61119 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61120 # Now convert it back to Unix-style (cygpath) 61121 input_path=`$CYGPATH -u "$shortmode_path"` 61122 new_path="$input_path" 61123 fi 61124 fi 61125 61126 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61127 if test "x$test_cygdrive_prefix" = x; then 61128 # As a simple fix, exclude /usr/bin since it's not a real path. 61129 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61130 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61131 # a path prefixed by /cygdrive for fixpath to work. 61132 new_path="$CYGWIN_ROOT_PATH$input_path" 61133 fi 61134 fi 61135 61136 61137 if test "x$path" != "x$new_path"; then 61138 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61139 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61140 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61141 fi 61142 61143 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61144 61145 path="$POTENTIAL_FREETYPE_LIB_PATH" 61146 has_colon=`$ECHO $path | $GREP ^.:` 61147 new_path="$path" 61148 if test "x$has_colon" = x; then 61149 # Not in mixed or Windows style, start by that. 61150 new_path=`cmd //c echo $path` 61151 fi 61152 61153 61154 input_path="$new_path" 61155 # Check if we need to convert this using DOS-style short mode. If the path 61156 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61157 # take no chances and rewrite it. 61158 # Note: m4 eats our [], so we need to use [ and ] instead. 61159 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 61160 if test "x$has_forbidden_chars" != x; then 61161 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61162 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61163 fi 61164 61165 61166 windows_path="$new_path" 61167 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61168 unix_path=`$CYGPATH -u "$windows_path"` 61169 new_path="$unix_path" 61170 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61171 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61172 new_path="$unix_path" 61173 fi 61174 61175 if test "x$path" != "x$new_path"; then 61176 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61177 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61178 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61179 fi 61180 61181 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61182 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61183 61184 else 61185 # We're on a unix platform. Hooray! :) 61186 path="$POTENTIAL_FREETYPE_LIB_PATH" 61187 has_space=`$ECHO "$path" | $GREP " "` 61188 if test "x$has_space" != x; then 61189 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61190 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61191 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61192 fi 61193 61194 # Use eval to expand a potential ~ 61195 eval path="$path" 61196 if test ! -f "$path" && test ! -d "$path"; then 61197 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61198 fi 61199 61200 if test -d "$path"; then 61201 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 61202 else 61203 dir="`$DIRNAME "$path"`" 61204 base="`$BASENAME "$path"`" 61205 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61206 fi 61207 fi 61208 fi 61209 61210 61211 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61212 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 61213 $as_echo_n "checking for freetype includes... " >&6; } 61214 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 61215 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 61216 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 61217 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 61218 $as_echo_n "checking for freetype libraries... " >&6; } 61219 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 61220 $as_echo "$FREETYPE_LIB_PATH" >&6; } 61221 fi 61222 61223 fi 61224 61225 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 61226 if test "x$FOUND_FREETYPE" != xyes; then 61227 # Due to changes in OSX 10.11 XQuartz now installs to /opt/X11 61228 FREETYPE_BASE_DIR="$SYSROOT/opt/X11" 61229 61230 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 61231 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 61232 METHOD="well-known location" 61233 61234 # Let's start with an optimistic view of the world :-) 61235 FOUND_FREETYPE=yes 61236 61237 # First look for the canonical freetype main include file ft2build.h. 61238 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61239 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 61240 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 61241 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61242 # Fail. 61243 FOUND_FREETYPE=no 61244 fi 61245 fi 61246 61247 if test "x$FOUND_FREETYPE" = xyes; then 61248 # Include file found, let's continue the sanity check. 61249 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 61250 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 61251 61252 # Reset to default value 61253 FREETYPE_BASE_NAME=freetype 61254 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61255 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 61256 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 61257 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 61258 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 61259 # for the .6 version explicitly. 61260 FREETYPE_BASE_NAME=freetype.6 61261 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61262 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 61263 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 61264 else 61265 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 61266 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 61267 FOUND_FREETYPE=no 61268 fi 61269 else 61270 if test "x$OPENJDK_TARGET_OS" = xwindows; then 61271 # On Windows, we will need both .lib and .dll file. 61272 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 61273 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 61274 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 61275 FOUND_FREETYPE=no 61276 fi 61277 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 61278 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 61279 # Found lib in isa dir, use that instead. 61280 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 61281 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 61282 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 61283 fi 61284 fi 61285 fi 61286 61287 if test "x$FOUND_FREETYPE" = xyes; then 61288 61289 # Only process if variable expands to non-empty 61290 61291 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 61292 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61293 61294 # Input might be given as Windows format, start by converting to 61295 # unix format. 61296 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61297 new_path=`$CYGPATH -u "$path"` 61298 61299 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61300 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61301 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61302 # "foo.exe" is OK but "foo" is an error. 61303 # 61304 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61305 # It is also a way to make sure we got the proper file name for the real test later on. 61306 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61307 if test "x$test_shortpath" = x; then 61308 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61309 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61310 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 61311 fi 61312 61313 # Call helper function which possibly converts this using DOS-style short mode. 61314 # If so, the updated path is stored in $new_path. 61315 61316 input_path="$new_path" 61317 # Check if we need to convert this using DOS-style short mode. If the path 61318 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61319 # take no chances and rewrite it. 61320 # Note: m4 eats our [], so we need to use [ and ] instead. 61321 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61322 if test "x$has_forbidden_chars" != x; then 61323 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61324 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61325 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61326 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61327 # Going to short mode and back again did indeed matter. Since short mode is 61328 # case insensitive, let's make it lowercase to improve readability. 61329 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61330 # Now convert it back to Unix-style (cygpath) 61331 input_path=`$CYGPATH -u "$shortmode_path"` 61332 new_path="$input_path" 61333 fi 61334 fi 61335 61336 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61337 if test "x$test_cygdrive_prefix" = x; then 61338 # As a simple fix, exclude /usr/bin since it's not a real path. 61339 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61340 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61341 # a path prefixed by /cygdrive for fixpath to work. 61342 new_path="$CYGWIN_ROOT_PATH$input_path" 61343 fi 61344 fi 61345 61346 61347 if test "x$path" != "x$new_path"; then 61348 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61349 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61350 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61351 fi 61352 61353 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61354 61355 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61356 has_colon=`$ECHO $path | $GREP ^.:` 61357 new_path="$path" 61358 if test "x$has_colon" = x; then 61359 # Not in mixed or Windows style, start by that. 61360 new_path=`cmd //c echo $path` 61361 fi 61362 61363 61364 input_path="$new_path" 61365 # Check if we need to convert this using DOS-style short mode. If the path 61366 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61367 # take no chances and rewrite it. 61368 # Note: m4 eats our [], so we need to use [ and ] instead. 61369 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 61370 if test "x$has_forbidden_chars" != x; then 61371 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61372 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61373 fi 61374 61375 61376 windows_path="$new_path" 61377 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61378 unix_path=`$CYGPATH -u "$windows_path"` 61379 new_path="$unix_path" 61380 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61381 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61382 new_path="$unix_path" 61383 fi 61384 61385 if test "x$path" != "x$new_path"; then 61386 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61387 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61388 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61389 fi 61390 61391 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61392 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61393 61394 else 61395 # We're on a unix platform. Hooray! :) 61396 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61397 has_space=`$ECHO "$path" | $GREP " "` 61398 if test "x$has_space" != x; then 61399 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61400 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61401 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61402 fi 61403 61404 # Use eval to expand a potential ~ 61405 eval path="$path" 61406 if test ! -f "$path" && test ! -d "$path"; then 61407 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61408 fi 61409 61410 if test -d "$path"; then 61411 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 61412 else 61413 dir="`$DIRNAME "$path"`" 61414 base="`$BASENAME "$path"`" 61415 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61416 fi 61417 fi 61418 fi 61419 61420 61421 # Only process if variable expands to non-empty 61422 61423 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 61424 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61425 61426 # Input might be given as Windows format, start by converting to 61427 # unix format. 61428 path="$POTENTIAL_FREETYPE_LIB_PATH" 61429 new_path=`$CYGPATH -u "$path"` 61430 61431 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61432 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61433 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61434 # "foo.exe" is OK but "foo" is an error. 61435 # 61436 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61437 # It is also a way to make sure we got the proper file name for the real test later on. 61438 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61439 if test "x$test_shortpath" = x; then 61440 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61441 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61442 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 61443 fi 61444 61445 # Call helper function which possibly converts this using DOS-style short mode. 61446 # If so, the updated path is stored in $new_path. 61447 61448 input_path="$new_path" 61449 # Check if we need to convert this using DOS-style short mode. If the path 61450 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61451 # take no chances and rewrite it. 61452 # Note: m4 eats our [], so we need to use [ and ] instead. 61453 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61454 if test "x$has_forbidden_chars" != x; then 61455 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61456 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61457 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61458 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61459 # Going to short mode and back again did indeed matter. Since short mode is 61460 # case insensitive, let's make it lowercase to improve readability. 61461 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61462 # Now convert it back to Unix-style (cygpath) 61463 input_path=`$CYGPATH -u "$shortmode_path"` 61464 new_path="$input_path" 61465 fi 61466 fi 61467 61468 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61469 if test "x$test_cygdrive_prefix" = x; then 61470 # As a simple fix, exclude /usr/bin since it's not a real path. 61471 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61472 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61473 # a path prefixed by /cygdrive for fixpath to work. 61474 new_path="$CYGWIN_ROOT_PATH$input_path" 61475 fi 61476 fi 61477 61478 61479 if test "x$path" != "x$new_path"; then 61480 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61481 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61482 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61483 fi 61484 61485 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61486 61487 path="$POTENTIAL_FREETYPE_LIB_PATH" 61488 has_colon=`$ECHO $path | $GREP ^.:` 61489 new_path="$path" 61490 if test "x$has_colon" = x; then 61491 # Not in mixed or Windows style, start by that. 61492 new_path=`cmd //c echo $path` 61493 fi 61494 61495 61496 input_path="$new_path" 61497 # Check if we need to convert this using DOS-style short mode. If the path 61498 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61499 # take no chances and rewrite it. 61500 # Note: m4 eats our [], so we need to use [ and ] instead. 61501 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 61502 if test "x$has_forbidden_chars" != x; then 61503 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61504 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61505 fi 61506 61507 61508 windows_path="$new_path" 61509 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61510 unix_path=`$CYGPATH -u "$windows_path"` 61511 new_path="$unix_path" 61512 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61513 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61514 new_path="$unix_path" 61515 fi 61516 61517 if test "x$path" != "x$new_path"; then 61518 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61519 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61520 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61521 fi 61522 61523 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61524 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61525 61526 else 61527 # We're on a unix platform. Hooray! :) 61528 path="$POTENTIAL_FREETYPE_LIB_PATH" 61529 has_space=`$ECHO "$path" | $GREP " "` 61530 if test "x$has_space" != x; then 61531 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61532 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61533 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61534 fi 61535 61536 # Use eval to expand a potential ~ 61537 eval path="$path" 61538 if test ! -f "$path" && test ! -d "$path"; then 61539 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61540 fi 61541 61542 if test -d "$path"; then 61543 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 61544 else 61545 dir="`$DIRNAME "$path"`" 61546 base="`$BASENAME "$path"`" 61547 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61548 fi 61549 fi 61550 fi 61551 61552 61553 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61554 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 61555 $as_echo_n "checking for freetype includes... " >&6; } 61556 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 61557 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 61558 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 61559 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 61560 $as_echo_n "checking for freetype libraries... " >&6; } 61561 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 61562 $as_echo "$FREETYPE_LIB_PATH" >&6; } 61563 fi 61564 61565 fi 61566 fi 61567 61568 if test "x$FOUND_FREETYPE" != xyes; then 61569 FREETYPE_BASE_DIR="$SYSROOT/usr" 61570 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 61571 61572 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 61573 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib/x86_64-linux-gnu" 61574 METHOD="well-known location" 61575 61576 # Let's start with an optimistic view of the world :-) 61577 FOUND_FREETYPE=yes 61578 61579 # First look for the canonical freetype main include file ft2build.h. 61580 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61581 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 61582 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 61583 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61584 # Fail. 61585 FOUND_FREETYPE=no 61586 fi 61587 fi 61588 61589 if test "x$FOUND_FREETYPE" = xyes; then 61590 # Include file found, let's continue the sanity check. 61591 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 61592 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 61593 61594 # Reset to default value 61595 FREETYPE_BASE_NAME=freetype 61596 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61597 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 61598 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 61599 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 61600 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 61601 # for the .6 version explicitly. 61602 FREETYPE_BASE_NAME=freetype.6 61603 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61604 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 61605 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 61606 else 61607 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 61608 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 61609 FOUND_FREETYPE=no 61610 fi 61611 else 61612 if test "x$OPENJDK_TARGET_OS" = xwindows; then 61613 # On Windows, we will need both .lib and .dll file. 61614 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 61615 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 61616 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 61617 FOUND_FREETYPE=no 61618 fi 61619 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 61620 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 61621 # Found lib in isa dir, use that instead. 61622 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 61623 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 61624 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 61625 fi 61626 fi 61627 fi 61628 61629 if test "x$FOUND_FREETYPE" = xyes; then 61630 61631 # Only process if variable expands to non-empty 61632 61633 if test "x$POTENTIAL_FREETYPE_INCLUDE_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_INCLUDE_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_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61651 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61652 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_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_INCLUDE_PATH="$new_path" 61691 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61692 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61693 fi 61694 61695 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61696 61697 path="$POTENTIAL_FREETYPE_INCLUDE_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_INCLUDE_PATH="$new_path" 61729 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61730 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_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_INCLUDE_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_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61742 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_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_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61750 fi 61751 61752 if test -d "$path"; then 61753 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 61754 else 61755 dir="`$DIRNAME "$path"`" 61756 base="`$BASENAME "$path"`" 61757 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61758 fi 61759 fi 61760 fi 61761 61762 61763 # Only process if variable expands to non-empty 61764 61765 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 61766 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61767 61768 # Input might be given as Windows format, start by converting to 61769 # unix format. 61770 path="$POTENTIAL_FREETYPE_LIB_PATH" 61771 new_path=`$CYGPATH -u "$path"` 61772 61773 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61774 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61775 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61776 # "foo.exe" is OK but "foo" is an error. 61777 # 61778 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61779 # It is also a way to make sure we got the proper file name for the real test later on. 61780 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61781 if test "x$test_shortpath" = x; then 61782 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61783 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61784 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 61785 fi 61786 61787 # Call helper function which possibly converts this using DOS-style short mode. 61788 # If so, the updated path is stored in $new_path. 61789 61790 input_path="$new_path" 61791 # Check if we need to convert this using DOS-style short mode. If the path 61792 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61793 # take no chances and rewrite it. 61794 # Note: m4 eats our [], so we need to use [ and ] instead. 61795 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61796 if test "x$has_forbidden_chars" != x; then 61797 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61798 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61799 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61800 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61801 # Going to short mode and back again did indeed matter. Since short mode is 61802 # case insensitive, let's make it lowercase to improve readability. 61803 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61804 # Now convert it back to Unix-style (cygpath) 61805 input_path=`$CYGPATH -u "$shortmode_path"` 61806 new_path="$input_path" 61807 fi 61808 fi 61809 61810 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61811 if test "x$test_cygdrive_prefix" = x; then 61812 # As a simple fix, exclude /usr/bin since it's not a real path. 61813 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61814 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61815 # a path prefixed by /cygdrive for fixpath to work. 61816 new_path="$CYGWIN_ROOT_PATH$input_path" 61817 fi 61818 fi 61819 61820 61821 if test "x$path" != "x$new_path"; then 61822 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61823 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61824 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61825 fi 61826 61827 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61828 61829 path="$POTENTIAL_FREETYPE_LIB_PATH" 61830 has_colon=`$ECHO $path | $GREP ^.:` 61831 new_path="$path" 61832 if test "x$has_colon" = x; then 61833 # Not in mixed or Windows style, start by that. 61834 new_path=`cmd //c echo $path` 61835 fi 61836 61837 61838 input_path="$new_path" 61839 # Check if we need to convert this using DOS-style short mode. If the path 61840 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61841 # take no chances and rewrite it. 61842 # Note: m4 eats our [], so we need to use [ and ] instead. 61843 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 61844 if test "x$has_forbidden_chars" != x; then 61845 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61846 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61847 fi 61848 61849 61850 windows_path="$new_path" 61851 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61852 unix_path=`$CYGPATH -u "$windows_path"` 61853 new_path="$unix_path" 61854 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61855 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61856 new_path="$unix_path" 61857 fi 61858 61859 if test "x$path" != "x$new_path"; then 61860 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61861 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61862 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61863 fi 61864 61865 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61866 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61867 61868 else 61869 # We're on a unix platform. Hooray! :) 61870 path="$POTENTIAL_FREETYPE_LIB_PATH" 61871 has_space=`$ECHO "$path" | $GREP " "` 61872 if test "x$has_space" != x; then 61873 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61874 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61875 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61876 fi 61877 61878 # Use eval to expand a potential ~ 61879 eval path="$path" 61880 if test ! -f "$path" && test ! -d "$path"; then 61881 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61882 fi 61883 61884 if test -d "$path"; then 61885 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 61886 else 61887 dir="`$DIRNAME "$path"`" 61888 base="`$BASENAME "$path"`" 61889 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61890 fi 61891 fi 61892 fi 61893 61894 61895 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61896 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 61897 $as_echo_n "checking for freetype includes... " >&6; } 61898 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 61899 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 61900 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 61901 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 61902 $as_echo_n "checking for freetype libraries... " >&6; } 61903 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 61904 $as_echo "$FREETYPE_LIB_PATH" >&6; } 61905 fi 61906 61907 else 61908 61909 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 61910 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib/i386-linux-gnu" 61911 METHOD="well-known location" 61912 61913 # Let's start with an optimistic view of the world :-) 61914 FOUND_FREETYPE=yes 61915 61916 # First look for the canonical freetype main include file ft2build.h. 61917 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61918 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 61919 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 61920 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61921 # Fail. 61922 FOUND_FREETYPE=no 61923 fi 61924 fi 61925 61926 if test "x$FOUND_FREETYPE" = xyes; then 61927 # Include file found, let's continue the sanity check. 61928 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 61929 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 61930 61931 # Reset to default value 61932 FREETYPE_BASE_NAME=freetype 61933 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61934 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 61935 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 61936 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 61937 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 61938 # for the .6 version explicitly. 61939 FREETYPE_BASE_NAME=freetype.6 61940 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61941 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 61942 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 61943 else 61944 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 61945 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 61946 FOUND_FREETYPE=no 61947 fi 61948 else 61949 if test "x$OPENJDK_TARGET_OS" = xwindows; then 61950 # On Windows, we will need both .lib and .dll file. 61951 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 61952 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 61953 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 61954 FOUND_FREETYPE=no 61955 fi 61956 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 61957 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 61958 # Found lib in isa dir, use that instead. 61959 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 61960 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 61961 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 61962 fi 61963 fi 61964 fi 61965 61966 if test "x$FOUND_FREETYPE" = xyes; then 61967 61968 # Only process if variable expands to non-empty 61969 61970 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 61971 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61972 61973 # Input might be given as Windows format, start by converting to 61974 # unix format. 61975 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61976 new_path=`$CYGPATH -u "$path"` 61977 61978 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61979 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61980 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61981 # "foo.exe" is OK but "foo" is an error. 61982 # 61983 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61984 # It is also a way to make sure we got the proper file name for the real test later on. 61985 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61986 if test "x$test_shortpath" = x; then 61987 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61988 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61989 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 61990 fi 61991 61992 # Call helper function which possibly converts this using DOS-style short mode. 61993 # If so, the updated path is stored in $new_path. 61994 61995 input_path="$new_path" 61996 # Check if we need to convert this using DOS-style short mode. If the path 61997 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61998 # take no chances and rewrite it. 61999 # Note: m4 eats our [], so we need to use [ and ] instead. 62000 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 62001 if test "x$has_forbidden_chars" != x; then 62002 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62003 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 62004 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 62005 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 62006 # Going to short mode and back again did indeed matter. Since short mode is 62007 # case insensitive, let's make it lowercase to improve readability. 62008 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62009 # Now convert it back to Unix-style (cygpath) 62010 input_path=`$CYGPATH -u "$shortmode_path"` 62011 new_path="$input_path" 62012 fi 62013 fi 62014 62015 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 62016 if test "x$test_cygdrive_prefix" = x; then 62017 # As a simple fix, exclude /usr/bin since it's not a real path. 62018 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 62019 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 62020 # a path prefixed by /cygdrive for fixpath to work. 62021 new_path="$CYGWIN_ROOT_PATH$input_path" 62022 fi 62023 fi 62024 62025 62026 if test "x$path" != "x$new_path"; then 62027 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 62028 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 62029 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 62030 fi 62031 62032 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62033 62034 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62035 has_colon=`$ECHO $path | $GREP ^.:` 62036 new_path="$path" 62037 if test "x$has_colon" = x; then 62038 # Not in mixed or Windows style, start by that. 62039 new_path=`cmd //c echo $path` 62040 fi 62041 62042 62043 input_path="$new_path" 62044 # Check if we need to convert this using DOS-style short mode. If the path 62045 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62046 # take no chances and rewrite it. 62047 # Note: m4 eats our [], so we need to use [ and ] instead. 62048 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 62049 if test "x$has_forbidden_chars" != x; then 62050 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62051 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62052 fi 62053 62054 62055 windows_path="$new_path" 62056 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62057 unix_path=`$CYGPATH -u "$windows_path"` 62058 new_path="$unix_path" 62059 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62060 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62061 new_path="$unix_path" 62062 fi 62063 62064 if test "x$path" != "x$new_path"; then 62065 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 62066 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 62067 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 62068 fi 62069 62070 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62071 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62072 62073 else 62074 # We're on a unix platform. Hooray! :) 62075 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62076 has_space=`$ECHO "$path" | $GREP " "` 62077 if test "x$has_space" != x; then 62078 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 62079 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 62080 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62081 fi 62082 62083 # Use eval to expand a potential ~ 62084 eval path="$path" 62085 if test ! -f "$path" && test ! -d "$path"; then 62086 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62087 fi 62088 62089 if test -d "$path"; then 62090 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 62091 else 62092 dir="`$DIRNAME "$path"`" 62093 base="`$BASENAME "$path"`" 62094 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62095 fi 62096 fi 62097 fi 62098 62099 62100 # Only process if variable expands to non-empty 62101 62102 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 62103 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62104 62105 # Input might be given as Windows format, start by converting to 62106 # unix format. 62107 path="$POTENTIAL_FREETYPE_LIB_PATH" 62108 new_path=`$CYGPATH -u "$path"` 62109 62110 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 62111 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 62112 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 62113 # "foo.exe" is OK but "foo" is an error. 62114 # 62115 # This test is therefore slightly more accurate than "test -f" to check for file precense. 62116 # It is also a way to make sure we got the proper file name for the real test later on. 62117 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 62118 if test "x$test_shortpath" = x; then 62119 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62120 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62121 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 62122 fi 62123 62124 # Call helper function which possibly converts this using DOS-style short mode. 62125 # If so, the updated path is stored in $new_path. 62126 62127 input_path="$new_path" 62128 # Check if we need to convert this using DOS-style short mode. If the path 62129 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62130 # take no chances and rewrite it. 62131 # Note: m4 eats our [], so we need to use [ and ] instead. 62132 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 62133 if test "x$has_forbidden_chars" != x; then 62134 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62135 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 62136 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 62137 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 62138 # Going to short mode and back again did indeed matter. Since short mode is 62139 # case insensitive, let's make it lowercase to improve readability. 62140 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62141 # Now convert it back to Unix-style (cygpath) 62142 input_path=`$CYGPATH -u "$shortmode_path"` 62143 new_path="$input_path" 62144 fi 62145 fi 62146 62147 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 62148 if test "x$test_cygdrive_prefix" = x; then 62149 # As a simple fix, exclude /usr/bin since it's not a real path. 62150 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 62151 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 62152 # a path prefixed by /cygdrive for fixpath to work. 62153 new_path="$CYGWIN_ROOT_PATH$input_path" 62154 fi 62155 fi 62156 62157 62158 if test "x$path" != "x$new_path"; then 62159 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 62160 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 62161 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62162 fi 62163 62164 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62165 62166 path="$POTENTIAL_FREETYPE_LIB_PATH" 62167 has_colon=`$ECHO $path | $GREP ^.:` 62168 new_path="$path" 62169 if test "x$has_colon" = x; then 62170 # Not in mixed or Windows style, start by that. 62171 new_path=`cmd //c echo $path` 62172 fi 62173 62174 62175 input_path="$new_path" 62176 # Check if we need to convert this using DOS-style short mode. If the path 62177 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62178 # take no chances and rewrite it. 62179 # Note: m4 eats our [], so we need to use [ and ] instead. 62180 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 62181 if test "x$has_forbidden_chars" != x; then 62182 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62183 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62184 fi 62185 62186 62187 windows_path="$new_path" 62188 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62189 unix_path=`$CYGPATH -u "$windows_path"` 62190 new_path="$unix_path" 62191 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62192 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62193 new_path="$unix_path" 62194 fi 62195 62196 if test "x$path" != "x$new_path"; then 62197 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 62198 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 62199 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62200 fi 62201 62202 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62203 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62204 62205 else 62206 # We're on a unix platform. Hooray! :) 62207 path="$POTENTIAL_FREETYPE_LIB_PATH" 62208 has_space=`$ECHO "$path" | $GREP " "` 62209 if test "x$has_space" != x; then 62210 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62211 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62212 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62213 fi 62214 62215 # Use eval to expand a potential ~ 62216 eval path="$path" 62217 if test ! -f "$path" && test ! -d "$path"; then 62218 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62219 fi 62220 62221 if test -d "$path"; then 62222 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 62223 else 62224 dir="`$DIRNAME "$path"`" 62225 base="`$BASENAME "$path"`" 62226 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62227 fi 62228 fi 62229 fi 62230 62231 62232 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62233 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 62234 $as_echo_n "checking for freetype includes... " >&6; } 62235 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 62236 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 62237 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 62238 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 62239 $as_echo_n "checking for freetype libraries... " >&6; } 62240 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 62241 $as_echo "$FREETYPE_LIB_PATH" >&6; } 62242 fi 62243 62244 if test "x$FOUND_FREETYPE" != xyes; then 62245 62246 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 62247 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib32" 62248 METHOD="well-known location" 62249 62250 # Let's start with an optimistic view of the world :-) 62251 FOUND_FREETYPE=yes 62252 62253 # First look for the canonical freetype main include file ft2build.h. 62254 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 62255 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 62256 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 62257 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 62258 # Fail. 62259 FOUND_FREETYPE=no 62260 fi 62261 fi 62262 62263 if test "x$FOUND_FREETYPE" = xyes; then 62264 # Include file found, let's continue the sanity check. 62265 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 62266 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 62267 62268 # Reset to default value 62269 FREETYPE_BASE_NAME=freetype 62270 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 62271 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 62272 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 62273 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 62274 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 62275 # for the .6 version explicitly. 62276 FREETYPE_BASE_NAME=freetype.6 62277 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 62278 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 62279 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 62280 else 62281 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 62282 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 62283 FOUND_FREETYPE=no 62284 fi 62285 else 62286 if test "x$OPENJDK_TARGET_OS" = xwindows; then 62287 # On Windows, we will need both .lib and .dll file. 62288 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 62289 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 62290 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 62291 FOUND_FREETYPE=no 62292 fi 62293 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 62294 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 62295 # Found lib in isa dir, use that instead. 62296 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 62297 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 62298 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 62299 fi 62300 fi 62301 fi 62302 62303 if test "x$FOUND_FREETYPE" = xyes; then 62304 62305 # Only process if variable expands to non-empty 62306 62307 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 62308 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62309 62310 # Input might be given as Windows format, start by converting to 62311 # unix format. 62312 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62313 new_path=`$CYGPATH -u "$path"` 62314 62315 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 62316 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 62317 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 62318 # "foo.exe" is OK but "foo" is an error. 62319 # 62320 # This test is therefore slightly more accurate than "test -f" to check for file precense. 62321 # It is also a way to make sure we got the proper file name for the real test later on. 62322 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 62323 if test "x$test_shortpath" = x; then 62324 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 62325 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 62326 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 62327 fi 62328 62329 # Call helper function which possibly converts this using DOS-style short mode. 62330 # If so, the updated path is stored in $new_path. 62331 62332 input_path="$new_path" 62333 # Check if we need to convert this using DOS-style short mode. If the path 62334 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62335 # take no chances and rewrite it. 62336 # Note: m4 eats our [], so we need to use [ and ] instead. 62337 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 62338 if test "x$has_forbidden_chars" != x; then 62339 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62340 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 62341 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 62342 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 62343 # Going to short mode and back again did indeed matter. Since short mode is 62344 # case insensitive, let's make it lowercase to improve readability. 62345 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62346 # Now convert it back to Unix-style (cygpath) 62347 input_path=`$CYGPATH -u "$shortmode_path"` 62348 new_path="$input_path" 62349 fi 62350 fi 62351 62352 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 62353 if test "x$test_cygdrive_prefix" = x; then 62354 # As a simple fix, exclude /usr/bin since it's not a real path. 62355 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 62356 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 62357 # a path prefixed by /cygdrive for fixpath to work. 62358 new_path="$CYGWIN_ROOT_PATH$input_path" 62359 fi 62360 fi 62361 62362 62363 if test "x$path" != "x$new_path"; then 62364 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 62365 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 62366 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 62367 fi 62368 62369 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62370 62371 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62372 has_colon=`$ECHO $path | $GREP ^.:` 62373 new_path="$path" 62374 if test "x$has_colon" = x; then 62375 # Not in mixed or Windows style, start by that. 62376 new_path=`cmd //c echo $path` 62377 fi 62378 62379 62380 input_path="$new_path" 62381 # Check if we need to convert this using DOS-style short mode. If the path 62382 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62383 # take no chances and rewrite it. 62384 # Note: m4 eats our [], so we need to use [ and ] instead. 62385 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 62386 if test "x$has_forbidden_chars" != x; then 62387 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62388 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62389 fi 62390 62391 62392 windows_path="$new_path" 62393 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62394 unix_path=`$CYGPATH -u "$windows_path"` 62395 new_path="$unix_path" 62396 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62397 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62398 new_path="$unix_path" 62399 fi 62400 62401 if test "x$path" != "x$new_path"; then 62402 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 62403 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 62404 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 62405 fi 62406 62407 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62408 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62409 62410 else 62411 # We're on a unix platform. Hooray! :) 62412 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62413 has_space=`$ECHO "$path" | $GREP " "` 62414 if test "x$has_space" != x; then 62415 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 62416 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 62417 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62418 fi 62419 62420 # Use eval to expand a potential ~ 62421 eval path="$path" 62422 if test ! -f "$path" && test ! -d "$path"; then 62423 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62424 fi 62425 62426 if test -d "$path"; then 62427 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 62428 else 62429 dir="`$DIRNAME "$path"`" 62430 base="`$BASENAME "$path"`" 62431 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62432 fi 62433 fi 62434 fi 62435 62436 62437 # Only process if variable expands to non-empty 62438 62439 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 62440 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62441 62442 # Input might be given as Windows format, start by converting to 62443 # unix format. 62444 path="$POTENTIAL_FREETYPE_LIB_PATH" 62445 new_path=`$CYGPATH -u "$path"` 62446 62447 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 62448 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 62449 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 62450 # "foo.exe" is OK but "foo" is an error. 62451 # 62452 # This test is therefore slightly more accurate than "test -f" to check for file precense. 62453 # It is also a way to make sure we got the proper file name for the real test later on. 62454 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 62455 if test "x$test_shortpath" = x; then 62456 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62457 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62458 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 62459 fi 62460 62461 # Call helper function which possibly converts this using DOS-style short mode. 62462 # If so, the updated path is stored in $new_path. 62463 62464 input_path="$new_path" 62465 # Check if we need to convert this using DOS-style short mode. If the path 62466 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62467 # take no chances and rewrite it. 62468 # Note: m4 eats our [], so we need to use [ and ] instead. 62469 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 62470 if test "x$has_forbidden_chars" != x; then 62471 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62472 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 62473 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 62474 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 62475 # Going to short mode and back again did indeed matter. Since short mode is 62476 # case insensitive, let's make it lowercase to improve readability. 62477 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62478 # Now convert it back to Unix-style (cygpath) 62479 input_path=`$CYGPATH -u "$shortmode_path"` 62480 new_path="$input_path" 62481 fi 62482 fi 62483 62484 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 62485 if test "x$test_cygdrive_prefix" = x; then 62486 # As a simple fix, exclude /usr/bin since it's not a real path. 62487 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 62488 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 62489 # a path prefixed by /cygdrive for fixpath to work. 62490 new_path="$CYGWIN_ROOT_PATH$input_path" 62491 fi 62492 fi 62493 62494 62495 if test "x$path" != "x$new_path"; then 62496 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 62497 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 62498 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62499 fi 62500 62501 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62502 62503 path="$POTENTIAL_FREETYPE_LIB_PATH" 62504 has_colon=`$ECHO $path | $GREP ^.:` 62505 new_path="$path" 62506 if test "x$has_colon" = x; then 62507 # Not in mixed or Windows style, start by that. 62508 new_path=`cmd //c echo $path` 62509 fi 62510 62511 62512 input_path="$new_path" 62513 # Check if we need to convert this using DOS-style short mode. If the path 62514 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62515 # take no chances and rewrite it. 62516 # Note: m4 eats our [], so we need to use [ and ] instead. 62517 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 62518 if test "x$has_forbidden_chars" != x; then 62519 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62520 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62521 fi 62522 62523 62524 windows_path="$new_path" 62525 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62526 unix_path=`$CYGPATH -u "$windows_path"` 62527 new_path="$unix_path" 62528 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62529 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62530 new_path="$unix_path" 62531 fi 62532 62533 if test "x$path" != "x$new_path"; then 62534 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 62535 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 62536 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62537 fi 62538 62539 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62540 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62541 62542 else 62543 # We're on a unix platform. Hooray! :) 62544 path="$POTENTIAL_FREETYPE_LIB_PATH" 62545 has_space=`$ECHO "$path" | $GREP " "` 62546 if test "x$has_space" != x; then 62547 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62548 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62549 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62550 fi 62551 62552 # Use eval to expand a potential ~ 62553 eval path="$path" 62554 if test ! -f "$path" && test ! -d "$path"; then 62555 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62556 fi 62557 62558 if test -d "$path"; then 62559 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 62560 else 62561 dir="`$DIRNAME "$path"`" 62562 base="`$BASENAME "$path"`" 62563 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62564 fi 62565 fi 62566 fi 62567 62568 62569 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62570 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 62571 $as_echo_n "checking for freetype includes... " >&6; } 62572 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 62573 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 62574 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 62575 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 62576 $as_echo_n "checking for freetype libraries... " >&6; } 62577 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 62578 $as_echo "$FREETYPE_LIB_PATH" >&6; } 62579 fi 62580 62581 fi 62582 fi 62583 fi 62584 fi 62585 fi # end check in well-known locations 62586 62587 if test "x$FOUND_FREETYPE" != xyes; then 62588 62589 # Print a helpful message on how to acquire the necessary build dependency. 62590 # freetype is the help tag: freetype, cups, alsa etc 62591 MISSING_DEPENDENCY=freetype 62592 62593 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62594 cygwin_help $MISSING_DEPENDENCY 62595 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62596 msys_help $MISSING_DEPENDENCY 62597 else 62598 PKGHANDLER_COMMAND= 62599 62600 case $PKGHANDLER in 62601 apt-get) 62602 apt_help $MISSING_DEPENDENCY ;; 62603 yum) 62604 yum_help $MISSING_DEPENDENCY ;; 62605 brew) 62606 brew_help $MISSING_DEPENDENCY ;; 62607 port) 62608 port_help $MISSING_DEPENDENCY ;; 62609 pkgutil) 62610 pkgutil_help $MISSING_DEPENDENCY ;; 62611 pkgadd) 62612 pkgadd_help $MISSING_DEPENDENCY ;; 62613 esac 62614 62615 if test "x$PKGHANDLER_COMMAND" != x; then 62616 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 62617 fi 62618 fi 62619 62620 as_fn_error $? "Could not find freetype! $HELP_MSG " "$LINENO" 5 62621 fi 62622 fi # end user specified settings 62623 62624 # Set FREETYPE_CFLAGS, _LIBS and _LIB_PATH from include and lib dir. 62625 if test "x$FREETYPE_CFLAGS" = x; then 62626 62627 # Only process if variable expands to non-empty 62628 62629 if test "x$FREETYPE_INCLUDE_PATH" != x; then 62630 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62631 62632 # Input might be given as Windows format, start by converting to 62633 # unix format. 62634 path="$FREETYPE_INCLUDE_PATH" 62635 new_path=`$CYGPATH -u "$path"` 62636 62637 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 62638 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 62639 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 62640 # "foo.exe" is OK but "foo" is an error. 62641 # 62642 # This test is therefore slightly more accurate than "test -f" to check for file precense. 62643 # It is also a way to make sure we got the proper file name for the real test later on. 62644 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 62645 if test "x$test_shortpath" = x; then 62646 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 62647 $as_echo "$as_me: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 62648 as_fn_error $? "Cannot locate the the path of FREETYPE_INCLUDE_PATH" "$LINENO" 5 62649 fi 62650 62651 # Call helper function which possibly converts this using DOS-style short mode. 62652 # If so, the updated path is stored in $new_path. 62653 62654 input_path="$new_path" 62655 # Check if we need to convert this using DOS-style short mode. If the path 62656 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62657 # take no chances and rewrite it. 62658 # Note: m4 eats our [], so we need to use [ and ] instead. 62659 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 62660 if test "x$has_forbidden_chars" != x; then 62661 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62662 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 62663 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 62664 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 62665 # Going to short mode and back again did indeed matter. Since short mode is 62666 # case insensitive, let's make it lowercase to improve readability. 62667 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62668 # Now convert it back to Unix-style (cygpath) 62669 input_path=`$CYGPATH -u "$shortmode_path"` 62670 new_path="$input_path" 62671 fi 62672 fi 62673 62674 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 62675 if test "x$test_cygdrive_prefix" = x; then 62676 # As a simple fix, exclude /usr/bin since it's not a real path. 62677 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 62678 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 62679 # a path prefixed by /cygdrive for fixpath to work. 62680 new_path="$CYGWIN_ROOT_PATH$input_path" 62681 fi 62682 fi 62683 62684 62685 if test "x$path" != "x$new_path"; then 62686 FREETYPE_INCLUDE_PATH="$new_path" 62687 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 62688 $as_echo "$as_me: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 62689 fi 62690 62691 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62692 62693 path="$FREETYPE_INCLUDE_PATH" 62694 has_colon=`$ECHO $path | $GREP ^.:` 62695 new_path="$path" 62696 if test "x$has_colon" = x; then 62697 # Not in mixed or Windows style, start by that. 62698 new_path=`cmd //c echo $path` 62699 fi 62700 62701 62702 input_path="$new_path" 62703 # Check if we need to convert this using DOS-style short mode. If the path 62704 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62705 # take no chances and rewrite it. 62706 # Note: m4 eats our [], so we need to use [ and ] instead. 62707 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 62708 if test "x$has_forbidden_chars" != x; then 62709 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62710 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62711 fi 62712 62713 62714 windows_path="$new_path" 62715 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62716 unix_path=`$CYGPATH -u "$windows_path"` 62717 new_path="$unix_path" 62718 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62719 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62720 new_path="$unix_path" 62721 fi 62722 62723 if test "x$path" != "x$new_path"; then 62724 FREETYPE_INCLUDE_PATH="$new_path" 62725 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 62726 $as_echo "$as_me: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 62727 fi 62728 62729 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62730 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62731 62732 else 62733 # We're on a unix platform. Hooray! :) 62734 path="$FREETYPE_INCLUDE_PATH" 62735 has_space=`$ECHO "$path" | $GREP " "` 62736 if test "x$has_space" != x; then 62737 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 62738 $as_echo "$as_me: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 62739 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62740 fi 62741 62742 # Use eval to expand a potential ~ 62743 eval path="$path" 62744 if test ! -f "$path" && test ! -d "$path"; then 62745 as_fn_error $? "The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62746 fi 62747 62748 if test -d "$path"; then 62749 FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 62750 else 62751 dir="`$DIRNAME "$path"`" 62752 base="`$BASENAME "$path"`" 62753 FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62754 fi 62755 fi 62756 fi 62757 62758 if test -d $FREETYPE_INCLUDE_PATH/freetype2/freetype; then 62759 FREETYPE_CFLAGS="-I$FREETYPE_INCLUDE_PATH/freetype2 -I$FREETYPE_INCLUDE_PATH" 62760 else 62761 FREETYPE_CFLAGS="-I$FREETYPE_INCLUDE_PATH" 62762 fi 62763 fi 62764 62765 if test "x$FREETYPE_LIBS" = x; then 62766 62767 # Only process if variable expands to non-empty 62768 62769 if test "x$FREETYPE_LIB_PATH" != x; then 62770 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62771 62772 # Input might be given as Windows format, start by converting to 62773 # unix format. 62774 path="$FREETYPE_LIB_PATH" 62775 new_path=`$CYGPATH -u "$path"` 62776 62777 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 62778 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 62779 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 62780 # "foo.exe" is OK but "foo" is an error. 62781 # 62782 # This test is therefore slightly more accurate than "test -f" to check for file precense. 62783 # It is also a way to make sure we got the proper file name for the real test later on. 62784 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 62785 if test "x$test_shortpath" = x; then 62786 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62787 $as_echo "$as_me: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62788 as_fn_error $? "Cannot locate the the path of FREETYPE_LIB_PATH" "$LINENO" 5 62789 fi 62790 62791 # Call helper function which possibly converts this using DOS-style short mode. 62792 # If so, the updated path is stored in $new_path. 62793 62794 input_path="$new_path" 62795 # Check if we need to convert this using DOS-style short mode. If the path 62796 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62797 # take no chances and rewrite it. 62798 # Note: m4 eats our [], so we need to use [ and ] instead. 62799 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 62800 if test "x$has_forbidden_chars" != x; then 62801 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62802 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 62803 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 62804 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 62805 # Going to short mode and back again did indeed matter. Since short mode is 62806 # case insensitive, let's make it lowercase to improve readability. 62807 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62808 # Now convert it back to Unix-style (cygpath) 62809 input_path=`$CYGPATH -u "$shortmode_path"` 62810 new_path="$input_path" 62811 fi 62812 fi 62813 62814 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 62815 if test "x$test_cygdrive_prefix" = x; then 62816 # As a simple fix, exclude /usr/bin since it's not a real path. 62817 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 62818 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 62819 # a path prefixed by /cygdrive for fixpath to work. 62820 new_path="$CYGWIN_ROOT_PATH$input_path" 62821 fi 62822 fi 62823 62824 62825 if test "x$path" != "x$new_path"; then 62826 FREETYPE_LIB_PATH="$new_path" 62827 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&5 62828 $as_echo "$as_me: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62829 fi 62830 62831 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62832 62833 path="$FREETYPE_LIB_PATH" 62834 has_colon=`$ECHO $path | $GREP ^.:` 62835 new_path="$path" 62836 if test "x$has_colon" = x; then 62837 # Not in mixed or Windows style, start by that. 62838 new_path=`cmd //c echo $path` 62839 fi 62840 62841 62842 input_path="$new_path" 62843 # Check if we need to convert this using DOS-style short mode. If the path 62844 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62845 # take no chances and rewrite it. 62846 # Note: m4 eats our [], so we need to use [ and ] instead. 62847 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 62848 if test "x$has_forbidden_chars" != x; then 62849 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62850 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62851 fi 62852 62853 62854 windows_path="$new_path" 62855 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62856 unix_path=`$CYGPATH -u "$windows_path"` 62857 new_path="$unix_path" 62858 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62859 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62860 new_path="$unix_path" 62861 fi 62862 62863 if test "x$path" != "x$new_path"; then 62864 FREETYPE_LIB_PATH="$new_path" 62865 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&5 62866 $as_echo "$as_me: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62867 fi 62868 62869 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62870 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62871 62872 else 62873 # We're on a unix platform. Hooray! :) 62874 path="$FREETYPE_LIB_PATH" 62875 has_space=`$ECHO "$path" | $GREP " "` 62876 if test "x$has_space" != x; then 62877 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62878 $as_echo "$as_me: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62879 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62880 fi 62881 62882 # Use eval to expand a potential ~ 62883 eval path="$path" 62884 if test ! -f "$path" && test ! -d "$path"; then 62885 as_fn_error $? "The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62886 fi 62887 62888 if test -d "$path"; then 62889 FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 62890 else 62891 dir="`$DIRNAME "$path"`" 62892 base="`$BASENAME "$path"`" 62893 FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62894 fi 62895 fi 62896 fi 62897 62898 if test "x$OPENJDK_TARGET_OS" = xwindows; then 62899 FREETYPE_LIBS="$FREETYPE_LIB_PATH/$FREETYPE_BASE_NAME.lib" 62900 else 62901 FREETYPE_LIBS="-L$FREETYPE_LIB_PATH -l$FREETYPE_BASE_NAME" 62902 fi 62903 fi 62904 62905 # Try to compile it 62906 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can compile and link with freetype" >&5 62907 $as_echo_n "checking if we can compile and link with freetype... " >&6; } 62908 ac_ext=cpp 62909 ac_cpp='$CXXCPP $CPPFLAGS' 62910 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 62911 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 62912 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 62913 62914 PREV_CXXCFLAGS="$CXXFLAGS" 62915 PREV_LIBS="$LIBS" 62916 PREV_CXX="$CXX" 62917 CXXFLAGS="$CXXFLAGS $FREETYPE_CFLAGS" 62918 LIBS="$LIBS $FREETYPE_LIBS" 62919 CXX="$FIXPATH $CXX" 62920 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 62921 /* end confdefs.h. */ 62922 62923 #include<ft2build.h> 62924 #include FT_FREETYPE_H 62925 int main () { 62926 FT_Init_FreeType(NULL); 62927 return 0; 62928 } 62929 62930 _ACEOF 62931 if ac_fn_cxx_try_link "$LINENO"; then : 62932 62933 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 62934 $as_echo "yes" >&6; } 62935 62936 else 62937 62938 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 62939 $as_echo "no" >&6; } 62940 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not compile and link with freetype. This might be a 32/64-bit mismatch." >&5 62941 $as_echo "$as_me: Could not compile and link with freetype. This might be a 32/64-bit mismatch." >&6;} 62942 { $as_echo "$as_me:${as_lineno-$LINENO}: Using FREETYPE_CFLAGS=$FREETYPE_CFLAGS and FREETYPE_LIBS=$FREETYPE_LIBS" >&5 62943 $as_echo "$as_me: Using FREETYPE_CFLAGS=$FREETYPE_CFLAGS and FREETYPE_LIBS=$FREETYPE_LIBS" >&6;} 62944 62945 62946 # Print a helpful message on how to acquire the necessary build dependency. 62947 # freetype is the help tag: freetype, cups, alsa etc 62948 MISSING_DEPENDENCY=freetype 62949 62950 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62951 cygwin_help $MISSING_DEPENDENCY 62952 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62953 msys_help $MISSING_DEPENDENCY 62954 else 62955 PKGHANDLER_COMMAND= 62956 62957 case $PKGHANDLER in 62958 apt-get) 62959 apt_help $MISSING_DEPENDENCY ;; 62960 yum) 62961 yum_help $MISSING_DEPENDENCY ;; 62962 brew) 62963 brew_help $MISSING_DEPENDENCY ;; 62964 port) 62965 port_help $MISSING_DEPENDENCY ;; 62966 pkgutil) 62967 pkgutil_help $MISSING_DEPENDENCY ;; 62968 pkgadd) 62969 pkgadd_help $MISSING_DEPENDENCY ;; 62970 esac 62971 62972 if test "x$PKGHANDLER_COMMAND" != x; then 62973 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 62974 fi 62975 fi 62976 62977 62978 as_fn_error $? "Can not continue without freetype. $HELP_MSG" "$LINENO" 5 62979 62980 62981 fi 62982 rm -f core conftest.err conftest.$ac_objext \ 62983 conftest$ac_exeext conftest.$ac_ext 62984 CXXCFLAGS="$PREV_CXXFLAGS" 62985 LIBS="$PREV_LIBS" 62986 CXX="$PREV_CXX" 62987 ac_ext=cpp 62988 ac_cpp='$CXXCPP $CPPFLAGS' 62989 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 62990 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 62991 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 62992 62993 62994 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should bundle freetype" >&5 62995 $as_echo_n "checking if we should bundle freetype... " >&6; } 62996 if test "x$BUNDLE_FREETYPE" = xyes; then 62997 FREETYPE_BUNDLE_LIB_PATH="$FREETYPE_LIB_PATH" 62998 fi 62999 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUNDLE_FREETYPE" >&5 63000 $as_echo "$BUNDLE_FREETYPE" >&6; } 63001 63002 fi # end freetype needed 63003 63004 63005 63006 63007 63008 63009 63010 # Check whether --with-alsa was given. 63011 if test "${with_alsa+set}" = set; then : 63012 withval=$with_alsa; 63013 fi 63014 63015 63016 # Check whether --with-alsa-include was given. 63017 if test "${with_alsa_include+set}" = set; then : 63018 withval=$with_alsa_include; 63019 fi 63020 63021 63022 # Check whether --with-alsa-lib was given. 63023 if test "${with_alsa_lib+set}" = set; then : 63024 withval=$with_alsa_lib; 63025 fi 63026 63027 63028 if test "x$NEEDS_LIB_ALSA" = xfalse; then 63029 if (test "x${with_alsa}" != x && test "x${with_alsa}" != xno) || \ 63030 (test "x${with_alsa_include}" != x && test "x${with_alsa_include}" != xno) || \ 63031 (test "x${with_alsa_lib}" != x && test "x${with_alsa_lib}" != xno); then 63032 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: alsa not used, so --with-alsa[-*] is ignored" >&5 63033 $as_echo "$as_me: WARNING: alsa not used, so --with-alsa[-*] is ignored" >&2;} 63034 fi 63035 ALSA_CFLAGS= 63036 ALSA_LIBS= 63037 else 63038 ALSA_FOUND=no 63039 63040 if test "x${with_alsa}" = xno || test "x${with_alsa_include}" = xno || test "x${with_alsa_lib}" = xno; then 63041 as_fn_error $? "It is not possible to disable the use of alsa. Remove the --without-alsa option." "$LINENO" 5 63042 fi 63043 63044 if test "x${with_alsa}" != x; then 63045 ALSA_LIBS="-L${with_alsa}/lib -lasound" 63046 ALSA_CFLAGS="-I${with_alsa}/include" 63047 ALSA_FOUND=yes 63048 fi 63049 if test "x${with_alsa_include}" != x; then 63050 ALSA_CFLAGS="-I${with_alsa_include}" 63051 ALSA_FOUND=yes 63052 fi 63053 if test "x${with_alsa_lib}" != x; then 63054 ALSA_LIBS="-L${with_alsa_lib} -lasound" 63055 ALSA_FOUND=yes 63056 fi 63057 # Do not try pkg-config if we have a sysroot set. 63058 if test "x$SYSROOT" = x; then 63059 if test "x$ALSA_FOUND" = xno; then 63060 63061 pkg_failed=no 63062 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ALSA" >&5 63063 $as_echo_n "checking for ALSA... " >&6; } 63064 63065 if test -n "$ALSA_CFLAGS"; then 63066 pkg_cv_ALSA_CFLAGS="$ALSA_CFLAGS" 63067 elif test -n "$PKG_CONFIG"; then 63068 if test -n "$PKG_CONFIG" && \ 63069 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"alsa\""; } >&5 63070 ($PKG_CONFIG --exists --print-errors "alsa") 2>&5 63071 ac_status=$? 63072 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 63073 test $ac_status = 0; }; then 63074 pkg_cv_ALSA_CFLAGS=`$PKG_CONFIG --cflags "alsa" 2>/dev/null` 63075 else 63076 pkg_failed=yes 63077 fi 63078 else 63079 pkg_failed=untried 63080 fi 63081 if test -n "$ALSA_LIBS"; then 63082 pkg_cv_ALSA_LIBS="$ALSA_LIBS" 63083 elif test -n "$PKG_CONFIG"; then 63084 if test -n "$PKG_CONFIG" && \ 63085 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"alsa\""; } >&5 63086 ($PKG_CONFIG --exists --print-errors "alsa") 2>&5 63087 ac_status=$? 63088 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 63089 test $ac_status = 0; }; then 63090 pkg_cv_ALSA_LIBS=`$PKG_CONFIG --libs "alsa" 2>/dev/null` 63091 else 63092 pkg_failed=yes 63093 fi 63094 else 63095 pkg_failed=untried 63096 fi 63097 63098 63099 63100 if test $pkg_failed = yes; then 63101 63102 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 63103 _pkg_short_errors_supported=yes 63104 else 63105 _pkg_short_errors_supported=no 63106 fi 63107 if test $_pkg_short_errors_supported = yes; then 63108 ALSA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "alsa" 2>&1` 63109 else 63110 ALSA_PKG_ERRORS=`$PKG_CONFIG --print-errors "alsa" 2>&1` 63111 fi 63112 # Put the nasty error message in config.log where it belongs 63113 echo "$ALSA_PKG_ERRORS" >&5 63114 63115 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 63116 $as_echo "no" >&6; } 63117 ALSA_FOUND=no 63118 elif test $pkg_failed = untried; then 63119 ALSA_FOUND=no 63120 else 63121 ALSA_CFLAGS=$pkg_cv_ALSA_CFLAGS 63122 ALSA_LIBS=$pkg_cv_ALSA_LIBS 63123 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 63124 $as_echo "yes" >&6; } 63125 ALSA_FOUND=yes 63126 fi 63127 fi 63128 fi 63129 if test "x$ALSA_FOUND" = xno; then 63130 for ac_header in alsa/asoundlib.h 63131 do : 63132 ac_fn_cxx_check_header_mongrel "$LINENO" "alsa/asoundlib.h" "ac_cv_header_alsa_asoundlib_h" "$ac_includes_default" 63133 if test "x$ac_cv_header_alsa_asoundlib_h" = xyes; then : 63134 cat >>confdefs.h <<_ACEOF 63135 #define HAVE_ALSA_ASOUNDLIB_H 1 63136 _ACEOF 63137 63138 ALSA_FOUND=yes 63139 ALSA_CFLAGS=-Iignoreme 63140 ALSA_LIBS=-lasound 63141 DEFAULT_ALSA=yes 63142 63143 else 63144 ALSA_FOUND=no 63145 63146 fi 63147 63148 done 63149 63150 fi 63151 if test "x$ALSA_FOUND" = xno; then 63152 63153 # Print a helpful message on how to acquire the necessary build dependency. 63154 # alsa is the help tag: freetype, cups, alsa etc 63155 MISSING_DEPENDENCY=alsa 63156 63157 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63158 cygwin_help $MISSING_DEPENDENCY 63159 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63160 msys_help $MISSING_DEPENDENCY 63161 else 63162 PKGHANDLER_COMMAND= 63163 63164 case $PKGHANDLER in 63165 apt-get) 63166 apt_help $MISSING_DEPENDENCY ;; 63167 yum) 63168 yum_help $MISSING_DEPENDENCY ;; 63169 brew) 63170 brew_help $MISSING_DEPENDENCY ;; 63171 port) 63172 port_help $MISSING_DEPENDENCY ;; 63173 pkgutil) 63174 pkgutil_help $MISSING_DEPENDENCY ;; 63175 pkgadd) 63176 pkgadd_help $MISSING_DEPENDENCY ;; 63177 esac 63178 63179 if test "x$PKGHANDLER_COMMAND" != x; then 63180 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 63181 fi 63182 fi 63183 63184 as_fn_error $? "Could not find alsa! $HELP_MSG" "$LINENO" 5 63185 fi 63186 fi 63187 63188 63189 63190 63191 63192 63193 # Check whether --with-libffi was given. 63194 if test "${with_libffi+set}" = set; then : 63195 withval=$with_libffi; 63196 fi 63197 63198 63199 # Check whether --with-libffi-include was given. 63200 if test "${with_libffi_include+set}" = set; then : 63201 withval=$with_libffi_include; 63202 fi 63203 63204 63205 # Check whether --with-libffi-lib was given. 63206 if test "${with_libffi_lib+set}" = set; then : 63207 withval=$with_libffi_lib; 63208 fi 63209 63210 # Check whether --enable-libffi-bundling was given. 63211 if test "${enable_libffi_bundling+set}" = set; then : 63212 enableval=$enable_libffi_bundling; 63213 fi 63214 63215 63216 if test "x$NEEDS_LIB_FFI" = xfalse; then 63217 if (test "x${with_libffi}" != x && test "x${with_libffi}" != xno) || \ 63218 (test "x${with_libffi_include}" != x && test "x${with_libffi_include}" != xno) || \ 63219 (test "x${with_libffi_lib}" != x && test "x${with_libffi_lib}" != xno); then 63220 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libffi not used, so --with-libffi[-*] is ignored" >&5 63221 $as_echo "$as_me: WARNING: libffi not used, so --with-libffi[-*] is ignored" >&2;} 63222 fi 63223 LIBFFI_CFLAGS= 63224 LIBFFI_LIBS= 63225 else 63226 LIBFFI_FOUND=no 63227 63228 if test "x${with_libffi}" = xno || test "x${with_libffi_include}" = xno || test "x${with_libffi_lib}" = xno; then 63229 as_fn_error $? "It is not possible to disable the use of libffi. Remove the --without-libffi option." "$LINENO" 5 63230 fi 63231 63232 if test "x${with_libffi}" != x; then 63233 LIBFFI_LIB_PATH="${with_libffi}/lib" 63234 LIBFFI_LIBS="-L${with_libffi}/lib -lffi" 63235 LIBFFI_CFLAGS="-I${with_libffi}/include" 63236 LIBFFI_FOUND=yes 63237 fi 63238 if test "x${with_libffi_include}" != x; then 63239 LIBFFI_CFLAGS="-I${with_libffi_include}" 63240 LIBFFI_FOUND=yes 63241 fi 63242 if test "x${with_libffi_lib}" != x; then 63243 LIBFFI_LIB_PATH="${with_libffi_lib}" 63244 LIBFFI_LIBS="-L${with_libffi_lib} -lffi" 63245 LIBFFI_FOUND=yes 63246 fi 63247 # Do not try pkg-config if we have a sysroot set. 63248 if test "x$SYSROOT" = x; then 63249 if test "x$LIBFFI_FOUND" = xno; then 63250 # Figure out LIBFFI_CFLAGS and LIBFFI_LIBS 63251 63252 pkg_failed=no 63253 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIBFFI" >&5 63254 $as_echo_n "checking for LIBFFI... " >&6; } 63255 63256 if test -n "$LIBFFI_CFLAGS"; then 63257 pkg_cv_LIBFFI_CFLAGS="$LIBFFI_CFLAGS" 63258 elif test -n "$PKG_CONFIG"; then 63259 if test -n "$PKG_CONFIG" && \ 63260 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libffi\""; } >&5 63261 ($PKG_CONFIG --exists --print-errors "libffi") 2>&5 63262 ac_status=$? 63263 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 63264 test $ac_status = 0; }; then 63265 pkg_cv_LIBFFI_CFLAGS=`$PKG_CONFIG --cflags "libffi" 2>/dev/null` 63266 else 63267 pkg_failed=yes 63268 fi 63269 else 63270 pkg_failed=untried 63271 fi 63272 if test -n "$LIBFFI_LIBS"; then 63273 pkg_cv_LIBFFI_LIBS="$LIBFFI_LIBS" 63274 elif test -n "$PKG_CONFIG"; then 63275 if test -n "$PKG_CONFIG" && \ 63276 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libffi\""; } >&5 63277 ($PKG_CONFIG --exists --print-errors "libffi") 2>&5 63278 ac_status=$? 63279 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 63280 test $ac_status = 0; }; then 63281 pkg_cv_LIBFFI_LIBS=`$PKG_CONFIG --libs "libffi" 2>/dev/null` 63282 else 63283 pkg_failed=yes 63284 fi 63285 else 63286 pkg_failed=untried 63287 fi 63288 63289 63290 63291 if test $pkg_failed = yes; then 63292 63293 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 63294 _pkg_short_errors_supported=yes 63295 else 63296 _pkg_short_errors_supported=no 63297 fi 63298 if test $_pkg_short_errors_supported = yes; then 63299 LIBFFI_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "libffi" 2>&1` 63300 else 63301 LIBFFI_PKG_ERRORS=`$PKG_CONFIG --print-errors "libffi" 2>&1` 63302 fi 63303 # Put the nasty error message in config.log where it belongs 63304 echo "$LIBFFI_PKG_ERRORS" >&5 63305 63306 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 63307 $as_echo "no" >&6; } 63308 LIBFFI_FOUND=no 63309 elif test $pkg_failed = untried; then 63310 LIBFFI_FOUND=no 63311 else 63312 LIBFFI_CFLAGS=$pkg_cv_LIBFFI_CFLAGS 63313 LIBFFI_LIBS=$pkg_cv_LIBFFI_LIBS 63314 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 63315 $as_echo "yes" >&6; } 63316 LIBFFI_FOUND=yes 63317 fi 63318 fi 63319 fi 63320 if test "x$LIBFFI_FOUND" = xno; then 63321 for ac_header in ffi.h 63322 do : 63323 ac_fn_cxx_check_header_mongrel "$LINENO" "ffi.h" "ac_cv_header_ffi_h" "$ac_includes_default" 63324 if test "x$ac_cv_header_ffi_h" = xyes; then : 63325 cat >>confdefs.h <<_ACEOF 63326 #define HAVE_FFI_H 1 63327 _ACEOF 63328 63329 LIBFFI_FOUND=yes 63330 LIBFFI_CFLAGS= 63331 LIBFFI_LIBS=-lffi 63332 63333 else 63334 LIBFFI_FOUND=no 63335 63336 fi 63337 63338 done 63339 63340 fi 63341 if test "x$LIBFFI_FOUND" = xno; then 63342 63343 # Print a helpful message on how to acquire the necessary build dependency. 63344 # ffi is the help tag: freetype, cups, alsa etc 63345 MISSING_DEPENDENCY=ffi 63346 63347 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63348 cygwin_help $MISSING_DEPENDENCY 63349 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63350 msys_help $MISSING_DEPENDENCY 63351 else 63352 PKGHANDLER_COMMAND= 63353 63354 case $PKGHANDLER in 63355 apt-get) 63356 apt_help $MISSING_DEPENDENCY ;; 63357 yum) 63358 yum_help $MISSING_DEPENDENCY ;; 63359 brew) 63360 brew_help $MISSING_DEPENDENCY ;; 63361 port) 63362 port_help $MISSING_DEPENDENCY ;; 63363 pkgutil) 63364 pkgutil_help $MISSING_DEPENDENCY ;; 63365 pkgadd) 63366 pkgadd_help $MISSING_DEPENDENCY ;; 63367 esac 63368 63369 if test "x$PKGHANDLER_COMMAND" != x; then 63370 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 63371 fi 63372 fi 63373 63374 as_fn_error $? "Could not find libffi! $HELP_MSG" "$LINENO" 5 63375 fi 63376 63377 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libffi works" >&5 63378 $as_echo_n "checking if libffi works... " >&6; } 63379 ac_ext=c 63380 ac_cpp='$CPP $CPPFLAGS' 63381 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 63382 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 63383 ac_compiler_gnu=$ac_cv_c_compiler_gnu 63384 63385 OLD_CFLAGS="$CFLAGS" 63386 CFLAGS="$CFLAGS $LIBFFI_CFLAGS" 63387 OLD_LIBS="$LIBS" 63388 LIBS="$LIBS $LIBFFI_LIBS" 63389 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 63390 /* end confdefs.h. */ 63391 #include <ffi.h> 63392 int 63393 main () 63394 { 63395 63396 ffi_call(NULL, NULL, NULL, NULL); 63397 return 0; 63398 63399 ; 63400 return 0; 63401 } 63402 _ACEOF 63403 if ac_fn_c_try_link "$LINENO"; then : 63404 LIBFFI_WORKS=yes 63405 else 63406 LIBFFI_WORKS=no 63407 63408 fi 63409 rm -f core conftest.err conftest.$ac_objext \ 63410 conftest$ac_exeext conftest.$ac_ext 63411 CFLAGS="$OLD_CFLAGS" 63412 LIBS="$OLD_LIBS" 63413 ac_ext=cpp 63414 ac_cpp='$CXXCPP $CPPFLAGS' 63415 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 63416 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 63417 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 63418 63419 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBFFI_WORKS" >&5 63420 $as_echo "$LIBFFI_WORKS" >&6; } 63421 63422 if test "x$LIBFFI_WORKS" = xno; then 63423 63424 # Print a helpful message on how to acquire the necessary build dependency. 63425 # ffi is the help tag: freetype, cups, alsa etc 63426 MISSING_DEPENDENCY=ffi 63427 63428 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63429 cygwin_help $MISSING_DEPENDENCY 63430 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63431 msys_help $MISSING_DEPENDENCY 63432 else 63433 PKGHANDLER_COMMAND= 63434 63435 case $PKGHANDLER in 63436 apt-get) 63437 apt_help $MISSING_DEPENDENCY ;; 63438 yum) 63439 yum_help $MISSING_DEPENDENCY ;; 63440 brew) 63441 brew_help $MISSING_DEPENDENCY ;; 63442 port) 63443 port_help $MISSING_DEPENDENCY ;; 63444 pkgutil) 63445 pkgutil_help $MISSING_DEPENDENCY ;; 63446 pkgadd) 63447 pkgadd_help $MISSING_DEPENDENCY ;; 63448 esac 63449 63450 if test "x$PKGHANDLER_COMMAND" != x; then 63451 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 63452 fi 63453 fi 63454 63455 as_fn_error $? "Found libffi but could not link and compile with it. $HELP_MSG" "$LINENO" 5 63456 fi 63457 63458 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libffi should be bundled" >&5 63459 $as_echo_n "checking if libffi should be bundled... " >&6; } 63460 if test "x$enable_libffi_bundling" = "x"; then 63461 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 63462 $as_echo "no" >&6; } 63463 ENABLE_LIBFFI_BUNDLING=false 63464 elif test "x$enable_libffi_bundling" = "xno"; then 63465 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 63466 $as_echo "no, forced" >&6; } 63467 ENABLE_LIBFFI_BUNDLING=false 63468 elif test "x$enable_libffi_bundling" = "xyes"; then 63469 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 63470 $as_echo "yes, forced" >&6; } 63471 ENABLE_LIBFFI_BUNDLING=true 63472 else 63473 as_fn_error $? "Invalid value for --enable-libffi-bundling" "$LINENO" 5 63474 fi 63475 63476 # Find the libffi.so.X to bundle 63477 if test "x${ENABLE_LIBFFI_BUNDLING}" = "xtrue"; then 63478 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libffi lib file location" >&5 63479 $as_echo_n "checking for libffi lib file location... " >&6; } 63480 if test "x${LIBFFI_LIB_PATH}" != x; then 63481 if test -e ${LIBFFI_LIB_PATH}/libffi.so.?; then 63482 LIBFFI_LIB_FILE="${LIBFFI_LIB_PATH}/libffi.so.?" 63483 else 63484 as_fn_error $? "Could not locate libffi.so.? for bundling in ${LIBFFI_LIB_PATH}" "$LINENO" 5 63485 fi 63486 else 63487 # If we don't have an explicit path, look in a few obvious places 63488 if test "x${OPENJDK_TARGET_CPU}" = "xx86"; then 63489 if test -e ${SYSROOT}/usr/lib/libffi.so.? ; then 63490 LIBFFI_LIB_FILE="${SYSROOT}/usr/lib/libffi.so.?" 63491 elif test -e ${SYSROOT}/usr/lib/i386-linux-gnu/libffi.so.? ; then 63492 LIBFFI_LIB_FILE="${SYSROOT}/usr/lib/i386-linux-gnu/libffi.so.?" 63493 else 63494 as_fn_error $? "Could not locate libffi.so.? for bundling" "$LINENO" 5 63495 fi 63496 elif test "x${OPENJDK_TARGET_CPU}" = "xx86_64"; then 63497 if test -e ${SYSROOT}/usr/lib64/libffi.so.? ; then 63498 LIBFFI_LIB_FILE="${SYSROOT}/usr/lib64/libffi.so.?" 63499 elif test -e ${SYSROOT}/usr/lib/x86_64-linux-gnu/libffi.so.? ; then 63500 LIBFFI_LIB_FILE="${SYSROOT}/usr/lib/x86_64-linux-gnu/libffi.so.?" 63501 else 63502 as_fn_error $? "Could not locate libffi.so.? for bundling" "$LINENO" 5 63503 fi 63504 else 63505 # Fallback on the default /usr/lib dir 63506 if test -e ${SYSROOT}/usr/lib/libffi.so.? ; then 63507 LIBFFI_LIB_FILE="${SYSROOT}/usr/lib/libffi.so.?" 63508 else 63509 as_fn_error $? "Could not locate libffi.so.? for bundling" "$LINENO" 5 63510 fi 63511 fi 63512 fi 63513 # Make sure the wildcard is evaluated 63514 LIBFFI_LIB_FILE="$(ls ${LIBFFI_LIB_FILE})" 63515 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${LIBFFI_LIB_FILE}" >&5 63516 $as_echo "${LIBFFI_LIB_FILE}" >&6; } 63517 fi 63518 fi 63519 63520 63521 63522 63523 63524 63525 63526 if [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 63527 # Extract the first word of "llvm-config", so it can be a program name with args. 63528 set dummy llvm-config; ac_word=$2 63529 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 63530 $as_echo_n "checking for $ac_word... " >&6; } 63531 if ${ac_cv_prog_LLVM_CONFIG+:} false; then : 63532 $as_echo_n "(cached) " >&6 63533 else 63534 if test -n "$LLVM_CONFIG"; then 63535 ac_cv_prog_LLVM_CONFIG="$LLVM_CONFIG" # Let the user override the test. 63536 else 63537 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 63538 for as_dir in $PATH 63539 do 63540 IFS=$as_save_IFS 63541 test -z "$as_dir" && as_dir=. 63542 for ac_exec_ext in '' $ac_executable_extensions; do 63543 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 63544 ac_cv_prog_LLVM_CONFIG="llvm-config" 63545 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 63546 break 2 63547 fi 63548 done 63549 done 63550 IFS=$as_save_IFS 63551 63552 fi 63553 fi 63554 LLVM_CONFIG=$ac_cv_prog_LLVM_CONFIG 63555 if test -n "$LLVM_CONFIG"; then 63556 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LLVM_CONFIG" >&5 63557 $as_echo "$LLVM_CONFIG" >&6; } 63558 else 63559 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 63560 $as_echo "no" >&6; } 63561 fi 63562 63563 63564 63565 if test "x$LLVM_CONFIG" != xllvm-config; then 63566 as_fn_error $? "llvm-config not found in $PATH." "$LINENO" 5 63567 fi 63568 63569 llvm_components="jit mcjit engine nativecodegen native" 63570 unset LLVM_CFLAGS 63571 for flag in $("$LLVM_CONFIG" --cxxflags); do 63572 if echo "${flag}" | grep -q '^-[ID]'; then 63573 if test "${flag}" != "-D_DEBUG" ; then 63574 if test "${LLVM_CFLAGS}" != "" ; then 63575 LLVM_CFLAGS="${LLVM_CFLAGS} " 63576 fi 63577 LLVM_CFLAGS="${LLVM_CFLAGS}${flag}" 63578 fi 63579 fi 63580 done 63581 llvm_version=$("${LLVM_CONFIG}" --version | $SED 's/\.//; s/svn.*//') 63582 LLVM_CFLAGS="${LLVM_CFLAGS} -DSHARK_LLVM_VERSION=${llvm_version}" 63583 63584 unset LLVM_LDFLAGS 63585 for flag in $("${LLVM_CONFIG}" --ldflags); do 63586 if echo "${flag}" | grep -q '^-L'; then 63587 if test "${LLVM_LDFLAGS}" != ""; then 63588 LLVM_LDFLAGS="${LLVM_LDFLAGS} " 63589 fi 63590 LLVM_LDFLAGS="${LLVM_LDFLAGS}${flag}" 63591 fi 63592 done 63593 63594 unset LLVM_LIBS 63595 for flag in $("${LLVM_CONFIG}" --libs ${llvm_components}); do 63596 if echo "${flag}" | grep -q '^-l'; then 63597 if test "${LLVM_LIBS}" != ""; then 63598 LLVM_LIBS="${LLVM_LIBS} " 63599 fi 63600 LLVM_LIBS="${LLVM_LIBS}${flag}" 63601 fi 63602 done 63603 63604 # Due to https://llvm.org/bugs/show_bug.cgi?id=16902, llvm does not 63605 # always properly detect -ltinfo 63606 LLVM_LIBS="${LLVM_LIBS} -ltinfo" 63607 63608 63609 63610 63611 fi 63612 63613 63614 63615 # Check whether --with-libjpeg was given. 63616 if test "${with_libjpeg+set}" = set; then : 63617 withval=$with_libjpeg; 63618 fi 63619 63620 63621 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which libjpeg to use" >&5 63622 $as_echo_n "checking for which libjpeg to use... " >&6; } 63623 # default is bundled 63624 DEFAULT_LIBJPEG=bundled 63625 # if user didn't specify, use DEFAULT_LIBJPEG 63626 if test "x${with_libjpeg}" = "x"; then 63627 with_libjpeg=${DEFAULT_LIBJPEG} 63628 fi 63629 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_libjpeg}" >&5 63630 $as_echo "${with_libjpeg}" >&6; } 63631 63632 if test "x${with_libjpeg}" = "xbundled"; then 63633 USE_EXTERNAL_LIBJPEG=false 63634 elif test "x${with_libjpeg}" = "xsystem"; then 63635 ac_fn_cxx_check_header_mongrel "$LINENO" "jpeglib.h" "ac_cv_header_jpeglib_h" "$ac_includes_default" 63636 if test "x$ac_cv_header_jpeglib_h" = xyes; then : 63637 63638 else 63639 as_fn_error $? "--with-libjpeg=system specified, but jpeglib.h not found!" "$LINENO" 5 63640 fi 63641 63642 63643 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jpeg_CreateDecompress in -ljpeg" >&5 63644 $as_echo_n "checking for jpeg_CreateDecompress in -ljpeg... " >&6; } 63645 if ${ac_cv_lib_jpeg_jpeg_CreateDecompress+:} false; then : 63646 $as_echo_n "(cached) " >&6 63647 else 63648 ac_check_lib_save_LIBS=$LIBS 63649 LIBS="-ljpeg $LIBS" 63650 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 63651 /* end confdefs.h. */ 63652 63653 /* Override any GCC internal prototype to avoid an error. 63654 Use char because int might match the return type of a GCC 63655 builtin and then its argument prototype would still apply. */ 63656 #ifdef __cplusplus 63657 extern "C" 63658 #endif 63659 char jpeg_CreateDecompress (); 63660 int 63661 main () 63662 { 63663 return jpeg_CreateDecompress (); 63664 ; 63665 return 0; 63666 } 63667 _ACEOF 63668 if ac_fn_cxx_try_link "$LINENO"; then : 63669 ac_cv_lib_jpeg_jpeg_CreateDecompress=yes 63670 else 63671 ac_cv_lib_jpeg_jpeg_CreateDecompress=no 63672 fi 63673 rm -f core conftest.err conftest.$ac_objext \ 63674 conftest$ac_exeext conftest.$ac_ext 63675 LIBS=$ac_check_lib_save_LIBS 63676 fi 63677 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_jpeg_jpeg_CreateDecompress" >&5 63678 $as_echo "$ac_cv_lib_jpeg_jpeg_CreateDecompress" >&6; } 63679 if test "x$ac_cv_lib_jpeg_jpeg_CreateDecompress" = xyes; then : 63680 cat >>confdefs.h <<_ACEOF 63681 #define HAVE_LIBJPEG 1 63682 _ACEOF 63683 63684 LIBS="-ljpeg $LIBS" 63685 63686 else 63687 as_fn_error $? "--with-libjpeg=system specified, but no libjpeg found" "$LINENO" 5 63688 fi 63689 63690 63691 USE_EXTERNAL_LIBJPEG=true 63692 else 63693 as_fn_error $? "Invalid use of --with-libjpeg: ${with_libjpeg}, use 'system' or 'bundled'" "$LINENO" 5 63694 fi 63695 63696 63697 63698 63699 63700 # Check whether --with-giflib was given. 63701 if test "${with_giflib+set}" = set; then : 63702 withval=$with_giflib; 63703 fi 63704 63705 63706 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which giflib to use" >&5 63707 $as_echo_n "checking for which giflib to use... " >&6; } 63708 # default is bundled 63709 DEFAULT_GIFLIB=bundled 63710 # if user didn't specify, use DEFAULT_GIFLIB 63711 if test "x${with_giflib}" = "x"; then 63712 with_giflib=${DEFAULT_GIFLIB} 63713 fi 63714 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_giflib}" >&5 63715 $as_echo "${with_giflib}" >&6; } 63716 63717 if test "x${with_giflib}" = "xbundled"; then 63718 USE_EXTERNAL_LIBGIF=false 63719 elif test "x${with_giflib}" = "xsystem"; then 63720 ac_fn_cxx_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default" 63721 if test "x$ac_cv_header_gif_lib_h" = xyes; then : 63722 63723 else 63724 as_fn_error $? "--with-giflib=system specified, but gif_lib.h not found!" "$LINENO" 5 63725 fi 63726 63727 63728 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DGifGetCode in -lgif" >&5 63729 $as_echo_n "checking for DGifGetCode in -lgif... " >&6; } 63730 if ${ac_cv_lib_gif_DGifGetCode+:} false; then : 63731 $as_echo_n "(cached) " >&6 63732 else 63733 ac_check_lib_save_LIBS=$LIBS 63734 LIBS="-lgif $LIBS" 63735 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 63736 /* end confdefs.h. */ 63737 63738 /* Override any GCC internal prototype to avoid an error. 63739 Use char because int might match the return type of a GCC 63740 builtin and then its argument prototype would still apply. */ 63741 #ifdef __cplusplus 63742 extern "C" 63743 #endif 63744 char DGifGetCode (); 63745 int 63746 main () 63747 { 63748 return DGifGetCode (); 63749 ; 63750 return 0; 63751 } 63752 _ACEOF 63753 if ac_fn_cxx_try_link "$LINENO"; then : 63754 ac_cv_lib_gif_DGifGetCode=yes 63755 else 63756 ac_cv_lib_gif_DGifGetCode=no 63757 fi 63758 rm -f core conftest.err conftest.$ac_objext \ 63759 conftest$ac_exeext conftest.$ac_ext 63760 LIBS=$ac_check_lib_save_LIBS 63761 fi 63762 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gif_DGifGetCode" >&5 63763 $as_echo "$ac_cv_lib_gif_DGifGetCode" >&6; } 63764 if test "x$ac_cv_lib_gif_DGifGetCode" = xyes; then : 63765 cat >>confdefs.h <<_ACEOF 63766 #define HAVE_LIBGIF 1 63767 _ACEOF 63768 63769 LIBS="-lgif $LIBS" 63770 63771 else 63772 as_fn_error $? "--with-giflib=system specified, but no giflib found!" "$LINENO" 5 63773 fi 63774 63775 63776 USE_EXTERNAL_LIBGIF=true 63777 else 63778 as_fn_error $? "Invalid value of --with-giflib: ${with_giflib}, use 'system' or 'bundled'" "$LINENO" 5 63779 fi 63780 63781 63782 63783 63784 63785 # Check whether --with-libpng was given. 63786 if test "${with_libpng+set}" = set; then : 63787 withval=$with_libpng; 63788 fi 63789 63790 63791 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which libpng to use" >&5 63792 $as_echo_n "checking for which libpng to use... " >&6; } 63793 63794 # default is bundled 63795 DEFAULT_LIBPNG=bundled 63796 # if user didn't specify, use DEFAULT_LIBPNG 63797 if test "x${with_libpng}" = "x"; then 63798 with_libpng=${DEFAULT_LIBPNG} 63799 fi 63800 63801 if test "x${with_libpng}" = "xbundled"; then 63802 USE_EXTERNAL_LIBPNG=false 63803 PNG_CFLAGS="" 63804 PNG_LIBS="" 63805 { $as_echo "$as_me:${as_lineno-$LINENO}: result: bundled" >&5 63806 $as_echo "bundled" >&6; } 63807 elif test "x${with_libpng}" = "xsystem"; then 63808 63809 pkg_failed=no 63810 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PNG" >&5 63811 $as_echo_n "checking for PNG... " >&6; } 63812 63813 if test -n "$PNG_CFLAGS"; then 63814 pkg_cv_PNG_CFLAGS="$PNG_CFLAGS" 63815 elif test -n "$PKG_CONFIG"; then 63816 if test -n "$PKG_CONFIG" && \ 63817 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libpng\""; } >&5 63818 ($PKG_CONFIG --exists --print-errors "libpng") 2>&5 63819 ac_status=$? 63820 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 63821 test $ac_status = 0; }; then 63822 pkg_cv_PNG_CFLAGS=`$PKG_CONFIG --cflags "libpng" 2>/dev/null` 63823 else 63824 pkg_failed=yes 63825 fi 63826 else 63827 pkg_failed=untried 63828 fi 63829 if test -n "$PNG_LIBS"; then 63830 pkg_cv_PNG_LIBS="$PNG_LIBS" 63831 elif test -n "$PKG_CONFIG"; then 63832 if test -n "$PKG_CONFIG" && \ 63833 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libpng\""; } >&5 63834 ($PKG_CONFIG --exists --print-errors "libpng") 2>&5 63835 ac_status=$? 63836 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 63837 test $ac_status = 0; }; then 63838 pkg_cv_PNG_LIBS=`$PKG_CONFIG --libs "libpng" 2>/dev/null` 63839 else 63840 pkg_failed=yes 63841 fi 63842 else 63843 pkg_failed=untried 63844 fi 63845 63846 63847 63848 if test $pkg_failed = yes; then 63849 63850 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 63851 _pkg_short_errors_supported=yes 63852 else 63853 _pkg_short_errors_supported=no 63854 fi 63855 if test $_pkg_short_errors_supported = yes; then 63856 PNG_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "libpng" 2>&1` 63857 else 63858 PNG_PKG_ERRORS=`$PKG_CONFIG --print-errors "libpng" 2>&1` 63859 fi 63860 # Put the nasty error message in config.log where it belongs 63861 echo "$PNG_PKG_ERRORS" >&5 63862 63863 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 63864 $as_echo "no" >&6; } 63865 LIBPNG_FOUND=no 63866 elif test $pkg_failed = untried; then 63867 LIBPNG_FOUND=no 63868 else 63869 PNG_CFLAGS=$pkg_cv_PNG_CFLAGS 63870 PNG_LIBS=$pkg_cv_PNG_LIBS 63871 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 63872 $as_echo "yes" >&6; } 63873 LIBPNG_FOUND=yes 63874 fi 63875 if test "x${LIBPNG_FOUND}" = "xyes"; then 63876 # PKG_CHECK_MODULES will set PNG_CFLAGS and PNG_LIBS 63877 USE_EXTERNAL_LIBPNG=true 63878 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system" >&5 63879 $as_echo "system" >&6; } 63880 else 63881 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system not found" >&5 63882 $as_echo "system not found" >&6; } 63883 as_fn_error $? "--with-libpng=system specified, but no libpng found!" "$LINENO" 5 63884 fi 63885 else 63886 as_fn_error $? "Invalid value of --with-libpng: ${with_libpng}, use 'system' or 'bundled'" "$LINENO" 5 63887 fi 63888 63889 63890 63891 63892 63893 63894 63895 # Check whether --with-zlib was given. 63896 if test "${with_zlib+set}" = set; then : 63897 withval=$with_zlib; 63898 fi 63899 63900 63901 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compress in -lz" >&5 63902 $as_echo_n "checking for compress in -lz... " >&6; } 63903 if ${ac_cv_lib_z_compress+:} false; then : 63904 $as_echo_n "(cached) " >&6 63905 else 63906 ac_check_lib_save_LIBS=$LIBS 63907 LIBS="-lz $LIBS" 63908 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 63909 /* end confdefs.h. */ 63910 63911 /* Override any GCC internal prototype to avoid an error. 63912 Use char because int might match the return type of a GCC 63913 builtin and then its argument prototype would still apply. */ 63914 #ifdef __cplusplus 63915 extern "C" 63916 #endif 63917 char compress (); 63918 int 63919 main () 63920 { 63921 return compress (); 63922 ; 63923 return 0; 63924 } 63925 _ACEOF 63926 if ac_fn_cxx_try_link "$LINENO"; then : 63927 ac_cv_lib_z_compress=yes 63928 else 63929 ac_cv_lib_z_compress=no 63930 fi 63931 rm -f core conftest.err conftest.$ac_objext \ 63932 conftest$ac_exeext conftest.$ac_ext 63933 LIBS=$ac_check_lib_save_LIBS 63934 fi 63935 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_compress" >&5 63936 $as_echo "$ac_cv_lib_z_compress" >&6; } 63937 if test "x$ac_cv_lib_z_compress" = xyes; then : 63938 ZLIB_FOUND=yes 63939 else 63940 ZLIB_FOUND=no 63941 fi 63942 63943 63944 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which zlib to use" >&5 63945 $as_echo_n "checking for which zlib to use... " >&6; } 63946 63947 DEFAULT_ZLIB=system 63948 if test "x$OPENJDK_TARGET_OS" = xwindows; then 63949 # On windows default is bundled...on others default is system 63950 DEFAULT_ZLIB=bundled 63951 fi 63952 63953 if test "x${ZLIB_FOUND}" != "xyes"; then 63954 # If we don't find any system...set default to bundled 63955 DEFAULT_ZLIB=bundled 63956 fi 63957 63958 # If user didn't specify, use DEFAULT_ZLIB 63959 if test "x${with_zlib}" = "x"; then 63960 with_zlib=${DEFAULT_ZLIB} 63961 fi 63962 63963 if test "x${with_zlib}" = "xbundled"; then 63964 USE_EXTERNAL_LIBZ=false 63965 { $as_echo "$as_me:${as_lineno-$LINENO}: result: bundled" >&5 63966 $as_echo "bundled" >&6; } 63967 elif test "x${with_zlib}" = "xsystem"; then 63968 if test "x${ZLIB_FOUND}" = "xyes"; then 63969 USE_EXTERNAL_LIBZ=true 63970 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system" >&5 63971 $as_echo "system" >&6; } 63972 else 63973 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system not found" >&5 63974 $as_echo "system not found" >&6; } 63975 as_fn_error $? "--with-zlib=system specified, but no zlib found!" "$LINENO" 5 63976 fi 63977 else 63978 as_fn_error $? "Invalid value for --with-zlib: ${with_zlib}, use 'system' or 'bundled'" "$LINENO" 5 63979 fi 63980 63981 63982 63983 63984 63985 # Check whether --with-lcms was given. 63986 if test "${with_lcms+set}" = set; then : 63987 withval=$with_lcms; 63988 fi 63989 63990 63991 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which lcms to use" >&5 63992 $as_echo_n "checking for which lcms to use... " >&6; } 63993 63994 DEFAULT_LCMS=bundled 63995 # If user didn't specify, use DEFAULT_LCMS 63996 if test "x${with_lcms}" = "x"; then 63997 with_lcms=${DEFAULT_LCMS} 63998 fi 63999 64000 if test "x${with_lcms}" = "xbundled"; then 64001 USE_EXTERNAL_LCMS=false 64002 LCMS_CFLAGS="" 64003 LCMS_LIBS="" 64004 { $as_echo "$as_me:${as_lineno-$LINENO}: result: bundled" >&5 64005 $as_echo "bundled" >&6; } 64006 elif test "x${with_lcms}" = "xsystem"; then 64007 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system" >&5 64008 $as_echo "system" >&6; } 64009 64010 pkg_failed=no 64011 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LCMS" >&5 64012 $as_echo_n "checking for LCMS... " >&6; } 64013 64014 if test -n "$LCMS_CFLAGS"; then 64015 pkg_cv_LCMS_CFLAGS="$LCMS_CFLAGS" 64016 elif test -n "$PKG_CONFIG"; then 64017 if test -n "$PKG_CONFIG" && \ 64018 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lcms2\""; } >&5 64019 ($PKG_CONFIG --exists --print-errors "lcms2") 2>&5 64020 ac_status=$? 64021 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 64022 test $ac_status = 0; }; then 64023 pkg_cv_LCMS_CFLAGS=`$PKG_CONFIG --cflags "lcms2" 2>/dev/null` 64024 else 64025 pkg_failed=yes 64026 fi 64027 else 64028 pkg_failed=untried 64029 fi 64030 if test -n "$LCMS_LIBS"; then 64031 pkg_cv_LCMS_LIBS="$LCMS_LIBS" 64032 elif test -n "$PKG_CONFIG"; then 64033 if test -n "$PKG_CONFIG" && \ 64034 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lcms2\""; } >&5 64035 ($PKG_CONFIG --exists --print-errors "lcms2") 2>&5 64036 ac_status=$? 64037 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 64038 test $ac_status = 0; }; then 64039 pkg_cv_LCMS_LIBS=`$PKG_CONFIG --libs "lcms2" 2>/dev/null` 64040 else 64041 pkg_failed=yes 64042 fi 64043 else 64044 pkg_failed=untried 64045 fi 64046 64047 64048 64049 if test $pkg_failed = yes; then 64050 64051 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 64052 _pkg_short_errors_supported=yes 64053 else 64054 _pkg_short_errors_supported=no 64055 fi 64056 if test $_pkg_short_errors_supported = yes; then 64057 LCMS_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lcms2" 2>&1` 64058 else 64059 LCMS_PKG_ERRORS=`$PKG_CONFIG --print-errors "lcms2" 2>&1` 64060 fi 64061 # Put the nasty error message in config.log where it belongs 64062 echo "$LCMS_PKG_ERRORS" >&5 64063 64064 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 64065 $as_echo "no" >&6; } 64066 LCMS_FOUND=no 64067 elif test $pkg_failed = untried; then 64068 LCMS_FOUND=no 64069 else 64070 LCMS_CFLAGS=$pkg_cv_LCMS_CFLAGS 64071 LCMS_LIBS=$pkg_cv_LCMS_LIBS 64072 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 64073 $as_echo "yes" >&6; } 64074 LCMS_FOUND=yes 64075 fi 64076 if test "x${LCMS_FOUND}" = "xyes"; then 64077 # PKG_CHECK_MODULES will set LCMS_CFLAGS and LCMS_LIBS 64078 USE_EXTERNAL_LCMS=true 64079 else 64080 as_fn_error $? "--with-lcms=system specified, but no lcms found!" "$LINENO" 5 64081 fi 64082 else 64083 as_fn_error $? "Invalid value for --with-lcms: ${with_lcms}, use 'system' or 'bundled'" "$LINENO" 5 64084 fi 64085 64086 64087 64088 64089 64090 64091 64092 64093 64094 64095 64096 64097 64098 # Setup libm (the maths library) 64099 if test "x$OPENJDK_TARGET_OS" != "xwindows"; then 64100 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cos in -lm" >&5 64101 $as_echo_n "checking for cos in -lm... " >&6; } 64102 if ${ac_cv_lib_m_cos+:} false; then : 64103 $as_echo_n "(cached) " >&6 64104 else 64105 ac_check_lib_save_LIBS=$LIBS 64106 LIBS="-lm $LIBS" 64107 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 64108 /* end confdefs.h. */ 64109 64110 /* Override any GCC internal prototype to avoid an error. 64111 Use char because int might match the return type of a GCC 64112 builtin and then its argument prototype would still apply. */ 64113 #ifdef __cplusplus 64114 extern "C" 64115 #endif 64116 char cos (); 64117 int 64118 main () 64119 { 64120 return cos (); 64121 ; 64122 return 0; 64123 } 64124 _ACEOF 64125 if ac_fn_cxx_try_link "$LINENO"; then : 64126 ac_cv_lib_m_cos=yes 64127 else 64128 ac_cv_lib_m_cos=no 64129 fi 64130 rm -f core conftest.err conftest.$ac_objext \ 64131 conftest$ac_exeext conftest.$ac_ext 64132 LIBS=$ac_check_lib_save_LIBS 64133 fi 64134 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_cos" >&5 64135 $as_echo "$ac_cv_lib_m_cos" >&6; } 64136 if test "x$ac_cv_lib_m_cos" = xyes; then : 64137 cat >>confdefs.h <<_ACEOF 64138 #define HAVE_LIBM 1 64139 _ACEOF 64140 64141 LIBS="-lm $LIBS" 64142 64143 else 64144 64145 { $as_echo "$as_me:${as_lineno-$LINENO}: Maths library was not found" >&5 64146 $as_echo "$as_me: Maths library was not found" >&6;} 64147 64148 fi 64149 64150 LIBM="-lm" 64151 else 64152 LIBM="" 64153 fi 64154 64155 64156 # Setup libdl (for dynamic library loading) 64157 save_LIBS="$LIBS" 64158 LIBS="" 64159 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 64160 $as_echo_n "checking for dlopen in -ldl... " >&6; } 64161 if ${ac_cv_lib_dl_dlopen+:} false; then : 64162 $as_echo_n "(cached) " >&6 64163 else 64164 ac_check_lib_save_LIBS=$LIBS 64165 LIBS="-ldl $LIBS" 64166 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 64167 /* end confdefs.h. */ 64168 64169 /* Override any GCC internal prototype to avoid an error. 64170 Use char because int might match the return type of a GCC 64171 builtin and then its argument prototype would still apply. */ 64172 #ifdef __cplusplus 64173 extern "C" 64174 #endif 64175 char dlopen (); 64176 int 64177 main () 64178 { 64179 return dlopen (); 64180 ; 64181 return 0; 64182 } 64183 _ACEOF 64184 if ac_fn_cxx_try_link "$LINENO"; then : 64185 ac_cv_lib_dl_dlopen=yes 64186 else 64187 ac_cv_lib_dl_dlopen=no 64188 fi 64189 rm -f core conftest.err conftest.$ac_objext \ 64190 conftest$ac_exeext conftest.$ac_ext 64191 LIBS=$ac_check_lib_save_LIBS 64192 fi 64193 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 64194 $as_echo "$ac_cv_lib_dl_dlopen" >&6; } 64195 if test "x$ac_cv_lib_dl_dlopen" = xyes; then : 64196 cat >>confdefs.h <<_ACEOF 64197 #define HAVE_LIBDL 1 64198 _ACEOF 64199 64200 LIBS="-ldl $LIBS" 64201 64202 fi 64203 64204 LIBDL="$LIBS" 64205 64206 LIBS="$save_LIBS" 64207 64208 # Deprecated libraries, keep the flags for backwards compatibility 64209 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 64210 64211 64212 # Check whether --with-dxsdk was given. 64213 if test "${with_dxsdk+set}" = set; then : 64214 withval=$with_dxsdk; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk is deprecated and will be ignored." >&5 64215 $as_echo "$as_me: WARNING: Option --with-dxsdk is deprecated and will be ignored." >&2;} 64216 fi 64217 64218 64219 64220 64221 # Check whether --with-dxsdk-lib was given. 64222 if test "${with_dxsdk_lib+set}" = set; then : 64223 withval=$with_dxsdk_lib; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk-lib is deprecated and will be ignored." >&5 64224 $as_echo "$as_me: WARNING: Option --with-dxsdk-lib is deprecated and will be ignored." >&2;} 64225 fi 64226 64227 64228 64229 64230 # Check whether --with-dxsdk-include was given. 64231 if test "${with_dxsdk_include+set}" = set; then : 64232 withval=$with_dxsdk_include; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk-include is deprecated and will be ignored." >&5 64233 $as_echo "$as_me: WARNING: Option --with-dxsdk-include is deprecated and will be ignored." >&2;} 64234 fi 64235 64236 64237 fi 64238 64239 # Control if libzip can use mmap. Available for purposes of overriding. 64240 LIBZIP_CAN_USE_MMAP=true 64241 64242 64243 64244 if test "$OPENJDK_TARGET_OS" = "solaris" && test "x$BUILD_GTEST" = "xtrue"; then 64245 # Find the root of the Solaris Studio installation from the compiler path 64246 SOLARIS_STUDIO_DIR="$(dirname $CC)/.." 64247 STLPORT_LIB="$SOLARIS_STUDIO_DIR/lib/stlport4$OPENJDK_TARGET_CPU_ISADIR/libstlport.so.1" 64248 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libstlport.so.1" >&5 64249 $as_echo_n "checking for libstlport.so.1... " >&6; } 64250 if ! test -f "$STLPORT_LIB" && test "x$OPENJDK_TARGET_CPU_ISADIR" = "x/sparcv9"; then 64251 # SS12u3 has libstlport under 'stlport4/v9' instead of 'stlport4/sparcv9' 64252 STLPORT_LIB="$SOLARIS_STUDIO_DIR/lib/stlport4/v9/libstlport.so.1" 64253 fi 64254 if test -f "$STLPORT_LIB"; then 64255 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, $STLPORT_LIB" >&5 64256 $as_echo "yes, $STLPORT_LIB" >&6; } 64257 64258 # Only process if variable expands to non-empty 64259 64260 if test "x$STLPORT_LIB" != x; then 64261 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 64262 64263 # Input might be given as Windows format, start by converting to 64264 # unix format. 64265 path="$STLPORT_LIB" 64266 new_path=`$CYGPATH -u "$path"` 64267 64268 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 64269 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 64270 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 64271 # "foo.exe" is OK but "foo" is an error. 64272 # 64273 # This test is therefore slightly more accurate than "test -f" to check for file precense. 64274 # It is also a way to make sure we got the proper file name for the real test later on. 64275 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 64276 if test "x$test_shortpath" = x; then 64277 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STLPORT_LIB, which resolves as \"$path\", is invalid." >&5 64278 $as_echo "$as_me: The path of STLPORT_LIB, which resolves as \"$path\", is invalid." >&6;} 64279 as_fn_error $? "Cannot locate the the path of STLPORT_LIB" "$LINENO" 5 64280 fi 64281 64282 # Call helper function which possibly converts this using DOS-style short mode. 64283 # If so, the updated path is stored in $new_path. 64284 64285 input_path="$new_path" 64286 # Check if we need to convert this using DOS-style short mode. If the path 64287 # contains just simple characters, use it. Otherwise (spaces, weird characters), 64288 # take no chances and rewrite it. 64289 # Note: m4 eats our [], so we need to use [ and ] instead. 64290 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 64291 if test "x$has_forbidden_chars" != x; then 64292 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 64293 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 64294 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 64295 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 64296 # Going to short mode and back again did indeed matter. Since short mode is 64297 # case insensitive, let's make it lowercase to improve readability. 64298 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 64299 # Now convert it back to Unix-style (cygpath) 64300 input_path=`$CYGPATH -u "$shortmode_path"` 64301 new_path="$input_path" 64302 fi 64303 fi 64304 64305 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 64306 if test "x$test_cygdrive_prefix" = x; then 64307 # As a simple fix, exclude /usr/bin since it's not a real path. 64308 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 64309 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 64310 # a path prefixed by /cygdrive for fixpath to work. 64311 new_path="$CYGWIN_ROOT_PATH$input_path" 64312 fi 64313 fi 64314 64315 64316 if test "x$path" != "x$new_path"; then 64317 STLPORT_LIB="$new_path" 64318 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STLPORT_LIB to \"$new_path\"" >&5 64319 $as_echo "$as_me: Rewriting STLPORT_LIB to \"$new_path\"" >&6;} 64320 fi 64321 64322 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 64323 64324 path="$STLPORT_LIB" 64325 has_colon=`$ECHO $path | $GREP ^.:` 64326 new_path="$path" 64327 if test "x$has_colon" = x; then 64328 # Not in mixed or Windows style, start by that. 64329 new_path=`cmd //c echo $path` 64330 fi 64331 64332 64333 input_path="$new_path" 64334 # Check if we need to convert this using DOS-style short mode. If the path 64335 # contains just simple characters, use it. Otherwise (spaces, weird characters), 64336 # take no chances and rewrite it. 64337 # Note: m4 eats our [], so we need to use [ and ] instead. 64338 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 64339 if test "x$has_forbidden_chars" != x; then 64340 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 64341 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 64342 fi 64343 64344 64345 windows_path="$new_path" 64346 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 64347 unix_path=`$CYGPATH -u "$windows_path"` 64348 new_path="$unix_path" 64349 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 64350 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 64351 new_path="$unix_path" 64352 fi 64353 64354 if test "x$path" != "x$new_path"; then 64355 STLPORT_LIB="$new_path" 64356 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STLPORT_LIB to \"$new_path\"" >&5 64357 $as_echo "$as_me: Rewriting STLPORT_LIB to \"$new_path\"" >&6;} 64358 fi 64359 64360 # Save the first 10 bytes of this path to the storage, so fixpath can work. 64361 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 64362 64363 else 64364 # We're on a unix platform. Hooray! :) 64365 path="$STLPORT_LIB" 64366 has_space=`$ECHO "$path" | $GREP " "` 64367 if test "x$has_space" != x; then 64368 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STLPORT_LIB, which resolves as \"$path\", is invalid." >&5 64369 $as_echo "$as_me: The path of STLPORT_LIB, which resolves as \"$path\", is invalid." >&6;} 64370 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 64371 fi 64372 64373 # Use eval to expand a potential ~ 64374 eval path="$path" 64375 if test ! -f "$path" && test ! -d "$path"; then 64376 as_fn_error $? "The path of STLPORT_LIB, which resolves as \"$path\", is not found." "$LINENO" 5 64377 fi 64378 64379 if test -d "$path"; then 64380 STLPORT_LIB="`cd "$path"; $THEPWDCMD -L`" 64381 else 64382 dir="`$DIRNAME "$path"`" 64383 base="`$BASENAME "$path"`" 64384 STLPORT_LIB="`cd "$dir"; $THEPWDCMD -L`/$base" 64385 fi 64386 fi 64387 fi 64388 64389 else 64390 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, not found at $STLPORT_LIB" >&5 64391 $as_echo "no, not found at $STLPORT_LIB" >&6; } 64392 as_fn_error $? "Failed to find libstlport.so.1, cannot build Hotspot gtests" "$LINENO" 5 64393 fi 64394 64395 fi 64396 64397 64398 64399 # Check whether --with-libelf was given. 64400 if test "${with_libelf+set}" = set; then : 64401 withval=$with_libelf; 64402 fi 64403 64404 64405 # Check whether --with-libelf-include was given. 64406 if test "${with_libelf_include+set}" = set; then : 64407 withval=$with_libelf_include; 64408 fi 64409 64410 64411 # Check whether --with-libelf-lib was given. 64412 if test "${with_libelf_lib+set}" = set; then : 64413 withval=$with_libelf_lib; 64414 fi 64415 64416 64417 if test "x$ENABLE_AOT" = xfalse; then 64418 if (test "x${with_libelf}" != x && test "x${with_libelf}" != xno) || \ 64419 (test "x${with_libelf_include}" != x && test "x${with_libelf_include}" != xno) || \ 64420 (test "x${with_libelf_lib}" != x && test "x${with_libelf_lib}" != xno); then 64421 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libelf is not used, so --with-libelf[-*] is ignored" >&5 64422 $as_echo "$as_me: WARNING: libelf is not used, so --with-libelf[-*] is ignored" >&2;} 64423 fi 64424 LIBELF_CFLAGS= 64425 LIBELF_LIBS= 64426 else 64427 LIBELF_FOUND=no 64428 64429 if test "x${with_libelf}" = xno || test "x${with_libelf_include}" = xno || test "x${with_libelf_lib}" = xno; then 64430 ENABLE_AOT="false" 64431 if test "x${enable_aot}" = xyes; then 64432 as_fn_error $? "libelf is explicitly disabled, cannot build AOT. Enable libelf or remove --enable-aot to disable AOT." "$LINENO" 5 64433 fi 64434 else 64435 if test "x${with_libelf}" != x; then 64436 ELF_LIBS="-L${with_libelf}/lib -lelf" 64437 ELF_CFLAGS="-I${with_libelf}/include" 64438 LIBELF_FOUND=yes 64439 fi 64440 if test "x${with_libelf_include}" != x; then 64441 ELF_CFLAGS="-I${with_libelf_include}" 64442 LIBELF_FOUND=yes 64443 fi 64444 if test "x${with_libelf_lib}" != x; then 64445 ELF_LIBS="-L${with_libelf_lib} -lelf" 64446 LIBELF_FOUND=yes 64447 fi 64448 # Do not try pkg-config if we have a sysroot set. 64449 if test "x$SYSROOT" = x; then 64450 if test "x$LIBELF_FOUND" = xno; then 64451 # Figure out ELF_CFLAGS and ELF_LIBS 64452 64453 pkg_failed=no 64454 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ELF" >&5 64455 $as_echo_n "checking for ELF... " >&6; } 64456 64457 if test -n "$ELF_CFLAGS"; then 64458 pkg_cv_ELF_CFLAGS="$ELF_CFLAGS" 64459 elif test -n "$PKG_CONFIG"; then 64460 if test -n "$PKG_CONFIG" && \ 64461 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libelf\""; } >&5 64462 ($PKG_CONFIG --exists --print-errors "libelf") 2>&5 64463 ac_status=$? 64464 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 64465 test $ac_status = 0; }; then 64466 pkg_cv_ELF_CFLAGS=`$PKG_CONFIG --cflags "libelf" 2>/dev/null` 64467 else 64468 pkg_failed=yes 64469 fi 64470 else 64471 pkg_failed=untried 64472 fi 64473 if test -n "$ELF_LIBS"; then 64474 pkg_cv_ELF_LIBS="$ELF_LIBS" 64475 elif test -n "$PKG_CONFIG"; then 64476 if test -n "$PKG_CONFIG" && \ 64477 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libelf\""; } >&5 64478 ($PKG_CONFIG --exists --print-errors "libelf") 2>&5 64479 ac_status=$? 64480 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 64481 test $ac_status = 0; }; then 64482 pkg_cv_ELF_LIBS=`$PKG_CONFIG --libs "libelf" 2>/dev/null` 64483 else 64484 pkg_failed=yes 64485 fi 64486 else 64487 pkg_failed=untried 64488 fi 64489 64490 64491 64492 if test $pkg_failed = yes; then 64493 64494 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 64495 _pkg_short_errors_supported=yes 64496 else 64497 _pkg_short_errors_supported=no 64498 fi 64499 if test $_pkg_short_errors_supported = yes; then 64500 ELF_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "libelf" 2>&1` 64501 else 64502 ELF_PKG_ERRORS=`$PKG_CONFIG --print-errors "libelf" 2>&1` 64503 fi 64504 # Put the nasty error message in config.log where it belongs 64505 echo "$ELF_PKG_ERRORS" >&5 64506 64507 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 64508 $as_echo "no" >&6; } 64509 LIBELF_FOUND=no 64510 elif test $pkg_failed = untried; then 64511 LIBELF_FOUND=no 64512 else 64513 ELF_CFLAGS=$pkg_cv_ELF_CFLAGS 64514 ELF_LIBS=$pkg_cv_ELF_LIBS 64515 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 64516 $as_echo "yes" >&6; } 64517 LIBELF_FOUND=yes 64518 fi 64519 fi 64520 fi 64521 if test "x$LIBELF_FOUND" = xno; then 64522 for ac_header in libelf.h 64523 do : 64524 ac_fn_cxx_check_header_mongrel "$LINENO" "libelf.h" "ac_cv_header_libelf_h" "$ac_includes_default" 64525 if test "x$ac_cv_header_libelf_h" = xyes; then : 64526 cat >>confdefs.h <<_ACEOF 64527 #define HAVE_LIBELF_H 1 64528 _ACEOF 64529 64530 LIBELF_FOUND=yes 64531 ELF_CFLAGS= 64532 ELF_LIBS=-lelf 64533 64534 else 64535 LIBELF_FOUND=no 64536 64537 fi 64538 64539 done 64540 64541 fi 64542 if test "x$LIBELF_FOUND" = xno; then 64543 ENABLE_AOT="false" 64544 64545 # Print a helpful message on how to acquire the necessary build dependency. 64546 # elf is the help tag: freetype, cups, alsa etc 64547 MISSING_DEPENDENCY=elf 64548 64549 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 64550 cygwin_help $MISSING_DEPENDENCY 64551 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 64552 msys_help $MISSING_DEPENDENCY 64553 else 64554 PKGHANDLER_COMMAND= 64555 64556 case $PKGHANDLER in 64557 apt-get) 64558 apt_help $MISSING_DEPENDENCY ;; 64559 yum) 64560 yum_help $MISSING_DEPENDENCY ;; 64561 brew) 64562 brew_help $MISSING_DEPENDENCY ;; 64563 port) 64564 port_help $MISSING_DEPENDENCY ;; 64565 pkgutil) 64566 pkgutil_help $MISSING_DEPENDENCY ;; 64567 pkgadd) 64568 pkgadd_help $MISSING_DEPENDENCY ;; 64569 esac 64570 64571 if test "x$PKGHANDLER_COMMAND" != x; then 64572 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 64573 fi 64574 fi 64575 64576 if test "x${enable_aot}" = xyes; then 64577 as_fn_error $? "libelf not found, cannot build AOT. Remove --enable-aot to disable AOT or: $HELP_MSG" "$LINENO" 5 64578 else 64579 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libelf not found, cannot build AOT. $HELP_MSG" >&5 64580 $as_echo "$as_me: WARNING: libelf not found, cannot build AOT. $HELP_MSG" >&2;} 64581 fi 64582 else 64583 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libelf works" >&5 64584 $as_echo_n "checking if libelf works... " >&6; } 64585 ac_ext=c 64586 ac_cpp='$CPP $CPPFLAGS' 64587 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 64588 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 64589 ac_compiler_gnu=$ac_cv_c_compiler_gnu 64590 64591 OLD_CFLAGS="$CFLAGS" 64592 CFLAGS="$CFLAGS $ELF_CFLAGS" 64593 OLD_LIBS="$LIBS" 64594 LIBS="$LIBS $ELF_LIBS" 64595 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 64596 /* end confdefs.h. */ 64597 #include <libelf.h> 64598 int 64599 main () 64600 { 64601 64602 elf_version(0); 64603 return 0; 64604 64605 ; 64606 return 0; 64607 } 64608 _ACEOF 64609 if ac_fn_c_try_link "$LINENO"; then : 64610 LIBELF_WORKS=yes 64611 else 64612 LIBELF_WORKS=no 64613 64614 fi 64615 rm -f core conftest.err conftest.$ac_objext \ 64616 conftest$ac_exeext conftest.$ac_ext 64617 CFLAGS="$OLD_CFLAGS" 64618 LIBS="$OLD_LIBS" 64619 ac_ext=cpp 64620 ac_cpp='$CXXCPP $CPPFLAGS' 64621 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 64622 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 64623 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 64624 64625 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBELF_WORKS" >&5 64626 $as_echo "$LIBELF_WORKS" >&6; } 64627 64628 if test "x$LIBELF_WORKS" = xno; then 64629 ENABLE_AOT="false" 64630 64631 # Print a helpful message on how to acquire the necessary build dependency. 64632 # elf is the help tag: freetype, cups, alsa etc 64633 MISSING_DEPENDENCY=elf 64634 64635 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 64636 cygwin_help $MISSING_DEPENDENCY 64637 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 64638 msys_help $MISSING_DEPENDENCY 64639 else 64640 PKGHANDLER_COMMAND= 64641 64642 case $PKGHANDLER in 64643 apt-get) 64644 apt_help $MISSING_DEPENDENCY ;; 64645 yum) 64646 yum_help $MISSING_DEPENDENCY ;; 64647 brew) 64648 brew_help $MISSING_DEPENDENCY ;; 64649 port) 64650 port_help $MISSING_DEPENDENCY ;; 64651 pkgutil) 64652 pkgutil_help $MISSING_DEPENDENCY ;; 64653 pkgadd) 64654 pkgadd_help $MISSING_DEPENDENCY ;; 64655 esac 64656 64657 if test "x$PKGHANDLER_COMMAND" != x; then 64658 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 64659 fi 64660 fi 64661 64662 if test "x$enable_aot" = "xyes"; then 64663 as_fn_error $? "Found libelf but could not link and compile with it. Remove --enable-aot to disable AOT or: $HELP_MSG" "$LINENO" 5 64664 else 64665 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Found libelf but could not link and compile with it. $HELP_MSG" >&5 64666 $as_echo "$as_me: WARNING: Found libelf but could not link and compile with it. $HELP_MSG" >&2;} 64667 fi 64668 fi 64669 fi 64670 fi 64671 fi 64672 64673 64674 64675 64676 64677 64678 64679 64680 64681 64682 64683 64684 64685 64686 64687 64688 64689 64690 # Hotspot setup depends on lib checks (AOT needs libelf). 64691 64692 64693 # The user can in some cases supply additional jvm features. For the custom 64694 # variant, this defines the entire variant. 64695 64696 # Check whether --with-jvm-features was given. 64697 if test "${with_jvm_features+set}" = set; then : 64698 withval=$with_jvm_features; 64699 fi 64700 64701 if test "x$with_jvm_features" != x; then 64702 { $as_echo "$as_me:${as_lineno-$LINENO}: checking additional JVM features" >&5 64703 $as_echo_n "checking additional JVM features... " >&6; } 64704 JVM_FEATURES=`$ECHO $with_jvm_features | $SED -e 's/,/ /g'` 64705 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JVM_FEATURES" >&5 64706 $as_echo "$JVM_FEATURES" >&6; } 64707 fi 64708 64709 # Override hotspot cpu definitions for ARM platforms 64710 if test "x$OPENJDK_TARGET_CPU" = xarm; then 64711 HOTSPOT_TARGET_CPU=arm_32 64712 HOTSPOT_TARGET_CPU_DEFINE="ARM32" 64713 JVM_LDFLAGS="$JVM_LDFLAGS -fsigned-char" 64714 JVM_CFLAGS="$JVM_CFLAGS -DARM -fsigned-char" 64715 elif test "x$OPENJDK_TARGET_CPU" = xaarch64 && test "x$HOTSPOT_TARGET_CPU_PORT" = xarm64; then 64716 HOTSPOT_TARGET_CPU=arm_64 64717 HOTSPOT_TARGET_CPU_ARCH=arm 64718 JVM_LDFLAGS="$JVM_LDFLAGS -fsigned-char" 64719 JVM_CFLAGS="$JVM_CFLAGS -DARM -fsigned-char" 64720 fi 64721 64722 # Verify that dependencies are met for explicitly set features. 64723 if [[ " $JVM_FEATURES " =~ " jvmti " ]] && ! [[ " $JVM_FEATURES " =~ " services " ]] ; then 64724 as_fn_error $? "Specified JVM feature 'jvmti' requires feature 'services'" "$LINENO" 5 64725 fi 64726 64727 if [[ " $JVM_FEATURES " =~ " management " ]] && ! [[ " $JVM_FEATURES " =~ " nmt " ]] ; then 64728 as_fn_error $? "Specified JVM feature 'management' requires feature 'nmt'" "$LINENO" 5 64729 fi 64730 64731 if [[ " $JVM_FEATURES " =~ " jvmci " ]] && ! ( [[ " $JVM_FEATURES " =~ " compiler1 " ]] || [[ " $JVM_FEATURES " =~ " compiler2 " ]] ); then 64732 as_fn_error $? "Specified JVM feature 'jvmci' requires feature 'compiler2' or 'compiler1'" "$LINENO" 5 64733 fi 64734 64735 if [[ " $JVM_FEATURES " =~ " compiler2 " ]] && ! [[ " $JVM_FEATURES " =~ " all-gcs " ]] ; then 64736 as_fn_error $? "Specified JVM feature 'compiler2' requires feature 'all-gcs'" "$LINENO" 5 64737 fi 64738 64739 if [[ " $JVM_FEATURES " =~ " vm-structs " ]] && ! [[ " $JVM_FEATURES " =~ " all-gcs " ]] ; then 64740 as_fn_error $? "Specified JVM feature 'vm-structs' requires feature 'all-gcs'" "$LINENO" 5 64741 fi 64742 64743 # Turn on additional features based on other parts of configure 64744 if test "x$INCLUDE_DTRACE" = "xtrue"; then 64745 JVM_FEATURES="$JVM_FEATURES dtrace" 64746 else 64747 if [[ " $JVM_FEATURES " =~ " dtrace " ]] ; then 64748 as_fn_error $? "To enable dtrace, you must use --enable-dtrace" "$LINENO" 5 64749 fi 64750 fi 64751 64752 if test "x$STATIC_BUILD" = "xtrue"; then 64753 JVM_FEATURES="$JVM_FEATURES static-build" 64754 else 64755 if [[ " $JVM_FEATURES " =~ " static-build " ]] ; then 64756 as_fn_error $? "To enable static-build, you must use --enable-static-build" "$LINENO" 5 64757 fi 64758 fi 64759 64760 if ! [[ " $JVM_VARIANTS " =~ " zero " ]] && ! [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 64761 if [[ " $JVM_FEATURES " =~ " zero " ]] ; then 64762 as_fn_error $? "To enable zero/zeroshark, you must use --with-jvm-variants=zero/zeroshark" "$LINENO" 5 64763 fi 64764 fi 64765 64766 if ! [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 64767 if [[ " $JVM_FEATURES " =~ " shark " ]] ; then 64768 as_fn_error $? "To enable shark, you must use --with-jvm-variants=zeroshark" "$LINENO" 5 64769 fi 64770 fi 64771 64772 # Only enable jvmci on x86_64, sparcv9 and aarch64. 64773 if test "x$OPENJDK_TARGET_CPU" = "xx86_64" || \ 64774 test "x$OPENJDK_TARGET_CPU" = "xsparcv9" || \ 64775 test "x$OPENJDK_TARGET_CPU" = "xaarch64" ; then 64776 JVM_FEATURES_jvmci="jvmci" 64777 else 64778 JVM_FEATURES_jvmci="" 64779 fi 64780 64781 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if jdk.internal.vm.compiler should be built" >&5 64782 $as_echo_n "checking if jdk.internal.vm.compiler should be built... " >&6; } 64783 if [[ " $JVM_FEATURES " =~ " graal " ]] ; then 64784 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 64785 $as_echo "yes, forced" >&6; } 64786 if test "x$JVM_FEATURES_jvmci" != "xjvmci" ; then 64787 as_fn_error $? "Specified JVM feature 'graal' requires feature 'jvmci'" "$LINENO" 5 64788 fi 64789 INCLUDE_GRAAL="true" 64790 else 64791 # By default enable graal build where AOT is available 64792 if test "x$ENABLE_AOT" = "xtrue"; then 64793 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 64794 $as_echo "yes" >&6; } 64795 JVM_FEATURES_graal="graal" 64796 INCLUDE_GRAAL="true" 64797 else 64798 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 64799 $as_echo "no" >&6; } 64800 JVM_FEATURES_graal="" 64801 INCLUDE_GRAAL="false" 64802 fi 64803 fi 64804 64805 64806 64807 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if aot should be enabled" >&5 64808 $as_echo_n "checking if aot should be enabled... " >&6; } 64809 if test "x$ENABLE_AOT" = "xtrue"; then 64810 if test "x$enable_aot" = "xyes"; then 64811 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 64812 $as_echo "yes, forced" >&6; } 64813 else 64814 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 64815 $as_echo "yes" >&6; } 64816 fi 64817 JVM_FEATURES_aot="aot" 64818 else 64819 if test "x$enable_aot" = "xno"; then 64820 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 64821 $as_echo "no, forced" >&6; } 64822 else 64823 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 64824 $as_echo "no" >&6; } 64825 fi 64826 JVM_FEATURES_aot="" 64827 fi 64828 64829 if test "x$OPENJDK_TARGET_CPU" = xarm ; then 64830 # Default to use link time optimizations on minimal on arm 64831 JVM_FEATURES_link_time_opt="link-time-opt" 64832 else 64833 JVM_FEATURES_link_time_opt="" 64834 fi 64835 64836 # All variants but minimal (and custom) get these features 64837 NON_MINIMAL_FEATURES="$NON_MINIMAL_FEATURES jvmti fprof vm-structs jni-check services management all-gcs nmt cds" 64838 64839 # Enable features depending on variant. 64840 JVM_FEATURES_server="compiler1 compiler2 $NON_MINIMAL_FEATURES $JVM_FEATURES $JVM_FEATURES_jvmci $JVM_FEATURES_aot $JVM_FEATURES_graal" 64841 JVM_FEATURES_client="compiler1 $NON_MINIMAL_FEATURES $JVM_FEATURES $JVM_FEATURES_jvmci" 64842 JVM_FEATURES_core="$NON_MINIMAL_FEATURES $JVM_FEATURES" 64843 JVM_FEATURES_minimal="compiler1 minimal $JVM_FEATURES $JVM_FEATURES_link_time_opt" 64844 JVM_FEATURES_zero="zero $NON_MINIMAL_FEATURES $JVM_FEATURES" 64845 JVM_FEATURES_zeroshark="zero shark $NON_MINIMAL_FEATURES $JVM_FEATURES" 64846 JVM_FEATURES_custom="$JVM_FEATURES" 64847 64848 64849 64850 64851 64852 64853 64854 64855 64856 # Used for verification of Makefiles by check-jvm-feature 64857 64858 64859 # We don't support --with-jvm-interpreter anymore, use zero instead. 64860 64861 64862 # Check whether --with-jvm-interpreter was given. 64863 if test "${with_jvm_interpreter+set}" = set; then : 64864 withval=$with_jvm_interpreter; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-jvm-interpreter is deprecated and will be ignored." >&5 64865 $as_echo "$as_me: WARNING: Option --with-jvm-interpreter is deprecated and will be ignored." >&2;} 64866 fi 64867 64868 64869 64870 64871 ############################################################################### 64872 # 64873 # We need to do some final tweaking, when everything else is done. 64874 # 64875 ############################################################################### 64876 64877 64878 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if elliptic curve crypto implementation is present" >&5 64879 $as_echo_n "checking if elliptic curve crypto implementation is present... " >&6; } 64880 64881 if test -d "${SRC_ROOT}/jdk/src/jdk.crypto.ec/share/native/libsunec/impl"; then 64882 ENABLE_INTREE_EC=true 64883 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 64884 $as_echo "yes" >&6; } 64885 else 64886 ENABLE_INTREE_EC=false 64887 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 64888 $as_echo "no" >&6; } 64889 fi 64890 64891 64892 64893 64894 # Check whether --enable-jtreg-failure-handler was given. 64895 if test "${enable_jtreg_failure_handler+set}" = set; then : 64896 enableval=$enable_jtreg_failure_handler; 64897 fi 64898 64899 64900 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if jtreg failure handler should be built" >&5 64901 $as_echo_n "checking if jtreg failure handler should be built... " >&6; } 64902 64903 if test "x$enable_jtreg_failure_handler" = "xyes"; then 64904 if test "x$JT_HOME" = "x"; then 64905 as_fn_error $? "Cannot enable jtreg failure handler without jtreg." "$LINENO" 5 64906 else 64907 BUILD_FAILURE_HANDLER=true 64908 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 64909 $as_echo "yes, forced" >&6; } 64910 fi 64911 elif test "x$enable_jtreg_failure_handler" = "xno"; then 64912 BUILD_FAILURE_HANDLER=false 64913 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 64914 $as_echo "no, forced" >&6; } 64915 elif test "x$enable_jtreg_failure_handler" = "xauto" \ 64916 || test "x$enable_jtreg_failure_handler" = "x"; then 64917 if test "x$JT_HOME" = "x"; then 64918 BUILD_FAILURE_HANDLER=false 64919 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, missing jtreg" >&5 64920 $as_echo "no, missing jtreg" >&6; } 64921 else 64922 BUILD_FAILURE_HANDLER=true 64923 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, jtreg present" >&5 64924 $as_echo "yes, jtreg present" >&6; } 64925 fi 64926 else 64927 as_fn_error $? "Invalid value for --enable-jtreg-failure-handler: $enable_jtreg_failure_handler" "$LINENO" 5 64928 fi 64929 64930 64931 64932 64933 # Check whether --enable-generate-classlist was given. 64934 if test "${enable_generate_classlist+set}" = set; then : 64935 enableval=$enable_generate_classlist; 64936 fi 64937 64938 64939 # Check if it's likely that it's possible to generate the classlist. Depending 64940 # on exact jvm configuration it could be possible anyway. 64941 if [[ " $JVM_VARIANTS " =~ " server " ]] || [[ " $JVM_VARIANTS " =~ " client " ]] ; then 64942 ENABLE_GENERATE_CLASSLIST_POSSIBLE="true" 64943 else 64944 ENABLE_GENERATE_CLASSLIST_POSSIBLE="false" 64945 fi 64946 64947 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the CDS classlist generation should be enabled" >&5 64948 $as_echo_n "checking if the CDS classlist generation should be enabled... " >&6; } 64949 if test "x$enable_generate_classlist" = "xyes"; then 64950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 64951 $as_echo "yes, forced" >&6; } 64952 ENABLE_GENERATE_CLASSLIST="true" 64953 if test "x$ENABLE_GENERATE_CLASSLIST_POSSIBLE" = "xfalse"; then 64954 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Generation of classlist might not be possible with JVM Variants $JVM_VARIANTS" >&5 64955 $as_echo "$as_me: WARNING: Generation of classlist might not be possible with JVM Variants $JVM_VARIANTS" >&2;} 64956 fi 64957 elif test "x$enable_generate_classlist" = "xno"; then 64958 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 64959 $as_echo "no, forced" >&6; } 64960 ENABLE_GENERATE_CLASSLIST="false" 64961 elif test "x$enable_generate_classlist" = "x"; then 64962 if test "x$ENABLE_GENERATE_CLASSLIST_POSSIBLE" = "xtrue"; then 64963 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 64964 $as_echo "yes" >&6; } 64965 ENABLE_GENERATE_CLASSLIST="true" 64966 else 64967 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 64968 $as_echo "no" >&6; } 64969 ENABLE_GENERATE_CLASSLIST="false" 64970 fi 64971 else 64972 as_fn_error $? "Invalid value for --enable-generate-classlist: $enable_generate_classlist" "$LINENO" 5 64973 fi 64974 64975 64976 64977 64978 ############################################################################### 64979 # 64980 # Configure parts of the build that only affect the build performance, 64981 # not the result. 64982 # 64983 ############################################################################### 64984 64985 64986 # How many cores do we have on this build system? 64987 64988 # Check whether --with-num-cores was given. 64989 if test "${with_num_cores+set}" = set; then : 64990 withval=$with_num_cores; 64991 fi 64992 64993 if test "x$with_num_cores" = x; then 64994 # The number of cores were not specified, try to probe them. 64995 64996 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for number of cores" >&5 64997 $as_echo_n "checking for number of cores... " >&6; } 64998 NUM_CORES=1 64999 FOUND_CORES=no 65000 65001 if test -f /proc/cpuinfo; then 65002 # Looks like a Linux (or cygwin) system 65003 NUM_CORES=`cat /proc/cpuinfo | grep -c processor` 65004 FOUND_CORES=yes 65005 elif test -x /usr/sbin/psrinfo; then 65006 # Looks like a Solaris system 65007 NUM_CORES=`LC_MESSAGES=C /usr/sbin/psrinfo -v | grep -c on-line` 65008 FOUND_CORES=yes 65009 elif test -x /usr/sbin/sysctl; then 65010 # Looks like a MacOSX system 65011 NUM_CORES=`/usr/sbin/sysctl -n hw.ncpu` 65012 FOUND_CORES=yes 65013 elif test "x$OPENJDK_BUILD_OS" = xaix ; then 65014 NUM_CORES=`/usr/sbin/prtconf | grep "^Number Of Processors" | awk '{ print $4 }'` 65015 FOUND_CORES=yes 65016 elif test -n "$NUMBER_OF_PROCESSORS"; then 65017 # On windows, look in the env 65018 NUM_CORES=$NUMBER_OF_PROCESSORS 65019 FOUND_CORES=yes 65020 fi 65021 65022 if test "x$FOUND_CORES" = xyes; then 65023 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NUM_CORES" >&5 65024 $as_echo "$NUM_CORES" >&6; } 65025 else 65026 { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not detect number of cores, defaulting to 1" >&5 65027 $as_echo "could not detect number of cores, defaulting to 1" >&6; } 65028 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This will disable all parallelism from build!" >&5 65029 $as_echo "$as_me: WARNING: This will disable all parallelism from build!" >&2;} 65030 fi 65031 65032 else 65033 NUM_CORES=$with_num_cores 65034 fi 65035 65036 65037 65038 # How much memory do we have on this build system? 65039 65040 # Check whether --with-memory-size was given. 65041 if test "${with_memory_size+set}" = set; then : 65042 withval=$with_memory_size; 65043 fi 65044 65045 if test "x$with_memory_size" = x; then 65046 # The memory size was not specified, try to probe it. 65047 65048 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for memory size" >&5 65049 $as_echo_n "checking for memory size... " >&6; } 65050 # Default to 1024 MB 65051 MEMORY_SIZE=1024 65052 FOUND_MEM=no 65053 65054 if test -f /proc/meminfo; then 65055 # Looks like a Linux (or cygwin) system 65056 MEMORY_SIZE=`cat /proc/meminfo | grep MemTotal | awk '{print $2}'` 65057 MEMORY_SIZE=`expr $MEMORY_SIZE / 1024` 65058 FOUND_MEM=yes 65059 elif test -x /usr/sbin/prtconf; then 65060 # Looks like a Solaris or AIX system 65061 MEMORY_SIZE=`/usr/sbin/prtconf 2> /dev/null | grep "^Memory [Ss]ize" | awk '{ print $3 }'` 65062 FOUND_MEM=yes 65063 elif test -x /usr/sbin/sysctl; then 65064 # Looks like a MacOSX system 65065 MEMORY_SIZE=`/usr/sbin/sysctl -n hw.memsize` 65066 MEMORY_SIZE=`expr $MEMORY_SIZE / 1024 / 1024` 65067 FOUND_MEM=yes 65068 elif test "x$OPENJDK_BUILD_OS" = xwindows; then 65069 # Windows, but without cygwin 65070 MEMORY_SIZE=`wmic computersystem get totalphysicalmemory -value | grep = | cut -d "=" -f 2-` 65071 MEMORY_SIZE=`expr $MEMORY_SIZE / 1024 / 1024` 65072 FOUND_MEM=yes 65073 fi 65074 65075 if test "x$FOUND_MEM" = xyes; then 65076 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MEMORY_SIZE MB" >&5 65077 $as_echo "$MEMORY_SIZE MB" >&6; } 65078 else 65079 { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not detect memory size, defaulting to $MEMORY_SIZE MB" >&5 65080 $as_echo "could not detect memory size, defaulting to $MEMORY_SIZE MB" >&6; } 65081 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This might seriously impact build performance!" >&5 65082 $as_echo "$as_me: WARNING: This might seriously impact build performance!" >&2;} 65083 fi 65084 65085 else 65086 MEMORY_SIZE=$with_memory_size 65087 fi 65088 65089 65090 65091 # Provide a decent default number of parallel jobs for make depending on 65092 # number of cores, amount of memory and machine architecture. 65093 65094 # Check whether --with-jobs was given. 65095 if test "${with_jobs+set}" = set; then : 65096 withval=$with_jobs; 65097 fi 65098 65099 if test "x$with_jobs" = x; then 65100 # Number of jobs was not specified, calculate. 65101 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for appropriate number of jobs to run in parallel" >&5 65102 $as_echo_n "checking for appropriate number of jobs to run in parallel... " >&6; } 65103 # Approximate memory in GB. 65104 memory_gb=`expr $MEMORY_SIZE / 1024` 65105 # Pick the lowest of memory in gb and number of cores. 65106 if test "$memory_gb" -lt "$NUM_CORES"; then 65107 JOBS="$memory_gb" 65108 else 65109 JOBS="$NUM_CORES" 65110 fi 65111 if test "$JOBS" -eq "0"; then 65112 JOBS=1 65113 fi 65114 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JOBS" >&5 65115 $as_echo "$JOBS" >&6; } 65116 else 65117 JOBS=$with_jobs 65118 fi 65119 65120 65121 65122 # The number of test jobs will be chosen automatically if TEST_JOBS is 0 65123 65124 # Check whether --with-test-jobs was given. 65125 if test "${with_test_jobs+set}" = set; then : 65126 withval=$with_test_jobs; 65127 fi 65128 65129 if test "x$with_test_jobs" = x; then 65130 TEST_JOBS=0 65131 else 65132 TEST_JOBS=$with_test_jobs 65133 fi 65134 65135 65136 65137 # Setup arguments for the boot jdk (after cores and memory have been setup) 65138 65139 ############################################################################## 65140 # 65141 # Specify jvm options for anything that is run with the Boot JDK. 65142 # Not all JVM:s accept the same arguments on the command line. 65143 # 65144 65145 # Check whether --with-boot-jdk-jvmargs was given. 65146 if test "${with_boot_jdk_jvmargs+set}" = set; then : 65147 withval=$with_boot_jdk_jvmargs; 65148 fi 65149 65150 65151 { $as_echo "$as_me:${as_lineno-$LINENO}: checking flags for boot jdk java command " >&5 65152 $as_echo_n "checking flags for boot jdk java command ... " >&6; } 65153 65154 # Disable special log output when a debug build is used as Boot JDK... 65155 65156 $ECHO "Check if jvm arg is ok: -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput" >&5 65157 $ECHO "Command: $JAVA -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput -version" >&5 65158 OUTPUT=`$JAVA -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput -version 2>&1` 65159 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 65160 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 65161 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 65162 boot_jdk_jvmargs="$boot_jdk_jvmargs -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput" 65163 JVM_ARG_OK=true 65164 else 65165 $ECHO "Arg failed:" >&5 65166 $ECHO "$OUTPUT" >&5 65167 JVM_ARG_OK=false 65168 fi 65169 65170 65171 # Force en-US environment 65172 65173 $ECHO "Check if jvm arg is ok: -Duser.language=en -Duser.country=US" >&5 65174 $ECHO "Command: $JAVA -Duser.language=en -Duser.country=US -version" >&5 65175 OUTPUT=`$JAVA -Duser.language=en -Duser.country=US -version 2>&1` 65176 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 65177 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 65178 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 65179 boot_jdk_jvmargs="$boot_jdk_jvmargs -Duser.language=en -Duser.country=US" 65180 JVM_ARG_OK=true 65181 else 65182 $ECHO "Arg failed:" >&5 65183 $ECHO "$OUTPUT" >&5 65184 JVM_ARG_OK=false 65185 fi 65186 65187 65188 # Apply user provided options. 65189 65190 $ECHO "Check if jvm arg is ok: $with_boot_jdk_jvmargs" >&5 65191 $ECHO "Command: $JAVA $with_boot_jdk_jvmargs -version" >&5 65192 OUTPUT=`$JAVA $with_boot_jdk_jvmargs -version 2>&1` 65193 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 65194 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 65195 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 65196 boot_jdk_jvmargs="$boot_jdk_jvmargs $with_boot_jdk_jvmargs" 65197 JVM_ARG_OK=true 65198 else 65199 $ECHO "Arg failed:" >&5 65200 $ECHO "$OUTPUT" >&5 65201 JVM_ARG_OK=false 65202 fi 65203 65204 65205 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $boot_jdk_jvmargs" >&5 65206 $as_echo "$boot_jdk_jvmargs" >&6; } 65207 65208 # For now, general JAVA_FLAGS are the same as the boot jdk jvmargs 65209 JAVA_FLAGS=$boot_jdk_jvmargs 65210 65211 65212 65213 { $as_echo "$as_me:${as_lineno-$LINENO}: checking flags for boot jdk java command for big workloads" >&5 65214 $as_echo_n "checking flags for boot jdk java command for big workloads... " >&6; } 65215 65216 # Starting amount of heap memory. 65217 65218 $ECHO "Check if jvm arg is ok: -Xms64M" >&5 65219 $ECHO "Command: $JAVA -Xms64M -version" >&5 65220 OUTPUT=`$JAVA -Xms64M -version 2>&1` 65221 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 65222 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 65223 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 65224 boot_jdk_jvmargs_big="$boot_jdk_jvmargs_big -Xms64M" 65225 JVM_ARG_OK=true 65226 else 65227 $ECHO "Arg failed:" >&5 65228 $ECHO "$OUTPUT" >&5 65229 JVM_ARG_OK=false 65230 fi 65231 65232 BOOTCYCLE_JVM_ARGS_BIG=-Xms64M 65233 65234 # Maximum amount of heap memory and stack size. 65235 JVM_HEAP_LIMIT_32="1024" 65236 # Running a 64 bit JVM allows for and requires a bigger heap 65237 JVM_HEAP_LIMIT_64="1600" 65238 STACK_SIZE_32=768 65239 STACK_SIZE_64=1536 65240 JVM_HEAP_LIMIT_GLOBAL=`expr $MEMORY_SIZE / 2` 65241 if test "$JVM_HEAP_LIMIT_GLOBAL" -lt "$JVM_HEAP_LIMIT_32"; then 65242 JVM_HEAP_LIMIT_32=$JVM_HEAP_LIMIT_GLOBAL 65243 fi 65244 if test "$JVM_HEAP_LIMIT_GLOBAL" -lt "$JVM_HEAP_LIMIT_64"; then 65245 JVM_HEAP_LIMIT_64=$JVM_HEAP_LIMIT_GLOBAL 65246 fi 65247 if test "$JVM_HEAP_LIMIT_GLOBAL" -lt "512"; then 65248 JVM_HEAP_LIMIT_32=512 65249 JVM_HEAP_LIMIT_64=512 65250 fi 65251 65252 if test "x$BOOT_JDK_BITS" = "x32"; then 65253 STACK_SIZE=$STACK_SIZE_32 65254 JVM_MAX_HEAP=$JVM_HEAP_LIMIT_32 65255 else 65256 STACK_SIZE=$STACK_SIZE_64 65257 JVM_MAX_HEAP=$JVM_HEAP_LIMIT_64 65258 fi 65259 65260 $ECHO "Check if jvm arg is ok: -Xmx${JVM_MAX_HEAP}M" >&5 65261 $ECHO "Command: $JAVA -Xmx${JVM_MAX_HEAP}M -version" >&5 65262 OUTPUT=`$JAVA -Xmx${JVM_MAX_HEAP}M -version 2>&1` 65263 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 65264 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 65265 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 65266 boot_jdk_jvmargs_big="$boot_jdk_jvmargs_big -Xmx${JVM_MAX_HEAP}M" 65267 JVM_ARG_OK=true 65268 else 65269 $ECHO "Arg failed:" >&5 65270 $ECHO "$OUTPUT" >&5 65271 JVM_ARG_OK=false 65272 fi 65273 65274 65275 $ECHO "Check if jvm arg is ok: -XX:ThreadStackSize=$STACK_SIZE" >&5 65276 $ECHO "Command: $JAVA -XX:ThreadStackSize=$STACK_SIZE -version" >&5 65277 OUTPUT=`$JAVA -XX:ThreadStackSize=$STACK_SIZE -version 2>&1` 65278 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 65279 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 65280 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 65281 boot_jdk_jvmargs_big="$boot_jdk_jvmargs_big -XX:ThreadStackSize=$STACK_SIZE" 65282 JVM_ARG_OK=true 65283 else 65284 $ECHO "Arg failed:" >&5 65285 $ECHO "$OUTPUT" >&5 65286 JVM_ARG_OK=false 65287 fi 65288 65289 65290 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $boot_jdk_jvmargs_big" >&5 65291 $as_echo "$boot_jdk_jvmargs_big" >&6; } 65292 65293 JAVA_FLAGS_BIG=$boot_jdk_jvmargs_big 65294 65295 65296 if test "x$OPENJDK_TARGET_CPU_BITS" = "x32"; then 65297 BOOTCYCLE_MAX_HEAP=$JVM_HEAP_LIMIT_32 65298 BOOTCYCLE_STACK_SIZE=$STACK_SIZE_32 65299 else 65300 BOOTCYCLE_MAX_HEAP=$JVM_HEAP_LIMIT_64 65301 BOOTCYCLE_STACK_SIZE=$STACK_SIZE_64 65302 fi 65303 BOOTCYCLE_JVM_ARGS_BIG="$BOOTCYCLE_JVM_ARGS_BIG -Xmx${BOOTCYCLE_MAX_HEAP}M" 65304 BOOTCYCLE_JVM_ARGS_BIG="$BOOTCYCLE_JVM_ARGS_BIG -XX:ThreadStackSize=$BOOTCYCLE_STACK_SIZE" 65305 { $as_echo "$as_me:${as_lineno-$LINENO}: checking flags for bootcycle boot jdk java command for big workloads" >&5 65306 $as_echo_n "checking flags for bootcycle boot jdk java command for big workloads... " >&6; } 65307 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOTCYCLE_JVM_ARGS_BIG" >&5 65308 $as_echo "$BOOTCYCLE_JVM_ARGS_BIG" >&6; } 65309 65310 65311 # By default, the main javac compilations use big 65312 JAVA_FLAGS_JAVAC="$JAVA_FLAGS_BIG" 65313 65314 65315 { $as_echo "$as_me:${as_lineno-$LINENO}: checking flags for boot jdk java command for small workloads" >&5 65316 $as_echo_n "checking flags for boot jdk java command for small workloads... " >&6; } 65317 65318 # Use serial gc for small short lived tools if possible 65319 65320 $ECHO "Check if jvm arg is ok: -XX:+UseSerialGC" >&5 65321 $ECHO "Command: $JAVA -XX:+UseSerialGC -version" >&5 65322 OUTPUT=`$JAVA -XX:+UseSerialGC -version 2>&1` 65323 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 65324 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 65325 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 65326 boot_jdk_jvmargs_small="$boot_jdk_jvmargs_small -XX:+UseSerialGC" 65327 JVM_ARG_OK=true 65328 else 65329 $ECHO "Arg failed:" >&5 65330 $ECHO "$OUTPUT" >&5 65331 JVM_ARG_OK=false 65332 fi 65333 65334 65335 $ECHO "Check if jvm arg is ok: -Xms32M" >&5 65336 $ECHO "Command: $JAVA -Xms32M -version" >&5 65337 OUTPUT=`$JAVA -Xms32M -version 2>&1` 65338 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 65339 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 65340 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 65341 boot_jdk_jvmargs_small="$boot_jdk_jvmargs_small -Xms32M" 65342 JVM_ARG_OK=true 65343 else 65344 $ECHO "Arg failed:" >&5 65345 $ECHO "$OUTPUT" >&5 65346 JVM_ARG_OK=false 65347 fi 65348 65349 65350 $ECHO "Check if jvm arg is ok: -Xmx512M" >&5 65351 $ECHO "Command: $JAVA -Xmx512M -version" >&5 65352 OUTPUT=`$JAVA -Xmx512M -version 2>&1` 65353 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 65354 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 65355 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 65356 boot_jdk_jvmargs_small="$boot_jdk_jvmargs_small -Xmx512M" 65357 JVM_ARG_OK=true 65358 else 65359 $ECHO "Arg failed:" >&5 65360 $ECHO "$OUTPUT" >&5 65361 JVM_ARG_OK=false 65362 fi 65363 65364 65365 $ECHO "Check if jvm arg is ok: -XX:TieredStopAtLevel=1" >&5 65366 $ECHO "Command: $JAVA -XX:TieredStopAtLevel=1 -version" >&5 65367 OUTPUT=`$JAVA -XX:TieredStopAtLevel=1 -version 2>&1` 65368 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 65369 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 65370 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 65371 boot_jdk_jvmargs_small="$boot_jdk_jvmargs_small -XX:TieredStopAtLevel=1" 65372 JVM_ARG_OK=true 65373 else 65374 $ECHO "Arg failed:" >&5 65375 $ECHO "$OUTPUT" >&5 65376 JVM_ARG_OK=false 65377 fi 65378 65379 65380 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $boot_jdk_jvmargs_small" >&5 65381 $as_echo "$boot_jdk_jvmargs_small" >&6; } 65382 65383 JAVA_FLAGS_SMALL=$boot_jdk_jvmargs_small 65384 65385 65386 JAVA_TOOL_FLAGS_SMALL="" 65387 for f in $JAVA_FLAGS_SMALL; do 65388 JAVA_TOOL_FLAGS_SMALL="$JAVA_TOOL_FLAGS_SMALL -J$f" 65389 done 65390 65391 65392 65393 # Setup smart javac (after cores and memory have been setup) 65394 65395 65396 # Check whether --with-sjavac-server-java was given. 65397 if test "${with_sjavac_server_java+set}" = set; then : 65398 withval=$with_sjavac_server_java; 65399 fi 65400 65401 65402 if test "x$with_sjavac_server_java" != x; then 65403 SJAVAC_SERVER_JAVA="$with_sjavac_server_java" 65404 FOUND_VERSION=`$SJAVAC_SERVER_JAVA -version 2>&1 | grep " version \""` 65405 if test "x$FOUND_VERSION" = x; then 65406 as_fn_error $? "Could not execute server java: $SJAVAC_SERVER_JAVA" "$LINENO" 5 65407 fi 65408 else 65409 SJAVAC_SERVER_JAVA="$JAVA" 65410 fi 65411 65412 65413 if test "$MEMORY_SIZE" -gt "3000"; then 65414 65415 $ECHO "Check if jvm arg is ok: -d64" >&5 65416 $ECHO "Command: $SJAVAC_SERVER_JAVA -d64 -version" >&5 65417 OUTPUT=`$SJAVAC_SERVER_JAVA -d64 -version 2>&1` 65418 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 65419 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 65420 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 65421 SJAVAC_SERVER_JAVA_FLAGS="$SJAVAC_SERVER_JAVA_FLAGS -d64" 65422 JVM_ARG_OK=true 65423 else 65424 $ECHO "Arg failed:" >&5 65425 $ECHO "$OUTPUT" >&5 65426 JVM_ARG_OK=false 65427 fi 65428 65429 if test "$JVM_ARG_OK" = true; then 65430 JVM_64BIT=true 65431 JVM_ARG_OK=false 65432 fi 65433 fi 65434 65435 MX_VALUE=`expr $MEMORY_SIZE / 2` 65436 if test "$JVM_64BIT" = true; then 65437 # Set ms lower than mx since more than one instance of the server might 65438 # get launched at the same time before they figure out which instance won. 65439 MS_VALUE=512 65440 if test "$MX_VALUE" -gt "2048"; then 65441 MX_VALUE=2048 65442 fi 65443 else 65444 MS_VALUE=256 65445 if test "$MX_VALUE" -gt "1500"; then 65446 MX_VALUE=1500 65447 fi 65448 fi 65449 if test "$MX_VALUE" -lt "512"; then 65450 MX_VALUE=512 65451 fi 65452 65453 $ECHO "Check if jvm arg is ok: -Xms${MS_VALUE}M -Xmx${MX_VALUE}M" >&5 65454 $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms${MS_VALUE}M -Xmx${MX_VALUE}M -version" >&5 65455 OUTPUT=`$SJAVAC_SERVER_JAVA -Xms${MS_VALUE}M -Xmx${MX_VALUE}M -version 2>&1` 65456 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 65457 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 65458 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 65459 SJAVAC_SERVER_JAVA_FLAGS="$SJAVAC_SERVER_JAVA_FLAGS -Xms${MS_VALUE}M -Xmx${MX_VALUE}M" 65460 JVM_ARG_OK=true 65461 else 65462 $ECHO "Arg failed:" >&5 65463 $ECHO "$OUTPUT" >&5 65464 JVM_ARG_OK=false 65465 fi 65466 65467 65468 65469 # Check whether --enable-sjavac was given. 65470 if test "${enable_sjavac+set}" = set; then : 65471 enableval=$enable_sjavac; ENABLE_SJAVAC="${enableval}" 65472 else 65473 ENABLE_SJAVAC="no" 65474 fi 65475 65476 if test "x$JVM_ARG_OK" = "xfalse"; then 65477 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Could not set -Xms${MS_VALUE}M -Xmx${MX_VALUE}M, disabling sjavac" >&5 65478 $as_echo "$as_me: WARNING: Could not set -Xms${MS_VALUE}M -Xmx${MX_VALUE}M, disabling sjavac" >&2;} 65479 ENABLE_SJAVAC="no" 65480 fi 65481 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use sjavac" >&5 65482 $as_echo_n "checking whether to use sjavac... " >&6; } 65483 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ENABLE_SJAVAC" >&5 65484 $as_echo "$ENABLE_SJAVAC" >&6; } 65485 65486 65487 # Check whether --enable-javac-server was given. 65488 if test "${enable_javac_server+set}" = set; then : 65489 enableval=$enable_javac_server; ENABLE_JAVAC_SERVER="${enableval}" 65490 else 65491 ENABLE_JAVAC_SERVER="yes" 65492 fi 65493 65494 if test "x$JVM_ARG_OK" = "xfalse"; then 65495 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Could not set -Xms${MS_VALUE}M -Xmx${MX_VALUE}M, disabling javac server" >&5 65496 $as_echo "$as_me: WARNING: Could not set -Xms${MS_VALUE}M -Xmx${MX_VALUE}M, disabling javac server" >&2;} 65497 ENABLE_JAVAC_SERVER="no" 65498 fi 65499 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use javac server" >&5 65500 $as_echo_n "checking whether to use javac server... " >&6; } 65501 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ENABLE_JAVAC_SERVER" >&5 65502 $as_echo "$ENABLE_JAVAC_SERVER" >&6; } 65503 65504 65505 if test "x$ENABLE_JAVAC_SERVER" = "xyes" || test "x$ENABLE_SJAVAC" = "xyes"; then 65506 # When using a server javac, the small client instances do not need much 65507 # resources. 65508 JAVA_FLAGS_JAVAC="$JAVA_FLAGS_SMALL" 65509 fi 65510 65511 65512 # Setup use of icecc if requested 65513 65514 # Check whether --enable-icecc was given. 65515 if test "${enable_icecc+set}" = set; then : 65516 enableval=$enable_icecc; 65517 fi 65518 65519 65520 if test "x${enable_icecc}" = "xyes"; then 65521 65522 65523 65524 # Publish this variable in the help. 65525 65526 65527 if [ -z "${ICECC_CMD+x}" ]; then 65528 # The variable is not set by user, try to locate tool using the code snippet 65529 for ac_prog in icecc 65530 do 65531 # Extract the first word of "$ac_prog", so it can be a program name with args. 65532 set dummy $ac_prog; ac_word=$2 65533 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 65534 $as_echo_n "checking for $ac_word... " >&6; } 65535 if ${ac_cv_path_ICECC_CMD+:} false; then : 65536 $as_echo_n "(cached) " >&6 65537 else 65538 case $ICECC_CMD in 65539 [\\/]* | ?:[\\/]*) 65540 ac_cv_path_ICECC_CMD="$ICECC_CMD" # Let the user override the test with a path. 65541 ;; 65542 *) 65543 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 65544 for as_dir in $PATH 65545 do 65546 IFS=$as_save_IFS 65547 test -z "$as_dir" && as_dir=. 65548 for ac_exec_ext in '' $ac_executable_extensions; do 65549 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 65550 ac_cv_path_ICECC_CMD="$as_dir/$ac_word$ac_exec_ext" 65551 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 65552 break 2 65553 fi 65554 done 65555 done 65556 IFS=$as_save_IFS 65557 65558 ;; 65559 esac 65560 fi 65561 ICECC_CMD=$ac_cv_path_ICECC_CMD 65562 if test -n "$ICECC_CMD"; then 65563 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CMD" >&5 65564 $as_echo "$ICECC_CMD" >&6; } 65565 else 65566 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65567 $as_echo "no" >&6; } 65568 fi 65569 65570 65571 test -n "$ICECC_CMD" && break 65572 done 65573 65574 else 65575 # The variable is set, but is it from the command line or the environment? 65576 65577 # Try to remove the string !ICECC_CMD! from our list. 65578 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ICECC_CMD!/} 65579 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 65580 # If it failed, the variable was not from the command line. Ignore it, 65581 # but warn the user (except for BASH, which is always set by the calling BASH). 65582 if test "xICECC_CMD" != xBASH; then 65583 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ICECC_CMD from the environment. Use command line variables instead." >&5 65584 $as_echo "$as_me: WARNING: Ignoring value of ICECC_CMD from the environment. Use command line variables instead." >&2;} 65585 fi 65586 # Try to locate tool using the code snippet 65587 for ac_prog in icecc 65588 do 65589 # Extract the first word of "$ac_prog", so it can be a program name with args. 65590 set dummy $ac_prog; ac_word=$2 65591 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 65592 $as_echo_n "checking for $ac_word... " >&6; } 65593 if ${ac_cv_path_ICECC_CMD+:} false; then : 65594 $as_echo_n "(cached) " >&6 65595 else 65596 case $ICECC_CMD in 65597 [\\/]* | ?:[\\/]*) 65598 ac_cv_path_ICECC_CMD="$ICECC_CMD" # Let the user override the test with a path. 65599 ;; 65600 *) 65601 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 65602 for as_dir in $PATH 65603 do 65604 IFS=$as_save_IFS 65605 test -z "$as_dir" && as_dir=. 65606 for ac_exec_ext in '' $ac_executable_extensions; do 65607 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 65608 ac_cv_path_ICECC_CMD="$as_dir/$ac_word$ac_exec_ext" 65609 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 65610 break 2 65611 fi 65612 done 65613 done 65614 IFS=$as_save_IFS 65615 65616 ;; 65617 esac 65618 fi 65619 ICECC_CMD=$ac_cv_path_ICECC_CMD 65620 if test -n "$ICECC_CMD"; then 65621 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CMD" >&5 65622 $as_echo "$ICECC_CMD" >&6; } 65623 else 65624 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65625 $as_echo "no" >&6; } 65626 fi 65627 65628 65629 test -n "$ICECC_CMD" && break 65630 done 65631 65632 else 65633 # If it succeeded, then it was overridden by the user. We will use it 65634 # for the tool. 65635 65636 # First remove it from the list of overridden variables, so we can test 65637 # for unknown variables in the end. 65638 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 65639 65640 # Check if we try to supply an empty value 65641 if test "x$ICECC_CMD" = x; then 65642 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ICECC_CMD= (no value)" >&5 65643 $as_echo "$as_me: Setting user supplied tool ICECC_CMD= (no value)" >&6;} 65644 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_CMD" >&5 65645 $as_echo_n "checking for ICECC_CMD... " >&6; } 65646 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 65647 $as_echo "disabled" >&6; } 65648 else 65649 # Check if the provided tool contains a complete path. 65650 tool_specified="$ICECC_CMD" 65651 tool_basename="${tool_specified##*/}" 65652 if test "x$tool_basename" = "x$tool_specified"; then 65653 # A command without a complete path is provided, search $PATH. 65654 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ICECC_CMD=$tool_basename" >&5 65655 $as_echo "$as_me: Will search for user supplied tool ICECC_CMD=$tool_basename" >&6;} 65656 # Extract the first word of "$tool_basename", so it can be a program name with args. 65657 set dummy $tool_basename; ac_word=$2 65658 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 65659 $as_echo_n "checking for $ac_word... " >&6; } 65660 if ${ac_cv_path_ICECC_CMD+:} false; then : 65661 $as_echo_n "(cached) " >&6 65662 else 65663 case $ICECC_CMD in 65664 [\\/]* | ?:[\\/]*) 65665 ac_cv_path_ICECC_CMD="$ICECC_CMD" # Let the user override the test with a path. 65666 ;; 65667 *) 65668 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 65669 for as_dir in $PATH 65670 do 65671 IFS=$as_save_IFS 65672 test -z "$as_dir" && as_dir=. 65673 for ac_exec_ext in '' $ac_executable_extensions; do 65674 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 65675 ac_cv_path_ICECC_CMD="$as_dir/$ac_word$ac_exec_ext" 65676 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 65677 break 2 65678 fi 65679 done 65680 done 65681 IFS=$as_save_IFS 65682 65683 ;; 65684 esac 65685 fi 65686 ICECC_CMD=$ac_cv_path_ICECC_CMD 65687 if test -n "$ICECC_CMD"; then 65688 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CMD" >&5 65689 $as_echo "$ICECC_CMD" >&6; } 65690 else 65691 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65692 $as_echo "no" >&6; } 65693 fi 65694 65695 65696 if test "x$ICECC_CMD" = x; then 65697 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 65698 fi 65699 else 65700 # Otherwise we believe it is a complete path. Use it as it is. 65701 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ICECC_CMD=$tool_specified" >&5 65702 $as_echo "$as_me: Will use user supplied tool ICECC_CMD=$tool_specified" >&6;} 65703 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_CMD" >&5 65704 $as_echo_n "checking for ICECC_CMD... " >&6; } 65705 if test ! -x "$tool_specified"; then 65706 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 65707 $as_echo "not found" >&6; } 65708 as_fn_error $? "User supplied tool ICECC_CMD=$tool_specified does not exist or is not executable" "$LINENO" 5 65709 fi 65710 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 65711 $as_echo "$tool_specified" >&6; } 65712 fi 65713 fi 65714 fi 65715 65716 fi 65717 65718 65719 65720 if test "x$ICECC_CMD" = x; then 65721 as_fn_error $? "Could not find required tool for ICECC_CMD" "$LINENO" 5 65722 fi 65723 65724 65725 old_path="$PATH" 65726 65727 # Look for icecc-create-env in some known places 65728 PATH="$PATH:/usr/lib/icecc:/usr/lib64/icecc" 65729 65730 65731 65732 # Publish this variable in the help. 65733 65734 65735 if [ -z "${ICECC_CREATE_ENV+x}" ]; then 65736 # The variable is not set by user, try to locate tool using the code snippet 65737 for ac_prog in icecc-create-env 65738 do 65739 # Extract the first word of "$ac_prog", so it can be a program name with args. 65740 set dummy $ac_prog; ac_word=$2 65741 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 65742 $as_echo_n "checking for $ac_word... " >&6; } 65743 if ${ac_cv_path_ICECC_CREATE_ENV+:} false; then : 65744 $as_echo_n "(cached) " >&6 65745 else 65746 case $ICECC_CREATE_ENV in 65747 [\\/]* | ?:[\\/]*) 65748 ac_cv_path_ICECC_CREATE_ENV="$ICECC_CREATE_ENV" # Let the user override the test with a path. 65749 ;; 65750 *) 65751 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 65752 for as_dir in $PATH 65753 do 65754 IFS=$as_save_IFS 65755 test -z "$as_dir" && as_dir=. 65756 for ac_exec_ext in '' $ac_executable_extensions; do 65757 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 65758 ac_cv_path_ICECC_CREATE_ENV="$as_dir/$ac_word$ac_exec_ext" 65759 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 65760 break 2 65761 fi 65762 done 65763 done 65764 IFS=$as_save_IFS 65765 65766 ;; 65767 esac 65768 fi 65769 ICECC_CREATE_ENV=$ac_cv_path_ICECC_CREATE_ENV 65770 if test -n "$ICECC_CREATE_ENV"; then 65771 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CREATE_ENV" >&5 65772 $as_echo "$ICECC_CREATE_ENV" >&6; } 65773 else 65774 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65775 $as_echo "no" >&6; } 65776 fi 65777 65778 65779 test -n "$ICECC_CREATE_ENV" && break 65780 done 65781 65782 else 65783 # The variable is set, but is it from the command line or the environment? 65784 65785 # Try to remove the string !ICECC_CREATE_ENV! from our list. 65786 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ICECC_CREATE_ENV!/} 65787 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 65788 # If it failed, the variable was not from the command line. Ignore it, 65789 # but warn the user (except for BASH, which is always set by the calling BASH). 65790 if test "xICECC_CREATE_ENV" != xBASH; then 65791 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ICECC_CREATE_ENV from the environment. Use command line variables instead." >&5 65792 $as_echo "$as_me: WARNING: Ignoring value of ICECC_CREATE_ENV from the environment. Use command line variables instead." >&2;} 65793 fi 65794 # Try to locate tool using the code snippet 65795 for ac_prog in icecc-create-env 65796 do 65797 # Extract the first word of "$ac_prog", so it can be a program name with args. 65798 set dummy $ac_prog; ac_word=$2 65799 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 65800 $as_echo_n "checking for $ac_word... " >&6; } 65801 if ${ac_cv_path_ICECC_CREATE_ENV+:} false; then : 65802 $as_echo_n "(cached) " >&6 65803 else 65804 case $ICECC_CREATE_ENV in 65805 [\\/]* | ?:[\\/]*) 65806 ac_cv_path_ICECC_CREATE_ENV="$ICECC_CREATE_ENV" # Let the user override the test with a path. 65807 ;; 65808 *) 65809 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 65810 for as_dir in $PATH 65811 do 65812 IFS=$as_save_IFS 65813 test -z "$as_dir" && as_dir=. 65814 for ac_exec_ext in '' $ac_executable_extensions; do 65815 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 65816 ac_cv_path_ICECC_CREATE_ENV="$as_dir/$ac_word$ac_exec_ext" 65817 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 65818 break 2 65819 fi 65820 done 65821 done 65822 IFS=$as_save_IFS 65823 65824 ;; 65825 esac 65826 fi 65827 ICECC_CREATE_ENV=$ac_cv_path_ICECC_CREATE_ENV 65828 if test -n "$ICECC_CREATE_ENV"; then 65829 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CREATE_ENV" >&5 65830 $as_echo "$ICECC_CREATE_ENV" >&6; } 65831 else 65832 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65833 $as_echo "no" >&6; } 65834 fi 65835 65836 65837 test -n "$ICECC_CREATE_ENV" && break 65838 done 65839 65840 else 65841 # If it succeeded, then it was overridden by the user. We will use it 65842 # for the tool. 65843 65844 # First remove it from the list of overridden variables, so we can test 65845 # for unknown variables in the end. 65846 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 65847 65848 # Check if we try to supply an empty value 65849 if test "x$ICECC_CREATE_ENV" = x; then 65850 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ICECC_CREATE_ENV= (no value)" >&5 65851 $as_echo "$as_me: Setting user supplied tool ICECC_CREATE_ENV= (no value)" >&6;} 65852 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_CREATE_ENV" >&5 65853 $as_echo_n "checking for ICECC_CREATE_ENV... " >&6; } 65854 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 65855 $as_echo "disabled" >&6; } 65856 else 65857 # Check if the provided tool contains a complete path. 65858 tool_specified="$ICECC_CREATE_ENV" 65859 tool_basename="${tool_specified##*/}" 65860 if test "x$tool_basename" = "x$tool_specified"; then 65861 # A command without a complete path is provided, search $PATH. 65862 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ICECC_CREATE_ENV=$tool_basename" >&5 65863 $as_echo "$as_me: Will search for user supplied tool ICECC_CREATE_ENV=$tool_basename" >&6;} 65864 # Extract the first word of "$tool_basename", so it can be a program name with args. 65865 set dummy $tool_basename; ac_word=$2 65866 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 65867 $as_echo_n "checking for $ac_word... " >&6; } 65868 if ${ac_cv_path_ICECC_CREATE_ENV+:} false; then : 65869 $as_echo_n "(cached) " >&6 65870 else 65871 case $ICECC_CREATE_ENV in 65872 [\\/]* | ?:[\\/]*) 65873 ac_cv_path_ICECC_CREATE_ENV="$ICECC_CREATE_ENV" # Let the user override the test with a path. 65874 ;; 65875 *) 65876 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 65877 for as_dir in $PATH 65878 do 65879 IFS=$as_save_IFS 65880 test -z "$as_dir" && as_dir=. 65881 for ac_exec_ext in '' $ac_executable_extensions; do 65882 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 65883 ac_cv_path_ICECC_CREATE_ENV="$as_dir/$ac_word$ac_exec_ext" 65884 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 65885 break 2 65886 fi 65887 done 65888 done 65889 IFS=$as_save_IFS 65890 65891 ;; 65892 esac 65893 fi 65894 ICECC_CREATE_ENV=$ac_cv_path_ICECC_CREATE_ENV 65895 if test -n "$ICECC_CREATE_ENV"; then 65896 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CREATE_ENV" >&5 65897 $as_echo "$ICECC_CREATE_ENV" >&6; } 65898 else 65899 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65900 $as_echo "no" >&6; } 65901 fi 65902 65903 65904 if test "x$ICECC_CREATE_ENV" = x; then 65905 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 65906 fi 65907 else 65908 # Otherwise we believe it is a complete path. Use it as it is. 65909 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ICECC_CREATE_ENV=$tool_specified" >&5 65910 $as_echo "$as_me: Will use user supplied tool ICECC_CREATE_ENV=$tool_specified" >&6;} 65911 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_CREATE_ENV" >&5 65912 $as_echo_n "checking for ICECC_CREATE_ENV... " >&6; } 65913 if test ! -x "$tool_specified"; then 65914 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 65915 $as_echo "not found" >&6; } 65916 as_fn_error $? "User supplied tool ICECC_CREATE_ENV=$tool_specified does not exist or is not executable" "$LINENO" 5 65917 fi 65918 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 65919 $as_echo "$tool_specified" >&6; } 65920 fi 65921 fi 65922 fi 65923 65924 fi 65925 65926 65927 65928 if test "x$ICECC_CREATE_ENV" = x; then 65929 as_fn_error $? "Could not find required tool for ICECC_CREATE_ENV" "$LINENO" 5 65930 fi 65931 65932 65933 # Use icecc-create-env to create a minimal compilation environment that can 65934 # be sent to the other hosts in the icecream cluster. 65935 icecc_create_env_log="${CONFIGURESUPPORT_OUTPUTDIR}/icecc/icecc_create_env.log" 65936 ${MKDIR} -p ${CONFIGURESUPPORT_OUTPUTDIR}/icecc 65937 # Older versions of icecc does not have the --gcc parameter 65938 if ${ICECC_CREATE_ENV} | $GREP -q -e --gcc; then 65939 icecc_gcc_arg="--gcc" 65940 fi 65941 if test "x${TOOLCHAIN_TYPE}" = "xgcc"; then 65942 65943 ( cd ${CONFIGURESUPPORT_OUTPUTDIR}/icecc \ 65944 && ${ICECC_CREATE_ENV} ${icecc_gcc_arg} ${CC} ${CXX} > \ 65945 ${icecc_create_env_log} 2>&1 ) 65946 if test "$?" != "0"; then 65947 { $as_echo "$as_me:${as_lineno-$LINENO}: icecc-create-env output:" >&5 65948 $as_echo "$as_me: icecc-create-env output:" >&6;} 65949 cat \ 65950 ${icecc_create_env_log} 65951 as_fn_error $? "Failed to create icecc compiler environment" "$LINENO" 5 65952 fi 65953 65954 elif test "x$TOOLCHAIN_TYPE" = "xclang"; then 65955 # For clang, the icecc compilerwrapper is needed. It usually resides next 65956 # to icecc-create-env. 65957 65958 65959 65960 # Publish this variable in the help. 65961 65962 65963 if [ -z "${ICECC_WRAPPER+x}" ]; then 65964 # The variable is not set by user, try to locate tool using the code snippet 65965 for ac_prog in compilerwrapper 65966 do 65967 # Extract the first word of "$ac_prog", so it can be a program name with args. 65968 set dummy $ac_prog; ac_word=$2 65969 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 65970 $as_echo_n "checking for $ac_word... " >&6; } 65971 if ${ac_cv_path_ICECC_WRAPPER+:} false; then : 65972 $as_echo_n "(cached) " >&6 65973 else 65974 case $ICECC_WRAPPER in 65975 [\\/]* | ?:[\\/]*) 65976 ac_cv_path_ICECC_WRAPPER="$ICECC_WRAPPER" # Let the user override the test with a path. 65977 ;; 65978 *) 65979 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 65980 for as_dir in $PATH 65981 do 65982 IFS=$as_save_IFS 65983 test -z "$as_dir" && as_dir=. 65984 for ac_exec_ext in '' $ac_executable_extensions; do 65985 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 65986 ac_cv_path_ICECC_WRAPPER="$as_dir/$ac_word$ac_exec_ext" 65987 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 65988 break 2 65989 fi 65990 done 65991 done 65992 IFS=$as_save_IFS 65993 65994 ;; 65995 esac 65996 fi 65997 ICECC_WRAPPER=$ac_cv_path_ICECC_WRAPPER 65998 if test -n "$ICECC_WRAPPER"; then 65999 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_WRAPPER" >&5 66000 $as_echo "$ICECC_WRAPPER" >&6; } 66001 else 66002 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 66003 $as_echo "no" >&6; } 66004 fi 66005 66006 66007 test -n "$ICECC_WRAPPER" && break 66008 done 66009 66010 else 66011 # The variable is set, but is it from the command line or the environment? 66012 66013 # Try to remove the string !ICECC_WRAPPER! from our list. 66014 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ICECC_WRAPPER!/} 66015 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 66016 # If it failed, the variable was not from the command line. Ignore it, 66017 # but warn the user (except for BASH, which is always set by the calling BASH). 66018 if test "xICECC_WRAPPER" != xBASH; then 66019 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ICECC_WRAPPER from the environment. Use command line variables instead." >&5 66020 $as_echo "$as_me: WARNING: Ignoring value of ICECC_WRAPPER from the environment. Use command line variables instead." >&2;} 66021 fi 66022 # Try to locate tool using the code snippet 66023 for ac_prog in compilerwrapper 66024 do 66025 # Extract the first word of "$ac_prog", so it can be a program name with args. 66026 set dummy $ac_prog; ac_word=$2 66027 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 66028 $as_echo_n "checking for $ac_word... " >&6; } 66029 if ${ac_cv_path_ICECC_WRAPPER+:} false; then : 66030 $as_echo_n "(cached) " >&6 66031 else 66032 case $ICECC_WRAPPER in 66033 [\\/]* | ?:[\\/]*) 66034 ac_cv_path_ICECC_WRAPPER="$ICECC_WRAPPER" # Let the user override the test with a path. 66035 ;; 66036 *) 66037 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 66038 for as_dir in $PATH 66039 do 66040 IFS=$as_save_IFS 66041 test -z "$as_dir" && as_dir=. 66042 for ac_exec_ext in '' $ac_executable_extensions; do 66043 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 66044 ac_cv_path_ICECC_WRAPPER="$as_dir/$ac_word$ac_exec_ext" 66045 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 66046 break 2 66047 fi 66048 done 66049 done 66050 IFS=$as_save_IFS 66051 66052 ;; 66053 esac 66054 fi 66055 ICECC_WRAPPER=$ac_cv_path_ICECC_WRAPPER 66056 if test -n "$ICECC_WRAPPER"; then 66057 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_WRAPPER" >&5 66058 $as_echo "$ICECC_WRAPPER" >&6; } 66059 else 66060 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 66061 $as_echo "no" >&6; } 66062 fi 66063 66064 66065 test -n "$ICECC_WRAPPER" && break 66066 done 66067 66068 else 66069 # If it succeeded, then it was overridden by the user. We will use it 66070 # for the tool. 66071 66072 # First remove it from the list of overridden variables, so we can test 66073 # for unknown variables in the end. 66074 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 66075 66076 # Check if we try to supply an empty value 66077 if test "x$ICECC_WRAPPER" = x; then 66078 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ICECC_WRAPPER= (no value)" >&5 66079 $as_echo "$as_me: Setting user supplied tool ICECC_WRAPPER= (no value)" >&6;} 66080 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_WRAPPER" >&5 66081 $as_echo_n "checking for ICECC_WRAPPER... " >&6; } 66082 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 66083 $as_echo "disabled" >&6; } 66084 else 66085 # Check if the provided tool contains a complete path. 66086 tool_specified="$ICECC_WRAPPER" 66087 tool_basename="${tool_specified##*/}" 66088 if test "x$tool_basename" = "x$tool_specified"; then 66089 # A command without a complete path is provided, search $PATH. 66090 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ICECC_WRAPPER=$tool_basename" >&5 66091 $as_echo "$as_me: Will search for user supplied tool ICECC_WRAPPER=$tool_basename" >&6;} 66092 # Extract the first word of "$tool_basename", so it can be a program name with args. 66093 set dummy $tool_basename; ac_word=$2 66094 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 66095 $as_echo_n "checking for $ac_word... " >&6; } 66096 if ${ac_cv_path_ICECC_WRAPPER+:} false; then : 66097 $as_echo_n "(cached) " >&6 66098 else 66099 case $ICECC_WRAPPER in 66100 [\\/]* | ?:[\\/]*) 66101 ac_cv_path_ICECC_WRAPPER="$ICECC_WRAPPER" # Let the user override the test with a path. 66102 ;; 66103 *) 66104 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 66105 for as_dir in $PATH 66106 do 66107 IFS=$as_save_IFS 66108 test -z "$as_dir" && as_dir=. 66109 for ac_exec_ext in '' $ac_executable_extensions; do 66110 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 66111 ac_cv_path_ICECC_WRAPPER="$as_dir/$ac_word$ac_exec_ext" 66112 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 66113 break 2 66114 fi 66115 done 66116 done 66117 IFS=$as_save_IFS 66118 66119 ;; 66120 esac 66121 fi 66122 ICECC_WRAPPER=$ac_cv_path_ICECC_WRAPPER 66123 if test -n "$ICECC_WRAPPER"; then 66124 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_WRAPPER" >&5 66125 $as_echo "$ICECC_WRAPPER" >&6; } 66126 else 66127 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 66128 $as_echo "no" >&6; } 66129 fi 66130 66131 66132 if test "x$ICECC_WRAPPER" = x; then 66133 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 66134 fi 66135 else 66136 # Otherwise we believe it is a complete path. Use it as it is. 66137 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ICECC_WRAPPER=$tool_specified" >&5 66138 $as_echo "$as_me: Will use user supplied tool ICECC_WRAPPER=$tool_specified" >&6;} 66139 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_WRAPPER" >&5 66140 $as_echo_n "checking for ICECC_WRAPPER... " >&6; } 66141 if test ! -x "$tool_specified"; then 66142 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 66143 $as_echo "not found" >&6; } 66144 as_fn_error $? "User supplied tool ICECC_WRAPPER=$tool_specified does not exist or is not executable" "$LINENO" 5 66145 fi 66146 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 66147 $as_echo "$tool_specified" >&6; } 66148 fi 66149 fi 66150 fi 66151 66152 fi 66153 66154 66155 66156 if test "x$ICECC_WRAPPER" = x; then 66157 as_fn_error $? "Could not find required tool for ICECC_WRAPPER" "$LINENO" 5 66158 fi 66159 66160 66161 66162 ( cd ${CONFIGURESUPPORT_OUTPUTDIR}/icecc \ 66163 && ${ICECC_CREATE_ENV} --clang ${CC} ${ICECC_WRAPPER} > ${icecc_create_env_log} 2>&1 ) 66164 if test "$?" != "0"; then 66165 { $as_echo "$as_me:${as_lineno-$LINENO}: icecc-create-env output:" >&5 66166 $as_echo "$as_me: icecc-create-env output:" >&6;} 66167 cat ${icecc_create_env_log} 66168 as_fn_error $? "Failed to create icecc compiler environment" "$LINENO" 5 66169 fi 66170 66171 else 66172 as_fn_error $? "Can only create icecc compiler packages for toolchain types gcc and clang" "$LINENO" 5 66173 fi 66174 PATH="$old_path" 66175 # The bundle with the compiler gets a name based on checksums. Parse log file 66176 # to find it. 66177 ICECC_ENV_BUNDLE_BASENAME="`${SED} -n '/^creating/s/creating //p' ${icecc_create_env_log}`" 66178 ICECC_ENV_BUNDLE="${CONFIGURESUPPORT_OUTPUTDIR}/icecc/${ICECC_ENV_BUNDLE_BASENAME}" 66179 if test ! -f ${ICECC_ENV_BUNDLE}; then 66180 as_fn_error $? "icecc-create-env did not produce an environment ${ICECC_ENV_BUNDLE}" "$LINENO" 5 66181 fi 66182 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for icecc build environment for target compiler" >&5 66183 $as_echo_n "checking for icecc build environment for target compiler... " >&6; } 66184 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${ICECC_ENV_BUNDLE}" >&5 66185 $as_echo "${ICECC_ENV_BUNDLE}" >&6; } 66186 ICECC="ICECC_VERSION=${ICECC_ENV_BUNDLE} ICECC_CC=${CC} ICECC_CXX=${CXX} ${ICECC_CMD}" 66187 66188 if test "x${COMPILE_TYPE}" = "xcross"; then 66189 # If cross compiling, create a separate env package for the build compiler 66190 # Assume "gcc" or "cc" is gcc and "clang" is clang. Otherwise bail. 66191 icecc_create_env_log_build="${CONFIGURESUPPORT_OUTPUTDIR}/icecc/icecc_create_env_build.log" 66192 if test "x${BUILD_CC##*/}" = "xgcc" || test "x${BUILD_CC##*/}" = "xcc"; then 66193 66194 ( cd ${CONFIGURESUPPORT_OUTPUTDIR}/icecc \ 66195 && ${ICECC_CREATE_ENV} ${icecc_gcc_arg} ${BUILD_CC} ${BUILD_CXX} > \ 66196 ${icecc_create_env_log_build} 2>&1 ) 66197 if test "$?" != "0"; then 66198 { $as_echo "$as_me:${as_lineno-$LINENO}: icecc-create-env output:" >&5 66199 $as_echo "$as_me: icecc-create-env output:" >&6;} 66200 cat \ 66201 ${icecc_create_env_log_build} 66202 as_fn_error $? "Failed to create icecc compiler environment" "$LINENO" 5 66203 fi 66204 66205 elif test "x${BUILD_CC##*/}" = "xclang"; then 66206 66207 ( cd ${CONFIGURESUPPORT_OUTPUTDIR}/icecc \ 66208 && ${ICECC_CREATE_ENV} --clang ${BUILD_CC} ${ICECC_WRAPPER} > ${icecc_create_env_log_build} 2>&1 ) 66209 if test "$?" != "0"; then 66210 { $as_echo "$as_me:${as_lineno-$LINENO}: icecc-create-env output:" >&5 66211 $as_echo "$as_me: icecc-create-env output:" >&6;} 66212 cat ${icecc_create_env_log_build} 66213 as_fn_error $? "Failed to create icecc compiler environment" "$LINENO" 5 66214 fi 66215 66216 else 66217 as_fn_error $? "Cannot create icecc compiler package for ${BUILD_CC}" "$LINENO" 5 66218 fi 66219 ICECC_ENV_BUNDLE_BASENAME="`${SED} -n '/^creating/s/creating //p' ${icecc_create_env_log_build}`" 66220 ICECC_ENV_BUNDLE="${CONFIGURESUPPORT_OUTPUTDIR}/icecc/${ICECC_ENV_BUNDLE_BASENAME}" 66221 if test ! -f ${ICECC_ENV_BUNDLE}; then 66222 as_fn_error $? "icecc-create-env did not produce an environment ${ICECC_ENV_BUNDLE}" "$LINENO" 5 66223 fi 66224 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for icecc build environment for build compiler" >&5 66225 $as_echo_n "checking for icecc build environment for build compiler... " >&6; } 66226 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${ICECC_ENV_BUNDLE}" >&5 66227 $as_echo "${ICECC_ENV_BUNDLE}" >&6; } 66228 BUILD_ICECC="ICECC_VERSION=${ICECC_ENV_BUNDLE} ICECC_CC=${BUILD_CC} \ 66229 ICECC_CXX=${BUILD_CXX} ${ICECC_CMD}" 66230 else 66231 BUILD_ICECC="${ICECC}" 66232 fi 66233 66234 66235 fi 66236 66237 66238 # Can the C/C++ compiler use precompiled headers? 66239 66240 66241 ############################################################################### 66242 # 66243 # Can the C/C++ compiler use precompiled headers? 66244 # 66245 # Check whether --enable-precompiled-headers was given. 66246 if test "${enable_precompiled_headers+set}" = set; then : 66247 enableval=$enable_precompiled_headers; ENABLE_PRECOMPH=${enable_precompiled_headers} 66248 else 66249 ENABLE_PRECOMPH=yes 66250 fi 66251 66252 66253 USE_PRECOMPILED_HEADER=true 66254 { $as_echo "$as_me:${as_lineno-$LINENO}: checking If precompiled header is enabled" >&5 66255 $as_echo_n "checking If precompiled header is enabled... " >&6; } 66256 if test "x$ENABLE_PRECOMPH" = xno; then 66257 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 66258 $as_echo "no, forced" >&6; } 66259 USE_PRECOMPILED_HEADER=false 66260 elif test "x$ICECC" != "x"; then 66261 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, does not work effectively with icecc" >&5 66262 $as_echo "no, does not work effectively with icecc" >&6; } 66263 USE_PRECOMPILED_HEADER=false 66264 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 66265 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, does not work with Solaris Studio" >&5 66266 $as_echo "no, does not work with Solaris Studio" >&6; } 66267 USE_PRECOMPILED_HEADER=false 66268 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 66269 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, does not work with xlc" >&5 66270 $as_echo "no, does not work with xlc" >&6; } 66271 USE_PRECOMPILED_HEADER=false 66272 else 66273 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 66274 $as_echo "yes" >&6; } 66275 fi 66276 66277 if test "x$ENABLE_PRECOMPH" = xyes; then 66278 # Check that the compiler actually supports precomp headers. 66279 if test "x$TOOLCHAIN_TYPE" = xgcc; then 66280 { $as_echo "$as_me:${as_lineno-$LINENO}: checking that precompiled headers work" >&5 66281 $as_echo_n "checking that precompiled headers work... " >&6; } 66282 echo "int alfa();" > conftest.h 66283 $CXX -x c++-header conftest.h -o conftest.hpp.gch 2>&5 >&5 66284 if test ! -f conftest.hpp.gch; then 66285 USE_PRECOMPILED_HEADER=false 66286 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 66287 $as_echo "no" >&6; } 66288 else 66289 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 66290 $as_echo "yes" >&6; } 66291 fi 66292 $RM conftest.h conftest.hpp.gch 66293 fi 66294 fi 66295 66296 66297 66298 66299 # Setup use of ccache, if available 66300 66301 # Check whether --enable-ccache was given. 66302 if test "${enable_ccache+set}" = set; then : 66303 enableval=$enable_ccache; 66304 fi 66305 66306 66307 CCACHE_STATUS= 66308 { $as_echo "$as_me:${as_lineno-$LINENO}: checking is ccache enabled" >&5 66309 $as_echo_n "checking is ccache enabled... " >&6; } 66310 if test "x$enable_ccache" = xyes; then 66311 if test "x$TOOLCHAIN_TYPE" = "xgcc" -o "x$TOOLCHAIN_TYPE" = "xclang"; then 66312 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 66313 $as_echo "yes" >&6; } 66314 OLD_PATH="$PATH" 66315 if test "x$TOOLCHAIN_PATH" != x; then 66316 PATH=$TOOLCHAIN_PATH:$PATH 66317 fi 66318 66319 66320 66321 # Publish this variable in the help. 66322 66323 66324 if [ -z "${CCACHE+x}" ]; then 66325 # The variable is not set by user, try to locate tool using the code snippet 66326 for ac_prog in ccache 66327 do 66328 # Extract the first word of "$ac_prog", so it can be a program name with args. 66329 set dummy $ac_prog; ac_word=$2 66330 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 66331 $as_echo_n "checking for $ac_word... " >&6; } 66332 if ${ac_cv_path_CCACHE+:} false; then : 66333 $as_echo_n "(cached) " >&6 66334 else 66335 case $CCACHE in 66336 [\\/]* | ?:[\\/]*) 66337 ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path. 66338 ;; 66339 *) 66340 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 66341 for as_dir in $PATH 66342 do 66343 IFS=$as_save_IFS 66344 test -z "$as_dir" && as_dir=. 66345 for ac_exec_ext in '' $ac_executable_extensions; do 66346 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 66347 ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext" 66348 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 66349 break 2 66350 fi 66351 done 66352 done 66353 IFS=$as_save_IFS 66354 66355 ;; 66356 esac 66357 fi 66358 CCACHE=$ac_cv_path_CCACHE 66359 if test -n "$CCACHE"; then 66360 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5 66361 $as_echo "$CCACHE" >&6; } 66362 else 66363 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 66364 $as_echo "no" >&6; } 66365 fi 66366 66367 66368 test -n "$CCACHE" && break 66369 done 66370 66371 else 66372 # The variable is set, but is it from the command line or the environment? 66373 66374 # Try to remove the string !CCACHE! from our list. 66375 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CCACHE!/} 66376 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 66377 # If it failed, the variable was not from the command line. Ignore it, 66378 # but warn the user (except for BASH, which is always set by the calling BASH). 66379 if test "xCCACHE" != xBASH; then 66380 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CCACHE from the environment. Use command line variables instead." >&5 66381 $as_echo "$as_me: WARNING: Ignoring value of CCACHE from the environment. Use command line variables instead." >&2;} 66382 fi 66383 # Try to locate tool using the code snippet 66384 for ac_prog in ccache 66385 do 66386 # Extract the first word of "$ac_prog", so it can be a program name with args. 66387 set dummy $ac_prog; ac_word=$2 66388 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 66389 $as_echo_n "checking for $ac_word... " >&6; } 66390 if ${ac_cv_path_CCACHE+:} false; then : 66391 $as_echo_n "(cached) " >&6 66392 else 66393 case $CCACHE in 66394 [\\/]* | ?:[\\/]*) 66395 ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path. 66396 ;; 66397 *) 66398 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 66399 for as_dir in $PATH 66400 do 66401 IFS=$as_save_IFS 66402 test -z "$as_dir" && as_dir=. 66403 for ac_exec_ext in '' $ac_executable_extensions; do 66404 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 66405 ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext" 66406 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 66407 break 2 66408 fi 66409 done 66410 done 66411 IFS=$as_save_IFS 66412 66413 ;; 66414 esac 66415 fi 66416 CCACHE=$ac_cv_path_CCACHE 66417 if test -n "$CCACHE"; then 66418 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5 66419 $as_echo "$CCACHE" >&6; } 66420 else 66421 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 66422 $as_echo "no" >&6; } 66423 fi 66424 66425 66426 test -n "$CCACHE" && break 66427 done 66428 66429 else 66430 # If it succeeded, then it was overridden by the user. We will use it 66431 # for the tool. 66432 66433 # First remove it from the list of overridden variables, so we can test 66434 # for unknown variables in the end. 66435 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 66436 66437 # Check if we try to supply an empty value 66438 if test "x$CCACHE" = x; then 66439 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CCACHE= (no value)" >&5 66440 $as_echo "$as_me: Setting user supplied tool CCACHE= (no value)" >&6;} 66441 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CCACHE" >&5 66442 $as_echo_n "checking for CCACHE... " >&6; } 66443 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 66444 $as_echo "disabled" >&6; } 66445 else 66446 # Check if the provided tool contains a complete path. 66447 tool_specified="$CCACHE" 66448 tool_basename="${tool_specified##*/}" 66449 if test "x$tool_basename" = "x$tool_specified"; then 66450 # A command without a complete path is provided, search $PATH. 66451 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CCACHE=$tool_basename" >&5 66452 $as_echo "$as_me: Will search for user supplied tool CCACHE=$tool_basename" >&6;} 66453 # Extract the first word of "$tool_basename", so it can be a program name with args. 66454 set dummy $tool_basename; ac_word=$2 66455 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 66456 $as_echo_n "checking for $ac_word... " >&6; } 66457 if ${ac_cv_path_CCACHE+:} false; then : 66458 $as_echo_n "(cached) " >&6 66459 else 66460 case $CCACHE in 66461 [\\/]* | ?:[\\/]*) 66462 ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path. 66463 ;; 66464 *) 66465 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 66466 for as_dir in $PATH 66467 do 66468 IFS=$as_save_IFS 66469 test -z "$as_dir" && as_dir=. 66470 for ac_exec_ext in '' $ac_executable_extensions; do 66471 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 66472 ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext" 66473 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 66474 break 2 66475 fi 66476 done 66477 done 66478 IFS=$as_save_IFS 66479 66480 ;; 66481 esac 66482 fi 66483 CCACHE=$ac_cv_path_CCACHE 66484 if test -n "$CCACHE"; then 66485 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5 66486 $as_echo "$CCACHE" >&6; } 66487 else 66488 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 66489 $as_echo "no" >&6; } 66490 fi 66491 66492 66493 if test "x$CCACHE" = x; then 66494 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 66495 fi 66496 else 66497 # Otherwise we believe it is a complete path. Use it as it is. 66498 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CCACHE=$tool_specified" >&5 66499 $as_echo "$as_me: Will use user supplied tool CCACHE=$tool_specified" >&6;} 66500 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CCACHE" >&5 66501 $as_echo_n "checking for CCACHE... " >&6; } 66502 if test ! -x "$tool_specified"; then 66503 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 66504 $as_echo "not found" >&6; } 66505 as_fn_error $? "User supplied tool CCACHE=$tool_specified does not exist or is not executable" "$LINENO" 5 66506 fi 66507 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 66508 $as_echo "$tool_specified" >&6; } 66509 fi 66510 fi 66511 fi 66512 66513 fi 66514 66515 66516 66517 if test "x$CCACHE" = x; then 66518 as_fn_error $? "Could not find required tool for CCACHE" "$LINENO" 5 66519 fi 66520 66521 66522 PATH="$OLD_PATH" 66523 CCACHE_VERSION=`$CCACHE --version | head -n1 | $SED 's/[A-Za-z ]*//'` 66524 CCACHE_STATUS="Active ($CCACHE_VERSION)" 66525 else 66526 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 66527 $as_echo "no" >&6; } 66528 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: ccache is not supported with toolchain type $TOOLCHAIN_TYPE" >&5 66529 $as_echo "$as_me: WARNING: ccache is not supported with toolchain type $TOOLCHAIN_TYPE" >&2;} 66530 fi 66531 elif test "x$enable_ccache" = xno; then 66532 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, explicitly disabled" >&5 66533 $as_echo "no, explicitly disabled" >&6; } 66534 CCACHE_STATUS="Disabled" 66535 elif test "x$enable_ccache" = x; then 66536 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 66537 $as_echo "no" >&6; } 66538 else 66539 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unknown" >&5 66540 $as_echo "unknown" >&6; } 66541 as_fn_error $? "--enable-ccache does not accept any parameters" "$LINENO" 5 66542 fi 66543 66544 66545 66546 # Check whether --with-ccache-dir was given. 66547 if test "${with_ccache_dir+set}" = set; then : 66548 withval=$with_ccache_dir; 66549 fi 66550 66551 66552 if test "x$with_ccache_dir" != x; then 66553 # When using a non home ccache directory, assume the use is to share ccache files 66554 # with other users. Thus change the umask. 66555 SET_CCACHE_DIR="CCACHE_DIR=$with_ccache_dir CCACHE_UMASK=002" 66556 if test "x$CCACHE" = x; then 66557 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-ccache-dir has no meaning when ccache is not enabled" >&5 66558 $as_echo "$as_me: WARNING: --with-ccache-dir has no meaning when ccache is not enabled" >&2;} 66559 fi 66560 fi 66561 66562 if test "x$CCACHE" != x; then 66563 66564 if test "x$CCACHE" != x; then 66565 if test "x$OPENJDK_BUILD_OS" = "xmacosx"; then 66566 HAS_BAD_CCACHE=`$ECHO $CCACHE_VERSION | \ 66567 $GREP -e '^1\.' -e '^2\.' -e '^3\.0\.' -e '^3\.1\.'` 66568 if test "x$HAS_BAD_CCACHE" != "x"; then 66569 as_fn_error $? "On macosx, ccache 3.2 or later is required, found $CCACHE_VERSION" "$LINENO" 5 66570 fi 66571 fi 66572 if test "x$USE_PRECOMPILED_HEADER" = "xtrue"; then 66573 HAS_BAD_CCACHE=`$ECHO $CCACHE_VERSION | \ 66574 $GREP -e '^1.*' -e '^2.*' -e '^3\.0.*' -e '^3\.1\.[0123]$'` 66575 if test "x$HAS_BAD_CCACHE" != "x"; then 66576 as_fn_error $? "Precompiled headers requires ccache 3.1.4 or later, found $CCACHE_VERSION" "$LINENO" 5 66577 fi 66578 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if C-compiler supports ccache precompiled headers" >&5 66579 $as_echo_n "checking if C-compiler supports ccache precompiled headers... " >&6; } 66580 CCACHE_PRECOMP_FLAG="-fpch-preprocess" 66581 PUSHED_FLAGS="$CXXFLAGS" 66582 CXXFLAGS="$CCACHE_PRECOMP_FLAG $CXXFLAGS" 66583 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 66584 /* end confdefs.h. */ 66585 66586 int 66587 main () 66588 { 66589 66590 ; 66591 return 0; 66592 } 66593 _ACEOF 66594 if ac_fn_cxx_try_compile "$LINENO"; then : 66595 CC_KNOWS_CCACHE_TRICK=yes 66596 else 66597 CC_KNOWS_CCACHE_TRICK=no 66598 fi 66599 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 66600 CXXFLAGS="$PUSHED_FLAGS" 66601 if test "x$CC_KNOWS_CCACHE_TRICK" = xyes; then 66602 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 66603 $as_echo "yes" >&6; } 66604 CFLAGS_CCACHE="$CCACHE_PRECOMP_FLAG" 66605 66606 CCACHE_SLOPPINESS=pch_defines,time_macros 66607 else 66608 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 66609 $as_echo "no" >&6; } 66610 as_fn_error $? "Cannot use ccache with precompiled headers without compiler support for $CCACHE_PRECOMP_FLAG" "$LINENO" 5 66611 fi 66612 fi 66613 66614 CCACHE="CCACHE_COMPRESS=1 $SET_CCACHE_DIR \ 66615 CCACHE_SLOPPINESS=$CCACHE_SLOPPINESS CCACHE_BASEDIR=$TOPDIR $CCACHE" 66616 66617 if test "x$SET_CCACHE_DIR" != x; then 66618 mkdir -p $CCACHE_DIR > /dev/null 2>&1 66619 chmod a+rwxs $CCACHE_DIR > /dev/null 2>&1 66620 fi 66621 fi 66622 66623 fi 66624 66625 66626 ############################################################################### 66627 # 66628 # And now the finish... 66629 # 66630 ############################################################################### 66631 66632 # Check for some common pitfalls 66633 66634 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 66635 file_to_test="$SRC_ROOT/LICENSE" 66636 if test `$STAT -c '%a' "$file_to_test"` -lt 400; then 66637 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 66638 fi 66639 fi 66640 66641 66642 # Did user specify any unknown variables? 66643 66644 if test "x$CONFIGURE_OVERRIDDEN_VARIABLES" != x; then 66645 # Replace the separating ! with spaces before presenting for end user. 66646 unknown_variables=${CONFIGURE_OVERRIDDEN_VARIABLES//!/ } 66647 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: The following variables might be unknown to configure: $unknown_variables" >&5 66648 $as_echo "$as_me: WARNING: The following variables might be unknown to configure: $unknown_variables" >&2;} 66649 fi 66650 66651 66652 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if build directory is on local disk" >&5 66653 $as_echo_n "checking if build directory is on local disk... " >&6; } 66654 66655 # df -l lists only local disks; if the given directory is not found then 66656 # a non-zero exit code is given 66657 if test "x$DF" = x; then 66658 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 66659 # msys does not have df; use Windows "net use" instead. 66660 IS_NETWORK_DISK=`net use | grep \`pwd -W | cut -d ":" -f 1 | tr a-z A-Z\`:` 66661 if test "x$IS_NETWORK_DISK" = x; then 66662 OUTPUT_DIR_IS_LOCAL="yes" 66663 else 66664 OUTPUT_DIR_IS_LOCAL="no" 66665 fi 66666 else 66667 # No df here, say it's local 66668 OUTPUT_DIR_IS_LOCAL="yes" 66669 fi 66670 else 66671 if $DF -l $OUTPUT_ROOT > /dev/null 2>&1; then 66672 OUTPUT_DIR_IS_LOCAL="yes" 66673 else 66674 OUTPUT_DIR_IS_LOCAL="no" 66675 fi 66676 fi 66677 66678 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OUTPUT_DIR_IS_LOCAL" >&5 66679 $as_echo "$OUTPUT_DIR_IS_LOCAL" >&6; } 66680 66681 66682 66683 # Check if the user has any old-style ALT_ variables set. 66684 FOUND_ALT_VARIABLES=`env | grep ^ALT_` 66685 66686 # Before generating output files, test if they exist. If they do, this is a reconfigure. 66687 # Since we can't properly handle the dependencies for this, warn the user about the situation 66688 if test -e $OUTPUT_ROOT/spec.gmk; then 66689 IS_RECONFIGURE=yes 66690 else 66691 IS_RECONFIGURE=no 66692 fi 66693 66694 66695 # At the end, call the custom hook. (Dummy macro if no custom sources available) 66696 66697 66698 # This needs to be done after CUSTOM_LATE_HOOK since we can setup custom features. 66699 66700 # Keep feature lists sorted and free of duplicates 66701 JVM_FEATURES_server="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_server | $SORT -u))" 66702 JVM_FEATURES_client="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_client | $SORT -u))" 66703 JVM_FEATURES_core="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_core | $SORT -u))" 66704 JVM_FEATURES_minimal="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_minimal | $SORT -u))" 66705 JVM_FEATURES_zero="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_zero | $SORT -u))" 66706 JVM_FEATURES_zeroshark="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_zeroshark | $SORT -u))" 66707 JVM_FEATURES_custom="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_custom | $SORT -u))" 66708 66709 # Validate features 66710 for variant in $JVM_VARIANTS; do 66711 { $as_echo "$as_me:${as_lineno-$LINENO}: checking JVM features for JVM variant '$variant'" >&5 66712 $as_echo_n "checking JVM features for JVM variant '$variant'... " >&6; } 66713 features_var_name=JVM_FEATURES_$variant 66714 JVM_FEATURES_TO_TEST=${!features_var_name} 66715 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JVM_FEATURES_TO_TEST" >&5 66716 $as_echo "$JVM_FEATURES_TO_TEST" >&6; } 66717 NEEDLE=${VALID_JVM_FEATURES// /$'\n'} 66718 STACK=${JVM_FEATURES_TO_TEST// /$'\n'} 66719 INVALID_FEATURES=`$GREP -Fvx "${NEEDLE}" <<< "${STACK}"` 66720 if test "x$INVALID_FEATURES" != x; then 66721 as_fn_error $? "Invalid JVM feature(s): $INVALID_FEATURES" "$LINENO" 5 66722 fi 66723 done 66724 66725 66726 # We're messing a bit with internal autoconf variables to put the config.status 66727 # in the output directory instead of the current directory. 66728 CONFIG_STATUS="$CONFIGURESUPPORT_OUTPUTDIR/config.status" 66729 66730 # Create the actual output files. Now the main work of configure is done. 66731 cat >confcache <<\_ACEOF 66732 # This file is a shell script that caches the results of configure 66733 # tests run on this system so they can be shared between configure 66734 # scripts and configure runs, see configure's option --config-cache. 66735 # It is not useful on other systems. If it contains results you don't 66736 # want to keep, you may remove or edit it. 66737 # 66738 # config.status only pays attention to the cache file if you give it 66739 # the --recheck option to rerun configure. 66740 # 66741 # `ac_cv_env_foo' variables (set or unset) will be overridden when 66742 # loading this file, other *unset* `ac_cv_foo' will be assigned the 66743 # following values. 66744 66745 _ACEOF 66746 66747 # The following way of writing the cache mishandles newlines in values, 66748 # but we know of no workaround that is simple, portable, and efficient. 66749 # So, we kill variables containing newlines. 66750 # Ultrix sh set writes to stderr and can't be redirected directly, 66751 # and sets the high bit in the cache file unless we assign to the vars. 66752 ( 66753 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do 66754 eval ac_val=\$$ac_var 66755 case $ac_val in #( 66756 *${as_nl}*) 66757 case $ac_var in #( 66758 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 66759 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; 66760 esac 66761 case $ac_var in #( 66762 _ | IFS | as_nl) ;; #( 66763 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( 66764 *) { eval $ac_var=; unset $ac_var;} ;; 66765 esac ;; 66766 esac 66767 done 66768 66769 (set) 2>&1 | 66770 case $as_nl`(ac_space=' '; set) 2>&1` in #( 66771 *${as_nl}ac_space=\ *) 66772 # `set' does not quote correctly, so add quotes: double-quote 66773 # substitution turns \\\\ into \\, and sed turns \\ into \. 66774 sed -n \ 66775 "s/'/'\\\\''/g; 66776 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" 66777 ;; #( 66778 *) 66779 # `set' quotes correctly as required by POSIX, so do not add quotes. 66780 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" 66781 ;; 66782 esac | 66783 sort 66784 ) | 66785 sed ' 66786 /^ac_cv_env_/b end 66787 t clear 66788 :clear 66789 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ 66790 t end 66791 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ 66792 :end' >>confcache 66793 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else 66794 if test -w "$cache_file"; then 66795 if test "x$cache_file" != "x/dev/null"; then 66796 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 66797 $as_echo "$as_me: updating cache $cache_file" >&6;} 66798 if test ! -f "$cache_file" || test -h "$cache_file"; then 66799 cat confcache >"$cache_file" 66800 else 66801 case $cache_file in #( 66802 */* | ?:*) 66803 mv -f confcache "$cache_file"$$ && 66804 mv -f "$cache_file"$$ "$cache_file" ;; #( 66805 *) 66806 mv -f confcache "$cache_file" ;; 66807 esac 66808 fi 66809 fi 66810 else 66811 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 66812 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} 66813 fi 66814 fi 66815 rm -f confcache 66816 66817 test "x$prefix" = xNONE && prefix=$ac_default_prefix 66818 # Let make expand exec_prefix. 66819 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' 66820 66821 # Transform confdefs.h into DEFS. 66822 # Protect against shell expansion while executing Makefile rules. 66823 # Protect against Makefile macro expansion. 66824 # 66825 # If the first sed substitution is executed (which looks for macros that 66826 # take arguments), then branch to the quote section. Otherwise, 66827 # look for a macro that doesn't take arguments. 66828 ac_script=' 66829 :mline 66830 /\\$/{ 66831 N 66832 s,\\\n,, 66833 b mline 66834 } 66835 t clear 66836 :clear 66837 s/^[ ]*#[ ]*define[ ][ ]*\([^ (][^ (]*([^)]*)\)[ ]*\(.*\)/-D\1=\2/g 66838 t quote 66839 s/^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)/-D\1=\2/g 66840 t quote 66841 b any 66842 :quote 66843 s/[ `~#$^&*(){}\\|;'\''"<>?]/\\&/g 66844 s/\[/\\&/g 66845 s/\]/\\&/g 66846 s/\$/$$/g 66847 H 66848 :any 66849 ${ 66850 g 66851 s/^\n// 66852 s/\n/ /g 66853 p 66854 } 66855 ' 66856 DEFS=`sed -n "$ac_script" confdefs.h` 66857 66858 66859 ac_libobjs= 66860 ac_ltlibobjs= 66861 U= 66862 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue 66863 # 1. Remove the extension, and $U if already installed. 66864 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' 66865 ac_i=`$as_echo "$ac_i" | sed "$ac_script"` 66866 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR 66867 # will be set to the directory where LIBOBJS objects are built. 66868 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" 66869 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' 66870 done 66871 LIBOBJS=$ac_libobjs 66872 66873 LTLIBOBJS=$ac_ltlibobjs 66874 66875 66876 66877 : "${CONFIG_STATUS=./config.status}" 66878 ac_write_fail=0 66879 ac_clean_files_save=$ac_clean_files 66880 ac_clean_files="$ac_clean_files $CONFIG_STATUS" 66881 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 66882 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;} 66883 as_write_fail=0 66884 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 66885 #! $SHELL 66886 # Generated by $as_me. 66887 # Run this file to recreate the current configuration. 66888 # Compiler output produced by configure, useful for debugging 66889 # configure, is in config.log if it exists. 66890 66891 debug=false 66892 ac_cs_recheck=false 66893 ac_cs_silent=false 66894 66895 SHELL=\${CONFIG_SHELL-$SHELL} 66896 export SHELL 66897 _ASEOF 66898 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 66899 ## -------------------- ## 66900 ## M4sh Initialization. ## 66901 ## -------------------- ## 66902 66903 # Be more Bourne compatible 66904 DUALCASE=1; export DUALCASE # for MKS sh 66905 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : 66906 emulate sh 66907 NULLCMD=: 66908 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which 66909 # is contrary to our usage. Disable this feature. 66910 alias -g '${1+"$@"}'='"$@"' 66911 setopt NO_GLOB_SUBST 66912 else 66913 case `(set -o) 2>/dev/null` in #( 66914 *posix*) : 66915 set -o posix ;; #( 66916 *) : 66917 ;; 66918 esac 66919 fi 66920 66921 66922 as_nl=' 66923 ' 66924 export as_nl 66925 # Printing a long string crashes Solaris 7 /usr/bin/printf. 66926 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' 66927 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo 66928 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo 66929 # Prefer a ksh shell builtin over an external printf program on Solaris, 66930 # but without wasting forks for bash or zsh. 66931 if test -z "$BASH_VERSION$ZSH_VERSION" \ 66932 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then 66933 as_echo='print -r --' 66934 as_echo_n='print -rn --' 66935 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then 66936 as_echo='printf %s\n' 66937 as_echo_n='printf %s' 66938 else 66939 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then 66940 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' 66941 as_echo_n='/usr/ucb/echo -n' 66942 else 66943 as_echo_body='eval expr "X$1" : "X\\(.*\\)"' 66944 as_echo_n_body='eval 66945 arg=$1; 66946 case $arg in #( 66947 *"$as_nl"*) 66948 expr "X$arg" : "X\\(.*\\)$as_nl"; 66949 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; 66950 esac; 66951 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" 66952 ' 66953 export as_echo_n_body 66954 as_echo_n='sh -c $as_echo_n_body as_echo' 66955 fi 66956 export as_echo_body 66957 as_echo='sh -c $as_echo_body as_echo' 66958 fi 66959 66960 # The user is always right. 66961 if test "${PATH_SEPARATOR+set}" != set; then 66962 PATH_SEPARATOR=: 66963 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { 66964 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || 66965 PATH_SEPARATOR=';' 66966 } 66967 fi 66968 66969 66970 # IFS 66971 # We need space, tab and new line, in precisely that order. Quoting is 66972 # there to prevent editors from complaining about space-tab. 66973 # (If _AS_PATH_WALK were called with IFS unset, it would disable word 66974 # splitting by setting IFS to empty value.) 66975 IFS=" "" $as_nl" 66976 66977 # Find who we are. Look in the path if we contain no directory separator. 66978 as_myself= 66979 case $0 in #(( 66980 *[\\/]* ) as_myself=$0 ;; 66981 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 66982 for as_dir in $PATH 66983 do 66984 IFS=$as_save_IFS 66985 test -z "$as_dir" && as_dir=. 66986 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break 66987 done 66988 IFS=$as_save_IFS 66989 66990 ;; 66991 esac 66992 # We did not find ourselves, most probably we were run as `sh COMMAND' 66993 # in which case we are not to be found in the path. 66994 if test "x$as_myself" = x; then 66995 as_myself=$0 66996 fi 66997 if test ! -f "$as_myself"; then 66998 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 66999 exit 1 67000 fi 67001 67002 # Unset variables that we do not need and which cause bugs (e.g. in 67003 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" 67004 # suppresses any "Segmentation fault" message there. '((' could 67005 # trigger a bug in pdksh 5.2.14. 67006 for as_var in BASH_ENV ENV MAIL MAILPATH 67007 do eval test x\${$as_var+set} = xset \ 67008 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : 67009 done 67010 PS1='$ ' 67011 PS2='> ' 67012 PS4='+ ' 67013 67014 # NLS nuisances. 67015 LC_ALL=C 67016 export LC_ALL 67017 LANGUAGE=C 67018 export LANGUAGE 67019 67020 # CDPATH. 67021 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH 67022 67023 67024 # as_fn_error STATUS ERROR [LINENO LOG_FD] 67025 # ---------------------------------------- 67026 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are 67027 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the 67028 # script with STATUS, using 1 if that was 0. 67029 as_fn_error () 67030 { 67031 as_status=$1; test $as_status -eq 0 && as_status=1 67032 if test "$4"; then 67033 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 67034 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 67035 fi 67036 $as_echo "$as_me: error: $2" >&2 67037 as_fn_exit $as_status 67038 } # as_fn_error 67039 67040 67041 # as_fn_set_status STATUS 67042 # ----------------------- 67043 # Set $? to STATUS, without forking. 67044 as_fn_set_status () 67045 { 67046 return $1 67047 } # as_fn_set_status 67048 67049 # as_fn_exit STATUS 67050 # ----------------- 67051 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. 67052 as_fn_exit () 67053 { 67054 set +e 67055 as_fn_set_status $1 67056 exit $1 67057 } # as_fn_exit 67058 67059 # as_fn_unset VAR 67060 # --------------- 67061 # Portably unset VAR. 67062 as_fn_unset () 67063 { 67064 { eval $1=; unset $1;} 67065 } 67066 as_unset=as_fn_unset 67067 # as_fn_append VAR VALUE 67068 # ---------------------- 67069 # Append the text in VALUE to the end of the definition contained in VAR. Take 67070 # advantage of any shell optimizations that allow amortized linear growth over 67071 # repeated appends, instead of the typical quadratic growth present in naive 67072 # implementations. 67073 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : 67074 eval 'as_fn_append () 67075 { 67076 eval $1+=\$2 67077 }' 67078 else 67079 as_fn_append () 67080 { 67081 eval $1=\$$1\$2 67082 } 67083 fi # as_fn_append 67084 67085 # as_fn_arith ARG... 67086 # ------------------ 67087 # Perform arithmetic evaluation on the ARGs, and store the result in the 67088 # global $as_val. Take advantage of shells that can avoid forks. The arguments 67089 # must be portable across $(()) and expr. 67090 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : 67091 eval 'as_fn_arith () 67092 { 67093 as_val=$(( $* )) 67094 }' 67095 else 67096 as_fn_arith () 67097 { 67098 as_val=`expr "$@" || test $? -eq 1` 67099 } 67100 fi # as_fn_arith 67101 67102 67103 if expr a : '\(a\)' >/dev/null 2>&1 && 67104 test "X`expr 00001 : '.*\(...\)'`" = X001; then 67105 as_expr=expr 67106 else 67107 as_expr=false 67108 fi 67109 67110 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then 67111 as_basename=basename 67112 else 67113 as_basename=false 67114 fi 67115 67116 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then 67117 as_dirname=dirname 67118 else 67119 as_dirname=false 67120 fi 67121 67122 as_me=`$as_basename -- "$0" || 67123 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ 67124 X"$0" : 'X\(//\)$' \| \ 67125 X"$0" : 'X\(/\)' \| . 2>/dev/null || 67126 $as_echo X/"$0" | 67127 sed '/^.*\/\([^/][^/]*\)\/*$/{ 67128 s//\1/ 67129 q 67130 } 67131 /^X\/\(\/\/\)$/{ 67132 s//\1/ 67133 q 67134 } 67135 /^X\/\(\/\).*/{ 67136 s//\1/ 67137 q 67138 } 67139 s/.*/./; q'` 67140 67141 # Avoid depending upon Character Ranges. 67142 as_cr_letters='abcdefghijklmnopqrstuvwxyz' 67143 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' 67144 as_cr_Letters=$as_cr_letters$as_cr_LETTERS 67145 as_cr_digits='0123456789' 67146 as_cr_alnum=$as_cr_Letters$as_cr_digits 67147 67148 ECHO_C= ECHO_N= ECHO_T= 67149 case `echo -n x` in #((((( 67150 -n*) 67151 case `echo 'xy\c'` in 67152 *c*) ECHO_T=' ';; # ECHO_T is single tab character. 67153 xy) ECHO_C='\c';; 67154 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null 67155 ECHO_T=' ';; 67156 esac;; 67157 *) 67158 ECHO_N='-n';; 67159 esac 67160 67161 rm -f conf$$ conf$$.exe conf$$.file 67162 if test -d conf$$.dir; then 67163 rm -f conf$$.dir/conf$$.file 67164 else 67165 rm -f conf$$.dir 67166 mkdir conf$$.dir 2>/dev/null 67167 fi 67168 if (echo >conf$$.file) 2>/dev/null; then 67169 if ln -s conf$$.file conf$$ 2>/dev/null; then 67170 as_ln_s='ln -s' 67171 # ... but there are two gotchas: 67172 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. 67173 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. 67174 # In both cases, we have to default to `cp -pR'. 67175 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || 67176 as_ln_s='cp -pR' 67177 elif ln conf$$.file conf$$ 2>/dev/null; then 67178 as_ln_s=ln 67179 else 67180 as_ln_s='cp -pR' 67181 fi 67182 else 67183 as_ln_s='cp -pR' 67184 fi 67185 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file 67186 rmdir conf$$.dir 2>/dev/null 67187 67188 67189 # as_fn_mkdir_p 67190 # ------------- 67191 # Create "$as_dir" as a directory, including parents if necessary. 67192 as_fn_mkdir_p () 67193 { 67194 67195 case $as_dir in #( 67196 -*) as_dir=./$as_dir;; 67197 esac 67198 test -d "$as_dir" || eval $as_mkdir_p || { 67199 as_dirs= 67200 while :; do 67201 case $as_dir in #( 67202 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( 67203 *) as_qdir=$as_dir;; 67204 esac 67205 as_dirs="'$as_qdir' $as_dirs" 67206 as_dir=`$as_dirname -- "$as_dir" || 67207 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 67208 X"$as_dir" : 'X\(//\)[^/]' \| \ 67209 X"$as_dir" : 'X\(//\)$' \| \ 67210 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || 67211 $as_echo X"$as_dir" | 67212 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 67213 s//\1/ 67214 q 67215 } 67216 /^X\(\/\/\)[^/].*/{ 67217 s//\1/ 67218 q 67219 } 67220 /^X\(\/\/\)$/{ 67221 s//\1/ 67222 q 67223 } 67224 /^X\(\/\).*/{ 67225 s//\1/ 67226 q 67227 } 67228 s/.*/./; q'` 67229 test -d "$as_dir" && break 67230 done 67231 test -z "$as_dirs" || eval "mkdir $as_dirs" 67232 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" 67233 67234 67235 } # as_fn_mkdir_p 67236 if mkdir -p . 2>/dev/null; then 67237 as_mkdir_p='mkdir -p "$as_dir"' 67238 else 67239 test -d ./-p && rmdir ./-p 67240 as_mkdir_p=false 67241 fi 67242 67243 67244 # as_fn_executable_p FILE 67245 # ----------------------- 67246 # Test if FILE is an executable regular file. 67247 as_fn_executable_p () 67248 { 67249 test -f "$1" && test -x "$1" 67250 } # as_fn_executable_p 67251 as_test_x='test -x' 67252 as_executable_p=as_fn_executable_p 67253 67254 # Sed expression to map a string onto a valid CPP name. 67255 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" 67256 67257 # Sed expression to map a string onto a valid variable name. 67258 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" 67259 67260 67261 exec 6>&1 67262 ## ----------------------------------- ## 67263 ## Main body of $CONFIG_STATUS script. ## 67264 ## ----------------------------------- ## 67265 _ASEOF 67266 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 67267 67268 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 67269 # Save the log message, to keep $0 and so on meaningful, and to 67270 # report actual input values of CONFIG_FILES etc. instead of their 67271 # values after options handling. 67272 ac_log=" 67273 This file was extended by OpenJDK $as_me jdk9, which was 67274 generated by GNU Autoconf 2.69. Invocation command line was 67275 67276 CONFIG_FILES = $CONFIG_FILES 67277 CONFIG_HEADERS = $CONFIG_HEADERS 67278 CONFIG_LINKS = $CONFIG_LINKS 67279 CONFIG_COMMANDS = $CONFIG_COMMANDS 67280 $ $0 $@ 67281 67282 on `(hostname || uname -n) 2>/dev/null | sed 1q` 67283 " 67284 67285 _ACEOF 67286 67287 case $ac_config_files in *" 67288 "*) set x $ac_config_files; shift; ac_config_files=$*;; 67289 esac 67290 67291 67292 67293 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 67294 # Files that config.status was made for. 67295 config_files="$ac_config_files" 67296 67297 _ACEOF 67298 67299 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 67300 ac_cs_usage="\ 67301 \`$as_me' instantiates files and other configuration actions 67302 from templates according to the current configuration. Unless the files 67303 and actions are specified as TAGs, all are instantiated by default. 67304 67305 Usage: $0 [OPTION]... [TAG]... 67306 67307 -h, --help print this help, then exit 67308 -V, --version print version number and configuration settings, then exit 67309 --config print configuration, then exit 67310 -q, --quiet, --silent 67311 do not print progress messages 67312 -d, --debug don't remove temporary files 67313 --recheck update $as_me by reconfiguring in the same conditions 67314 --file=FILE[:TEMPLATE] 67315 instantiate the configuration file FILE 67316 67317 Configuration files: 67318 $config_files 67319 67320 Report bugs to <build-dev@openjdk.java.net>. 67321 OpenJDK home page: <http://openjdk.java.net>." 67322 67323 _ACEOF 67324 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 67325 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" 67326 ac_cs_version="\\ 67327 OpenJDK config.status jdk9 67328 configured by $0, generated by GNU Autoconf 2.69, 67329 with options \\"\$ac_cs_config\\" 67330 67331 Copyright (C) 2012 Free Software Foundation, Inc. 67332 This config.status script is free software; the Free Software Foundation 67333 gives unlimited permission to copy, distribute and modify it." 67334 67335 ac_pwd='$ac_pwd' 67336 srcdir='$srcdir' 67337 AWK='$AWK' 67338 test -n "\$AWK" || AWK=awk 67339 _ACEOF 67340 67341 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 67342 # The default lists apply if the user does not specify any file. 67343 ac_need_defaults=: 67344 while test $# != 0 67345 do 67346 case $1 in 67347 --*=?*) 67348 ac_option=`expr "X$1" : 'X\([^=]*\)='` 67349 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` 67350 ac_shift=: 67351 ;; 67352 --*=) 67353 ac_option=`expr "X$1" : 'X\([^=]*\)='` 67354 ac_optarg= 67355 ac_shift=: 67356 ;; 67357 *) 67358 ac_option=$1 67359 ac_optarg=$2 67360 ac_shift=shift 67361 ;; 67362 esac 67363 67364 case $ac_option in 67365 # Handling of the options. 67366 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) 67367 ac_cs_recheck=: ;; 67368 --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) 67369 $as_echo "$ac_cs_version"; exit ;; 67370 --config | --confi | --conf | --con | --co | --c ) 67371 $as_echo "$ac_cs_config"; exit ;; 67372 --debug | --debu | --deb | --de | --d | -d ) 67373 debug=: ;; 67374 --file | --fil | --fi | --f ) 67375 $ac_shift 67376 case $ac_optarg in 67377 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; 67378 '') as_fn_error $? "missing file argument" ;; 67379 esac 67380 as_fn_append CONFIG_FILES " '$ac_optarg'" 67381 ac_need_defaults=false;; 67382 --he | --h | --help | --hel | -h ) 67383 $as_echo "$ac_cs_usage"; exit ;; 67384 -q | -quiet | --quiet | --quie | --qui | --qu | --q \ 67385 | -silent | --silent | --silen | --sile | --sil | --si | --s) 67386 ac_cs_silent=: ;; 67387 67388 # This is an error. 67389 -*) as_fn_error $? "unrecognized option: \`$1' 67390 Try \`$0 --help' for more information." ;; 67391 67392 *) as_fn_append ac_config_targets " $1" 67393 ac_need_defaults=false ;; 67394 67395 esac 67396 shift 67397 done 67398 67399 ac_configure_extra_args= 67400 67401 if $ac_cs_silent; then 67402 exec 6>/dev/null 67403 ac_configure_extra_args="$ac_configure_extra_args --silent" 67404 fi 67405 67406 _ACEOF 67407 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 67408 if \$ac_cs_recheck; then 67409 set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion 67410 shift 67411 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 67412 CONFIG_SHELL='$SHELL' 67413 export CONFIG_SHELL 67414 exec "\$@" 67415 fi 67416 67417 _ACEOF 67418 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 67419 exec 5>>config.log 67420 { 67421 echo 67422 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX 67423 ## Running $as_me. ## 67424 _ASBOX 67425 $as_echo "$ac_log" 67426 } >&5 67427 67428 _ACEOF 67429 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 67430 _ACEOF 67431 67432 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 67433 67434 # Handling of arguments. 67435 for ac_config_target in $ac_config_targets 67436 do 67437 case $ac_config_target in 67438 "$OUTPUT_ROOT/spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/spec.gmk:$AUTOCONF_DIR/spec.gmk.in" ;; 67439 "$OUTPUT_ROOT/bootcycle-spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/bootcycle-spec.gmk:$AUTOCONF_DIR/bootcycle-spec.gmk.in" ;; 67440 "$OUTPUT_ROOT/buildjdk-spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/buildjdk-spec.gmk:$AUTOCONF_DIR/buildjdk-spec.gmk.in" ;; 67441 "$OUTPUT_ROOT/compare.sh") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/compare.sh:$AUTOCONF_DIR/compare.sh.in" ;; 67442 "$OUTPUT_ROOT/Makefile") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/Makefile:$AUTOCONF_DIR/Makefile.in" ;; 67443 67444 *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; 67445 esac 67446 done 67447 67448 67449 # If the user did not use the arguments to specify the items to instantiate, 67450 # then the envvar interface is used. Set only those that are not. 67451 # We use the long form for the default assignment because of an extremely 67452 # bizarre bug on SunOS 4.1.3. 67453 if $ac_need_defaults; then 67454 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files 67455 fi 67456 67457 # Have a temporary directory for convenience. Make it in the build tree 67458 # simply because there is no reason against having it here, and in addition, 67459 # creating and moving files from /tmp can sometimes cause problems. 67460 # Hook for its removal unless debugging. 67461 # Note that there is a small window in which the directory will not be cleaned: 67462 # after its creation but before its name has been assigned to `$tmp'. 67463 $debug || 67464 { 67465 tmp= ac_tmp= 67466 trap 'exit_status=$? 67467 : "${ac_tmp:=$tmp}" 67468 { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status 67469 ' 0 67470 trap 'as_fn_exit 1' 1 2 13 15 67471 } 67472 # Create a (secure) tmp directory for tmp files. 67473 67474 { 67475 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && 67476 test -d "$tmp" 67477 } || 67478 { 67479 tmp=./conf$$-$RANDOM 67480 (umask 077 && mkdir "$tmp") 67481 } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 67482 ac_tmp=$tmp 67483 67484 # Set up the scripts for CONFIG_FILES section. 67485 # No need to generate them if there are no CONFIG_FILES. 67486 # This happens for instance with `./config.status config.h'. 67487 if test -n "$CONFIG_FILES"; then 67488 67489 67490 ac_cr=`echo X | tr X '\015'` 67491 # On cygwin, bash can eat \r inside `` if the user requested igncr. 67492 # But we know of no other shell where ac_cr would be empty at this 67493 # point, so we can use a bashism as a fallback. 67494 if test "x$ac_cr" = x; then 67495 eval ac_cr=\$\'\\r\' 67496 fi 67497 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null` 67498 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then 67499 ac_cs_awk_cr='\\r' 67500 else 67501 ac_cs_awk_cr=$ac_cr 67502 fi 67503 67504 echo 'BEGIN {' >"$ac_tmp/subs1.awk" && 67505 _ACEOF 67506 67507 67508 { 67509 echo "cat >conf$$subs.awk <<_ACEOF" && 67510 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && 67511 echo "_ACEOF" 67512 } >conf$$subs.sh || 67513 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 67514 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` 67515 ac_delim='%!_!# ' 67516 for ac_last_try in false false false false false :; do 67517 . ./conf$$subs.sh || 67518 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 67519 67520 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` 67521 if test $ac_delim_n = $ac_delim_num; then 67522 break 67523 elif $ac_last_try; then 67524 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 67525 else 67526 ac_delim="$ac_delim!$ac_delim _$ac_delim!! " 67527 fi 67528 done 67529 rm -f conf$$subs.sh 67530 67531 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 67532 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && 67533 _ACEOF 67534 sed -n ' 67535 h 67536 s/^/S["/; s/!.*/"]=/ 67537 p 67538 g 67539 s/^[^!]*!// 67540 :repl 67541 t repl 67542 s/'"$ac_delim"'$// 67543 t delim 67544 :nl 67545 h 67546 s/\(.\{148\}\)..*/\1/ 67547 t more1 67548 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ 67549 p 67550 n 67551 b repl 67552 :more1 67553 s/["\\]/\\&/g; s/^/"/; s/$/"\\/ 67554 p 67555 g 67556 s/.\{148\}// 67557 t nl 67558 :delim 67559 h 67560 s/\(.\{148\}\)..*/\1/ 67561 t more2 67562 s/["\\]/\\&/g; s/^/"/; s/$/"/ 67563 p 67564 b 67565 :more2 67566 s/["\\]/\\&/g; s/^/"/; s/$/"\\/ 67567 p 67568 g 67569 s/.\{148\}// 67570 t delim 67571 ' <conf$$subs.awk | sed ' 67572 /^[^""]/{ 67573 N 67574 s/\n// 67575 } 67576 ' >>$CONFIG_STATUS || ac_write_fail=1 67577 rm -f conf$$subs.awk 67578 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 67579 _ACAWK 67580 cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && 67581 for (key in S) S_is_set[key] = 1 67582 FS = "" 67583 67584 } 67585 { 67586 line = $ 0 67587 nfields = split(line, field, "@") 67588 substed = 0 67589 len = length(field[1]) 67590 for (i = 2; i < nfields; i++) { 67591 key = field[i] 67592 keylen = length(key) 67593 if (S_is_set[key]) { 67594 value = S[key] 67595 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) 67596 len += length(value) + length(field[++i]) 67597 substed = 1 67598 } else 67599 len += 1 + keylen 67600 } 67601 67602 print line 67603 } 67604 67605 _ACAWK 67606 _ACEOF 67607 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 67608 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then 67609 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" 67610 else 67611 cat 67612 fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ 67613 || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 67614 _ACEOF 67615 67616 # VPATH may cause trouble with some makes, so we remove sole $(srcdir), 67617 # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and 67618 # trailing colons and then remove the whole line if VPATH becomes empty 67619 # (actually we leave an empty line to preserve line numbers). 67620 if test "x$srcdir" = x.; then 67621 ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ 67622 h 67623 s/// 67624 s/^/:/ 67625 s/[ ]*$/:/ 67626 s/:\$(srcdir):/:/g 67627 s/:\${srcdir}:/:/g 67628 s/:@srcdir@:/:/g 67629 s/^:*// 67630 s/:*$// 67631 x 67632 s/\(=[ ]*\).*/\1/ 67633 G 67634 s/\n// 67635 s/^[^=]*=[ ]*$// 67636 }' 67637 fi 67638 67639 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 67640 fi # test -n "$CONFIG_FILES" 67641 67642 67643 eval set X " :F $CONFIG_FILES " 67644 shift 67645 for ac_tag 67646 do 67647 case $ac_tag in 67648 :[FHLC]) ac_mode=$ac_tag; continue;; 67649 esac 67650 case $ac_mode$ac_tag in 67651 :[FHL]*:*);; 67652 :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; 67653 :[FH]-) ac_tag=-:-;; 67654 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; 67655 esac 67656 ac_save_IFS=$IFS 67657 IFS=: 67658 set x $ac_tag 67659 IFS=$ac_save_IFS 67660 shift 67661 ac_file=$1 67662 shift 67663 67664 case $ac_mode in 67665 :L) ac_source=$1;; 67666 :[FH]) 67667 ac_file_inputs= 67668 for ac_f 67669 do 67670 case $ac_f in 67671 -) ac_f="$ac_tmp/stdin";; 67672 *) # Look for the file first in the build tree, then in the source tree 67673 # (if the path is not absolute). The absolute path cannot be DOS-style, 67674 # because $ac_f cannot contain `:'. 67675 test -f "$ac_f" || 67676 case $ac_f in 67677 [\\/$]*) false;; 67678 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; 67679 esac || 67680 as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; 67681 esac 67682 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac 67683 as_fn_append ac_file_inputs " '$ac_f'" 67684 done 67685 67686 # Let's still pretend it is `configure' which instantiates (i.e., don't 67687 # use $as_me), people would be surprised to read: 67688 # /* config.h. Generated by config.status. */ 67689 configure_input='Generated from '` 67690 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' 67691 `' by configure.' 67692 if test x"$ac_file" != x-; then 67693 configure_input="$ac_file. $configure_input" 67694 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 67695 $as_echo "$as_me: creating $ac_file" >&6;} 67696 fi 67697 # Neutralize special characters interpreted by sed in replacement strings. 67698 case $configure_input in #( 67699 *\&* | *\|* | *\\* ) 67700 ac_sed_conf_input=`$as_echo "$configure_input" | 67701 sed 's/[\\\\&|]/\\\\&/g'`;; #( 67702 *) ac_sed_conf_input=$configure_input;; 67703 esac 67704 67705 case $ac_tag in 67706 *:-:* | *:-) cat >"$ac_tmp/stdin" \ 67707 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; 67708 esac 67709 ;; 67710 esac 67711 67712 ac_dir=`$as_dirname -- "$ac_file" || 67713 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 67714 X"$ac_file" : 'X\(//\)[^/]' \| \ 67715 X"$ac_file" : 'X\(//\)$' \| \ 67716 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || 67717 $as_echo X"$ac_file" | 67718 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 67719 s//\1/ 67720 q 67721 } 67722 /^X\(\/\/\)[^/].*/{ 67723 s//\1/ 67724 q 67725 } 67726 /^X\(\/\/\)$/{ 67727 s//\1/ 67728 q 67729 } 67730 /^X\(\/\).*/{ 67731 s//\1/ 67732 q 67733 } 67734 s/.*/./; q'` 67735 as_dir="$ac_dir"; as_fn_mkdir_p 67736 ac_builddir=. 67737 67738 case "$ac_dir" in 67739 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; 67740 *) 67741 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` 67742 # A ".." for each directory in $ac_dir_suffix. 67743 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` 67744 case $ac_top_builddir_sub in 67745 "") ac_top_builddir_sub=. ac_top_build_prefix= ;; 67746 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; 67747 esac ;; 67748 esac 67749 ac_abs_top_builddir=$ac_pwd 67750 ac_abs_builddir=$ac_pwd$ac_dir_suffix 67751 # for backward compatibility: 67752 ac_top_builddir=$ac_top_build_prefix 67753 67754 case $srcdir in 67755 .) # We are building in place. 67756 ac_srcdir=. 67757 ac_top_srcdir=$ac_top_builddir_sub 67758 ac_abs_top_srcdir=$ac_pwd ;; 67759 [\\/]* | ?:[\\/]* ) # Absolute name. 67760 ac_srcdir=$srcdir$ac_dir_suffix; 67761 ac_top_srcdir=$srcdir 67762 ac_abs_top_srcdir=$srcdir ;; 67763 *) # Relative name. 67764 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix 67765 ac_top_srcdir=$ac_top_build_prefix$srcdir 67766 ac_abs_top_srcdir=$ac_pwd/$srcdir ;; 67767 esac 67768 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix 67769 67770 67771 case $ac_mode in 67772 :F) 67773 # 67774 # CONFIG_FILE 67775 # 67776 67777 _ACEOF 67778 67779 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 67780 # If the template does not know about datarootdir, expand it. 67781 # FIXME: This hack should be removed a few years after 2.60. 67782 ac_datarootdir_hack=; ac_datarootdir_seen= 67783 ac_sed_dataroot=' 67784 /datarootdir/ { 67785 p 67786 q 67787 } 67788 /@datadir@/p 67789 /@docdir@/p 67790 /@infodir@/p 67791 /@localedir@/p 67792 /@mandir@/p' 67793 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in 67794 *datarootdir*) ac_datarootdir_seen=yes;; 67795 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) 67796 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 67797 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} 67798 _ACEOF 67799 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 67800 ac_datarootdir_hack=' 67801 s&@datadir@&$datadir&g 67802 s&@docdir@&$docdir&g 67803 s&@infodir@&$infodir&g 67804 s&@localedir@&$localedir&g 67805 s&@mandir@&$mandir&g 67806 s&\\\${datarootdir}&$datarootdir&g' ;; 67807 esac 67808 _ACEOF 67809 67810 # Neutralize VPATH when `$srcdir' = `.'. 67811 # Shell code in configure.ac might set extrasub. 67812 # FIXME: do we really want to maintain this feature? 67813 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 67814 ac_sed_extra="$ac_vpsub 67815 $extrasub 67816 _ACEOF 67817 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 67818 :t 67819 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b 67820 s|@configure_input@|$ac_sed_conf_input|;t t 67821 s&@top_builddir@&$ac_top_builddir_sub&;t t 67822 s&@top_build_prefix@&$ac_top_build_prefix&;t t 67823 s&@srcdir@&$ac_srcdir&;t t 67824 s&@abs_srcdir@&$ac_abs_srcdir&;t t 67825 s&@top_srcdir@&$ac_top_srcdir&;t t 67826 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t 67827 s&@builddir@&$ac_builddir&;t t 67828 s&@abs_builddir@&$ac_abs_builddir&;t t 67829 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t 67830 $ac_datarootdir_hack 67831 " 67832 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ 67833 >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 67834 67835 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && 67836 { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && 67837 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ 67838 "$ac_tmp/out"`; test -z "$ac_out"; } && 67839 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' 67840 which seems to be undefined. Please make sure it is defined" >&5 67841 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' 67842 which seems to be undefined. Please make sure it is defined" >&2;} 67843 67844 rm -f "$ac_tmp/stdin" 67845 case $ac_file in 67846 -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; 67847 *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; 67848 esac \ 67849 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 67850 ;; 67851 67852 67853 67854 esac 67855 67856 done # for ac_tag 67857 67858 67859 as_fn_exit 0 67860 _ACEOF 67861 ac_clean_files=$ac_clean_files_save 67862 67863 test $ac_write_fail = 0 || 67864 as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 67865 67866 67867 # configure is writing to config.log, and then calls config.status. 67868 # config.status does its own redirection, appending to config.log. 67869 # Unfortunately, on DOS this fails, as config.log is still kept open 67870 # by configure, so config.status won't be able to write to it; its 67871 # output is simply discarded. So we exec the FD to /dev/null, 67872 # effectively closing config.log, so it can be properly (re)opened and 67873 # appended to by config.status. When coming back to configure, we 67874 # need to make the FD available again. 67875 if test "$no_create" != yes; then 67876 ac_cs_success=: 67877 ac_config_status_args= 67878 test "$silent" = yes && 67879 ac_config_status_args="$ac_config_status_args --quiet" 67880 exec 5>/dev/null 67881 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false 67882 exec 5>>config.log 67883 # Use ||, not &&, to avoid exiting from the if with $? = 1, which 67884 # would make configure fail if this is the last instruction. 67885 $ac_cs_success || as_fn_exit 1 67886 fi 67887 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then 67888 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 67889 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} 67890 fi 67891 67892 67893 # After AC_OUTPUT, we need to do final work 67894 67895 67896 # Try to move config.log (generated by autoconf) to the configure-support directory. 67897 if test -e ./config.log; then 67898 $MV -f ./config.log "$CONFIGURESUPPORT_OUTPUTDIR/config.log" 2> /dev/null 67899 fi 67900 67901 # Rotate our log file (configure.log) 67902 if test -e "$OUTPUT_ROOT/configure.log.old"; then 67903 $RM -f "$OUTPUT_ROOT/configure.log.old" 67904 fi 67905 if test -e "$OUTPUT_ROOT/configure.log"; then 67906 $MV -f "$OUTPUT_ROOT/configure.log" "$OUTPUT_ROOT/configure.log.old" 2> /dev/null 67907 fi 67908 67909 # Move configure.log from current directory to the build output root 67910 if test -e ./configure.log; then 67911 $MV -f ./configure.log "$OUTPUT_ROOT/configure.log" 2> /dev/null 67912 fi 67913 67914 # Make the compare script executable 67915 $CHMOD +x $OUTPUT_ROOT/compare.sh 67916 67917 67918 # Finally output some useful information to the user 67919 67920 # Finally output some useful information to the user 67921 67922 printf "\n" 67923 printf "====================================================\n" 67924 if test "x$no_create" != "xyes"; then 67925 if test "x$IS_RECONFIGURE" != "xyes"; then 67926 printf "A new configuration has been successfully created in\n%s\n" "$OUTPUT_ROOT" 67927 else 67928 printf "The existing configuration has been successfully updated in\n%s\n" "$OUTPUT_ROOT" 67929 fi 67930 else 67931 if test "x$IS_RECONFIGURE" != "xyes"; then 67932 printf "A configuration has been successfully checked but not created\n" 67933 else 67934 printf "The existing configuration has been successfully checked in\n%s\n" "$OUTPUT_ROOT" 67935 fi 67936 fi 67937 if test "x$CONFIGURE_COMMAND_LINE" != x; then 67938 printf "using configure arguments '$CONFIGURE_COMMAND_LINE'.\n" 67939 else 67940 printf "using default settings.\n" 67941 fi 67942 67943 printf "\n" 67944 printf "Configuration summary:\n" 67945 printf "* Debug level: $DEBUG_LEVEL\n" 67946 printf "* HS debug level: $HOTSPOT_DEBUG_LEVEL\n" 67947 printf "* JDK variant: $JDK_VARIANT\n" 67948 printf "* JVM variants: $JVM_VARIANTS\n" 67949 printf "* OpenJDK target: OS: $OPENJDK_TARGET_OS, CPU architecture: $OPENJDK_TARGET_CPU_ARCH, address length: $OPENJDK_TARGET_CPU_BITS\n" 67950 printf "* Version string: $VERSION_STRING ($VERSION_SHORT)\n" 67951 67952 printf "\n" 67953 printf "Tools summary:\n" 67954 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 67955 printf "* Environment: $WINDOWS_ENV_VENDOR version $WINDOWS_ENV_VERSION (root at $WINDOWS_ENV_ROOT_PATH)\n" 67956 fi 67957 printf "* Boot JDK: $BOOT_JDK_VERSION (at $BOOT_JDK)\n" 67958 if test "x$TOOLCHAIN_VERSION" != "x"; then 67959 print_version=" $TOOLCHAIN_VERSION" 67960 fi 67961 printf "* Toolchain: $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION$print_version)\n" 67962 printf "* C Compiler: Version $CC_VERSION_NUMBER (at $CC)\n" 67963 printf "* C++ Compiler: Version $CXX_VERSION_NUMBER (at $CXX)\n" 67964 67965 printf "\n" 67966 printf "Build performance summary:\n" 67967 printf "* Cores to use: $JOBS\n" 67968 printf "* Memory limit: $MEMORY_SIZE MB\n" 67969 if test "x$CCACHE_STATUS" != "x"; then 67970 printf "* ccache status: $CCACHE_STATUS\n" 67971 fi 67972 printf "\n" 67973 67974 if test "x$BUILDING_MULTIPLE_JVM_VARIANTS" = "xtrue"; then 67975 printf "NOTE: You have requested to build more than one version of the JVM, which\n" 67976 printf "will result in longer build times.\n" 67977 printf "\n" 67978 fi 67979 67980 if test "x$FOUND_ALT_VARIABLES" != "x"; then 67981 printf "WARNING: You have old-style ALT_ environment variables set.\n" 67982 printf "These are not respected, and will be ignored. It is recommended\n" 67983 printf "that you clean your environment. The following variables are set:\n" 67984 printf "$FOUND_ALT_VARIABLES\n" 67985 printf "\n" 67986 fi 67987 67988 if test "x$OUTPUT_DIR_IS_LOCAL" != "xyes"; then 67989 printf "WARNING: Your build output directory is not on a local disk.\n" 67990 printf "This will severely degrade build performance!\n" 67991 printf "It is recommended that you create an output directory on a local disk,\n" 67992 printf "and run the configure script again from that directory.\n" 67993 printf "\n" 67994 fi 67995 67996 if test "x$IS_RECONFIGURE" = "xyes" && test "x$no_create" != "xyes"; then 67997 printf "WARNING: The result of this configuration has overridden an older\n" 67998 printf "configuration. You *should* run 'make clean' to make sure you get a\n" 67999 printf "proper build. Failure to do so might result in strange build problems.\n" 68000 printf "\n" 68001 fi 68002 68003 if test "x$IS_RECONFIGURE" != "xyes" && test "x$no_create" = "xyes"; then 68004 printf "WARNING: The result of this configuration was not saved.\n" 68005 printf "You should run without '--no-create | -n' to create the configuration.\n" 68006 printf "\n" 68007 fi 68008 68009 68010 68011 # Locate config.log. 68012 if test -e "$CONFIGURESUPPORT_OUTPUTDIR/config.log"; then 68013 CONFIG_LOG_PATH="$CONFIGURESUPPORT_OUTPUTDIR" 68014 elif test -e "./config.log"; then 68015 CONFIG_LOG_PATH="." 68016 fi 68017 68018 if test -e "$CONFIG_LOG_PATH/config.log"; then 68019 $GREP '^configure:.*: WARNING:' "$CONFIG_LOG_PATH/config.log" > /dev/null 2>&1 68020 if test $? -eq 0; then 68021 printf "The following warnings were produced. Repeated here for convenience:\n" 68022 # We must quote sed expression (using []) to stop m4 from eating the []. 68023 $GREP '^configure:.*: WARNING:' "$CONFIG_LOG_PATH/config.log" | $SED -e 's/^configure:[0-9]*: //' 68024 printf "\n" 68025 fi 68026 fi 68027