1 #!/bin/bash 2 # 3 # ########################################################## 4 # ### THIS FILE IS AUTOMATICALLY GENERATED. DO NOT EDIT. ### 5 # ########################################################## 6 # 7 #! /bin/sh 8 # Guess values for system-dependent variables and create Makefiles. 9 # Generated by GNU Autoconf 2.69 for OpenJDK jdk9. 10 # 11 # Report bugs to <build-dev@openjdk.java.net>. 12 # 13 # 14 # Copyright (C) 1992-1996, 1998-2012 Free Software Foundation, Inc. 15 # 16 # 17 # This configure script is free software; the Free Software Foundation 18 # gives unlimited permission to copy, distribute and modify it. 19 ## -------------------- ## 20 ## M4sh Initialization. ## 21 ## -------------------- ## 22 23 # Be more Bourne compatible 24 DUALCASE=1; export DUALCASE # for MKS sh 25 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : 26 emulate sh 27 NULLCMD=: 28 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which 29 # is contrary to our usage. Disable this feature. 30 alias -g '${1+"$@"}'='"$@"' 31 setopt NO_GLOB_SUBST 32 else 33 case `(set -o) 2>/dev/null` in #( 34 *posix*) : 35 set -o posix ;; #( 36 *) : 37 ;; 38 esac 39 fi 40 41 42 as_nl=' 43 ' 44 export as_nl 45 # Printing a long string crashes Solaris 7 /usr/bin/printf. 46 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' 47 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo 48 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo 49 # Prefer a ksh shell builtin over an external printf program on Solaris, 50 # but without wasting forks for bash or zsh. 51 if test -z "$BASH_VERSION$ZSH_VERSION" \ 52 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then 53 as_echo='print -r --' 54 as_echo_n='print -rn --' 55 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then 56 as_echo='printf %s\n' 57 as_echo_n='printf %s' 58 else 59 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then 60 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' 61 as_echo_n='/usr/ucb/echo -n' 62 else 63 as_echo_body='eval expr "X$1" : "X\\(.*\\)"' 64 as_echo_n_body='eval 65 arg=$1; 66 case $arg in #( 67 *"$as_nl"*) 68 expr "X$arg" : "X\\(.*\\)$as_nl"; 69 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; 70 esac; 71 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" 72 ' 73 export as_echo_n_body 74 as_echo_n='sh -c $as_echo_n_body as_echo' 75 fi 76 export as_echo_body 77 as_echo='sh -c $as_echo_body as_echo' 78 fi 79 80 # The user is always right. 81 if test "${PATH_SEPARATOR+set}" != set; then 82 PATH_SEPARATOR=: 83 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { 84 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || 85 PATH_SEPARATOR=';' 86 } 87 fi 88 89 90 # IFS 91 # We need space, tab and new line, in precisely that order. Quoting is 92 # there to prevent editors from complaining about space-tab. 93 # (If _AS_PATH_WALK were called with IFS unset, it would disable word 94 # splitting by setting IFS to empty value.) 95 IFS=" "" $as_nl" 96 97 # Find who we are. Look in the path if we contain no directory separator. 98 as_myself= 99 case $0 in #(( 100 *[\\/]* ) as_myself=$0 ;; 101 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 102 for as_dir in $PATH 103 do 104 IFS=$as_save_IFS 105 test -z "$as_dir" && as_dir=. 106 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break 107 done 108 IFS=$as_save_IFS 109 110 ;; 111 esac 112 # We did not find ourselves, most probably we were run as `sh COMMAND' 113 # in which case we are not to be found in the path. 114 if test "x$as_myself" = x; then 115 as_myself=$0 116 fi 117 if test ! -f "$as_myself"; then 118 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 119 exit 1 120 fi 121 122 # Unset variables that we do not need and which cause bugs (e.g. in 123 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" 124 # suppresses any "Segmentation fault" message there. '((' could 125 # trigger a bug in pdksh 5.2.14. 126 for as_var in BASH_ENV ENV MAIL MAILPATH 127 do eval test x\${$as_var+set} = xset \ 128 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : 129 done 130 PS1='$ ' 131 PS2='> ' 132 PS4='+ ' 133 134 # NLS nuisances. 135 LC_ALL=C 136 export LC_ALL 137 LANGUAGE=C 138 export LANGUAGE 139 140 # CDPATH. 141 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH 142 143 # Use a proper internal environment variable to ensure we don't fall 144 # into an infinite loop, continuously re-executing ourselves. 145 if test x"${_as_can_reexec}" != xno && test "x$CONFIG_SHELL" != x; then 146 _as_can_reexec=no; export _as_can_reexec; 147 # We cannot yet assume a decent shell, so we have to provide a 148 # neutralization value for shells without unset; and this also 149 # works around shells that cannot unset nonexistent variables. 150 # Preserve -v and -x to the replacement shell. 151 BASH_ENV=/dev/null 152 ENV=/dev/null 153 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV 154 case $- in # (((( 155 *v*x* | *x*v* ) as_opts=-vx ;; 156 *v* ) as_opts=-v ;; 157 *x* ) as_opts=-x ;; 158 * ) as_opts= ;; 159 esac 160 exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} 161 # Admittedly, this is quite paranoid, since all the known shells bail 162 # out after a failed `exec'. 163 $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 164 as_fn_exit 255 165 fi 166 # We don't want this to propagate to other subprocesses. 167 { _as_can_reexec=; unset _as_can_reexec;} 168 if test "x$CONFIG_SHELL" = x; then 169 as_bourne_compatible="if test -n \"\${ZSH_VERSION+set}\" && (emulate sh) >/dev/null 2>&1; then : 170 emulate sh 171 NULLCMD=: 172 # Pre-4.2 versions of Zsh do word splitting on \${1+\"\$@\"}, which 173 # is contrary to our usage. Disable this feature. 174 alias -g '\${1+\"\$@\"}'='\"\$@\"' 175 setopt NO_GLOB_SUBST 176 else 177 case \`(set -o) 2>/dev/null\` in #( 178 *posix*) : 179 set -o posix ;; #( 180 *) : 181 ;; 182 esac 183 fi 184 " 185 as_required="as_fn_return () { (exit \$1); } 186 as_fn_success () { as_fn_return 0; } 187 as_fn_failure () { as_fn_return 1; } 188 as_fn_ret_success () { return 0; } 189 as_fn_ret_failure () { return 1; } 190 191 exitcode=0 192 as_fn_success || { exitcode=1; echo as_fn_success failed.; } 193 as_fn_failure && { exitcode=1; echo as_fn_failure succeeded.; } 194 as_fn_ret_success || { exitcode=1; echo as_fn_ret_success failed.; } 195 as_fn_ret_failure && { exitcode=1; echo as_fn_ret_failure succeeded.; } 196 if ( set x; as_fn_ret_success y && test x = \"\$1\" ); then : 197 198 else 199 exitcode=1; echo positional parameters were not saved. 200 fi 201 test x\$exitcode = x0 || exit 1 202 test -x / || exit 1" 203 as_suggested=" as_lineno_1=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_1a=\$LINENO 204 as_lineno_2=";as_suggested=$as_suggested$LINENO;as_suggested=$as_suggested" as_lineno_2a=\$LINENO 205 eval 'test \"x\$as_lineno_1'\$as_run'\" != \"x\$as_lineno_2'\$as_run'\" && 206 test \"x\`expr \$as_lineno_1'\$as_run' + 1\`\" = \"x\$as_lineno_2'\$as_run'\"' || exit 1 207 test \$(( 1 + 1 )) = 2 || exit 1" 208 if (eval "$as_required") 2>/dev/null; then : 209 as_have_required=yes 210 else 211 as_have_required=no 212 fi 213 if test x$as_have_required = xyes && (eval "$as_suggested") 2>/dev/null; then : 214 215 else 216 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 217 as_found=false 218 for as_dir in /bin$PATH_SEPARATOR/usr/bin$PATH_SEPARATOR$PATH 219 do 220 IFS=$as_save_IFS 221 test -z "$as_dir" && as_dir=. 222 as_found=: 223 case $as_dir in #( 224 /*) 225 for as_base in sh bash ksh sh5; do 226 # Try only shells that exist, to save several forks. 227 as_shell=$as_dir/$as_base 228 if { test -f "$as_shell" || test -f "$as_shell.exe"; } && 229 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$as_shell"; } 2>/dev/null; then : 230 CONFIG_SHELL=$as_shell as_have_required=yes 231 if { $as_echo "$as_bourne_compatible""$as_suggested" | as_run=a "$as_shell"; } 2>/dev/null; then : 232 break 2 233 fi 234 fi 235 done;; 236 esac 237 as_found=false 238 done 239 $as_found || { if { test -f "$SHELL" || test -f "$SHELL.exe"; } && 240 { $as_echo "$as_bourne_compatible""$as_required" | as_run=a "$SHELL"; } 2>/dev/null; then : 241 CONFIG_SHELL=$SHELL as_have_required=yes 242 fi; } 243 IFS=$as_save_IFS 244 245 246 if test "x$CONFIG_SHELL" != x; then : 247 export CONFIG_SHELL 248 # We cannot yet assume a decent shell, so we have to provide a 249 # neutralization value for shells without unset; and this also 250 # works around shells that cannot unset nonexistent variables. 251 # Preserve -v and -x to the replacement shell. 252 BASH_ENV=/dev/null 253 ENV=/dev/null 254 (unset BASH_ENV) >/dev/null 2>&1 && unset BASH_ENV ENV 255 case $- in # (((( 256 *v*x* | *x*v* ) as_opts=-vx ;; 257 *v* ) as_opts=-v ;; 258 *x* ) as_opts=-x ;; 259 * ) as_opts= ;; 260 esac 261 exec $CONFIG_SHELL $as_opts "$as_myself" ${1+"$@"} 262 # Admittedly, this is quite paranoid, since all the known shells bail 263 # out after a failed `exec'. 264 $as_echo "$0: could not re-execute with $CONFIG_SHELL" >&2 265 exit 255 266 fi 267 268 if test x$as_have_required = xno; then : 269 $as_echo "$0: This script requires a shell more modern than all" 270 $as_echo "$0: the shells that I found on your system." 271 if test x${ZSH_VERSION+set} = xset ; then 272 $as_echo "$0: In particular, zsh $ZSH_VERSION has bugs and should" 273 $as_echo "$0: be upgraded to zsh 4.3.4 or later." 274 else 275 $as_echo "$0: Please tell bug-autoconf@gnu.org and 276 $0: build-dev@openjdk.java.net about your system, including 277 $0: any error possibly output before this message. Then 278 $0: install a modern shell, or manually run the script 279 $0: under such a shell if you do have one." 280 fi 281 exit 1 282 fi 283 fi 284 fi 285 SHELL=${CONFIG_SHELL-/bin/sh} 286 export SHELL 287 # Unset more variables known to interfere with behavior of common tools. 288 CLICOLOR_FORCE= GREP_OPTIONS= 289 unset CLICOLOR_FORCE GREP_OPTIONS 290 291 ## --------------------- ## 292 ## M4sh Shell Functions. ## 293 ## --------------------- ## 294 # as_fn_unset VAR 295 # --------------- 296 # Portably unset VAR. 297 as_fn_unset () 298 { 299 { eval $1=; unset $1;} 300 } 301 as_unset=as_fn_unset 302 303 # as_fn_set_status STATUS 304 # ----------------------- 305 # Set $? to STATUS, without forking. 306 as_fn_set_status () 307 { 308 return $1 309 } # as_fn_set_status 310 311 # as_fn_exit STATUS 312 # ----------------- 313 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. 314 as_fn_exit () 315 { 316 set +e 317 as_fn_set_status $1 318 exit $1 319 } # as_fn_exit 320 321 # as_fn_mkdir_p 322 # ------------- 323 # Create "$as_dir" as a directory, including parents if necessary. 324 as_fn_mkdir_p () 325 { 326 327 case $as_dir in #( 328 -*) as_dir=./$as_dir;; 329 esac 330 test -d "$as_dir" || eval $as_mkdir_p || { 331 as_dirs= 332 while :; do 333 case $as_dir in #( 334 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( 335 *) as_qdir=$as_dir;; 336 esac 337 as_dirs="'$as_qdir' $as_dirs" 338 as_dir=`$as_dirname -- "$as_dir" || 339 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 340 X"$as_dir" : 'X\(//\)[^/]' \| \ 341 X"$as_dir" : 'X\(//\)$' \| \ 342 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || 343 $as_echo X"$as_dir" | 344 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 345 s//\1/ 346 q 347 } 348 /^X\(\/\/\)[^/].*/{ 349 s//\1/ 350 q 351 } 352 /^X\(\/\/\)$/{ 353 s//\1/ 354 q 355 } 356 /^X\(\/\).*/{ 357 s//\1/ 358 q 359 } 360 s/.*/./; q'` 361 test -d "$as_dir" && break 362 done 363 test -z "$as_dirs" || eval "mkdir $as_dirs" 364 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" 365 366 367 } # as_fn_mkdir_p 368 369 # as_fn_executable_p FILE 370 # ----------------------- 371 # Test if FILE is an executable regular file. 372 as_fn_executable_p () 373 { 374 test -f "$1" && test -x "$1" 375 } # as_fn_executable_p 376 # as_fn_append VAR VALUE 377 # ---------------------- 378 # Append the text in VALUE to the end of the definition contained in VAR. Take 379 # advantage of any shell optimizations that allow amortized linear growth over 380 # repeated appends, instead of the typical quadratic growth present in naive 381 # implementations. 382 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : 383 eval 'as_fn_append () 384 { 385 eval $1+=\$2 386 }' 387 else 388 as_fn_append () 389 { 390 eval $1=\$$1\$2 391 } 392 fi # as_fn_append 393 394 # as_fn_arith ARG... 395 # ------------------ 396 # Perform arithmetic evaluation on the ARGs, and store the result in the 397 # global $as_val. Take advantage of shells that can avoid forks. The arguments 398 # must be portable across $(()) and expr. 399 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : 400 eval 'as_fn_arith () 401 { 402 as_val=$(( $* )) 403 }' 404 else 405 as_fn_arith () 406 { 407 as_val=`expr "$@" || test $? -eq 1` 408 } 409 fi # as_fn_arith 410 411 412 # as_fn_error STATUS ERROR [LINENO LOG_FD] 413 # ---------------------------------------- 414 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are 415 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the 416 # script with STATUS, using 1 if that was 0. 417 as_fn_error () 418 { 419 as_status=$1; test $as_status -eq 0 && as_status=1 420 if test "$4"; then 421 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 422 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 423 fi 424 $as_echo "$as_me: error: $2" >&2 425 as_fn_exit $as_status 426 } # as_fn_error 427 428 if expr a : '\(a\)' >/dev/null 2>&1 && 429 test "X`expr 00001 : '.*\(...\)'`" = X001; then 430 as_expr=expr 431 else 432 as_expr=false 433 fi 434 435 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then 436 as_basename=basename 437 else 438 as_basename=false 439 fi 440 441 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then 442 as_dirname=dirname 443 else 444 as_dirname=false 445 fi 446 447 as_me=`$as_basename -- "$0" || 448 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ 449 X"$0" : 'X\(//\)$' \| \ 450 X"$0" : 'X\(/\)' \| . 2>/dev/null || 451 $as_echo X/"$0" | 452 sed '/^.*\/\([^/][^/]*\)\/*$/{ 453 s//\1/ 454 q 455 } 456 /^X\/\(\/\/\)$/{ 457 s//\1/ 458 q 459 } 460 /^X\/\(\/\).*/{ 461 s//\1/ 462 q 463 } 464 s/.*/./; q'` 465 466 # Avoid depending upon Character Ranges. 467 as_cr_letters='abcdefghijklmnopqrstuvwxyz' 468 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' 469 as_cr_Letters=$as_cr_letters$as_cr_LETTERS 470 as_cr_digits='0123456789' 471 as_cr_alnum=$as_cr_Letters$as_cr_digits 472 473 474 as_lineno_1=$LINENO as_lineno_1a=$LINENO 475 as_lineno_2=$LINENO as_lineno_2a=$LINENO 476 eval 'test "x$as_lineno_1'$as_run'" != "x$as_lineno_2'$as_run'" && 477 test "x`expr $as_lineno_1'$as_run' + 1`" = "x$as_lineno_2'$as_run'"' || { 478 # Blame Lee E. McMahon (1931-1989) for sed's syntax. :-) 479 sed -n ' 480 p 481 /[$]LINENO/= 482 ' <$as_myself | 483 sed ' 484 s/[$]LINENO.*/&-/ 485 t lineno 486 b 487 :lineno 488 N 489 :loop 490 s/[$]LINENO\([^'$as_cr_alnum'_].*\n\)\(.*\)/\2\1\2/ 491 t loop 492 s/-\n.*// 493 ' >$as_me.lineno && 494 chmod +x "$as_me.lineno" || 495 { $as_echo "$as_me: error: cannot create $as_me.lineno; rerun with a POSIX shell" >&2; as_fn_exit 1; } 496 497 # If we had to re-execute with $CONFIG_SHELL, we're ensured to have 498 # already done that, so ensure we don't try to do so again and fall 499 # in an infinite loop. This has already happened in practice. 500 _as_can_reexec=no; export _as_can_reexec 501 # Don't try to exec as it changes $[0], causing all sort of problems 502 # (the dirname of $[0] is not the place where we might find the 503 # original and so on. Autoconf is especially sensitive to this). 504 . "./$as_me.lineno" 505 # Exit status is that of the last command. 506 exit 507 } 508 509 ECHO_C= ECHO_N= ECHO_T= 510 case `echo -n x` in #((((( 511 -n*) 512 case `echo 'xy\c'` in 513 *c*) ECHO_T=' ';; # ECHO_T is single tab character. 514 xy) ECHO_C='\c';; 515 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null 516 ECHO_T=' ';; 517 esac;; 518 *) 519 ECHO_N='-n';; 520 esac 521 522 rm -f conf$$ conf$$.exe conf$$.file 523 if test -d conf$$.dir; then 524 rm -f conf$$.dir/conf$$.file 525 else 526 rm -f conf$$.dir 527 mkdir conf$$.dir 2>/dev/null 528 fi 529 if (echo >conf$$.file) 2>/dev/null; then 530 if ln -s conf$$.file conf$$ 2>/dev/null; then 531 as_ln_s='ln -s' 532 # ... but there are two gotchas: 533 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. 534 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. 535 # In both cases, we have to default to `cp -pR'. 536 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || 537 as_ln_s='cp -pR' 538 elif ln conf$$.file conf$$ 2>/dev/null; then 539 as_ln_s=ln 540 else 541 as_ln_s='cp -pR' 542 fi 543 else 544 as_ln_s='cp -pR' 545 fi 546 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file 547 rmdir conf$$.dir 2>/dev/null 548 549 if mkdir -p . 2>/dev/null; then 550 as_mkdir_p='mkdir -p "$as_dir"' 551 else 552 test -d ./-p && rmdir ./-p 553 as_mkdir_p=false 554 fi 555 556 as_test_x='test -x' 557 as_executable_p=as_fn_executable_p 558 559 # Sed expression to map a string onto a valid CPP name. 560 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" 561 562 # Sed expression to map a string onto a valid variable name. 563 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" 564 565 566 test -n "$DJDIR" || exec 7<&0 </dev/null 567 exec 6>&1 568 569 # Name of the host. 570 # hostname on some systems (SVR3.2, old GNU/Linux) returns a bogus exit status, 571 # so uname gets run too. 572 ac_hostname=`(hostname || uname -n) 2>/dev/null | sed 1q` 573 574 # 575 # Initializations. 576 # 577 ac_default_prefix=/usr/local 578 ac_clean_files= 579 ac_config_libobj_dir=. 580 LIBOBJS= 581 cross_compiling=no 582 subdirs= 583 MFLAGS= 584 MAKEFLAGS= 585 586 # Identity of this package. 587 PACKAGE_NAME='OpenJDK' 588 PACKAGE_TARNAME='openjdk' 589 PACKAGE_VERSION='jdk9' 590 PACKAGE_STRING='OpenJDK jdk9' 591 PACKAGE_BUGREPORT='build-dev@openjdk.java.net' 592 PACKAGE_URL='http://openjdk.java.net' 593 594 # Factoring default headers for most tests. 595 ac_includes_default="\ 596 #include <stdio.h> 597 #ifdef HAVE_SYS_TYPES_H 598 # include <sys/types.h> 599 #endif 600 #ifdef HAVE_SYS_STAT_H 601 # include <sys/stat.h> 602 #endif 603 #ifdef STDC_HEADERS 604 # include <stdlib.h> 605 # include <stddef.h> 606 #else 607 # ifdef HAVE_STDLIB_H 608 # include <stdlib.h> 609 # endif 610 #endif 611 #ifdef HAVE_STRING_H 612 # if !defined STDC_HEADERS && defined HAVE_MEMORY_H 613 # include <memory.h> 614 # endif 615 # include <string.h> 616 #endif 617 #ifdef HAVE_STRINGS_H 618 # include <strings.h> 619 #endif 620 #ifdef HAVE_INTTYPES_H 621 # include <inttypes.h> 622 #endif 623 #ifdef HAVE_STDINT_H 624 # include <stdint.h> 625 #endif 626 #ifdef HAVE_UNISTD_H 627 # include <unistd.h> 628 #endif" 629 630 ac_subst_vars='LTLIBOBJS 631 LIBOBJS 632 CFLAGS_CCACHE 633 CCACHE 634 USE_PRECOMPILED_HEADER 635 BUILD_ICECC 636 ICECC 637 ICECC_WRAPPER 638 ICECC_CREATE_ENV 639 ICECC_CMD 640 ENABLE_JAVAC_SERVER 641 ENABLE_SJAVAC 642 SJAVAC_SERVER_JAVA_FLAGS 643 SJAVAC_SERVER_JAVA 644 JAVA_TOOL_FLAGS_SMALL 645 JAVA_FLAGS_SMALL 646 JAVA_FLAGS_JAVAC 647 BOOTCYCLE_JVM_ARGS_BIG 648 JAVA_FLAGS_BIG 649 JAVA_FLAGS 650 TEST_JOBS 651 JOBS 652 MEMORY_SIZE 653 NUM_CORES 654 ENABLE_GENERATE_CLASSLIST 655 BUILD_FAILURE_HANDLER 656 ENABLE_INTREE_EC 657 STLPORT_LIB 658 LIBZIP_CAN_USE_MMAP 659 LIBDL 660 LIBM 661 USE_EXTERNAL_LCMS 662 LCMS_LIBS 663 LCMS_CFLAGS 664 USE_EXTERNAL_LIBZ 665 USE_EXTERNAL_LIBPNG 666 PNG_LIBS 667 PNG_CFLAGS 668 USE_EXTERNAL_LIBGIF 669 USE_EXTERNAL_LIBJPEG 670 LLVM_LIBS 671 LLVM_LDFLAGS 672 LLVM_CFLAGS 673 LLVM_CONFIG 674 LIBFFI_LIBS 675 LIBFFI_CFLAGS 676 ALSA_LIBS 677 ALSA_CFLAGS 678 FREETYPE_BUNDLE_LIB_PATH 679 FREETYPE_LIBS 680 FREETYPE_CFLAGS 681 CUPS_CFLAGS 682 X_EXTRA_LIBS 683 X_LIBS 684 X_PRE_LIBS 685 X_CFLAGS 686 XMKMF 687 MSVCP_DLL 688 MSVCR_DLL 689 LIBCXX 690 FIXPATH_DETACH_FLAG 691 FIXPATH 692 BUILD_GTEST 693 VALID_JVM_FEATURES 694 JVM_FEATURES_custom 695 JVM_FEATURES_zeroshark 696 JVM_FEATURES_zero 697 JVM_FEATURES_minimal 698 JVM_FEATURES_core 699 JVM_FEATURES_client 700 JVM_FEATURES_server 701 INCLUDE_DTRACE 702 GCOV_ENABLED 703 STRIP_POLICY 704 DEBUG_BINARIES 705 ZIP_EXTERNAL_DEBUG_SYMBOLS 706 COPY_DEBUG_SYMBOLS 707 COMPILE_WITH_DEBUG_SYMBOLS 708 CFLAGS_WARNINGS_ARE_ERRORS 709 BUILD_CC_DISABLE_WARNING_PREFIX 710 DISABLE_WARNING_PREFIX 711 HOTSPOT_SET_WARNINGS_AS_ERRORS 712 WARNINGS_AS_ERRORS 713 COMPILER_SUPPORTS_TARGET_BITS_FLAG 714 ZERO_ARCHFLAG 715 LDFLAGS_TESTEXE 716 LDFLAGS_TESTLIB 717 CXXFLAGS_TESTEXE 718 CXXFLAGS_TESTLIB 719 CFLAGS_TESTEXE 720 CFLAGS_TESTLIB 721 OPENJDK_BUILD_JVM_LIBS 722 OPENJDK_BUILD_JVM_ASFLAGS 723 OPENJDK_BUILD_JVM_LDFLAGS 724 OPENJDK_BUILD_JVM_CFLAGS 725 OPENJDK_BUILD_LDFLAGS_HASH_STYLE 726 OPENJDK_BUILD_LDFLAGS_CXX_JDK 727 OPENJDK_BUILD_JDKEXE_LIBS 728 OPENJDK_BUILD_JDKLIB_LIBS 729 OPENJDK_BUILD_LDFLAGS_JDKEXE 730 OPENJDK_BUILD_LDFLAGS_JDKLIB 731 OPENJDK_BUILD_CXXFLAGS_JDKEXE 732 OPENJDK_BUILD_CXXFLAGS_JDKLIB 733 OPENJDK_BUILD_CFLAGS_JDKEXE 734 OPENJDK_BUILD_CFLAGS_JDKLIB 735 OPENJDK_BUILD_CXXSTD_CXXFLAG 736 JVM_LIBS 737 JVM_ASFLAGS 738 JVM_LDFLAGS 739 JVM_CFLAGS 740 LDFLAGS_HASH_STYLE 741 LDFLAGS_CXX_JDK 742 JDKEXE_LIBS 743 JDKLIB_LIBS 744 LDFLAGS_JDKEXE 745 LDFLAGS_JDKLIB 746 CXXFLAGS_JDKEXE 747 CXXFLAGS_JDKLIB 748 CFLAGS_JDKEXE 749 CFLAGS_JDKLIB 750 MACOSX_VERSION_MIN 751 CXXSTD_CXXFLAG 752 CXX_O_FLAG_SIZE 753 CXX_O_FLAG_NONE 754 CXX_O_FLAG_DEBUG 755 CXX_O_FLAG_NORM 756 CXX_O_FLAG_HI 757 CXX_O_FLAG_HIGHEST 758 CXX_O_FLAG_HIGHEST_JVM 759 C_O_FLAG_SIZE 760 C_O_FLAG_NONE 761 C_O_FLAG_DEBUG 762 C_O_FLAG_NORM 763 C_O_FLAG_HI 764 C_O_FLAG_HIGHEST 765 C_O_FLAG_HIGHEST_JVM 766 JVM_CFLAGS_SYMBOLS 767 CXXFLAGS_DEBUG_SYMBOLS 768 CFLAGS_DEBUG_SYMBOLS 769 CXX_FLAG_DEPS 770 C_FLAG_DEPS 771 SHARED_LIBRARY_FLAGS 772 SET_SHARED_LIBRARY_MAPFILE 773 SET_SHARED_LIBRARY_NAME 774 SET_SHARED_LIBRARY_ORIGIN 775 SET_EXECUTABLE_ORIGIN 776 CXX_FLAG_REORDER 777 C_FLAG_REORDER 778 JVM_RCFLAGS 779 RC_FLAGS 780 AR_OUT_OPTION 781 LD_OUT_OPTION 782 EXE_OUT_OPTION 783 CC_OUT_OPTION 784 STRIPFLAGS 785 ARFLAGS 786 COMPILER_BINDCMD_FILE_FLAG 787 COMPILER_COMMAND_FILE_FLAG 788 COMPILER_TARGET_BITS_FLAG 789 JT_HOME 790 JTREGEXE 791 HOTSPOT_TOOLCHAIN_TYPE 792 USING_BROKEN_SUSE_LD 793 PACKAGE_PATH 794 USE_CLANG 795 HOTSPOT_LD 796 HOTSPOT_CXX 797 HOTSPOT_RC 798 HOTSPOT_MT 799 BUILD_AS 800 BUILD_LDCXX 801 BUILD_LD 802 BUILD_STRIP 803 BUILD_OBJCOPY 804 BUILD_AR 805 BUILD_NM 806 BUILD_CXX 807 BUILD_CC 808 BUILD_SYSROOT_LDFLAGS 809 BUILD_SYSROOT_CFLAGS 810 ac_ct_OBJDUMP 811 OBJDUMP 812 ac_ct_OBJCOPY 813 OBJCOPY 814 ac_ct_NM 815 ac_ct_STRIP 816 GNM 817 NM 818 STRIP 819 MSBUILD 820 DUMPBIN 821 RC 822 MT 823 LIPO 824 ac_ct_AR 825 AR 826 AS 827 LDCXX 828 LD 829 CXXCPP 830 CPP 831 CXX_VERSION_NUMBER 832 CC_VERSION_NUMBER 833 ac_ct_CXX 834 CXXFLAGS 835 CXX 836 TOOLCHAIN_PATH_CXX 837 POTENTIAL_CXX 838 OBJEXT 839 EXEEXT 840 ac_ct_CC 841 CPPFLAGS 842 LDFLAGS 843 CFLAGS 844 CC 845 TOOLCHAIN_PATH_CC 846 POTENTIAL_CC 847 TOOLCHAIN_VERSION 848 VS_LIB 849 VS_INCLUDE 850 VS_PATH 851 CYGWIN_LINK 852 SYSROOT_LDFLAGS 853 SYSROOT_CFLAGS 854 EXTRA_LDFLAGS 855 EXTRA_CXXFLAGS 856 EXTRA_CFLAGS 857 LEGACY_EXTRA_LDFLAGS 858 LEGACY_EXTRA_CXXFLAGS 859 LEGACY_EXTRA_CFLAGS 860 EXE_SUFFIX 861 OBJ_SUFFIX 862 STATIC_LIBRARY 863 SHARED_LIBRARY 864 STATIC_LIBRARY_SUFFIX 865 SHARED_LIBRARY_SUFFIX 866 LIBRARY_PREFIX 867 TOOLCHAIN_TYPE 868 STATIC_BUILD 869 IMPORT_MODULES_MAKE 870 IMPORT_MODULES_SRC 871 IMPORT_MODULES_CONF 872 IMPORT_MODULES_LIBS 873 IMPORT_MODULES_CMDS 874 IMPORT_MODULES_CLASSES 875 BUILD_HOTSPOT 876 HOTSPOT_DIST 877 BUILD_OUTPUT 878 JDK_TOPDIR 879 NASHORN_TOPDIR 880 HOTSPOT_TOPDIR 881 JAXWS_TOPDIR 882 JAXP_TOPDIR 883 CORBA_TOPDIR 884 LANGTOOLS_TOPDIR 885 EXTERNAL_BUILDJDK 886 BUILD_JDK 887 CREATE_BUILDJDK 888 JLINK 889 JMOD 890 BOOT_JDK_BITS 891 JAVAC_FLAGS 892 BOOT_JDK_MODULAR 893 BOOT_JDK_SOURCETARGET 894 JARSIGNER 895 JAR 896 JAVAH 897 JAVAC 898 JAVA 899 BOOT_JDK 900 JAVA_CHECK 901 JAVAC_CHECK 902 VERSION_IS_GA 903 VERSION_SHORT 904 VERSION_STRING 905 VERSION_NUMBER_FOUR_POSITIONS 906 VERSION_NUMBER 907 VERSION_OPT 908 VERSION_BUILD 909 VERSION_PRE 910 VERSION_PATCH 911 VERSION_SECURITY 912 VERSION_MINOR 913 VERSION_MAJOR 914 MACOSX_BUNDLE_ID_BASE 915 MACOSX_BUNDLE_NAME_BASE 916 HOTSPOT_VM_DISTRO 917 COMPANY_NAME 918 JDK_RC_PLATFORM_NAME 919 PRODUCT_SUFFIX 920 PRODUCT_NAME 921 LAUNCHER_NAME 922 JLINK_KEEP_PACKAGED_MODULES 923 COPYRIGHT_YEAR 924 COMPRESS_JARS 925 INCLUDE_SA 926 UNLIMITED_CRYPTO 927 CACERTS_FILE 928 ENABLE_HEADLESS_ONLY 929 DEFAULT_MAKE_TARGET 930 OS_VERSION_MICRO 931 OS_VERSION_MINOR 932 OS_VERSION_MAJOR 933 PKG_CONFIG 934 BASH_ARGS 935 SETFILE 936 CODESIGN 937 XATTR 938 DSYMUTIL 939 IS_GNU_TIME 940 PATCH 941 DTRACE 942 TIME 943 STAT 944 HG 945 READELF 946 OTOOL 947 LDD 948 ZIP 949 UNZIP 950 TAR_SUPPORTS_TRANSFORM 951 TAR_INCLUDE_PARAM 952 TAR_CREATE_EXTRA_PARAM 953 TAR_TYPE 954 FIND_DELETE 955 OUTPUT_SYNC 956 OUTPUT_SYNC_SUPPORTED 957 CHECK_TOOLSDIR_MAKE 958 CHECK_TOOLSDIR_GMAKE 959 CHECK_MAKE 960 CHECK_GMAKE 961 MAKE 962 PKGHANDLER 963 CONFIGURESUPPORT_OUTPUTDIR 964 OUTPUT_ROOT 965 CONF_NAME 966 SPEC 967 SDKROOT 968 XCODEBUILD 969 VALID_JVM_VARIANTS 970 JVM_VARIANTS 971 DEBUG_LEVEL 972 HOTSPOT_DEBUG_LEVEL 973 JDK_VARIANT 974 USERNAME 975 CANONICAL_TOPDIR 976 ORIGINAL_TOPDIR 977 TOPDIR 978 PATH_SEP 979 ZERO_ARCHDEF 980 HOTSPOT_BUILD_CPU_DEFINE 981 HOTSPOT_BUILD_CPU_ARCH 982 HOTSPOT_BUILD_CPU 983 HOTSPOT_BUILD_OS_TYPE 984 HOTSPOT_BUILD_OS 985 OPENJDK_BUILD_BUNDLE_PLATFORM 986 OPENJDK_BUILD_CPU_BUNDLE 987 OPENJDK_BUILD_OS_BUNDLE 988 OPENJDK_BUILD_OS_EXPORT_DIR 989 OPENJDK_BUILD_CPU_JLI_CFLAGS 990 OPENJDK_BUILD_CPU_OSARCH 991 OPENJDK_BUILD_CPU_ISADIR 992 OPENJDK_BUILD_CPU_LIBDIR 993 OPENJDK_BUILD_CPU_LEGACY_LIB 994 OPENJDK_BUILD_CPU_LEGACY 995 HOTSPOT_TARGET_CPU_DEFINE 996 HOTSPOT_TARGET_CPU_ARCH 997 HOTSPOT_TARGET_CPU 998 HOTSPOT_TARGET_OS_TYPE 999 HOTSPOT_TARGET_OS 1000 DEFINE_CROSS_COMPILE_ARCH 1001 LP64 1002 OPENJDK_TARGET_BUNDLE_PLATFORM 1003 OPENJDK_TARGET_CPU_BUNDLE 1004 OPENJDK_TARGET_OS_BUNDLE 1005 OPENJDK_TARGET_OS_EXPORT_DIR 1006 OPENJDK_TARGET_CPU_JLI_CFLAGS 1007 OPENJDK_TARGET_CPU_OSARCH 1008 OPENJDK_TARGET_CPU_ISADIR 1009 OPENJDK_TARGET_CPU_LIBDIR 1010 OPENJDK_TARGET_CPU_LEGACY_LIB 1011 OPENJDK_TARGET_CPU_LEGACY 1012 REQUIRED_OS_VERSION 1013 REQUIRED_OS_NAME 1014 COMPILE_TYPE 1015 OPENJDK_TARGET_CPU_ENDIAN 1016 OPENJDK_TARGET_CPU_BITS 1017 OPENJDK_TARGET_CPU_ARCH 1018 OPENJDK_TARGET_CPU 1019 OPENJDK_TARGET_OS_ENV 1020 OPENJDK_TARGET_OS_TYPE 1021 OPENJDK_TARGET_OS 1022 OPENJDK_BUILD_CPU_ENDIAN 1023 OPENJDK_BUILD_CPU_BITS 1024 OPENJDK_BUILD_CPU_ARCH 1025 OPENJDK_BUILD_CPU 1026 OPENJDK_BUILD_OS_ENV 1027 OPENJDK_BUILD_OS_TYPE 1028 OPENJDK_BUILD_OS 1029 OPENJDK_BUILD_AUTOCONF_NAME 1030 OPENJDK_TARGET_AUTOCONF_NAME 1031 target_os 1032 target_vendor 1033 target_cpu 1034 target 1035 host_os 1036 host_vendor 1037 host_cpu 1038 host 1039 build_os 1040 build_vendor 1041 build_cpu 1042 build 1043 NICE 1044 CPIO 1045 DF 1046 READLINK 1047 CYGPATH 1048 SED 1049 FGREP 1050 EGREP 1051 GREP 1052 AWK 1053 XARGS 1054 WHICH 1055 WC 1056 UNIQ 1057 UNAME 1058 TR 1059 TOUCH 1060 TEE 1061 TAR 1062 TAIL 1063 SORT 1064 SH 1065 RMDIR 1066 RM 1067 PRINTF 1068 NAWK 1069 MV 1070 MKTEMP 1071 MKDIR 1072 LS 1073 LN 1074 GZIP 1075 GUNZIP 1076 HEAD 1077 FIND 1078 FILE 1079 EXPR 1080 ECHO 1081 DIRNAME 1082 DIFF 1083 DATE 1084 CUT 1085 CP 1086 COMM 1087 CMP 1088 CHMOD 1089 CAT 1090 BASH 1091 BASENAME 1092 DATE_WHEN_CONFIGURED 1093 ORIGINAL_PATH 1094 CONFIGURE_COMMAND_LINE 1095 target_alias 1096 host_alias 1097 build_alias 1098 LIBS 1099 ECHO_T 1100 ECHO_N 1101 ECHO_C 1102 DEFS 1103 mandir 1104 localedir 1105 libdir 1106 psdir 1107 pdfdir 1108 dvidir 1109 htmldir 1110 infodir 1111 docdir 1112 oldincludedir 1113 includedir 1114 localstatedir 1115 sharedstatedir 1116 sysconfdir 1117 datadir 1118 datarootdir 1119 libexecdir 1120 sbindir 1121 bindir 1122 program_transform_name 1123 prefix 1124 exec_prefix 1125 PACKAGE_URL 1126 PACKAGE_BUGREPORT 1127 PACKAGE_STRING 1128 PACKAGE_VERSION 1129 PACKAGE_TARNAME 1130 PACKAGE_NAME 1131 PATH_SEPARATOR 1132 SHELL' 1133 ac_subst_files='' 1134 ac_user_opts=' 1135 enable_option_checking 1136 with_target_bits 1137 enable_openjdk_only 1138 with_custom_make_dir 1139 with_jdk_variant 1140 enable_debug 1141 with_debug_level 1142 with_jvm_variants 1143 with_devkit 1144 with_sys_root 1145 with_sysroot 1146 with_tools_dir 1147 with_toolchain_path 1148 with_extra_path 1149 with_sdk_name 1150 with_conf_name 1151 with_output_sync 1152 with_default_make_target 1153 enable_headless_only 1154 with_cacerts_file 1155 enable_unlimited_crypto 1156 with_copyright_year 1157 enable_keep_packaged_modules 1158 with_milestone 1159 with_update_version 1160 with_user_release_suffix 1161 with_build_number 1162 with_version_string 1163 with_version_pre 1164 with_version_opt 1165 with_version_build 1166 with_version_major 1167 with_version_minor 1168 with_version_security 1169 with_version_patch 1170 with_boot_jdk 1171 with_build_jdk 1172 with_add_source_root 1173 with_override_source_root 1174 with_adds_and_overrides 1175 with_override_langtools 1176 with_override_corba 1177 with_override_jaxp 1178 with_override_jaxws 1179 with_override_hotspot 1180 with_override_nashorn 1181 with_override_jdk 1182 with_import_hotspot 1183 with_import_modules 1184 enable_static_build 1185 with_toolchain_type 1186 with_extra_cflags 1187 with_extra_cxxflags 1188 with_extra_ldflags 1189 with_toolchain_version 1190 with_build_devkit 1191 with_jtreg 1192 enable_warnings_as_errors 1193 with_native_debug_symbols 1194 enable_debug_symbols 1195 enable_zip_debug_info 1196 enable_native_coverage 1197 enable_dtrace 1198 with_jvm_features 1199 with_jvm_interpreter 1200 enable_hotspot_gtest 1201 with_stdc__lib 1202 with_msvcr_dll 1203 with_msvcp_dll 1204 with_x 1205 with_cups 1206 with_cups_include 1207 with_freetype 1208 with_freetype_include 1209 with_freetype_lib 1210 with_freetype_src 1211 enable_freetype_bundling 1212 with_alsa 1213 with_alsa_include 1214 with_alsa_lib 1215 with_libffi 1216 with_libffi_include 1217 with_libffi_lib 1218 with_libjpeg 1219 with_giflib 1220 with_libpng 1221 with_zlib 1222 with_lcms 1223 with_dxsdk 1224 with_dxsdk_lib 1225 with_dxsdk_include 1226 enable_jtreg_failure_handler 1227 enable_generate_classlist 1228 with_num_cores 1229 with_memory_size 1230 with_jobs 1231 with_test_jobs 1232 with_boot_jdk_jvmargs 1233 with_sjavac_server_java 1234 enable_sjavac 1235 enable_javac_server 1236 enable_icecc 1237 enable_precompiled_headers 1238 enable_ccache 1239 with_ccache_dir 1240 ' 1241 ac_precious_vars='build_alias 1242 host_alias 1243 target_alias 1244 BASENAME 1245 BASH 1246 CAT 1247 CHMOD 1248 CMP 1249 COMM 1250 CP 1251 CUT 1252 DATE 1253 DIFF 1254 DIRNAME 1255 ECHO 1256 EXPR 1257 FILE 1258 FIND 1259 HEAD 1260 GUNZIP 1261 GZIP 1262 LN 1263 LS 1264 MKDIR 1265 MKTEMP 1266 MV 1267 NAWK 1268 PRINTF 1269 RM 1270 RMDIR 1271 SH 1272 SORT 1273 TAIL 1274 TAR 1275 TEE 1276 TOUCH 1277 TR 1278 UNAME 1279 UNIQ 1280 WC 1281 WHICH 1282 XARGS 1283 AWK 1284 GREP 1285 EGREP 1286 FGREP 1287 SED 1288 CYGPATH 1289 READLINK 1290 DF 1291 CPIO 1292 NICE 1293 MAKE 1294 UNZIP 1295 ZIP 1296 LDD 1297 OTOOL 1298 READELF 1299 HG 1300 STAT 1301 TIME 1302 DTRACE 1303 PATCH 1304 DSYMUTIL 1305 XATTR 1306 CODESIGN 1307 SETFILE 1308 PKG_CONFIG 1309 JAVA 1310 JAVAC 1311 JAVAH 1312 JAR 1313 JARSIGNER 1314 CC 1315 CFLAGS 1316 LDFLAGS 1317 LIBS 1318 CPPFLAGS 1319 CXX 1320 CXXFLAGS 1321 CCC 1322 CPP 1323 CXXCPP 1324 AS 1325 AR 1326 LIPO 1327 STRIP 1328 NM 1329 GNM 1330 OBJCOPY 1331 OBJDUMP 1332 BUILD_CC 1333 BUILD_CXX 1334 BUILD_NM 1335 BUILD_AR 1336 BUILD_OBJCOPY 1337 BUILD_STRIP 1338 JTREGEXE 1339 XMKMF 1340 FREETYPE_CFLAGS 1341 FREETYPE_LIBS 1342 ALSA_CFLAGS 1343 ALSA_LIBS 1344 LIBFFI_CFLAGS 1345 LIBFFI_LIBS 1346 PNG_CFLAGS 1347 PNG_LIBS 1348 LCMS_CFLAGS 1349 LCMS_LIBS 1350 ICECC_CMD 1351 ICECC_CREATE_ENV 1352 ICECC_WRAPPER 1353 CCACHE' 1354 1355 1356 # Initialize some variables set by options. 1357 ac_init_help= 1358 ac_init_version=false 1359 ac_unrecognized_opts= 1360 ac_unrecognized_sep= 1361 # The variables have the same names as the options, with 1362 # dashes changed to underlines. 1363 cache_file=/dev/null 1364 exec_prefix=NONE 1365 no_create= 1366 no_recursion= 1367 prefix=NONE 1368 program_prefix=NONE 1369 program_suffix=NONE 1370 program_transform_name=s,x,x, 1371 silent= 1372 site= 1373 srcdir= 1374 verbose= 1375 x_includes=NONE 1376 x_libraries=NONE 1377 1378 # Installation directory options. 1379 # These are left unexpanded so users can "make install exec_prefix=/foo" 1380 # and all the variables that are supposed to be based on exec_prefix 1381 # by default will actually change. 1382 # Use braces instead of parens because sh, perl, etc. also accept them. 1383 # (The list follows the same order as the GNU Coding Standards.) 1384 bindir='${exec_prefix}/bin' 1385 sbindir='${exec_prefix}/sbin' 1386 libexecdir='${exec_prefix}/libexec' 1387 datarootdir='${prefix}/share' 1388 datadir='${datarootdir}' 1389 sysconfdir='${prefix}/etc' 1390 sharedstatedir='${prefix}/com' 1391 localstatedir='${prefix}/var' 1392 includedir='${prefix}/include' 1393 oldincludedir='/usr/include' 1394 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' 1395 infodir='${datarootdir}/info' 1396 htmldir='${docdir}' 1397 dvidir='${docdir}' 1398 pdfdir='${docdir}' 1399 psdir='${docdir}' 1400 libdir='${exec_prefix}/lib' 1401 localedir='${datarootdir}/locale' 1402 mandir='${datarootdir}/man' 1403 1404 ac_prev= 1405 ac_dashdash= 1406 for ac_option 1407 do 1408 # If the previous option needs an argument, assign it. 1409 if test -n "$ac_prev"; then 1410 eval $ac_prev=\$ac_option 1411 ac_prev= 1412 continue 1413 fi 1414 1415 case $ac_option in 1416 *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; 1417 *=) ac_optarg= ;; 1418 *) ac_optarg=yes ;; 1419 esac 1420 1421 # Accept the important Cygnus configure options, so we can diagnose typos. 1422 1423 case $ac_dashdash$ac_option in 1424 --) 1425 ac_dashdash=yes ;; 1426 1427 -bindir | --bindir | --bindi | --bind | --bin | --bi) 1428 ac_prev=bindir ;; 1429 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) 1430 bindir=$ac_optarg ;; 1431 1432 -build | --build | --buil | --bui | --bu) 1433 ac_prev=build_alias ;; 1434 -build=* | --build=* | --buil=* | --bui=* | --bu=*) 1435 build_alias=$ac_optarg ;; 1436 1437 -cache-file | --cache-file | --cache-fil | --cache-fi \ 1438 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) 1439 ac_prev=cache_file ;; 1440 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ 1441 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) 1442 cache_file=$ac_optarg ;; 1443 1444 --config-cache | -C) 1445 cache_file=config.cache ;; 1446 1447 -datadir | --datadir | --datadi | --datad) 1448 ac_prev=datadir ;; 1449 -datadir=* | --datadir=* | --datadi=* | --datad=*) 1450 datadir=$ac_optarg ;; 1451 1452 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ 1453 | --dataroo | --dataro | --datar) 1454 ac_prev=datarootdir ;; 1455 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ 1456 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) 1457 datarootdir=$ac_optarg ;; 1458 1459 -disable-* | --disable-*) 1460 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` 1461 # Reject names that are not valid shell variable names. 1462 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1463 as_fn_error $? "invalid feature name: $ac_useropt" 1464 ac_useropt_orig=$ac_useropt 1465 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` 1466 case $ac_user_opts in 1467 *" 1468 "enable_$ac_useropt" 1469 "*) ;; 1470 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" 1471 ac_unrecognized_sep=', ';; 1472 esac 1473 eval enable_$ac_useropt=no ;; 1474 1475 -docdir | --docdir | --docdi | --doc | --do) 1476 ac_prev=docdir ;; 1477 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) 1478 docdir=$ac_optarg ;; 1479 1480 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) 1481 ac_prev=dvidir ;; 1482 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) 1483 dvidir=$ac_optarg ;; 1484 1485 -enable-* | --enable-*) 1486 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` 1487 # Reject names that are not valid shell variable names. 1488 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1489 as_fn_error $? "invalid feature name: $ac_useropt" 1490 ac_useropt_orig=$ac_useropt 1491 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` 1492 case $ac_user_opts in 1493 *" 1494 "enable_$ac_useropt" 1495 "*) ;; 1496 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" 1497 ac_unrecognized_sep=', ';; 1498 esac 1499 eval enable_$ac_useropt=\$ac_optarg ;; 1500 1501 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ 1502 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ 1503 | --exec | --exe | --ex) 1504 ac_prev=exec_prefix ;; 1505 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ 1506 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ 1507 | --exec=* | --exe=* | --ex=*) 1508 exec_prefix=$ac_optarg ;; 1509 1510 -gas | --gas | --ga | --g) 1511 # Obsolete; use --with-gas. 1512 with_gas=yes ;; 1513 1514 -help | --help | --hel | --he | -h) 1515 ac_init_help=long ;; 1516 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) 1517 ac_init_help=recursive ;; 1518 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) 1519 ac_init_help=short ;; 1520 1521 -host | --host | --hos | --ho) 1522 ac_prev=host_alias ;; 1523 -host=* | --host=* | --hos=* | --ho=*) 1524 host_alias=$ac_optarg ;; 1525 1526 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) 1527 ac_prev=htmldir ;; 1528 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ 1529 | --ht=*) 1530 htmldir=$ac_optarg ;; 1531 1532 -includedir | --includedir | --includedi | --included | --include \ 1533 | --includ | --inclu | --incl | --inc) 1534 ac_prev=includedir ;; 1535 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ 1536 | --includ=* | --inclu=* | --incl=* | --inc=*) 1537 includedir=$ac_optarg ;; 1538 1539 -infodir | --infodir | --infodi | --infod | --info | --inf) 1540 ac_prev=infodir ;; 1541 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) 1542 infodir=$ac_optarg ;; 1543 1544 -libdir | --libdir | --libdi | --libd) 1545 ac_prev=libdir ;; 1546 -libdir=* | --libdir=* | --libdi=* | --libd=*) 1547 libdir=$ac_optarg ;; 1548 1549 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ 1550 | --libexe | --libex | --libe) 1551 ac_prev=libexecdir ;; 1552 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ 1553 | --libexe=* | --libex=* | --libe=*) 1554 libexecdir=$ac_optarg ;; 1555 1556 -localedir | --localedir | --localedi | --localed | --locale) 1557 ac_prev=localedir ;; 1558 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) 1559 localedir=$ac_optarg ;; 1560 1561 -localstatedir | --localstatedir | --localstatedi | --localstated \ 1562 | --localstate | --localstat | --localsta | --localst | --locals) 1563 ac_prev=localstatedir ;; 1564 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ 1565 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) 1566 localstatedir=$ac_optarg ;; 1567 1568 -mandir | --mandir | --mandi | --mand | --man | --ma | --m) 1569 ac_prev=mandir ;; 1570 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) 1571 mandir=$ac_optarg ;; 1572 1573 -nfp | --nfp | --nf) 1574 # Obsolete; use --without-fp. 1575 with_fp=no ;; 1576 1577 -no-create | --no-create | --no-creat | --no-crea | --no-cre \ 1578 | --no-cr | --no-c | -n) 1579 no_create=yes ;; 1580 1581 -no-recursion | --no-recursion | --no-recursio | --no-recursi \ 1582 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) 1583 no_recursion=yes ;; 1584 1585 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ 1586 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ 1587 | --oldin | --oldi | --old | --ol | --o) 1588 ac_prev=oldincludedir ;; 1589 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ 1590 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ 1591 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) 1592 oldincludedir=$ac_optarg ;; 1593 1594 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) 1595 ac_prev=prefix ;; 1596 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) 1597 prefix=$ac_optarg ;; 1598 1599 -program-prefix | --program-prefix | --program-prefi | --program-pref \ 1600 | --program-pre | --program-pr | --program-p) 1601 ac_prev=program_prefix ;; 1602 -program-prefix=* | --program-prefix=* | --program-prefi=* \ 1603 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) 1604 program_prefix=$ac_optarg ;; 1605 1606 -program-suffix | --program-suffix | --program-suffi | --program-suff \ 1607 | --program-suf | --program-su | --program-s) 1608 ac_prev=program_suffix ;; 1609 -program-suffix=* | --program-suffix=* | --program-suffi=* \ 1610 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) 1611 program_suffix=$ac_optarg ;; 1612 1613 -program-transform-name | --program-transform-name \ 1614 | --program-transform-nam | --program-transform-na \ 1615 | --program-transform-n | --program-transform- \ 1616 | --program-transform | --program-transfor \ 1617 | --program-transfo | --program-transf \ 1618 | --program-trans | --program-tran \ 1619 | --progr-tra | --program-tr | --program-t) 1620 ac_prev=program_transform_name ;; 1621 -program-transform-name=* | --program-transform-name=* \ 1622 | --program-transform-nam=* | --program-transform-na=* \ 1623 | --program-transform-n=* | --program-transform-=* \ 1624 | --program-transform=* | --program-transfor=* \ 1625 | --program-transfo=* | --program-transf=* \ 1626 | --program-trans=* | --program-tran=* \ 1627 | --progr-tra=* | --program-tr=* | --program-t=*) 1628 program_transform_name=$ac_optarg ;; 1629 1630 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) 1631 ac_prev=pdfdir ;; 1632 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) 1633 pdfdir=$ac_optarg ;; 1634 1635 -psdir | --psdir | --psdi | --psd | --ps) 1636 ac_prev=psdir ;; 1637 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) 1638 psdir=$ac_optarg ;; 1639 1640 -q | -quiet | --quiet | --quie | --qui | --qu | --q \ 1641 | -silent | --silent | --silen | --sile | --sil) 1642 silent=yes ;; 1643 1644 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) 1645 ac_prev=sbindir ;; 1646 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ 1647 | --sbi=* | --sb=*) 1648 sbindir=$ac_optarg ;; 1649 1650 -sharedstatedir | --sharedstatedir | --sharedstatedi \ 1651 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ 1652 | --sharedst | --shareds | --shared | --share | --shar \ 1653 | --sha | --sh) 1654 ac_prev=sharedstatedir ;; 1655 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ 1656 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ 1657 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ 1658 | --sha=* | --sh=*) 1659 sharedstatedir=$ac_optarg ;; 1660 1661 -site | --site | --sit) 1662 ac_prev=site ;; 1663 -site=* | --site=* | --sit=*) 1664 site=$ac_optarg ;; 1665 1666 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) 1667 ac_prev=srcdir ;; 1668 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) 1669 srcdir=$ac_optarg ;; 1670 1671 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ 1672 | --syscon | --sysco | --sysc | --sys | --sy) 1673 ac_prev=sysconfdir ;; 1674 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ 1675 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) 1676 sysconfdir=$ac_optarg ;; 1677 1678 -target | --target | --targe | --targ | --tar | --ta | --t) 1679 ac_prev=target_alias ;; 1680 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) 1681 target_alias=$ac_optarg ;; 1682 1683 -v | -verbose | --verbose | --verbos | --verbo | --verb) 1684 verbose=yes ;; 1685 1686 -version | --version | --versio | --versi | --vers | -V) 1687 ac_init_version=: ;; 1688 1689 -with-* | --with-*) 1690 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` 1691 # Reject names that are not valid shell variable names. 1692 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1693 as_fn_error $? "invalid package name: $ac_useropt" 1694 ac_useropt_orig=$ac_useropt 1695 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` 1696 case $ac_user_opts in 1697 *" 1698 "with_$ac_useropt" 1699 "*) ;; 1700 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" 1701 ac_unrecognized_sep=', ';; 1702 esac 1703 eval with_$ac_useropt=\$ac_optarg ;; 1704 1705 -without-* | --without-*) 1706 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` 1707 # Reject names that are not valid shell variable names. 1708 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1709 as_fn_error $? "invalid package name: $ac_useropt" 1710 ac_useropt_orig=$ac_useropt 1711 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` 1712 case $ac_user_opts in 1713 *" 1714 "with_$ac_useropt" 1715 "*) ;; 1716 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" 1717 ac_unrecognized_sep=', ';; 1718 esac 1719 eval with_$ac_useropt=no ;; 1720 1721 --x) 1722 # Obsolete; use --with-x. 1723 with_x=yes ;; 1724 1725 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ 1726 | --x-incl | --x-inc | --x-in | --x-i) 1727 ac_prev=x_includes ;; 1728 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ 1729 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) 1730 x_includes=$ac_optarg ;; 1731 1732 -x-libraries | --x-libraries | --x-librarie | --x-librari \ 1733 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) 1734 ac_prev=x_libraries ;; 1735 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ 1736 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) 1737 x_libraries=$ac_optarg ;; 1738 1739 -*) as_fn_error $? "unrecognized option: \`$ac_option' 1740 Try \`$0 --help' for more information" 1741 ;; 1742 1743 *=*) 1744 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` 1745 # Reject names that are not valid shell variable names. 1746 case $ac_envvar in #( 1747 '' | [0-9]* | *[!_$as_cr_alnum]* ) 1748 as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; 1749 esac 1750 eval $ac_envvar=\$ac_optarg 1751 export $ac_envvar ;; 1752 1753 *) 1754 # FIXME: should be removed in autoconf 3.0. 1755 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 1756 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && 1757 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 1758 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}" 1759 ;; 1760 1761 esac 1762 done 1763 1764 if test -n "$ac_prev"; then 1765 ac_option=--`echo $ac_prev | sed 's/_/-/g'` 1766 as_fn_error $? "missing argument to $ac_option" 1767 fi 1768 1769 if test -n "$ac_unrecognized_opts"; then 1770 case $enable_option_checking in 1771 no) ;; 1772 fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; 1773 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; 1774 esac 1775 fi 1776 1777 # Check all directory arguments for consistency. 1778 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ 1779 datadir sysconfdir sharedstatedir localstatedir includedir \ 1780 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ 1781 libdir localedir mandir 1782 do 1783 eval ac_val=\$$ac_var 1784 # Remove trailing slashes. 1785 case $ac_val in 1786 */ ) 1787 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` 1788 eval $ac_var=\$ac_val;; 1789 esac 1790 # Be sure to have absolute directory names. 1791 case $ac_val in 1792 [\\/$]* | ?:[\\/]* ) continue;; 1793 NONE | '' ) case $ac_var in *prefix ) continue;; esac;; 1794 esac 1795 as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val" 1796 done 1797 1798 # There might be people who depend on the old broken behavior: `$host' 1799 # used to hold the argument of --host etc. 1800 # FIXME: To remove some day. 1801 build=$build_alias 1802 host=$host_alias 1803 target=$target_alias 1804 1805 # FIXME: To remove some day. 1806 if test "x$host_alias" != x; then 1807 if test "x$build_alias" = x; then 1808 cross_compiling=maybe 1809 elif test "x$build_alias" != "x$host_alias"; then 1810 cross_compiling=yes 1811 fi 1812 fi 1813 1814 ac_tool_prefix= 1815 test -n "$host_alias" && ac_tool_prefix=$host_alias- 1816 1817 test "$silent" = yes && exec 6>/dev/null 1818 1819 1820 ac_pwd=`pwd` && test -n "$ac_pwd" && 1821 ac_ls_di=`ls -di .` && 1822 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || 1823 as_fn_error $? "working directory cannot be determined" 1824 test "X$ac_ls_di" = "X$ac_pwd_ls_di" || 1825 as_fn_error $? "pwd does not report name of working directory" 1826 1827 1828 # Find the source files, if location was not specified. 1829 if test -z "$srcdir"; then 1830 ac_srcdir_defaulted=yes 1831 # Try the directory containing this script, then the parent directory. 1832 ac_confdir=`$as_dirname -- "$as_myself" || 1833 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 1834 X"$as_myself" : 'X\(//\)[^/]' \| \ 1835 X"$as_myself" : 'X\(//\)$' \| \ 1836 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || 1837 $as_echo X"$as_myself" | 1838 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 1839 s//\1/ 1840 q 1841 } 1842 /^X\(\/\/\)[^/].*/{ 1843 s//\1/ 1844 q 1845 } 1846 /^X\(\/\/\)$/{ 1847 s//\1/ 1848 q 1849 } 1850 /^X\(\/\).*/{ 1851 s//\1/ 1852 q 1853 } 1854 s/.*/./; q'` 1855 srcdir=$ac_confdir 1856 if test ! -r "$srcdir/$ac_unique_file"; then 1857 srcdir=.. 1858 fi 1859 else 1860 ac_srcdir_defaulted=no 1861 fi 1862 if test ! -r "$srcdir/$ac_unique_file"; then 1863 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." 1864 as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" 1865 fi 1866 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" 1867 ac_abs_confdir=`( 1868 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" 1869 pwd)` 1870 # When building in place, set srcdir=. 1871 if test "$ac_abs_confdir" = "$ac_pwd"; then 1872 srcdir=. 1873 fi 1874 # Remove unnecessary trailing slashes from srcdir. 1875 # Double slashes in file names in object file debugging info 1876 # mess up M-x gdb in Emacs. 1877 case $srcdir in 1878 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; 1879 esac 1880 for ac_var in $ac_precious_vars; do 1881 eval ac_env_${ac_var}_set=\${${ac_var}+set} 1882 eval ac_env_${ac_var}_value=\$${ac_var} 1883 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} 1884 eval ac_cv_env_${ac_var}_value=\$${ac_var} 1885 done 1886 1887 # 1888 # Report the --help message. 1889 # 1890 if test "$ac_init_help" = "long"; then 1891 # Omit some internal or obsolete options to make the list less imposing. 1892 # This message is too long to be a string in the A/UX 3.1 sh. 1893 cat <<_ACEOF 1894 \`configure' configures OpenJDK jdk9 to adapt to many kinds of systems. 1895 1896 Usage: $0 [OPTION]... [VAR=VALUE]... 1897 1898 To assign environment variables (e.g., CC, CFLAGS...), specify them as 1899 VAR=VALUE. See below for descriptions of some of the useful variables. 1900 1901 Defaults for the options are specified in brackets. 1902 1903 Configuration: 1904 -h, --help display this help and exit 1905 --help=short display options specific to this package 1906 --help=recursive display the short help of all the included packages 1907 -V, --version display version information and exit 1908 -q, --quiet, --silent do not print \`checking ...' messages 1909 --cache-file=FILE cache test results in FILE [disabled] 1910 -C, --config-cache alias for \`--cache-file=config.cache' 1911 -n, --no-create do not create output files 1912 --srcdir=DIR find the sources in DIR [configure dir or \`..'] 1913 1914 Installation directories: 1915 --prefix=PREFIX install architecture-independent files in PREFIX 1916 [$ac_default_prefix] 1917 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX 1918 [PREFIX] 1919 1920 By default, \`make install' will install all the files in 1921 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify 1922 an installation prefix other than \`$ac_default_prefix' using \`--prefix', 1923 for instance \`--prefix=\$HOME'. 1924 1925 For better control, use the options below. 1926 1927 Fine tuning of the installation directories: 1928 --bindir=DIR user executables [EPREFIX/bin] 1929 --sbindir=DIR system admin executables [EPREFIX/sbin] 1930 --libexecdir=DIR program executables [EPREFIX/libexec] 1931 --sysconfdir=DIR read-only single-machine data [PREFIX/etc] 1932 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] 1933 --localstatedir=DIR modifiable single-machine data [PREFIX/var] 1934 --libdir=DIR object code libraries [EPREFIX/lib] 1935 --includedir=DIR C header files [PREFIX/include] 1936 --oldincludedir=DIR C header files for non-gcc [/usr/include] 1937 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] 1938 --datadir=DIR read-only architecture-independent data [DATAROOTDIR] 1939 --infodir=DIR info documentation [DATAROOTDIR/info] 1940 --localedir=DIR locale-dependent data [DATAROOTDIR/locale] 1941 --mandir=DIR man documentation [DATAROOTDIR/man] 1942 --docdir=DIR documentation root [DATAROOTDIR/doc/openjdk] 1943 --htmldir=DIR html documentation [DOCDIR] 1944 --dvidir=DIR dvi documentation [DOCDIR] 1945 --pdfdir=DIR pdf documentation [DOCDIR] 1946 --psdir=DIR ps documentation [DOCDIR] 1947 _ACEOF 1948 1949 cat <<\_ACEOF 1950 1951 X features: 1952 --x-includes=DIR X include files are in DIR 1953 --x-libraries=DIR X library files are in DIR 1954 1955 System types: 1956 --build=BUILD configure for building on BUILD [guessed] 1957 --host=HOST cross-compile to build programs to run on HOST [BUILD] 1958 --target=TARGET configure for building compilers for TARGET [HOST] 1959 _ACEOF 1960 fi 1961 1962 if test -n "$ac_init_help"; then 1963 case $ac_init_help in 1964 short | recursive ) echo "Configuration of OpenJDK jdk9:";; 1965 esac 1966 cat <<\_ACEOF 1967 1968 Optional Features: 1969 --disable-option-checking ignore unrecognized --enable/--with options 1970 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) 1971 --enable-FEATURE[=ARG] include FEATURE [ARG=yes] 1972 --enable-openjdk-only suppress building custom source even if present 1973 [disabled] 1974 --enable-debug set the debug level to fastdebug (shorthand for 1975 --with-debug-level=fastdebug) [disabled] 1976 --enable-headless-only only build headless (no GUI) support [disabled] 1977 --enable-unlimited-crypto 1978 Enable unlimited crypto policy [disabled] 1979 --disable-keep-packaged-modules 1980 Do not keep packaged modules in jdk image [enable] 1981 --enable-static-build enable static library build [disabled] 1982 --disable-warnings-as-errors 1983 do not consider native warnings to be an error 1984 [enabled] 1985 --enable-debug-symbols Deprecated. Option is kept for backwards 1986 compatibility and is ignored 1987 --enable-zip-debug-info Deprecated. Option is kept for backwards 1988 compatibility and is ignored 1989 --enable-native-coverage 1990 enable native compilation with code coverage 1991 data[disabled] 1992 --enable-dtrace[=yes/no/auto] 1993 enable dtrace. Default is auto, where dtrace is 1994 enabled if all dependencies are present. 1995 --disable-hotspot-gtest Disables building of the Hotspot unit tests 1996 --disable-freetype-bundling 1997 disable bundling of the freetype library with the 1998 build result [enabled on Windows or when using 1999 --with-freetype, disabled otherwise] 2000 --enable-jtreg-failure-handler 2001 forces build of the jtreg failure handler to be 2002 enabled, missing dependencies become fatal errors. 2003 Default is auto, where the failure handler is built 2004 if all dependencies are present and otherwise just 2005 disabled. 2006 --disable-generate-classlist 2007 forces enabling or disabling of the generation of a 2008 CDS classlist at build time. Default is to generate 2009 it when either the server or client JVMs are built. 2010 --enable-sjavac use sjavac to do fast incremental compiles 2011 [disabled] 2012 --disable-javac-server disable javac server [enabled] 2013 --enable-icecc enable distribted compilation of native code using 2014 icecc/icecream [disabled] 2015 --disable-precompiled-headers 2016 disable using precompiled headers when compiling C++ 2017 [enabled] 2018 --enable-ccache enable using ccache to speed up recompilations 2019 [disabled] 2020 2021 Optional Packages: 2022 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] 2023 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) 2024 --with-target-bits build 32-bit or 64-bit binaries (for platforms that 2025 support it), e.g. --with-target-bits=32 [guessed] 2026 --with-custom-make-dir Deprecated. Option is kept for backwards 2027 compatibility and is ignored 2028 --with-jdk-variant JDK variant to build (normal) [normal] 2029 --with-debug-level set the debug level (release, fastdebug, slowdebug, 2030 optimized) [release] 2031 --with-jvm-variants JVM variants (separated by commas) to build 2032 (server,client,minimal,core,zero,zeroshark,custom) 2033 [server] 2034 --with-devkit use this devkit for compilers, tools and resources 2035 --with-sys-root alias for --with-sysroot for backwards compatability 2036 --with-sysroot use this directory as sysroot 2037 --with-tools-dir alias for --with-toolchain-path for backwards 2038 compatibility 2039 --with-toolchain-path prepend these directories when searching for 2040 toolchain binaries (compilers etc) 2041 --with-extra-path prepend these directories to the default path 2042 --with-sdk-name use the platform SDK of the given name. [macosx] 2043 --with-conf-name use this as the name of the configuration [generated 2044 from important configuration options] 2045 --with-output-sync set make output sync type if supported by make. 2046 [recurse] 2047 --with-default-make-target 2048 set the default make target [exploded-image] 2049 --with-cacerts-file specify alternative cacerts file 2050 --with-copyright-year Set copyright year value for build [current year] 2051 --with-milestone Deprecated. Option is kept for backwards 2052 compatibility and is ignored 2053 --with-update-version Deprecated. Option is kept for backwards 2054 compatibility and is ignored 2055 --with-user-release-suffix 2056 Deprecated. Option is kept for backwards 2057 compatibility and is ignored 2058 --with-build-number Deprecated. Option is kept for backwards 2059 compatibility and is ignored 2060 --with-version-string Set version string [calculated] 2061 --with-version-pre Set the base part of the version 'PRE' field 2062 (pre-release identifier) ['internal'] 2063 --with-version-opt Set version 'OPT' field (build metadata) 2064 [<timestamp>.<user>.<dirname>] 2065 --with-version-build Set version 'BUILD' field (build number) [not 2066 specified] 2067 --with-version-major Set version 'MAJOR' field (first number) [current 2068 source value] 2069 --with-version-minor Set version 'MINOR' field (second number) [current 2070 source value] 2071 --with-version-security Set version 'SECURITY' field (third number) [current 2072 source value] 2073 --with-version-patch Set version 'PATCH' field (fourth number) [not 2074 specified] 2075 --with-boot-jdk path to Boot JDK (used to bootstrap build) [probed] 2076 --with-build-jdk path to JDK of same version as is being built[the 2077 newly built JDK] 2078 --with-add-source-root Deprecated. Option is kept for backwards 2079 compatibility and is ignored 2080 --with-override-source-root 2081 Deprecated. Option is kept for backwards 2082 compatibility and is ignored 2083 --with-adds-and-overrides 2084 Deprecated. Option is kept for backwards 2085 compatibility and is ignored 2086 --with-override-langtools 2087 Deprecated. Option is kept for backwards 2088 compatibility and is ignored 2089 --with-override-corba Deprecated. Option is kept for backwards 2090 compatibility and is ignored 2091 --with-override-jaxp Deprecated. Option is kept for backwards 2092 compatibility and is ignored 2093 --with-override-jaxws Deprecated. Option is kept for backwards 2094 compatibility and is ignored 2095 --with-override-hotspot Deprecated. Option is kept for backwards 2096 compatibility and is ignored 2097 --with-override-nashorn Deprecated. Option is kept for backwards 2098 compatibility and is ignored 2099 --with-override-jdk Deprecated. Option is kept for backwards 2100 compatibility and is ignored 2101 --with-import-hotspot import hotspot binaries from this jdk image or 2102 hotspot build dist dir instead of building from 2103 source 2104 --with-import-modules import a set of prebuilt modules either as a zip 2105 file or an exploded directory 2106 --with-toolchain-type the toolchain type (or family) to use, use '--help' 2107 to show possible values [platform dependent] 2108 --with-extra-cflags extra flags to be used when compiling jdk c-files 2109 --with-extra-cxxflags extra flags to be used when compiling jdk c++-files 2110 --with-extra-ldflags extra flags to be used when linking jdk 2111 --with-toolchain-version 2112 the version of the toolchain to look for, use 2113 '--help' to show possible values [platform 2114 dependent] 2115 --with-build-devkit Devkit to use for the build platform toolchain 2116 --with-jtreg Regression Test Harness [probed] 2117 --with-native-debug-symbols 2118 set the native debug symbol configuration (none, 2119 internal, external, zipped) [varying] 2120 --with-jvm-features additional JVM features to enable (separated by 2121 comma), use '--help' to show possible values [none] 2122 --with-jvm-interpreter Deprecated. Option is kept for backwards 2123 compatibility and is ignored 2124 --with-stdc++lib=<static>,<dynamic>,<default> 2125 force linking of the C++ runtime on Linux to either 2126 static or dynamic, default is static with dynamic as 2127 fallback 2128 --with-msvcr-dll path to microsoft C runtime dll (msvcr*.dll) 2129 (Windows only) [probed] 2130 --with-msvcp-dll path to microsoft C++ runtime dll (msvcp*.dll) 2131 (Windows only) [probed] 2132 --with-x use the X Window System 2133 --with-cups specify prefix directory for the cups package 2134 (expecting the headers under PATH/include) 2135 --with-cups-include specify directory for the cups include files 2136 --with-freetype specify prefix directory for the freetype package 2137 (expecting the libraries under PATH/lib and the 2138 headers under PATH/include) 2139 --with-freetype-include specify directory for the freetype include files 2140 --with-freetype-lib specify directory for the freetype library 2141 --with-freetype-src specify directory with freetype sources to 2142 automatically build the library (experimental, 2143 Windows-only) 2144 --with-alsa specify prefix directory for the alsa package 2145 (expecting the libraries under PATH/lib and the 2146 headers under PATH/include) 2147 --with-alsa-include specify directory for the alsa include files 2148 --with-alsa-lib specify directory for the alsa library 2149 --with-libffi specify prefix directory for the libffi package 2150 (expecting the libraries under PATH/lib and the 2151 headers under PATH/include) 2152 --with-libffi-include specify directory for the libffi include files 2153 --with-libffi-lib specify directory for the libffi library 2154 --with-libjpeg use libjpeg from build system or OpenJDK source 2155 (system, bundled) [bundled] 2156 --with-giflib use giflib from build system or OpenJDK source 2157 (system, bundled) [bundled] 2158 --with-libpng use libpng from build system or OpenJDK source 2159 (system, bundled) [bundled] 2160 --with-zlib use zlib from build system or OpenJDK source 2161 (system, bundled) [bundled] 2162 --with-lcms use lcms2 from build system or OpenJDK source 2163 (system, bundled) [bundled] 2164 --with-dxsdk Deprecated. Option is kept for backwards 2165 compatibility and is ignored 2166 --with-dxsdk-lib Deprecated. Option is kept for backwards 2167 compatibility and is ignored 2168 --with-dxsdk-include Deprecated. Option is kept for backwards 2169 compatibility and is ignored 2170 --with-num-cores number of cores in the build system, e.g. 2171 --with-num-cores=8 [probed] 2172 --with-memory-size memory (in MB) available in the build system, e.g. 2173 --with-memory-size=1024 [probed] 2174 --with-jobs number of parallel jobs to let make run [calculated 2175 based on cores and memory] 2176 --with-test-jobs number of parallel tests jobs to run [based on build 2177 jobs] 2178 --with-boot-jdk-jvmargs specify JVM arguments to be passed to all java 2179 invocations of boot JDK, overriding the default 2180 values, e.g --with-boot-jdk-jvmargs="-Xmx8G 2181 -enableassertions" 2182 --with-sjavac-server-java 2183 use this java binary for running the sjavac 2184 background server [Boot JDK java] 2185 --with-ccache-dir where to store ccache files [~/.ccache] 2186 2187 Some influential environment variables: 2188 BASENAME Override default value for BASENAME 2189 BASH Override default value for BASH 2190 CAT Override default value for CAT 2191 CHMOD Override default value for CHMOD 2192 CMP Override default value for CMP 2193 COMM Override default value for COMM 2194 CP Override default value for CP 2195 CUT Override default value for CUT 2196 DATE Override default value for DATE 2197 DIFF Override default value for DIFF 2198 DIRNAME Override default value for DIRNAME 2199 ECHO Override default value for ECHO 2200 EXPR Override default value for EXPR 2201 FILE Override default value for FILE 2202 FIND Override default value for FIND 2203 HEAD Override default value for HEAD 2204 GUNZIP Override default value for GUNZIP 2205 GZIP Override default value for GZIP 2206 LN Override default value for LN 2207 LS Override default value for LS 2208 MKDIR Override default value for MKDIR 2209 MKTEMP Override default value for MKTEMP 2210 MV Override default value for MV 2211 NAWK Override default value for NAWK 2212 PRINTF Override default value for PRINTF 2213 RM Override default value for RM 2214 RMDIR Override default value for RMDIR 2215 SH Override default value for SH 2216 SORT Override default value for SORT 2217 TAIL Override default value for TAIL 2218 TAR Override default value for TAR 2219 TEE Override default value for TEE 2220 TOUCH Override default value for TOUCH 2221 TR Override default value for TR 2222 UNAME Override default value for UNAME 2223 UNIQ Override default value for UNIQ 2224 WC Override default value for WC 2225 WHICH Override default value for WHICH 2226 XARGS Override default value for XARGS 2227 AWK Override default value for AWK 2228 GREP Override default value for GREP 2229 EGREP Override default value for EGREP 2230 FGREP Override default value for FGREP 2231 SED Override default value for SED 2232 CYGPATH Override default value for CYGPATH 2233 READLINK Override default value for READLINK 2234 DF Override default value for DF 2235 CPIO Override default value for CPIO 2236 NICE Override default value for NICE 2237 MAKE Override default value for MAKE 2238 UNZIP Override default value for UNZIP 2239 ZIP Override default value for ZIP 2240 LDD Override default value for LDD 2241 OTOOL Override default value for OTOOL 2242 READELF Override default value for READELF 2243 HG Override default value for HG 2244 STAT Override default value for STAT 2245 TIME Override default value for TIME 2246 DTRACE Override default value for DTRACE 2247 PATCH Override default value for PATCH 2248 DSYMUTIL Override default value for DSYMUTIL 2249 XATTR Override default value for XATTR 2250 CODESIGN Override default value for CODESIGN 2251 SETFILE Override default value for SETFILE 2252 PKG_CONFIG path to pkg-config utility 2253 JAVA Override default value for JAVA 2254 JAVAC Override default value for JAVAC 2255 JAVAH Override default value for JAVAH 2256 JAR Override default value for JAR 2257 JARSIGNER Override default value for JARSIGNER 2258 CC C compiler command 2259 CFLAGS C compiler flags 2260 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a 2261 nonstandard directory <lib dir> 2262 LIBS libraries to pass to the linker, e.g. -l<library> 2263 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if 2264 you have headers in a nonstandard directory <include dir> 2265 CXX C++ compiler command 2266 CXXFLAGS C++ compiler flags 2267 CPP C preprocessor 2268 CXXCPP C++ preprocessor 2269 AS Override default value for AS 2270 AR Override default value for AR 2271 LIPO Override default value for LIPO 2272 STRIP Override default value for STRIP 2273 NM Override default value for NM 2274 GNM Override default value for GNM 2275 OBJCOPY Override default value for OBJCOPY 2276 OBJDUMP Override default value for OBJDUMP 2277 BUILD_CC Override default value for BUILD_CC 2278 BUILD_CXX Override default value for BUILD_CXX 2279 BUILD_NM Override default value for BUILD_NM 2280 BUILD_AR Override default value for BUILD_AR 2281 BUILD_OBJCOPY 2282 Override default value for BUILD_OBJCOPY 2283 BUILD_STRIP Override default value for BUILD_STRIP 2284 JTREGEXE Override default value for JTREGEXE 2285 XMKMF Path to xmkmf, Makefile generator for X Window System 2286 FREETYPE_CFLAGS 2287 C compiler flags for FREETYPE, overriding pkg-config 2288 FREETYPE_LIBS 2289 linker flags for FREETYPE, overriding pkg-config 2290 ALSA_CFLAGS C compiler flags for ALSA, overriding pkg-config 2291 ALSA_LIBS linker flags for ALSA, overriding pkg-config 2292 LIBFFI_CFLAGS 2293 C compiler flags for LIBFFI, overriding pkg-config 2294 LIBFFI_LIBS linker flags for LIBFFI, overriding pkg-config 2295 PNG_CFLAGS C compiler flags for PNG, overriding pkg-config 2296 PNG_LIBS linker flags for PNG, overriding pkg-config 2297 LCMS_CFLAGS C compiler flags for LCMS, overriding pkg-config 2298 LCMS_LIBS linker flags for LCMS, overriding pkg-config 2299 ICECC_CMD Override default value for ICECC_CMD 2300 ICECC_CREATE_ENV 2301 Override default value for ICECC_CREATE_ENV 2302 ICECC_WRAPPER 2303 Override default value for ICECC_WRAPPER 2304 CCACHE Override default value for CCACHE 2305 2306 Use these variables to override the choices made by `configure' or to help 2307 it to find libraries and programs with nonstandard names/locations. 2308 2309 Report bugs to <build-dev@openjdk.java.net>. 2310 OpenJDK home page: <http://openjdk.java.net>. 2311 _ACEOF 2312 ac_status=$? 2313 fi 2314 2315 if test "$ac_init_help" = "recursive"; then 2316 # If there are subdirs, report their specific --help. 2317 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue 2318 test -d "$ac_dir" || 2319 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || 2320 continue 2321 ac_builddir=. 2322 2323 case "$ac_dir" in 2324 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; 2325 *) 2326 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` 2327 # A ".." for each directory in $ac_dir_suffix. 2328 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` 2329 case $ac_top_builddir_sub in 2330 "") ac_top_builddir_sub=. ac_top_build_prefix= ;; 2331 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; 2332 esac ;; 2333 esac 2334 ac_abs_top_builddir=$ac_pwd 2335 ac_abs_builddir=$ac_pwd$ac_dir_suffix 2336 # for backward compatibility: 2337 ac_top_builddir=$ac_top_build_prefix 2338 2339 case $srcdir in 2340 .) # We are building in place. 2341 ac_srcdir=. 2342 ac_top_srcdir=$ac_top_builddir_sub 2343 ac_abs_top_srcdir=$ac_pwd ;; 2344 [\\/]* | ?:[\\/]* ) # Absolute name. 2345 ac_srcdir=$srcdir$ac_dir_suffix; 2346 ac_top_srcdir=$srcdir 2347 ac_abs_top_srcdir=$srcdir ;; 2348 *) # Relative name. 2349 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix 2350 ac_top_srcdir=$ac_top_build_prefix$srcdir 2351 ac_abs_top_srcdir=$ac_pwd/$srcdir ;; 2352 esac 2353 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix 2354 2355 cd "$ac_dir" || { ac_status=$?; continue; } 2356 # Check for guested configure. 2357 if test -f "$ac_srcdir/configure.gnu"; then 2358 echo && 2359 $SHELL "$ac_srcdir/configure.gnu" --help=recursive 2360 elif test -f "$ac_srcdir/configure"; then 2361 echo && 2362 $SHELL "$ac_srcdir/configure" --help=recursive 2363 else 2364 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 2365 fi || ac_status=$? 2366 cd "$ac_pwd" || { ac_status=$?; break; } 2367 done 2368 fi 2369 2370 test -n "$ac_init_help" && exit $ac_status 2371 if $ac_init_version; then 2372 cat <<\_ACEOF 2373 OpenJDK configure jdk9 2374 generated by GNU Autoconf 2.69 2375 2376 Copyright (C) 2012 Free Software Foundation, Inc. 2377 This configure script is free software; the Free Software Foundation 2378 gives unlimited permission to copy, distribute and modify it. 2379 _ACEOF 2380 exit 2381 fi 2382 2383 ## ------------------------ ## 2384 ## Autoconf initialization. ## 2385 ## ------------------------ ## 2386 2387 # ac_fn_c_try_compile LINENO 2388 # -------------------------- 2389 # Try to compile conftest.$ac_ext, and return whether this succeeded. 2390 ac_fn_c_try_compile () 2391 { 2392 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2393 rm -f conftest.$ac_objext 2394 if { { ac_try="$ac_compile" 2395 case "(($ac_try" in 2396 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2397 *) ac_try_echo=$ac_try;; 2398 esac 2399 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2400 $as_echo "$ac_try_echo"; } >&5 2401 (eval "$ac_compile") 2>conftest.err 2402 ac_status=$? 2403 if test -s conftest.err; then 2404 grep -v '^ *+' conftest.err >conftest.er1 2405 cat conftest.er1 >&5 2406 mv -f conftest.er1 conftest.err 2407 fi 2408 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2409 test $ac_status = 0; } && { 2410 test -z "$ac_c_werror_flag" || 2411 test ! -s conftest.err 2412 } && test -s conftest.$ac_objext; then : 2413 ac_retval=0 2414 else 2415 $as_echo "$as_me: failed program was:" >&5 2416 sed 's/^/| /' conftest.$ac_ext >&5 2417 2418 ac_retval=1 2419 fi 2420 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2421 as_fn_set_status $ac_retval 2422 2423 } # ac_fn_c_try_compile 2424 2425 # ac_fn_cxx_try_compile LINENO 2426 # ---------------------------- 2427 # Try to compile conftest.$ac_ext, and return whether this succeeded. 2428 ac_fn_cxx_try_compile () 2429 { 2430 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2431 rm -f conftest.$ac_objext 2432 if { { ac_try="$ac_compile" 2433 case "(($ac_try" in 2434 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2435 *) ac_try_echo=$ac_try;; 2436 esac 2437 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2438 $as_echo "$ac_try_echo"; } >&5 2439 (eval "$ac_compile") 2>conftest.err 2440 ac_status=$? 2441 if test -s conftest.err; then 2442 grep -v '^ *+' conftest.err >conftest.er1 2443 cat conftest.er1 >&5 2444 mv -f conftest.er1 conftest.err 2445 fi 2446 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2447 test $ac_status = 0; } && { 2448 test -z "$ac_cxx_werror_flag" || 2449 test ! -s conftest.err 2450 } && test -s conftest.$ac_objext; then : 2451 ac_retval=0 2452 else 2453 $as_echo "$as_me: failed program was:" >&5 2454 sed 's/^/| /' conftest.$ac_ext >&5 2455 2456 ac_retval=1 2457 fi 2458 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2459 as_fn_set_status $ac_retval 2460 2461 } # ac_fn_cxx_try_compile 2462 2463 # ac_fn_c_try_cpp LINENO 2464 # ---------------------- 2465 # Try to preprocess conftest.$ac_ext, and return whether this succeeded. 2466 ac_fn_c_try_cpp () 2467 { 2468 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2469 if { { ac_try="$ac_cpp conftest.$ac_ext" 2470 case "(($ac_try" in 2471 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2472 *) ac_try_echo=$ac_try;; 2473 esac 2474 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2475 $as_echo "$ac_try_echo"; } >&5 2476 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err 2477 ac_status=$? 2478 if test -s conftest.err; then 2479 grep -v '^ *+' conftest.err >conftest.er1 2480 cat conftest.er1 >&5 2481 mv -f conftest.er1 conftest.err 2482 fi 2483 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2484 test $ac_status = 0; } > conftest.i && { 2485 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || 2486 test ! -s conftest.err 2487 }; then : 2488 ac_retval=0 2489 else 2490 $as_echo "$as_me: failed program was:" >&5 2491 sed 's/^/| /' conftest.$ac_ext >&5 2492 2493 ac_retval=1 2494 fi 2495 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2496 as_fn_set_status $ac_retval 2497 2498 } # ac_fn_c_try_cpp 2499 2500 # ac_fn_cxx_try_cpp LINENO 2501 # ------------------------ 2502 # Try to preprocess conftest.$ac_ext, and return whether this succeeded. 2503 ac_fn_cxx_try_cpp () 2504 { 2505 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2506 if { { ac_try="$ac_cpp conftest.$ac_ext" 2507 case "(($ac_try" in 2508 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2509 *) ac_try_echo=$ac_try;; 2510 esac 2511 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2512 $as_echo "$ac_try_echo"; } >&5 2513 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err 2514 ac_status=$? 2515 if test -s conftest.err; then 2516 grep -v '^ *+' conftest.err >conftest.er1 2517 cat conftest.er1 >&5 2518 mv -f conftest.er1 conftest.err 2519 fi 2520 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2521 test $ac_status = 0; } > conftest.i && { 2522 test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" || 2523 test ! -s conftest.err 2524 }; then : 2525 ac_retval=0 2526 else 2527 $as_echo "$as_me: failed program was:" >&5 2528 sed 's/^/| /' conftest.$ac_ext >&5 2529 2530 ac_retval=1 2531 fi 2532 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2533 as_fn_set_status $ac_retval 2534 2535 } # ac_fn_cxx_try_cpp 2536 2537 # ac_fn_c_try_link LINENO 2538 # ----------------------- 2539 # Try to link conftest.$ac_ext, and return whether this succeeded. 2540 ac_fn_c_try_link () 2541 { 2542 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2543 rm -f conftest.$ac_objext conftest$ac_exeext 2544 if { { ac_try="$ac_link" 2545 case "(($ac_try" in 2546 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2547 *) ac_try_echo=$ac_try;; 2548 esac 2549 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2550 $as_echo "$ac_try_echo"; } >&5 2551 (eval "$ac_link") 2>conftest.err 2552 ac_status=$? 2553 if test -s conftest.err; then 2554 grep -v '^ *+' conftest.err >conftest.er1 2555 cat conftest.er1 >&5 2556 mv -f conftest.er1 conftest.err 2557 fi 2558 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2559 test $ac_status = 0; } && { 2560 test -z "$ac_c_werror_flag" || 2561 test ! -s conftest.err 2562 } && test -s conftest$ac_exeext && { 2563 test "$cross_compiling" = yes || 2564 test -x conftest$ac_exeext 2565 }; then : 2566 ac_retval=0 2567 else 2568 $as_echo "$as_me: failed program was:" >&5 2569 sed 's/^/| /' conftest.$ac_ext >&5 2570 2571 ac_retval=1 2572 fi 2573 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information 2574 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would 2575 # interfere with the next link command; also delete a directory that is 2576 # left behind by Apple's compiler. We do this before executing the actions. 2577 rm -rf conftest.dSYM conftest_ipa8_conftest.oo 2578 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2579 as_fn_set_status $ac_retval 2580 2581 } # ac_fn_c_try_link 2582 2583 # ac_fn_cxx_check_header_mongrel LINENO HEADER VAR INCLUDES 2584 # --------------------------------------------------------- 2585 # Tests whether HEADER exists, giving a warning if it cannot be compiled using 2586 # the include files in INCLUDES and setting the cache variable VAR 2587 # accordingly. 2588 ac_fn_cxx_check_header_mongrel () 2589 { 2590 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2591 if eval \${$3+:} false; then : 2592 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2593 $as_echo_n "checking for $2... " >&6; } 2594 if eval \${$3+:} false; then : 2595 $as_echo_n "(cached) " >&6 2596 fi 2597 eval ac_res=\$$3 2598 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 2599 $as_echo "$ac_res" >&6; } 2600 else 2601 # Is the header compilable? 2602 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 2603 $as_echo_n "checking $2 usability... " >&6; } 2604 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2605 /* end confdefs.h. */ 2606 $4 2607 #include <$2> 2608 _ACEOF 2609 if ac_fn_cxx_try_compile "$LINENO"; then : 2610 ac_header_compiler=yes 2611 else 2612 ac_header_compiler=no 2613 fi 2614 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2615 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 2616 $as_echo "$ac_header_compiler" >&6; } 2617 2618 # Is the header present? 2619 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 2620 $as_echo_n "checking $2 presence... " >&6; } 2621 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2622 /* end confdefs.h. */ 2623 #include <$2> 2624 _ACEOF 2625 if ac_fn_cxx_try_cpp "$LINENO"; then : 2626 ac_header_preproc=yes 2627 else 2628 ac_header_preproc=no 2629 fi 2630 rm -f conftest.err conftest.i conftest.$ac_ext 2631 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 2632 $as_echo "$ac_header_preproc" >&6; } 2633 2634 # So? What about this header? 2635 case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in #(( 2636 yes:no: ) 2637 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 2638 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;} 2639 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 2640 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} 2641 ;; 2642 no:yes:* ) 2643 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 2644 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} 2645 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 2646 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} 2647 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 2648 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} 2649 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 2650 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} 2651 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 2652 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} 2653 ( $as_echo "## ----------------------------------------- ## 2654 ## Report this to build-dev@openjdk.java.net ## 2655 ## ----------------------------------------- ##" 2656 ) | sed "s/^/$as_me: WARNING: /" >&2 2657 ;; 2658 esac 2659 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2660 $as_echo_n "checking for $2... " >&6; } 2661 if eval \${$3+:} false; then : 2662 $as_echo_n "(cached) " >&6 2663 else 2664 eval "$3=\$ac_header_compiler" 2665 fi 2666 eval ac_res=\$$3 2667 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 2668 $as_echo "$ac_res" >&6; } 2669 fi 2670 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2671 2672 } # ac_fn_cxx_check_header_mongrel 2673 2674 # ac_fn_cxx_try_run LINENO 2675 # ------------------------ 2676 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes 2677 # that executables *can* be run. 2678 ac_fn_cxx_try_run () 2679 { 2680 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2681 if { { ac_try="$ac_link" 2682 case "(($ac_try" in 2683 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2684 *) ac_try_echo=$ac_try;; 2685 esac 2686 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2687 $as_echo "$ac_try_echo"; } >&5 2688 (eval "$ac_link") 2>&5 2689 ac_status=$? 2690 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2691 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' 2692 { { case "(($ac_try" in 2693 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2694 *) ac_try_echo=$ac_try;; 2695 esac 2696 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2697 $as_echo "$ac_try_echo"; } >&5 2698 (eval "$ac_try") 2>&5 2699 ac_status=$? 2700 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2701 test $ac_status = 0; }; }; then : 2702 ac_retval=0 2703 else 2704 $as_echo "$as_me: program exited with status $ac_status" >&5 2705 $as_echo "$as_me: failed program was:" >&5 2706 sed 's/^/| /' conftest.$ac_ext >&5 2707 2708 ac_retval=$ac_status 2709 fi 2710 rm -rf conftest.dSYM conftest_ipa8_conftest.oo 2711 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2712 as_fn_set_status $ac_retval 2713 2714 } # ac_fn_cxx_try_run 2715 2716 # ac_fn_cxx_check_header_compile LINENO HEADER VAR INCLUDES 2717 # --------------------------------------------------------- 2718 # Tests whether HEADER exists and can be compiled using the include files in 2719 # INCLUDES, setting the cache variable VAR accordingly. 2720 ac_fn_cxx_check_header_compile () 2721 { 2722 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2723 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2724 $as_echo_n "checking for $2... " >&6; } 2725 if eval \${$3+:} false; then : 2726 $as_echo_n "(cached) " >&6 2727 else 2728 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2729 /* end confdefs.h. */ 2730 $4 2731 #include <$2> 2732 _ACEOF 2733 if ac_fn_cxx_try_compile "$LINENO"; then : 2734 eval "$3=yes" 2735 else 2736 eval "$3=no" 2737 fi 2738 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2739 fi 2740 eval ac_res=\$$3 2741 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 2742 $as_echo "$ac_res" >&6; } 2743 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2744 2745 } # ac_fn_cxx_check_header_compile 2746 2747 # ac_fn_cxx_compute_int LINENO EXPR VAR INCLUDES 2748 # ---------------------------------------------- 2749 # Tries to find the compile-time value of EXPR in a program that includes 2750 # INCLUDES, setting VAR accordingly. Returns whether the value could be 2751 # computed 2752 ac_fn_cxx_compute_int () 2753 { 2754 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2755 if test "$cross_compiling" = yes; then 2756 # Depending upon the size, compute the lo and hi bounds. 2757 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2758 /* end confdefs.h. */ 2759 $4 2760 int 2761 main () 2762 { 2763 static int test_array [1 - 2 * !(($2) >= 0)]; 2764 test_array [0] = 0; 2765 return test_array [0]; 2766 2767 ; 2768 return 0; 2769 } 2770 _ACEOF 2771 if ac_fn_cxx_try_compile "$LINENO"; then : 2772 ac_lo=0 ac_mid=0 2773 while :; do 2774 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2775 /* end confdefs.h. */ 2776 $4 2777 int 2778 main () 2779 { 2780 static int test_array [1 - 2 * !(($2) <= $ac_mid)]; 2781 test_array [0] = 0; 2782 return test_array [0]; 2783 2784 ; 2785 return 0; 2786 } 2787 _ACEOF 2788 if ac_fn_cxx_try_compile "$LINENO"; then : 2789 ac_hi=$ac_mid; break 2790 else 2791 as_fn_arith $ac_mid + 1 && ac_lo=$as_val 2792 if test $ac_lo -le $ac_mid; then 2793 ac_lo= ac_hi= 2794 break 2795 fi 2796 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val 2797 fi 2798 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2799 done 2800 else 2801 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2802 /* end confdefs.h. */ 2803 $4 2804 int 2805 main () 2806 { 2807 static int test_array [1 - 2 * !(($2) < 0)]; 2808 test_array [0] = 0; 2809 return test_array [0]; 2810 2811 ; 2812 return 0; 2813 } 2814 _ACEOF 2815 if ac_fn_cxx_try_compile "$LINENO"; then : 2816 ac_hi=-1 ac_mid=-1 2817 while :; do 2818 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2819 /* end confdefs.h. */ 2820 $4 2821 int 2822 main () 2823 { 2824 static int test_array [1 - 2 * !(($2) >= $ac_mid)]; 2825 test_array [0] = 0; 2826 return test_array [0]; 2827 2828 ; 2829 return 0; 2830 } 2831 _ACEOF 2832 if ac_fn_cxx_try_compile "$LINENO"; then : 2833 ac_lo=$ac_mid; break 2834 else 2835 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val 2836 if test $ac_mid -le $ac_hi; then 2837 ac_lo= ac_hi= 2838 break 2839 fi 2840 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val 2841 fi 2842 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2843 done 2844 else 2845 ac_lo= ac_hi= 2846 fi 2847 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2848 fi 2849 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2850 # Binary search between lo and hi bounds. 2851 while test "x$ac_lo" != "x$ac_hi"; do 2852 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val 2853 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2854 /* end confdefs.h. */ 2855 $4 2856 int 2857 main () 2858 { 2859 static int test_array [1 - 2 * !(($2) <= $ac_mid)]; 2860 test_array [0] = 0; 2861 return test_array [0]; 2862 2863 ; 2864 return 0; 2865 } 2866 _ACEOF 2867 if ac_fn_cxx_try_compile "$LINENO"; then : 2868 ac_hi=$ac_mid 2869 else 2870 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val 2871 fi 2872 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2873 done 2874 case $ac_lo in #(( 2875 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;; 2876 '') ac_retval=1 ;; 2877 esac 2878 else 2879 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2880 /* end confdefs.h. */ 2881 $4 2882 static long int longval () { return $2; } 2883 static unsigned long int ulongval () { return $2; } 2884 #include <stdio.h> 2885 #include <stdlib.h> 2886 int 2887 main () 2888 { 2889 2890 FILE *f = fopen ("conftest.val", "w"); 2891 if (! f) 2892 return 1; 2893 if (($2) < 0) 2894 { 2895 long int i = longval (); 2896 if (i != ($2)) 2897 return 1; 2898 fprintf (f, "%ld", i); 2899 } 2900 else 2901 { 2902 unsigned long int i = ulongval (); 2903 if (i != ($2)) 2904 return 1; 2905 fprintf (f, "%lu", i); 2906 } 2907 /* Do not output a trailing newline, as this causes \r\n confusion 2908 on some platforms. */ 2909 return ferror (f) || fclose (f) != 0; 2910 2911 ; 2912 return 0; 2913 } 2914 _ACEOF 2915 if ac_fn_cxx_try_run "$LINENO"; then : 2916 echo >>conftest.val; read $3 <conftest.val; ac_retval=0 2917 else 2918 ac_retval=1 2919 fi 2920 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 2921 conftest.$ac_objext conftest.beam conftest.$ac_ext 2922 rm -f conftest.val 2923 2924 fi 2925 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2926 as_fn_set_status $ac_retval 2927 2928 } # ac_fn_cxx_compute_int 2929 2930 # ac_fn_cxx_try_link LINENO 2931 # ------------------------- 2932 # Try to link conftest.$ac_ext, and return whether this succeeded. 2933 ac_fn_cxx_try_link () 2934 { 2935 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2936 rm -f conftest.$ac_objext conftest$ac_exeext 2937 if { { ac_try="$ac_link" 2938 case "(($ac_try" in 2939 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2940 *) ac_try_echo=$ac_try;; 2941 esac 2942 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2943 $as_echo "$ac_try_echo"; } >&5 2944 (eval "$ac_link") 2>conftest.err 2945 ac_status=$? 2946 if test -s conftest.err; then 2947 grep -v '^ *+' conftest.err >conftest.er1 2948 cat conftest.er1 >&5 2949 mv -f conftest.er1 conftest.err 2950 fi 2951 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2952 test $ac_status = 0; } && { 2953 test -z "$ac_cxx_werror_flag" || 2954 test ! -s conftest.err 2955 } && test -s conftest$ac_exeext && { 2956 test "$cross_compiling" = yes || 2957 test -x conftest$ac_exeext 2958 }; then : 2959 ac_retval=0 2960 else 2961 $as_echo "$as_me: failed program was:" >&5 2962 sed 's/^/| /' conftest.$ac_ext >&5 2963 2964 ac_retval=1 2965 fi 2966 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information 2967 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would 2968 # interfere with the next link command; also delete a directory that is 2969 # left behind by Apple's compiler. We do this before executing the actions. 2970 rm -rf conftest.dSYM conftest_ipa8_conftest.oo 2971 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2972 as_fn_set_status $ac_retval 2973 2974 } # ac_fn_cxx_try_link 2975 2976 # ac_fn_cxx_check_func LINENO FUNC VAR 2977 # ------------------------------------ 2978 # Tests whether FUNC exists, setting the cache variable VAR accordingly 2979 ac_fn_cxx_check_func () 2980 { 2981 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2982 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2983 $as_echo_n "checking for $2... " >&6; } 2984 if eval \${$3+:} false; then : 2985 $as_echo_n "(cached) " >&6 2986 else 2987 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2988 /* end confdefs.h. */ 2989 /* Define $2 to an innocuous variant, in case <limits.h> declares $2. 2990 For example, HP-UX 11i <limits.h> declares gettimeofday. */ 2991 #define $2 innocuous_$2 2992 2993 /* System header to define __stub macros and hopefully few prototypes, 2994 which can conflict with char $2 (); below. 2995 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 2996 <limits.h> exists even on freestanding compilers. */ 2997 2998 #ifdef __STDC__ 2999 # include <limits.h> 3000 #else 3001 # include <assert.h> 3002 #endif 3003 3004 #undef $2 3005 3006 /* Override any GCC internal prototype to avoid an error. 3007 Use char because int might match the return type of a GCC 3008 builtin and then its argument prototype would still apply. */ 3009 #ifdef __cplusplus 3010 extern "C" 3011 #endif 3012 char $2 (); 3013 /* The GNU C library defines this for functions which it implements 3014 to always fail with ENOSYS. Some functions are actually named 3015 something starting with __ and the normal name is an alias. */ 3016 #if defined __stub_$2 || defined __stub___$2 3017 choke me 3018 #endif 3019 3020 int 3021 main () 3022 { 3023 return $2 (); 3024 ; 3025 return 0; 3026 } 3027 _ACEOF 3028 if ac_fn_cxx_try_link "$LINENO"; then : 3029 eval "$3=yes" 3030 else 3031 eval "$3=no" 3032 fi 3033 rm -f core conftest.err conftest.$ac_objext \ 3034 conftest$ac_exeext conftest.$ac_ext 3035 fi 3036 eval ac_res=\$$3 3037 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 3038 $as_echo "$ac_res" >&6; } 3039 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 3040 3041 } # ac_fn_cxx_check_func 3042 3043 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES 3044 # ------------------------------------------------------- 3045 # Tests whether HEADER exists and can be compiled using the include files in 3046 # INCLUDES, setting the cache variable VAR accordingly. 3047 ac_fn_c_check_header_compile () 3048 { 3049 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 3050 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 3051 $as_echo_n "checking for $2... " >&6; } 3052 if eval \${$3+:} false; then : 3053 $as_echo_n "(cached) " >&6 3054 else 3055 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 3056 /* end confdefs.h. */ 3057 $4 3058 #include <$2> 3059 _ACEOF 3060 if ac_fn_c_try_compile "$LINENO"; then : 3061 eval "$3=yes" 3062 else 3063 eval "$3=no" 3064 fi 3065 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 3066 fi 3067 eval ac_res=\$$3 3068 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 3069 $as_echo "$ac_res" >&6; } 3070 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 3071 3072 } # ac_fn_c_check_header_compile 3073 cat >config.log <<_ACEOF 3074 This file contains any messages produced by compilers while 3075 running configure, to aid debugging if configure makes a mistake. 3076 3077 It was created by OpenJDK $as_me jdk9, which was 3078 generated by GNU Autoconf 2.69. Invocation command line was 3079 3080 $ $0 $@ 3081 3082 _ACEOF 3083 exec 5>>config.log 3084 { 3085 cat <<_ASUNAME 3086 ## --------- ## 3087 ## Platform. ## 3088 ## --------- ## 3089 3090 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` 3091 uname -m = `(uname -m) 2>/dev/null || echo unknown` 3092 uname -r = `(uname -r) 2>/dev/null || echo unknown` 3093 uname -s = `(uname -s) 2>/dev/null || echo unknown` 3094 uname -v = `(uname -v) 2>/dev/null || echo unknown` 3095 3096 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` 3097 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` 3098 3099 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` 3100 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` 3101 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` 3102 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` 3103 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` 3104 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` 3105 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` 3106 3107 _ASUNAME 3108 3109 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 3110 for as_dir in $PATH 3111 do 3112 IFS=$as_save_IFS 3113 test -z "$as_dir" && as_dir=. 3114 $as_echo "PATH: $as_dir" 3115 done 3116 IFS=$as_save_IFS 3117 3118 } >&5 3119 3120 cat >&5 <<_ACEOF 3121 3122 3123 ## ----------- ## 3124 ## Core tests. ## 3125 ## ----------- ## 3126 3127 _ACEOF 3128 3129 3130 # Keep a trace of the command line. 3131 # Strip out --no-create and --no-recursion so they do not pile up. 3132 # Strip out --silent because we don't want to record it for future runs. 3133 # Also quote any args containing shell meta-characters. 3134 # Make two passes to allow for proper duplicate-argument suppression. 3135 ac_configure_args= 3136 ac_configure_args0= 3137 ac_configure_args1= 3138 ac_must_keep_next=false 3139 for ac_pass in 1 2 3140 do 3141 for ac_arg 3142 do 3143 case $ac_arg in 3144 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; 3145 -q | -quiet | --quiet | --quie | --qui | --qu | --q \ 3146 | -silent | --silent | --silen | --sile | --sil) 3147 continue ;; 3148 *\'*) 3149 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; 3150 esac 3151 case $ac_pass in 3152 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; 3153 2) 3154 as_fn_append ac_configure_args1 " '$ac_arg'" 3155 if test $ac_must_keep_next = true; then 3156 ac_must_keep_next=false # Got value, back to normal. 3157 else 3158 case $ac_arg in 3159 *=* | --config-cache | -C | -disable-* | --disable-* \ 3160 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ 3161 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ 3162 | -with-* | --with-* | -without-* | --without-* | --x) 3163 case "$ac_configure_args0 " in 3164 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; 3165 esac 3166 ;; 3167 -* ) ac_must_keep_next=true ;; 3168 esac 3169 fi 3170 as_fn_append ac_configure_args " '$ac_arg'" 3171 ;; 3172 esac 3173 done 3174 done 3175 { ac_configure_args0=; unset ac_configure_args0;} 3176 { ac_configure_args1=; unset ac_configure_args1;} 3177 3178 # When interrupted or exit'd, cleanup temporary files, and complete 3179 # config.log. We remove comments because anyway the quotes in there 3180 # would cause problems or look ugly. 3181 # WARNING: Use '\'' to represent an apostrophe within the trap. 3182 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. 3183 trap 'exit_status=$? 3184 # Save into config.log some information that might help in debugging. 3185 { 3186 echo 3187 3188 $as_echo "## ---------------- ## 3189 ## Cache variables. ## 3190 ## ---------------- ##" 3191 echo 3192 # The following way of writing the cache mishandles newlines in values, 3193 ( 3194 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do 3195 eval ac_val=\$$ac_var 3196 case $ac_val in #( 3197 *${as_nl}*) 3198 case $ac_var in #( 3199 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 3200 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; 3201 esac 3202 case $ac_var in #( 3203 _ | IFS | as_nl) ;; #( 3204 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( 3205 *) { eval $ac_var=; unset $ac_var;} ;; 3206 esac ;; 3207 esac 3208 done 3209 (set) 2>&1 | 3210 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( 3211 *${as_nl}ac_space=\ *) 3212 sed -n \ 3213 "s/'\''/'\''\\\\'\'''\''/g; 3214 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" 3215 ;; #( 3216 *) 3217 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" 3218 ;; 3219 esac | 3220 sort 3221 ) 3222 echo 3223 3224 $as_echo "## ----------------- ## 3225 ## Output variables. ## 3226 ## ----------------- ##" 3227 echo 3228 for ac_var in $ac_subst_vars 3229 do 3230 eval ac_val=\$$ac_var 3231 case $ac_val in 3232 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; 3233 esac 3234 $as_echo "$ac_var='\''$ac_val'\''" 3235 done | sort 3236 echo 3237 3238 if test -n "$ac_subst_files"; then 3239 $as_echo "## ------------------- ## 3240 ## File substitutions. ## 3241 ## ------------------- ##" 3242 echo 3243 for ac_var in $ac_subst_files 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 fi 3253 3254 if test -s confdefs.h; then 3255 $as_echo "## ----------- ## 3256 ## confdefs.h. ## 3257 ## ----------- ##" 3258 echo 3259 cat confdefs.h 3260 echo 3261 fi 3262 test "$ac_signal" != 0 && 3263 $as_echo "$as_me: caught signal $ac_signal" 3264 $as_echo "$as_me: exit $exit_status" 3265 } >&5 3266 rm -f core *.core core.conftest.* && 3267 rm -f -r conftest* confdefs* conf$$* $ac_clean_files && 3268 exit $exit_status 3269 ' 0 3270 for ac_signal in 1 2 13 15; do 3271 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal 3272 done 3273 ac_signal=0 3274 3275 # confdefs.h avoids OS command line length limits that DEFS can exceed. 3276 rm -f -r conftest* confdefs.h 3277 3278 $as_echo "/* confdefs.h */" > confdefs.h 3279 3280 # Predefined preprocessor variables. 3281 3282 cat >>confdefs.h <<_ACEOF 3283 #define PACKAGE_NAME "$PACKAGE_NAME" 3284 _ACEOF 3285 3286 cat >>confdefs.h <<_ACEOF 3287 #define PACKAGE_TARNAME "$PACKAGE_TARNAME" 3288 _ACEOF 3289 3290 cat >>confdefs.h <<_ACEOF 3291 #define PACKAGE_VERSION "$PACKAGE_VERSION" 3292 _ACEOF 3293 3294 cat >>confdefs.h <<_ACEOF 3295 #define PACKAGE_STRING "$PACKAGE_STRING" 3296 _ACEOF 3297 3298 cat >>confdefs.h <<_ACEOF 3299 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" 3300 _ACEOF 3301 3302 cat >>confdefs.h <<_ACEOF 3303 #define PACKAGE_URL "$PACKAGE_URL" 3304 _ACEOF 3305 3306 3307 # Let the site file select an alternate cache file if it wants to. 3308 # Prefer an explicitly selected file to automatically selected ones. 3309 ac_site_file1=NONE 3310 ac_site_file2=NONE 3311 if test -n "$CONFIG_SITE"; then 3312 # We do not want a PATH search for config.site. 3313 case $CONFIG_SITE in #(( 3314 -*) ac_site_file1=./$CONFIG_SITE;; 3315 */*) ac_site_file1=$CONFIG_SITE;; 3316 *) ac_site_file1=./$CONFIG_SITE;; 3317 esac 3318 elif test "x$prefix" != xNONE; then 3319 ac_site_file1=$prefix/share/config.site 3320 ac_site_file2=$prefix/etc/config.site 3321 else 3322 ac_site_file1=$ac_default_prefix/share/config.site 3323 ac_site_file2=$ac_default_prefix/etc/config.site 3324 fi 3325 for ac_site_file in "$ac_site_file1" "$ac_site_file2" 3326 do 3327 test "x$ac_site_file" = xNONE && continue 3328 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then 3329 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 3330 $as_echo "$as_me: loading site script $ac_site_file" >&6;} 3331 sed 's/^/| /' "$ac_site_file" >&5 3332 . "$ac_site_file" \ 3333 || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 3334 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 3335 as_fn_error $? "failed to load site script $ac_site_file 3336 See \`config.log' for more details" "$LINENO" 5; } 3337 fi 3338 done 3339 3340 if test -r "$cache_file"; then 3341 # Some versions of bash will fail to source /dev/null (special files 3342 # actually), so we avoid doing that. DJGPP emulates it as a regular file. 3343 if test /dev/null != "$cache_file" && test -f "$cache_file"; then 3344 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 3345 $as_echo "$as_me: loading cache $cache_file" >&6;} 3346 case $cache_file in 3347 [\\/]* | ?:[\\/]* ) . "$cache_file";; 3348 *) . "./$cache_file";; 3349 esac 3350 fi 3351 else 3352 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 3353 $as_echo "$as_me: creating cache $cache_file" >&6;} 3354 >$cache_file 3355 fi 3356 3357 # Check that the precious variables saved in the cache have kept the same 3358 # value. 3359 ac_cache_corrupted=false 3360 for ac_var in $ac_precious_vars; do 3361 eval ac_old_set=\$ac_cv_env_${ac_var}_set 3362 eval ac_new_set=\$ac_env_${ac_var}_set 3363 eval ac_old_val=\$ac_cv_env_${ac_var}_value 3364 eval ac_new_val=\$ac_env_${ac_var}_value 3365 case $ac_old_set,$ac_new_set in 3366 set,) 3367 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 3368 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} 3369 ac_cache_corrupted=: ;; 3370 ,set) 3371 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 3372 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} 3373 ac_cache_corrupted=: ;; 3374 ,);; 3375 *) 3376 if test "x$ac_old_val" != "x$ac_new_val"; then 3377 # differences in whitespace do not lead to failure. 3378 ac_old_val_w=`echo x $ac_old_val` 3379 ac_new_val_w=`echo x $ac_new_val` 3380 if test "$ac_old_val_w" != "$ac_new_val_w"; then 3381 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 3382 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} 3383 ac_cache_corrupted=: 3384 else 3385 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 3386 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} 3387 eval $ac_var=\$ac_old_val 3388 fi 3389 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 3390 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;} 3391 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 3392 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;} 3393 fi;; 3394 esac 3395 # Pass precious variables to config.status. 3396 if test "$ac_new_set" = set; then 3397 case $ac_new_val in 3398 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; 3399 *) ac_arg=$ac_var=$ac_new_val ;; 3400 esac 3401 case " $ac_configure_args " in 3402 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. 3403 *) as_fn_append ac_configure_args " '$ac_arg'" ;; 3404 esac 3405 fi 3406 done 3407 if $ac_cache_corrupted; then 3408 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 3409 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 3410 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 3411 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} 3412 as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 3413 fi 3414 ## -------------------- ## 3415 ## Main body of script. ## 3416 ## -------------------- ## 3417 3418 ac_ext=c 3419 ac_cpp='$CPP $CPPFLAGS' 3420 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 3421 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 3422 ac_compiler_gnu=$ac_cv_c_compiler_gnu 3423 3424 3425 3426 ac_aux_dir= 3427 for ac_dir in $TOPDIR/common/autoconf/build-aux "$srcdir"/$TOPDIR/common/autoconf/build-aux; do 3428 if test -f "$ac_dir/install-sh"; then 3429 ac_aux_dir=$ac_dir 3430 ac_install_sh="$ac_aux_dir/install-sh -c" 3431 break 3432 elif test -f "$ac_dir/install.sh"; then 3433 ac_aux_dir=$ac_dir 3434 ac_install_sh="$ac_aux_dir/install.sh -c" 3435 break 3436 elif test -f "$ac_dir/shtool"; then 3437 ac_aux_dir=$ac_dir 3438 ac_install_sh="$ac_aux_dir/shtool install -c" 3439 break 3440 fi 3441 done 3442 if test -z "$ac_aux_dir"; then 3443 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 3444 fi 3445 3446 # These three variables are undocumented and unsupported, 3447 # and are intended to be withdrawn in a future Autoconf release. 3448 # They can cause serious problems if a builder's source tree is in a directory 3449 # whose full name contains unusual characters. 3450 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. 3451 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. 3452 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. 3453 3454 3455 # pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*- 3456 3457 # 3458 # Copyright (c) 2012, 2013, Oracle and/or its affiliates. All rights reserved. 3459 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3460 # 3461 # This code is free software; you can redistribute it and/or modify it 3462 # under the terms of the GNU General Public License version 2 only, as 3463 # published by the Free Software Foundation. Oracle designates this 3464 # particular file as subject to the "Classpath" exception as provided 3465 # by Oracle in the LICENSE file that accompanied this code. 3466 # 3467 # This code is distributed in the hope that it will be useful, but WITHOUT 3468 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3469 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3470 # version 2 for more details (a copy is included in the LICENSE file that 3471 # accompanied this code). 3472 # 3473 # You should have received a copy of the GNU General Public License version 3474 # 2 along with this work; if not, write to the Free Software Foundation, 3475 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3476 # 3477 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3478 # or visit www.oracle.com if you need additional information or have any 3479 # questions. 3480 # 3481 3482 # 3483 # Copyright © 2004 Scott James Remnant <scott@netsplit.com>. 3484 # 3485 # This program is free software; you can redistribute it and/or modify 3486 # it under the terms of the GNU General Public License as published by 3487 # the Free Software Foundation; either version 2 of the License, or 3488 # (at your option) any later version. 3489 # 3490 # This program is distributed in the hope that it will be useful, but 3491 # WITHOUT ANY WARRANTY; without even the implied warranty of 3492 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 3493 # General Public License for more details. 3494 # 3495 # You should have received a copy of the GNU General Public License 3496 # along with this program; if not, write to the Free Software 3497 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 3498 # 3499 # As a special exception to the GNU General Public License, if you 3500 # distribute this file as part of a program that contains a 3501 # configuration script generated by Autoconf, you may include it under 3502 # the same distribution terms that you use for the rest of that program. 3503 3504 # PKG_PROG_PKG_CONFIG([MIN-VERSION]) 3505 # ---------------------------------- 3506 # PKG_PROG_PKG_CONFIG 3507 3508 # PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]) 3509 # 3510 # Check to see whether a particular set of modules exists. Similar 3511 # to PKG_CHECK_MODULES(), but does not set variables or print errors. 3512 # 3513 # 3514 # Similar to PKG_CHECK_MODULES, make sure that the first instance of 3515 # this or PKG_CHECK_MODULES is called, or make sure to call 3516 # PKG_CHECK_EXISTS manually 3517 # -------------------------------------------------------------- 3518 3519 3520 3521 # _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES]) 3522 # --------------------------------------------- 3523 # _PKG_CONFIG 3524 3525 # _PKG_SHORT_ERRORS_SUPPORTED 3526 # ----------------------------- 3527 # _PKG_SHORT_ERRORS_SUPPORTED 3528 3529 3530 # PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND], 3531 # [ACTION-IF-NOT-FOUND]) 3532 # 3533 # 3534 # Note that if there is a possibility the first call to 3535 # PKG_CHECK_MODULES might not happen, you should be sure to include an 3536 # explicit call to PKG_PROG_PKG_CONFIG in your configure.ac 3537 # 3538 # 3539 # -------------------------------------------------------------- 3540 # PKG_CHECK_MODULES 3541 3542 3543 # Include these first... 3544 # 3545 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 3546 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3547 # 3548 # This code is free software; you can redistribute it and/or modify it 3549 # under the terms of the GNU General Public License version 2 only, as 3550 # published by the Free Software Foundation. Oracle designates this 3551 # particular file as subject to the "Classpath" exception as provided 3552 # by Oracle in the LICENSE file that accompanied this code. 3553 # 3554 # This code is distributed in the hope that it will be useful, but WITHOUT 3555 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3556 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3557 # version 2 for more details (a copy is included in the LICENSE file that 3558 # accompanied this code). 3559 # 3560 # You should have received a copy of the GNU General Public License version 3561 # 2 along with this work; if not, write to the Free Software Foundation, 3562 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3563 # 3564 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3565 # or visit www.oracle.com if you need additional information or have any 3566 # questions. 3567 # 3568 3569 # Create a function/macro that takes a series of named arguments. The call is 3570 # similar to AC_DEFUN, but the setup of the function looks like this: 3571 # BASIC_DEFUN_NAMED([MYFUNC], [FOO *BAR], [$@], [ 3572 # ... do something 3573 # AC_MSG_NOTICE([Value of BAR is ARG_BAR]) 3574 # ]) 3575 # A star (*) in front of a named argument means that it is required and it's 3576 # presence will be verified. To pass e.g. the first value as a normal indexed 3577 # argument, use [m4_shift($@)] as the third argument instead of [$@]. These 3578 # arguments are referenced in the function by their name prefixed by ARG_, e.g. 3579 # "ARG_FOO". 3580 # 3581 # The generated function can be called like this: 3582 # MYFUNC(FOO: [foo-val], 3583 # BAR: [ 3584 # $ECHO hello world 3585 # ]) 3586 # Note that the argument value must start on the same line as the argument name. 3587 # 3588 # Argument 1: Name of the function to define 3589 # Argument 2: List of legal named arguments, with a * prefix for required arguments 3590 # Argument 3: Argument array to treat as named, typically $@ 3591 # Argument 4: The main function body 3592 3593 3594 # Test if $1 is a valid argument to $3 (often is $JAVA passed as $3) 3595 # If so, then append $1 to $2 \ 3596 # Also set JVM_ARG_OK to true/false depending on outcome. 3597 3598 3599 # Appends a string to a path variable, only adding the : when needed. 3600 3601 3602 # Prepends a string to a path variable, only adding the : when needed. 3603 3604 3605 # This will make sure the given variable points to a full and proper 3606 # path. This means: 3607 # 1) There will be no spaces in the path. On unix platforms, 3608 # spaces in the path will result in an error. On Windows, 3609 # the path will be rewritten using short-style to be space-free. 3610 # 2) The path will be absolute, and it will be in unix-style (on 3611 # cygwin). 3612 # $1: The name of the variable to fix 3613 3614 3615 # This will make sure the given variable points to a executable 3616 # with a full and proper path. This means: 3617 # 1) There will be no spaces in the path. On unix platforms, 3618 # spaces in the path will result in an error. On Windows, 3619 # the path will be rewritten using short-style to be space-free. 3620 # 2) The path will be absolute, and it will be in unix-style (on 3621 # cygwin). 3622 # Any arguments given to the executable is preserved. 3623 # If the input variable does not have a directory specification, then 3624 # it need to be in the PATH. 3625 # $1: The name of the variable to fix 3626 3627 3628 3629 3630 # Register a --with argument but mark it as deprecated 3631 # $1: The name of the with argument to deprecate, not including --with- 3632 3633 3634 # Register a --enable argument but mark it as deprecated 3635 # $1: The name of the with argument to deprecate, not including --enable- 3636 # $2: The name of the argument to deprecate, in shell variable style (i.e. with _ instead of -) 3637 # $3: Messages to user. 3638 3639 3640 3641 3642 # Test that variable $1 denoting a program is not empty. If empty, exit with an error. 3643 # $1: variable to check 3644 3645 3646 # Check that there are no unprocessed overridden variables left. 3647 # If so, they are an incorrect argument and we will exit with an error. 3648 3649 3650 # Setup a tool for the given variable. If correctly specified by the user, 3651 # use that value, otherwise search for the tool using the supplied code snippet. 3652 # $1: variable to set 3653 # $2: code snippet to call to look for the tool 3654 # $3: code snippet to call if variable was used to find tool 3655 3656 3657 # Call BASIC_SETUP_TOOL with AC_PATH_PROGS to locate the tool 3658 # $1: variable to set 3659 # $2: executable name (or list of names) to look for 3660 3661 3662 # Call BASIC_SETUP_TOOL with AC_CHECK_TOOLS to locate the tool 3663 # $1: variable to set 3664 # $2: executable name (or list of names) to look for 3665 3666 3667 # Like BASIC_PATH_PROGS but fails if no tool was found. 3668 # $1: variable to set 3669 # $2: executable name (or list of names) to look for 3670 3671 3672 # Like BASIC_SETUP_TOOL but fails if no tool was found. 3673 # $1: variable to set 3674 # $2: autoconf macro to call to look for the special tool 3675 3676 3677 # Setup the most fundamental tools that relies on not much else to set up, 3678 # but is used by much of the early bootstrap code. 3679 3680 3681 # Setup basic configuration paths, and platform-specific stuff related to PATHs. 3682 3683 3684 # Evaluates platform specific overrides for devkit variables. 3685 # $1: Name of variable 3686 3687 3688 3689 3690 3691 3692 #%%% Simple tools %%% 3693 3694 # Check if we have found a usable version of make 3695 # $1: the path to a potential make binary (or empty) 3696 # $2: the description on how we found this 3697 3698 3699 3700 3701 # Goes looking for a usable version of GNU make. 3702 3703 3704 3705 3706 3707 3708 3709 3710 # Check if build directory is on local disk. If not possible to determine, 3711 # we prefer to claim it's local. 3712 # Argument 1: directory to test 3713 # Argument 2: what to do if it is on local disk 3714 # Argument 3: what to do otherwise (remote disk or failure) 3715 3716 3717 # Check that source files have basic read permissions set. This might 3718 # not be the case in cygwin in certain conditions. 3719 3720 3721 3722 3723 # Check for support for specific options in bash 3724 3725 3726 ################################################################################ 3727 # 3728 # Default make target 3729 # 3730 3731 3732 # Code to run after AC_OUTPUT 3733 3734 3735 # 3736 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. 3737 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3738 # 3739 # This code is free software; you can redistribute it and/or modify it 3740 # under the terms of the GNU General Public License version 2 only, as 3741 # published by the Free Software Foundation. Oracle designates this 3742 # particular file as subject to the "Classpath" exception as provided 3743 # by Oracle in the LICENSE file that accompanied this code. 3744 # 3745 # This code is distributed in the hope that it will be useful, but WITHOUT 3746 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3747 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3748 # version 2 for more details (a copy is included in the LICENSE file that 3749 # accompanied this code). 3750 # 3751 # You should have received a copy of the GNU General Public License version 3752 # 2 along with this work; if not, write to the Free Software Foundation, 3753 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3754 # 3755 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3756 # or visit www.oracle.com if you need additional information or have any 3757 # questions. 3758 # 3759 3760 3761 3762 3763 3764 # Helper function which possibly converts a path using DOS-style short mode. 3765 # If so, the updated path is stored in $new_path. 3766 # $1: The path to check 3767 3768 3769 # Helper function which possibly converts a path using DOS-style short mode. 3770 # If so, the updated path is stored in $new_path. 3771 # $1: The path to check 3772 3773 3774 # FIXME: The BASIC_FIXUP_*_CYGWIN/MSYS is most likely too convoluted 3775 # and could probably be heavily simplified. However, all changes in this 3776 # area tend to need lot of testing in different scenarios, and in lack of 3777 # proper unit testing, cleaning this up has not been deemed worth the effort 3778 # at the moment. 3779 3780 3781 3782 3783 3784 3785 3786 3787 3788 # Setup basic configuration paths, and platform-specific stuff related to PATHs. 3789 3790 3791 3792 3793 # ... then the rest 3794 # 3795 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. 3796 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3797 # 3798 # This code is free software; you can redistribute it and/or modify it 3799 # under the terms of the GNU General Public License version 2 only, as 3800 # published by the Free Software Foundation. Oracle designates this 3801 # particular file as subject to the "Classpath" exception as provided 3802 # by Oracle in the LICENSE file that accompanied this code. 3803 # 3804 # This code is distributed in the hope that it will be useful, but WITHOUT 3805 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3806 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3807 # version 2 for more details (a copy is included in the LICENSE file that 3808 # accompanied this code). 3809 # 3810 # You should have received a copy of the GNU General Public License version 3811 # 2 along with this work; if not, write to the Free Software Foundation, 3812 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3813 # 3814 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3815 # or visit www.oracle.com if you need additional information or have any 3816 # questions. 3817 # 3818 3819 ######################################################################## 3820 # This file handles detection of the Boot JDK. The Boot JDK detection 3821 # process has been developed as a response to solve a complex real-world 3822 # problem. Initially, it was simple, but it has grown as platform after 3823 # platform, idiosyncracy after idiosyncracy has been supported. 3824 # 3825 # The basic idea is this: 3826 # 1) You need an acceptable *) JDK to use as a Boot JDK 3827 # 2) There are several ways to locate a JDK, that are mostly platform 3828 # dependent **) 3829 # 3) You can have multiple JDKs installed 3830 # 4) If possible, configure should try to dig out an acceptable JDK 3831 # automatically, without having to resort to command-line options 3832 # 3833 # *) acceptable means e.g. JDK7 for building JDK8, a complete JDK (with 3834 # javac) and not a JRE, etc. 3835 # 3836 # **) On Windows we typically use a well-known path. 3837 # On MacOSX we typically use the tool java_home. 3838 # On Linux we typically find javac in the $PATH, and then follow a 3839 # chain of symlinks that often ends up in a real JDK. 3840 # 3841 # This leads to the code where we check in different ways to locate a 3842 # JDK, and if one is found, check if it is acceptable. If not, we print 3843 # our reasons for rejecting it (useful when debugging non-working 3844 # configure situations) and continue checking the next one. 3845 ######################################################################## 3846 3847 # Execute the check given as argument, and verify the result 3848 # If the Boot JDK was previously found, do nothing 3849 # $1 A command line (typically autoconf macro) to execute 3850 3851 3852 # Test: Is bootjdk explicitely set by command line arguments? 3853 3854 3855 # Test: Is $JAVA_HOME set? 3856 3857 3858 # Test: Is there a java or javac in the PATH, which is a symlink to the JDK? 3859 3860 3861 # Test: Is there a /usr/libexec/java_home? (Typically on MacOSX) 3862 # $1: Argument to the java_home binary (optional) 3863 3864 3865 # Test: On MacOS X, can we find a boot jdk using /usr/libexec/java_home? 3866 3867 3868 # Look for a jdk in the given path. If there are multiple, try to select the newest. 3869 # If found, set BOOT_JDK and BOOT_JDK_FOUND. 3870 # $1 = Path to directory containing jdk installations. 3871 # $2 = String to append to the found JDK directory to get the proper JDK home 3872 3873 3874 # Call BOOTJDK_FIND_BEST_JDK_IN_DIRECTORY, but use the given 3875 # environmental variable as base for where to look. 3876 # $1 Name of an environmal variable, assumed to point to the Program Files directory. 3877 3878 3879 # Test: Is there a JDK installed in default, well-known locations? 3880 3881 3882 # Check that a command-line tool in the Boot JDK is correct 3883 # $1 = name of variable to assign 3884 # $2 = name of binary 3885 3886 3887 ############################################################################### 3888 # 3889 # We need a Boot JDK to bootstrap the build. 3890 # 3891 3892 3893 3894 3895 3896 # BUILD_JDK: the location of the latest JDK that can run 3897 # on the host system and supports the target class file version 3898 # generated in this JDK build. This variable should only be 3899 # used after the launchers are built. 3900 # 3901 3902 # Execute the check given as argument, and verify the result. 3903 # If the JDK was previously found, do nothing. 3904 # $1 A command line (typically autoconf macro) to execute 3905 3906 3907 # By default the BUILD_JDK is the JDK_OUTPUTDIR. If the target architecture 3908 # is different than the host system doing the build (e.g. cross-compilation), 3909 # a special BUILD_JDK is built as part of the build process. An external 3910 # prebuilt BUILD_JDK can also be supplied. 3911 3912 3913 # 3914 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 3915 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3916 # 3917 # This code is free software; you can redistribute it and/or modify it 3918 # under the terms of the GNU General Public License version 2 only, as 3919 # published by the Free Software Foundation. Oracle designates this 3920 # particular file as subject to the "Classpath" exception as provided 3921 # by Oracle in the LICENSE file that accompanied this code. 3922 # 3923 # This code is distributed in the hope that it will be useful, but WITHOUT 3924 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3925 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3926 # version 2 for more details (a copy is included in the LICENSE file that 3927 # accompanied this code). 3928 # 3929 # You should have received a copy of the GNU General Public License version 3930 # 2 along with this work; if not, write to the Free Software Foundation, 3931 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3932 # 3933 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3934 # or visit www.oracle.com if you need additional information or have any 3935 # questions. 3936 # 3937 3938 3939 3940 3941 3942 3943 3944 3945 3946 3947 3948 3949 3950 3951 3952 3953 3954 ################################################################################ 3955 # 3956 # Runs icecc-create-env once and prints the error if it fails 3957 # 3958 # $1: arguments to icecc-create-env 3959 # $2: log file 3960 # 3961 3962 3963 ################################################################################ 3964 # 3965 # Optionally enable distributed compilation of native code using icecc/icecream 3966 # 3967 3968 3969 3970 3971 3972 3973 3974 # 3975 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 3976 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3977 # 3978 # This code is free software; you can redistribute it and/or modify it 3979 # under the terms of the GNU General Public License version 2 only, as 3980 # published by the Free Software Foundation. Oracle designates this 3981 # particular file as subject to the "Classpath" exception as provided 3982 # by Oracle in the LICENSE file that accompanied this code. 3983 # 3984 # This code is distributed in the hope that it will be useful, but WITHOUT 3985 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3986 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3987 # version 2 for more details (a copy is included in the LICENSE file that 3988 # accompanied this code). 3989 # 3990 # You should have received a copy of the GNU General Public License version 3991 # 2 along with this work; if not, write to the Free Software Foundation, 3992 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3993 # 3994 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3995 # or visit www.oracle.com if you need additional information or have any 3996 # questions. 3997 # 3998 3999 # Reset the global CFLAGS/LDFLAGS variables and initialize them with the 4000 # corresponding configure arguments instead 4001 4002 4003 # Setup the sysroot flags and add them to global CFLAGS and LDFLAGS so 4004 # that configure can use them while detecting compilers. 4005 # TOOLCHAIN_TYPE is available here. 4006 # Param 1 - Optional prefix to all variables. (e.g BUILD_) 4007 4008 4009 4010 4011 4012 4013 # Documentation on common flags used for solstudio in HIGHEST. 4014 # 4015 # WARNING: Use of OPTIMIZATION_LEVEL=HIGHEST in your Makefile needs to be 4016 # done with care, there are some assumptions below that need to 4017 # be understood about the use of pointers, and IEEE behavior. 4018 # 4019 # -fns: Use non-standard floating point mode (not IEEE 754) 4020 # -fsimple: Do some simplification of floating point arithmetic (not IEEE 754) 4021 # -fsingle: Use single precision floating point with 'float' 4022 # -xalias_level=basic: Assume memory references via basic pointer types do not alias 4023 # (Source with excessing pointer casting and data access with mixed 4024 # pointer types are not recommended) 4025 # -xbuiltin=%all: Use intrinsic or inline versions for math/std functions 4026 # (If you expect perfect errno behavior, do not use this) 4027 # -xdepend: Loop data dependency optimizations (need -xO3 or higher) 4028 # -xrestrict: Pointer parameters to functions do not overlap 4029 # (Similar to -xalias_level=basic usage, but less obvious sometimes. 4030 # If you pass in multiple pointers to the same data, do not use this) 4031 # -xlibmil: Inline some library routines 4032 # (If you expect perfect errno behavior, do not use this) 4033 # -xlibmopt: Use optimized math routines (CURRENTLY DISABLED) 4034 # (If you expect perfect errno behavior, do not use this) 4035 # Can cause undefined external on Solaris 8 X86 on __sincos, removing for now 4036 4037 # FIXME: this will never happen since sparc != sparcv9, ie 32 bit, which we don't build anymore. 4038 # Bug? 4039 #if test "x$OPENJDK_TARGET_CPU" = xsparc; then 4040 # CFLAGS_JDK="${CFLAGS_JDK} -xmemalign=4s" 4041 # CXXFLAGS_JDK="${CXXFLAGS_JDK} -xmemalign=4s" 4042 #fi 4043 4044 4045 4046 4047 4048 4049 ################################################################################ 4050 # $1 - Either BUILD or TARGET to pick the correct OS/CPU variables to check 4051 # conditionals against. 4052 # $2 - Optional prefix for each variable defined. 4053 4054 4055 # FLAGS_C_COMPILER_CHECK_ARGUMENTS(ARGUMENT: [ARGUMENT], IF_TRUE: [RUN-IF-TRUE], 4056 # IF_FALSE: [RUN-IF-FALSE]) 4057 # ------------------------------------------------------------ 4058 # Check that the C compiler supports an argument 4059 4060 4061 4062 4063 # FLAGS_CXX_COMPILER_CHECK_ARGUMENTS(ARGUMENT: [ARGUMENT], IF_TRUE: [RUN-IF-TRUE], 4064 # IF_FALSE: [RUN-IF-FALSE]) 4065 # ------------------------------------------------------------ 4066 # Check that the C++ compiler supports an argument 4067 4068 4069 4070 4071 # FLAGS_COMPILER_CHECK_ARGUMENTS(ARGUMENT: [ARGUMENT], IF_TRUE: [RUN-IF-TRUE], 4072 # IF_FALSE: [RUN-IF-FALSE]) 4073 # ------------------------------------------------------------ 4074 # Check that the C and C++ compilers support an argument 4075 4076 4077 4078 4079 # FLAGS_LINKER_CHECK_ARGUMENTS(ARGUMENT: [ARGUMENT], IF_TRUE: [RUN-IF-TRUE], 4080 # IF_FALSE: [RUN-IF-FALSE]) 4081 # ------------------------------------------------------------ 4082 # Check that the linker support an argument 4083 4084 4085 4086 4087 4088 4089 # FLAGS_SETUP_GCC6_COMPILER_FLAGS([PREFIX]) 4090 # Arguments: 4091 # $1 - Optional prefix for each variable defined. 4092 4093 4094 # 4095 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 4096 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4097 # 4098 # This code is free software; you can redistribute it and/or modify it 4099 # under the terms of the GNU General Public License version 2 only, as 4100 # published by the Free Software Foundation. Oracle designates this 4101 # particular file as subject to the "Classpath" exception as provided 4102 # by Oracle in the LICENSE file that accompanied this code. 4103 # 4104 # This code is distributed in the hope that it will be useful, but WITHOUT 4105 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4106 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4107 # version 2 for more details (a copy is included in the LICENSE file that 4108 # accompanied this code). 4109 # 4110 # You should have received a copy of the GNU General Public License version 4111 # 2 along with this work; if not, write to the Free Software Foundation, 4112 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4113 # 4114 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4115 # or visit www.oracle.com if you need additional information or have any 4116 # questions. 4117 # 4118 4119 4120 4121 4122 4123 cygwin_help() { 4124 case $1 in 4125 unzip) 4126 PKGHANDLER_COMMAND="( cd <location of cygwin setup.exe> && cmd /c setup -q -P unzip )" 4127 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 4128 ;; 4129 zip) 4130 PKGHANDLER_COMMAND="( cd <location of cygwin setup.exe> && cmd /c setup -q -P zip )" 4131 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 4132 ;; 4133 make) 4134 PKGHANDLER_COMMAND="( cd <location of cygwin setup.exe> && cmd /c setup -q -P make )" 4135 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 4136 ;; 4137 freetype) 4138 HELP_MSG=" 4139 The freetype library can now be build during the configure process. 4140 Download the freetype sources and unpack them into an arbitrary directory: 4141 4142 wget http://download.savannah.gnu.org/releases/freetype/freetype-2.5.3.tar.gz 4143 tar -xzf freetype-2.5.3.tar.gz 4144 4145 Then run configure with '--with-freetype-src=<freetype_src>'. This will 4146 automatically build the freetype library into '<freetype_src>/lib64' for 64-bit 4147 builds or into '<freetype_src>/lib32' for 32-bit builds. 4148 Afterwards you can always use '--with-freetype-include=<freetype_src>/include' 4149 and '--with-freetype-lib=<freetype_src>/lib32|64' for other builds. 4150 4151 Alternatively you can unpack the sources like this to use the default directory: 4152 4153 tar --one-top-level=$HOME/freetype --strip-components=1 -xzf freetype-2.5.3.tar.gz" 4154 ;; 4155 esac 4156 } 4157 4158 msys_help() { 4159 PKGHANDLER_COMMAND="" 4160 } 4161 4162 apt_help() { 4163 case $1 in 4164 reduced) 4165 PKGHANDLER_COMMAND="sudo apt-get install gcc-multilib g++-multilib" ;; 4166 devkit) 4167 PKGHANDLER_COMMAND="sudo apt-get install build-essential" ;; 4168 openjdk) 4169 PKGHANDLER_COMMAND="sudo apt-get install openjdk-8-jdk" ;; 4170 alsa) 4171 PKGHANDLER_COMMAND="sudo apt-get install libasound2-dev" ;; 4172 cups) 4173 PKGHANDLER_COMMAND="sudo apt-get install libcups2-dev" ;; 4174 freetype) 4175 PKGHANDLER_COMMAND="sudo apt-get install libfreetype6-dev" ;; 4176 ffi) 4177 PKGHANDLER_COMMAND="sudo apt-get install libffi-dev" ;; 4178 x11) 4179 PKGHANDLER_COMMAND="sudo apt-get install libX11-dev libxext-dev libxrender-dev libxtst-dev libxt-dev" ;; 4180 ccache) 4181 PKGHANDLER_COMMAND="sudo apt-get install ccache" ;; 4182 dtrace) 4183 PKGHANDLER_COMMAND="sudo apt-get install systemtap-sdt-dev" ;; 4184 esac 4185 } 4186 4187 yum_help() { 4188 case $1 in 4189 devkit) 4190 PKGHANDLER_COMMAND="sudo yum groupinstall \"Development Tools\"" ;; 4191 openjdk) 4192 PKGHANDLER_COMMAND="sudo yum install java-1.8.0-openjdk-devel" ;; 4193 alsa) 4194 PKGHANDLER_COMMAND="sudo yum install alsa-lib-devel" ;; 4195 cups) 4196 PKGHANDLER_COMMAND="sudo yum install cups-devel" ;; 4197 freetype) 4198 PKGHANDLER_COMMAND="sudo yum install freetype-devel" ;; 4199 x11) 4200 PKGHANDLER_COMMAND="sudo yum install libXtst-devel libXt-devel libXrender-devel libXi-devel" ;; 4201 ccache) 4202 PKGHANDLER_COMMAND="sudo yum install ccache" ;; 4203 esac 4204 } 4205 4206 port_help() { 4207 PKGHANDLER_COMMAND="" 4208 } 4209 4210 pkgutil_help() { 4211 PKGHANDLER_COMMAND="" 4212 } 4213 4214 pkgadd_help() { 4215 PKGHANDLER_COMMAND="" 4216 } 4217 4218 # This function will check if we're called from the "configure" wrapper while 4219 # printing --help. If so, we will print out additional information that can 4220 # only be extracted within the autoconf script, and then exit. This must be 4221 # called at the very beginning in configure.ac. 4222 4223 4224 4225 4226 4227 4228 # 4229 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 4230 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4231 # 4232 # This code is free software; you can redistribute it and/or modify it 4233 # under the terms of the GNU General Public License version 2 only, as 4234 # published by the Free Software Foundation. Oracle designates this 4235 # particular file as subject to the "Classpath" exception as provided 4236 # by Oracle in the LICENSE file that accompanied this code. 4237 # 4238 # This code is distributed in the hope that it will be useful, but WITHOUT 4239 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4240 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4241 # version 2 for more details (a copy is included in the LICENSE file that 4242 # accompanied this code). 4243 # 4244 # You should have received a copy of the GNU General Public License version 4245 # 2 along with this work; if not, write to the Free Software Foundation, 4246 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4247 # 4248 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4249 # or visit www.oracle.com if you need additional information or have any 4250 # questions. 4251 # 4252 4253 # All valid JVM features, regardless of platform 4254 VALID_JVM_FEATURES="compiler1 compiler2 zero shark minimal dtrace jvmti jvmci \ 4255 fprof vm-structs jni-check services management all-gcs nmt cds static-build" 4256 4257 # All valid JVM variants 4258 VALID_JVM_VARIANTS="server client minimal core zero zeroshark custom" 4259 4260 ############################################################################### 4261 # Check if the specified JVM variant should be built. To be used in shell if 4262 # constructs, like this: 4263 # if HOTSPOT_CHECK_JVM_VARIANT(server); then 4264 # 4265 # Only valid to use after HOTSPOT_SETUP_JVM_VARIANTS has setup variants. 4266 4267 # Definition kept in one line to allow inlining in if statements. 4268 # Additional [] needed to keep m4 from mangling shell constructs. 4269 4270 4271 ############################################################################### 4272 # Check if the specified JVM features are explicitly enabled. To be used in 4273 # shell if constructs, like this: 4274 # if HOTSPOT_CHECK_JVM_FEATURE(jvmti); then 4275 # 4276 # Only valid to use after HOTSPOT_SETUP_JVM_FEATURES has setup features. 4277 4278 # Definition kept in one line to allow inlining in if statements. 4279 # Additional [] needed to keep m4 from mangling shell constructs. 4280 4281 4282 ############################################################################### 4283 # Check which variants of the JVM that we want to build. Available variants are: 4284 # server: normal interpreter, and a tiered C1/C2 compiler 4285 # client: normal interpreter, and C1 (no C2 compiler) 4286 # minimal: reduced form of client with optional features stripped out 4287 # core: normal interpreter only, no compiler 4288 # zero: C++ based interpreter only, no compiler 4289 # zeroshark: C++ based interpreter, and a llvm-based compiler 4290 # custom: baseline JVM with no default features 4291 # 4292 4293 4294 ############################################################################### 4295 # Check if dtrace should be enabled and has all prerequisites present. 4296 # 4297 4298 4299 ############################################################################### 4300 # Set up all JVM features for each JVM variant. 4301 # 4302 4303 4304 ############################################################################### 4305 # Validate JVM features once all setup is complete, including custom setup. 4306 # 4307 4308 4309 ################################################################################ 4310 # Check if gtest should be built 4311 # 4312 4313 4314 # 4315 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 4316 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4317 # 4318 # This code is free software; you can redistribute it and/or modify it 4319 # under the terms of the GNU General Public License version 2 only, as 4320 # published by the Free Software Foundation. Oracle designates this 4321 # particular file as subject to the "Classpath" exception as provided 4322 # by Oracle in the LICENSE file that accompanied this code. 4323 # 4324 # This code is distributed in the hope that it will be useful, but WITHOUT 4325 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4326 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4327 # version 2 for more details (a copy is included in the LICENSE file that 4328 # accompanied this code). 4329 # 4330 # You should have received a copy of the GNU General Public License version 4331 # 2 along with this work; if not, write to the Free Software Foundation, 4332 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4333 # 4334 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4335 # or visit www.oracle.com if you need additional information or have any 4336 # questions. 4337 # 4338 4339 ############################################################################### 4340 # Check which variant of the JDK that we want to build. 4341 # Currently we have: 4342 # normal: standard edition 4343 # but the custom make system may add other variants 4344 # 4345 # Effectively the JDK variant gives a name to a specific set of 4346 # modules to compile into the JDK. 4347 4348 4349 ############################################################################### 4350 # Set the debug level 4351 # release: no debug information, all optimizations, no asserts. 4352 # optimized: no debug information, all optimizations, no asserts, HotSpot target is 'optimized'. 4353 # fastdebug: debug information (-g), all optimizations, all asserts 4354 # slowdebug: debug information (-g), no optimizations, all asserts 4355 4356 4357 ############################################################################### 4358 # 4359 # Should we build only OpenJDK even if closed sources are present? 4360 # 4361 4362 4363 4364 4365 ############################################################################### 4366 # 4367 # Enable or disable the elliptic curve crypto implementation 4368 # 4369 4370 4371 4372 4373 ################################################################################ 4374 # 4375 # Gcov coverage data for hotspot 4376 # 4377 4378 4379 ################################################################################ 4380 # 4381 # Static build support. When enabled will generate static 4382 # libraries instead of shared libraries for all JDK libs. 4383 # 4384 4385 4386 ################################################################################ 4387 # 4388 # jlink options. 4389 # We always keep packaged modules in JDK image. 4390 # 4391 4392 4393 ################################################################################ 4394 # 4395 # Check if building of the jtreg failure handler should be enabled. 4396 # 4397 4398 4399 ################################################################################ 4400 # 4401 # Enable or disable generation of the classlist at build time 4402 # 4403 4404 4405 # 4406 # Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. 4407 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4408 # 4409 # This code is free software; you can redistribute it and/or modify it 4410 # under the terms of the GNU General Public License version 2 only, as 4411 # published by the Free Software Foundation. Oracle designates this 4412 # particular file as subject to the "Classpath" exception as provided 4413 # by Oracle in the LICENSE file that accompanied this code. 4414 # 4415 # This code is distributed in the hope that it will be useful, but WITHOUT 4416 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4417 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4418 # version 2 for more details (a copy is included in the LICENSE file that 4419 # accompanied this code). 4420 # 4421 # You should have received a copy of the GNU General Public License version 4422 # 2 along with this work; if not, write to the Free Software Foundation, 4423 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4424 # 4425 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4426 # or visit www.oracle.com if you need additional information or have any 4427 # questions. 4428 # 4429 4430 ############################################################################### 4431 # 4432 # Setup version numbers 4433 # 4434 4435 # Verify that a given string represents a valid version number, and assign it 4436 # to a variable. 4437 4438 # Argument 1: the variable to assign to 4439 # Argument 2: the value given by the user 4440 4441 4442 4443 4444 # 4445 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 4446 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4447 # 4448 # This code is free software; you can redistribute it and/or modify it 4449 # under the terms of the GNU General Public License version 2 only, as 4450 # published by the Free Software Foundation. Oracle designates this 4451 # particular file as subject to the "Classpath" exception as provided 4452 # by Oracle in the LICENSE file that accompanied this code. 4453 # 4454 # This code is distributed in the hope that it will be useful, but WITHOUT 4455 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4456 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4457 # version 2 for more details (a copy is included in the LICENSE file that 4458 # accompanied this code). 4459 # 4460 # You should have received a copy of the GNU General Public License version 4461 # 2 along with this work; if not, write to the Free Software Foundation, 4462 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4463 # 4464 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4465 # or visit www.oracle.com if you need additional information or have any 4466 # questions. 4467 # 4468 4469 # Major library component reside in separate files. 4470 # 4471 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. 4472 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4473 # 4474 # This code is free software; you can redistribute it and/or modify it 4475 # under the terms of the GNU General Public License version 2 only, as 4476 # published by the Free Software Foundation. Oracle designates this 4477 # particular file as subject to the "Classpath" exception as provided 4478 # by Oracle in the LICENSE file that accompanied this code. 4479 # 4480 # This code is distributed in the hope that it will be useful, but WITHOUT 4481 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4482 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4483 # version 2 for more details (a copy is included in the LICENSE file that 4484 # accompanied this code). 4485 # 4486 # You should have received a copy of the GNU General Public License version 4487 # 2 along with this work; if not, write to the Free Software Foundation, 4488 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4489 # 4490 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4491 # or visit www.oracle.com if you need additional information or have any 4492 # questions. 4493 # 4494 4495 ################################################################################ 4496 # Setup alsa (Advanced Linux Sound Architecture) 4497 ################################################################################ 4498 4499 4500 # 4501 # Copyright (c) 2011, 2015, 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 ################################################################################ 4526 # Setup bundled libraries. 4527 # 4528 # For libjpeg, giflib, libpng, lcms2 and zlib, the source is present in the 4529 # OpenJDK repository. Default is to use these libraries as bundled, but they 4530 # might be replaced by en external version by the user. 4531 ################################################################################ 4532 4533 4534 ################################################################################ 4535 # Setup libjpeg 4536 ################################################################################ 4537 4538 4539 ################################################################################ 4540 # Setup giflib 4541 ################################################################################ 4542 4543 4544 ################################################################################ 4545 # Setup libpng 4546 ################################################################################ 4547 4548 4549 ################################################################################ 4550 # Setup zlib 4551 ################################################################################ 4552 4553 4554 ################################################################################ 4555 # Setup lcms (Little CMS) 4556 ################################################################################ 4557 4558 4559 # 4560 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 4561 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4562 # 4563 # This code is free software; you can redistribute it and/or modify it 4564 # under the terms of the GNU General Public License version 2 only, as 4565 # published by the Free Software Foundation. Oracle designates this 4566 # particular file as subject to the "Classpath" exception as provided 4567 # by Oracle in the LICENSE file that accompanied this code. 4568 # 4569 # This code is distributed in the hope that it will be useful, but WITHOUT 4570 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4571 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4572 # version 2 for more details (a copy is included in the LICENSE file that 4573 # accompanied this code). 4574 # 4575 # You should have received a copy of the GNU General Public License version 4576 # 2 along with this work; if not, write to the Free Software Foundation, 4577 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4578 # 4579 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4580 # or visit www.oracle.com if you need additional information or have any 4581 # questions. 4582 # 4583 4584 ################################################################################ 4585 # Setup cups (Common Unix Printing System) 4586 ################################################################################ 4587 4588 4589 # 4590 # Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. 4591 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4592 # 4593 # This code is free software; you can redistribute it and/or modify it 4594 # under the terms of the GNU General Public License version 2 only, as 4595 # published by the Free Software Foundation. Oracle designates this 4596 # particular file as subject to the "Classpath" exception as provided 4597 # by Oracle in the LICENSE file that accompanied this code. 4598 # 4599 # This code is distributed in the hope that it will be useful, but WITHOUT 4600 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4601 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4602 # version 2 for more details (a copy is included in the LICENSE file that 4603 # accompanied this code). 4604 # 4605 # You should have received a copy of the GNU General Public License version 4606 # 2 along with this work; if not, write to the Free Software Foundation, 4607 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4608 # 4609 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4610 # or visit www.oracle.com if you need additional information or have any 4611 # questions. 4612 # 4613 4614 ################################################################################ 4615 # Setup libffi (Foreign Function Interface) 4616 ################################################################################ 4617 4618 4619 # 4620 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. 4621 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4622 # 4623 # This code is free software; you can redistribute it and/or modify it 4624 # under the terms of the GNU General Public License version 2 only, as 4625 # published by the Free Software Foundation. Oracle designates this 4626 # particular file as subject to the "Classpath" exception as provided 4627 # by Oracle in the LICENSE file that accompanied this code. 4628 # 4629 # This code is distributed in the hope that it will be useful, but WITHOUT 4630 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4631 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4632 # version 2 for more details (a copy is included in the LICENSE file that 4633 # accompanied this code). 4634 # 4635 # You should have received a copy of the GNU General Public License version 4636 # 2 along with this work; if not, write to the Free Software Foundation, 4637 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4638 # 4639 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4640 # or visit www.oracle.com if you need additional information or have any 4641 # questions. 4642 # 4643 4644 ################################################################################ 4645 # Build the freetype lib from source 4646 ################################################################################ 4647 4648 4649 ################################################################################ 4650 # Check if a potential freeype library match is correct and usable 4651 ################################################################################ 4652 4653 4654 ################################################################################ 4655 # Setup freetype (The FreeType2 font rendering library) 4656 ################################################################################ 4657 4658 4659 # 4660 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 4661 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4662 # 4663 # This code is free software; you can redistribute it and/or modify it 4664 # under the terms of the GNU General Public License version 2 only, as 4665 # published by the Free Software Foundation. Oracle designates this 4666 # particular file as subject to the "Classpath" exception as provided 4667 # by Oracle in the LICENSE file that accompanied this code. 4668 # 4669 # This code is distributed in the hope that it will be useful, but WITHOUT 4670 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4671 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4672 # version 2 for more details (a copy is included in the LICENSE file that 4673 # accompanied this code). 4674 # 4675 # You should have received a copy of the GNU General Public License version 4676 # 2 along with this work; if not, write to the Free Software Foundation, 4677 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4678 # 4679 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4680 # or visit www.oracle.com if you need additional information or have any 4681 # questions. 4682 # 4683 4684 ################################################################################ 4685 # Setup the standard C/C++ runtime libraries. 4686 # 4687 # Most importantly, determine if stdc++ should be linked statically or 4688 # dynamically. 4689 ################################################################################ 4690 4691 4692 # 4693 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. 4694 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4695 # 4696 # This code is free software; you can redistribute it and/or modify it 4697 # under the terms of the GNU General Public License version 2 only, as 4698 # published by the Free Software Foundation. Oracle designates this 4699 # particular file as subject to the "Classpath" exception as provided 4700 # by Oracle in the LICENSE file that accompanied this code. 4701 # 4702 # This code is distributed in the hope that it will be useful, but WITHOUT 4703 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4704 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4705 # version 2 for more details (a copy is included in the LICENSE file that 4706 # accompanied this code). 4707 # 4708 # You should have received a copy of the GNU General Public License version 4709 # 2 along with this work; if not, write to the Free Software Foundation, 4710 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4711 # 4712 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4713 # or visit www.oracle.com if you need additional information or have any 4714 # questions. 4715 # 4716 4717 ################################################################################ 4718 # Setup X11 Windows system 4719 ################################################################################ 4720 4721 4722 4723 ################################################################################ 4724 # Determine which libraries are needed for this configuration 4725 ################################################################################ 4726 4727 4728 ################################################################################ 4729 # Parse library options, and setup needed libraries 4730 ################################################################################ 4731 4732 4733 ################################################################################ 4734 # Setup llvm (Low-Level VM) 4735 ################################################################################ 4736 4737 4738 ################################################################################ 4739 # Setup various libraries, typically small system libraries 4740 ################################################################################ 4741 4742 4743 ################################################################################ 4744 # libstlport.so.1 is needed for running gtest on Solaris. Find it to 4745 # redistribute it in the test image. 4746 ################################################################################ 4747 4748 4749 4750 # 4751 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 4752 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4753 # 4754 # This code is free software; you can redistribute it and/or modify it 4755 # under the terms of the GNU General Public License version 2 only, as 4756 # published by the Free Software Foundation. Oracle designates this 4757 # particular file as subject to the "Classpath" exception as provided 4758 # by Oracle in the LICENSE file that accompanied this code. 4759 # 4760 # This code is distributed in the hope that it will be useful, but WITHOUT 4761 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4762 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4763 # version 2 for more details (a copy is included in the LICENSE file that 4764 # accompanied this code). 4765 # 4766 # You should have received a copy of the GNU General Public License version 4767 # 2 along with this work; if not, write to the Free Software Foundation, 4768 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4769 # 4770 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4771 # or visit www.oracle.com if you need additional information or have any 4772 # questions. 4773 # 4774 4775 # Support macro for PLATFORM_EXTRACT_TARGET_AND_BUILD. 4776 # Converts autoconf style CPU name to OpenJDK style, into 4777 # VAR_CPU, VAR_CPU_ARCH, VAR_CPU_BITS and VAR_CPU_ENDIAN. 4778 4779 4780 # Support macro for PLATFORM_EXTRACT_TARGET_AND_BUILD. 4781 # Converts autoconf style OS name to OpenJDK style, into 4782 # VAR_OS, VAR_OS_TYPE and VAR_OS_ENV. 4783 4784 4785 # Expects $host_os $host_cpu $build_os and $build_cpu 4786 # and $with_target_bits to have been setup! 4787 # 4788 # Translate the standard triplet(quadruplet) definition 4789 # of the target/build system into OPENJDK_TARGET_OS, OPENJDK_TARGET_CPU, 4790 # OPENJDK_BUILD_OS, etc. 4791 4792 4793 # Check if a reduced build (32-bit on 64-bit platforms) is requested, and modify behaviour 4794 # accordingly. Must be done after setting up build and target system, but before 4795 # doing anything else with these values. 4796 4797 4798 # Setup the legacy variables, for controlling the old makefiles. 4799 # 4800 4801 4802 # $1 - Either TARGET or BUILD to setup the variables for. 4803 4804 4805 4806 4807 #%%% Build and target systems %%% 4808 4809 4810 4811 4812 # Support macro for PLATFORM_SETUP_OPENJDK_TARGET_BITS. 4813 # Add -mX to various FLAGS variables. 4814 4815 4816 4817 4818 4819 4820 # 4821 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. 4822 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4823 # 4824 # This code is free software; you can redistribute it and/or modify it 4825 # under the terms of the GNU General Public License version 2 only, as 4826 # published by the Free Software Foundation. Oracle designates this 4827 # particular file as subject to the "Classpath" exception as provided 4828 # by Oracle in the LICENSE file that accompanied this code. 4829 # 4830 # This code is distributed in the hope that it will be useful, but WITHOUT 4831 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4832 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4833 # version 2 for more details (a copy is included in the LICENSE file that 4834 # accompanied this code). 4835 # 4836 # You should have received a copy of the GNU General Public License version 4837 # 2 along with this work; if not, write to the Free Software Foundation, 4838 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4839 # 4840 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4841 # or visit www.oracle.com if you need additional information or have any 4842 # questions. 4843 # 4844 4845 4846 4847 4848 4849 4850 4851 ################################################################################ 4852 # Define a mechanism for importing extra prebuilt modules 4853 # 4854 4855 4856 4857 # 4858 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 4859 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4860 # 4861 # This code is free software; you can redistribute it and/or modify it 4862 # under the terms of the GNU General Public License version 2 only, as 4863 # published by the Free Software Foundation. Oracle designates this 4864 # particular file as subject to the "Classpath" exception as provided 4865 # by Oracle in the LICENSE file that accompanied this code. 4866 # 4867 # This code is distributed in the hope that it will be useful, but WITHOUT 4868 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4869 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4870 # version 2 for more details (a copy is included in the LICENSE file that 4871 # accompanied this code). 4872 # 4873 # You should have received a copy of the GNU General Public License version 4874 # 2 along with this work; if not, write to the Free Software Foundation, 4875 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4876 # 4877 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4878 # or visit www.oracle.com if you need additional information or have any 4879 # questions. 4880 # 4881 4882 ######################################################################## 4883 # This file is responsible for detecting, verifying and setting up the 4884 # toolchain, i.e. the compiler, linker and related utilities. It will setup 4885 # proper paths to the binaries, but it will not setup any flags. 4886 # 4887 # The binaries used is determined by the toolchain type, which is the family of 4888 # compilers and related tools that are used. 4889 ######################################################################## 4890 4891 4892 # All valid toolchains, regardless of platform (used by help.m4) 4893 VALID_TOOLCHAINS_all="gcc clang solstudio xlc microsoft" 4894 4895 # These toolchains are valid on different platforms 4896 VALID_TOOLCHAINS_linux="gcc clang" 4897 VALID_TOOLCHAINS_solaris="solstudio" 4898 VALID_TOOLCHAINS_macosx="gcc clang" 4899 VALID_TOOLCHAINS_aix="xlc" 4900 VALID_TOOLCHAINS_windows="microsoft" 4901 4902 # Toolchain descriptions 4903 TOOLCHAIN_DESCRIPTION_clang="clang/LLVM" 4904 TOOLCHAIN_DESCRIPTION_gcc="GNU Compiler Collection" 4905 TOOLCHAIN_DESCRIPTION_microsoft="Microsoft Visual Studio" 4906 TOOLCHAIN_DESCRIPTION_solstudio="Oracle Solaris Studio" 4907 TOOLCHAIN_DESCRIPTION_xlc="IBM XL C/C++" 4908 4909 # Minimum supported versions, empty means unspecified 4910 TOOLCHAIN_MINIMUM_VERSION_clang="3.2" 4911 TOOLCHAIN_MINIMUM_VERSION_gcc="4.3" 4912 TOOLCHAIN_MINIMUM_VERSION_microsoft="" 4913 TOOLCHAIN_MINIMUM_VERSION_solstudio="5.13" 4914 TOOLCHAIN_MINIMUM_VERSION_xlc="" 4915 4916 # Prepare the system so that TOOLCHAIN_CHECK_COMPILER_VERSION can be called. 4917 # Must have CC_VERSION_NUMBER and CXX_VERSION_NUMBER. 4918 # $1 - optional variable prefix for compiler and version variables (BUILD_) 4919 # $2 - optional variable prefix for comparable variable (OPENJDK_BUILD_) 4920 4921 4922 # Check if the configured compiler (C and C++) is of a specific version or 4923 # newer. TOOLCHAIN_PREPARE_FOR_VERSION_COMPARISONS must have been called before. 4924 # 4925 # Arguments: 4926 # VERSION: The version string to check against the found version 4927 # IF_AT_LEAST: block to run if the compiler is at least this version (>=) 4928 # IF_OLDER_THAN: block to run if the compiler is older than this version (<) 4929 # PREFIX: Optional variable prefix for compiler to compare version for (OPENJDK_BUILD_) 4930 4931 4932 4933 4934 # Setup a number of variables describing how native output files are 4935 # named on this platform/toolchain. 4936 4937 4938 # Determine which toolchain type to use, and make sure it is valid for this 4939 # platform. Setup various information about the selected toolchain. 4940 4941 4942 # Before we start detecting the toolchain executables, we might need some 4943 # special setup, e.g. additional paths etc. 4944 4945 4946 # Restore path, etc 4947 4948 4949 # Check if a compiler is of the toolchain type we expect, and save the version 4950 # information from it. If the compiler does not match the expected type, 4951 # this function will abort using AC_MSG_ERROR. If it matches, the version will 4952 # be stored in CC_VERSION_NUMBER/CXX_VERSION_NUMBER (as a dotted number), and 4953 # the full version string in CC_VERSION_STRING/CXX_VERSION_STRING. 4954 # 4955 # $1 = compiler to test (CC or CXX) 4956 # $2 = human readable name of compiler (C or C++) 4957 4958 4959 # Try to locate the given C or C++ compiler in the path, or otherwise. 4960 # 4961 # $1 = compiler to test (CC or CXX) 4962 # $2 = human readable name of compiler (C or C++) 4963 # $3 = list of compiler names to search for 4964 4965 4966 # Detect the core components of the toolchain, i.e. the compilers (CC and CXX), 4967 # preprocessor (CPP and CXXCPP), the linker (LD), the assembler (AS) and the 4968 # archiver (AR). Verify that the compilers are correct according to the 4969 # toolchain type. 4970 4971 4972 # Setup additional tools that is considered a part of the toolchain, but not the 4973 # core part. Many of these are highly platform-specific and do not exist, 4974 # and/or are not needed on all platforms. 4975 4976 4977 # Setup the build tools (i.e, the compiler and linker used to build programs 4978 # that should be run on the build platform, not the target platform, as a build 4979 # helper). Since the non-cross-compile case uses the normal, target compilers 4980 # for this, we can only do this after these have been setup. 4981 4982 4983 # Setup legacy variables that are still needed as alternative ways to refer to 4984 # parts of the toolchain. 4985 4986 4987 # Do some additional checks on the detected tools. 4988 4989 4990 # Setup the JTReg Regression Test Harness. 4991 4992 4993 # 4994 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. 4995 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4996 # 4997 # This code is free software; you can redistribute it and/or modify it 4998 # under the terms of the GNU General Public License version 2 only, as 4999 # published by the Free Software Foundation. Oracle designates this 5000 # particular file as subject to the "Classpath" exception as provided 5001 # by Oracle in the LICENSE file that accompanied this code. 5002 # 5003 # This code is distributed in the hope that it will be useful, but WITHOUT 5004 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 5005 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 5006 # version 2 for more details (a copy is included in the LICENSE file that 5007 # accompanied this code). 5008 # 5009 # You should have received a copy of the GNU General Public License version 5010 # 2 along with this work; if not, write to the Free Software Foundation, 5011 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 5012 # 5013 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 5014 # or visit www.oracle.com if you need additional information or have any 5015 # questions. 5016 # 5017 5018 ################################################################################ 5019 # The order of these defines the priority by which we try to find them. 5020 VALID_VS_VERSIONS="2013 2012 2010" 5021 5022 VS_DESCRIPTION_2010="Microsoft Visual Studio 2010" 5023 VS_VERSION_INTERNAL_2010=100 5024 VS_MSVCR_2010=msvcr100.dll 5025 # We don't use msvcp on Visual Studio 2010 5026 #VS_MSVCP_2010=msvcp100.dll 5027 VS_ENVVAR_2010="VS100COMNTOOLS" 5028 VS_VS_INSTALLDIR_2010="Microsoft Visual Studio 10.0" 5029 VS_SDK_INSTALLDIR_2010="Microsoft SDKs/Windows/v7.1" 5030 VS_VS_PLATFORM_NAME_2010="v100" 5031 VS_SDK_PLATFORM_NAME_2010="Windows7.1SDK" 5032 5033 VS_DESCRIPTION_2012="Microsoft Visual Studio 2012" 5034 VS_VERSION_INTERNAL_2012=110 5035 VS_MSVCR_2012=msvcr110.dll 5036 VS_MSVCP_2012=msvcp110.dll 5037 VS_ENVVAR_2012="VS110COMNTOOLS" 5038 VS_VS_INSTALLDIR_2012="Microsoft Visual Studio 11.0" 5039 VS_SDK_INSTALLDIR_2012= 5040 VS_VS_PLATFORM_NAME_2012="v110" 5041 VS_SDK_PLATFORM_NAME_2012= 5042 5043 VS_DESCRIPTION_2013="Microsoft Visual Studio 2013" 5044 VS_VERSION_INTERNAL_2013=120 5045 VS_MSVCR_2013=msvcr120.dll 5046 VS_MSVCP_2013=msvcp120.dll 5047 VS_ENVVAR_2013="VS120COMNTOOLS" 5048 VS_VS_INSTALLDIR_2013="Microsoft Visual Studio 12.0" 5049 VS_SDK_INSTALLDIR_2013= 5050 VS_VS_PLATFORM_NAME_2013="v120" 5051 VS_SDK_PLATFORM_NAME_2013= 5052 5053 ################################################################################ 5054 5055 5056 5057 ################################################################################ 5058 5059 5060 5061 ################################################################################ 5062 # Finds the bat or cmd file in Visual Studio or the SDK that sets up a proper 5063 # build environment and assigns it to VS_ENV_CMD 5064 5065 5066 ################################################################################ 5067 5068 5069 5070 ################################################################################ 5071 # Check if the VS env variables were setup prior to running configure. 5072 # If not, then find vcvarsall.bat and run it automatically, and integrate 5073 # the set env variables into the spec file. 5074 5075 5076 5077 5078 5079 5080 5081 5082 5083 5084 5085 5086 5087 5088 # This line needs to be here, verbatim, after all includes and the dummy hook 5089 # definitions. It is replaced with custom functionality when building 5090 # custom sources. 5091 #CUSTOM_AUTOCONF_INCLUDE 5092 5093 # Do not change or remove the following line, it is needed for consistency checks: 5094 DATE_WHEN_GENERATED=1475062505 5095 5096 ############################################################################### 5097 # 5098 # Initialization / Boot-strapping 5099 # 5100 # The bootstrapping process needs to solve the "chicken or the egg" problem, 5101 # thus it jumps back and forth, each time gaining something needed later on. 5102 # 5103 ############################################################################### 5104 5105 # If we are requested to print additional help, do that and then exit. 5106 # This must be the very first call. 5107 5108 if test "x$CONFIGURE_PRINT_ADDITIONAL_HELP" != x; then 5109 5110 # Print available toolchains 5111 $PRINTF "The following toolchains are available as arguments to --with-toolchain-type.\n" 5112 $PRINTF "Which are valid to use depends on the build platform.\n" 5113 for toolchain in $VALID_TOOLCHAINS_all; do 5114 # Use indirect variable referencing 5115 toolchain_var_name=TOOLCHAIN_DESCRIPTION_$toolchain 5116 TOOLCHAIN_DESCRIPTION=${!toolchain_var_name} 5117 $PRINTF " %-10s %s\n" $toolchain "$TOOLCHAIN_DESCRIPTION" 5118 done 5119 $PRINTF "\n" 5120 5121 # Print available jvm features 5122 $PRINTF "The following JVM features are available as arguments to --with-jvm-features.\n" 5123 $PRINTF "Which are valid to use depends on the target platform.\n " 5124 $PRINTF "%s " $VALID_JVM_FEATURES 5125 $PRINTF "\n" 5126 5127 # And now exit directly 5128 exit 0 5129 fi 5130 5131 5132 # Basic initialization that must happen first of all in the normal process. 5133 5134 # Save the original command line. This is passed to us by the wrapper configure script. 5135 5136 # Save the path variable before it gets changed 5137 ORIGINAL_PATH="$PATH" 5138 5139 DATE_WHEN_CONFIGURED=`LANG=C date` 5140 5141 { $as_echo "$as_me:${as_lineno-$LINENO}: Configuration created at $DATE_WHEN_CONFIGURED." >&5 5142 $as_echo "$as_me: Configuration created at $DATE_WHEN_CONFIGURED." >&6;} 5143 { $as_echo "$as_me:${as_lineno-$LINENO}: configure script generated at timestamp $DATE_WHEN_GENERATED." >&5 5144 $as_echo "$as_me: configure script generated at timestamp $DATE_WHEN_GENERATED." >&6;} 5145 5146 5147 # Start with tools that do not need have cross compilation support 5148 # and can be expected to be found in the default PATH. These tools are 5149 # used by configure. 5150 5151 # First are all the simple required tools. 5152 5153 5154 5155 # Publish this variable in the help. 5156 5157 5158 if [ -z "${BASENAME+x}" ]; then 5159 # The variable is not set by user, try to locate tool using the code snippet 5160 for ac_prog in basename 5161 do 5162 # Extract the first word of "$ac_prog", so it can be a program name with args. 5163 set dummy $ac_prog; ac_word=$2 5164 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5165 $as_echo_n "checking for $ac_word... " >&6; } 5166 if ${ac_cv_path_BASENAME+:} false; then : 5167 $as_echo_n "(cached) " >&6 5168 else 5169 case $BASENAME in 5170 [\\/]* | ?:[\\/]*) 5171 ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path. 5172 ;; 5173 *) 5174 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5175 for as_dir in $PATH 5176 do 5177 IFS=$as_save_IFS 5178 test -z "$as_dir" && as_dir=. 5179 for ac_exec_ext in '' $ac_executable_extensions; do 5180 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5181 ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext" 5182 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5183 break 2 5184 fi 5185 done 5186 done 5187 IFS=$as_save_IFS 5188 5189 ;; 5190 esac 5191 fi 5192 BASENAME=$ac_cv_path_BASENAME 5193 if test -n "$BASENAME"; then 5194 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5 5195 $as_echo "$BASENAME" >&6; } 5196 else 5197 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5198 $as_echo "no" >&6; } 5199 fi 5200 5201 5202 test -n "$BASENAME" && break 5203 done 5204 5205 else 5206 # The variable is set, but is it from the command line or the environment? 5207 5208 # Try to remove the string !BASENAME! from our list. 5209 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BASENAME!/} 5210 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 5211 # If it failed, the variable was not from the command line. Ignore it, 5212 # but warn the user (except for BASH, which is always set by the calling BASH). 5213 if test "xBASENAME" != xBASH; then 5214 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BASENAME from the environment. Use command line variables instead." >&5 5215 $as_echo "$as_me: WARNING: Ignoring value of BASENAME from the environment. Use command line variables instead." >&2;} 5216 fi 5217 # Try to locate tool using the code snippet 5218 for ac_prog in basename 5219 do 5220 # Extract the first word of "$ac_prog", so it can be a program name with args. 5221 set dummy $ac_prog; ac_word=$2 5222 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5223 $as_echo_n "checking for $ac_word... " >&6; } 5224 if ${ac_cv_path_BASENAME+:} false; then : 5225 $as_echo_n "(cached) " >&6 5226 else 5227 case $BASENAME in 5228 [\\/]* | ?:[\\/]*) 5229 ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path. 5230 ;; 5231 *) 5232 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5233 for as_dir in $PATH 5234 do 5235 IFS=$as_save_IFS 5236 test -z "$as_dir" && as_dir=. 5237 for ac_exec_ext in '' $ac_executable_extensions; do 5238 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5239 ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext" 5240 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5241 break 2 5242 fi 5243 done 5244 done 5245 IFS=$as_save_IFS 5246 5247 ;; 5248 esac 5249 fi 5250 BASENAME=$ac_cv_path_BASENAME 5251 if test -n "$BASENAME"; then 5252 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5 5253 $as_echo "$BASENAME" >&6; } 5254 else 5255 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5256 $as_echo "no" >&6; } 5257 fi 5258 5259 5260 test -n "$BASENAME" && break 5261 done 5262 5263 else 5264 # If it succeeded, then it was overridden by the user. We will use it 5265 # for the tool. 5266 5267 # First remove it from the list of overridden variables, so we can test 5268 # for unknown variables in the end. 5269 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 5270 5271 # Check if we try to supply an empty value 5272 if test "x$BASENAME" = x; then 5273 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BASENAME= (no value)" >&5 5274 $as_echo "$as_me: Setting user supplied tool BASENAME= (no value)" >&6;} 5275 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASENAME" >&5 5276 $as_echo_n "checking for BASENAME... " >&6; } 5277 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 5278 $as_echo "disabled" >&6; } 5279 else 5280 # Check if the provided tool contains a complete path. 5281 tool_specified="$BASENAME" 5282 tool_basename="${tool_specified##*/}" 5283 if test "x$tool_basename" = "x$tool_specified"; then 5284 # A command without a complete path is provided, search $PATH. 5285 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BASENAME=$tool_basename" >&5 5286 $as_echo "$as_me: Will search for user supplied tool BASENAME=$tool_basename" >&6;} 5287 # Extract the first word of "$tool_basename", so it can be a program name with args. 5288 set dummy $tool_basename; ac_word=$2 5289 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5290 $as_echo_n "checking for $ac_word... " >&6; } 5291 if ${ac_cv_path_BASENAME+:} false; then : 5292 $as_echo_n "(cached) " >&6 5293 else 5294 case $BASENAME in 5295 [\\/]* | ?:[\\/]*) 5296 ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path. 5297 ;; 5298 *) 5299 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5300 for as_dir in $PATH 5301 do 5302 IFS=$as_save_IFS 5303 test -z "$as_dir" && as_dir=. 5304 for ac_exec_ext in '' $ac_executable_extensions; do 5305 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5306 ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext" 5307 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5308 break 2 5309 fi 5310 done 5311 done 5312 IFS=$as_save_IFS 5313 5314 ;; 5315 esac 5316 fi 5317 BASENAME=$ac_cv_path_BASENAME 5318 if test -n "$BASENAME"; then 5319 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5 5320 $as_echo "$BASENAME" >&6; } 5321 else 5322 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5323 $as_echo "no" >&6; } 5324 fi 5325 5326 5327 if test "x$BASENAME" = x; then 5328 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 5329 fi 5330 else 5331 # Otherwise we believe it is a complete path. Use it as it is. 5332 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BASENAME=$tool_specified" >&5 5333 $as_echo "$as_me: Will use user supplied tool BASENAME=$tool_specified" >&6;} 5334 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASENAME" >&5 5335 $as_echo_n "checking for BASENAME... " >&6; } 5336 if test ! -x "$tool_specified"; then 5337 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 5338 $as_echo "not found" >&6; } 5339 as_fn_error $? "User supplied tool BASENAME=$tool_specified does not exist or is not executable" "$LINENO" 5 5340 fi 5341 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 5342 $as_echo "$tool_specified" >&6; } 5343 fi 5344 fi 5345 fi 5346 5347 fi 5348 5349 5350 5351 if test "x$BASENAME" = x; then 5352 as_fn_error $? "Could not find required tool for BASENAME" "$LINENO" 5 5353 fi 5354 5355 5356 5357 5358 5359 # Publish this variable in the help. 5360 5361 5362 if [ -z "${BASH+x}" ]; then 5363 # The variable is not set by user, try to locate tool using the code snippet 5364 for ac_prog in bash 5365 do 5366 # Extract the first word of "$ac_prog", so it can be a program name with args. 5367 set dummy $ac_prog; ac_word=$2 5368 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5369 $as_echo_n "checking for $ac_word... " >&6; } 5370 if ${ac_cv_path_BASH+:} false; then : 5371 $as_echo_n "(cached) " >&6 5372 else 5373 case $BASH in 5374 [\\/]* | ?:[\\/]*) 5375 ac_cv_path_BASH="$BASH" # Let the user override the test with a path. 5376 ;; 5377 *) 5378 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5379 for as_dir in $PATH 5380 do 5381 IFS=$as_save_IFS 5382 test -z "$as_dir" && as_dir=. 5383 for ac_exec_ext in '' $ac_executable_extensions; do 5384 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5385 ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext" 5386 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5387 break 2 5388 fi 5389 done 5390 done 5391 IFS=$as_save_IFS 5392 5393 ;; 5394 esac 5395 fi 5396 BASH=$ac_cv_path_BASH 5397 if test -n "$BASH"; then 5398 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5 5399 $as_echo "$BASH" >&6; } 5400 else 5401 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5402 $as_echo "no" >&6; } 5403 fi 5404 5405 5406 test -n "$BASH" && break 5407 done 5408 5409 else 5410 # The variable is set, but is it from the command line or the environment? 5411 5412 # Try to remove the string !BASH! from our list. 5413 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BASH!/} 5414 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 5415 # If it failed, the variable was not from the command line. Ignore it, 5416 # but warn the user (except for BASH, which is always set by the calling BASH). 5417 if test "xBASH" != xBASH; then 5418 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BASH from the environment. Use command line variables instead." >&5 5419 $as_echo "$as_me: WARNING: Ignoring value of BASH from the environment. Use command line variables instead." >&2;} 5420 fi 5421 # Try to locate tool using the code snippet 5422 for ac_prog in bash 5423 do 5424 # Extract the first word of "$ac_prog", so it can be a program name with args. 5425 set dummy $ac_prog; ac_word=$2 5426 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5427 $as_echo_n "checking for $ac_word... " >&6; } 5428 if ${ac_cv_path_BASH+:} false; then : 5429 $as_echo_n "(cached) " >&6 5430 else 5431 case $BASH in 5432 [\\/]* | ?:[\\/]*) 5433 ac_cv_path_BASH="$BASH" # Let the user override the test with a path. 5434 ;; 5435 *) 5436 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5437 for as_dir in $PATH 5438 do 5439 IFS=$as_save_IFS 5440 test -z "$as_dir" && as_dir=. 5441 for ac_exec_ext in '' $ac_executable_extensions; do 5442 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5443 ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext" 5444 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5445 break 2 5446 fi 5447 done 5448 done 5449 IFS=$as_save_IFS 5450 5451 ;; 5452 esac 5453 fi 5454 BASH=$ac_cv_path_BASH 5455 if test -n "$BASH"; then 5456 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5 5457 $as_echo "$BASH" >&6; } 5458 else 5459 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5460 $as_echo "no" >&6; } 5461 fi 5462 5463 5464 test -n "$BASH" && break 5465 done 5466 5467 else 5468 # If it succeeded, then it was overridden by the user. We will use it 5469 # for the tool. 5470 5471 # First remove it from the list of overridden variables, so we can test 5472 # for unknown variables in the end. 5473 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 5474 5475 # Check if we try to supply an empty value 5476 if test "x$BASH" = x; then 5477 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BASH= (no value)" >&5 5478 $as_echo "$as_me: Setting user supplied tool BASH= (no value)" >&6;} 5479 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASH" >&5 5480 $as_echo_n "checking for BASH... " >&6; } 5481 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 5482 $as_echo "disabled" >&6; } 5483 else 5484 # Check if the provided tool contains a complete path. 5485 tool_specified="$BASH" 5486 tool_basename="${tool_specified##*/}" 5487 if test "x$tool_basename" = "x$tool_specified"; then 5488 # A command without a complete path is provided, search $PATH. 5489 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BASH=$tool_basename" >&5 5490 $as_echo "$as_me: Will search for user supplied tool BASH=$tool_basename" >&6;} 5491 # Extract the first word of "$tool_basename", so it can be a program name with args. 5492 set dummy $tool_basename; ac_word=$2 5493 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5494 $as_echo_n "checking for $ac_word... " >&6; } 5495 if ${ac_cv_path_BASH+:} false; then : 5496 $as_echo_n "(cached) " >&6 5497 else 5498 case $BASH in 5499 [\\/]* | ?:[\\/]*) 5500 ac_cv_path_BASH="$BASH" # Let the user override the test with a path. 5501 ;; 5502 *) 5503 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5504 for as_dir in $PATH 5505 do 5506 IFS=$as_save_IFS 5507 test -z "$as_dir" && as_dir=. 5508 for ac_exec_ext in '' $ac_executable_extensions; do 5509 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5510 ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext" 5511 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5512 break 2 5513 fi 5514 done 5515 done 5516 IFS=$as_save_IFS 5517 5518 ;; 5519 esac 5520 fi 5521 BASH=$ac_cv_path_BASH 5522 if test -n "$BASH"; then 5523 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5 5524 $as_echo "$BASH" >&6; } 5525 else 5526 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5527 $as_echo "no" >&6; } 5528 fi 5529 5530 5531 if test "x$BASH" = x; then 5532 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 5533 fi 5534 else 5535 # Otherwise we believe it is a complete path. Use it as it is. 5536 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BASH=$tool_specified" >&5 5537 $as_echo "$as_me: Will use user supplied tool BASH=$tool_specified" >&6;} 5538 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASH" >&5 5539 $as_echo_n "checking for BASH... " >&6; } 5540 if test ! -x "$tool_specified"; then 5541 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 5542 $as_echo "not found" >&6; } 5543 as_fn_error $? "User supplied tool BASH=$tool_specified does not exist or is not executable" "$LINENO" 5 5544 fi 5545 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 5546 $as_echo "$tool_specified" >&6; } 5547 fi 5548 fi 5549 fi 5550 5551 fi 5552 5553 5554 5555 if test "x$BASH" = x; then 5556 as_fn_error $? "Could not find required tool for BASH" "$LINENO" 5 5557 fi 5558 5559 5560 5561 5562 5563 # Publish this variable in the help. 5564 5565 5566 if [ -z "${CAT+x}" ]; then 5567 # The variable is not set by user, try to locate tool using the code snippet 5568 for ac_prog in cat 5569 do 5570 # Extract the first word of "$ac_prog", so it can be a program name with args. 5571 set dummy $ac_prog; ac_word=$2 5572 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5573 $as_echo_n "checking for $ac_word... " >&6; } 5574 if ${ac_cv_path_CAT+:} false; then : 5575 $as_echo_n "(cached) " >&6 5576 else 5577 case $CAT in 5578 [\\/]* | ?:[\\/]*) 5579 ac_cv_path_CAT="$CAT" # Let the user override the test with a path. 5580 ;; 5581 *) 5582 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5583 for as_dir in $PATH 5584 do 5585 IFS=$as_save_IFS 5586 test -z "$as_dir" && as_dir=. 5587 for ac_exec_ext in '' $ac_executable_extensions; do 5588 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5589 ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext" 5590 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5591 break 2 5592 fi 5593 done 5594 done 5595 IFS=$as_save_IFS 5596 5597 ;; 5598 esac 5599 fi 5600 CAT=$ac_cv_path_CAT 5601 if test -n "$CAT"; then 5602 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5 5603 $as_echo "$CAT" >&6; } 5604 else 5605 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5606 $as_echo "no" >&6; } 5607 fi 5608 5609 5610 test -n "$CAT" && break 5611 done 5612 5613 else 5614 # The variable is set, but is it from the command line or the environment? 5615 5616 # Try to remove the string !CAT! from our list. 5617 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CAT!/} 5618 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 5619 # If it failed, the variable was not from the command line. Ignore it, 5620 # but warn the user (except for BASH, which is always set by the calling BASH). 5621 if test "xCAT" != xBASH; then 5622 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CAT from the environment. Use command line variables instead." >&5 5623 $as_echo "$as_me: WARNING: Ignoring value of CAT from the environment. Use command line variables instead." >&2;} 5624 fi 5625 # Try to locate tool using the code snippet 5626 for ac_prog in cat 5627 do 5628 # Extract the first word of "$ac_prog", so it can be a program name with args. 5629 set dummy $ac_prog; ac_word=$2 5630 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5631 $as_echo_n "checking for $ac_word... " >&6; } 5632 if ${ac_cv_path_CAT+:} false; then : 5633 $as_echo_n "(cached) " >&6 5634 else 5635 case $CAT in 5636 [\\/]* | ?:[\\/]*) 5637 ac_cv_path_CAT="$CAT" # Let the user override the test with a path. 5638 ;; 5639 *) 5640 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5641 for as_dir in $PATH 5642 do 5643 IFS=$as_save_IFS 5644 test -z "$as_dir" && as_dir=. 5645 for ac_exec_ext in '' $ac_executable_extensions; do 5646 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5647 ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext" 5648 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5649 break 2 5650 fi 5651 done 5652 done 5653 IFS=$as_save_IFS 5654 5655 ;; 5656 esac 5657 fi 5658 CAT=$ac_cv_path_CAT 5659 if test -n "$CAT"; then 5660 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5 5661 $as_echo "$CAT" >&6; } 5662 else 5663 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5664 $as_echo "no" >&6; } 5665 fi 5666 5667 5668 test -n "$CAT" && break 5669 done 5670 5671 else 5672 # If it succeeded, then it was overridden by the user. We will use it 5673 # for the tool. 5674 5675 # First remove it from the list of overridden variables, so we can test 5676 # for unknown variables in the end. 5677 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 5678 5679 # Check if we try to supply an empty value 5680 if test "x$CAT" = x; then 5681 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CAT= (no value)" >&5 5682 $as_echo "$as_me: Setting user supplied tool CAT= (no value)" >&6;} 5683 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CAT" >&5 5684 $as_echo_n "checking for CAT... " >&6; } 5685 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 5686 $as_echo "disabled" >&6; } 5687 else 5688 # Check if the provided tool contains a complete path. 5689 tool_specified="$CAT" 5690 tool_basename="${tool_specified##*/}" 5691 if test "x$tool_basename" = "x$tool_specified"; then 5692 # A command without a complete path is provided, search $PATH. 5693 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CAT=$tool_basename" >&5 5694 $as_echo "$as_me: Will search for user supplied tool CAT=$tool_basename" >&6;} 5695 # Extract the first word of "$tool_basename", so it can be a program name with args. 5696 set dummy $tool_basename; ac_word=$2 5697 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5698 $as_echo_n "checking for $ac_word... " >&6; } 5699 if ${ac_cv_path_CAT+:} false; then : 5700 $as_echo_n "(cached) " >&6 5701 else 5702 case $CAT in 5703 [\\/]* | ?:[\\/]*) 5704 ac_cv_path_CAT="$CAT" # Let the user override the test with a path. 5705 ;; 5706 *) 5707 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5708 for as_dir in $PATH 5709 do 5710 IFS=$as_save_IFS 5711 test -z "$as_dir" && as_dir=. 5712 for ac_exec_ext in '' $ac_executable_extensions; do 5713 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5714 ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext" 5715 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5716 break 2 5717 fi 5718 done 5719 done 5720 IFS=$as_save_IFS 5721 5722 ;; 5723 esac 5724 fi 5725 CAT=$ac_cv_path_CAT 5726 if test -n "$CAT"; then 5727 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5 5728 $as_echo "$CAT" >&6; } 5729 else 5730 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5731 $as_echo "no" >&6; } 5732 fi 5733 5734 5735 if test "x$CAT" = x; then 5736 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 5737 fi 5738 else 5739 # Otherwise we believe it is a complete path. Use it as it is. 5740 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CAT=$tool_specified" >&5 5741 $as_echo "$as_me: Will use user supplied tool CAT=$tool_specified" >&6;} 5742 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CAT" >&5 5743 $as_echo_n "checking for CAT... " >&6; } 5744 if test ! -x "$tool_specified"; then 5745 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 5746 $as_echo "not found" >&6; } 5747 as_fn_error $? "User supplied tool CAT=$tool_specified does not exist or is not executable" "$LINENO" 5 5748 fi 5749 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 5750 $as_echo "$tool_specified" >&6; } 5751 fi 5752 fi 5753 fi 5754 5755 fi 5756 5757 5758 5759 if test "x$CAT" = x; then 5760 as_fn_error $? "Could not find required tool for CAT" "$LINENO" 5 5761 fi 5762 5763 5764 5765 5766 5767 # Publish this variable in the help. 5768 5769 5770 if [ -z "${CHMOD+x}" ]; then 5771 # The variable is not set by user, try to locate tool using the code snippet 5772 for ac_prog in chmod 5773 do 5774 # Extract the first word of "$ac_prog", so it can be a program name with args. 5775 set dummy $ac_prog; ac_word=$2 5776 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5777 $as_echo_n "checking for $ac_word... " >&6; } 5778 if ${ac_cv_path_CHMOD+:} false; then : 5779 $as_echo_n "(cached) " >&6 5780 else 5781 case $CHMOD in 5782 [\\/]* | ?:[\\/]*) 5783 ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path. 5784 ;; 5785 *) 5786 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5787 for as_dir in $PATH 5788 do 5789 IFS=$as_save_IFS 5790 test -z "$as_dir" && as_dir=. 5791 for ac_exec_ext in '' $ac_executable_extensions; do 5792 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5793 ac_cv_path_CHMOD="$as_dir/$ac_word$ac_exec_ext" 5794 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5795 break 2 5796 fi 5797 done 5798 done 5799 IFS=$as_save_IFS 5800 5801 ;; 5802 esac 5803 fi 5804 CHMOD=$ac_cv_path_CHMOD 5805 if test -n "$CHMOD"; then 5806 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5 5807 $as_echo "$CHMOD" >&6; } 5808 else 5809 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5810 $as_echo "no" >&6; } 5811 fi 5812 5813 5814 test -n "$CHMOD" && break 5815 done 5816 5817 else 5818 # The variable is set, but is it from the command line or the environment? 5819 5820 # Try to remove the string !CHMOD! from our list. 5821 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CHMOD!/} 5822 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 5823 # If it failed, the variable was not from the command line. Ignore it, 5824 # but warn the user (except for BASH, which is always set by the calling BASH). 5825 if test "xCHMOD" != xBASH; then 5826 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CHMOD from the environment. Use command line variables instead." >&5 5827 $as_echo "$as_me: WARNING: Ignoring value of CHMOD from the environment. Use command line variables instead." >&2;} 5828 fi 5829 # Try to locate tool using the code snippet 5830 for ac_prog in chmod 5831 do 5832 # Extract the first word of "$ac_prog", so it can be a program name with args. 5833 set dummy $ac_prog; ac_word=$2 5834 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5835 $as_echo_n "checking for $ac_word... " >&6; } 5836 if ${ac_cv_path_CHMOD+:} false; then : 5837 $as_echo_n "(cached) " >&6 5838 else 5839 case $CHMOD in 5840 [\\/]* | ?:[\\/]*) 5841 ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path. 5842 ;; 5843 *) 5844 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5845 for as_dir in $PATH 5846 do 5847 IFS=$as_save_IFS 5848 test -z "$as_dir" && as_dir=. 5849 for ac_exec_ext in '' $ac_executable_extensions; do 5850 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5851 ac_cv_path_CHMOD="$as_dir/$ac_word$ac_exec_ext" 5852 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5853 break 2 5854 fi 5855 done 5856 done 5857 IFS=$as_save_IFS 5858 5859 ;; 5860 esac 5861 fi 5862 CHMOD=$ac_cv_path_CHMOD 5863 if test -n "$CHMOD"; then 5864 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5 5865 $as_echo "$CHMOD" >&6; } 5866 else 5867 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5868 $as_echo "no" >&6; } 5869 fi 5870 5871 5872 test -n "$CHMOD" && break 5873 done 5874 5875 else 5876 # If it succeeded, then it was overridden by the user. We will use it 5877 # for the tool. 5878 5879 # First remove it from the list of overridden variables, so we can test 5880 # for unknown variables in the end. 5881 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 5882 5883 # Check if we try to supply an empty value 5884 if test "x$CHMOD" = x; then 5885 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CHMOD= (no value)" >&5 5886 $as_echo "$as_me: Setting user supplied tool CHMOD= (no value)" >&6;} 5887 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CHMOD" >&5 5888 $as_echo_n "checking for CHMOD... " >&6; } 5889 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 5890 $as_echo "disabled" >&6; } 5891 else 5892 # Check if the provided tool contains a complete path. 5893 tool_specified="$CHMOD" 5894 tool_basename="${tool_specified##*/}" 5895 if test "x$tool_basename" = "x$tool_specified"; then 5896 # A command without a complete path is provided, search $PATH. 5897 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CHMOD=$tool_basename" >&5 5898 $as_echo "$as_me: Will search for user supplied tool CHMOD=$tool_basename" >&6;} 5899 # Extract the first word of "$tool_basename", so it can be a program name with args. 5900 set dummy $tool_basename; ac_word=$2 5901 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5902 $as_echo_n "checking for $ac_word... " >&6; } 5903 if ${ac_cv_path_CHMOD+:} false; then : 5904 $as_echo_n "(cached) " >&6 5905 else 5906 case $CHMOD in 5907 [\\/]* | ?:[\\/]*) 5908 ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path. 5909 ;; 5910 *) 5911 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5912 for as_dir in $PATH 5913 do 5914 IFS=$as_save_IFS 5915 test -z "$as_dir" && as_dir=. 5916 for ac_exec_ext in '' $ac_executable_extensions; do 5917 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5918 ac_cv_path_CHMOD="$as_dir/$ac_word$ac_exec_ext" 5919 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5920 break 2 5921 fi 5922 done 5923 done 5924 IFS=$as_save_IFS 5925 5926 ;; 5927 esac 5928 fi 5929 CHMOD=$ac_cv_path_CHMOD 5930 if test -n "$CHMOD"; then 5931 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5 5932 $as_echo "$CHMOD" >&6; } 5933 else 5934 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5935 $as_echo "no" >&6; } 5936 fi 5937 5938 5939 if test "x$CHMOD" = x; then 5940 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 5941 fi 5942 else 5943 # Otherwise we believe it is a complete path. Use it as it is. 5944 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CHMOD=$tool_specified" >&5 5945 $as_echo "$as_me: Will use user supplied tool CHMOD=$tool_specified" >&6;} 5946 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CHMOD" >&5 5947 $as_echo_n "checking for CHMOD... " >&6; } 5948 if test ! -x "$tool_specified"; then 5949 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 5950 $as_echo "not found" >&6; } 5951 as_fn_error $? "User supplied tool CHMOD=$tool_specified does not exist or is not executable" "$LINENO" 5 5952 fi 5953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 5954 $as_echo "$tool_specified" >&6; } 5955 fi 5956 fi 5957 fi 5958 5959 fi 5960 5961 5962 5963 if test "x$CHMOD" = x; then 5964 as_fn_error $? "Could not find required tool for CHMOD" "$LINENO" 5 5965 fi 5966 5967 5968 5969 5970 5971 # Publish this variable in the help. 5972 5973 5974 if [ -z "${CMP+x}" ]; then 5975 # The variable is not set by user, try to locate tool using the code snippet 5976 for ac_prog in cmp 5977 do 5978 # Extract the first word of "$ac_prog", so it can be a program name with args. 5979 set dummy $ac_prog; ac_word=$2 5980 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5981 $as_echo_n "checking for $ac_word... " >&6; } 5982 if ${ac_cv_path_CMP+:} false; then : 5983 $as_echo_n "(cached) " >&6 5984 else 5985 case $CMP in 5986 [\\/]* | ?:[\\/]*) 5987 ac_cv_path_CMP="$CMP" # Let the user override the test with a path. 5988 ;; 5989 *) 5990 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5991 for as_dir in $PATH 5992 do 5993 IFS=$as_save_IFS 5994 test -z "$as_dir" && as_dir=. 5995 for ac_exec_ext in '' $ac_executable_extensions; do 5996 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5997 ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext" 5998 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5999 break 2 6000 fi 6001 done 6002 done 6003 IFS=$as_save_IFS 6004 6005 ;; 6006 esac 6007 fi 6008 CMP=$ac_cv_path_CMP 6009 if test -n "$CMP"; then 6010 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5 6011 $as_echo "$CMP" >&6; } 6012 else 6013 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6014 $as_echo "no" >&6; } 6015 fi 6016 6017 6018 test -n "$CMP" && break 6019 done 6020 6021 else 6022 # The variable is set, but is it from the command line or the environment? 6023 6024 # Try to remove the string !CMP! from our list. 6025 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CMP!/} 6026 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 6027 # If it failed, the variable was not from the command line. Ignore it, 6028 # but warn the user (except for BASH, which is always set by the calling BASH). 6029 if test "xCMP" != xBASH; then 6030 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CMP from the environment. Use command line variables instead." >&5 6031 $as_echo "$as_me: WARNING: Ignoring value of CMP from the environment. Use command line variables instead." >&2;} 6032 fi 6033 # Try to locate tool using the code snippet 6034 for ac_prog in cmp 6035 do 6036 # Extract the first word of "$ac_prog", so it can be a program name with args. 6037 set dummy $ac_prog; ac_word=$2 6038 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6039 $as_echo_n "checking for $ac_word... " >&6; } 6040 if ${ac_cv_path_CMP+:} false; then : 6041 $as_echo_n "(cached) " >&6 6042 else 6043 case $CMP in 6044 [\\/]* | ?:[\\/]*) 6045 ac_cv_path_CMP="$CMP" # Let the user override the test with a path. 6046 ;; 6047 *) 6048 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6049 for as_dir in $PATH 6050 do 6051 IFS=$as_save_IFS 6052 test -z "$as_dir" && as_dir=. 6053 for ac_exec_ext in '' $ac_executable_extensions; do 6054 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6055 ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext" 6056 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6057 break 2 6058 fi 6059 done 6060 done 6061 IFS=$as_save_IFS 6062 6063 ;; 6064 esac 6065 fi 6066 CMP=$ac_cv_path_CMP 6067 if test -n "$CMP"; then 6068 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5 6069 $as_echo "$CMP" >&6; } 6070 else 6071 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6072 $as_echo "no" >&6; } 6073 fi 6074 6075 6076 test -n "$CMP" && break 6077 done 6078 6079 else 6080 # If it succeeded, then it was overridden by the user. We will use it 6081 # for the tool. 6082 6083 # First remove it from the list of overridden variables, so we can test 6084 # for unknown variables in the end. 6085 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 6086 6087 # Check if we try to supply an empty value 6088 if test "x$CMP" = x; then 6089 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CMP= (no value)" >&5 6090 $as_echo "$as_me: Setting user supplied tool CMP= (no value)" >&6;} 6091 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CMP" >&5 6092 $as_echo_n "checking for CMP... " >&6; } 6093 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 6094 $as_echo "disabled" >&6; } 6095 else 6096 # Check if the provided tool contains a complete path. 6097 tool_specified="$CMP" 6098 tool_basename="${tool_specified##*/}" 6099 if test "x$tool_basename" = "x$tool_specified"; then 6100 # A command without a complete path is provided, search $PATH. 6101 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CMP=$tool_basename" >&5 6102 $as_echo "$as_me: Will search for user supplied tool CMP=$tool_basename" >&6;} 6103 # Extract the first word of "$tool_basename", so it can be a program name with args. 6104 set dummy $tool_basename; ac_word=$2 6105 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6106 $as_echo_n "checking for $ac_word... " >&6; } 6107 if ${ac_cv_path_CMP+:} false; then : 6108 $as_echo_n "(cached) " >&6 6109 else 6110 case $CMP in 6111 [\\/]* | ?:[\\/]*) 6112 ac_cv_path_CMP="$CMP" # Let the user override the test with a path. 6113 ;; 6114 *) 6115 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6116 for as_dir in $PATH 6117 do 6118 IFS=$as_save_IFS 6119 test -z "$as_dir" && as_dir=. 6120 for ac_exec_ext in '' $ac_executable_extensions; do 6121 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6122 ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext" 6123 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6124 break 2 6125 fi 6126 done 6127 done 6128 IFS=$as_save_IFS 6129 6130 ;; 6131 esac 6132 fi 6133 CMP=$ac_cv_path_CMP 6134 if test -n "$CMP"; then 6135 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5 6136 $as_echo "$CMP" >&6; } 6137 else 6138 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6139 $as_echo "no" >&6; } 6140 fi 6141 6142 6143 if test "x$CMP" = x; then 6144 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 6145 fi 6146 else 6147 # Otherwise we believe it is a complete path. Use it as it is. 6148 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CMP=$tool_specified" >&5 6149 $as_echo "$as_me: Will use user supplied tool CMP=$tool_specified" >&6;} 6150 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CMP" >&5 6151 $as_echo_n "checking for CMP... " >&6; } 6152 if test ! -x "$tool_specified"; then 6153 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 6154 $as_echo "not found" >&6; } 6155 as_fn_error $? "User supplied tool CMP=$tool_specified does not exist or is not executable" "$LINENO" 5 6156 fi 6157 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 6158 $as_echo "$tool_specified" >&6; } 6159 fi 6160 fi 6161 fi 6162 6163 fi 6164 6165 6166 6167 if test "x$CMP" = x; then 6168 as_fn_error $? "Could not find required tool for CMP" "$LINENO" 5 6169 fi 6170 6171 6172 6173 6174 6175 # Publish this variable in the help. 6176 6177 6178 if [ -z "${COMM+x}" ]; then 6179 # The variable is not set by user, try to locate tool using the code snippet 6180 for ac_prog in comm 6181 do 6182 # Extract the first word of "$ac_prog", so it can be a program name with args. 6183 set dummy $ac_prog; ac_word=$2 6184 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6185 $as_echo_n "checking for $ac_word... " >&6; } 6186 if ${ac_cv_path_COMM+:} false; then : 6187 $as_echo_n "(cached) " >&6 6188 else 6189 case $COMM in 6190 [\\/]* | ?:[\\/]*) 6191 ac_cv_path_COMM="$COMM" # Let the user override the test with a path. 6192 ;; 6193 *) 6194 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6195 for as_dir in $PATH 6196 do 6197 IFS=$as_save_IFS 6198 test -z "$as_dir" && as_dir=. 6199 for ac_exec_ext in '' $ac_executable_extensions; do 6200 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6201 ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext" 6202 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6203 break 2 6204 fi 6205 done 6206 done 6207 IFS=$as_save_IFS 6208 6209 ;; 6210 esac 6211 fi 6212 COMM=$ac_cv_path_COMM 6213 if test -n "$COMM"; then 6214 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5 6215 $as_echo "$COMM" >&6; } 6216 else 6217 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6218 $as_echo "no" >&6; } 6219 fi 6220 6221 6222 test -n "$COMM" && break 6223 done 6224 6225 else 6226 # The variable is set, but is it from the command line or the environment? 6227 6228 # Try to remove the string !COMM! from our list. 6229 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!COMM!/} 6230 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 6231 # If it failed, the variable was not from the command line. Ignore it, 6232 # but warn the user (except for BASH, which is always set by the calling BASH). 6233 if test "xCOMM" != xBASH; then 6234 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of COMM from the environment. Use command line variables instead." >&5 6235 $as_echo "$as_me: WARNING: Ignoring value of COMM from the environment. Use command line variables instead." >&2;} 6236 fi 6237 # Try to locate tool using the code snippet 6238 for ac_prog in comm 6239 do 6240 # Extract the first word of "$ac_prog", so it can be a program name with args. 6241 set dummy $ac_prog; ac_word=$2 6242 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6243 $as_echo_n "checking for $ac_word... " >&6; } 6244 if ${ac_cv_path_COMM+:} false; then : 6245 $as_echo_n "(cached) " >&6 6246 else 6247 case $COMM in 6248 [\\/]* | ?:[\\/]*) 6249 ac_cv_path_COMM="$COMM" # Let the user override the test with a path. 6250 ;; 6251 *) 6252 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6253 for as_dir in $PATH 6254 do 6255 IFS=$as_save_IFS 6256 test -z "$as_dir" && as_dir=. 6257 for ac_exec_ext in '' $ac_executable_extensions; do 6258 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6259 ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext" 6260 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6261 break 2 6262 fi 6263 done 6264 done 6265 IFS=$as_save_IFS 6266 6267 ;; 6268 esac 6269 fi 6270 COMM=$ac_cv_path_COMM 6271 if test -n "$COMM"; then 6272 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5 6273 $as_echo "$COMM" >&6; } 6274 else 6275 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6276 $as_echo "no" >&6; } 6277 fi 6278 6279 6280 test -n "$COMM" && break 6281 done 6282 6283 else 6284 # If it succeeded, then it was overridden by the user. We will use it 6285 # for the tool. 6286 6287 # First remove it from the list of overridden variables, so we can test 6288 # for unknown variables in the end. 6289 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 6290 6291 # Check if we try to supply an empty value 6292 if test "x$COMM" = x; then 6293 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool COMM= (no value)" >&5 6294 $as_echo "$as_me: Setting user supplied tool COMM= (no value)" >&6;} 6295 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for COMM" >&5 6296 $as_echo_n "checking for COMM... " >&6; } 6297 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 6298 $as_echo "disabled" >&6; } 6299 else 6300 # Check if the provided tool contains a complete path. 6301 tool_specified="$COMM" 6302 tool_basename="${tool_specified##*/}" 6303 if test "x$tool_basename" = "x$tool_specified"; then 6304 # A command without a complete path is provided, search $PATH. 6305 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool COMM=$tool_basename" >&5 6306 $as_echo "$as_me: Will search for user supplied tool COMM=$tool_basename" >&6;} 6307 # Extract the first word of "$tool_basename", so it can be a program name with args. 6308 set dummy $tool_basename; ac_word=$2 6309 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6310 $as_echo_n "checking for $ac_word... " >&6; } 6311 if ${ac_cv_path_COMM+:} false; then : 6312 $as_echo_n "(cached) " >&6 6313 else 6314 case $COMM in 6315 [\\/]* | ?:[\\/]*) 6316 ac_cv_path_COMM="$COMM" # Let the user override the test with a path. 6317 ;; 6318 *) 6319 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6320 for as_dir in $PATH 6321 do 6322 IFS=$as_save_IFS 6323 test -z "$as_dir" && as_dir=. 6324 for ac_exec_ext in '' $ac_executable_extensions; do 6325 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6326 ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext" 6327 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6328 break 2 6329 fi 6330 done 6331 done 6332 IFS=$as_save_IFS 6333 6334 ;; 6335 esac 6336 fi 6337 COMM=$ac_cv_path_COMM 6338 if test -n "$COMM"; then 6339 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5 6340 $as_echo "$COMM" >&6; } 6341 else 6342 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6343 $as_echo "no" >&6; } 6344 fi 6345 6346 6347 if test "x$COMM" = x; then 6348 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 6349 fi 6350 else 6351 # Otherwise we believe it is a complete path. Use it as it is. 6352 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool COMM=$tool_specified" >&5 6353 $as_echo "$as_me: Will use user supplied tool COMM=$tool_specified" >&6;} 6354 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for COMM" >&5 6355 $as_echo_n "checking for COMM... " >&6; } 6356 if test ! -x "$tool_specified"; then 6357 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 6358 $as_echo "not found" >&6; } 6359 as_fn_error $? "User supplied tool COMM=$tool_specified does not exist or is not executable" "$LINENO" 5 6360 fi 6361 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 6362 $as_echo "$tool_specified" >&6; } 6363 fi 6364 fi 6365 fi 6366 6367 fi 6368 6369 6370 6371 if test "x$COMM" = x; then 6372 as_fn_error $? "Could not find required tool for COMM" "$LINENO" 5 6373 fi 6374 6375 6376 6377 6378 6379 # Publish this variable in the help. 6380 6381 6382 if [ -z "${CP+x}" ]; then 6383 # The variable is not set by user, try to locate tool using the code snippet 6384 for ac_prog in cp 6385 do 6386 # Extract the first word of "$ac_prog", so it can be a program name with args. 6387 set dummy $ac_prog; ac_word=$2 6388 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6389 $as_echo_n "checking for $ac_word... " >&6; } 6390 if ${ac_cv_path_CP+:} false; then : 6391 $as_echo_n "(cached) " >&6 6392 else 6393 case $CP in 6394 [\\/]* | ?:[\\/]*) 6395 ac_cv_path_CP="$CP" # Let the user override the test with a path. 6396 ;; 6397 *) 6398 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6399 for as_dir in $PATH 6400 do 6401 IFS=$as_save_IFS 6402 test -z "$as_dir" && as_dir=. 6403 for ac_exec_ext in '' $ac_executable_extensions; do 6404 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6405 ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext" 6406 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6407 break 2 6408 fi 6409 done 6410 done 6411 IFS=$as_save_IFS 6412 6413 ;; 6414 esac 6415 fi 6416 CP=$ac_cv_path_CP 6417 if test -n "$CP"; then 6418 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CP" >&5 6419 $as_echo "$CP" >&6; } 6420 else 6421 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6422 $as_echo "no" >&6; } 6423 fi 6424 6425 6426 test -n "$CP" && break 6427 done 6428 6429 else 6430 # The variable is set, but is it from the command line or the environment? 6431 6432 # Try to remove the string !CP! from our list. 6433 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CP!/} 6434 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 6435 # If it failed, the variable was not from the command line. Ignore it, 6436 # but warn the user (except for BASH, which is always set by the calling BASH). 6437 if test "xCP" != xBASH; then 6438 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CP from the environment. Use command line variables instead." >&5 6439 $as_echo "$as_me: WARNING: Ignoring value of CP from the environment. Use command line variables instead." >&2;} 6440 fi 6441 # Try to locate tool using the code snippet 6442 for ac_prog in cp 6443 do 6444 # Extract the first word of "$ac_prog", so it can be a program name with args. 6445 set dummy $ac_prog; ac_word=$2 6446 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6447 $as_echo_n "checking for $ac_word... " >&6; } 6448 if ${ac_cv_path_CP+:} false; then : 6449 $as_echo_n "(cached) " >&6 6450 else 6451 case $CP in 6452 [\\/]* | ?:[\\/]*) 6453 ac_cv_path_CP="$CP" # Let the user override the test with a path. 6454 ;; 6455 *) 6456 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6457 for as_dir in $PATH 6458 do 6459 IFS=$as_save_IFS 6460 test -z "$as_dir" && as_dir=. 6461 for ac_exec_ext in '' $ac_executable_extensions; do 6462 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6463 ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext" 6464 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6465 break 2 6466 fi 6467 done 6468 done 6469 IFS=$as_save_IFS 6470 6471 ;; 6472 esac 6473 fi 6474 CP=$ac_cv_path_CP 6475 if test -n "$CP"; then 6476 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CP" >&5 6477 $as_echo "$CP" >&6; } 6478 else 6479 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6480 $as_echo "no" >&6; } 6481 fi 6482 6483 6484 test -n "$CP" && break 6485 done 6486 6487 else 6488 # If it succeeded, then it was overridden by the user. We will use it 6489 # for the tool. 6490 6491 # First remove it from the list of overridden variables, so we can test 6492 # for unknown variables in the end. 6493 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 6494 6495 # Check if we try to supply an empty value 6496 if test "x$CP" = x; then 6497 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CP= (no value)" >&5 6498 $as_echo "$as_me: Setting user supplied tool CP= (no value)" >&6;} 6499 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CP" >&5 6500 $as_echo_n "checking for CP... " >&6; } 6501 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 6502 $as_echo "disabled" >&6; } 6503 else 6504 # Check if the provided tool contains a complete path. 6505 tool_specified="$CP" 6506 tool_basename="${tool_specified##*/}" 6507 if test "x$tool_basename" = "x$tool_specified"; then 6508 # A command without a complete path is provided, search $PATH. 6509 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CP=$tool_basename" >&5 6510 $as_echo "$as_me: Will search for user supplied tool CP=$tool_basename" >&6;} 6511 # Extract the first word of "$tool_basename", so it can be a program name with args. 6512 set dummy $tool_basename; ac_word=$2 6513 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6514 $as_echo_n "checking for $ac_word... " >&6; } 6515 if ${ac_cv_path_CP+:} false; then : 6516 $as_echo_n "(cached) " >&6 6517 else 6518 case $CP in 6519 [\\/]* | ?:[\\/]*) 6520 ac_cv_path_CP="$CP" # Let the user override the test with a path. 6521 ;; 6522 *) 6523 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6524 for as_dir in $PATH 6525 do 6526 IFS=$as_save_IFS 6527 test -z "$as_dir" && as_dir=. 6528 for ac_exec_ext in '' $ac_executable_extensions; do 6529 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6530 ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext" 6531 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6532 break 2 6533 fi 6534 done 6535 done 6536 IFS=$as_save_IFS 6537 6538 ;; 6539 esac 6540 fi 6541 CP=$ac_cv_path_CP 6542 if test -n "$CP"; then 6543 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CP" >&5 6544 $as_echo "$CP" >&6; } 6545 else 6546 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6547 $as_echo "no" >&6; } 6548 fi 6549 6550 6551 if test "x$CP" = x; then 6552 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 6553 fi 6554 else 6555 # Otherwise we believe it is a complete path. Use it as it is. 6556 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CP=$tool_specified" >&5 6557 $as_echo "$as_me: Will use user supplied tool CP=$tool_specified" >&6;} 6558 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CP" >&5 6559 $as_echo_n "checking for CP... " >&6; } 6560 if test ! -x "$tool_specified"; then 6561 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 6562 $as_echo "not found" >&6; } 6563 as_fn_error $? "User supplied tool CP=$tool_specified does not exist or is not executable" "$LINENO" 5 6564 fi 6565 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 6566 $as_echo "$tool_specified" >&6; } 6567 fi 6568 fi 6569 fi 6570 6571 fi 6572 6573 6574 6575 if test "x$CP" = x; then 6576 as_fn_error $? "Could not find required tool for CP" "$LINENO" 5 6577 fi 6578 6579 6580 6581 6582 6583 # Publish this variable in the help. 6584 6585 6586 if [ -z "${CUT+x}" ]; then 6587 # The variable is not set by user, try to locate tool using the code snippet 6588 for ac_prog in cut 6589 do 6590 # Extract the first word of "$ac_prog", so it can be a program name with args. 6591 set dummy $ac_prog; ac_word=$2 6592 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6593 $as_echo_n "checking for $ac_word... " >&6; } 6594 if ${ac_cv_path_CUT+:} false; then : 6595 $as_echo_n "(cached) " >&6 6596 else 6597 case $CUT in 6598 [\\/]* | ?:[\\/]*) 6599 ac_cv_path_CUT="$CUT" # Let the user override the test with a path. 6600 ;; 6601 *) 6602 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6603 for as_dir in $PATH 6604 do 6605 IFS=$as_save_IFS 6606 test -z "$as_dir" && as_dir=. 6607 for ac_exec_ext in '' $ac_executable_extensions; do 6608 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6609 ac_cv_path_CUT="$as_dir/$ac_word$ac_exec_ext" 6610 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6611 break 2 6612 fi 6613 done 6614 done 6615 IFS=$as_save_IFS 6616 6617 ;; 6618 esac 6619 fi 6620 CUT=$ac_cv_path_CUT 6621 if test -n "$CUT"; then 6622 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUT" >&5 6623 $as_echo "$CUT" >&6; } 6624 else 6625 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6626 $as_echo "no" >&6; } 6627 fi 6628 6629 6630 test -n "$CUT" && break 6631 done 6632 6633 else 6634 # The variable is set, but is it from the command line or the environment? 6635 6636 # Try to remove the string !CUT! from our list. 6637 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CUT!/} 6638 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 6639 # If it failed, the variable was not from the command line. Ignore it, 6640 # but warn the user (except for BASH, which is always set by the calling BASH). 6641 if test "xCUT" != xBASH; then 6642 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CUT from the environment. Use command line variables instead." >&5 6643 $as_echo "$as_me: WARNING: Ignoring value of CUT from the environment. Use command line variables instead." >&2;} 6644 fi 6645 # Try to locate tool using the code snippet 6646 for ac_prog in cut 6647 do 6648 # Extract the first word of "$ac_prog", so it can be a program name with args. 6649 set dummy $ac_prog; ac_word=$2 6650 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6651 $as_echo_n "checking for $ac_word... " >&6; } 6652 if ${ac_cv_path_CUT+:} false; then : 6653 $as_echo_n "(cached) " >&6 6654 else 6655 case $CUT in 6656 [\\/]* | ?:[\\/]*) 6657 ac_cv_path_CUT="$CUT" # Let the user override the test with a path. 6658 ;; 6659 *) 6660 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6661 for as_dir in $PATH 6662 do 6663 IFS=$as_save_IFS 6664 test -z "$as_dir" && as_dir=. 6665 for ac_exec_ext in '' $ac_executable_extensions; do 6666 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6667 ac_cv_path_CUT="$as_dir/$ac_word$ac_exec_ext" 6668 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6669 break 2 6670 fi 6671 done 6672 done 6673 IFS=$as_save_IFS 6674 6675 ;; 6676 esac 6677 fi 6678 CUT=$ac_cv_path_CUT 6679 if test -n "$CUT"; then 6680 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUT" >&5 6681 $as_echo "$CUT" >&6; } 6682 else 6683 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6684 $as_echo "no" >&6; } 6685 fi 6686 6687 6688 test -n "$CUT" && break 6689 done 6690 6691 else 6692 # If it succeeded, then it was overridden by the user. We will use it 6693 # for the tool. 6694 6695 # First remove it from the list of overridden variables, so we can test 6696 # for unknown variables in the end. 6697 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 6698 6699 # Check if we try to supply an empty value 6700 if test "x$CUT" = x; then 6701 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CUT= (no value)" >&5 6702 $as_echo "$as_me: Setting user supplied tool CUT= (no value)" >&6;} 6703 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CUT" >&5 6704 $as_echo_n "checking for CUT... " >&6; } 6705 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 6706 $as_echo "disabled" >&6; } 6707 else 6708 # Check if the provided tool contains a complete path. 6709 tool_specified="$CUT" 6710 tool_basename="${tool_specified##*/}" 6711 if test "x$tool_basename" = "x$tool_specified"; then 6712 # A command without a complete path is provided, search $PATH. 6713 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CUT=$tool_basename" >&5 6714 $as_echo "$as_me: Will search for user supplied tool CUT=$tool_basename" >&6;} 6715 # Extract the first word of "$tool_basename", so it can be a program name with args. 6716 set dummy $tool_basename; ac_word=$2 6717 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6718 $as_echo_n "checking for $ac_word... " >&6; } 6719 if ${ac_cv_path_CUT+:} false; then : 6720 $as_echo_n "(cached) " >&6 6721 else 6722 case $CUT in 6723 [\\/]* | ?:[\\/]*) 6724 ac_cv_path_CUT="$CUT" # Let the user override the test with a path. 6725 ;; 6726 *) 6727 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6728 for as_dir in $PATH 6729 do 6730 IFS=$as_save_IFS 6731 test -z "$as_dir" && as_dir=. 6732 for ac_exec_ext in '' $ac_executable_extensions; do 6733 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6734 ac_cv_path_CUT="$as_dir/$ac_word$ac_exec_ext" 6735 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6736 break 2 6737 fi 6738 done 6739 done 6740 IFS=$as_save_IFS 6741 6742 ;; 6743 esac 6744 fi 6745 CUT=$ac_cv_path_CUT 6746 if test -n "$CUT"; then 6747 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUT" >&5 6748 $as_echo "$CUT" >&6; } 6749 else 6750 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6751 $as_echo "no" >&6; } 6752 fi 6753 6754 6755 if test "x$CUT" = x; then 6756 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 6757 fi 6758 else 6759 # Otherwise we believe it is a complete path. Use it as it is. 6760 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CUT=$tool_specified" >&5 6761 $as_echo "$as_me: Will use user supplied tool CUT=$tool_specified" >&6;} 6762 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CUT" >&5 6763 $as_echo_n "checking for CUT... " >&6; } 6764 if test ! -x "$tool_specified"; then 6765 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 6766 $as_echo "not found" >&6; } 6767 as_fn_error $? "User supplied tool CUT=$tool_specified does not exist or is not executable" "$LINENO" 5 6768 fi 6769 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 6770 $as_echo "$tool_specified" >&6; } 6771 fi 6772 fi 6773 fi 6774 6775 fi 6776 6777 6778 6779 if test "x$CUT" = x; then 6780 as_fn_error $? "Could not find required tool for CUT" "$LINENO" 5 6781 fi 6782 6783 6784 6785 6786 6787 # Publish this variable in the help. 6788 6789 6790 if [ -z "${DATE+x}" ]; then 6791 # The variable is not set by user, try to locate tool using the code snippet 6792 for ac_prog in date 6793 do 6794 # Extract the first word of "$ac_prog", so it can be a program name with args. 6795 set dummy $ac_prog; ac_word=$2 6796 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6797 $as_echo_n "checking for $ac_word... " >&6; } 6798 if ${ac_cv_path_DATE+:} false; then : 6799 $as_echo_n "(cached) " >&6 6800 else 6801 case $DATE in 6802 [\\/]* | ?:[\\/]*) 6803 ac_cv_path_DATE="$DATE" # Let the user override the test with a path. 6804 ;; 6805 *) 6806 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6807 for as_dir in $PATH 6808 do 6809 IFS=$as_save_IFS 6810 test -z "$as_dir" && as_dir=. 6811 for ac_exec_ext in '' $ac_executable_extensions; do 6812 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6813 ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext" 6814 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6815 break 2 6816 fi 6817 done 6818 done 6819 IFS=$as_save_IFS 6820 6821 ;; 6822 esac 6823 fi 6824 DATE=$ac_cv_path_DATE 6825 if test -n "$DATE"; then 6826 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DATE" >&5 6827 $as_echo "$DATE" >&6; } 6828 else 6829 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6830 $as_echo "no" >&6; } 6831 fi 6832 6833 6834 test -n "$DATE" && break 6835 done 6836 6837 else 6838 # The variable is set, but is it from the command line or the environment? 6839 6840 # Try to remove the string !DATE! from our list. 6841 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DATE!/} 6842 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 6843 # If it failed, the variable was not from the command line. Ignore it, 6844 # but warn the user (except for BASH, which is always set by the calling BASH). 6845 if test "xDATE" != xBASH; then 6846 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DATE from the environment. Use command line variables instead." >&5 6847 $as_echo "$as_me: WARNING: Ignoring value of DATE from the environment. Use command line variables instead." >&2;} 6848 fi 6849 # Try to locate tool using the code snippet 6850 for ac_prog in date 6851 do 6852 # Extract the first word of "$ac_prog", so it can be a program name with args. 6853 set dummy $ac_prog; ac_word=$2 6854 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6855 $as_echo_n "checking for $ac_word... " >&6; } 6856 if ${ac_cv_path_DATE+:} false; then : 6857 $as_echo_n "(cached) " >&6 6858 else 6859 case $DATE in 6860 [\\/]* | ?:[\\/]*) 6861 ac_cv_path_DATE="$DATE" # Let the user override the test with a path. 6862 ;; 6863 *) 6864 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6865 for as_dir in $PATH 6866 do 6867 IFS=$as_save_IFS 6868 test -z "$as_dir" && as_dir=. 6869 for ac_exec_ext in '' $ac_executable_extensions; do 6870 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6871 ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext" 6872 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6873 break 2 6874 fi 6875 done 6876 done 6877 IFS=$as_save_IFS 6878 6879 ;; 6880 esac 6881 fi 6882 DATE=$ac_cv_path_DATE 6883 if test -n "$DATE"; then 6884 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DATE" >&5 6885 $as_echo "$DATE" >&6; } 6886 else 6887 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6888 $as_echo "no" >&6; } 6889 fi 6890 6891 6892 test -n "$DATE" && break 6893 done 6894 6895 else 6896 # If it succeeded, then it was overridden by the user. We will use it 6897 # for the tool. 6898 6899 # First remove it from the list of overridden variables, so we can test 6900 # for unknown variables in the end. 6901 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 6902 6903 # Check if we try to supply an empty value 6904 if test "x$DATE" = x; then 6905 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DATE= (no value)" >&5 6906 $as_echo "$as_me: Setting user supplied tool DATE= (no value)" >&6;} 6907 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DATE" >&5 6908 $as_echo_n "checking for DATE... " >&6; } 6909 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 6910 $as_echo "disabled" >&6; } 6911 else 6912 # Check if the provided tool contains a complete path. 6913 tool_specified="$DATE" 6914 tool_basename="${tool_specified##*/}" 6915 if test "x$tool_basename" = "x$tool_specified"; then 6916 # A command without a complete path is provided, search $PATH. 6917 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DATE=$tool_basename" >&5 6918 $as_echo "$as_me: Will search for user supplied tool DATE=$tool_basename" >&6;} 6919 # Extract the first word of "$tool_basename", so it can be a program name with args. 6920 set dummy $tool_basename; ac_word=$2 6921 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6922 $as_echo_n "checking for $ac_word... " >&6; } 6923 if ${ac_cv_path_DATE+:} false; then : 6924 $as_echo_n "(cached) " >&6 6925 else 6926 case $DATE in 6927 [\\/]* | ?:[\\/]*) 6928 ac_cv_path_DATE="$DATE" # Let the user override the test with a path. 6929 ;; 6930 *) 6931 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6932 for as_dir in $PATH 6933 do 6934 IFS=$as_save_IFS 6935 test -z "$as_dir" && as_dir=. 6936 for ac_exec_ext in '' $ac_executable_extensions; do 6937 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6938 ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext" 6939 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6940 break 2 6941 fi 6942 done 6943 done 6944 IFS=$as_save_IFS 6945 6946 ;; 6947 esac 6948 fi 6949 DATE=$ac_cv_path_DATE 6950 if test -n "$DATE"; then 6951 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DATE" >&5 6952 $as_echo "$DATE" >&6; } 6953 else 6954 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6955 $as_echo "no" >&6; } 6956 fi 6957 6958 6959 if test "x$DATE" = x; then 6960 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 6961 fi 6962 else 6963 # Otherwise we believe it is a complete path. Use it as it is. 6964 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DATE=$tool_specified" >&5 6965 $as_echo "$as_me: Will use user supplied tool DATE=$tool_specified" >&6;} 6966 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DATE" >&5 6967 $as_echo_n "checking for DATE... " >&6; } 6968 if test ! -x "$tool_specified"; then 6969 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 6970 $as_echo "not found" >&6; } 6971 as_fn_error $? "User supplied tool DATE=$tool_specified does not exist or is not executable" "$LINENO" 5 6972 fi 6973 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 6974 $as_echo "$tool_specified" >&6; } 6975 fi 6976 fi 6977 fi 6978 6979 fi 6980 6981 6982 6983 if test "x$DATE" = x; then 6984 as_fn_error $? "Could not find required tool for DATE" "$LINENO" 5 6985 fi 6986 6987 6988 6989 6990 6991 # Publish this variable in the help. 6992 6993 6994 if [ -z "${DIFF+x}" ]; then 6995 # The variable is not set by user, try to locate tool using the code snippet 6996 for ac_prog in gdiff diff 6997 do 6998 # Extract the first word of "$ac_prog", so it can be a program name with args. 6999 set dummy $ac_prog; ac_word=$2 7000 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7001 $as_echo_n "checking for $ac_word... " >&6; } 7002 if ${ac_cv_path_DIFF+:} false; then : 7003 $as_echo_n "(cached) " >&6 7004 else 7005 case $DIFF in 7006 [\\/]* | ?:[\\/]*) 7007 ac_cv_path_DIFF="$DIFF" # Let the user override the test with a path. 7008 ;; 7009 *) 7010 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7011 for as_dir in $PATH 7012 do 7013 IFS=$as_save_IFS 7014 test -z "$as_dir" && as_dir=. 7015 for ac_exec_ext in '' $ac_executable_extensions; do 7016 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7017 ac_cv_path_DIFF="$as_dir/$ac_word$ac_exec_ext" 7018 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7019 break 2 7020 fi 7021 done 7022 done 7023 IFS=$as_save_IFS 7024 7025 ;; 7026 esac 7027 fi 7028 DIFF=$ac_cv_path_DIFF 7029 if test -n "$DIFF"; then 7030 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIFF" >&5 7031 $as_echo "$DIFF" >&6; } 7032 else 7033 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7034 $as_echo "no" >&6; } 7035 fi 7036 7037 7038 test -n "$DIFF" && break 7039 done 7040 7041 else 7042 # The variable is set, but is it from the command line or the environment? 7043 7044 # Try to remove the string !DIFF! from our list. 7045 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DIFF!/} 7046 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 7047 # If it failed, the variable was not from the command line. Ignore it, 7048 # but warn the user (except for BASH, which is always set by the calling BASH). 7049 if test "xDIFF" != xBASH; then 7050 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DIFF from the environment. Use command line variables instead." >&5 7051 $as_echo "$as_me: WARNING: Ignoring value of DIFF from the environment. Use command line variables instead." >&2;} 7052 fi 7053 # Try to locate tool using the code snippet 7054 for ac_prog in gdiff diff 7055 do 7056 # Extract the first word of "$ac_prog", so it can be a program name with args. 7057 set dummy $ac_prog; ac_word=$2 7058 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7059 $as_echo_n "checking for $ac_word... " >&6; } 7060 if ${ac_cv_path_DIFF+:} false; then : 7061 $as_echo_n "(cached) " >&6 7062 else 7063 case $DIFF in 7064 [\\/]* | ?:[\\/]*) 7065 ac_cv_path_DIFF="$DIFF" # Let the user override the test with a path. 7066 ;; 7067 *) 7068 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7069 for as_dir in $PATH 7070 do 7071 IFS=$as_save_IFS 7072 test -z "$as_dir" && as_dir=. 7073 for ac_exec_ext in '' $ac_executable_extensions; do 7074 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7075 ac_cv_path_DIFF="$as_dir/$ac_word$ac_exec_ext" 7076 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7077 break 2 7078 fi 7079 done 7080 done 7081 IFS=$as_save_IFS 7082 7083 ;; 7084 esac 7085 fi 7086 DIFF=$ac_cv_path_DIFF 7087 if test -n "$DIFF"; then 7088 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIFF" >&5 7089 $as_echo "$DIFF" >&6; } 7090 else 7091 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7092 $as_echo "no" >&6; } 7093 fi 7094 7095 7096 test -n "$DIFF" && break 7097 done 7098 7099 else 7100 # If it succeeded, then it was overridden by the user. We will use it 7101 # for the tool. 7102 7103 # First remove it from the list of overridden variables, so we can test 7104 # for unknown variables in the end. 7105 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 7106 7107 # Check if we try to supply an empty value 7108 if test "x$DIFF" = x; then 7109 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DIFF= (no value)" >&5 7110 $as_echo "$as_me: Setting user supplied tool DIFF= (no value)" >&6;} 7111 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIFF" >&5 7112 $as_echo_n "checking for DIFF... " >&6; } 7113 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 7114 $as_echo "disabled" >&6; } 7115 else 7116 # Check if the provided tool contains a complete path. 7117 tool_specified="$DIFF" 7118 tool_basename="${tool_specified##*/}" 7119 if test "x$tool_basename" = "x$tool_specified"; then 7120 # A command without a complete path is provided, search $PATH. 7121 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DIFF=$tool_basename" >&5 7122 $as_echo "$as_me: Will search for user supplied tool DIFF=$tool_basename" >&6;} 7123 # Extract the first word of "$tool_basename", so it can be a program name with args. 7124 set dummy $tool_basename; ac_word=$2 7125 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7126 $as_echo_n "checking for $ac_word... " >&6; } 7127 if ${ac_cv_path_DIFF+:} false; then : 7128 $as_echo_n "(cached) " >&6 7129 else 7130 case $DIFF in 7131 [\\/]* | ?:[\\/]*) 7132 ac_cv_path_DIFF="$DIFF" # Let the user override the test with a path. 7133 ;; 7134 *) 7135 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7136 for as_dir in $PATH 7137 do 7138 IFS=$as_save_IFS 7139 test -z "$as_dir" && as_dir=. 7140 for ac_exec_ext in '' $ac_executable_extensions; do 7141 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7142 ac_cv_path_DIFF="$as_dir/$ac_word$ac_exec_ext" 7143 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7144 break 2 7145 fi 7146 done 7147 done 7148 IFS=$as_save_IFS 7149 7150 ;; 7151 esac 7152 fi 7153 DIFF=$ac_cv_path_DIFF 7154 if test -n "$DIFF"; then 7155 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIFF" >&5 7156 $as_echo "$DIFF" >&6; } 7157 else 7158 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7159 $as_echo "no" >&6; } 7160 fi 7161 7162 7163 if test "x$DIFF" = x; then 7164 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 7165 fi 7166 else 7167 # Otherwise we believe it is a complete path. Use it as it is. 7168 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DIFF=$tool_specified" >&5 7169 $as_echo "$as_me: Will use user supplied tool DIFF=$tool_specified" >&6;} 7170 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIFF" >&5 7171 $as_echo_n "checking for DIFF... " >&6; } 7172 if test ! -x "$tool_specified"; then 7173 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 7174 $as_echo "not found" >&6; } 7175 as_fn_error $? "User supplied tool DIFF=$tool_specified does not exist or is not executable" "$LINENO" 5 7176 fi 7177 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 7178 $as_echo "$tool_specified" >&6; } 7179 fi 7180 fi 7181 fi 7182 7183 fi 7184 7185 7186 7187 if test "x$DIFF" = x; then 7188 as_fn_error $? "Could not find required tool for DIFF" "$LINENO" 5 7189 fi 7190 7191 7192 7193 7194 7195 # Publish this variable in the help. 7196 7197 7198 if [ -z "${DIRNAME+x}" ]; then 7199 # The variable is not set by user, try to locate tool using the code snippet 7200 for ac_prog in dirname 7201 do 7202 # Extract the first word of "$ac_prog", so it can be a program name with args. 7203 set dummy $ac_prog; ac_word=$2 7204 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7205 $as_echo_n "checking for $ac_word... " >&6; } 7206 if ${ac_cv_path_DIRNAME+:} false; then : 7207 $as_echo_n "(cached) " >&6 7208 else 7209 case $DIRNAME in 7210 [\\/]* | ?:[\\/]*) 7211 ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path. 7212 ;; 7213 *) 7214 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7215 for as_dir in $PATH 7216 do 7217 IFS=$as_save_IFS 7218 test -z "$as_dir" && as_dir=. 7219 for ac_exec_ext in '' $ac_executable_extensions; do 7220 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7221 ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext" 7222 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7223 break 2 7224 fi 7225 done 7226 done 7227 IFS=$as_save_IFS 7228 7229 ;; 7230 esac 7231 fi 7232 DIRNAME=$ac_cv_path_DIRNAME 7233 if test -n "$DIRNAME"; then 7234 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5 7235 $as_echo "$DIRNAME" >&6; } 7236 else 7237 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7238 $as_echo "no" >&6; } 7239 fi 7240 7241 7242 test -n "$DIRNAME" && break 7243 done 7244 7245 else 7246 # The variable is set, but is it from the command line or the environment? 7247 7248 # Try to remove the string !DIRNAME! from our list. 7249 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DIRNAME!/} 7250 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 7251 # If it failed, the variable was not from the command line. Ignore it, 7252 # but warn the user (except for BASH, which is always set by the calling BASH). 7253 if test "xDIRNAME" != xBASH; then 7254 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DIRNAME from the environment. Use command line variables instead." >&5 7255 $as_echo "$as_me: WARNING: Ignoring value of DIRNAME from the environment. Use command line variables instead." >&2;} 7256 fi 7257 # Try to locate tool using the code snippet 7258 for ac_prog in dirname 7259 do 7260 # Extract the first word of "$ac_prog", so it can be a program name with args. 7261 set dummy $ac_prog; ac_word=$2 7262 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7263 $as_echo_n "checking for $ac_word... " >&6; } 7264 if ${ac_cv_path_DIRNAME+:} false; then : 7265 $as_echo_n "(cached) " >&6 7266 else 7267 case $DIRNAME in 7268 [\\/]* | ?:[\\/]*) 7269 ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path. 7270 ;; 7271 *) 7272 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7273 for as_dir in $PATH 7274 do 7275 IFS=$as_save_IFS 7276 test -z "$as_dir" && as_dir=. 7277 for ac_exec_ext in '' $ac_executable_extensions; do 7278 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7279 ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext" 7280 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7281 break 2 7282 fi 7283 done 7284 done 7285 IFS=$as_save_IFS 7286 7287 ;; 7288 esac 7289 fi 7290 DIRNAME=$ac_cv_path_DIRNAME 7291 if test -n "$DIRNAME"; then 7292 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5 7293 $as_echo "$DIRNAME" >&6; } 7294 else 7295 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7296 $as_echo "no" >&6; } 7297 fi 7298 7299 7300 test -n "$DIRNAME" && break 7301 done 7302 7303 else 7304 # If it succeeded, then it was overridden by the user. We will use it 7305 # for the tool. 7306 7307 # First remove it from the list of overridden variables, so we can test 7308 # for unknown variables in the end. 7309 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 7310 7311 # Check if we try to supply an empty value 7312 if test "x$DIRNAME" = x; then 7313 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DIRNAME= (no value)" >&5 7314 $as_echo "$as_me: Setting user supplied tool DIRNAME= (no value)" >&6;} 7315 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIRNAME" >&5 7316 $as_echo_n "checking for DIRNAME... " >&6; } 7317 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 7318 $as_echo "disabled" >&6; } 7319 else 7320 # Check if the provided tool contains a complete path. 7321 tool_specified="$DIRNAME" 7322 tool_basename="${tool_specified##*/}" 7323 if test "x$tool_basename" = "x$tool_specified"; then 7324 # A command without a complete path is provided, search $PATH. 7325 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DIRNAME=$tool_basename" >&5 7326 $as_echo "$as_me: Will search for user supplied tool DIRNAME=$tool_basename" >&6;} 7327 # Extract the first word of "$tool_basename", so it can be a program name with args. 7328 set dummy $tool_basename; ac_word=$2 7329 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7330 $as_echo_n "checking for $ac_word... " >&6; } 7331 if ${ac_cv_path_DIRNAME+:} false; then : 7332 $as_echo_n "(cached) " >&6 7333 else 7334 case $DIRNAME in 7335 [\\/]* | ?:[\\/]*) 7336 ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path. 7337 ;; 7338 *) 7339 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7340 for as_dir in $PATH 7341 do 7342 IFS=$as_save_IFS 7343 test -z "$as_dir" && as_dir=. 7344 for ac_exec_ext in '' $ac_executable_extensions; do 7345 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7346 ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext" 7347 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7348 break 2 7349 fi 7350 done 7351 done 7352 IFS=$as_save_IFS 7353 7354 ;; 7355 esac 7356 fi 7357 DIRNAME=$ac_cv_path_DIRNAME 7358 if test -n "$DIRNAME"; then 7359 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5 7360 $as_echo "$DIRNAME" >&6; } 7361 else 7362 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7363 $as_echo "no" >&6; } 7364 fi 7365 7366 7367 if test "x$DIRNAME" = x; then 7368 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 7369 fi 7370 else 7371 # Otherwise we believe it is a complete path. Use it as it is. 7372 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DIRNAME=$tool_specified" >&5 7373 $as_echo "$as_me: Will use user supplied tool DIRNAME=$tool_specified" >&6;} 7374 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIRNAME" >&5 7375 $as_echo_n "checking for DIRNAME... " >&6; } 7376 if test ! -x "$tool_specified"; then 7377 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 7378 $as_echo "not found" >&6; } 7379 as_fn_error $? "User supplied tool DIRNAME=$tool_specified does not exist or is not executable" "$LINENO" 5 7380 fi 7381 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 7382 $as_echo "$tool_specified" >&6; } 7383 fi 7384 fi 7385 fi 7386 7387 fi 7388 7389 7390 7391 if test "x$DIRNAME" = x; then 7392 as_fn_error $? "Could not find required tool for DIRNAME" "$LINENO" 5 7393 fi 7394 7395 7396 7397 7398 7399 # Publish this variable in the help. 7400 7401 7402 if [ -z "${ECHO+x}" ]; then 7403 # The variable is not set by user, try to locate tool using the code snippet 7404 for ac_prog in echo 7405 do 7406 # Extract the first word of "$ac_prog", so it can be a program name with args. 7407 set dummy $ac_prog; ac_word=$2 7408 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7409 $as_echo_n "checking for $ac_word... " >&6; } 7410 if ${ac_cv_path_ECHO+:} false; then : 7411 $as_echo_n "(cached) " >&6 7412 else 7413 case $ECHO in 7414 [\\/]* | ?:[\\/]*) 7415 ac_cv_path_ECHO="$ECHO" # Let the user override the test with a path. 7416 ;; 7417 *) 7418 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7419 for as_dir in $PATH 7420 do 7421 IFS=$as_save_IFS 7422 test -z "$as_dir" && as_dir=. 7423 for ac_exec_ext in '' $ac_executable_extensions; do 7424 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7425 ac_cv_path_ECHO="$as_dir/$ac_word$ac_exec_ext" 7426 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7427 break 2 7428 fi 7429 done 7430 done 7431 IFS=$as_save_IFS 7432 7433 ;; 7434 esac 7435 fi 7436 ECHO=$ac_cv_path_ECHO 7437 if test -n "$ECHO"; then 7438 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ECHO" >&5 7439 $as_echo "$ECHO" >&6; } 7440 else 7441 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7442 $as_echo "no" >&6; } 7443 fi 7444 7445 7446 test -n "$ECHO" && break 7447 done 7448 7449 else 7450 # The variable is set, but is it from the command line or the environment? 7451 7452 # Try to remove the string !ECHO! from our list. 7453 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ECHO!/} 7454 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 7455 # If it failed, the variable was not from the command line. Ignore it, 7456 # but warn the user (except for BASH, which is always set by the calling BASH). 7457 if test "xECHO" != xBASH; then 7458 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ECHO from the environment. Use command line variables instead." >&5 7459 $as_echo "$as_me: WARNING: Ignoring value of ECHO from the environment. Use command line variables instead." >&2;} 7460 fi 7461 # Try to locate tool using the code snippet 7462 for ac_prog in echo 7463 do 7464 # Extract the first word of "$ac_prog", so it can be a program name with args. 7465 set dummy $ac_prog; ac_word=$2 7466 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7467 $as_echo_n "checking for $ac_word... " >&6; } 7468 if ${ac_cv_path_ECHO+:} false; then : 7469 $as_echo_n "(cached) " >&6 7470 else 7471 case $ECHO in 7472 [\\/]* | ?:[\\/]*) 7473 ac_cv_path_ECHO="$ECHO" # Let the user override the test with a path. 7474 ;; 7475 *) 7476 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7477 for as_dir in $PATH 7478 do 7479 IFS=$as_save_IFS 7480 test -z "$as_dir" && as_dir=. 7481 for ac_exec_ext in '' $ac_executable_extensions; do 7482 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7483 ac_cv_path_ECHO="$as_dir/$ac_word$ac_exec_ext" 7484 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7485 break 2 7486 fi 7487 done 7488 done 7489 IFS=$as_save_IFS 7490 7491 ;; 7492 esac 7493 fi 7494 ECHO=$ac_cv_path_ECHO 7495 if test -n "$ECHO"; then 7496 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ECHO" >&5 7497 $as_echo "$ECHO" >&6; } 7498 else 7499 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7500 $as_echo "no" >&6; } 7501 fi 7502 7503 7504 test -n "$ECHO" && break 7505 done 7506 7507 else 7508 # If it succeeded, then it was overridden by the user. We will use it 7509 # for the tool. 7510 7511 # First remove it from the list of overridden variables, so we can test 7512 # for unknown variables in the end. 7513 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 7514 7515 # Check if we try to supply an empty value 7516 if test "x$ECHO" = x; then 7517 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ECHO= (no value)" >&5 7518 $as_echo "$as_me: Setting user supplied tool ECHO= (no value)" >&6;} 7519 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ECHO" >&5 7520 $as_echo_n "checking for ECHO... " >&6; } 7521 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 7522 $as_echo "disabled" >&6; } 7523 else 7524 # Check if the provided tool contains a complete path. 7525 tool_specified="$ECHO" 7526 tool_basename="${tool_specified##*/}" 7527 if test "x$tool_basename" = "x$tool_specified"; then 7528 # A command without a complete path is provided, search $PATH. 7529 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ECHO=$tool_basename" >&5 7530 $as_echo "$as_me: Will search for user supplied tool ECHO=$tool_basename" >&6;} 7531 # Extract the first word of "$tool_basename", so it can be a program name with args. 7532 set dummy $tool_basename; ac_word=$2 7533 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7534 $as_echo_n "checking for $ac_word... " >&6; } 7535 if ${ac_cv_path_ECHO+:} false; then : 7536 $as_echo_n "(cached) " >&6 7537 else 7538 case $ECHO in 7539 [\\/]* | ?:[\\/]*) 7540 ac_cv_path_ECHO="$ECHO" # Let the user override the test with a path. 7541 ;; 7542 *) 7543 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7544 for as_dir in $PATH 7545 do 7546 IFS=$as_save_IFS 7547 test -z "$as_dir" && as_dir=. 7548 for ac_exec_ext in '' $ac_executable_extensions; do 7549 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7550 ac_cv_path_ECHO="$as_dir/$ac_word$ac_exec_ext" 7551 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7552 break 2 7553 fi 7554 done 7555 done 7556 IFS=$as_save_IFS 7557 7558 ;; 7559 esac 7560 fi 7561 ECHO=$ac_cv_path_ECHO 7562 if test -n "$ECHO"; then 7563 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ECHO" >&5 7564 $as_echo "$ECHO" >&6; } 7565 else 7566 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7567 $as_echo "no" >&6; } 7568 fi 7569 7570 7571 if test "x$ECHO" = x; then 7572 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 7573 fi 7574 else 7575 # Otherwise we believe it is a complete path. Use it as it is. 7576 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ECHO=$tool_specified" >&5 7577 $as_echo "$as_me: Will use user supplied tool ECHO=$tool_specified" >&6;} 7578 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ECHO" >&5 7579 $as_echo_n "checking for ECHO... " >&6; } 7580 if test ! -x "$tool_specified"; then 7581 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 7582 $as_echo "not found" >&6; } 7583 as_fn_error $? "User supplied tool ECHO=$tool_specified does not exist or is not executable" "$LINENO" 5 7584 fi 7585 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 7586 $as_echo "$tool_specified" >&6; } 7587 fi 7588 fi 7589 fi 7590 7591 fi 7592 7593 7594 7595 if test "x$ECHO" = x; then 7596 as_fn_error $? "Could not find required tool for ECHO" "$LINENO" 5 7597 fi 7598 7599 7600 7601 7602 7603 # Publish this variable in the help. 7604 7605 7606 if [ -z "${EXPR+x}" ]; then 7607 # The variable is not set by user, try to locate tool using the code snippet 7608 for ac_prog in expr 7609 do 7610 # Extract the first word of "$ac_prog", so it can be a program name with args. 7611 set dummy $ac_prog; ac_word=$2 7612 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7613 $as_echo_n "checking for $ac_word... " >&6; } 7614 if ${ac_cv_path_EXPR+:} false; then : 7615 $as_echo_n "(cached) " >&6 7616 else 7617 case $EXPR in 7618 [\\/]* | ?:[\\/]*) 7619 ac_cv_path_EXPR="$EXPR" # Let the user override the test with a path. 7620 ;; 7621 *) 7622 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7623 for as_dir in $PATH 7624 do 7625 IFS=$as_save_IFS 7626 test -z "$as_dir" && as_dir=. 7627 for ac_exec_ext in '' $ac_executable_extensions; do 7628 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7629 ac_cv_path_EXPR="$as_dir/$ac_word$ac_exec_ext" 7630 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7631 break 2 7632 fi 7633 done 7634 done 7635 IFS=$as_save_IFS 7636 7637 ;; 7638 esac 7639 fi 7640 EXPR=$ac_cv_path_EXPR 7641 if test -n "$EXPR"; then 7642 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPR" >&5 7643 $as_echo "$EXPR" >&6; } 7644 else 7645 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7646 $as_echo "no" >&6; } 7647 fi 7648 7649 7650 test -n "$EXPR" && break 7651 done 7652 7653 else 7654 # The variable is set, but is it from the command line or the environment? 7655 7656 # Try to remove the string !EXPR! from our list. 7657 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!EXPR!/} 7658 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 7659 # If it failed, the variable was not from the command line. Ignore it, 7660 # but warn the user (except for BASH, which is always set by the calling BASH). 7661 if test "xEXPR" != xBASH; then 7662 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of EXPR from the environment. Use command line variables instead." >&5 7663 $as_echo "$as_me: WARNING: Ignoring value of EXPR from the environment. Use command line variables instead." >&2;} 7664 fi 7665 # Try to locate tool using the code snippet 7666 for ac_prog in expr 7667 do 7668 # Extract the first word of "$ac_prog", so it can be a program name with args. 7669 set dummy $ac_prog; ac_word=$2 7670 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7671 $as_echo_n "checking for $ac_word... " >&6; } 7672 if ${ac_cv_path_EXPR+:} false; then : 7673 $as_echo_n "(cached) " >&6 7674 else 7675 case $EXPR in 7676 [\\/]* | ?:[\\/]*) 7677 ac_cv_path_EXPR="$EXPR" # Let the user override the test with a path. 7678 ;; 7679 *) 7680 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7681 for as_dir in $PATH 7682 do 7683 IFS=$as_save_IFS 7684 test -z "$as_dir" && as_dir=. 7685 for ac_exec_ext in '' $ac_executable_extensions; do 7686 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7687 ac_cv_path_EXPR="$as_dir/$ac_word$ac_exec_ext" 7688 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7689 break 2 7690 fi 7691 done 7692 done 7693 IFS=$as_save_IFS 7694 7695 ;; 7696 esac 7697 fi 7698 EXPR=$ac_cv_path_EXPR 7699 if test -n "$EXPR"; then 7700 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPR" >&5 7701 $as_echo "$EXPR" >&6; } 7702 else 7703 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7704 $as_echo "no" >&6; } 7705 fi 7706 7707 7708 test -n "$EXPR" && break 7709 done 7710 7711 else 7712 # If it succeeded, then it was overridden by the user. We will use it 7713 # for the tool. 7714 7715 # First remove it from the list of overridden variables, so we can test 7716 # for unknown variables in the end. 7717 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 7718 7719 # Check if we try to supply an empty value 7720 if test "x$EXPR" = x; then 7721 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool EXPR= (no value)" >&5 7722 $as_echo "$as_me: Setting user supplied tool EXPR= (no value)" >&6;} 7723 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EXPR" >&5 7724 $as_echo_n "checking for EXPR... " >&6; } 7725 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 7726 $as_echo "disabled" >&6; } 7727 else 7728 # Check if the provided tool contains a complete path. 7729 tool_specified="$EXPR" 7730 tool_basename="${tool_specified##*/}" 7731 if test "x$tool_basename" = "x$tool_specified"; then 7732 # A command without a complete path is provided, search $PATH. 7733 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool EXPR=$tool_basename" >&5 7734 $as_echo "$as_me: Will search for user supplied tool EXPR=$tool_basename" >&6;} 7735 # Extract the first word of "$tool_basename", so it can be a program name with args. 7736 set dummy $tool_basename; ac_word=$2 7737 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7738 $as_echo_n "checking for $ac_word... " >&6; } 7739 if ${ac_cv_path_EXPR+:} false; then : 7740 $as_echo_n "(cached) " >&6 7741 else 7742 case $EXPR in 7743 [\\/]* | ?:[\\/]*) 7744 ac_cv_path_EXPR="$EXPR" # Let the user override the test with a path. 7745 ;; 7746 *) 7747 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7748 for as_dir in $PATH 7749 do 7750 IFS=$as_save_IFS 7751 test -z "$as_dir" && as_dir=. 7752 for ac_exec_ext in '' $ac_executable_extensions; do 7753 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7754 ac_cv_path_EXPR="$as_dir/$ac_word$ac_exec_ext" 7755 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7756 break 2 7757 fi 7758 done 7759 done 7760 IFS=$as_save_IFS 7761 7762 ;; 7763 esac 7764 fi 7765 EXPR=$ac_cv_path_EXPR 7766 if test -n "$EXPR"; then 7767 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPR" >&5 7768 $as_echo "$EXPR" >&6; } 7769 else 7770 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7771 $as_echo "no" >&6; } 7772 fi 7773 7774 7775 if test "x$EXPR" = x; then 7776 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 7777 fi 7778 else 7779 # Otherwise we believe it is a complete path. Use it as it is. 7780 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool EXPR=$tool_specified" >&5 7781 $as_echo "$as_me: Will use user supplied tool EXPR=$tool_specified" >&6;} 7782 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EXPR" >&5 7783 $as_echo_n "checking for EXPR... " >&6; } 7784 if test ! -x "$tool_specified"; then 7785 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 7786 $as_echo "not found" >&6; } 7787 as_fn_error $? "User supplied tool EXPR=$tool_specified does not exist or is not executable" "$LINENO" 5 7788 fi 7789 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 7790 $as_echo "$tool_specified" >&6; } 7791 fi 7792 fi 7793 fi 7794 7795 fi 7796 7797 7798 7799 if test "x$EXPR" = x; then 7800 as_fn_error $? "Could not find required tool for EXPR" "$LINENO" 5 7801 fi 7802 7803 7804 7805 7806 7807 # Publish this variable in the help. 7808 7809 7810 if [ -z "${FILE+x}" ]; then 7811 # The variable is not set by user, try to locate tool using the code snippet 7812 for ac_prog in file 7813 do 7814 # Extract the first word of "$ac_prog", so it can be a program name with args. 7815 set dummy $ac_prog; ac_word=$2 7816 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7817 $as_echo_n "checking for $ac_word... " >&6; } 7818 if ${ac_cv_path_FILE+:} false; then : 7819 $as_echo_n "(cached) " >&6 7820 else 7821 case $FILE in 7822 [\\/]* | ?:[\\/]*) 7823 ac_cv_path_FILE="$FILE" # Let the user override the test with a path. 7824 ;; 7825 *) 7826 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7827 for as_dir in $PATH 7828 do 7829 IFS=$as_save_IFS 7830 test -z "$as_dir" && as_dir=. 7831 for ac_exec_ext in '' $ac_executable_extensions; do 7832 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7833 ac_cv_path_FILE="$as_dir/$ac_word$ac_exec_ext" 7834 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7835 break 2 7836 fi 7837 done 7838 done 7839 IFS=$as_save_IFS 7840 7841 ;; 7842 esac 7843 fi 7844 FILE=$ac_cv_path_FILE 7845 if test -n "$FILE"; then 7846 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILE" >&5 7847 $as_echo "$FILE" >&6; } 7848 else 7849 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7850 $as_echo "no" >&6; } 7851 fi 7852 7853 7854 test -n "$FILE" && break 7855 done 7856 7857 else 7858 # The variable is set, but is it from the command line or the environment? 7859 7860 # Try to remove the string !FILE! from our list. 7861 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FILE!/} 7862 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 7863 # If it failed, the variable was not from the command line. Ignore it, 7864 # but warn the user (except for BASH, which is always set by the calling BASH). 7865 if test "xFILE" != xBASH; then 7866 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FILE from the environment. Use command line variables instead." >&5 7867 $as_echo "$as_me: WARNING: Ignoring value of FILE from the environment. Use command line variables instead." >&2;} 7868 fi 7869 # Try to locate tool using the code snippet 7870 for ac_prog in file 7871 do 7872 # Extract the first word of "$ac_prog", so it can be a program name with args. 7873 set dummy $ac_prog; ac_word=$2 7874 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7875 $as_echo_n "checking for $ac_word... " >&6; } 7876 if ${ac_cv_path_FILE+:} false; then : 7877 $as_echo_n "(cached) " >&6 7878 else 7879 case $FILE in 7880 [\\/]* | ?:[\\/]*) 7881 ac_cv_path_FILE="$FILE" # Let the user override the test with a path. 7882 ;; 7883 *) 7884 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7885 for as_dir in $PATH 7886 do 7887 IFS=$as_save_IFS 7888 test -z "$as_dir" && as_dir=. 7889 for ac_exec_ext in '' $ac_executable_extensions; do 7890 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7891 ac_cv_path_FILE="$as_dir/$ac_word$ac_exec_ext" 7892 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7893 break 2 7894 fi 7895 done 7896 done 7897 IFS=$as_save_IFS 7898 7899 ;; 7900 esac 7901 fi 7902 FILE=$ac_cv_path_FILE 7903 if test -n "$FILE"; then 7904 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILE" >&5 7905 $as_echo "$FILE" >&6; } 7906 else 7907 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7908 $as_echo "no" >&6; } 7909 fi 7910 7911 7912 test -n "$FILE" && break 7913 done 7914 7915 else 7916 # If it succeeded, then it was overridden by the user. We will use it 7917 # for the tool. 7918 7919 # First remove it from the list of overridden variables, so we can test 7920 # for unknown variables in the end. 7921 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 7922 7923 # Check if we try to supply an empty value 7924 if test "x$FILE" = x; then 7925 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool FILE= (no value)" >&5 7926 $as_echo "$as_me: Setting user supplied tool FILE= (no value)" >&6;} 7927 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FILE" >&5 7928 $as_echo_n "checking for FILE... " >&6; } 7929 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 7930 $as_echo "disabled" >&6; } 7931 else 7932 # Check if the provided tool contains a complete path. 7933 tool_specified="$FILE" 7934 tool_basename="${tool_specified##*/}" 7935 if test "x$tool_basename" = "x$tool_specified"; then 7936 # A command without a complete path is provided, search $PATH. 7937 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FILE=$tool_basename" >&5 7938 $as_echo "$as_me: Will search for user supplied tool FILE=$tool_basename" >&6;} 7939 # Extract the first word of "$tool_basename", so it can be a program name with args. 7940 set dummy $tool_basename; ac_word=$2 7941 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7942 $as_echo_n "checking for $ac_word... " >&6; } 7943 if ${ac_cv_path_FILE+:} false; then : 7944 $as_echo_n "(cached) " >&6 7945 else 7946 case $FILE in 7947 [\\/]* | ?:[\\/]*) 7948 ac_cv_path_FILE="$FILE" # Let the user override the test with a path. 7949 ;; 7950 *) 7951 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7952 for as_dir in $PATH 7953 do 7954 IFS=$as_save_IFS 7955 test -z "$as_dir" && as_dir=. 7956 for ac_exec_ext in '' $ac_executable_extensions; do 7957 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7958 ac_cv_path_FILE="$as_dir/$ac_word$ac_exec_ext" 7959 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7960 break 2 7961 fi 7962 done 7963 done 7964 IFS=$as_save_IFS 7965 7966 ;; 7967 esac 7968 fi 7969 FILE=$ac_cv_path_FILE 7970 if test -n "$FILE"; then 7971 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILE" >&5 7972 $as_echo "$FILE" >&6; } 7973 else 7974 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7975 $as_echo "no" >&6; } 7976 fi 7977 7978 7979 if test "x$FILE" = x; then 7980 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 7981 fi 7982 else 7983 # Otherwise we believe it is a complete path. Use it as it is. 7984 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FILE=$tool_specified" >&5 7985 $as_echo "$as_me: Will use user supplied tool FILE=$tool_specified" >&6;} 7986 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FILE" >&5 7987 $as_echo_n "checking for FILE... " >&6; } 7988 if test ! -x "$tool_specified"; then 7989 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 7990 $as_echo "not found" >&6; } 7991 as_fn_error $? "User supplied tool FILE=$tool_specified does not exist or is not executable" "$LINENO" 5 7992 fi 7993 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 7994 $as_echo "$tool_specified" >&6; } 7995 fi 7996 fi 7997 fi 7998 7999 fi 8000 8001 8002 8003 if test "x$FILE" = x; then 8004 as_fn_error $? "Could not find required tool for FILE" "$LINENO" 5 8005 fi 8006 8007 8008 8009 8010 8011 # Publish this variable in the help. 8012 8013 8014 if [ -z "${FIND+x}" ]; then 8015 # The variable is not set by user, try to locate tool using the code snippet 8016 for ac_prog in find 8017 do 8018 # Extract the first word of "$ac_prog", so it can be a program name with args. 8019 set dummy $ac_prog; ac_word=$2 8020 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8021 $as_echo_n "checking for $ac_word... " >&6; } 8022 if ${ac_cv_path_FIND+:} false; then : 8023 $as_echo_n "(cached) " >&6 8024 else 8025 case $FIND in 8026 [\\/]* | ?:[\\/]*) 8027 ac_cv_path_FIND="$FIND" # Let the user override the test with a path. 8028 ;; 8029 *) 8030 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8031 for as_dir in $PATH 8032 do 8033 IFS=$as_save_IFS 8034 test -z "$as_dir" && as_dir=. 8035 for ac_exec_ext in '' $ac_executable_extensions; do 8036 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8037 ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext" 8038 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8039 break 2 8040 fi 8041 done 8042 done 8043 IFS=$as_save_IFS 8044 8045 ;; 8046 esac 8047 fi 8048 FIND=$ac_cv_path_FIND 8049 if test -n "$FIND"; then 8050 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5 8051 $as_echo "$FIND" >&6; } 8052 else 8053 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8054 $as_echo "no" >&6; } 8055 fi 8056 8057 8058 test -n "$FIND" && break 8059 done 8060 8061 else 8062 # The variable is set, but is it from the command line or the environment? 8063 8064 # Try to remove the string !FIND! from our list. 8065 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FIND!/} 8066 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 8067 # If it failed, the variable was not from the command line. Ignore it, 8068 # but warn the user (except for BASH, which is always set by the calling BASH). 8069 if test "xFIND" != xBASH; then 8070 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FIND from the environment. Use command line variables instead." >&5 8071 $as_echo "$as_me: WARNING: Ignoring value of FIND from the environment. Use command line variables instead." >&2;} 8072 fi 8073 # Try to locate tool using the code snippet 8074 for ac_prog in find 8075 do 8076 # Extract the first word of "$ac_prog", so it can be a program name with args. 8077 set dummy $ac_prog; ac_word=$2 8078 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8079 $as_echo_n "checking for $ac_word... " >&6; } 8080 if ${ac_cv_path_FIND+:} false; then : 8081 $as_echo_n "(cached) " >&6 8082 else 8083 case $FIND in 8084 [\\/]* | ?:[\\/]*) 8085 ac_cv_path_FIND="$FIND" # Let the user override the test with a path. 8086 ;; 8087 *) 8088 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8089 for as_dir in $PATH 8090 do 8091 IFS=$as_save_IFS 8092 test -z "$as_dir" && as_dir=. 8093 for ac_exec_ext in '' $ac_executable_extensions; do 8094 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8095 ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext" 8096 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8097 break 2 8098 fi 8099 done 8100 done 8101 IFS=$as_save_IFS 8102 8103 ;; 8104 esac 8105 fi 8106 FIND=$ac_cv_path_FIND 8107 if test -n "$FIND"; then 8108 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5 8109 $as_echo "$FIND" >&6; } 8110 else 8111 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8112 $as_echo "no" >&6; } 8113 fi 8114 8115 8116 test -n "$FIND" && break 8117 done 8118 8119 else 8120 # If it succeeded, then it was overridden by the user. We will use it 8121 # for the tool. 8122 8123 # First remove it from the list of overridden variables, so we can test 8124 # for unknown variables in the end. 8125 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 8126 8127 # Check if we try to supply an empty value 8128 if test "x$FIND" = x; then 8129 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool FIND= (no value)" >&5 8130 $as_echo "$as_me: Setting user supplied tool FIND= (no value)" >&6;} 8131 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FIND" >&5 8132 $as_echo_n "checking for FIND... " >&6; } 8133 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 8134 $as_echo "disabled" >&6; } 8135 else 8136 # Check if the provided tool contains a complete path. 8137 tool_specified="$FIND" 8138 tool_basename="${tool_specified##*/}" 8139 if test "x$tool_basename" = "x$tool_specified"; then 8140 # A command without a complete path is provided, search $PATH. 8141 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FIND=$tool_basename" >&5 8142 $as_echo "$as_me: Will search for user supplied tool FIND=$tool_basename" >&6;} 8143 # Extract the first word of "$tool_basename", so it can be a program name with args. 8144 set dummy $tool_basename; ac_word=$2 8145 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8146 $as_echo_n "checking for $ac_word... " >&6; } 8147 if ${ac_cv_path_FIND+:} false; then : 8148 $as_echo_n "(cached) " >&6 8149 else 8150 case $FIND in 8151 [\\/]* | ?:[\\/]*) 8152 ac_cv_path_FIND="$FIND" # Let the user override the test with a path. 8153 ;; 8154 *) 8155 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8156 for as_dir in $PATH 8157 do 8158 IFS=$as_save_IFS 8159 test -z "$as_dir" && as_dir=. 8160 for ac_exec_ext in '' $ac_executable_extensions; do 8161 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8162 ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext" 8163 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8164 break 2 8165 fi 8166 done 8167 done 8168 IFS=$as_save_IFS 8169 8170 ;; 8171 esac 8172 fi 8173 FIND=$ac_cv_path_FIND 8174 if test -n "$FIND"; then 8175 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5 8176 $as_echo "$FIND" >&6; } 8177 else 8178 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8179 $as_echo "no" >&6; } 8180 fi 8181 8182 8183 if test "x$FIND" = x; then 8184 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 8185 fi 8186 else 8187 # Otherwise we believe it is a complete path. Use it as it is. 8188 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FIND=$tool_specified" >&5 8189 $as_echo "$as_me: Will use user supplied tool FIND=$tool_specified" >&6;} 8190 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FIND" >&5 8191 $as_echo_n "checking for FIND... " >&6; } 8192 if test ! -x "$tool_specified"; then 8193 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 8194 $as_echo "not found" >&6; } 8195 as_fn_error $? "User supplied tool FIND=$tool_specified does not exist or is not executable" "$LINENO" 5 8196 fi 8197 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 8198 $as_echo "$tool_specified" >&6; } 8199 fi 8200 fi 8201 fi 8202 8203 fi 8204 8205 8206 8207 if test "x$FIND" = x; then 8208 as_fn_error $? "Could not find required tool for FIND" "$LINENO" 5 8209 fi 8210 8211 8212 8213 8214 8215 # Publish this variable in the help. 8216 8217 8218 if [ -z "${HEAD+x}" ]; then 8219 # The variable is not set by user, try to locate tool using the code snippet 8220 for ac_prog in head 8221 do 8222 # Extract the first word of "$ac_prog", so it can be a program name with args. 8223 set dummy $ac_prog; ac_word=$2 8224 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8225 $as_echo_n "checking for $ac_word... " >&6; } 8226 if ${ac_cv_path_HEAD+:} false; then : 8227 $as_echo_n "(cached) " >&6 8228 else 8229 case $HEAD in 8230 [\\/]* | ?:[\\/]*) 8231 ac_cv_path_HEAD="$HEAD" # Let the user override the test with a path. 8232 ;; 8233 *) 8234 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8235 for as_dir in $PATH 8236 do 8237 IFS=$as_save_IFS 8238 test -z "$as_dir" && as_dir=. 8239 for ac_exec_ext in '' $ac_executable_extensions; do 8240 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8241 ac_cv_path_HEAD="$as_dir/$ac_word$ac_exec_ext" 8242 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8243 break 2 8244 fi 8245 done 8246 done 8247 IFS=$as_save_IFS 8248 8249 ;; 8250 esac 8251 fi 8252 HEAD=$ac_cv_path_HEAD 8253 if test -n "$HEAD"; then 8254 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HEAD" >&5 8255 $as_echo "$HEAD" >&6; } 8256 else 8257 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8258 $as_echo "no" >&6; } 8259 fi 8260 8261 8262 test -n "$HEAD" && break 8263 done 8264 8265 else 8266 # The variable is set, but is it from the command line or the environment? 8267 8268 # Try to remove the string !HEAD! from our list. 8269 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!HEAD!/} 8270 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 8271 # If it failed, the variable was not from the command line. Ignore it, 8272 # but warn the user (except for BASH, which is always set by the calling BASH). 8273 if test "xHEAD" != xBASH; then 8274 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of HEAD from the environment. Use command line variables instead." >&5 8275 $as_echo "$as_me: WARNING: Ignoring value of HEAD from the environment. Use command line variables instead." >&2;} 8276 fi 8277 # Try to locate tool using the code snippet 8278 for ac_prog in head 8279 do 8280 # Extract the first word of "$ac_prog", so it can be a program name with args. 8281 set dummy $ac_prog; ac_word=$2 8282 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8283 $as_echo_n "checking for $ac_word... " >&6; } 8284 if ${ac_cv_path_HEAD+:} false; then : 8285 $as_echo_n "(cached) " >&6 8286 else 8287 case $HEAD in 8288 [\\/]* | ?:[\\/]*) 8289 ac_cv_path_HEAD="$HEAD" # Let the user override the test with a path. 8290 ;; 8291 *) 8292 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8293 for as_dir in $PATH 8294 do 8295 IFS=$as_save_IFS 8296 test -z "$as_dir" && as_dir=. 8297 for ac_exec_ext in '' $ac_executable_extensions; do 8298 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8299 ac_cv_path_HEAD="$as_dir/$ac_word$ac_exec_ext" 8300 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8301 break 2 8302 fi 8303 done 8304 done 8305 IFS=$as_save_IFS 8306 8307 ;; 8308 esac 8309 fi 8310 HEAD=$ac_cv_path_HEAD 8311 if test -n "$HEAD"; then 8312 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HEAD" >&5 8313 $as_echo "$HEAD" >&6; } 8314 else 8315 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8316 $as_echo "no" >&6; } 8317 fi 8318 8319 8320 test -n "$HEAD" && break 8321 done 8322 8323 else 8324 # If it succeeded, then it was overridden by the user. We will use it 8325 # for the tool. 8326 8327 # First remove it from the list of overridden variables, so we can test 8328 # for unknown variables in the end. 8329 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 8330 8331 # Check if we try to supply an empty value 8332 if test "x$HEAD" = x; then 8333 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool HEAD= (no value)" >&5 8334 $as_echo "$as_me: Setting user supplied tool HEAD= (no value)" >&6;} 8335 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HEAD" >&5 8336 $as_echo_n "checking for HEAD... " >&6; } 8337 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 8338 $as_echo "disabled" >&6; } 8339 else 8340 # Check if the provided tool contains a complete path. 8341 tool_specified="$HEAD" 8342 tool_basename="${tool_specified##*/}" 8343 if test "x$tool_basename" = "x$tool_specified"; then 8344 # A command without a complete path is provided, search $PATH. 8345 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool HEAD=$tool_basename" >&5 8346 $as_echo "$as_me: Will search for user supplied tool HEAD=$tool_basename" >&6;} 8347 # Extract the first word of "$tool_basename", so it can be a program name with args. 8348 set dummy $tool_basename; ac_word=$2 8349 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8350 $as_echo_n "checking for $ac_word... " >&6; } 8351 if ${ac_cv_path_HEAD+:} false; then : 8352 $as_echo_n "(cached) " >&6 8353 else 8354 case $HEAD in 8355 [\\/]* | ?:[\\/]*) 8356 ac_cv_path_HEAD="$HEAD" # Let the user override the test with a path. 8357 ;; 8358 *) 8359 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8360 for as_dir in $PATH 8361 do 8362 IFS=$as_save_IFS 8363 test -z "$as_dir" && as_dir=. 8364 for ac_exec_ext in '' $ac_executable_extensions; do 8365 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8366 ac_cv_path_HEAD="$as_dir/$ac_word$ac_exec_ext" 8367 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8368 break 2 8369 fi 8370 done 8371 done 8372 IFS=$as_save_IFS 8373 8374 ;; 8375 esac 8376 fi 8377 HEAD=$ac_cv_path_HEAD 8378 if test -n "$HEAD"; then 8379 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HEAD" >&5 8380 $as_echo "$HEAD" >&6; } 8381 else 8382 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8383 $as_echo "no" >&6; } 8384 fi 8385 8386 8387 if test "x$HEAD" = x; then 8388 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 8389 fi 8390 else 8391 # Otherwise we believe it is a complete path. Use it as it is. 8392 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool HEAD=$tool_specified" >&5 8393 $as_echo "$as_me: Will use user supplied tool HEAD=$tool_specified" >&6;} 8394 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HEAD" >&5 8395 $as_echo_n "checking for HEAD... " >&6; } 8396 if test ! -x "$tool_specified"; then 8397 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 8398 $as_echo "not found" >&6; } 8399 as_fn_error $? "User supplied tool HEAD=$tool_specified does not exist or is not executable" "$LINENO" 5 8400 fi 8401 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 8402 $as_echo "$tool_specified" >&6; } 8403 fi 8404 fi 8405 fi 8406 8407 fi 8408 8409 8410 8411 if test "x$HEAD" = x; then 8412 as_fn_error $? "Could not find required tool for HEAD" "$LINENO" 5 8413 fi 8414 8415 8416 8417 8418 8419 # Publish this variable in the help. 8420 8421 8422 if [ -z "${GUNZIP+x}" ]; then 8423 # The variable is not set by user, try to locate tool using the code snippet 8424 for ac_prog in gunzip 8425 do 8426 # Extract the first word of "$ac_prog", so it can be a program name with args. 8427 set dummy $ac_prog; ac_word=$2 8428 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8429 $as_echo_n "checking for $ac_word... " >&6; } 8430 if ${ac_cv_path_GUNZIP+:} false; then : 8431 $as_echo_n "(cached) " >&6 8432 else 8433 case $GUNZIP in 8434 [\\/]* | ?:[\\/]*) 8435 ac_cv_path_GUNZIP="$GUNZIP" # Let the user override the test with a path. 8436 ;; 8437 *) 8438 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8439 for as_dir in $PATH 8440 do 8441 IFS=$as_save_IFS 8442 test -z "$as_dir" && as_dir=. 8443 for ac_exec_ext in '' $ac_executable_extensions; do 8444 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8445 ac_cv_path_GUNZIP="$as_dir/$ac_word$ac_exec_ext" 8446 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8447 break 2 8448 fi 8449 done 8450 done 8451 IFS=$as_save_IFS 8452 8453 ;; 8454 esac 8455 fi 8456 GUNZIP=$ac_cv_path_GUNZIP 8457 if test -n "$GUNZIP"; then 8458 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GUNZIP" >&5 8459 $as_echo "$GUNZIP" >&6; } 8460 else 8461 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8462 $as_echo "no" >&6; } 8463 fi 8464 8465 8466 test -n "$GUNZIP" && break 8467 done 8468 8469 else 8470 # The variable is set, but is it from the command line or the environment? 8471 8472 # Try to remove the string !GUNZIP! from our list. 8473 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!GUNZIP!/} 8474 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 8475 # If it failed, the variable was not from the command line. Ignore it, 8476 # but warn the user (except for BASH, which is always set by the calling BASH). 8477 if test "xGUNZIP" != xBASH; then 8478 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of GUNZIP from the environment. Use command line variables instead." >&5 8479 $as_echo "$as_me: WARNING: Ignoring value of GUNZIP from the environment. Use command line variables instead." >&2;} 8480 fi 8481 # Try to locate tool using the code snippet 8482 for ac_prog in gunzip 8483 do 8484 # Extract the first word of "$ac_prog", so it can be a program name with args. 8485 set dummy $ac_prog; ac_word=$2 8486 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8487 $as_echo_n "checking for $ac_word... " >&6; } 8488 if ${ac_cv_path_GUNZIP+:} false; then : 8489 $as_echo_n "(cached) " >&6 8490 else 8491 case $GUNZIP in 8492 [\\/]* | ?:[\\/]*) 8493 ac_cv_path_GUNZIP="$GUNZIP" # Let the user override the test with a path. 8494 ;; 8495 *) 8496 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8497 for as_dir in $PATH 8498 do 8499 IFS=$as_save_IFS 8500 test -z "$as_dir" && as_dir=. 8501 for ac_exec_ext in '' $ac_executable_extensions; do 8502 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8503 ac_cv_path_GUNZIP="$as_dir/$ac_word$ac_exec_ext" 8504 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8505 break 2 8506 fi 8507 done 8508 done 8509 IFS=$as_save_IFS 8510 8511 ;; 8512 esac 8513 fi 8514 GUNZIP=$ac_cv_path_GUNZIP 8515 if test -n "$GUNZIP"; then 8516 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GUNZIP" >&5 8517 $as_echo "$GUNZIP" >&6; } 8518 else 8519 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8520 $as_echo "no" >&6; } 8521 fi 8522 8523 8524 test -n "$GUNZIP" && break 8525 done 8526 8527 else 8528 # If it succeeded, then it was overridden by the user. We will use it 8529 # for the tool. 8530 8531 # First remove it from the list of overridden variables, so we can test 8532 # for unknown variables in the end. 8533 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 8534 8535 # Check if we try to supply an empty value 8536 if test "x$GUNZIP" = x; then 8537 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool GUNZIP= (no value)" >&5 8538 $as_echo "$as_me: Setting user supplied tool GUNZIP= (no value)" >&6;} 8539 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GUNZIP" >&5 8540 $as_echo_n "checking for GUNZIP... " >&6; } 8541 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 8542 $as_echo "disabled" >&6; } 8543 else 8544 # Check if the provided tool contains a complete path. 8545 tool_specified="$GUNZIP" 8546 tool_basename="${tool_specified##*/}" 8547 if test "x$tool_basename" = "x$tool_specified"; then 8548 # A command without a complete path is provided, search $PATH. 8549 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool GUNZIP=$tool_basename" >&5 8550 $as_echo "$as_me: Will search for user supplied tool GUNZIP=$tool_basename" >&6;} 8551 # Extract the first word of "$tool_basename", so it can be a program name with args. 8552 set dummy $tool_basename; ac_word=$2 8553 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8554 $as_echo_n "checking for $ac_word... " >&6; } 8555 if ${ac_cv_path_GUNZIP+:} false; then : 8556 $as_echo_n "(cached) " >&6 8557 else 8558 case $GUNZIP in 8559 [\\/]* | ?:[\\/]*) 8560 ac_cv_path_GUNZIP="$GUNZIP" # Let the user override the test with a path. 8561 ;; 8562 *) 8563 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8564 for as_dir in $PATH 8565 do 8566 IFS=$as_save_IFS 8567 test -z "$as_dir" && as_dir=. 8568 for ac_exec_ext in '' $ac_executable_extensions; do 8569 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8570 ac_cv_path_GUNZIP="$as_dir/$ac_word$ac_exec_ext" 8571 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8572 break 2 8573 fi 8574 done 8575 done 8576 IFS=$as_save_IFS 8577 8578 ;; 8579 esac 8580 fi 8581 GUNZIP=$ac_cv_path_GUNZIP 8582 if test -n "$GUNZIP"; then 8583 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GUNZIP" >&5 8584 $as_echo "$GUNZIP" >&6; } 8585 else 8586 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8587 $as_echo "no" >&6; } 8588 fi 8589 8590 8591 if test "x$GUNZIP" = x; then 8592 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 8593 fi 8594 else 8595 # Otherwise we believe it is a complete path. Use it as it is. 8596 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool GUNZIP=$tool_specified" >&5 8597 $as_echo "$as_me: Will use user supplied tool GUNZIP=$tool_specified" >&6;} 8598 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GUNZIP" >&5 8599 $as_echo_n "checking for GUNZIP... " >&6; } 8600 if test ! -x "$tool_specified"; then 8601 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 8602 $as_echo "not found" >&6; } 8603 as_fn_error $? "User supplied tool GUNZIP=$tool_specified does not exist or is not executable" "$LINENO" 5 8604 fi 8605 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 8606 $as_echo "$tool_specified" >&6; } 8607 fi 8608 fi 8609 fi 8610 8611 fi 8612 8613 8614 8615 if test "x$GUNZIP" = x; then 8616 as_fn_error $? "Could not find required tool for GUNZIP" "$LINENO" 5 8617 fi 8618 8619 8620 8621 8622 8623 # Publish this variable in the help. 8624 8625 8626 if [ -z "${GZIP+x}" ]; then 8627 # The variable is not set by user, try to locate tool using the code snippet 8628 for ac_prog in pigz gzip 8629 do 8630 # Extract the first word of "$ac_prog", so it can be a program name with args. 8631 set dummy $ac_prog; ac_word=$2 8632 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8633 $as_echo_n "checking for $ac_word... " >&6; } 8634 if ${ac_cv_path_GZIP+:} false; then : 8635 $as_echo_n "(cached) " >&6 8636 else 8637 case $GZIP in 8638 [\\/]* | ?:[\\/]*) 8639 ac_cv_path_GZIP="$GZIP" # Let the user override the test with a path. 8640 ;; 8641 *) 8642 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8643 for as_dir in $PATH 8644 do 8645 IFS=$as_save_IFS 8646 test -z "$as_dir" && as_dir=. 8647 for ac_exec_ext in '' $ac_executable_extensions; do 8648 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8649 ac_cv_path_GZIP="$as_dir/$ac_word$ac_exec_ext" 8650 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8651 break 2 8652 fi 8653 done 8654 done 8655 IFS=$as_save_IFS 8656 8657 ;; 8658 esac 8659 fi 8660 GZIP=$ac_cv_path_GZIP 8661 if test -n "$GZIP"; then 8662 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP" >&5 8663 $as_echo "$GZIP" >&6; } 8664 else 8665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8666 $as_echo "no" >&6; } 8667 fi 8668 8669 8670 test -n "$GZIP" && break 8671 done 8672 8673 else 8674 # The variable is set, but is it from the command line or the environment? 8675 8676 # Try to remove the string !GZIP! from our list. 8677 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!GZIP!/} 8678 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 8679 # If it failed, the variable was not from the command line. Ignore it, 8680 # but warn the user (except for BASH, which is always set by the calling BASH). 8681 if test "xGZIP" != xBASH; then 8682 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of GZIP from the environment. Use command line variables instead." >&5 8683 $as_echo "$as_me: WARNING: Ignoring value of GZIP from the environment. Use command line variables instead." >&2;} 8684 fi 8685 # Try to locate tool using the code snippet 8686 for ac_prog in pigz gzip 8687 do 8688 # Extract the first word of "$ac_prog", so it can be a program name with args. 8689 set dummy $ac_prog; ac_word=$2 8690 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8691 $as_echo_n "checking for $ac_word... " >&6; } 8692 if ${ac_cv_path_GZIP+:} false; then : 8693 $as_echo_n "(cached) " >&6 8694 else 8695 case $GZIP in 8696 [\\/]* | ?:[\\/]*) 8697 ac_cv_path_GZIP="$GZIP" # Let the user override the test with a path. 8698 ;; 8699 *) 8700 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8701 for as_dir in $PATH 8702 do 8703 IFS=$as_save_IFS 8704 test -z "$as_dir" && as_dir=. 8705 for ac_exec_ext in '' $ac_executable_extensions; do 8706 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8707 ac_cv_path_GZIP="$as_dir/$ac_word$ac_exec_ext" 8708 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8709 break 2 8710 fi 8711 done 8712 done 8713 IFS=$as_save_IFS 8714 8715 ;; 8716 esac 8717 fi 8718 GZIP=$ac_cv_path_GZIP 8719 if test -n "$GZIP"; then 8720 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP" >&5 8721 $as_echo "$GZIP" >&6; } 8722 else 8723 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8724 $as_echo "no" >&6; } 8725 fi 8726 8727 8728 test -n "$GZIP" && break 8729 done 8730 8731 else 8732 # If it succeeded, then it was overridden by the user. We will use it 8733 # for the tool. 8734 8735 # First remove it from the list of overridden variables, so we can test 8736 # for unknown variables in the end. 8737 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 8738 8739 # Check if we try to supply an empty value 8740 if test "x$GZIP" = x; then 8741 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool GZIP= (no value)" >&5 8742 $as_echo "$as_me: Setting user supplied tool GZIP= (no value)" >&6;} 8743 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GZIP" >&5 8744 $as_echo_n "checking for GZIP... " >&6; } 8745 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 8746 $as_echo "disabled" >&6; } 8747 else 8748 # Check if the provided tool contains a complete path. 8749 tool_specified="$GZIP" 8750 tool_basename="${tool_specified##*/}" 8751 if test "x$tool_basename" = "x$tool_specified"; then 8752 # A command without a complete path is provided, search $PATH. 8753 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool GZIP=$tool_basename" >&5 8754 $as_echo "$as_me: Will search for user supplied tool GZIP=$tool_basename" >&6;} 8755 # Extract the first word of "$tool_basename", so it can be a program name with args. 8756 set dummy $tool_basename; ac_word=$2 8757 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8758 $as_echo_n "checking for $ac_word... " >&6; } 8759 if ${ac_cv_path_GZIP+:} false; then : 8760 $as_echo_n "(cached) " >&6 8761 else 8762 case $GZIP in 8763 [\\/]* | ?:[\\/]*) 8764 ac_cv_path_GZIP="$GZIP" # Let the user override the test with a path. 8765 ;; 8766 *) 8767 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8768 for as_dir in $PATH 8769 do 8770 IFS=$as_save_IFS 8771 test -z "$as_dir" && as_dir=. 8772 for ac_exec_ext in '' $ac_executable_extensions; do 8773 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8774 ac_cv_path_GZIP="$as_dir/$ac_word$ac_exec_ext" 8775 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8776 break 2 8777 fi 8778 done 8779 done 8780 IFS=$as_save_IFS 8781 8782 ;; 8783 esac 8784 fi 8785 GZIP=$ac_cv_path_GZIP 8786 if test -n "$GZIP"; then 8787 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GZIP" >&5 8788 $as_echo "$GZIP" >&6; } 8789 else 8790 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8791 $as_echo "no" >&6; } 8792 fi 8793 8794 8795 if test "x$GZIP" = x; then 8796 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 8797 fi 8798 else 8799 # Otherwise we believe it is a complete path. Use it as it is. 8800 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool GZIP=$tool_specified" >&5 8801 $as_echo "$as_me: Will use user supplied tool GZIP=$tool_specified" >&6;} 8802 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GZIP" >&5 8803 $as_echo_n "checking for GZIP... " >&6; } 8804 if test ! -x "$tool_specified"; then 8805 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 8806 $as_echo "not found" >&6; } 8807 as_fn_error $? "User supplied tool GZIP=$tool_specified does not exist or is not executable" "$LINENO" 5 8808 fi 8809 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 8810 $as_echo "$tool_specified" >&6; } 8811 fi 8812 fi 8813 fi 8814 8815 fi 8816 8817 8818 8819 if test "x$GZIP" = x; then 8820 as_fn_error $? "Could not find required tool for GZIP" "$LINENO" 5 8821 fi 8822 8823 8824 8825 8826 8827 # Publish this variable in the help. 8828 8829 8830 if [ -z "${LN+x}" ]; then 8831 # The variable is not set by user, try to locate tool using the code snippet 8832 for ac_prog in ln 8833 do 8834 # Extract the first word of "$ac_prog", so it can be a program name with args. 8835 set dummy $ac_prog; ac_word=$2 8836 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8837 $as_echo_n "checking for $ac_word... " >&6; } 8838 if ${ac_cv_path_LN+:} false; then : 8839 $as_echo_n "(cached) " >&6 8840 else 8841 case $LN in 8842 [\\/]* | ?:[\\/]*) 8843 ac_cv_path_LN="$LN" # Let the user override the test with a path. 8844 ;; 8845 *) 8846 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8847 for as_dir in $PATH 8848 do 8849 IFS=$as_save_IFS 8850 test -z "$as_dir" && as_dir=. 8851 for ac_exec_ext in '' $ac_executable_extensions; do 8852 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8853 ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext" 8854 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8855 break 2 8856 fi 8857 done 8858 done 8859 IFS=$as_save_IFS 8860 8861 ;; 8862 esac 8863 fi 8864 LN=$ac_cv_path_LN 8865 if test -n "$LN"; then 8866 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5 8867 $as_echo "$LN" >&6; } 8868 else 8869 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8870 $as_echo "no" >&6; } 8871 fi 8872 8873 8874 test -n "$LN" && break 8875 done 8876 8877 else 8878 # The variable is set, but is it from the command line or the environment? 8879 8880 # Try to remove the string !LN! from our list. 8881 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LN!/} 8882 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 8883 # If it failed, the variable was not from the command line. Ignore it, 8884 # but warn the user (except for BASH, which is always set by the calling BASH). 8885 if test "xLN" != xBASH; then 8886 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LN from the environment. Use command line variables instead." >&5 8887 $as_echo "$as_me: WARNING: Ignoring value of LN from the environment. Use command line variables instead." >&2;} 8888 fi 8889 # Try to locate tool using the code snippet 8890 for ac_prog in ln 8891 do 8892 # Extract the first word of "$ac_prog", so it can be a program name with args. 8893 set dummy $ac_prog; ac_word=$2 8894 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8895 $as_echo_n "checking for $ac_word... " >&6; } 8896 if ${ac_cv_path_LN+:} false; then : 8897 $as_echo_n "(cached) " >&6 8898 else 8899 case $LN in 8900 [\\/]* | ?:[\\/]*) 8901 ac_cv_path_LN="$LN" # Let the user override the test with a path. 8902 ;; 8903 *) 8904 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8905 for as_dir in $PATH 8906 do 8907 IFS=$as_save_IFS 8908 test -z "$as_dir" && as_dir=. 8909 for ac_exec_ext in '' $ac_executable_extensions; do 8910 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8911 ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext" 8912 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8913 break 2 8914 fi 8915 done 8916 done 8917 IFS=$as_save_IFS 8918 8919 ;; 8920 esac 8921 fi 8922 LN=$ac_cv_path_LN 8923 if test -n "$LN"; then 8924 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5 8925 $as_echo "$LN" >&6; } 8926 else 8927 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8928 $as_echo "no" >&6; } 8929 fi 8930 8931 8932 test -n "$LN" && break 8933 done 8934 8935 else 8936 # If it succeeded, then it was overridden by the user. We will use it 8937 # for the tool. 8938 8939 # First remove it from the list of overridden variables, so we can test 8940 # for unknown variables in the end. 8941 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 8942 8943 # Check if we try to supply an empty value 8944 if test "x$LN" = x; then 8945 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool LN= (no value)" >&5 8946 $as_echo "$as_me: Setting user supplied tool LN= (no value)" >&6;} 8947 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LN" >&5 8948 $as_echo_n "checking for LN... " >&6; } 8949 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 8950 $as_echo "disabled" >&6; } 8951 else 8952 # Check if the provided tool contains a complete path. 8953 tool_specified="$LN" 8954 tool_basename="${tool_specified##*/}" 8955 if test "x$tool_basename" = "x$tool_specified"; then 8956 # A command without a complete path is provided, search $PATH. 8957 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LN=$tool_basename" >&5 8958 $as_echo "$as_me: Will search for user supplied tool LN=$tool_basename" >&6;} 8959 # Extract the first word of "$tool_basename", so it can be a program name with args. 8960 set dummy $tool_basename; ac_word=$2 8961 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8962 $as_echo_n "checking for $ac_word... " >&6; } 8963 if ${ac_cv_path_LN+:} false; then : 8964 $as_echo_n "(cached) " >&6 8965 else 8966 case $LN in 8967 [\\/]* | ?:[\\/]*) 8968 ac_cv_path_LN="$LN" # Let the user override the test with a path. 8969 ;; 8970 *) 8971 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8972 for as_dir in $PATH 8973 do 8974 IFS=$as_save_IFS 8975 test -z "$as_dir" && as_dir=. 8976 for ac_exec_ext in '' $ac_executable_extensions; do 8977 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8978 ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext" 8979 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8980 break 2 8981 fi 8982 done 8983 done 8984 IFS=$as_save_IFS 8985 8986 ;; 8987 esac 8988 fi 8989 LN=$ac_cv_path_LN 8990 if test -n "$LN"; then 8991 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5 8992 $as_echo "$LN" >&6; } 8993 else 8994 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8995 $as_echo "no" >&6; } 8996 fi 8997 8998 8999 if test "x$LN" = x; then 9000 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 9001 fi 9002 else 9003 # Otherwise we believe it is a complete path. Use it as it is. 9004 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LN=$tool_specified" >&5 9005 $as_echo "$as_me: Will use user supplied tool LN=$tool_specified" >&6;} 9006 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LN" >&5 9007 $as_echo_n "checking for LN... " >&6; } 9008 if test ! -x "$tool_specified"; then 9009 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 9010 $as_echo "not found" >&6; } 9011 as_fn_error $? "User supplied tool LN=$tool_specified does not exist or is not executable" "$LINENO" 5 9012 fi 9013 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 9014 $as_echo "$tool_specified" >&6; } 9015 fi 9016 fi 9017 fi 9018 9019 fi 9020 9021 9022 9023 if test "x$LN" = x; then 9024 as_fn_error $? "Could not find required tool for LN" "$LINENO" 5 9025 fi 9026 9027 9028 9029 9030 9031 # Publish this variable in the help. 9032 9033 9034 if [ -z "${LS+x}" ]; then 9035 # The variable is not set by user, try to locate tool using the code snippet 9036 for ac_prog in ls 9037 do 9038 # Extract the first word of "$ac_prog", so it can be a program name with args. 9039 set dummy $ac_prog; ac_word=$2 9040 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9041 $as_echo_n "checking for $ac_word... " >&6; } 9042 if ${ac_cv_path_LS+:} false; then : 9043 $as_echo_n "(cached) " >&6 9044 else 9045 case $LS in 9046 [\\/]* | ?:[\\/]*) 9047 ac_cv_path_LS="$LS" # Let the user override the test with a path. 9048 ;; 9049 *) 9050 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9051 for as_dir in $PATH 9052 do 9053 IFS=$as_save_IFS 9054 test -z "$as_dir" && as_dir=. 9055 for ac_exec_ext in '' $ac_executable_extensions; do 9056 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9057 ac_cv_path_LS="$as_dir/$ac_word$ac_exec_ext" 9058 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9059 break 2 9060 fi 9061 done 9062 done 9063 IFS=$as_save_IFS 9064 9065 ;; 9066 esac 9067 fi 9068 LS=$ac_cv_path_LS 9069 if test -n "$LS"; then 9070 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LS" >&5 9071 $as_echo "$LS" >&6; } 9072 else 9073 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9074 $as_echo "no" >&6; } 9075 fi 9076 9077 9078 test -n "$LS" && break 9079 done 9080 9081 else 9082 # The variable is set, but is it from the command line or the environment? 9083 9084 # Try to remove the string !LS! from our list. 9085 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LS!/} 9086 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 9087 # If it failed, the variable was not from the command line. Ignore it, 9088 # but warn the user (except for BASH, which is always set by the calling BASH). 9089 if test "xLS" != xBASH; then 9090 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LS from the environment. Use command line variables instead." >&5 9091 $as_echo "$as_me: WARNING: Ignoring value of LS from the environment. Use command line variables instead." >&2;} 9092 fi 9093 # Try to locate tool using the code snippet 9094 for ac_prog in ls 9095 do 9096 # Extract the first word of "$ac_prog", so it can be a program name with args. 9097 set dummy $ac_prog; ac_word=$2 9098 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9099 $as_echo_n "checking for $ac_word... " >&6; } 9100 if ${ac_cv_path_LS+:} false; then : 9101 $as_echo_n "(cached) " >&6 9102 else 9103 case $LS in 9104 [\\/]* | ?:[\\/]*) 9105 ac_cv_path_LS="$LS" # Let the user override the test with a path. 9106 ;; 9107 *) 9108 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9109 for as_dir in $PATH 9110 do 9111 IFS=$as_save_IFS 9112 test -z "$as_dir" && as_dir=. 9113 for ac_exec_ext in '' $ac_executable_extensions; do 9114 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9115 ac_cv_path_LS="$as_dir/$ac_word$ac_exec_ext" 9116 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9117 break 2 9118 fi 9119 done 9120 done 9121 IFS=$as_save_IFS 9122 9123 ;; 9124 esac 9125 fi 9126 LS=$ac_cv_path_LS 9127 if test -n "$LS"; then 9128 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LS" >&5 9129 $as_echo "$LS" >&6; } 9130 else 9131 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9132 $as_echo "no" >&6; } 9133 fi 9134 9135 9136 test -n "$LS" && break 9137 done 9138 9139 else 9140 # If it succeeded, then it was overridden by the user. We will use it 9141 # for the tool. 9142 9143 # First remove it from the list of overridden variables, so we can test 9144 # for unknown variables in the end. 9145 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 9146 9147 # Check if we try to supply an empty value 9148 if test "x$LS" = x; then 9149 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool LS= (no value)" >&5 9150 $as_echo "$as_me: Setting user supplied tool LS= (no value)" >&6;} 9151 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LS" >&5 9152 $as_echo_n "checking for LS... " >&6; } 9153 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 9154 $as_echo "disabled" >&6; } 9155 else 9156 # Check if the provided tool contains a complete path. 9157 tool_specified="$LS" 9158 tool_basename="${tool_specified##*/}" 9159 if test "x$tool_basename" = "x$tool_specified"; then 9160 # A command without a complete path is provided, search $PATH. 9161 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LS=$tool_basename" >&5 9162 $as_echo "$as_me: Will search for user supplied tool LS=$tool_basename" >&6;} 9163 # Extract the first word of "$tool_basename", so it can be a program name with args. 9164 set dummy $tool_basename; ac_word=$2 9165 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9166 $as_echo_n "checking for $ac_word... " >&6; } 9167 if ${ac_cv_path_LS+:} false; then : 9168 $as_echo_n "(cached) " >&6 9169 else 9170 case $LS in 9171 [\\/]* | ?:[\\/]*) 9172 ac_cv_path_LS="$LS" # Let the user override the test with a path. 9173 ;; 9174 *) 9175 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9176 for as_dir in $PATH 9177 do 9178 IFS=$as_save_IFS 9179 test -z "$as_dir" && as_dir=. 9180 for ac_exec_ext in '' $ac_executable_extensions; do 9181 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9182 ac_cv_path_LS="$as_dir/$ac_word$ac_exec_ext" 9183 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9184 break 2 9185 fi 9186 done 9187 done 9188 IFS=$as_save_IFS 9189 9190 ;; 9191 esac 9192 fi 9193 LS=$ac_cv_path_LS 9194 if test -n "$LS"; then 9195 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LS" >&5 9196 $as_echo "$LS" >&6; } 9197 else 9198 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9199 $as_echo "no" >&6; } 9200 fi 9201 9202 9203 if test "x$LS" = x; then 9204 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 9205 fi 9206 else 9207 # Otherwise we believe it is a complete path. Use it as it is. 9208 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LS=$tool_specified" >&5 9209 $as_echo "$as_me: Will use user supplied tool LS=$tool_specified" >&6;} 9210 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LS" >&5 9211 $as_echo_n "checking for LS... " >&6; } 9212 if test ! -x "$tool_specified"; then 9213 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 9214 $as_echo "not found" >&6; } 9215 as_fn_error $? "User supplied tool LS=$tool_specified does not exist or is not executable" "$LINENO" 5 9216 fi 9217 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 9218 $as_echo "$tool_specified" >&6; } 9219 fi 9220 fi 9221 fi 9222 9223 fi 9224 9225 9226 9227 if test "x$LS" = x; then 9228 as_fn_error $? "Could not find required tool for LS" "$LINENO" 5 9229 fi 9230 9231 9232 9233 9234 9235 # Publish this variable in the help. 9236 9237 9238 if [ -z "${MKDIR+x}" ]; then 9239 # The variable is not set by user, try to locate tool using the code snippet 9240 for ac_prog in mkdir 9241 do 9242 # Extract the first word of "$ac_prog", so it can be a program name with args. 9243 set dummy $ac_prog; ac_word=$2 9244 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9245 $as_echo_n "checking for $ac_word... " >&6; } 9246 if ${ac_cv_path_MKDIR+:} false; then : 9247 $as_echo_n "(cached) " >&6 9248 else 9249 case $MKDIR in 9250 [\\/]* | ?:[\\/]*) 9251 ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path. 9252 ;; 9253 *) 9254 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9255 for as_dir in $PATH 9256 do 9257 IFS=$as_save_IFS 9258 test -z "$as_dir" && as_dir=. 9259 for ac_exec_ext in '' $ac_executable_extensions; do 9260 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9261 ac_cv_path_MKDIR="$as_dir/$ac_word$ac_exec_ext" 9262 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9263 break 2 9264 fi 9265 done 9266 done 9267 IFS=$as_save_IFS 9268 9269 ;; 9270 esac 9271 fi 9272 MKDIR=$ac_cv_path_MKDIR 9273 if test -n "$MKDIR"; then 9274 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR" >&5 9275 $as_echo "$MKDIR" >&6; } 9276 else 9277 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9278 $as_echo "no" >&6; } 9279 fi 9280 9281 9282 test -n "$MKDIR" && break 9283 done 9284 9285 else 9286 # The variable is set, but is it from the command line or the environment? 9287 9288 # Try to remove the string !MKDIR! from our list. 9289 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MKDIR!/} 9290 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 9291 # If it failed, the variable was not from the command line. Ignore it, 9292 # but warn the user (except for BASH, which is always set by the calling BASH). 9293 if test "xMKDIR" != xBASH; then 9294 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MKDIR from the environment. Use command line variables instead." >&5 9295 $as_echo "$as_me: WARNING: Ignoring value of MKDIR from the environment. Use command line variables instead." >&2;} 9296 fi 9297 # Try to locate tool using the code snippet 9298 for ac_prog in mkdir 9299 do 9300 # Extract the first word of "$ac_prog", so it can be a program name with args. 9301 set dummy $ac_prog; ac_word=$2 9302 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9303 $as_echo_n "checking for $ac_word... " >&6; } 9304 if ${ac_cv_path_MKDIR+:} false; then : 9305 $as_echo_n "(cached) " >&6 9306 else 9307 case $MKDIR in 9308 [\\/]* | ?:[\\/]*) 9309 ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path. 9310 ;; 9311 *) 9312 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9313 for as_dir in $PATH 9314 do 9315 IFS=$as_save_IFS 9316 test -z "$as_dir" && as_dir=. 9317 for ac_exec_ext in '' $ac_executable_extensions; do 9318 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9319 ac_cv_path_MKDIR="$as_dir/$ac_word$ac_exec_ext" 9320 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9321 break 2 9322 fi 9323 done 9324 done 9325 IFS=$as_save_IFS 9326 9327 ;; 9328 esac 9329 fi 9330 MKDIR=$ac_cv_path_MKDIR 9331 if test -n "$MKDIR"; then 9332 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR" >&5 9333 $as_echo "$MKDIR" >&6; } 9334 else 9335 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9336 $as_echo "no" >&6; } 9337 fi 9338 9339 9340 test -n "$MKDIR" && break 9341 done 9342 9343 else 9344 # If it succeeded, then it was overridden by the user. We will use it 9345 # for the tool. 9346 9347 # First remove it from the list of overridden variables, so we can test 9348 # for unknown variables in the end. 9349 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 9350 9351 # Check if we try to supply an empty value 9352 if test "x$MKDIR" = x; then 9353 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool MKDIR= (no value)" >&5 9354 $as_echo "$as_me: Setting user supplied tool MKDIR= (no value)" >&6;} 9355 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKDIR" >&5 9356 $as_echo_n "checking for MKDIR... " >&6; } 9357 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 9358 $as_echo "disabled" >&6; } 9359 else 9360 # Check if the provided tool contains a complete path. 9361 tool_specified="$MKDIR" 9362 tool_basename="${tool_specified##*/}" 9363 if test "x$tool_basename" = "x$tool_specified"; then 9364 # A command without a complete path is provided, search $PATH. 9365 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MKDIR=$tool_basename" >&5 9366 $as_echo "$as_me: Will search for user supplied tool MKDIR=$tool_basename" >&6;} 9367 # Extract the first word of "$tool_basename", so it can be a program name with args. 9368 set dummy $tool_basename; ac_word=$2 9369 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9370 $as_echo_n "checking for $ac_word... " >&6; } 9371 if ${ac_cv_path_MKDIR+:} false; then : 9372 $as_echo_n "(cached) " >&6 9373 else 9374 case $MKDIR in 9375 [\\/]* | ?:[\\/]*) 9376 ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path. 9377 ;; 9378 *) 9379 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9380 for as_dir in $PATH 9381 do 9382 IFS=$as_save_IFS 9383 test -z "$as_dir" && as_dir=. 9384 for ac_exec_ext in '' $ac_executable_extensions; do 9385 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9386 ac_cv_path_MKDIR="$as_dir/$ac_word$ac_exec_ext" 9387 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9388 break 2 9389 fi 9390 done 9391 done 9392 IFS=$as_save_IFS 9393 9394 ;; 9395 esac 9396 fi 9397 MKDIR=$ac_cv_path_MKDIR 9398 if test -n "$MKDIR"; then 9399 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR" >&5 9400 $as_echo "$MKDIR" >&6; } 9401 else 9402 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9403 $as_echo "no" >&6; } 9404 fi 9405 9406 9407 if test "x$MKDIR" = x; then 9408 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 9409 fi 9410 else 9411 # Otherwise we believe it is a complete path. Use it as it is. 9412 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MKDIR=$tool_specified" >&5 9413 $as_echo "$as_me: Will use user supplied tool MKDIR=$tool_specified" >&6;} 9414 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKDIR" >&5 9415 $as_echo_n "checking for MKDIR... " >&6; } 9416 if test ! -x "$tool_specified"; then 9417 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 9418 $as_echo "not found" >&6; } 9419 as_fn_error $? "User supplied tool MKDIR=$tool_specified does not exist or is not executable" "$LINENO" 5 9420 fi 9421 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 9422 $as_echo "$tool_specified" >&6; } 9423 fi 9424 fi 9425 fi 9426 9427 fi 9428 9429 9430 9431 if test "x$MKDIR" = x; then 9432 as_fn_error $? "Could not find required tool for MKDIR" "$LINENO" 5 9433 fi 9434 9435 9436 9437 9438 9439 # Publish this variable in the help. 9440 9441 9442 if [ -z "${MKTEMP+x}" ]; then 9443 # The variable is not set by user, try to locate tool using the code snippet 9444 for ac_prog in mktemp 9445 do 9446 # Extract the first word of "$ac_prog", so it can be a program name with args. 9447 set dummy $ac_prog; ac_word=$2 9448 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9449 $as_echo_n "checking for $ac_word... " >&6; } 9450 if ${ac_cv_path_MKTEMP+:} false; then : 9451 $as_echo_n "(cached) " >&6 9452 else 9453 case $MKTEMP in 9454 [\\/]* | ?:[\\/]*) 9455 ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path. 9456 ;; 9457 *) 9458 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9459 for as_dir in $PATH 9460 do 9461 IFS=$as_save_IFS 9462 test -z "$as_dir" && as_dir=. 9463 for ac_exec_ext in '' $ac_executable_extensions; do 9464 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9465 ac_cv_path_MKTEMP="$as_dir/$ac_word$ac_exec_ext" 9466 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9467 break 2 9468 fi 9469 done 9470 done 9471 IFS=$as_save_IFS 9472 9473 ;; 9474 esac 9475 fi 9476 MKTEMP=$ac_cv_path_MKTEMP 9477 if test -n "$MKTEMP"; then 9478 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKTEMP" >&5 9479 $as_echo "$MKTEMP" >&6; } 9480 else 9481 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9482 $as_echo "no" >&6; } 9483 fi 9484 9485 9486 test -n "$MKTEMP" && break 9487 done 9488 9489 else 9490 # The variable is set, but is it from the command line or the environment? 9491 9492 # Try to remove the string !MKTEMP! from our list. 9493 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MKTEMP!/} 9494 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 9495 # If it failed, the variable was not from the command line. Ignore it, 9496 # but warn the user (except for BASH, which is always set by the calling BASH). 9497 if test "xMKTEMP" != xBASH; then 9498 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MKTEMP from the environment. Use command line variables instead." >&5 9499 $as_echo "$as_me: WARNING: Ignoring value of MKTEMP from the environment. Use command line variables instead." >&2;} 9500 fi 9501 # Try to locate tool using the code snippet 9502 for ac_prog in mktemp 9503 do 9504 # Extract the first word of "$ac_prog", so it can be a program name with args. 9505 set dummy $ac_prog; ac_word=$2 9506 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9507 $as_echo_n "checking for $ac_word... " >&6; } 9508 if ${ac_cv_path_MKTEMP+:} false; then : 9509 $as_echo_n "(cached) " >&6 9510 else 9511 case $MKTEMP in 9512 [\\/]* | ?:[\\/]*) 9513 ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path. 9514 ;; 9515 *) 9516 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9517 for as_dir in $PATH 9518 do 9519 IFS=$as_save_IFS 9520 test -z "$as_dir" && as_dir=. 9521 for ac_exec_ext in '' $ac_executable_extensions; do 9522 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9523 ac_cv_path_MKTEMP="$as_dir/$ac_word$ac_exec_ext" 9524 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9525 break 2 9526 fi 9527 done 9528 done 9529 IFS=$as_save_IFS 9530 9531 ;; 9532 esac 9533 fi 9534 MKTEMP=$ac_cv_path_MKTEMP 9535 if test -n "$MKTEMP"; then 9536 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKTEMP" >&5 9537 $as_echo "$MKTEMP" >&6; } 9538 else 9539 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9540 $as_echo "no" >&6; } 9541 fi 9542 9543 9544 test -n "$MKTEMP" && break 9545 done 9546 9547 else 9548 # If it succeeded, then it was overridden by the user. We will use it 9549 # for the tool. 9550 9551 # First remove it from the list of overridden variables, so we can test 9552 # for unknown variables in the end. 9553 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 9554 9555 # Check if we try to supply an empty value 9556 if test "x$MKTEMP" = x; then 9557 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool MKTEMP= (no value)" >&5 9558 $as_echo "$as_me: Setting user supplied tool MKTEMP= (no value)" >&6;} 9559 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKTEMP" >&5 9560 $as_echo_n "checking for MKTEMP... " >&6; } 9561 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 9562 $as_echo "disabled" >&6; } 9563 else 9564 # Check if the provided tool contains a complete path. 9565 tool_specified="$MKTEMP" 9566 tool_basename="${tool_specified##*/}" 9567 if test "x$tool_basename" = "x$tool_specified"; then 9568 # A command without a complete path is provided, search $PATH. 9569 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MKTEMP=$tool_basename" >&5 9570 $as_echo "$as_me: Will search for user supplied tool MKTEMP=$tool_basename" >&6;} 9571 # Extract the first word of "$tool_basename", so it can be a program name with args. 9572 set dummy $tool_basename; ac_word=$2 9573 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9574 $as_echo_n "checking for $ac_word... " >&6; } 9575 if ${ac_cv_path_MKTEMP+:} false; then : 9576 $as_echo_n "(cached) " >&6 9577 else 9578 case $MKTEMP in 9579 [\\/]* | ?:[\\/]*) 9580 ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path. 9581 ;; 9582 *) 9583 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9584 for as_dir in $PATH 9585 do 9586 IFS=$as_save_IFS 9587 test -z "$as_dir" && as_dir=. 9588 for ac_exec_ext in '' $ac_executable_extensions; do 9589 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9590 ac_cv_path_MKTEMP="$as_dir/$ac_word$ac_exec_ext" 9591 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9592 break 2 9593 fi 9594 done 9595 done 9596 IFS=$as_save_IFS 9597 9598 ;; 9599 esac 9600 fi 9601 MKTEMP=$ac_cv_path_MKTEMP 9602 if test -n "$MKTEMP"; then 9603 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKTEMP" >&5 9604 $as_echo "$MKTEMP" >&6; } 9605 else 9606 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9607 $as_echo "no" >&6; } 9608 fi 9609 9610 9611 if test "x$MKTEMP" = x; then 9612 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 9613 fi 9614 else 9615 # Otherwise we believe it is a complete path. Use it as it is. 9616 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MKTEMP=$tool_specified" >&5 9617 $as_echo "$as_me: Will use user supplied tool MKTEMP=$tool_specified" >&6;} 9618 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKTEMP" >&5 9619 $as_echo_n "checking for MKTEMP... " >&6; } 9620 if test ! -x "$tool_specified"; then 9621 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 9622 $as_echo "not found" >&6; } 9623 as_fn_error $? "User supplied tool MKTEMP=$tool_specified does not exist or is not executable" "$LINENO" 5 9624 fi 9625 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 9626 $as_echo "$tool_specified" >&6; } 9627 fi 9628 fi 9629 fi 9630 9631 fi 9632 9633 9634 9635 if test "x$MKTEMP" = x; then 9636 as_fn_error $? "Could not find required tool for MKTEMP" "$LINENO" 5 9637 fi 9638 9639 9640 9641 9642 9643 # Publish this variable in the help. 9644 9645 9646 if [ -z "${MV+x}" ]; then 9647 # The variable is not set by user, try to locate tool using the code snippet 9648 for ac_prog in mv 9649 do 9650 # Extract the first word of "$ac_prog", so it can be a program name with args. 9651 set dummy $ac_prog; ac_word=$2 9652 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9653 $as_echo_n "checking for $ac_word... " >&6; } 9654 if ${ac_cv_path_MV+:} false; then : 9655 $as_echo_n "(cached) " >&6 9656 else 9657 case $MV in 9658 [\\/]* | ?:[\\/]*) 9659 ac_cv_path_MV="$MV" # Let the user override the test with a path. 9660 ;; 9661 *) 9662 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9663 for as_dir in $PATH 9664 do 9665 IFS=$as_save_IFS 9666 test -z "$as_dir" && as_dir=. 9667 for ac_exec_ext in '' $ac_executable_extensions; do 9668 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9669 ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext" 9670 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9671 break 2 9672 fi 9673 done 9674 done 9675 IFS=$as_save_IFS 9676 9677 ;; 9678 esac 9679 fi 9680 MV=$ac_cv_path_MV 9681 if test -n "$MV"; then 9682 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MV" >&5 9683 $as_echo "$MV" >&6; } 9684 else 9685 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9686 $as_echo "no" >&6; } 9687 fi 9688 9689 9690 test -n "$MV" && break 9691 done 9692 9693 else 9694 # The variable is set, but is it from the command line or the environment? 9695 9696 # Try to remove the string !MV! from our list. 9697 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MV!/} 9698 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 9699 # If it failed, the variable was not from the command line. Ignore it, 9700 # but warn the user (except for BASH, which is always set by the calling BASH). 9701 if test "xMV" != xBASH; then 9702 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MV from the environment. Use command line variables instead." >&5 9703 $as_echo "$as_me: WARNING: Ignoring value of MV from the environment. Use command line variables instead." >&2;} 9704 fi 9705 # Try to locate tool using the code snippet 9706 for ac_prog in mv 9707 do 9708 # Extract the first word of "$ac_prog", so it can be a program name with args. 9709 set dummy $ac_prog; ac_word=$2 9710 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9711 $as_echo_n "checking for $ac_word... " >&6; } 9712 if ${ac_cv_path_MV+:} false; then : 9713 $as_echo_n "(cached) " >&6 9714 else 9715 case $MV in 9716 [\\/]* | ?:[\\/]*) 9717 ac_cv_path_MV="$MV" # Let the user override the test with a path. 9718 ;; 9719 *) 9720 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9721 for as_dir in $PATH 9722 do 9723 IFS=$as_save_IFS 9724 test -z "$as_dir" && as_dir=. 9725 for ac_exec_ext in '' $ac_executable_extensions; do 9726 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9727 ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext" 9728 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9729 break 2 9730 fi 9731 done 9732 done 9733 IFS=$as_save_IFS 9734 9735 ;; 9736 esac 9737 fi 9738 MV=$ac_cv_path_MV 9739 if test -n "$MV"; then 9740 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MV" >&5 9741 $as_echo "$MV" >&6; } 9742 else 9743 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9744 $as_echo "no" >&6; } 9745 fi 9746 9747 9748 test -n "$MV" && break 9749 done 9750 9751 else 9752 # If it succeeded, then it was overridden by the user. We will use it 9753 # for the tool. 9754 9755 # First remove it from the list of overridden variables, so we can test 9756 # for unknown variables in the end. 9757 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 9758 9759 # Check if we try to supply an empty value 9760 if test "x$MV" = x; then 9761 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool MV= (no value)" >&5 9762 $as_echo "$as_me: Setting user supplied tool MV= (no value)" >&6;} 9763 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MV" >&5 9764 $as_echo_n "checking for MV... " >&6; } 9765 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 9766 $as_echo "disabled" >&6; } 9767 else 9768 # Check if the provided tool contains a complete path. 9769 tool_specified="$MV" 9770 tool_basename="${tool_specified##*/}" 9771 if test "x$tool_basename" = "x$tool_specified"; then 9772 # A command without a complete path is provided, search $PATH. 9773 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MV=$tool_basename" >&5 9774 $as_echo "$as_me: Will search for user supplied tool MV=$tool_basename" >&6;} 9775 # Extract the first word of "$tool_basename", so it can be a program name with args. 9776 set dummy $tool_basename; ac_word=$2 9777 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9778 $as_echo_n "checking for $ac_word... " >&6; } 9779 if ${ac_cv_path_MV+:} false; then : 9780 $as_echo_n "(cached) " >&6 9781 else 9782 case $MV in 9783 [\\/]* | ?:[\\/]*) 9784 ac_cv_path_MV="$MV" # Let the user override the test with a path. 9785 ;; 9786 *) 9787 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9788 for as_dir in $PATH 9789 do 9790 IFS=$as_save_IFS 9791 test -z "$as_dir" && as_dir=. 9792 for ac_exec_ext in '' $ac_executable_extensions; do 9793 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9794 ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext" 9795 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9796 break 2 9797 fi 9798 done 9799 done 9800 IFS=$as_save_IFS 9801 9802 ;; 9803 esac 9804 fi 9805 MV=$ac_cv_path_MV 9806 if test -n "$MV"; then 9807 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MV" >&5 9808 $as_echo "$MV" >&6; } 9809 else 9810 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9811 $as_echo "no" >&6; } 9812 fi 9813 9814 9815 if test "x$MV" = x; then 9816 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 9817 fi 9818 else 9819 # Otherwise we believe it is a complete path. Use it as it is. 9820 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MV=$tool_specified" >&5 9821 $as_echo "$as_me: Will use user supplied tool MV=$tool_specified" >&6;} 9822 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MV" >&5 9823 $as_echo_n "checking for MV... " >&6; } 9824 if test ! -x "$tool_specified"; then 9825 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 9826 $as_echo "not found" >&6; } 9827 as_fn_error $? "User supplied tool MV=$tool_specified does not exist or is not executable" "$LINENO" 5 9828 fi 9829 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 9830 $as_echo "$tool_specified" >&6; } 9831 fi 9832 fi 9833 fi 9834 9835 fi 9836 9837 9838 9839 if test "x$MV" = x; then 9840 as_fn_error $? "Could not find required tool for MV" "$LINENO" 5 9841 fi 9842 9843 9844 9845 9846 9847 # Publish this variable in the help. 9848 9849 9850 if [ -z "${NAWK+x}" ]; then 9851 # The variable is not set by user, try to locate tool using the code snippet 9852 for ac_prog in nawk gawk awk 9853 do 9854 # Extract the first word of "$ac_prog", so it can be a program name with args. 9855 set dummy $ac_prog; ac_word=$2 9856 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9857 $as_echo_n "checking for $ac_word... " >&6; } 9858 if ${ac_cv_path_NAWK+:} false; then : 9859 $as_echo_n "(cached) " >&6 9860 else 9861 case $NAWK in 9862 [\\/]* | ?:[\\/]*) 9863 ac_cv_path_NAWK="$NAWK" # Let the user override the test with a path. 9864 ;; 9865 *) 9866 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9867 for as_dir in $PATH 9868 do 9869 IFS=$as_save_IFS 9870 test -z "$as_dir" && as_dir=. 9871 for ac_exec_ext in '' $ac_executable_extensions; do 9872 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9873 ac_cv_path_NAWK="$as_dir/$ac_word$ac_exec_ext" 9874 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9875 break 2 9876 fi 9877 done 9878 done 9879 IFS=$as_save_IFS 9880 9881 ;; 9882 esac 9883 fi 9884 NAWK=$ac_cv_path_NAWK 9885 if test -n "$NAWK"; then 9886 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NAWK" >&5 9887 $as_echo "$NAWK" >&6; } 9888 else 9889 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9890 $as_echo "no" >&6; } 9891 fi 9892 9893 9894 test -n "$NAWK" && break 9895 done 9896 9897 else 9898 # The variable is set, but is it from the command line or the environment? 9899 9900 # Try to remove the string !NAWK! from our list. 9901 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NAWK!/} 9902 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 9903 # If it failed, the variable was not from the command line. Ignore it, 9904 # but warn the user (except for BASH, which is always set by the calling BASH). 9905 if test "xNAWK" != xBASH; then 9906 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NAWK from the environment. Use command line variables instead." >&5 9907 $as_echo "$as_me: WARNING: Ignoring value of NAWK from the environment. Use command line variables instead." >&2;} 9908 fi 9909 # Try to locate tool using the code snippet 9910 for ac_prog in nawk gawk awk 9911 do 9912 # Extract the first word of "$ac_prog", so it can be a program name with args. 9913 set dummy $ac_prog; ac_word=$2 9914 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9915 $as_echo_n "checking for $ac_word... " >&6; } 9916 if ${ac_cv_path_NAWK+:} false; then : 9917 $as_echo_n "(cached) " >&6 9918 else 9919 case $NAWK in 9920 [\\/]* | ?:[\\/]*) 9921 ac_cv_path_NAWK="$NAWK" # Let the user override the test with a path. 9922 ;; 9923 *) 9924 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9925 for as_dir in $PATH 9926 do 9927 IFS=$as_save_IFS 9928 test -z "$as_dir" && as_dir=. 9929 for ac_exec_ext in '' $ac_executable_extensions; do 9930 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9931 ac_cv_path_NAWK="$as_dir/$ac_word$ac_exec_ext" 9932 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9933 break 2 9934 fi 9935 done 9936 done 9937 IFS=$as_save_IFS 9938 9939 ;; 9940 esac 9941 fi 9942 NAWK=$ac_cv_path_NAWK 9943 if test -n "$NAWK"; then 9944 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NAWK" >&5 9945 $as_echo "$NAWK" >&6; } 9946 else 9947 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9948 $as_echo "no" >&6; } 9949 fi 9950 9951 9952 test -n "$NAWK" && break 9953 done 9954 9955 else 9956 # If it succeeded, then it was overridden by the user. We will use it 9957 # for the tool. 9958 9959 # First remove it from the list of overridden variables, so we can test 9960 # for unknown variables in the end. 9961 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 9962 9963 # Check if we try to supply an empty value 9964 if test "x$NAWK" = x; then 9965 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool NAWK= (no value)" >&5 9966 $as_echo "$as_me: Setting user supplied tool NAWK= (no value)" >&6;} 9967 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NAWK" >&5 9968 $as_echo_n "checking for NAWK... " >&6; } 9969 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 9970 $as_echo "disabled" >&6; } 9971 else 9972 # Check if the provided tool contains a complete path. 9973 tool_specified="$NAWK" 9974 tool_basename="${tool_specified##*/}" 9975 if test "x$tool_basename" = "x$tool_specified"; then 9976 # A command without a complete path is provided, search $PATH. 9977 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NAWK=$tool_basename" >&5 9978 $as_echo "$as_me: Will search for user supplied tool NAWK=$tool_basename" >&6;} 9979 # Extract the first word of "$tool_basename", so it can be a program name with args. 9980 set dummy $tool_basename; ac_word=$2 9981 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9982 $as_echo_n "checking for $ac_word... " >&6; } 9983 if ${ac_cv_path_NAWK+:} false; then : 9984 $as_echo_n "(cached) " >&6 9985 else 9986 case $NAWK in 9987 [\\/]* | ?:[\\/]*) 9988 ac_cv_path_NAWK="$NAWK" # Let the user override the test with a path. 9989 ;; 9990 *) 9991 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9992 for as_dir in $PATH 9993 do 9994 IFS=$as_save_IFS 9995 test -z "$as_dir" && as_dir=. 9996 for ac_exec_ext in '' $ac_executable_extensions; do 9997 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9998 ac_cv_path_NAWK="$as_dir/$ac_word$ac_exec_ext" 9999 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10000 break 2 10001 fi 10002 done 10003 done 10004 IFS=$as_save_IFS 10005 10006 ;; 10007 esac 10008 fi 10009 NAWK=$ac_cv_path_NAWK 10010 if test -n "$NAWK"; then 10011 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NAWK" >&5 10012 $as_echo "$NAWK" >&6; } 10013 else 10014 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10015 $as_echo "no" >&6; } 10016 fi 10017 10018 10019 if test "x$NAWK" = x; then 10020 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 10021 fi 10022 else 10023 # Otherwise we believe it is a complete path. Use it as it is. 10024 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NAWK=$tool_specified" >&5 10025 $as_echo "$as_me: Will use user supplied tool NAWK=$tool_specified" >&6;} 10026 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NAWK" >&5 10027 $as_echo_n "checking for NAWK... " >&6; } 10028 if test ! -x "$tool_specified"; then 10029 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 10030 $as_echo "not found" >&6; } 10031 as_fn_error $? "User supplied tool NAWK=$tool_specified does not exist or is not executable" "$LINENO" 5 10032 fi 10033 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 10034 $as_echo "$tool_specified" >&6; } 10035 fi 10036 fi 10037 fi 10038 10039 fi 10040 10041 10042 10043 if test "x$NAWK" = x; then 10044 as_fn_error $? "Could not find required tool for NAWK" "$LINENO" 5 10045 fi 10046 10047 10048 10049 10050 10051 # Publish this variable in the help. 10052 10053 10054 if [ -z "${PRINTF+x}" ]; then 10055 # The variable is not set by user, try to locate tool using the code snippet 10056 for ac_prog in printf 10057 do 10058 # Extract the first word of "$ac_prog", so it can be a program name with args. 10059 set dummy $ac_prog; ac_word=$2 10060 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10061 $as_echo_n "checking for $ac_word... " >&6; } 10062 if ${ac_cv_path_PRINTF+:} false; then : 10063 $as_echo_n "(cached) " >&6 10064 else 10065 case $PRINTF in 10066 [\\/]* | ?:[\\/]*) 10067 ac_cv_path_PRINTF="$PRINTF" # Let the user override the test with a path. 10068 ;; 10069 *) 10070 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10071 for as_dir in $PATH 10072 do 10073 IFS=$as_save_IFS 10074 test -z "$as_dir" && as_dir=. 10075 for ac_exec_ext in '' $ac_executable_extensions; do 10076 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10077 ac_cv_path_PRINTF="$as_dir/$ac_word$ac_exec_ext" 10078 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10079 break 2 10080 fi 10081 done 10082 done 10083 IFS=$as_save_IFS 10084 10085 ;; 10086 esac 10087 fi 10088 PRINTF=$ac_cv_path_PRINTF 10089 if test -n "$PRINTF"; then 10090 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRINTF" >&5 10091 $as_echo "$PRINTF" >&6; } 10092 else 10093 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10094 $as_echo "no" >&6; } 10095 fi 10096 10097 10098 test -n "$PRINTF" && break 10099 done 10100 10101 else 10102 # The variable is set, but is it from the command line or the environment? 10103 10104 # Try to remove the string !PRINTF! from our list. 10105 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!PRINTF!/} 10106 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 10107 # If it failed, the variable was not from the command line. Ignore it, 10108 # but warn the user (except for BASH, which is always set by the calling BASH). 10109 if test "xPRINTF" != xBASH; then 10110 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of PRINTF from the environment. Use command line variables instead." >&5 10111 $as_echo "$as_me: WARNING: Ignoring value of PRINTF from the environment. Use command line variables instead." >&2;} 10112 fi 10113 # Try to locate tool using the code snippet 10114 for ac_prog in printf 10115 do 10116 # Extract the first word of "$ac_prog", so it can be a program name with args. 10117 set dummy $ac_prog; ac_word=$2 10118 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10119 $as_echo_n "checking for $ac_word... " >&6; } 10120 if ${ac_cv_path_PRINTF+:} false; then : 10121 $as_echo_n "(cached) " >&6 10122 else 10123 case $PRINTF in 10124 [\\/]* | ?:[\\/]*) 10125 ac_cv_path_PRINTF="$PRINTF" # Let the user override the test with a path. 10126 ;; 10127 *) 10128 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10129 for as_dir in $PATH 10130 do 10131 IFS=$as_save_IFS 10132 test -z "$as_dir" && as_dir=. 10133 for ac_exec_ext in '' $ac_executable_extensions; do 10134 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10135 ac_cv_path_PRINTF="$as_dir/$ac_word$ac_exec_ext" 10136 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10137 break 2 10138 fi 10139 done 10140 done 10141 IFS=$as_save_IFS 10142 10143 ;; 10144 esac 10145 fi 10146 PRINTF=$ac_cv_path_PRINTF 10147 if test -n "$PRINTF"; then 10148 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRINTF" >&5 10149 $as_echo "$PRINTF" >&6; } 10150 else 10151 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10152 $as_echo "no" >&6; } 10153 fi 10154 10155 10156 test -n "$PRINTF" && break 10157 done 10158 10159 else 10160 # If it succeeded, then it was overridden by the user. We will use it 10161 # for the tool. 10162 10163 # First remove it from the list of overridden variables, so we can test 10164 # for unknown variables in the end. 10165 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 10166 10167 # Check if we try to supply an empty value 10168 if test "x$PRINTF" = x; then 10169 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool PRINTF= (no value)" >&5 10170 $as_echo "$as_me: Setting user supplied tool PRINTF= (no value)" >&6;} 10171 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PRINTF" >&5 10172 $as_echo_n "checking for PRINTF... " >&6; } 10173 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 10174 $as_echo "disabled" >&6; } 10175 else 10176 # Check if the provided tool contains a complete path. 10177 tool_specified="$PRINTF" 10178 tool_basename="${tool_specified##*/}" 10179 if test "x$tool_basename" = "x$tool_specified"; then 10180 # A command without a complete path is provided, search $PATH. 10181 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool PRINTF=$tool_basename" >&5 10182 $as_echo "$as_me: Will search for user supplied tool PRINTF=$tool_basename" >&6;} 10183 # Extract the first word of "$tool_basename", so it can be a program name with args. 10184 set dummy $tool_basename; ac_word=$2 10185 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10186 $as_echo_n "checking for $ac_word... " >&6; } 10187 if ${ac_cv_path_PRINTF+:} false; then : 10188 $as_echo_n "(cached) " >&6 10189 else 10190 case $PRINTF in 10191 [\\/]* | ?:[\\/]*) 10192 ac_cv_path_PRINTF="$PRINTF" # Let the user override the test with a path. 10193 ;; 10194 *) 10195 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10196 for as_dir in $PATH 10197 do 10198 IFS=$as_save_IFS 10199 test -z "$as_dir" && as_dir=. 10200 for ac_exec_ext in '' $ac_executable_extensions; do 10201 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10202 ac_cv_path_PRINTF="$as_dir/$ac_word$ac_exec_ext" 10203 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10204 break 2 10205 fi 10206 done 10207 done 10208 IFS=$as_save_IFS 10209 10210 ;; 10211 esac 10212 fi 10213 PRINTF=$ac_cv_path_PRINTF 10214 if test -n "$PRINTF"; then 10215 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRINTF" >&5 10216 $as_echo "$PRINTF" >&6; } 10217 else 10218 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10219 $as_echo "no" >&6; } 10220 fi 10221 10222 10223 if test "x$PRINTF" = x; then 10224 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 10225 fi 10226 else 10227 # Otherwise we believe it is a complete path. Use it as it is. 10228 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool PRINTF=$tool_specified" >&5 10229 $as_echo "$as_me: Will use user supplied tool PRINTF=$tool_specified" >&6;} 10230 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PRINTF" >&5 10231 $as_echo_n "checking for PRINTF... " >&6; } 10232 if test ! -x "$tool_specified"; then 10233 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 10234 $as_echo "not found" >&6; } 10235 as_fn_error $? "User supplied tool PRINTF=$tool_specified does not exist or is not executable" "$LINENO" 5 10236 fi 10237 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 10238 $as_echo "$tool_specified" >&6; } 10239 fi 10240 fi 10241 fi 10242 10243 fi 10244 10245 10246 10247 if test "x$PRINTF" = x; then 10248 as_fn_error $? "Could not find required tool for PRINTF" "$LINENO" 5 10249 fi 10250 10251 10252 10253 10254 10255 # Publish this variable in the help. 10256 10257 10258 if [ -z "${RM+x}" ]; then 10259 # The variable is not set by user, try to locate tool using the code snippet 10260 for ac_prog in rm 10261 do 10262 # Extract the first word of "$ac_prog", so it can be a program name with args. 10263 set dummy $ac_prog; ac_word=$2 10264 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10265 $as_echo_n "checking for $ac_word... " >&6; } 10266 if ${ac_cv_path_RM+:} false; then : 10267 $as_echo_n "(cached) " >&6 10268 else 10269 case $RM in 10270 [\\/]* | ?:[\\/]*) 10271 ac_cv_path_RM="$RM" # Let the user override the test with a path. 10272 ;; 10273 *) 10274 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10275 for as_dir in $PATH 10276 do 10277 IFS=$as_save_IFS 10278 test -z "$as_dir" && as_dir=. 10279 for ac_exec_ext in '' $ac_executable_extensions; do 10280 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10281 ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext" 10282 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10283 break 2 10284 fi 10285 done 10286 done 10287 IFS=$as_save_IFS 10288 10289 ;; 10290 esac 10291 fi 10292 RM=$ac_cv_path_RM 10293 if test -n "$RM"; then 10294 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RM" >&5 10295 $as_echo "$RM" >&6; } 10296 else 10297 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10298 $as_echo "no" >&6; } 10299 fi 10300 10301 10302 test -n "$RM" && break 10303 done 10304 10305 else 10306 # The variable is set, but is it from the command line or the environment? 10307 10308 # Try to remove the string !RM! from our list. 10309 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!RM!/} 10310 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 10311 # If it failed, the variable was not from the command line. Ignore it, 10312 # but warn the user (except for BASH, which is always set by the calling BASH). 10313 if test "xRM" != xBASH; then 10314 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of RM from the environment. Use command line variables instead." >&5 10315 $as_echo "$as_me: WARNING: Ignoring value of RM from the environment. Use command line variables instead." >&2;} 10316 fi 10317 # Try to locate tool using the code snippet 10318 for ac_prog in rm 10319 do 10320 # Extract the first word of "$ac_prog", so it can be a program name with args. 10321 set dummy $ac_prog; ac_word=$2 10322 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10323 $as_echo_n "checking for $ac_word... " >&6; } 10324 if ${ac_cv_path_RM+:} false; then : 10325 $as_echo_n "(cached) " >&6 10326 else 10327 case $RM in 10328 [\\/]* | ?:[\\/]*) 10329 ac_cv_path_RM="$RM" # Let the user override the test with a path. 10330 ;; 10331 *) 10332 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10333 for as_dir in $PATH 10334 do 10335 IFS=$as_save_IFS 10336 test -z "$as_dir" && as_dir=. 10337 for ac_exec_ext in '' $ac_executable_extensions; do 10338 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10339 ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext" 10340 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10341 break 2 10342 fi 10343 done 10344 done 10345 IFS=$as_save_IFS 10346 10347 ;; 10348 esac 10349 fi 10350 RM=$ac_cv_path_RM 10351 if test -n "$RM"; then 10352 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RM" >&5 10353 $as_echo "$RM" >&6; } 10354 else 10355 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10356 $as_echo "no" >&6; } 10357 fi 10358 10359 10360 test -n "$RM" && break 10361 done 10362 10363 else 10364 # If it succeeded, then it was overridden by the user. We will use it 10365 # for the tool. 10366 10367 # First remove it from the list of overridden variables, so we can test 10368 # for unknown variables in the end. 10369 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 10370 10371 # Check if we try to supply an empty value 10372 if test "x$RM" = x; then 10373 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool RM= (no value)" >&5 10374 $as_echo "$as_me: Setting user supplied tool RM= (no value)" >&6;} 10375 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RM" >&5 10376 $as_echo_n "checking for RM... " >&6; } 10377 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 10378 $as_echo "disabled" >&6; } 10379 else 10380 # Check if the provided tool contains a complete path. 10381 tool_specified="$RM" 10382 tool_basename="${tool_specified##*/}" 10383 if test "x$tool_basename" = "x$tool_specified"; then 10384 # A command without a complete path is provided, search $PATH. 10385 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool RM=$tool_basename" >&5 10386 $as_echo "$as_me: Will search for user supplied tool RM=$tool_basename" >&6;} 10387 # Extract the first word of "$tool_basename", so it can be a program name with args. 10388 set dummy $tool_basename; ac_word=$2 10389 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10390 $as_echo_n "checking for $ac_word... " >&6; } 10391 if ${ac_cv_path_RM+:} false; then : 10392 $as_echo_n "(cached) " >&6 10393 else 10394 case $RM in 10395 [\\/]* | ?:[\\/]*) 10396 ac_cv_path_RM="$RM" # Let the user override the test with a path. 10397 ;; 10398 *) 10399 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10400 for as_dir in $PATH 10401 do 10402 IFS=$as_save_IFS 10403 test -z "$as_dir" && as_dir=. 10404 for ac_exec_ext in '' $ac_executable_extensions; do 10405 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10406 ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext" 10407 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10408 break 2 10409 fi 10410 done 10411 done 10412 IFS=$as_save_IFS 10413 10414 ;; 10415 esac 10416 fi 10417 RM=$ac_cv_path_RM 10418 if test -n "$RM"; then 10419 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RM" >&5 10420 $as_echo "$RM" >&6; } 10421 else 10422 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10423 $as_echo "no" >&6; } 10424 fi 10425 10426 10427 if test "x$RM" = x; then 10428 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 10429 fi 10430 else 10431 # Otherwise we believe it is a complete path. Use it as it is. 10432 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool RM=$tool_specified" >&5 10433 $as_echo "$as_me: Will use user supplied tool RM=$tool_specified" >&6;} 10434 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RM" >&5 10435 $as_echo_n "checking for RM... " >&6; } 10436 if test ! -x "$tool_specified"; then 10437 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 10438 $as_echo "not found" >&6; } 10439 as_fn_error $? "User supplied tool RM=$tool_specified does not exist or is not executable" "$LINENO" 5 10440 fi 10441 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 10442 $as_echo "$tool_specified" >&6; } 10443 fi 10444 fi 10445 fi 10446 10447 fi 10448 10449 10450 10451 if test "x$RM" = x; then 10452 as_fn_error $? "Could not find required tool for RM" "$LINENO" 5 10453 fi 10454 10455 10456 10457 10458 10459 # Publish this variable in the help. 10460 10461 10462 if [ -z "${RMDIR+x}" ]; then 10463 # The variable is not set by user, try to locate tool using the code snippet 10464 for ac_prog in rmdir 10465 do 10466 # Extract the first word of "$ac_prog", so it can be a program name with args. 10467 set dummy $ac_prog; ac_word=$2 10468 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10469 $as_echo_n "checking for $ac_word... " >&6; } 10470 if ${ac_cv_path_RMDIR+:} false; then : 10471 $as_echo_n "(cached) " >&6 10472 else 10473 case $RMDIR in 10474 [\\/]* | ?:[\\/]*) 10475 ac_cv_path_RMDIR="$RMDIR" # Let the user override the test with a path. 10476 ;; 10477 *) 10478 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10479 for as_dir in $PATH 10480 do 10481 IFS=$as_save_IFS 10482 test -z "$as_dir" && as_dir=. 10483 for ac_exec_ext in '' $ac_executable_extensions; do 10484 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10485 ac_cv_path_RMDIR="$as_dir/$ac_word$ac_exec_ext" 10486 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10487 break 2 10488 fi 10489 done 10490 done 10491 IFS=$as_save_IFS 10492 10493 ;; 10494 esac 10495 fi 10496 RMDIR=$ac_cv_path_RMDIR 10497 if test -n "$RMDIR"; then 10498 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RMDIR" >&5 10499 $as_echo "$RMDIR" >&6; } 10500 else 10501 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10502 $as_echo "no" >&6; } 10503 fi 10504 10505 10506 test -n "$RMDIR" && break 10507 done 10508 10509 else 10510 # The variable is set, but is it from the command line or the environment? 10511 10512 # Try to remove the string !RMDIR! from our list. 10513 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!RMDIR!/} 10514 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 10515 # If it failed, the variable was not from the command line. Ignore it, 10516 # but warn the user (except for BASH, which is always set by the calling BASH). 10517 if test "xRMDIR" != xBASH; then 10518 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of RMDIR from the environment. Use command line variables instead." >&5 10519 $as_echo "$as_me: WARNING: Ignoring value of RMDIR from the environment. Use command line variables instead." >&2;} 10520 fi 10521 # Try to locate tool using the code snippet 10522 for ac_prog in rmdir 10523 do 10524 # Extract the first word of "$ac_prog", so it can be a program name with args. 10525 set dummy $ac_prog; ac_word=$2 10526 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10527 $as_echo_n "checking for $ac_word... " >&6; } 10528 if ${ac_cv_path_RMDIR+:} false; then : 10529 $as_echo_n "(cached) " >&6 10530 else 10531 case $RMDIR in 10532 [\\/]* | ?:[\\/]*) 10533 ac_cv_path_RMDIR="$RMDIR" # Let the user override the test with a path. 10534 ;; 10535 *) 10536 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10537 for as_dir in $PATH 10538 do 10539 IFS=$as_save_IFS 10540 test -z "$as_dir" && as_dir=. 10541 for ac_exec_ext in '' $ac_executable_extensions; do 10542 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10543 ac_cv_path_RMDIR="$as_dir/$ac_word$ac_exec_ext" 10544 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10545 break 2 10546 fi 10547 done 10548 done 10549 IFS=$as_save_IFS 10550 10551 ;; 10552 esac 10553 fi 10554 RMDIR=$ac_cv_path_RMDIR 10555 if test -n "$RMDIR"; then 10556 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RMDIR" >&5 10557 $as_echo "$RMDIR" >&6; } 10558 else 10559 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10560 $as_echo "no" >&6; } 10561 fi 10562 10563 10564 test -n "$RMDIR" && break 10565 done 10566 10567 else 10568 # If it succeeded, then it was overridden by the user. We will use it 10569 # for the tool. 10570 10571 # First remove it from the list of overridden variables, so we can test 10572 # for unknown variables in the end. 10573 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 10574 10575 # Check if we try to supply an empty value 10576 if test "x$RMDIR" = x; then 10577 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool RMDIR= (no value)" >&5 10578 $as_echo "$as_me: Setting user supplied tool RMDIR= (no value)" >&6;} 10579 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RMDIR" >&5 10580 $as_echo_n "checking for RMDIR... " >&6; } 10581 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 10582 $as_echo "disabled" >&6; } 10583 else 10584 # Check if the provided tool contains a complete path. 10585 tool_specified="$RMDIR" 10586 tool_basename="${tool_specified##*/}" 10587 if test "x$tool_basename" = "x$tool_specified"; then 10588 # A command without a complete path is provided, search $PATH. 10589 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool RMDIR=$tool_basename" >&5 10590 $as_echo "$as_me: Will search for user supplied tool RMDIR=$tool_basename" >&6;} 10591 # Extract the first word of "$tool_basename", so it can be a program name with args. 10592 set dummy $tool_basename; ac_word=$2 10593 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10594 $as_echo_n "checking for $ac_word... " >&6; } 10595 if ${ac_cv_path_RMDIR+:} false; then : 10596 $as_echo_n "(cached) " >&6 10597 else 10598 case $RMDIR in 10599 [\\/]* | ?:[\\/]*) 10600 ac_cv_path_RMDIR="$RMDIR" # Let the user override the test with a path. 10601 ;; 10602 *) 10603 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10604 for as_dir in $PATH 10605 do 10606 IFS=$as_save_IFS 10607 test -z "$as_dir" && as_dir=. 10608 for ac_exec_ext in '' $ac_executable_extensions; do 10609 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10610 ac_cv_path_RMDIR="$as_dir/$ac_word$ac_exec_ext" 10611 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10612 break 2 10613 fi 10614 done 10615 done 10616 IFS=$as_save_IFS 10617 10618 ;; 10619 esac 10620 fi 10621 RMDIR=$ac_cv_path_RMDIR 10622 if test -n "$RMDIR"; then 10623 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RMDIR" >&5 10624 $as_echo "$RMDIR" >&6; } 10625 else 10626 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10627 $as_echo "no" >&6; } 10628 fi 10629 10630 10631 if test "x$RMDIR" = x; then 10632 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 10633 fi 10634 else 10635 # Otherwise we believe it is a complete path. Use it as it is. 10636 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool RMDIR=$tool_specified" >&5 10637 $as_echo "$as_me: Will use user supplied tool RMDIR=$tool_specified" >&6;} 10638 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RMDIR" >&5 10639 $as_echo_n "checking for RMDIR... " >&6; } 10640 if test ! -x "$tool_specified"; then 10641 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 10642 $as_echo "not found" >&6; } 10643 as_fn_error $? "User supplied tool RMDIR=$tool_specified does not exist or is not executable" "$LINENO" 5 10644 fi 10645 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 10646 $as_echo "$tool_specified" >&6; } 10647 fi 10648 fi 10649 fi 10650 10651 fi 10652 10653 10654 10655 if test "x$RMDIR" = x; then 10656 as_fn_error $? "Could not find required tool for RMDIR" "$LINENO" 5 10657 fi 10658 10659 10660 10661 10662 10663 # Publish this variable in the help. 10664 10665 10666 if [ -z "${SH+x}" ]; then 10667 # The variable is not set by user, try to locate tool using the code snippet 10668 for ac_prog in sh 10669 do 10670 # Extract the first word of "$ac_prog", so it can be a program name with args. 10671 set dummy $ac_prog; ac_word=$2 10672 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10673 $as_echo_n "checking for $ac_word... " >&6; } 10674 if ${ac_cv_path_SH+:} false; then : 10675 $as_echo_n "(cached) " >&6 10676 else 10677 case $SH in 10678 [\\/]* | ?:[\\/]*) 10679 ac_cv_path_SH="$SH" # Let the user override the test with a path. 10680 ;; 10681 *) 10682 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10683 for as_dir in $PATH 10684 do 10685 IFS=$as_save_IFS 10686 test -z "$as_dir" && as_dir=. 10687 for ac_exec_ext in '' $ac_executable_extensions; do 10688 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10689 ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext" 10690 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10691 break 2 10692 fi 10693 done 10694 done 10695 IFS=$as_save_IFS 10696 10697 ;; 10698 esac 10699 fi 10700 SH=$ac_cv_path_SH 10701 if test -n "$SH"; then 10702 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5 10703 $as_echo "$SH" >&6; } 10704 else 10705 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10706 $as_echo "no" >&6; } 10707 fi 10708 10709 10710 test -n "$SH" && break 10711 done 10712 10713 else 10714 # The variable is set, but is it from the command line or the environment? 10715 10716 # Try to remove the string !SH! from our list. 10717 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SH!/} 10718 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 10719 # If it failed, the variable was not from the command line. Ignore it, 10720 # but warn the user (except for BASH, which is always set by the calling BASH). 10721 if test "xSH" != xBASH; then 10722 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SH from the environment. Use command line variables instead." >&5 10723 $as_echo "$as_me: WARNING: Ignoring value of SH from the environment. Use command line variables instead." >&2;} 10724 fi 10725 # Try to locate tool using the code snippet 10726 for ac_prog in sh 10727 do 10728 # Extract the first word of "$ac_prog", so it can be a program name with args. 10729 set dummy $ac_prog; ac_word=$2 10730 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10731 $as_echo_n "checking for $ac_word... " >&6; } 10732 if ${ac_cv_path_SH+:} false; then : 10733 $as_echo_n "(cached) " >&6 10734 else 10735 case $SH in 10736 [\\/]* | ?:[\\/]*) 10737 ac_cv_path_SH="$SH" # Let the user override the test with a path. 10738 ;; 10739 *) 10740 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10741 for as_dir in $PATH 10742 do 10743 IFS=$as_save_IFS 10744 test -z "$as_dir" && as_dir=. 10745 for ac_exec_ext in '' $ac_executable_extensions; do 10746 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10747 ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext" 10748 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10749 break 2 10750 fi 10751 done 10752 done 10753 IFS=$as_save_IFS 10754 10755 ;; 10756 esac 10757 fi 10758 SH=$ac_cv_path_SH 10759 if test -n "$SH"; then 10760 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5 10761 $as_echo "$SH" >&6; } 10762 else 10763 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10764 $as_echo "no" >&6; } 10765 fi 10766 10767 10768 test -n "$SH" && break 10769 done 10770 10771 else 10772 # If it succeeded, then it was overridden by the user. We will use it 10773 # for the tool. 10774 10775 # First remove it from the list of overridden variables, so we can test 10776 # for unknown variables in the end. 10777 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 10778 10779 # Check if we try to supply an empty value 10780 if test "x$SH" = x; then 10781 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool SH= (no value)" >&5 10782 $as_echo "$as_me: Setting user supplied tool SH= (no value)" >&6;} 10783 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SH" >&5 10784 $as_echo_n "checking for SH... " >&6; } 10785 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 10786 $as_echo "disabled" >&6; } 10787 else 10788 # Check if the provided tool contains a complete path. 10789 tool_specified="$SH" 10790 tool_basename="${tool_specified##*/}" 10791 if test "x$tool_basename" = "x$tool_specified"; then 10792 # A command without a complete path is provided, search $PATH. 10793 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SH=$tool_basename" >&5 10794 $as_echo "$as_me: Will search for user supplied tool SH=$tool_basename" >&6;} 10795 # Extract the first word of "$tool_basename", so it can be a program name with args. 10796 set dummy $tool_basename; ac_word=$2 10797 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10798 $as_echo_n "checking for $ac_word... " >&6; } 10799 if ${ac_cv_path_SH+:} false; then : 10800 $as_echo_n "(cached) " >&6 10801 else 10802 case $SH in 10803 [\\/]* | ?:[\\/]*) 10804 ac_cv_path_SH="$SH" # Let the user override the test with a path. 10805 ;; 10806 *) 10807 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10808 for as_dir in $PATH 10809 do 10810 IFS=$as_save_IFS 10811 test -z "$as_dir" && as_dir=. 10812 for ac_exec_ext in '' $ac_executable_extensions; do 10813 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10814 ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext" 10815 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10816 break 2 10817 fi 10818 done 10819 done 10820 IFS=$as_save_IFS 10821 10822 ;; 10823 esac 10824 fi 10825 SH=$ac_cv_path_SH 10826 if test -n "$SH"; then 10827 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5 10828 $as_echo "$SH" >&6; } 10829 else 10830 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10831 $as_echo "no" >&6; } 10832 fi 10833 10834 10835 if test "x$SH" = x; then 10836 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 10837 fi 10838 else 10839 # Otherwise we believe it is a complete path. Use it as it is. 10840 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SH=$tool_specified" >&5 10841 $as_echo "$as_me: Will use user supplied tool SH=$tool_specified" >&6;} 10842 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SH" >&5 10843 $as_echo_n "checking for SH... " >&6; } 10844 if test ! -x "$tool_specified"; then 10845 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 10846 $as_echo "not found" >&6; } 10847 as_fn_error $? "User supplied tool SH=$tool_specified does not exist or is not executable" "$LINENO" 5 10848 fi 10849 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 10850 $as_echo "$tool_specified" >&6; } 10851 fi 10852 fi 10853 fi 10854 10855 fi 10856 10857 10858 10859 if test "x$SH" = x; then 10860 as_fn_error $? "Could not find required tool for SH" "$LINENO" 5 10861 fi 10862 10863 10864 10865 10866 10867 # Publish this variable in the help. 10868 10869 10870 if [ -z "${SORT+x}" ]; then 10871 # The variable is not set by user, try to locate tool using the code snippet 10872 for ac_prog in sort 10873 do 10874 # Extract the first word of "$ac_prog", so it can be a program name with args. 10875 set dummy $ac_prog; ac_word=$2 10876 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10877 $as_echo_n "checking for $ac_word... " >&6; } 10878 if ${ac_cv_path_SORT+:} false; then : 10879 $as_echo_n "(cached) " >&6 10880 else 10881 case $SORT in 10882 [\\/]* | ?:[\\/]*) 10883 ac_cv_path_SORT="$SORT" # Let the user override the test with a path. 10884 ;; 10885 *) 10886 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10887 for as_dir in $PATH 10888 do 10889 IFS=$as_save_IFS 10890 test -z "$as_dir" && as_dir=. 10891 for ac_exec_ext in '' $ac_executable_extensions; do 10892 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10893 ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext" 10894 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10895 break 2 10896 fi 10897 done 10898 done 10899 IFS=$as_save_IFS 10900 10901 ;; 10902 esac 10903 fi 10904 SORT=$ac_cv_path_SORT 10905 if test -n "$SORT"; then 10906 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5 10907 $as_echo "$SORT" >&6; } 10908 else 10909 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10910 $as_echo "no" >&6; } 10911 fi 10912 10913 10914 test -n "$SORT" && break 10915 done 10916 10917 else 10918 # The variable is set, but is it from the command line or the environment? 10919 10920 # Try to remove the string !SORT! from our list. 10921 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SORT!/} 10922 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 10923 # If it failed, the variable was not from the command line. Ignore it, 10924 # but warn the user (except for BASH, which is always set by the calling BASH). 10925 if test "xSORT" != xBASH; then 10926 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SORT from the environment. Use command line variables instead." >&5 10927 $as_echo "$as_me: WARNING: Ignoring value of SORT from the environment. Use command line variables instead." >&2;} 10928 fi 10929 # Try to locate tool using the code snippet 10930 for ac_prog in sort 10931 do 10932 # Extract the first word of "$ac_prog", so it can be a program name with args. 10933 set dummy $ac_prog; ac_word=$2 10934 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10935 $as_echo_n "checking for $ac_word... " >&6; } 10936 if ${ac_cv_path_SORT+:} false; then : 10937 $as_echo_n "(cached) " >&6 10938 else 10939 case $SORT in 10940 [\\/]* | ?:[\\/]*) 10941 ac_cv_path_SORT="$SORT" # Let the user override the test with a path. 10942 ;; 10943 *) 10944 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10945 for as_dir in $PATH 10946 do 10947 IFS=$as_save_IFS 10948 test -z "$as_dir" && as_dir=. 10949 for ac_exec_ext in '' $ac_executable_extensions; do 10950 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10951 ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext" 10952 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10953 break 2 10954 fi 10955 done 10956 done 10957 IFS=$as_save_IFS 10958 10959 ;; 10960 esac 10961 fi 10962 SORT=$ac_cv_path_SORT 10963 if test -n "$SORT"; then 10964 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5 10965 $as_echo "$SORT" >&6; } 10966 else 10967 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10968 $as_echo "no" >&6; } 10969 fi 10970 10971 10972 test -n "$SORT" && break 10973 done 10974 10975 else 10976 # If it succeeded, then it was overridden by the user. We will use it 10977 # for the tool. 10978 10979 # First remove it from the list of overridden variables, so we can test 10980 # for unknown variables in the end. 10981 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 10982 10983 # Check if we try to supply an empty value 10984 if test "x$SORT" = x; then 10985 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool SORT= (no value)" >&5 10986 $as_echo "$as_me: Setting user supplied tool SORT= (no value)" >&6;} 10987 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SORT" >&5 10988 $as_echo_n "checking for SORT... " >&6; } 10989 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 10990 $as_echo "disabled" >&6; } 10991 else 10992 # Check if the provided tool contains a complete path. 10993 tool_specified="$SORT" 10994 tool_basename="${tool_specified##*/}" 10995 if test "x$tool_basename" = "x$tool_specified"; then 10996 # A command without a complete path is provided, search $PATH. 10997 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SORT=$tool_basename" >&5 10998 $as_echo "$as_me: Will search for user supplied tool SORT=$tool_basename" >&6;} 10999 # Extract the first word of "$tool_basename", so it can be a program name with args. 11000 set dummy $tool_basename; ac_word=$2 11001 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11002 $as_echo_n "checking for $ac_word... " >&6; } 11003 if ${ac_cv_path_SORT+:} false; then : 11004 $as_echo_n "(cached) " >&6 11005 else 11006 case $SORT in 11007 [\\/]* | ?:[\\/]*) 11008 ac_cv_path_SORT="$SORT" # Let the user override the test with a path. 11009 ;; 11010 *) 11011 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11012 for as_dir in $PATH 11013 do 11014 IFS=$as_save_IFS 11015 test -z "$as_dir" && as_dir=. 11016 for ac_exec_ext in '' $ac_executable_extensions; do 11017 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11018 ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext" 11019 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11020 break 2 11021 fi 11022 done 11023 done 11024 IFS=$as_save_IFS 11025 11026 ;; 11027 esac 11028 fi 11029 SORT=$ac_cv_path_SORT 11030 if test -n "$SORT"; then 11031 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5 11032 $as_echo "$SORT" >&6; } 11033 else 11034 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11035 $as_echo "no" >&6; } 11036 fi 11037 11038 11039 if test "x$SORT" = x; then 11040 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 11041 fi 11042 else 11043 # Otherwise we believe it is a complete path. Use it as it is. 11044 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SORT=$tool_specified" >&5 11045 $as_echo "$as_me: Will use user supplied tool SORT=$tool_specified" >&6;} 11046 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SORT" >&5 11047 $as_echo_n "checking for SORT... " >&6; } 11048 if test ! -x "$tool_specified"; then 11049 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 11050 $as_echo "not found" >&6; } 11051 as_fn_error $? "User supplied tool SORT=$tool_specified does not exist or is not executable" "$LINENO" 5 11052 fi 11053 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 11054 $as_echo "$tool_specified" >&6; } 11055 fi 11056 fi 11057 fi 11058 11059 fi 11060 11061 11062 11063 if test "x$SORT" = x; then 11064 as_fn_error $? "Could not find required tool for SORT" "$LINENO" 5 11065 fi 11066 11067 11068 11069 11070 11071 # Publish this variable in the help. 11072 11073 11074 if [ -z "${TAIL+x}" ]; then 11075 # The variable is not set by user, try to locate tool using the code snippet 11076 for ac_prog in tail 11077 do 11078 # Extract the first word of "$ac_prog", so it can be a program name with args. 11079 set dummy $ac_prog; ac_word=$2 11080 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11081 $as_echo_n "checking for $ac_word... " >&6; } 11082 if ${ac_cv_path_TAIL+:} false; then : 11083 $as_echo_n "(cached) " >&6 11084 else 11085 case $TAIL in 11086 [\\/]* | ?:[\\/]*) 11087 ac_cv_path_TAIL="$TAIL" # Let the user override the test with a path. 11088 ;; 11089 *) 11090 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11091 for as_dir in $PATH 11092 do 11093 IFS=$as_save_IFS 11094 test -z "$as_dir" && as_dir=. 11095 for ac_exec_ext in '' $ac_executable_extensions; do 11096 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11097 ac_cv_path_TAIL="$as_dir/$ac_word$ac_exec_ext" 11098 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11099 break 2 11100 fi 11101 done 11102 done 11103 IFS=$as_save_IFS 11104 11105 ;; 11106 esac 11107 fi 11108 TAIL=$ac_cv_path_TAIL 11109 if test -n "$TAIL"; then 11110 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAIL" >&5 11111 $as_echo "$TAIL" >&6; } 11112 else 11113 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11114 $as_echo "no" >&6; } 11115 fi 11116 11117 11118 test -n "$TAIL" && break 11119 done 11120 11121 else 11122 # The variable is set, but is it from the command line or the environment? 11123 11124 # Try to remove the string !TAIL! from our list. 11125 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TAIL!/} 11126 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 11127 # If it failed, the variable was not from the command line. Ignore it, 11128 # but warn the user (except for BASH, which is always set by the calling BASH). 11129 if test "xTAIL" != xBASH; then 11130 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TAIL from the environment. Use command line variables instead." >&5 11131 $as_echo "$as_me: WARNING: Ignoring value of TAIL from the environment. Use command line variables instead." >&2;} 11132 fi 11133 # Try to locate tool using the code snippet 11134 for ac_prog in tail 11135 do 11136 # Extract the first word of "$ac_prog", so it can be a program name with args. 11137 set dummy $ac_prog; ac_word=$2 11138 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11139 $as_echo_n "checking for $ac_word... " >&6; } 11140 if ${ac_cv_path_TAIL+:} false; then : 11141 $as_echo_n "(cached) " >&6 11142 else 11143 case $TAIL in 11144 [\\/]* | ?:[\\/]*) 11145 ac_cv_path_TAIL="$TAIL" # Let the user override the test with a path. 11146 ;; 11147 *) 11148 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11149 for as_dir in $PATH 11150 do 11151 IFS=$as_save_IFS 11152 test -z "$as_dir" && as_dir=. 11153 for ac_exec_ext in '' $ac_executable_extensions; do 11154 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11155 ac_cv_path_TAIL="$as_dir/$ac_word$ac_exec_ext" 11156 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11157 break 2 11158 fi 11159 done 11160 done 11161 IFS=$as_save_IFS 11162 11163 ;; 11164 esac 11165 fi 11166 TAIL=$ac_cv_path_TAIL 11167 if test -n "$TAIL"; then 11168 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAIL" >&5 11169 $as_echo "$TAIL" >&6; } 11170 else 11171 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11172 $as_echo "no" >&6; } 11173 fi 11174 11175 11176 test -n "$TAIL" && break 11177 done 11178 11179 else 11180 # If it succeeded, then it was overridden by the user. We will use it 11181 # for the tool. 11182 11183 # First remove it from the list of overridden variables, so we can test 11184 # for unknown variables in the end. 11185 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 11186 11187 # Check if we try to supply an empty value 11188 if test "x$TAIL" = x; then 11189 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TAIL= (no value)" >&5 11190 $as_echo "$as_me: Setting user supplied tool TAIL= (no value)" >&6;} 11191 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAIL" >&5 11192 $as_echo_n "checking for TAIL... " >&6; } 11193 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 11194 $as_echo "disabled" >&6; } 11195 else 11196 # Check if the provided tool contains a complete path. 11197 tool_specified="$TAIL" 11198 tool_basename="${tool_specified##*/}" 11199 if test "x$tool_basename" = "x$tool_specified"; then 11200 # A command without a complete path is provided, search $PATH. 11201 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TAIL=$tool_basename" >&5 11202 $as_echo "$as_me: Will search for user supplied tool TAIL=$tool_basename" >&6;} 11203 # Extract the first word of "$tool_basename", so it can be a program name with args. 11204 set dummy $tool_basename; ac_word=$2 11205 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11206 $as_echo_n "checking for $ac_word... " >&6; } 11207 if ${ac_cv_path_TAIL+:} false; then : 11208 $as_echo_n "(cached) " >&6 11209 else 11210 case $TAIL in 11211 [\\/]* | ?:[\\/]*) 11212 ac_cv_path_TAIL="$TAIL" # Let the user override the test with a path. 11213 ;; 11214 *) 11215 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11216 for as_dir in $PATH 11217 do 11218 IFS=$as_save_IFS 11219 test -z "$as_dir" && as_dir=. 11220 for ac_exec_ext in '' $ac_executable_extensions; do 11221 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11222 ac_cv_path_TAIL="$as_dir/$ac_word$ac_exec_ext" 11223 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11224 break 2 11225 fi 11226 done 11227 done 11228 IFS=$as_save_IFS 11229 11230 ;; 11231 esac 11232 fi 11233 TAIL=$ac_cv_path_TAIL 11234 if test -n "$TAIL"; then 11235 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAIL" >&5 11236 $as_echo "$TAIL" >&6; } 11237 else 11238 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11239 $as_echo "no" >&6; } 11240 fi 11241 11242 11243 if test "x$TAIL" = x; then 11244 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 11245 fi 11246 else 11247 # Otherwise we believe it is a complete path. Use it as it is. 11248 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TAIL=$tool_specified" >&5 11249 $as_echo "$as_me: Will use user supplied tool TAIL=$tool_specified" >&6;} 11250 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAIL" >&5 11251 $as_echo_n "checking for TAIL... " >&6; } 11252 if test ! -x "$tool_specified"; then 11253 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 11254 $as_echo "not found" >&6; } 11255 as_fn_error $? "User supplied tool TAIL=$tool_specified does not exist or is not executable" "$LINENO" 5 11256 fi 11257 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 11258 $as_echo "$tool_specified" >&6; } 11259 fi 11260 fi 11261 fi 11262 11263 fi 11264 11265 11266 11267 if test "x$TAIL" = x; then 11268 as_fn_error $? "Could not find required tool for TAIL" "$LINENO" 5 11269 fi 11270 11271 11272 11273 11274 11275 # Publish this variable in the help. 11276 11277 11278 if [ -z "${TAR+x}" ]; then 11279 # The variable is not set by user, try to locate tool using the code snippet 11280 for ac_prog in gtar tar 11281 do 11282 # Extract the first word of "$ac_prog", so it can be a program name with args. 11283 set dummy $ac_prog; ac_word=$2 11284 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11285 $as_echo_n "checking for $ac_word... " >&6; } 11286 if ${ac_cv_path_TAR+:} false; then : 11287 $as_echo_n "(cached) " >&6 11288 else 11289 case $TAR in 11290 [\\/]* | ?:[\\/]*) 11291 ac_cv_path_TAR="$TAR" # Let the user override the test with a path. 11292 ;; 11293 *) 11294 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11295 for as_dir in $PATH 11296 do 11297 IFS=$as_save_IFS 11298 test -z "$as_dir" && as_dir=. 11299 for ac_exec_ext in '' $ac_executable_extensions; do 11300 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11301 ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext" 11302 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11303 break 2 11304 fi 11305 done 11306 done 11307 IFS=$as_save_IFS 11308 11309 ;; 11310 esac 11311 fi 11312 TAR=$ac_cv_path_TAR 11313 if test -n "$TAR"; then 11314 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5 11315 $as_echo "$TAR" >&6; } 11316 else 11317 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11318 $as_echo "no" >&6; } 11319 fi 11320 11321 11322 test -n "$TAR" && break 11323 done 11324 11325 else 11326 # The variable is set, but is it from the command line or the environment? 11327 11328 # Try to remove the string !TAR! from our list. 11329 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TAR!/} 11330 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 11331 # If it failed, the variable was not from the command line. Ignore it, 11332 # but warn the user (except for BASH, which is always set by the calling BASH). 11333 if test "xTAR" != xBASH; then 11334 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TAR from the environment. Use command line variables instead." >&5 11335 $as_echo "$as_me: WARNING: Ignoring value of TAR from the environment. Use command line variables instead." >&2;} 11336 fi 11337 # Try to locate tool using the code snippet 11338 for ac_prog in gtar tar 11339 do 11340 # Extract the first word of "$ac_prog", so it can be a program name with args. 11341 set dummy $ac_prog; ac_word=$2 11342 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11343 $as_echo_n "checking for $ac_word... " >&6; } 11344 if ${ac_cv_path_TAR+:} false; then : 11345 $as_echo_n "(cached) " >&6 11346 else 11347 case $TAR in 11348 [\\/]* | ?:[\\/]*) 11349 ac_cv_path_TAR="$TAR" # Let the user override the test with a path. 11350 ;; 11351 *) 11352 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11353 for as_dir in $PATH 11354 do 11355 IFS=$as_save_IFS 11356 test -z "$as_dir" && as_dir=. 11357 for ac_exec_ext in '' $ac_executable_extensions; do 11358 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11359 ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext" 11360 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11361 break 2 11362 fi 11363 done 11364 done 11365 IFS=$as_save_IFS 11366 11367 ;; 11368 esac 11369 fi 11370 TAR=$ac_cv_path_TAR 11371 if test -n "$TAR"; then 11372 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5 11373 $as_echo "$TAR" >&6; } 11374 else 11375 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11376 $as_echo "no" >&6; } 11377 fi 11378 11379 11380 test -n "$TAR" && break 11381 done 11382 11383 else 11384 # If it succeeded, then it was overridden by the user. We will use it 11385 # for the tool. 11386 11387 # First remove it from the list of overridden variables, so we can test 11388 # for unknown variables in the end. 11389 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 11390 11391 # Check if we try to supply an empty value 11392 if test "x$TAR" = x; then 11393 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TAR= (no value)" >&5 11394 $as_echo "$as_me: Setting user supplied tool TAR= (no value)" >&6;} 11395 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAR" >&5 11396 $as_echo_n "checking for TAR... " >&6; } 11397 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 11398 $as_echo "disabled" >&6; } 11399 else 11400 # Check if the provided tool contains a complete path. 11401 tool_specified="$TAR" 11402 tool_basename="${tool_specified##*/}" 11403 if test "x$tool_basename" = "x$tool_specified"; then 11404 # A command without a complete path is provided, search $PATH. 11405 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TAR=$tool_basename" >&5 11406 $as_echo "$as_me: Will search for user supplied tool TAR=$tool_basename" >&6;} 11407 # Extract the first word of "$tool_basename", so it can be a program name with args. 11408 set dummy $tool_basename; ac_word=$2 11409 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11410 $as_echo_n "checking for $ac_word... " >&6; } 11411 if ${ac_cv_path_TAR+:} false; then : 11412 $as_echo_n "(cached) " >&6 11413 else 11414 case $TAR in 11415 [\\/]* | ?:[\\/]*) 11416 ac_cv_path_TAR="$TAR" # Let the user override the test with a path. 11417 ;; 11418 *) 11419 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11420 for as_dir in $PATH 11421 do 11422 IFS=$as_save_IFS 11423 test -z "$as_dir" && as_dir=. 11424 for ac_exec_ext in '' $ac_executable_extensions; do 11425 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11426 ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext" 11427 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11428 break 2 11429 fi 11430 done 11431 done 11432 IFS=$as_save_IFS 11433 11434 ;; 11435 esac 11436 fi 11437 TAR=$ac_cv_path_TAR 11438 if test -n "$TAR"; then 11439 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5 11440 $as_echo "$TAR" >&6; } 11441 else 11442 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11443 $as_echo "no" >&6; } 11444 fi 11445 11446 11447 if test "x$TAR" = x; then 11448 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 11449 fi 11450 else 11451 # Otherwise we believe it is a complete path. Use it as it is. 11452 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TAR=$tool_specified" >&5 11453 $as_echo "$as_me: Will use user supplied tool TAR=$tool_specified" >&6;} 11454 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAR" >&5 11455 $as_echo_n "checking for TAR... " >&6; } 11456 if test ! -x "$tool_specified"; then 11457 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 11458 $as_echo "not found" >&6; } 11459 as_fn_error $? "User supplied tool TAR=$tool_specified does not exist or is not executable" "$LINENO" 5 11460 fi 11461 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 11462 $as_echo "$tool_specified" >&6; } 11463 fi 11464 fi 11465 fi 11466 11467 fi 11468 11469 11470 11471 if test "x$TAR" = x; then 11472 as_fn_error $? "Could not find required tool for TAR" "$LINENO" 5 11473 fi 11474 11475 11476 11477 11478 11479 # Publish this variable in the help. 11480 11481 11482 if [ -z "${TEE+x}" ]; then 11483 # The variable is not set by user, try to locate tool using the code snippet 11484 for ac_prog in tee 11485 do 11486 # Extract the first word of "$ac_prog", so it can be a program name with args. 11487 set dummy $ac_prog; ac_word=$2 11488 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11489 $as_echo_n "checking for $ac_word... " >&6; } 11490 if ${ac_cv_path_TEE+:} false; then : 11491 $as_echo_n "(cached) " >&6 11492 else 11493 case $TEE in 11494 [\\/]* | ?:[\\/]*) 11495 ac_cv_path_TEE="$TEE" # Let the user override the test with a path. 11496 ;; 11497 *) 11498 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11499 for as_dir in $PATH 11500 do 11501 IFS=$as_save_IFS 11502 test -z "$as_dir" && as_dir=. 11503 for ac_exec_ext in '' $ac_executable_extensions; do 11504 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11505 ac_cv_path_TEE="$as_dir/$ac_word$ac_exec_ext" 11506 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11507 break 2 11508 fi 11509 done 11510 done 11511 IFS=$as_save_IFS 11512 11513 ;; 11514 esac 11515 fi 11516 TEE=$ac_cv_path_TEE 11517 if test -n "$TEE"; then 11518 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5 11519 $as_echo "$TEE" >&6; } 11520 else 11521 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11522 $as_echo "no" >&6; } 11523 fi 11524 11525 11526 test -n "$TEE" && break 11527 done 11528 11529 else 11530 # The variable is set, but is it from the command line or the environment? 11531 11532 # Try to remove the string !TEE! from our list. 11533 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TEE!/} 11534 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 11535 # If it failed, the variable was not from the command line. Ignore it, 11536 # but warn the user (except for BASH, which is always set by the calling BASH). 11537 if test "xTEE" != xBASH; then 11538 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TEE from the environment. Use command line variables instead." >&5 11539 $as_echo "$as_me: WARNING: Ignoring value of TEE from the environment. Use command line variables instead." >&2;} 11540 fi 11541 # Try to locate tool using the code snippet 11542 for ac_prog in tee 11543 do 11544 # Extract the first word of "$ac_prog", so it can be a program name with args. 11545 set dummy $ac_prog; ac_word=$2 11546 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11547 $as_echo_n "checking for $ac_word... " >&6; } 11548 if ${ac_cv_path_TEE+:} false; then : 11549 $as_echo_n "(cached) " >&6 11550 else 11551 case $TEE in 11552 [\\/]* | ?:[\\/]*) 11553 ac_cv_path_TEE="$TEE" # Let the user override the test with a path. 11554 ;; 11555 *) 11556 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11557 for as_dir in $PATH 11558 do 11559 IFS=$as_save_IFS 11560 test -z "$as_dir" && as_dir=. 11561 for ac_exec_ext in '' $ac_executable_extensions; do 11562 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11563 ac_cv_path_TEE="$as_dir/$ac_word$ac_exec_ext" 11564 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11565 break 2 11566 fi 11567 done 11568 done 11569 IFS=$as_save_IFS 11570 11571 ;; 11572 esac 11573 fi 11574 TEE=$ac_cv_path_TEE 11575 if test -n "$TEE"; then 11576 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5 11577 $as_echo "$TEE" >&6; } 11578 else 11579 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11580 $as_echo "no" >&6; } 11581 fi 11582 11583 11584 test -n "$TEE" && break 11585 done 11586 11587 else 11588 # If it succeeded, then it was overridden by the user. We will use it 11589 # for the tool. 11590 11591 # First remove it from the list of overridden variables, so we can test 11592 # for unknown variables in the end. 11593 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 11594 11595 # Check if we try to supply an empty value 11596 if test "x$TEE" = x; then 11597 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TEE= (no value)" >&5 11598 $as_echo "$as_me: Setting user supplied tool TEE= (no value)" >&6;} 11599 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TEE" >&5 11600 $as_echo_n "checking for TEE... " >&6; } 11601 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 11602 $as_echo "disabled" >&6; } 11603 else 11604 # Check if the provided tool contains a complete path. 11605 tool_specified="$TEE" 11606 tool_basename="${tool_specified##*/}" 11607 if test "x$tool_basename" = "x$tool_specified"; then 11608 # A command without a complete path is provided, search $PATH. 11609 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TEE=$tool_basename" >&5 11610 $as_echo "$as_me: Will search for user supplied tool TEE=$tool_basename" >&6;} 11611 # Extract the first word of "$tool_basename", so it can be a program name with args. 11612 set dummy $tool_basename; ac_word=$2 11613 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11614 $as_echo_n "checking for $ac_word... " >&6; } 11615 if ${ac_cv_path_TEE+:} false; then : 11616 $as_echo_n "(cached) " >&6 11617 else 11618 case $TEE in 11619 [\\/]* | ?:[\\/]*) 11620 ac_cv_path_TEE="$TEE" # Let the user override the test with a path. 11621 ;; 11622 *) 11623 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11624 for as_dir in $PATH 11625 do 11626 IFS=$as_save_IFS 11627 test -z "$as_dir" && as_dir=. 11628 for ac_exec_ext in '' $ac_executable_extensions; do 11629 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11630 ac_cv_path_TEE="$as_dir/$ac_word$ac_exec_ext" 11631 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11632 break 2 11633 fi 11634 done 11635 done 11636 IFS=$as_save_IFS 11637 11638 ;; 11639 esac 11640 fi 11641 TEE=$ac_cv_path_TEE 11642 if test -n "$TEE"; then 11643 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5 11644 $as_echo "$TEE" >&6; } 11645 else 11646 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11647 $as_echo "no" >&6; } 11648 fi 11649 11650 11651 if test "x$TEE" = x; then 11652 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 11653 fi 11654 else 11655 # Otherwise we believe it is a complete path. Use it as it is. 11656 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TEE=$tool_specified" >&5 11657 $as_echo "$as_me: Will use user supplied tool TEE=$tool_specified" >&6;} 11658 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TEE" >&5 11659 $as_echo_n "checking for TEE... " >&6; } 11660 if test ! -x "$tool_specified"; then 11661 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 11662 $as_echo "not found" >&6; } 11663 as_fn_error $? "User supplied tool TEE=$tool_specified does not exist or is not executable" "$LINENO" 5 11664 fi 11665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 11666 $as_echo "$tool_specified" >&6; } 11667 fi 11668 fi 11669 fi 11670 11671 fi 11672 11673 11674 11675 if test "x$TEE" = x; then 11676 as_fn_error $? "Could not find required tool for TEE" "$LINENO" 5 11677 fi 11678 11679 11680 11681 11682 11683 # Publish this variable in the help. 11684 11685 11686 if [ -z "${TOUCH+x}" ]; then 11687 # The variable is not set by user, try to locate tool using the code snippet 11688 for ac_prog in touch 11689 do 11690 # Extract the first word of "$ac_prog", so it can be a program name with args. 11691 set dummy $ac_prog; ac_word=$2 11692 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11693 $as_echo_n "checking for $ac_word... " >&6; } 11694 if ${ac_cv_path_TOUCH+:} false; then : 11695 $as_echo_n "(cached) " >&6 11696 else 11697 case $TOUCH in 11698 [\\/]* | ?:[\\/]*) 11699 ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path. 11700 ;; 11701 *) 11702 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11703 for as_dir in $PATH 11704 do 11705 IFS=$as_save_IFS 11706 test -z "$as_dir" && as_dir=. 11707 for ac_exec_ext in '' $ac_executable_extensions; do 11708 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11709 ac_cv_path_TOUCH="$as_dir/$ac_word$ac_exec_ext" 11710 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11711 break 2 11712 fi 11713 done 11714 done 11715 IFS=$as_save_IFS 11716 11717 ;; 11718 esac 11719 fi 11720 TOUCH=$ac_cv_path_TOUCH 11721 if test -n "$TOUCH"; then 11722 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOUCH" >&5 11723 $as_echo "$TOUCH" >&6; } 11724 else 11725 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11726 $as_echo "no" >&6; } 11727 fi 11728 11729 11730 test -n "$TOUCH" && break 11731 done 11732 11733 else 11734 # The variable is set, but is it from the command line or the environment? 11735 11736 # Try to remove the string !TOUCH! from our list. 11737 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TOUCH!/} 11738 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 11739 # If it failed, the variable was not from the command line. Ignore it, 11740 # but warn the user (except for BASH, which is always set by the calling BASH). 11741 if test "xTOUCH" != xBASH; then 11742 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TOUCH from the environment. Use command line variables instead." >&5 11743 $as_echo "$as_me: WARNING: Ignoring value of TOUCH from the environment. Use command line variables instead." >&2;} 11744 fi 11745 # Try to locate tool using the code snippet 11746 for ac_prog in touch 11747 do 11748 # Extract the first word of "$ac_prog", so it can be a program name with args. 11749 set dummy $ac_prog; ac_word=$2 11750 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11751 $as_echo_n "checking for $ac_word... " >&6; } 11752 if ${ac_cv_path_TOUCH+:} false; then : 11753 $as_echo_n "(cached) " >&6 11754 else 11755 case $TOUCH in 11756 [\\/]* | ?:[\\/]*) 11757 ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path. 11758 ;; 11759 *) 11760 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11761 for as_dir in $PATH 11762 do 11763 IFS=$as_save_IFS 11764 test -z "$as_dir" && as_dir=. 11765 for ac_exec_ext in '' $ac_executable_extensions; do 11766 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11767 ac_cv_path_TOUCH="$as_dir/$ac_word$ac_exec_ext" 11768 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11769 break 2 11770 fi 11771 done 11772 done 11773 IFS=$as_save_IFS 11774 11775 ;; 11776 esac 11777 fi 11778 TOUCH=$ac_cv_path_TOUCH 11779 if test -n "$TOUCH"; then 11780 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOUCH" >&5 11781 $as_echo "$TOUCH" >&6; } 11782 else 11783 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11784 $as_echo "no" >&6; } 11785 fi 11786 11787 11788 test -n "$TOUCH" && break 11789 done 11790 11791 else 11792 # If it succeeded, then it was overridden by the user. We will use it 11793 # for the tool. 11794 11795 # First remove it from the list of overridden variables, so we can test 11796 # for unknown variables in the end. 11797 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 11798 11799 # Check if we try to supply an empty value 11800 if test "x$TOUCH" = x; then 11801 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TOUCH= (no value)" >&5 11802 $as_echo "$as_me: Setting user supplied tool TOUCH= (no value)" >&6;} 11803 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TOUCH" >&5 11804 $as_echo_n "checking for TOUCH... " >&6; } 11805 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 11806 $as_echo "disabled" >&6; } 11807 else 11808 # Check if the provided tool contains a complete path. 11809 tool_specified="$TOUCH" 11810 tool_basename="${tool_specified##*/}" 11811 if test "x$tool_basename" = "x$tool_specified"; then 11812 # A command without a complete path is provided, search $PATH. 11813 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TOUCH=$tool_basename" >&5 11814 $as_echo "$as_me: Will search for user supplied tool TOUCH=$tool_basename" >&6;} 11815 # Extract the first word of "$tool_basename", so it can be a program name with args. 11816 set dummy $tool_basename; ac_word=$2 11817 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11818 $as_echo_n "checking for $ac_word... " >&6; } 11819 if ${ac_cv_path_TOUCH+:} false; then : 11820 $as_echo_n "(cached) " >&6 11821 else 11822 case $TOUCH in 11823 [\\/]* | ?:[\\/]*) 11824 ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path. 11825 ;; 11826 *) 11827 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11828 for as_dir in $PATH 11829 do 11830 IFS=$as_save_IFS 11831 test -z "$as_dir" && as_dir=. 11832 for ac_exec_ext in '' $ac_executable_extensions; do 11833 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11834 ac_cv_path_TOUCH="$as_dir/$ac_word$ac_exec_ext" 11835 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11836 break 2 11837 fi 11838 done 11839 done 11840 IFS=$as_save_IFS 11841 11842 ;; 11843 esac 11844 fi 11845 TOUCH=$ac_cv_path_TOUCH 11846 if test -n "$TOUCH"; then 11847 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOUCH" >&5 11848 $as_echo "$TOUCH" >&6; } 11849 else 11850 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11851 $as_echo "no" >&6; } 11852 fi 11853 11854 11855 if test "x$TOUCH" = x; then 11856 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 11857 fi 11858 else 11859 # Otherwise we believe it is a complete path. Use it as it is. 11860 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TOUCH=$tool_specified" >&5 11861 $as_echo "$as_me: Will use user supplied tool TOUCH=$tool_specified" >&6;} 11862 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TOUCH" >&5 11863 $as_echo_n "checking for TOUCH... " >&6; } 11864 if test ! -x "$tool_specified"; then 11865 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 11866 $as_echo "not found" >&6; } 11867 as_fn_error $? "User supplied tool TOUCH=$tool_specified does not exist or is not executable" "$LINENO" 5 11868 fi 11869 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 11870 $as_echo "$tool_specified" >&6; } 11871 fi 11872 fi 11873 fi 11874 11875 fi 11876 11877 11878 11879 if test "x$TOUCH" = x; then 11880 as_fn_error $? "Could not find required tool for TOUCH" "$LINENO" 5 11881 fi 11882 11883 11884 11885 11886 11887 # Publish this variable in the help. 11888 11889 11890 if [ -z "${TR+x}" ]; then 11891 # The variable is not set by user, try to locate tool using the code snippet 11892 for ac_prog in tr 11893 do 11894 # Extract the first word of "$ac_prog", so it can be a program name with args. 11895 set dummy $ac_prog; ac_word=$2 11896 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11897 $as_echo_n "checking for $ac_word... " >&6; } 11898 if ${ac_cv_path_TR+:} false; then : 11899 $as_echo_n "(cached) " >&6 11900 else 11901 case $TR in 11902 [\\/]* | ?:[\\/]*) 11903 ac_cv_path_TR="$TR" # Let the user override the test with a path. 11904 ;; 11905 *) 11906 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11907 for as_dir in $PATH 11908 do 11909 IFS=$as_save_IFS 11910 test -z "$as_dir" && as_dir=. 11911 for ac_exec_ext in '' $ac_executable_extensions; do 11912 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11913 ac_cv_path_TR="$as_dir/$ac_word$ac_exec_ext" 11914 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11915 break 2 11916 fi 11917 done 11918 done 11919 IFS=$as_save_IFS 11920 11921 ;; 11922 esac 11923 fi 11924 TR=$ac_cv_path_TR 11925 if test -n "$TR"; then 11926 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TR" >&5 11927 $as_echo "$TR" >&6; } 11928 else 11929 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11930 $as_echo "no" >&6; } 11931 fi 11932 11933 11934 test -n "$TR" && break 11935 done 11936 11937 else 11938 # The variable is set, but is it from the command line or the environment? 11939 11940 # Try to remove the string !TR! from our list. 11941 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TR!/} 11942 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 11943 # If it failed, the variable was not from the command line. Ignore it, 11944 # but warn the user (except for BASH, which is always set by the calling BASH). 11945 if test "xTR" != xBASH; then 11946 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TR from the environment. Use command line variables instead." >&5 11947 $as_echo "$as_me: WARNING: Ignoring value of TR from the environment. Use command line variables instead." >&2;} 11948 fi 11949 # Try to locate tool using the code snippet 11950 for ac_prog in tr 11951 do 11952 # Extract the first word of "$ac_prog", so it can be a program name with args. 11953 set dummy $ac_prog; ac_word=$2 11954 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11955 $as_echo_n "checking for $ac_word... " >&6; } 11956 if ${ac_cv_path_TR+:} false; then : 11957 $as_echo_n "(cached) " >&6 11958 else 11959 case $TR in 11960 [\\/]* | ?:[\\/]*) 11961 ac_cv_path_TR="$TR" # Let the user override the test with a path. 11962 ;; 11963 *) 11964 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11965 for as_dir in $PATH 11966 do 11967 IFS=$as_save_IFS 11968 test -z "$as_dir" && as_dir=. 11969 for ac_exec_ext in '' $ac_executable_extensions; do 11970 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11971 ac_cv_path_TR="$as_dir/$ac_word$ac_exec_ext" 11972 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11973 break 2 11974 fi 11975 done 11976 done 11977 IFS=$as_save_IFS 11978 11979 ;; 11980 esac 11981 fi 11982 TR=$ac_cv_path_TR 11983 if test -n "$TR"; then 11984 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TR" >&5 11985 $as_echo "$TR" >&6; } 11986 else 11987 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11988 $as_echo "no" >&6; } 11989 fi 11990 11991 11992 test -n "$TR" && break 11993 done 11994 11995 else 11996 # If it succeeded, then it was overridden by the user. We will use it 11997 # for the tool. 11998 11999 # First remove it from the list of overridden variables, so we can test 12000 # for unknown variables in the end. 12001 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 12002 12003 # Check if we try to supply an empty value 12004 if test "x$TR" = x; then 12005 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TR= (no value)" >&5 12006 $as_echo "$as_me: Setting user supplied tool TR= (no value)" >&6;} 12007 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TR" >&5 12008 $as_echo_n "checking for TR... " >&6; } 12009 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 12010 $as_echo "disabled" >&6; } 12011 else 12012 # Check if the provided tool contains a complete path. 12013 tool_specified="$TR" 12014 tool_basename="${tool_specified##*/}" 12015 if test "x$tool_basename" = "x$tool_specified"; then 12016 # A command without a complete path is provided, search $PATH. 12017 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TR=$tool_basename" >&5 12018 $as_echo "$as_me: Will search for user supplied tool TR=$tool_basename" >&6;} 12019 # Extract the first word of "$tool_basename", so it can be a program name with args. 12020 set dummy $tool_basename; ac_word=$2 12021 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12022 $as_echo_n "checking for $ac_word... " >&6; } 12023 if ${ac_cv_path_TR+:} false; then : 12024 $as_echo_n "(cached) " >&6 12025 else 12026 case $TR in 12027 [\\/]* | ?:[\\/]*) 12028 ac_cv_path_TR="$TR" # Let the user override the test with a path. 12029 ;; 12030 *) 12031 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12032 for as_dir in $PATH 12033 do 12034 IFS=$as_save_IFS 12035 test -z "$as_dir" && as_dir=. 12036 for ac_exec_ext in '' $ac_executable_extensions; do 12037 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12038 ac_cv_path_TR="$as_dir/$ac_word$ac_exec_ext" 12039 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12040 break 2 12041 fi 12042 done 12043 done 12044 IFS=$as_save_IFS 12045 12046 ;; 12047 esac 12048 fi 12049 TR=$ac_cv_path_TR 12050 if test -n "$TR"; then 12051 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TR" >&5 12052 $as_echo "$TR" >&6; } 12053 else 12054 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12055 $as_echo "no" >&6; } 12056 fi 12057 12058 12059 if test "x$TR" = x; then 12060 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 12061 fi 12062 else 12063 # Otherwise we believe it is a complete path. Use it as it is. 12064 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TR=$tool_specified" >&5 12065 $as_echo "$as_me: Will use user supplied tool TR=$tool_specified" >&6;} 12066 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TR" >&5 12067 $as_echo_n "checking for TR... " >&6; } 12068 if test ! -x "$tool_specified"; then 12069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 12070 $as_echo "not found" >&6; } 12071 as_fn_error $? "User supplied tool TR=$tool_specified does not exist or is not executable" "$LINENO" 5 12072 fi 12073 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 12074 $as_echo "$tool_specified" >&6; } 12075 fi 12076 fi 12077 fi 12078 12079 fi 12080 12081 12082 12083 if test "x$TR" = x; then 12084 as_fn_error $? "Could not find required tool for TR" "$LINENO" 5 12085 fi 12086 12087 12088 12089 12090 12091 # Publish this variable in the help. 12092 12093 12094 if [ -z "${UNAME+x}" ]; then 12095 # The variable is not set by user, try to locate tool using the code snippet 12096 for ac_prog in uname 12097 do 12098 # Extract the first word of "$ac_prog", so it can be a program name with args. 12099 set dummy $ac_prog; ac_word=$2 12100 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12101 $as_echo_n "checking for $ac_word... " >&6; } 12102 if ${ac_cv_path_UNAME+:} false; then : 12103 $as_echo_n "(cached) " >&6 12104 else 12105 case $UNAME in 12106 [\\/]* | ?:[\\/]*) 12107 ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path. 12108 ;; 12109 *) 12110 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12111 for as_dir in $PATH 12112 do 12113 IFS=$as_save_IFS 12114 test -z "$as_dir" && as_dir=. 12115 for ac_exec_ext in '' $ac_executable_extensions; do 12116 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12117 ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext" 12118 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12119 break 2 12120 fi 12121 done 12122 done 12123 IFS=$as_save_IFS 12124 12125 ;; 12126 esac 12127 fi 12128 UNAME=$ac_cv_path_UNAME 12129 if test -n "$UNAME"; then 12130 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5 12131 $as_echo "$UNAME" >&6; } 12132 else 12133 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12134 $as_echo "no" >&6; } 12135 fi 12136 12137 12138 test -n "$UNAME" && break 12139 done 12140 12141 else 12142 # The variable is set, but is it from the command line or the environment? 12143 12144 # Try to remove the string !UNAME! from our list. 12145 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!UNAME!/} 12146 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 12147 # If it failed, the variable was not from the command line. Ignore it, 12148 # but warn the user (except for BASH, which is always set by the calling BASH). 12149 if test "xUNAME" != xBASH; then 12150 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of UNAME from the environment. Use command line variables instead." >&5 12151 $as_echo "$as_me: WARNING: Ignoring value of UNAME from the environment. Use command line variables instead." >&2;} 12152 fi 12153 # Try to locate tool using the code snippet 12154 for ac_prog in uname 12155 do 12156 # Extract the first word of "$ac_prog", so it can be a program name with args. 12157 set dummy $ac_prog; ac_word=$2 12158 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12159 $as_echo_n "checking for $ac_word... " >&6; } 12160 if ${ac_cv_path_UNAME+:} false; then : 12161 $as_echo_n "(cached) " >&6 12162 else 12163 case $UNAME in 12164 [\\/]* | ?:[\\/]*) 12165 ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path. 12166 ;; 12167 *) 12168 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12169 for as_dir in $PATH 12170 do 12171 IFS=$as_save_IFS 12172 test -z "$as_dir" && as_dir=. 12173 for ac_exec_ext in '' $ac_executable_extensions; do 12174 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12175 ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext" 12176 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12177 break 2 12178 fi 12179 done 12180 done 12181 IFS=$as_save_IFS 12182 12183 ;; 12184 esac 12185 fi 12186 UNAME=$ac_cv_path_UNAME 12187 if test -n "$UNAME"; then 12188 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5 12189 $as_echo "$UNAME" >&6; } 12190 else 12191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12192 $as_echo "no" >&6; } 12193 fi 12194 12195 12196 test -n "$UNAME" && break 12197 done 12198 12199 else 12200 # If it succeeded, then it was overridden by the user. We will use it 12201 # for the tool. 12202 12203 # First remove it from the list of overridden variables, so we can test 12204 # for unknown variables in the end. 12205 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 12206 12207 # Check if we try to supply an empty value 12208 if test "x$UNAME" = x; then 12209 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool UNAME= (no value)" >&5 12210 $as_echo "$as_me: Setting user supplied tool UNAME= (no value)" >&6;} 12211 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNAME" >&5 12212 $as_echo_n "checking for UNAME... " >&6; } 12213 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 12214 $as_echo "disabled" >&6; } 12215 else 12216 # Check if the provided tool contains a complete path. 12217 tool_specified="$UNAME" 12218 tool_basename="${tool_specified##*/}" 12219 if test "x$tool_basename" = "x$tool_specified"; then 12220 # A command without a complete path is provided, search $PATH. 12221 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool UNAME=$tool_basename" >&5 12222 $as_echo "$as_me: Will search for user supplied tool UNAME=$tool_basename" >&6;} 12223 # Extract the first word of "$tool_basename", so it can be a program name with args. 12224 set dummy $tool_basename; ac_word=$2 12225 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12226 $as_echo_n "checking for $ac_word... " >&6; } 12227 if ${ac_cv_path_UNAME+:} false; then : 12228 $as_echo_n "(cached) " >&6 12229 else 12230 case $UNAME in 12231 [\\/]* | ?:[\\/]*) 12232 ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path. 12233 ;; 12234 *) 12235 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12236 for as_dir in $PATH 12237 do 12238 IFS=$as_save_IFS 12239 test -z "$as_dir" && as_dir=. 12240 for ac_exec_ext in '' $ac_executable_extensions; do 12241 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12242 ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext" 12243 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12244 break 2 12245 fi 12246 done 12247 done 12248 IFS=$as_save_IFS 12249 12250 ;; 12251 esac 12252 fi 12253 UNAME=$ac_cv_path_UNAME 12254 if test -n "$UNAME"; then 12255 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5 12256 $as_echo "$UNAME" >&6; } 12257 else 12258 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12259 $as_echo "no" >&6; } 12260 fi 12261 12262 12263 if test "x$UNAME" = x; then 12264 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 12265 fi 12266 else 12267 # Otherwise we believe it is a complete path. Use it as it is. 12268 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool UNAME=$tool_specified" >&5 12269 $as_echo "$as_me: Will use user supplied tool UNAME=$tool_specified" >&6;} 12270 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNAME" >&5 12271 $as_echo_n "checking for UNAME... " >&6; } 12272 if test ! -x "$tool_specified"; then 12273 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 12274 $as_echo "not found" >&6; } 12275 as_fn_error $? "User supplied tool UNAME=$tool_specified does not exist or is not executable" "$LINENO" 5 12276 fi 12277 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 12278 $as_echo "$tool_specified" >&6; } 12279 fi 12280 fi 12281 fi 12282 12283 fi 12284 12285 12286 12287 if test "x$UNAME" = x; then 12288 as_fn_error $? "Could not find required tool for UNAME" "$LINENO" 5 12289 fi 12290 12291 12292 12293 12294 12295 # Publish this variable in the help. 12296 12297 12298 if [ -z "${UNIQ+x}" ]; then 12299 # The variable is not set by user, try to locate tool using the code snippet 12300 for ac_prog in uniq 12301 do 12302 # Extract the first word of "$ac_prog", so it can be a program name with args. 12303 set dummy $ac_prog; ac_word=$2 12304 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12305 $as_echo_n "checking for $ac_word... " >&6; } 12306 if ${ac_cv_path_UNIQ+:} false; then : 12307 $as_echo_n "(cached) " >&6 12308 else 12309 case $UNIQ in 12310 [\\/]* | ?:[\\/]*) 12311 ac_cv_path_UNIQ="$UNIQ" # Let the user override the test with a path. 12312 ;; 12313 *) 12314 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12315 for as_dir in $PATH 12316 do 12317 IFS=$as_save_IFS 12318 test -z "$as_dir" && as_dir=. 12319 for ac_exec_ext in '' $ac_executable_extensions; do 12320 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12321 ac_cv_path_UNIQ="$as_dir/$ac_word$ac_exec_ext" 12322 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12323 break 2 12324 fi 12325 done 12326 done 12327 IFS=$as_save_IFS 12328 12329 ;; 12330 esac 12331 fi 12332 UNIQ=$ac_cv_path_UNIQ 12333 if test -n "$UNIQ"; then 12334 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNIQ" >&5 12335 $as_echo "$UNIQ" >&6; } 12336 else 12337 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12338 $as_echo "no" >&6; } 12339 fi 12340 12341 12342 test -n "$UNIQ" && break 12343 done 12344 12345 else 12346 # The variable is set, but is it from the command line or the environment? 12347 12348 # Try to remove the string !UNIQ! from our list. 12349 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!UNIQ!/} 12350 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 12351 # If it failed, the variable was not from the command line. Ignore it, 12352 # but warn the user (except for BASH, which is always set by the calling BASH). 12353 if test "xUNIQ" != xBASH; then 12354 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of UNIQ from the environment. Use command line variables instead." >&5 12355 $as_echo "$as_me: WARNING: Ignoring value of UNIQ from the environment. Use command line variables instead." >&2;} 12356 fi 12357 # Try to locate tool using the code snippet 12358 for ac_prog in uniq 12359 do 12360 # Extract the first word of "$ac_prog", so it can be a program name with args. 12361 set dummy $ac_prog; ac_word=$2 12362 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12363 $as_echo_n "checking for $ac_word... " >&6; } 12364 if ${ac_cv_path_UNIQ+:} false; then : 12365 $as_echo_n "(cached) " >&6 12366 else 12367 case $UNIQ in 12368 [\\/]* | ?:[\\/]*) 12369 ac_cv_path_UNIQ="$UNIQ" # Let the user override the test with a path. 12370 ;; 12371 *) 12372 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12373 for as_dir in $PATH 12374 do 12375 IFS=$as_save_IFS 12376 test -z "$as_dir" && as_dir=. 12377 for ac_exec_ext in '' $ac_executable_extensions; do 12378 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12379 ac_cv_path_UNIQ="$as_dir/$ac_word$ac_exec_ext" 12380 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12381 break 2 12382 fi 12383 done 12384 done 12385 IFS=$as_save_IFS 12386 12387 ;; 12388 esac 12389 fi 12390 UNIQ=$ac_cv_path_UNIQ 12391 if test -n "$UNIQ"; then 12392 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNIQ" >&5 12393 $as_echo "$UNIQ" >&6; } 12394 else 12395 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12396 $as_echo "no" >&6; } 12397 fi 12398 12399 12400 test -n "$UNIQ" && break 12401 done 12402 12403 else 12404 # If it succeeded, then it was overridden by the user. We will use it 12405 # for the tool. 12406 12407 # First remove it from the list of overridden variables, so we can test 12408 # for unknown variables in the end. 12409 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 12410 12411 # Check if we try to supply an empty value 12412 if test "x$UNIQ" = x; then 12413 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool UNIQ= (no value)" >&5 12414 $as_echo "$as_me: Setting user supplied tool UNIQ= (no value)" >&6;} 12415 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNIQ" >&5 12416 $as_echo_n "checking for UNIQ... " >&6; } 12417 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 12418 $as_echo "disabled" >&6; } 12419 else 12420 # Check if the provided tool contains a complete path. 12421 tool_specified="$UNIQ" 12422 tool_basename="${tool_specified##*/}" 12423 if test "x$tool_basename" = "x$tool_specified"; then 12424 # A command without a complete path is provided, search $PATH. 12425 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool UNIQ=$tool_basename" >&5 12426 $as_echo "$as_me: Will search for user supplied tool UNIQ=$tool_basename" >&6;} 12427 # Extract the first word of "$tool_basename", so it can be a program name with args. 12428 set dummy $tool_basename; ac_word=$2 12429 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12430 $as_echo_n "checking for $ac_word... " >&6; } 12431 if ${ac_cv_path_UNIQ+:} false; then : 12432 $as_echo_n "(cached) " >&6 12433 else 12434 case $UNIQ in 12435 [\\/]* | ?:[\\/]*) 12436 ac_cv_path_UNIQ="$UNIQ" # Let the user override the test with a path. 12437 ;; 12438 *) 12439 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12440 for as_dir in $PATH 12441 do 12442 IFS=$as_save_IFS 12443 test -z "$as_dir" && as_dir=. 12444 for ac_exec_ext in '' $ac_executable_extensions; do 12445 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12446 ac_cv_path_UNIQ="$as_dir/$ac_word$ac_exec_ext" 12447 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12448 break 2 12449 fi 12450 done 12451 done 12452 IFS=$as_save_IFS 12453 12454 ;; 12455 esac 12456 fi 12457 UNIQ=$ac_cv_path_UNIQ 12458 if test -n "$UNIQ"; then 12459 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNIQ" >&5 12460 $as_echo "$UNIQ" >&6; } 12461 else 12462 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12463 $as_echo "no" >&6; } 12464 fi 12465 12466 12467 if test "x$UNIQ" = x; then 12468 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 12469 fi 12470 else 12471 # Otherwise we believe it is a complete path. Use it as it is. 12472 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool UNIQ=$tool_specified" >&5 12473 $as_echo "$as_me: Will use user supplied tool UNIQ=$tool_specified" >&6;} 12474 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNIQ" >&5 12475 $as_echo_n "checking for UNIQ... " >&6; } 12476 if test ! -x "$tool_specified"; then 12477 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 12478 $as_echo "not found" >&6; } 12479 as_fn_error $? "User supplied tool UNIQ=$tool_specified does not exist or is not executable" "$LINENO" 5 12480 fi 12481 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 12482 $as_echo "$tool_specified" >&6; } 12483 fi 12484 fi 12485 fi 12486 12487 fi 12488 12489 12490 12491 if test "x$UNIQ" = x; then 12492 as_fn_error $? "Could not find required tool for UNIQ" "$LINENO" 5 12493 fi 12494 12495 12496 12497 12498 12499 # Publish this variable in the help. 12500 12501 12502 if [ -z "${WC+x}" ]; then 12503 # The variable is not set by user, try to locate tool using the code snippet 12504 for ac_prog in wc 12505 do 12506 # Extract the first word of "$ac_prog", so it can be a program name with args. 12507 set dummy $ac_prog; ac_word=$2 12508 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12509 $as_echo_n "checking for $ac_word... " >&6; } 12510 if ${ac_cv_path_WC+:} false; then : 12511 $as_echo_n "(cached) " >&6 12512 else 12513 case $WC in 12514 [\\/]* | ?:[\\/]*) 12515 ac_cv_path_WC="$WC" # Let the user override the test with a path. 12516 ;; 12517 *) 12518 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12519 for as_dir in $PATH 12520 do 12521 IFS=$as_save_IFS 12522 test -z "$as_dir" && as_dir=. 12523 for ac_exec_ext in '' $ac_executable_extensions; do 12524 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12525 ac_cv_path_WC="$as_dir/$ac_word$ac_exec_ext" 12526 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12527 break 2 12528 fi 12529 done 12530 done 12531 IFS=$as_save_IFS 12532 12533 ;; 12534 esac 12535 fi 12536 WC=$ac_cv_path_WC 12537 if test -n "$WC"; then 12538 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WC" >&5 12539 $as_echo "$WC" >&6; } 12540 else 12541 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12542 $as_echo "no" >&6; } 12543 fi 12544 12545 12546 test -n "$WC" && break 12547 done 12548 12549 else 12550 # The variable is set, but is it from the command line or the environment? 12551 12552 # Try to remove the string !WC! from our list. 12553 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!WC!/} 12554 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 12555 # If it failed, the variable was not from the command line. Ignore it, 12556 # but warn the user (except for BASH, which is always set by the calling BASH). 12557 if test "xWC" != xBASH; then 12558 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of WC from the environment. Use command line variables instead." >&5 12559 $as_echo "$as_me: WARNING: Ignoring value of WC from the environment. Use command line variables instead." >&2;} 12560 fi 12561 # Try to locate tool using the code snippet 12562 for ac_prog in wc 12563 do 12564 # Extract the first word of "$ac_prog", so it can be a program name with args. 12565 set dummy $ac_prog; ac_word=$2 12566 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12567 $as_echo_n "checking for $ac_word... " >&6; } 12568 if ${ac_cv_path_WC+:} false; then : 12569 $as_echo_n "(cached) " >&6 12570 else 12571 case $WC in 12572 [\\/]* | ?:[\\/]*) 12573 ac_cv_path_WC="$WC" # Let the user override the test with a path. 12574 ;; 12575 *) 12576 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12577 for as_dir in $PATH 12578 do 12579 IFS=$as_save_IFS 12580 test -z "$as_dir" && as_dir=. 12581 for ac_exec_ext in '' $ac_executable_extensions; do 12582 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12583 ac_cv_path_WC="$as_dir/$ac_word$ac_exec_ext" 12584 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12585 break 2 12586 fi 12587 done 12588 done 12589 IFS=$as_save_IFS 12590 12591 ;; 12592 esac 12593 fi 12594 WC=$ac_cv_path_WC 12595 if test -n "$WC"; then 12596 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WC" >&5 12597 $as_echo "$WC" >&6; } 12598 else 12599 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12600 $as_echo "no" >&6; } 12601 fi 12602 12603 12604 test -n "$WC" && break 12605 done 12606 12607 else 12608 # If it succeeded, then it was overridden by the user. We will use it 12609 # for the tool. 12610 12611 # First remove it from the list of overridden variables, so we can test 12612 # for unknown variables in the end. 12613 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 12614 12615 # Check if we try to supply an empty value 12616 if test "x$WC" = x; then 12617 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool WC= (no value)" >&5 12618 $as_echo "$as_me: Setting user supplied tool WC= (no value)" >&6;} 12619 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WC" >&5 12620 $as_echo_n "checking for WC... " >&6; } 12621 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 12622 $as_echo "disabled" >&6; } 12623 else 12624 # Check if the provided tool contains a complete path. 12625 tool_specified="$WC" 12626 tool_basename="${tool_specified##*/}" 12627 if test "x$tool_basename" = "x$tool_specified"; then 12628 # A command without a complete path is provided, search $PATH. 12629 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool WC=$tool_basename" >&5 12630 $as_echo "$as_me: Will search for user supplied tool WC=$tool_basename" >&6;} 12631 # Extract the first word of "$tool_basename", so it can be a program name with args. 12632 set dummy $tool_basename; ac_word=$2 12633 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12634 $as_echo_n "checking for $ac_word... " >&6; } 12635 if ${ac_cv_path_WC+:} false; then : 12636 $as_echo_n "(cached) " >&6 12637 else 12638 case $WC in 12639 [\\/]* | ?:[\\/]*) 12640 ac_cv_path_WC="$WC" # Let the user override the test with a path. 12641 ;; 12642 *) 12643 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12644 for as_dir in $PATH 12645 do 12646 IFS=$as_save_IFS 12647 test -z "$as_dir" && as_dir=. 12648 for ac_exec_ext in '' $ac_executable_extensions; do 12649 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12650 ac_cv_path_WC="$as_dir/$ac_word$ac_exec_ext" 12651 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12652 break 2 12653 fi 12654 done 12655 done 12656 IFS=$as_save_IFS 12657 12658 ;; 12659 esac 12660 fi 12661 WC=$ac_cv_path_WC 12662 if test -n "$WC"; then 12663 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WC" >&5 12664 $as_echo "$WC" >&6; } 12665 else 12666 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12667 $as_echo "no" >&6; } 12668 fi 12669 12670 12671 if test "x$WC" = x; then 12672 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 12673 fi 12674 else 12675 # Otherwise we believe it is a complete path. Use it as it is. 12676 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool WC=$tool_specified" >&5 12677 $as_echo "$as_me: Will use user supplied tool WC=$tool_specified" >&6;} 12678 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WC" >&5 12679 $as_echo_n "checking for WC... " >&6; } 12680 if test ! -x "$tool_specified"; then 12681 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 12682 $as_echo "not found" >&6; } 12683 as_fn_error $? "User supplied tool WC=$tool_specified does not exist or is not executable" "$LINENO" 5 12684 fi 12685 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 12686 $as_echo "$tool_specified" >&6; } 12687 fi 12688 fi 12689 fi 12690 12691 fi 12692 12693 12694 12695 if test "x$WC" = x; then 12696 as_fn_error $? "Could not find required tool for WC" "$LINENO" 5 12697 fi 12698 12699 12700 12701 12702 12703 # Publish this variable in the help. 12704 12705 12706 if [ -z "${WHICH+x}" ]; then 12707 # The variable is not set by user, try to locate tool using the code snippet 12708 for ac_prog in which 12709 do 12710 # Extract the first word of "$ac_prog", so it can be a program name with args. 12711 set dummy $ac_prog; ac_word=$2 12712 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12713 $as_echo_n "checking for $ac_word... " >&6; } 12714 if ${ac_cv_path_WHICH+:} false; then : 12715 $as_echo_n "(cached) " >&6 12716 else 12717 case $WHICH in 12718 [\\/]* | ?:[\\/]*) 12719 ac_cv_path_WHICH="$WHICH" # Let the user override the test with a path. 12720 ;; 12721 *) 12722 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12723 for as_dir in $PATH 12724 do 12725 IFS=$as_save_IFS 12726 test -z "$as_dir" && as_dir=. 12727 for ac_exec_ext in '' $ac_executable_extensions; do 12728 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12729 ac_cv_path_WHICH="$as_dir/$ac_word$ac_exec_ext" 12730 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12731 break 2 12732 fi 12733 done 12734 done 12735 IFS=$as_save_IFS 12736 12737 ;; 12738 esac 12739 fi 12740 WHICH=$ac_cv_path_WHICH 12741 if test -n "$WHICH"; then 12742 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WHICH" >&5 12743 $as_echo "$WHICH" >&6; } 12744 else 12745 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12746 $as_echo "no" >&6; } 12747 fi 12748 12749 12750 test -n "$WHICH" && break 12751 done 12752 12753 else 12754 # The variable is set, but is it from the command line or the environment? 12755 12756 # Try to remove the string !WHICH! from our list. 12757 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!WHICH!/} 12758 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 12759 # If it failed, the variable was not from the command line. Ignore it, 12760 # but warn the user (except for BASH, which is always set by the calling BASH). 12761 if test "xWHICH" != xBASH; then 12762 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of WHICH from the environment. Use command line variables instead." >&5 12763 $as_echo "$as_me: WARNING: Ignoring value of WHICH from the environment. Use command line variables instead." >&2;} 12764 fi 12765 # Try to locate tool using the code snippet 12766 for ac_prog in which 12767 do 12768 # Extract the first word of "$ac_prog", so it can be a program name with args. 12769 set dummy $ac_prog; ac_word=$2 12770 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12771 $as_echo_n "checking for $ac_word... " >&6; } 12772 if ${ac_cv_path_WHICH+:} false; then : 12773 $as_echo_n "(cached) " >&6 12774 else 12775 case $WHICH in 12776 [\\/]* | ?:[\\/]*) 12777 ac_cv_path_WHICH="$WHICH" # Let the user override the test with a path. 12778 ;; 12779 *) 12780 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12781 for as_dir in $PATH 12782 do 12783 IFS=$as_save_IFS 12784 test -z "$as_dir" && as_dir=. 12785 for ac_exec_ext in '' $ac_executable_extensions; do 12786 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12787 ac_cv_path_WHICH="$as_dir/$ac_word$ac_exec_ext" 12788 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12789 break 2 12790 fi 12791 done 12792 done 12793 IFS=$as_save_IFS 12794 12795 ;; 12796 esac 12797 fi 12798 WHICH=$ac_cv_path_WHICH 12799 if test -n "$WHICH"; then 12800 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WHICH" >&5 12801 $as_echo "$WHICH" >&6; } 12802 else 12803 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12804 $as_echo "no" >&6; } 12805 fi 12806 12807 12808 test -n "$WHICH" && break 12809 done 12810 12811 else 12812 # If it succeeded, then it was overridden by the user. We will use it 12813 # for the tool. 12814 12815 # First remove it from the list of overridden variables, so we can test 12816 # for unknown variables in the end. 12817 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 12818 12819 # Check if we try to supply an empty value 12820 if test "x$WHICH" = x; then 12821 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool WHICH= (no value)" >&5 12822 $as_echo "$as_me: Setting user supplied tool WHICH= (no value)" >&6;} 12823 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WHICH" >&5 12824 $as_echo_n "checking for WHICH... " >&6; } 12825 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 12826 $as_echo "disabled" >&6; } 12827 else 12828 # Check if the provided tool contains a complete path. 12829 tool_specified="$WHICH" 12830 tool_basename="${tool_specified##*/}" 12831 if test "x$tool_basename" = "x$tool_specified"; then 12832 # A command without a complete path is provided, search $PATH. 12833 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool WHICH=$tool_basename" >&5 12834 $as_echo "$as_me: Will search for user supplied tool WHICH=$tool_basename" >&6;} 12835 # Extract the first word of "$tool_basename", so it can be a program name with args. 12836 set dummy $tool_basename; ac_word=$2 12837 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12838 $as_echo_n "checking for $ac_word... " >&6; } 12839 if ${ac_cv_path_WHICH+:} false; then : 12840 $as_echo_n "(cached) " >&6 12841 else 12842 case $WHICH in 12843 [\\/]* | ?:[\\/]*) 12844 ac_cv_path_WHICH="$WHICH" # Let the user override the test with a path. 12845 ;; 12846 *) 12847 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12848 for as_dir in $PATH 12849 do 12850 IFS=$as_save_IFS 12851 test -z "$as_dir" && as_dir=. 12852 for ac_exec_ext in '' $ac_executable_extensions; do 12853 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12854 ac_cv_path_WHICH="$as_dir/$ac_word$ac_exec_ext" 12855 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12856 break 2 12857 fi 12858 done 12859 done 12860 IFS=$as_save_IFS 12861 12862 ;; 12863 esac 12864 fi 12865 WHICH=$ac_cv_path_WHICH 12866 if test -n "$WHICH"; then 12867 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WHICH" >&5 12868 $as_echo "$WHICH" >&6; } 12869 else 12870 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12871 $as_echo "no" >&6; } 12872 fi 12873 12874 12875 if test "x$WHICH" = x; then 12876 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 12877 fi 12878 else 12879 # Otherwise we believe it is a complete path. Use it as it is. 12880 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool WHICH=$tool_specified" >&5 12881 $as_echo "$as_me: Will use user supplied tool WHICH=$tool_specified" >&6;} 12882 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WHICH" >&5 12883 $as_echo_n "checking for WHICH... " >&6; } 12884 if test ! -x "$tool_specified"; then 12885 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 12886 $as_echo "not found" >&6; } 12887 as_fn_error $? "User supplied tool WHICH=$tool_specified does not exist or is not executable" "$LINENO" 5 12888 fi 12889 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 12890 $as_echo "$tool_specified" >&6; } 12891 fi 12892 fi 12893 fi 12894 12895 fi 12896 12897 12898 12899 if test "x$WHICH" = x; then 12900 as_fn_error $? "Could not find required tool for WHICH" "$LINENO" 5 12901 fi 12902 12903 12904 12905 12906 12907 # Publish this variable in the help. 12908 12909 12910 if [ -z "${XARGS+x}" ]; then 12911 # The variable is not set by user, try to locate tool using the code snippet 12912 for ac_prog in xargs 12913 do 12914 # Extract the first word of "$ac_prog", so it can be a program name with args. 12915 set dummy $ac_prog; ac_word=$2 12916 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12917 $as_echo_n "checking for $ac_word... " >&6; } 12918 if ${ac_cv_path_XARGS+:} false; then : 12919 $as_echo_n "(cached) " >&6 12920 else 12921 case $XARGS in 12922 [\\/]* | ?:[\\/]*) 12923 ac_cv_path_XARGS="$XARGS" # Let the user override the test with a path. 12924 ;; 12925 *) 12926 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12927 for as_dir in $PATH 12928 do 12929 IFS=$as_save_IFS 12930 test -z "$as_dir" && as_dir=. 12931 for ac_exec_ext in '' $ac_executable_extensions; do 12932 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12933 ac_cv_path_XARGS="$as_dir/$ac_word$ac_exec_ext" 12934 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12935 break 2 12936 fi 12937 done 12938 done 12939 IFS=$as_save_IFS 12940 12941 ;; 12942 esac 12943 fi 12944 XARGS=$ac_cv_path_XARGS 12945 if test -n "$XARGS"; then 12946 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XARGS" >&5 12947 $as_echo "$XARGS" >&6; } 12948 else 12949 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12950 $as_echo "no" >&6; } 12951 fi 12952 12953 12954 test -n "$XARGS" && break 12955 done 12956 12957 else 12958 # The variable is set, but is it from the command line or the environment? 12959 12960 # Try to remove the string !XARGS! from our list. 12961 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!XARGS!/} 12962 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 12963 # If it failed, the variable was not from the command line. Ignore it, 12964 # but warn the user (except for BASH, which is always set by the calling BASH). 12965 if test "xXARGS" != xBASH; then 12966 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of XARGS from the environment. Use command line variables instead." >&5 12967 $as_echo "$as_me: WARNING: Ignoring value of XARGS from the environment. Use command line variables instead." >&2;} 12968 fi 12969 # Try to locate tool using the code snippet 12970 for ac_prog in xargs 12971 do 12972 # Extract the first word of "$ac_prog", so it can be a program name with args. 12973 set dummy $ac_prog; ac_word=$2 12974 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12975 $as_echo_n "checking for $ac_word... " >&6; } 12976 if ${ac_cv_path_XARGS+:} false; then : 12977 $as_echo_n "(cached) " >&6 12978 else 12979 case $XARGS in 12980 [\\/]* | ?:[\\/]*) 12981 ac_cv_path_XARGS="$XARGS" # Let the user override the test with a path. 12982 ;; 12983 *) 12984 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12985 for as_dir in $PATH 12986 do 12987 IFS=$as_save_IFS 12988 test -z "$as_dir" && as_dir=. 12989 for ac_exec_ext in '' $ac_executable_extensions; do 12990 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12991 ac_cv_path_XARGS="$as_dir/$ac_word$ac_exec_ext" 12992 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12993 break 2 12994 fi 12995 done 12996 done 12997 IFS=$as_save_IFS 12998 12999 ;; 13000 esac 13001 fi 13002 XARGS=$ac_cv_path_XARGS 13003 if test -n "$XARGS"; then 13004 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XARGS" >&5 13005 $as_echo "$XARGS" >&6; } 13006 else 13007 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13008 $as_echo "no" >&6; } 13009 fi 13010 13011 13012 test -n "$XARGS" && break 13013 done 13014 13015 else 13016 # If it succeeded, then it was overridden by the user. We will use it 13017 # for the tool. 13018 13019 # First remove it from the list of overridden variables, so we can test 13020 # for unknown variables in the end. 13021 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 13022 13023 # Check if we try to supply an empty value 13024 if test "x$XARGS" = x; then 13025 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool XARGS= (no value)" >&5 13026 $as_echo "$as_me: Setting user supplied tool XARGS= (no value)" >&6;} 13027 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XARGS" >&5 13028 $as_echo_n "checking for XARGS... " >&6; } 13029 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 13030 $as_echo "disabled" >&6; } 13031 else 13032 # Check if the provided tool contains a complete path. 13033 tool_specified="$XARGS" 13034 tool_basename="${tool_specified##*/}" 13035 if test "x$tool_basename" = "x$tool_specified"; then 13036 # A command without a complete path is provided, search $PATH. 13037 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool XARGS=$tool_basename" >&5 13038 $as_echo "$as_me: Will search for user supplied tool XARGS=$tool_basename" >&6;} 13039 # Extract the first word of "$tool_basename", so it can be a program name with args. 13040 set dummy $tool_basename; ac_word=$2 13041 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13042 $as_echo_n "checking for $ac_word... " >&6; } 13043 if ${ac_cv_path_XARGS+:} false; then : 13044 $as_echo_n "(cached) " >&6 13045 else 13046 case $XARGS in 13047 [\\/]* | ?:[\\/]*) 13048 ac_cv_path_XARGS="$XARGS" # Let the user override the test with a path. 13049 ;; 13050 *) 13051 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13052 for as_dir in $PATH 13053 do 13054 IFS=$as_save_IFS 13055 test -z "$as_dir" && as_dir=. 13056 for ac_exec_ext in '' $ac_executable_extensions; do 13057 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13058 ac_cv_path_XARGS="$as_dir/$ac_word$ac_exec_ext" 13059 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13060 break 2 13061 fi 13062 done 13063 done 13064 IFS=$as_save_IFS 13065 13066 ;; 13067 esac 13068 fi 13069 XARGS=$ac_cv_path_XARGS 13070 if test -n "$XARGS"; then 13071 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XARGS" >&5 13072 $as_echo "$XARGS" >&6; } 13073 else 13074 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13075 $as_echo "no" >&6; } 13076 fi 13077 13078 13079 if test "x$XARGS" = x; then 13080 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 13081 fi 13082 else 13083 # Otherwise we believe it is a complete path. Use it as it is. 13084 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool XARGS=$tool_specified" >&5 13085 $as_echo "$as_me: Will use user supplied tool XARGS=$tool_specified" >&6;} 13086 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XARGS" >&5 13087 $as_echo_n "checking for XARGS... " >&6; } 13088 if test ! -x "$tool_specified"; then 13089 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 13090 $as_echo "not found" >&6; } 13091 as_fn_error $? "User supplied tool XARGS=$tool_specified does not exist or is not executable" "$LINENO" 5 13092 fi 13093 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 13094 $as_echo "$tool_specified" >&6; } 13095 fi 13096 fi 13097 fi 13098 13099 fi 13100 13101 13102 13103 if test "x$XARGS" = x; then 13104 as_fn_error $? "Could not find required tool for XARGS" "$LINENO" 5 13105 fi 13106 13107 13108 13109 # Then required tools that require some special treatment. 13110 13111 13112 # Publish this variable in the help. 13113 13114 13115 if [ -z "${AWK+x}" ]; then 13116 # The variable is not set by user, try to locate tool using the code snippet 13117 for ac_prog in gawk mawk nawk awk 13118 do 13119 # Extract the first word of "$ac_prog", so it can be a program name with args. 13120 set dummy $ac_prog; ac_word=$2 13121 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13122 $as_echo_n "checking for $ac_word... " >&6; } 13123 if ${ac_cv_prog_AWK+:} false; then : 13124 $as_echo_n "(cached) " >&6 13125 else 13126 if test -n "$AWK"; then 13127 ac_cv_prog_AWK="$AWK" # Let the user override the test. 13128 else 13129 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13130 for as_dir in $PATH 13131 do 13132 IFS=$as_save_IFS 13133 test -z "$as_dir" && as_dir=. 13134 for ac_exec_ext in '' $ac_executable_extensions; do 13135 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13136 ac_cv_prog_AWK="$ac_prog" 13137 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13138 break 2 13139 fi 13140 done 13141 done 13142 IFS=$as_save_IFS 13143 13144 fi 13145 fi 13146 AWK=$ac_cv_prog_AWK 13147 if test -n "$AWK"; then 13148 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 13149 $as_echo "$AWK" >&6; } 13150 else 13151 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13152 $as_echo "no" >&6; } 13153 fi 13154 13155 13156 test -n "$AWK" && break 13157 done 13158 13159 else 13160 # The variable is set, but is it from the command line or the environment? 13161 13162 # Try to remove the string !AWK! from our list. 13163 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AWK!/} 13164 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 13165 # If it failed, the variable was not from the command line. Ignore it, 13166 # but warn the user (except for BASH, which is always set by the calling BASH). 13167 if test "xAWK" != xBASH; then 13168 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AWK from the environment. Use command line variables instead." >&5 13169 $as_echo "$as_me: WARNING: Ignoring value of AWK from the environment. Use command line variables instead." >&2;} 13170 fi 13171 # Try to locate tool using the code snippet 13172 for ac_prog in gawk mawk nawk awk 13173 do 13174 # Extract the first word of "$ac_prog", so it can be a program name with args. 13175 set dummy $ac_prog; ac_word=$2 13176 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13177 $as_echo_n "checking for $ac_word... " >&6; } 13178 if ${ac_cv_prog_AWK+:} false; then : 13179 $as_echo_n "(cached) " >&6 13180 else 13181 if test -n "$AWK"; then 13182 ac_cv_prog_AWK="$AWK" # Let the user override the test. 13183 else 13184 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13185 for as_dir in $PATH 13186 do 13187 IFS=$as_save_IFS 13188 test -z "$as_dir" && as_dir=. 13189 for ac_exec_ext in '' $ac_executable_extensions; do 13190 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13191 ac_cv_prog_AWK="$ac_prog" 13192 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13193 break 2 13194 fi 13195 done 13196 done 13197 IFS=$as_save_IFS 13198 13199 fi 13200 fi 13201 AWK=$ac_cv_prog_AWK 13202 if test -n "$AWK"; then 13203 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 13204 $as_echo "$AWK" >&6; } 13205 else 13206 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13207 $as_echo "no" >&6; } 13208 fi 13209 13210 13211 test -n "$AWK" && break 13212 done 13213 13214 else 13215 # If it succeeded, then it was overridden by the user. We will use it 13216 # for the tool. 13217 13218 # First remove it from the list of overridden variables, so we can test 13219 # for unknown variables in the end. 13220 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 13221 13222 # Check if we try to supply an empty value 13223 if test "x$AWK" = x; then 13224 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool AWK= (no value)" >&5 13225 $as_echo "$as_me: Setting user supplied tool AWK= (no value)" >&6;} 13226 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AWK" >&5 13227 $as_echo_n "checking for AWK... " >&6; } 13228 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 13229 $as_echo "disabled" >&6; } 13230 else 13231 # Check if the provided tool contains a complete path. 13232 tool_specified="$AWK" 13233 tool_basename="${tool_specified##*/}" 13234 if test "x$tool_basename" = "x$tool_specified"; then 13235 # A command without a complete path is provided, search $PATH. 13236 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AWK=$tool_basename" >&5 13237 $as_echo "$as_me: Will search for user supplied tool AWK=$tool_basename" >&6;} 13238 # Extract the first word of "$tool_basename", so it can be a program name with args. 13239 set dummy $tool_basename; ac_word=$2 13240 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13241 $as_echo_n "checking for $ac_word... " >&6; } 13242 if ${ac_cv_path_AWK+:} false; then : 13243 $as_echo_n "(cached) " >&6 13244 else 13245 case $AWK in 13246 [\\/]* | ?:[\\/]*) 13247 ac_cv_path_AWK="$AWK" # Let the user override the test with a path. 13248 ;; 13249 *) 13250 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13251 for as_dir in $PATH 13252 do 13253 IFS=$as_save_IFS 13254 test -z "$as_dir" && as_dir=. 13255 for ac_exec_ext in '' $ac_executable_extensions; do 13256 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13257 ac_cv_path_AWK="$as_dir/$ac_word$ac_exec_ext" 13258 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13259 break 2 13260 fi 13261 done 13262 done 13263 IFS=$as_save_IFS 13264 13265 ;; 13266 esac 13267 fi 13268 AWK=$ac_cv_path_AWK 13269 if test -n "$AWK"; then 13270 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 13271 $as_echo "$AWK" >&6; } 13272 else 13273 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13274 $as_echo "no" >&6; } 13275 fi 13276 13277 13278 if test "x$AWK" = x; then 13279 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 13280 fi 13281 else 13282 # Otherwise we believe it is a complete path. Use it as it is. 13283 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AWK=$tool_specified" >&5 13284 $as_echo "$as_me: Will use user supplied tool AWK=$tool_specified" >&6;} 13285 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AWK" >&5 13286 $as_echo_n "checking for AWK... " >&6; } 13287 if test ! -x "$tool_specified"; then 13288 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 13289 $as_echo "not found" >&6; } 13290 as_fn_error $? "User supplied tool AWK=$tool_specified does not exist or is not executable" "$LINENO" 5 13291 fi 13292 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 13293 $as_echo "$tool_specified" >&6; } 13294 fi 13295 fi 13296 fi 13297 13298 fi 13299 13300 13301 if test "x$AWK" = x; then 13302 as_fn_error $? "Could not find required tool for AWK" "$LINENO" 5 13303 fi 13304 13305 13306 13307 13308 # Publish this variable in the help. 13309 13310 13311 if [ -z "${GREP+x}" ]; then 13312 # The variable is not set by user, try to locate tool using the code snippet 13313 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 13314 $as_echo_n "checking for grep that handles long lines and -e... " >&6; } 13315 if ${ac_cv_path_GREP+:} false; then : 13316 $as_echo_n "(cached) " >&6 13317 else 13318 if test -z "$GREP"; then 13319 ac_path_GREP_found=false 13320 # Loop through the user's path and test for each of PROGNAME-LIST 13321 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13322 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13323 do 13324 IFS=$as_save_IFS 13325 test -z "$as_dir" && as_dir=. 13326 for ac_prog in grep ggrep; do 13327 for ac_exec_ext in '' $ac_executable_extensions; do 13328 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" 13329 as_fn_executable_p "$ac_path_GREP" || continue 13330 # Check for GNU ac_path_GREP and select it if it is found. 13331 # Check for GNU $ac_path_GREP 13332 case `"$ac_path_GREP" --version 2>&1` in 13333 *GNU*) 13334 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; 13335 *) 13336 ac_count=0 13337 $as_echo_n 0123456789 >"conftest.in" 13338 while : 13339 do 13340 cat "conftest.in" "conftest.in" >"conftest.tmp" 13341 mv "conftest.tmp" "conftest.in" 13342 cp "conftest.in" "conftest.nl" 13343 $as_echo 'GREP' >> "conftest.nl" 13344 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break 13345 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13346 as_fn_arith $ac_count + 1 && ac_count=$as_val 13347 if test $ac_count -gt ${ac_path_GREP_max-0}; then 13348 # Best one so far, save it but keep looking for a better one 13349 ac_cv_path_GREP="$ac_path_GREP" 13350 ac_path_GREP_max=$ac_count 13351 fi 13352 # 10*(2^10) chars as input seems more than enough 13353 test $ac_count -gt 10 && break 13354 done 13355 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13356 esac 13357 13358 $ac_path_GREP_found && break 3 13359 done 13360 done 13361 done 13362 IFS=$as_save_IFS 13363 if test -z "$ac_cv_path_GREP"; then 13364 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13365 fi 13366 else 13367 ac_cv_path_GREP=$GREP 13368 fi 13369 13370 fi 13371 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 13372 $as_echo "$ac_cv_path_GREP" >&6; } 13373 GREP="$ac_cv_path_GREP" 13374 13375 13376 else 13377 # The variable is set, but is it from the command line or the environment? 13378 13379 # Try to remove the string !GREP! from our list. 13380 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!GREP!/} 13381 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 13382 # If it failed, the variable was not from the command line. Ignore it, 13383 # but warn the user (except for BASH, which is always set by the calling BASH). 13384 if test "xGREP" != xBASH; then 13385 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of GREP from the environment. Use command line variables instead." >&5 13386 $as_echo "$as_me: WARNING: Ignoring value of GREP from the environment. Use command line variables instead." >&2;} 13387 fi 13388 # Try to locate tool using the code snippet 13389 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 13390 $as_echo_n "checking for grep that handles long lines and -e... " >&6; } 13391 if ${ac_cv_path_GREP+:} false; then : 13392 $as_echo_n "(cached) " >&6 13393 else 13394 if test -z "$GREP"; then 13395 ac_path_GREP_found=false 13396 # Loop through the user's path and test for each of PROGNAME-LIST 13397 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13398 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13399 do 13400 IFS=$as_save_IFS 13401 test -z "$as_dir" && as_dir=. 13402 for ac_prog in grep ggrep; do 13403 for ac_exec_ext in '' $ac_executable_extensions; do 13404 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" 13405 as_fn_executable_p "$ac_path_GREP" || continue 13406 # Check for GNU ac_path_GREP and select it if it is found. 13407 # Check for GNU $ac_path_GREP 13408 case `"$ac_path_GREP" --version 2>&1` in 13409 *GNU*) 13410 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; 13411 *) 13412 ac_count=0 13413 $as_echo_n 0123456789 >"conftest.in" 13414 while : 13415 do 13416 cat "conftest.in" "conftest.in" >"conftest.tmp" 13417 mv "conftest.tmp" "conftest.in" 13418 cp "conftest.in" "conftest.nl" 13419 $as_echo 'GREP' >> "conftest.nl" 13420 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break 13421 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13422 as_fn_arith $ac_count + 1 && ac_count=$as_val 13423 if test $ac_count -gt ${ac_path_GREP_max-0}; then 13424 # Best one so far, save it but keep looking for a better one 13425 ac_cv_path_GREP="$ac_path_GREP" 13426 ac_path_GREP_max=$ac_count 13427 fi 13428 # 10*(2^10) chars as input seems more than enough 13429 test $ac_count -gt 10 && break 13430 done 13431 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13432 esac 13433 13434 $ac_path_GREP_found && break 3 13435 done 13436 done 13437 done 13438 IFS=$as_save_IFS 13439 if test -z "$ac_cv_path_GREP"; then 13440 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13441 fi 13442 else 13443 ac_cv_path_GREP=$GREP 13444 fi 13445 13446 fi 13447 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 13448 $as_echo "$ac_cv_path_GREP" >&6; } 13449 GREP="$ac_cv_path_GREP" 13450 13451 13452 else 13453 # If it succeeded, then it was overridden by the user. We will use it 13454 # for the tool. 13455 13456 # First remove it from the list of overridden variables, so we can test 13457 # for unknown variables in the end. 13458 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 13459 13460 # Check if we try to supply an empty value 13461 if test "x$GREP" = x; then 13462 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool GREP= (no value)" >&5 13463 $as_echo "$as_me: Setting user supplied tool GREP= (no value)" >&6;} 13464 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GREP" >&5 13465 $as_echo_n "checking for GREP... " >&6; } 13466 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 13467 $as_echo "disabled" >&6; } 13468 else 13469 # Check if the provided tool contains a complete path. 13470 tool_specified="$GREP" 13471 tool_basename="${tool_specified##*/}" 13472 if test "x$tool_basename" = "x$tool_specified"; then 13473 # A command without a complete path is provided, search $PATH. 13474 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool GREP=$tool_basename" >&5 13475 $as_echo "$as_me: Will search for user supplied tool GREP=$tool_basename" >&6;} 13476 # Extract the first word of "$tool_basename", so it can be a program name with args. 13477 set dummy $tool_basename; ac_word=$2 13478 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13479 $as_echo_n "checking for $ac_word... " >&6; } 13480 if ${ac_cv_path_GREP+:} false; then : 13481 $as_echo_n "(cached) " >&6 13482 else 13483 case $GREP in 13484 [\\/]* | ?:[\\/]*) 13485 ac_cv_path_GREP="$GREP" # Let the user override the test with a path. 13486 ;; 13487 *) 13488 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13489 for as_dir in $PATH 13490 do 13491 IFS=$as_save_IFS 13492 test -z "$as_dir" && as_dir=. 13493 for ac_exec_ext in '' $ac_executable_extensions; do 13494 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13495 ac_cv_path_GREP="$as_dir/$ac_word$ac_exec_ext" 13496 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13497 break 2 13498 fi 13499 done 13500 done 13501 IFS=$as_save_IFS 13502 13503 ;; 13504 esac 13505 fi 13506 GREP=$ac_cv_path_GREP 13507 if test -n "$GREP"; then 13508 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GREP" >&5 13509 $as_echo "$GREP" >&6; } 13510 else 13511 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13512 $as_echo "no" >&6; } 13513 fi 13514 13515 13516 if test "x$GREP" = x; then 13517 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 13518 fi 13519 else 13520 # Otherwise we believe it is a complete path. Use it as it is. 13521 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool GREP=$tool_specified" >&5 13522 $as_echo "$as_me: Will use user supplied tool GREP=$tool_specified" >&6;} 13523 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GREP" >&5 13524 $as_echo_n "checking for GREP... " >&6; } 13525 if test ! -x "$tool_specified"; then 13526 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 13527 $as_echo "not found" >&6; } 13528 as_fn_error $? "User supplied tool GREP=$tool_specified does not exist or is not executable" "$LINENO" 5 13529 fi 13530 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 13531 $as_echo "$tool_specified" >&6; } 13532 fi 13533 fi 13534 fi 13535 13536 fi 13537 13538 13539 if test "x$GREP" = x; then 13540 as_fn_error $? "Could not find required tool for GREP" "$LINENO" 5 13541 fi 13542 13543 13544 13545 13546 # Publish this variable in the help. 13547 13548 13549 if [ -z "${EGREP+x}" ]; then 13550 # The variable is not set by user, try to locate tool using the code snippet 13551 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 13552 $as_echo_n "checking for egrep... " >&6; } 13553 if ${ac_cv_path_EGREP+:} false; then : 13554 $as_echo_n "(cached) " >&6 13555 else 13556 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 13557 then ac_cv_path_EGREP="$GREP -E" 13558 else 13559 if test -z "$EGREP"; then 13560 ac_path_EGREP_found=false 13561 # Loop through the user's path and test for each of PROGNAME-LIST 13562 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13563 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13564 do 13565 IFS=$as_save_IFS 13566 test -z "$as_dir" && as_dir=. 13567 for ac_prog in egrep; do 13568 for ac_exec_ext in '' $ac_executable_extensions; do 13569 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" 13570 as_fn_executable_p "$ac_path_EGREP" || continue 13571 # Check for GNU ac_path_EGREP and select it if it is found. 13572 # Check for GNU $ac_path_EGREP 13573 case `"$ac_path_EGREP" --version 2>&1` in 13574 *GNU*) 13575 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; 13576 *) 13577 ac_count=0 13578 $as_echo_n 0123456789 >"conftest.in" 13579 while : 13580 do 13581 cat "conftest.in" "conftest.in" >"conftest.tmp" 13582 mv "conftest.tmp" "conftest.in" 13583 cp "conftest.in" "conftest.nl" 13584 $as_echo 'EGREP' >> "conftest.nl" 13585 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break 13586 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13587 as_fn_arith $ac_count + 1 && ac_count=$as_val 13588 if test $ac_count -gt ${ac_path_EGREP_max-0}; then 13589 # Best one so far, save it but keep looking for a better one 13590 ac_cv_path_EGREP="$ac_path_EGREP" 13591 ac_path_EGREP_max=$ac_count 13592 fi 13593 # 10*(2^10) chars as input seems more than enough 13594 test $ac_count -gt 10 && break 13595 done 13596 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13597 esac 13598 13599 $ac_path_EGREP_found && break 3 13600 done 13601 done 13602 done 13603 IFS=$as_save_IFS 13604 if test -z "$ac_cv_path_EGREP"; then 13605 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13606 fi 13607 else 13608 ac_cv_path_EGREP=$EGREP 13609 fi 13610 13611 fi 13612 fi 13613 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 13614 $as_echo "$ac_cv_path_EGREP" >&6; } 13615 EGREP="$ac_cv_path_EGREP" 13616 13617 13618 else 13619 # The variable is set, but is it from the command line or the environment? 13620 13621 # Try to remove the string !EGREP! from our list. 13622 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!EGREP!/} 13623 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 13624 # If it failed, the variable was not from the command line. Ignore it, 13625 # but warn the user (except for BASH, which is always set by the calling BASH). 13626 if test "xEGREP" != xBASH; then 13627 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of EGREP from the environment. Use command line variables instead." >&5 13628 $as_echo "$as_me: WARNING: Ignoring value of EGREP from the environment. Use command line variables instead." >&2;} 13629 fi 13630 # Try to locate tool using the code snippet 13631 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 13632 $as_echo_n "checking for egrep... " >&6; } 13633 if ${ac_cv_path_EGREP+:} false; then : 13634 $as_echo_n "(cached) " >&6 13635 else 13636 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 13637 then ac_cv_path_EGREP="$GREP -E" 13638 else 13639 if test -z "$EGREP"; then 13640 ac_path_EGREP_found=false 13641 # Loop through the user's path and test for each of PROGNAME-LIST 13642 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13643 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13644 do 13645 IFS=$as_save_IFS 13646 test -z "$as_dir" && as_dir=. 13647 for ac_prog in egrep; do 13648 for ac_exec_ext in '' $ac_executable_extensions; do 13649 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" 13650 as_fn_executable_p "$ac_path_EGREP" || continue 13651 # Check for GNU ac_path_EGREP and select it if it is found. 13652 # Check for GNU $ac_path_EGREP 13653 case `"$ac_path_EGREP" --version 2>&1` in 13654 *GNU*) 13655 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; 13656 *) 13657 ac_count=0 13658 $as_echo_n 0123456789 >"conftest.in" 13659 while : 13660 do 13661 cat "conftest.in" "conftest.in" >"conftest.tmp" 13662 mv "conftest.tmp" "conftest.in" 13663 cp "conftest.in" "conftest.nl" 13664 $as_echo 'EGREP' >> "conftest.nl" 13665 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break 13666 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13667 as_fn_arith $ac_count + 1 && ac_count=$as_val 13668 if test $ac_count -gt ${ac_path_EGREP_max-0}; then 13669 # Best one so far, save it but keep looking for a better one 13670 ac_cv_path_EGREP="$ac_path_EGREP" 13671 ac_path_EGREP_max=$ac_count 13672 fi 13673 # 10*(2^10) chars as input seems more than enough 13674 test $ac_count -gt 10 && break 13675 done 13676 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13677 esac 13678 13679 $ac_path_EGREP_found && break 3 13680 done 13681 done 13682 done 13683 IFS=$as_save_IFS 13684 if test -z "$ac_cv_path_EGREP"; then 13685 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13686 fi 13687 else 13688 ac_cv_path_EGREP=$EGREP 13689 fi 13690 13691 fi 13692 fi 13693 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 13694 $as_echo "$ac_cv_path_EGREP" >&6; } 13695 EGREP="$ac_cv_path_EGREP" 13696 13697 13698 else 13699 # If it succeeded, then it was overridden by the user. We will use it 13700 # for the tool. 13701 13702 # First remove it from the list of overridden variables, so we can test 13703 # for unknown variables in the end. 13704 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 13705 13706 # Check if we try to supply an empty value 13707 if test "x$EGREP" = x; then 13708 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool EGREP= (no value)" >&5 13709 $as_echo "$as_me: Setting user supplied tool EGREP= (no value)" >&6;} 13710 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGREP" >&5 13711 $as_echo_n "checking for EGREP... " >&6; } 13712 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 13713 $as_echo "disabled" >&6; } 13714 else 13715 # Check if the provided tool contains a complete path. 13716 tool_specified="$EGREP" 13717 tool_basename="${tool_specified##*/}" 13718 if test "x$tool_basename" = "x$tool_specified"; then 13719 # A command without a complete path is provided, search $PATH. 13720 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool EGREP=$tool_basename" >&5 13721 $as_echo "$as_me: Will search for user supplied tool EGREP=$tool_basename" >&6;} 13722 # Extract the first word of "$tool_basename", so it can be a program name with args. 13723 set dummy $tool_basename; ac_word=$2 13724 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13725 $as_echo_n "checking for $ac_word... " >&6; } 13726 if ${ac_cv_path_EGREP+:} false; then : 13727 $as_echo_n "(cached) " >&6 13728 else 13729 case $EGREP in 13730 [\\/]* | ?:[\\/]*) 13731 ac_cv_path_EGREP="$EGREP" # Let the user override the test with a path. 13732 ;; 13733 *) 13734 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13735 for as_dir in $PATH 13736 do 13737 IFS=$as_save_IFS 13738 test -z "$as_dir" && as_dir=. 13739 for ac_exec_ext in '' $ac_executable_extensions; do 13740 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13741 ac_cv_path_EGREP="$as_dir/$ac_word$ac_exec_ext" 13742 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13743 break 2 13744 fi 13745 done 13746 done 13747 IFS=$as_save_IFS 13748 13749 ;; 13750 esac 13751 fi 13752 EGREP=$ac_cv_path_EGREP 13753 if test -n "$EGREP"; then 13754 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EGREP" >&5 13755 $as_echo "$EGREP" >&6; } 13756 else 13757 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13758 $as_echo "no" >&6; } 13759 fi 13760 13761 13762 if test "x$EGREP" = x; then 13763 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 13764 fi 13765 else 13766 # Otherwise we believe it is a complete path. Use it as it is. 13767 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool EGREP=$tool_specified" >&5 13768 $as_echo "$as_me: Will use user supplied tool EGREP=$tool_specified" >&6;} 13769 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGREP" >&5 13770 $as_echo_n "checking for EGREP... " >&6; } 13771 if test ! -x "$tool_specified"; then 13772 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 13773 $as_echo "not found" >&6; } 13774 as_fn_error $? "User supplied tool EGREP=$tool_specified does not exist or is not executable" "$LINENO" 5 13775 fi 13776 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 13777 $as_echo "$tool_specified" >&6; } 13778 fi 13779 fi 13780 fi 13781 13782 fi 13783 13784 13785 if test "x$EGREP" = x; then 13786 as_fn_error $? "Could not find required tool for EGREP" "$LINENO" 5 13787 fi 13788 13789 13790 13791 13792 # Publish this variable in the help. 13793 13794 13795 if [ -z "${FGREP+x}" ]; then 13796 # The variable is not set by user, try to locate tool using the code snippet 13797 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5 13798 $as_echo_n "checking for fgrep... " >&6; } 13799 if ${ac_cv_path_FGREP+:} false; then : 13800 $as_echo_n "(cached) " >&6 13801 else 13802 if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1 13803 then ac_cv_path_FGREP="$GREP -F" 13804 else 13805 if test -z "$FGREP"; then 13806 ac_path_FGREP_found=false 13807 # Loop through the user's path and test for each of PROGNAME-LIST 13808 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13809 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13810 do 13811 IFS=$as_save_IFS 13812 test -z "$as_dir" && as_dir=. 13813 for ac_prog in fgrep; do 13814 for ac_exec_ext in '' $ac_executable_extensions; do 13815 ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext" 13816 as_fn_executable_p "$ac_path_FGREP" || continue 13817 # Check for GNU ac_path_FGREP and select it if it is found. 13818 # Check for GNU $ac_path_FGREP 13819 case `"$ac_path_FGREP" --version 2>&1` in 13820 *GNU*) 13821 ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;; 13822 *) 13823 ac_count=0 13824 $as_echo_n 0123456789 >"conftest.in" 13825 while : 13826 do 13827 cat "conftest.in" "conftest.in" >"conftest.tmp" 13828 mv "conftest.tmp" "conftest.in" 13829 cp "conftest.in" "conftest.nl" 13830 $as_echo 'FGREP' >> "conftest.nl" 13831 "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break 13832 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13833 as_fn_arith $ac_count + 1 && ac_count=$as_val 13834 if test $ac_count -gt ${ac_path_FGREP_max-0}; then 13835 # Best one so far, save it but keep looking for a better one 13836 ac_cv_path_FGREP="$ac_path_FGREP" 13837 ac_path_FGREP_max=$ac_count 13838 fi 13839 # 10*(2^10) chars as input seems more than enough 13840 test $ac_count -gt 10 && break 13841 done 13842 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13843 esac 13844 13845 $ac_path_FGREP_found && break 3 13846 done 13847 done 13848 done 13849 IFS=$as_save_IFS 13850 if test -z "$ac_cv_path_FGREP"; then 13851 as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13852 fi 13853 else 13854 ac_cv_path_FGREP=$FGREP 13855 fi 13856 13857 fi 13858 fi 13859 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5 13860 $as_echo "$ac_cv_path_FGREP" >&6; } 13861 FGREP="$ac_cv_path_FGREP" 13862 13863 13864 else 13865 # The variable is set, but is it from the command line or the environment? 13866 13867 # Try to remove the string !FGREP! from our list. 13868 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FGREP!/} 13869 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 13870 # If it failed, the variable was not from the command line. Ignore it, 13871 # but warn the user (except for BASH, which is always set by the calling BASH). 13872 if test "xFGREP" != xBASH; then 13873 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FGREP from the environment. Use command line variables instead." >&5 13874 $as_echo "$as_me: WARNING: Ignoring value of FGREP from the environment. Use command line variables instead." >&2;} 13875 fi 13876 # Try to locate tool using the code snippet 13877 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5 13878 $as_echo_n "checking for fgrep... " >&6; } 13879 if ${ac_cv_path_FGREP+:} false; then : 13880 $as_echo_n "(cached) " >&6 13881 else 13882 if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1 13883 then ac_cv_path_FGREP="$GREP -F" 13884 else 13885 if test -z "$FGREP"; then 13886 ac_path_FGREP_found=false 13887 # Loop through the user's path and test for each of PROGNAME-LIST 13888 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13889 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13890 do 13891 IFS=$as_save_IFS 13892 test -z "$as_dir" && as_dir=. 13893 for ac_prog in fgrep; do 13894 for ac_exec_ext in '' $ac_executable_extensions; do 13895 ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext" 13896 as_fn_executable_p "$ac_path_FGREP" || continue 13897 # Check for GNU ac_path_FGREP and select it if it is found. 13898 # Check for GNU $ac_path_FGREP 13899 case `"$ac_path_FGREP" --version 2>&1` in 13900 *GNU*) 13901 ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;; 13902 *) 13903 ac_count=0 13904 $as_echo_n 0123456789 >"conftest.in" 13905 while : 13906 do 13907 cat "conftest.in" "conftest.in" >"conftest.tmp" 13908 mv "conftest.tmp" "conftest.in" 13909 cp "conftest.in" "conftest.nl" 13910 $as_echo 'FGREP' >> "conftest.nl" 13911 "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break 13912 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13913 as_fn_arith $ac_count + 1 && ac_count=$as_val 13914 if test $ac_count -gt ${ac_path_FGREP_max-0}; then 13915 # Best one so far, save it but keep looking for a better one 13916 ac_cv_path_FGREP="$ac_path_FGREP" 13917 ac_path_FGREP_max=$ac_count 13918 fi 13919 # 10*(2^10) chars as input seems more than enough 13920 test $ac_count -gt 10 && break 13921 done 13922 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13923 esac 13924 13925 $ac_path_FGREP_found && break 3 13926 done 13927 done 13928 done 13929 IFS=$as_save_IFS 13930 if test -z "$ac_cv_path_FGREP"; then 13931 as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13932 fi 13933 else 13934 ac_cv_path_FGREP=$FGREP 13935 fi 13936 13937 fi 13938 fi 13939 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5 13940 $as_echo "$ac_cv_path_FGREP" >&6; } 13941 FGREP="$ac_cv_path_FGREP" 13942 13943 13944 else 13945 # If it succeeded, then it was overridden by the user. We will use it 13946 # for the tool. 13947 13948 # First remove it from the list of overridden variables, so we can test 13949 # for unknown variables in the end. 13950 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 13951 13952 # Check if we try to supply an empty value 13953 if test "x$FGREP" = x; then 13954 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool FGREP= (no value)" >&5 13955 $as_echo "$as_me: Setting user supplied tool FGREP= (no value)" >&6;} 13956 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FGREP" >&5 13957 $as_echo_n "checking for FGREP... " >&6; } 13958 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 13959 $as_echo "disabled" >&6; } 13960 else 13961 # Check if the provided tool contains a complete path. 13962 tool_specified="$FGREP" 13963 tool_basename="${tool_specified##*/}" 13964 if test "x$tool_basename" = "x$tool_specified"; then 13965 # A command without a complete path is provided, search $PATH. 13966 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FGREP=$tool_basename" >&5 13967 $as_echo "$as_me: Will search for user supplied tool FGREP=$tool_basename" >&6;} 13968 # Extract the first word of "$tool_basename", so it can be a program name with args. 13969 set dummy $tool_basename; ac_word=$2 13970 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13971 $as_echo_n "checking for $ac_word... " >&6; } 13972 if ${ac_cv_path_FGREP+:} false; then : 13973 $as_echo_n "(cached) " >&6 13974 else 13975 case $FGREP in 13976 [\\/]* | ?:[\\/]*) 13977 ac_cv_path_FGREP="$FGREP" # Let the user override the test with a path. 13978 ;; 13979 *) 13980 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13981 for as_dir in $PATH 13982 do 13983 IFS=$as_save_IFS 13984 test -z "$as_dir" && as_dir=. 13985 for ac_exec_ext in '' $ac_executable_extensions; do 13986 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13987 ac_cv_path_FGREP="$as_dir/$ac_word$ac_exec_ext" 13988 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13989 break 2 13990 fi 13991 done 13992 done 13993 IFS=$as_save_IFS 13994 13995 ;; 13996 esac 13997 fi 13998 FGREP=$ac_cv_path_FGREP 13999 if test -n "$FGREP"; then 14000 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FGREP" >&5 14001 $as_echo "$FGREP" >&6; } 14002 else 14003 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14004 $as_echo "no" >&6; } 14005 fi 14006 14007 14008 if test "x$FGREP" = x; then 14009 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 14010 fi 14011 else 14012 # Otherwise we believe it is a complete path. Use it as it is. 14013 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FGREP=$tool_specified" >&5 14014 $as_echo "$as_me: Will use user supplied tool FGREP=$tool_specified" >&6;} 14015 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FGREP" >&5 14016 $as_echo_n "checking for FGREP... " >&6; } 14017 if test ! -x "$tool_specified"; then 14018 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 14019 $as_echo "not found" >&6; } 14020 as_fn_error $? "User supplied tool FGREP=$tool_specified does not exist or is not executable" "$LINENO" 5 14021 fi 14022 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 14023 $as_echo "$tool_specified" >&6; } 14024 fi 14025 fi 14026 fi 14027 14028 fi 14029 14030 14031 if test "x$FGREP" = x; then 14032 as_fn_error $? "Could not find required tool for FGREP" "$LINENO" 5 14033 fi 14034 14035 14036 14037 14038 # Publish this variable in the help. 14039 14040 14041 if [ -z "${SED+x}" ]; then 14042 # The variable is not set by user, try to locate tool using the code snippet 14043 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 14044 $as_echo_n "checking for a sed that does not truncate output... " >&6; } 14045 if ${ac_cv_path_SED+:} false; then : 14046 $as_echo_n "(cached) " >&6 14047 else 14048 ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ 14049 for ac_i in 1 2 3 4 5 6 7; do 14050 ac_script="$ac_script$as_nl$ac_script" 14051 done 14052 echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed 14053 { ac_script=; unset ac_script;} 14054 if test -z "$SED"; then 14055 ac_path_SED_found=false 14056 # Loop through the user's path and test for each of PROGNAME-LIST 14057 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14058 for as_dir in $PATH 14059 do 14060 IFS=$as_save_IFS 14061 test -z "$as_dir" && as_dir=. 14062 for ac_prog in sed gsed; do 14063 for ac_exec_ext in '' $ac_executable_extensions; do 14064 ac_path_SED="$as_dir/$ac_prog$ac_exec_ext" 14065 as_fn_executable_p "$ac_path_SED" || continue 14066 # Check for GNU ac_path_SED and select it if it is found. 14067 # Check for GNU $ac_path_SED 14068 case `"$ac_path_SED" --version 2>&1` in 14069 *GNU*) 14070 ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;; 14071 *) 14072 ac_count=0 14073 $as_echo_n 0123456789 >"conftest.in" 14074 while : 14075 do 14076 cat "conftest.in" "conftest.in" >"conftest.tmp" 14077 mv "conftest.tmp" "conftest.in" 14078 cp "conftest.in" "conftest.nl" 14079 $as_echo '' >> "conftest.nl" 14080 "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break 14081 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 14082 as_fn_arith $ac_count + 1 && ac_count=$as_val 14083 if test $ac_count -gt ${ac_path_SED_max-0}; then 14084 # Best one so far, save it but keep looking for a better one 14085 ac_cv_path_SED="$ac_path_SED" 14086 ac_path_SED_max=$ac_count 14087 fi 14088 # 10*(2^10) chars as input seems more than enough 14089 test $ac_count -gt 10 && break 14090 done 14091 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 14092 esac 14093 14094 $ac_path_SED_found && break 3 14095 done 14096 done 14097 done 14098 IFS=$as_save_IFS 14099 if test -z "$ac_cv_path_SED"; then 14100 as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5 14101 fi 14102 else 14103 ac_cv_path_SED=$SED 14104 fi 14105 14106 fi 14107 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5 14108 $as_echo "$ac_cv_path_SED" >&6; } 14109 SED="$ac_cv_path_SED" 14110 rm -f conftest.sed 14111 14112 else 14113 # The variable is set, but is it from the command line or the environment? 14114 14115 # Try to remove the string !SED! from our list. 14116 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SED!/} 14117 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 14118 # If it failed, the variable was not from the command line. Ignore it, 14119 # but warn the user (except for BASH, which is always set by the calling BASH). 14120 if test "xSED" != xBASH; then 14121 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SED from the environment. Use command line variables instead." >&5 14122 $as_echo "$as_me: WARNING: Ignoring value of SED from the environment. Use command line variables instead." >&2;} 14123 fi 14124 # 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 # If it succeeded, then it was overridden by the user. We will use it 14196 # for the tool. 14197 14198 # First remove it from the list of overridden variables, so we can test 14199 # for unknown variables in the end. 14200 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 14201 14202 # Check if we try to supply an empty value 14203 if test "x$SED" = x; then 14204 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool SED= (no value)" >&5 14205 $as_echo "$as_me: Setting user supplied tool SED= (no value)" >&6;} 14206 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SED" >&5 14207 $as_echo_n "checking for SED... " >&6; } 14208 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 14209 $as_echo "disabled" >&6; } 14210 else 14211 # Check if the provided tool contains a complete path. 14212 tool_specified="$SED" 14213 tool_basename="${tool_specified##*/}" 14214 if test "x$tool_basename" = "x$tool_specified"; then 14215 # A command without a complete path is provided, search $PATH. 14216 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SED=$tool_basename" >&5 14217 $as_echo "$as_me: Will search for user supplied tool SED=$tool_basename" >&6;} 14218 # Extract the first word of "$tool_basename", so it can be a program name with args. 14219 set dummy $tool_basename; ac_word=$2 14220 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14221 $as_echo_n "checking for $ac_word... " >&6; } 14222 if ${ac_cv_path_SED+:} false; then : 14223 $as_echo_n "(cached) " >&6 14224 else 14225 case $SED in 14226 [\\/]* | ?:[\\/]*) 14227 ac_cv_path_SED="$SED" # Let the user override the test with a path. 14228 ;; 14229 *) 14230 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14231 for as_dir in $PATH 14232 do 14233 IFS=$as_save_IFS 14234 test -z "$as_dir" && as_dir=. 14235 for ac_exec_ext in '' $ac_executable_extensions; do 14236 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14237 ac_cv_path_SED="$as_dir/$ac_word$ac_exec_ext" 14238 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14239 break 2 14240 fi 14241 done 14242 done 14243 IFS=$as_save_IFS 14244 14245 ;; 14246 esac 14247 fi 14248 SED=$ac_cv_path_SED 14249 if test -n "$SED"; then 14250 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SED" >&5 14251 $as_echo "$SED" >&6; } 14252 else 14253 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14254 $as_echo "no" >&6; } 14255 fi 14256 14257 14258 if test "x$SED" = x; then 14259 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 14260 fi 14261 else 14262 # Otherwise we believe it is a complete path. Use it as it is. 14263 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SED=$tool_specified" >&5 14264 $as_echo "$as_me: Will use user supplied tool SED=$tool_specified" >&6;} 14265 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SED" >&5 14266 $as_echo_n "checking for SED... " >&6; } 14267 if test ! -x "$tool_specified"; then 14268 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 14269 $as_echo "not found" >&6; } 14270 as_fn_error $? "User supplied tool SED=$tool_specified does not exist or is not executable" "$LINENO" 5 14271 fi 14272 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 14273 $as_echo "$tool_specified" >&6; } 14274 fi 14275 fi 14276 fi 14277 14278 fi 14279 14280 14281 if test "x$SED" = x; then 14282 as_fn_error $? "Could not find required tool for SED" "$LINENO" 5 14283 fi 14284 14285 14286 14287 # Always force rm. 14288 RM="$RM -f" 14289 14290 # pwd behaves differently on various platforms and some don't support the -L flag. 14291 # Always use the bash builtin pwd to get uniform behavior. 14292 THEPWDCMD=pwd 14293 14294 # These are not required on all platforms 14295 14296 14297 # Publish this variable in the help. 14298 14299 14300 if [ -z "${CYGPATH+x}" ]; then 14301 # The variable is not set by user, try to locate tool using the code snippet 14302 for ac_prog in cygpath 14303 do 14304 # Extract the first word of "$ac_prog", so it can be a program name with args. 14305 set dummy $ac_prog; ac_word=$2 14306 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14307 $as_echo_n "checking for $ac_word... " >&6; } 14308 if ${ac_cv_path_CYGPATH+:} false; then : 14309 $as_echo_n "(cached) " >&6 14310 else 14311 case $CYGPATH in 14312 [\\/]* | ?:[\\/]*) 14313 ac_cv_path_CYGPATH="$CYGPATH" # Let the user override the test with a path. 14314 ;; 14315 *) 14316 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14317 for as_dir in $PATH 14318 do 14319 IFS=$as_save_IFS 14320 test -z "$as_dir" && as_dir=. 14321 for ac_exec_ext in '' $ac_executable_extensions; do 14322 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14323 ac_cv_path_CYGPATH="$as_dir/$ac_word$ac_exec_ext" 14324 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14325 break 2 14326 fi 14327 done 14328 done 14329 IFS=$as_save_IFS 14330 14331 ;; 14332 esac 14333 fi 14334 CYGPATH=$ac_cv_path_CYGPATH 14335 if test -n "$CYGPATH"; then 14336 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5 14337 $as_echo "$CYGPATH" >&6; } 14338 else 14339 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14340 $as_echo "no" >&6; } 14341 fi 14342 14343 14344 test -n "$CYGPATH" && break 14345 done 14346 14347 else 14348 # The variable is set, but is it from the command line or the environment? 14349 14350 # Try to remove the string !CYGPATH! from our list. 14351 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CYGPATH!/} 14352 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 14353 # If it failed, the variable was not from the command line. Ignore it, 14354 # but warn the user (except for BASH, which is always set by the calling BASH). 14355 if test "xCYGPATH" != xBASH; then 14356 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CYGPATH from the environment. Use command line variables instead." >&5 14357 $as_echo "$as_me: WARNING: Ignoring value of CYGPATH from the environment. Use command line variables instead." >&2;} 14358 fi 14359 # Try to locate tool using the code snippet 14360 for ac_prog in cygpath 14361 do 14362 # Extract the first word of "$ac_prog", so it can be a program name with args. 14363 set dummy $ac_prog; ac_word=$2 14364 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14365 $as_echo_n "checking for $ac_word... " >&6; } 14366 if ${ac_cv_path_CYGPATH+:} false; then : 14367 $as_echo_n "(cached) " >&6 14368 else 14369 case $CYGPATH in 14370 [\\/]* | ?:[\\/]*) 14371 ac_cv_path_CYGPATH="$CYGPATH" # Let the user override the test with a path. 14372 ;; 14373 *) 14374 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14375 for as_dir in $PATH 14376 do 14377 IFS=$as_save_IFS 14378 test -z "$as_dir" && as_dir=. 14379 for ac_exec_ext in '' $ac_executable_extensions; do 14380 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14381 ac_cv_path_CYGPATH="$as_dir/$ac_word$ac_exec_ext" 14382 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14383 break 2 14384 fi 14385 done 14386 done 14387 IFS=$as_save_IFS 14388 14389 ;; 14390 esac 14391 fi 14392 CYGPATH=$ac_cv_path_CYGPATH 14393 if test -n "$CYGPATH"; then 14394 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5 14395 $as_echo "$CYGPATH" >&6; } 14396 else 14397 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14398 $as_echo "no" >&6; } 14399 fi 14400 14401 14402 test -n "$CYGPATH" && break 14403 done 14404 14405 else 14406 # If it succeeded, then it was overridden by the user. We will use it 14407 # for the tool. 14408 14409 # First remove it from the list of overridden variables, so we can test 14410 # for unknown variables in the end. 14411 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 14412 14413 # Check if we try to supply an empty value 14414 if test "x$CYGPATH" = x; then 14415 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CYGPATH= (no value)" >&5 14416 $as_echo "$as_me: Setting user supplied tool CYGPATH= (no value)" >&6;} 14417 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CYGPATH" >&5 14418 $as_echo_n "checking for CYGPATH... " >&6; } 14419 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 14420 $as_echo "disabled" >&6; } 14421 else 14422 # Check if the provided tool contains a complete path. 14423 tool_specified="$CYGPATH" 14424 tool_basename="${tool_specified##*/}" 14425 if test "x$tool_basename" = "x$tool_specified"; then 14426 # A command without a complete path is provided, search $PATH. 14427 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CYGPATH=$tool_basename" >&5 14428 $as_echo "$as_me: Will search for user supplied tool CYGPATH=$tool_basename" >&6;} 14429 # Extract the first word of "$tool_basename", so it can be a program name with args. 14430 set dummy $tool_basename; ac_word=$2 14431 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14432 $as_echo_n "checking for $ac_word... " >&6; } 14433 if ${ac_cv_path_CYGPATH+:} false; then : 14434 $as_echo_n "(cached) " >&6 14435 else 14436 case $CYGPATH in 14437 [\\/]* | ?:[\\/]*) 14438 ac_cv_path_CYGPATH="$CYGPATH" # Let the user override the test with a path. 14439 ;; 14440 *) 14441 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14442 for as_dir in $PATH 14443 do 14444 IFS=$as_save_IFS 14445 test -z "$as_dir" && as_dir=. 14446 for ac_exec_ext in '' $ac_executable_extensions; do 14447 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14448 ac_cv_path_CYGPATH="$as_dir/$ac_word$ac_exec_ext" 14449 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14450 break 2 14451 fi 14452 done 14453 done 14454 IFS=$as_save_IFS 14455 14456 ;; 14457 esac 14458 fi 14459 CYGPATH=$ac_cv_path_CYGPATH 14460 if test -n "$CYGPATH"; then 14461 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5 14462 $as_echo "$CYGPATH" >&6; } 14463 else 14464 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14465 $as_echo "no" >&6; } 14466 fi 14467 14468 14469 if test "x$CYGPATH" = x; then 14470 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 14471 fi 14472 else 14473 # Otherwise we believe it is a complete path. Use it as it is. 14474 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CYGPATH=$tool_specified" >&5 14475 $as_echo "$as_me: Will use user supplied tool CYGPATH=$tool_specified" >&6;} 14476 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CYGPATH" >&5 14477 $as_echo_n "checking for CYGPATH... " >&6; } 14478 if test ! -x "$tool_specified"; then 14479 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 14480 $as_echo "not found" >&6; } 14481 as_fn_error $? "User supplied tool CYGPATH=$tool_specified does not exist or is not executable" "$LINENO" 5 14482 fi 14483 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 14484 $as_echo "$tool_specified" >&6; } 14485 fi 14486 fi 14487 fi 14488 14489 fi 14490 14491 14492 14493 14494 # Publish this variable in the help. 14495 14496 14497 if [ -z "${READLINK+x}" ]; then 14498 # The variable is not set by user, try to locate tool using the code snippet 14499 for ac_prog in greadlink readlink 14500 do 14501 # Extract the first word of "$ac_prog", so it can be a program name with args. 14502 set dummy $ac_prog; ac_word=$2 14503 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14504 $as_echo_n "checking for $ac_word... " >&6; } 14505 if ${ac_cv_path_READLINK+:} false; then : 14506 $as_echo_n "(cached) " >&6 14507 else 14508 case $READLINK in 14509 [\\/]* | ?:[\\/]*) 14510 ac_cv_path_READLINK="$READLINK" # Let the user override the test with a path. 14511 ;; 14512 *) 14513 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14514 for as_dir in $PATH 14515 do 14516 IFS=$as_save_IFS 14517 test -z "$as_dir" && as_dir=. 14518 for ac_exec_ext in '' $ac_executable_extensions; do 14519 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14520 ac_cv_path_READLINK="$as_dir/$ac_word$ac_exec_ext" 14521 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14522 break 2 14523 fi 14524 done 14525 done 14526 IFS=$as_save_IFS 14527 14528 ;; 14529 esac 14530 fi 14531 READLINK=$ac_cv_path_READLINK 14532 if test -n "$READLINK"; then 14533 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINK" >&5 14534 $as_echo "$READLINK" >&6; } 14535 else 14536 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14537 $as_echo "no" >&6; } 14538 fi 14539 14540 14541 test -n "$READLINK" && break 14542 done 14543 14544 else 14545 # The variable is set, but is it from the command line or the environment? 14546 14547 # Try to remove the string !READLINK! from our list. 14548 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!READLINK!/} 14549 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 14550 # If it failed, the variable was not from the command line. Ignore it, 14551 # but warn the user (except for BASH, which is always set by the calling BASH). 14552 if test "xREADLINK" != xBASH; then 14553 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of READLINK from the environment. Use command line variables instead." >&5 14554 $as_echo "$as_me: WARNING: Ignoring value of READLINK from the environment. Use command line variables instead." >&2;} 14555 fi 14556 # Try to locate tool using the code snippet 14557 for ac_prog in greadlink readlink 14558 do 14559 # Extract the first word of "$ac_prog", so it can be a program name with args. 14560 set dummy $ac_prog; ac_word=$2 14561 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14562 $as_echo_n "checking for $ac_word... " >&6; } 14563 if ${ac_cv_path_READLINK+:} false; then : 14564 $as_echo_n "(cached) " >&6 14565 else 14566 case $READLINK in 14567 [\\/]* | ?:[\\/]*) 14568 ac_cv_path_READLINK="$READLINK" # Let the user override the test with a path. 14569 ;; 14570 *) 14571 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14572 for as_dir in $PATH 14573 do 14574 IFS=$as_save_IFS 14575 test -z "$as_dir" && as_dir=. 14576 for ac_exec_ext in '' $ac_executable_extensions; do 14577 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14578 ac_cv_path_READLINK="$as_dir/$ac_word$ac_exec_ext" 14579 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14580 break 2 14581 fi 14582 done 14583 done 14584 IFS=$as_save_IFS 14585 14586 ;; 14587 esac 14588 fi 14589 READLINK=$ac_cv_path_READLINK 14590 if test -n "$READLINK"; then 14591 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINK" >&5 14592 $as_echo "$READLINK" >&6; } 14593 else 14594 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14595 $as_echo "no" >&6; } 14596 fi 14597 14598 14599 test -n "$READLINK" && break 14600 done 14601 14602 else 14603 # If it succeeded, then it was overridden by the user. We will use it 14604 # for the tool. 14605 14606 # First remove it from the list of overridden variables, so we can test 14607 # for unknown variables in the end. 14608 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 14609 14610 # Check if we try to supply an empty value 14611 if test "x$READLINK" = x; then 14612 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool READLINK= (no value)" >&5 14613 $as_echo "$as_me: Setting user supplied tool READLINK= (no value)" >&6;} 14614 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READLINK" >&5 14615 $as_echo_n "checking for READLINK... " >&6; } 14616 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 14617 $as_echo "disabled" >&6; } 14618 else 14619 # Check if the provided tool contains a complete path. 14620 tool_specified="$READLINK" 14621 tool_basename="${tool_specified##*/}" 14622 if test "x$tool_basename" = "x$tool_specified"; then 14623 # A command without a complete path is provided, search $PATH. 14624 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool READLINK=$tool_basename" >&5 14625 $as_echo "$as_me: Will search for user supplied tool READLINK=$tool_basename" >&6;} 14626 # Extract the first word of "$tool_basename", so it can be a program name with args. 14627 set dummy $tool_basename; ac_word=$2 14628 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14629 $as_echo_n "checking for $ac_word... " >&6; } 14630 if ${ac_cv_path_READLINK+:} false; then : 14631 $as_echo_n "(cached) " >&6 14632 else 14633 case $READLINK in 14634 [\\/]* | ?:[\\/]*) 14635 ac_cv_path_READLINK="$READLINK" # Let the user override the test with a path. 14636 ;; 14637 *) 14638 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14639 for as_dir in $PATH 14640 do 14641 IFS=$as_save_IFS 14642 test -z "$as_dir" && as_dir=. 14643 for ac_exec_ext in '' $ac_executable_extensions; do 14644 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14645 ac_cv_path_READLINK="$as_dir/$ac_word$ac_exec_ext" 14646 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14647 break 2 14648 fi 14649 done 14650 done 14651 IFS=$as_save_IFS 14652 14653 ;; 14654 esac 14655 fi 14656 READLINK=$ac_cv_path_READLINK 14657 if test -n "$READLINK"; then 14658 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINK" >&5 14659 $as_echo "$READLINK" >&6; } 14660 else 14661 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14662 $as_echo "no" >&6; } 14663 fi 14664 14665 14666 if test "x$READLINK" = x; then 14667 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 14668 fi 14669 else 14670 # Otherwise we believe it is a complete path. Use it as it is. 14671 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool READLINK=$tool_specified" >&5 14672 $as_echo "$as_me: Will use user supplied tool READLINK=$tool_specified" >&6;} 14673 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READLINK" >&5 14674 $as_echo_n "checking for READLINK... " >&6; } 14675 if test ! -x "$tool_specified"; then 14676 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 14677 $as_echo "not found" >&6; } 14678 as_fn_error $? "User supplied tool READLINK=$tool_specified does not exist or is not executable" "$LINENO" 5 14679 fi 14680 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 14681 $as_echo "$tool_specified" >&6; } 14682 fi 14683 fi 14684 fi 14685 14686 fi 14687 14688 14689 14690 14691 # Publish this variable in the help. 14692 14693 14694 if [ -z "${DF+x}" ]; then 14695 # The variable is not set by user, try to locate tool using the code snippet 14696 for ac_prog in df 14697 do 14698 # Extract the first word of "$ac_prog", so it can be a program name with args. 14699 set dummy $ac_prog; ac_word=$2 14700 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14701 $as_echo_n "checking for $ac_word... " >&6; } 14702 if ${ac_cv_path_DF+:} false; then : 14703 $as_echo_n "(cached) " >&6 14704 else 14705 case $DF in 14706 [\\/]* | ?:[\\/]*) 14707 ac_cv_path_DF="$DF" # Let the user override the test with a path. 14708 ;; 14709 *) 14710 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14711 for as_dir in $PATH 14712 do 14713 IFS=$as_save_IFS 14714 test -z "$as_dir" && as_dir=. 14715 for ac_exec_ext in '' $ac_executable_extensions; do 14716 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14717 ac_cv_path_DF="$as_dir/$ac_word$ac_exec_ext" 14718 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14719 break 2 14720 fi 14721 done 14722 done 14723 IFS=$as_save_IFS 14724 14725 ;; 14726 esac 14727 fi 14728 DF=$ac_cv_path_DF 14729 if test -n "$DF"; then 14730 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DF" >&5 14731 $as_echo "$DF" >&6; } 14732 else 14733 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14734 $as_echo "no" >&6; } 14735 fi 14736 14737 14738 test -n "$DF" && break 14739 done 14740 14741 else 14742 # The variable is set, but is it from the command line or the environment? 14743 14744 # Try to remove the string !DF! from our list. 14745 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DF!/} 14746 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 14747 # If it failed, the variable was not from the command line. Ignore it, 14748 # but warn the user (except for BASH, which is always set by the calling BASH). 14749 if test "xDF" != xBASH; then 14750 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DF from the environment. Use command line variables instead." >&5 14751 $as_echo "$as_me: WARNING: Ignoring value of DF from the environment. Use command line variables instead." >&2;} 14752 fi 14753 # Try to locate tool using the code snippet 14754 for ac_prog in df 14755 do 14756 # Extract the first word of "$ac_prog", so it can be a program name with args. 14757 set dummy $ac_prog; ac_word=$2 14758 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14759 $as_echo_n "checking for $ac_word... " >&6; } 14760 if ${ac_cv_path_DF+:} false; then : 14761 $as_echo_n "(cached) " >&6 14762 else 14763 case $DF in 14764 [\\/]* | ?:[\\/]*) 14765 ac_cv_path_DF="$DF" # Let the user override the test with a path. 14766 ;; 14767 *) 14768 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14769 for as_dir in $PATH 14770 do 14771 IFS=$as_save_IFS 14772 test -z "$as_dir" && as_dir=. 14773 for ac_exec_ext in '' $ac_executable_extensions; do 14774 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14775 ac_cv_path_DF="$as_dir/$ac_word$ac_exec_ext" 14776 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14777 break 2 14778 fi 14779 done 14780 done 14781 IFS=$as_save_IFS 14782 14783 ;; 14784 esac 14785 fi 14786 DF=$ac_cv_path_DF 14787 if test -n "$DF"; then 14788 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DF" >&5 14789 $as_echo "$DF" >&6; } 14790 else 14791 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14792 $as_echo "no" >&6; } 14793 fi 14794 14795 14796 test -n "$DF" && break 14797 done 14798 14799 else 14800 # If it succeeded, then it was overridden by the user. We will use it 14801 # for the tool. 14802 14803 # First remove it from the list of overridden variables, so we can test 14804 # for unknown variables in the end. 14805 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 14806 14807 # Check if we try to supply an empty value 14808 if test "x$DF" = x; then 14809 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DF= (no value)" >&5 14810 $as_echo "$as_me: Setting user supplied tool DF= (no value)" >&6;} 14811 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DF" >&5 14812 $as_echo_n "checking for DF... " >&6; } 14813 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 14814 $as_echo "disabled" >&6; } 14815 else 14816 # Check if the provided tool contains a complete path. 14817 tool_specified="$DF" 14818 tool_basename="${tool_specified##*/}" 14819 if test "x$tool_basename" = "x$tool_specified"; then 14820 # A command without a complete path is provided, search $PATH. 14821 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DF=$tool_basename" >&5 14822 $as_echo "$as_me: Will search for user supplied tool DF=$tool_basename" >&6;} 14823 # Extract the first word of "$tool_basename", so it can be a program name with args. 14824 set dummy $tool_basename; ac_word=$2 14825 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14826 $as_echo_n "checking for $ac_word... " >&6; } 14827 if ${ac_cv_path_DF+:} false; then : 14828 $as_echo_n "(cached) " >&6 14829 else 14830 case $DF in 14831 [\\/]* | ?:[\\/]*) 14832 ac_cv_path_DF="$DF" # Let the user override the test with a path. 14833 ;; 14834 *) 14835 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14836 for as_dir in $PATH 14837 do 14838 IFS=$as_save_IFS 14839 test -z "$as_dir" && as_dir=. 14840 for ac_exec_ext in '' $ac_executable_extensions; do 14841 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14842 ac_cv_path_DF="$as_dir/$ac_word$ac_exec_ext" 14843 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14844 break 2 14845 fi 14846 done 14847 done 14848 IFS=$as_save_IFS 14849 14850 ;; 14851 esac 14852 fi 14853 DF=$ac_cv_path_DF 14854 if test -n "$DF"; then 14855 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DF" >&5 14856 $as_echo "$DF" >&6; } 14857 else 14858 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14859 $as_echo "no" >&6; } 14860 fi 14861 14862 14863 if test "x$DF" = x; then 14864 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 14865 fi 14866 else 14867 # Otherwise we believe it is a complete path. Use it as it is. 14868 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DF=$tool_specified" >&5 14869 $as_echo "$as_me: Will use user supplied tool DF=$tool_specified" >&6;} 14870 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DF" >&5 14871 $as_echo_n "checking for DF... " >&6; } 14872 if test ! -x "$tool_specified"; then 14873 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 14874 $as_echo "not found" >&6; } 14875 as_fn_error $? "User supplied tool DF=$tool_specified does not exist or is not executable" "$LINENO" 5 14876 fi 14877 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 14878 $as_echo "$tool_specified" >&6; } 14879 fi 14880 fi 14881 fi 14882 14883 fi 14884 14885 14886 14887 14888 # Publish this variable in the help. 14889 14890 14891 if [ -z "${CPIO+x}" ]; then 14892 # The variable is not set by user, try to locate tool using the code snippet 14893 for ac_prog in cpio bsdcpio 14894 do 14895 # Extract the first word of "$ac_prog", so it can be a program name with args. 14896 set dummy $ac_prog; ac_word=$2 14897 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14898 $as_echo_n "checking for $ac_word... " >&6; } 14899 if ${ac_cv_path_CPIO+:} false; then : 14900 $as_echo_n "(cached) " >&6 14901 else 14902 case $CPIO in 14903 [\\/]* | ?:[\\/]*) 14904 ac_cv_path_CPIO="$CPIO" # Let the user override the test with a path. 14905 ;; 14906 *) 14907 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14908 for as_dir in $PATH 14909 do 14910 IFS=$as_save_IFS 14911 test -z "$as_dir" && as_dir=. 14912 for ac_exec_ext in '' $ac_executable_extensions; do 14913 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14914 ac_cv_path_CPIO="$as_dir/$ac_word$ac_exec_ext" 14915 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14916 break 2 14917 fi 14918 done 14919 done 14920 IFS=$as_save_IFS 14921 14922 ;; 14923 esac 14924 fi 14925 CPIO=$ac_cv_path_CPIO 14926 if test -n "$CPIO"; then 14927 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPIO" >&5 14928 $as_echo "$CPIO" >&6; } 14929 else 14930 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14931 $as_echo "no" >&6; } 14932 fi 14933 14934 14935 test -n "$CPIO" && break 14936 done 14937 14938 else 14939 # The variable is set, but is it from the command line or the environment? 14940 14941 # Try to remove the string !CPIO! from our list. 14942 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CPIO!/} 14943 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 14944 # If it failed, the variable was not from the command line. Ignore it, 14945 # but warn the user (except for BASH, which is always set by the calling BASH). 14946 if test "xCPIO" != xBASH; then 14947 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CPIO from the environment. Use command line variables instead." >&5 14948 $as_echo "$as_me: WARNING: Ignoring value of CPIO from the environment. Use command line variables instead." >&2;} 14949 fi 14950 # Try to locate tool using the code snippet 14951 for ac_prog in cpio bsdcpio 14952 do 14953 # Extract the first word of "$ac_prog", so it can be a program name with args. 14954 set dummy $ac_prog; ac_word=$2 14955 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14956 $as_echo_n "checking for $ac_word... " >&6; } 14957 if ${ac_cv_path_CPIO+:} false; then : 14958 $as_echo_n "(cached) " >&6 14959 else 14960 case $CPIO in 14961 [\\/]* | ?:[\\/]*) 14962 ac_cv_path_CPIO="$CPIO" # Let the user override the test with a path. 14963 ;; 14964 *) 14965 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14966 for as_dir in $PATH 14967 do 14968 IFS=$as_save_IFS 14969 test -z "$as_dir" && as_dir=. 14970 for ac_exec_ext in '' $ac_executable_extensions; do 14971 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14972 ac_cv_path_CPIO="$as_dir/$ac_word$ac_exec_ext" 14973 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14974 break 2 14975 fi 14976 done 14977 done 14978 IFS=$as_save_IFS 14979 14980 ;; 14981 esac 14982 fi 14983 CPIO=$ac_cv_path_CPIO 14984 if test -n "$CPIO"; then 14985 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPIO" >&5 14986 $as_echo "$CPIO" >&6; } 14987 else 14988 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14989 $as_echo "no" >&6; } 14990 fi 14991 14992 14993 test -n "$CPIO" && break 14994 done 14995 14996 else 14997 # If it succeeded, then it was overridden by the user. We will use it 14998 # for the tool. 14999 15000 # First remove it from the list of overridden variables, so we can test 15001 # for unknown variables in the end. 15002 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 15003 15004 # Check if we try to supply an empty value 15005 if test "x$CPIO" = x; then 15006 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CPIO= (no value)" >&5 15007 $as_echo "$as_me: Setting user supplied tool CPIO= (no value)" >&6;} 15008 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CPIO" >&5 15009 $as_echo_n "checking for CPIO... " >&6; } 15010 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 15011 $as_echo "disabled" >&6; } 15012 else 15013 # Check if the provided tool contains a complete path. 15014 tool_specified="$CPIO" 15015 tool_basename="${tool_specified##*/}" 15016 if test "x$tool_basename" = "x$tool_specified"; then 15017 # A command without a complete path is provided, search $PATH. 15018 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CPIO=$tool_basename" >&5 15019 $as_echo "$as_me: Will search for user supplied tool CPIO=$tool_basename" >&6;} 15020 # Extract the first word of "$tool_basename", so it can be a program name with args. 15021 set dummy $tool_basename; ac_word=$2 15022 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15023 $as_echo_n "checking for $ac_word... " >&6; } 15024 if ${ac_cv_path_CPIO+:} false; then : 15025 $as_echo_n "(cached) " >&6 15026 else 15027 case $CPIO in 15028 [\\/]* | ?:[\\/]*) 15029 ac_cv_path_CPIO="$CPIO" # Let the user override the test with a path. 15030 ;; 15031 *) 15032 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15033 for as_dir in $PATH 15034 do 15035 IFS=$as_save_IFS 15036 test -z "$as_dir" && as_dir=. 15037 for ac_exec_ext in '' $ac_executable_extensions; do 15038 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15039 ac_cv_path_CPIO="$as_dir/$ac_word$ac_exec_ext" 15040 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15041 break 2 15042 fi 15043 done 15044 done 15045 IFS=$as_save_IFS 15046 15047 ;; 15048 esac 15049 fi 15050 CPIO=$ac_cv_path_CPIO 15051 if test -n "$CPIO"; then 15052 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPIO" >&5 15053 $as_echo "$CPIO" >&6; } 15054 else 15055 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15056 $as_echo "no" >&6; } 15057 fi 15058 15059 15060 if test "x$CPIO" = x; then 15061 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 15062 fi 15063 else 15064 # Otherwise we believe it is a complete path. Use it as it is. 15065 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CPIO=$tool_specified" >&5 15066 $as_echo "$as_me: Will use user supplied tool CPIO=$tool_specified" >&6;} 15067 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CPIO" >&5 15068 $as_echo_n "checking for CPIO... " >&6; } 15069 if test ! -x "$tool_specified"; then 15070 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 15071 $as_echo "not found" >&6; } 15072 as_fn_error $? "User supplied tool CPIO=$tool_specified does not exist or is not executable" "$LINENO" 5 15073 fi 15074 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 15075 $as_echo "$tool_specified" >&6; } 15076 fi 15077 fi 15078 fi 15079 15080 fi 15081 15082 15083 15084 15085 # Publish this variable in the help. 15086 15087 15088 if [ -z "${NICE+x}" ]; then 15089 # The variable is not set by user, try to locate tool using the code snippet 15090 for ac_prog in nice 15091 do 15092 # Extract the first word of "$ac_prog", so it can be a program name with args. 15093 set dummy $ac_prog; ac_word=$2 15094 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15095 $as_echo_n "checking for $ac_word... " >&6; } 15096 if ${ac_cv_path_NICE+:} false; then : 15097 $as_echo_n "(cached) " >&6 15098 else 15099 case $NICE in 15100 [\\/]* | ?:[\\/]*) 15101 ac_cv_path_NICE="$NICE" # Let the user override the test with a path. 15102 ;; 15103 *) 15104 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15105 for as_dir in $PATH 15106 do 15107 IFS=$as_save_IFS 15108 test -z "$as_dir" && as_dir=. 15109 for ac_exec_ext in '' $ac_executable_extensions; do 15110 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15111 ac_cv_path_NICE="$as_dir/$ac_word$ac_exec_ext" 15112 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15113 break 2 15114 fi 15115 done 15116 done 15117 IFS=$as_save_IFS 15118 15119 ;; 15120 esac 15121 fi 15122 NICE=$ac_cv_path_NICE 15123 if test -n "$NICE"; then 15124 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NICE" >&5 15125 $as_echo "$NICE" >&6; } 15126 else 15127 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15128 $as_echo "no" >&6; } 15129 fi 15130 15131 15132 test -n "$NICE" && break 15133 done 15134 15135 else 15136 # The variable is set, but is it from the command line or the environment? 15137 15138 # Try to remove the string !NICE! from our list. 15139 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NICE!/} 15140 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 15141 # If it failed, the variable was not from the command line. Ignore it, 15142 # but warn the user (except for BASH, which is always set by the calling BASH). 15143 if test "xNICE" != xBASH; then 15144 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NICE from the environment. Use command line variables instead." >&5 15145 $as_echo "$as_me: WARNING: Ignoring value of NICE from the environment. Use command line variables instead." >&2;} 15146 fi 15147 # Try to locate tool using the code snippet 15148 for ac_prog in nice 15149 do 15150 # Extract the first word of "$ac_prog", so it can be a program name with args. 15151 set dummy $ac_prog; ac_word=$2 15152 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15153 $as_echo_n "checking for $ac_word... " >&6; } 15154 if ${ac_cv_path_NICE+:} false; then : 15155 $as_echo_n "(cached) " >&6 15156 else 15157 case $NICE in 15158 [\\/]* | ?:[\\/]*) 15159 ac_cv_path_NICE="$NICE" # Let the user override the test with a path. 15160 ;; 15161 *) 15162 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15163 for as_dir in $PATH 15164 do 15165 IFS=$as_save_IFS 15166 test -z "$as_dir" && as_dir=. 15167 for ac_exec_ext in '' $ac_executable_extensions; do 15168 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15169 ac_cv_path_NICE="$as_dir/$ac_word$ac_exec_ext" 15170 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15171 break 2 15172 fi 15173 done 15174 done 15175 IFS=$as_save_IFS 15176 15177 ;; 15178 esac 15179 fi 15180 NICE=$ac_cv_path_NICE 15181 if test -n "$NICE"; then 15182 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NICE" >&5 15183 $as_echo "$NICE" >&6; } 15184 else 15185 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15186 $as_echo "no" >&6; } 15187 fi 15188 15189 15190 test -n "$NICE" && break 15191 done 15192 15193 else 15194 # If it succeeded, then it was overridden by the user. We will use it 15195 # for the tool. 15196 15197 # First remove it from the list of overridden variables, so we can test 15198 # for unknown variables in the end. 15199 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 15200 15201 # Check if we try to supply an empty value 15202 if test "x$NICE" = x; then 15203 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool NICE= (no value)" >&5 15204 $as_echo "$as_me: Setting user supplied tool NICE= (no value)" >&6;} 15205 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NICE" >&5 15206 $as_echo_n "checking for NICE... " >&6; } 15207 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 15208 $as_echo "disabled" >&6; } 15209 else 15210 # Check if the provided tool contains a complete path. 15211 tool_specified="$NICE" 15212 tool_basename="${tool_specified##*/}" 15213 if test "x$tool_basename" = "x$tool_specified"; then 15214 # A command without a complete path is provided, search $PATH. 15215 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NICE=$tool_basename" >&5 15216 $as_echo "$as_me: Will search for user supplied tool NICE=$tool_basename" >&6;} 15217 # Extract the first word of "$tool_basename", so it can be a program name with args. 15218 set dummy $tool_basename; ac_word=$2 15219 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 15220 $as_echo_n "checking for $ac_word... " >&6; } 15221 if ${ac_cv_path_NICE+:} false; then : 15222 $as_echo_n "(cached) " >&6 15223 else 15224 case $NICE in 15225 [\\/]* | ?:[\\/]*) 15226 ac_cv_path_NICE="$NICE" # Let the user override the test with a path. 15227 ;; 15228 *) 15229 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 15230 for as_dir in $PATH 15231 do 15232 IFS=$as_save_IFS 15233 test -z "$as_dir" && as_dir=. 15234 for ac_exec_ext in '' $ac_executable_extensions; do 15235 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 15236 ac_cv_path_NICE="$as_dir/$ac_word$ac_exec_ext" 15237 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 15238 break 2 15239 fi 15240 done 15241 done 15242 IFS=$as_save_IFS 15243 15244 ;; 15245 esac 15246 fi 15247 NICE=$ac_cv_path_NICE 15248 if test -n "$NICE"; then 15249 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NICE" >&5 15250 $as_echo "$NICE" >&6; } 15251 else 15252 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 15253 $as_echo "no" >&6; } 15254 fi 15255 15256 15257 if test "x$NICE" = x; then 15258 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 15259 fi 15260 else 15261 # Otherwise we believe it is a complete path. Use it as it is. 15262 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NICE=$tool_specified" >&5 15263 $as_echo "$as_me: Will use user supplied tool NICE=$tool_specified" >&6;} 15264 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NICE" >&5 15265 $as_echo_n "checking for NICE... " >&6; } 15266 if test ! -x "$tool_specified"; then 15267 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 15268 $as_echo "not found" >&6; } 15269 as_fn_error $? "User supplied tool NICE=$tool_specified does not exist or is not executable" "$LINENO" 5 15270 fi 15271 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 15272 $as_echo "$tool_specified" >&6; } 15273 fi 15274 fi 15275 fi 15276 15277 fi 15278 15279 15280 15281 15282 # Now we can determine OpenJDK build and target platforms. This is required to 15283 # have early on. 15284 # Make sure we can run config.sub. 15285 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || 15286 as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5 15287 15288 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5 15289 $as_echo_n "checking build system type... " >&6; } 15290 if ${ac_cv_build+:} false; then : 15291 $as_echo_n "(cached) " >&6 15292 else 15293 ac_build_alias=$build_alias 15294 test "x$ac_build_alias" = x && 15295 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"` 15296 test "x$ac_build_alias" = x && 15297 as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5 15298 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` || 15299 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5 15300 15301 fi 15302 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5 15303 $as_echo "$ac_cv_build" >&6; } 15304 case $ac_cv_build in 15305 *-*-*) ;; 15306 *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;; 15307 esac 15308 build=$ac_cv_build 15309 ac_save_IFS=$IFS; IFS='-' 15310 set x $ac_cv_build 15311 shift 15312 build_cpu=$1 15313 build_vendor=$2 15314 shift; shift 15315 # Remember, the first character of IFS is used to create $*, 15316 # except with old shells: 15317 build_os=$* 15318 IFS=$ac_save_IFS 15319 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac 15320 15321 15322 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5 15323 $as_echo_n "checking host system type... " >&6; } 15324 if ${ac_cv_host+:} false; then : 15325 $as_echo_n "(cached) " >&6 15326 else 15327 if test "x$host_alias" = x; then 15328 ac_cv_host=$ac_cv_build 15329 else 15330 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` || 15331 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5 15332 fi 15333 15334 fi 15335 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5 15336 $as_echo "$ac_cv_host" >&6; } 15337 case $ac_cv_host in 15338 *-*-*) ;; 15339 *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;; 15340 esac 15341 host=$ac_cv_host 15342 ac_save_IFS=$IFS; IFS='-' 15343 set x $ac_cv_host 15344 shift 15345 host_cpu=$1 15346 host_vendor=$2 15347 shift; shift 15348 # Remember, the first character of IFS is used to create $*, 15349 # except with old shells: 15350 host_os=$* 15351 IFS=$ac_save_IFS 15352 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac 15353 15354 15355 { $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5 15356 $as_echo_n "checking target system type... " >&6; } 15357 if ${ac_cv_target+:} false; then : 15358 $as_echo_n "(cached) " >&6 15359 else 15360 if test "x$target_alias" = x; then 15361 ac_cv_target=$ac_cv_host 15362 else 15363 ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` || 15364 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5 15365 fi 15366 15367 fi 15368 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5 15369 $as_echo "$ac_cv_target" >&6; } 15370 case $ac_cv_target in 15371 *-*-*) ;; 15372 *) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;; 15373 esac 15374 target=$ac_cv_target 15375 ac_save_IFS=$IFS; IFS='-' 15376 set x $ac_cv_target 15377 shift 15378 target_cpu=$1 15379 target_vendor=$2 15380 shift; shift 15381 # Remember, the first character of IFS is used to create $*, 15382 # except with old shells: 15383 target_os=$* 15384 IFS=$ac_save_IFS 15385 case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac 15386 15387 15388 # The aliases save the names the user supplied, while $host etc. 15389 # will get canonicalized. 15390 test -n "$target_alias" && 15391 test "$program_prefix$program_suffix$program_transform_name" = \ 15392 NONENONEs,x,x, && 15393 program_prefix=${target_alias}- 15394 15395 # Figure out the build and target systems. # Note that in autoconf terminology, "build" is obvious, but "target" 15396 # is confusing; it assumes you are cross-compiling a cross-compiler (!) and "target" is thus the target of the 15397 # product you're building. The target of this build is called "host". Since this is confusing to most people, we 15398 # have not adopted that system, but use "target" as the platform we are building for. In some places though we need 15399 # to use the configure naming style. 15400 15401 15402 15403 15404 15405 # Copy the autoconf trip/quadruplet verbatim to OPENJDK_TARGET_AUTOCONF_NAME 15406 # (from the autoconf "host") and OPENJDK_BUILD_AUTOCONF_NAME 15407 # Note that we might later on rewrite e.g. OPENJDK_TARGET_CPU due to reduced build, 15408 # but this will not change the value of OPENJDK_TARGET_AUTOCONF_NAME. 15409 OPENJDK_TARGET_AUTOCONF_NAME="$host" 15410 OPENJDK_BUILD_AUTOCONF_NAME="$build" 15411 15412 15413 15414 # Convert the autoconf OS/CPU value to our own data, into the VAR_OS/CPU variables. 15415 15416 case "$build_os" in 15417 *linux*) 15418 VAR_OS=linux 15419 VAR_OS_TYPE=unix 15420 ;; 15421 *solaris*) 15422 VAR_OS=solaris 15423 VAR_OS_TYPE=unix 15424 ;; 15425 *darwin*) 15426 VAR_OS=macosx 15427 VAR_OS_TYPE=unix 15428 ;; 15429 *bsd*) 15430 VAR_OS=bsd 15431 VAR_OS_TYPE=unix 15432 ;; 15433 *cygwin*) 15434 VAR_OS=windows 15435 VAR_OS_ENV=windows.cygwin 15436 ;; 15437 *mingw*) 15438 VAR_OS=windows 15439 VAR_OS_ENV=windows.msys 15440 ;; 15441 *aix*) 15442 VAR_OS=aix 15443 VAR_OS_TYPE=unix 15444 ;; 15445 *) 15446 as_fn_error $? "unsupported operating system $build_os" "$LINENO" 5 15447 ;; 15448 esac 15449 15450 15451 # First argument is the cpu name from the trip/quad 15452 case "$build_cpu" in 15453 x86_64) 15454 VAR_CPU=x86_64 15455 VAR_CPU_ARCH=x86 15456 VAR_CPU_BITS=64 15457 VAR_CPU_ENDIAN=little 15458 ;; 15459 i?86) 15460 VAR_CPU=x86 15461 VAR_CPU_ARCH=x86 15462 VAR_CPU_BITS=32 15463 VAR_CPU_ENDIAN=little 15464 ;; 15465 arm*) 15466 VAR_CPU=arm 15467 VAR_CPU_ARCH=arm 15468 VAR_CPU_BITS=32 15469 VAR_CPU_ENDIAN=little 15470 ;; 15471 aarch64) 15472 VAR_CPU=aarch64 15473 VAR_CPU_ARCH=aarch64 15474 VAR_CPU_BITS=64 15475 VAR_CPU_ENDIAN=little 15476 ;; 15477 powerpc) 15478 VAR_CPU=ppc 15479 VAR_CPU_ARCH=ppc 15480 VAR_CPU_BITS=32 15481 VAR_CPU_ENDIAN=big 15482 ;; 15483 powerpc64) 15484 VAR_CPU=ppc64 15485 VAR_CPU_ARCH=ppc 15486 VAR_CPU_BITS=64 15487 VAR_CPU_ENDIAN=big 15488 ;; 15489 powerpc64le) 15490 VAR_CPU=ppc64le 15491 VAR_CPU_ARCH=ppc 15492 VAR_CPU_BITS=64 15493 VAR_CPU_ENDIAN=little 15494 ;; 15495 s390) 15496 VAR_CPU=s390 15497 VAR_CPU_ARCH=s390 15498 VAR_CPU_BITS=32 15499 VAR_CPU_ENDIAN=big 15500 ;; 15501 s390x) 15502 VAR_CPU=s390x 15503 VAR_CPU_ARCH=s390 15504 VAR_CPU_BITS=64 15505 VAR_CPU_ENDIAN=big 15506 ;; 15507 sparc) 15508 VAR_CPU=sparc 15509 VAR_CPU_ARCH=sparc 15510 VAR_CPU_BITS=32 15511 VAR_CPU_ENDIAN=big 15512 ;; 15513 sparcv9|sparc64) 15514 VAR_CPU=sparcv9 15515 VAR_CPU_ARCH=sparc 15516 VAR_CPU_BITS=64 15517 VAR_CPU_ENDIAN=big 15518 ;; 15519 *) 15520 as_fn_error $? "unsupported cpu $build_cpu" "$LINENO" 5 15521 ;; 15522 esac 15523 15524 # ..and setup our own variables. (Do this explicitely to facilitate searching) 15525 OPENJDK_BUILD_OS="$VAR_OS" 15526 if test "x$VAR_OS_TYPE" != x; then 15527 OPENJDK_BUILD_OS_TYPE="$VAR_OS_TYPE" 15528 else 15529 OPENJDK_BUILD_OS_TYPE="$VAR_OS" 15530 fi 15531 if test "x$VAR_OS_ENV" != x; then 15532 OPENJDK_BUILD_OS_ENV="$VAR_OS_ENV" 15533 else 15534 OPENJDK_BUILD_OS_ENV="$VAR_OS" 15535 fi 15536 OPENJDK_BUILD_CPU="$VAR_CPU" 15537 OPENJDK_BUILD_CPU_ARCH="$VAR_CPU_ARCH" 15538 OPENJDK_BUILD_CPU_BITS="$VAR_CPU_BITS" 15539 OPENJDK_BUILD_CPU_ENDIAN="$VAR_CPU_ENDIAN" 15540 15541 15542 15543 15544 15545 15546 15547 15548 { $as_echo "$as_me:${as_lineno-$LINENO}: checking openjdk-build os-cpu" >&5 15549 $as_echo_n "checking openjdk-build os-cpu... " >&6; } 15550 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_BUILD_OS-$OPENJDK_BUILD_CPU" >&5 15551 $as_echo "$OPENJDK_BUILD_OS-$OPENJDK_BUILD_CPU" >&6; } 15552 15553 # Convert the autoconf OS/CPU value to our own data, into the VAR_OS/CPU variables. 15554 15555 case "$host_os" in 15556 *linux*) 15557 VAR_OS=linux 15558 VAR_OS_TYPE=unix 15559 ;; 15560 *solaris*) 15561 VAR_OS=solaris 15562 VAR_OS_TYPE=unix 15563 ;; 15564 *darwin*) 15565 VAR_OS=macosx 15566 VAR_OS_TYPE=unix 15567 ;; 15568 *bsd*) 15569 VAR_OS=bsd 15570 VAR_OS_TYPE=unix 15571 ;; 15572 *cygwin*) 15573 VAR_OS=windows 15574 VAR_OS_ENV=windows.cygwin 15575 ;; 15576 *mingw*) 15577 VAR_OS=windows 15578 VAR_OS_ENV=windows.msys 15579 ;; 15580 *aix*) 15581 VAR_OS=aix 15582 VAR_OS_TYPE=unix 15583 ;; 15584 *) 15585 as_fn_error $? "unsupported operating system $host_os" "$LINENO" 5 15586 ;; 15587 esac 15588 15589 15590 # First argument is the cpu name from the trip/quad 15591 case "$host_cpu" in 15592 x86_64) 15593 VAR_CPU=x86_64 15594 VAR_CPU_ARCH=x86 15595 VAR_CPU_BITS=64 15596 VAR_CPU_ENDIAN=little 15597 ;; 15598 i?86) 15599 VAR_CPU=x86 15600 VAR_CPU_ARCH=x86 15601 VAR_CPU_BITS=32 15602 VAR_CPU_ENDIAN=little 15603 ;; 15604 arm*) 15605 VAR_CPU=arm 15606 VAR_CPU_ARCH=arm 15607 VAR_CPU_BITS=32 15608 VAR_CPU_ENDIAN=little 15609 ;; 15610 aarch64) 15611 VAR_CPU=aarch64 15612 VAR_CPU_ARCH=aarch64 15613 VAR_CPU_BITS=64 15614 VAR_CPU_ENDIAN=little 15615 ;; 15616 powerpc) 15617 VAR_CPU=ppc 15618 VAR_CPU_ARCH=ppc 15619 VAR_CPU_BITS=32 15620 VAR_CPU_ENDIAN=big 15621 ;; 15622 powerpc64) 15623 VAR_CPU=ppc64 15624 VAR_CPU_ARCH=ppc 15625 VAR_CPU_BITS=64 15626 VAR_CPU_ENDIAN=big 15627 ;; 15628 powerpc64le) 15629 VAR_CPU=ppc64le 15630 VAR_CPU_ARCH=ppc 15631 VAR_CPU_BITS=64 15632 VAR_CPU_ENDIAN=little 15633 ;; 15634 s390) 15635 VAR_CPU=s390 15636 VAR_CPU_ARCH=s390 15637 VAR_CPU_BITS=32 15638 VAR_CPU_ENDIAN=big 15639 ;; 15640 s390x) 15641 VAR_CPU=s390x 15642 VAR_CPU_ARCH=s390 15643 VAR_CPU_BITS=64 15644 VAR_CPU_ENDIAN=big 15645 ;; 15646 sparc) 15647 VAR_CPU=sparc 15648 VAR_CPU_ARCH=sparc 15649 VAR_CPU_BITS=32 15650 VAR_CPU_ENDIAN=big 15651 ;; 15652 sparcv9|sparc64) 15653 VAR_CPU=sparcv9 15654 VAR_CPU_ARCH=sparc 15655 VAR_CPU_BITS=64 15656 VAR_CPU_ENDIAN=big 15657 ;; 15658 *) 15659 as_fn_error $? "unsupported cpu $host_cpu" "$LINENO" 5 15660 ;; 15661 esac 15662 15663 # ... and setup our own variables. (Do this explicitely to facilitate searching) 15664 OPENJDK_TARGET_OS="$VAR_OS" 15665 if test "x$VAR_OS_TYPE" != x; then 15666 OPENJDK_TARGET_OS_TYPE="$VAR_OS_TYPE" 15667 else 15668 OPENJDK_TARGET_OS_TYPE="$VAR_OS" 15669 fi 15670 if test "x$VAR_OS_ENV" != x; then 15671 OPENJDK_TARGET_OS_ENV="$VAR_OS_ENV" 15672 else 15673 OPENJDK_TARGET_OS_ENV="$VAR_OS" 15674 fi 15675 OPENJDK_TARGET_CPU="$VAR_CPU" 15676 OPENJDK_TARGET_CPU_ARCH="$VAR_CPU_ARCH" 15677 OPENJDK_TARGET_CPU_BITS="$VAR_CPU_BITS" 15678 OPENJDK_TARGET_CPU_ENDIAN="$VAR_CPU_ENDIAN" 15679 15680 15681 15682 15683 15684 15685 15686 15687 { $as_echo "$as_me:${as_lineno-$LINENO}: checking openjdk-target os-cpu" >&5 15688 $as_echo_n "checking openjdk-target os-cpu... " >&6; } 15689 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" >&5 15690 $as_echo "$OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" >&6; } 15691 15692 15693 15694 # Check whether --with-target-bits was given. 15695 if test "${with_target_bits+set}" = set; then : 15696 withval=$with_target_bits; 15697 fi 15698 15699 15700 # We have three types of compiles: 15701 # native == normal compilation, target system == build system 15702 # cross == traditional cross compilation, target system != build system; special toolchain needed 15703 # reduced == using native compilers, but with special flags (e.g. -m32) to produce 32-bit builds on 64-bit machines 15704 # 15705 if test "x$OPENJDK_BUILD_AUTOCONF_NAME" != "x$OPENJDK_TARGET_AUTOCONF_NAME"; then 15706 # We're doing a proper cross-compilation 15707 COMPILE_TYPE="cross" 15708 else 15709 COMPILE_TYPE="native" 15710 fi 15711 15712 if test "x$with_target_bits" != x; then 15713 if test "x$COMPILE_TYPE" = "xcross"; then 15714 as_fn_error $? "It is not possible to combine --with-target-bits=X and proper cross-compilation. Choose either." "$LINENO" 5 15715 fi 15716 15717 if test "x$with_target_bits" = x32 && test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 15718 # A reduced build is requested 15719 COMPILE_TYPE="reduced" 15720 OPENJDK_TARGET_CPU_BITS=32 15721 if test "x$OPENJDK_TARGET_CPU_ARCH" = "xx86"; then 15722 OPENJDK_TARGET_CPU=x86 15723 elif test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then 15724 OPENJDK_TARGET_CPU=sparc 15725 else 15726 as_fn_error $? "Reduced build (--with-target-bits=32) is only supported on x86_64 and sparcv9" "$LINENO" 5 15727 fi 15728 elif test "x$with_target_bits" = x64 && test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 15729 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 15730 elif test "x$with_target_bits" = "x$OPENJDK_TARGET_CPU_BITS"; then 15731 { $as_echo "$as_me:${as_lineno-$LINENO}: --with-target-bits are set to build platform address size; argument has no meaning" >&5 15732 $as_echo "$as_me: --with-target-bits are set to build platform address size; argument has no meaning" >&6;} 15733 else 15734 as_fn_error $? "--with-target-bits can only be 32 or 64, you specified $with_target_bits!" "$LINENO" 5 15735 fi 15736 fi 15737 15738 15739 { $as_echo "$as_me:${as_lineno-$LINENO}: checking compilation type" >&5 15740 $as_echo_n "checking compilation type... " >&6; } 15741 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMPILE_TYPE" >&5 15742 $as_echo "$COMPILE_TYPE" >&6; } 15743 15744 15745 if test "x$OPENJDK_TARGET_OS" = "xsolaris"; then 15746 REQUIRED_OS_NAME=SunOS 15747 REQUIRED_OS_VERSION=5.10 15748 fi 15749 if test "x$OPENJDK_TARGET_OS" = "xlinux"; then 15750 REQUIRED_OS_NAME=Linux 15751 REQUIRED_OS_VERSION=2.6 15752 fi 15753 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 15754 REQUIRED_OS_NAME=Windows 15755 if test "x$OPENJDK_TARGET_CPU_BITS" = "x64"; then 15756 REQUIRED_OS_VERSION=5.2 15757 else 15758 REQUIRED_OS_VERSION=5.1 15759 fi 15760 fi 15761 if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then 15762 REQUIRED_OS_NAME=Darwin 15763 REQUIRED_OS_VERSION=11.2 15764 fi 15765 if test "x$OPENJDK_TARGET_OS" = "xaix"; then 15766 REQUIRED_OS_NAME=AIX 15767 REQUIRED_OS_VERSION=7.1 15768 fi 15769 15770 15771 15772 15773 15774 15775 # Also store the legacy naming of the cpu. 15776 # Ie i586 and amd64 instead of x86 and x86_64 15777 OPENJDK_TARGET_CPU_LEGACY="$OPENJDK_TARGET_CPU" 15778 if test "x$OPENJDK_TARGET_CPU" = xx86; then 15779 OPENJDK_TARGET_CPU_LEGACY="i586" 15780 elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then 15781 # On all platforms except MacOSX replace x86_64 with amd64. 15782 OPENJDK_TARGET_CPU_LEGACY="amd64" 15783 fi 15784 15785 15786 # And the second legacy naming of the cpu. 15787 # Ie i386 and amd64 instead of x86 and x86_64. 15788 OPENJDK_TARGET_CPU_LEGACY_LIB="$OPENJDK_TARGET_CPU" 15789 if test "x$OPENJDK_TARGET_CPU" = xx86; then 15790 OPENJDK_TARGET_CPU_LEGACY_LIB="i386" 15791 elif test "x$OPENJDK_TARGET_CPU" = xx86_64; then 15792 OPENJDK_TARGET_CPU_LEGACY_LIB="amd64" 15793 fi 15794 15795 15796 # This is the name of the cpu (but using i386 and amd64 instead of 15797 # x86 and x86_64, respectively), preceeded by a /, to be used when 15798 # locating libraries. On macosx, it's empty, though. 15799 OPENJDK_TARGET_CPU_LIBDIR="/$OPENJDK_TARGET_CPU_LEGACY_LIB" 15800 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 15801 OPENJDK_TARGET_CPU_LIBDIR="" 15802 fi 15803 15804 15805 # OPENJDK_TARGET_CPU_ISADIR is normally empty. On 64-bit Solaris systems, it is set to 15806 # /amd64 or /sparcv9. This string is appended to some library paths, like this: 15807 # /usr/lib${OPENJDK_TARGET_CPU_ISADIR}/libexample.so 15808 OPENJDK_TARGET_CPU_ISADIR="" 15809 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 15810 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 15811 OPENJDK_TARGET_CPU_ISADIR="/amd64" 15812 elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then 15813 OPENJDK_TARGET_CPU_ISADIR="/sparcv9" 15814 fi 15815 fi 15816 15817 15818 # Setup OPENJDK_TARGET_CPU_OSARCH, which is used to set the os.arch Java system property 15819 OPENJDK_TARGET_CPU_OSARCH="$OPENJDK_TARGET_CPU" 15820 if test "x$OPENJDK_TARGET_OS" = xlinux && test "x$OPENJDK_TARGET_CPU" = xx86; then 15821 # On linux only, we replace x86 with i386. 15822 OPENJDK_TARGET_CPU_OSARCH="i386" 15823 elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then 15824 # On all platforms except macosx, we replace x86_64 with amd64. 15825 OPENJDK_TARGET_CPU_OSARCH="amd64" 15826 fi 15827 15828 15829 OPENJDK_TARGET_CPU_JLI="$OPENJDK_TARGET_CPU" 15830 if test "x$OPENJDK_TARGET_CPU" = xx86; then 15831 OPENJDK_TARGET_CPU_JLI="i386" 15832 elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then 15833 # On all platforms except macosx, we replace x86_64 with amd64. 15834 OPENJDK_TARGET_CPU_JLI="amd64" 15835 fi 15836 # Now setup the -D flags for building libjli. 15837 OPENJDK_TARGET_CPU_JLI_CFLAGS="-DLIBARCHNAME='\"$OPENJDK_TARGET_CPU_JLI\"'" 15838 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 15839 if test "x$OPENJDK_TARGET_CPU_ARCH" = xsparc; then 15840 OPENJDK_TARGET_CPU_JLI_CFLAGS="$OPENJDK_TARGET_CPU_JLI_CFLAGS -DLIBARCH32NAME='\"sparc\"' -DLIBARCH64NAME='\"sparcv9\"'" 15841 elif test "x$OPENJDK_TARGET_CPU_ARCH" = xx86; then 15842 OPENJDK_TARGET_CPU_JLI_CFLAGS="$OPENJDK_TARGET_CPU_JLI_CFLAGS -DLIBARCH32NAME='\"i386\"' -DLIBARCH64NAME='\"amd64\"'" 15843 fi 15844 fi 15845 15846 15847 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 15848 OPENJDK_TARGET_OS_EXPORT_DIR=macosx 15849 else 15850 OPENJDK_TARGET_OS_EXPORT_DIR=${OPENJDK_TARGET_OS_TYPE} 15851 fi 15852 15853 15854 # The new version string in JDK 9 also defined new naming of OS and ARCH for bundles 15855 # Macosx is osx and x86_64 is x64 15856 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 15857 OPENJDK_TARGET_OS_BUNDLE="osx" 15858 else 15859 OPENJDK_TARGET_OS_BUNDLE="$OPENJDK_TARGET_OS" 15860 fi 15861 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 15862 OPENJDK_TARGET_CPU_BUNDLE="x64" 15863 else 15864 OPENJDK_TARGET_CPU_BUNDLE="$OPENJDK_TARGET_CPU" 15865 fi 15866 OPENJDK_TARGET_BUNDLE_PLATFORM="${OPENJDK_TARGET_OS_BUNDLE}-${OPENJDK_TARGET_CPU_BUNDLE}" 15867 15868 15869 15870 15871 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 15872 A_LP64="LP64:=" 15873 # -D_LP64=1 is only set on linux and mac. Setting on windows causes diff in 15874 # unpack200.exe 15875 if test "x$OPENJDK_TARGET_OS" = xlinux || test "x$OPENJDK_TARGET_OS" = xmacosx; then 15876 OPENJDK_TARGET_ADD_LP64="-D_LP64=1" 15877 fi 15878 fi 15879 LP64=$A_LP64 15880 15881 15882 if test "x$COMPILE_TYPE" = "xcross"; then 15883 # FIXME: ... or should this include reduced builds..? 15884 DEFINE_CROSS_COMPILE_ARCH="CROSS_COMPILE_ARCH:=$OPENJDK_TARGET_CPU_LEGACY" 15885 else 15886 DEFINE_CROSS_COMPILE_ARCH="" 15887 fi 15888 15889 15890 # Convert openjdk platform names to hotspot names 15891 15892 HOTSPOT_TARGET_OS=${OPENJDK_TARGET_OS} 15893 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 15894 HOTSPOT_TARGET_OS=bsd 15895 fi 15896 15897 15898 HOTSPOT_TARGET_OS_TYPE=${OPENJDK_TARGET_OS_TYPE} 15899 if test "x$OPENJDK_TARGET_OS_TYPE" = xunix; then 15900 HOTSPOT_TARGET_OS_TYPE=posix 15901 fi 15902 15903 15904 HOTSPOT_TARGET_CPU=${OPENJDK_TARGET_CPU} 15905 if test "x$OPENJDK_TARGET_CPU" = xx86; then 15906 HOTSPOT_TARGET_CPU=x86_32 15907 elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then 15908 HOTSPOT_TARGET_CPU=sparc 15909 elif test "x$OPENJDK_TARGET_CPU" = xppc64; then 15910 HOTSPOT_TARGET_CPU=ppc_64 15911 elif test "x$OPENJDK_TARGET_CPU" = xppc64le; then 15912 HOTSPOT_TARGET_CPU=ppc_64 15913 fi 15914 15915 15916 # This is identical with OPENJDK_*, but define anyway for consistency. 15917 HOTSPOT_TARGET_CPU_ARCH=${OPENJDK_TARGET_CPU_ARCH} 15918 15919 15920 # Setup HOTSPOT_TARGET_CPU_DEFINE 15921 if test "x$OPENJDK_TARGET_CPU" = xx86; then 15922 HOTSPOT_TARGET_CPU_DEFINE=IA32 15923 elif test "x$OPENJDK_TARGET_CPU" = xx86_64; then 15924 HOTSPOT_TARGET_CPU_DEFINE=AMD64 15925 elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then 15926 HOTSPOT_TARGET_CPU_DEFINE=SPARC 15927 elif test "x$OPENJDK_TARGET_CPU" = xaarch64; then 15928 HOTSPOT_TARGET_CPU_DEFINE=AARCH64 15929 elif test "x$OPENJDK_TARGET_CPU" = xppc64; then 15930 HOTSPOT_TARGET_CPU_DEFINE=PPC64 15931 elif test "x$OPENJDK_TARGET_CPU" = xppc64le; then 15932 HOTSPOT_TARGET_CPU_DEFINE=PPC64 15933 15934 # The cpu defines below are for zero, we don't support them directly. 15935 elif test "x$OPENJDK_TARGET_CPU" = xsparc; then 15936 HOTSPOT_TARGET_CPU_DEFINE=SPARC 15937 elif test "x$OPENJDK_TARGET_CPU" = xppc; then 15938 HOTSPOT_TARGET_CPU_DEFINE=PPC32 15939 elif test "x$OPENJDK_TARGET_CPU" = xs390; then 15940 HOTSPOT_TARGET_CPU_DEFINE=S390 15941 elif test "x$OPENJDK_TARGET_CPU" = xs390x; then 15942 HOTSPOT_TARGET_CPU_DEFINE=S390 15943 elif test "x$OPENJDK_TARGET_CPU" != x; then 15944 HOTSPOT_TARGET_CPU_DEFINE=$(echo $OPENJDK_TARGET_CPU | tr a-z A-Z) 15945 fi 15946 15947 15948 15949 15950 # Also store the legacy naming of the cpu. 15951 # Ie i586 and amd64 instead of x86 and x86_64 15952 OPENJDK_BUILD_CPU_LEGACY="$OPENJDK_BUILD_CPU" 15953 if test "x$OPENJDK_BUILD_CPU" = xx86; then 15954 OPENJDK_BUILD_CPU_LEGACY="i586" 15955 elif test "x$OPENJDK_BUILD_OS" != xmacosx && test "x$OPENJDK_BUILD_CPU" = xx86_64; then 15956 # On all platforms except MacOSX replace x86_64 with amd64. 15957 OPENJDK_BUILD_CPU_LEGACY="amd64" 15958 fi 15959 15960 15961 # And the second legacy naming of the cpu. 15962 # Ie i386 and amd64 instead of x86 and x86_64. 15963 OPENJDK_BUILD_CPU_LEGACY_LIB="$OPENJDK_BUILD_CPU" 15964 if test "x$OPENJDK_BUILD_CPU" = xx86; then 15965 OPENJDK_BUILD_CPU_LEGACY_LIB="i386" 15966 elif test "x$OPENJDK_BUILD_CPU" = xx86_64; then 15967 OPENJDK_BUILD_CPU_LEGACY_LIB="amd64" 15968 fi 15969 15970 15971 # This is the name of the cpu (but using i386 and amd64 instead of 15972 # x86 and x86_64, respectively), preceeded by a /, to be used when 15973 # locating libraries. On macosx, it's empty, though. 15974 OPENJDK_BUILD_CPU_LIBDIR="/$OPENJDK_BUILD_CPU_LEGACY_LIB" 15975 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 15976 OPENJDK_BUILD_CPU_LIBDIR="" 15977 fi 15978 15979 15980 # OPENJDK_BUILD_CPU_ISADIR is normally empty. On 64-bit Solaris systems, it is set to 15981 # /amd64 or /sparcv9. This string is appended to some library paths, like this: 15982 # /usr/lib${OPENJDK_BUILD_CPU_ISADIR}/libexample.so 15983 OPENJDK_BUILD_CPU_ISADIR="" 15984 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 15985 if test "x$OPENJDK_BUILD_CPU" = xx86_64; then 15986 OPENJDK_BUILD_CPU_ISADIR="/amd64" 15987 elif test "x$OPENJDK_BUILD_CPU" = xsparcv9; then 15988 OPENJDK_BUILD_CPU_ISADIR="/sparcv9" 15989 fi 15990 fi 15991 15992 15993 # Setup OPENJDK_BUILD_CPU_OSARCH, which is used to set the os.arch Java system property 15994 OPENJDK_BUILD_CPU_OSARCH="$OPENJDK_BUILD_CPU" 15995 if test "x$OPENJDK_BUILD_OS" = xlinux && test "x$OPENJDK_BUILD_CPU" = xx86; then 15996 # On linux only, we replace x86 with i386. 15997 OPENJDK_BUILD_CPU_OSARCH="i386" 15998 elif test "x$OPENJDK_BUILD_OS" != xmacosx && test "x$OPENJDK_BUILD_CPU" = xx86_64; then 15999 # On all platforms except macosx, we replace x86_64 with amd64. 16000 OPENJDK_BUILD_CPU_OSARCH="amd64" 16001 fi 16002 16003 16004 OPENJDK_BUILD_CPU_JLI="$OPENJDK_BUILD_CPU" 16005 if test "x$OPENJDK_BUILD_CPU" = xx86; then 16006 OPENJDK_BUILD_CPU_JLI="i386" 16007 elif test "x$OPENJDK_BUILD_OS" != xmacosx && test "x$OPENJDK_BUILD_CPU" = xx86_64; then 16008 # On all platforms except macosx, we replace x86_64 with amd64. 16009 OPENJDK_BUILD_CPU_JLI="amd64" 16010 fi 16011 # Now setup the -D flags for building libjli. 16012 OPENJDK_BUILD_CPU_JLI_CFLAGS="-DLIBARCHNAME='\"$OPENJDK_BUILD_CPU_JLI\"'" 16013 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 16014 if test "x$OPENJDK_BUILD_CPU_ARCH" = xsparc; then 16015 OPENJDK_BUILD_CPU_JLI_CFLAGS="$OPENJDK_BUILD_CPU_JLI_CFLAGS -DLIBARCH32NAME='\"sparc\"' -DLIBARCH64NAME='\"sparcv9\"'" 16016 elif test "x$OPENJDK_BUILD_CPU_ARCH" = xx86; then 16017 OPENJDK_BUILD_CPU_JLI_CFLAGS="$OPENJDK_BUILD_CPU_JLI_CFLAGS -DLIBARCH32NAME='\"i386\"' -DLIBARCH64NAME='\"amd64\"'" 16018 fi 16019 fi 16020 16021 16022 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 16023 OPENJDK_BUILD_OS_EXPORT_DIR=macosx 16024 else 16025 OPENJDK_BUILD_OS_EXPORT_DIR=${OPENJDK_BUILD_OS_TYPE} 16026 fi 16027 16028 16029 # The new version string in JDK 9 also defined new naming of OS and ARCH for bundles 16030 # Macosx is osx and x86_64 is x64 16031 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 16032 OPENJDK_BUILD_OS_BUNDLE="osx" 16033 else 16034 OPENJDK_BUILD_OS_BUNDLE="$OPENJDK_TARGET_OS" 16035 fi 16036 if test "x$OPENJDK_BUILD_CPU" = xx86_64; then 16037 OPENJDK_BUILD_CPU_BUNDLE="x64" 16038 else 16039 OPENJDK_BUILD_CPU_BUNDLE="$OPENJDK_BUILD_CPU" 16040 fi 16041 OPENJDK_BUILD_BUNDLE_PLATFORM="${OPENJDK_BUILD_OS_BUNDLE}-${OPENJDK_BUILD_CPU_BUNDLE}" 16042 16043 16044 16045 16046 if test "x$OPENJDK_BUILD_CPU_BITS" = x64; then 16047 A_LP64="LP64:=" 16048 # -D_LP64=1 is only set on linux and mac. Setting on windows causes diff in 16049 # unpack200.exe 16050 if test "x$OPENJDK_BUILD_OS" = xlinux || test "x$OPENJDK_BUILD_OS" = xmacosx; then 16051 OPENJDK_BUILD_ADD_LP64="-D_LP64=1" 16052 fi 16053 fi 16054 LP64=$A_LP64 16055 16056 16057 if test "x$COMPILE_TYPE" = "xcross"; then 16058 # FIXME: ... or should this include reduced builds..? 16059 DEFINE_CROSS_COMPILE_ARCH="CROSS_COMPILE_ARCH:=$OPENJDK_BUILD_CPU_LEGACY" 16060 else 16061 DEFINE_CROSS_COMPILE_ARCH="" 16062 fi 16063 16064 16065 # Convert openjdk platform names to hotspot names 16066 16067 HOTSPOT_BUILD_OS=${OPENJDK_BUILD_OS} 16068 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 16069 HOTSPOT_BUILD_OS=bsd 16070 fi 16071 16072 16073 HOTSPOT_BUILD_OS_TYPE=${OPENJDK_BUILD_OS_TYPE} 16074 if test "x$OPENJDK_BUILD_OS_TYPE" = xunix; then 16075 HOTSPOT_BUILD_OS_TYPE=posix 16076 fi 16077 16078 16079 HOTSPOT_BUILD_CPU=${OPENJDK_BUILD_CPU} 16080 if test "x$OPENJDK_BUILD_CPU" = xx86; then 16081 HOTSPOT_BUILD_CPU=x86_32 16082 elif test "x$OPENJDK_BUILD_CPU" = xsparcv9; then 16083 HOTSPOT_BUILD_CPU=sparc 16084 elif test "x$OPENJDK_BUILD_CPU" = xppc64; then 16085 HOTSPOT_BUILD_CPU=ppc_64 16086 elif test "x$OPENJDK_BUILD_CPU" = xppc64le; then 16087 HOTSPOT_BUILD_CPU=ppc_64 16088 fi 16089 16090 16091 # This is identical with OPENJDK_*, but define anyway for consistency. 16092 HOTSPOT_BUILD_CPU_ARCH=${OPENJDK_BUILD_CPU_ARCH} 16093 16094 16095 # Setup HOTSPOT_BUILD_CPU_DEFINE 16096 if test "x$OPENJDK_BUILD_CPU" = xx86; then 16097 HOTSPOT_BUILD_CPU_DEFINE=IA32 16098 elif test "x$OPENJDK_BUILD_CPU" = xx86_64; then 16099 HOTSPOT_BUILD_CPU_DEFINE=AMD64 16100 elif test "x$OPENJDK_BUILD_CPU" = xsparcv9; then 16101 HOTSPOT_BUILD_CPU_DEFINE=SPARC 16102 elif test "x$OPENJDK_BUILD_CPU" = xaarch64; then 16103 HOTSPOT_BUILD_CPU_DEFINE=AARCH64 16104 elif test "x$OPENJDK_BUILD_CPU" = xppc64; then 16105 HOTSPOT_BUILD_CPU_DEFINE=PPC64 16106 elif test "x$OPENJDK_BUILD_CPU" = xppc64le; then 16107 HOTSPOT_BUILD_CPU_DEFINE=PPC64 16108 16109 # The cpu defines below are for zero, we don't support them directly. 16110 elif test "x$OPENJDK_BUILD_CPU" = xsparc; then 16111 HOTSPOT_BUILD_CPU_DEFINE=SPARC 16112 elif test "x$OPENJDK_BUILD_CPU" = xppc; then 16113 HOTSPOT_BUILD_CPU_DEFINE=PPC32 16114 elif test "x$OPENJDK_BUILD_CPU" = xs390; then 16115 HOTSPOT_BUILD_CPU_DEFINE=S390 16116 elif test "x$OPENJDK_BUILD_CPU" = xs390x; then 16117 HOTSPOT_BUILD_CPU_DEFINE=S390 16118 elif test "x$OPENJDK_BUILD_CPU" != x; then 16119 HOTSPOT_BUILD_CPU_DEFINE=$(echo $OPENJDK_BUILD_CPU | tr a-z A-Z) 16120 fi 16121 16122 16123 16124 16125 # ZERO_ARCHDEF is used to enable architecture-specific code. 16126 # This is used in legacy hotspot build. 16127 ZERO_ARCHDEF="$HOTSPOT_TARGET_CPU_DEFINE" 16128 16129 16130 16131 16132 16133 # Continue setting up basic stuff. Most remaining code require fundamental tools. 16134 16135 # Save the current directory this script was started from 16136 CURDIR="$PWD" 16137 16138 # We might need to rewrite ORIGINAL_PATH, if it includes "#", to quote them 16139 # for make. We couldn't do this when we retrieved ORIGINAL_PATH, since SED 16140 # was not available at that time. 16141 REWRITTEN_PATH=`$ECHO "$ORIGINAL_PATH" | $SED -e 's/#/\\\\#/g'` 16142 if test "x$REWRITTEN_PATH" != "x$ORIGINAL_PATH"; then 16143 ORIGINAL_PATH="$REWRITTEN_PATH" 16144 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting ORIGINAL_PATH to $REWRITTEN_PATH" >&5 16145 $as_echo "$as_me: Rewriting ORIGINAL_PATH to $REWRITTEN_PATH" >&6;} 16146 fi 16147 16148 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 16149 PATH_SEP=";" 16150 16151 SRC_ROOT_LENGTH=`$THEPWDCMD -L|$WC -m` 16152 if test $SRC_ROOT_LENGTH -gt 100; then 16153 as_fn_error $? "Your base path is too long. It is $SRC_ROOT_LENGTH characters long, but only 100 is supported" "$LINENO" 5 16154 fi 16155 16156 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16157 { $as_echo "$as_me:${as_lineno-$LINENO}: checking cygwin release" >&5 16158 $as_echo_n "checking cygwin release... " >&6; } 16159 CYGWIN_VERSION=`$UNAME -r` 16160 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_VERSION" >&5 16161 $as_echo "$CYGWIN_VERSION" >&6; } 16162 WINDOWS_ENV_VENDOR='cygwin' 16163 WINDOWS_ENV_VERSION="$CYGWIN_VERSION" 16164 16165 CYGWIN_VERSION_OLD=`$ECHO $CYGWIN_VERSION | $GREP -e '^1\.0-6'` 16166 if test "x$CYGWIN_VERSION_OLD" != x; then 16167 { $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 16168 $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;} 16169 as_fn_error $? "Cannot continue" "$LINENO" 5 16170 fi 16171 if test "x$CYGPATH" = x; then 16172 as_fn_error $? "Something is wrong with your cygwin installation since I cannot find cygpath.exe in your path" "$LINENO" 5 16173 fi 16174 { $as_echo "$as_me:${as_lineno-$LINENO}: checking cygwin root directory as unix-style path" >&5 16175 $as_echo_n "checking cygwin root directory as unix-style path... " >&6; } 16176 # The cmd output ends with Windows line endings (CR/LF), the grep command will strip that away 16177 cygwin_winpath_root=`cd / ; cmd /c cd | $GREP ".*"` 16178 # Force cygpath to report the proper root by including a trailing space, and then stripping it off again. 16179 CYGWIN_ROOT_PATH=`$CYGPATH -u "$cygwin_winpath_root " | $CUT -f 1 -d " "` 16180 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_ROOT_PATH" >&5 16181 $as_echo "$CYGWIN_ROOT_PATH" >&6; } 16182 WINDOWS_ENV_ROOT_PATH="$CYGWIN_ROOT_PATH" 16183 test_cygdrive_prefix=`$ECHO $CYGWIN_ROOT_PATH | $GREP ^/cygdrive/` 16184 if test "x$test_cygdrive_prefix" = x; then 16185 as_fn_error $? "Your cygdrive prefix is not /cygdrive. This is currently not supported. Change with mount -c." "$LINENO" 5 16186 fi 16187 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16188 { $as_echo "$as_me:${as_lineno-$LINENO}: checking msys release" >&5 16189 $as_echo_n "checking msys release... " >&6; } 16190 MSYS_VERSION=`$UNAME -r` 16191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSYS_VERSION" >&5 16192 $as_echo "$MSYS_VERSION" >&6; } 16193 16194 WINDOWS_ENV_VENDOR='msys' 16195 WINDOWS_ENV_VERSION="$MSYS_VERSION" 16196 16197 { $as_echo "$as_me:${as_lineno-$LINENO}: checking msys root directory as unix-style path" >&5 16198 $as_echo_n "checking msys root directory as unix-style path... " >&6; } 16199 # The cmd output ends with Windows line endings (CR/LF), the grep command will strip that away 16200 MSYS_ROOT_PATH=`cd / ; cmd /c cd | $GREP ".*"` 16201 16202 windows_path="$MSYS_ROOT_PATH" 16203 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16204 unix_path=`$CYGPATH -u "$windows_path"` 16205 MSYS_ROOT_PATH="$unix_path" 16206 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16207 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16208 MSYS_ROOT_PATH="$unix_path" 16209 fi 16210 16211 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSYS_ROOT_PATH" >&5 16212 $as_echo "$MSYS_ROOT_PATH" >&6; } 16213 WINDOWS_ENV_ROOT_PATH="$MSYS_ROOT_PATH" 16214 else 16215 as_fn_error $? "Unknown Windows environment. Neither cygwin nor msys was detected." "$LINENO" 5 16216 fi 16217 16218 # Test if windows or unix (cygwin/msys) find is first in path. 16219 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what kind of 'find' is first on the PATH" >&5 16220 $as_echo_n "checking what kind of 'find' is first on the PATH... " >&6; } 16221 FIND_BINARY_OUTPUT=`find --version 2>&1` 16222 if test "x`echo $FIND_BINARY_OUTPUT | $GREP GNU`" != x; then 16223 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unix style" >&5 16224 $as_echo "unix style" >&6; } 16225 elif test "x`echo $FIND_BINARY_OUTPUT | $GREP FIND`" != x; then 16226 { $as_echo "$as_me:${as_lineno-$LINENO}: result: Windows" >&5 16227 $as_echo "Windows" >&6; } 16228 { $as_echo "$as_me:${as_lineno-$LINENO}: Your path contains Windows tools (C:\Windows\system32) before your unix (cygwin or msys) tools." >&5 16229 $as_echo "$as_me: Your path contains Windows tools (C:\Windows\system32) before your unix (cygwin or msys) tools." >&6;} 16230 { $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 16231 $as_echo "$as_me: This will not work. Please correct and make sure /usr/bin (or similar) is first in path." >&6;} 16232 as_fn_error $? "Cannot continue" "$LINENO" 5 16233 else 16234 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unknown" >&5 16235 $as_echo "unknown" >&6; } 16236 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: It seems that your find utility is non-standard." >&5 16237 $as_echo "$as_me: WARNING: It seems that your find utility is non-standard." >&2;} 16238 fi 16239 16240 else 16241 PATH_SEP=":" 16242 fi 16243 16244 16245 # We get the top-level directory from the supporting wrappers. 16246 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for top-level directory" >&5 16247 $as_echo_n "checking for top-level directory... " >&6; } 16248 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOPDIR" >&5 16249 $as_echo "$TOPDIR" >&6; } 16250 16251 16252 # Save the original version of TOPDIR for string comparisons 16253 ORIGINAL_TOPDIR="$TOPDIR" 16254 16255 16256 # We can only call BASIC_FIXUP_PATH after BASIC_CHECK_PATHS_WINDOWS. 16257 16258 # Only process if variable expands to non-empty 16259 16260 if test "x$CURDIR" != x; then 16261 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16262 16263 # Input might be given as Windows format, start by converting to 16264 # unix format. 16265 path="$CURDIR" 16266 new_path=`$CYGPATH -u "$path"` 16267 16268 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 16269 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 16270 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 16271 # "foo.exe" is OK but "foo" is an error. 16272 # 16273 # This test is therefore slightly more accurate than "test -f" to check for file precense. 16274 # It is also a way to make sure we got the proper file name for the real test later on. 16275 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 16276 if test "x$test_shortpath" = x; then 16277 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CURDIR, which resolves as \"$path\", is invalid." >&5 16278 $as_echo "$as_me: The path of CURDIR, which resolves as \"$path\", is invalid." >&6;} 16279 as_fn_error $? "Cannot locate the the path of CURDIR" "$LINENO" 5 16280 fi 16281 16282 # Call helper function which possibly converts this using DOS-style short mode. 16283 # If so, the updated path is stored in $new_path. 16284 16285 input_path="$new_path" 16286 # Check if we need to convert this using DOS-style short mode. If the path 16287 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16288 # take no chances and rewrite it. 16289 # Note: m4 eats our [], so we need to use [ and ] instead. 16290 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 16291 if test "x$has_forbidden_chars" != x; then 16292 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16293 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 16294 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 16295 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 16296 # Going to short mode and back again did indeed matter. Since short mode is 16297 # case insensitive, let's make it lowercase to improve readability. 16298 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16299 # Now convert it back to Unix-style (cygpath) 16300 input_path=`$CYGPATH -u "$shortmode_path"` 16301 new_path="$input_path" 16302 fi 16303 fi 16304 16305 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 16306 if test "x$test_cygdrive_prefix" = x; then 16307 # As a simple fix, exclude /usr/bin since it's not a real path. 16308 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 16309 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 16310 # a path prefixed by /cygdrive for fixpath to work. 16311 new_path="$CYGWIN_ROOT_PATH$input_path" 16312 fi 16313 fi 16314 16315 16316 if test "x$path" != "x$new_path"; then 16317 CURDIR="$new_path" 16318 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CURDIR to \"$new_path\"" >&5 16319 $as_echo "$as_me: Rewriting CURDIR to \"$new_path\"" >&6;} 16320 fi 16321 16322 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16323 16324 path="$CURDIR" 16325 has_colon=`$ECHO $path | $GREP ^.:` 16326 new_path="$path" 16327 if test "x$has_colon" = x; then 16328 # Not in mixed or Windows style, start by that. 16329 new_path=`cmd //c echo $path` 16330 fi 16331 16332 16333 input_path="$new_path" 16334 # Check if we need to convert this using DOS-style short mode. If the path 16335 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16336 # take no chances and rewrite it. 16337 # Note: m4 eats our [], so we need to use [ and ] instead. 16338 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 16339 if test "x$has_forbidden_chars" != x; then 16340 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16341 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16342 fi 16343 16344 16345 windows_path="$new_path" 16346 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16347 unix_path=`$CYGPATH -u "$windows_path"` 16348 new_path="$unix_path" 16349 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16350 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16351 new_path="$unix_path" 16352 fi 16353 16354 if test "x$path" != "x$new_path"; then 16355 CURDIR="$new_path" 16356 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CURDIR to \"$new_path\"" >&5 16357 $as_echo "$as_me: Rewriting CURDIR to \"$new_path\"" >&6;} 16358 fi 16359 16360 # Save the first 10 bytes of this path to the storage, so fixpath can work. 16361 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 16362 16363 else 16364 # We're on a unix platform. Hooray! :) 16365 path="$CURDIR" 16366 has_space=`$ECHO "$path" | $GREP " "` 16367 if test "x$has_space" != x; then 16368 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CURDIR, which resolves as \"$path\", is invalid." >&5 16369 $as_echo "$as_me: The path of CURDIR, which resolves as \"$path\", is invalid." >&6;} 16370 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 16371 fi 16372 16373 # Use eval to expand a potential ~ 16374 eval path="$path" 16375 if test ! -f "$path" && test ! -d "$path"; then 16376 as_fn_error $? "The path of CURDIR, which resolves as \"$path\", is not found." "$LINENO" 5 16377 fi 16378 16379 if test -d "$path"; then 16380 CURDIR="`cd "$path"; $THEPWDCMD -L`" 16381 else 16382 dir="`$DIRNAME "$path"`" 16383 base="`$BASENAME "$path"`" 16384 CURDIR="`cd "$dir"; $THEPWDCMD -L`/$base" 16385 fi 16386 fi 16387 fi 16388 16389 16390 # Only process if variable expands to non-empty 16391 16392 if test "x$TOPDIR" != x; then 16393 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16394 16395 # Input might be given as Windows format, start by converting to 16396 # unix format. 16397 path="$TOPDIR" 16398 new_path=`$CYGPATH -u "$path"` 16399 16400 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 16401 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 16402 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 16403 # "foo.exe" is OK but "foo" is an error. 16404 # 16405 # This test is therefore slightly more accurate than "test -f" to check for file precense. 16406 # It is also a way to make sure we got the proper file name for the real test later on. 16407 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 16408 if test "x$test_shortpath" = x; then 16409 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of TOPDIR, which resolves as \"$path\", is invalid." >&5 16410 $as_echo "$as_me: The path of TOPDIR, which resolves as \"$path\", is invalid." >&6;} 16411 as_fn_error $? "Cannot locate the the path of TOPDIR" "$LINENO" 5 16412 fi 16413 16414 # Call helper function which possibly converts this using DOS-style short mode. 16415 # If so, the updated path is stored in $new_path. 16416 16417 input_path="$new_path" 16418 # Check if we need to convert this using DOS-style short mode. If the path 16419 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16420 # take no chances and rewrite it. 16421 # Note: m4 eats our [], so we need to use [ and ] instead. 16422 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 16423 if test "x$has_forbidden_chars" != x; then 16424 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16425 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 16426 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 16427 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 16428 # Going to short mode and back again did indeed matter. Since short mode is 16429 # case insensitive, let's make it lowercase to improve readability. 16430 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16431 # Now convert it back to Unix-style (cygpath) 16432 input_path=`$CYGPATH -u "$shortmode_path"` 16433 new_path="$input_path" 16434 fi 16435 fi 16436 16437 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 16438 if test "x$test_cygdrive_prefix" = x; then 16439 # As a simple fix, exclude /usr/bin since it's not a real path. 16440 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 16441 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 16442 # a path prefixed by /cygdrive for fixpath to work. 16443 new_path="$CYGWIN_ROOT_PATH$input_path" 16444 fi 16445 fi 16446 16447 16448 if test "x$path" != "x$new_path"; then 16449 TOPDIR="$new_path" 16450 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting TOPDIR to \"$new_path\"" >&5 16451 $as_echo "$as_me: Rewriting TOPDIR to \"$new_path\"" >&6;} 16452 fi 16453 16454 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16455 16456 path="$TOPDIR" 16457 has_colon=`$ECHO $path | $GREP ^.:` 16458 new_path="$path" 16459 if test "x$has_colon" = x; then 16460 # Not in mixed or Windows style, start by that. 16461 new_path=`cmd //c echo $path` 16462 fi 16463 16464 16465 input_path="$new_path" 16466 # Check if we need to convert this using DOS-style short mode. If the path 16467 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16468 # take no chances and rewrite it. 16469 # Note: m4 eats our [], so we need to use [ and ] instead. 16470 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 16471 if test "x$has_forbidden_chars" != x; then 16472 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16473 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16474 fi 16475 16476 16477 windows_path="$new_path" 16478 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16479 unix_path=`$CYGPATH -u "$windows_path"` 16480 new_path="$unix_path" 16481 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16482 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16483 new_path="$unix_path" 16484 fi 16485 16486 if test "x$path" != "x$new_path"; then 16487 TOPDIR="$new_path" 16488 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting TOPDIR to \"$new_path\"" >&5 16489 $as_echo "$as_me: Rewriting TOPDIR to \"$new_path\"" >&6;} 16490 fi 16491 16492 # Save the first 10 bytes of this path to the storage, so fixpath can work. 16493 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 16494 16495 else 16496 # We're on a unix platform. Hooray! :) 16497 path="$TOPDIR" 16498 has_space=`$ECHO "$path" | $GREP " "` 16499 if test "x$has_space" != x; then 16500 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of TOPDIR, which resolves as \"$path\", is invalid." >&5 16501 $as_echo "$as_me: The path of TOPDIR, which resolves as \"$path\", is invalid." >&6;} 16502 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 16503 fi 16504 16505 # Use eval to expand a potential ~ 16506 eval path="$path" 16507 if test ! -f "$path" && test ! -d "$path"; then 16508 as_fn_error $? "The path of TOPDIR, which resolves as \"$path\", is not found." "$LINENO" 5 16509 fi 16510 16511 if test -d "$path"; then 16512 TOPDIR="`cd "$path"; $THEPWDCMD -L`" 16513 else 16514 dir="`$DIRNAME "$path"`" 16515 base="`$BASENAME "$path"`" 16516 TOPDIR="`cd "$dir"; $THEPWDCMD -L`/$base" 16517 fi 16518 fi 16519 fi 16520 16521 # SRC_ROOT is a traditional alias for TOPDIR. 16522 SRC_ROOT=$TOPDIR 16523 16524 # Calculate a canonical version of TOPDIR for string comparisons 16525 CANONICAL_TOPDIR=$TOPDIR 16526 16527 if test "x$OPENJDK_BUILD_OS" != xwindows; then 16528 # Follow a chain of symbolic links. Use readlink 16529 # where it exists, else fall back to horribly 16530 # complicated shell code. 16531 if test "x$READLINK_TESTED" != yes; then 16532 # On MacOSX there is a readlink tool with a different 16533 # purpose than the GNU readlink tool. Check the found readlink. 16534 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 16535 if test "x$ISGNU" = x; then 16536 # A readlink that we do not know how to use. 16537 # Are there other non-GNU readlinks out there? 16538 READLINK_TESTED=yes 16539 READLINK= 16540 fi 16541 fi 16542 16543 if test "x$READLINK" != x; then 16544 CANONICAL_TOPDIR=`$READLINK -f $CANONICAL_TOPDIR` 16545 else 16546 # Save the current directory for restoring afterwards 16547 STARTDIR=$PWD 16548 COUNTER=0 16549 sym_link_dir=`$DIRNAME $CANONICAL_TOPDIR` 16550 sym_link_file=`$BASENAME $CANONICAL_TOPDIR` 16551 cd $sym_link_dir 16552 # Use -P flag to resolve symlinks in directories. 16553 cd `$THEPWDCMD -P` 16554 sym_link_dir=`$THEPWDCMD -P` 16555 # Resolve file symlinks 16556 while test $COUNTER -lt 20; do 16557 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 16558 if test "x$ISLINK" == x; then 16559 # This is not a symbolic link! We are done! 16560 break 16561 fi 16562 # Again resolve directory symlinks since the target of the just found 16563 # link could be in a different directory 16564 cd `$DIRNAME $ISLINK` 16565 sym_link_dir=`$THEPWDCMD -P` 16566 sym_link_file=`$BASENAME $ISLINK` 16567 let COUNTER=COUNTER+1 16568 done 16569 cd $STARTDIR 16570 CANONICAL_TOPDIR=$sym_link_dir/$sym_link_file 16571 fi 16572 fi 16573 16574 16575 16576 # Locate the directory of this script. 16577 AUTOCONF_DIR=$TOPDIR/common/autoconf 16578 16579 # Setup username (for use in adhoc version strings etc) 16580 # Outer [ ] to quote m4. 16581 USERNAME=`$ECHO "$USER" | $TR -d -c '[a-z][A-Z][0-9]'` 16582 16583 16584 16585 # Check if it's a pure open build or if custom sources are to be used. 16586 16587 # Check whether --enable-openjdk-only was given. 16588 if test "${enable_openjdk_only+set}" = set; then : 16589 enableval=$enable_openjdk_only; 16590 else 16591 enable_openjdk_only="no" 16592 fi 16593 16594 16595 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if custom source is suppressed (openjdk-only)" >&5 16596 $as_echo_n "checking if custom source is suppressed (openjdk-only)... " >&6; } 16597 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $enable_openjdk_only" >&5 16598 $as_echo "$enable_openjdk_only" >&6; } 16599 if test "x$enable_openjdk_only" = "xyes"; then 16600 SUPPRESS_CUSTOM_EXTENSIONS="true" 16601 elif test "x$enable_openjdk_only" = "xno"; then 16602 SUPPRESS_CUSTOM_EXTENSIONS="false" 16603 else 16604 as_fn_error $? "Invalid value for --enable-openjdk-only: $enable_openjdk_only" "$LINENO" 5 16605 fi 16606 16607 # custom-make-dir is deprecated. Please use your custom-hook.m4 to override 16608 # the IncludeCustomExtension macro. 16609 16610 16611 # Check whether --with-custom-make-dir was given. 16612 if test "${with_custom_make_dir+set}" = set; then : 16613 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 16614 $as_echo "$as_me: WARNING: Option --with-custom-make-dir is deprecated and will be ignored." >&2;} 16615 fi 16616 16617 16618 16619 16620 # These are needed to be able to create a configuration name (and thus the output directory) 16621 16622 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variant of the JDK to build" >&5 16623 $as_echo_n "checking which variant of the JDK to build... " >&6; } 16624 16625 # Check whether --with-jdk-variant was given. 16626 if test "${with_jdk_variant+set}" = set; then : 16627 withval=$with_jdk_variant; 16628 fi 16629 16630 16631 if test "x$with_jdk_variant" = xnormal || test "x$with_jdk_variant" = x; then 16632 JDK_VARIANT="normal" 16633 else 16634 as_fn_error $? "The available JDK variants are: normal" "$LINENO" 5 16635 fi 16636 16637 16638 16639 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JDK_VARIANT" >&5 16640 $as_echo "$JDK_VARIANT" >&6; } 16641 16642 16643 DEBUG_LEVEL="release" 16644 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which debug level to use" >&5 16645 $as_echo_n "checking which debug level to use... " >&6; } 16646 # Check whether --enable-debug was given. 16647 if test "${enable_debug+set}" = set; then : 16648 enableval=$enable_debug; 16649 ENABLE_DEBUG="${enableval}" 16650 DEBUG_LEVEL="fastdebug" 16651 16652 else 16653 ENABLE_DEBUG="no" 16654 fi 16655 16656 16657 16658 # Check whether --with-debug-level was given. 16659 if test "${with_debug_level+set}" = set; then : 16660 withval=$with_debug_level; 16661 DEBUG_LEVEL="${withval}" 16662 if test "x$ENABLE_DEBUG" = xyes; then 16663 as_fn_error $? "You cannot use both --enable-debug and --with-debug-level at the same time." "$LINENO" 5 16664 fi 16665 16666 fi 16667 16668 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEBUG_LEVEL" >&5 16669 $as_echo "$DEBUG_LEVEL" >&6; } 16670 16671 if test "x$DEBUG_LEVEL" != xrelease && \ 16672 test "x$DEBUG_LEVEL" != xoptimized && \ 16673 test "x$DEBUG_LEVEL" != xfastdebug && \ 16674 test "x$DEBUG_LEVEL" != xslowdebug; then 16675 as_fn_error $? "Allowed debug levels are: release, fastdebug, slowdebug and optimized" "$LINENO" 5 16676 fi 16677 16678 # Translate DEBUG_LEVEL to debug level used by Hotspot 16679 HOTSPOT_DEBUG_LEVEL="$DEBUG_LEVEL" 16680 if test "x$DEBUG_LEVEL" = xrelease; then 16681 HOTSPOT_DEBUG_LEVEL="product" 16682 elif test "x$DEBUG_LEVEL" = xslowdebug; then 16683 HOTSPOT_DEBUG_LEVEL="debug" 16684 fi 16685 16686 if test "x$DEBUG_LEVEL" = xoptimized; then 16687 # The debug level 'optimized' is a little special because it is currently only 16688 # applicable to the HotSpot build where it means to build a completely 16689 # optimized version of the VM without any debugging code (like for the 16690 # 'release' debug level which is called 'product' in the HotSpot build) but 16691 # with the exception that it can contain additional code which is otherwise 16692 # protected by '#ifndef PRODUCT' macros. These 'optimized' builds are used to 16693 # test new and/or experimental features which are not intended for customer 16694 # shipment. Because these new features need to be tested and benchmarked in 16695 # real world scenarios, we want to build the containing JDK at the 'release' 16696 # debug level. 16697 DEBUG_LEVEL="release" 16698 fi 16699 16700 16701 16702 16703 16704 16705 # Check whether --with-jvm-variants was given. 16706 if test "${with_jvm_variants+set}" = set; then : 16707 withval=$with_jvm_variants; 16708 fi 16709 16710 16711 if test "x$with_jvm_variants" = x; then 16712 with_jvm_variants="server" 16713 fi 16714 JVM_VARIANTS_OPT="$with_jvm_variants" 16715 16716 # Has the user listed more than one variant? 16717 # Additional [] needed to keep m4 from mangling shell constructs. 16718 if [[ "$JVM_VARIANTS_OPT" =~ "," ]] ; then 16719 BUILDING_MULTIPLE_JVM_VARIANTS=true 16720 else 16721 BUILDING_MULTIPLE_JVM_VARIANTS=false 16722 fi 16723 # Replace the commas with AND for use in the build directory name. 16724 JVM_VARIANTS_WITH_AND=`$ECHO "$JVM_VARIANTS_OPT" | $SED -e 's/,/AND/g'` 16725 16726 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variants of the JVM to build" >&5 16727 $as_echo_n "checking which variants of the JVM to build... " >&6; } 16728 # JVM_VARIANTS is a space-separated list. 16729 # Also use minimal, not minimal1 (which is kept for backwards compatibility). 16730 JVM_VARIANTS=`$ECHO $JVM_VARIANTS_OPT | $SED -e 's/,/ /g' -e 's/minimal1/minimal/'` 16731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JVM_VARIANTS" >&5 16732 $as_echo "$JVM_VARIANTS" >&6; } 16733 16734 # Check that the selected variants are valid 16735 16736 # grep filter function inspired by a comment to http://stackoverflow.com/a/1617326 16737 # Notice that the original variant failes on SLES 10 and 11 16738 NEEDLE=${VALID_JVM_VARIANTS// /$'\n'} 16739 STACK=${JVM_VARIANTS// /$'\n'} 16740 INVALID_VARIANTS=`$GREP -Fvx "${NEEDLE}" <<< "${STACK}"` 16741 if test "x$INVALID_VARIANTS" != x; then 16742 { $as_echo "$as_me:${as_lineno-$LINENO}: Unknown variant(s) specified: $INVALID_VARIANTS" >&5 16743 $as_echo "$as_me: Unknown variant(s) specified: $INVALID_VARIANTS" >&6;} 16744 as_fn_error $? "The available JVM variants are: $VALID_JVM_VARIANTS" "$LINENO" 5 16745 fi 16746 16747 # All "special" variants share the same output directory ("server") 16748 VALID_MULTIPLE_JVM_VARIANTS="server client minimal" 16749 NEEDLE=${VALID_MULTIPLE_JVM_VARIANTS// /$'\n'} 16750 STACK=${JVM_VARIANTS// /$'\n'} 16751 INVALID_MULTIPLE_VARIANTS=`$GREP -Fvx "${NEEDLE}" <<< "${STACK}"` 16752 if test "x$INVALID_MULTIPLE_VARIANTS" != x && test "x$BUILDING_MULTIPLE_JVM_VARIANTS" = xtrue; then 16753 as_fn_error $? "You cannot build multiple variants with anything else than $VALID_MULTIPLE_JVM_VARIANTS." "$LINENO" 5 16754 fi 16755 16756 16757 16758 16759 if [[ " $JVM_VARIANTS " =~ " zero " ]] || [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 16760 # zero behaves as a platform and rewrites these values. This is really weird. :( 16761 # We are guaranteed that we do not build any other variants when building zero. 16762 HOTSPOT_TARGET_CPU=zero 16763 HOTSPOT_TARGET_CPU_ARCH=zero 16764 fi 16765 16766 16767 # With basic setup done, call the custom early hook. 16768 16769 16770 # Check if we have devkits, extra paths or sysroot set. 16771 16772 16773 # Check whether --with-devkit was given. 16774 if test "${with_devkit+set}" = set; then : 16775 withval=$with_devkit; 16776 16777 # Only process if variable expands to non-empty 16778 16779 if test "x$with_devkit" != x; then 16780 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16781 16782 # Input might be given as Windows format, start by converting to 16783 # unix format. 16784 path="$with_devkit" 16785 new_path=`$CYGPATH -u "$path"` 16786 16787 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 16788 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 16789 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 16790 # "foo.exe" is OK but "foo" is an error. 16791 # 16792 # This test is therefore slightly more accurate than "test -f" to check for file precense. 16793 # It is also a way to make sure we got the proper file name for the real test later on. 16794 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 16795 if test "x$test_shortpath" = x; then 16796 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_devkit, which resolves as \"$path\", is invalid." >&5 16797 $as_echo "$as_me: The path of with_devkit, which resolves as \"$path\", is invalid." >&6;} 16798 as_fn_error $? "Cannot locate the the path of with_devkit" "$LINENO" 5 16799 fi 16800 16801 # Call helper function which possibly converts this using DOS-style short mode. 16802 # If so, the updated path is stored in $new_path. 16803 16804 input_path="$new_path" 16805 # Check if we need to convert this using DOS-style short mode. If the path 16806 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16807 # take no chances and rewrite it. 16808 # Note: m4 eats our [], so we need to use [ and ] instead. 16809 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 16810 if test "x$has_forbidden_chars" != x; then 16811 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16812 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 16813 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 16814 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 16815 # Going to short mode and back again did indeed matter. Since short mode is 16816 # case insensitive, let's make it lowercase to improve readability. 16817 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16818 # Now convert it back to Unix-style (cygpath) 16819 input_path=`$CYGPATH -u "$shortmode_path"` 16820 new_path="$input_path" 16821 fi 16822 fi 16823 16824 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 16825 if test "x$test_cygdrive_prefix" = x; then 16826 # As a simple fix, exclude /usr/bin since it's not a real path. 16827 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 16828 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 16829 # a path prefixed by /cygdrive for fixpath to work. 16830 new_path="$CYGWIN_ROOT_PATH$input_path" 16831 fi 16832 fi 16833 16834 16835 if test "x$path" != "x$new_path"; then 16836 with_devkit="$new_path" 16837 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_devkit to \"$new_path\"" >&5 16838 $as_echo "$as_me: Rewriting with_devkit to \"$new_path\"" >&6;} 16839 fi 16840 16841 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16842 16843 path="$with_devkit" 16844 has_colon=`$ECHO $path | $GREP ^.:` 16845 new_path="$path" 16846 if test "x$has_colon" = x; then 16847 # Not in mixed or Windows style, start by that. 16848 new_path=`cmd //c echo $path` 16849 fi 16850 16851 16852 input_path="$new_path" 16853 # Check if we need to convert this using DOS-style short mode. If the path 16854 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16855 # take no chances and rewrite it. 16856 # Note: m4 eats our [], so we need to use [ and ] instead. 16857 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 16858 if test "x$has_forbidden_chars" != x; then 16859 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16860 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16861 fi 16862 16863 16864 windows_path="$new_path" 16865 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16866 unix_path=`$CYGPATH -u "$windows_path"` 16867 new_path="$unix_path" 16868 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16869 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16870 new_path="$unix_path" 16871 fi 16872 16873 if test "x$path" != "x$new_path"; then 16874 with_devkit="$new_path" 16875 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_devkit to \"$new_path\"" >&5 16876 $as_echo "$as_me: Rewriting with_devkit to \"$new_path\"" >&6;} 16877 fi 16878 16879 # Save the first 10 bytes of this path to the storage, so fixpath can work. 16880 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 16881 16882 else 16883 # We're on a unix platform. Hooray! :) 16884 path="$with_devkit" 16885 has_space=`$ECHO "$path" | $GREP " "` 16886 if test "x$has_space" != x; then 16887 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_devkit, which resolves as \"$path\", is invalid." >&5 16888 $as_echo "$as_me: The path of with_devkit, which resolves as \"$path\", is invalid." >&6;} 16889 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 16890 fi 16891 16892 # Use eval to expand a potential ~ 16893 eval path="$path" 16894 if test ! -f "$path" && test ! -d "$path"; then 16895 as_fn_error $? "The path of with_devkit, which resolves as \"$path\", is not found." "$LINENO" 5 16896 fi 16897 16898 if test -d "$path"; then 16899 with_devkit="`cd "$path"; $THEPWDCMD -L`" 16900 else 16901 dir="`$DIRNAME "$path"`" 16902 base="`$BASENAME "$path"`" 16903 with_devkit="`cd "$dir"; $THEPWDCMD -L`/$base" 16904 fi 16905 fi 16906 fi 16907 16908 DEVKIT_ROOT="$with_devkit" 16909 # Check for a meta data info file in the root of the devkit 16910 if test -f "$DEVKIT_ROOT/devkit.info"; then 16911 . $DEVKIT_ROOT/devkit.info 16912 # This potentially sets the following: 16913 # A descriptive name of the devkit 16914 16915 if test "x$DEVKIT_NAME" = x; then 16916 eval DEVKIT_NAME="\${DEVKIT_NAME_${OPENJDK_TARGET_CPU}}" 16917 fi 16918 16919 # Corresponds to --with-extra-path 16920 16921 if test "x$DEVKIT_EXTRA_PATH" = x; then 16922 eval DEVKIT_EXTRA_PATH="\${DEVKIT_EXTRA_PATH_${OPENJDK_TARGET_CPU}}" 16923 fi 16924 16925 # Corresponds to --with-toolchain-path 16926 16927 if test "x$DEVKIT_TOOLCHAIN_PATH" = x; then 16928 eval DEVKIT_TOOLCHAIN_PATH="\${DEVKIT_TOOLCHAIN_PATH_${OPENJDK_TARGET_CPU}}" 16929 fi 16930 16931 # Corresponds to --with-sysroot 16932 16933 if test "x$DEVKIT_SYSROOT" = x; then 16934 eval DEVKIT_SYSROOT="\${DEVKIT_SYSROOT_${OPENJDK_TARGET_CPU}}" 16935 fi 16936 16937 16938 # Identifies the Visual Studio version in the devkit 16939 16940 if test "x$DEVKIT_VS_VERSION" = x; then 16941 eval DEVKIT_VS_VERSION="\${DEVKIT_VS_VERSION_${OPENJDK_TARGET_CPU}}" 16942 fi 16943 16944 # The Visual Studio include environment variable 16945 16946 if test "x$DEVKIT_VS_INCLUDE" = x; then 16947 eval DEVKIT_VS_INCLUDE="\${DEVKIT_VS_INCLUDE_${OPENJDK_TARGET_CPU}}" 16948 fi 16949 16950 # The Visual Studio lib environment variable 16951 16952 if test "x$DEVKIT_VS_LIB" = x; then 16953 eval DEVKIT_VS_LIB="\${DEVKIT_VS_LIB_${OPENJDK_TARGET_CPU}}" 16954 fi 16955 16956 # Corresponds to --with-msvcr-dll 16957 16958 if test "x$DEVKIT_MSVCR_DLL" = x; then 16959 eval DEVKIT_MSVCR_DLL="\${DEVKIT_MSVCR_DLL_${OPENJDK_TARGET_CPU}}" 16960 fi 16961 16962 # Corresponds to --with-msvcp-dll 16963 16964 if test "x$DEVKIT_MSVCP_DLL" = x; then 16965 eval DEVKIT_MSVCP_DLL="\${DEVKIT_MSVCP_DLL_${OPENJDK_TARGET_CPU}}" 16966 fi 16967 16968 fi 16969 16970 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for devkit" >&5 16971 $as_echo_n "checking for devkit... " >&6; } 16972 if test "x$DEVKIT_NAME" != x; then 16973 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEVKIT_NAME in $DEVKIT_ROOT" >&5 16974 $as_echo "$DEVKIT_NAME in $DEVKIT_ROOT" >&6; } 16975 else 16976 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEVKIT_ROOT" >&5 16977 $as_echo "$DEVKIT_ROOT" >&6; } 16978 fi 16979 16980 16981 if test "x$DEVKIT_EXTRA_PATH" != x; then 16982 if test "x$EXTRA_PATH" = x; then 16983 EXTRA_PATH="$DEVKIT_EXTRA_PATH" 16984 else 16985 EXTRA_PATH="$DEVKIT_EXTRA_PATH:$EXTRA_PATH" 16986 fi 16987 fi 16988 16989 16990 # Fallback default of just /bin if DEVKIT_PATH is not defined 16991 if test "x$DEVKIT_TOOLCHAIN_PATH" = x; then 16992 DEVKIT_TOOLCHAIN_PATH="$DEVKIT_ROOT/bin" 16993 fi 16994 16995 if test "x$DEVKIT_TOOLCHAIN_PATH" != x; then 16996 if test "x$TOOLCHAIN_PATH" = x; then 16997 TOOLCHAIN_PATH="$DEVKIT_TOOLCHAIN_PATH" 16998 else 16999 TOOLCHAIN_PATH="$DEVKIT_TOOLCHAIN_PATH:$TOOLCHAIN_PATH" 17000 fi 17001 fi 17002 17003 17004 # If DEVKIT_SYSROOT is set, use that, otherwise try a couple of known 17005 # places for backwards compatiblity. 17006 if test "x$DEVKIT_SYSROOT" != x; then 17007 SYSROOT="$DEVKIT_SYSROOT" 17008 elif test -d "$DEVKIT_ROOT/$host_alias/libc"; then 17009 SYSROOT="$DEVKIT_ROOT/$host_alias/libc" 17010 elif test -d "$DEVKIT_ROOT/$host/sys-root"; then 17011 SYSROOT="$DEVKIT_ROOT/$host/sys-root" 17012 fi 17013 17014 17015 fi 17016 17017 17018 # You can force the sysroot if the sysroot encoded into the compiler tools 17019 # is not correct. 17020 17021 # Check whether --with-sys-root was given. 17022 if test "${with_sys_root+set}" = set; then : 17023 withval=$with_sys_root; SYSROOT=$with_sys_root 17024 17025 fi 17026 17027 17028 17029 # Check whether --with-sysroot was given. 17030 if test "${with_sysroot+set}" = set; then : 17031 withval=$with_sysroot; SYSROOT=$with_sysroot 17032 17033 fi 17034 17035 17036 17037 # Check whether --with-tools-dir was given. 17038 if test "${with_tools_dir+set}" = set; then : 17039 withval=$with_tools_dir; 17040 if test "x$with_tools_dir" != x; then 17041 if test "x$TOOLCHAIN_PATH" = x; then 17042 TOOLCHAIN_PATH="$with_tools_dir" 17043 else 17044 TOOLCHAIN_PATH="$with_tools_dir:$TOOLCHAIN_PATH" 17045 fi 17046 fi 17047 17048 17049 fi 17050 17051 17052 17053 # Check whether --with-toolchain-path was given. 17054 if test "${with_toolchain_path+set}" = set; then : 17055 withval=$with_toolchain_path; 17056 if test "x$with_toolchain_path" != x; then 17057 if test "x$TOOLCHAIN_PATH" = x; then 17058 TOOLCHAIN_PATH="$with_toolchain_path" 17059 else 17060 TOOLCHAIN_PATH="$with_toolchain_path:$TOOLCHAIN_PATH" 17061 fi 17062 fi 17063 17064 17065 fi 17066 17067 17068 17069 # Check whether --with-extra-path was given. 17070 if test "${with_extra_path+set}" = set; then : 17071 withval=$with_extra_path; 17072 if test "x$with_extra_path" != x; then 17073 if test "x$EXTRA_PATH" = x; then 17074 EXTRA_PATH="$with_extra_path" 17075 else 17076 EXTRA_PATH="$with_extra_path:$EXTRA_PATH" 17077 fi 17078 fi 17079 17080 17081 fi 17082 17083 17084 if test "x$OPENJDK_BUILD_OS" = "xmacosx"; then 17085 # If a devkit has been supplied, find xcodebuild in the toolchain_path. 17086 # If not, detect if Xcode is installed by running xcodebuild -version 17087 # if no Xcode installed, xcodebuild exits with 1 17088 # if Xcode is installed, even if xcode-select is misconfigured, then it exits with 0 17089 if test "x$DEVKIT_ROOT" != x || /usr/bin/xcodebuild -version >/dev/null 2>&1; then 17090 # We need to use xcodebuild in the toolchain dir provided by the user, this will 17091 # fall back on the stub binary in /usr/bin/xcodebuild 17092 # Extract the first word of "xcodebuild", so it can be a program name with args. 17093 set dummy xcodebuild; ac_word=$2 17094 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 17095 $as_echo_n "checking for $ac_word... " >&6; } 17096 if ${ac_cv_path_XCODEBUILD+:} false; then : 17097 $as_echo_n "(cached) " >&6 17098 else 17099 case $XCODEBUILD in 17100 [\\/]* | ?:[\\/]*) 17101 ac_cv_path_XCODEBUILD="$XCODEBUILD" # Let the user override the test with a path. 17102 ;; 17103 *) 17104 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 17105 for as_dir in $TOOLCHAIN_PATH 17106 do 17107 IFS=$as_save_IFS 17108 test -z "$as_dir" && as_dir=. 17109 for ac_exec_ext in '' $ac_executable_extensions; do 17110 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 17111 ac_cv_path_XCODEBUILD="$as_dir/$ac_word$ac_exec_ext" 17112 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 17113 break 2 17114 fi 17115 done 17116 done 17117 IFS=$as_save_IFS 17118 17119 test -z "$ac_cv_path_XCODEBUILD" && ac_cv_path_XCODEBUILD="/usr/bin/xcodebuild" 17120 ;; 17121 esac 17122 fi 17123 XCODEBUILD=$ac_cv_path_XCODEBUILD 17124 if test -n "$XCODEBUILD"; then 17125 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XCODEBUILD" >&5 17126 $as_echo "$XCODEBUILD" >&6; } 17127 else 17128 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 17129 $as_echo "no" >&6; } 17130 fi 17131 17132 17133 else 17134 # this should result in SYSROOT being empty, unless --with-sysroot is provided 17135 # when only the command line tools are installed there are no SDKs, so headers 17136 # are copied into the system frameworks 17137 XCODEBUILD= 17138 17139 fi 17140 17141 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sdk name" >&5 17142 $as_echo_n "checking for sdk name... " >&6; } 17143 17144 # Check whether --with-sdk-name was given. 17145 if test "${with_sdk_name+set}" = set; then : 17146 withval=$with_sdk_name; SDKNAME=$with_sdk_name 17147 17148 fi 17149 17150 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SDKNAME" >&5 17151 $as_echo "$SDKNAME" >&6; } 17152 17153 # if toolchain path is specified then don't rely on system headers, they may not compile 17154 HAVE_SYSTEM_FRAMEWORK_HEADERS=0 17155 test -z "$TOOLCHAIN_PATH" && \ 17156 HAVE_SYSTEM_FRAMEWORK_HEADERS=`test ! -f /System/Library/Frameworks/Foundation.framework/Headers/Foundation.h; echo $?` 17157 17158 if test -z "$SYSROOT"; then 17159 if test -n "$XCODEBUILD"; then 17160 # if we don't have system headers, use default SDK name (last resort) 17161 if test -z "$SDKNAME" -a $HAVE_SYSTEM_FRAMEWORK_HEADERS -eq 0; then 17162 SDKNAME=${SDKNAME:-macosx} 17163 fi 17164 17165 if test -n "$SDKNAME"; then 17166 # Call xcodebuild to determine SYSROOT 17167 SYSROOT=`"$XCODEBUILD" -sdk $SDKNAME -version | $GREP '^Path: ' | $SED 's/Path: //'` 17168 fi 17169 else 17170 if test $HAVE_SYSTEM_FRAMEWORK_HEADERS -eq 0; then 17171 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 17172 fi 17173 fi 17174 else 17175 # warn user if --with-sdk-name was also set 17176 if test -n "$with_sdk_name"; then 17177 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Both SYSROOT and --with-sdk-name are set, only SYSROOT will be used" >&5 17178 $as_echo "$as_me: WARNING: Both SYSROOT and --with-sdk-name are set, only SYSROOT will be used" >&2;} 17179 fi 17180 fi 17181 17182 if test $HAVE_SYSTEM_FRAMEWORK_HEADERS -eq 0 -a -z "$SYSROOT"; then 17183 # If no system framework headers, then SYSROOT must be set, or we won't build 17184 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 17185 fi 17186 17187 # Perform a basic sanity test 17188 if test ! -f "$SYSROOT/System/Library/Frameworks/Foundation.framework/Headers/Foundation.h"; then 17189 if test -z "$SYSROOT"; then 17190 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 17191 else 17192 as_fn_error $? "Invalid SDK or SYSROOT path, dependent framework headers not found" "$LINENO" 5 17193 fi 17194 fi 17195 17196 # set SDKROOT too, Xcode tools will pick it up 17197 SDKROOT=$SYSROOT 17198 17199 fi 17200 17201 # Prepend the extra path to the global path 17202 17203 if test "x$EXTRA_PATH" != x; then 17204 if test "x$PATH" = x; then 17205 PATH="$EXTRA_PATH" 17206 else 17207 PATH="$EXTRA_PATH:$PATH" 17208 fi 17209 fi 17210 17211 17212 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5 17213 $as_echo_n "checking for sysroot... " >&6; } 17214 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SYSROOT" >&5 17215 $as_echo "$SYSROOT" >&6; } 17216 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for toolchain path" >&5 17217 $as_echo_n "checking for toolchain path... " >&6; } 17218 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLCHAIN_PATH" >&5 17219 $as_echo "$TOOLCHAIN_PATH" >&6; } 17220 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for extra path" >&5 17221 $as_echo_n "checking for extra path... " >&6; } 17222 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXTRA_PATH" >&5 17223 $as_echo "$EXTRA_PATH" >&6; } 17224 17225 17226 # To properly create a configuration name, we need to have the OpenJDK target 17227 # and options (variants and debug level) parsed. 17228 17229 17230 17231 # Check whether --with-conf-name was given. 17232 if test "${with_conf_name+set}" = set; then : 17233 withval=$with_conf_name; CONF_NAME=${with_conf_name} 17234 fi 17235 17236 17237 # Test from where we are running configure, in or outside of src root. 17238 { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to store configuration" >&5 17239 $as_echo_n "checking where to store configuration... " >&6; } 17240 if test "x$CURDIR" = "x$SRC_ROOT" || test "x$CURDIR" = "x$SRC_ROOT/common" \ 17241 || test "x$CURDIR" = "x$SRC_ROOT/common/autoconf" \ 17242 || test "x$CURDIR" = "x$SRC_ROOT/make" ; then 17243 # We are running configure from the src root. 17244 # Create a default ./build/target-variant-debuglevel output root. 17245 if test "x${CONF_NAME}" = x; then 17246 { $as_echo "$as_me:${as_lineno-$LINENO}: result: in default location" >&5 17247 $as_echo "in default location" >&6; } 17248 CONF_NAME="${OPENJDK_TARGET_OS}-${OPENJDK_TARGET_CPU}-${JDK_VARIANT}-${JVM_VARIANTS_WITH_AND}-${DEBUG_LEVEL}" 17249 else 17250 { $as_echo "$as_me:${as_lineno-$LINENO}: result: in build directory with custom name" >&5 17251 $as_echo "in build directory with custom name" >&6; } 17252 fi 17253 OUTPUT_ROOT="$SRC_ROOT/build/${CONF_NAME}" 17254 $MKDIR -p "$OUTPUT_ROOT" 17255 if test ! -d "$OUTPUT_ROOT"; then 17256 as_fn_error $? "Could not create build directory $OUTPUT_ROOT" "$LINENO" 5 17257 fi 17258 else 17259 # We are running configure from outside of the src dir. 17260 # Then use the current directory as output dir! 17261 # If configuration is situated in normal build directory, just use the build 17262 # directory name as configuration name, otherwise use the complete path. 17263 if test "x${CONF_NAME}" = x; then 17264 CONF_NAME=`$ECHO $CURDIR | $SED -e "s!^${SRC_ROOT}/build/!!"` 17265 fi 17266 OUTPUT_ROOT="$CURDIR" 17267 { $as_echo "$as_me:${as_lineno-$LINENO}: result: in current directory" >&5 17268 $as_echo "in current directory" >&6; } 17269 17270 # WARNING: This might be a bad thing to do. You need to be sure you want to 17271 # have a configuration in this directory. Do some sanity checks! 17272 17273 if test ! -e "$OUTPUT_ROOT/spec.gmk"; then 17274 # If we have a spec.gmk, we have run here before and we are OK. Otherwise, check for 17275 # other files 17276 files_present=`$LS $OUTPUT_ROOT` 17277 # Configure has already touched config.log and confdefs.h in the current dir when this check 17278 # is performed. 17279 filtered_files=`$ECHO "$files_present" \ 17280 | $SED -e 's/config.log//g' \ 17281 -e 's/configure.log//g' \ 17282 -e 's/confdefs.h//g' \ 17283 -e 's/ //g' \ 17284 | $TR -d '\n'` 17285 if test "x$filtered_files" != x; then 17286 { $as_echo "$as_me:${as_lineno-$LINENO}: Current directory is $CURDIR." >&5 17287 $as_echo "$as_me: Current directory is $CURDIR." >&6;} 17288 { $as_echo "$as_me:${as_lineno-$LINENO}: Since this is not the source root, configure will output the configuration here" >&5 17289 $as_echo "$as_me: Since this is not the source root, configure will output the configuration here" >&6;} 17290 { $as_echo "$as_me:${as_lineno-$LINENO}: (as opposed to creating a configuration in <src_root>/build/<conf-name>)." >&5 17291 $as_echo "$as_me: (as opposed to creating a configuration in <src_root>/build/<conf-name>)." >&6;} 17292 { $as_echo "$as_me:${as_lineno-$LINENO}: However, this directory is not empty. This is not allowed, since it could" >&5 17293 $as_echo "$as_me: However, this directory is not empty. This is not allowed, since it could" >&6;} 17294 { $as_echo "$as_me:${as_lineno-$LINENO}: seriously mess up just about everything." >&5 17295 $as_echo "$as_me: seriously mess up just about everything." >&6;} 17296 { $as_echo "$as_me:${as_lineno-$LINENO}: Try 'cd $SRC_ROOT' and restart configure" >&5 17297 $as_echo "$as_me: Try 'cd $SRC_ROOT' and restart configure" >&6;} 17298 { $as_echo "$as_me:${as_lineno-$LINENO}: (or create a new empty directory and cd to it)." >&5 17299 $as_echo "$as_me: (or create a new empty directory and cd to it)." >&6;} 17300 as_fn_error $? "Will not continue creating configuration in $CURDIR" "$LINENO" 5 17301 fi 17302 fi 17303 fi 17304 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what configuration name to use" >&5 17305 $as_echo_n "checking what configuration name to use... " >&6; } 17306 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CONF_NAME" >&5 17307 $as_echo "$CONF_NAME" >&6; } 17308 17309 17310 # Only process if variable expands to non-empty 17311 17312 if test "x$OUTPUT_ROOT" != x; then 17313 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17314 17315 # Input might be given as Windows format, start by converting to 17316 # unix format. 17317 path="$OUTPUT_ROOT" 17318 new_path=`$CYGPATH -u "$path"` 17319 17320 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 17321 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 17322 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 17323 # "foo.exe" is OK but "foo" is an error. 17324 # 17325 # This test is therefore slightly more accurate than "test -f" to check for file precense. 17326 # It is also a way to make sure we got the proper file name for the real test later on. 17327 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 17328 if test "x$test_shortpath" = x; then 17329 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&5 17330 $as_echo "$as_me: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&6;} 17331 as_fn_error $? "Cannot locate the the path of OUTPUT_ROOT" "$LINENO" 5 17332 fi 17333 17334 # Call helper function which possibly converts this using DOS-style short mode. 17335 # If so, the updated path is stored in $new_path. 17336 17337 input_path="$new_path" 17338 # Check if we need to convert this using DOS-style short mode. If the path 17339 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17340 # take no chances and rewrite it. 17341 # Note: m4 eats our [], so we need to use [ and ] instead. 17342 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 17343 if test "x$has_forbidden_chars" != x; then 17344 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17345 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 17346 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 17347 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 17348 # Going to short mode and back again did indeed matter. Since short mode is 17349 # case insensitive, let's make it lowercase to improve readability. 17350 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17351 # Now convert it back to Unix-style (cygpath) 17352 input_path=`$CYGPATH -u "$shortmode_path"` 17353 new_path="$input_path" 17354 fi 17355 fi 17356 17357 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 17358 if test "x$test_cygdrive_prefix" = x; then 17359 # As a simple fix, exclude /usr/bin since it's not a real path. 17360 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 17361 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 17362 # a path prefixed by /cygdrive for fixpath to work. 17363 new_path="$CYGWIN_ROOT_PATH$input_path" 17364 fi 17365 fi 17366 17367 17368 if test "x$path" != "x$new_path"; then 17369 OUTPUT_ROOT="$new_path" 17370 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OUTPUT_ROOT to \"$new_path\"" >&5 17371 $as_echo "$as_me: Rewriting OUTPUT_ROOT to \"$new_path\"" >&6;} 17372 fi 17373 17374 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17375 17376 path="$OUTPUT_ROOT" 17377 has_colon=`$ECHO $path | $GREP ^.:` 17378 new_path="$path" 17379 if test "x$has_colon" = x; then 17380 # Not in mixed or Windows style, start by that. 17381 new_path=`cmd //c echo $path` 17382 fi 17383 17384 17385 input_path="$new_path" 17386 # Check if we need to convert this using DOS-style short mode. If the path 17387 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17388 # take no chances and rewrite it. 17389 # Note: m4 eats our [], so we need to use [ and ] instead. 17390 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 17391 if test "x$has_forbidden_chars" != x; then 17392 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17393 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17394 fi 17395 17396 17397 windows_path="$new_path" 17398 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17399 unix_path=`$CYGPATH -u "$windows_path"` 17400 new_path="$unix_path" 17401 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17402 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17403 new_path="$unix_path" 17404 fi 17405 17406 if test "x$path" != "x$new_path"; then 17407 OUTPUT_ROOT="$new_path" 17408 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OUTPUT_ROOT to \"$new_path\"" >&5 17409 $as_echo "$as_me: Rewriting OUTPUT_ROOT to \"$new_path\"" >&6;} 17410 fi 17411 17412 # Save the first 10 bytes of this path to the storage, so fixpath can work. 17413 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 17414 17415 else 17416 # We're on a unix platform. Hooray! :) 17417 path="$OUTPUT_ROOT" 17418 has_space=`$ECHO "$path" | $GREP " "` 17419 if test "x$has_space" != x; then 17420 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&5 17421 $as_echo "$as_me: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&6;} 17422 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 17423 fi 17424 17425 # Use eval to expand a potential ~ 17426 eval path="$path" 17427 if test ! -f "$path" && test ! -d "$path"; then 17428 as_fn_error $? "The path of OUTPUT_ROOT, which resolves as \"$path\", is not found." "$LINENO" 5 17429 fi 17430 17431 if test -d "$path"; then 17432 OUTPUT_ROOT="`cd "$path"; $THEPWDCMD -L`" 17433 else 17434 dir="`$DIRNAME "$path"`" 17435 base="`$BASENAME "$path"`" 17436 OUTPUT_ROOT="`cd "$dir"; $THEPWDCMD -L`/$base" 17437 fi 17438 fi 17439 fi 17440 17441 17442 CONFIGURESUPPORT_OUTPUTDIR="$OUTPUT_ROOT/configure-support" 17443 $MKDIR -p "$CONFIGURESUPPORT_OUTPUTDIR" 17444 17445 SPEC=$OUTPUT_ROOT/spec.gmk 17446 17447 CONF_NAME=$CONF_NAME 17448 17449 OUTPUT_ROOT=$OUTPUT_ROOT 17450 17451 17452 17453 # The spec.gmk file contains all variables for the make system. 17454 ac_config_files="$ac_config_files $OUTPUT_ROOT/spec.gmk:$AUTOCONF_DIR/spec.gmk.in" 17455 17456 # The bootcycle-spec.gmk file contains support for boot cycle builds. 17457 ac_config_files="$ac_config_files $OUTPUT_ROOT/bootcycle-spec.gmk:$AUTOCONF_DIR/bootcycle-spec.gmk.in" 17458 17459 # The buildjdk-spec.gmk file contains support for building a buildjdk when cross compiling. 17460 ac_config_files="$ac_config_files $OUTPUT_ROOT/buildjdk-spec.gmk:$AUTOCONF_DIR/buildjdk-spec.gmk.in" 17461 17462 # The compare.sh is used to compare the build output to other builds. 17463 ac_config_files="$ac_config_files $OUTPUT_ROOT/compare.sh:$AUTOCONF_DIR/compare.sh.in" 17464 17465 # The generated Makefile knows where the spec.gmk is and where the source is. 17466 # You can run make from the OUTPUT_ROOT, or from the top-level Makefile 17467 # which will look for generated configurations 17468 ac_config_files="$ac_config_files $OUTPUT_ROOT/Makefile:$AUTOCONF_DIR/Makefile.in" 17469 17470 17471 17472 # Must be done before we can call HELP_MSG_MISSING_DEPENDENCY. 17473 17474 for ac_prog in apt-get yum port pkgutil pkgadd 17475 do 17476 # Extract the first word of "$ac_prog", so it can be a program name with args. 17477 set dummy $ac_prog; ac_word=$2 17478 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 17479 $as_echo_n "checking for $ac_word... " >&6; } 17480 if ${ac_cv_prog_PKGHANDLER+:} false; then : 17481 $as_echo_n "(cached) " >&6 17482 else 17483 if test -n "$PKGHANDLER"; then 17484 ac_cv_prog_PKGHANDLER="$PKGHANDLER" # Let the user override the test. 17485 else 17486 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 17487 for as_dir in $PATH 17488 do 17489 IFS=$as_save_IFS 17490 test -z "$as_dir" && as_dir=. 17491 for ac_exec_ext in '' $ac_executable_extensions; do 17492 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 17493 ac_cv_prog_PKGHANDLER="$ac_prog" 17494 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 17495 break 2 17496 fi 17497 done 17498 done 17499 IFS=$as_save_IFS 17500 17501 fi 17502 fi 17503 PKGHANDLER=$ac_cv_prog_PKGHANDLER 17504 if test -n "$PKGHANDLER"; then 17505 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGHANDLER" >&5 17506 $as_echo "$PKGHANDLER" >&6; } 17507 else 17508 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 17509 $as_echo "no" >&6; } 17510 fi 17511 17512 17513 test -n "$PKGHANDLER" && break 17514 done 17515 17516 17517 17518 # Setup tools that requires more complex handling, or that is not needed by the configure script. 17519 17520 17521 17522 # Publish this variable in the help. 17523 17524 17525 if [ -z "${MAKE+x}" ]; then 17526 # The variable is not set by user, try to locate tool using the code snippet 17527 17528 # Try our hardest to locate a correct version of GNU make 17529 for ac_prog in gmake 17530 do 17531 # Extract the first word of "$ac_prog", so it can be a program name with args. 17532 set dummy $ac_prog; ac_word=$2 17533 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 17534 $as_echo_n "checking for $ac_word... " >&6; } 17535 if ${ac_cv_path_CHECK_GMAKE+:} false; then : 17536 $as_echo_n "(cached) " >&6 17537 else 17538 case $CHECK_GMAKE in 17539 [\\/]* | ?:[\\/]*) 17540 ac_cv_path_CHECK_GMAKE="$CHECK_GMAKE" # Let the user override the test with a path. 17541 ;; 17542 *) 17543 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 17544 for as_dir in $PATH 17545 do 17546 IFS=$as_save_IFS 17547 test -z "$as_dir" && as_dir=. 17548 for ac_exec_ext in '' $ac_executable_extensions; do 17549 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 17550 ac_cv_path_CHECK_GMAKE="$as_dir/$ac_word$ac_exec_ext" 17551 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 17552 break 2 17553 fi 17554 done 17555 done 17556 IFS=$as_save_IFS 17557 17558 ;; 17559 esac 17560 fi 17561 CHECK_GMAKE=$ac_cv_path_CHECK_GMAKE 17562 if test -n "$CHECK_GMAKE"; then 17563 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_GMAKE" >&5 17564 $as_echo "$CHECK_GMAKE" >&6; } 17565 else 17566 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 17567 $as_echo "no" >&6; } 17568 fi 17569 17570 17571 test -n "$CHECK_GMAKE" && break 17572 done 17573 17574 17575 MAKE_CANDIDATE=""$CHECK_GMAKE"" 17576 DESCRIPTION="gmake in PATH" 17577 17578 # On Cygwin, we require a newer version of make than on other platforms 17579 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17580 MAKE_VERSION_EXPR="-e 4\." 17581 MAKE_REQUIRED_VERSION="4.0" 17582 else 17583 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 17584 MAKE_REQUIRED_VERSION="3.81" 17585 fi 17586 17587 if test "x$MAKE_CANDIDATE" != x; then 17588 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 17589 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 17590 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 17591 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 17592 if test "x$IS_GNU_MAKE" = x; then 17593 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 17594 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 17595 else 17596 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 17597 if test "x$IS_MODERN_MAKE" = x; then 17598 { $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 17599 $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;} 17600 else 17601 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 17602 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17603 MAKE_EXPECTED_ENV='cygwin' 17604 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17605 MAKE_EXPECTED_ENV='msys' 17606 else 17607 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 17608 fi 17609 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 17610 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 17611 else 17612 # Not relevant for non-Windows 17613 IS_MAKE_CORRECT_ENV=true 17614 fi 17615 if test "x$IS_MAKE_CORRECT_ENV" = x; then 17616 { $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 17617 $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;} 17618 else 17619 FOUND_MAKE=$MAKE_CANDIDATE 17620 17621 # Only process if variable expands to non-empty 17622 17623 if test "x$FOUND_MAKE" != x; then 17624 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17625 17626 # First separate the path from the arguments. This will split at the first 17627 # space. 17628 complete="$FOUND_MAKE" 17629 path="${complete%% *}" 17630 tmp="$complete EOL" 17631 arguments="${tmp#* }" 17632 17633 # Input might be given as Windows format, start by converting to 17634 # unix format. 17635 new_path=`$CYGPATH -u "$path"` 17636 17637 # Now try to locate executable using which 17638 new_path=`$WHICH "$new_path" 2> /dev/null` 17639 # bat and cmd files are not always considered executable in cygwin causing which 17640 # to not find them 17641 if test "x$new_path" = x \ 17642 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 17643 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 17644 new_path=`$CYGPATH -u "$path"` 17645 fi 17646 if test "x$new_path" = x; then 17647 # Oops. Which didn't find the executable. 17648 # The splitting of arguments from the executable at a space might have been incorrect, 17649 # since paths with space are more likely in Windows. Give it another try with the whole 17650 # argument. 17651 path="$complete" 17652 arguments="EOL" 17653 new_path=`$CYGPATH -u "$path"` 17654 new_path=`$WHICH "$new_path" 2> /dev/null` 17655 # bat and cmd files are not always considered executable in cygwin causing which 17656 # to not find them 17657 if test "x$new_path" = x \ 17658 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 17659 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 17660 new_path=`$CYGPATH -u "$path"` 17661 fi 17662 if test "x$new_path" = x; then 17663 # It's still not found. Now this is an unrecoverable error. 17664 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 17665 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 17666 has_space=`$ECHO "$complete" | $GREP " "` 17667 if test "x$has_space" != x; then 17668 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 17669 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 17670 fi 17671 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 17672 fi 17673 fi 17674 17675 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 17676 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 17677 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 17678 # "foo.exe" is OK but "foo" is an error. 17679 # 17680 # This test is therefore slightly more accurate than "test -f" to check for file presence. 17681 # It is also a way to make sure we got the proper file name for the real test later on. 17682 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 17683 if test "x$test_shortpath" = x; then 17684 # Short path failed, file does not exist as specified. 17685 # Try adding .exe or .cmd 17686 if test -f "${new_path}.exe"; then 17687 input_to_shortpath="${new_path}.exe" 17688 elif test -f "${new_path}.cmd"; then 17689 input_to_shortpath="${new_path}.cmd" 17690 else 17691 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 17692 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 17693 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 17694 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 17695 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 17696 fi 17697 else 17698 input_to_shortpath="$new_path" 17699 fi 17700 17701 # Call helper function which possibly converts this using DOS-style short mode. 17702 # If so, the updated path is stored in $new_path. 17703 new_path="$input_to_shortpath" 17704 17705 input_path="$input_to_shortpath" 17706 # Check if we need to convert this using DOS-style short mode. If the path 17707 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17708 # take no chances and rewrite it. 17709 # Note: m4 eats our [], so we need to use [ and ] instead. 17710 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 17711 if test "x$has_forbidden_chars" != x; then 17712 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17713 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 17714 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 17715 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 17716 # Going to short mode and back again did indeed matter. Since short mode is 17717 # case insensitive, let's make it lowercase to improve readability. 17718 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17719 # Now convert it back to Unix-style (cygpath) 17720 input_path=`$CYGPATH -u "$shortmode_path"` 17721 new_path="$input_path" 17722 fi 17723 fi 17724 17725 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 17726 if test "x$test_cygdrive_prefix" = x; then 17727 # As a simple fix, exclude /usr/bin since it's not a real path. 17728 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 17729 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 17730 # a path prefixed by /cygdrive for fixpath to work. 17731 new_path="$CYGWIN_ROOT_PATH$input_path" 17732 fi 17733 fi 17734 17735 # remove trailing .exe if any 17736 new_path="${new_path/%.exe/}" 17737 17738 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17739 17740 # First separate the path from the arguments. This will split at the first 17741 # space. 17742 complete="$FOUND_MAKE" 17743 path="${complete%% *}" 17744 tmp="$complete EOL" 17745 arguments="${tmp#* }" 17746 17747 # Input might be given as Windows format, start by converting to 17748 # unix format. 17749 new_path="$path" 17750 17751 windows_path="$new_path" 17752 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17753 unix_path=`$CYGPATH -u "$windows_path"` 17754 new_path="$unix_path" 17755 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17756 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17757 new_path="$unix_path" 17758 fi 17759 17760 17761 # Now try to locate executable using which 17762 new_path=`$WHICH "$new_path" 2> /dev/null` 17763 17764 if test "x$new_path" = x; then 17765 # Oops. Which didn't find the executable. 17766 # The splitting of arguments from the executable at a space might have been incorrect, 17767 # since paths with space are more likely in Windows. Give it another try with the whole 17768 # argument. 17769 path="$complete" 17770 arguments="EOL" 17771 new_path="$path" 17772 17773 windows_path="$new_path" 17774 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17775 unix_path=`$CYGPATH -u "$windows_path"` 17776 new_path="$unix_path" 17777 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17778 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17779 new_path="$unix_path" 17780 fi 17781 17782 17783 new_path=`$WHICH "$new_path" 2> /dev/null` 17784 # bat and cmd files are not always considered executable in MSYS causing which 17785 # to not find them 17786 if test "x$new_path" = x \ 17787 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 17788 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 17789 new_path="$path" 17790 17791 windows_path="$new_path" 17792 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17793 unix_path=`$CYGPATH -u "$windows_path"` 17794 new_path="$unix_path" 17795 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17796 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17797 new_path="$unix_path" 17798 fi 17799 17800 fi 17801 17802 if test "x$new_path" = x; then 17803 # It's still not found. Now this is an unrecoverable error. 17804 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 17805 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 17806 has_space=`$ECHO "$complete" | $GREP " "` 17807 if test "x$has_space" != x; then 17808 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 17809 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 17810 fi 17811 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 17812 fi 17813 fi 17814 17815 # Now new_path has a complete unix path to the binary 17816 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 17817 # Keep paths in /bin as-is, but remove trailing .exe if any 17818 new_path="${new_path/%.exe/}" 17819 # Do not save /bin paths to all_fixpath_prefixes! 17820 else 17821 # Not in mixed or Windows style, start by that. 17822 new_path=`cmd //c echo $new_path` 17823 17824 input_path="$new_path" 17825 # Check if we need to convert this using DOS-style short mode. If the path 17826 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17827 # take no chances and rewrite it. 17828 # Note: m4 eats our [], so we need to use [ and ] instead. 17829 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 17830 if test "x$has_forbidden_chars" != x; then 17831 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17832 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17833 fi 17834 17835 # Output is in $new_path 17836 17837 windows_path="$new_path" 17838 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17839 unix_path=`$CYGPATH -u "$windows_path"` 17840 new_path="$unix_path" 17841 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17842 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17843 new_path="$unix_path" 17844 fi 17845 17846 # remove trailing .exe if any 17847 new_path="${new_path/%.exe/}" 17848 17849 # Save the first 10 bytes of this path to the storage, so fixpath can work. 17850 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 17851 fi 17852 17853 else 17854 # We're on a unix platform. Hooray! :) 17855 # First separate the path from the arguments. This will split at the first 17856 # space. 17857 complete="$FOUND_MAKE" 17858 path="${complete%% *}" 17859 tmp="$complete EOL" 17860 arguments="${tmp#* }" 17861 17862 # Cannot rely on the command "which" here since it doesn't always work. 17863 is_absolute_path=`$ECHO "$path" | $GREP ^/` 17864 if test -z "$is_absolute_path"; then 17865 # Path to executable is not absolute. Find it. 17866 IFS_save="$IFS" 17867 IFS=: 17868 for p in $PATH; do 17869 if test -f "$p/$path" && test -x "$p/$path"; then 17870 new_path="$p/$path" 17871 break 17872 fi 17873 done 17874 IFS="$IFS_save" 17875 else 17876 # This is an absolute path, we can use it without further modifications. 17877 new_path="$path" 17878 fi 17879 17880 if test "x$new_path" = x; then 17881 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 17882 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 17883 has_space=`$ECHO "$complete" | $GREP " "` 17884 if test "x$has_space" != x; then 17885 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 17886 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 17887 fi 17888 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 17889 fi 17890 fi 17891 17892 # Now join together the path and the arguments once again 17893 if test "x$arguments" != xEOL; then 17894 new_complete="$new_path ${arguments% *}" 17895 else 17896 new_complete="$new_path" 17897 fi 17898 17899 if test "x$complete" != "x$new_complete"; then 17900 FOUND_MAKE="$new_complete" 17901 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 17902 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 17903 fi 17904 fi 17905 17906 fi 17907 fi 17908 fi 17909 fi 17910 17911 17912 if test "x$FOUND_MAKE" = x; then 17913 for ac_prog in make 17914 do 17915 # Extract the first word of "$ac_prog", so it can be a program name with args. 17916 set dummy $ac_prog; ac_word=$2 17917 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 17918 $as_echo_n "checking for $ac_word... " >&6; } 17919 if ${ac_cv_path_CHECK_MAKE+:} false; then : 17920 $as_echo_n "(cached) " >&6 17921 else 17922 case $CHECK_MAKE in 17923 [\\/]* | ?:[\\/]*) 17924 ac_cv_path_CHECK_MAKE="$CHECK_MAKE" # Let the user override the test with a path. 17925 ;; 17926 *) 17927 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 17928 for as_dir in $PATH 17929 do 17930 IFS=$as_save_IFS 17931 test -z "$as_dir" && as_dir=. 17932 for ac_exec_ext in '' $ac_executable_extensions; do 17933 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 17934 ac_cv_path_CHECK_MAKE="$as_dir/$ac_word$ac_exec_ext" 17935 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 17936 break 2 17937 fi 17938 done 17939 done 17940 IFS=$as_save_IFS 17941 17942 ;; 17943 esac 17944 fi 17945 CHECK_MAKE=$ac_cv_path_CHECK_MAKE 17946 if test -n "$CHECK_MAKE"; then 17947 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_MAKE" >&5 17948 $as_echo "$CHECK_MAKE" >&6; } 17949 else 17950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 17951 $as_echo "no" >&6; } 17952 fi 17953 17954 17955 test -n "$CHECK_MAKE" && break 17956 done 17957 17958 17959 MAKE_CANDIDATE=""$CHECK_MAKE"" 17960 DESCRIPTION="make in PATH" 17961 17962 # On Cygwin, we require a newer version of make than on other platforms 17963 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17964 MAKE_VERSION_EXPR="-e 4\." 17965 MAKE_REQUIRED_VERSION="4.0" 17966 else 17967 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 17968 MAKE_REQUIRED_VERSION="3.81" 17969 fi 17970 17971 if test "x$MAKE_CANDIDATE" != x; then 17972 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 17973 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 17974 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 17975 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 17976 if test "x$IS_GNU_MAKE" = x; then 17977 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 17978 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 17979 else 17980 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 17981 if test "x$IS_MODERN_MAKE" = x; then 17982 { $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 17983 $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;} 17984 else 17985 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 17986 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17987 MAKE_EXPECTED_ENV='cygwin' 17988 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17989 MAKE_EXPECTED_ENV='msys' 17990 else 17991 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 17992 fi 17993 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 17994 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 17995 else 17996 # Not relevant for non-Windows 17997 IS_MAKE_CORRECT_ENV=true 17998 fi 17999 if test "x$IS_MAKE_CORRECT_ENV" = x; then 18000 { $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 18001 $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;} 18002 else 18003 FOUND_MAKE=$MAKE_CANDIDATE 18004 18005 # Only process if variable expands to non-empty 18006 18007 if test "x$FOUND_MAKE" != x; then 18008 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18009 18010 # First separate the path from the arguments. This will split at the first 18011 # space. 18012 complete="$FOUND_MAKE" 18013 path="${complete%% *}" 18014 tmp="$complete EOL" 18015 arguments="${tmp#* }" 18016 18017 # Input might be given as Windows format, start by converting to 18018 # unix format. 18019 new_path=`$CYGPATH -u "$path"` 18020 18021 # Now try to locate executable using which 18022 new_path=`$WHICH "$new_path" 2> /dev/null` 18023 # bat and cmd files are not always considered executable in cygwin causing which 18024 # to not find them 18025 if test "x$new_path" = x \ 18026 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18027 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18028 new_path=`$CYGPATH -u "$path"` 18029 fi 18030 if test "x$new_path" = x; then 18031 # Oops. Which didn't find the executable. 18032 # The splitting of arguments from the executable at a space might have been incorrect, 18033 # since paths with space are more likely in Windows. Give it another try with the whole 18034 # argument. 18035 path="$complete" 18036 arguments="EOL" 18037 new_path=`$CYGPATH -u "$path"` 18038 new_path=`$WHICH "$new_path" 2> /dev/null` 18039 # bat and cmd files are not always considered executable in cygwin causing which 18040 # to not find them 18041 if test "x$new_path" = x \ 18042 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18043 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18044 new_path=`$CYGPATH -u "$path"` 18045 fi 18046 if test "x$new_path" = x; then 18047 # It's still not found. Now this is an unrecoverable error. 18048 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18049 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18050 has_space=`$ECHO "$complete" | $GREP " "` 18051 if test "x$has_space" != x; then 18052 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18053 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18054 fi 18055 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18056 fi 18057 fi 18058 18059 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 18060 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 18061 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 18062 # "foo.exe" is OK but "foo" is an error. 18063 # 18064 # This test is therefore slightly more accurate than "test -f" to check for file presence. 18065 # It is also a way to make sure we got the proper file name for the real test later on. 18066 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 18067 if test "x$test_shortpath" = x; then 18068 # Short path failed, file does not exist as specified. 18069 # Try adding .exe or .cmd 18070 if test -f "${new_path}.exe"; then 18071 input_to_shortpath="${new_path}.exe" 18072 elif test -f "${new_path}.cmd"; then 18073 input_to_shortpath="${new_path}.cmd" 18074 else 18075 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 18076 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 18077 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 18078 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 18079 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18080 fi 18081 else 18082 input_to_shortpath="$new_path" 18083 fi 18084 18085 # Call helper function which possibly converts this using DOS-style short mode. 18086 # If so, the updated path is stored in $new_path. 18087 new_path="$input_to_shortpath" 18088 18089 input_path="$input_to_shortpath" 18090 # Check if we need to convert this using DOS-style short mode. If the path 18091 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18092 # take no chances and rewrite it. 18093 # Note: m4 eats our [], so we need to use [ and ] instead. 18094 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 18095 if test "x$has_forbidden_chars" != x; then 18096 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18097 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 18098 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 18099 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 18100 # Going to short mode and back again did indeed matter. Since short mode is 18101 # case insensitive, let's make it lowercase to improve readability. 18102 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18103 # Now convert it back to Unix-style (cygpath) 18104 input_path=`$CYGPATH -u "$shortmode_path"` 18105 new_path="$input_path" 18106 fi 18107 fi 18108 18109 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 18110 if test "x$test_cygdrive_prefix" = x; then 18111 # As a simple fix, exclude /usr/bin since it's not a real path. 18112 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 18113 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 18114 # a path prefixed by /cygdrive for fixpath to work. 18115 new_path="$CYGWIN_ROOT_PATH$input_path" 18116 fi 18117 fi 18118 18119 # remove trailing .exe if any 18120 new_path="${new_path/%.exe/}" 18121 18122 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18123 18124 # First separate the path from the arguments. This will split at the first 18125 # space. 18126 complete="$FOUND_MAKE" 18127 path="${complete%% *}" 18128 tmp="$complete EOL" 18129 arguments="${tmp#* }" 18130 18131 # Input might be given as Windows format, start by converting to 18132 # unix format. 18133 new_path="$path" 18134 18135 windows_path="$new_path" 18136 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18137 unix_path=`$CYGPATH -u "$windows_path"` 18138 new_path="$unix_path" 18139 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18140 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18141 new_path="$unix_path" 18142 fi 18143 18144 18145 # Now try to locate executable using which 18146 new_path=`$WHICH "$new_path" 2> /dev/null` 18147 18148 if test "x$new_path" = x; then 18149 # Oops. Which didn't find the executable. 18150 # The splitting of arguments from the executable at a space might have been incorrect, 18151 # since paths with space are more likely in Windows. Give it another try with the whole 18152 # argument. 18153 path="$complete" 18154 arguments="EOL" 18155 new_path="$path" 18156 18157 windows_path="$new_path" 18158 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18159 unix_path=`$CYGPATH -u "$windows_path"` 18160 new_path="$unix_path" 18161 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18162 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18163 new_path="$unix_path" 18164 fi 18165 18166 18167 new_path=`$WHICH "$new_path" 2> /dev/null` 18168 # bat and cmd files are not always considered executable in MSYS causing which 18169 # to not find them 18170 if test "x$new_path" = x \ 18171 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18172 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18173 new_path="$path" 18174 18175 windows_path="$new_path" 18176 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18177 unix_path=`$CYGPATH -u "$windows_path"` 18178 new_path="$unix_path" 18179 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18180 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18181 new_path="$unix_path" 18182 fi 18183 18184 fi 18185 18186 if test "x$new_path" = x; then 18187 # It's still not found. Now this is an unrecoverable error. 18188 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18189 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18190 has_space=`$ECHO "$complete" | $GREP " "` 18191 if test "x$has_space" != x; then 18192 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18193 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18194 fi 18195 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18196 fi 18197 fi 18198 18199 # Now new_path has a complete unix path to the binary 18200 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 18201 # Keep paths in /bin as-is, but remove trailing .exe if any 18202 new_path="${new_path/%.exe/}" 18203 # Do not save /bin paths to all_fixpath_prefixes! 18204 else 18205 # Not in mixed or Windows style, start by that. 18206 new_path=`cmd //c echo $new_path` 18207 18208 input_path="$new_path" 18209 # Check if we need to convert this using DOS-style short mode. If the path 18210 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18211 # take no chances and rewrite it. 18212 # Note: m4 eats our [], so we need to use [ and ] instead. 18213 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 18214 if test "x$has_forbidden_chars" != x; then 18215 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18216 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18217 fi 18218 18219 # Output is in $new_path 18220 18221 windows_path="$new_path" 18222 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18223 unix_path=`$CYGPATH -u "$windows_path"` 18224 new_path="$unix_path" 18225 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18226 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18227 new_path="$unix_path" 18228 fi 18229 18230 # remove trailing .exe if any 18231 new_path="${new_path/%.exe/}" 18232 18233 # Save the first 10 bytes of this path to the storage, so fixpath can work. 18234 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 18235 fi 18236 18237 else 18238 # We're on a unix platform. Hooray! :) 18239 # First separate the path from the arguments. This will split at the first 18240 # space. 18241 complete="$FOUND_MAKE" 18242 path="${complete%% *}" 18243 tmp="$complete EOL" 18244 arguments="${tmp#* }" 18245 18246 # Cannot rely on the command "which" here since it doesn't always work. 18247 is_absolute_path=`$ECHO "$path" | $GREP ^/` 18248 if test -z "$is_absolute_path"; then 18249 # Path to executable is not absolute. Find it. 18250 IFS_save="$IFS" 18251 IFS=: 18252 for p in $PATH; do 18253 if test -f "$p/$path" && test -x "$p/$path"; then 18254 new_path="$p/$path" 18255 break 18256 fi 18257 done 18258 IFS="$IFS_save" 18259 else 18260 # This is an absolute path, we can use it without further modifications. 18261 new_path="$path" 18262 fi 18263 18264 if test "x$new_path" = x; then 18265 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18266 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18267 has_space=`$ECHO "$complete" | $GREP " "` 18268 if test "x$has_space" != x; then 18269 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 18270 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 18271 fi 18272 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18273 fi 18274 fi 18275 18276 # Now join together the path and the arguments once again 18277 if test "x$arguments" != xEOL; then 18278 new_complete="$new_path ${arguments% *}" 18279 else 18280 new_complete="$new_path" 18281 fi 18282 18283 if test "x$complete" != "x$new_complete"; then 18284 FOUND_MAKE="$new_complete" 18285 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 18286 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 18287 fi 18288 fi 18289 18290 fi 18291 fi 18292 fi 18293 fi 18294 18295 fi 18296 18297 if test "x$FOUND_MAKE" = x; then 18298 if test "x$TOOLCHAIN_PATH" != x; then 18299 # We have a toolchain path, check that as well before giving up. 18300 OLD_PATH=$PATH 18301 PATH=$TOOLCHAIN_PATH:$PATH 18302 for ac_prog in gmake 18303 do 18304 # Extract the first word of "$ac_prog", so it can be a program name with args. 18305 set dummy $ac_prog; ac_word=$2 18306 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 18307 $as_echo_n "checking for $ac_word... " >&6; } 18308 if ${ac_cv_path_CHECK_TOOLSDIR_GMAKE+:} false; then : 18309 $as_echo_n "(cached) " >&6 18310 else 18311 case $CHECK_TOOLSDIR_GMAKE in 18312 [\\/]* | ?:[\\/]*) 18313 ac_cv_path_CHECK_TOOLSDIR_GMAKE="$CHECK_TOOLSDIR_GMAKE" # Let the user override the test with a path. 18314 ;; 18315 *) 18316 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 18317 for as_dir in $PATH 18318 do 18319 IFS=$as_save_IFS 18320 test -z "$as_dir" && as_dir=. 18321 for ac_exec_ext in '' $ac_executable_extensions; do 18322 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 18323 ac_cv_path_CHECK_TOOLSDIR_GMAKE="$as_dir/$ac_word$ac_exec_ext" 18324 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 18325 break 2 18326 fi 18327 done 18328 done 18329 IFS=$as_save_IFS 18330 18331 ;; 18332 esac 18333 fi 18334 CHECK_TOOLSDIR_GMAKE=$ac_cv_path_CHECK_TOOLSDIR_GMAKE 18335 if test -n "$CHECK_TOOLSDIR_GMAKE"; then 18336 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_GMAKE" >&5 18337 $as_echo "$CHECK_TOOLSDIR_GMAKE" >&6; } 18338 else 18339 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 18340 $as_echo "no" >&6; } 18341 fi 18342 18343 18344 test -n "$CHECK_TOOLSDIR_GMAKE" && break 18345 done 18346 18347 18348 MAKE_CANDIDATE=""$CHECK_TOOLSDIR_GMAKE"" 18349 DESCRIPTION="gmake in tools-dir" 18350 18351 # On Cygwin, we require a newer version of make than on other platforms 18352 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18353 MAKE_VERSION_EXPR="-e 4\." 18354 MAKE_REQUIRED_VERSION="4.0" 18355 else 18356 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 18357 MAKE_REQUIRED_VERSION="3.81" 18358 fi 18359 18360 if test "x$MAKE_CANDIDATE" != x; then 18361 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 18362 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 18363 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 18364 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 18365 if test "x$IS_GNU_MAKE" = x; then 18366 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 18367 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 18368 else 18369 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 18370 if test "x$IS_MODERN_MAKE" = x; then 18371 { $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 18372 $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;} 18373 else 18374 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 18375 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18376 MAKE_EXPECTED_ENV='cygwin' 18377 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18378 MAKE_EXPECTED_ENV='msys' 18379 else 18380 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 18381 fi 18382 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 18383 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 18384 else 18385 # Not relevant for non-Windows 18386 IS_MAKE_CORRECT_ENV=true 18387 fi 18388 if test "x$IS_MAKE_CORRECT_ENV" = x; then 18389 { $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 18390 $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;} 18391 else 18392 FOUND_MAKE=$MAKE_CANDIDATE 18393 18394 # Only process if variable expands to non-empty 18395 18396 if test "x$FOUND_MAKE" != x; then 18397 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18398 18399 # First separate the path from the arguments. This will split at the first 18400 # space. 18401 complete="$FOUND_MAKE" 18402 path="${complete%% *}" 18403 tmp="$complete EOL" 18404 arguments="${tmp#* }" 18405 18406 # Input might be given as Windows format, start by converting to 18407 # unix format. 18408 new_path=`$CYGPATH -u "$path"` 18409 18410 # Now try to locate executable using which 18411 new_path=`$WHICH "$new_path" 2> /dev/null` 18412 # bat and cmd files are not always considered executable in cygwin causing which 18413 # to not find them 18414 if test "x$new_path" = x \ 18415 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18416 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18417 new_path=`$CYGPATH -u "$path"` 18418 fi 18419 if test "x$new_path" = x; then 18420 # Oops. Which didn't find the executable. 18421 # The splitting of arguments from the executable at a space might have been incorrect, 18422 # since paths with space are more likely in Windows. Give it another try with the whole 18423 # argument. 18424 path="$complete" 18425 arguments="EOL" 18426 new_path=`$CYGPATH -u "$path"` 18427 new_path=`$WHICH "$new_path" 2> /dev/null` 18428 # bat and cmd files are not always considered executable in cygwin causing which 18429 # to not find them 18430 if test "x$new_path" = x \ 18431 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18432 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18433 new_path=`$CYGPATH -u "$path"` 18434 fi 18435 if test "x$new_path" = x; then 18436 # It's still not found. Now this is an unrecoverable error. 18437 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18438 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18439 has_space=`$ECHO "$complete" | $GREP " "` 18440 if test "x$has_space" != x; then 18441 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18442 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18443 fi 18444 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18445 fi 18446 fi 18447 18448 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 18449 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 18450 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 18451 # "foo.exe" is OK but "foo" is an error. 18452 # 18453 # This test is therefore slightly more accurate than "test -f" to check for file presence. 18454 # It is also a way to make sure we got the proper file name for the real test later on. 18455 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 18456 if test "x$test_shortpath" = x; then 18457 # Short path failed, file does not exist as specified. 18458 # Try adding .exe or .cmd 18459 if test -f "${new_path}.exe"; then 18460 input_to_shortpath="${new_path}.exe" 18461 elif test -f "${new_path}.cmd"; then 18462 input_to_shortpath="${new_path}.cmd" 18463 else 18464 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 18465 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 18466 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 18467 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 18468 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18469 fi 18470 else 18471 input_to_shortpath="$new_path" 18472 fi 18473 18474 # Call helper function which possibly converts this using DOS-style short mode. 18475 # If so, the updated path is stored in $new_path. 18476 new_path="$input_to_shortpath" 18477 18478 input_path="$input_to_shortpath" 18479 # Check if we need to convert this using DOS-style short mode. If the path 18480 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18481 # take no chances and rewrite it. 18482 # Note: m4 eats our [], so we need to use [ and ] instead. 18483 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 18484 if test "x$has_forbidden_chars" != x; then 18485 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18486 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 18487 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 18488 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 18489 # Going to short mode and back again did indeed matter. Since short mode is 18490 # case insensitive, let's make it lowercase to improve readability. 18491 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18492 # Now convert it back to Unix-style (cygpath) 18493 input_path=`$CYGPATH -u "$shortmode_path"` 18494 new_path="$input_path" 18495 fi 18496 fi 18497 18498 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 18499 if test "x$test_cygdrive_prefix" = x; then 18500 # As a simple fix, exclude /usr/bin since it's not a real path. 18501 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 18502 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 18503 # a path prefixed by /cygdrive for fixpath to work. 18504 new_path="$CYGWIN_ROOT_PATH$input_path" 18505 fi 18506 fi 18507 18508 # remove trailing .exe if any 18509 new_path="${new_path/%.exe/}" 18510 18511 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18512 18513 # First separate the path from the arguments. This will split at the first 18514 # space. 18515 complete="$FOUND_MAKE" 18516 path="${complete%% *}" 18517 tmp="$complete EOL" 18518 arguments="${tmp#* }" 18519 18520 # Input might be given as Windows format, start by converting to 18521 # unix format. 18522 new_path="$path" 18523 18524 windows_path="$new_path" 18525 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18526 unix_path=`$CYGPATH -u "$windows_path"` 18527 new_path="$unix_path" 18528 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18529 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18530 new_path="$unix_path" 18531 fi 18532 18533 18534 # Now try to locate executable using which 18535 new_path=`$WHICH "$new_path" 2> /dev/null` 18536 18537 if test "x$new_path" = x; then 18538 # Oops. Which didn't find the executable. 18539 # The splitting of arguments from the executable at a space might have been incorrect, 18540 # since paths with space are more likely in Windows. Give it another try with the whole 18541 # argument. 18542 path="$complete" 18543 arguments="EOL" 18544 new_path="$path" 18545 18546 windows_path="$new_path" 18547 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18548 unix_path=`$CYGPATH -u "$windows_path"` 18549 new_path="$unix_path" 18550 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18551 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18552 new_path="$unix_path" 18553 fi 18554 18555 18556 new_path=`$WHICH "$new_path" 2> /dev/null` 18557 # bat and cmd files are not always considered executable in MSYS causing which 18558 # to not find them 18559 if test "x$new_path" = x \ 18560 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18561 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18562 new_path="$path" 18563 18564 windows_path="$new_path" 18565 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18566 unix_path=`$CYGPATH -u "$windows_path"` 18567 new_path="$unix_path" 18568 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18569 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18570 new_path="$unix_path" 18571 fi 18572 18573 fi 18574 18575 if test "x$new_path" = x; then 18576 # It's still not found. Now this is an unrecoverable error. 18577 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18578 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18579 has_space=`$ECHO "$complete" | $GREP " "` 18580 if test "x$has_space" != x; then 18581 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18582 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18583 fi 18584 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18585 fi 18586 fi 18587 18588 # Now new_path has a complete unix path to the binary 18589 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 18590 # Keep paths in /bin as-is, but remove trailing .exe if any 18591 new_path="${new_path/%.exe/}" 18592 # Do not save /bin paths to all_fixpath_prefixes! 18593 else 18594 # Not in mixed or Windows style, start by that. 18595 new_path=`cmd //c echo $new_path` 18596 18597 input_path="$new_path" 18598 # Check if we need to convert this using DOS-style short mode. If the path 18599 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18600 # take no chances and rewrite it. 18601 # Note: m4 eats our [], so we need to use [ and ] instead. 18602 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 18603 if test "x$has_forbidden_chars" != x; then 18604 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18605 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18606 fi 18607 18608 # Output is in $new_path 18609 18610 windows_path="$new_path" 18611 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18612 unix_path=`$CYGPATH -u "$windows_path"` 18613 new_path="$unix_path" 18614 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18615 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18616 new_path="$unix_path" 18617 fi 18618 18619 # remove trailing .exe if any 18620 new_path="${new_path/%.exe/}" 18621 18622 # Save the first 10 bytes of this path to the storage, so fixpath can work. 18623 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 18624 fi 18625 18626 else 18627 # We're on a unix platform. Hooray! :) 18628 # First separate the path from the arguments. This will split at the first 18629 # space. 18630 complete="$FOUND_MAKE" 18631 path="${complete%% *}" 18632 tmp="$complete EOL" 18633 arguments="${tmp#* }" 18634 18635 # Cannot rely on the command "which" here since it doesn't always work. 18636 is_absolute_path=`$ECHO "$path" | $GREP ^/` 18637 if test -z "$is_absolute_path"; then 18638 # Path to executable is not absolute. Find it. 18639 IFS_save="$IFS" 18640 IFS=: 18641 for p in $PATH; do 18642 if test -f "$p/$path" && test -x "$p/$path"; then 18643 new_path="$p/$path" 18644 break 18645 fi 18646 done 18647 IFS="$IFS_save" 18648 else 18649 # This is an absolute path, we can use it without further modifications. 18650 new_path="$path" 18651 fi 18652 18653 if test "x$new_path" = x; then 18654 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18655 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18656 has_space=`$ECHO "$complete" | $GREP " "` 18657 if test "x$has_space" != x; then 18658 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 18659 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 18660 fi 18661 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18662 fi 18663 fi 18664 18665 # Now join together the path and the arguments once again 18666 if test "x$arguments" != xEOL; then 18667 new_complete="$new_path ${arguments% *}" 18668 else 18669 new_complete="$new_path" 18670 fi 18671 18672 if test "x$complete" != "x$new_complete"; then 18673 FOUND_MAKE="$new_complete" 18674 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 18675 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 18676 fi 18677 fi 18678 18679 fi 18680 fi 18681 fi 18682 fi 18683 18684 if test "x$FOUND_MAKE" = x; then 18685 for ac_prog in make 18686 do 18687 # Extract the first word of "$ac_prog", so it can be a program name with args. 18688 set dummy $ac_prog; ac_word=$2 18689 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 18690 $as_echo_n "checking for $ac_word... " >&6; } 18691 if ${ac_cv_path_CHECK_TOOLSDIR_MAKE+:} false; then : 18692 $as_echo_n "(cached) " >&6 18693 else 18694 case $CHECK_TOOLSDIR_MAKE in 18695 [\\/]* | ?:[\\/]*) 18696 ac_cv_path_CHECK_TOOLSDIR_MAKE="$CHECK_TOOLSDIR_MAKE" # Let the user override the test with a path. 18697 ;; 18698 *) 18699 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 18700 for as_dir in $PATH 18701 do 18702 IFS=$as_save_IFS 18703 test -z "$as_dir" && as_dir=. 18704 for ac_exec_ext in '' $ac_executable_extensions; do 18705 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 18706 ac_cv_path_CHECK_TOOLSDIR_MAKE="$as_dir/$ac_word$ac_exec_ext" 18707 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 18708 break 2 18709 fi 18710 done 18711 done 18712 IFS=$as_save_IFS 18713 18714 ;; 18715 esac 18716 fi 18717 CHECK_TOOLSDIR_MAKE=$ac_cv_path_CHECK_TOOLSDIR_MAKE 18718 if test -n "$CHECK_TOOLSDIR_MAKE"; then 18719 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_MAKE" >&5 18720 $as_echo "$CHECK_TOOLSDIR_MAKE" >&6; } 18721 else 18722 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 18723 $as_echo "no" >&6; } 18724 fi 18725 18726 18727 test -n "$CHECK_TOOLSDIR_MAKE" && break 18728 done 18729 18730 18731 MAKE_CANDIDATE=""$CHECK_TOOLSDIR_MAKE"" 18732 DESCRIPTION="make in tools-dir" 18733 18734 # On Cygwin, we require a newer version of make than on other platforms 18735 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18736 MAKE_VERSION_EXPR="-e 4\." 18737 MAKE_REQUIRED_VERSION="4.0" 18738 else 18739 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 18740 MAKE_REQUIRED_VERSION="3.81" 18741 fi 18742 18743 if test "x$MAKE_CANDIDATE" != x; then 18744 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 18745 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 18746 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 18747 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 18748 if test "x$IS_GNU_MAKE" = x; then 18749 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 18750 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 18751 else 18752 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 18753 if test "x$IS_MODERN_MAKE" = x; then 18754 { $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 18755 $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;} 18756 else 18757 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 18758 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18759 MAKE_EXPECTED_ENV='cygwin' 18760 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18761 MAKE_EXPECTED_ENV='msys' 18762 else 18763 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 18764 fi 18765 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 18766 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 18767 else 18768 # Not relevant for non-Windows 18769 IS_MAKE_CORRECT_ENV=true 18770 fi 18771 if test "x$IS_MAKE_CORRECT_ENV" = x; then 18772 { $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 18773 $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;} 18774 else 18775 FOUND_MAKE=$MAKE_CANDIDATE 18776 18777 # Only process if variable expands to non-empty 18778 18779 if test "x$FOUND_MAKE" != x; then 18780 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18781 18782 # First separate the path from the arguments. This will split at the first 18783 # space. 18784 complete="$FOUND_MAKE" 18785 path="${complete%% *}" 18786 tmp="$complete EOL" 18787 arguments="${tmp#* }" 18788 18789 # Input might be given as Windows format, start by converting to 18790 # unix format. 18791 new_path=`$CYGPATH -u "$path"` 18792 18793 # Now try to locate executable using which 18794 new_path=`$WHICH "$new_path" 2> /dev/null` 18795 # bat and cmd files are not always considered executable in cygwin causing which 18796 # to not find them 18797 if test "x$new_path" = x \ 18798 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18799 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18800 new_path=`$CYGPATH -u "$path"` 18801 fi 18802 if test "x$new_path" = x; then 18803 # Oops. Which didn't find the executable. 18804 # The splitting of arguments from the executable at a space might have been incorrect, 18805 # since paths with space are more likely in Windows. Give it another try with the whole 18806 # argument. 18807 path="$complete" 18808 arguments="EOL" 18809 new_path=`$CYGPATH -u "$path"` 18810 new_path=`$WHICH "$new_path" 2> /dev/null` 18811 # bat and cmd files are not always considered executable in cygwin causing which 18812 # to not find them 18813 if test "x$new_path" = x \ 18814 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18815 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18816 new_path=`$CYGPATH -u "$path"` 18817 fi 18818 if test "x$new_path" = x; then 18819 # It's still not found. Now this is an unrecoverable error. 18820 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18821 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18822 has_space=`$ECHO "$complete" | $GREP " "` 18823 if test "x$has_space" != x; then 18824 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18825 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18826 fi 18827 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18828 fi 18829 fi 18830 18831 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 18832 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 18833 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 18834 # "foo.exe" is OK but "foo" is an error. 18835 # 18836 # This test is therefore slightly more accurate than "test -f" to check for file presence. 18837 # It is also a way to make sure we got the proper file name for the real test later on. 18838 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 18839 if test "x$test_shortpath" = x; then 18840 # Short path failed, file does not exist as specified. 18841 # Try adding .exe or .cmd 18842 if test -f "${new_path}.exe"; then 18843 input_to_shortpath="${new_path}.exe" 18844 elif test -f "${new_path}.cmd"; then 18845 input_to_shortpath="${new_path}.cmd" 18846 else 18847 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 18848 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 18849 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 18850 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 18851 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18852 fi 18853 else 18854 input_to_shortpath="$new_path" 18855 fi 18856 18857 # Call helper function which possibly converts this using DOS-style short mode. 18858 # If so, the updated path is stored in $new_path. 18859 new_path="$input_to_shortpath" 18860 18861 input_path="$input_to_shortpath" 18862 # Check if we need to convert this using DOS-style short mode. If the path 18863 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18864 # take no chances and rewrite it. 18865 # Note: m4 eats our [], so we need to use [ and ] instead. 18866 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 18867 if test "x$has_forbidden_chars" != x; then 18868 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18869 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 18870 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 18871 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 18872 # Going to short mode and back again did indeed matter. Since short mode is 18873 # case insensitive, let's make it lowercase to improve readability. 18874 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18875 # Now convert it back to Unix-style (cygpath) 18876 input_path=`$CYGPATH -u "$shortmode_path"` 18877 new_path="$input_path" 18878 fi 18879 fi 18880 18881 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 18882 if test "x$test_cygdrive_prefix" = x; then 18883 # As a simple fix, exclude /usr/bin since it's not a real path. 18884 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 18885 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 18886 # a path prefixed by /cygdrive for fixpath to work. 18887 new_path="$CYGWIN_ROOT_PATH$input_path" 18888 fi 18889 fi 18890 18891 # remove trailing .exe if any 18892 new_path="${new_path/%.exe/}" 18893 18894 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18895 18896 # First separate the path from the arguments. This will split at the first 18897 # space. 18898 complete="$FOUND_MAKE" 18899 path="${complete%% *}" 18900 tmp="$complete EOL" 18901 arguments="${tmp#* }" 18902 18903 # Input might be given as Windows format, start by converting to 18904 # unix format. 18905 new_path="$path" 18906 18907 windows_path="$new_path" 18908 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18909 unix_path=`$CYGPATH -u "$windows_path"` 18910 new_path="$unix_path" 18911 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18912 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18913 new_path="$unix_path" 18914 fi 18915 18916 18917 # Now try to locate executable using which 18918 new_path=`$WHICH "$new_path" 2> /dev/null` 18919 18920 if test "x$new_path" = x; then 18921 # Oops. Which didn't find the executable. 18922 # The splitting of arguments from the executable at a space might have been incorrect, 18923 # since paths with space are more likely in Windows. Give it another try with the whole 18924 # argument. 18925 path="$complete" 18926 arguments="EOL" 18927 new_path="$path" 18928 18929 windows_path="$new_path" 18930 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18931 unix_path=`$CYGPATH -u "$windows_path"` 18932 new_path="$unix_path" 18933 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18934 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18935 new_path="$unix_path" 18936 fi 18937 18938 18939 new_path=`$WHICH "$new_path" 2> /dev/null` 18940 # bat and cmd files are not always considered executable in MSYS causing which 18941 # to not find them 18942 if test "x$new_path" = x \ 18943 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18944 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18945 new_path="$path" 18946 18947 windows_path="$new_path" 18948 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18949 unix_path=`$CYGPATH -u "$windows_path"` 18950 new_path="$unix_path" 18951 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18952 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18953 new_path="$unix_path" 18954 fi 18955 18956 fi 18957 18958 if test "x$new_path" = x; then 18959 # It's still not found. Now this is an unrecoverable error. 18960 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18961 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18962 has_space=`$ECHO "$complete" | $GREP " "` 18963 if test "x$has_space" != x; then 18964 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18965 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18966 fi 18967 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18968 fi 18969 fi 18970 18971 # Now new_path has a complete unix path to the binary 18972 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 18973 # Keep paths in /bin as-is, but remove trailing .exe if any 18974 new_path="${new_path/%.exe/}" 18975 # Do not save /bin paths to all_fixpath_prefixes! 18976 else 18977 # Not in mixed or Windows style, start by that. 18978 new_path=`cmd //c echo $new_path` 18979 18980 input_path="$new_path" 18981 # Check if we need to convert this using DOS-style short mode. If the path 18982 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18983 # take no chances and rewrite it. 18984 # Note: m4 eats our [], so we need to use [ and ] instead. 18985 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 18986 if test "x$has_forbidden_chars" != x; then 18987 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18988 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18989 fi 18990 18991 # Output is in $new_path 18992 18993 windows_path="$new_path" 18994 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18995 unix_path=`$CYGPATH -u "$windows_path"` 18996 new_path="$unix_path" 18997 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18998 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18999 new_path="$unix_path" 19000 fi 19001 19002 # remove trailing .exe if any 19003 new_path="${new_path/%.exe/}" 19004 19005 # Save the first 10 bytes of this path to the storage, so fixpath can work. 19006 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 19007 fi 19008 19009 else 19010 # We're on a unix platform. Hooray! :) 19011 # First separate the path from the arguments. This will split at the first 19012 # space. 19013 complete="$FOUND_MAKE" 19014 path="${complete%% *}" 19015 tmp="$complete EOL" 19016 arguments="${tmp#* }" 19017 19018 # Cannot rely on the command "which" here since it doesn't always work. 19019 is_absolute_path=`$ECHO "$path" | $GREP ^/` 19020 if test -z "$is_absolute_path"; then 19021 # Path to executable is not absolute. Find it. 19022 IFS_save="$IFS" 19023 IFS=: 19024 for p in $PATH; do 19025 if test -f "$p/$path" && test -x "$p/$path"; then 19026 new_path="$p/$path" 19027 break 19028 fi 19029 done 19030 IFS="$IFS_save" 19031 else 19032 # This is an absolute path, we can use it without further modifications. 19033 new_path="$path" 19034 fi 19035 19036 if test "x$new_path" = x; then 19037 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19038 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19039 has_space=`$ECHO "$complete" | $GREP " "` 19040 if test "x$has_space" != x; then 19041 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 19042 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 19043 fi 19044 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19045 fi 19046 fi 19047 19048 # Now join together the path and the arguments once again 19049 if test "x$arguments" != xEOL; then 19050 new_complete="$new_path ${arguments% *}" 19051 else 19052 new_complete="$new_path" 19053 fi 19054 19055 if test "x$complete" != "x$new_complete"; then 19056 FOUND_MAKE="$new_complete" 19057 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 19058 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 19059 fi 19060 fi 19061 19062 fi 19063 fi 19064 fi 19065 fi 19066 19067 fi 19068 PATH=$OLD_PATH 19069 fi 19070 fi 19071 19072 if test "x$FOUND_MAKE" = x; then 19073 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 19074 fi 19075 19076 else 19077 # The variable is set, but is it from the command line or the environment? 19078 19079 # Try to remove the string !MAKE! from our list. 19080 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MAKE!/} 19081 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 19082 # If it failed, the variable was not from the command line. Ignore it, 19083 # but warn the user (except for BASH, which is always set by the calling BASH). 19084 if test "xMAKE" != xBASH; then 19085 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MAKE from the environment. Use command line variables instead." >&5 19086 $as_echo "$as_me: WARNING: Ignoring value of MAKE from the environment. Use command line variables instead." >&2;} 19087 fi 19088 # Try to locate tool using the code snippet 19089 19090 # Try our hardest to locate a correct version of GNU make 19091 for ac_prog in gmake 19092 do 19093 # Extract the first word of "$ac_prog", so it can be a program name with args. 19094 set dummy $ac_prog; ac_word=$2 19095 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 19096 $as_echo_n "checking for $ac_word... " >&6; } 19097 if ${ac_cv_path_CHECK_GMAKE+:} false; then : 19098 $as_echo_n "(cached) " >&6 19099 else 19100 case $CHECK_GMAKE in 19101 [\\/]* | ?:[\\/]*) 19102 ac_cv_path_CHECK_GMAKE="$CHECK_GMAKE" # Let the user override the test with a path. 19103 ;; 19104 *) 19105 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 19106 for as_dir in $PATH 19107 do 19108 IFS=$as_save_IFS 19109 test -z "$as_dir" && as_dir=. 19110 for ac_exec_ext in '' $ac_executable_extensions; do 19111 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 19112 ac_cv_path_CHECK_GMAKE="$as_dir/$ac_word$ac_exec_ext" 19113 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 19114 break 2 19115 fi 19116 done 19117 done 19118 IFS=$as_save_IFS 19119 19120 ;; 19121 esac 19122 fi 19123 CHECK_GMAKE=$ac_cv_path_CHECK_GMAKE 19124 if test -n "$CHECK_GMAKE"; then 19125 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_GMAKE" >&5 19126 $as_echo "$CHECK_GMAKE" >&6; } 19127 else 19128 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 19129 $as_echo "no" >&6; } 19130 fi 19131 19132 19133 test -n "$CHECK_GMAKE" && break 19134 done 19135 19136 19137 MAKE_CANDIDATE=""$CHECK_GMAKE"" 19138 DESCRIPTION="gmake in PATH" 19139 19140 # On Cygwin, we require a newer version of make than on other platforms 19141 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19142 MAKE_VERSION_EXPR="-e 4\." 19143 MAKE_REQUIRED_VERSION="4.0" 19144 else 19145 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 19146 MAKE_REQUIRED_VERSION="3.81" 19147 fi 19148 19149 if test "x$MAKE_CANDIDATE" != x; then 19150 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 19151 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 19152 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 19153 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 19154 if test "x$IS_GNU_MAKE" = x; then 19155 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 19156 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 19157 else 19158 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 19159 if test "x$IS_MODERN_MAKE" = x; then 19160 { $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 19161 $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;} 19162 else 19163 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 19164 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19165 MAKE_EXPECTED_ENV='cygwin' 19166 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19167 MAKE_EXPECTED_ENV='msys' 19168 else 19169 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 19170 fi 19171 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 19172 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 19173 else 19174 # Not relevant for non-Windows 19175 IS_MAKE_CORRECT_ENV=true 19176 fi 19177 if test "x$IS_MAKE_CORRECT_ENV" = x; then 19178 { $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 19179 $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;} 19180 else 19181 FOUND_MAKE=$MAKE_CANDIDATE 19182 19183 # Only process if variable expands to non-empty 19184 19185 if test "x$FOUND_MAKE" != x; then 19186 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19187 19188 # First separate the path from the arguments. This will split at the first 19189 # space. 19190 complete="$FOUND_MAKE" 19191 path="${complete%% *}" 19192 tmp="$complete EOL" 19193 arguments="${tmp#* }" 19194 19195 # Input might be given as Windows format, start by converting to 19196 # unix format. 19197 new_path=`$CYGPATH -u "$path"` 19198 19199 # Now try to locate executable using which 19200 new_path=`$WHICH "$new_path" 2> /dev/null` 19201 # bat and cmd files are not always considered executable in cygwin causing which 19202 # to not find them 19203 if test "x$new_path" = x \ 19204 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19205 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19206 new_path=`$CYGPATH -u "$path"` 19207 fi 19208 if test "x$new_path" = x; then 19209 # Oops. Which didn't find the executable. 19210 # The splitting of arguments from the executable at a space might have been incorrect, 19211 # since paths with space are more likely in Windows. Give it another try with the whole 19212 # argument. 19213 path="$complete" 19214 arguments="EOL" 19215 new_path=`$CYGPATH -u "$path"` 19216 new_path=`$WHICH "$new_path" 2> /dev/null` 19217 # bat and cmd files are not always considered executable in cygwin causing which 19218 # to not find them 19219 if test "x$new_path" = x \ 19220 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19221 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19222 new_path=`$CYGPATH -u "$path"` 19223 fi 19224 if test "x$new_path" = x; then 19225 # It's still not found. Now this is an unrecoverable error. 19226 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19227 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19228 has_space=`$ECHO "$complete" | $GREP " "` 19229 if test "x$has_space" != x; then 19230 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19231 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19232 fi 19233 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19234 fi 19235 fi 19236 19237 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 19238 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 19239 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 19240 # "foo.exe" is OK but "foo" is an error. 19241 # 19242 # This test is therefore slightly more accurate than "test -f" to check for file presence. 19243 # It is also a way to make sure we got the proper file name for the real test later on. 19244 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 19245 if test "x$test_shortpath" = x; then 19246 # Short path failed, file does not exist as specified. 19247 # Try adding .exe or .cmd 19248 if test -f "${new_path}.exe"; then 19249 input_to_shortpath="${new_path}.exe" 19250 elif test -f "${new_path}.cmd"; then 19251 input_to_shortpath="${new_path}.cmd" 19252 else 19253 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 19254 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 19255 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 19256 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 19257 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19258 fi 19259 else 19260 input_to_shortpath="$new_path" 19261 fi 19262 19263 # Call helper function which possibly converts this using DOS-style short mode. 19264 # If so, the updated path is stored in $new_path. 19265 new_path="$input_to_shortpath" 19266 19267 input_path="$input_to_shortpath" 19268 # Check if we need to convert this using DOS-style short mode. If the path 19269 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19270 # take no chances and rewrite it. 19271 # Note: m4 eats our [], so we need to use [ and ] instead. 19272 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 19273 if test "x$has_forbidden_chars" != x; then 19274 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19275 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 19276 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 19277 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 19278 # Going to short mode and back again did indeed matter. Since short mode is 19279 # case insensitive, let's make it lowercase to improve readability. 19280 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19281 # Now convert it back to Unix-style (cygpath) 19282 input_path=`$CYGPATH -u "$shortmode_path"` 19283 new_path="$input_path" 19284 fi 19285 fi 19286 19287 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 19288 if test "x$test_cygdrive_prefix" = x; then 19289 # As a simple fix, exclude /usr/bin since it's not a real path. 19290 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 19291 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 19292 # a path prefixed by /cygdrive for fixpath to work. 19293 new_path="$CYGWIN_ROOT_PATH$input_path" 19294 fi 19295 fi 19296 19297 # remove trailing .exe if any 19298 new_path="${new_path/%.exe/}" 19299 19300 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19301 19302 # First separate the path from the arguments. This will split at the first 19303 # space. 19304 complete="$FOUND_MAKE" 19305 path="${complete%% *}" 19306 tmp="$complete EOL" 19307 arguments="${tmp#* }" 19308 19309 # Input might be given as Windows format, start by converting to 19310 # unix format. 19311 new_path="$path" 19312 19313 windows_path="$new_path" 19314 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19315 unix_path=`$CYGPATH -u "$windows_path"` 19316 new_path="$unix_path" 19317 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19318 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19319 new_path="$unix_path" 19320 fi 19321 19322 19323 # Now try to locate executable using which 19324 new_path=`$WHICH "$new_path" 2> /dev/null` 19325 19326 if test "x$new_path" = x; then 19327 # Oops. Which didn't find the executable. 19328 # The splitting of arguments from the executable at a space might have been incorrect, 19329 # since paths with space are more likely in Windows. Give it another try with the whole 19330 # argument. 19331 path="$complete" 19332 arguments="EOL" 19333 new_path="$path" 19334 19335 windows_path="$new_path" 19336 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19337 unix_path=`$CYGPATH -u "$windows_path"` 19338 new_path="$unix_path" 19339 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19340 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19341 new_path="$unix_path" 19342 fi 19343 19344 19345 new_path=`$WHICH "$new_path" 2> /dev/null` 19346 # bat and cmd files are not always considered executable in MSYS causing which 19347 # to not find them 19348 if test "x$new_path" = x \ 19349 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19350 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19351 new_path="$path" 19352 19353 windows_path="$new_path" 19354 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19355 unix_path=`$CYGPATH -u "$windows_path"` 19356 new_path="$unix_path" 19357 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19358 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19359 new_path="$unix_path" 19360 fi 19361 19362 fi 19363 19364 if test "x$new_path" = x; then 19365 # It's still not found. Now this is an unrecoverable error. 19366 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19367 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19368 has_space=`$ECHO "$complete" | $GREP " "` 19369 if test "x$has_space" != x; then 19370 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19371 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19372 fi 19373 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19374 fi 19375 fi 19376 19377 # Now new_path has a complete unix path to the binary 19378 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 19379 # Keep paths in /bin as-is, but remove trailing .exe if any 19380 new_path="${new_path/%.exe/}" 19381 # Do not save /bin paths to all_fixpath_prefixes! 19382 else 19383 # Not in mixed or Windows style, start by that. 19384 new_path=`cmd //c echo $new_path` 19385 19386 input_path="$new_path" 19387 # Check if we need to convert this using DOS-style short mode. If the path 19388 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19389 # take no chances and rewrite it. 19390 # Note: m4 eats our [], so we need to use [ and ] instead. 19391 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 19392 if test "x$has_forbidden_chars" != x; then 19393 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19394 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19395 fi 19396 19397 # Output is in $new_path 19398 19399 windows_path="$new_path" 19400 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19401 unix_path=`$CYGPATH -u "$windows_path"` 19402 new_path="$unix_path" 19403 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19404 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19405 new_path="$unix_path" 19406 fi 19407 19408 # remove trailing .exe if any 19409 new_path="${new_path/%.exe/}" 19410 19411 # Save the first 10 bytes of this path to the storage, so fixpath can work. 19412 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 19413 fi 19414 19415 else 19416 # We're on a unix platform. Hooray! :) 19417 # First separate the path from the arguments. This will split at the first 19418 # space. 19419 complete="$FOUND_MAKE" 19420 path="${complete%% *}" 19421 tmp="$complete EOL" 19422 arguments="${tmp#* }" 19423 19424 # Cannot rely on the command "which" here since it doesn't always work. 19425 is_absolute_path=`$ECHO "$path" | $GREP ^/` 19426 if test -z "$is_absolute_path"; then 19427 # Path to executable is not absolute. Find it. 19428 IFS_save="$IFS" 19429 IFS=: 19430 for p in $PATH; do 19431 if test -f "$p/$path" && test -x "$p/$path"; then 19432 new_path="$p/$path" 19433 break 19434 fi 19435 done 19436 IFS="$IFS_save" 19437 else 19438 # This is an absolute path, we can use it without further modifications. 19439 new_path="$path" 19440 fi 19441 19442 if test "x$new_path" = x; then 19443 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19444 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19445 has_space=`$ECHO "$complete" | $GREP " "` 19446 if test "x$has_space" != x; then 19447 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 19448 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 19449 fi 19450 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19451 fi 19452 fi 19453 19454 # Now join together the path and the arguments once again 19455 if test "x$arguments" != xEOL; then 19456 new_complete="$new_path ${arguments% *}" 19457 else 19458 new_complete="$new_path" 19459 fi 19460 19461 if test "x$complete" != "x$new_complete"; then 19462 FOUND_MAKE="$new_complete" 19463 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 19464 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 19465 fi 19466 fi 19467 19468 fi 19469 fi 19470 fi 19471 fi 19472 19473 19474 if test "x$FOUND_MAKE" = x; then 19475 for ac_prog in make 19476 do 19477 # Extract the first word of "$ac_prog", so it can be a program name with args. 19478 set dummy $ac_prog; ac_word=$2 19479 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 19480 $as_echo_n "checking for $ac_word... " >&6; } 19481 if ${ac_cv_path_CHECK_MAKE+:} false; then : 19482 $as_echo_n "(cached) " >&6 19483 else 19484 case $CHECK_MAKE in 19485 [\\/]* | ?:[\\/]*) 19486 ac_cv_path_CHECK_MAKE="$CHECK_MAKE" # Let the user override the test with a path. 19487 ;; 19488 *) 19489 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 19490 for as_dir in $PATH 19491 do 19492 IFS=$as_save_IFS 19493 test -z "$as_dir" && as_dir=. 19494 for ac_exec_ext in '' $ac_executable_extensions; do 19495 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 19496 ac_cv_path_CHECK_MAKE="$as_dir/$ac_word$ac_exec_ext" 19497 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 19498 break 2 19499 fi 19500 done 19501 done 19502 IFS=$as_save_IFS 19503 19504 ;; 19505 esac 19506 fi 19507 CHECK_MAKE=$ac_cv_path_CHECK_MAKE 19508 if test -n "$CHECK_MAKE"; then 19509 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_MAKE" >&5 19510 $as_echo "$CHECK_MAKE" >&6; } 19511 else 19512 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 19513 $as_echo "no" >&6; } 19514 fi 19515 19516 19517 test -n "$CHECK_MAKE" && break 19518 done 19519 19520 19521 MAKE_CANDIDATE=""$CHECK_MAKE"" 19522 DESCRIPTION="make in PATH" 19523 19524 # On Cygwin, we require a newer version of make than on other platforms 19525 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19526 MAKE_VERSION_EXPR="-e 4\." 19527 MAKE_REQUIRED_VERSION="4.0" 19528 else 19529 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 19530 MAKE_REQUIRED_VERSION="3.81" 19531 fi 19532 19533 if test "x$MAKE_CANDIDATE" != x; then 19534 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 19535 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 19536 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 19537 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 19538 if test "x$IS_GNU_MAKE" = x; then 19539 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 19540 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 19541 else 19542 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 19543 if test "x$IS_MODERN_MAKE" = x; then 19544 { $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 19545 $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;} 19546 else 19547 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 19548 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19549 MAKE_EXPECTED_ENV='cygwin' 19550 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19551 MAKE_EXPECTED_ENV='msys' 19552 else 19553 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 19554 fi 19555 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 19556 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 19557 else 19558 # Not relevant for non-Windows 19559 IS_MAKE_CORRECT_ENV=true 19560 fi 19561 if test "x$IS_MAKE_CORRECT_ENV" = x; then 19562 { $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 19563 $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;} 19564 else 19565 FOUND_MAKE=$MAKE_CANDIDATE 19566 19567 # Only process if variable expands to non-empty 19568 19569 if test "x$FOUND_MAKE" != x; then 19570 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19571 19572 # First separate the path from the arguments. This will split at the first 19573 # space. 19574 complete="$FOUND_MAKE" 19575 path="${complete%% *}" 19576 tmp="$complete EOL" 19577 arguments="${tmp#* }" 19578 19579 # Input might be given as Windows format, start by converting to 19580 # unix format. 19581 new_path=`$CYGPATH -u "$path"` 19582 19583 # Now try to locate executable using which 19584 new_path=`$WHICH "$new_path" 2> /dev/null` 19585 # bat and cmd files are not always considered executable in cygwin causing which 19586 # to not find them 19587 if test "x$new_path" = x \ 19588 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19589 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19590 new_path=`$CYGPATH -u "$path"` 19591 fi 19592 if test "x$new_path" = x; then 19593 # Oops. Which didn't find the executable. 19594 # The splitting of arguments from the executable at a space might have been incorrect, 19595 # since paths with space are more likely in Windows. Give it another try with the whole 19596 # argument. 19597 path="$complete" 19598 arguments="EOL" 19599 new_path=`$CYGPATH -u "$path"` 19600 new_path=`$WHICH "$new_path" 2> /dev/null` 19601 # bat and cmd files are not always considered executable in cygwin causing which 19602 # to not find them 19603 if test "x$new_path" = x \ 19604 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19605 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19606 new_path=`$CYGPATH -u "$path"` 19607 fi 19608 if test "x$new_path" = x; then 19609 # It's still not found. Now this is an unrecoverable error. 19610 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19611 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19612 has_space=`$ECHO "$complete" | $GREP " "` 19613 if test "x$has_space" != x; then 19614 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19615 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19616 fi 19617 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19618 fi 19619 fi 19620 19621 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 19622 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 19623 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 19624 # "foo.exe" is OK but "foo" is an error. 19625 # 19626 # This test is therefore slightly more accurate than "test -f" to check for file presence. 19627 # It is also a way to make sure we got the proper file name for the real test later on. 19628 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 19629 if test "x$test_shortpath" = x; then 19630 # Short path failed, file does not exist as specified. 19631 # Try adding .exe or .cmd 19632 if test -f "${new_path}.exe"; then 19633 input_to_shortpath="${new_path}.exe" 19634 elif test -f "${new_path}.cmd"; then 19635 input_to_shortpath="${new_path}.cmd" 19636 else 19637 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 19638 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 19639 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 19640 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 19641 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19642 fi 19643 else 19644 input_to_shortpath="$new_path" 19645 fi 19646 19647 # Call helper function which possibly converts this using DOS-style short mode. 19648 # If so, the updated path is stored in $new_path. 19649 new_path="$input_to_shortpath" 19650 19651 input_path="$input_to_shortpath" 19652 # Check if we need to convert this using DOS-style short mode. If the path 19653 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19654 # take no chances and rewrite it. 19655 # Note: m4 eats our [], so we need to use [ and ] instead. 19656 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 19657 if test "x$has_forbidden_chars" != x; then 19658 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19659 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 19660 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 19661 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 19662 # Going to short mode and back again did indeed matter. Since short mode is 19663 # case insensitive, let's make it lowercase to improve readability. 19664 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19665 # Now convert it back to Unix-style (cygpath) 19666 input_path=`$CYGPATH -u "$shortmode_path"` 19667 new_path="$input_path" 19668 fi 19669 fi 19670 19671 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 19672 if test "x$test_cygdrive_prefix" = x; then 19673 # As a simple fix, exclude /usr/bin since it's not a real path. 19674 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 19675 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 19676 # a path prefixed by /cygdrive for fixpath to work. 19677 new_path="$CYGWIN_ROOT_PATH$input_path" 19678 fi 19679 fi 19680 19681 # remove trailing .exe if any 19682 new_path="${new_path/%.exe/}" 19683 19684 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19685 19686 # First separate the path from the arguments. This will split at the first 19687 # space. 19688 complete="$FOUND_MAKE" 19689 path="${complete%% *}" 19690 tmp="$complete EOL" 19691 arguments="${tmp#* }" 19692 19693 # Input might be given as Windows format, start by converting to 19694 # unix format. 19695 new_path="$path" 19696 19697 windows_path="$new_path" 19698 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19699 unix_path=`$CYGPATH -u "$windows_path"` 19700 new_path="$unix_path" 19701 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19702 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19703 new_path="$unix_path" 19704 fi 19705 19706 19707 # Now try to locate executable using which 19708 new_path=`$WHICH "$new_path" 2> /dev/null` 19709 19710 if test "x$new_path" = x; then 19711 # Oops. Which didn't find the executable. 19712 # The splitting of arguments from the executable at a space might have been incorrect, 19713 # since paths with space are more likely in Windows. Give it another try with the whole 19714 # argument. 19715 path="$complete" 19716 arguments="EOL" 19717 new_path="$path" 19718 19719 windows_path="$new_path" 19720 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19721 unix_path=`$CYGPATH -u "$windows_path"` 19722 new_path="$unix_path" 19723 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19724 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19725 new_path="$unix_path" 19726 fi 19727 19728 19729 new_path=`$WHICH "$new_path" 2> /dev/null` 19730 # bat and cmd files are not always considered executable in MSYS causing which 19731 # to not find them 19732 if test "x$new_path" = x \ 19733 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19734 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19735 new_path="$path" 19736 19737 windows_path="$new_path" 19738 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19739 unix_path=`$CYGPATH -u "$windows_path"` 19740 new_path="$unix_path" 19741 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19742 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19743 new_path="$unix_path" 19744 fi 19745 19746 fi 19747 19748 if test "x$new_path" = x; then 19749 # It's still not found. Now this is an unrecoverable error. 19750 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19751 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19752 has_space=`$ECHO "$complete" | $GREP " "` 19753 if test "x$has_space" != x; then 19754 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19755 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19756 fi 19757 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19758 fi 19759 fi 19760 19761 # Now new_path has a complete unix path to the binary 19762 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 19763 # Keep paths in /bin as-is, but remove trailing .exe if any 19764 new_path="${new_path/%.exe/}" 19765 # Do not save /bin paths to all_fixpath_prefixes! 19766 else 19767 # Not in mixed or Windows style, start by that. 19768 new_path=`cmd //c echo $new_path` 19769 19770 input_path="$new_path" 19771 # Check if we need to convert this using DOS-style short mode. If the path 19772 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19773 # take no chances and rewrite it. 19774 # Note: m4 eats our [], so we need to use [ and ] instead. 19775 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 19776 if test "x$has_forbidden_chars" != x; then 19777 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19778 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19779 fi 19780 19781 # Output is in $new_path 19782 19783 windows_path="$new_path" 19784 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19785 unix_path=`$CYGPATH -u "$windows_path"` 19786 new_path="$unix_path" 19787 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19788 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19789 new_path="$unix_path" 19790 fi 19791 19792 # remove trailing .exe if any 19793 new_path="${new_path/%.exe/}" 19794 19795 # Save the first 10 bytes of this path to the storage, so fixpath can work. 19796 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 19797 fi 19798 19799 else 19800 # We're on a unix platform. Hooray! :) 19801 # First separate the path from the arguments. This will split at the first 19802 # space. 19803 complete="$FOUND_MAKE" 19804 path="${complete%% *}" 19805 tmp="$complete EOL" 19806 arguments="${tmp#* }" 19807 19808 # Cannot rely on the command "which" here since it doesn't always work. 19809 is_absolute_path=`$ECHO "$path" | $GREP ^/` 19810 if test -z "$is_absolute_path"; then 19811 # Path to executable is not absolute. Find it. 19812 IFS_save="$IFS" 19813 IFS=: 19814 for p in $PATH; do 19815 if test -f "$p/$path" && test -x "$p/$path"; then 19816 new_path="$p/$path" 19817 break 19818 fi 19819 done 19820 IFS="$IFS_save" 19821 else 19822 # This is an absolute path, we can use it without further modifications. 19823 new_path="$path" 19824 fi 19825 19826 if test "x$new_path" = x; then 19827 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19828 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19829 has_space=`$ECHO "$complete" | $GREP " "` 19830 if test "x$has_space" != x; then 19831 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 19832 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 19833 fi 19834 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19835 fi 19836 fi 19837 19838 # Now join together the path and the arguments once again 19839 if test "x$arguments" != xEOL; then 19840 new_complete="$new_path ${arguments% *}" 19841 else 19842 new_complete="$new_path" 19843 fi 19844 19845 if test "x$complete" != "x$new_complete"; then 19846 FOUND_MAKE="$new_complete" 19847 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 19848 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 19849 fi 19850 fi 19851 19852 fi 19853 fi 19854 fi 19855 fi 19856 19857 fi 19858 19859 if test "x$FOUND_MAKE" = x; then 19860 if test "x$TOOLCHAIN_PATH" != x; then 19861 # We have a toolchain path, check that as well before giving up. 19862 OLD_PATH=$PATH 19863 PATH=$TOOLCHAIN_PATH:$PATH 19864 for ac_prog in gmake 19865 do 19866 # Extract the first word of "$ac_prog", so it can be a program name with args. 19867 set dummy $ac_prog; ac_word=$2 19868 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 19869 $as_echo_n "checking for $ac_word... " >&6; } 19870 if ${ac_cv_path_CHECK_TOOLSDIR_GMAKE+:} false; then : 19871 $as_echo_n "(cached) " >&6 19872 else 19873 case $CHECK_TOOLSDIR_GMAKE in 19874 [\\/]* | ?:[\\/]*) 19875 ac_cv_path_CHECK_TOOLSDIR_GMAKE="$CHECK_TOOLSDIR_GMAKE" # Let the user override the test with a path. 19876 ;; 19877 *) 19878 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 19879 for as_dir in $PATH 19880 do 19881 IFS=$as_save_IFS 19882 test -z "$as_dir" && as_dir=. 19883 for ac_exec_ext in '' $ac_executable_extensions; do 19884 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 19885 ac_cv_path_CHECK_TOOLSDIR_GMAKE="$as_dir/$ac_word$ac_exec_ext" 19886 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 19887 break 2 19888 fi 19889 done 19890 done 19891 IFS=$as_save_IFS 19892 19893 ;; 19894 esac 19895 fi 19896 CHECK_TOOLSDIR_GMAKE=$ac_cv_path_CHECK_TOOLSDIR_GMAKE 19897 if test -n "$CHECK_TOOLSDIR_GMAKE"; then 19898 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_GMAKE" >&5 19899 $as_echo "$CHECK_TOOLSDIR_GMAKE" >&6; } 19900 else 19901 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 19902 $as_echo "no" >&6; } 19903 fi 19904 19905 19906 test -n "$CHECK_TOOLSDIR_GMAKE" && break 19907 done 19908 19909 19910 MAKE_CANDIDATE=""$CHECK_TOOLSDIR_GMAKE"" 19911 DESCRIPTION="gmake in tools-dir" 19912 19913 # On Cygwin, we require a newer version of make than on other platforms 19914 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19915 MAKE_VERSION_EXPR="-e 4\." 19916 MAKE_REQUIRED_VERSION="4.0" 19917 else 19918 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 19919 MAKE_REQUIRED_VERSION="3.81" 19920 fi 19921 19922 if test "x$MAKE_CANDIDATE" != x; then 19923 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 19924 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 19925 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 19926 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 19927 if test "x$IS_GNU_MAKE" = x; then 19928 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 19929 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 19930 else 19931 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 19932 if test "x$IS_MODERN_MAKE" = x; then 19933 { $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 19934 $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;} 19935 else 19936 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 19937 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19938 MAKE_EXPECTED_ENV='cygwin' 19939 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19940 MAKE_EXPECTED_ENV='msys' 19941 else 19942 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 19943 fi 19944 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 19945 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 19946 else 19947 # Not relevant for non-Windows 19948 IS_MAKE_CORRECT_ENV=true 19949 fi 19950 if test "x$IS_MAKE_CORRECT_ENV" = x; then 19951 { $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 19952 $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;} 19953 else 19954 FOUND_MAKE=$MAKE_CANDIDATE 19955 19956 # Only process if variable expands to non-empty 19957 19958 if test "x$FOUND_MAKE" != x; then 19959 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19960 19961 # First separate the path from the arguments. This will split at the first 19962 # space. 19963 complete="$FOUND_MAKE" 19964 path="${complete%% *}" 19965 tmp="$complete EOL" 19966 arguments="${tmp#* }" 19967 19968 # Input might be given as Windows format, start by converting to 19969 # unix format. 19970 new_path=`$CYGPATH -u "$path"` 19971 19972 # Now try to locate executable using which 19973 new_path=`$WHICH "$new_path" 2> /dev/null` 19974 # bat and cmd files are not always considered executable in cygwin causing which 19975 # to not find them 19976 if test "x$new_path" = x \ 19977 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19978 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19979 new_path=`$CYGPATH -u "$path"` 19980 fi 19981 if test "x$new_path" = x; then 19982 # Oops. Which didn't find the executable. 19983 # The splitting of arguments from the executable at a space might have been incorrect, 19984 # since paths with space are more likely in Windows. Give it another try with the whole 19985 # argument. 19986 path="$complete" 19987 arguments="EOL" 19988 new_path=`$CYGPATH -u "$path"` 19989 new_path=`$WHICH "$new_path" 2> /dev/null` 19990 # bat and cmd files are not always considered executable in cygwin causing which 19991 # to not find them 19992 if test "x$new_path" = x \ 19993 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19994 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19995 new_path=`$CYGPATH -u "$path"` 19996 fi 19997 if test "x$new_path" = x; then 19998 # It's still not found. Now this is an unrecoverable error. 19999 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20000 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20001 has_space=`$ECHO "$complete" | $GREP " "` 20002 if test "x$has_space" != x; then 20003 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20004 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20005 fi 20006 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20007 fi 20008 fi 20009 20010 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 20011 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 20012 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 20013 # "foo.exe" is OK but "foo" is an error. 20014 # 20015 # This test is therefore slightly more accurate than "test -f" to check for file presence. 20016 # It is also a way to make sure we got the proper file name for the real test later on. 20017 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 20018 if test "x$test_shortpath" = x; then 20019 # Short path failed, file does not exist as specified. 20020 # Try adding .exe or .cmd 20021 if test -f "${new_path}.exe"; then 20022 input_to_shortpath="${new_path}.exe" 20023 elif test -f "${new_path}.cmd"; then 20024 input_to_shortpath="${new_path}.cmd" 20025 else 20026 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 20027 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 20028 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 20029 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 20030 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20031 fi 20032 else 20033 input_to_shortpath="$new_path" 20034 fi 20035 20036 # Call helper function which possibly converts this using DOS-style short mode. 20037 # If so, the updated path is stored in $new_path. 20038 new_path="$input_to_shortpath" 20039 20040 input_path="$input_to_shortpath" 20041 # Check if we need to convert this using DOS-style short mode. If the path 20042 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20043 # take no chances and rewrite it. 20044 # Note: m4 eats our [], so we need to use [ and ] instead. 20045 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 20046 if test "x$has_forbidden_chars" != x; then 20047 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20048 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 20049 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 20050 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 20051 # Going to short mode and back again did indeed matter. Since short mode is 20052 # case insensitive, let's make it lowercase to improve readability. 20053 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20054 # Now convert it back to Unix-style (cygpath) 20055 input_path=`$CYGPATH -u "$shortmode_path"` 20056 new_path="$input_path" 20057 fi 20058 fi 20059 20060 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 20061 if test "x$test_cygdrive_prefix" = x; then 20062 # As a simple fix, exclude /usr/bin since it's not a real path. 20063 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 20064 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 20065 # a path prefixed by /cygdrive for fixpath to work. 20066 new_path="$CYGWIN_ROOT_PATH$input_path" 20067 fi 20068 fi 20069 20070 # remove trailing .exe if any 20071 new_path="${new_path/%.exe/}" 20072 20073 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20074 20075 # First separate the path from the arguments. This will split at the first 20076 # space. 20077 complete="$FOUND_MAKE" 20078 path="${complete%% *}" 20079 tmp="$complete EOL" 20080 arguments="${tmp#* }" 20081 20082 # Input might be given as Windows format, start by converting to 20083 # unix format. 20084 new_path="$path" 20085 20086 windows_path="$new_path" 20087 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20088 unix_path=`$CYGPATH -u "$windows_path"` 20089 new_path="$unix_path" 20090 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20091 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20092 new_path="$unix_path" 20093 fi 20094 20095 20096 # Now try to locate executable using which 20097 new_path=`$WHICH "$new_path" 2> /dev/null` 20098 20099 if test "x$new_path" = x; then 20100 # Oops. Which didn't find the executable. 20101 # The splitting of arguments from the executable at a space might have been incorrect, 20102 # since paths with space are more likely in Windows. Give it another try with the whole 20103 # argument. 20104 path="$complete" 20105 arguments="EOL" 20106 new_path="$path" 20107 20108 windows_path="$new_path" 20109 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20110 unix_path=`$CYGPATH -u "$windows_path"` 20111 new_path="$unix_path" 20112 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20113 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20114 new_path="$unix_path" 20115 fi 20116 20117 20118 new_path=`$WHICH "$new_path" 2> /dev/null` 20119 # bat and cmd files are not always considered executable in MSYS causing which 20120 # to not find them 20121 if test "x$new_path" = x \ 20122 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20123 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20124 new_path="$path" 20125 20126 windows_path="$new_path" 20127 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20128 unix_path=`$CYGPATH -u "$windows_path"` 20129 new_path="$unix_path" 20130 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20131 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20132 new_path="$unix_path" 20133 fi 20134 20135 fi 20136 20137 if test "x$new_path" = x; then 20138 # It's still not found. Now this is an unrecoverable error. 20139 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20140 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20141 has_space=`$ECHO "$complete" | $GREP " "` 20142 if test "x$has_space" != x; then 20143 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20144 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20145 fi 20146 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20147 fi 20148 fi 20149 20150 # Now new_path has a complete unix path to the binary 20151 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 20152 # Keep paths in /bin as-is, but remove trailing .exe if any 20153 new_path="${new_path/%.exe/}" 20154 # Do not save /bin paths to all_fixpath_prefixes! 20155 else 20156 # Not in mixed or Windows style, start by that. 20157 new_path=`cmd //c echo $new_path` 20158 20159 input_path="$new_path" 20160 # Check if we need to convert this using DOS-style short mode. If the path 20161 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20162 # take no chances and rewrite it. 20163 # Note: m4 eats our [], so we need to use [ and ] instead. 20164 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 20165 if test "x$has_forbidden_chars" != x; then 20166 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20167 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20168 fi 20169 20170 # Output is in $new_path 20171 20172 windows_path="$new_path" 20173 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20174 unix_path=`$CYGPATH -u "$windows_path"` 20175 new_path="$unix_path" 20176 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20177 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20178 new_path="$unix_path" 20179 fi 20180 20181 # remove trailing .exe if any 20182 new_path="${new_path/%.exe/}" 20183 20184 # Save the first 10 bytes of this path to the storage, so fixpath can work. 20185 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 20186 fi 20187 20188 else 20189 # We're on a unix platform. Hooray! :) 20190 # First separate the path from the arguments. This will split at the first 20191 # space. 20192 complete="$FOUND_MAKE" 20193 path="${complete%% *}" 20194 tmp="$complete EOL" 20195 arguments="${tmp#* }" 20196 20197 # Cannot rely on the command "which" here since it doesn't always work. 20198 is_absolute_path=`$ECHO "$path" | $GREP ^/` 20199 if test -z "$is_absolute_path"; then 20200 # Path to executable is not absolute. Find it. 20201 IFS_save="$IFS" 20202 IFS=: 20203 for p in $PATH; do 20204 if test -f "$p/$path" && test -x "$p/$path"; then 20205 new_path="$p/$path" 20206 break 20207 fi 20208 done 20209 IFS="$IFS_save" 20210 else 20211 # This is an absolute path, we can use it without further modifications. 20212 new_path="$path" 20213 fi 20214 20215 if test "x$new_path" = x; then 20216 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20217 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20218 has_space=`$ECHO "$complete" | $GREP " "` 20219 if test "x$has_space" != x; then 20220 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 20221 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 20222 fi 20223 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20224 fi 20225 fi 20226 20227 # Now join together the path and the arguments once again 20228 if test "x$arguments" != xEOL; then 20229 new_complete="$new_path ${arguments% *}" 20230 else 20231 new_complete="$new_path" 20232 fi 20233 20234 if test "x$complete" != "x$new_complete"; then 20235 FOUND_MAKE="$new_complete" 20236 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 20237 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 20238 fi 20239 fi 20240 20241 fi 20242 fi 20243 fi 20244 fi 20245 20246 if test "x$FOUND_MAKE" = x; then 20247 for ac_prog in make 20248 do 20249 # Extract the first word of "$ac_prog", so it can be a program name with args. 20250 set dummy $ac_prog; ac_word=$2 20251 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 20252 $as_echo_n "checking for $ac_word... " >&6; } 20253 if ${ac_cv_path_CHECK_TOOLSDIR_MAKE+:} false; then : 20254 $as_echo_n "(cached) " >&6 20255 else 20256 case $CHECK_TOOLSDIR_MAKE in 20257 [\\/]* | ?:[\\/]*) 20258 ac_cv_path_CHECK_TOOLSDIR_MAKE="$CHECK_TOOLSDIR_MAKE" # Let the user override the test with a path. 20259 ;; 20260 *) 20261 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 20262 for as_dir in $PATH 20263 do 20264 IFS=$as_save_IFS 20265 test -z "$as_dir" && as_dir=. 20266 for ac_exec_ext in '' $ac_executable_extensions; do 20267 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 20268 ac_cv_path_CHECK_TOOLSDIR_MAKE="$as_dir/$ac_word$ac_exec_ext" 20269 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 20270 break 2 20271 fi 20272 done 20273 done 20274 IFS=$as_save_IFS 20275 20276 ;; 20277 esac 20278 fi 20279 CHECK_TOOLSDIR_MAKE=$ac_cv_path_CHECK_TOOLSDIR_MAKE 20280 if test -n "$CHECK_TOOLSDIR_MAKE"; then 20281 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_MAKE" >&5 20282 $as_echo "$CHECK_TOOLSDIR_MAKE" >&6; } 20283 else 20284 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 20285 $as_echo "no" >&6; } 20286 fi 20287 20288 20289 test -n "$CHECK_TOOLSDIR_MAKE" && break 20290 done 20291 20292 20293 MAKE_CANDIDATE=""$CHECK_TOOLSDIR_MAKE"" 20294 DESCRIPTION="make in tools-dir" 20295 20296 # On Cygwin, we require a newer version of make than on other platforms 20297 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20298 MAKE_VERSION_EXPR="-e 4\." 20299 MAKE_REQUIRED_VERSION="4.0" 20300 else 20301 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 20302 MAKE_REQUIRED_VERSION="3.81" 20303 fi 20304 20305 if test "x$MAKE_CANDIDATE" != x; then 20306 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 20307 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 20308 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 20309 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 20310 if test "x$IS_GNU_MAKE" = x; then 20311 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 20312 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 20313 else 20314 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 20315 if test "x$IS_MODERN_MAKE" = x; then 20316 { $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 20317 $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;} 20318 else 20319 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 20320 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20321 MAKE_EXPECTED_ENV='cygwin' 20322 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20323 MAKE_EXPECTED_ENV='msys' 20324 else 20325 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 20326 fi 20327 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 20328 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 20329 else 20330 # Not relevant for non-Windows 20331 IS_MAKE_CORRECT_ENV=true 20332 fi 20333 if test "x$IS_MAKE_CORRECT_ENV" = x; then 20334 { $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 20335 $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;} 20336 else 20337 FOUND_MAKE=$MAKE_CANDIDATE 20338 20339 # Only process if variable expands to non-empty 20340 20341 if test "x$FOUND_MAKE" != x; then 20342 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20343 20344 # First separate the path from the arguments. This will split at the first 20345 # space. 20346 complete="$FOUND_MAKE" 20347 path="${complete%% *}" 20348 tmp="$complete EOL" 20349 arguments="${tmp#* }" 20350 20351 # Input might be given as Windows format, start by converting to 20352 # unix format. 20353 new_path=`$CYGPATH -u "$path"` 20354 20355 # Now try to locate executable using which 20356 new_path=`$WHICH "$new_path" 2> /dev/null` 20357 # bat and cmd files are not always considered executable in cygwin causing which 20358 # to not find them 20359 if test "x$new_path" = x \ 20360 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20361 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20362 new_path=`$CYGPATH -u "$path"` 20363 fi 20364 if test "x$new_path" = x; then 20365 # Oops. Which didn't find the executable. 20366 # The splitting of arguments from the executable at a space might have been incorrect, 20367 # since paths with space are more likely in Windows. Give it another try with the whole 20368 # argument. 20369 path="$complete" 20370 arguments="EOL" 20371 new_path=`$CYGPATH -u "$path"` 20372 new_path=`$WHICH "$new_path" 2> /dev/null` 20373 # bat and cmd files are not always considered executable in cygwin causing which 20374 # to not find them 20375 if test "x$new_path" = x \ 20376 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20377 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20378 new_path=`$CYGPATH -u "$path"` 20379 fi 20380 if test "x$new_path" = x; then 20381 # It's still not found. Now this is an unrecoverable error. 20382 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20383 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20384 has_space=`$ECHO "$complete" | $GREP " "` 20385 if test "x$has_space" != x; then 20386 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20387 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20388 fi 20389 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20390 fi 20391 fi 20392 20393 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 20394 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 20395 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 20396 # "foo.exe" is OK but "foo" is an error. 20397 # 20398 # This test is therefore slightly more accurate than "test -f" to check for file presence. 20399 # It is also a way to make sure we got the proper file name for the real test later on. 20400 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 20401 if test "x$test_shortpath" = x; then 20402 # Short path failed, file does not exist as specified. 20403 # Try adding .exe or .cmd 20404 if test -f "${new_path}.exe"; then 20405 input_to_shortpath="${new_path}.exe" 20406 elif test -f "${new_path}.cmd"; then 20407 input_to_shortpath="${new_path}.cmd" 20408 else 20409 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 20410 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 20411 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 20412 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 20413 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20414 fi 20415 else 20416 input_to_shortpath="$new_path" 20417 fi 20418 20419 # Call helper function which possibly converts this using DOS-style short mode. 20420 # If so, the updated path is stored in $new_path. 20421 new_path="$input_to_shortpath" 20422 20423 input_path="$input_to_shortpath" 20424 # Check if we need to convert this using DOS-style short mode. If the path 20425 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20426 # take no chances and rewrite it. 20427 # Note: m4 eats our [], so we need to use [ and ] instead. 20428 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 20429 if test "x$has_forbidden_chars" != x; then 20430 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20431 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 20432 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 20433 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 20434 # Going to short mode and back again did indeed matter. Since short mode is 20435 # case insensitive, let's make it lowercase to improve readability. 20436 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20437 # Now convert it back to Unix-style (cygpath) 20438 input_path=`$CYGPATH -u "$shortmode_path"` 20439 new_path="$input_path" 20440 fi 20441 fi 20442 20443 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 20444 if test "x$test_cygdrive_prefix" = x; then 20445 # As a simple fix, exclude /usr/bin since it's not a real path. 20446 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 20447 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 20448 # a path prefixed by /cygdrive for fixpath to work. 20449 new_path="$CYGWIN_ROOT_PATH$input_path" 20450 fi 20451 fi 20452 20453 # remove trailing .exe if any 20454 new_path="${new_path/%.exe/}" 20455 20456 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20457 20458 # First separate the path from the arguments. This will split at the first 20459 # space. 20460 complete="$FOUND_MAKE" 20461 path="${complete%% *}" 20462 tmp="$complete EOL" 20463 arguments="${tmp#* }" 20464 20465 # Input might be given as Windows format, start by converting to 20466 # unix format. 20467 new_path="$path" 20468 20469 windows_path="$new_path" 20470 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20471 unix_path=`$CYGPATH -u "$windows_path"` 20472 new_path="$unix_path" 20473 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20474 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20475 new_path="$unix_path" 20476 fi 20477 20478 20479 # Now try to locate executable using which 20480 new_path=`$WHICH "$new_path" 2> /dev/null` 20481 20482 if test "x$new_path" = x; then 20483 # Oops. Which didn't find the executable. 20484 # The splitting of arguments from the executable at a space might have been incorrect, 20485 # since paths with space are more likely in Windows. Give it another try with the whole 20486 # argument. 20487 path="$complete" 20488 arguments="EOL" 20489 new_path="$path" 20490 20491 windows_path="$new_path" 20492 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20493 unix_path=`$CYGPATH -u "$windows_path"` 20494 new_path="$unix_path" 20495 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20496 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20497 new_path="$unix_path" 20498 fi 20499 20500 20501 new_path=`$WHICH "$new_path" 2> /dev/null` 20502 # bat and cmd files are not always considered executable in MSYS causing which 20503 # to not find them 20504 if test "x$new_path" = x \ 20505 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20506 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20507 new_path="$path" 20508 20509 windows_path="$new_path" 20510 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20511 unix_path=`$CYGPATH -u "$windows_path"` 20512 new_path="$unix_path" 20513 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20514 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20515 new_path="$unix_path" 20516 fi 20517 20518 fi 20519 20520 if test "x$new_path" = x; then 20521 # It's still not found. Now this is an unrecoverable error. 20522 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20523 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20524 has_space=`$ECHO "$complete" | $GREP " "` 20525 if test "x$has_space" != x; then 20526 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20527 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20528 fi 20529 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20530 fi 20531 fi 20532 20533 # Now new_path has a complete unix path to the binary 20534 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 20535 # Keep paths in /bin as-is, but remove trailing .exe if any 20536 new_path="${new_path/%.exe/}" 20537 # Do not save /bin paths to all_fixpath_prefixes! 20538 else 20539 # Not in mixed or Windows style, start by that. 20540 new_path=`cmd //c echo $new_path` 20541 20542 input_path="$new_path" 20543 # Check if we need to convert this using DOS-style short mode. If the path 20544 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20545 # take no chances and rewrite it. 20546 # Note: m4 eats our [], so we need to use [ and ] instead. 20547 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 20548 if test "x$has_forbidden_chars" != x; then 20549 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20550 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20551 fi 20552 20553 # Output is in $new_path 20554 20555 windows_path="$new_path" 20556 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20557 unix_path=`$CYGPATH -u "$windows_path"` 20558 new_path="$unix_path" 20559 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20560 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20561 new_path="$unix_path" 20562 fi 20563 20564 # remove trailing .exe if any 20565 new_path="${new_path/%.exe/}" 20566 20567 # Save the first 10 bytes of this path to the storage, so fixpath can work. 20568 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 20569 fi 20570 20571 else 20572 # We're on a unix platform. Hooray! :) 20573 # First separate the path from the arguments. This will split at the first 20574 # space. 20575 complete="$FOUND_MAKE" 20576 path="${complete%% *}" 20577 tmp="$complete EOL" 20578 arguments="${tmp#* }" 20579 20580 # Cannot rely on the command "which" here since it doesn't always work. 20581 is_absolute_path=`$ECHO "$path" | $GREP ^/` 20582 if test -z "$is_absolute_path"; then 20583 # Path to executable is not absolute. Find it. 20584 IFS_save="$IFS" 20585 IFS=: 20586 for p in $PATH; do 20587 if test -f "$p/$path" && test -x "$p/$path"; then 20588 new_path="$p/$path" 20589 break 20590 fi 20591 done 20592 IFS="$IFS_save" 20593 else 20594 # This is an absolute path, we can use it without further modifications. 20595 new_path="$path" 20596 fi 20597 20598 if test "x$new_path" = x; then 20599 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20600 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20601 has_space=`$ECHO "$complete" | $GREP " "` 20602 if test "x$has_space" != x; then 20603 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 20604 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 20605 fi 20606 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20607 fi 20608 fi 20609 20610 # Now join together the path and the arguments once again 20611 if test "x$arguments" != xEOL; then 20612 new_complete="$new_path ${arguments% *}" 20613 else 20614 new_complete="$new_path" 20615 fi 20616 20617 if test "x$complete" != "x$new_complete"; then 20618 FOUND_MAKE="$new_complete" 20619 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 20620 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 20621 fi 20622 fi 20623 20624 fi 20625 fi 20626 fi 20627 fi 20628 20629 fi 20630 PATH=$OLD_PATH 20631 fi 20632 fi 20633 20634 if test "x$FOUND_MAKE" = x; then 20635 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 20636 fi 20637 20638 else 20639 # If it succeeded, then it was overridden by the user. We will use it 20640 # for the tool. 20641 20642 # First remove it from the list of overridden variables, so we can test 20643 # for unknown variables in the end. 20644 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 20645 20646 # Check if we try to supply an empty value 20647 if test "x$MAKE" = x; then 20648 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool MAKE= (no value)" >&5 20649 $as_echo "$as_me: Setting user supplied tool MAKE= (no value)" >&6;} 20650 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MAKE" >&5 20651 $as_echo_n "checking for MAKE... " >&6; } 20652 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 20653 $as_echo "disabled" >&6; } 20654 else 20655 # Check if the provided tool contains a complete path. 20656 tool_specified="$MAKE" 20657 tool_basename="${tool_specified##*/}" 20658 if test "x$tool_basename" = "x$tool_specified"; then 20659 # A command without a complete path is provided, search $PATH. 20660 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MAKE=$tool_basename" >&5 20661 $as_echo "$as_me: Will search for user supplied tool MAKE=$tool_basename" >&6;} 20662 # Extract the first word of "$tool_basename", so it can be a program name with args. 20663 set dummy $tool_basename; ac_word=$2 20664 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 20665 $as_echo_n "checking for $ac_word... " >&6; } 20666 if ${ac_cv_path_MAKE+:} false; then : 20667 $as_echo_n "(cached) " >&6 20668 else 20669 case $MAKE in 20670 [\\/]* | ?:[\\/]*) 20671 ac_cv_path_MAKE="$MAKE" # Let the user override the test with a path. 20672 ;; 20673 *) 20674 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 20675 for as_dir in $PATH 20676 do 20677 IFS=$as_save_IFS 20678 test -z "$as_dir" && as_dir=. 20679 for ac_exec_ext in '' $ac_executable_extensions; do 20680 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 20681 ac_cv_path_MAKE="$as_dir/$ac_word$ac_exec_ext" 20682 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 20683 break 2 20684 fi 20685 done 20686 done 20687 IFS=$as_save_IFS 20688 20689 ;; 20690 esac 20691 fi 20692 MAKE=$ac_cv_path_MAKE 20693 if test -n "$MAKE"; then 20694 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKE" >&5 20695 $as_echo "$MAKE" >&6; } 20696 else 20697 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 20698 $as_echo "no" >&6; } 20699 fi 20700 20701 20702 if test "x$MAKE" = x; then 20703 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 20704 fi 20705 else 20706 # Otherwise we believe it is a complete path. Use it as it is. 20707 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MAKE=$tool_specified" >&5 20708 $as_echo "$as_me: Will use user supplied tool MAKE=$tool_specified" >&6;} 20709 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MAKE" >&5 20710 $as_echo_n "checking for MAKE... " >&6; } 20711 if test ! -x "$tool_specified"; then 20712 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 20713 $as_echo "not found" >&6; } 20714 as_fn_error $? "User supplied tool MAKE=$tool_specified does not exist or is not executable" "$LINENO" 5 20715 fi 20716 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 20717 $as_echo "$tool_specified" >&6; } 20718 fi 20719 fi 20720 fi 20721 20722 # If MAKE was set by user, verify the version 20723 20724 MAKE_CANDIDATE=""$MAKE"" 20725 DESCRIPTION="user supplied MAKE=$MAKE" 20726 20727 # On Cygwin, we require a newer version of make than on other platforms 20728 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20729 MAKE_VERSION_EXPR="-e 4\." 20730 MAKE_REQUIRED_VERSION="4.0" 20731 else 20732 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 20733 MAKE_REQUIRED_VERSION="3.81" 20734 fi 20735 20736 if test "x$MAKE_CANDIDATE" != x; then 20737 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 20738 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 20739 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 20740 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 20741 if test "x$IS_GNU_MAKE" = x; then 20742 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 20743 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 20744 else 20745 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 20746 if test "x$IS_MODERN_MAKE" = x; then 20747 { $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 20748 $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;} 20749 else 20750 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 20751 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20752 MAKE_EXPECTED_ENV='cygwin' 20753 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20754 MAKE_EXPECTED_ENV='msys' 20755 else 20756 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 20757 fi 20758 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 20759 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 20760 else 20761 # Not relevant for non-Windows 20762 IS_MAKE_CORRECT_ENV=true 20763 fi 20764 if test "x$IS_MAKE_CORRECT_ENV" = x; then 20765 { $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 20766 $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;} 20767 else 20768 FOUND_MAKE=$MAKE_CANDIDATE 20769 20770 # Only process if variable expands to non-empty 20771 20772 if test "x$FOUND_MAKE" != x; then 20773 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20774 20775 # First separate the path from the arguments. This will split at the first 20776 # space. 20777 complete="$FOUND_MAKE" 20778 path="${complete%% *}" 20779 tmp="$complete EOL" 20780 arguments="${tmp#* }" 20781 20782 # Input might be given as Windows format, start by converting to 20783 # unix format. 20784 new_path=`$CYGPATH -u "$path"` 20785 20786 # Now try to locate executable using which 20787 new_path=`$WHICH "$new_path" 2> /dev/null` 20788 # bat and cmd files are not always considered executable in cygwin causing which 20789 # to not find them 20790 if test "x$new_path" = x \ 20791 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20792 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20793 new_path=`$CYGPATH -u "$path"` 20794 fi 20795 if test "x$new_path" = x; then 20796 # Oops. Which didn't find the executable. 20797 # The splitting of arguments from the executable at a space might have been incorrect, 20798 # since paths with space are more likely in Windows. Give it another try with the whole 20799 # argument. 20800 path="$complete" 20801 arguments="EOL" 20802 new_path=`$CYGPATH -u "$path"` 20803 new_path=`$WHICH "$new_path" 2> /dev/null` 20804 # bat and cmd files are not always considered executable in cygwin causing which 20805 # to not find them 20806 if test "x$new_path" = x \ 20807 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20808 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20809 new_path=`$CYGPATH -u "$path"` 20810 fi 20811 if test "x$new_path" = x; then 20812 # It's still not found. Now this is an unrecoverable error. 20813 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20814 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20815 has_space=`$ECHO "$complete" | $GREP " "` 20816 if test "x$has_space" != x; then 20817 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20818 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20819 fi 20820 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20821 fi 20822 fi 20823 20824 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 20825 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 20826 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 20827 # "foo.exe" is OK but "foo" is an error. 20828 # 20829 # This test is therefore slightly more accurate than "test -f" to check for file presence. 20830 # It is also a way to make sure we got the proper file name for the real test later on. 20831 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 20832 if test "x$test_shortpath" = x; then 20833 # Short path failed, file does not exist as specified. 20834 # Try adding .exe or .cmd 20835 if test -f "${new_path}.exe"; then 20836 input_to_shortpath="${new_path}.exe" 20837 elif test -f "${new_path}.cmd"; then 20838 input_to_shortpath="${new_path}.cmd" 20839 else 20840 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 20841 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 20842 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 20843 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 20844 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20845 fi 20846 else 20847 input_to_shortpath="$new_path" 20848 fi 20849 20850 # Call helper function which possibly converts this using DOS-style short mode. 20851 # If so, the updated path is stored in $new_path. 20852 new_path="$input_to_shortpath" 20853 20854 input_path="$input_to_shortpath" 20855 # Check if we need to convert this using DOS-style short mode. If the path 20856 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20857 # take no chances and rewrite it. 20858 # Note: m4 eats our [], so we need to use [ and ] instead. 20859 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 20860 if test "x$has_forbidden_chars" != x; then 20861 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20862 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 20863 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 20864 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 20865 # Going to short mode and back again did indeed matter. Since short mode is 20866 # case insensitive, let's make it lowercase to improve readability. 20867 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20868 # Now convert it back to Unix-style (cygpath) 20869 input_path=`$CYGPATH -u "$shortmode_path"` 20870 new_path="$input_path" 20871 fi 20872 fi 20873 20874 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 20875 if test "x$test_cygdrive_prefix" = x; then 20876 # As a simple fix, exclude /usr/bin since it's not a real path. 20877 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 20878 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 20879 # a path prefixed by /cygdrive for fixpath to work. 20880 new_path="$CYGWIN_ROOT_PATH$input_path" 20881 fi 20882 fi 20883 20884 # remove trailing .exe if any 20885 new_path="${new_path/%.exe/}" 20886 20887 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20888 20889 # First separate the path from the arguments. This will split at the first 20890 # space. 20891 complete="$FOUND_MAKE" 20892 path="${complete%% *}" 20893 tmp="$complete EOL" 20894 arguments="${tmp#* }" 20895 20896 # Input might be given as Windows format, start by converting to 20897 # unix format. 20898 new_path="$path" 20899 20900 windows_path="$new_path" 20901 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20902 unix_path=`$CYGPATH -u "$windows_path"` 20903 new_path="$unix_path" 20904 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20905 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20906 new_path="$unix_path" 20907 fi 20908 20909 20910 # Now try to locate executable using which 20911 new_path=`$WHICH "$new_path" 2> /dev/null` 20912 20913 if test "x$new_path" = x; then 20914 # Oops. Which didn't find the executable. 20915 # The splitting of arguments from the executable at a space might have been incorrect, 20916 # since paths with space are more likely in Windows. Give it another try with the whole 20917 # argument. 20918 path="$complete" 20919 arguments="EOL" 20920 new_path="$path" 20921 20922 windows_path="$new_path" 20923 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20924 unix_path=`$CYGPATH -u "$windows_path"` 20925 new_path="$unix_path" 20926 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20927 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20928 new_path="$unix_path" 20929 fi 20930 20931 20932 new_path=`$WHICH "$new_path" 2> /dev/null` 20933 # bat and cmd files are not always considered executable in MSYS causing which 20934 # to not find them 20935 if test "x$new_path" = x \ 20936 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20937 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20938 new_path="$path" 20939 20940 windows_path="$new_path" 20941 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20942 unix_path=`$CYGPATH -u "$windows_path"` 20943 new_path="$unix_path" 20944 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20945 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20946 new_path="$unix_path" 20947 fi 20948 20949 fi 20950 20951 if test "x$new_path" = x; then 20952 # It's still not found. Now this is an unrecoverable error. 20953 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20954 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20955 has_space=`$ECHO "$complete" | $GREP " "` 20956 if test "x$has_space" != x; then 20957 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20958 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20959 fi 20960 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20961 fi 20962 fi 20963 20964 # Now new_path has a complete unix path to the binary 20965 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 20966 # Keep paths in /bin as-is, but remove trailing .exe if any 20967 new_path="${new_path/%.exe/}" 20968 # Do not save /bin paths to all_fixpath_prefixes! 20969 else 20970 # Not in mixed or Windows style, start by that. 20971 new_path=`cmd //c echo $new_path` 20972 20973 input_path="$new_path" 20974 # Check if we need to convert this using DOS-style short mode. If the path 20975 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20976 # take no chances and rewrite it. 20977 # Note: m4 eats our [], so we need to use [ and ] instead. 20978 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 20979 if test "x$has_forbidden_chars" != x; then 20980 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20981 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20982 fi 20983 20984 # Output is in $new_path 20985 20986 windows_path="$new_path" 20987 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20988 unix_path=`$CYGPATH -u "$windows_path"` 20989 new_path="$unix_path" 20990 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20991 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20992 new_path="$unix_path" 20993 fi 20994 20995 # remove trailing .exe if any 20996 new_path="${new_path/%.exe/}" 20997 20998 # Save the first 10 bytes of this path to the storage, so fixpath can work. 20999 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 21000 fi 21001 21002 else 21003 # We're on a unix platform. Hooray! :) 21004 # First separate the path from the arguments. This will split at the first 21005 # space. 21006 complete="$FOUND_MAKE" 21007 path="${complete%% *}" 21008 tmp="$complete EOL" 21009 arguments="${tmp#* }" 21010 21011 # Cannot rely on the command "which" here since it doesn't always work. 21012 is_absolute_path=`$ECHO "$path" | $GREP ^/` 21013 if test -z "$is_absolute_path"; then 21014 # Path to executable is not absolute. Find it. 21015 IFS_save="$IFS" 21016 IFS=: 21017 for p in $PATH; do 21018 if test -f "$p/$path" && test -x "$p/$path"; then 21019 new_path="$p/$path" 21020 break 21021 fi 21022 done 21023 IFS="$IFS_save" 21024 else 21025 # This is an absolute path, we can use it without further modifications. 21026 new_path="$path" 21027 fi 21028 21029 if test "x$new_path" = x; then 21030 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 21031 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 21032 has_space=`$ECHO "$complete" | $GREP " "` 21033 if test "x$has_space" != x; then 21034 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 21035 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 21036 fi 21037 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 21038 fi 21039 fi 21040 21041 # Now join together the path and the arguments once again 21042 if test "x$arguments" != xEOL; then 21043 new_complete="$new_path ${arguments% *}" 21044 else 21045 new_complete="$new_path" 21046 fi 21047 21048 if test "x$complete" != "x$new_complete"; then 21049 FOUND_MAKE="$new_complete" 21050 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 21051 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 21052 fi 21053 fi 21054 21055 fi 21056 fi 21057 fi 21058 fi 21059 21060 if test "x$FOUND_MAKE" = x; then 21061 as_fn_error $? "The specified make (by MAKE=$MAKE) is not GNU make $MAKE_REQUIRED_VERSION or newer." "$LINENO" 5 21062 fi 21063 21064 fi 21065 21066 21067 MAKE=$FOUND_MAKE 21068 21069 { $as_echo "$as_me:${as_lineno-$LINENO}: Using GNU make at $FOUND_MAKE (version: $MAKE_VERSION_STRING)" >&5 21070 $as_echo "$as_me: Using GNU make at $FOUND_MAKE (version: $MAKE_VERSION_STRING)" >&6;} 21071 21072 21073 # Check if make supports the output sync option and if so, setup using it. 21074 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if make --output-sync is supported" >&5 21075 $as_echo_n "checking if make --output-sync is supported... " >&6; } 21076 if $MAKE --version -O > /dev/null 2>&1; then 21077 OUTPUT_SYNC_SUPPORTED=true 21078 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 21079 $as_echo "yes" >&6; } 21080 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for output-sync value" >&5 21081 $as_echo_n "checking for output-sync value... " >&6; } 21082 21083 # Check whether --with-output-sync was given. 21084 if test "${with_output_sync+set}" = set; then : 21085 withval=$with_output_sync; OUTPUT_SYNC=$with_output_sync 21086 fi 21087 21088 if test "x$OUTPUT_SYNC" = "x"; then 21089 OUTPUT_SYNC=none 21090 fi 21091 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OUTPUT_SYNC" >&5 21092 $as_echo "$OUTPUT_SYNC" >&6; } 21093 if ! $MAKE --version -O$OUTPUT_SYNC > /dev/null 2>&1; then 21094 as_fn_error $? "Make did not the support the value $OUTPUT_SYNC as output sync type." "$LINENO" 5 21095 fi 21096 else 21097 OUTPUT_SYNC_SUPPORTED=false 21098 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21099 $as_echo "no" >&6; } 21100 fi 21101 21102 21103 21104 21105 21106 21107 # Test if find supports -delete 21108 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if find supports -delete" >&5 21109 $as_echo_n "checking if find supports -delete... " >&6; } 21110 FIND_DELETE="-delete" 21111 21112 DELETEDIR=`$MKTEMP -d tmp.XXXXXXXXXX` || (echo Could not create temporary directory!; exit $?) 21113 21114 echo Hejsan > $DELETEDIR/TestIfFindSupportsDelete 21115 21116 TEST_DELETE=`$FIND "$DELETEDIR" -name TestIfFindSupportsDelete $FIND_DELETE 2>&1` 21117 if test -f $DELETEDIR/TestIfFindSupportsDelete; then 21118 # No, it does not. 21119 $RM $DELETEDIR/TestIfFindSupportsDelete 21120 if test "x$OPENJDK_TARGET_OS" = "xaix"; then 21121 # AIX 'find' is buggy if called with '-exec {} \+' and an empty file list 21122 FIND_DELETE="-print | $XARGS $RM" 21123 else 21124 FIND_DELETE="-exec $RM \{\} \+" 21125 fi 21126 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21127 $as_echo "no" >&6; } 21128 else 21129 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 21130 $as_echo "yes" >&6; } 21131 fi 21132 $RMDIR $DELETEDIR 21133 21134 21135 21136 # Test which kind of tar was found 21137 if test "x$($TAR --version | $GREP "GNU tar")" != "x"; then 21138 TAR_TYPE="gnu" 21139 elif test "x$($TAR -v | $GREP "bsdtar")" != "x"; then 21140 TAR_TYPE="bsd" 21141 elif test "x$OPENJDK_BUILD_OS" = "xsolaris"; then 21142 TAR_TYPE="solaris" 21143 fi 21144 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what type of tar was found" >&5 21145 $as_echo_n "checking what type of tar was found... " >&6; } 21146 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR_TYPE" >&5 21147 $as_echo "$TAR_TYPE" >&6; } 21148 21149 TAR_CREATE_FILE_PARAM="" 21150 21151 if test "x$TAR_TYPE" = "xgnu"; then 21152 TAR_INCLUDE_PARAM="T" 21153 TAR_SUPPORTS_TRANSFORM="true" 21154 if test "x$OPENJDK_TARGET_OS" = "xsolaris"; then 21155 # When using gnu tar for Solaris targets, need to use compatibility mode 21156 TAR_CREATE_EXTRA_PARAM="--format=ustar" 21157 fi 21158 else 21159 TAR_INCLUDE_PARAM="I" 21160 TAR_SUPPORTS_TRANSFORM="false" 21161 fi 21162 21163 21164 21165 21166 21167 21168 # These tools might not be installed by default, 21169 # need hint on how to install them. 21170 21171 21172 21173 # Publish this variable in the help. 21174 21175 21176 if [ -z "${UNZIP+x}" ]; then 21177 # The variable is not set by user, try to locate tool using the code snippet 21178 for ac_prog in unzip 21179 do 21180 # Extract the first word of "$ac_prog", so it can be a program name with args. 21181 set dummy $ac_prog; ac_word=$2 21182 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21183 $as_echo_n "checking for $ac_word... " >&6; } 21184 if ${ac_cv_path_UNZIP+:} false; then : 21185 $as_echo_n "(cached) " >&6 21186 else 21187 case $UNZIP in 21188 [\\/]* | ?:[\\/]*) 21189 ac_cv_path_UNZIP="$UNZIP" # Let the user override the test with a path. 21190 ;; 21191 *) 21192 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21193 for as_dir in $PATH 21194 do 21195 IFS=$as_save_IFS 21196 test -z "$as_dir" && as_dir=. 21197 for ac_exec_ext in '' $ac_executable_extensions; do 21198 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21199 ac_cv_path_UNZIP="$as_dir/$ac_word$ac_exec_ext" 21200 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21201 break 2 21202 fi 21203 done 21204 done 21205 IFS=$as_save_IFS 21206 21207 ;; 21208 esac 21209 fi 21210 UNZIP=$ac_cv_path_UNZIP 21211 if test -n "$UNZIP"; then 21212 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNZIP" >&5 21213 $as_echo "$UNZIP" >&6; } 21214 else 21215 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21216 $as_echo "no" >&6; } 21217 fi 21218 21219 21220 test -n "$UNZIP" && break 21221 done 21222 21223 else 21224 # The variable is set, but is it from the command line or the environment? 21225 21226 # Try to remove the string !UNZIP! from our list. 21227 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!UNZIP!/} 21228 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 21229 # If it failed, the variable was not from the command line. Ignore it, 21230 # but warn the user (except for BASH, which is always set by the calling BASH). 21231 if test "xUNZIP" != xBASH; then 21232 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of UNZIP from the environment. Use command line variables instead." >&5 21233 $as_echo "$as_me: WARNING: Ignoring value of UNZIP from the environment. Use command line variables instead." >&2;} 21234 fi 21235 # Try to locate tool using the code snippet 21236 for ac_prog in unzip 21237 do 21238 # Extract the first word of "$ac_prog", so it can be a program name with args. 21239 set dummy $ac_prog; ac_word=$2 21240 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21241 $as_echo_n "checking for $ac_word... " >&6; } 21242 if ${ac_cv_path_UNZIP+:} false; then : 21243 $as_echo_n "(cached) " >&6 21244 else 21245 case $UNZIP in 21246 [\\/]* | ?:[\\/]*) 21247 ac_cv_path_UNZIP="$UNZIP" # Let the user override the test with a path. 21248 ;; 21249 *) 21250 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21251 for as_dir in $PATH 21252 do 21253 IFS=$as_save_IFS 21254 test -z "$as_dir" && as_dir=. 21255 for ac_exec_ext in '' $ac_executable_extensions; do 21256 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21257 ac_cv_path_UNZIP="$as_dir/$ac_word$ac_exec_ext" 21258 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21259 break 2 21260 fi 21261 done 21262 done 21263 IFS=$as_save_IFS 21264 21265 ;; 21266 esac 21267 fi 21268 UNZIP=$ac_cv_path_UNZIP 21269 if test -n "$UNZIP"; then 21270 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNZIP" >&5 21271 $as_echo "$UNZIP" >&6; } 21272 else 21273 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21274 $as_echo "no" >&6; } 21275 fi 21276 21277 21278 test -n "$UNZIP" && break 21279 done 21280 21281 else 21282 # If it succeeded, then it was overridden by the user. We will use it 21283 # for the tool. 21284 21285 # First remove it from the list of overridden variables, so we can test 21286 # for unknown variables in the end. 21287 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 21288 21289 # Check if we try to supply an empty value 21290 if test "x$UNZIP" = x; then 21291 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool UNZIP= (no value)" >&5 21292 $as_echo "$as_me: Setting user supplied tool UNZIP= (no value)" >&6;} 21293 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNZIP" >&5 21294 $as_echo_n "checking for UNZIP... " >&6; } 21295 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 21296 $as_echo "disabled" >&6; } 21297 else 21298 # Check if the provided tool contains a complete path. 21299 tool_specified="$UNZIP" 21300 tool_basename="${tool_specified##*/}" 21301 if test "x$tool_basename" = "x$tool_specified"; then 21302 # A command without a complete path is provided, search $PATH. 21303 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool UNZIP=$tool_basename" >&5 21304 $as_echo "$as_me: Will search for user supplied tool UNZIP=$tool_basename" >&6;} 21305 # Extract the first word of "$tool_basename", so it can be a program name with args. 21306 set dummy $tool_basename; ac_word=$2 21307 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21308 $as_echo_n "checking for $ac_word... " >&6; } 21309 if ${ac_cv_path_UNZIP+:} false; then : 21310 $as_echo_n "(cached) " >&6 21311 else 21312 case $UNZIP in 21313 [\\/]* | ?:[\\/]*) 21314 ac_cv_path_UNZIP="$UNZIP" # Let the user override the test with a path. 21315 ;; 21316 *) 21317 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21318 for as_dir in $PATH 21319 do 21320 IFS=$as_save_IFS 21321 test -z "$as_dir" && as_dir=. 21322 for ac_exec_ext in '' $ac_executable_extensions; do 21323 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21324 ac_cv_path_UNZIP="$as_dir/$ac_word$ac_exec_ext" 21325 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21326 break 2 21327 fi 21328 done 21329 done 21330 IFS=$as_save_IFS 21331 21332 ;; 21333 esac 21334 fi 21335 UNZIP=$ac_cv_path_UNZIP 21336 if test -n "$UNZIP"; then 21337 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNZIP" >&5 21338 $as_echo "$UNZIP" >&6; } 21339 else 21340 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21341 $as_echo "no" >&6; } 21342 fi 21343 21344 21345 if test "x$UNZIP" = x; then 21346 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 21347 fi 21348 else 21349 # Otherwise we believe it is a complete path. Use it as it is. 21350 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool UNZIP=$tool_specified" >&5 21351 $as_echo "$as_me: Will use user supplied tool UNZIP=$tool_specified" >&6;} 21352 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNZIP" >&5 21353 $as_echo_n "checking for UNZIP... " >&6; } 21354 if test ! -x "$tool_specified"; then 21355 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 21356 $as_echo "not found" >&6; } 21357 as_fn_error $? "User supplied tool UNZIP=$tool_specified does not exist or is not executable" "$LINENO" 5 21358 fi 21359 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 21360 $as_echo "$tool_specified" >&6; } 21361 fi 21362 fi 21363 fi 21364 21365 fi 21366 21367 21368 21369 if test "x$UNZIP" = x; then 21370 as_fn_error $? "Could not find required tool for UNZIP" "$LINENO" 5 21371 fi 21372 21373 21374 21375 21376 21377 # Publish this variable in the help. 21378 21379 21380 if [ -z "${ZIP+x}" ]; then 21381 # The variable is not set by user, try to locate tool using the code snippet 21382 for ac_prog in zip 21383 do 21384 # Extract the first word of "$ac_prog", so it can be a program name with args. 21385 set dummy $ac_prog; ac_word=$2 21386 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21387 $as_echo_n "checking for $ac_word... " >&6; } 21388 if ${ac_cv_path_ZIP+:} false; then : 21389 $as_echo_n "(cached) " >&6 21390 else 21391 case $ZIP in 21392 [\\/]* | ?:[\\/]*) 21393 ac_cv_path_ZIP="$ZIP" # Let the user override the test with a path. 21394 ;; 21395 *) 21396 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21397 for as_dir in $PATH 21398 do 21399 IFS=$as_save_IFS 21400 test -z "$as_dir" && as_dir=. 21401 for ac_exec_ext in '' $ac_executable_extensions; do 21402 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21403 ac_cv_path_ZIP="$as_dir/$ac_word$ac_exec_ext" 21404 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21405 break 2 21406 fi 21407 done 21408 done 21409 IFS=$as_save_IFS 21410 21411 ;; 21412 esac 21413 fi 21414 ZIP=$ac_cv_path_ZIP 21415 if test -n "$ZIP"; then 21416 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIP" >&5 21417 $as_echo "$ZIP" >&6; } 21418 else 21419 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21420 $as_echo "no" >&6; } 21421 fi 21422 21423 21424 test -n "$ZIP" && break 21425 done 21426 21427 else 21428 # The variable is set, but is it from the command line or the environment? 21429 21430 # Try to remove the string !ZIP! from our list. 21431 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ZIP!/} 21432 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 21433 # If it failed, the variable was not from the command line. Ignore it, 21434 # but warn the user (except for BASH, which is always set by the calling BASH). 21435 if test "xZIP" != xBASH; then 21436 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ZIP from the environment. Use command line variables instead." >&5 21437 $as_echo "$as_me: WARNING: Ignoring value of ZIP from the environment. Use command line variables instead." >&2;} 21438 fi 21439 # Try to locate tool using the code snippet 21440 for ac_prog in zip 21441 do 21442 # Extract the first word of "$ac_prog", so it can be a program name with args. 21443 set dummy $ac_prog; ac_word=$2 21444 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21445 $as_echo_n "checking for $ac_word... " >&6; } 21446 if ${ac_cv_path_ZIP+:} false; then : 21447 $as_echo_n "(cached) " >&6 21448 else 21449 case $ZIP in 21450 [\\/]* | ?:[\\/]*) 21451 ac_cv_path_ZIP="$ZIP" # Let the user override the test with a path. 21452 ;; 21453 *) 21454 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21455 for as_dir in $PATH 21456 do 21457 IFS=$as_save_IFS 21458 test -z "$as_dir" && as_dir=. 21459 for ac_exec_ext in '' $ac_executable_extensions; do 21460 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21461 ac_cv_path_ZIP="$as_dir/$ac_word$ac_exec_ext" 21462 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21463 break 2 21464 fi 21465 done 21466 done 21467 IFS=$as_save_IFS 21468 21469 ;; 21470 esac 21471 fi 21472 ZIP=$ac_cv_path_ZIP 21473 if test -n "$ZIP"; then 21474 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIP" >&5 21475 $as_echo "$ZIP" >&6; } 21476 else 21477 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21478 $as_echo "no" >&6; } 21479 fi 21480 21481 21482 test -n "$ZIP" && break 21483 done 21484 21485 else 21486 # If it succeeded, then it was overridden by the user. We will use it 21487 # for the tool. 21488 21489 # First remove it from the list of overridden variables, so we can test 21490 # for unknown variables in the end. 21491 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 21492 21493 # Check if we try to supply an empty value 21494 if test "x$ZIP" = x; then 21495 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ZIP= (no value)" >&5 21496 $as_echo "$as_me: Setting user supplied tool ZIP= (no value)" >&6;} 21497 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ZIP" >&5 21498 $as_echo_n "checking for ZIP... " >&6; } 21499 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 21500 $as_echo "disabled" >&6; } 21501 else 21502 # Check if the provided tool contains a complete path. 21503 tool_specified="$ZIP" 21504 tool_basename="${tool_specified##*/}" 21505 if test "x$tool_basename" = "x$tool_specified"; then 21506 # A command without a complete path is provided, search $PATH. 21507 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ZIP=$tool_basename" >&5 21508 $as_echo "$as_me: Will search for user supplied tool ZIP=$tool_basename" >&6;} 21509 # Extract the first word of "$tool_basename", so it can be a program name with args. 21510 set dummy $tool_basename; ac_word=$2 21511 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21512 $as_echo_n "checking for $ac_word... " >&6; } 21513 if ${ac_cv_path_ZIP+:} false; then : 21514 $as_echo_n "(cached) " >&6 21515 else 21516 case $ZIP in 21517 [\\/]* | ?:[\\/]*) 21518 ac_cv_path_ZIP="$ZIP" # Let the user override the test with a path. 21519 ;; 21520 *) 21521 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21522 for as_dir in $PATH 21523 do 21524 IFS=$as_save_IFS 21525 test -z "$as_dir" && as_dir=. 21526 for ac_exec_ext in '' $ac_executable_extensions; do 21527 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21528 ac_cv_path_ZIP="$as_dir/$ac_word$ac_exec_ext" 21529 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21530 break 2 21531 fi 21532 done 21533 done 21534 IFS=$as_save_IFS 21535 21536 ;; 21537 esac 21538 fi 21539 ZIP=$ac_cv_path_ZIP 21540 if test -n "$ZIP"; then 21541 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIP" >&5 21542 $as_echo "$ZIP" >&6; } 21543 else 21544 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21545 $as_echo "no" >&6; } 21546 fi 21547 21548 21549 if test "x$ZIP" = x; then 21550 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 21551 fi 21552 else 21553 # Otherwise we believe it is a complete path. Use it as it is. 21554 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ZIP=$tool_specified" >&5 21555 $as_echo "$as_me: Will use user supplied tool ZIP=$tool_specified" >&6;} 21556 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ZIP" >&5 21557 $as_echo_n "checking for ZIP... " >&6; } 21558 if test ! -x "$tool_specified"; then 21559 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 21560 $as_echo "not found" >&6; } 21561 as_fn_error $? "User supplied tool ZIP=$tool_specified does not exist or is not executable" "$LINENO" 5 21562 fi 21563 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 21564 $as_echo "$tool_specified" >&6; } 21565 fi 21566 fi 21567 fi 21568 21569 fi 21570 21571 21572 21573 if test "x$ZIP" = x; then 21574 as_fn_error $? "Could not find required tool for ZIP" "$LINENO" 5 21575 fi 21576 21577 21578 21579 # Non-required basic tools 21580 21581 21582 21583 # Publish this variable in the help. 21584 21585 21586 if [ -z "${LDD+x}" ]; then 21587 # The variable is not set by user, try to locate tool using the code snippet 21588 for ac_prog in ldd 21589 do 21590 # Extract the first word of "$ac_prog", so it can be a program name with args. 21591 set dummy $ac_prog; ac_word=$2 21592 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21593 $as_echo_n "checking for $ac_word... " >&6; } 21594 if ${ac_cv_path_LDD+:} false; then : 21595 $as_echo_n "(cached) " >&6 21596 else 21597 case $LDD in 21598 [\\/]* | ?:[\\/]*) 21599 ac_cv_path_LDD="$LDD" # Let the user override the test with a path. 21600 ;; 21601 *) 21602 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21603 for as_dir in $PATH 21604 do 21605 IFS=$as_save_IFS 21606 test -z "$as_dir" && as_dir=. 21607 for ac_exec_ext in '' $ac_executable_extensions; do 21608 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21609 ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext" 21610 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21611 break 2 21612 fi 21613 done 21614 done 21615 IFS=$as_save_IFS 21616 21617 ;; 21618 esac 21619 fi 21620 LDD=$ac_cv_path_LDD 21621 if test -n "$LDD"; then 21622 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDD" >&5 21623 $as_echo "$LDD" >&6; } 21624 else 21625 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21626 $as_echo "no" >&6; } 21627 fi 21628 21629 21630 test -n "$LDD" && break 21631 done 21632 21633 else 21634 # The variable is set, but is it from the command line or the environment? 21635 21636 # Try to remove the string !LDD! from our list. 21637 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LDD!/} 21638 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 21639 # If it failed, the variable was not from the command line. Ignore it, 21640 # but warn the user (except for BASH, which is always set by the calling BASH). 21641 if test "xLDD" != xBASH; then 21642 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LDD from the environment. Use command line variables instead." >&5 21643 $as_echo "$as_me: WARNING: Ignoring value of LDD from the environment. Use command line variables instead." >&2;} 21644 fi 21645 # Try to locate tool using the code snippet 21646 for ac_prog in ldd 21647 do 21648 # Extract the first word of "$ac_prog", so it can be a program name with args. 21649 set dummy $ac_prog; ac_word=$2 21650 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21651 $as_echo_n "checking for $ac_word... " >&6; } 21652 if ${ac_cv_path_LDD+:} false; then : 21653 $as_echo_n "(cached) " >&6 21654 else 21655 case $LDD in 21656 [\\/]* | ?:[\\/]*) 21657 ac_cv_path_LDD="$LDD" # Let the user override the test with a path. 21658 ;; 21659 *) 21660 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21661 for as_dir in $PATH 21662 do 21663 IFS=$as_save_IFS 21664 test -z "$as_dir" && as_dir=. 21665 for ac_exec_ext in '' $ac_executable_extensions; do 21666 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21667 ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext" 21668 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21669 break 2 21670 fi 21671 done 21672 done 21673 IFS=$as_save_IFS 21674 21675 ;; 21676 esac 21677 fi 21678 LDD=$ac_cv_path_LDD 21679 if test -n "$LDD"; then 21680 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDD" >&5 21681 $as_echo "$LDD" >&6; } 21682 else 21683 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21684 $as_echo "no" >&6; } 21685 fi 21686 21687 21688 test -n "$LDD" && break 21689 done 21690 21691 else 21692 # If it succeeded, then it was overridden by the user. We will use it 21693 # for the tool. 21694 21695 # First remove it from the list of overridden variables, so we can test 21696 # for unknown variables in the end. 21697 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 21698 21699 # Check if we try to supply an empty value 21700 if test "x$LDD" = x; then 21701 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool LDD= (no value)" >&5 21702 $as_echo "$as_me: Setting user supplied tool LDD= (no value)" >&6;} 21703 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LDD" >&5 21704 $as_echo_n "checking for LDD... " >&6; } 21705 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 21706 $as_echo "disabled" >&6; } 21707 else 21708 # Check if the provided tool contains a complete path. 21709 tool_specified="$LDD" 21710 tool_basename="${tool_specified##*/}" 21711 if test "x$tool_basename" = "x$tool_specified"; then 21712 # A command without a complete path is provided, search $PATH. 21713 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LDD=$tool_basename" >&5 21714 $as_echo "$as_me: Will search for user supplied tool LDD=$tool_basename" >&6;} 21715 # Extract the first word of "$tool_basename", so it can be a program name with args. 21716 set dummy $tool_basename; ac_word=$2 21717 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21718 $as_echo_n "checking for $ac_word... " >&6; } 21719 if ${ac_cv_path_LDD+:} false; then : 21720 $as_echo_n "(cached) " >&6 21721 else 21722 case $LDD in 21723 [\\/]* | ?:[\\/]*) 21724 ac_cv_path_LDD="$LDD" # Let the user override the test with a path. 21725 ;; 21726 *) 21727 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21728 for as_dir in $PATH 21729 do 21730 IFS=$as_save_IFS 21731 test -z "$as_dir" && as_dir=. 21732 for ac_exec_ext in '' $ac_executable_extensions; do 21733 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21734 ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext" 21735 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21736 break 2 21737 fi 21738 done 21739 done 21740 IFS=$as_save_IFS 21741 21742 ;; 21743 esac 21744 fi 21745 LDD=$ac_cv_path_LDD 21746 if test -n "$LDD"; then 21747 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDD" >&5 21748 $as_echo "$LDD" >&6; } 21749 else 21750 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21751 $as_echo "no" >&6; } 21752 fi 21753 21754 21755 if test "x$LDD" = x; then 21756 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 21757 fi 21758 else 21759 # Otherwise we believe it is a complete path. Use it as it is. 21760 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LDD=$tool_specified" >&5 21761 $as_echo "$as_me: Will use user supplied tool LDD=$tool_specified" >&6;} 21762 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LDD" >&5 21763 $as_echo_n "checking for LDD... " >&6; } 21764 if test ! -x "$tool_specified"; then 21765 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 21766 $as_echo "not found" >&6; } 21767 as_fn_error $? "User supplied tool LDD=$tool_specified does not exist or is not executable" "$LINENO" 5 21768 fi 21769 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 21770 $as_echo "$tool_specified" >&6; } 21771 fi 21772 fi 21773 fi 21774 21775 fi 21776 21777 21778 if test "x$LDD" = "x"; then 21779 # List shared lib dependencies is used for 21780 # debug output and checking for forbidden dependencies. 21781 # We can build without it. 21782 LDD="true" 21783 fi 21784 21785 21786 # Publish this variable in the help. 21787 21788 21789 if [ -z "${OTOOL+x}" ]; then 21790 # The variable is not set by user, try to locate tool using the code snippet 21791 for ac_prog in otool 21792 do 21793 # Extract the first word of "$ac_prog", so it can be a program name with args. 21794 set dummy $ac_prog; ac_word=$2 21795 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21796 $as_echo_n "checking for $ac_word... " >&6; } 21797 if ${ac_cv_path_OTOOL+:} false; then : 21798 $as_echo_n "(cached) " >&6 21799 else 21800 case $OTOOL in 21801 [\\/]* | ?:[\\/]*) 21802 ac_cv_path_OTOOL="$OTOOL" # Let the user override the test with a path. 21803 ;; 21804 *) 21805 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21806 for as_dir in $PATH 21807 do 21808 IFS=$as_save_IFS 21809 test -z "$as_dir" && as_dir=. 21810 for ac_exec_ext in '' $ac_executable_extensions; do 21811 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21812 ac_cv_path_OTOOL="$as_dir/$ac_word$ac_exec_ext" 21813 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21814 break 2 21815 fi 21816 done 21817 done 21818 IFS=$as_save_IFS 21819 21820 ;; 21821 esac 21822 fi 21823 OTOOL=$ac_cv_path_OTOOL 21824 if test -n "$OTOOL"; then 21825 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 21826 $as_echo "$OTOOL" >&6; } 21827 else 21828 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21829 $as_echo "no" >&6; } 21830 fi 21831 21832 21833 test -n "$OTOOL" && break 21834 done 21835 21836 else 21837 # The variable is set, but is it from the command line or the environment? 21838 21839 # Try to remove the string !OTOOL! from our list. 21840 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!OTOOL!/} 21841 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 21842 # If it failed, the variable was not from the command line. Ignore it, 21843 # but warn the user (except for BASH, which is always set by the calling BASH). 21844 if test "xOTOOL" != xBASH; then 21845 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of OTOOL from the environment. Use command line variables instead." >&5 21846 $as_echo "$as_me: WARNING: Ignoring value of OTOOL from the environment. Use command line variables instead." >&2;} 21847 fi 21848 # Try to locate tool using the code snippet 21849 for ac_prog in otool 21850 do 21851 # Extract the first word of "$ac_prog", so it can be a program name with args. 21852 set dummy $ac_prog; ac_word=$2 21853 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21854 $as_echo_n "checking for $ac_word... " >&6; } 21855 if ${ac_cv_path_OTOOL+:} false; then : 21856 $as_echo_n "(cached) " >&6 21857 else 21858 case $OTOOL in 21859 [\\/]* | ?:[\\/]*) 21860 ac_cv_path_OTOOL="$OTOOL" # Let the user override the test with a path. 21861 ;; 21862 *) 21863 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21864 for as_dir in $PATH 21865 do 21866 IFS=$as_save_IFS 21867 test -z "$as_dir" && as_dir=. 21868 for ac_exec_ext in '' $ac_executable_extensions; do 21869 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21870 ac_cv_path_OTOOL="$as_dir/$ac_word$ac_exec_ext" 21871 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21872 break 2 21873 fi 21874 done 21875 done 21876 IFS=$as_save_IFS 21877 21878 ;; 21879 esac 21880 fi 21881 OTOOL=$ac_cv_path_OTOOL 21882 if test -n "$OTOOL"; then 21883 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 21884 $as_echo "$OTOOL" >&6; } 21885 else 21886 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21887 $as_echo "no" >&6; } 21888 fi 21889 21890 21891 test -n "$OTOOL" && break 21892 done 21893 21894 else 21895 # If it succeeded, then it was overridden by the user. We will use it 21896 # for the tool. 21897 21898 # First remove it from the list of overridden variables, so we can test 21899 # for unknown variables in the end. 21900 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 21901 21902 # Check if we try to supply an empty value 21903 if test "x$OTOOL" = x; then 21904 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool OTOOL= (no value)" >&5 21905 $as_echo "$as_me: Setting user supplied tool OTOOL= (no value)" >&6;} 21906 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTOOL" >&5 21907 $as_echo_n "checking for OTOOL... " >&6; } 21908 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 21909 $as_echo "disabled" >&6; } 21910 else 21911 # Check if the provided tool contains a complete path. 21912 tool_specified="$OTOOL" 21913 tool_basename="${tool_specified##*/}" 21914 if test "x$tool_basename" = "x$tool_specified"; then 21915 # A command without a complete path is provided, search $PATH. 21916 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool OTOOL=$tool_basename" >&5 21917 $as_echo "$as_me: Will search for user supplied tool OTOOL=$tool_basename" >&6;} 21918 # Extract the first word of "$tool_basename", so it can be a program name with args. 21919 set dummy $tool_basename; ac_word=$2 21920 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21921 $as_echo_n "checking for $ac_word... " >&6; } 21922 if ${ac_cv_path_OTOOL+:} false; then : 21923 $as_echo_n "(cached) " >&6 21924 else 21925 case $OTOOL in 21926 [\\/]* | ?:[\\/]*) 21927 ac_cv_path_OTOOL="$OTOOL" # Let the user override the test with a path. 21928 ;; 21929 *) 21930 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21931 for as_dir in $PATH 21932 do 21933 IFS=$as_save_IFS 21934 test -z "$as_dir" && as_dir=. 21935 for ac_exec_ext in '' $ac_executable_extensions; do 21936 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21937 ac_cv_path_OTOOL="$as_dir/$ac_word$ac_exec_ext" 21938 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21939 break 2 21940 fi 21941 done 21942 done 21943 IFS=$as_save_IFS 21944 21945 ;; 21946 esac 21947 fi 21948 OTOOL=$ac_cv_path_OTOOL 21949 if test -n "$OTOOL"; then 21950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 21951 $as_echo "$OTOOL" >&6; } 21952 else 21953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21954 $as_echo "no" >&6; } 21955 fi 21956 21957 21958 if test "x$OTOOL" = x; then 21959 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 21960 fi 21961 else 21962 # Otherwise we believe it is a complete path. Use it as it is. 21963 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool OTOOL=$tool_specified" >&5 21964 $as_echo "$as_me: Will use user supplied tool OTOOL=$tool_specified" >&6;} 21965 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTOOL" >&5 21966 $as_echo_n "checking for OTOOL... " >&6; } 21967 if test ! -x "$tool_specified"; then 21968 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 21969 $as_echo "not found" >&6; } 21970 as_fn_error $? "User supplied tool OTOOL=$tool_specified does not exist or is not executable" "$LINENO" 5 21971 fi 21972 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 21973 $as_echo "$tool_specified" >&6; } 21974 fi 21975 fi 21976 fi 21977 21978 fi 21979 21980 21981 if test "x$OTOOL" = "x"; then 21982 OTOOL="true" 21983 fi 21984 21985 21986 # Publish this variable in the help. 21987 21988 21989 if [ -z "${READELF+x}" ]; then 21990 # The variable is not set by user, try to locate tool using the code snippet 21991 for ac_prog in greadelf readelf 21992 do 21993 # Extract the first word of "$ac_prog", so it can be a program name with args. 21994 set dummy $ac_prog; ac_word=$2 21995 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21996 $as_echo_n "checking for $ac_word... " >&6; } 21997 if ${ac_cv_path_READELF+:} false; then : 21998 $as_echo_n "(cached) " >&6 21999 else 22000 case $READELF in 22001 [\\/]* | ?:[\\/]*) 22002 ac_cv_path_READELF="$READELF" # Let the user override the test with a path. 22003 ;; 22004 *) 22005 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22006 for as_dir in $PATH 22007 do 22008 IFS=$as_save_IFS 22009 test -z "$as_dir" && as_dir=. 22010 for ac_exec_ext in '' $ac_executable_extensions; do 22011 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22012 ac_cv_path_READELF="$as_dir/$ac_word$ac_exec_ext" 22013 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22014 break 2 22015 fi 22016 done 22017 done 22018 IFS=$as_save_IFS 22019 22020 ;; 22021 esac 22022 fi 22023 READELF=$ac_cv_path_READELF 22024 if test -n "$READELF"; then 22025 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5 22026 $as_echo "$READELF" >&6; } 22027 else 22028 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22029 $as_echo "no" >&6; } 22030 fi 22031 22032 22033 test -n "$READELF" && break 22034 done 22035 22036 else 22037 # The variable is set, but is it from the command line or the environment? 22038 22039 # Try to remove the string !READELF! from our list. 22040 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!READELF!/} 22041 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 22042 # If it failed, the variable was not from the command line. Ignore it, 22043 # but warn the user (except for BASH, which is always set by the calling BASH). 22044 if test "xREADELF" != xBASH; then 22045 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of READELF from the environment. Use command line variables instead." >&5 22046 $as_echo "$as_me: WARNING: Ignoring value of READELF from the environment. Use command line variables instead." >&2;} 22047 fi 22048 # Try to locate tool using the code snippet 22049 for ac_prog in greadelf readelf 22050 do 22051 # Extract the first word of "$ac_prog", so it can be a program name with args. 22052 set dummy $ac_prog; ac_word=$2 22053 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22054 $as_echo_n "checking for $ac_word... " >&6; } 22055 if ${ac_cv_path_READELF+:} false; then : 22056 $as_echo_n "(cached) " >&6 22057 else 22058 case $READELF in 22059 [\\/]* | ?:[\\/]*) 22060 ac_cv_path_READELF="$READELF" # Let the user override the test with a path. 22061 ;; 22062 *) 22063 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22064 for as_dir in $PATH 22065 do 22066 IFS=$as_save_IFS 22067 test -z "$as_dir" && as_dir=. 22068 for ac_exec_ext in '' $ac_executable_extensions; do 22069 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22070 ac_cv_path_READELF="$as_dir/$ac_word$ac_exec_ext" 22071 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22072 break 2 22073 fi 22074 done 22075 done 22076 IFS=$as_save_IFS 22077 22078 ;; 22079 esac 22080 fi 22081 READELF=$ac_cv_path_READELF 22082 if test -n "$READELF"; then 22083 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5 22084 $as_echo "$READELF" >&6; } 22085 else 22086 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22087 $as_echo "no" >&6; } 22088 fi 22089 22090 22091 test -n "$READELF" && break 22092 done 22093 22094 else 22095 # If it succeeded, then it was overridden by the user. We will use it 22096 # for the tool. 22097 22098 # First remove it from the list of overridden variables, so we can test 22099 # for unknown variables in the end. 22100 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 22101 22102 # Check if we try to supply an empty value 22103 if test "x$READELF" = x; then 22104 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool READELF= (no value)" >&5 22105 $as_echo "$as_me: Setting user supplied tool READELF= (no value)" >&6;} 22106 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READELF" >&5 22107 $as_echo_n "checking for READELF... " >&6; } 22108 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 22109 $as_echo "disabled" >&6; } 22110 else 22111 # Check if the provided tool contains a complete path. 22112 tool_specified="$READELF" 22113 tool_basename="${tool_specified##*/}" 22114 if test "x$tool_basename" = "x$tool_specified"; then 22115 # A command without a complete path is provided, search $PATH. 22116 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool READELF=$tool_basename" >&5 22117 $as_echo "$as_me: Will search for user supplied tool READELF=$tool_basename" >&6;} 22118 # Extract the first word of "$tool_basename", so it can be a program name with args. 22119 set dummy $tool_basename; ac_word=$2 22120 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22121 $as_echo_n "checking for $ac_word... " >&6; } 22122 if ${ac_cv_path_READELF+:} false; then : 22123 $as_echo_n "(cached) " >&6 22124 else 22125 case $READELF in 22126 [\\/]* | ?:[\\/]*) 22127 ac_cv_path_READELF="$READELF" # Let the user override the test with a path. 22128 ;; 22129 *) 22130 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22131 for as_dir in $PATH 22132 do 22133 IFS=$as_save_IFS 22134 test -z "$as_dir" && as_dir=. 22135 for ac_exec_ext in '' $ac_executable_extensions; do 22136 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22137 ac_cv_path_READELF="$as_dir/$ac_word$ac_exec_ext" 22138 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22139 break 2 22140 fi 22141 done 22142 done 22143 IFS=$as_save_IFS 22144 22145 ;; 22146 esac 22147 fi 22148 READELF=$ac_cv_path_READELF 22149 if test -n "$READELF"; then 22150 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5 22151 $as_echo "$READELF" >&6; } 22152 else 22153 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22154 $as_echo "no" >&6; } 22155 fi 22156 22157 22158 if test "x$READELF" = x; then 22159 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 22160 fi 22161 else 22162 # Otherwise we believe it is a complete path. Use it as it is. 22163 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool READELF=$tool_specified" >&5 22164 $as_echo "$as_me: Will use user supplied tool READELF=$tool_specified" >&6;} 22165 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READELF" >&5 22166 $as_echo_n "checking for READELF... " >&6; } 22167 if test ! -x "$tool_specified"; then 22168 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 22169 $as_echo "not found" >&6; } 22170 as_fn_error $? "User supplied tool READELF=$tool_specified does not exist or is not executable" "$LINENO" 5 22171 fi 22172 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 22173 $as_echo "$tool_specified" >&6; } 22174 fi 22175 fi 22176 fi 22177 22178 fi 22179 22180 22181 22182 22183 # Publish this variable in the help. 22184 22185 22186 if [ -z "${HG+x}" ]; then 22187 # The variable is not set by user, try to locate tool using the code snippet 22188 for ac_prog in hg 22189 do 22190 # Extract the first word of "$ac_prog", so it can be a program name with args. 22191 set dummy $ac_prog; ac_word=$2 22192 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22193 $as_echo_n "checking for $ac_word... " >&6; } 22194 if ${ac_cv_path_HG+:} false; then : 22195 $as_echo_n "(cached) " >&6 22196 else 22197 case $HG in 22198 [\\/]* | ?:[\\/]*) 22199 ac_cv_path_HG="$HG" # Let the user override the test with a path. 22200 ;; 22201 *) 22202 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22203 for as_dir in $PATH 22204 do 22205 IFS=$as_save_IFS 22206 test -z "$as_dir" && as_dir=. 22207 for ac_exec_ext in '' $ac_executable_extensions; do 22208 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22209 ac_cv_path_HG="$as_dir/$ac_word$ac_exec_ext" 22210 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22211 break 2 22212 fi 22213 done 22214 done 22215 IFS=$as_save_IFS 22216 22217 ;; 22218 esac 22219 fi 22220 HG=$ac_cv_path_HG 22221 if test -n "$HG"; then 22222 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HG" >&5 22223 $as_echo "$HG" >&6; } 22224 else 22225 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22226 $as_echo "no" >&6; } 22227 fi 22228 22229 22230 test -n "$HG" && break 22231 done 22232 22233 else 22234 # The variable is set, but is it from the command line or the environment? 22235 22236 # Try to remove the string !HG! from our list. 22237 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!HG!/} 22238 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 22239 # If it failed, the variable was not from the command line. Ignore it, 22240 # but warn the user (except for BASH, which is always set by the calling BASH). 22241 if test "xHG" != xBASH; then 22242 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of HG from the environment. Use command line variables instead." >&5 22243 $as_echo "$as_me: WARNING: Ignoring value of HG from the environment. Use command line variables instead." >&2;} 22244 fi 22245 # Try to locate tool using the code snippet 22246 for ac_prog in hg 22247 do 22248 # Extract the first word of "$ac_prog", so it can be a program name with args. 22249 set dummy $ac_prog; ac_word=$2 22250 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22251 $as_echo_n "checking for $ac_word... " >&6; } 22252 if ${ac_cv_path_HG+:} false; then : 22253 $as_echo_n "(cached) " >&6 22254 else 22255 case $HG in 22256 [\\/]* | ?:[\\/]*) 22257 ac_cv_path_HG="$HG" # Let the user override the test with a path. 22258 ;; 22259 *) 22260 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22261 for as_dir in $PATH 22262 do 22263 IFS=$as_save_IFS 22264 test -z "$as_dir" && as_dir=. 22265 for ac_exec_ext in '' $ac_executable_extensions; do 22266 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22267 ac_cv_path_HG="$as_dir/$ac_word$ac_exec_ext" 22268 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22269 break 2 22270 fi 22271 done 22272 done 22273 IFS=$as_save_IFS 22274 22275 ;; 22276 esac 22277 fi 22278 HG=$ac_cv_path_HG 22279 if test -n "$HG"; then 22280 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HG" >&5 22281 $as_echo "$HG" >&6; } 22282 else 22283 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22284 $as_echo "no" >&6; } 22285 fi 22286 22287 22288 test -n "$HG" && break 22289 done 22290 22291 else 22292 # If it succeeded, then it was overridden by the user. We will use it 22293 # for the tool. 22294 22295 # First remove it from the list of overridden variables, so we can test 22296 # for unknown variables in the end. 22297 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 22298 22299 # Check if we try to supply an empty value 22300 if test "x$HG" = x; then 22301 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool HG= (no value)" >&5 22302 $as_echo "$as_me: Setting user supplied tool HG= (no value)" >&6;} 22303 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HG" >&5 22304 $as_echo_n "checking for HG... " >&6; } 22305 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 22306 $as_echo "disabled" >&6; } 22307 else 22308 # Check if the provided tool contains a complete path. 22309 tool_specified="$HG" 22310 tool_basename="${tool_specified##*/}" 22311 if test "x$tool_basename" = "x$tool_specified"; then 22312 # A command without a complete path is provided, search $PATH. 22313 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool HG=$tool_basename" >&5 22314 $as_echo "$as_me: Will search for user supplied tool HG=$tool_basename" >&6;} 22315 # Extract the first word of "$tool_basename", so it can be a program name with args. 22316 set dummy $tool_basename; ac_word=$2 22317 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22318 $as_echo_n "checking for $ac_word... " >&6; } 22319 if ${ac_cv_path_HG+:} false; then : 22320 $as_echo_n "(cached) " >&6 22321 else 22322 case $HG in 22323 [\\/]* | ?:[\\/]*) 22324 ac_cv_path_HG="$HG" # Let the user override the test with a path. 22325 ;; 22326 *) 22327 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22328 for as_dir in $PATH 22329 do 22330 IFS=$as_save_IFS 22331 test -z "$as_dir" && as_dir=. 22332 for ac_exec_ext in '' $ac_executable_extensions; do 22333 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22334 ac_cv_path_HG="$as_dir/$ac_word$ac_exec_ext" 22335 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22336 break 2 22337 fi 22338 done 22339 done 22340 IFS=$as_save_IFS 22341 22342 ;; 22343 esac 22344 fi 22345 HG=$ac_cv_path_HG 22346 if test -n "$HG"; then 22347 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HG" >&5 22348 $as_echo "$HG" >&6; } 22349 else 22350 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22351 $as_echo "no" >&6; } 22352 fi 22353 22354 22355 if test "x$HG" = x; then 22356 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 22357 fi 22358 else 22359 # Otherwise we believe it is a complete path. Use it as it is. 22360 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool HG=$tool_specified" >&5 22361 $as_echo "$as_me: Will use user supplied tool HG=$tool_specified" >&6;} 22362 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HG" >&5 22363 $as_echo_n "checking for HG... " >&6; } 22364 if test ! -x "$tool_specified"; then 22365 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 22366 $as_echo "not found" >&6; } 22367 as_fn_error $? "User supplied tool HG=$tool_specified does not exist or is not executable" "$LINENO" 5 22368 fi 22369 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 22370 $as_echo "$tool_specified" >&6; } 22371 fi 22372 fi 22373 fi 22374 22375 fi 22376 22377 22378 22379 22380 # Publish this variable in the help. 22381 22382 22383 if [ -z "${STAT+x}" ]; then 22384 # The variable is not set by user, try to locate tool using the code snippet 22385 for ac_prog in stat 22386 do 22387 # Extract the first word of "$ac_prog", so it can be a program name with args. 22388 set dummy $ac_prog; ac_word=$2 22389 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22390 $as_echo_n "checking for $ac_word... " >&6; } 22391 if ${ac_cv_path_STAT+:} false; then : 22392 $as_echo_n "(cached) " >&6 22393 else 22394 case $STAT in 22395 [\\/]* | ?:[\\/]*) 22396 ac_cv_path_STAT="$STAT" # Let the user override the test with a path. 22397 ;; 22398 *) 22399 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22400 for as_dir in $PATH 22401 do 22402 IFS=$as_save_IFS 22403 test -z "$as_dir" && as_dir=. 22404 for ac_exec_ext in '' $ac_executable_extensions; do 22405 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22406 ac_cv_path_STAT="$as_dir/$ac_word$ac_exec_ext" 22407 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22408 break 2 22409 fi 22410 done 22411 done 22412 IFS=$as_save_IFS 22413 22414 ;; 22415 esac 22416 fi 22417 STAT=$ac_cv_path_STAT 22418 if test -n "$STAT"; then 22419 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAT" >&5 22420 $as_echo "$STAT" >&6; } 22421 else 22422 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22423 $as_echo "no" >&6; } 22424 fi 22425 22426 22427 test -n "$STAT" && break 22428 done 22429 22430 else 22431 # The variable is set, but is it from the command line or the environment? 22432 22433 # Try to remove the string !STAT! from our list. 22434 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!STAT!/} 22435 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 22436 # If it failed, the variable was not from the command line. Ignore it, 22437 # but warn the user (except for BASH, which is always set by the calling BASH). 22438 if test "xSTAT" != xBASH; then 22439 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of STAT from the environment. Use command line variables instead." >&5 22440 $as_echo "$as_me: WARNING: Ignoring value of STAT from the environment. Use command line variables instead." >&2;} 22441 fi 22442 # Try to locate tool using the code snippet 22443 for ac_prog in stat 22444 do 22445 # Extract the first word of "$ac_prog", so it can be a program name with args. 22446 set dummy $ac_prog; ac_word=$2 22447 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22448 $as_echo_n "checking for $ac_word... " >&6; } 22449 if ${ac_cv_path_STAT+:} false; then : 22450 $as_echo_n "(cached) " >&6 22451 else 22452 case $STAT in 22453 [\\/]* | ?:[\\/]*) 22454 ac_cv_path_STAT="$STAT" # Let the user override the test with a path. 22455 ;; 22456 *) 22457 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22458 for as_dir in $PATH 22459 do 22460 IFS=$as_save_IFS 22461 test -z "$as_dir" && as_dir=. 22462 for ac_exec_ext in '' $ac_executable_extensions; do 22463 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22464 ac_cv_path_STAT="$as_dir/$ac_word$ac_exec_ext" 22465 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22466 break 2 22467 fi 22468 done 22469 done 22470 IFS=$as_save_IFS 22471 22472 ;; 22473 esac 22474 fi 22475 STAT=$ac_cv_path_STAT 22476 if test -n "$STAT"; then 22477 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAT" >&5 22478 $as_echo "$STAT" >&6; } 22479 else 22480 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22481 $as_echo "no" >&6; } 22482 fi 22483 22484 22485 test -n "$STAT" && break 22486 done 22487 22488 else 22489 # If it succeeded, then it was overridden by the user. We will use it 22490 # for the tool. 22491 22492 # First remove it from the list of overridden variables, so we can test 22493 # for unknown variables in the end. 22494 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 22495 22496 # Check if we try to supply an empty value 22497 if test "x$STAT" = x; then 22498 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool STAT= (no value)" >&5 22499 $as_echo "$as_me: Setting user supplied tool STAT= (no value)" >&6;} 22500 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STAT" >&5 22501 $as_echo_n "checking for STAT... " >&6; } 22502 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 22503 $as_echo "disabled" >&6; } 22504 else 22505 # Check if the provided tool contains a complete path. 22506 tool_specified="$STAT" 22507 tool_basename="${tool_specified##*/}" 22508 if test "x$tool_basename" = "x$tool_specified"; then 22509 # A command without a complete path is provided, search $PATH. 22510 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool STAT=$tool_basename" >&5 22511 $as_echo "$as_me: Will search for user supplied tool STAT=$tool_basename" >&6;} 22512 # Extract the first word of "$tool_basename", so it can be a program name with args. 22513 set dummy $tool_basename; ac_word=$2 22514 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22515 $as_echo_n "checking for $ac_word... " >&6; } 22516 if ${ac_cv_path_STAT+:} false; then : 22517 $as_echo_n "(cached) " >&6 22518 else 22519 case $STAT in 22520 [\\/]* | ?:[\\/]*) 22521 ac_cv_path_STAT="$STAT" # Let the user override the test with a path. 22522 ;; 22523 *) 22524 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22525 for as_dir in $PATH 22526 do 22527 IFS=$as_save_IFS 22528 test -z "$as_dir" && as_dir=. 22529 for ac_exec_ext in '' $ac_executable_extensions; do 22530 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22531 ac_cv_path_STAT="$as_dir/$ac_word$ac_exec_ext" 22532 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22533 break 2 22534 fi 22535 done 22536 done 22537 IFS=$as_save_IFS 22538 22539 ;; 22540 esac 22541 fi 22542 STAT=$ac_cv_path_STAT 22543 if test -n "$STAT"; then 22544 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAT" >&5 22545 $as_echo "$STAT" >&6; } 22546 else 22547 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22548 $as_echo "no" >&6; } 22549 fi 22550 22551 22552 if test "x$STAT" = x; then 22553 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 22554 fi 22555 else 22556 # Otherwise we believe it is a complete path. Use it as it is. 22557 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool STAT=$tool_specified" >&5 22558 $as_echo "$as_me: Will use user supplied tool STAT=$tool_specified" >&6;} 22559 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STAT" >&5 22560 $as_echo_n "checking for STAT... " >&6; } 22561 if test ! -x "$tool_specified"; then 22562 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 22563 $as_echo "not found" >&6; } 22564 as_fn_error $? "User supplied tool STAT=$tool_specified does not exist or is not executable" "$LINENO" 5 22565 fi 22566 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 22567 $as_echo "$tool_specified" >&6; } 22568 fi 22569 fi 22570 fi 22571 22572 fi 22573 22574 22575 22576 22577 # Publish this variable in the help. 22578 22579 22580 if [ -z "${TIME+x}" ]; then 22581 # The variable is not set by user, try to locate tool using the code snippet 22582 for ac_prog in time 22583 do 22584 # Extract the first word of "$ac_prog", so it can be a program name with args. 22585 set dummy $ac_prog; ac_word=$2 22586 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22587 $as_echo_n "checking for $ac_word... " >&6; } 22588 if ${ac_cv_path_TIME+:} false; then : 22589 $as_echo_n "(cached) " >&6 22590 else 22591 case $TIME in 22592 [\\/]* | ?:[\\/]*) 22593 ac_cv_path_TIME="$TIME" # Let the user override the test with a path. 22594 ;; 22595 *) 22596 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22597 for as_dir in $PATH 22598 do 22599 IFS=$as_save_IFS 22600 test -z "$as_dir" && as_dir=. 22601 for ac_exec_ext in '' $ac_executable_extensions; do 22602 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22603 ac_cv_path_TIME="$as_dir/$ac_word$ac_exec_ext" 22604 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22605 break 2 22606 fi 22607 done 22608 done 22609 IFS=$as_save_IFS 22610 22611 ;; 22612 esac 22613 fi 22614 TIME=$ac_cv_path_TIME 22615 if test -n "$TIME"; then 22616 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TIME" >&5 22617 $as_echo "$TIME" >&6; } 22618 else 22619 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22620 $as_echo "no" >&6; } 22621 fi 22622 22623 22624 test -n "$TIME" && break 22625 done 22626 22627 else 22628 # The variable is set, but is it from the command line or the environment? 22629 22630 # Try to remove the string !TIME! from our list. 22631 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TIME!/} 22632 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 22633 # If it failed, the variable was not from the command line. Ignore it, 22634 # but warn the user (except for BASH, which is always set by the calling BASH). 22635 if test "xTIME" != xBASH; then 22636 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TIME from the environment. Use command line variables instead." >&5 22637 $as_echo "$as_me: WARNING: Ignoring value of TIME from the environment. Use command line variables instead." >&2;} 22638 fi 22639 # Try to locate tool using the code snippet 22640 for ac_prog in time 22641 do 22642 # Extract the first word of "$ac_prog", so it can be a program name with args. 22643 set dummy $ac_prog; ac_word=$2 22644 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22645 $as_echo_n "checking for $ac_word... " >&6; } 22646 if ${ac_cv_path_TIME+:} false; then : 22647 $as_echo_n "(cached) " >&6 22648 else 22649 case $TIME in 22650 [\\/]* | ?:[\\/]*) 22651 ac_cv_path_TIME="$TIME" # Let the user override the test with a path. 22652 ;; 22653 *) 22654 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22655 for as_dir in $PATH 22656 do 22657 IFS=$as_save_IFS 22658 test -z "$as_dir" && as_dir=. 22659 for ac_exec_ext in '' $ac_executable_extensions; do 22660 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22661 ac_cv_path_TIME="$as_dir/$ac_word$ac_exec_ext" 22662 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22663 break 2 22664 fi 22665 done 22666 done 22667 IFS=$as_save_IFS 22668 22669 ;; 22670 esac 22671 fi 22672 TIME=$ac_cv_path_TIME 22673 if test -n "$TIME"; then 22674 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TIME" >&5 22675 $as_echo "$TIME" >&6; } 22676 else 22677 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22678 $as_echo "no" >&6; } 22679 fi 22680 22681 22682 test -n "$TIME" && break 22683 done 22684 22685 else 22686 # If it succeeded, then it was overridden by the user. We will use it 22687 # for the tool. 22688 22689 # First remove it from the list of overridden variables, so we can test 22690 # for unknown variables in the end. 22691 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 22692 22693 # Check if we try to supply an empty value 22694 if test "x$TIME" = x; then 22695 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TIME= (no value)" >&5 22696 $as_echo "$as_me: Setting user supplied tool TIME= (no value)" >&6;} 22697 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIME" >&5 22698 $as_echo_n "checking for TIME... " >&6; } 22699 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 22700 $as_echo "disabled" >&6; } 22701 else 22702 # Check if the provided tool contains a complete path. 22703 tool_specified="$TIME" 22704 tool_basename="${tool_specified##*/}" 22705 if test "x$tool_basename" = "x$tool_specified"; then 22706 # A command without a complete path is provided, search $PATH. 22707 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TIME=$tool_basename" >&5 22708 $as_echo "$as_me: Will search for user supplied tool TIME=$tool_basename" >&6;} 22709 # Extract the first word of "$tool_basename", so it can be a program name with args. 22710 set dummy $tool_basename; ac_word=$2 22711 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22712 $as_echo_n "checking for $ac_word... " >&6; } 22713 if ${ac_cv_path_TIME+:} false; then : 22714 $as_echo_n "(cached) " >&6 22715 else 22716 case $TIME in 22717 [\\/]* | ?:[\\/]*) 22718 ac_cv_path_TIME="$TIME" # Let the user override the test with a path. 22719 ;; 22720 *) 22721 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22722 for as_dir in $PATH 22723 do 22724 IFS=$as_save_IFS 22725 test -z "$as_dir" && as_dir=. 22726 for ac_exec_ext in '' $ac_executable_extensions; do 22727 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22728 ac_cv_path_TIME="$as_dir/$ac_word$ac_exec_ext" 22729 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22730 break 2 22731 fi 22732 done 22733 done 22734 IFS=$as_save_IFS 22735 22736 ;; 22737 esac 22738 fi 22739 TIME=$ac_cv_path_TIME 22740 if test -n "$TIME"; then 22741 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TIME" >&5 22742 $as_echo "$TIME" >&6; } 22743 else 22744 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22745 $as_echo "no" >&6; } 22746 fi 22747 22748 22749 if test "x$TIME" = x; then 22750 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 22751 fi 22752 else 22753 # Otherwise we believe it is a complete path. Use it as it is. 22754 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TIME=$tool_specified" >&5 22755 $as_echo "$as_me: Will use user supplied tool TIME=$tool_specified" >&6;} 22756 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIME" >&5 22757 $as_echo_n "checking for TIME... " >&6; } 22758 if test ! -x "$tool_specified"; then 22759 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 22760 $as_echo "not found" >&6; } 22761 as_fn_error $? "User supplied tool TIME=$tool_specified does not exist or is not executable" "$LINENO" 5 22762 fi 22763 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 22764 $as_echo "$tool_specified" >&6; } 22765 fi 22766 fi 22767 fi 22768 22769 fi 22770 22771 22772 22773 22774 # Publish this variable in the help. 22775 22776 22777 if [ -z "${DTRACE+x}" ]; then 22778 # The variable is not set by user, try to locate tool using the code snippet 22779 for ac_prog in dtrace 22780 do 22781 # Extract the first word of "$ac_prog", so it can be a program name with args. 22782 set dummy $ac_prog; ac_word=$2 22783 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22784 $as_echo_n "checking for $ac_word... " >&6; } 22785 if ${ac_cv_path_DTRACE+:} false; then : 22786 $as_echo_n "(cached) " >&6 22787 else 22788 case $DTRACE in 22789 [\\/]* | ?:[\\/]*) 22790 ac_cv_path_DTRACE="$DTRACE" # Let the user override the test with a path. 22791 ;; 22792 *) 22793 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22794 for as_dir in $PATH 22795 do 22796 IFS=$as_save_IFS 22797 test -z "$as_dir" && as_dir=. 22798 for ac_exec_ext in '' $ac_executable_extensions; do 22799 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22800 ac_cv_path_DTRACE="$as_dir/$ac_word$ac_exec_ext" 22801 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22802 break 2 22803 fi 22804 done 22805 done 22806 IFS=$as_save_IFS 22807 22808 ;; 22809 esac 22810 fi 22811 DTRACE=$ac_cv_path_DTRACE 22812 if test -n "$DTRACE"; then 22813 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DTRACE" >&5 22814 $as_echo "$DTRACE" >&6; } 22815 else 22816 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22817 $as_echo "no" >&6; } 22818 fi 22819 22820 22821 test -n "$DTRACE" && break 22822 done 22823 22824 else 22825 # The variable is set, but is it from the command line or the environment? 22826 22827 # Try to remove the string !DTRACE! from our list. 22828 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DTRACE!/} 22829 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 22830 # If it failed, the variable was not from the command line. Ignore it, 22831 # but warn the user (except for BASH, which is always set by the calling BASH). 22832 if test "xDTRACE" != xBASH; then 22833 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DTRACE from the environment. Use command line variables instead." >&5 22834 $as_echo "$as_me: WARNING: Ignoring value of DTRACE from the environment. Use command line variables instead." >&2;} 22835 fi 22836 # Try to locate tool using the code snippet 22837 for ac_prog in dtrace 22838 do 22839 # Extract the first word of "$ac_prog", so it can be a program name with args. 22840 set dummy $ac_prog; ac_word=$2 22841 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22842 $as_echo_n "checking for $ac_word... " >&6; } 22843 if ${ac_cv_path_DTRACE+:} false; then : 22844 $as_echo_n "(cached) " >&6 22845 else 22846 case $DTRACE in 22847 [\\/]* | ?:[\\/]*) 22848 ac_cv_path_DTRACE="$DTRACE" # Let the user override the test with a path. 22849 ;; 22850 *) 22851 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22852 for as_dir in $PATH 22853 do 22854 IFS=$as_save_IFS 22855 test -z "$as_dir" && as_dir=. 22856 for ac_exec_ext in '' $ac_executable_extensions; do 22857 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22858 ac_cv_path_DTRACE="$as_dir/$ac_word$ac_exec_ext" 22859 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22860 break 2 22861 fi 22862 done 22863 done 22864 IFS=$as_save_IFS 22865 22866 ;; 22867 esac 22868 fi 22869 DTRACE=$ac_cv_path_DTRACE 22870 if test -n "$DTRACE"; then 22871 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DTRACE" >&5 22872 $as_echo "$DTRACE" >&6; } 22873 else 22874 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22875 $as_echo "no" >&6; } 22876 fi 22877 22878 22879 test -n "$DTRACE" && break 22880 done 22881 22882 else 22883 # If it succeeded, then it was overridden by the user. We will use it 22884 # for the tool. 22885 22886 # First remove it from the list of overridden variables, so we can test 22887 # for unknown variables in the end. 22888 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 22889 22890 # Check if we try to supply an empty value 22891 if test "x$DTRACE" = x; then 22892 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DTRACE= (no value)" >&5 22893 $as_echo "$as_me: Setting user supplied tool DTRACE= (no value)" >&6;} 22894 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DTRACE" >&5 22895 $as_echo_n "checking for DTRACE... " >&6; } 22896 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 22897 $as_echo "disabled" >&6; } 22898 else 22899 # Check if the provided tool contains a complete path. 22900 tool_specified="$DTRACE" 22901 tool_basename="${tool_specified##*/}" 22902 if test "x$tool_basename" = "x$tool_specified"; then 22903 # A command without a complete path is provided, search $PATH. 22904 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DTRACE=$tool_basename" >&5 22905 $as_echo "$as_me: Will search for user supplied tool DTRACE=$tool_basename" >&6;} 22906 # Extract the first word of "$tool_basename", so it can be a program name with args. 22907 set dummy $tool_basename; ac_word=$2 22908 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22909 $as_echo_n "checking for $ac_word... " >&6; } 22910 if ${ac_cv_path_DTRACE+:} false; then : 22911 $as_echo_n "(cached) " >&6 22912 else 22913 case $DTRACE in 22914 [\\/]* | ?:[\\/]*) 22915 ac_cv_path_DTRACE="$DTRACE" # Let the user override the test with a path. 22916 ;; 22917 *) 22918 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22919 for as_dir in $PATH 22920 do 22921 IFS=$as_save_IFS 22922 test -z "$as_dir" && as_dir=. 22923 for ac_exec_ext in '' $ac_executable_extensions; do 22924 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22925 ac_cv_path_DTRACE="$as_dir/$ac_word$ac_exec_ext" 22926 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22927 break 2 22928 fi 22929 done 22930 done 22931 IFS=$as_save_IFS 22932 22933 ;; 22934 esac 22935 fi 22936 DTRACE=$ac_cv_path_DTRACE 22937 if test -n "$DTRACE"; then 22938 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DTRACE" >&5 22939 $as_echo "$DTRACE" >&6; } 22940 else 22941 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22942 $as_echo "no" >&6; } 22943 fi 22944 22945 22946 if test "x$DTRACE" = x; then 22947 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 22948 fi 22949 else 22950 # Otherwise we believe it is a complete path. Use it as it is. 22951 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DTRACE=$tool_specified" >&5 22952 $as_echo "$as_me: Will use user supplied tool DTRACE=$tool_specified" >&6;} 22953 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DTRACE" >&5 22954 $as_echo_n "checking for DTRACE... " >&6; } 22955 if test ! -x "$tool_specified"; then 22956 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 22957 $as_echo "not found" >&6; } 22958 as_fn_error $? "User supplied tool DTRACE=$tool_specified does not exist or is not executable" "$LINENO" 5 22959 fi 22960 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 22961 $as_echo "$tool_specified" >&6; } 22962 fi 22963 fi 22964 fi 22965 22966 fi 22967 22968 22969 22970 22971 # Publish this variable in the help. 22972 22973 22974 if [ -z "${PATCH+x}" ]; then 22975 # The variable is not set by user, try to locate tool using the code snippet 22976 for ac_prog in gpatch patch 22977 do 22978 # Extract the first word of "$ac_prog", so it can be a program name with args. 22979 set dummy $ac_prog; ac_word=$2 22980 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22981 $as_echo_n "checking for $ac_word... " >&6; } 22982 if ${ac_cv_path_PATCH+:} false; then : 22983 $as_echo_n "(cached) " >&6 22984 else 22985 case $PATCH in 22986 [\\/]* | ?:[\\/]*) 22987 ac_cv_path_PATCH="$PATCH" # Let the user override the test with a path. 22988 ;; 22989 *) 22990 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22991 for as_dir in $PATH 22992 do 22993 IFS=$as_save_IFS 22994 test -z "$as_dir" && as_dir=. 22995 for ac_exec_ext in '' $ac_executable_extensions; do 22996 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22997 ac_cv_path_PATCH="$as_dir/$ac_word$ac_exec_ext" 22998 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22999 break 2 23000 fi 23001 done 23002 done 23003 IFS=$as_save_IFS 23004 23005 ;; 23006 esac 23007 fi 23008 PATCH=$ac_cv_path_PATCH 23009 if test -n "$PATCH"; then 23010 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATCH" >&5 23011 $as_echo "$PATCH" >&6; } 23012 else 23013 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23014 $as_echo "no" >&6; } 23015 fi 23016 23017 23018 test -n "$PATCH" && break 23019 done 23020 23021 else 23022 # The variable is set, but is it from the command line or the environment? 23023 23024 # Try to remove the string !PATCH! from our list. 23025 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!PATCH!/} 23026 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 23027 # If it failed, the variable was not from the command line. Ignore it, 23028 # but warn the user (except for BASH, which is always set by the calling BASH). 23029 if test "xPATCH" != xBASH; then 23030 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of PATCH from the environment. Use command line variables instead." >&5 23031 $as_echo "$as_me: WARNING: Ignoring value of PATCH from the environment. Use command line variables instead." >&2;} 23032 fi 23033 # Try to locate tool using the code snippet 23034 for ac_prog in gpatch patch 23035 do 23036 # Extract the first word of "$ac_prog", so it can be a program name with args. 23037 set dummy $ac_prog; ac_word=$2 23038 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23039 $as_echo_n "checking for $ac_word... " >&6; } 23040 if ${ac_cv_path_PATCH+:} false; then : 23041 $as_echo_n "(cached) " >&6 23042 else 23043 case $PATCH in 23044 [\\/]* | ?:[\\/]*) 23045 ac_cv_path_PATCH="$PATCH" # Let the user override the test with a path. 23046 ;; 23047 *) 23048 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23049 for as_dir in $PATH 23050 do 23051 IFS=$as_save_IFS 23052 test -z "$as_dir" && as_dir=. 23053 for ac_exec_ext in '' $ac_executable_extensions; do 23054 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23055 ac_cv_path_PATCH="$as_dir/$ac_word$ac_exec_ext" 23056 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23057 break 2 23058 fi 23059 done 23060 done 23061 IFS=$as_save_IFS 23062 23063 ;; 23064 esac 23065 fi 23066 PATCH=$ac_cv_path_PATCH 23067 if test -n "$PATCH"; then 23068 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATCH" >&5 23069 $as_echo "$PATCH" >&6; } 23070 else 23071 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23072 $as_echo "no" >&6; } 23073 fi 23074 23075 23076 test -n "$PATCH" && break 23077 done 23078 23079 else 23080 # If it succeeded, then it was overridden by the user. We will use it 23081 # for the tool. 23082 23083 # First remove it from the list of overridden variables, so we can test 23084 # for unknown variables in the end. 23085 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 23086 23087 # Check if we try to supply an empty value 23088 if test "x$PATCH" = x; then 23089 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool PATCH= (no value)" >&5 23090 $as_echo "$as_me: Setting user supplied tool PATCH= (no value)" >&6;} 23091 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PATCH" >&5 23092 $as_echo_n "checking for PATCH... " >&6; } 23093 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 23094 $as_echo "disabled" >&6; } 23095 else 23096 # Check if the provided tool contains a complete path. 23097 tool_specified="$PATCH" 23098 tool_basename="${tool_specified##*/}" 23099 if test "x$tool_basename" = "x$tool_specified"; then 23100 # A command without a complete path is provided, search $PATH. 23101 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool PATCH=$tool_basename" >&5 23102 $as_echo "$as_me: Will search for user supplied tool PATCH=$tool_basename" >&6;} 23103 # Extract the first word of "$tool_basename", so it can be a program name with args. 23104 set dummy $tool_basename; ac_word=$2 23105 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23106 $as_echo_n "checking for $ac_word... " >&6; } 23107 if ${ac_cv_path_PATCH+:} false; then : 23108 $as_echo_n "(cached) " >&6 23109 else 23110 case $PATCH in 23111 [\\/]* | ?:[\\/]*) 23112 ac_cv_path_PATCH="$PATCH" # Let the user override the test with a path. 23113 ;; 23114 *) 23115 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23116 for as_dir in $PATH 23117 do 23118 IFS=$as_save_IFS 23119 test -z "$as_dir" && as_dir=. 23120 for ac_exec_ext in '' $ac_executable_extensions; do 23121 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23122 ac_cv_path_PATCH="$as_dir/$ac_word$ac_exec_ext" 23123 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23124 break 2 23125 fi 23126 done 23127 done 23128 IFS=$as_save_IFS 23129 23130 ;; 23131 esac 23132 fi 23133 PATCH=$ac_cv_path_PATCH 23134 if test -n "$PATCH"; then 23135 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATCH" >&5 23136 $as_echo "$PATCH" >&6; } 23137 else 23138 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23139 $as_echo "no" >&6; } 23140 fi 23141 23142 23143 if test "x$PATCH" = x; then 23144 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 23145 fi 23146 else 23147 # Otherwise we believe it is a complete path. Use it as it is. 23148 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool PATCH=$tool_specified" >&5 23149 $as_echo "$as_me: Will use user supplied tool PATCH=$tool_specified" >&6;} 23150 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PATCH" >&5 23151 $as_echo_n "checking for PATCH... " >&6; } 23152 if test ! -x "$tool_specified"; then 23153 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 23154 $as_echo "not found" >&6; } 23155 as_fn_error $? "User supplied tool PATCH=$tool_specified does not exist or is not executable" "$LINENO" 5 23156 fi 23157 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 23158 $as_echo "$tool_specified" >&6; } 23159 fi 23160 fi 23161 fi 23162 23163 fi 23164 23165 23166 # Check if it's GNU time 23167 IS_GNU_TIME=`$TIME --version 2>&1 | $GREP 'GNU time'` 23168 if test "x$IS_GNU_TIME" != x; then 23169 IS_GNU_TIME=yes 23170 else 23171 IS_GNU_TIME=no 23172 fi 23173 23174 23175 if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then 23176 23177 23178 23179 # Publish this variable in the help. 23180 23181 23182 if [ -z "${DSYMUTIL+x}" ]; then 23183 # The variable is not set by user, try to locate tool using the code snippet 23184 for ac_prog in dsymutil 23185 do 23186 # Extract the first word of "$ac_prog", so it can be a program name with args. 23187 set dummy $ac_prog; ac_word=$2 23188 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23189 $as_echo_n "checking for $ac_word... " >&6; } 23190 if ${ac_cv_path_DSYMUTIL+:} false; then : 23191 $as_echo_n "(cached) " >&6 23192 else 23193 case $DSYMUTIL in 23194 [\\/]* | ?:[\\/]*) 23195 ac_cv_path_DSYMUTIL="$DSYMUTIL" # Let the user override the test with a path. 23196 ;; 23197 *) 23198 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23199 for as_dir in $PATH 23200 do 23201 IFS=$as_save_IFS 23202 test -z "$as_dir" && as_dir=. 23203 for ac_exec_ext in '' $ac_executable_extensions; do 23204 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23205 ac_cv_path_DSYMUTIL="$as_dir/$ac_word$ac_exec_ext" 23206 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23207 break 2 23208 fi 23209 done 23210 done 23211 IFS=$as_save_IFS 23212 23213 ;; 23214 esac 23215 fi 23216 DSYMUTIL=$ac_cv_path_DSYMUTIL 23217 if test -n "$DSYMUTIL"; then 23218 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 23219 $as_echo "$DSYMUTIL" >&6; } 23220 else 23221 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23222 $as_echo "no" >&6; } 23223 fi 23224 23225 23226 test -n "$DSYMUTIL" && break 23227 done 23228 23229 else 23230 # The variable is set, but is it from the command line or the environment? 23231 23232 # Try to remove the string !DSYMUTIL! from our list. 23233 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DSYMUTIL!/} 23234 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 23235 # If it failed, the variable was not from the command line. Ignore it, 23236 # but warn the user (except for BASH, which is always set by the calling BASH). 23237 if test "xDSYMUTIL" != xBASH; then 23238 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DSYMUTIL from the environment. Use command line variables instead." >&5 23239 $as_echo "$as_me: WARNING: Ignoring value of DSYMUTIL from the environment. Use command line variables instead." >&2;} 23240 fi 23241 # Try to locate tool using the code snippet 23242 for ac_prog in dsymutil 23243 do 23244 # Extract the first word of "$ac_prog", so it can be a program name with args. 23245 set dummy $ac_prog; ac_word=$2 23246 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23247 $as_echo_n "checking for $ac_word... " >&6; } 23248 if ${ac_cv_path_DSYMUTIL+:} false; then : 23249 $as_echo_n "(cached) " >&6 23250 else 23251 case $DSYMUTIL in 23252 [\\/]* | ?:[\\/]*) 23253 ac_cv_path_DSYMUTIL="$DSYMUTIL" # Let the user override the test with a path. 23254 ;; 23255 *) 23256 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23257 for as_dir in $PATH 23258 do 23259 IFS=$as_save_IFS 23260 test -z "$as_dir" && as_dir=. 23261 for ac_exec_ext in '' $ac_executable_extensions; do 23262 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23263 ac_cv_path_DSYMUTIL="$as_dir/$ac_word$ac_exec_ext" 23264 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23265 break 2 23266 fi 23267 done 23268 done 23269 IFS=$as_save_IFS 23270 23271 ;; 23272 esac 23273 fi 23274 DSYMUTIL=$ac_cv_path_DSYMUTIL 23275 if test -n "$DSYMUTIL"; then 23276 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 23277 $as_echo "$DSYMUTIL" >&6; } 23278 else 23279 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23280 $as_echo "no" >&6; } 23281 fi 23282 23283 23284 test -n "$DSYMUTIL" && break 23285 done 23286 23287 else 23288 # If it succeeded, then it was overridden by the user. We will use it 23289 # for the tool. 23290 23291 # First remove it from the list of overridden variables, so we can test 23292 # for unknown variables in the end. 23293 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 23294 23295 # Check if we try to supply an empty value 23296 if test "x$DSYMUTIL" = x; then 23297 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DSYMUTIL= (no value)" >&5 23298 $as_echo "$as_me: Setting user supplied tool DSYMUTIL= (no value)" >&6;} 23299 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DSYMUTIL" >&5 23300 $as_echo_n "checking for DSYMUTIL... " >&6; } 23301 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 23302 $as_echo "disabled" >&6; } 23303 else 23304 # Check if the provided tool contains a complete path. 23305 tool_specified="$DSYMUTIL" 23306 tool_basename="${tool_specified##*/}" 23307 if test "x$tool_basename" = "x$tool_specified"; then 23308 # A command without a complete path is provided, search $PATH. 23309 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DSYMUTIL=$tool_basename" >&5 23310 $as_echo "$as_me: Will search for user supplied tool DSYMUTIL=$tool_basename" >&6;} 23311 # Extract the first word of "$tool_basename", so it can be a program name with args. 23312 set dummy $tool_basename; ac_word=$2 23313 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23314 $as_echo_n "checking for $ac_word... " >&6; } 23315 if ${ac_cv_path_DSYMUTIL+:} false; then : 23316 $as_echo_n "(cached) " >&6 23317 else 23318 case $DSYMUTIL in 23319 [\\/]* | ?:[\\/]*) 23320 ac_cv_path_DSYMUTIL="$DSYMUTIL" # Let the user override the test with a path. 23321 ;; 23322 *) 23323 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23324 for as_dir in $PATH 23325 do 23326 IFS=$as_save_IFS 23327 test -z "$as_dir" && as_dir=. 23328 for ac_exec_ext in '' $ac_executable_extensions; do 23329 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23330 ac_cv_path_DSYMUTIL="$as_dir/$ac_word$ac_exec_ext" 23331 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23332 break 2 23333 fi 23334 done 23335 done 23336 IFS=$as_save_IFS 23337 23338 ;; 23339 esac 23340 fi 23341 DSYMUTIL=$ac_cv_path_DSYMUTIL 23342 if test -n "$DSYMUTIL"; then 23343 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 23344 $as_echo "$DSYMUTIL" >&6; } 23345 else 23346 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23347 $as_echo "no" >&6; } 23348 fi 23349 23350 23351 if test "x$DSYMUTIL" = x; then 23352 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 23353 fi 23354 else 23355 # Otherwise we believe it is a complete path. Use it as it is. 23356 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DSYMUTIL=$tool_specified" >&5 23357 $as_echo "$as_me: Will use user supplied tool DSYMUTIL=$tool_specified" >&6;} 23358 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DSYMUTIL" >&5 23359 $as_echo_n "checking for DSYMUTIL... " >&6; } 23360 if test ! -x "$tool_specified"; then 23361 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 23362 $as_echo "not found" >&6; } 23363 as_fn_error $? "User supplied tool DSYMUTIL=$tool_specified does not exist or is not executable" "$LINENO" 5 23364 fi 23365 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 23366 $as_echo "$tool_specified" >&6; } 23367 fi 23368 fi 23369 fi 23370 23371 fi 23372 23373 23374 23375 if test "x$DSYMUTIL" = x; then 23376 as_fn_error $? "Could not find required tool for DSYMUTIL" "$LINENO" 5 23377 fi 23378 23379 23380 23381 23382 23383 # Publish this variable in the help. 23384 23385 23386 if [ -z "${XATTR+x}" ]; then 23387 # The variable is not set by user, try to locate tool using the code snippet 23388 for ac_prog in xattr 23389 do 23390 # Extract the first word of "$ac_prog", so it can be a program name with args. 23391 set dummy $ac_prog; ac_word=$2 23392 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23393 $as_echo_n "checking for $ac_word... " >&6; } 23394 if ${ac_cv_path_XATTR+:} false; then : 23395 $as_echo_n "(cached) " >&6 23396 else 23397 case $XATTR in 23398 [\\/]* | ?:[\\/]*) 23399 ac_cv_path_XATTR="$XATTR" # Let the user override the test with a path. 23400 ;; 23401 *) 23402 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23403 for as_dir in $PATH 23404 do 23405 IFS=$as_save_IFS 23406 test -z "$as_dir" && as_dir=. 23407 for ac_exec_ext in '' $ac_executable_extensions; do 23408 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23409 ac_cv_path_XATTR="$as_dir/$ac_word$ac_exec_ext" 23410 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23411 break 2 23412 fi 23413 done 23414 done 23415 IFS=$as_save_IFS 23416 23417 ;; 23418 esac 23419 fi 23420 XATTR=$ac_cv_path_XATTR 23421 if test -n "$XATTR"; then 23422 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XATTR" >&5 23423 $as_echo "$XATTR" >&6; } 23424 else 23425 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23426 $as_echo "no" >&6; } 23427 fi 23428 23429 23430 test -n "$XATTR" && break 23431 done 23432 23433 else 23434 # The variable is set, but is it from the command line or the environment? 23435 23436 # Try to remove the string !XATTR! from our list. 23437 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!XATTR!/} 23438 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 23439 # If it failed, the variable was not from the command line. Ignore it, 23440 # but warn the user (except for BASH, which is always set by the calling BASH). 23441 if test "xXATTR" != xBASH; then 23442 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of XATTR from the environment. Use command line variables instead." >&5 23443 $as_echo "$as_me: WARNING: Ignoring value of XATTR from the environment. Use command line variables instead." >&2;} 23444 fi 23445 # Try to locate tool using the code snippet 23446 for ac_prog in xattr 23447 do 23448 # Extract the first word of "$ac_prog", so it can be a program name with args. 23449 set dummy $ac_prog; ac_word=$2 23450 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23451 $as_echo_n "checking for $ac_word... " >&6; } 23452 if ${ac_cv_path_XATTR+:} false; then : 23453 $as_echo_n "(cached) " >&6 23454 else 23455 case $XATTR in 23456 [\\/]* | ?:[\\/]*) 23457 ac_cv_path_XATTR="$XATTR" # Let the user override the test with a path. 23458 ;; 23459 *) 23460 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23461 for as_dir in $PATH 23462 do 23463 IFS=$as_save_IFS 23464 test -z "$as_dir" && as_dir=. 23465 for ac_exec_ext in '' $ac_executable_extensions; do 23466 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23467 ac_cv_path_XATTR="$as_dir/$ac_word$ac_exec_ext" 23468 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23469 break 2 23470 fi 23471 done 23472 done 23473 IFS=$as_save_IFS 23474 23475 ;; 23476 esac 23477 fi 23478 XATTR=$ac_cv_path_XATTR 23479 if test -n "$XATTR"; then 23480 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XATTR" >&5 23481 $as_echo "$XATTR" >&6; } 23482 else 23483 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23484 $as_echo "no" >&6; } 23485 fi 23486 23487 23488 test -n "$XATTR" && break 23489 done 23490 23491 else 23492 # If it succeeded, then it was overridden by the user. We will use it 23493 # for the tool. 23494 23495 # First remove it from the list of overridden variables, so we can test 23496 # for unknown variables in the end. 23497 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 23498 23499 # Check if we try to supply an empty value 23500 if test "x$XATTR" = x; then 23501 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool XATTR= (no value)" >&5 23502 $as_echo "$as_me: Setting user supplied tool XATTR= (no value)" >&6;} 23503 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XATTR" >&5 23504 $as_echo_n "checking for XATTR... " >&6; } 23505 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 23506 $as_echo "disabled" >&6; } 23507 else 23508 # Check if the provided tool contains a complete path. 23509 tool_specified="$XATTR" 23510 tool_basename="${tool_specified##*/}" 23511 if test "x$tool_basename" = "x$tool_specified"; then 23512 # A command without a complete path is provided, search $PATH. 23513 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool XATTR=$tool_basename" >&5 23514 $as_echo "$as_me: Will search for user supplied tool XATTR=$tool_basename" >&6;} 23515 # Extract the first word of "$tool_basename", so it can be a program name with args. 23516 set dummy $tool_basename; ac_word=$2 23517 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23518 $as_echo_n "checking for $ac_word... " >&6; } 23519 if ${ac_cv_path_XATTR+:} false; then : 23520 $as_echo_n "(cached) " >&6 23521 else 23522 case $XATTR in 23523 [\\/]* | ?:[\\/]*) 23524 ac_cv_path_XATTR="$XATTR" # Let the user override the test with a path. 23525 ;; 23526 *) 23527 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23528 for as_dir in $PATH 23529 do 23530 IFS=$as_save_IFS 23531 test -z "$as_dir" && as_dir=. 23532 for ac_exec_ext in '' $ac_executable_extensions; do 23533 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23534 ac_cv_path_XATTR="$as_dir/$ac_word$ac_exec_ext" 23535 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23536 break 2 23537 fi 23538 done 23539 done 23540 IFS=$as_save_IFS 23541 23542 ;; 23543 esac 23544 fi 23545 XATTR=$ac_cv_path_XATTR 23546 if test -n "$XATTR"; then 23547 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XATTR" >&5 23548 $as_echo "$XATTR" >&6; } 23549 else 23550 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23551 $as_echo "no" >&6; } 23552 fi 23553 23554 23555 if test "x$XATTR" = x; then 23556 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 23557 fi 23558 else 23559 # Otherwise we believe it is a complete path. Use it as it is. 23560 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool XATTR=$tool_specified" >&5 23561 $as_echo "$as_me: Will use user supplied tool XATTR=$tool_specified" >&6;} 23562 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XATTR" >&5 23563 $as_echo_n "checking for XATTR... " >&6; } 23564 if test ! -x "$tool_specified"; then 23565 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 23566 $as_echo "not found" >&6; } 23567 as_fn_error $? "User supplied tool XATTR=$tool_specified does not exist or is not executable" "$LINENO" 5 23568 fi 23569 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 23570 $as_echo "$tool_specified" >&6; } 23571 fi 23572 fi 23573 fi 23574 23575 fi 23576 23577 23578 23579 if test "x$XATTR" = x; then 23580 as_fn_error $? "Could not find required tool for XATTR" "$LINENO" 5 23581 fi 23582 23583 23584 23585 23586 # Publish this variable in the help. 23587 23588 23589 if [ -z "${CODESIGN+x}" ]; then 23590 # The variable is not set by user, try to locate tool using the code snippet 23591 for ac_prog in codesign 23592 do 23593 # Extract the first word of "$ac_prog", so it can be a program name with args. 23594 set dummy $ac_prog; ac_word=$2 23595 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23596 $as_echo_n "checking for $ac_word... " >&6; } 23597 if ${ac_cv_path_CODESIGN+:} false; then : 23598 $as_echo_n "(cached) " >&6 23599 else 23600 case $CODESIGN in 23601 [\\/]* | ?:[\\/]*) 23602 ac_cv_path_CODESIGN="$CODESIGN" # Let the user override the test with a path. 23603 ;; 23604 *) 23605 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23606 for as_dir in $PATH 23607 do 23608 IFS=$as_save_IFS 23609 test -z "$as_dir" && as_dir=. 23610 for ac_exec_ext in '' $ac_executable_extensions; do 23611 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23612 ac_cv_path_CODESIGN="$as_dir/$ac_word$ac_exec_ext" 23613 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23614 break 2 23615 fi 23616 done 23617 done 23618 IFS=$as_save_IFS 23619 23620 ;; 23621 esac 23622 fi 23623 CODESIGN=$ac_cv_path_CODESIGN 23624 if test -n "$CODESIGN"; then 23625 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CODESIGN" >&5 23626 $as_echo "$CODESIGN" >&6; } 23627 else 23628 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23629 $as_echo "no" >&6; } 23630 fi 23631 23632 23633 test -n "$CODESIGN" && break 23634 done 23635 23636 else 23637 # The variable is set, but is it from the command line or the environment? 23638 23639 # Try to remove the string !CODESIGN! from our list. 23640 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CODESIGN!/} 23641 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 23642 # If it failed, the variable was not from the command line. Ignore it, 23643 # but warn the user (except for BASH, which is always set by the calling BASH). 23644 if test "xCODESIGN" != xBASH; then 23645 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CODESIGN from the environment. Use command line variables instead." >&5 23646 $as_echo "$as_me: WARNING: Ignoring value of CODESIGN from the environment. Use command line variables instead." >&2;} 23647 fi 23648 # Try to locate tool using the code snippet 23649 for ac_prog in codesign 23650 do 23651 # Extract the first word of "$ac_prog", so it can be a program name with args. 23652 set dummy $ac_prog; ac_word=$2 23653 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23654 $as_echo_n "checking for $ac_word... " >&6; } 23655 if ${ac_cv_path_CODESIGN+:} false; then : 23656 $as_echo_n "(cached) " >&6 23657 else 23658 case $CODESIGN in 23659 [\\/]* | ?:[\\/]*) 23660 ac_cv_path_CODESIGN="$CODESIGN" # Let the user override the test with a path. 23661 ;; 23662 *) 23663 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23664 for as_dir in $PATH 23665 do 23666 IFS=$as_save_IFS 23667 test -z "$as_dir" && as_dir=. 23668 for ac_exec_ext in '' $ac_executable_extensions; do 23669 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23670 ac_cv_path_CODESIGN="$as_dir/$ac_word$ac_exec_ext" 23671 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23672 break 2 23673 fi 23674 done 23675 done 23676 IFS=$as_save_IFS 23677 23678 ;; 23679 esac 23680 fi 23681 CODESIGN=$ac_cv_path_CODESIGN 23682 if test -n "$CODESIGN"; then 23683 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CODESIGN" >&5 23684 $as_echo "$CODESIGN" >&6; } 23685 else 23686 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23687 $as_echo "no" >&6; } 23688 fi 23689 23690 23691 test -n "$CODESIGN" && break 23692 done 23693 23694 else 23695 # If it succeeded, then it was overridden by the user. We will use it 23696 # for the tool. 23697 23698 # First remove it from the list of overridden variables, so we can test 23699 # for unknown variables in the end. 23700 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 23701 23702 # Check if we try to supply an empty value 23703 if test "x$CODESIGN" = x; then 23704 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CODESIGN= (no value)" >&5 23705 $as_echo "$as_me: Setting user supplied tool CODESIGN= (no value)" >&6;} 23706 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CODESIGN" >&5 23707 $as_echo_n "checking for CODESIGN... " >&6; } 23708 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 23709 $as_echo "disabled" >&6; } 23710 else 23711 # Check if the provided tool contains a complete path. 23712 tool_specified="$CODESIGN" 23713 tool_basename="${tool_specified##*/}" 23714 if test "x$tool_basename" = "x$tool_specified"; then 23715 # A command without a complete path is provided, search $PATH. 23716 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CODESIGN=$tool_basename" >&5 23717 $as_echo "$as_me: Will search for user supplied tool CODESIGN=$tool_basename" >&6;} 23718 # Extract the first word of "$tool_basename", so it can be a program name with args. 23719 set dummy $tool_basename; ac_word=$2 23720 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23721 $as_echo_n "checking for $ac_word... " >&6; } 23722 if ${ac_cv_path_CODESIGN+:} false; then : 23723 $as_echo_n "(cached) " >&6 23724 else 23725 case $CODESIGN in 23726 [\\/]* | ?:[\\/]*) 23727 ac_cv_path_CODESIGN="$CODESIGN" # Let the user override the test with a path. 23728 ;; 23729 *) 23730 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23731 for as_dir in $PATH 23732 do 23733 IFS=$as_save_IFS 23734 test -z "$as_dir" && as_dir=. 23735 for ac_exec_ext in '' $ac_executable_extensions; do 23736 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23737 ac_cv_path_CODESIGN="$as_dir/$ac_word$ac_exec_ext" 23738 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23739 break 2 23740 fi 23741 done 23742 done 23743 IFS=$as_save_IFS 23744 23745 ;; 23746 esac 23747 fi 23748 CODESIGN=$ac_cv_path_CODESIGN 23749 if test -n "$CODESIGN"; then 23750 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CODESIGN" >&5 23751 $as_echo "$CODESIGN" >&6; } 23752 else 23753 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23754 $as_echo "no" >&6; } 23755 fi 23756 23757 23758 if test "x$CODESIGN" = x; then 23759 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 23760 fi 23761 else 23762 # Otherwise we believe it is a complete path. Use it as it is. 23763 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CODESIGN=$tool_specified" >&5 23764 $as_echo "$as_me: Will use user supplied tool CODESIGN=$tool_specified" >&6;} 23765 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CODESIGN" >&5 23766 $as_echo_n "checking for CODESIGN... " >&6; } 23767 if test ! -x "$tool_specified"; then 23768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 23769 $as_echo "not found" >&6; } 23770 as_fn_error $? "User supplied tool CODESIGN=$tool_specified does not exist or is not executable" "$LINENO" 5 23771 fi 23772 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 23773 $as_echo "$tool_specified" >&6; } 23774 fi 23775 fi 23776 fi 23777 23778 fi 23779 23780 23781 if test "x$CODESIGN" != "x"; then 23782 # Verify that the openjdk_codesign certificate is present 23783 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if openjdk_codesign certificate is present" >&5 23784 $as_echo_n "checking if openjdk_codesign certificate is present... " >&6; } 23785 $RM codesign-testfile 23786 $TOUCH codesign-testfile 23787 $CODESIGN -s openjdk_codesign codesign-testfile 2>&5 >&5 || CODESIGN= 23788 $RM codesign-testfile 23789 if test "x$CODESIGN" = x; then 23790 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23791 $as_echo "no" >&6; } 23792 else 23793 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 23794 $as_echo "yes" >&6; } 23795 fi 23796 fi 23797 23798 23799 23800 # Publish this variable in the help. 23801 23802 23803 if [ -z "${SETFILE+x}" ]; then 23804 # The variable is not set by user, try to locate tool using the code snippet 23805 for ac_prog in SetFile 23806 do 23807 # Extract the first word of "$ac_prog", so it can be a program name with args. 23808 set dummy $ac_prog; ac_word=$2 23809 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23810 $as_echo_n "checking for $ac_word... " >&6; } 23811 if ${ac_cv_path_SETFILE+:} false; then : 23812 $as_echo_n "(cached) " >&6 23813 else 23814 case $SETFILE in 23815 [\\/]* | ?:[\\/]*) 23816 ac_cv_path_SETFILE="$SETFILE" # Let the user override the test with a path. 23817 ;; 23818 *) 23819 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23820 for as_dir in $PATH 23821 do 23822 IFS=$as_save_IFS 23823 test -z "$as_dir" && as_dir=. 23824 for ac_exec_ext in '' $ac_executable_extensions; do 23825 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23826 ac_cv_path_SETFILE="$as_dir/$ac_word$ac_exec_ext" 23827 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23828 break 2 23829 fi 23830 done 23831 done 23832 IFS=$as_save_IFS 23833 23834 ;; 23835 esac 23836 fi 23837 SETFILE=$ac_cv_path_SETFILE 23838 if test -n "$SETFILE"; then 23839 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SETFILE" >&5 23840 $as_echo "$SETFILE" >&6; } 23841 else 23842 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23843 $as_echo "no" >&6; } 23844 fi 23845 23846 23847 test -n "$SETFILE" && break 23848 done 23849 23850 else 23851 # The variable is set, but is it from the command line or the environment? 23852 23853 # Try to remove the string !SETFILE! from our list. 23854 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SETFILE!/} 23855 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 23856 # If it failed, the variable was not from the command line. Ignore it, 23857 # but warn the user (except for BASH, which is always set by the calling BASH). 23858 if test "xSETFILE" != xBASH; then 23859 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SETFILE from the environment. Use command line variables instead." >&5 23860 $as_echo "$as_me: WARNING: Ignoring value of SETFILE from the environment. Use command line variables instead." >&2;} 23861 fi 23862 # Try to locate tool using the code snippet 23863 for ac_prog in SetFile 23864 do 23865 # Extract the first word of "$ac_prog", so it can be a program name with args. 23866 set dummy $ac_prog; ac_word=$2 23867 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23868 $as_echo_n "checking for $ac_word... " >&6; } 23869 if ${ac_cv_path_SETFILE+:} false; then : 23870 $as_echo_n "(cached) " >&6 23871 else 23872 case $SETFILE in 23873 [\\/]* | ?:[\\/]*) 23874 ac_cv_path_SETFILE="$SETFILE" # Let the user override the test with a path. 23875 ;; 23876 *) 23877 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23878 for as_dir in $PATH 23879 do 23880 IFS=$as_save_IFS 23881 test -z "$as_dir" && as_dir=. 23882 for ac_exec_ext in '' $ac_executable_extensions; do 23883 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23884 ac_cv_path_SETFILE="$as_dir/$ac_word$ac_exec_ext" 23885 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23886 break 2 23887 fi 23888 done 23889 done 23890 IFS=$as_save_IFS 23891 23892 ;; 23893 esac 23894 fi 23895 SETFILE=$ac_cv_path_SETFILE 23896 if test -n "$SETFILE"; then 23897 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SETFILE" >&5 23898 $as_echo "$SETFILE" >&6; } 23899 else 23900 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23901 $as_echo "no" >&6; } 23902 fi 23903 23904 23905 test -n "$SETFILE" && break 23906 done 23907 23908 else 23909 # If it succeeded, then it was overridden by the user. We will use it 23910 # for the tool. 23911 23912 # First remove it from the list of overridden variables, so we can test 23913 # for unknown variables in the end. 23914 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 23915 23916 # Check if we try to supply an empty value 23917 if test "x$SETFILE" = x; then 23918 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool SETFILE= (no value)" >&5 23919 $as_echo "$as_me: Setting user supplied tool SETFILE= (no value)" >&6;} 23920 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SETFILE" >&5 23921 $as_echo_n "checking for SETFILE... " >&6; } 23922 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 23923 $as_echo "disabled" >&6; } 23924 else 23925 # Check if the provided tool contains a complete path. 23926 tool_specified="$SETFILE" 23927 tool_basename="${tool_specified##*/}" 23928 if test "x$tool_basename" = "x$tool_specified"; then 23929 # A command without a complete path is provided, search $PATH. 23930 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SETFILE=$tool_basename" >&5 23931 $as_echo "$as_me: Will search for user supplied tool SETFILE=$tool_basename" >&6;} 23932 # Extract the first word of "$tool_basename", so it can be a program name with args. 23933 set dummy $tool_basename; ac_word=$2 23934 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23935 $as_echo_n "checking for $ac_word... " >&6; } 23936 if ${ac_cv_path_SETFILE+:} false; then : 23937 $as_echo_n "(cached) " >&6 23938 else 23939 case $SETFILE in 23940 [\\/]* | ?:[\\/]*) 23941 ac_cv_path_SETFILE="$SETFILE" # Let the user override the test with a path. 23942 ;; 23943 *) 23944 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23945 for as_dir in $PATH 23946 do 23947 IFS=$as_save_IFS 23948 test -z "$as_dir" && as_dir=. 23949 for ac_exec_ext in '' $ac_executable_extensions; do 23950 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23951 ac_cv_path_SETFILE="$as_dir/$ac_word$ac_exec_ext" 23952 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23953 break 2 23954 fi 23955 done 23956 done 23957 IFS=$as_save_IFS 23958 23959 ;; 23960 esac 23961 fi 23962 SETFILE=$ac_cv_path_SETFILE 23963 if test -n "$SETFILE"; then 23964 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SETFILE" >&5 23965 $as_echo "$SETFILE" >&6; } 23966 else 23967 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23968 $as_echo "no" >&6; } 23969 fi 23970 23971 23972 if test "x$SETFILE" = x; then 23973 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 23974 fi 23975 else 23976 # Otherwise we believe it is a complete path. Use it as it is. 23977 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SETFILE=$tool_specified" >&5 23978 $as_echo "$as_me: Will use user supplied tool SETFILE=$tool_specified" >&6;} 23979 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SETFILE" >&5 23980 $as_echo_n "checking for SETFILE... " >&6; } 23981 if test ! -x "$tool_specified"; then 23982 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 23983 $as_echo "not found" >&6; } 23984 as_fn_error $? "User supplied tool SETFILE=$tool_specified does not exist or is not executable" "$LINENO" 5 23985 fi 23986 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 23987 $as_echo "$tool_specified" >&6; } 23988 fi 23989 fi 23990 fi 23991 23992 fi 23993 23994 23995 23996 if test "x$SETFILE" = x; then 23997 as_fn_error $? "Could not find required tool for SETFILE" "$LINENO" 5 23998 fi 23999 24000 24001 fi 24002 24003 24004 # Test if bash supports pipefail. 24005 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if bash supports pipefail" >&5 24006 $as_echo_n "checking if bash supports pipefail... " >&6; } 24007 if ${BASH} -c 'set -o pipefail'; then 24008 BASH_ARGS="$BASH_ARGS -o pipefail" 24009 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24010 $as_echo "yes" >&6; } 24011 else 24012 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24013 $as_echo "no" >&6; } 24014 fi 24015 24016 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if bash supports errexit (-e)" >&5 24017 $as_echo_n "checking if bash supports errexit (-e)... " >&6; } 24018 if ${BASH} -e -c 'true'; then 24019 BASH_ARGS="$BASH_ARGS -e" 24020 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24021 $as_echo "yes" >&6; } 24022 else 24023 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24024 $as_echo "no" >&6; } 24025 fi 24026 24027 24028 24029 24030 # Check if pkg-config is available. 24031 24032 24033 if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then 24034 if test -n "$ac_tool_prefix"; then 24035 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. 24036 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 24037 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24038 $as_echo_n "checking for $ac_word... " >&6; } 24039 if ${ac_cv_path_PKG_CONFIG+:} false; then : 24040 $as_echo_n "(cached) " >&6 24041 else 24042 case $PKG_CONFIG in 24043 [\\/]* | ?:[\\/]*) 24044 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. 24045 ;; 24046 *) 24047 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24048 for as_dir in $PATH 24049 do 24050 IFS=$as_save_IFS 24051 test -z "$as_dir" && as_dir=. 24052 for ac_exec_ext in '' $ac_executable_extensions; do 24053 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24054 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" 24055 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24056 break 2 24057 fi 24058 done 24059 done 24060 IFS=$as_save_IFS 24061 24062 ;; 24063 esac 24064 fi 24065 PKG_CONFIG=$ac_cv_path_PKG_CONFIG 24066 if test -n "$PKG_CONFIG"; then 24067 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 24068 $as_echo "$PKG_CONFIG" >&6; } 24069 else 24070 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24071 $as_echo "no" >&6; } 24072 fi 24073 24074 24075 fi 24076 if test -z "$ac_cv_path_PKG_CONFIG"; then 24077 ac_pt_PKG_CONFIG=$PKG_CONFIG 24078 # Extract the first word of "pkg-config", so it can be a program name with args. 24079 set dummy pkg-config; ac_word=$2 24080 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 24081 $as_echo_n "checking for $ac_word... " >&6; } 24082 if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then : 24083 $as_echo_n "(cached) " >&6 24084 else 24085 case $ac_pt_PKG_CONFIG in 24086 [\\/]* | ?:[\\/]*) 24087 ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path. 24088 ;; 24089 *) 24090 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 24091 for as_dir in $PATH 24092 do 24093 IFS=$as_save_IFS 24094 test -z "$as_dir" && as_dir=. 24095 for ac_exec_ext in '' $ac_executable_extensions; do 24096 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 24097 ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" 24098 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 24099 break 2 24100 fi 24101 done 24102 done 24103 IFS=$as_save_IFS 24104 24105 ;; 24106 esac 24107 fi 24108 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG 24109 if test -n "$ac_pt_PKG_CONFIG"; then 24110 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5 24111 $as_echo "$ac_pt_PKG_CONFIG" >&6; } 24112 else 24113 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24114 $as_echo "no" >&6; } 24115 fi 24116 24117 if test "x$ac_pt_PKG_CONFIG" = x; then 24118 PKG_CONFIG="" 24119 else 24120 case $cross_compiling:$ac_tool_warned in 24121 yes:) 24122 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 24123 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 24124 ac_tool_warned=yes ;; 24125 esac 24126 PKG_CONFIG=$ac_pt_PKG_CONFIG 24127 fi 24128 else 24129 PKG_CONFIG="$ac_cv_path_PKG_CONFIG" 24130 fi 24131 24132 fi 24133 if test -n "$PKG_CONFIG"; then 24134 _pkg_min_version=0.9.0 24135 { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5 24136 $as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; } 24137 if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then 24138 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24139 $as_echo "yes" >&6; } 24140 else 24141 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24142 $as_echo "no" >&6; } 24143 PKG_CONFIG="" 24144 fi 24145 24146 fi 24147 24148 # After basic tools have been setup, we can check build os specific details. 24149 24150 ############################################################################### 24151 24152 # Note that this is the build platform OS version! 24153 24154 OS_VERSION="`uname -r | ${SED} 's!\.! !g' | ${SED} 's!-! !g'`" 24155 OS_VERSION_MAJOR="`${ECHO} ${OS_VERSION} | ${CUT} -f 1 -d ' '`" 24156 OS_VERSION_MINOR="`${ECHO} ${OS_VERSION} | ${CUT} -f 2 -d ' '`" 24157 OS_VERSION_MICRO="`${ECHO} ${OS_VERSION} | ${CUT} -f 3 -d ' '`" 24158 24159 24160 24161 24162 24163 # Misc basic settings 24164 24165 24166 # Check whether --with-default-make-target was given. 24167 if test "${with_default_make_target+set}" = set; then : 24168 withval=$with_default_make_target; 24169 fi 24170 24171 if test "x$with_default_make_target" = "x" \ 24172 || test "x$with_default_make_target" = "xyes"; then 24173 DEFAULT_MAKE_TARGET="exploded-image" 24174 elif test "x$with_default_make_target" = "xno"; then 24175 as_fn_error $? "--without-default-make-target is not a valid option" "$LINENO" 5 24176 else 24177 DEFAULT_MAKE_TARGET="$with_default_make_target" 24178 fi 24179 24180 24181 24182 24183 ############################################################################### 24184 # 24185 # Determine OpenJDK variants, options and version numbers. 24186 # 24187 ############################################################################### 24188 24189 # We need build & target for this. 24190 24191 # Should we build a JDK without a graphical UI? 24192 { $as_echo "$as_me:${as_lineno-$LINENO}: checking headless only" >&5 24193 $as_echo_n "checking headless only... " >&6; } 24194 # Check whether --enable-headless-only was given. 24195 if test "${enable_headless_only+set}" = set; then : 24196 enableval=$enable_headless_only; 24197 fi 24198 24199 24200 if test "x$enable_headless_only" = "xyes"; then 24201 ENABLE_HEADLESS_ONLY="true" 24202 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24203 $as_echo "yes" >&6; } 24204 elif test "x$enable_headless_only" = "xno"; then 24205 ENABLE_HEADLESS_ONLY="false" 24206 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24207 $as_echo "no" >&6; } 24208 elif test "x$enable_headless_only" = "x"; then 24209 ENABLE_HEADLESS_ONLY="false" 24210 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24211 $as_echo "no" >&6; } 24212 else 24213 as_fn_error $? "--enable-headless-only can only take yes or no" "$LINENO" 5 24214 fi 24215 24216 24217 24218 # Choose cacerts source file 24219 24220 # Check whether --with-cacerts-file was given. 24221 if test "${with_cacerts_file+set}" = set; then : 24222 withval=$with_cacerts_file; 24223 fi 24224 24225 if test "x$with_cacerts_file" != x; then 24226 CACERTS_FILE=$with_cacerts_file 24227 fi 24228 24229 24230 # Enable or disable unlimited crypto 24231 # Check whether --enable-unlimited-crypto was given. 24232 if test "${enable_unlimited_crypto+set}" = set; then : 24233 enableval=$enable_unlimited_crypto; 24234 else 24235 enable_unlimited_crypto=no 24236 fi 24237 24238 if test "x$enable_unlimited_crypto" = "xyes"; then 24239 UNLIMITED_CRYPTO=true 24240 else 24241 UNLIMITED_CRYPTO=false 24242 fi 24243 24244 24245 # Should we build the serviceability agent (SA)? 24246 INCLUDE_SA=true 24247 if [[ " $JVM_VARIANTS " =~ " zero " ]] || [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 24248 INCLUDE_SA=false 24249 fi 24250 if test "x$OPENJDK_TARGET_OS" = xaix ; then 24251 INCLUDE_SA=false 24252 fi 24253 24254 24255 # Compress jars 24256 COMPRESS_JARS=false 24257 24258 24259 24260 # Setup default copyright year. Mostly overridden when building close to a new year. 24261 24262 # Check whether --with-copyright-year was given. 24263 if test "${with_copyright_year+set}" = set; then : 24264 withval=$with_copyright_year; 24265 fi 24266 24267 if test "x$with_copyright_year" = xyes; then 24268 as_fn_error $? "Copyright year must have a value" "$LINENO" 5 24269 elif test "x$with_copyright_year" != x; then 24270 COPYRIGHT_YEAR="$with_copyright_year" 24271 else 24272 COPYRIGHT_YEAR=`$DATE +'%Y'` 24273 fi 24274 24275 24276 24277 # Check whether --enable-keep-packaged-modules was given. 24278 if test "${enable_keep_packaged_modules+set}" = set; then : 24279 enableval=$enable_keep_packaged_modules; 24280 fi 24281 24282 24283 if test "x$enable_keep_packaged_modules" = "xyes"; then 24284 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if packaged modules are kept" >&5 24285 $as_echo_n "checking if packaged modules are kept... " >&6; } 24286 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 24287 $as_echo "yes" >&6; } 24288 JLINK_KEEP_PACKAGED_MODULES=true 24289 elif test "x$enable_keep_packaged_modules" = "xno"; then 24290 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if packaged modules are kept" >&5 24291 $as_echo_n "checking if packaged modules are kept... " >&6; } 24292 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 24293 $as_echo "no" >&6; } 24294 JLINK_KEEP_PACKAGED_MODULES=false 24295 elif test "x$enable_keep_packaged_modules" = "x"; then 24296 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (default)" >&5 24297 $as_echo "yes (default)" >&6; } 24298 JLINK_KEEP_PACKAGED_MODULES=true 24299 else 24300 as_fn_error $? "--enable-keep-packaged-modules accepts no argument" "$LINENO" 5 24301 fi 24302 24303 24304 24305 24306 # Warn user that old version arguments are deprecated. 24307 24308 24309 # Check whether --with-milestone was given. 24310 if test "${with_milestone+set}" = set; then : 24311 withval=$with_milestone; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-milestone is deprecated and will be ignored." >&5 24312 $as_echo "$as_me: WARNING: Option --with-milestone is deprecated and will be ignored." >&2;} 24313 fi 24314 24315 24316 24317 24318 # Check whether --with-update-version was given. 24319 if test "${with_update_version+set}" = set; then : 24320 withval=$with_update_version; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-update-version is deprecated and will be ignored." >&5 24321 $as_echo "$as_me: WARNING: Option --with-update-version is deprecated and will be ignored." >&2;} 24322 fi 24323 24324 24325 24326 24327 # Check whether --with-user-release-suffix was given. 24328 if test "${with_user_release_suffix+set}" = set; then : 24329 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 24330 $as_echo "$as_me: WARNING: Option --with-user-release-suffix is deprecated and will be ignored." >&2;} 24331 fi 24332 24333 24334 24335 24336 # Check whether --with-build-number was given. 24337 if test "${with_build_number+set}" = set; then : 24338 withval=$with_build_number; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-build-number is deprecated and will be ignored." >&5 24339 $as_echo "$as_me: WARNING: Option --with-build-number is deprecated and will be ignored." >&2;} 24340 fi 24341 24342 24343 24344 # Source the version numbers file 24345 . $AUTOCONF_DIR/version-numbers 24346 24347 # Some non-version number information is set in that file 24348 24349 24350 24351 24352 24353 24354 24355 24356 24357 # Override version from arguments 24358 24359 # If --with-version-string is set, process it first. It is possible to 24360 # override parts with more specific flags, since these are processed later. 24361 24362 # Check whether --with-version-string was given. 24363 if test "${with_version_string+set}" = set; then : 24364 withval=$with_version_string; 24365 fi 24366 24367 if test "x$with_version_string" = xyes; then 24368 as_fn_error $? "--with-version-string must have a value" "$LINENO" 5 24369 elif test "x$with_version_string" != x; then 24370 # Additional [] needed to keep m4 from mangling shell constructs. 24371 if [[ $with_version_string =~ ^([0-9]+)(\.([0-9]+))?(\.([0-9]+))?(\.([0-9]+))?(-([a-zA-Z]+))?((\+)([0-9]+)?(-([-a-zA-Z0-9.]+))?)?$ ]] ; then 24372 VERSION_MAJOR=${BASH_REMATCH[1]} 24373 VERSION_MINOR=${BASH_REMATCH[3]} 24374 VERSION_SECURITY=${BASH_REMATCH[5]} 24375 VERSION_PATCH=${BASH_REMATCH[7]} 24376 VERSION_PRE=${BASH_REMATCH[9]} 24377 version_plus_separator=${BASH_REMATCH[11]} 24378 VERSION_BUILD=${BASH_REMATCH[12]} 24379 VERSION_OPT=${BASH_REMATCH[14]} 24380 # Unspecified numerical fields are interpreted as 0. 24381 if test "x$VERSION_MINOR" = x; then 24382 VERSION_MINOR=0 24383 fi 24384 if test "x$VERSION_SECURITY" = x; then 24385 VERSION_SECURITY=0 24386 fi 24387 if test "x$VERSION_PATCH" = x; then 24388 VERSION_PATCH=0 24389 fi 24390 if test "x$version_plus_separator" != x \ 24391 && test "x$VERSION_BUILD$VERSION_OPT" = x; then 24392 as_fn_error $? "Version string contains + but both 'BUILD' and 'OPT' are missing" "$LINENO" 5 24393 fi 24394 # Stop the version part process from setting default values. 24395 # We still allow them to explicitely override though. 24396 NO_DEFAULT_VERSION_PARTS=true 24397 else 24398 as_fn_error $? "--with-version-string fails to parse as a valid version string: $with_version_string" "$LINENO" 5 24399 fi 24400 fi 24401 24402 24403 # Check whether --with-version-pre was given. 24404 if test "${with_version_pre+set}" = set; then : 24405 withval=$with_version_pre; with_version_pre_present=true 24406 else 24407 with_version_pre_present=false 24408 fi 24409 24410 24411 if test "x$with_version_pre_present" = xtrue; then 24412 if test "x$with_version_pre" = xyes; then 24413 as_fn_error $? "--with-version-pre must have a value" "$LINENO" 5 24414 elif test "x$with_version_pre" = xno; then 24415 # Interpret --without-* as empty string instead of the literal "no" 24416 VERSION_PRE= 24417 else 24418 # Only [a-zA-Z] is allowed in the VERSION_PRE. Outer [ ] to quote m4. 24419 VERSION_PRE=`$ECHO "$with_version_pre" | $TR -c -d '[a-z][A-Z]'` 24420 if test "x$VERSION_PRE" != "x$with_version_pre"; then 24421 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-version-pre value has been sanitized from '$with_version_pre' to '$VERSION_PRE'" >&5 24422 $as_echo "$as_me: WARNING: --with-version-pre value has been sanitized from '$with_version_pre' to '$VERSION_PRE'" >&2;} 24423 fi 24424 fi 24425 else 24426 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 24427 # Default is to use "internal" as pre 24428 VERSION_PRE="internal" 24429 fi 24430 fi 24431 24432 24433 # Check whether --with-version-opt was given. 24434 if test "${with_version_opt+set}" = set; then : 24435 withval=$with_version_opt; with_version_opt_present=true 24436 else 24437 with_version_opt_present=false 24438 fi 24439 24440 24441 if test "x$with_version_opt_present" = xtrue; then 24442 if test "x$with_version_opt" = xyes; then 24443 as_fn_error $? "--with-version-opt must have a value" "$LINENO" 5 24444 elif test "x$with_version_opt" = xno; then 24445 # Interpret --without-* as empty string instead of the literal "no" 24446 VERSION_OPT= 24447 else 24448 # Only [-.a-zA-Z0-9] is allowed in the VERSION_OPT. Outer [ ] to quote m4. 24449 VERSION_OPT=`$ECHO "$with_version_opt" | $TR -c -d '[a-z][A-Z][0-9].-'` 24450 if test "x$VERSION_OPT" != "x$with_version_opt"; then 24451 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-version-opt value has been sanitized from '$with_version_opt' to '$VERSION_OPT'" >&5 24452 $as_echo "$as_me: WARNING: --with-version-opt value has been sanitized from '$with_version_opt' to '$VERSION_OPT'" >&2;} 24453 fi 24454 fi 24455 else 24456 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 24457 # Default is to calculate a string like this <timestamp>.<username>.<base dir name> 24458 timestamp=`$DATE '+%Y-%m-%d-%H%M%S'` 24459 # Outer [ ] to quote m4. 24460 basedirname=`$BASENAME "$TOPDIR" | $TR -d -c '[a-z][A-Z][0-9].-'` 24461 VERSION_OPT="$timestamp.$USERNAME.$basedirname" 24462 fi 24463 fi 24464 24465 24466 # Check whether --with-version-build was given. 24467 if test "${with_version_build+set}" = set; then : 24468 withval=$with_version_build; with_version_build_present=true 24469 else 24470 with_version_build_present=false 24471 fi 24472 24473 24474 if test "x$with_version_build_present" = xtrue; then 24475 if test "x$with_version_build" = xyes; then 24476 as_fn_error $? "--with-version-build must have a value" "$LINENO" 5 24477 elif test "x$with_version_build" = xno; then 24478 # Interpret --without-* as empty string instead of the literal "no" 24479 VERSION_BUILD= 24480 elif test "x$with_version_build" = x; then 24481 VERSION_BUILD= 24482 else 24483 24484 # Additional [] needed to keep m4 from mangling shell constructs. 24485 if ! [[ "$with_version_build" =~ ^0*([1-9][0-9]*)|(0)$ ]] ; then 24486 as_fn_error $? "\"$with_version_build\" is not a valid numerical value for VERSION_BUILD" "$LINENO" 5 24487 fi 24488 # Extract the version number without leading zeros. 24489 cleaned_value=${BASH_REMATCH[1]} 24490 if test "x$cleaned_value" = x; then 24491 # Special case for zero 24492 cleaned_value=${BASH_REMATCH[2]} 24493 fi 24494 24495 if test $cleaned_value -gt 255; then 24496 as_fn_error $? "VERSION_BUILD is given as $with_version_build. This is greater than 255 which is not allowed." "$LINENO" 5 24497 fi 24498 if test "x$cleaned_value" != "x$with_version_build"; then 24499 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Value for VERSION_BUILD has been sanitized from '$with_version_build' to '$cleaned_value'" >&5 24500 $as_echo "$as_me: WARNING: Value for VERSION_BUILD has been sanitized from '$with_version_build' to '$cleaned_value'" >&2;} 24501 fi 24502 VERSION_BUILD=$cleaned_value 24503 24504 fi 24505 else 24506 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 24507 # Default is to not have a build number. 24508 VERSION_BUILD="" 24509 # FIXME: Until all code can cope with an empty VERSION_BUILD, set it to 0. 24510 VERSION_BUILD=0 24511 fi 24512 fi 24513 24514 24515 # Check whether --with-version-major was given. 24516 if test "${with_version_major+set}" = set; then : 24517 withval=$with_version_major; with_version_major_present=true 24518 else 24519 with_version_major_present=false 24520 fi 24521 24522 24523 if test "x$with_version_major_present" = xtrue; then 24524 if test "x$with_version_major" = xyes; then 24525 as_fn_error $? "--with-version-major must have a value" "$LINENO" 5 24526 else 24527 24528 # Additional [] needed to keep m4 from mangling shell constructs. 24529 if ! [[ "$with_version_major" =~ ^0*([1-9][0-9]*)|(0)$ ]] ; then 24530 as_fn_error $? "\"$with_version_major\" is not a valid numerical value for VERSION_MAJOR" "$LINENO" 5 24531 fi 24532 # Extract the version number without leading zeros. 24533 cleaned_value=${BASH_REMATCH[1]} 24534 if test "x$cleaned_value" = x; then 24535 # Special case for zero 24536 cleaned_value=${BASH_REMATCH[2]} 24537 fi 24538 24539 if test $cleaned_value -gt 255; then 24540 as_fn_error $? "VERSION_MAJOR is given as $with_version_major. This is greater than 255 which is not allowed." "$LINENO" 5 24541 fi 24542 if test "x$cleaned_value" != "x$with_version_major"; then 24543 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Value for VERSION_MAJOR has been sanitized from '$with_version_major' to '$cleaned_value'" >&5 24544 $as_echo "$as_me: WARNING: Value for VERSION_MAJOR has been sanitized from '$with_version_major' to '$cleaned_value'" >&2;} 24545 fi 24546 VERSION_MAJOR=$cleaned_value 24547 24548 fi 24549 else 24550 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 24551 # Default is to get value from version-numbers 24552 VERSION_MAJOR="$DEFAULT_VERSION_MAJOR" 24553 fi 24554 fi 24555 24556 24557 # Check whether --with-version-minor was given. 24558 if test "${with_version_minor+set}" = set; then : 24559 withval=$with_version_minor; with_version_minor_present=true 24560 else 24561 with_version_minor_present=false 24562 fi 24563 24564 24565 if test "x$with_version_minor_present" = xtrue; then 24566 if test "x$with_version_minor" = xyes; then 24567 as_fn_error $? "--with-version-minor must have a value" "$LINENO" 5 24568 elif test "x$with_version_minor" = xno; then 24569 # Interpret --without-* as empty string (i.e. 0) instead of the literal "no" 24570 VERSION_MINOR=0 24571 elif test "x$with_version_minor" = x; then 24572 VERSION_MINOR=0 24573 else 24574 24575 # Additional [] needed to keep m4 from mangling shell constructs. 24576 if ! [[ "$with_version_minor" =~ ^0*([1-9][0-9]*)|(0)$ ]] ; then 24577 as_fn_error $? "\"$with_version_minor\" is not a valid numerical value for VERSION_MINOR" "$LINENO" 5 24578 fi 24579 # Extract the version number without leading zeros. 24580 cleaned_value=${BASH_REMATCH[1]} 24581 if test "x$cleaned_value" = x; then 24582 # Special case for zero 24583 cleaned_value=${BASH_REMATCH[2]} 24584 fi 24585 24586 if test $cleaned_value -gt 255; then 24587 as_fn_error $? "VERSION_MINOR is given as $with_version_minor. This is greater than 255 which is not allowed." "$LINENO" 5 24588 fi 24589 if test "x$cleaned_value" != "x$with_version_minor"; then 24590 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Value for VERSION_MINOR has been sanitized from '$with_version_minor' to '$cleaned_value'" >&5 24591 $as_echo "$as_me: WARNING: Value for VERSION_MINOR has been sanitized from '$with_version_minor' to '$cleaned_value'" >&2;} 24592 fi 24593 VERSION_MINOR=$cleaned_value 24594 24595 fi 24596 else 24597 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 24598 # Default is 0, if unspecified 24599 VERSION_MINOR=0 24600 fi 24601 fi 24602 24603 24604 # Check whether --with-version-security was given. 24605 if test "${with_version_security+set}" = set; then : 24606 withval=$with_version_security; with_version_security_present=true 24607 else 24608 with_version_security_present=false 24609 fi 24610 24611 24612 if test "x$with_version_security_present" = xtrue; then 24613 if test "x$with_version_security" = xyes; then 24614 as_fn_error $? "--with-version-security must have a value" "$LINENO" 5 24615 elif test "x$with_version_security" = xno; then 24616 # Interpret --without-* as empty string (i.e. 0) instead of the literal "no" 24617 VERSION_SECURITY=0 24618 elif test "x$with_version_security" = x; then 24619 VERSION_SECURITY=0 24620 else 24621 24622 # Additional [] needed to keep m4 from mangling shell constructs. 24623 if ! [[ "$with_version_security" =~ ^0*([1-9][0-9]*)|(0)$ ]] ; then 24624 as_fn_error $? "\"$with_version_security\" is not a valid numerical value for VERSION_SECURITY" "$LINENO" 5 24625 fi 24626 # Extract the version number without leading zeros. 24627 cleaned_value=${BASH_REMATCH[1]} 24628 if test "x$cleaned_value" = x; then 24629 # Special case for zero 24630 cleaned_value=${BASH_REMATCH[2]} 24631 fi 24632 24633 if test $cleaned_value -gt 255; then 24634 as_fn_error $? "VERSION_SECURITY is given as $with_version_security. This is greater than 255 which is not allowed." "$LINENO" 5 24635 fi 24636 if test "x$cleaned_value" != "x$with_version_security"; then 24637 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Value for VERSION_SECURITY has been sanitized from '$with_version_security' to '$cleaned_value'" >&5 24638 $as_echo "$as_me: WARNING: Value for VERSION_SECURITY has been sanitized from '$with_version_security' to '$cleaned_value'" >&2;} 24639 fi 24640 VERSION_SECURITY=$cleaned_value 24641 24642 fi 24643 else 24644 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 24645 # Default is 0, if unspecified 24646 VERSION_SECURITY=0 24647 fi 24648 fi 24649 24650 24651 # Check whether --with-version-patch was given. 24652 if test "${with_version_patch+set}" = set; then : 24653 withval=$with_version_patch; with_version_patch_present=true 24654 else 24655 with_version_patch_present=false 24656 fi 24657 24658 24659 if test "x$with_version_patch_present" = xtrue; then 24660 if test "x$with_version_patch" = xyes; then 24661 as_fn_error $? "--with-version-patch must have a value" "$LINENO" 5 24662 elif test "x$with_version_patch" = xno; then 24663 # Interpret --without-* as empty string (i.e. 0) instead of the literal "no" 24664 VERSION_PATCH=0 24665 elif test "x$with_version_patch" = x; then 24666 VERSION_PATCH=0 24667 else 24668 24669 # Additional [] needed to keep m4 from mangling shell constructs. 24670 if ! [[ "$with_version_patch" =~ ^0*([1-9][0-9]*)|(0)$ ]] ; then 24671 as_fn_error $? "\"$with_version_patch\" is not a valid numerical value for VERSION_PATCH" "$LINENO" 5 24672 fi 24673 # Extract the version number without leading zeros. 24674 cleaned_value=${BASH_REMATCH[1]} 24675 if test "x$cleaned_value" = x; then 24676 # Special case for zero 24677 cleaned_value=${BASH_REMATCH[2]} 24678 fi 24679 24680 if test $cleaned_value -gt 255; then 24681 as_fn_error $? "VERSION_PATCH is given as $with_version_patch. This is greater than 255 which is not allowed." "$LINENO" 5 24682 fi 24683 if test "x$cleaned_value" != "x$with_version_patch"; then 24684 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Value for VERSION_PATCH has been sanitized from '$with_version_patch' to '$cleaned_value'" >&5 24685 $as_echo "$as_me: WARNING: Value for VERSION_PATCH has been sanitized from '$with_version_patch' to '$cleaned_value'" >&2;} 24686 fi 24687 VERSION_PATCH=$cleaned_value 24688 24689 fi 24690 else 24691 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 24692 # Default is 0, if unspecified 24693 VERSION_PATCH=0 24694 fi 24695 fi 24696 24697 # Calculate derived version properties 24698 24699 # Set VERSION_IS_GA based on if VERSION_PRE has a value 24700 if test "x$VERSION_PRE" = x; then 24701 VERSION_IS_GA=true 24702 else 24703 VERSION_IS_GA=false 24704 fi 24705 24706 # VERSION_NUMBER but always with exactly 4 positions, with 0 for empty positions. 24707 VERSION_NUMBER_FOUR_POSITIONS=$VERSION_MAJOR.$VERSION_MINOR.$VERSION_SECURITY.$VERSION_PATCH 24708 24709 stripped_version_number=$VERSION_NUMBER_FOUR_POSITIONS 24710 # Strip trailing zeroes from stripped_version_number 24711 for i in 1 2 3 ; do stripped_version_number=${stripped_version_number%.0} ; done 24712 VERSION_NUMBER=$stripped_version_number 24713 24714 # The complete version string, with additional build information 24715 if test "x$VERSION_BUILD$VERSION_OPT" = x; then 24716 VERSION_STRING=$VERSION_NUMBER${VERSION_PRE:+-$VERSION_PRE} 24717 else 24718 # If either build or opt is set, we need a + separator 24719 VERSION_STRING=$VERSION_NUMBER${VERSION_PRE:+-$VERSION_PRE}+$VERSION_BUILD${VERSION_OPT:+-$VERSION_OPT} 24720 fi 24721 24722 # The short version string, just VERSION_NUMBER and PRE, if present. 24723 VERSION_SHORT=$VERSION_NUMBER${VERSION_PRE:+-$VERSION_PRE} 24724 24725 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for version string" >&5 24726 $as_echo_n "checking for version string... " >&6; } 24727 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $VERSION_STRING" >&5 24728 $as_echo "$VERSION_STRING" >&6; } 24729 24730 24731 24732 24733 24734 24735 24736 24737 24738 24739 24740 24741 24742 24743 24744 ############################################################################### 24745 # 24746 # Setup BootJDK, used to bootstrap the build. 24747 # 24748 ############################################################################### 24749 24750 24751 BOOT_JDK_FOUND=no 24752 24753 # Check whether --with-boot-jdk was given. 24754 if test "${with_boot_jdk+set}" = set; then : 24755 withval=$with_boot_jdk; 24756 fi 24757 24758 24759 # We look for the Boot JDK through various means, going from more certain to 24760 # more of a guess-work. After each test, BOOT_JDK_FOUND is set to "yes" if 24761 # we detected something (if so, the path to the jdk is in BOOT_JDK). But we 24762 # must check if this is indeed valid; otherwise we'll continue looking. 24763 24764 # Test: Is bootjdk explicitely set by command line arguments? 24765 24766 if test "x$BOOT_JDK_FOUND" = xno; then 24767 # Now execute the test 24768 24769 if test "x$with_boot_jdk" != x; then 24770 BOOT_JDK=$with_boot_jdk 24771 BOOT_JDK_FOUND=maybe 24772 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using configure arguments" >&5 24773 $as_echo "$as_me: Found potential Boot JDK using configure arguments" >&6;} 24774 fi 24775 24776 24777 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 24778 if test "x$BOOT_JDK_FOUND" = xmaybe; then 24779 # Do we have a bin/java? 24780 if test ! -x "$BOOT_JDK/bin/java"; then 24781 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 24782 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 24783 BOOT_JDK_FOUND=no 24784 else 24785 # Do we have a bin/javac? 24786 if test ! -x "$BOOT_JDK/bin/javac"; then 24787 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 24788 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 24789 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 24790 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 24791 BOOT_JDK_FOUND=no 24792 else 24793 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 24794 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 24795 24796 # Extra M4 quote needed to protect [] in grep expression. 24797 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 24798 if test "x$FOUND_CORRECT_VERSION" = x; then 24799 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 24800 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 24801 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 24802 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 24803 BOOT_JDK_FOUND=no 24804 else 24805 # We're done! :-) 24806 BOOT_JDK_FOUND=yes 24807 24808 # Only process if variable expands to non-empty 24809 24810 if test "x$BOOT_JDK" != x; then 24811 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24812 24813 # Input might be given as Windows format, start by converting to 24814 # unix format. 24815 path="$BOOT_JDK" 24816 new_path=`$CYGPATH -u "$path"` 24817 24818 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 24819 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 24820 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 24821 # "foo.exe" is OK but "foo" is an error. 24822 # 24823 # This test is therefore slightly more accurate than "test -f" to check for file precense. 24824 # It is also a way to make sure we got the proper file name for the real test later on. 24825 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 24826 if test "x$test_shortpath" = x; then 24827 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 24828 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 24829 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 24830 fi 24831 24832 # Call helper function which possibly converts this using DOS-style short mode. 24833 # If so, the updated path is stored in $new_path. 24834 24835 input_path="$new_path" 24836 # Check if we need to convert this using DOS-style short mode. If the path 24837 # contains just simple characters, use it. Otherwise (spaces, weird characters), 24838 # take no chances and rewrite it. 24839 # Note: m4 eats our [], so we need to use [ and ] instead. 24840 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 24841 if test "x$has_forbidden_chars" != x; then 24842 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 24843 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 24844 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 24845 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 24846 # Going to short mode and back again did indeed matter. Since short mode is 24847 # case insensitive, let's make it lowercase to improve readability. 24848 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 24849 # Now convert it back to Unix-style (cygpath) 24850 input_path=`$CYGPATH -u "$shortmode_path"` 24851 new_path="$input_path" 24852 fi 24853 fi 24854 24855 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 24856 if test "x$test_cygdrive_prefix" = x; then 24857 # As a simple fix, exclude /usr/bin since it's not a real path. 24858 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 24859 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 24860 # a path prefixed by /cygdrive for fixpath to work. 24861 new_path="$CYGWIN_ROOT_PATH$input_path" 24862 fi 24863 fi 24864 24865 24866 if test "x$path" != "x$new_path"; then 24867 BOOT_JDK="$new_path" 24868 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 24869 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 24870 fi 24871 24872 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24873 24874 path="$BOOT_JDK" 24875 has_colon=`$ECHO $path | $GREP ^.:` 24876 new_path="$path" 24877 if test "x$has_colon" = x; then 24878 # Not in mixed or Windows style, start by that. 24879 new_path=`cmd //c echo $path` 24880 fi 24881 24882 24883 input_path="$new_path" 24884 # Check if we need to convert this using DOS-style short mode. If the path 24885 # contains just simple characters, use it. Otherwise (spaces, weird characters), 24886 # take no chances and rewrite it. 24887 # Note: m4 eats our [], so we need to use [ and ] instead. 24888 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 24889 if test "x$has_forbidden_chars" != x; then 24890 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 24891 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 24892 fi 24893 24894 24895 windows_path="$new_path" 24896 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24897 unix_path=`$CYGPATH -u "$windows_path"` 24898 new_path="$unix_path" 24899 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24900 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 24901 new_path="$unix_path" 24902 fi 24903 24904 if test "x$path" != "x$new_path"; then 24905 BOOT_JDK="$new_path" 24906 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 24907 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 24908 fi 24909 24910 # Save the first 10 bytes of this path to the storage, so fixpath can work. 24911 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 24912 24913 else 24914 # We're on a unix platform. Hooray! :) 24915 path="$BOOT_JDK" 24916 has_space=`$ECHO "$path" | $GREP " "` 24917 if test "x$has_space" != x; then 24918 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 24919 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 24920 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 24921 fi 24922 24923 # Use eval to expand a potential ~ 24924 eval path="$path" 24925 if test ! -f "$path" && test ! -d "$path"; then 24926 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 24927 fi 24928 24929 if test -d "$path"; then 24930 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 24931 else 24932 dir="`$DIRNAME "$path"`" 24933 base="`$BASENAME "$path"`" 24934 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 24935 fi 24936 fi 24937 fi 24938 24939 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 24940 $as_echo_n "checking for Boot JDK... " >&6; } 24941 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 24942 $as_echo "$BOOT_JDK" >&6; } 24943 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 24944 $as_echo_n "checking Boot JDK version... " >&6; } 24945 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 24946 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 24947 $as_echo "$BOOT_JDK_VERSION" >&6; } 24948 fi # end check jdk version 24949 fi # end check javac 24950 fi # end check java 24951 fi # end check boot jdk found 24952 fi 24953 24954 if test "x$with_boot_jdk" != x && test "x$BOOT_JDK_FOUND" = xno; then 24955 # Having specified an argument which is incorrect will produce an instant failure; 24956 # we should not go on looking 24957 as_fn_error $? "The path given by --with-boot-jdk does not contain a valid Boot JDK" "$LINENO" 5 24958 fi 24959 24960 # Test: On MacOS X, can we find a boot jdk using /usr/libexec/java_home? 24961 24962 if test "x$BOOT_JDK_FOUND" = xno; then 24963 # Now execute the test 24964 24965 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 24966 # First check at user selected default 24967 24968 if test "x$BOOT_JDK_FOUND" = xno; then 24969 # Now execute the test 24970 24971 if test -x /usr/libexec/java_home; then 24972 BOOT_JDK=`/usr/libexec/java_home ` 24973 BOOT_JDK_FOUND=maybe 24974 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home " >&5 24975 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home " >&6;} 24976 fi 24977 24978 24979 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 24980 if test "x$BOOT_JDK_FOUND" = xmaybe; then 24981 # Do we have a bin/java? 24982 if test ! -x "$BOOT_JDK/bin/java"; then 24983 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 24984 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 24985 BOOT_JDK_FOUND=no 24986 else 24987 # Do we have a bin/javac? 24988 if test ! -x "$BOOT_JDK/bin/javac"; then 24989 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 24990 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 24991 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 24992 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 24993 BOOT_JDK_FOUND=no 24994 else 24995 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 24996 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 24997 24998 # Extra M4 quote needed to protect [] in grep expression. 24999 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 25000 if test "x$FOUND_CORRECT_VERSION" = x; then 25001 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 25002 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 25003 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 25004 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 25005 BOOT_JDK_FOUND=no 25006 else 25007 # We're done! :-) 25008 BOOT_JDK_FOUND=yes 25009 25010 # Only process if variable expands to non-empty 25011 25012 if test "x$BOOT_JDK" != x; then 25013 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25014 25015 # Input might be given as Windows format, start by converting to 25016 # unix format. 25017 path="$BOOT_JDK" 25018 new_path=`$CYGPATH -u "$path"` 25019 25020 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 25021 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 25022 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 25023 # "foo.exe" is OK but "foo" is an error. 25024 # 25025 # This test is therefore slightly more accurate than "test -f" to check for file precense. 25026 # It is also a way to make sure we got the proper file name for the real test later on. 25027 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 25028 if test "x$test_shortpath" = x; then 25029 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25030 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25031 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 25032 fi 25033 25034 # Call helper function which possibly converts this using DOS-style short mode. 25035 # If so, the updated path is stored in $new_path. 25036 25037 input_path="$new_path" 25038 # Check if we need to convert this using DOS-style short mode. If the path 25039 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25040 # take no chances and rewrite it. 25041 # Note: m4 eats our [], so we need to use [ and ] instead. 25042 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 25043 if test "x$has_forbidden_chars" != x; then 25044 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25045 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 25046 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 25047 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 25048 # Going to short mode and back again did indeed matter. Since short mode is 25049 # case insensitive, let's make it lowercase to improve readability. 25050 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25051 # Now convert it back to Unix-style (cygpath) 25052 input_path=`$CYGPATH -u "$shortmode_path"` 25053 new_path="$input_path" 25054 fi 25055 fi 25056 25057 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 25058 if test "x$test_cygdrive_prefix" = x; then 25059 # As a simple fix, exclude /usr/bin since it's not a real path. 25060 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 25061 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 25062 # a path prefixed by /cygdrive for fixpath to work. 25063 new_path="$CYGWIN_ROOT_PATH$input_path" 25064 fi 25065 fi 25066 25067 25068 if test "x$path" != "x$new_path"; then 25069 BOOT_JDK="$new_path" 25070 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25071 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25072 fi 25073 25074 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25075 25076 path="$BOOT_JDK" 25077 has_colon=`$ECHO $path | $GREP ^.:` 25078 new_path="$path" 25079 if test "x$has_colon" = x; then 25080 # Not in mixed or Windows style, start by that. 25081 new_path=`cmd //c echo $path` 25082 fi 25083 25084 25085 input_path="$new_path" 25086 # Check if we need to convert this using DOS-style short mode. If the path 25087 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25088 # take no chances and rewrite it. 25089 # Note: m4 eats our [], so we need to use [ and ] instead. 25090 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 25091 if test "x$has_forbidden_chars" != x; then 25092 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25093 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25094 fi 25095 25096 25097 windows_path="$new_path" 25098 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25099 unix_path=`$CYGPATH -u "$windows_path"` 25100 new_path="$unix_path" 25101 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25102 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25103 new_path="$unix_path" 25104 fi 25105 25106 if test "x$path" != "x$new_path"; then 25107 BOOT_JDK="$new_path" 25108 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25109 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25110 fi 25111 25112 # Save the first 10 bytes of this path to the storage, so fixpath can work. 25113 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 25114 25115 else 25116 # We're on a unix platform. Hooray! :) 25117 path="$BOOT_JDK" 25118 has_space=`$ECHO "$path" | $GREP " "` 25119 if test "x$has_space" != x; then 25120 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25121 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25122 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 25123 fi 25124 25125 # Use eval to expand a potential ~ 25126 eval path="$path" 25127 if test ! -f "$path" && test ! -d "$path"; then 25128 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 25129 fi 25130 25131 if test -d "$path"; then 25132 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 25133 else 25134 dir="`$DIRNAME "$path"`" 25135 base="`$BASENAME "$path"`" 25136 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 25137 fi 25138 fi 25139 fi 25140 25141 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 25142 $as_echo_n "checking for Boot JDK... " >&6; } 25143 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 25144 $as_echo "$BOOT_JDK" >&6; } 25145 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 25146 $as_echo_n "checking Boot JDK version... " >&6; } 25147 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 25148 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 25149 $as_echo "$BOOT_JDK_VERSION" >&6; } 25150 fi # end check jdk version 25151 fi # end check javac 25152 fi # end check java 25153 fi # end check boot jdk found 25154 fi 25155 25156 # If that did not work out (e.g. too old), try explicit versions instead 25157 25158 if test "x$BOOT_JDK_FOUND" = xno; then 25159 # Now execute the test 25160 25161 if test -x /usr/libexec/java_home; then 25162 BOOT_JDK=`/usr/libexec/java_home -v 1.9` 25163 BOOT_JDK_FOUND=maybe 25164 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home -v 1.9" >&5 25165 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home -v 1.9" >&6;} 25166 fi 25167 25168 25169 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 25170 if test "x$BOOT_JDK_FOUND" = xmaybe; then 25171 # Do we have a bin/java? 25172 if test ! -x "$BOOT_JDK/bin/java"; then 25173 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 25174 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 25175 BOOT_JDK_FOUND=no 25176 else 25177 # Do we have a bin/javac? 25178 if test ! -x "$BOOT_JDK/bin/javac"; then 25179 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 25180 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 25181 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 25182 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 25183 BOOT_JDK_FOUND=no 25184 else 25185 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 25186 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 25187 25188 # Extra M4 quote needed to protect [] in grep expression. 25189 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 25190 if test "x$FOUND_CORRECT_VERSION" = x; then 25191 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 25192 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 25193 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 25194 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 25195 BOOT_JDK_FOUND=no 25196 else 25197 # We're done! :-) 25198 BOOT_JDK_FOUND=yes 25199 25200 # Only process if variable expands to non-empty 25201 25202 if test "x$BOOT_JDK" != x; then 25203 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25204 25205 # Input might be given as Windows format, start by converting to 25206 # unix format. 25207 path="$BOOT_JDK" 25208 new_path=`$CYGPATH -u "$path"` 25209 25210 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 25211 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 25212 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 25213 # "foo.exe" is OK but "foo" is an error. 25214 # 25215 # This test is therefore slightly more accurate than "test -f" to check for file precense. 25216 # It is also a way to make sure we got the proper file name for the real test later on. 25217 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 25218 if test "x$test_shortpath" = x; then 25219 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25220 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25221 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 25222 fi 25223 25224 # Call helper function which possibly converts this using DOS-style short mode. 25225 # If so, the updated path is stored in $new_path. 25226 25227 input_path="$new_path" 25228 # Check if we need to convert this using DOS-style short mode. If the path 25229 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25230 # take no chances and rewrite it. 25231 # Note: m4 eats our [], so we need to use [ and ] instead. 25232 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 25233 if test "x$has_forbidden_chars" != x; then 25234 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25235 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 25236 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 25237 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 25238 # Going to short mode and back again did indeed matter. Since short mode is 25239 # case insensitive, let's make it lowercase to improve readability. 25240 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25241 # Now convert it back to Unix-style (cygpath) 25242 input_path=`$CYGPATH -u "$shortmode_path"` 25243 new_path="$input_path" 25244 fi 25245 fi 25246 25247 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 25248 if test "x$test_cygdrive_prefix" = x; then 25249 # As a simple fix, exclude /usr/bin since it's not a real path. 25250 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 25251 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 25252 # a path prefixed by /cygdrive for fixpath to work. 25253 new_path="$CYGWIN_ROOT_PATH$input_path" 25254 fi 25255 fi 25256 25257 25258 if test "x$path" != "x$new_path"; then 25259 BOOT_JDK="$new_path" 25260 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25261 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25262 fi 25263 25264 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25265 25266 path="$BOOT_JDK" 25267 has_colon=`$ECHO $path | $GREP ^.:` 25268 new_path="$path" 25269 if test "x$has_colon" = x; then 25270 # Not in mixed or Windows style, start by that. 25271 new_path=`cmd //c echo $path` 25272 fi 25273 25274 25275 input_path="$new_path" 25276 # Check if we need to convert this using DOS-style short mode. If the path 25277 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25278 # take no chances and rewrite it. 25279 # Note: m4 eats our [], so we need to use [ and ] instead. 25280 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 25281 if test "x$has_forbidden_chars" != x; then 25282 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25283 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25284 fi 25285 25286 25287 windows_path="$new_path" 25288 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25289 unix_path=`$CYGPATH -u "$windows_path"` 25290 new_path="$unix_path" 25291 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25292 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25293 new_path="$unix_path" 25294 fi 25295 25296 if test "x$path" != "x$new_path"; then 25297 BOOT_JDK="$new_path" 25298 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25299 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25300 fi 25301 25302 # Save the first 10 bytes of this path to the storage, so fixpath can work. 25303 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 25304 25305 else 25306 # We're on a unix platform. Hooray! :) 25307 path="$BOOT_JDK" 25308 has_space=`$ECHO "$path" | $GREP " "` 25309 if test "x$has_space" != x; then 25310 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25311 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25312 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 25313 fi 25314 25315 # Use eval to expand a potential ~ 25316 eval path="$path" 25317 if test ! -f "$path" && test ! -d "$path"; then 25318 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 25319 fi 25320 25321 if test -d "$path"; then 25322 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 25323 else 25324 dir="`$DIRNAME "$path"`" 25325 base="`$BASENAME "$path"`" 25326 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 25327 fi 25328 fi 25329 fi 25330 25331 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 25332 $as_echo_n "checking for Boot JDK... " >&6; } 25333 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 25334 $as_echo "$BOOT_JDK" >&6; } 25335 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 25336 $as_echo_n "checking Boot JDK version... " >&6; } 25337 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 25338 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 25339 $as_echo "$BOOT_JDK_VERSION" >&6; } 25340 fi # end check jdk version 25341 fi # end check javac 25342 fi # end check java 25343 fi # end check boot jdk found 25344 fi 25345 25346 25347 if test "x$BOOT_JDK_FOUND" = xno; then 25348 # Now execute the test 25349 25350 if test -x /usr/libexec/java_home; then 25351 BOOT_JDK=`/usr/libexec/java_home -v 1.8` 25352 BOOT_JDK_FOUND=maybe 25353 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home -v 1.8" >&5 25354 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home -v 1.8" >&6;} 25355 fi 25356 25357 25358 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 25359 if test "x$BOOT_JDK_FOUND" = xmaybe; then 25360 # Do we have a bin/java? 25361 if test ! -x "$BOOT_JDK/bin/java"; then 25362 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 25363 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 25364 BOOT_JDK_FOUND=no 25365 else 25366 # Do we have a bin/javac? 25367 if test ! -x "$BOOT_JDK/bin/javac"; then 25368 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 25369 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 25370 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 25371 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 25372 BOOT_JDK_FOUND=no 25373 else 25374 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 25375 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 25376 25377 # Extra M4 quote needed to protect [] in grep expression. 25378 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 25379 if test "x$FOUND_CORRECT_VERSION" = x; then 25380 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 25381 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 25382 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 25383 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 25384 BOOT_JDK_FOUND=no 25385 else 25386 # We're done! :-) 25387 BOOT_JDK_FOUND=yes 25388 25389 # Only process if variable expands to non-empty 25390 25391 if test "x$BOOT_JDK" != x; then 25392 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25393 25394 # Input might be given as Windows format, start by converting to 25395 # unix format. 25396 path="$BOOT_JDK" 25397 new_path=`$CYGPATH -u "$path"` 25398 25399 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 25400 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 25401 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 25402 # "foo.exe" is OK but "foo" is an error. 25403 # 25404 # This test is therefore slightly more accurate than "test -f" to check for file precense. 25405 # It is also a way to make sure we got the proper file name for the real test later on. 25406 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 25407 if test "x$test_shortpath" = x; then 25408 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25409 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25410 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 25411 fi 25412 25413 # Call helper function which possibly converts this using DOS-style short mode. 25414 # If so, the updated path is stored in $new_path. 25415 25416 input_path="$new_path" 25417 # Check if we need to convert this using DOS-style short mode. If the path 25418 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25419 # take no chances and rewrite it. 25420 # Note: m4 eats our [], so we need to use [ and ] instead. 25421 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 25422 if test "x$has_forbidden_chars" != x; then 25423 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25424 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 25425 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 25426 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 25427 # Going to short mode and back again did indeed matter. Since short mode is 25428 # case insensitive, let's make it lowercase to improve readability. 25429 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25430 # Now convert it back to Unix-style (cygpath) 25431 input_path=`$CYGPATH -u "$shortmode_path"` 25432 new_path="$input_path" 25433 fi 25434 fi 25435 25436 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 25437 if test "x$test_cygdrive_prefix" = x; then 25438 # As a simple fix, exclude /usr/bin since it's not a real path. 25439 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 25440 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 25441 # a path prefixed by /cygdrive for fixpath to work. 25442 new_path="$CYGWIN_ROOT_PATH$input_path" 25443 fi 25444 fi 25445 25446 25447 if test "x$path" != "x$new_path"; then 25448 BOOT_JDK="$new_path" 25449 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25450 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25451 fi 25452 25453 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25454 25455 path="$BOOT_JDK" 25456 has_colon=`$ECHO $path | $GREP ^.:` 25457 new_path="$path" 25458 if test "x$has_colon" = x; then 25459 # Not in mixed or Windows style, start by that. 25460 new_path=`cmd //c echo $path` 25461 fi 25462 25463 25464 input_path="$new_path" 25465 # Check if we need to convert this using DOS-style short mode. If the path 25466 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25467 # take no chances and rewrite it. 25468 # Note: m4 eats our [], so we need to use [ and ] instead. 25469 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 25470 if test "x$has_forbidden_chars" != x; then 25471 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25472 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25473 fi 25474 25475 25476 windows_path="$new_path" 25477 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25478 unix_path=`$CYGPATH -u "$windows_path"` 25479 new_path="$unix_path" 25480 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25481 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25482 new_path="$unix_path" 25483 fi 25484 25485 if test "x$path" != "x$new_path"; then 25486 BOOT_JDK="$new_path" 25487 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25488 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25489 fi 25490 25491 # Save the first 10 bytes of this path to the storage, so fixpath can work. 25492 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 25493 25494 else 25495 # We're on a unix platform. Hooray! :) 25496 path="$BOOT_JDK" 25497 has_space=`$ECHO "$path" | $GREP " "` 25498 if test "x$has_space" != x; then 25499 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25500 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25501 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 25502 fi 25503 25504 # Use eval to expand a potential ~ 25505 eval path="$path" 25506 if test ! -f "$path" && test ! -d "$path"; then 25507 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 25508 fi 25509 25510 if test -d "$path"; then 25511 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 25512 else 25513 dir="`$DIRNAME "$path"`" 25514 base="`$BASENAME "$path"`" 25515 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 25516 fi 25517 fi 25518 fi 25519 25520 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 25521 $as_echo_n "checking for Boot JDK... " >&6; } 25522 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 25523 $as_echo "$BOOT_JDK" >&6; } 25524 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 25525 $as_echo_n "checking Boot JDK version... " >&6; } 25526 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 25527 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 25528 $as_echo "$BOOT_JDK_VERSION" >&6; } 25529 fi # end check jdk version 25530 fi # end check javac 25531 fi # end check java 25532 fi # end check boot jdk found 25533 fi 25534 25535 25536 if test "x$BOOT_JDK_FOUND" = xno; then 25537 # Now execute the test 25538 25539 if test -x /usr/libexec/java_home; then 25540 BOOT_JDK=`/usr/libexec/java_home -v 1.7` 25541 BOOT_JDK_FOUND=maybe 25542 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home -v 1.7" >&5 25543 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home -v 1.7" >&6;} 25544 fi 25545 25546 25547 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 25548 if test "x$BOOT_JDK_FOUND" = xmaybe; then 25549 # Do we have a bin/java? 25550 if test ! -x "$BOOT_JDK/bin/java"; then 25551 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 25552 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 25553 BOOT_JDK_FOUND=no 25554 else 25555 # Do we have a bin/javac? 25556 if test ! -x "$BOOT_JDK/bin/javac"; then 25557 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 25558 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 25559 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 25560 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 25561 BOOT_JDK_FOUND=no 25562 else 25563 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 25564 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 25565 25566 # Extra M4 quote needed to protect [] in grep expression. 25567 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 25568 if test "x$FOUND_CORRECT_VERSION" = x; then 25569 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 25570 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 25571 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 25572 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 25573 BOOT_JDK_FOUND=no 25574 else 25575 # We're done! :-) 25576 BOOT_JDK_FOUND=yes 25577 25578 # Only process if variable expands to non-empty 25579 25580 if test "x$BOOT_JDK" != x; then 25581 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25582 25583 # Input might be given as Windows format, start by converting to 25584 # unix format. 25585 path="$BOOT_JDK" 25586 new_path=`$CYGPATH -u "$path"` 25587 25588 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 25589 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 25590 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 25591 # "foo.exe" is OK but "foo" is an error. 25592 # 25593 # This test is therefore slightly more accurate than "test -f" to check for file precense. 25594 # It is also a way to make sure we got the proper file name for the real test later on. 25595 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 25596 if test "x$test_shortpath" = x; then 25597 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25598 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25599 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 25600 fi 25601 25602 # Call helper function which possibly converts this using DOS-style short mode. 25603 # If so, the updated path is stored in $new_path. 25604 25605 input_path="$new_path" 25606 # Check if we need to convert this using DOS-style short mode. If the path 25607 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25608 # take no chances and rewrite it. 25609 # Note: m4 eats our [], so we need to use [ and ] instead. 25610 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 25611 if test "x$has_forbidden_chars" != x; then 25612 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25613 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 25614 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 25615 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 25616 # Going to short mode and back again did indeed matter. Since short mode is 25617 # case insensitive, let's make it lowercase to improve readability. 25618 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25619 # Now convert it back to Unix-style (cygpath) 25620 input_path=`$CYGPATH -u "$shortmode_path"` 25621 new_path="$input_path" 25622 fi 25623 fi 25624 25625 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 25626 if test "x$test_cygdrive_prefix" = x; then 25627 # As a simple fix, exclude /usr/bin since it's not a real path. 25628 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 25629 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 25630 # a path prefixed by /cygdrive for fixpath to work. 25631 new_path="$CYGWIN_ROOT_PATH$input_path" 25632 fi 25633 fi 25634 25635 25636 if test "x$path" != "x$new_path"; then 25637 BOOT_JDK="$new_path" 25638 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25639 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25640 fi 25641 25642 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25643 25644 path="$BOOT_JDK" 25645 has_colon=`$ECHO $path | $GREP ^.:` 25646 new_path="$path" 25647 if test "x$has_colon" = x; then 25648 # Not in mixed or Windows style, start by that. 25649 new_path=`cmd //c echo $path` 25650 fi 25651 25652 25653 input_path="$new_path" 25654 # Check if we need to convert this using DOS-style short mode. If the path 25655 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25656 # take no chances and rewrite it. 25657 # Note: m4 eats our [], so we need to use [ and ] instead. 25658 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 25659 if test "x$has_forbidden_chars" != x; then 25660 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25661 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25662 fi 25663 25664 25665 windows_path="$new_path" 25666 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25667 unix_path=`$CYGPATH -u "$windows_path"` 25668 new_path="$unix_path" 25669 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25670 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25671 new_path="$unix_path" 25672 fi 25673 25674 if test "x$path" != "x$new_path"; then 25675 BOOT_JDK="$new_path" 25676 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25677 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25678 fi 25679 25680 # Save the first 10 bytes of this path to the storage, so fixpath can work. 25681 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 25682 25683 else 25684 # We're on a unix platform. Hooray! :) 25685 path="$BOOT_JDK" 25686 has_space=`$ECHO "$path" | $GREP " "` 25687 if test "x$has_space" != x; then 25688 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25689 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25690 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 25691 fi 25692 25693 # Use eval to expand a potential ~ 25694 eval path="$path" 25695 if test ! -f "$path" && test ! -d "$path"; then 25696 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 25697 fi 25698 25699 if test -d "$path"; then 25700 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 25701 else 25702 dir="`$DIRNAME "$path"`" 25703 base="`$BASENAME "$path"`" 25704 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 25705 fi 25706 fi 25707 fi 25708 25709 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 25710 $as_echo_n "checking for Boot JDK... " >&6; } 25711 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 25712 $as_echo "$BOOT_JDK" >&6; } 25713 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 25714 $as_echo_n "checking Boot JDK version... " >&6; } 25715 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 25716 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 25717 $as_echo "$BOOT_JDK_VERSION" >&6; } 25718 fi # end check jdk version 25719 fi # end check javac 25720 fi # end check java 25721 fi # end check boot jdk found 25722 fi 25723 25724 fi 25725 25726 25727 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 25728 if test "x$BOOT_JDK_FOUND" = xmaybe; then 25729 # Do we have a bin/java? 25730 if test ! -x "$BOOT_JDK/bin/java"; then 25731 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 25732 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 25733 BOOT_JDK_FOUND=no 25734 else 25735 # Do we have a bin/javac? 25736 if test ! -x "$BOOT_JDK/bin/javac"; then 25737 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 25738 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 25739 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 25740 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 25741 BOOT_JDK_FOUND=no 25742 else 25743 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 25744 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 25745 25746 # Extra M4 quote needed to protect [] in grep expression. 25747 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 25748 if test "x$FOUND_CORRECT_VERSION" = x; then 25749 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 25750 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 25751 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 25752 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 25753 BOOT_JDK_FOUND=no 25754 else 25755 # We're done! :-) 25756 BOOT_JDK_FOUND=yes 25757 25758 # Only process if variable expands to non-empty 25759 25760 if test "x$BOOT_JDK" != x; then 25761 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25762 25763 # Input might be given as Windows format, start by converting to 25764 # unix format. 25765 path="$BOOT_JDK" 25766 new_path=`$CYGPATH -u "$path"` 25767 25768 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 25769 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 25770 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 25771 # "foo.exe" is OK but "foo" is an error. 25772 # 25773 # This test is therefore slightly more accurate than "test -f" to check for file precense. 25774 # It is also a way to make sure we got the proper file name for the real test later on. 25775 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 25776 if test "x$test_shortpath" = x; then 25777 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25778 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25779 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 25780 fi 25781 25782 # Call helper function which possibly converts this using DOS-style short mode. 25783 # If so, the updated path is stored in $new_path. 25784 25785 input_path="$new_path" 25786 # Check if we need to convert this using DOS-style short mode. If the path 25787 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25788 # take no chances and rewrite it. 25789 # Note: m4 eats our [], so we need to use [ and ] instead. 25790 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 25791 if test "x$has_forbidden_chars" != x; then 25792 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25793 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 25794 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 25795 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 25796 # Going to short mode and back again did indeed matter. Since short mode is 25797 # case insensitive, let's make it lowercase to improve readability. 25798 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25799 # Now convert it back to Unix-style (cygpath) 25800 input_path=`$CYGPATH -u "$shortmode_path"` 25801 new_path="$input_path" 25802 fi 25803 fi 25804 25805 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 25806 if test "x$test_cygdrive_prefix" = x; then 25807 # As a simple fix, exclude /usr/bin since it's not a real path. 25808 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 25809 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 25810 # a path prefixed by /cygdrive for fixpath to work. 25811 new_path="$CYGWIN_ROOT_PATH$input_path" 25812 fi 25813 fi 25814 25815 25816 if test "x$path" != "x$new_path"; then 25817 BOOT_JDK="$new_path" 25818 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25819 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25820 fi 25821 25822 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25823 25824 path="$BOOT_JDK" 25825 has_colon=`$ECHO $path | $GREP ^.:` 25826 new_path="$path" 25827 if test "x$has_colon" = x; then 25828 # Not in mixed or Windows style, start by that. 25829 new_path=`cmd //c echo $path` 25830 fi 25831 25832 25833 input_path="$new_path" 25834 # Check if we need to convert this using DOS-style short mode. If the path 25835 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25836 # take no chances and rewrite it. 25837 # Note: m4 eats our [], so we need to use [ and ] instead. 25838 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 25839 if test "x$has_forbidden_chars" != x; then 25840 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25841 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25842 fi 25843 25844 25845 windows_path="$new_path" 25846 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25847 unix_path=`$CYGPATH -u "$windows_path"` 25848 new_path="$unix_path" 25849 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25850 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25851 new_path="$unix_path" 25852 fi 25853 25854 if test "x$path" != "x$new_path"; then 25855 BOOT_JDK="$new_path" 25856 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25857 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25858 fi 25859 25860 # Save the first 10 bytes of this path to the storage, so fixpath can work. 25861 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 25862 25863 else 25864 # We're on a unix platform. Hooray! :) 25865 path="$BOOT_JDK" 25866 has_space=`$ECHO "$path" | $GREP " "` 25867 if test "x$has_space" != x; then 25868 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25869 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25870 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 25871 fi 25872 25873 # Use eval to expand a potential ~ 25874 eval path="$path" 25875 if test ! -f "$path" && test ! -d "$path"; then 25876 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 25877 fi 25878 25879 if test -d "$path"; then 25880 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 25881 else 25882 dir="`$DIRNAME "$path"`" 25883 base="`$BASENAME "$path"`" 25884 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 25885 fi 25886 fi 25887 fi 25888 25889 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 25890 $as_echo_n "checking for Boot JDK... " >&6; } 25891 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 25892 $as_echo "$BOOT_JDK" >&6; } 25893 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 25894 $as_echo_n "checking Boot JDK version... " >&6; } 25895 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 25896 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 25897 $as_echo "$BOOT_JDK_VERSION" >&6; } 25898 fi # end check jdk version 25899 fi # end check javac 25900 fi # end check java 25901 fi # end check boot jdk found 25902 fi 25903 25904 25905 # Test: Is $JAVA_HOME set? 25906 25907 if test "x$BOOT_JDK_FOUND" = xno; then 25908 # Now execute the test 25909 25910 if test "x$JAVA_HOME" != x; then 25911 JAVA_HOME_PROCESSED="$JAVA_HOME" 25912 25913 # Only process if variable expands to non-empty 25914 25915 if test "x$JAVA_HOME_PROCESSED" != x; then 25916 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25917 25918 # Input might be given as Windows format, start by converting to 25919 # unix format. 25920 path="$JAVA_HOME_PROCESSED" 25921 new_path=`$CYGPATH -u "$path"` 25922 25923 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 25924 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 25925 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 25926 # "foo.exe" is OK but "foo" is an error. 25927 # 25928 # This test is therefore slightly more accurate than "test -f" to check for file precense. 25929 # It is also a way to make sure we got the proper file name for the real test later on. 25930 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 25931 if test "x$test_shortpath" = x; then 25932 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&5 25933 $as_echo "$as_me: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&6;} 25934 as_fn_error $? "Cannot locate the the path of JAVA_HOME_PROCESSED" "$LINENO" 5 25935 fi 25936 25937 # Call helper function which possibly converts this using DOS-style short mode. 25938 # If so, the updated path is stored in $new_path. 25939 25940 input_path="$new_path" 25941 # Check if we need to convert this using DOS-style short mode. If the path 25942 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25943 # take no chances and rewrite it. 25944 # Note: m4 eats our [], so we need to use [ and ] instead. 25945 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 25946 if test "x$has_forbidden_chars" != x; then 25947 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25948 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 25949 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 25950 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 25951 # Going to short mode and back again did indeed matter. Since short mode is 25952 # case insensitive, let's make it lowercase to improve readability. 25953 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25954 # Now convert it back to Unix-style (cygpath) 25955 input_path=`$CYGPATH -u "$shortmode_path"` 25956 new_path="$input_path" 25957 fi 25958 fi 25959 25960 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 25961 if test "x$test_cygdrive_prefix" = x; then 25962 # As a simple fix, exclude /usr/bin since it's not a real path. 25963 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 25964 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 25965 # a path prefixed by /cygdrive for fixpath to work. 25966 new_path="$CYGWIN_ROOT_PATH$input_path" 25967 fi 25968 fi 25969 25970 25971 if test "x$path" != "x$new_path"; then 25972 JAVA_HOME_PROCESSED="$new_path" 25973 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&5 25974 $as_echo "$as_me: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&6;} 25975 fi 25976 25977 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25978 25979 path="$JAVA_HOME_PROCESSED" 25980 has_colon=`$ECHO $path | $GREP ^.:` 25981 new_path="$path" 25982 if test "x$has_colon" = x; then 25983 # Not in mixed or Windows style, start by that. 25984 new_path=`cmd //c echo $path` 25985 fi 25986 25987 25988 input_path="$new_path" 25989 # Check if we need to convert this using DOS-style short mode. If the path 25990 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25991 # take no chances and rewrite it. 25992 # Note: m4 eats our [], so we need to use [ and ] instead. 25993 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 25994 if test "x$has_forbidden_chars" != x; then 25995 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25996 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25997 fi 25998 25999 26000 windows_path="$new_path" 26001 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26002 unix_path=`$CYGPATH -u "$windows_path"` 26003 new_path="$unix_path" 26004 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26005 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26006 new_path="$unix_path" 26007 fi 26008 26009 if test "x$path" != "x$new_path"; then 26010 JAVA_HOME_PROCESSED="$new_path" 26011 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&5 26012 $as_echo "$as_me: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&6;} 26013 fi 26014 26015 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26016 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26017 26018 else 26019 # We're on a unix platform. Hooray! :) 26020 path="$JAVA_HOME_PROCESSED" 26021 has_space=`$ECHO "$path" | $GREP " "` 26022 if test "x$has_space" != x; then 26023 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&5 26024 $as_echo "$as_me: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&6;} 26025 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 26026 fi 26027 26028 # Use eval to expand a potential ~ 26029 eval path="$path" 26030 if test ! -f "$path" && test ! -d "$path"; then 26031 as_fn_error $? "The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is not found." "$LINENO" 5 26032 fi 26033 26034 if test -d "$path"; then 26035 JAVA_HOME_PROCESSED="`cd "$path"; $THEPWDCMD -L`" 26036 else 26037 dir="`$DIRNAME "$path"`" 26038 base="`$BASENAME "$path"`" 26039 JAVA_HOME_PROCESSED="`cd "$dir"; $THEPWDCMD -L`/$base" 26040 fi 26041 fi 26042 fi 26043 26044 if test ! -d "$JAVA_HOME_PROCESSED"; then 26045 { $as_echo "$as_me:${as_lineno-$LINENO}: Your JAVA_HOME points to a non-existing directory!" >&5 26046 $as_echo "$as_me: Your JAVA_HOME points to a non-existing directory!" >&6;} 26047 else 26048 # Aha, the user has set a JAVA_HOME 26049 # let us use that as the Boot JDK. 26050 BOOT_JDK="$JAVA_HOME_PROCESSED" 26051 BOOT_JDK_FOUND=maybe 26052 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using JAVA_HOME" >&5 26053 $as_echo "$as_me: Found potential Boot JDK using JAVA_HOME" >&6;} 26054 fi 26055 fi 26056 26057 26058 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 26059 if test "x$BOOT_JDK_FOUND" = xmaybe; then 26060 # Do we have a bin/java? 26061 if test ! -x "$BOOT_JDK/bin/java"; then 26062 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 26063 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 26064 BOOT_JDK_FOUND=no 26065 else 26066 # Do we have a bin/javac? 26067 if test ! -x "$BOOT_JDK/bin/javac"; then 26068 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 26069 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 26070 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 26071 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 26072 BOOT_JDK_FOUND=no 26073 else 26074 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 26075 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 26076 26077 # Extra M4 quote needed to protect [] in grep expression. 26078 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 26079 if test "x$FOUND_CORRECT_VERSION" = x; then 26080 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 26081 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 26082 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 26083 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 26084 BOOT_JDK_FOUND=no 26085 else 26086 # We're done! :-) 26087 BOOT_JDK_FOUND=yes 26088 26089 # Only process if variable expands to non-empty 26090 26091 if test "x$BOOT_JDK" != x; then 26092 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26093 26094 # Input might be given as Windows format, start by converting to 26095 # unix format. 26096 path="$BOOT_JDK" 26097 new_path=`$CYGPATH -u "$path"` 26098 26099 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26100 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26101 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26102 # "foo.exe" is OK but "foo" is an error. 26103 # 26104 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26105 # It is also a way to make sure we got the proper file name for the real test later on. 26106 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26107 if test "x$test_shortpath" = x; then 26108 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26109 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26110 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 26111 fi 26112 26113 # Call helper function which possibly converts this using DOS-style short mode. 26114 # If so, the updated path is stored in $new_path. 26115 26116 input_path="$new_path" 26117 # Check if we need to convert this using DOS-style short mode. If the path 26118 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26119 # take no chances and rewrite it. 26120 # Note: m4 eats our [], so we need to use [ and ] instead. 26121 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26122 if test "x$has_forbidden_chars" != x; then 26123 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26124 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26125 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26126 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26127 # Going to short mode and back again did indeed matter. Since short mode is 26128 # case insensitive, let's make it lowercase to improve readability. 26129 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26130 # Now convert it back to Unix-style (cygpath) 26131 input_path=`$CYGPATH -u "$shortmode_path"` 26132 new_path="$input_path" 26133 fi 26134 fi 26135 26136 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26137 if test "x$test_cygdrive_prefix" = x; then 26138 # As a simple fix, exclude /usr/bin since it's not a real path. 26139 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 26140 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26141 # a path prefixed by /cygdrive for fixpath to work. 26142 new_path="$CYGWIN_ROOT_PATH$input_path" 26143 fi 26144 fi 26145 26146 26147 if test "x$path" != "x$new_path"; then 26148 BOOT_JDK="$new_path" 26149 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26150 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26151 fi 26152 26153 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26154 26155 path="$BOOT_JDK" 26156 has_colon=`$ECHO $path | $GREP ^.:` 26157 new_path="$path" 26158 if test "x$has_colon" = x; then 26159 # Not in mixed or Windows style, start by that. 26160 new_path=`cmd //c echo $path` 26161 fi 26162 26163 26164 input_path="$new_path" 26165 # Check if we need to convert this using DOS-style short mode. If the path 26166 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26167 # take no chances and rewrite it. 26168 # Note: m4 eats our [], so we need to use [ and ] instead. 26169 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26170 if test "x$has_forbidden_chars" != x; then 26171 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26172 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26173 fi 26174 26175 26176 windows_path="$new_path" 26177 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26178 unix_path=`$CYGPATH -u "$windows_path"` 26179 new_path="$unix_path" 26180 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26181 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26182 new_path="$unix_path" 26183 fi 26184 26185 if test "x$path" != "x$new_path"; then 26186 BOOT_JDK="$new_path" 26187 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26188 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26189 fi 26190 26191 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26192 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26193 26194 else 26195 # We're on a unix platform. Hooray! :) 26196 path="$BOOT_JDK" 26197 has_space=`$ECHO "$path" | $GREP " "` 26198 if test "x$has_space" != x; then 26199 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26200 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26201 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 26202 fi 26203 26204 # Use eval to expand a potential ~ 26205 eval path="$path" 26206 if test ! -f "$path" && test ! -d "$path"; then 26207 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 26208 fi 26209 26210 if test -d "$path"; then 26211 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 26212 else 26213 dir="`$DIRNAME "$path"`" 26214 base="`$BASENAME "$path"`" 26215 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 26216 fi 26217 fi 26218 fi 26219 26220 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 26221 $as_echo_n "checking for Boot JDK... " >&6; } 26222 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 26223 $as_echo "$BOOT_JDK" >&6; } 26224 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 26225 $as_echo_n "checking Boot JDK version... " >&6; } 26226 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 26227 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 26228 $as_echo "$BOOT_JDK_VERSION" >&6; } 26229 fi # end check jdk version 26230 fi # end check javac 26231 fi # end check java 26232 fi # end check boot jdk found 26233 fi 26234 26235 26236 # Test: Is there a java or javac in the PATH, which is a symlink to the JDK? 26237 26238 if test "x$BOOT_JDK_FOUND" = xno; then 26239 # Now execute the test 26240 26241 # Extract the first word of "javac", so it can be a program name with args. 26242 set dummy javac; ac_word=$2 26243 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 26244 $as_echo_n "checking for $ac_word... " >&6; } 26245 if ${ac_cv_path_JAVAC_CHECK+:} false; then : 26246 $as_echo_n "(cached) " >&6 26247 else 26248 case $JAVAC_CHECK in 26249 [\\/]* | ?:[\\/]*) 26250 ac_cv_path_JAVAC_CHECK="$JAVAC_CHECK" # Let the user override the test with a path. 26251 ;; 26252 *) 26253 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 26254 for as_dir in $PATH 26255 do 26256 IFS=$as_save_IFS 26257 test -z "$as_dir" && as_dir=. 26258 for ac_exec_ext in '' $ac_executable_extensions; do 26259 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 26260 ac_cv_path_JAVAC_CHECK="$as_dir/$ac_word$ac_exec_ext" 26261 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 26262 break 2 26263 fi 26264 done 26265 done 26266 IFS=$as_save_IFS 26267 26268 ;; 26269 esac 26270 fi 26271 JAVAC_CHECK=$ac_cv_path_JAVAC_CHECK 26272 if test -n "$JAVAC_CHECK"; then 26273 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVAC_CHECK" >&5 26274 $as_echo "$JAVAC_CHECK" >&6; } 26275 else 26276 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 26277 $as_echo "no" >&6; } 26278 fi 26279 26280 26281 # Extract the first word of "java", so it can be a program name with args. 26282 set dummy java; ac_word=$2 26283 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 26284 $as_echo_n "checking for $ac_word... " >&6; } 26285 if ${ac_cv_path_JAVA_CHECK+:} false; then : 26286 $as_echo_n "(cached) " >&6 26287 else 26288 case $JAVA_CHECK in 26289 [\\/]* | ?:[\\/]*) 26290 ac_cv_path_JAVA_CHECK="$JAVA_CHECK" # Let the user override the test with a path. 26291 ;; 26292 *) 26293 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 26294 for as_dir in $PATH 26295 do 26296 IFS=$as_save_IFS 26297 test -z "$as_dir" && as_dir=. 26298 for ac_exec_ext in '' $ac_executable_extensions; do 26299 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 26300 ac_cv_path_JAVA_CHECK="$as_dir/$ac_word$ac_exec_ext" 26301 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 26302 break 2 26303 fi 26304 done 26305 done 26306 IFS=$as_save_IFS 26307 26308 ;; 26309 esac 26310 fi 26311 JAVA_CHECK=$ac_cv_path_JAVA_CHECK 26312 if test -n "$JAVA_CHECK"; then 26313 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVA_CHECK" >&5 26314 $as_echo "$JAVA_CHECK" >&6; } 26315 else 26316 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 26317 $as_echo "no" >&6; } 26318 fi 26319 26320 26321 BINARY="$JAVAC_CHECK" 26322 if test "x$JAVAC_CHECK" = x; then 26323 BINARY="$JAVA_CHECK" 26324 fi 26325 if test "x$BINARY" != x; then 26326 # So there is a java(c) binary, it might be part of a JDK. 26327 # Lets find the JDK/JRE directory by following symbolic links. 26328 # Linux/GNU systems often have links from /usr/bin/java to 26329 # /etc/alternatives/java to the real JDK binary. 26330 26331 if test "x$OPENJDK_BUILD_OS" != xwindows; then 26332 # Follow a chain of symbolic links. Use readlink 26333 # where it exists, else fall back to horribly 26334 # complicated shell code. 26335 if test "x$READLINK_TESTED" != yes; then 26336 # On MacOSX there is a readlink tool with a different 26337 # purpose than the GNU readlink tool. Check the found readlink. 26338 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 26339 if test "x$ISGNU" = x; then 26340 # A readlink that we do not know how to use. 26341 # Are there other non-GNU readlinks out there? 26342 READLINK_TESTED=yes 26343 READLINK= 26344 fi 26345 fi 26346 26347 if test "x$READLINK" != x; then 26348 BINARY=`$READLINK -f $BINARY` 26349 else 26350 # Save the current directory for restoring afterwards 26351 STARTDIR=$PWD 26352 COUNTER=0 26353 sym_link_dir=`$DIRNAME $BINARY` 26354 sym_link_file=`$BASENAME $BINARY` 26355 cd $sym_link_dir 26356 # Use -P flag to resolve symlinks in directories. 26357 cd `$THEPWDCMD -P` 26358 sym_link_dir=`$THEPWDCMD -P` 26359 # Resolve file symlinks 26360 while test $COUNTER -lt 20; do 26361 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 26362 if test "x$ISLINK" == x; then 26363 # This is not a symbolic link! We are done! 26364 break 26365 fi 26366 # Again resolve directory symlinks since the target of the just found 26367 # link could be in a different directory 26368 cd `$DIRNAME $ISLINK` 26369 sym_link_dir=`$THEPWDCMD -P` 26370 sym_link_file=`$BASENAME $ISLINK` 26371 let COUNTER=COUNTER+1 26372 done 26373 cd $STARTDIR 26374 BINARY=$sym_link_dir/$sym_link_file 26375 fi 26376 fi 26377 26378 BOOT_JDK=`dirname "$BINARY"` 26379 BOOT_JDK=`cd "$BOOT_JDK/.."; pwd` 26380 if test -x "$BOOT_JDK/bin/javac" && test -x "$BOOT_JDK/bin/java"; then 26381 # Looks like we found ourselves an JDK 26382 BOOT_JDK_FOUND=maybe 26383 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using java(c) in PATH" >&5 26384 $as_echo "$as_me: Found potential Boot JDK using java(c) in PATH" >&6;} 26385 fi 26386 fi 26387 26388 26389 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 26390 if test "x$BOOT_JDK_FOUND" = xmaybe; then 26391 # Do we have a bin/java? 26392 if test ! -x "$BOOT_JDK/bin/java"; then 26393 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 26394 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 26395 BOOT_JDK_FOUND=no 26396 else 26397 # Do we have a bin/javac? 26398 if test ! -x "$BOOT_JDK/bin/javac"; then 26399 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 26400 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 26401 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 26402 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 26403 BOOT_JDK_FOUND=no 26404 else 26405 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 26406 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 26407 26408 # Extra M4 quote needed to protect [] in grep expression. 26409 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 26410 if test "x$FOUND_CORRECT_VERSION" = x; then 26411 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 26412 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 26413 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 26414 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 26415 BOOT_JDK_FOUND=no 26416 else 26417 # We're done! :-) 26418 BOOT_JDK_FOUND=yes 26419 26420 # Only process if variable expands to non-empty 26421 26422 if test "x$BOOT_JDK" != x; then 26423 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26424 26425 # Input might be given as Windows format, start by converting to 26426 # unix format. 26427 path="$BOOT_JDK" 26428 new_path=`$CYGPATH -u "$path"` 26429 26430 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26431 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26432 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26433 # "foo.exe" is OK but "foo" is an error. 26434 # 26435 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26436 # It is also a way to make sure we got the proper file name for the real test later on. 26437 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26438 if test "x$test_shortpath" = x; then 26439 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26440 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26441 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 26442 fi 26443 26444 # Call helper function which possibly converts this using DOS-style short mode. 26445 # If so, the updated path is stored in $new_path. 26446 26447 input_path="$new_path" 26448 # Check if we need to convert this using DOS-style short mode. If the path 26449 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26450 # take no chances and rewrite it. 26451 # Note: m4 eats our [], so we need to use [ and ] instead. 26452 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26453 if test "x$has_forbidden_chars" != x; then 26454 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26455 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26456 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26457 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26458 # Going to short mode and back again did indeed matter. Since short mode is 26459 # case insensitive, let's make it lowercase to improve readability. 26460 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26461 # Now convert it back to Unix-style (cygpath) 26462 input_path=`$CYGPATH -u "$shortmode_path"` 26463 new_path="$input_path" 26464 fi 26465 fi 26466 26467 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26468 if test "x$test_cygdrive_prefix" = x; then 26469 # As a simple fix, exclude /usr/bin since it's not a real path. 26470 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 26471 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26472 # a path prefixed by /cygdrive for fixpath to work. 26473 new_path="$CYGWIN_ROOT_PATH$input_path" 26474 fi 26475 fi 26476 26477 26478 if test "x$path" != "x$new_path"; then 26479 BOOT_JDK="$new_path" 26480 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26481 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26482 fi 26483 26484 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26485 26486 path="$BOOT_JDK" 26487 has_colon=`$ECHO $path | $GREP ^.:` 26488 new_path="$path" 26489 if test "x$has_colon" = x; then 26490 # Not in mixed or Windows style, start by that. 26491 new_path=`cmd //c echo $path` 26492 fi 26493 26494 26495 input_path="$new_path" 26496 # Check if we need to convert this using DOS-style short mode. If the path 26497 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26498 # take no chances and rewrite it. 26499 # Note: m4 eats our [], so we need to use [ and ] instead. 26500 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26501 if test "x$has_forbidden_chars" != x; then 26502 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26503 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26504 fi 26505 26506 26507 windows_path="$new_path" 26508 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26509 unix_path=`$CYGPATH -u "$windows_path"` 26510 new_path="$unix_path" 26511 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26512 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26513 new_path="$unix_path" 26514 fi 26515 26516 if test "x$path" != "x$new_path"; then 26517 BOOT_JDK="$new_path" 26518 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26519 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26520 fi 26521 26522 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26523 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26524 26525 else 26526 # We're on a unix platform. Hooray! :) 26527 path="$BOOT_JDK" 26528 has_space=`$ECHO "$path" | $GREP " "` 26529 if test "x$has_space" != x; then 26530 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26531 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26532 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 26533 fi 26534 26535 # Use eval to expand a potential ~ 26536 eval path="$path" 26537 if test ! -f "$path" && test ! -d "$path"; then 26538 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 26539 fi 26540 26541 if test -d "$path"; then 26542 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 26543 else 26544 dir="`$DIRNAME "$path"`" 26545 base="`$BASENAME "$path"`" 26546 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 26547 fi 26548 fi 26549 fi 26550 26551 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 26552 $as_echo_n "checking for Boot JDK... " >&6; } 26553 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 26554 $as_echo "$BOOT_JDK" >&6; } 26555 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 26556 $as_echo_n "checking Boot JDK version... " >&6; } 26557 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 26558 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 26559 $as_echo "$BOOT_JDK_VERSION" >&6; } 26560 fi # end check jdk version 26561 fi # end check javac 26562 fi # end check java 26563 fi # end check boot jdk found 26564 fi 26565 26566 26567 # Test: Is there a JDK installed in default, well-known locations? 26568 26569 if test "x$BOOT_JDK_FOUND" = xno; then 26570 # Now execute the test 26571 26572 if test "x$OPENJDK_TARGET_OS" = xwindows; then 26573 26574 if test "x$BOOT_JDK_FOUND" = xno; then 26575 # Now execute the test 26576 26577 if test "x$ProgramW6432" != x; then 26578 VIRTUAL_DIR="$ProgramW6432/Java" 26579 26580 windows_path="$VIRTUAL_DIR" 26581 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26582 unix_path=`$CYGPATH -u "$windows_path"` 26583 VIRTUAL_DIR="$unix_path" 26584 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26585 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26586 VIRTUAL_DIR="$unix_path" 26587 fi 26588 26589 26590 BOOT_JDK_PREFIX="$VIRTUAL_DIR" 26591 BOOT_JDK_SUFFIX="" 26592 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 26593 if test "x$ALL_JDKS_FOUND" != x; then 26594 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 26595 26596 if test "x$BOOT_JDK_FOUND" = xno; then 26597 # Now execute the test 26598 26599 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 26600 if test -d "$BOOT_JDK"; then 26601 BOOT_JDK_FOUND=maybe 26602 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 26603 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 26604 fi 26605 26606 26607 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 26608 if test "x$BOOT_JDK_FOUND" = xmaybe; then 26609 # Do we have a bin/java? 26610 if test ! -x "$BOOT_JDK/bin/java"; then 26611 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 26612 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 26613 BOOT_JDK_FOUND=no 26614 else 26615 # Do we have a bin/javac? 26616 if test ! -x "$BOOT_JDK/bin/javac"; then 26617 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 26618 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 26619 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 26620 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 26621 BOOT_JDK_FOUND=no 26622 else 26623 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 26624 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 26625 26626 # Extra M4 quote needed to protect [] in grep expression. 26627 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 26628 if test "x$FOUND_CORRECT_VERSION" = x; then 26629 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 26630 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 26631 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 26632 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 26633 BOOT_JDK_FOUND=no 26634 else 26635 # We're done! :-) 26636 BOOT_JDK_FOUND=yes 26637 26638 # Only process if variable expands to non-empty 26639 26640 if test "x$BOOT_JDK" != x; then 26641 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26642 26643 # Input might be given as Windows format, start by converting to 26644 # unix format. 26645 path="$BOOT_JDK" 26646 new_path=`$CYGPATH -u "$path"` 26647 26648 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26649 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26650 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26651 # "foo.exe" is OK but "foo" is an error. 26652 # 26653 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26654 # It is also a way to make sure we got the proper file name for the real test later on. 26655 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26656 if test "x$test_shortpath" = x; then 26657 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26658 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26659 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 26660 fi 26661 26662 # Call helper function which possibly converts this using DOS-style short mode. 26663 # If so, the updated path is stored in $new_path. 26664 26665 input_path="$new_path" 26666 # Check if we need to convert this using DOS-style short mode. If the path 26667 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26668 # take no chances and rewrite it. 26669 # Note: m4 eats our [], so we need to use [ and ] instead. 26670 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26671 if test "x$has_forbidden_chars" != x; then 26672 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26673 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26674 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26675 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26676 # Going to short mode and back again did indeed matter. Since short mode is 26677 # case insensitive, let's make it lowercase to improve readability. 26678 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26679 # Now convert it back to Unix-style (cygpath) 26680 input_path=`$CYGPATH -u "$shortmode_path"` 26681 new_path="$input_path" 26682 fi 26683 fi 26684 26685 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26686 if test "x$test_cygdrive_prefix" = x; then 26687 # As a simple fix, exclude /usr/bin since it's not a real path. 26688 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 26689 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26690 # a path prefixed by /cygdrive for fixpath to work. 26691 new_path="$CYGWIN_ROOT_PATH$input_path" 26692 fi 26693 fi 26694 26695 26696 if test "x$path" != "x$new_path"; then 26697 BOOT_JDK="$new_path" 26698 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26699 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26700 fi 26701 26702 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26703 26704 path="$BOOT_JDK" 26705 has_colon=`$ECHO $path | $GREP ^.:` 26706 new_path="$path" 26707 if test "x$has_colon" = x; then 26708 # Not in mixed or Windows style, start by that. 26709 new_path=`cmd //c echo $path` 26710 fi 26711 26712 26713 input_path="$new_path" 26714 # Check if we need to convert this using DOS-style short mode. If the path 26715 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26716 # take no chances and rewrite it. 26717 # Note: m4 eats our [], so we need to use [ and ] instead. 26718 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26719 if test "x$has_forbidden_chars" != x; then 26720 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26721 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26722 fi 26723 26724 26725 windows_path="$new_path" 26726 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26727 unix_path=`$CYGPATH -u "$windows_path"` 26728 new_path="$unix_path" 26729 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26730 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26731 new_path="$unix_path" 26732 fi 26733 26734 if test "x$path" != "x$new_path"; then 26735 BOOT_JDK="$new_path" 26736 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26737 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26738 fi 26739 26740 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26741 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26742 26743 else 26744 # We're on a unix platform. Hooray! :) 26745 path="$BOOT_JDK" 26746 has_space=`$ECHO "$path" | $GREP " "` 26747 if test "x$has_space" != x; then 26748 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26749 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26750 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 26751 fi 26752 26753 # Use eval to expand a potential ~ 26754 eval path="$path" 26755 if test ! -f "$path" && test ! -d "$path"; then 26756 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 26757 fi 26758 26759 if test -d "$path"; then 26760 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 26761 else 26762 dir="`$DIRNAME "$path"`" 26763 base="`$BASENAME "$path"`" 26764 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 26765 fi 26766 fi 26767 fi 26768 26769 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 26770 $as_echo_n "checking for Boot JDK... " >&6; } 26771 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 26772 $as_echo "$BOOT_JDK" >&6; } 26773 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 26774 $as_echo_n "checking Boot JDK version... " >&6; } 26775 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 26776 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 26777 $as_echo "$BOOT_JDK_VERSION" >&6; } 26778 fi # end check jdk version 26779 fi # end check javac 26780 fi # end check java 26781 fi # end check boot jdk found 26782 fi 26783 26784 done 26785 fi 26786 26787 fi 26788 26789 26790 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 26791 if test "x$BOOT_JDK_FOUND" = xmaybe; then 26792 # Do we have a bin/java? 26793 if test ! -x "$BOOT_JDK/bin/java"; then 26794 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 26795 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 26796 BOOT_JDK_FOUND=no 26797 else 26798 # Do we have a bin/javac? 26799 if test ! -x "$BOOT_JDK/bin/javac"; then 26800 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 26801 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 26802 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 26803 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 26804 BOOT_JDK_FOUND=no 26805 else 26806 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 26807 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 26808 26809 # Extra M4 quote needed to protect [] in grep expression. 26810 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 26811 if test "x$FOUND_CORRECT_VERSION" = x; then 26812 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 26813 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 26814 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 26815 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 26816 BOOT_JDK_FOUND=no 26817 else 26818 # We're done! :-) 26819 BOOT_JDK_FOUND=yes 26820 26821 # Only process if variable expands to non-empty 26822 26823 if test "x$BOOT_JDK" != x; then 26824 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26825 26826 # Input might be given as Windows format, start by converting to 26827 # unix format. 26828 path="$BOOT_JDK" 26829 new_path=`$CYGPATH -u "$path"` 26830 26831 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26832 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26833 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26834 # "foo.exe" is OK but "foo" is an error. 26835 # 26836 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26837 # It is also a way to make sure we got the proper file name for the real test later on. 26838 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26839 if test "x$test_shortpath" = x; then 26840 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26841 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26842 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 26843 fi 26844 26845 # Call helper function which possibly converts this using DOS-style short mode. 26846 # If so, the updated path is stored in $new_path. 26847 26848 input_path="$new_path" 26849 # Check if we need to convert this using DOS-style short mode. If the path 26850 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26851 # take no chances and rewrite it. 26852 # Note: m4 eats our [], so we need to use [ and ] instead. 26853 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26854 if test "x$has_forbidden_chars" != x; then 26855 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26856 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26857 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26858 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26859 # Going to short mode and back again did indeed matter. Since short mode is 26860 # case insensitive, let's make it lowercase to improve readability. 26861 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26862 # Now convert it back to Unix-style (cygpath) 26863 input_path=`$CYGPATH -u "$shortmode_path"` 26864 new_path="$input_path" 26865 fi 26866 fi 26867 26868 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26869 if test "x$test_cygdrive_prefix" = x; then 26870 # As a simple fix, exclude /usr/bin since it's not a real path. 26871 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 26872 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26873 # a path prefixed by /cygdrive for fixpath to work. 26874 new_path="$CYGWIN_ROOT_PATH$input_path" 26875 fi 26876 fi 26877 26878 26879 if test "x$path" != "x$new_path"; then 26880 BOOT_JDK="$new_path" 26881 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26882 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26883 fi 26884 26885 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26886 26887 path="$BOOT_JDK" 26888 has_colon=`$ECHO $path | $GREP ^.:` 26889 new_path="$path" 26890 if test "x$has_colon" = x; then 26891 # Not in mixed or Windows style, start by that. 26892 new_path=`cmd //c echo $path` 26893 fi 26894 26895 26896 input_path="$new_path" 26897 # Check if we need to convert this using DOS-style short mode. If the path 26898 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26899 # take no chances and rewrite it. 26900 # Note: m4 eats our [], so we need to use [ and ] instead. 26901 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26902 if test "x$has_forbidden_chars" != x; then 26903 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26904 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26905 fi 26906 26907 26908 windows_path="$new_path" 26909 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26910 unix_path=`$CYGPATH -u "$windows_path"` 26911 new_path="$unix_path" 26912 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26913 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26914 new_path="$unix_path" 26915 fi 26916 26917 if test "x$path" != "x$new_path"; then 26918 BOOT_JDK="$new_path" 26919 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26920 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26921 fi 26922 26923 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26924 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26925 26926 else 26927 # We're on a unix platform. Hooray! :) 26928 path="$BOOT_JDK" 26929 has_space=`$ECHO "$path" | $GREP " "` 26930 if test "x$has_space" != x; then 26931 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26932 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26933 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 26934 fi 26935 26936 # Use eval to expand a potential ~ 26937 eval path="$path" 26938 if test ! -f "$path" && test ! -d "$path"; then 26939 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 26940 fi 26941 26942 if test -d "$path"; then 26943 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 26944 else 26945 dir="`$DIRNAME "$path"`" 26946 base="`$BASENAME "$path"`" 26947 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 26948 fi 26949 fi 26950 fi 26951 26952 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 26953 $as_echo_n "checking for Boot JDK... " >&6; } 26954 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 26955 $as_echo "$BOOT_JDK" >&6; } 26956 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 26957 $as_echo_n "checking Boot JDK version... " >&6; } 26958 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 26959 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 26960 $as_echo "$BOOT_JDK_VERSION" >&6; } 26961 fi # end check jdk version 26962 fi # end check javac 26963 fi # end check java 26964 fi # end check boot jdk found 26965 fi 26966 26967 26968 if test "x$BOOT_JDK_FOUND" = xno; then 26969 # Now execute the test 26970 26971 if test "x$PROGRAMW6432" != x; then 26972 VIRTUAL_DIR="$PROGRAMW6432/Java" 26973 26974 windows_path="$VIRTUAL_DIR" 26975 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26976 unix_path=`$CYGPATH -u "$windows_path"` 26977 VIRTUAL_DIR="$unix_path" 26978 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26979 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26980 VIRTUAL_DIR="$unix_path" 26981 fi 26982 26983 26984 BOOT_JDK_PREFIX="$VIRTUAL_DIR" 26985 BOOT_JDK_SUFFIX="" 26986 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 26987 if test "x$ALL_JDKS_FOUND" != x; then 26988 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 26989 26990 if test "x$BOOT_JDK_FOUND" = xno; then 26991 # Now execute the test 26992 26993 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 26994 if test -d "$BOOT_JDK"; then 26995 BOOT_JDK_FOUND=maybe 26996 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 26997 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 26998 fi 26999 27000 27001 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 27002 if test "x$BOOT_JDK_FOUND" = xmaybe; then 27003 # Do we have a bin/java? 27004 if test ! -x "$BOOT_JDK/bin/java"; then 27005 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 27006 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 27007 BOOT_JDK_FOUND=no 27008 else 27009 # Do we have a bin/javac? 27010 if test ! -x "$BOOT_JDK/bin/javac"; then 27011 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 27012 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 27013 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 27014 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 27015 BOOT_JDK_FOUND=no 27016 else 27017 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 27018 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 27019 27020 # Extra M4 quote needed to protect [] in grep expression. 27021 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 27022 if test "x$FOUND_CORRECT_VERSION" = x; then 27023 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 27024 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 27025 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 27026 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 27027 BOOT_JDK_FOUND=no 27028 else 27029 # We're done! :-) 27030 BOOT_JDK_FOUND=yes 27031 27032 # Only process if variable expands to non-empty 27033 27034 if test "x$BOOT_JDK" != x; then 27035 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27036 27037 # Input might be given as Windows format, start by converting to 27038 # unix format. 27039 path="$BOOT_JDK" 27040 new_path=`$CYGPATH -u "$path"` 27041 27042 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27043 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27044 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27045 # "foo.exe" is OK but "foo" is an error. 27046 # 27047 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27048 # It is also a way to make sure we got the proper file name for the real test later on. 27049 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27050 if test "x$test_shortpath" = x; then 27051 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27052 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27053 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 27054 fi 27055 27056 # Call helper function which possibly converts this using DOS-style short mode. 27057 # If so, the updated path is stored in $new_path. 27058 27059 input_path="$new_path" 27060 # Check if we need to convert this using DOS-style short mode. If the path 27061 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27062 # take no chances and rewrite it. 27063 # Note: m4 eats our [], so we need to use [ and ] instead. 27064 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27065 if test "x$has_forbidden_chars" != x; then 27066 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27067 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27068 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27069 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27070 # Going to short mode and back again did indeed matter. Since short mode is 27071 # case insensitive, let's make it lowercase to improve readability. 27072 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27073 # Now convert it back to Unix-style (cygpath) 27074 input_path=`$CYGPATH -u "$shortmode_path"` 27075 new_path="$input_path" 27076 fi 27077 fi 27078 27079 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27080 if test "x$test_cygdrive_prefix" = x; then 27081 # As a simple fix, exclude /usr/bin since it's not a real path. 27082 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 27083 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27084 # a path prefixed by /cygdrive for fixpath to work. 27085 new_path="$CYGWIN_ROOT_PATH$input_path" 27086 fi 27087 fi 27088 27089 27090 if test "x$path" != "x$new_path"; then 27091 BOOT_JDK="$new_path" 27092 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27093 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27094 fi 27095 27096 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27097 27098 path="$BOOT_JDK" 27099 has_colon=`$ECHO $path | $GREP ^.:` 27100 new_path="$path" 27101 if test "x$has_colon" = x; then 27102 # Not in mixed or Windows style, start by that. 27103 new_path=`cmd //c echo $path` 27104 fi 27105 27106 27107 input_path="$new_path" 27108 # Check if we need to convert this using DOS-style short mode. If the path 27109 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27110 # take no chances and rewrite it. 27111 # Note: m4 eats our [], so we need to use [ and ] instead. 27112 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27113 if test "x$has_forbidden_chars" != x; then 27114 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27115 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27116 fi 27117 27118 27119 windows_path="$new_path" 27120 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27121 unix_path=`$CYGPATH -u "$windows_path"` 27122 new_path="$unix_path" 27123 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27124 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27125 new_path="$unix_path" 27126 fi 27127 27128 if test "x$path" != "x$new_path"; then 27129 BOOT_JDK="$new_path" 27130 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27131 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27132 fi 27133 27134 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27135 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27136 27137 else 27138 # We're on a unix platform. Hooray! :) 27139 path="$BOOT_JDK" 27140 has_space=`$ECHO "$path" | $GREP " "` 27141 if test "x$has_space" != x; then 27142 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27143 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27144 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 27145 fi 27146 27147 # Use eval to expand a potential ~ 27148 eval path="$path" 27149 if test ! -f "$path" && test ! -d "$path"; then 27150 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 27151 fi 27152 27153 if test -d "$path"; then 27154 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 27155 else 27156 dir="`$DIRNAME "$path"`" 27157 base="`$BASENAME "$path"`" 27158 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 27159 fi 27160 fi 27161 fi 27162 27163 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 27164 $as_echo_n "checking for Boot JDK... " >&6; } 27165 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 27166 $as_echo "$BOOT_JDK" >&6; } 27167 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 27168 $as_echo_n "checking Boot JDK version... " >&6; } 27169 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 27170 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 27171 $as_echo "$BOOT_JDK_VERSION" >&6; } 27172 fi # end check jdk version 27173 fi # end check javac 27174 fi # end check java 27175 fi # end check boot jdk found 27176 fi 27177 27178 done 27179 fi 27180 27181 fi 27182 27183 27184 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 27185 if test "x$BOOT_JDK_FOUND" = xmaybe; then 27186 # Do we have a bin/java? 27187 if test ! -x "$BOOT_JDK/bin/java"; then 27188 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 27189 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 27190 BOOT_JDK_FOUND=no 27191 else 27192 # Do we have a bin/javac? 27193 if test ! -x "$BOOT_JDK/bin/javac"; then 27194 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 27195 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 27196 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 27197 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 27198 BOOT_JDK_FOUND=no 27199 else 27200 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 27201 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 27202 27203 # Extra M4 quote needed to protect [] in grep expression. 27204 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 27205 if test "x$FOUND_CORRECT_VERSION" = x; then 27206 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 27207 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 27208 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 27209 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 27210 BOOT_JDK_FOUND=no 27211 else 27212 # We're done! :-) 27213 BOOT_JDK_FOUND=yes 27214 27215 # Only process if variable expands to non-empty 27216 27217 if test "x$BOOT_JDK" != x; then 27218 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27219 27220 # Input might be given as Windows format, start by converting to 27221 # unix format. 27222 path="$BOOT_JDK" 27223 new_path=`$CYGPATH -u "$path"` 27224 27225 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27226 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27227 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27228 # "foo.exe" is OK but "foo" is an error. 27229 # 27230 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27231 # It is also a way to make sure we got the proper file name for the real test later on. 27232 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27233 if test "x$test_shortpath" = x; then 27234 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27235 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27236 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 27237 fi 27238 27239 # Call helper function which possibly converts this using DOS-style short mode. 27240 # If so, the updated path is stored in $new_path. 27241 27242 input_path="$new_path" 27243 # Check if we need to convert this using DOS-style short mode. If the path 27244 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27245 # take no chances and rewrite it. 27246 # Note: m4 eats our [], so we need to use [ and ] instead. 27247 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27248 if test "x$has_forbidden_chars" != x; then 27249 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27250 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27251 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27252 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27253 # Going to short mode and back again did indeed matter. Since short mode is 27254 # case insensitive, let's make it lowercase to improve readability. 27255 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27256 # Now convert it back to Unix-style (cygpath) 27257 input_path=`$CYGPATH -u "$shortmode_path"` 27258 new_path="$input_path" 27259 fi 27260 fi 27261 27262 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27263 if test "x$test_cygdrive_prefix" = x; then 27264 # As a simple fix, exclude /usr/bin since it's not a real path. 27265 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 27266 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27267 # a path prefixed by /cygdrive for fixpath to work. 27268 new_path="$CYGWIN_ROOT_PATH$input_path" 27269 fi 27270 fi 27271 27272 27273 if test "x$path" != "x$new_path"; then 27274 BOOT_JDK="$new_path" 27275 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27276 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27277 fi 27278 27279 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27280 27281 path="$BOOT_JDK" 27282 has_colon=`$ECHO $path | $GREP ^.:` 27283 new_path="$path" 27284 if test "x$has_colon" = x; then 27285 # Not in mixed or Windows style, start by that. 27286 new_path=`cmd //c echo $path` 27287 fi 27288 27289 27290 input_path="$new_path" 27291 # Check if we need to convert this using DOS-style short mode. If the path 27292 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27293 # take no chances and rewrite it. 27294 # Note: m4 eats our [], so we need to use [ and ] instead. 27295 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27296 if test "x$has_forbidden_chars" != x; then 27297 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27298 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27299 fi 27300 27301 27302 windows_path="$new_path" 27303 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27304 unix_path=`$CYGPATH -u "$windows_path"` 27305 new_path="$unix_path" 27306 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27307 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27308 new_path="$unix_path" 27309 fi 27310 27311 if test "x$path" != "x$new_path"; then 27312 BOOT_JDK="$new_path" 27313 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27314 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27315 fi 27316 27317 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27318 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27319 27320 else 27321 # We're on a unix platform. Hooray! :) 27322 path="$BOOT_JDK" 27323 has_space=`$ECHO "$path" | $GREP " "` 27324 if test "x$has_space" != x; then 27325 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27326 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27327 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 27328 fi 27329 27330 # Use eval to expand a potential ~ 27331 eval path="$path" 27332 if test ! -f "$path" && test ! -d "$path"; then 27333 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 27334 fi 27335 27336 if test -d "$path"; then 27337 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 27338 else 27339 dir="`$DIRNAME "$path"`" 27340 base="`$BASENAME "$path"`" 27341 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 27342 fi 27343 fi 27344 fi 27345 27346 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 27347 $as_echo_n "checking for Boot JDK... " >&6; } 27348 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 27349 $as_echo "$BOOT_JDK" >&6; } 27350 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 27351 $as_echo_n "checking Boot JDK version... " >&6; } 27352 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 27353 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 27354 $as_echo "$BOOT_JDK_VERSION" >&6; } 27355 fi # end check jdk version 27356 fi # end check javac 27357 fi # end check java 27358 fi # end check boot jdk found 27359 fi 27360 27361 27362 if test "x$BOOT_JDK_FOUND" = xno; then 27363 # Now execute the test 27364 27365 if test "x$PROGRAMFILES" != x; then 27366 VIRTUAL_DIR="$PROGRAMFILES/Java" 27367 27368 windows_path="$VIRTUAL_DIR" 27369 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27370 unix_path=`$CYGPATH -u "$windows_path"` 27371 VIRTUAL_DIR="$unix_path" 27372 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27373 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27374 VIRTUAL_DIR="$unix_path" 27375 fi 27376 27377 27378 BOOT_JDK_PREFIX="$VIRTUAL_DIR" 27379 BOOT_JDK_SUFFIX="" 27380 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 27381 if test "x$ALL_JDKS_FOUND" != x; then 27382 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 27383 27384 if test "x$BOOT_JDK_FOUND" = xno; then 27385 # Now execute the test 27386 27387 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 27388 if test -d "$BOOT_JDK"; then 27389 BOOT_JDK_FOUND=maybe 27390 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 27391 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 27392 fi 27393 27394 27395 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 27396 if test "x$BOOT_JDK_FOUND" = xmaybe; then 27397 # Do we have a bin/java? 27398 if test ! -x "$BOOT_JDK/bin/java"; then 27399 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 27400 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 27401 BOOT_JDK_FOUND=no 27402 else 27403 # Do we have a bin/javac? 27404 if test ! -x "$BOOT_JDK/bin/javac"; then 27405 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 27406 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 27407 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 27408 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 27409 BOOT_JDK_FOUND=no 27410 else 27411 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 27412 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 27413 27414 # Extra M4 quote needed to protect [] in grep expression. 27415 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 27416 if test "x$FOUND_CORRECT_VERSION" = x; then 27417 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 27418 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 27419 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 27420 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 27421 BOOT_JDK_FOUND=no 27422 else 27423 # We're done! :-) 27424 BOOT_JDK_FOUND=yes 27425 27426 # Only process if variable expands to non-empty 27427 27428 if test "x$BOOT_JDK" != x; then 27429 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27430 27431 # Input might be given as Windows format, start by converting to 27432 # unix format. 27433 path="$BOOT_JDK" 27434 new_path=`$CYGPATH -u "$path"` 27435 27436 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27437 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27438 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27439 # "foo.exe" is OK but "foo" is an error. 27440 # 27441 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27442 # It is also a way to make sure we got the proper file name for the real test later on. 27443 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27444 if test "x$test_shortpath" = x; then 27445 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27446 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27447 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 27448 fi 27449 27450 # Call helper function which possibly converts this using DOS-style short mode. 27451 # If so, the updated path is stored in $new_path. 27452 27453 input_path="$new_path" 27454 # Check if we need to convert this using DOS-style short mode. If the path 27455 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27456 # take no chances and rewrite it. 27457 # Note: m4 eats our [], so we need to use [ and ] instead. 27458 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27459 if test "x$has_forbidden_chars" != x; then 27460 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27461 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27462 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27463 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27464 # Going to short mode and back again did indeed matter. Since short mode is 27465 # case insensitive, let's make it lowercase to improve readability. 27466 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27467 # Now convert it back to Unix-style (cygpath) 27468 input_path=`$CYGPATH -u "$shortmode_path"` 27469 new_path="$input_path" 27470 fi 27471 fi 27472 27473 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27474 if test "x$test_cygdrive_prefix" = x; then 27475 # As a simple fix, exclude /usr/bin since it's not a real path. 27476 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 27477 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27478 # a path prefixed by /cygdrive for fixpath to work. 27479 new_path="$CYGWIN_ROOT_PATH$input_path" 27480 fi 27481 fi 27482 27483 27484 if test "x$path" != "x$new_path"; then 27485 BOOT_JDK="$new_path" 27486 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27487 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27488 fi 27489 27490 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27491 27492 path="$BOOT_JDK" 27493 has_colon=`$ECHO $path | $GREP ^.:` 27494 new_path="$path" 27495 if test "x$has_colon" = x; then 27496 # Not in mixed or Windows style, start by that. 27497 new_path=`cmd //c echo $path` 27498 fi 27499 27500 27501 input_path="$new_path" 27502 # Check if we need to convert this using DOS-style short mode. If the path 27503 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27504 # take no chances and rewrite it. 27505 # Note: m4 eats our [], so we need to use [ and ] instead. 27506 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27507 if test "x$has_forbidden_chars" != x; then 27508 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27509 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27510 fi 27511 27512 27513 windows_path="$new_path" 27514 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27515 unix_path=`$CYGPATH -u "$windows_path"` 27516 new_path="$unix_path" 27517 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27518 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27519 new_path="$unix_path" 27520 fi 27521 27522 if test "x$path" != "x$new_path"; then 27523 BOOT_JDK="$new_path" 27524 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27525 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27526 fi 27527 27528 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27529 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27530 27531 else 27532 # We're on a unix platform. Hooray! :) 27533 path="$BOOT_JDK" 27534 has_space=`$ECHO "$path" | $GREP " "` 27535 if test "x$has_space" != x; then 27536 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27537 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27538 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 27539 fi 27540 27541 # Use eval to expand a potential ~ 27542 eval path="$path" 27543 if test ! -f "$path" && test ! -d "$path"; then 27544 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 27545 fi 27546 27547 if test -d "$path"; then 27548 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 27549 else 27550 dir="`$DIRNAME "$path"`" 27551 base="`$BASENAME "$path"`" 27552 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 27553 fi 27554 fi 27555 fi 27556 27557 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 27558 $as_echo_n "checking for Boot JDK... " >&6; } 27559 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 27560 $as_echo "$BOOT_JDK" >&6; } 27561 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 27562 $as_echo_n "checking Boot JDK version... " >&6; } 27563 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 27564 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 27565 $as_echo "$BOOT_JDK_VERSION" >&6; } 27566 fi # end check jdk version 27567 fi # end check javac 27568 fi # end check java 27569 fi # end check boot jdk found 27570 fi 27571 27572 done 27573 fi 27574 27575 fi 27576 27577 27578 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 27579 if test "x$BOOT_JDK_FOUND" = xmaybe; then 27580 # Do we have a bin/java? 27581 if test ! -x "$BOOT_JDK/bin/java"; then 27582 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 27583 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 27584 BOOT_JDK_FOUND=no 27585 else 27586 # Do we have a bin/javac? 27587 if test ! -x "$BOOT_JDK/bin/javac"; then 27588 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 27589 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 27590 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 27591 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 27592 BOOT_JDK_FOUND=no 27593 else 27594 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 27595 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 27596 27597 # Extra M4 quote needed to protect [] in grep expression. 27598 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 27599 if test "x$FOUND_CORRECT_VERSION" = x; then 27600 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 27601 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 27602 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 27603 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 27604 BOOT_JDK_FOUND=no 27605 else 27606 # We're done! :-) 27607 BOOT_JDK_FOUND=yes 27608 27609 # Only process if variable expands to non-empty 27610 27611 if test "x$BOOT_JDK" != x; then 27612 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27613 27614 # Input might be given as Windows format, start by converting to 27615 # unix format. 27616 path="$BOOT_JDK" 27617 new_path=`$CYGPATH -u "$path"` 27618 27619 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27620 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27621 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27622 # "foo.exe" is OK but "foo" is an error. 27623 # 27624 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27625 # It is also a way to make sure we got the proper file name for the real test later on. 27626 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27627 if test "x$test_shortpath" = x; then 27628 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27629 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27630 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 27631 fi 27632 27633 # Call helper function which possibly converts this using DOS-style short mode. 27634 # If so, the updated path is stored in $new_path. 27635 27636 input_path="$new_path" 27637 # Check if we need to convert this using DOS-style short mode. If the path 27638 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27639 # take no chances and rewrite it. 27640 # Note: m4 eats our [], so we need to use [ and ] instead. 27641 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27642 if test "x$has_forbidden_chars" != x; then 27643 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27644 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27645 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27646 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27647 # Going to short mode and back again did indeed matter. Since short mode is 27648 # case insensitive, let's make it lowercase to improve readability. 27649 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27650 # Now convert it back to Unix-style (cygpath) 27651 input_path=`$CYGPATH -u "$shortmode_path"` 27652 new_path="$input_path" 27653 fi 27654 fi 27655 27656 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27657 if test "x$test_cygdrive_prefix" = x; then 27658 # As a simple fix, exclude /usr/bin since it's not a real path. 27659 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 27660 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27661 # a path prefixed by /cygdrive for fixpath to work. 27662 new_path="$CYGWIN_ROOT_PATH$input_path" 27663 fi 27664 fi 27665 27666 27667 if test "x$path" != "x$new_path"; then 27668 BOOT_JDK="$new_path" 27669 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27670 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27671 fi 27672 27673 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27674 27675 path="$BOOT_JDK" 27676 has_colon=`$ECHO $path | $GREP ^.:` 27677 new_path="$path" 27678 if test "x$has_colon" = x; then 27679 # Not in mixed or Windows style, start by that. 27680 new_path=`cmd //c echo $path` 27681 fi 27682 27683 27684 input_path="$new_path" 27685 # Check if we need to convert this using DOS-style short mode. If the path 27686 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27687 # take no chances and rewrite it. 27688 # Note: m4 eats our [], so we need to use [ and ] instead. 27689 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27690 if test "x$has_forbidden_chars" != x; then 27691 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27692 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27693 fi 27694 27695 27696 windows_path="$new_path" 27697 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27698 unix_path=`$CYGPATH -u "$windows_path"` 27699 new_path="$unix_path" 27700 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27701 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27702 new_path="$unix_path" 27703 fi 27704 27705 if test "x$path" != "x$new_path"; then 27706 BOOT_JDK="$new_path" 27707 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27708 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27709 fi 27710 27711 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27712 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27713 27714 else 27715 # We're on a unix platform. Hooray! :) 27716 path="$BOOT_JDK" 27717 has_space=`$ECHO "$path" | $GREP " "` 27718 if test "x$has_space" != x; then 27719 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27720 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27721 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 27722 fi 27723 27724 # Use eval to expand a potential ~ 27725 eval path="$path" 27726 if test ! -f "$path" && test ! -d "$path"; then 27727 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 27728 fi 27729 27730 if test -d "$path"; then 27731 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 27732 else 27733 dir="`$DIRNAME "$path"`" 27734 base="`$BASENAME "$path"`" 27735 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 27736 fi 27737 fi 27738 fi 27739 27740 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 27741 $as_echo_n "checking for Boot JDK... " >&6; } 27742 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 27743 $as_echo "$BOOT_JDK" >&6; } 27744 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 27745 $as_echo_n "checking Boot JDK version... " >&6; } 27746 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 27747 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 27748 $as_echo "$BOOT_JDK_VERSION" >&6; } 27749 fi # end check jdk version 27750 fi # end check javac 27751 fi # end check java 27752 fi # end check boot jdk found 27753 fi 27754 27755 27756 if test "x$BOOT_JDK_FOUND" = xno; then 27757 # Now execute the test 27758 27759 if test "x$ProgramFiles" != x; then 27760 VIRTUAL_DIR="$ProgramFiles/Java" 27761 27762 windows_path="$VIRTUAL_DIR" 27763 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27764 unix_path=`$CYGPATH -u "$windows_path"` 27765 VIRTUAL_DIR="$unix_path" 27766 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27767 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27768 VIRTUAL_DIR="$unix_path" 27769 fi 27770 27771 27772 BOOT_JDK_PREFIX="$VIRTUAL_DIR" 27773 BOOT_JDK_SUFFIX="" 27774 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 27775 if test "x$ALL_JDKS_FOUND" != x; then 27776 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 27777 27778 if test "x$BOOT_JDK_FOUND" = xno; then 27779 # Now execute the test 27780 27781 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 27782 if test -d "$BOOT_JDK"; then 27783 BOOT_JDK_FOUND=maybe 27784 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 27785 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 27786 fi 27787 27788 27789 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 27790 if test "x$BOOT_JDK_FOUND" = xmaybe; then 27791 # Do we have a bin/java? 27792 if test ! -x "$BOOT_JDK/bin/java"; then 27793 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 27794 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 27795 BOOT_JDK_FOUND=no 27796 else 27797 # Do we have a bin/javac? 27798 if test ! -x "$BOOT_JDK/bin/javac"; then 27799 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 27800 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 27801 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 27802 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 27803 BOOT_JDK_FOUND=no 27804 else 27805 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 27806 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 27807 27808 # Extra M4 quote needed to protect [] in grep expression. 27809 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 27810 if test "x$FOUND_CORRECT_VERSION" = x; then 27811 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 27812 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 27813 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 27814 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 27815 BOOT_JDK_FOUND=no 27816 else 27817 # We're done! :-) 27818 BOOT_JDK_FOUND=yes 27819 27820 # Only process if variable expands to non-empty 27821 27822 if test "x$BOOT_JDK" != x; then 27823 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27824 27825 # Input might be given as Windows format, start by converting to 27826 # unix format. 27827 path="$BOOT_JDK" 27828 new_path=`$CYGPATH -u "$path"` 27829 27830 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27831 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27832 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27833 # "foo.exe" is OK but "foo" is an error. 27834 # 27835 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27836 # It is also a way to make sure we got the proper file name for the real test later on. 27837 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27838 if test "x$test_shortpath" = x; then 27839 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27840 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27841 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 27842 fi 27843 27844 # Call helper function which possibly converts this using DOS-style short mode. 27845 # If so, the updated path is stored in $new_path. 27846 27847 input_path="$new_path" 27848 # Check if we need to convert this using DOS-style short mode. If the path 27849 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27850 # take no chances and rewrite it. 27851 # Note: m4 eats our [], so we need to use [ and ] instead. 27852 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27853 if test "x$has_forbidden_chars" != x; then 27854 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27855 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27856 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27857 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27858 # Going to short mode and back again did indeed matter. Since short mode is 27859 # case insensitive, let's make it lowercase to improve readability. 27860 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27861 # Now convert it back to Unix-style (cygpath) 27862 input_path=`$CYGPATH -u "$shortmode_path"` 27863 new_path="$input_path" 27864 fi 27865 fi 27866 27867 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27868 if test "x$test_cygdrive_prefix" = x; then 27869 # As a simple fix, exclude /usr/bin since it's not a real path. 27870 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 27871 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27872 # a path prefixed by /cygdrive for fixpath to work. 27873 new_path="$CYGWIN_ROOT_PATH$input_path" 27874 fi 27875 fi 27876 27877 27878 if test "x$path" != "x$new_path"; then 27879 BOOT_JDK="$new_path" 27880 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27881 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27882 fi 27883 27884 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27885 27886 path="$BOOT_JDK" 27887 has_colon=`$ECHO $path | $GREP ^.:` 27888 new_path="$path" 27889 if test "x$has_colon" = x; then 27890 # Not in mixed or Windows style, start by that. 27891 new_path=`cmd //c echo $path` 27892 fi 27893 27894 27895 input_path="$new_path" 27896 # Check if we need to convert this using DOS-style short mode. If the path 27897 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27898 # take no chances and rewrite it. 27899 # Note: m4 eats our [], so we need to use [ and ] instead. 27900 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27901 if test "x$has_forbidden_chars" != x; then 27902 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27903 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27904 fi 27905 27906 27907 windows_path="$new_path" 27908 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27909 unix_path=`$CYGPATH -u "$windows_path"` 27910 new_path="$unix_path" 27911 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27912 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27913 new_path="$unix_path" 27914 fi 27915 27916 if test "x$path" != "x$new_path"; then 27917 BOOT_JDK="$new_path" 27918 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27919 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27920 fi 27921 27922 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27923 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27924 27925 else 27926 # We're on a unix platform. Hooray! :) 27927 path="$BOOT_JDK" 27928 has_space=`$ECHO "$path" | $GREP " "` 27929 if test "x$has_space" != x; then 27930 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27931 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27932 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 27933 fi 27934 27935 # Use eval to expand a potential ~ 27936 eval path="$path" 27937 if test ! -f "$path" && test ! -d "$path"; then 27938 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 27939 fi 27940 27941 if test -d "$path"; then 27942 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 27943 else 27944 dir="`$DIRNAME "$path"`" 27945 base="`$BASENAME "$path"`" 27946 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 27947 fi 27948 fi 27949 fi 27950 27951 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 27952 $as_echo_n "checking for Boot JDK... " >&6; } 27953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 27954 $as_echo "$BOOT_JDK" >&6; } 27955 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 27956 $as_echo_n "checking Boot JDK version... " >&6; } 27957 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 27958 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 27959 $as_echo "$BOOT_JDK_VERSION" >&6; } 27960 fi # end check jdk version 27961 fi # end check javac 27962 fi # end check java 27963 fi # end check boot jdk found 27964 fi 27965 27966 done 27967 fi 27968 27969 fi 27970 27971 27972 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 27973 if test "x$BOOT_JDK_FOUND" = xmaybe; then 27974 # Do we have a bin/java? 27975 if test ! -x "$BOOT_JDK/bin/java"; then 27976 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 27977 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 27978 BOOT_JDK_FOUND=no 27979 else 27980 # Do we have a bin/javac? 27981 if test ! -x "$BOOT_JDK/bin/javac"; then 27982 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 27983 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 27984 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 27985 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 27986 BOOT_JDK_FOUND=no 27987 else 27988 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 27989 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 27990 27991 # Extra M4 quote needed to protect [] in grep expression. 27992 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 27993 if test "x$FOUND_CORRECT_VERSION" = x; then 27994 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 27995 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 27996 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 27997 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 27998 BOOT_JDK_FOUND=no 27999 else 28000 # We're done! :-) 28001 BOOT_JDK_FOUND=yes 28002 28003 # Only process if variable expands to non-empty 28004 28005 if test "x$BOOT_JDK" != x; then 28006 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28007 28008 # Input might be given as Windows format, start by converting to 28009 # unix format. 28010 path="$BOOT_JDK" 28011 new_path=`$CYGPATH -u "$path"` 28012 28013 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28014 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28015 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28016 # "foo.exe" is OK but "foo" is an error. 28017 # 28018 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28019 # It is also a way to make sure we got the proper file name for the real test later on. 28020 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28021 if test "x$test_shortpath" = x; then 28022 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28023 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28024 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28025 fi 28026 28027 # Call helper function which possibly converts this using DOS-style short mode. 28028 # If so, the updated path is stored in $new_path. 28029 28030 input_path="$new_path" 28031 # Check if we need to convert this using DOS-style short mode. If the path 28032 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28033 # take no chances and rewrite it. 28034 # Note: m4 eats our [], so we need to use [ and ] instead. 28035 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28036 if test "x$has_forbidden_chars" != x; then 28037 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28038 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28039 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28040 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28041 # Going to short mode and back again did indeed matter. Since short mode is 28042 # case insensitive, let's make it lowercase to improve readability. 28043 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28044 # Now convert it back to Unix-style (cygpath) 28045 input_path=`$CYGPATH -u "$shortmode_path"` 28046 new_path="$input_path" 28047 fi 28048 fi 28049 28050 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28051 if test "x$test_cygdrive_prefix" = x; then 28052 # As a simple fix, exclude /usr/bin since it's not a real path. 28053 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 28054 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28055 # a path prefixed by /cygdrive for fixpath to work. 28056 new_path="$CYGWIN_ROOT_PATH$input_path" 28057 fi 28058 fi 28059 28060 28061 if test "x$path" != "x$new_path"; then 28062 BOOT_JDK="$new_path" 28063 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28064 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28065 fi 28066 28067 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28068 28069 path="$BOOT_JDK" 28070 has_colon=`$ECHO $path | $GREP ^.:` 28071 new_path="$path" 28072 if test "x$has_colon" = x; then 28073 # Not in mixed or Windows style, start by that. 28074 new_path=`cmd //c echo $path` 28075 fi 28076 28077 28078 input_path="$new_path" 28079 # Check if we need to convert this using DOS-style short mode. If the path 28080 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28081 # take no chances and rewrite it. 28082 # Note: m4 eats our [], so we need to use [ and ] instead. 28083 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28084 if test "x$has_forbidden_chars" != x; then 28085 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28086 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28087 fi 28088 28089 28090 windows_path="$new_path" 28091 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28092 unix_path=`$CYGPATH -u "$windows_path"` 28093 new_path="$unix_path" 28094 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28095 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28096 new_path="$unix_path" 28097 fi 28098 28099 if test "x$path" != "x$new_path"; then 28100 BOOT_JDK="$new_path" 28101 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28102 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28103 fi 28104 28105 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28106 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28107 28108 else 28109 # We're on a unix platform. Hooray! :) 28110 path="$BOOT_JDK" 28111 has_space=`$ECHO "$path" | $GREP " "` 28112 if test "x$has_space" != x; then 28113 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28114 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28115 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28116 fi 28117 28118 # Use eval to expand a potential ~ 28119 eval path="$path" 28120 if test ! -f "$path" && test ! -d "$path"; then 28121 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28122 fi 28123 28124 if test -d "$path"; then 28125 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28126 else 28127 dir="`$DIRNAME "$path"`" 28128 base="`$BASENAME "$path"`" 28129 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28130 fi 28131 fi 28132 fi 28133 28134 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 28135 $as_echo_n "checking for Boot JDK... " >&6; } 28136 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 28137 $as_echo "$BOOT_JDK" >&6; } 28138 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 28139 $as_echo_n "checking Boot JDK version... " >&6; } 28140 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 28141 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 28142 $as_echo "$BOOT_JDK_VERSION" >&6; } 28143 fi # end check jdk version 28144 fi # end check javac 28145 fi # end check java 28146 fi # end check boot jdk found 28147 fi 28148 28149 28150 if test "x$BOOT_JDK_FOUND" = xno; then 28151 # Now execute the test 28152 28153 BOOT_JDK_PREFIX="/cygdrive/c/Program Files/Java" 28154 BOOT_JDK_SUFFIX="" 28155 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 28156 if test "x$ALL_JDKS_FOUND" != x; then 28157 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 28158 28159 if test "x$BOOT_JDK_FOUND" = xno; then 28160 # Now execute the test 28161 28162 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 28163 if test -d "$BOOT_JDK"; then 28164 BOOT_JDK_FOUND=maybe 28165 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 28166 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 28167 fi 28168 28169 28170 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 28171 if test "x$BOOT_JDK_FOUND" = xmaybe; then 28172 # Do we have a bin/java? 28173 if test ! -x "$BOOT_JDK/bin/java"; then 28174 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 28175 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 28176 BOOT_JDK_FOUND=no 28177 else 28178 # Do we have a bin/javac? 28179 if test ! -x "$BOOT_JDK/bin/javac"; then 28180 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 28181 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 28182 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 28183 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 28184 BOOT_JDK_FOUND=no 28185 else 28186 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 28187 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 28188 28189 # Extra M4 quote needed to protect [] in grep expression. 28190 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 28191 if test "x$FOUND_CORRECT_VERSION" = x; then 28192 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 28193 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 28194 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 28195 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 28196 BOOT_JDK_FOUND=no 28197 else 28198 # We're done! :-) 28199 BOOT_JDK_FOUND=yes 28200 28201 # Only process if variable expands to non-empty 28202 28203 if test "x$BOOT_JDK" != x; then 28204 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28205 28206 # Input might be given as Windows format, start by converting to 28207 # unix format. 28208 path="$BOOT_JDK" 28209 new_path=`$CYGPATH -u "$path"` 28210 28211 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28212 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28213 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28214 # "foo.exe" is OK but "foo" is an error. 28215 # 28216 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28217 # It is also a way to make sure we got the proper file name for the real test later on. 28218 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28219 if test "x$test_shortpath" = x; then 28220 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28221 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28222 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28223 fi 28224 28225 # Call helper function which possibly converts this using DOS-style short mode. 28226 # If so, the updated path is stored in $new_path. 28227 28228 input_path="$new_path" 28229 # Check if we need to convert this using DOS-style short mode. If the path 28230 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28231 # take no chances and rewrite it. 28232 # Note: m4 eats our [], so we need to use [ and ] instead. 28233 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28234 if test "x$has_forbidden_chars" != x; then 28235 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28236 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28237 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28238 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28239 # Going to short mode and back again did indeed matter. Since short mode is 28240 # case insensitive, let's make it lowercase to improve readability. 28241 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28242 # Now convert it back to Unix-style (cygpath) 28243 input_path=`$CYGPATH -u "$shortmode_path"` 28244 new_path="$input_path" 28245 fi 28246 fi 28247 28248 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28249 if test "x$test_cygdrive_prefix" = x; then 28250 # As a simple fix, exclude /usr/bin since it's not a real path. 28251 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 28252 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28253 # a path prefixed by /cygdrive for fixpath to work. 28254 new_path="$CYGWIN_ROOT_PATH$input_path" 28255 fi 28256 fi 28257 28258 28259 if test "x$path" != "x$new_path"; then 28260 BOOT_JDK="$new_path" 28261 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28262 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28263 fi 28264 28265 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28266 28267 path="$BOOT_JDK" 28268 has_colon=`$ECHO $path | $GREP ^.:` 28269 new_path="$path" 28270 if test "x$has_colon" = x; then 28271 # Not in mixed or Windows style, start by that. 28272 new_path=`cmd //c echo $path` 28273 fi 28274 28275 28276 input_path="$new_path" 28277 # Check if we need to convert this using DOS-style short mode. If the path 28278 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28279 # take no chances and rewrite it. 28280 # Note: m4 eats our [], so we need to use [ and ] instead. 28281 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28282 if test "x$has_forbidden_chars" != x; then 28283 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28284 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28285 fi 28286 28287 28288 windows_path="$new_path" 28289 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28290 unix_path=`$CYGPATH -u "$windows_path"` 28291 new_path="$unix_path" 28292 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28293 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28294 new_path="$unix_path" 28295 fi 28296 28297 if test "x$path" != "x$new_path"; then 28298 BOOT_JDK="$new_path" 28299 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28300 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28301 fi 28302 28303 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28304 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28305 28306 else 28307 # We're on a unix platform. Hooray! :) 28308 path="$BOOT_JDK" 28309 has_space=`$ECHO "$path" | $GREP " "` 28310 if test "x$has_space" != x; then 28311 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28312 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28313 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28314 fi 28315 28316 # Use eval to expand a potential ~ 28317 eval path="$path" 28318 if test ! -f "$path" && test ! -d "$path"; then 28319 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28320 fi 28321 28322 if test -d "$path"; then 28323 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28324 else 28325 dir="`$DIRNAME "$path"`" 28326 base="`$BASENAME "$path"`" 28327 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28328 fi 28329 fi 28330 fi 28331 28332 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 28333 $as_echo_n "checking for Boot JDK... " >&6; } 28334 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 28335 $as_echo "$BOOT_JDK" >&6; } 28336 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 28337 $as_echo_n "checking Boot JDK version... " >&6; } 28338 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 28339 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 28340 $as_echo "$BOOT_JDK_VERSION" >&6; } 28341 fi # end check jdk version 28342 fi # end check javac 28343 fi # end check java 28344 fi # end check boot jdk found 28345 fi 28346 28347 done 28348 fi 28349 28350 28351 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 28352 if test "x$BOOT_JDK_FOUND" = xmaybe; then 28353 # Do we have a bin/java? 28354 if test ! -x "$BOOT_JDK/bin/java"; then 28355 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 28356 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 28357 BOOT_JDK_FOUND=no 28358 else 28359 # Do we have a bin/javac? 28360 if test ! -x "$BOOT_JDK/bin/javac"; then 28361 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 28362 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 28363 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 28364 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 28365 BOOT_JDK_FOUND=no 28366 else 28367 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 28368 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 28369 28370 # Extra M4 quote needed to protect [] in grep expression. 28371 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 28372 if test "x$FOUND_CORRECT_VERSION" = x; then 28373 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 28374 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 28375 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 28376 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 28377 BOOT_JDK_FOUND=no 28378 else 28379 # We're done! :-) 28380 BOOT_JDK_FOUND=yes 28381 28382 # Only process if variable expands to non-empty 28383 28384 if test "x$BOOT_JDK" != x; then 28385 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28386 28387 # Input might be given as Windows format, start by converting to 28388 # unix format. 28389 path="$BOOT_JDK" 28390 new_path=`$CYGPATH -u "$path"` 28391 28392 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28393 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28394 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28395 # "foo.exe" is OK but "foo" is an error. 28396 # 28397 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28398 # It is also a way to make sure we got the proper file name for the real test later on. 28399 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28400 if test "x$test_shortpath" = x; then 28401 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28402 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28403 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28404 fi 28405 28406 # Call helper function which possibly converts this using DOS-style short mode. 28407 # If so, the updated path is stored in $new_path. 28408 28409 input_path="$new_path" 28410 # Check if we need to convert this using DOS-style short mode. If the path 28411 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28412 # take no chances and rewrite it. 28413 # Note: m4 eats our [], so we need to use [ and ] instead. 28414 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28415 if test "x$has_forbidden_chars" != x; then 28416 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28417 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28418 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28419 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28420 # Going to short mode and back again did indeed matter. Since short mode is 28421 # case insensitive, let's make it lowercase to improve readability. 28422 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28423 # Now convert it back to Unix-style (cygpath) 28424 input_path=`$CYGPATH -u "$shortmode_path"` 28425 new_path="$input_path" 28426 fi 28427 fi 28428 28429 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28430 if test "x$test_cygdrive_prefix" = x; then 28431 # As a simple fix, exclude /usr/bin since it's not a real path. 28432 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 28433 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28434 # a path prefixed by /cygdrive for fixpath to work. 28435 new_path="$CYGWIN_ROOT_PATH$input_path" 28436 fi 28437 fi 28438 28439 28440 if test "x$path" != "x$new_path"; then 28441 BOOT_JDK="$new_path" 28442 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28443 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28444 fi 28445 28446 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28447 28448 path="$BOOT_JDK" 28449 has_colon=`$ECHO $path | $GREP ^.:` 28450 new_path="$path" 28451 if test "x$has_colon" = x; then 28452 # Not in mixed or Windows style, start by that. 28453 new_path=`cmd //c echo $path` 28454 fi 28455 28456 28457 input_path="$new_path" 28458 # Check if we need to convert this using DOS-style short mode. If the path 28459 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28460 # take no chances and rewrite it. 28461 # Note: m4 eats our [], so we need to use [ and ] instead. 28462 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28463 if test "x$has_forbidden_chars" != x; then 28464 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28465 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28466 fi 28467 28468 28469 windows_path="$new_path" 28470 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28471 unix_path=`$CYGPATH -u "$windows_path"` 28472 new_path="$unix_path" 28473 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28474 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28475 new_path="$unix_path" 28476 fi 28477 28478 if test "x$path" != "x$new_path"; then 28479 BOOT_JDK="$new_path" 28480 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28481 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28482 fi 28483 28484 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28485 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28486 28487 else 28488 # We're on a unix platform. Hooray! :) 28489 path="$BOOT_JDK" 28490 has_space=`$ECHO "$path" | $GREP " "` 28491 if test "x$has_space" != x; then 28492 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28493 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28494 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28495 fi 28496 28497 # Use eval to expand a potential ~ 28498 eval path="$path" 28499 if test ! -f "$path" && test ! -d "$path"; then 28500 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28501 fi 28502 28503 if test -d "$path"; then 28504 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28505 else 28506 dir="`$DIRNAME "$path"`" 28507 base="`$BASENAME "$path"`" 28508 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28509 fi 28510 fi 28511 fi 28512 28513 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 28514 $as_echo_n "checking for Boot JDK... " >&6; } 28515 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 28516 $as_echo "$BOOT_JDK" >&6; } 28517 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 28518 $as_echo_n "checking Boot JDK version... " >&6; } 28519 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 28520 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 28521 $as_echo "$BOOT_JDK_VERSION" >&6; } 28522 fi # end check jdk version 28523 fi # end check javac 28524 fi # end check java 28525 fi # end check boot jdk found 28526 fi 28527 28528 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 28529 28530 if test "x$BOOT_JDK_FOUND" = xno; then 28531 # Now execute the test 28532 28533 BOOT_JDK_PREFIX="/Library/Java/JavaVirtualMachines" 28534 BOOT_JDK_SUFFIX="/Contents/Home" 28535 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 28536 if test "x$ALL_JDKS_FOUND" != x; then 28537 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 28538 28539 if test "x$BOOT_JDK_FOUND" = xno; then 28540 # Now execute the test 28541 28542 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 28543 if test -d "$BOOT_JDK"; then 28544 BOOT_JDK_FOUND=maybe 28545 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 28546 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 28547 fi 28548 28549 28550 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 28551 if test "x$BOOT_JDK_FOUND" = xmaybe; then 28552 # Do we have a bin/java? 28553 if test ! -x "$BOOT_JDK/bin/java"; then 28554 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 28555 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 28556 BOOT_JDK_FOUND=no 28557 else 28558 # Do we have a bin/javac? 28559 if test ! -x "$BOOT_JDK/bin/javac"; then 28560 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 28561 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 28562 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 28563 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 28564 BOOT_JDK_FOUND=no 28565 else 28566 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 28567 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 28568 28569 # Extra M4 quote needed to protect [] in grep expression. 28570 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 28571 if test "x$FOUND_CORRECT_VERSION" = x; then 28572 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 28573 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 28574 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 28575 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 28576 BOOT_JDK_FOUND=no 28577 else 28578 # We're done! :-) 28579 BOOT_JDK_FOUND=yes 28580 28581 # Only process if variable expands to non-empty 28582 28583 if test "x$BOOT_JDK" != x; then 28584 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28585 28586 # Input might be given as Windows format, start by converting to 28587 # unix format. 28588 path="$BOOT_JDK" 28589 new_path=`$CYGPATH -u "$path"` 28590 28591 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28592 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28593 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28594 # "foo.exe" is OK but "foo" is an error. 28595 # 28596 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28597 # It is also a way to make sure we got the proper file name for the real test later on. 28598 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28599 if test "x$test_shortpath" = x; then 28600 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28601 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28602 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28603 fi 28604 28605 # Call helper function which possibly converts this using DOS-style short mode. 28606 # If so, the updated path is stored in $new_path. 28607 28608 input_path="$new_path" 28609 # Check if we need to convert this using DOS-style short mode. If the path 28610 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28611 # take no chances and rewrite it. 28612 # Note: m4 eats our [], so we need to use [ and ] instead. 28613 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28614 if test "x$has_forbidden_chars" != x; then 28615 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28616 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28617 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28618 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28619 # Going to short mode and back again did indeed matter. Since short mode is 28620 # case insensitive, let's make it lowercase to improve readability. 28621 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28622 # Now convert it back to Unix-style (cygpath) 28623 input_path=`$CYGPATH -u "$shortmode_path"` 28624 new_path="$input_path" 28625 fi 28626 fi 28627 28628 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28629 if test "x$test_cygdrive_prefix" = x; then 28630 # As a simple fix, exclude /usr/bin since it's not a real path. 28631 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 28632 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28633 # a path prefixed by /cygdrive for fixpath to work. 28634 new_path="$CYGWIN_ROOT_PATH$input_path" 28635 fi 28636 fi 28637 28638 28639 if test "x$path" != "x$new_path"; then 28640 BOOT_JDK="$new_path" 28641 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28642 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28643 fi 28644 28645 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28646 28647 path="$BOOT_JDK" 28648 has_colon=`$ECHO $path | $GREP ^.:` 28649 new_path="$path" 28650 if test "x$has_colon" = x; then 28651 # Not in mixed or Windows style, start by that. 28652 new_path=`cmd //c echo $path` 28653 fi 28654 28655 28656 input_path="$new_path" 28657 # Check if we need to convert this using DOS-style short mode. If the path 28658 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28659 # take no chances and rewrite it. 28660 # Note: m4 eats our [], so we need to use [ and ] instead. 28661 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28662 if test "x$has_forbidden_chars" != x; then 28663 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28664 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28665 fi 28666 28667 28668 windows_path="$new_path" 28669 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28670 unix_path=`$CYGPATH -u "$windows_path"` 28671 new_path="$unix_path" 28672 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28673 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28674 new_path="$unix_path" 28675 fi 28676 28677 if test "x$path" != "x$new_path"; then 28678 BOOT_JDK="$new_path" 28679 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28680 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28681 fi 28682 28683 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28684 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28685 28686 else 28687 # We're on a unix platform. Hooray! :) 28688 path="$BOOT_JDK" 28689 has_space=`$ECHO "$path" | $GREP " "` 28690 if test "x$has_space" != x; then 28691 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28692 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28693 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28694 fi 28695 28696 # Use eval to expand a potential ~ 28697 eval path="$path" 28698 if test ! -f "$path" && test ! -d "$path"; then 28699 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28700 fi 28701 28702 if test -d "$path"; then 28703 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28704 else 28705 dir="`$DIRNAME "$path"`" 28706 base="`$BASENAME "$path"`" 28707 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28708 fi 28709 fi 28710 fi 28711 28712 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 28713 $as_echo_n "checking for Boot JDK... " >&6; } 28714 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 28715 $as_echo "$BOOT_JDK" >&6; } 28716 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 28717 $as_echo_n "checking Boot JDK version... " >&6; } 28718 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 28719 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 28720 $as_echo "$BOOT_JDK_VERSION" >&6; } 28721 fi # end check jdk version 28722 fi # end check javac 28723 fi # end check java 28724 fi # end check boot jdk found 28725 fi 28726 28727 done 28728 fi 28729 28730 28731 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 28732 if test "x$BOOT_JDK_FOUND" = xmaybe; then 28733 # Do we have a bin/java? 28734 if test ! -x "$BOOT_JDK/bin/java"; then 28735 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 28736 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 28737 BOOT_JDK_FOUND=no 28738 else 28739 # Do we have a bin/javac? 28740 if test ! -x "$BOOT_JDK/bin/javac"; then 28741 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 28742 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 28743 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 28744 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 28745 BOOT_JDK_FOUND=no 28746 else 28747 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 28748 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 28749 28750 # Extra M4 quote needed to protect [] in grep expression. 28751 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 28752 if test "x$FOUND_CORRECT_VERSION" = x; then 28753 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 28754 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 28755 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 28756 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 28757 BOOT_JDK_FOUND=no 28758 else 28759 # We're done! :-) 28760 BOOT_JDK_FOUND=yes 28761 28762 # Only process if variable expands to non-empty 28763 28764 if test "x$BOOT_JDK" != x; then 28765 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28766 28767 # Input might be given as Windows format, start by converting to 28768 # unix format. 28769 path="$BOOT_JDK" 28770 new_path=`$CYGPATH -u "$path"` 28771 28772 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28773 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28774 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28775 # "foo.exe" is OK but "foo" is an error. 28776 # 28777 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28778 # It is also a way to make sure we got the proper file name for the real test later on. 28779 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28780 if test "x$test_shortpath" = x; then 28781 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28782 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28783 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28784 fi 28785 28786 # Call helper function which possibly converts this using DOS-style short mode. 28787 # If so, the updated path is stored in $new_path. 28788 28789 input_path="$new_path" 28790 # Check if we need to convert this using DOS-style short mode. If the path 28791 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28792 # take no chances and rewrite it. 28793 # Note: m4 eats our [], so we need to use [ and ] instead. 28794 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28795 if test "x$has_forbidden_chars" != x; then 28796 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28797 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28798 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28799 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28800 # Going to short mode and back again did indeed matter. Since short mode is 28801 # case insensitive, let's make it lowercase to improve readability. 28802 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28803 # Now convert it back to Unix-style (cygpath) 28804 input_path=`$CYGPATH -u "$shortmode_path"` 28805 new_path="$input_path" 28806 fi 28807 fi 28808 28809 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28810 if test "x$test_cygdrive_prefix" = x; then 28811 # As a simple fix, exclude /usr/bin since it's not a real path. 28812 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 28813 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28814 # a path prefixed by /cygdrive for fixpath to work. 28815 new_path="$CYGWIN_ROOT_PATH$input_path" 28816 fi 28817 fi 28818 28819 28820 if test "x$path" != "x$new_path"; then 28821 BOOT_JDK="$new_path" 28822 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28823 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28824 fi 28825 28826 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28827 28828 path="$BOOT_JDK" 28829 has_colon=`$ECHO $path | $GREP ^.:` 28830 new_path="$path" 28831 if test "x$has_colon" = x; then 28832 # Not in mixed or Windows style, start by that. 28833 new_path=`cmd //c echo $path` 28834 fi 28835 28836 28837 input_path="$new_path" 28838 # Check if we need to convert this using DOS-style short mode. If the path 28839 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28840 # take no chances and rewrite it. 28841 # Note: m4 eats our [], so we need to use [ and ] instead. 28842 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28843 if test "x$has_forbidden_chars" != x; then 28844 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28845 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28846 fi 28847 28848 28849 windows_path="$new_path" 28850 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28851 unix_path=`$CYGPATH -u "$windows_path"` 28852 new_path="$unix_path" 28853 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28854 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28855 new_path="$unix_path" 28856 fi 28857 28858 if test "x$path" != "x$new_path"; then 28859 BOOT_JDK="$new_path" 28860 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28861 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28862 fi 28863 28864 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28865 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28866 28867 else 28868 # We're on a unix platform. Hooray! :) 28869 path="$BOOT_JDK" 28870 has_space=`$ECHO "$path" | $GREP " "` 28871 if test "x$has_space" != x; then 28872 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28873 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28874 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28875 fi 28876 28877 # Use eval to expand a potential ~ 28878 eval path="$path" 28879 if test ! -f "$path" && test ! -d "$path"; then 28880 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28881 fi 28882 28883 if test -d "$path"; then 28884 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28885 else 28886 dir="`$DIRNAME "$path"`" 28887 base="`$BASENAME "$path"`" 28888 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28889 fi 28890 fi 28891 fi 28892 28893 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 28894 $as_echo_n "checking for Boot JDK... " >&6; } 28895 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 28896 $as_echo "$BOOT_JDK" >&6; } 28897 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 28898 $as_echo_n "checking Boot JDK version... " >&6; } 28899 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 28900 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 28901 $as_echo "$BOOT_JDK_VERSION" >&6; } 28902 fi # end check jdk version 28903 fi # end check javac 28904 fi # end check java 28905 fi # end check boot jdk found 28906 fi 28907 28908 28909 if test "x$BOOT_JDK_FOUND" = xno; then 28910 # Now execute the test 28911 28912 BOOT_JDK_PREFIX="/System/Library/Java/JavaVirtualMachines" 28913 BOOT_JDK_SUFFIX="/Contents/Home" 28914 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 28915 if test "x$ALL_JDKS_FOUND" != x; then 28916 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 28917 28918 if test "x$BOOT_JDK_FOUND" = xno; then 28919 # Now execute the test 28920 28921 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 28922 if test -d "$BOOT_JDK"; then 28923 BOOT_JDK_FOUND=maybe 28924 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 28925 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 28926 fi 28927 28928 28929 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 28930 if test "x$BOOT_JDK_FOUND" = xmaybe; then 28931 # Do we have a bin/java? 28932 if test ! -x "$BOOT_JDK/bin/java"; then 28933 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 28934 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 28935 BOOT_JDK_FOUND=no 28936 else 28937 # Do we have a bin/javac? 28938 if test ! -x "$BOOT_JDK/bin/javac"; then 28939 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 28940 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 28941 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 28942 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 28943 BOOT_JDK_FOUND=no 28944 else 28945 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 28946 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 28947 28948 # Extra M4 quote needed to protect [] in grep expression. 28949 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 28950 if test "x$FOUND_CORRECT_VERSION" = x; then 28951 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 28952 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 28953 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 28954 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 28955 BOOT_JDK_FOUND=no 28956 else 28957 # We're done! :-) 28958 BOOT_JDK_FOUND=yes 28959 28960 # Only process if variable expands to non-empty 28961 28962 if test "x$BOOT_JDK" != x; then 28963 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28964 28965 # Input might be given as Windows format, start by converting to 28966 # unix format. 28967 path="$BOOT_JDK" 28968 new_path=`$CYGPATH -u "$path"` 28969 28970 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28971 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28972 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28973 # "foo.exe" is OK but "foo" is an error. 28974 # 28975 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28976 # It is also a way to make sure we got the proper file name for the real test later on. 28977 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28978 if test "x$test_shortpath" = x; then 28979 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28980 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28981 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28982 fi 28983 28984 # Call helper function which possibly converts this using DOS-style short mode. 28985 # If so, the updated path is stored in $new_path. 28986 28987 input_path="$new_path" 28988 # Check if we need to convert this using DOS-style short mode. If the path 28989 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28990 # take no chances and rewrite it. 28991 # Note: m4 eats our [], so we need to use [ and ] instead. 28992 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28993 if test "x$has_forbidden_chars" != x; then 28994 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28995 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28996 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28997 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28998 # Going to short mode and back again did indeed matter. Since short mode is 28999 # case insensitive, let's make it lowercase to improve readability. 29000 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29001 # Now convert it back to Unix-style (cygpath) 29002 input_path=`$CYGPATH -u "$shortmode_path"` 29003 new_path="$input_path" 29004 fi 29005 fi 29006 29007 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 29008 if test "x$test_cygdrive_prefix" = x; then 29009 # As a simple fix, exclude /usr/bin since it's not a real path. 29010 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 29011 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 29012 # a path prefixed by /cygdrive for fixpath to work. 29013 new_path="$CYGWIN_ROOT_PATH$input_path" 29014 fi 29015 fi 29016 29017 29018 if test "x$path" != "x$new_path"; then 29019 BOOT_JDK="$new_path" 29020 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29021 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29022 fi 29023 29024 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29025 29026 path="$BOOT_JDK" 29027 has_colon=`$ECHO $path | $GREP ^.:` 29028 new_path="$path" 29029 if test "x$has_colon" = x; then 29030 # Not in mixed or Windows style, start by that. 29031 new_path=`cmd //c echo $path` 29032 fi 29033 29034 29035 input_path="$new_path" 29036 # Check if we need to convert this using DOS-style short mode. If the path 29037 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29038 # take no chances and rewrite it. 29039 # Note: m4 eats our [], so we need to use [ and ] instead. 29040 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 29041 if test "x$has_forbidden_chars" != x; then 29042 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29043 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29044 fi 29045 29046 29047 windows_path="$new_path" 29048 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29049 unix_path=`$CYGPATH -u "$windows_path"` 29050 new_path="$unix_path" 29051 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29052 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 29053 new_path="$unix_path" 29054 fi 29055 29056 if test "x$path" != "x$new_path"; then 29057 BOOT_JDK="$new_path" 29058 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29059 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29060 fi 29061 29062 # Save the first 10 bytes of this path to the storage, so fixpath can work. 29063 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 29064 29065 else 29066 # We're on a unix platform. Hooray! :) 29067 path="$BOOT_JDK" 29068 has_space=`$ECHO "$path" | $GREP " "` 29069 if test "x$has_space" != x; then 29070 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29071 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29072 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 29073 fi 29074 29075 # Use eval to expand a potential ~ 29076 eval path="$path" 29077 if test ! -f "$path" && test ! -d "$path"; then 29078 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 29079 fi 29080 29081 if test -d "$path"; then 29082 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 29083 else 29084 dir="`$DIRNAME "$path"`" 29085 base="`$BASENAME "$path"`" 29086 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 29087 fi 29088 fi 29089 fi 29090 29091 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 29092 $as_echo_n "checking for Boot JDK... " >&6; } 29093 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 29094 $as_echo "$BOOT_JDK" >&6; } 29095 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 29096 $as_echo_n "checking Boot JDK version... " >&6; } 29097 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 29098 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 29099 $as_echo "$BOOT_JDK_VERSION" >&6; } 29100 fi # end check jdk version 29101 fi # end check javac 29102 fi # end check java 29103 fi # end check boot jdk found 29104 fi 29105 29106 done 29107 fi 29108 29109 29110 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 29111 if test "x$BOOT_JDK_FOUND" = xmaybe; then 29112 # Do we have a bin/java? 29113 if test ! -x "$BOOT_JDK/bin/java"; then 29114 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 29115 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 29116 BOOT_JDK_FOUND=no 29117 else 29118 # Do we have a bin/javac? 29119 if test ! -x "$BOOT_JDK/bin/javac"; then 29120 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 29121 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 29122 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 29123 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 29124 BOOT_JDK_FOUND=no 29125 else 29126 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 29127 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 29128 29129 # Extra M4 quote needed to protect [] in grep expression. 29130 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 29131 if test "x$FOUND_CORRECT_VERSION" = x; then 29132 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 29133 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 29134 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 29135 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 29136 BOOT_JDK_FOUND=no 29137 else 29138 # We're done! :-) 29139 BOOT_JDK_FOUND=yes 29140 29141 # Only process if variable expands to non-empty 29142 29143 if test "x$BOOT_JDK" != x; then 29144 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29145 29146 # Input might be given as Windows format, start by converting to 29147 # unix format. 29148 path="$BOOT_JDK" 29149 new_path=`$CYGPATH -u "$path"` 29150 29151 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 29152 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 29153 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 29154 # "foo.exe" is OK but "foo" is an error. 29155 # 29156 # This test is therefore slightly more accurate than "test -f" to check for file precense. 29157 # It is also a way to make sure we got the proper file name for the real test later on. 29158 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 29159 if test "x$test_shortpath" = x; then 29160 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29161 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29162 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 29163 fi 29164 29165 # Call helper function which possibly converts this using DOS-style short mode. 29166 # If so, the updated path is stored in $new_path. 29167 29168 input_path="$new_path" 29169 # Check if we need to convert this using DOS-style short mode. If the path 29170 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29171 # take no chances and rewrite it. 29172 # Note: m4 eats our [], so we need to use [ and ] instead. 29173 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 29174 if test "x$has_forbidden_chars" != x; then 29175 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29176 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 29177 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 29178 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 29179 # Going to short mode and back again did indeed matter. Since short mode is 29180 # case insensitive, let's make it lowercase to improve readability. 29181 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29182 # Now convert it back to Unix-style (cygpath) 29183 input_path=`$CYGPATH -u "$shortmode_path"` 29184 new_path="$input_path" 29185 fi 29186 fi 29187 29188 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 29189 if test "x$test_cygdrive_prefix" = x; then 29190 # As a simple fix, exclude /usr/bin since it's not a real path. 29191 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 29192 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 29193 # a path prefixed by /cygdrive for fixpath to work. 29194 new_path="$CYGWIN_ROOT_PATH$input_path" 29195 fi 29196 fi 29197 29198 29199 if test "x$path" != "x$new_path"; then 29200 BOOT_JDK="$new_path" 29201 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29202 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29203 fi 29204 29205 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29206 29207 path="$BOOT_JDK" 29208 has_colon=`$ECHO $path | $GREP ^.:` 29209 new_path="$path" 29210 if test "x$has_colon" = x; then 29211 # Not in mixed or Windows style, start by that. 29212 new_path=`cmd //c echo $path` 29213 fi 29214 29215 29216 input_path="$new_path" 29217 # Check if we need to convert this using DOS-style short mode. If the path 29218 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29219 # take no chances and rewrite it. 29220 # Note: m4 eats our [], so we need to use [ and ] instead. 29221 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 29222 if test "x$has_forbidden_chars" != x; then 29223 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29224 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29225 fi 29226 29227 29228 windows_path="$new_path" 29229 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29230 unix_path=`$CYGPATH -u "$windows_path"` 29231 new_path="$unix_path" 29232 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29233 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 29234 new_path="$unix_path" 29235 fi 29236 29237 if test "x$path" != "x$new_path"; then 29238 BOOT_JDK="$new_path" 29239 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29240 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29241 fi 29242 29243 # Save the first 10 bytes of this path to the storage, so fixpath can work. 29244 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 29245 29246 else 29247 # We're on a unix platform. Hooray! :) 29248 path="$BOOT_JDK" 29249 has_space=`$ECHO "$path" | $GREP " "` 29250 if test "x$has_space" != x; then 29251 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29252 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29253 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 29254 fi 29255 29256 # Use eval to expand a potential ~ 29257 eval path="$path" 29258 if test ! -f "$path" && test ! -d "$path"; then 29259 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 29260 fi 29261 29262 if test -d "$path"; then 29263 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 29264 else 29265 dir="`$DIRNAME "$path"`" 29266 base="`$BASENAME "$path"`" 29267 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 29268 fi 29269 fi 29270 fi 29271 29272 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 29273 $as_echo_n "checking for Boot JDK... " >&6; } 29274 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 29275 $as_echo "$BOOT_JDK" >&6; } 29276 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 29277 $as_echo_n "checking Boot JDK version... " >&6; } 29278 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 29279 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 29280 $as_echo "$BOOT_JDK_VERSION" >&6; } 29281 fi # end check jdk version 29282 fi # end check javac 29283 fi # end check java 29284 fi # end check boot jdk found 29285 fi 29286 29287 elif test "x$OPENJDK_TARGET_OS" = xlinux; then 29288 29289 if test "x$BOOT_JDK_FOUND" = xno; then 29290 # Now execute the test 29291 29292 BOOT_JDK_PREFIX="/usr/lib/jvm" 29293 BOOT_JDK_SUFFIX="" 29294 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 29295 if test "x$ALL_JDKS_FOUND" != x; then 29296 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 29297 29298 if test "x$BOOT_JDK_FOUND" = xno; then 29299 # Now execute the test 29300 29301 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 29302 if test -d "$BOOT_JDK"; then 29303 BOOT_JDK_FOUND=maybe 29304 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 29305 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 29306 fi 29307 29308 29309 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 29310 if test "x$BOOT_JDK_FOUND" = xmaybe; then 29311 # Do we have a bin/java? 29312 if test ! -x "$BOOT_JDK/bin/java"; then 29313 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 29314 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 29315 BOOT_JDK_FOUND=no 29316 else 29317 # Do we have a bin/javac? 29318 if test ! -x "$BOOT_JDK/bin/javac"; then 29319 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 29320 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 29321 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 29322 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 29323 BOOT_JDK_FOUND=no 29324 else 29325 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 29326 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 29327 29328 # Extra M4 quote needed to protect [] in grep expression. 29329 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 29330 if test "x$FOUND_CORRECT_VERSION" = x; then 29331 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 29332 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 29333 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 29334 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 29335 BOOT_JDK_FOUND=no 29336 else 29337 # We're done! :-) 29338 BOOT_JDK_FOUND=yes 29339 29340 # Only process if variable expands to non-empty 29341 29342 if test "x$BOOT_JDK" != x; then 29343 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29344 29345 # Input might be given as Windows format, start by converting to 29346 # unix format. 29347 path="$BOOT_JDK" 29348 new_path=`$CYGPATH -u "$path"` 29349 29350 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 29351 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 29352 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 29353 # "foo.exe" is OK but "foo" is an error. 29354 # 29355 # This test is therefore slightly more accurate than "test -f" to check for file precense. 29356 # It is also a way to make sure we got the proper file name for the real test later on. 29357 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 29358 if test "x$test_shortpath" = x; then 29359 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29360 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29361 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 29362 fi 29363 29364 # Call helper function which possibly converts this using DOS-style short mode. 29365 # If so, the updated path is stored in $new_path. 29366 29367 input_path="$new_path" 29368 # Check if we need to convert this using DOS-style short mode. If the path 29369 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29370 # take no chances and rewrite it. 29371 # Note: m4 eats our [], so we need to use [ and ] instead. 29372 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 29373 if test "x$has_forbidden_chars" != x; then 29374 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29375 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 29376 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 29377 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 29378 # Going to short mode and back again did indeed matter. Since short mode is 29379 # case insensitive, let's make it lowercase to improve readability. 29380 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29381 # Now convert it back to Unix-style (cygpath) 29382 input_path=`$CYGPATH -u "$shortmode_path"` 29383 new_path="$input_path" 29384 fi 29385 fi 29386 29387 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 29388 if test "x$test_cygdrive_prefix" = x; then 29389 # As a simple fix, exclude /usr/bin since it's not a real path. 29390 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 29391 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 29392 # a path prefixed by /cygdrive for fixpath to work. 29393 new_path="$CYGWIN_ROOT_PATH$input_path" 29394 fi 29395 fi 29396 29397 29398 if test "x$path" != "x$new_path"; then 29399 BOOT_JDK="$new_path" 29400 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29401 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29402 fi 29403 29404 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29405 29406 path="$BOOT_JDK" 29407 has_colon=`$ECHO $path | $GREP ^.:` 29408 new_path="$path" 29409 if test "x$has_colon" = x; then 29410 # Not in mixed or Windows style, start by that. 29411 new_path=`cmd //c echo $path` 29412 fi 29413 29414 29415 input_path="$new_path" 29416 # Check if we need to convert this using DOS-style short mode. If the path 29417 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29418 # take no chances and rewrite it. 29419 # Note: m4 eats our [], so we need to use [ and ] instead. 29420 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 29421 if test "x$has_forbidden_chars" != x; then 29422 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29423 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29424 fi 29425 29426 29427 windows_path="$new_path" 29428 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29429 unix_path=`$CYGPATH -u "$windows_path"` 29430 new_path="$unix_path" 29431 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29432 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 29433 new_path="$unix_path" 29434 fi 29435 29436 if test "x$path" != "x$new_path"; then 29437 BOOT_JDK="$new_path" 29438 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29439 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29440 fi 29441 29442 # Save the first 10 bytes of this path to the storage, so fixpath can work. 29443 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 29444 29445 else 29446 # We're on a unix platform. Hooray! :) 29447 path="$BOOT_JDK" 29448 has_space=`$ECHO "$path" | $GREP " "` 29449 if test "x$has_space" != x; then 29450 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29451 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29452 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 29453 fi 29454 29455 # Use eval to expand a potential ~ 29456 eval path="$path" 29457 if test ! -f "$path" && test ! -d "$path"; then 29458 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 29459 fi 29460 29461 if test -d "$path"; then 29462 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 29463 else 29464 dir="`$DIRNAME "$path"`" 29465 base="`$BASENAME "$path"`" 29466 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 29467 fi 29468 fi 29469 fi 29470 29471 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 29472 $as_echo_n "checking for Boot JDK... " >&6; } 29473 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 29474 $as_echo "$BOOT_JDK" >&6; } 29475 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 29476 $as_echo_n "checking Boot JDK version... " >&6; } 29477 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 29478 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 29479 $as_echo "$BOOT_JDK_VERSION" >&6; } 29480 fi # end check jdk version 29481 fi # end check javac 29482 fi # end check java 29483 fi # end check boot jdk found 29484 fi 29485 29486 done 29487 fi 29488 29489 29490 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 29491 if test "x$BOOT_JDK_FOUND" = xmaybe; then 29492 # Do we have a bin/java? 29493 if test ! -x "$BOOT_JDK/bin/java"; then 29494 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 29495 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 29496 BOOT_JDK_FOUND=no 29497 else 29498 # Do we have a bin/javac? 29499 if test ! -x "$BOOT_JDK/bin/javac"; then 29500 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 29501 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 29502 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 29503 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 29504 BOOT_JDK_FOUND=no 29505 else 29506 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 29507 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 29508 29509 # Extra M4 quote needed to protect [] in grep expression. 29510 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 29511 if test "x$FOUND_CORRECT_VERSION" = x; then 29512 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 29513 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 29514 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 29515 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 29516 BOOT_JDK_FOUND=no 29517 else 29518 # We're done! :-) 29519 BOOT_JDK_FOUND=yes 29520 29521 # Only process if variable expands to non-empty 29522 29523 if test "x$BOOT_JDK" != x; then 29524 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29525 29526 # Input might be given as Windows format, start by converting to 29527 # unix format. 29528 path="$BOOT_JDK" 29529 new_path=`$CYGPATH -u "$path"` 29530 29531 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 29532 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 29533 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 29534 # "foo.exe" is OK but "foo" is an error. 29535 # 29536 # This test is therefore slightly more accurate than "test -f" to check for file precense. 29537 # It is also a way to make sure we got the proper file name for the real test later on. 29538 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 29539 if test "x$test_shortpath" = x; then 29540 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29541 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29542 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 29543 fi 29544 29545 # Call helper function which possibly converts this using DOS-style short mode. 29546 # If so, the updated path is stored in $new_path. 29547 29548 input_path="$new_path" 29549 # Check if we need to convert this using DOS-style short mode. If the path 29550 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29551 # take no chances and rewrite it. 29552 # Note: m4 eats our [], so we need to use [ and ] instead. 29553 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 29554 if test "x$has_forbidden_chars" != x; then 29555 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29556 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 29557 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 29558 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 29559 # Going to short mode and back again did indeed matter. Since short mode is 29560 # case insensitive, let's make it lowercase to improve readability. 29561 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29562 # Now convert it back to Unix-style (cygpath) 29563 input_path=`$CYGPATH -u "$shortmode_path"` 29564 new_path="$input_path" 29565 fi 29566 fi 29567 29568 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 29569 if test "x$test_cygdrive_prefix" = x; then 29570 # As a simple fix, exclude /usr/bin since it's not a real path. 29571 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 29572 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 29573 # a path prefixed by /cygdrive for fixpath to work. 29574 new_path="$CYGWIN_ROOT_PATH$input_path" 29575 fi 29576 fi 29577 29578 29579 if test "x$path" != "x$new_path"; then 29580 BOOT_JDK="$new_path" 29581 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29582 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29583 fi 29584 29585 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29586 29587 path="$BOOT_JDK" 29588 has_colon=`$ECHO $path | $GREP ^.:` 29589 new_path="$path" 29590 if test "x$has_colon" = x; then 29591 # Not in mixed or Windows style, start by that. 29592 new_path=`cmd //c echo $path` 29593 fi 29594 29595 29596 input_path="$new_path" 29597 # Check if we need to convert this using DOS-style short mode. If the path 29598 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29599 # take no chances and rewrite it. 29600 # Note: m4 eats our [], so we need to use [ and ] instead. 29601 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 29602 if test "x$has_forbidden_chars" != x; then 29603 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29604 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29605 fi 29606 29607 29608 windows_path="$new_path" 29609 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29610 unix_path=`$CYGPATH -u "$windows_path"` 29611 new_path="$unix_path" 29612 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29613 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 29614 new_path="$unix_path" 29615 fi 29616 29617 if test "x$path" != "x$new_path"; then 29618 BOOT_JDK="$new_path" 29619 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29620 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29621 fi 29622 29623 # Save the first 10 bytes of this path to the storage, so fixpath can work. 29624 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 29625 29626 else 29627 # We're on a unix platform. Hooray! :) 29628 path="$BOOT_JDK" 29629 has_space=`$ECHO "$path" | $GREP " "` 29630 if test "x$has_space" != x; then 29631 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29632 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29633 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 29634 fi 29635 29636 # Use eval to expand a potential ~ 29637 eval path="$path" 29638 if test ! -f "$path" && test ! -d "$path"; then 29639 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 29640 fi 29641 29642 if test -d "$path"; then 29643 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 29644 else 29645 dir="`$DIRNAME "$path"`" 29646 base="`$BASENAME "$path"`" 29647 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 29648 fi 29649 fi 29650 fi 29651 29652 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 29653 $as_echo_n "checking for Boot JDK... " >&6; } 29654 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 29655 $as_echo "$BOOT_JDK" >&6; } 29656 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 29657 $as_echo_n "checking Boot JDK version... " >&6; } 29658 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 29659 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 29660 $as_echo "$BOOT_JDK_VERSION" >&6; } 29661 fi # end check jdk version 29662 fi # end check javac 29663 fi # end check java 29664 fi # end check boot jdk found 29665 fi 29666 29667 fi 29668 29669 29670 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 29671 if test "x$BOOT_JDK_FOUND" = xmaybe; then 29672 # Do we have a bin/java? 29673 if test ! -x "$BOOT_JDK/bin/java"; then 29674 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 29675 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 29676 BOOT_JDK_FOUND=no 29677 else 29678 # Do we have a bin/javac? 29679 if test ! -x "$BOOT_JDK/bin/javac"; then 29680 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 29681 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 29682 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 29683 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 29684 BOOT_JDK_FOUND=no 29685 else 29686 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 29687 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 29688 29689 # Extra M4 quote needed to protect [] in grep expression. 29690 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 29691 if test "x$FOUND_CORRECT_VERSION" = x; then 29692 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 29693 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 29694 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 29695 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 29696 BOOT_JDK_FOUND=no 29697 else 29698 # We're done! :-) 29699 BOOT_JDK_FOUND=yes 29700 29701 # Only process if variable expands to non-empty 29702 29703 if test "x$BOOT_JDK" != x; then 29704 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29705 29706 # Input might be given as Windows format, start by converting to 29707 # unix format. 29708 path="$BOOT_JDK" 29709 new_path=`$CYGPATH -u "$path"` 29710 29711 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 29712 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 29713 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 29714 # "foo.exe" is OK but "foo" is an error. 29715 # 29716 # This test is therefore slightly more accurate than "test -f" to check for file precense. 29717 # It is also a way to make sure we got the proper file name for the real test later on. 29718 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 29719 if test "x$test_shortpath" = x; then 29720 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29721 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29722 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 29723 fi 29724 29725 # Call helper function which possibly converts this using DOS-style short mode. 29726 # If so, the updated path is stored in $new_path. 29727 29728 input_path="$new_path" 29729 # Check if we need to convert this using DOS-style short mode. If the path 29730 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29731 # take no chances and rewrite it. 29732 # Note: m4 eats our [], so we need to use [ and ] instead. 29733 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 29734 if test "x$has_forbidden_chars" != x; then 29735 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29736 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 29737 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 29738 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 29739 # Going to short mode and back again did indeed matter. Since short mode is 29740 # case insensitive, let's make it lowercase to improve readability. 29741 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29742 # Now convert it back to Unix-style (cygpath) 29743 input_path=`$CYGPATH -u "$shortmode_path"` 29744 new_path="$input_path" 29745 fi 29746 fi 29747 29748 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 29749 if test "x$test_cygdrive_prefix" = x; then 29750 # As a simple fix, exclude /usr/bin since it's not a real path. 29751 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 29752 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 29753 # a path prefixed by /cygdrive for fixpath to work. 29754 new_path="$CYGWIN_ROOT_PATH$input_path" 29755 fi 29756 fi 29757 29758 29759 if test "x$path" != "x$new_path"; then 29760 BOOT_JDK="$new_path" 29761 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29762 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29763 fi 29764 29765 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29766 29767 path="$BOOT_JDK" 29768 has_colon=`$ECHO $path | $GREP ^.:` 29769 new_path="$path" 29770 if test "x$has_colon" = x; then 29771 # Not in mixed or Windows style, start by that. 29772 new_path=`cmd //c echo $path` 29773 fi 29774 29775 29776 input_path="$new_path" 29777 # Check if we need to convert this using DOS-style short mode. If the path 29778 # contains just simple characters, use it. Otherwise (spaces, weird characters), 29779 # take no chances and rewrite it. 29780 # Note: m4 eats our [], so we need to use [ and ] instead. 29781 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 29782 if test "x$has_forbidden_chars" != x; then 29783 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 29784 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 29785 fi 29786 29787 29788 windows_path="$new_path" 29789 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29790 unix_path=`$CYGPATH -u "$windows_path"` 29791 new_path="$unix_path" 29792 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29793 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 29794 new_path="$unix_path" 29795 fi 29796 29797 if test "x$path" != "x$new_path"; then 29798 BOOT_JDK="$new_path" 29799 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 29800 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 29801 fi 29802 29803 # Save the first 10 bytes of this path to the storage, so fixpath can work. 29804 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 29805 29806 else 29807 # We're on a unix platform. Hooray! :) 29808 path="$BOOT_JDK" 29809 has_space=`$ECHO "$path" | $GREP " "` 29810 if test "x$has_space" != x; then 29811 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 29812 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 29813 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 29814 fi 29815 29816 # Use eval to expand a potential ~ 29817 eval path="$path" 29818 if test ! -f "$path" && test ! -d "$path"; then 29819 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 29820 fi 29821 29822 if test -d "$path"; then 29823 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 29824 else 29825 dir="`$DIRNAME "$path"`" 29826 base="`$BASENAME "$path"`" 29827 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 29828 fi 29829 fi 29830 fi 29831 29832 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 29833 $as_echo_n "checking for Boot JDK... " >&6; } 29834 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 29835 $as_echo "$BOOT_JDK" >&6; } 29836 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 29837 $as_echo_n "checking Boot JDK version... " >&6; } 29838 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 29839 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 29840 $as_echo "$BOOT_JDK_VERSION" >&6; } 29841 fi # end check jdk version 29842 fi # end check javac 29843 fi # end check java 29844 fi # end check boot jdk found 29845 fi 29846 29847 29848 # If we haven't found anything yet, we've truly lost. Give up. 29849 if test "x$BOOT_JDK_FOUND" = xno; then 29850 29851 # Print a helpful message on how to acquire the necessary build dependency. 29852 # openjdk is the help tag: freetype, cups, alsa etc 29853 MISSING_DEPENDENCY=openjdk 29854 29855 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 29856 cygwin_help $MISSING_DEPENDENCY 29857 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 29858 msys_help $MISSING_DEPENDENCY 29859 else 29860 PKGHANDLER_COMMAND= 29861 29862 case $PKGHANDLER in 29863 apt-get) 29864 apt_help $MISSING_DEPENDENCY ;; 29865 yum) 29866 yum_help $MISSING_DEPENDENCY ;; 29867 port) 29868 port_help $MISSING_DEPENDENCY ;; 29869 pkgutil) 29870 pkgutil_help $MISSING_DEPENDENCY ;; 29871 pkgadd) 29872 pkgadd_help $MISSING_DEPENDENCY ;; 29873 esac 29874 29875 if test "x$PKGHANDLER_COMMAND" != x; then 29876 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 29877 fi 29878 fi 29879 29880 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find a valid Boot JDK. $HELP_MSG" >&5 29881 $as_echo "$as_me: Could not find a valid Boot JDK. $HELP_MSG" >&6;} 29882 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be fixed by explicitely setting --with-boot-jdk" >&5 29883 $as_echo "$as_me: This might be fixed by explicitely setting --with-boot-jdk" >&6;} 29884 as_fn_error $? "Cannot continue" "$LINENO" 5 29885 fi 29886 29887 29888 29889 # Setup tools from the Boot JDK. 29890 29891 # Use user overridden value if available, otherwise locate tool in the Boot JDK. 29892 29893 # Publish this variable in the help. 29894 29895 29896 if [ -z "${JAVA+x}" ]; then 29897 # The variable is not set by user, try to locate tool using the code snippet 29898 29899 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for java in Boot JDK" >&5 29900 $as_echo_n "checking for java in Boot JDK... " >&6; } 29901 JAVA=$BOOT_JDK/bin/java 29902 if test ! -x $JAVA; then 29903 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 29904 $as_echo "not found" >&6; } 29905 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 29906 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 29907 as_fn_error $? "Could not find java in the Boot JDK" "$LINENO" 5 29908 fi 29909 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 29910 $as_echo "ok" >&6; } 29911 29912 29913 else 29914 # The variable is set, but is it from the command line or the environment? 29915 29916 # Try to remove the string !JAVA! from our list. 29917 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAVA!/} 29918 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 29919 # If it failed, the variable was not from the command line. Ignore it, 29920 # but warn the user (except for BASH, which is always set by the calling BASH). 29921 if test "xJAVA" != xBASH; then 29922 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAVA from the environment. Use command line variables instead." >&5 29923 $as_echo "$as_me: WARNING: Ignoring value of JAVA from the environment. Use command line variables instead." >&2;} 29924 fi 29925 # Try to locate tool using the code snippet 29926 29927 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for java in Boot JDK" >&5 29928 $as_echo_n "checking for java in Boot JDK... " >&6; } 29929 JAVA=$BOOT_JDK/bin/java 29930 if test ! -x $JAVA; then 29931 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 29932 $as_echo "not found" >&6; } 29933 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 29934 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 29935 as_fn_error $? "Could not find java in the Boot JDK" "$LINENO" 5 29936 fi 29937 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 29938 $as_echo "ok" >&6; } 29939 29940 29941 else 29942 # If it succeeded, then it was overridden by the user. We will use it 29943 # for the tool. 29944 29945 # First remove it from the list of overridden variables, so we can test 29946 # for unknown variables in the end. 29947 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 29948 29949 # Check if we try to supply an empty value 29950 if test "x$JAVA" = x; then 29951 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JAVA= (no value)" >&5 29952 $as_echo "$as_me: Setting user supplied tool JAVA= (no value)" >&6;} 29953 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVA" >&5 29954 $as_echo_n "checking for JAVA... " >&6; } 29955 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 29956 $as_echo "disabled" >&6; } 29957 else 29958 # Check if the provided tool contains a complete path. 29959 tool_specified="$JAVA" 29960 tool_basename="${tool_specified##*/}" 29961 if test "x$tool_basename" = "x$tool_specified"; then 29962 # A command without a complete path is provided, search $PATH. 29963 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAVA=$tool_basename" >&5 29964 $as_echo "$as_me: Will search for user supplied tool JAVA=$tool_basename" >&6;} 29965 # Extract the first word of "$tool_basename", so it can be a program name with args. 29966 set dummy $tool_basename; ac_word=$2 29967 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 29968 $as_echo_n "checking for $ac_word... " >&6; } 29969 if ${ac_cv_path_JAVA+:} false; then : 29970 $as_echo_n "(cached) " >&6 29971 else 29972 case $JAVA in 29973 [\\/]* | ?:[\\/]*) 29974 ac_cv_path_JAVA="$JAVA" # Let the user override the test with a path. 29975 ;; 29976 *) 29977 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 29978 for as_dir in $PATH 29979 do 29980 IFS=$as_save_IFS 29981 test -z "$as_dir" && as_dir=. 29982 for ac_exec_ext in '' $ac_executable_extensions; do 29983 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 29984 ac_cv_path_JAVA="$as_dir/$ac_word$ac_exec_ext" 29985 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 29986 break 2 29987 fi 29988 done 29989 done 29990 IFS=$as_save_IFS 29991 29992 ;; 29993 esac 29994 fi 29995 JAVA=$ac_cv_path_JAVA 29996 if test -n "$JAVA"; then 29997 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVA" >&5 29998 $as_echo "$JAVA" >&6; } 29999 else 30000 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 30001 $as_echo "no" >&6; } 30002 fi 30003 30004 30005 if test "x$JAVA" = x; then 30006 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 30007 fi 30008 else 30009 # Otherwise we believe it is a complete path. Use it as it is. 30010 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAVA=$tool_specified" >&5 30011 $as_echo "$as_me: Will use user supplied tool JAVA=$tool_specified" >&6;} 30012 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVA" >&5 30013 $as_echo_n "checking for JAVA... " >&6; } 30014 if test ! -x "$tool_specified"; then 30015 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30016 $as_echo "not found" >&6; } 30017 as_fn_error $? "User supplied tool JAVA=$tool_specified does not exist or is not executable" "$LINENO" 5 30018 fi 30019 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 30020 $as_echo "$tool_specified" >&6; } 30021 fi 30022 fi 30023 fi 30024 30025 fi 30026 30027 30028 30029 # Use user overridden value if available, otherwise locate tool in the Boot JDK. 30030 30031 # Publish this variable in the help. 30032 30033 30034 if [ -z "${JAVAC+x}" ]; then 30035 # The variable is not set by user, try to locate tool using the code snippet 30036 30037 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javac in Boot JDK" >&5 30038 $as_echo_n "checking for javac in Boot JDK... " >&6; } 30039 JAVAC=$BOOT_JDK/bin/javac 30040 if test ! -x $JAVAC; then 30041 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30042 $as_echo "not found" >&6; } 30043 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 30044 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 30045 as_fn_error $? "Could not find javac in the Boot JDK" "$LINENO" 5 30046 fi 30047 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30048 $as_echo "ok" >&6; } 30049 30050 30051 else 30052 # The variable is set, but is it from the command line or the environment? 30053 30054 # Try to remove the string !JAVAC! from our list. 30055 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAVAC!/} 30056 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 30057 # If it failed, the variable was not from the command line. Ignore it, 30058 # but warn the user (except for BASH, which is always set by the calling BASH). 30059 if test "xJAVAC" != xBASH; then 30060 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAVAC from the environment. Use command line variables instead." >&5 30061 $as_echo "$as_me: WARNING: Ignoring value of JAVAC from the environment. Use command line variables instead." >&2;} 30062 fi 30063 # Try to locate tool using the code snippet 30064 30065 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javac in Boot JDK" >&5 30066 $as_echo_n "checking for javac in Boot JDK... " >&6; } 30067 JAVAC=$BOOT_JDK/bin/javac 30068 if test ! -x $JAVAC; then 30069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30070 $as_echo "not found" >&6; } 30071 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 30072 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 30073 as_fn_error $? "Could not find javac in the Boot JDK" "$LINENO" 5 30074 fi 30075 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30076 $as_echo "ok" >&6; } 30077 30078 30079 else 30080 # If it succeeded, then it was overridden by the user. We will use it 30081 # for the tool. 30082 30083 # First remove it from the list of overridden variables, so we can test 30084 # for unknown variables in the end. 30085 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 30086 30087 # Check if we try to supply an empty value 30088 if test "x$JAVAC" = x; then 30089 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JAVAC= (no value)" >&5 30090 $as_echo "$as_me: Setting user supplied tool JAVAC= (no value)" >&6;} 30091 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAC" >&5 30092 $as_echo_n "checking for JAVAC... " >&6; } 30093 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 30094 $as_echo "disabled" >&6; } 30095 else 30096 # Check if the provided tool contains a complete path. 30097 tool_specified="$JAVAC" 30098 tool_basename="${tool_specified##*/}" 30099 if test "x$tool_basename" = "x$tool_specified"; then 30100 # A command without a complete path is provided, search $PATH. 30101 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAVAC=$tool_basename" >&5 30102 $as_echo "$as_me: Will search for user supplied tool JAVAC=$tool_basename" >&6;} 30103 # Extract the first word of "$tool_basename", so it can be a program name with args. 30104 set dummy $tool_basename; ac_word=$2 30105 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 30106 $as_echo_n "checking for $ac_word... " >&6; } 30107 if ${ac_cv_path_JAVAC+:} false; then : 30108 $as_echo_n "(cached) " >&6 30109 else 30110 case $JAVAC in 30111 [\\/]* | ?:[\\/]*) 30112 ac_cv_path_JAVAC="$JAVAC" # Let the user override the test with a path. 30113 ;; 30114 *) 30115 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 30116 for as_dir in $PATH 30117 do 30118 IFS=$as_save_IFS 30119 test -z "$as_dir" && as_dir=. 30120 for ac_exec_ext in '' $ac_executable_extensions; do 30121 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 30122 ac_cv_path_JAVAC="$as_dir/$ac_word$ac_exec_ext" 30123 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 30124 break 2 30125 fi 30126 done 30127 done 30128 IFS=$as_save_IFS 30129 30130 ;; 30131 esac 30132 fi 30133 JAVAC=$ac_cv_path_JAVAC 30134 if test -n "$JAVAC"; then 30135 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVAC" >&5 30136 $as_echo "$JAVAC" >&6; } 30137 else 30138 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 30139 $as_echo "no" >&6; } 30140 fi 30141 30142 30143 if test "x$JAVAC" = x; then 30144 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 30145 fi 30146 else 30147 # Otherwise we believe it is a complete path. Use it as it is. 30148 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAVAC=$tool_specified" >&5 30149 $as_echo "$as_me: Will use user supplied tool JAVAC=$tool_specified" >&6;} 30150 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAC" >&5 30151 $as_echo_n "checking for JAVAC... " >&6; } 30152 if test ! -x "$tool_specified"; then 30153 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30154 $as_echo "not found" >&6; } 30155 as_fn_error $? "User supplied tool JAVAC=$tool_specified does not exist or is not executable" "$LINENO" 5 30156 fi 30157 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 30158 $as_echo "$tool_specified" >&6; } 30159 fi 30160 fi 30161 fi 30162 30163 fi 30164 30165 30166 30167 # Use user overridden value if available, otherwise locate tool in the Boot JDK. 30168 30169 # Publish this variable in the help. 30170 30171 30172 if [ -z "${JAVAH+x}" ]; then 30173 # The variable is not set by user, try to locate tool using the code snippet 30174 30175 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javah in Boot JDK" >&5 30176 $as_echo_n "checking for javah in Boot JDK... " >&6; } 30177 JAVAH=$BOOT_JDK/bin/javah 30178 if test ! -x $JAVAH; then 30179 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30180 $as_echo "not found" >&6; } 30181 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 30182 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 30183 as_fn_error $? "Could not find javah in the Boot JDK" "$LINENO" 5 30184 fi 30185 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30186 $as_echo "ok" >&6; } 30187 30188 30189 else 30190 # The variable is set, but is it from the command line or the environment? 30191 30192 # Try to remove the string !JAVAH! from our list. 30193 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAVAH!/} 30194 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 30195 # If it failed, the variable was not from the command line. Ignore it, 30196 # but warn the user (except for BASH, which is always set by the calling BASH). 30197 if test "xJAVAH" != xBASH; then 30198 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAVAH from the environment. Use command line variables instead." >&5 30199 $as_echo "$as_me: WARNING: Ignoring value of JAVAH from the environment. Use command line variables instead." >&2;} 30200 fi 30201 # Try to locate tool using the code snippet 30202 30203 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javah in Boot JDK" >&5 30204 $as_echo_n "checking for javah in Boot JDK... " >&6; } 30205 JAVAH=$BOOT_JDK/bin/javah 30206 if test ! -x $JAVAH; then 30207 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30208 $as_echo "not found" >&6; } 30209 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 30210 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 30211 as_fn_error $? "Could not find javah in the Boot JDK" "$LINENO" 5 30212 fi 30213 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30214 $as_echo "ok" >&6; } 30215 30216 30217 else 30218 # If it succeeded, then it was overridden by the user. We will use it 30219 # for the tool. 30220 30221 # First remove it from the list of overridden variables, so we can test 30222 # for unknown variables in the end. 30223 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 30224 30225 # Check if we try to supply an empty value 30226 if test "x$JAVAH" = x; then 30227 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JAVAH= (no value)" >&5 30228 $as_echo "$as_me: Setting user supplied tool JAVAH= (no value)" >&6;} 30229 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAH" >&5 30230 $as_echo_n "checking for JAVAH... " >&6; } 30231 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 30232 $as_echo "disabled" >&6; } 30233 else 30234 # Check if the provided tool contains a complete path. 30235 tool_specified="$JAVAH" 30236 tool_basename="${tool_specified##*/}" 30237 if test "x$tool_basename" = "x$tool_specified"; then 30238 # A command without a complete path is provided, search $PATH. 30239 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAVAH=$tool_basename" >&5 30240 $as_echo "$as_me: Will search for user supplied tool JAVAH=$tool_basename" >&6;} 30241 # Extract the first word of "$tool_basename", so it can be a program name with args. 30242 set dummy $tool_basename; ac_word=$2 30243 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 30244 $as_echo_n "checking for $ac_word... " >&6; } 30245 if ${ac_cv_path_JAVAH+:} false; then : 30246 $as_echo_n "(cached) " >&6 30247 else 30248 case $JAVAH in 30249 [\\/]* | ?:[\\/]*) 30250 ac_cv_path_JAVAH="$JAVAH" # Let the user override the test with a path. 30251 ;; 30252 *) 30253 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 30254 for as_dir in $PATH 30255 do 30256 IFS=$as_save_IFS 30257 test -z "$as_dir" && as_dir=. 30258 for ac_exec_ext in '' $ac_executable_extensions; do 30259 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 30260 ac_cv_path_JAVAH="$as_dir/$ac_word$ac_exec_ext" 30261 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 30262 break 2 30263 fi 30264 done 30265 done 30266 IFS=$as_save_IFS 30267 30268 ;; 30269 esac 30270 fi 30271 JAVAH=$ac_cv_path_JAVAH 30272 if test -n "$JAVAH"; then 30273 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVAH" >&5 30274 $as_echo "$JAVAH" >&6; } 30275 else 30276 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 30277 $as_echo "no" >&6; } 30278 fi 30279 30280 30281 if test "x$JAVAH" = x; then 30282 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 30283 fi 30284 else 30285 # Otherwise we believe it is a complete path. Use it as it is. 30286 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAVAH=$tool_specified" >&5 30287 $as_echo "$as_me: Will use user supplied tool JAVAH=$tool_specified" >&6;} 30288 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAH" >&5 30289 $as_echo_n "checking for JAVAH... " >&6; } 30290 if test ! -x "$tool_specified"; then 30291 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30292 $as_echo "not found" >&6; } 30293 as_fn_error $? "User supplied tool JAVAH=$tool_specified does not exist or is not executable" "$LINENO" 5 30294 fi 30295 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 30296 $as_echo "$tool_specified" >&6; } 30297 fi 30298 fi 30299 fi 30300 30301 fi 30302 30303 30304 30305 # Use user overridden value if available, otherwise locate tool in the Boot JDK. 30306 30307 # Publish this variable in the help. 30308 30309 30310 if [ -z "${JAR+x}" ]; then 30311 # The variable is not set by user, try to locate tool using the code snippet 30312 30313 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jar in Boot JDK" >&5 30314 $as_echo_n "checking for jar in Boot JDK... " >&6; } 30315 JAR=$BOOT_JDK/bin/jar 30316 if test ! -x $JAR; then 30317 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30318 $as_echo "not found" >&6; } 30319 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 30320 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 30321 as_fn_error $? "Could not find jar in the Boot JDK" "$LINENO" 5 30322 fi 30323 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30324 $as_echo "ok" >&6; } 30325 30326 30327 else 30328 # The variable is set, but is it from the command line or the environment? 30329 30330 # Try to remove the string !JAR! from our list. 30331 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAR!/} 30332 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 30333 # If it failed, the variable was not from the command line. Ignore it, 30334 # but warn the user (except for BASH, which is always set by the calling BASH). 30335 if test "xJAR" != xBASH; then 30336 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAR from the environment. Use command line variables instead." >&5 30337 $as_echo "$as_me: WARNING: Ignoring value of JAR from the environment. Use command line variables instead." >&2;} 30338 fi 30339 # Try to locate tool using the code snippet 30340 30341 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jar in Boot JDK" >&5 30342 $as_echo_n "checking for jar in Boot JDK... " >&6; } 30343 JAR=$BOOT_JDK/bin/jar 30344 if test ! -x $JAR; then 30345 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30346 $as_echo "not found" >&6; } 30347 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 30348 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 30349 as_fn_error $? "Could not find jar in the Boot JDK" "$LINENO" 5 30350 fi 30351 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30352 $as_echo "ok" >&6; } 30353 30354 30355 else 30356 # If it succeeded, then it was overridden by the user. We will use it 30357 # for the tool. 30358 30359 # First remove it from the list of overridden variables, so we can test 30360 # for unknown variables in the end. 30361 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 30362 30363 # Check if we try to supply an empty value 30364 if test "x$JAR" = x; then 30365 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JAR= (no value)" >&5 30366 $as_echo "$as_me: Setting user supplied tool JAR= (no value)" >&6;} 30367 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAR" >&5 30368 $as_echo_n "checking for JAR... " >&6; } 30369 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 30370 $as_echo "disabled" >&6; } 30371 else 30372 # Check if the provided tool contains a complete path. 30373 tool_specified="$JAR" 30374 tool_basename="${tool_specified##*/}" 30375 if test "x$tool_basename" = "x$tool_specified"; then 30376 # A command without a complete path is provided, search $PATH. 30377 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAR=$tool_basename" >&5 30378 $as_echo "$as_me: Will search for user supplied tool JAR=$tool_basename" >&6;} 30379 # Extract the first word of "$tool_basename", so it can be a program name with args. 30380 set dummy $tool_basename; ac_word=$2 30381 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 30382 $as_echo_n "checking for $ac_word... " >&6; } 30383 if ${ac_cv_path_JAR+:} false; then : 30384 $as_echo_n "(cached) " >&6 30385 else 30386 case $JAR in 30387 [\\/]* | ?:[\\/]*) 30388 ac_cv_path_JAR="$JAR" # Let the user override the test with a path. 30389 ;; 30390 *) 30391 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 30392 for as_dir in $PATH 30393 do 30394 IFS=$as_save_IFS 30395 test -z "$as_dir" && as_dir=. 30396 for ac_exec_ext in '' $ac_executable_extensions; do 30397 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 30398 ac_cv_path_JAR="$as_dir/$ac_word$ac_exec_ext" 30399 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 30400 break 2 30401 fi 30402 done 30403 done 30404 IFS=$as_save_IFS 30405 30406 ;; 30407 esac 30408 fi 30409 JAR=$ac_cv_path_JAR 30410 if test -n "$JAR"; then 30411 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAR" >&5 30412 $as_echo "$JAR" >&6; } 30413 else 30414 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 30415 $as_echo "no" >&6; } 30416 fi 30417 30418 30419 if test "x$JAR" = x; then 30420 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 30421 fi 30422 else 30423 # Otherwise we believe it is a complete path. Use it as it is. 30424 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAR=$tool_specified" >&5 30425 $as_echo "$as_me: Will use user supplied tool JAR=$tool_specified" >&6;} 30426 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAR" >&5 30427 $as_echo_n "checking for JAR... " >&6; } 30428 if test ! -x "$tool_specified"; then 30429 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30430 $as_echo "not found" >&6; } 30431 as_fn_error $? "User supplied tool JAR=$tool_specified does not exist or is not executable" "$LINENO" 5 30432 fi 30433 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 30434 $as_echo "$tool_specified" >&6; } 30435 fi 30436 fi 30437 fi 30438 30439 fi 30440 30441 30442 30443 # Use user overridden value if available, otherwise locate tool in the Boot JDK. 30444 30445 # Publish this variable in the help. 30446 30447 30448 if [ -z "${JARSIGNER+x}" ]; then 30449 # The variable is not set by user, try to locate tool using the code snippet 30450 30451 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jarsigner in Boot JDK" >&5 30452 $as_echo_n "checking for jarsigner in Boot JDK... " >&6; } 30453 JARSIGNER=$BOOT_JDK/bin/jarsigner 30454 if test ! -x $JARSIGNER; then 30455 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30456 $as_echo "not found" >&6; } 30457 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 30458 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 30459 as_fn_error $? "Could not find jarsigner in the Boot JDK" "$LINENO" 5 30460 fi 30461 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30462 $as_echo "ok" >&6; } 30463 30464 30465 else 30466 # The variable is set, but is it from the command line or the environment? 30467 30468 # Try to remove the string !JARSIGNER! from our list. 30469 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JARSIGNER!/} 30470 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 30471 # If it failed, the variable was not from the command line. Ignore it, 30472 # but warn the user (except for BASH, which is always set by the calling BASH). 30473 if test "xJARSIGNER" != xBASH; then 30474 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JARSIGNER from the environment. Use command line variables instead." >&5 30475 $as_echo "$as_me: WARNING: Ignoring value of JARSIGNER from the environment. Use command line variables instead." >&2;} 30476 fi 30477 # Try to locate tool using the code snippet 30478 30479 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jarsigner in Boot JDK" >&5 30480 $as_echo_n "checking for jarsigner in Boot JDK... " >&6; } 30481 JARSIGNER=$BOOT_JDK/bin/jarsigner 30482 if test ! -x $JARSIGNER; then 30483 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30484 $as_echo "not found" >&6; } 30485 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 30486 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 30487 as_fn_error $? "Could not find jarsigner in the Boot JDK" "$LINENO" 5 30488 fi 30489 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 30490 $as_echo "ok" >&6; } 30491 30492 30493 else 30494 # If it succeeded, then it was overridden by the user. We will use it 30495 # for the tool. 30496 30497 # First remove it from the list of overridden variables, so we can test 30498 # for unknown variables in the end. 30499 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 30500 30501 # Check if we try to supply an empty value 30502 if test "x$JARSIGNER" = x; then 30503 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JARSIGNER= (no value)" >&5 30504 $as_echo "$as_me: Setting user supplied tool JARSIGNER= (no value)" >&6;} 30505 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JARSIGNER" >&5 30506 $as_echo_n "checking for JARSIGNER... " >&6; } 30507 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 30508 $as_echo "disabled" >&6; } 30509 else 30510 # Check if the provided tool contains a complete path. 30511 tool_specified="$JARSIGNER" 30512 tool_basename="${tool_specified##*/}" 30513 if test "x$tool_basename" = "x$tool_specified"; then 30514 # A command without a complete path is provided, search $PATH. 30515 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JARSIGNER=$tool_basename" >&5 30516 $as_echo "$as_me: Will search for user supplied tool JARSIGNER=$tool_basename" >&6;} 30517 # Extract the first word of "$tool_basename", so it can be a program name with args. 30518 set dummy $tool_basename; ac_word=$2 30519 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 30520 $as_echo_n "checking for $ac_word... " >&6; } 30521 if ${ac_cv_path_JARSIGNER+:} false; then : 30522 $as_echo_n "(cached) " >&6 30523 else 30524 case $JARSIGNER in 30525 [\\/]* | ?:[\\/]*) 30526 ac_cv_path_JARSIGNER="$JARSIGNER" # Let the user override the test with a path. 30527 ;; 30528 *) 30529 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 30530 for as_dir in $PATH 30531 do 30532 IFS=$as_save_IFS 30533 test -z "$as_dir" && as_dir=. 30534 for ac_exec_ext in '' $ac_executable_extensions; do 30535 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 30536 ac_cv_path_JARSIGNER="$as_dir/$ac_word$ac_exec_ext" 30537 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 30538 break 2 30539 fi 30540 done 30541 done 30542 IFS=$as_save_IFS 30543 30544 ;; 30545 esac 30546 fi 30547 JARSIGNER=$ac_cv_path_JARSIGNER 30548 if test -n "$JARSIGNER"; then 30549 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JARSIGNER" >&5 30550 $as_echo "$JARSIGNER" >&6; } 30551 else 30552 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 30553 $as_echo "no" >&6; } 30554 fi 30555 30556 30557 if test "x$JARSIGNER" = x; then 30558 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 30559 fi 30560 else 30561 # Otherwise we believe it is a complete path. Use it as it is. 30562 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JARSIGNER=$tool_specified" >&5 30563 $as_echo "$as_me: Will use user supplied tool JARSIGNER=$tool_specified" >&6;} 30564 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JARSIGNER" >&5 30565 $as_echo_n "checking for JARSIGNER... " >&6; } 30566 if test ! -x "$tool_specified"; then 30567 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 30568 $as_echo "not found" >&6; } 30569 as_fn_error $? "User supplied tool JARSIGNER=$tool_specified does not exist or is not executable" "$LINENO" 5 30570 fi 30571 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 30572 $as_echo "$tool_specified" >&6; } 30573 fi 30574 fi 30575 fi 30576 30577 fi 30578 30579 30580 30581 # Finally, set some other options... 30582 30583 # When compiling code to be executed by the Boot JDK, force jdk8 compatibility. 30584 BOOT_JDK_SOURCETARGET="-source 8 -target 8" 30585 30586 30587 30588 $ECHO "Check if jvm arg is ok: --patch-module foo=bar" >&5 30589 $ECHO "Command: $JAVA --patch-module foo=bar -version" >&5 30590 OUTPUT=`$JAVA --patch-module foo=bar -version 2>&1` 30591 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 30592 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 30593 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 30594 dummy="$dummy --patch-module foo=bar" 30595 JVM_ARG_OK=true 30596 else 30597 $ECHO "Arg failed:" >&5 30598 $ECHO "$OUTPUT" >&5 30599 JVM_ARG_OK=false 30600 fi 30601 30602 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if Boot JDK supports modules" >&5 30603 $as_echo_n "checking if Boot JDK supports modules... " >&6; } 30604 if test "x$JVM_ARG_OK" = "xtrue"; then 30605 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 30606 $as_echo "yes" >&6; } 30607 BOOT_JDK_MODULAR="true" 30608 else 30609 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 30610 $as_echo "no" >&6; } 30611 BOOT_JDK_MODULAR="false" 30612 fi 30613 30614 30615 30616 30617 # Check if the boot jdk is 32 or 64 bit 30618 if "$JAVA" -d64 -version > /dev/null 2>&1; then 30619 BOOT_JDK_BITS="64" 30620 else 30621 BOOT_JDK_BITS="32" 30622 fi 30623 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if Boot JDK is 32 or 64 bits" >&5 30624 $as_echo_n "checking if Boot JDK is 32 or 64 bits... " >&6; } 30625 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_BITS" >&5 30626 $as_echo "$BOOT_JDK_BITS" >&6; } 30627 30628 30629 30630 30631 # Check whether --with-build-jdk was given. 30632 if test "${with_build_jdk+set}" = set; then : 30633 withval=$with_build_jdk; 30634 fi 30635 30636 30637 CREATE_BUILDJDK=false 30638 EXTERNAL_BUILDJDK=false 30639 BUILD_JDK_FOUND="no" 30640 if test "x$with_build_jdk" != "x"; then 30641 30642 if test "x$BUILD_JDK_FOUND" = xno; then 30643 # Execute the test 30644 30645 if test "x$with_build_jdk" != x; then 30646 BUILD_JDK=$with_build_jdk 30647 BUILD_JDK_FOUND=maybe 30648 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Build JDK using configure arguments" >&5 30649 $as_echo "$as_me: Found potential Build JDK using configure arguments" >&6;} 30650 fi 30651 30652 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 30653 if test "x$BUILD_JDK_FOUND" = xmaybe; then 30654 # Do we have a bin/java? 30655 if test ! -x "$BUILD_JDK/bin/java"; then 30656 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Build JDK found at $BUILD_JDK did not contain bin/java; ignoring" >&5 30657 $as_echo "$as_me: Potential Build JDK found at $BUILD_JDK did not contain bin/java; ignoring" >&6;} 30658 BUILD_JDK_FOUND=no 30659 elif test ! -x "$BUILD_JDK/bin/jlink"; then 30660 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Build JDK found at $BUILD_JDK did not contain bin/jlink; ignoring" >&5 30661 $as_echo "$as_me: Potential Build JDK found at $BUILD_JDK did not contain bin/jlink; ignoring" >&6;} 30662 BUILD_JDK_FOUND=no 30663 elif test ! -x "$BUILD_JDK/bin/jmod"; then 30664 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Build JDK found at $BUILD_JDK did not contain bin/jmod; ignoring" >&5 30665 $as_echo "$as_me: Potential Build JDK found at $BUILD_JDK did not contain bin/jmod; ignoring" >&6;} 30666 BUILD_JDK_FOUND=no 30667 elif test ! -x "$BUILD_JDK/bin/javac"; then 30668 # Do we have a bin/javac? 30669 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Build JDK found at $BUILD_JDK did not contain bin/javac; ignoring" >&5 30670 $as_echo "$as_me: Potential Build JDK found at $BUILD_JDK did not contain bin/javac; ignoring" >&6;} 30671 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be a JRE instead of an JDK)" >&5 30672 $as_echo "$as_me: (This might be a JRE instead of an JDK)" >&6;} 30673 BUILD_JDK_FOUND=no 30674 else 30675 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 30676 BUILD_JDK_VERSION=`"$BUILD_JDK/bin/java" -version 2>&1 | $HEAD -n 1` 30677 30678 # Extra M4 quote needed to protect [] in grep expression. 30679 FOUND_CORRECT_VERSION=`echo $BUILD_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"'` 30680 if test "x$FOUND_CORRECT_VERSION" = x; then 30681 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Build JDK found at $BUILD_JDK is incorrect JDK version ($BUILD_JDK_VERSION); ignoring" >&5 30682 $as_echo "$as_me: Potential Build JDK found at $BUILD_JDK is incorrect JDK version ($BUILD_JDK_VERSION); ignoring" >&6;} 30683 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Build JDK must be version 9)" >&5 30684 $as_echo "$as_me: (Your Build JDK must be version 9)" >&6;} 30685 BUILD_JDK_FOUND=no 30686 else 30687 # We're done! 30688 BUILD_JDK_FOUND=yes 30689 30690 # Only process if variable expands to non-empty 30691 30692 if test "x$BUILD_JDK" != x; then 30693 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30694 30695 # Input might be given as Windows format, start by converting to 30696 # unix format. 30697 path="$BUILD_JDK" 30698 new_path=`$CYGPATH -u "$path"` 30699 30700 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 30701 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 30702 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 30703 # "foo.exe" is OK but "foo" is an error. 30704 # 30705 # This test is therefore slightly more accurate than "test -f" to check for file precense. 30706 # It is also a way to make sure we got the proper file name for the real test later on. 30707 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 30708 if test "x$test_shortpath" = x; then 30709 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_JDK, which resolves as \"$path\", is invalid." >&5 30710 $as_echo "$as_me: The path of BUILD_JDK, which resolves as \"$path\", is invalid." >&6;} 30711 as_fn_error $? "Cannot locate the the path of BUILD_JDK" "$LINENO" 5 30712 fi 30713 30714 # Call helper function which possibly converts this using DOS-style short mode. 30715 # If so, the updated path is stored in $new_path. 30716 30717 input_path="$new_path" 30718 # Check if we need to convert this using DOS-style short mode. If the path 30719 # contains just simple characters, use it. Otherwise (spaces, weird characters), 30720 # take no chances and rewrite it. 30721 # Note: m4 eats our [], so we need to use [ and ] instead. 30722 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 30723 if test "x$has_forbidden_chars" != x; then 30724 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 30725 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 30726 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 30727 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 30728 # Going to short mode and back again did indeed matter. Since short mode is 30729 # case insensitive, let's make it lowercase to improve readability. 30730 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 30731 # Now convert it back to Unix-style (cygpath) 30732 input_path=`$CYGPATH -u "$shortmode_path"` 30733 new_path="$input_path" 30734 fi 30735 fi 30736 30737 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 30738 if test "x$test_cygdrive_prefix" = x; then 30739 # As a simple fix, exclude /usr/bin since it's not a real path. 30740 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 30741 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 30742 # a path prefixed by /cygdrive for fixpath to work. 30743 new_path="$CYGWIN_ROOT_PATH$input_path" 30744 fi 30745 fi 30746 30747 30748 if test "x$path" != "x$new_path"; then 30749 BUILD_JDK="$new_path" 30750 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_JDK to \"$new_path\"" >&5 30751 $as_echo "$as_me: Rewriting BUILD_JDK to \"$new_path\"" >&6;} 30752 fi 30753 30754 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30755 30756 path="$BUILD_JDK" 30757 has_colon=`$ECHO $path | $GREP ^.:` 30758 new_path="$path" 30759 if test "x$has_colon" = x; then 30760 # Not in mixed or Windows style, start by that. 30761 new_path=`cmd //c echo $path` 30762 fi 30763 30764 30765 input_path="$new_path" 30766 # Check if we need to convert this using DOS-style short mode. If the path 30767 # contains just simple characters, use it. Otherwise (spaces, weird characters), 30768 # take no chances and rewrite it. 30769 # Note: m4 eats our [], so we need to use [ and ] instead. 30770 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 30771 if test "x$has_forbidden_chars" != x; then 30772 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 30773 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 30774 fi 30775 30776 30777 windows_path="$new_path" 30778 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30779 unix_path=`$CYGPATH -u "$windows_path"` 30780 new_path="$unix_path" 30781 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30782 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 30783 new_path="$unix_path" 30784 fi 30785 30786 if test "x$path" != "x$new_path"; then 30787 BUILD_JDK="$new_path" 30788 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_JDK to \"$new_path\"" >&5 30789 $as_echo "$as_me: Rewriting BUILD_JDK to \"$new_path\"" >&6;} 30790 fi 30791 30792 # Save the first 10 bytes of this path to the storage, so fixpath can work. 30793 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 30794 30795 else 30796 # We're on a unix platform. Hooray! :) 30797 path="$BUILD_JDK" 30798 has_space=`$ECHO "$path" | $GREP " "` 30799 if test "x$has_space" != x; then 30800 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_JDK, which resolves as \"$path\", is invalid." >&5 30801 $as_echo "$as_me: The path of BUILD_JDK, which resolves as \"$path\", is invalid." >&6;} 30802 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 30803 fi 30804 30805 # Use eval to expand a potential ~ 30806 eval path="$path" 30807 if test ! -f "$path" && test ! -d "$path"; then 30808 as_fn_error $? "The path of BUILD_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 30809 fi 30810 30811 if test -d "$path"; then 30812 BUILD_JDK="`cd "$path"; $THEPWDCMD -L`" 30813 else 30814 dir="`$DIRNAME "$path"`" 30815 base="`$BASENAME "$path"`" 30816 BUILD_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 30817 fi 30818 fi 30819 fi 30820 30821 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Build JDK" >&5 30822 $as_echo_n "checking for Build JDK... " >&6; } 30823 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_JDK" >&5 30824 $as_echo "$BUILD_JDK" >&6; } 30825 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Build JDK version" >&5 30826 $as_echo_n "checking Build JDK version... " >&6; } 30827 BUILD_JDK_VERSION=`"$BUILD_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 30828 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_JDK_VERSION" >&5 30829 $as_echo "$BUILD_JDK_VERSION" >&6; } 30830 fi # end check jdk version 30831 fi # end check java 30832 fi # end check build jdk found 30833 fi 30834 30835 EXTERNAL_BUILDJDK=true 30836 else 30837 if test "x$COMPILE_TYPE" = "xcross"; then 30838 BUILD_JDK="\$(BUILDJDK_OUTPUTDIR)/jdk" 30839 BUILD_JDK_FOUND=yes 30840 CREATE_BUILDJDK=true 30841 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Build JDK" >&5 30842 $as_echo_n "checking for Build JDK... " >&6; } 30843 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, will build it for the host platform" >&5 30844 $as_echo "yes, will build it for the host platform" >&6; } 30845 else 30846 BUILD_JDK="\$(JDK_OUTPUTDIR)" 30847 BUILD_JDK_FOUND=yes 30848 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Build JDK" >&5 30849 $as_echo_n "checking for Build JDK... " >&6; } 30850 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, will use output dir" >&5 30851 $as_echo "yes, will use output dir" >&6; } 30852 fi 30853 fi 30854 30855 JMOD="$BUILD_JDK/bin/jmod" 30856 JLINK="$BUILD_JDK/bin/jlink" 30857 30858 30859 30860 if test "x$BUILD_JDK_FOUND" != "xyes"; then 30861 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Build JDK" >&5 30862 $as_echo_n "checking for Build JDK... " >&6; } 30863 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 30864 $as_echo "no" >&6; } 30865 as_fn_error $? "Could not find a suitable Build JDK" "$LINENO" 5 30866 fi 30867 30868 30869 30870 30871 30872 30873 ############################################################################### 30874 # 30875 # Configure the sources to use. We can add or override individual directories. 30876 # 30877 ############################################################################### 30878 30879 30880 # Where are the sources. 30881 LANGTOOLS_TOPDIR="$SRC_ROOT/langtools" 30882 CORBA_TOPDIR="$SRC_ROOT/corba" 30883 JAXP_TOPDIR="$SRC_ROOT/jaxp" 30884 JAXWS_TOPDIR="$SRC_ROOT/jaxws" 30885 HOTSPOT_TOPDIR="$SRC_ROOT/hotspot" 30886 NASHORN_TOPDIR="$SRC_ROOT/nashorn" 30887 JDK_TOPDIR="$SRC_ROOT/jdk" 30888 30889 30890 30891 30892 30893 30894 30895 30896 30897 # This feature is no longer supported. 30898 30899 30900 30901 # Check whether --with-add-source-root was given. 30902 if test "${with_add_source_root+set}" = set; then : 30903 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 30904 $as_echo "$as_me: WARNING: Option --with-add-source-root is deprecated and will be ignored." >&2;} 30905 fi 30906 30907 30908 30909 30910 # Check whether --with-override-source-root was given. 30911 if test "${with_override_source_root+set}" = set; then : 30912 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 30913 $as_echo "$as_me: WARNING: Option --with-override-source-root is deprecated and will be ignored." >&2;} 30914 fi 30915 30916 30917 30918 30919 # Check whether --with-adds-and-overrides was given. 30920 if test "${with_adds_and_overrides+set}" = set; then : 30921 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 30922 $as_echo "$as_me: WARNING: Option --with-adds-and-overrides is deprecated and will be ignored." >&2;} 30923 fi 30924 30925 30926 30927 30928 # Check whether --with-override-langtools was given. 30929 if test "${with_override_langtools+set}" = set; then : 30930 withval=$with_override_langtools; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-override-langtools is deprecated and will be ignored." >&5 30931 $as_echo "$as_me: WARNING: Option --with-override-langtools is deprecated and will be ignored." >&2;} 30932 fi 30933 30934 30935 30936 30937 # Check whether --with-override-corba was given. 30938 if test "${with_override_corba+set}" = set; then : 30939 withval=$with_override_corba; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-override-corba is deprecated and will be ignored." >&5 30940 $as_echo "$as_me: WARNING: Option --with-override-corba is deprecated and will be ignored." >&2;} 30941 fi 30942 30943 30944 30945 30946 # Check whether --with-override-jaxp was given. 30947 if test "${with_override_jaxp+set}" = set; then : 30948 withval=$with_override_jaxp; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-override-jaxp is deprecated and will be ignored." >&5 30949 $as_echo "$as_me: WARNING: Option --with-override-jaxp is deprecated and will be ignored." >&2;} 30950 fi 30951 30952 30953 30954 30955 # Check whether --with-override-jaxws was given. 30956 if test "${with_override_jaxws+set}" = set; then : 30957 withval=$with_override_jaxws; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-override-jaxws is deprecated and will be ignored." >&5 30958 $as_echo "$as_me: WARNING: Option --with-override-jaxws is deprecated and will be ignored." >&2;} 30959 fi 30960 30961 30962 30963 30964 # Check whether --with-override-hotspot was given. 30965 if test "${with_override_hotspot+set}" = set; then : 30966 withval=$with_override_hotspot; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-override-hotspot is deprecated and will be ignored." >&5 30967 $as_echo "$as_me: WARNING: Option --with-override-hotspot is deprecated and will be ignored." >&2;} 30968 fi 30969 30970 30971 30972 30973 # Check whether --with-override-nashorn was given. 30974 if test "${with_override_nashorn+set}" = set; then : 30975 withval=$with_override_nashorn; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-override-nashorn is deprecated and will be ignored." >&5 30976 $as_echo "$as_me: WARNING: Option --with-override-nashorn is deprecated and will be ignored." >&2;} 30977 fi 30978 30979 30980 30981 30982 # Check whether --with-override-jdk was given. 30983 if test "${with_override_jdk+set}" = set; then : 30984 withval=$with_override_jdk; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-override-jdk is deprecated and will be ignored." >&5 30985 $as_echo "$as_me: WARNING: Option --with-override-jdk is deprecated and will be ignored." >&2;} 30986 fi 30987 30988 30989 30990 30991 BUILD_OUTPUT="$OUTPUT_ROOT" 30992 30993 30994 HOTSPOT_DIST="$OUTPUT_ROOT/hotspot/dist" 30995 BUILD_HOTSPOT=true 30996 30997 30998 30999 # Check whether --with-import-hotspot was given. 31000 if test "${with_import_hotspot+set}" = set; then : 31001 withval=$with_import_hotspot; 31002 fi 31003 31004 if test "x$with_import_hotspot" != x; then 31005 CURDIR="$PWD" 31006 cd "$with_import_hotspot" 31007 HOTSPOT_DIST="`pwd`" 31008 cd "$CURDIR" 31009 if ! (test -d $HOTSPOT_DIST/lib && test -d $HOTSPOT_DIST/jre/lib); then 31010 as_fn_error $? "You have to import hotspot from a full jdk image or hotspot build dist dir!" "$LINENO" 5 31011 fi 31012 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if hotspot should be imported" >&5 31013 $as_echo_n "checking if hotspot should be imported... " >&6; } 31014 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes from $HOTSPOT_DIST" >&5 31015 $as_echo "yes from $HOTSPOT_DIST" >&6; } 31016 BUILD_HOTSPOT=false 31017 fi 31018 31019 JDK_OUTPUTDIR="$OUTPUT_ROOT/jdk" 31020 31021 31022 31023 31024 # Check whether --with-import-modules was given. 31025 if test "${with_import_modules+set}" = set; then : 31026 withval=$with_import_modules; 31027 fi 31028 31029 31030 if test "x$with_import_modules" != x \ 31031 && test "x$with_import_modules" != "xno"; then 31032 if test -d "$with_import_modules"; then 31033 IMPORT_MODULES_TOPDIR="$with_import_modules" 31034 31035 # Only process if variable expands to non-empty 31036 31037 if test "x$IMPORT_MODULES_TOPDIR" != x; then 31038 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31039 31040 # Input might be given as Windows format, start by converting to 31041 # unix format. 31042 path="$IMPORT_MODULES_TOPDIR" 31043 new_path=`$CYGPATH -u "$path"` 31044 31045 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 31046 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 31047 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 31048 # "foo.exe" is OK but "foo" is an error. 31049 # 31050 # This test is therefore slightly more accurate than "test -f" to check for file precense. 31051 # It is also a way to make sure we got the proper file name for the real test later on. 31052 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 31053 if test "x$test_shortpath" = x; then 31054 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of IMPORT_MODULES_TOPDIR, which resolves as \"$path\", is invalid." >&5 31055 $as_echo "$as_me: The path of IMPORT_MODULES_TOPDIR, which resolves as \"$path\", is invalid." >&6;} 31056 as_fn_error $? "Cannot locate the the path of IMPORT_MODULES_TOPDIR" "$LINENO" 5 31057 fi 31058 31059 # Call helper function which possibly converts this using DOS-style short mode. 31060 # If so, the updated path is stored in $new_path. 31061 31062 input_path="$new_path" 31063 # Check if we need to convert this using DOS-style short mode. If the path 31064 # contains just simple characters, use it. Otherwise (spaces, weird characters), 31065 # take no chances and rewrite it. 31066 # Note: m4 eats our [], so we need to use [ and ] instead. 31067 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 31068 if test "x$has_forbidden_chars" != x; then 31069 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 31070 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 31071 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 31072 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 31073 # Going to short mode and back again did indeed matter. Since short mode is 31074 # case insensitive, let's make it lowercase to improve readability. 31075 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 31076 # Now convert it back to Unix-style (cygpath) 31077 input_path=`$CYGPATH -u "$shortmode_path"` 31078 new_path="$input_path" 31079 fi 31080 fi 31081 31082 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 31083 if test "x$test_cygdrive_prefix" = x; then 31084 # As a simple fix, exclude /usr/bin since it's not a real path. 31085 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 31086 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 31087 # a path prefixed by /cygdrive for fixpath to work. 31088 new_path="$CYGWIN_ROOT_PATH$input_path" 31089 fi 31090 fi 31091 31092 31093 if test "x$path" != "x$new_path"; then 31094 IMPORT_MODULES_TOPDIR="$new_path" 31095 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting IMPORT_MODULES_TOPDIR to \"$new_path\"" >&5 31096 $as_echo "$as_me: Rewriting IMPORT_MODULES_TOPDIR to \"$new_path\"" >&6;} 31097 fi 31098 31099 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31100 31101 path="$IMPORT_MODULES_TOPDIR" 31102 has_colon=`$ECHO $path | $GREP ^.:` 31103 new_path="$path" 31104 if test "x$has_colon" = x; then 31105 # Not in mixed or Windows style, start by that. 31106 new_path=`cmd //c echo $path` 31107 fi 31108 31109 31110 input_path="$new_path" 31111 # Check if we need to convert this using DOS-style short mode. If the path 31112 # contains just simple characters, use it. Otherwise (spaces, weird characters), 31113 # take no chances and rewrite it. 31114 # Note: m4 eats our [], so we need to use [ and ] instead. 31115 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 31116 if test "x$has_forbidden_chars" != x; then 31117 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 31118 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 31119 fi 31120 31121 31122 windows_path="$new_path" 31123 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31124 unix_path=`$CYGPATH -u "$windows_path"` 31125 new_path="$unix_path" 31126 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31127 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31128 new_path="$unix_path" 31129 fi 31130 31131 if test "x$path" != "x$new_path"; then 31132 IMPORT_MODULES_TOPDIR="$new_path" 31133 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting IMPORT_MODULES_TOPDIR to \"$new_path\"" >&5 31134 $as_echo "$as_me: Rewriting IMPORT_MODULES_TOPDIR to \"$new_path\"" >&6;} 31135 fi 31136 31137 # Save the first 10 bytes of this path to the storage, so fixpath can work. 31138 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 31139 31140 else 31141 # We're on a unix platform. Hooray! :) 31142 path="$IMPORT_MODULES_TOPDIR" 31143 has_space=`$ECHO "$path" | $GREP " "` 31144 if test "x$has_space" != x; then 31145 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of IMPORT_MODULES_TOPDIR, which resolves as \"$path\", is invalid." >&5 31146 $as_echo "$as_me: The path of IMPORT_MODULES_TOPDIR, which resolves as \"$path\", is invalid." >&6;} 31147 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 31148 fi 31149 31150 # Use eval to expand a potential ~ 31151 eval path="$path" 31152 if test ! -f "$path" && test ! -d "$path"; then 31153 as_fn_error $? "The path of IMPORT_MODULES_TOPDIR, which resolves as \"$path\", is not found." "$LINENO" 5 31154 fi 31155 31156 if test -d "$path"; then 31157 IMPORT_MODULES_TOPDIR="`cd "$path"; $THEPWDCMD -L`" 31158 else 31159 dir="`$DIRNAME "$path"`" 31160 base="`$BASENAME "$path"`" 31161 IMPORT_MODULES_TOPDIR="`cd "$dir"; $THEPWDCMD -L`/$base" 31162 fi 31163 fi 31164 fi 31165 31166 elif test -e "$with_import_modules"; then 31167 IMPORT_MODULES_TOPDIR="$CONFIGURESUPPORT_OUTPUTDIR/import-modules" 31168 $RM -rf "$IMPORT_MODULES_TOPDIR" 31169 $MKDIR -p "$IMPORT_MODULES_TOPDIR" 31170 if ! $UNZIP -q "$with_import_modules" -d "$IMPORT_MODULES_TOPDIR"; then 31171 as_fn_error $? "--with-import-modules=\"$with_import_modules\" must point to a dir or a zip file" "$LINENO" 5 31172 fi 31173 else 31174 as_fn_error $? "--with-import-modules=\"$with_import_modules\" must point to a dir or a zip file" "$LINENO" 5 31175 fi 31176 fi 31177 31178 if test -d "$IMPORT_MODULES_TOPDIR/modules"; then 31179 IMPORT_MODULES_CLASSES="$IMPORT_MODULES_TOPDIR/modules" 31180 fi 31181 if test -d "$IMPORT_MODULES_TOPDIR/modules_cmds"; then 31182 IMPORT_MODULES_CMDS="$IMPORT_MODULES_TOPDIR/modules_cmds" 31183 fi 31184 if test -d "$IMPORT_MODULES_TOPDIR/modules_libs"; then 31185 IMPORT_MODULES_LIBS="$IMPORT_MODULES_TOPDIR/modules_libs" 31186 fi 31187 if test -d "$IMPORT_MODULES_TOPDIR/modules_conf"; then 31188 IMPORT_MODULES_CONF="$IMPORT_MODULES_TOPDIR/modules_conf" 31189 fi 31190 if test -d "$IMPORT_MODULES_TOPDIR/modules_src"; then 31191 IMPORT_MODULES_SRC="$IMPORT_MODULES_TOPDIR/modules_src" 31192 fi 31193 if test -d "$IMPORT_MODULES_TOPDIR/make"; then 31194 IMPORT_MODULES_MAKE="$IMPORT_MODULES_TOPDIR/make" 31195 fi 31196 31197 31198 31199 31200 31201 31202 31203 31204 31205 ############################################################################### 31206 # 31207 # Setup the toolchain (compilers etc), i.e. tools used to compile and process 31208 # native code. 31209 # 31210 ############################################################################### 31211 31212 # See if we are doing a complete static build or not 31213 31214 # Check whether --enable-static-build was given. 31215 if test "${enable_static_build+set}" = set; then : 31216 enableval=$enable_static_build; 31217 fi 31218 31219 STATIC_BUILD=false 31220 if test "x$enable_static_build" = "xyes"; then 31221 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if static build is enabled" >&5 31222 $as_echo_n "checking if static build is enabled... " >&6; } 31223 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 31224 $as_echo "yes" >&6; } 31225 if test "x$OPENJDK_TARGET_OS" != "xmacosx"; then 31226 as_fn_error $? "--enable-static-build is only supported for macosx builds" "$LINENO" 5 31227 fi 31228 STATIC_BUILD_CFLAGS="-DSTATIC_BUILD=1" 31229 LEGACY_EXTRA_CFLAGS="$LEGACY_EXTRA_CFLAGS $STATIC_BUILD_CFLAGS" 31230 LEGACY_EXTRA_CXXFLAGS="$LEGACY_EXTRA_CXXFLAGS $STATIC_BUILD_CFLAGS" 31231 CFLAGS_JDKLIB_EXTRA="$CFLAGS_JDKLIB_EXTRA $STATIC_BUILD_CFLAGS" 31232 CXXFLAGS_JDKLIB_EXTRA="$CXXFLAGS_JDKLIB_EXTRA $STATIC_BUILD_CFLAGS" 31233 STATIC_BUILD=true 31234 elif test "x$enable_static_build" = "xno"; then 31235 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if static build is enabled" >&5 31236 $as_echo_n "checking if static build is enabled... " >&6; } 31237 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 31238 $as_echo "no" >&6; } 31239 elif test "x$enable_static_build" != "x"; then 31240 as_fn_error $? "--enable-static-build can only be assigned \"yes\" or \"no\"" "$LINENO" 5 31241 fi 31242 31243 31244 31245 31246 # First determine the toolchain type (compiler family) 31247 31248 31249 # Check whether --with-toolchain-type was given. 31250 if test "${with_toolchain_type+set}" = set; then : 31251 withval=$with_toolchain_type; 31252 fi 31253 31254 31255 # Use indirect variable referencing 31256 toolchain_var_name=VALID_TOOLCHAINS_$OPENJDK_BUILD_OS 31257 VALID_TOOLCHAINS=${!toolchain_var_name} 31258 31259 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 31260 if test -n "$XCODEBUILD"; then 31261 # On Mac OS X, default toolchain to clang after Xcode 5 31262 XCODE_VERSION_OUTPUT=`"$XCODEBUILD" -version 2>&1 | $HEAD -n 1` 31263 $ECHO "$XCODE_VERSION_OUTPUT" | $GREP "Xcode " > /dev/null 31264 if test $? -ne 0; then 31265 as_fn_error $? "Failed to determine Xcode version." "$LINENO" 5 31266 fi 31267 XCODE_MAJOR_VERSION=`$ECHO $XCODE_VERSION_OUTPUT | \ 31268 $SED -e 's/^Xcode \([1-9][0-9.]*\)/\1/' | \ 31269 $CUT -f 1 -d .` 31270 { $as_echo "$as_me:${as_lineno-$LINENO}: Xcode major version: $XCODE_MAJOR_VERSION" >&5 31271 $as_echo "$as_me: Xcode major version: $XCODE_MAJOR_VERSION" >&6;} 31272 if test $XCODE_MAJOR_VERSION -ge 5; then 31273 DEFAULT_TOOLCHAIN="clang" 31274 else 31275 DEFAULT_TOOLCHAIN="gcc" 31276 fi 31277 else 31278 # If Xcode is not installed, but the command line tools are 31279 # then we can't run xcodebuild. On these systems we should 31280 # default to clang 31281 DEFAULT_TOOLCHAIN="clang" 31282 fi 31283 else 31284 # First toolchain type in the list is the default 31285 DEFAULT_TOOLCHAIN=${VALID_TOOLCHAINS%% *} 31286 fi 31287 31288 if test "x$with_toolchain_type" = xlist; then 31289 # List all toolchains 31290 { $as_echo "$as_me:${as_lineno-$LINENO}: The following toolchains are valid on this platform:" >&5 31291 $as_echo "$as_me: The following toolchains are valid on this platform:" >&6;} 31292 for toolchain in $VALID_TOOLCHAINS; do 31293 toolchain_var_name=TOOLCHAIN_DESCRIPTION_$toolchain 31294 TOOLCHAIN_DESCRIPTION=${!toolchain_var_name} 31295 $PRINTF " %-10s %s\n" $toolchain "$TOOLCHAIN_DESCRIPTION" 31296 done 31297 31298 exit 0 31299 elif test "x$with_toolchain_type" != x; then 31300 # User override; check that it is valid 31301 if test "x${VALID_TOOLCHAINS/$with_toolchain_type/}" = "x${VALID_TOOLCHAINS}"; then 31302 { $as_echo "$as_me:${as_lineno-$LINENO}: Toolchain type $with_toolchain_type is not valid on this platform." >&5 31303 $as_echo "$as_me: Toolchain type $with_toolchain_type is not valid on this platform." >&6;} 31304 { $as_echo "$as_me:${as_lineno-$LINENO}: Valid toolchains: $VALID_TOOLCHAINS." >&5 31305 $as_echo "$as_me: Valid toolchains: $VALID_TOOLCHAINS." >&6;} 31306 as_fn_error $? "Cannot continue." "$LINENO" 5 31307 fi 31308 TOOLCHAIN_TYPE=$with_toolchain_type 31309 else 31310 # No flag given, use default 31311 TOOLCHAIN_TYPE=$DEFAULT_TOOLCHAIN 31312 fi 31313 31314 31315 TOOLCHAIN_CC_BINARY_clang="clang" 31316 TOOLCHAIN_CC_BINARY_gcc="gcc" 31317 TOOLCHAIN_CC_BINARY_microsoft="cl" 31318 TOOLCHAIN_CC_BINARY_solstudio="cc" 31319 TOOLCHAIN_CC_BINARY_xlc="xlc_r" 31320 31321 TOOLCHAIN_CXX_BINARY_clang="clang++" 31322 TOOLCHAIN_CXX_BINARY_gcc="g++" 31323 TOOLCHAIN_CXX_BINARY_microsoft="cl" 31324 TOOLCHAIN_CXX_BINARY_solstudio="CC" 31325 TOOLCHAIN_CXX_BINARY_xlc="xlC_r" 31326 31327 # Use indirect variable referencing 31328 toolchain_var_name=TOOLCHAIN_DESCRIPTION_$TOOLCHAIN_TYPE 31329 TOOLCHAIN_DESCRIPTION=${!toolchain_var_name} 31330 toolchain_var_name=TOOLCHAIN_MINIMUM_VERSION_$TOOLCHAIN_TYPE 31331 TOOLCHAIN_MINIMUM_VERSION=${!toolchain_var_name} 31332 toolchain_var_name=TOOLCHAIN_CC_BINARY_$TOOLCHAIN_TYPE 31333 TOOLCHAIN_CC_BINARY=${!toolchain_var_name} 31334 toolchain_var_name=TOOLCHAIN_CXX_BINARY_$TOOLCHAIN_TYPE 31335 TOOLCHAIN_CXX_BINARY=${!toolchain_var_name} 31336 31337 31338 # Define filename patterns 31339 if test "x$OPENJDK_TARGET_OS" = xwindows; then 31340 LIBRARY_PREFIX= 31341 SHARED_LIBRARY_SUFFIX='.dll' 31342 STATIC_LIBRARY_SUFFIX='.lib' 31343 SHARED_LIBRARY='$1.dll' 31344 STATIC_LIBRARY='$1.lib' 31345 OBJ_SUFFIX='.obj' 31346 EXE_SUFFIX='.exe' 31347 else 31348 LIBRARY_PREFIX=lib 31349 SHARED_LIBRARY_SUFFIX='.so' 31350 STATIC_LIBRARY_SUFFIX='.a' 31351 SHARED_LIBRARY='lib$1.so' 31352 STATIC_LIBRARY='lib$1.a' 31353 OBJ_SUFFIX='.o' 31354 EXE_SUFFIX='' 31355 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 31356 # For full static builds, we're overloading the SHARED_LIBRARY 31357 # variables in order to limit the amount of changes required. 31358 # It would be better to remove SHARED and just use LIBRARY and 31359 # LIBRARY_SUFFIX for libraries that can be built either 31360 # shared or static and use STATIC_* for libraries that are 31361 # always built statically. 31362 if test "x$STATIC_BUILD" = xtrue; then 31363 SHARED_LIBRARY='lib$1.a' 31364 SHARED_LIBRARY_SUFFIX='.a' 31365 else 31366 SHARED_LIBRARY='lib$1.dylib' 31367 SHARED_LIBRARY_SUFFIX='.dylib' 31368 fi 31369 fi 31370 fi 31371 31372 31373 31374 31375 31376 31377 31378 31379 31380 31381 if test "x$TOOLCHAIN_TYPE" = "x$DEFAULT_TOOLCHAIN"; then 31382 { $as_echo "$as_me:${as_lineno-$LINENO}: Using default toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION)" >&5 31383 $as_echo "$as_me: Using default toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION)" >&6;} 31384 else 31385 { $as_echo "$as_me:${as_lineno-$LINENO}: Using user selected toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION). Default toolchain is $DEFAULT_TOOLCHAIN." >&5 31386 $as_echo "$as_me: Using user selected toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION). Default toolchain is $DEFAULT_TOOLCHAIN." >&6;} 31387 fi 31388 31389 31390 # User supplied flags should be used when configure detects compilers 31391 31392 if test "x$CFLAGS" != "x${ADDED_CFLAGS}"; then 31393 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring CFLAGS($CFLAGS) found in environment. Use --with-extra-cflags" >&5 31394 $as_echo "$as_me: WARNING: Ignoring CFLAGS($CFLAGS) found in environment. Use --with-extra-cflags" >&2;} 31395 fi 31396 31397 if test "x$CXXFLAGS" != "x${ADDED_CXXFLAGS}"; then 31398 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring CXXFLAGS($CXXFLAGS) found in environment. Use --with-extra-cxxflags" >&5 31399 $as_echo "$as_me: WARNING: Ignoring CXXFLAGS($CXXFLAGS) found in environment. Use --with-extra-cxxflags" >&2;} 31400 fi 31401 31402 if test "x$LDFLAGS" != "x${ADDED_LDFLAGS}"; then 31403 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring LDFLAGS($LDFLAGS) found in environment. Use --with-extra-ldflags" >&5 31404 $as_echo "$as_me: WARNING: Ignoring LDFLAGS($LDFLAGS) found in environment. Use --with-extra-ldflags" >&2;} 31405 fi 31406 31407 31408 # Check whether --with-extra-cflags was given. 31409 if test "${with_extra_cflags+set}" = set; then : 31410 withval=$with_extra_cflags; 31411 fi 31412 31413 31414 31415 # Check whether --with-extra-cxxflags was given. 31416 if test "${with_extra_cxxflags+set}" = set; then : 31417 withval=$with_extra_cxxflags; 31418 fi 31419 31420 31421 31422 # Check whether --with-extra-ldflags was given. 31423 if test "${with_extra_ldflags+set}" = set; then : 31424 withval=$with_extra_ldflags; 31425 fi 31426 31427 31428 EXTRA_CFLAGS="$with_extra_cflags" 31429 EXTRA_CXXFLAGS="$with_extra_cxxflags" 31430 EXTRA_LDFLAGS="$with_extra_ldflags" 31431 31432 # Hotspot needs these set in their legacy form 31433 LEGACY_EXTRA_CFLAGS="$LEGACY_EXTRA_CFLAGS $EXTRA_CFLAGS" 31434 LEGACY_EXTRA_CXXFLAGS="$LEGACY_EXTRA_CXXFLAGS $EXTRA_CXXFLAGS" 31435 LEGACY_EXTRA_LDFLAGS="$LEGACY_EXTRA_LDFLAGS $EXTRA_LDFLAGS" 31436 31437 31438 31439 31440 31441 31442 31443 31444 31445 # The global CFLAGS and LDLAGS variables are used by configure tests and 31446 # should include the extra parameters 31447 CFLAGS="$EXTRA_CFLAGS" 31448 CXXFLAGS="$EXTRA_CXXFLAGS" 31449 LDFLAGS="$EXTRA_LDFLAGS" 31450 CPPFLAGS="" 31451 31452 # The sysroot cflags are needed for configure to be able to run the compilers 31453 31454 if test "x$SYSROOT" != "x"; then 31455 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 31456 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 31457 # Solaris Studio does not have a concept of sysroot. Instead we must 31458 # make sure the default include and lib dirs are appended to each 31459 # compile and link command line. Must also add -I-xbuiltin to enable 31460 # inlining of system functions and intrinsics. 31461 SYSROOT_CFLAGS="-I-xbuiltin -I$SYSROOT/usr/include" 31462 SYSROOT_LDFLAGS="-L$SYSROOT/usr/lib$OPENJDK_TARGET_CPU_ISADIR \ 31463 -L$SYSROOT/lib$OPENJDK_TARGET_CPU_ISADIR" 31464 fi 31465 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 31466 SYSROOT_CFLAGS="--sysroot=$SYSROOT" 31467 SYSROOT_LDFLAGS="--sysroot=$SYSROOT" 31468 elif test "x$TOOLCHAIN_TYPE" = xclang; then 31469 SYSROOT_CFLAGS="-isysroot $SYSROOT" 31470 SYSROOT_LDFLAGS="-isysroot $SYSROOT" 31471 fi 31472 # Propagate the sysroot args to hotspot 31473 LEGACY_EXTRA_CFLAGS="$LEGACY_EXTRA_CFLAGS $SYSROOT_CFLAGS" 31474 LEGACY_EXTRA_CXXFLAGS="$LEGACY_EXTRA_CXXFLAGS $SYSROOT_CFLAGS" 31475 LEGACY_EXTRA_LDFLAGS="$LEGACY_EXTRA_LDFLAGS $SYSROOT_LDFLAGS" 31476 # The global CFLAGS and LDFLAGS variables need these for configure to function 31477 CFLAGS="$CFLAGS $SYSROOT_CFLAGS" 31478 CPPFLAGS="$CPPFLAGS $SYSROOT_CFLAGS" 31479 CXXFLAGS="$CXXFLAGS $SYSROOT_CFLAGS" 31480 LDFLAGS="$LDFLAGS $SYSROOT_LDFLAGS" 31481 fi 31482 31483 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 31484 # We also need -iframework<path>/System/Library/Frameworks 31485 SYSROOT_CFLAGS="$SYSROOT_CFLAGS -iframework $SYSROOT/System/Library/Frameworks" 31486 SYSROOT_LDFLAGS="$SYSROOT_LDFLAGS -iframework $SYSROOT/System/Library/Frameworks" 31487 # These always need to be set, or we can't find the frameworks embedded in JavaVM.framework 31488 # set this here so it doesn't have to be peppered throughout the forest 31489 SYSROOT_CFLAGS="$SYSROOT_CFLAGS -F $SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks" 31490 SYSROOT_LDFLAGS="$SYSROOT_LDFLAGS -F $SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks" 31491 fi 31492 31493 31494 31495 31496 31497 # Then detect the actual binaries needed 31498 31499 # FIXME: Is this needed? 31500 ac_ext=cpp 31501 ac_cpp='$CXXCPP $CPPFLAGS' 31502 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 31503 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 31504 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 31505 31506 31507 # Store the CFLAGS etc passed to the configure script. 31508 ORG_CFLAGS="$CFLAGS" 31509 ORG_CXXFLAGS="$CXXFLAGS" 31510 31511 # autoconf magic only relies on PATH, so update it if tools dir is specified 31512 OLD_PATH="$PATH" 31513 31514 # On Windows, we need to detect the visual studio installation first. 31515 # This will change the PATH, but we need to keep that new PATH even 31516 # after toolchain detection is done, since the compiler (on x86) uses 31517 # it for DLL resolution in runtime. 31518 if test "x$OPENJDK_BUILD_OS" = "xwindows" \ 31519 && test "x$TOOLCHAIN_TYPE" = "xmicrosoft"; then 31520 31521 # Store path to cygwin link.exe to help excluding it when searching for 31522 # VS linker. This must be done before changing the PATH when looking for VS. 31523 # Extract the first word of "link", so it can be a program name with args. 31524 set dummy link; ac_word=$2 31525 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 31526 $as_echo_n "checking for $ac_word... " >&6; } 31527 if ${ac_cv_path_CYGWIN_LINK+:} false; then : 31528 $as_echo_n "(cached) " >&6 31529 else 31530 case $CYGWIN_LINK in 31531 [\\/]* | ?:[\\/]*) 31532 ac_cv_path_CYGWIN_LINK="$CYGWIN_LINK" # Let the user override the test with a path. 31533 ;; 31534 *) 31535 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 31536 for as_dir in $PATH 31537 do 31538 IFS=$as_save_IFS 31539 test -z "$as_dir" && as_dir=. 31540 for ac_exec_ext in '' $ac_executable_extensions; do 31541 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 31542 ac_cv_path_CYGWIN_LINK="$as_dir/$ac_word$ac_exec_ext" 31543 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 31544 break 2 31545 fi 31546 done 31547 done 31548 IFS=$as_save_IFS 31549 31550 ;; 31551 esac 31552 fi 31553 CYGWIN_LINK=$ac_cv_path_CYGWIN_LINK 31554 if test -n "$CYGWIN_LINK"; then 31555 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_LINK" >&5 31556 $as_echo "$CYGWIN_LINK" >&6; } 31557 else 31558 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 31559 $as_echo "no" >&6; } 31560 fi 31561 31562 31563 if test "x$CYGWIN_LINK" != x; then 31564 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the first found link.exe is actually the Cygwin link tool" >&5 31565 $as_echo_n "checking if the first found link.exe is actually the Cygwin link tool... " >&6; } 31566 "$CYGWIN_LINK" --version > /dev/null 31567 if test $? -eq 0 ; then 31568 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 31569 $as_echo "yes" >&6; } 31570 else 31571 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 31572 $as_echo "no" >&6; } 31573 # This might be the VS linker. Don't exclude it later on. 31574 CYGWIN_LINK="" 31575 fi 31576 fi 31577 31578 # First-hand choice is to locate and run the vsvars bat file. 31579 31580 31581 # Check whether --with-toolchain-version was given. 31582 if test "${with_toolchain_version+set}" = set; then : 31583 withval=$with_toolchain_version; 31584 fi 31585 31586 31587 if test "x$with_toolchain_version" = xlist; then 31588 # List all toolchains 31589 { $as_echo "$as_me:${as_lineno-$LINENO}: The following toolchain versions are valid on this platform:" >&5 31590 $as_echo "$as_me: The following toolchain versions are valid on this platform:" >&6;} 31591 for version in $VALID_VS_VERSIONS; do 31592 eval VS_DESCRIPTION=\${VS_DESCRIPTION_$version} 31593 $PRINTF " %-10s %s\n" $version "$VS_DESCRIPTION" 31594 done 31595 31596 exit 0 31597 elif test "x$DEVKIT_VS_VERSION" != x; then 31598 VS_VERSION=$DEVKIT_VS_VERSION 31599 TOOLCHAIN_VERSION=$VS_VERSION 31600 eval VS_DESCRIPTION="\${VS_DESCRIPTION_${VS_VERSION}}" 31601 eval VS_VERSION_INTERNAL="\${VS_VERSION_INTERNAL_${VS_VERSION}}" 31602 eval MSVCR_NAME="\${VS_MSVCR_${VS_VERSION}}" 31603 eval MSVCP_NAME="\${VS_MSVCP_${VS_VERSION}}" 31604 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 31605 VS_PATH="$TOOLCHAIN_PATH:$PATH" 31606 31607 # Convert DEVKIT_VS_INCLUDE into windows style VS_INCLUDE so that it 31608 # can still be exported as INCLUDE for compiler invocations without 31609 # SYSROOT_CFLAGS 31610 OLDIFS="$IFS" 31611 IFS=";" 31612 for i in $DEVKIT_VS_INCLUDE; do 31613 ipath=$i 31614 31615 unix_path="$ipath" 31616 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31617 windows_path=`$CYGPATH -m "$unix_path"` 31618 ipath="$windows_path" 31619 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31620 windows_path=`cmd //c echo $unix_path` 31621 ipath="$windows_path" 31622 fi 31623 31624 VS_INCLUDE="$VS_INCLUDE;$ipath" 31625 done 31626 # Convert DEVKIT_VS_LIB into VS_LIB so that it can still be exported 31627 # as LIB for compiler invocations without SYSROOT_LDFLAGS 31628 for i in $DEVKIT_VS_LIB; do 31629 libpath=$i 31630 31631 unix_path="$libpath" 31632 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31633 windows_path=`$CYGPATH -m "$unix_path"` 31634 libpath="$windows_path" 31635 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31636 windows_path=`cmd //c echo $unix_path` 31637 libpath="$windows_path" 31638 fi 31639 31640 VS_LIB="$VS_LIB;$libpath" 31641 done 31642 IFS="$OLDIFS" 31643 31644 { $as_echo "$as_me:${as_lineno-$LINENO}: Found devkit $VS_DESCRIPTION" >&5 31645 $as_echo "$as_me: Found devkit $VS_DESCRIPTION" >&6;} 31646 31647 elif test "x$with_toolchain_version" != x; then 31648 # User override; check that it is valid 31649 if test "x${VALID_VS_VERSIONS/$with_toolchain_version/}" = "x${VALID_VS_VERSIONS}"; then 31650 { $as_echo "$as_me:${as_lineno-$LINENO}: Visual Studio version $with_toolchain_version is not valid." >&5 31651 $as_echo "$as_me: Visual Studio version $with_toolchain_version is not valid." >&6;} 31652 { $as_echo "$as_me:${as_lineno-$LINENO}: Valid Visual Studio versions: $VALID_VS_VERSIONS." >&5 31653 $as_echo "$as_me: Valid Visual Studio versions: $VALID_VS_VERSIONS." >&6;} 31654 as_fn_error $? "Cannot continue." "$LINENO" 5 31655 fi 31656 VS_VERSIONS_PROBE_LIST="$with_toolchain_version" 31657 else 31658 # No flag given, use default 31659 VS_VERSIONS_PROBE_LIST="$VALID_VS_VERSIONS" 31660 fi 31661 31662 for VS_VERSION in $VS_VERSIONS_PROBE_LIST; do 31663 31664 VS_VERSION="$VS_VERSION" 31665 eval VS_COMNTOOLS_VAR="\${VS_ENVVAR_${VS_VERSION}}" 31666 eval VS_COMNTOOLS="\$${VS_COMNTOOLS_VAR}" 31667 eval VS_INSTALL_DIR="\${VS_VS_INSTALLDIR_${VS_VERSION}}" 31668 eval SDK_INSTALL_DIR="\${VS_SDK_INSTALLDIR_${VS_VERSION}}" 31669 31670 # When using --with-tools-dir, assume it points to the correct and default 31671 # version of Visual Studio or that --with-toolchain-version was also set. 31672 if test "x$with_tools_dir" != x; then 31673 31674 if test "x$VS_ENV_CMD" = x; then 31675 VS_VERSION="${VS_VERSION}" 31676 VS_BASE="$with_tools_dir/../.." 31677 METHOD="--with-tools-dir" 31678 31679 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 31680 VCVARSFILE="vc/bin/vcvars32.bat" 31681 else 31682 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 31683 fi 31684 31685 31686 windows_path="$VS_BASE" 31687 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31688 unix_path=`$CYGPATH -u "$windows_path"` 31689 VS_BASE="$unix_path" 31690 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31691 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31692 VS_BASE="$unix_path" 31693 fi 31694 31695 if test -d "$VS_BASE"; then 31696 if test -f "$VS_BASE/$VCVARSFILE"; then 31697 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31698 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31699 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 31700 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 31701 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 31702 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 31703 else 31704 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31705 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31706 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 31707 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 31708 fi 31709 fi 31710 fi 31711 31712 31713 if test "x$VS_ENV_CMD" = x; then 31714 VS_VERSION="${VS_VERSION}" 31715 VS_BASE="$with_tools_dir/../../.." 31716 METHOD="--with-tools-dir" 31717 31718 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 31719 VCVARSFILE="vc/bin/vcvars32.bat" 31720 else 31721 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 31722 fi 31723 31724 31725 windows_path="$VS_BASE" 31726 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31727 unix_path=`$CYGPATH -u "$windows_path"` 31728 VS_BASE="$unix_path" 31729 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31730 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31731 VS_BASE="$unix_path" 31732 fi 31733 31734 if test -d "$VS_BASE"; then 31735 if test -f "$VS_BASE/$VCVARSFILE"; then 31736 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31737 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31738 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 31739 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 31740 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 31741 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 31742 else 31743 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31744 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31745 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 31746 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 31747 fi 31748 fi 31749 fi 31750 31751 if test "x$VS_ENV_CMD" = x; then 31752 # Having specified an argument which is incorrect will produce an instant failure; 31753 # we should not go on looking 31754 { $as_echo "$as_me:${as_lineno-$LINENO}: The path given by --with-tools-dir does not contain a valid" >&5 31755 $as_echo "$as_me: The path given by --with-tools-dir does not contain a valid" >&6;} 31756 { $as_echo "$as_me:${as_lineno-$LINENO}: Visual Studio installation. Please point to the VC/bin or VC/bin/amd64" >&5 31757 $as_echo "$as_me: Visual Studio installation. Please point to the VC/bin or VC/bin/amd64" >&6;} 31758 { $as_echo "$as_me:${as_lineno-$LINENO}: directory within the Visual Studio installation" >&5 31759 $as_echo "$as_me: directory within the Visual Studio installation" >&6;} 31760 as_fn_error $? "Cannot locate a valid Visual Studio installation" "$LINENO" 5 31761 fi 31762 fi 31763 31764 VS_ENV_CMD="" 31765 VS_ENV_ARGS="" 31766 31767 if test "x$VS_COMNTOOLS" != x; then 31768 31769 if test "x$VS_ENV_CMD" = x; then 31770 VS_VERSION="${VS_VERSION}" 31771 VS_BASE="$VS_COMNTOOLS/../.." 31772 METHOD="$VS_COMNTOOLS_VAR variable" 31773 31774 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 31775 VCVARSFILE="vc/bin/vcvars32.bat" 31776 else 31777 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 31778 fi 31779 31780 31781 windows_path="$VS_BASE" 31782 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31783 unix_path=`$CYGPATH -u "$windows_path"` 31784 VS_BASE="$unix_path" 31785 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31786 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31787 VS_BASE="$unix_path" 31788 fi 31789 31790 if test -d "$VS_BASE"; then 31791 if test -f "$VS_BASE/$VCVARSFILE"; then 31792 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31793 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31794 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 31795 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 31796 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 31797 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 31798 else 31799 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31800 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31801 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 31802 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 31803 fi 31804 fi 31805 fi 31806 31807 fi 31808 if test "x$PROGRAMFILES" != x; then 31809 31810 if test "x$VS_ENV_CMD" = x; then 31811 VS_VERSION="${VS_VERSION}" 31812 VS_BASE="$PROGRAMFILES/$VS_INSTALL_DIR" 31813 METHOD="well-known name" 31814 31815 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 31816 VCVARSFILE="vc/bin/vcvars32.bat" 31817 else 31818 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 31819 fi 31820 31821 31822 windows_path="$VS_BASE" 31823 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31824 unix_path=`$CYGPATH -u "$windows_path"` 31825 VS_BASE="$unix_path" 31826 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31827 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31828 VS_BASE="$unix_path" 31829 fi 31830 31831 if test -d "$VS_BASE"; then 31832 if test -f "$VS_BASE/$VCVARSFILE"; then 31833 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31834 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31835 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 31836 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 31837 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 31838 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 31839 else 31840 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31841 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31842 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 31843 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 31844 fi 31845 fi 31846 fi 31847 31848 fi 31849 # Work around the insanely named ProgramFiles(x86) env variable 31850 PROGRAMFILES_X86="`env | $SED -n 's/^ProgramFiles(x86)=//p'`" 31851 if test "x$PROGRAMFILES_X86" != x; then 31852 31853 if test "x$VS_ENV_CMD" = x; then 31854 VS_VERSION="${VS_VERSION}" 31855 VS_BASE="$PROGRAMFILES_X86/$VS_INSTALL_DIR" 31856 METHOD="well-known name" 31857 31858 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 31859 VCVARSFILE="vc/bin/vcvars32.bat" 31860 else 31861 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 31862 fi 31863 31864 31865 windows_path="$VS_BASE" 31866 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31867 unix_path=`$CYGPATH -u "$windows_path"` 31868 VS_BASE="$unix_path" 31869 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31870 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31871 VS_BASE="$unix_path" 31872 fi 31873 31874 if test -d "$VS_BASE"; then 31875 if test -f "$VS_BASE/$VCVARSFILE"; then 31876 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31877 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31878 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 31879 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 31880 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 31881 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 31882 else 31883 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31884 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31885 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 31886 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 31887 fi 31888 fi 31889 fi 31890 31891 fi 31892 31893 if test "x$VS_ENV_CMD" = x; then 31894 VS_VERSION="${VS_VERSION}" 31895 VS_BASE="C:/Program Files/$VS_INSTALL_DIR" 31896 METHOD="well-known name" 31897 31898 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 31899 VCVARSFILE="vc/bin/vcvars32.bat" 31900 else 31901 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 31902 fi 31903 31904 31905 windows_path="$VS_BASE" 31906 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31907 unix_path=`$CYGPATH -u "$windows_path"` 31908 VS_BASE="$unix_path" 31909 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31910 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31911 VS_BASE="$unix_path" 31912 fi 31913 31914 if test -d "$VS_BASE"; then 31915 if test -f "$VS_BASE/$VCVARSFILE"; then 31916 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31917 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31918 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 31919 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 31920 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 31921 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 31922 else 31923 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31924 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31925 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 31926 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 31927 fi 31928 fi 31929 fi 31930 31931 31932 if test "x$VS_ENV_CMD" = x; then 31933 VS_VERSION="${VS_VERSION}" 31934 VS_BASE="C:/Program Files (x86)/$VS_INSTALL_DIR" 31935 METHOD="well-known name" 31936 31937 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 31938 VCVARSFILE="vc/bin/vcvars32.bat" 31939 else 31940 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 31941 fi 31942 31943 31944 windows_path="$VS_BASE" 31945 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31946 unix_path=`$CYGPATH -u "$windows_path"` 31947 VS_BASE="$unix_path" 31948 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31949 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31950 VS_BASE="$unix_path" 31951 fi 31952 31953 if test -d "$VS_BASE"; then 31954 if test -f "$VS_BASE/$VCVARSFILE"; then 31955 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31956 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31957 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 31958 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 31959 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 31960 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 31961 else 31962 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 31963 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 31964 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 31965 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 31966 fi 31967 fi 31968 fi 31969 31970 31971 if test "x$SDK_INSTALL_DIR" != x; then 31972 if test "x$ProgramW6432" != x; then 31973 31974 if test "x$VS_ENV_CMD" = x; then 31975 VS_VERSION="${VS_VERSION}" 31976 WIN_SDK_BASE="$ProgramW6432/$SDK_INSTALL_DIR" 31977 METHOD="well-known name" 31978 31979 windows_path="$WIN_SDK_BASE" 31980 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31981 unix_path=`$CYGPATH -u "$windows_path"` 31982 WIN_SDK_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 WIN_SDK_BASE="$unix_path" 31986 fi 31987 31988 if test -d "$WIN_SDK_BASE"; then 31989 # There have been cases of partial or broken SDK installations. A missing 31990 # lib dir is not going to work. 31991 if test ! -d "$WIN_SDK_BASE/lib"; then 31992 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 31993 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 31994 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 31995 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 31996 elif test -f "$WIN_SDK_BASE/Bin/SetEnv.Cmd"; then 31997 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 31998 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 31999 VS_ENV_CMD="$WIN_SDK_BASE/Bin/SetEnv.Cmd" 32000 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32001 VS_ENV_ARGS="/x86" 32002 else 32003 VS_ENV_ARGS="/x64" 32004 fi 32005 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32006 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK 32007 # TODO: improve detection for other versions of SDK 32008 eval PLATFORM_TOOLSET="\${VS_SDK_PLATFORM_NAME_${VS_VERSION}}" 32009 else 32010 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32011 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32012 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 32013 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 32014 fi 32015 fi 32016 fi 32017 32018 fi 32019 if test "x$PROGRAMW6432" != x; then 32020 32021 if test "x$VS_ENV_CMD" = x; then 32022 VS_VERSION="${VS_VERSION}" 32023 WIN_SDK_BASE="$PROGRAMW6432/$SDK_INSTALL_DIR" 32024 METHOD="well-known name" 32025 32026 windows_path="$WIN_SDK_BASE" 32027 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32028 unix_path=`$CYGPATH -u "$windows_path"` 32029 WIN_SDK_BASE="$unix_path" 32030 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32031 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32032 WIN_SDK_BASE="$unix_path" 32033 fi 32034 32035 if test -d "$WIN_SDK_BASE"; then 32036 # There have been cases of partial or broken SDK installations. A missing 32037 # lib dir is not going to work. 32038 if test ! -d "$WIN_SDK_BASE/lib"; then 32039 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32040 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32041 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 32042 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 32043 elif test -f "$WIN_SDK_BASE/Bin/SetEnv.Cmd"; then 32044 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32045 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32046 VS_ENV_CMD="$WIN_SDK_BASE/Bin/SetEnv.Cmd" 32047 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32048 VS_ENV_ARGS="/x86" 32049 else 32050 VS_ENV_ARGS="/x64" 32051 fi 32052 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32053 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK 32054 # TODO: improve detection for other versions of SDK 32055 eval PLATFORM_TOOLSET="\${VS_SDK_PLATFORM_NAME_${VS_VERSION}}" 32056 else 32057 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32058 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32059 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 32060 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 32061 fi 32062 fi 32063 fi 32064 32065 fi 32066 if test "x$PROGRAMFILES" != x; then 32067 32068 if test "x$VS_ENV_CMD" = x; then 32069 VS_VERSION="${VS_VERSION}" 32070 WIN_SDK_BASE="$PROGRAMFILES/$SDK_INSTALL_DIR" 32071 METHOD="well-known name" 32072 32073 windows_path="$WIN_SDK_BASE" 32074 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32075 unix_path=`$CYGPATH -u "$windows_path"` 32076 WIN_SDK_BASE="$unix_path" 32077 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32078 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32079 WIN_SDK_BASE="$unix_path" 32080 fi 32081 32082 if test -d "$WIN_SDK_BASE"; then 32083 # There have been cases of partial or broken SDK installations. A missing 32084 # lib dir is not going to work. 32085 if test ! -d "$WIN_SDK_BASE/lib"; then 32086 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32087 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32088 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 32089 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 32090 elif test -f "$WIN_SDK_BASE/Bin/SetEnv.Cmd"; then 32091 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32092 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32093 VS_ENV_CMD="$WIN_SDK_BASE/Bin/SetEnv.Cmd" 32094 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32095 VS_ENV_ARGS="/x86" 32096 else 32097 VS_ENV_ARGS="/x64" 32098 fi 32099 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32100 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK 32101 # TODO: improve detection for other versions of SDK 32102 eval PLATFORM_TOOLSET="\${VS_SDK_PLATFORM_NAME_${VS_VERSION}}" 32103 else 32104 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32105 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32106 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 32107 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 32108 fi 32109 fi 32110 fi 32111 32112 fi 32113 32114 if test "x$VS_ENV_CMD" = x; then 32115 VS_VERSION="${VS_VERSION}" 32116 WIN_SDK_BASE="C:/Program Files/$SDK_INSTALL_DIR" 32117 METHOD="well-known name" 32118 32119 windows_path="$WIN_SDK_BASE" 32120 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32121 unix_path=`$CYGPATH -u "$windows_path"` 32122 WIN_SDK_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 WIN_SDK_BASE="$unix_path" 32126 fi 32127 32128 if test -d "$WIN_SDK_BASE"; then 32129 # There have been cases of partial or broken SDK installations. A missing 32130 # lib dir is not going to work. 32131 if test ! -d "$WIN_SDK_BASE/lib"; then 32132 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32133 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32134 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 32135 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 32136 elif test -f "$WIN_SDK_BASE/Bin/SetEnv.Cmd"; then 32137 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32138 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32139 VS_ENV_CMD="$WIN_SDK_BASE/Bin/SetEnv.Cmd" 32140 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32141 VS_ENV_ARGS="/x86" 32142 else 32143 VS_ENV_ARGS="/x64" 32144 fi 32145 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32146 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK 32147 # TODO: improve detection for other versions of SDK 32148 eval PLATFORM_TOOLSET="\${VS_SDK_PLATFORM_NAME_${VS_VERSION}}" 32149 else 32150 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32151 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32152 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 32153 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 32154 fi 32155 fi 32156 fi 32157 32158 32159 if test "x$VS_ENV_CMD" = x; then 32160 VS_VERSION="${VS_VERSION}" 32161 WIN_SDK_BASE="C:/Program Files (x86)/$SDK_INSTALL_DIR" 32162 METHOD="well-known name" 32163 32164 windows_path="$WIN_SDK_BASE" 32165 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32166 unix_path=`$CYGPATH -u "$windows_path"` 32167 WIN_SDK_BASE="$unix_path" 32168 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32169 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32170 WIN_SDK_BASE="$unix_path" 32171 fi 32172 32173 if test -d "$WIN_SDK_BASE"; then 32174 # There have been cases of partial or broken SDK installations. A missing 32175 # lib dir is not going to work. 32176 if test ! -d "$WIN_SDK_BASE/lib"; then 32177 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32178 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32179 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 32180 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 32181 elif test -f "$WIN_SDK_BASE/Bin/SetEnv.Cmd"; then 32182 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32183 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32184 VS_ENV_CMD="$WIN_SDK_BASE/Bin/SetEnv.Cmd" 32185 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 32186 VS_ENV_ARGS="/x86" 32187 else 32188 VS_ENV_ARGS="/x64" 32189 fi 32190 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 32191 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK 32192 # TODO: improve detection for other versions of SDK 32193 eval PLATFORM_TOOLSET="\${VS_SDK_PLATFORM_NAME_${VS_VERSION}}" 32194 else 32195 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 32196 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 32197 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 32198 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 32199 fi 32200 fi 32201 fi 32202 32203 fi 32204 32205 if test "x$VS_ENV_CMD" != x; then 32206 TOOLCHAIN_VERSION=$VS_VERSION 32207 eval VS_DESCRIPTION="\${VS_DESCRIPTION_${VS_VERSION}}" 32208 eval VS_VERSION_INTERNAL="\${VS_VERSION_INTERNAL_${VS_VERSION}}" 32209 eval MSVCR_NAME="\${VS_MSVCR_${VS_VERSION}}" 32210 eval MSVCP_NAME="\${VS_MSVCP_${VS_VERSION}}" 32211 # The rest of the variables are already evaled while probing 32212 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $VS_DESCRIPTION" >&5 32213 $as_echo "$as_me: Found $VS_DESCRIPTION" >&6;} 32214 break 32215 fi 32216 done 32217 32218 32219 # If we have a devkit, skip all of the below. 32220 if test "x$DEVKIT_VS_VERSION" = x; then 32221 if test "x$VS_ENV_CMD" != x; then 32222 # We have found a Visual Studio environment on disk, let's extract variables from the vsvars bat file. 32223 32224 # Only process if variable expands to non-empty 32225 32226 if test "x$VS_ENV_CMD" != x; then 32227 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32228 32229 # First separate the path from the arguments. This will split at the first 32230 # space. 32231 complete="$VS_ENV_CMD" 32232 path="${complete%% *}" 32233 tmp="$complete EOL" 32234 arguments="${tmp#* }" 32235 32236 # Input might be given as Windows format, start by converting to 32237 # unix format. 32238 new_path=`$CYGPATH -u "$path"` 32239 32240 # Now try to locate executable using which 32241 new_path=`$WHICH "$new_path" 2> /dev/null` 32242 # bat and cmd files are not always considered executable in cygwin causing which 32243 # to not find them 32244 if test "x$new_path" = x \ 32245 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 32246 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 32247 new_path=`$CYGPATH -u "$path"` 32248 fi 32249 if test "x$new_path" = x; then 32250 # Oops. Which didn't find the executable. 32251 # The splitting of arguments from the executable at a space might have been incorrect, 32252 # since paths with space are more likely in Windows. Give it another try with the whole 32253 # argument. 32254 path="$complete" 32255 arguments="EOL" 32256 new_path=`$CYGPATH -u "$path"` 32257 new_path=`$WHICH "$new_path" 2> /dev/null` 32258 # bat and cmd files are not always considered executable in cygwin causing which 32259 # to not find them 32260 if test "x$new_path" = x \ 32261 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 32262 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 32263 new_path=`$CYGPATH -u "$path"` 32264 fi 32265 if test "x$new_path" = x; then 32266 # It's still not found. Now this is an unrecoverable error. 32267 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5 32268 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;} 32269 has_space=`$ECHO "$complete" | $GREP " "` 32270 if test "x$has_space" != x; then 32271 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 32272 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 32273 fi 32274 as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5 32275 fi 32276 fi 32277 32278 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 32279 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 32280 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 32281 # "foo.exe" is OK but "foo" is an error. 32282 # 32283 # This test is therefore slightly more accurate than "test -f" to check for file presence. 32284 # It is also a way to make sure we got the proper file name for the real test later on. 32285 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 32286 if test "x$test_shortpath" = x; then 32287 # Short path failed, file does not exist as specified. 32288 # Try adding .exe or .cmd 32289 if test -f "${new_path}.exe"; then 32290 input_to_shortpath="${new_path}.exe" 32291 elif test -f "${new_path}.cmd"; then 32292 input_to_shortpath="${new_path}.cmd" 32293 else 32294 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$new_path\", is invalid." >&5 32295 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$new_path\", is invalid." >&6;} 32296 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 32297 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 32298 as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5 32299 fi 32300 else 32301 input_to_shortpath="$new_path" 32302 fi 32303 32304 # Call helper function which possibly converts this using DOS-style short mode. 32305 # If so, the updated path is stored in $new_path. 32306 new_path="$input_to_shortpath" 32307 32308 input_path="$input_to_shortpath" 32309 # Check if we need to convert this using DOS-style short mode. If the path 32310 # contains just simple characters, use it. Otherwise (spaces, weird characters), 32311 # take no chances and rewrite it. 32312 # Note: m4 eats our [], so we need to use [ and ] instead. 32313 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 32314 if test "x$has_forbidden_chars" != x; then 32315 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 32316 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 32317 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 32318 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 32319 # Going to short mode and back again did indeed matter. Since short mode is 32320 # case insensitive, let's make it lowercase to improve readability. 32321 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 32322 # Now convert it back to Unix-style (cygpath) 32323 input_path=`$CYGPATH -u "$shortmode_path"` 32324 new_path="$input_path" 32325 fi 32326 fi 32327 32328 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 32329 if test "x$test_cygdrive_prefix" = x; then 32330 # As a simple fix, exclude /usr/bin since it's not a real path. 32331 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 32332 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 32333 # a path prefixed by /cygdrive for fixpath to work. 32334 new_path="$CYGWIN_ROOT_PATH$input_path" 32335 fi 32336 fi 32337 32338 # remove trailing .exe if any 32339 new_path="${new_path/%.exe/}" 32340 32341 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32342 32343 # First separate the path from the arguments. This will split at the first 32344 # space. 32345 complete="$VS_ENV_CMD" 32346 path="${complete%% *}" 32347 tmp="$complete EOL" 32348 arguments="${tmp#* }" 32349 32350 # Input might be given as Windows format, start by converting to 32351 # unix format. 32352 new_path="$path" 32353 32354 windows_path="$new_path" 32355 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32356 unix_path=`$CYGPATH -u "$windows_path"` 32357 new_path="$unix_path" 32358 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32359 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32360 new_path="$unix_path" 32361 fi 32362 32363 32364 # Now try to locate executable using which 32365 new_path=`$WHICH "$new_path" 2> /dev/null` 32366 32367 if test "x$new_path" = x; then 32368 # Oops. Which didn't find the executable. 32369 # The splitting of arguments from the executable at a space might have been incorrect, 32370 # since paths with space are more likely in Windows. Give it another try with the whole 32371 # argument. 32372 path="$complete" 32373 arguments="EOL" 32374 new_path="$path" 32375 32376 windows_path="$new_path" 32377 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32378 unix_path=`$CYGPATH -u "$windows_path"` 32379 new_path="$unix_path" 32380 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32381 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32382 new_path="$unix_path" 32383 fi 32384 32385 32386 new_path=`$WHICH "$new_path" 2> /dev/null` 32387 # bat and cmd files are not always considered executable in MSYS causing which 32388 # to not find them 32389 if test "x$new_path" = x \ 32390 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 32391 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 32392 new_path="$path" 32393 32394 windows_path="$new_path" 32395 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32396 unix_path=`$CYGPATH -u "$windows_path"` 32397 new_path="$unix_path" 32398 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32399 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32400 new_path="$unix_path" 32401 fi 32402 32403 fi 32404 32405 if test "x$new_path" = x; then 32406 # It's still not found. Now this is an unrecoverable error. 32407 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5 32408 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;} 32409 has_space=`$ECHO "$complete" | $GREP " "` 32410 if test "x$has_space" != x; then 32411 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 32412 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 32413 fi 32414 as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5 32415 fi 32416 fi 32417 32418 # Now new_path has a complete unix path to the binary 32419 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 32420 # Keep paths in /bin as-is, but remove trailing .exe if any 32421 new_path="${new_path/%.exe/}" 32422 # Do not save /bin paths to all_fixpath_prefixes! 32423 else 32424 # Not in mixed or Windows style, start by that. 32425 new_path=`cmd //c echo $new_path` 32426 32427 input_path="$new_path" 32428 # Check if we need to convert this using DOS-style short mode. If the path 32429 # contains just simple characters, use it. Otherwise (spaces, weird characters), 32430 # take no chances and rewrite it. 32431 # Note: m4 eats our [], so we need to use [ and ] instead. 32432 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 32433 if test "x$has_forbidden_chars" != x; then 32434 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 32435 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 32436 fi 32437 32438 # Output is in $new_path 32439 32440 windows_path="$new_path" 32441 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32442 unix_path=`$CYGPATH -u "$windows_path"` 32443 new_path="$unix_path" 32444 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32445 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32446 new_path="$unix_path" 32447 fi 32448 32449 # remove trailing .exe if any 32450 new_path="${new_path/%.exe/}" 32451 32452 # Save the first 10 bytes of this path to the storage, so fixpath can work. 32453 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 32454 fi 32455 32456 else 32457 # We're on a unix platform. Hooray! :) 32458 # First separate the path from the arguments. This will split at the first 32459 # space. 32460 complete="$VS_ENV_CMD" 32461 path="${complete%% *}" 32462 tmp="$complete EOL" 32463 arguments="${tmp#* }" 32464 32465 # Cannot rely on the command "which" here since it doesn't always work. 32466 is_absolute_path=`$ECHO "$path" | $GREP ^/` 32467 if test -z "$is_absolute_path"; then 32468 # Path to executable is not absolute. Find it. 32469 IFS_save="$IFS" 32470 IFS=: 32471 for p in $PATH; do 32472 if test -f "$p/$path" && test -x "$p/$path"; then 32473 new_path="$p/$path" 32474 break 32475 fi 32476 done 32477 IFS="$IFS_save" 32478 else 32479 # This is an absolute path, we can use it without further modifications. 32480 new_path="$path" 32481 fi 32482 32483 if test "x$new_path" = x; then 32484 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5 32485 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;} 32486 has_space=`$ECHO "$complete" | $GREP " "` 32487 if test "x$has_space" != x; then 32488 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 32489 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 32490 fi 32491 as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5 32492 fi 32493 fi 32494 32495 # Now join together the path and the arguments once again 32496 if test "x$arguments" != xEOL; then 32497 new_complete="$new_path ${arguments% *}" 32498 else 32499 new_complete="$new_path" 32500 fi 32501 32502 if test "x$complete" != "x$new_complete"; then 32503 VS_ENV_CMD="$new_complete" 32504 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting VS_ENV_CMD to \"$new_complete\"" >&5 32505 $as_echo "$as_me: Rewriting VS_ENV_CMD to \"$new_complete\"" >&6;} 32506 fi 32507 fi 32508 32509 32510 # Lets extract the variables that are set by vcvarsall.bat/vsvars32.bat/vsvars64.bat 32511 { $as_echo "$as_me:${as_lineno-$LINENO}: Trying to extract Visual Studio environment variables" >&5 32512 $as_echo "$as_me: Trying to extract Visual Studio environment variables" >&6;} 32513 32514 # We need to create a couple of temporary files. 32515 VS_ENV_TMP_DIR="$CONFIGURESUPPORT_OUTPUTDIR/vs-env" 32516 $MKDIR -p $VS_ENV_TMP_DIR 32517 32518 # Cannot use the VS10 setup script directly (since it only updates the DOS subshell environment). 32519 # Instead create a shell script which will set the relevant variables when run. 32520 WINPATH_VS_ENV_CMD="$VS_ENV_CMD" 32521 32522 unix_path="$WINPATH_VS_ENV_CMD" 32523 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32524 windows_path=`$CYGPATH -m "$unix_path"` 32525 WINPATH_VS_ENV_CMD="$windows_path" 32526 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32527 windows_path=`cmd //c echo $unix_path` 32528 WINPATH_VS_ENV_CMD="$windows_path" 32529 fi 32530 32531 WINPATH_BASH="$BASH" 32532 32533 unix_path="$WINPATH_BASH" 32534 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32535 windows_path=`$CYGPATH -m "$unix_path"` 32536 WINPATH_BASH="$windows_path" 32537 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32538 windows_path=`cmd //c echo $unix_path` 32539 WINPATH_BASH="$windows_path" 32540 fi 32541 32542 32543 # Generate a DOS batch file which runs $VS_ENV_CMD, and then creates a shell 32544 # script (executable by bash) that will setup the important variables. 32545 EXTRACT_VC_ENV_BAT_FILE="$VS_ENV_TMP_DIR/extract-vs-env.bat" 32546 $ECHO "@echo off" > $EXTRACT_VC_ENV_BAT_FILE 32547 # This will end up something like: 32548 # call C:/progra~2/micros~2.0/vc/bin/amd64/vcvars64.bat 32549 $ECHO "call $WINPATH_VS_ENV_CMD $VS_ENV_ARGS" >> $EXTRACT_VC_ENV_BAT_FILE 32550 # These will end up something like: 32551 # C:/CygWin/bin/bash -c 'echo VS_PATH=\"$PATH\" > localdevenv.sh 32552 # The trailing space for everyone except PATH is no typo, but is needed due 32553 # to trailing \ in the Windows paths. These will be stripped later. 32554 $ECHO "$WINPATH_BASH -c 'echo VS_PATH="'\"$PATH\" > set-vs-env.sh' \ 32555 >> $EXTRACT_VC_ENV_BAT_FILE 32556 $ECHO "$WINPATH_BASH -c 'echo VS_INCLUDE="'\"$INCLUDE\;$include \" >> set-vs-env.sh' \ 32557 >> $EXTRACT_VC_ENV_BAT_FILE 32558 $ECHO "$WINPATH_BASH -c 'echo VS_LIB="'\"$LIB\;$lib \" >> set-vs-env.sh' \ 32559 >> $EXTRACT_VC_ENV_BAT_FILE 32560 $ECHO "$WINPATH_BASH -c 'echo VCINSTALLDIR="'\"$VCINSTALLDIR \" >> set-vs-env.sh' \ 32561 >> $EXTRACT_VC_ENV_BAT_FILE 32562 $ECHO "$WINPATH_BASH -c 'echo WindowsSdkDir="'\"$WindowsSdkDir \" >> set-vs-env.sh' \ 32563 >> $EXTRACT_VC_ENV_BAT_FILE 32564 $ECHO "$WINPATH_BASH -c 'echo WINDOWSSDKDIR="'\"$WINDOWSSDKDIR \" >> set-vs-env.sh' \ 32565 >> $EXTRACT_VC_ENV_BAT_FILE 32566 32567 # Now execute the newly created bat file. 32568 # The | cat is to stop SetEnv.Cmd to mess with system colors on msys. 32569 # Change directory so we don't need to mess with Windows paths in redirects. 32570 cd $VS_ENV_TMP_DIR 32571 cmd /c extract-vs-env.bat | $CAT 32572 cd $CURDIR 32573 32574 if test ! -s $VS_ENV_TMP_DIR/set-vs-env.sh; then 32575 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not succesfully extract the envionment variables needed for the VS setup." >&5 32576 $as_echo "$as_me: Could not succesfully extract the envionment variables needed for the VS setup." >&6;} 32577 { $as_echo "$as_me:${as_lineno-$LINENO}: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&5 32578 $as_echo "$as_me: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&6;} 32579 { $as_echo "$as_me:${as_lineno-$LINENO}: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&5 32580 $as_echo "$as_me: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&6;} 32581 as_fn_error $? "Cannot continue" "$LINENO" 5 32582 fi 32583 32584 # Now set all paths and other env variables. This will allow the rest of 32585 # the configure script to find and run the compiler in the proper way. 32586 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting extracted environment variables" >&5 32587 $as_echo "$as_me: Setting extracted environment variables" >&6;} 32588 . $VS_ENV_TMP_DIR/set-vs-env.sh 32589 # Now we have VS_PATH, VS_INCLUDE, VS_LIB. For further checking, we 32590 # also define VCINSTALLDIR, WindowsSdkDir and WINDOWSSDKDIR. 32591 else 32592 # We did not find a vsvars bat file, let's hope we are run from a VS command prompt. 32593 { $as_echo "$as_me:${as_lineno-$LINENO}: Cannot locate a valid Visual Studio installation, checking current environment" >&5 32594 $as_echo "$as_me: Cannot locate a valid Visual Studio installation, checking current environment" >&6;} 32595 fi 32596 fi 32597 32598 # At this point, we should have correct variables in the environment, or we can't continue. 32599 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Visual Studio variables" >&5 32600 $as_echo_n "checking for Visual Studio variables... " >&6; } 32601 32602 if test "x$VCINSTALLDIR" != x || test "x$WindowsSDKDir" != x \ 32603 || test "x$WINDOWSSDKDIR" != x || test "x$DEVKIT_NAME" != x; then 32604 if test "x$VS_INCLUDE" = x || test "x$VS_LIB" = x; then 32605 { $as_echo "$as_me:${as_lineno-$LINENO}: result: present but broken" >&5 32606 $as_echo "present but broken" >&6; } 32607 as_fn_error $? "Your VC command prompt seems broken, INCLUDE and/or LIB is missing." "$LINENO" 5 32608 else 32609 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 32610 $as_echo "ok" >&6; } 32611 # Remove any trailing "\" ";" and " " from the variables. 32612 VS_INCLUDE=`$ECHO "$VS_INCLUDE" | $SED -e 's/\\\\*;* *$//'` 32613 VS_LIB=`$ECHO "$VS_LIB" | $SED 's/\\\\*;* *$//'` 32614 VCINSTALLDIR=`$ECHO "$VCINSTALLDIR" | $SED 's/\\\\* *$//'` 32615 WindowsSDKDir=`$ECHO "$WindowsSDKDir" | $SED 's/\\\\* *$//'` 32616 WINDOWSSDKDIR=`$ECHO "$WINDOWSSDKDIR" | $SED 's/\\\\* *$//'` 32617 # Remove any paths containing # (typically F#) as that messes up make. This 32618 # is needed if visual studio was installed with F# support. 32619 VS_PATH=`$ECHO "$VS_PATH" | $SED 's/[^:#]*#[^:]*://g'` 32620 32621 32622 32623 32624 32625 # Convert VS_INCLUDE into SYSROOT_CFLAGS 32626 OLDIFS="$IFS" 32627 IFS=";" 32628 for i in $VS_INCLUDE; do 32629 ipath=$i 32630 # Only process non-empty elements 32631 if test "x$ipath" != x; then 32632 IFS="$OLDIFS" 32633 # Check that directory exists before calling fixup_path 32634 testpath=$ipath 32635 32636 windows_path="$testpath" 32637 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32638 unix_path=`$CYGPATH -u "$windows_path"` 32639 testpath="$unix_path" 32640 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32641 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32642 testpath="$unix_path" 32643 fi 32644 32645 if test -d "$testpath"; then 32646 32647 # Only process if variable expands to non-empty 32648 32649 if test "x$ipath" != x; then 32650 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32651 32652 # Input might be given as Windows format, start by converting to 32653 # unix format. 32654 path="$ipath" 32655 new_path=`$CYGPATH -u "$path"` 32656 32657 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 32658 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 32659 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 32660 # "foo.exe" is OK but "foo" is an error. 32661 # 32662 # This test is therefore slightly more accurate than "test -f" to check for file precense. 32663 # It is also a way to make sure we got the proper file name for the real test later on. 32664 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 32665 if test "x$test_shortpath" = x; then 32666 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of ipath, which resolves as \"$path\", is invalid." >&5 32667 $as_echo "$as_me: The path of ipath, which resolves as \"$path\", is invalid." >&6;} 32668 as_fn_error $? "Cannot locate the the path of ipath" "$LINENO" 5 32669 fi 32670 32671 # Call helper function which possibly converts this using DOS-style short mode. 32672 # If so, the updated path is stored in $new_path. 32673 32674 input_path="$new_path" 32675 # Check if we need to convert this using DOS-style short mode. If the path 32676 # contains just simple characters, use it. Otherwise (spaces, weird characters), 32677 # take no chances and rewrite it. 32678 # Note: m4 eats our [], so we need to use [ and ] instead. 32679 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 32680 if test "x$has_forbidden_chars" != x; then 32681 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 32682 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 32683 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 32684 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 32685 # Going to short mode and back again did indeed matter. Since short mode is 32686 # case insensitive, let's make it lowercase to improve readability. 32687 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 32688 # Now convert it back to Unix-style (cygpath) 32689 input_path=`$CYGPATH -u "$shortmode_path"` 32690 new_path="$input_path" 32691 fi 32692 fi 32693 32694 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 32695 if test "x$test_cygdrive_prefix" = x; then 32696 # As a simple fix, exclude /usr/bin since it's not a real path. 32697 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 32698 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 32699 # a path prefixed by /cygdrive for fixpath to work. 32700 new_path="$CYGWIN_ROOT_PATH$input_path" 32701 fi 32702 fi 32703 32704 32705 if test "x$path" != "x$new_path"; then 32706 ipath="$new_path" 32707 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting ipath to \"$new_path\"" >&5 32708 $as_echo "$as_me: Rewriting ipath to \"$new_path\"" >&6;} 32709 fi 32710 32711 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32712 32713 path="$ipath" 32714 has_colon=`$ECHO $path | $GREP ^.:` 32715 new_path="$path" 32716 if test "x$has_colon" = x; then 32717 # Not in mixed or Windows style, start by that. 32718 new_path=`cmd //c echo $path` 32719 fi 32720 32721 32722 input_path="$new_path" 32723 # Check if we need to convert this using DOS-style short mode. If the path 32724 # contains just simple characters, use it. Otherwise (spaces, weird characters), 32725 # take no chances and rewrite it. 32726 # Note: m4 eats our [], so we need to use [ and ] instead. 32727 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 32728 if test "x$has_forbidden_chars" != x; then 32729 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 32730 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 32731 fi 32732 32733 32734 windows_path="$new_path" 32735 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32736 unix_path=`$CYGPATH -u "$windows_path"` 32737 new_path="$unix_path" 32738 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32739 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32740 new_path="$unix_path" 32741 fi 32742 32743 if test "x$path" != "x$new_path"; then 32744 ipath="$new_path" 32745 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting ipath to \"$new_path\"" >&5 32746 $as_echo "$as_me: Rewriting ipath to \"$new_path\"" >&6;} 32747 fi 32748 32749 # Save the first 10 bytes of this path to the storage, so fixpath can work. 32750 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 32751 32752 else 32753 # We're on a unix platform. Hooray! :) 32754 path="$ipath" 32755 has_space=`$ECHO "$path" | $GREP " "` 32756 if test "x$has_space" != x; then 32757 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of ipath, which resolves as \"$path\", is invalid." >&5 32758 $as_echo "$as_me: The path of ipath, which resolves as \"$path\", is invalid." >&6;} 32759 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 32760 fi 32761 32762 # Use eval to expand a potential ~ 32763 eval path="$path" 32764 if test ! -f "$path" && test ! -d "$path"; then 32765 as_fn_error $? "The path of ipath, which resolves as \"$path\", is not found." "$LINENO" 5 32766 fi 32767 32768 if test -d "$path"; then 32769 ipath="`cd "$path"; $THEPWDCMD -L`" 32770 else 32771 dir="`$DIRNAME "$path"`" 32772 base="`$BASENAME "$path"`" 32773 ipath="`cd "$dir"; $THEPWDCMD -L`/$base" 32774 fi 32775 fi 32776 fi 32777 32778 SYSROOT_CFLAGS="$SYSROOT_CFLAGS -I$ipath" 32779 fi 32780 IFS=";" 32781 fi 32782 done 32783 # Convert VS_LIB into SYSROOT_LDFLAGS 32784 for i in $VS_LIB; do 32785 libpath=$i 32786 # Only process non-empty elements 32787 if test "x$libpath" != x; then 32788 IFS="$OLDIFS" 32789 # Check that directory exists before calling fixup_path 32790 testpath=$libpath 32791 32792 windows_path="$testpath" 32793 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32794 unix_path=`$CYGPATH -u "$windows_path"` 32795 testpath="$unix_path" 32796 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32797 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32798 testpath="$unix_path" 32799 fi 32800 32801 if test -d "$testpath"; then 32802 32803 # Only process if variable expands to non-empty 32804 32805 if test "x$libpath" != x; then 32806 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32807 32808 # Input might be given as Windows format, start by converting to 32809 # unix format. 32810 path="$libpath" 32811 new_path=`$CYGPATH -u "$path"` 32812 32813 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 32814 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 32815 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 32816 # "foo.exe" is OK but "foo" is an error. 32817 # 32818 # This test is therefore slightly more accurate than "test -f" to check for file precense. 32819 # It is also a way to make sure we got the proper file name for the real test later on. 32820 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 32821 if test "x$test_shortpath" = x; then 32822 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of libpath, which resolves as \"$path\", is invalid." >&5 32823 $as_echo "$as_me: The path of libpath, which resolves as \"$path\", is invalid." >&6;} 32824 as_fn_error $? "Cannot locate the the path of libpath" "$LINENO" 5 32825 fi 32826 32827 # Call helper function which possibly converts this using DOS-style short mode. 32828 # If so, the updated path is stored in $new_path. 32829 32830 input_path="$new_path" 32831 # Check if we need to convert this using DOS-style short mode. If the path 32832 # contains just simple characters, use it. Otherwise (spaces, weird characters), 32833 # take no chances and rewrite it. 32834 # Note: m4 eats our [], so we need to use [ and ] instead. 32835 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 32836 if test "x$has_forbidden_chars" != x; then 32837 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 32838 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 32839 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 32840 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 32841 # Going to short mode and back again did indeed matter. Since short mode is 32842 # case insensitive, let's make it lowercase to improve readability. 32843 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 32844 # Now convert it back to Unix-style (cygpath) 32845 input_path=`$CYGPATH -u "$shortmode_path"` 32846 new_path="$input_path" 32847 fi 32848 fi 32849 32850 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 32851 if test "x$test_cygdrive_prefix" = x; then 32852 # As a simple fix, exclude /usr/bin since it's not a real path. 32853 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 32854 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 32855 # a path prefixed by /cygdrive for fixpath to work. 32856 new_path="$CYGWIN_ROOT_PATH$input_path" 32857 fi 32858 fi 32859 32860 32861 if test "x$path" != "x$new_path"; then 32862 libpath="$new_path" 32863 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting libpath to \"$new_path\"" >&5 32864 $as_echo "$as_me: Rewriting libpath to \"$new_path\"" >&6;} 32865 fi 32866 32867 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32868 32869 path="$libpath" 32870 has_colon=`$ECHO $path | $GREP ^.:` 32871 new_path="$path" 32872 if test "x$has_colon" = x; then 32873 # Not in mixed or Windows style, start by that. 32874 new_path=`cmd //c echo $path` 32875 fi 32876 32877 32878 input_path="$new_path" 32879 # Check if we need to convert this using DOS-style short mode. If the path 32880 # contains just simple characters, use it. Otherwise (spaces, weird characters), 32881 # take no chances and rewrite it. 32882 # Note: m4 eats our [], so we need to use [ and ] instead. 32883 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 32884 if test "x$has_forbidden_chars" != x; then 32885 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 32886 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 32887 fi 32888 32889 32890 windows_path="$new_path" 32891 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32892 unix_path=`$CYGPATH -u "$windows_path"` 32893 new_path="$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 new_path="$unix_path" 32897 fi 32898 32899 if test "x$path" != "x$new_path"; then 32900 libpath="$new_path" 32901 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting libpath to \"$new_path\"" >&5 32902 $as_echo "$as_me: Rewriting libpath to \"$new_path\"" >&6;} 32903 fi 32904 32905 # Save the first 10 bytes of this path to the storage, so fixpath can work. 32906 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 32907 32908 else 32909 # We're on a unix platform. Hooray! :) 32910 path="$libpath" 32911 has_space=`$ECHO "$path" | $GREP " "` 32912 if test "x$has_space" != x; then 32913 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of libpath, which resolves as \"$path\", is invalid." >&5 32914 $as_echo "$as_me: The path of libpath, which resolves as \"$path\", is invalid." >&6;} 32915 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 32916 fi 32917 32918 # Use eval to expand a potential ~ 32919 eval path="$path" 32920 if test ! -f "$path" && test ! -d "$path"; then 32921 as_fn_error $? "The path of libpath, which resolves as \"$path\", is not found." "$LINENO" 5 32922 fi 32923 32924 if test -d "$path"; then 32925 libpath="`cd "$path"; $THEPWDCMD -L`" 32926 else 32927 dir="`$DIRNAME "$path"`" 32928 base="`$BASENAME "$path"`" 32929 libpath="`cd "$dir"; $THEPWDCMD -L`/$base" 32930 fi 32931 fi 32932 fi 32933 32934 SYSROOT_LDFLAGS="$SYSROOT_LDFLAGS -libpath:$libpath" 32935 fi 32936 IFS=";" 32937 fi 32938 done 32939 IFS="$OLDIFS" 32940 fi 32941 else 32942 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 32943 $as_echo "not found" >&6; } 32944 32945 if test "x$VS_ENV_CMD" = x; then 32946 { $as_echo "$as_me:${as_lineno-$LINENO}: Cannot locate a valid Visual Studio or Windows SDK installation on disk," >&5 32947 $as_echo "$as_me: Cannot locate a valid Visual Studio or Windows SDK installation on disk," >&6;} 32948 { $as_echo "$as_me:${as_lineno-$LINENO}: nor is this script run from a Visual Studio command prompt." >&5 32949 $as_echo "$as_me: nor is this script run from a Visual Studio command prompt." >&6;} 32950 else 32951 { $as_echo "$as_me:${as_lineno-$LINENO}: Running the extraction script failed." >&5 32952 $as_echo "$as_me: Running the extraction script failed." >&6;} 32953 fi 32954 { $as_echo "$as_me:${as_lineno-$LINENO}: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&5 32955 $as_echo "$as_me: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&6;} 32956 { $as_echo "$as_me:${as_lineno-$LINENO}: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&5 32957 $as_echo "$as_me: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&6;} 32958 as_fn_error $? "Cannot continue" "$LINENO" 5 32959 fi 32960 32961 # Reset path to VS_PATH. It will include everything that was on PATH at the time we 32962 # ran TOOLCHAIN_SETUP_VISUAL_STUDIO_ENV. 32963 PATH="$VS_PATH" 32964 # The microsoft toolchain also requires INCLUDE and LIB to be set. 32965 export INCLUDE="$VS_INCLUDE" 32966 export LIB="$VS_LIB" 32967 else 32968 if test "x$XCODE_VERSION_OUTPUT" != x; then 32969 # For Xcode, we set the Xcode version as TOOLCHAIN_VERSION 32970 TOOLCHAIN_VERSION=`$ECHO $XCODE_VERSION_OUTPUT | $CUT -f 2 -d ' '` 32971 TOOLCHAIN_DESCRIPTION="$TOOLCHAIN_DESCRIPTION from Xcode" 32972 else 32973 # Currently we do not define this for other toolchains. This might change as the need arise. 32974 TOOLCHAIN_VERSION= 32975 fi 32976 fi 32977 32978 32979 # Finally add TOOLCHAIN_PATH at the beginning, to allow --with-tools-dir to 32980 # override all other locations. 32981 if test "x$TOOLCHAIN_PATH" != x; then 32982 PATH=$TOOLCHAIN_PATH:$PATH 32983 fi 32984 32985 32986 # 32987 # Setup the compilers (CC and CXX) 32988 # 32989 32990 COMPILER_NAME=C 32991 SEARCH_LIST="$TOOLCHAIN_CC_BINARY" 32992 32993 if test "x$CC" != x; then 32994 # User has supplied compiler name already, always let that override. 32995 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied compiler CC=$CC" >&5 32996 $as_echo "$as_me: Will use user supplied compiler CC=$CC" >&6;} 32997 if test "x`basename $CC`" = "x$CC"; then 32998 # A command without a complete path is provided, search $PATH. 32999 33000 for ac_prog in $CC 33001 do 33002 # Extract the first word of "$ac_prog", so it can be a program name with args. 33003 set dummy $ac_prog; ac_word=$2 33004 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33005 $as_echo_n "checking for $ac_word... " >&6; } 33006 if ${ac_cv_path_POTENTIAL_CC+:} false; then : 33007 $as_echo_n "(cached) " >&6 33008 else 33009 case $POTENTIAL_CC in 33010 [\\/]* | ?:[\\/]*) 33011 ac_cv_path_POTENTIAL_CC="$POTENTIAL_CC" # Let the user override the test with a path. 33012 ;; 33013 *) 33014 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33015 for as_dir in $PATH 33016 do 33017 IFS=$as_save_IFS 33018 test -z "$as_dir" && as_dir=. 33019 for ac_exec_ext in '' $ac_executable_extensions; do 33020 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 33021 ac_cv_path_POTENTIAL_CC="$as_dir/$ac_word$ac_exec_ext" 33022 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 33023 break 2 33024 fi 33025 done 33026 done 33027 IFS=$as_save_IFS 33028 33029 ;; 33030 esac 33031 fi 33032 POTENTIAL_CC=$ac_cv_path_POTENTIAL_CC 33033 if test -n "$POTENTIAL_CC"; then 33034 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CC" >&5 33035 $as_echo "$POTENTIAL_CC" >&6; } 33036 else 33037 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33038 $as_echo "no" >&6; } 33039 fi 33040 33041 33042 test -n "$POTENTIAL_CC" && break 33043 done 33044 33045 if test "x$POTENTIAL_CC" != x; then 33046 CC=$POTENTIAL_CC 33047 else 33048 as_fn_error $? "User supplied compiler CC=$CC could not be found" "$LINENO" 5 33049 fi 33050 else 33051 # Otherwise it might already be a complete path 33052 if test ! -x "$CC"; then 33053 as_fn_error $? "User supplied compiler CC=$CC does not exist" "$LINENO" 5 33054 fi 33055 fi 33056 else 33057 # No user supplied value. Locate compiler ourselves. 33058 33059 # If we are cross compiling, assume cross compilation tools follows the 33060 # cross compilation standard where they are prefixed with the autoconf 33061 # standard name for the target. For example the binary 33062 # i686-sun-solaris2.10-gcc will cross compile for i686-sun-solaris2.10. 33063 # If we are not cross compiling, then the default compiler name will be 33064 # used. 33065 33066 CC= 33067 # If TOOLCHAIN_PATH is set, check for all compiler names in there first 33068 # before checking the rest of the PATH. 33069 # FIXME: Now that we prefix the TOOLS_DIR to the PATH in the PRE_DETECTION 33070 # step, this should not be necessary. 33071 if test -n "$TOOLCHAIN_PATH"; then 33072 PATH_save="$PATH" 33073 PATH="$TOOLCHAIN_PATH" 33074 for ac_prog in $SEARCH_LIST 33075 do 33076 # Extract the first word of "$ac_prog", so it can be a program name with args. 33077 set dummy $ac_prog; ac_word=$2 33078 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33079 $as_echo_n "checking for $ac_word... " >&6; } 33080 if ${ac_cv_path_TOOLCHAIN_PATH_CC+:} false; then : 33081 $as_echo_n "(cached) " >&6 33082 else 33083 case $TOOLCHAIN_PATH_CC in 33084 [\\/]* | ?:[\\/]*) 33085 ac_cv_path_TOOLCHAIN_PATH_CC="$TOOLCHAIN_PATH_CC" # Let the user override the test with a path. 33086 ;; 33087 *) 33088 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33089 for as_dir in $PATH 33090 do 33091 IFS=$as_save_IFS 33092 test -z "$as_dir" && as_dir=. 33093 for ac_exec_ext in '' $ac_executable_extensions; do 33094 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 33095 ac_cv_path_TOOLCHAIN_PATH_CC="$as_dir/$ac_word$ac_exec_ext" 33096 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 33097 break 2 33098 fi 33099 done 33100 done 33101 IFS=$as_save_IFS 33102 33103 ;; 33104 esac 33105 fi 33106 TOOLCHAIN_PATH_CC=$ac_cv_path_TOOLCHAIN_PATH_CC 33107 if test -n "$TOOLCHAIN_PATH_CC"; then 33108 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLCHAIN_PATH_CC" >&5 33109 $as_echo "$TOOLCHAIN_PATH_CC" >&6; } 33110 else 33111 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33112 $as_echo "no" >&6; } 33113 fi 33114 33115 33116 test -n "$TOOLCHAIN_PATH_CC" && break 33117 done 33118 33119 CC=$TOOLCHAIN_PATH_CC 33120 PATH="$PATH_save" 33121 fi 33122 33123 # AC_PATH_PROGS can't be run multiple times with the same variable, 33124 # so create a new name for this run. 33125 if test "x$CC" = x; then 33126 for ac_prog in $SEARCH_LIST 33127 do 33128 # Extract the first word of "$ac_prog", so it can be a program name with args. 33129 set dummy $ac_prog; ac_word=$2 33130 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33131 $as_echo_n "checking for $ac_word... " >&6; } 33132 if ${ac_cv_path_POTENTIAL_CC+:} false; then : 33133 $as_echo_n "(cached) " >&6 33134 else 33135 case $POTENTIAL_CC in 33136 [\\/]* | ?:[\\/]*) 33137 ac_cv_path_POTENTIAL_CC="$POTENTIAL_CC" # Let the user override the test with a path. 33138 ;; 33139 *) 33140 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33141 for as_dir in $PATH 33142 do 33143 IFS=$as_save_IFS 33144 test -z "$as_dir" && as_dir=. 33145 for ac_exec_ext in '' $ac_executable_extensions; do 33146 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 33147 ac_cv_path_POTENTIAL_CC="$as_dir/$ac_word$ac_exec_ext" 33148 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 33149 break 2 33150 fi 33151 done 33152 done 33153 IFS=$as_save_IFS 33154 33155 ;; 33156 esac 33157 fi 33158 POTENTIAL_CC=$ac_cv_path_POTENTIAL_CC 33159 if test -n "$POTENTIAL_CC"; then 33160 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CC" >&5 33161 $as_echo "$POTENTIAL_CC" >&6; } 33162 else 33163 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33164 $as_echo "no" >&6; } 33165 fi 33166 33167 33168 test -n "$POTENTIAL_CC" && break 33169 done 33170 33171 CC=$POTENTIAL_CC 33172 fi 33173 33174 if test "x$CC" = x; then 33175 33176 # Print a helpful message on how to acquire the necessary build dependency. 33177 # devkit is the help tag: freetype, cups, alsa etc 33178 MISSING_DEPENDENCY=devkit 33179 33180 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33181 cygwin_help $MISSING_DEPENDENCY 33182 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33183 msys_help $MISSING_DEPENDENCY 33184 else 33185 PKGHANDLER_COMMAND= 33186 33187 case $PKGHANDLER in 33188 apt-get) 33189 apt_help $MISSING_DEPENDENCY ;; 33190 yum) 33191 yum_help $MISSING_DEPENDENCY ;; 33192 port) 33193 port_help $MISSING_DEPENDENCY ;; 33194 pkgutil) 33195 pkgutil_help $MISSING_DEPENDENCY ;; 33196 pkgadd) 33197 pkgadd_help $MISSING_DEPENDENCY ;; 33198 esac 33199 33200 if test "x$PKGHANDLER_COMMAND" != x; then 33201 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 33202 fi 33203 fi 33204 33205 as_fn_error $? "Could not find a $COMPILER_NAME compiler. $HELP_MSG" "$LINENO" 5 33206 fi 33207 fi 33208 33209 # Now we have a compiler binary in CC. Make sure it's okay. 33210 33211 # Only process if variable expands to non-empty 33212 33213 if test "x$CC" != x; then 33214 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33215 33216 # First separate the path from the arguments. This will split at the first 33217 # space. 33218 complete="$CC" 33219 path="${complete%% *}" 33220 tmp="$complete EOL" 33221 arguments="${tmp#* }" 33222 33223 # Input might be given as Windows format, start by converting to 33224 # unix format. 33225 new_path=`$CYGPATH -u "$path"` 33226 33227 # Now try to locate executable using which 33228 new_path=`$WHICH "$new_path" 2> /dev/null` 33229 # bat and cmd files are not always considered executable in cygwin causing which 33230 # to not find them 33231 if test "x$new_path" = x \ 33232 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 33233 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 33234 new_path=`$CYGPATH -u "$path"` 33235 fi 33236 if test "x$new_path" = x; then 33237 # Oops. Which didn't find the executable. 33238 # The splitting of arguments from the executable at a space might have been incorrect, 33239 # since paths with space are more likely in Windows. Give it another try with the whole 33240 # argument. 33241 path="$complete" 33242 arguments="EOL" 33243 new_path=`$CYGPATH -u "$path"` 33244 new_path=`$WHICH "$new_path" 2> /dev/null` 33245 # bat and cmd files are not always considered executable in cygwin causing which 33246 # to not find them 33247 if test "x$new_path" = x \ 33248 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 33249 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 33250 new_path=`$CYGPATH -u "$path"` 33251 fi 33252 if test "x$new_path" = x; then 33253 # It's still not found. Now this is an unrecoverable error. 33254 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5 33255 $as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;} 33256 has_space=`$ECHO "$complete" | $GREP " "` 33257 if test "x$has_space" != x; then 33258 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 33259 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 33260 fi 33261 as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5 33262 fi 33263 fi 33264 33265 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 33266 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 33267 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 33268 # "foo.exe" is OK but "foo" is an error. 33269 # 33270 # This test is therefore slightly more accurate than "test -f" to check for file presence. 33271 # It is also a way to make sure we got the proper file name for the real test later on. 33272 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 33273 if test "x$test_shortpath" = x; then 33274 # Short path failed, file does not exist as specified. 33275 # Try adding .exe or .cmd 33276 if test -f "${new_path}.exe"; then 33277 input_to_shortpath="${new_path}.exe" 33278 elif test -f "${new_path}.cmd"; then 33279 input_to_shortpath="${new_path}.cmd" 33280 else 33281 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$new_path\", is invalid." >&5 33282 $as_echo "$as_me: The path of CC, which resolves as \"$new_path\", is invalid." >&6;} 33283 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 33284 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 33285 as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5 33286 fi 33287 else 33288 input_to_shortpath="$new_path" 33289 fi 33290 33291 # Call helper function which possibly converts this using DOS-style short mode. 33292 # If so, the updated path is stored in $new_path. 33293 new_path="$input_to_shortpath" 33294 33295 input_path="$input_to_shortpath" 33296 # Check if we need to convert this using DOS-style short mode. If the path 33297 # contains just simple characters, use it. Otherwise (spaces, weird characters), 33298 # take no chances and rewrite it. 33299 # Note: m4 eats our [], so we need to use [ and ] instead. 33300 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 33301 if test "x$has_forbidden_chars" != x; then 33302 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 33303 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 33304 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 33305 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 33306 # Going to short mode and back again did indeed matter. Since short mode is 33307 # case insensitive, let's make it lowercase to improve readability. 33308 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 33309 # Now convert it back to Unix-style (cygpath) 33310 input_path=`$CYGPATH -u "$shortmode_path"` 33311 new_path="$input_path" 33312 fi 33313 fi 33314 33315 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 33316 if test "x$test_cygdrive_prefix" = x; then 33317 # As a simple fix, exclude /usr/bin since it's not a real path. 33318 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 33319 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 33320 # a path prefixed by /cygdrive for fixpath to work. 33321 new_path="$CYGWIN_ROOT_PATH$input_path" 33322 fi 33323 fi 33324 33325 # remove trailing .exe if any 33326 new_path="${new_path/%.exe/}" 33327 33328 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33329 33330 # First separate the path from the arguments. This will split at the first 33331 # space. 33332 complete="$CC" 33333 path="${complete%% *}" 33334 tmp="$complete EOL" 33335 arguments="${tmp#* }" 33336 33337 # Input might be given as Windows format, start by converting to 33338 # unix format. 33339 new_path="$path" 33340 33341 windows_path="$new_path" 33342 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33343 unix_path=`$CYGPATH -u "$windows_path"` 33344 new_path="$unix_path" 33345 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33346 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33347 new_path="$unix_path" 33348 fi 33349 33350 33351 # Now try to locate executable using which 33352 new_path=`$WHICH "$new_path" 2> /dev/null` 33353 33354 if test "x$new_path" = x; then 33355 # Oops. Which didn't find the executable. 33356 # The splitting of arguments from the executable at a space might have been incorrect, 33357 # since paths with space are more likely in Windows. Give it another try with the whole 33358 # argument. 33359 path="$complete" 33360 arguments="EOL" 33361 new_path="$path" 33362 33363 windows_path="$new_path" 33364 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33365 unix_path=`$CYGPATH -u "$windows_path"` 33366 new_path="$unix_path" 33367 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33368 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33369 new_path="$unix_path" 33370 fi 33371 33372 33373 new_path=`$WHICH "$new_path" 2> /dev/null` 33374 # bat and cmd files are not always considered executable in MSYS causing which 33375 # to not find them 33376 if test "x$new_path" = x \ 33377 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 33378 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 33379 new_path="$path" 33380 33381 windows_path="$new_path" 33382 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33383 unix_path=`$CYGPATH -u "$windows_path"` 33384 new_path="$unix_path" 33385 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33386 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33387 new_path="$unix_path" 33388 fi 33389 33390 fi 33391 33392 if test "x$new_path" = x; then 33393 # It's still not found. Now this is an unrecoverable error. 33394 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5 33395 $as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;} 33396 has_space=`$ECHO "$complete" | $GREP " "` 33397 if test "x$has_space" != x; then 33398 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 33399 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 33400 fi 33401 as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5 33402 fi 33403 fi 33404 33405 # Now new_path has a complete unix path to the binary 33406 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 33407 # Keep paths in /bin as-is, but remove trailing .exe if any 33408 new_path="${new_path/%.exe/}" 33409 # Do not save /bin paths to all_fixpath_prefixes! 33410 else 33411 # Not in mixed or Windows style, start by that. 33412 new_path=`cmd //c echo $new_path` 33413 33414 input_path="$new_path" 33415 # Check if we need to convert this using DOS-style short mode. If the path 33416 # contains just simple characters, use it. Otherwise (spaces, weird characters), 33417 # take no chances and rewrite it. 33418 # Note: m4 eats our [], so we need to use [ and ] instead. 33419 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 33420 if test "x$has_forbidden_chars" != x; then 33421 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 33422 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 33423 fi 33424 33425 # Output is in $new_path 33426 33427 windows_path="$new_path" 33428 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33429 unix_path=`$CYGPATH -u "$windows_path"` 33430 new_path="$unix_path" 33431 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33432 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33433 new_path="$unix_path" 33434 fi 33435 33436 # remove trailing .exe if any 33437 new_path="${new_path/%.exe/}" 33438 33439 # Save the first 10 bytes of this path to the storage, so fixpath can work. 33440 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 33441 fi 33442 33443 else 33444 # We're on a unix platform. Hooray! :) 33445 # First separate the path from the arguments. This will split at the first 33446 # space. 33447 complete="$CC" 33448 path="${complete%% *}" 33449 tmp="$complete EOL" 33450 arguments="${tmp#* }" 33451 33452 # Cannot rely on the command "which" here since it doesn't always work. 33453 is_absolute_path=`$ECHO "$path" | $GREP ^/` 33454 if test -z "$is_absolute_path"; then 33455 # Path to executable is not absolute. Find it. 33456 IFS_save="$IFS" 33457 IFS=: 33458 for p in $PATH; do 33459 if test -f "$p/$path" && test -x "$p/$path"; then 33460 new_path="$p/$path" 33461 break 33462 fi 33463 done 33464 IFS="$IFS_save" 33465 else 33466 # This is an absolute path, we can use it without further modifications. 33467 new_path="$path" 33468 fi 33469 33470 if test "x$new_path" = x; then 33471 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5 33472 $as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;} 33473 has_space=`$ECHO "$complete" | $GREP " "` 33474 if test "x$has_space" != x; then 33475 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 33476 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 33477 fi 33478 as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5 33479 fi 33480 fi 33481 33482 # Now join together the path and the arguments once again 33483 if test "x$arguments" != xEOL; then 33484 new_complete="$new_path ${arguments% *}" 33485 else 33486 new_complete="$new_path" 33487 fi 33488 33489 if test "x$complete" != "x$new_complete"; then 33490 CC="$new_complete" 33491 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CC to \"$new_complete\"" >&5 33492 $as_echo "$as_me: Rewriting CC to \"$new_complete\"" >&6;} 33493 fi 33494 fi 33495 33496 TEST_COMPILER="$CC" 33497 33498 { $as_echo "$as_me:${as_lineno-$LINENO}: checking resolved symbolic links for CC" >&5 33499 $as_echo_n "checking resolved symbolic links for CC... " >&6; } 33500 SYMLINK_ORIGINAL="$TEST_COMPILER" 33501 33502 if test "x$OPENJDK_BUILD_OS" != xwindows; then 33503 # Follow a chain of symbolic links. Use readlink 33504 # where it exists, else fall back to horribly 33505 # complicated shell code. 33506 if test "x$READLINK_TESTED" != yes; then 33507 # On MacOSX there is a readlink tool with a different 33508 # purpose than the GNU readlink tool. Check the found readlink. 33509 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 33510 if test "x$ISGNU" = x; then 33511 # A readlink that we do not know how to use. 33512 # Are there other non-GNU readlinks out there? 33513 READLINK_TESTED=yes 33514 READLINK= 33515 fi 33516 fi 33517 33518 if test "x$READLINK" != x; then 33519 SYMLINK_ORIGINAL=`$READLINK -f $SYMLINK_ORIGINAL` 33520 else 33521 # Save the current directory for restoring afterwards 33522 STARTDIR=$PWD 33523 COUNTER=0 33524 sym_link_dir=`$DIRNAME $SYMLINK_ORIGINAL` 33525 sym_link_file=`$BASENAME $SYMLINK_ORIGINAL` 33526 cd $sym_link_dir 33527 # Use -P flag to resolve symlinks in directories. 33528 cd `$THEPWDCMD -P` 33529 sym_link_dir=`$THEPWDCMD -P` 33530 # Resolve file symlinks 33531 while test $COUNTER -lt 20; do 33532 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 33533 if test "x$ISLINK" == x; then 33534 # This is not a symbolic link! We are done! 33535 break 33536 fi 33537 # Again resolve directory symlinks since the target of the just found 33538 # link could be in a different directory 33539 cd `$DIRNAME $ISLINK` 33540 sym_link_dir=`$THEPWDCMD -P` 33541 sym_link_file=`$BASENAME $ISLINK` 33542 let COUNTER=COUNTER+1 33543 done 33544 cd $STARTDIR 33545 SYMLINK_ORIGINAL=$sym_link_dir/$sym_link_file 33546 fi 33547 fi 33548 33549 if test "x$TEST_COMPILER" = "x$SYMLINK_ORIGINAL"; then 33550 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no symlink" >&5 33551 $as_echo "no symlink" >&6; } 33552 else 33553 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SYMLINK_ORIGINAL" >&5 33554 $as_echo "$SYMLINK_ORIGINAL" >&6; } 33555 33556 # We can't handle ccache by gcc wrappers, since we need to know if we're 33557 # using ccache. Instead ccache usage must be controlled by a configure option. 33558 COMPILER_BASENAME=`$BASENAME "$SYMLINK_ORIGINAL"` 33559 if test "x$COMPILER_BASENAME" = "xccache"; then 33560 { $as_echo "$as_me:${as_lineno-$LINENO}: Please use --enable-ccache instead of providing a wrapped compiler." >&5 33561 $as_echo "$as_me: Please use --enable-ccache instead of providing a wrapped compiler." >&6;} 33562 as_fn_error $? "$TEST_COMPILER is a symbolic link to ccache. This is not supported." "$LINENO" 5 33563 fi 33564 fi 33565 33566 33567 COMPILER=$CC 33568 COMPILER_NAME=$COMPILER_NAME 33569 33570 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 33571 # cc -V output typically looks like 33572 # cc: Sun C 5.12 Linux_i386 2011/11/16 33573 COMPILER_VERSION_OUTPUT=`$COMPILER -V 2>&1` 33574 # Check that this is likely to be the Solaris Studio cc. 33575 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "^.*: Sun $COMPILER_NAME" > /dev/null 33576 if test $? -ne 0; then 33577 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 33578 { $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 33579 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 33580 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&5 33581 $as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 33582 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 33583 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 33584 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 33585 fi 33586 # Remove usage instructions (if present), and 33587 # collapse compiler output into a single line 33588 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 33589 $SED -e 's/ *[Uu]sage:.*//'` 33590 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 33591 $SED -e "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/"` 33592 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 33593 # xlc -qversion output typically looks like 33594 # IBM XL C/C++ for AIX, V11.1 (5724-X13) 33595 # Version: 11.01.0000.0015 33596 COMPILER_VERSION_OUTPUT=`$COMPILER -qversion 2>&1` 33597 # Check that this is likely to be the IBM XL C compiler. 33598 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "IBM XL C" > /dev/null 33599 if test $? -ne 0; then 33600 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 33601 { $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 33602 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 33603 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&5 33604 $as_echo "$as_me: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 33605 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 33606 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 33607 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 33608 fi 33609 # Collapse compiler output into a single line 33610 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 33611 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 33612 $SED -e 's/^.*, V\([1-9][0-9.]*\).*$/\1/'` 33613 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 33614 # There is no specific version flag, but all output starts with a version string. 33615 # First line typically looks something like: 33616 # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86 33617 COMPILER_VERSION_OUTPUT=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'` 33618 # Check that this is likely to be Microsoft CL.EXE. 33619 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Microsoft.*Compiler" > /dev/null 33620 if test $? -ne 0; then 33621 { $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 33622 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 33623 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&5 33624 $as_echo "$as_me: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 33625 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 33626 fi 33627 # Collapse compiler output into a single line 33628 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 33629 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 33630 $SED -e 's/^.*ersion.\([1-9][0-9.]*\) .*$/\1/'` 33631 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 33632 # gcc --version output typically looks like 33633 # gcc (Ubuntu/Linaro 4.8.1-10ubuntu9) 4.8.1 33634 # Copyright (C) 2013 Free Software Foundation, Inc. 33635 # This is free software; see the source for copying conditions. There is NO 33636 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 33637 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 33638 # Check that this is likely to be GCC. 33639 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Free Software Foundation" > /dev/null 33640 if test $? -ne 0; then 33641 { $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 33642 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 33643 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION\"" >&5 33644 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION\"" >&6;} 33645 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 33646 fi 33647 # Remove Copyright and legalese from version string, and 33648 # collapse into a single line 33649 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 33650 $SED -e 's/ *Copyright .*//'` 33651 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 33652 $SED -e 's/^.* \([1-9]\.[0-9.]*\)[^0-9.].*$/\1/'` 33653 elif test "x$TOOLCHAIN_TYPE" = xclang; then 33654 # clang --version output typically looks like 33655 # Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn) 33656 # clang version 3.3 (tags/RELEASE_33/final) 33657 # or 33658 # Debian clang version 3.2-7ubuntu1 (tags/RELEASE_32/final) (based on LLVM 3.2) 33659 # Target: x86_64-pc-linux-gnu 33660 # Thread model: posix 33661 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 33662 # Check that this is likely to be clang 33663 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "clang" > /dev/null 33664 if test $? -ne 0; then 33665 { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&5 33666 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 33667 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&5 33668 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 33669 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 33670 fi 33671 # Collapse compiler output into a single line 33672 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 33673 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 33674 $SED -e 's/^.* version \([1-9][0-9.]*\).*$/\1/'` 33675 else 33676 as_fn_error $? "Unknown toolchain type $TOOLCHAIN_TYPE." "$LINENO" 5 33677 fi 33678 # This sets CC_VERSION_NUMBER or CXX_VERSION_NUMBER. (This comment is a grep marker) 33679 CC_VERSION_NUMBER="$COMPILER_VERSION_NUMBER" 33680 # This sets CC_VERSION_STRING or CXX_VERSION_STRING. (This comment is a grep marker) 33681 CC_VERSION_STRING="$COMPILER_VERSION_STRING" 33682 33683 { $as_echo "$as_me:${as_lineno-$LINENO}: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&5 33684 $as_echo "$as_me: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&6;} 33685 33686 33687 # Now that we have resolved CC ourself, let autoconf have its go at it 33688 ac_ext=c 33689 ac_cpp='$CPP $CPPFLAGS' 33690 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 33691 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 33692 ac_compiler_gnu=$ac_cv_c_compiler_gnu 33693 if test -n "$ac_tool_prefix"; then 33694 for ac_prog in $CC 33695 do 33696 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 33697 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 33698 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33699 $as_echo_n "checking for $ac_word... " >&6; } 33700 if ${ac_cv_prog_CC+:} false; then : 33701 $as_echo_n "(cached) " >&6 33702 else 33703 if test -n "$CC"; then 33704 ac_cv_prog_CC="$CC" # Let the user override the test. 33705 else 33706 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33707 for as_dir in $PATH 33708 do 33709 IFS=$as_save_IFS 33710 test -z "$as_dir" && as_dir=. 33711 for ac_exec_ext in '' $ac_executable_extensions; do 33712 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 33713 ac_cv_prog_CC="$ac_tool_prefix$ac_prog" 33714 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 33715 break 2 33716 fi 33717 done 33718 done 33719 IFS=$as_save_IFS 33720 33721 fi 33722 fi 33723 CC=$ac_cv_prog_CC 33724 if test -n "$CC"; then 33725 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 33726 $as_echo "$CC" >&6; } 33727 else 33728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33729 $as_echo "no" >&6; } 33730 fi 33731 33732 33733 test -n "$CC" && break 33734 done 33735 fi 33736 if test -z "$CC"; then 33737 ac_ct_CC=$CC 33738 for ac_prog in $CC 33739 do 33740 # Extract the first word of "$ac_prog", so it can be a program name with args. 33741 set dummy $ac_prog; ac_word=$2 33742 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33743 $as_echo_n "checking for $ac_word... " >&6; } 33744 if ${ac_cv_prog_ac_ct_CC+:} false; then : 33745 $as_echo_n "(cached) " >&6 33746 else 33747 if test -n "$ac_ct_CC"; then 33748 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. 33749 else 33750 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33751 for as_dir in $PATH 33752 do 33753 IFS=$as_save_IFS 33754 test -z "$as_dir" && as_dir=. 33755 for ac_exec_ext in '' $ac_executable_extensions; do 33756 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 33757 ac_cv_prog_ac_ct_CC="$ac_prog" 33758 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 33759 break 2 33760 fi 33761 done 33762 done 33763 IFS=$as_save_IFS 33764 33765 fi 33766 fi 33767 ac_ct_CC=$ac_cv_prog_ac_ct_CC 33768 if test -n "$ac_ct_CC"; then 33769 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 33770 $as_echo "$ac_ct_CC" >&6; } 33771 else 33772 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33773 $as_echo "no" >&6; } 33774 fi 33775 33776 33777 test -n "$ac_ct_CC" && break 33778 done 33779 33780 if test "x$ac_ct_CC" = x; then 33781 CC="" 33782 else 33783 case $cross_compiling:$ac_tool_warned in 33784 yes:) 33785 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 33786 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 33787 ac_tool_warned=yes ;; 33788 esac 33789 CC=$ac_ct_CC 33790 fi 33791 fi 33792 33793 33794 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 33795 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 33796 as_fn_error $? "no acceptable C compiler found in \$PATH 33797 See \`config.log' for more details" "$LINENO" 5; } 33798 33799 # Provide some information about the compiler. 33800 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 33801 set X $ac_compile 33802 ac_compiler=$2 33803 for ac_option in --version -v -V -qversion; do 33804 { { ac_try="$ac_compiler $ac_option >&5" 33805 case "(($ac_try" in 33806 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 33807 *) ac_try_echo=$ac_try;; 33808 esac 33809 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 33810 $as_echo "$ac_try_echo"; } >&5 33811 (eval "$ac_compiler $ac_option >&5") 2>conftest.err 33812 ac_status=$? 33813 if test -s conftest.err; then 33814 sed '10a\ 33815 ... rest of stderr output deleted ... 33816 10q' conftest.err >conftest.er1 33817 cat conftest.er1 >&5 33818 fi 33819 rm -f conftest.er1 conftest.err 33820 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 33821 test $ac_status = 0; } 33822 done 33823 33824 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 33825 /* end confdefs.h. */ 33826 33827 int 33828 main () 33829 { 33830 33831 ; 33832 return 0; 33833 } 33834 _ACEOF 33835 ac_clean_files_save=$ac_clean_files 33836 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" 33837 # Try to create an executable without -o first, disregard a.out. 33838 # It will help us diagnose broken compilers, and finding out an intuition 33839 # of exeext. 33840 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 33841 $as_echo_n "checking whether the C compiler works... " >&6; } 33842 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` 33843 33844 # The possible output files: 33845 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" 33846 33847 ac_rmfiles= 33848 for ac_file in $ac_files 33849 do 33850 case $ac_file in 33851 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; 33852 * ) ac_rmfiles="$ac_rmfiles $ac_file";; 33853 esac 33854 done 33855 rm -f $ac_rmfiles 33856 33857 if { { ac_try="$ac_link_default" 33858 case "(($ac_try" in 33859 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 33860 *) ac_try_echo=$ac_try;; 33861 esac 33862 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 33863 $as_echo "$ac_try_echo"; } >&5 33864 (eval "$ac_link_default") 2>&5 33865 ac_status=$? 33866 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 33867 test $ac_status = 0; }; then : 33868 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. 33869 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no' 33870 # in a Makefile. We should not override ac_cv_exeext if it was cached, 33871 # so that the user can short-circuit this test for compilers unknown to 33872 # Autoconf. 33873 for ac_file in $ac_files '' 33874 do 33875 test -f "$ac_file" || continue 33876 case $ac_file in 33877 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) 33878 ;; 33879 [ab].out ) 33880 # We found the default executable, but exeext='' is most 33881 # certainly right. 33882 break;; 33883 *.* ) 33884 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; 33885 then :; else 33886 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` 33887 fi 33888 # We set ac_cv_exeext here because the later test for it is not 33889 # safe: cross compilers may not add the suffix if given an `-o' 33890 # argument, so we may need to know it at that point already. 33891 # Even if this section looks crufty: it has the advantage of 33892 # actually working. 33893 break;; 33894 * ) 33895 break;; 33896 esac 33897 done 33898 test "$ac_cv_exeext" = no && ac_cv_exeext= 33899 33900 else 33901 ac_file='' 33902 fi 33903 if test -z "$ac_file"; then : 33904 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33905 $as_echo "no" >&6; } 33906 $as_echo "$as_me: failed program was:" >&5 33907 sed 's/^/| /' conftest.$ac_ext >&5 33908 33909 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 33910 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 33911 as_fn_error 77 "C compiler cannot create executables 33912 See \`config.log' for more details" "$LINENO" 5; } 33913 else 33914 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 33915 $as_echo "yes" >&6; } 33916 fi 33917 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 33918 $as_echo_n "checking for C compiler default output file name... " >&6; } 33919 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 33920 $as_echo "$ac_file" >&6; } 33921 ac_exeext=$ac_cv_exeext 33922 33923 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out 33924 ac_clean_files=$ac_clean_files_save 33925 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 33926 $as_echo_n "checking for suffix of executables... " >&6; } 33927 if { { ac_try="$ac_link" 33928 case "(($ac_try" in 33929 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 33930 *) ac_try_echo=$ac_try;; 33931 esac 33932 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 33933 $as_echo "$ac_try_echo"; } >&5 33934 (eval "$ac_link") 2>&5 33935 ac_status=$? 33936 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 33937 test $ac_status = 0; }; then : 33938 # If both `conftest.exe' and `conftest' are `present' (well, observable) 33939 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will 33940 # work properly (i.e., refer to `conftest.exe'), while it won't with 33941 # `rm'. 33942 for ac_file in conftest.exe conftest conftest.*; do 33943 test -f "$ac_file" || continue 33944 case $ac_file in 33945 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; 33946 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` 33947 break;; 33948 * ) break;; 33949 esac 33950 done 33951 else 33952 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 33953 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 33954 as_fn_error $? "cannot compute suffix of executables: cannot compile and link 33955 See \`config.log' for more details" "$LINENO" 5; } 33956 fi 33957 rm -f conftest conftest$ac_cv_exeext 33958 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 33959 $as_echo "$ac_cv_exeext" >&6; } 33960 33961 rm -f conftest.$ac_ext 33962 EXEEXT=$ac_cv_exeext 33963 ac_exeext=$EXEEXT 33964 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 33965 /* end confdefs.h. */ 33966 #include <stdio.h> 33967 int 33968 main () 33969 { 33970 FILE *f = fopen ("conftest.out", "w"); 33971 return ferror (f) || fclose (f) != 0; 33972 33973 ; 33974 return 0; 33975 } 33976 _ACEOF 33977 ac_clean_files="$ac_clean_files conftest.out" 33978 # Check that the compiler produces executables we can run. If not, either 33979 # the compiler is broken, or we cross compile. 33980 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 33981 $as_echo_n "checking whether we are cross compiling... " >&6; } 33982 if test "$cross_compiling" != yes; then 33983 { { ac_try="$ac_link" 33984 case "(($ac_try" in 33985 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 33986 *) ac_try_echo=$ac_try;; 33987 esac 33988 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 33989 $as_echo "$ac_try_echo"; } >&5 33990 (eval "$ac_link") 2>&5 33991 ac_status=$? 33992 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 33993 test $ac_status = 0; } 33994 if { ac_try='./conftest$ac_cv_exeext' 33995 { { case "(($ac_try" in 33996 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 33997 *) ac_try_echo=$ac_try;; 33998 esac 33999 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 34000 $as_echo "$ac_try_echo"; } >&5 34001 (eval "$ac_try") 2>&5 34002 ac_status=$? 34003 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 34004 test $ac_status = 0; }; }; then 34005 cross_compiling=no 34006 else 34007 if test "$cross_compiling" = maybe; then 34008 cross_compiling=yes 34009 else 34010 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 34011 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 34012 as_fn_error $? "cannot run C compiled programs. 34013 If you meant to cross compile, use \`--host'. 34014 See \`config.log' for more details" "$LINENO" 5; } 34015 fi 34016 fi 34017 fi 34018 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 34019 $as_echo "$cross_compiling" >&6; } 34020 34021 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out 34022 ac_clean_files=$ac_clean_files_save 34023 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 34024 $as_echo_n "checking for suffix of object files... " >&6; } 34025 if ${ac_cv_objext+:} false; then : 34026 $as_echo_n "(cached) " >&6 34027 else 34028 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34029 /* end confdefs.h. */ 34030 34031 int 34032 main () 34033 { 34034 34035 ; 34036 return 0; 34037 } 34038 _ACEOF 34039 rm -f conftest.o conftest.obj 34040 if { { ac_try="$ac_compile" 34041 case "(($ac_try" in 34042 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 34043 *) ac_try_echo=$ac_try;; 34044 esac 34045 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 34046 $as_echo "$ac_try_echo"; } >&5 34047 (eval "$ac_compile") 2>&5 34048 ac_status=$? 34049 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 34050 test $ac_status = 0; }; then : 34051 for ac_file in conftest.o conftest.obj conftest.*; do 34052 test -f "$ac_file" || continue; 34053 case $ac_file in 34054 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; 34055 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` 34056 break;; 34057 esac 34058 done 34059 else 34060 $as_echo "$as_me: failed program was:" >&5 34061 sed 's/^/| /' conftest.$ac_ext >&5 34062 34063 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 34064 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 34065 as_fn_error $? "cannot compute suffix of object files: cannot compile 34066 See \`config.log' for more details" "$LINENO" 5; } 34067 fi 34068 rm -f conftest.$ac_cv_objext conftest.$ac_ext 34069 fi 34070 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 34071 $as_echo "$ac_cv_objext" >&6; } 34072 OBJEXT=$ac_cv_objext 34073 ac_objext=$OBJEXT 34074 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 34075 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; } 34076 if ${ac_cv_c_compiler_gnu+:} false; then : 34077 $as_echo_n "(cached) " >&6 34078 else 34079 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34080 /* end confdefs.h. */ 34081 34082 int 34083 main () 34084 { 34085 #ifndef __GNUC__ 34086 choke me 34087 #endif 34088 34089 ; 34090 return 0; 34091 } 34092 _ACEOF 34093 if ac_fn_c_try_compile "$LINENO"; then : 34094 ac_compiler_gnu=yes 34095 else 34096 ac_compiler_gnu=no 34097 fi 34098 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 34099 ac_cv_c_compiler_gnu=$ac_compiler_gnu 34100 34101 fi 34102 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 34103 $as_echo "$ac_cv_c_compiler_gnu" >&6; } 34104 if test $ac_compiler_gnu = yes; then 34105 GCC=yes 34106 else 34107 GCC= 34108 fi 34109 ac_test_CFLAGS=${CFLAGS+set} 34110 ac_save_CFLAGS=$CFLAGS 34111 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 34112 $as_echo_n "checking whether $CC accepts -g... " >&6; } 34113 if ${ac_cv_prog_cc_g+:} false; then : 34114 $as_echo_n "(cached) " >&6 34115 else 34116 ac_save_c_werror_flag=$ac_c_werror_flag 34117 ac_c_werror_flag=yes 34118 ac_cv_prog_cc_g=no 34119 CFLAGS="-g" 34120 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34121 /* end confdefs.h. */ 34122 34123 int 34124 main () 34125 { 34126 34127 ; 34128 return 0; 34129 } 34130 _ACEOF 34131 if ac_fn_c_try_compile "$LINENO"; then : 34132 ac_cv_prog_cc_g=yes 34133 else 34134 CFLAGS="" 34135 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34136 /* end confdefs.h. */ 34137 34138 int 34139 main () 34140 { 34141 34142 ; 34143 return 0; 34144 } 34145 _ACEOF 34146 if ac_fn_c_try_compile "$LINENO"; then : 34147 34148 else 34149 ac_c_werror_flag=$ac_save_c_werror_flag 34150 CFLAGS="-g" 34151 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34152 /* end confdefs.h. */ 34153 34154 int 34155 main () 34156 { 34157 34158 ; 34159 return 0; 34160 } 34161 _ACEOF 34162 if ac_fn_c_try_compile "$LINENO"; then : 34163 ac_cv_prog_cc_g=yes 34164 fi 34165 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 34166 fi 34167 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 34168 fi 34169 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 34170 ac_c_werror_flag=$ac_save_c_werror_flag 34171 fi 34172 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 34173 $as_echo "$ac_cv_prog_cc_g" >&6; } 34174 if test "$ac_test_CFLAGS" = set; then 34175 CFLAGS=$ac_save_CFLAGS 34176 elif test $ac_cv_prog_cc_g = yes; then 34177 if test "$GCC" = yes; then 34178 CFLAGS="-g -O2" 34179 else 34180 CFLAGS="-g" 34181 fi 34182 else 34183 if test "$GCC" = yes; then 34184 CFLAGS="-O2" 34185 else 34186 CFLAGS= 34187 fi 34188 fi 34189 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 34190 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; } 34191 if ${ac_cv_prog_cc_c89+:} false; then : 34192 $as_echo_n "(cached) " >&6 34193 else 34194 ac_cv_prog_cc_c89=no 34195 ac_save_CC=$CC 34196 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34197 /* end confdefs.h. */ 34198 #include <stdarg.h> 34199 #include <stdio.h> 34200 struct stat; 34201 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ 34202 struct buf { int x; }; 34203 FILE * (*rcsopen) (struct buf *, struct stat *, int); 34204 static char *e (p, i) 34205 char **p; 34206 int i; 34207 { 34208 return p[i]; 34209 } 34210 static char *f (char * (*g) (char **, int), char **p, ...) 34211 { 34212 char *s; 34213 va_list v; 34214 va_start (v,p); 34215 s = g (p, va_arg (v,int)); 34216 va_end (v); 34217 return s; 34218 } 34219 34220 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has 34221 function prototypes and stuff, but not '\xHH' hex character constants. 34222 These don't provoke an error unfortunately, instead are silently treated 34223 as 'x'. The following induces an error, until -std is added to get 34224 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an 34225 array size at least. It's necessary to write '\x00'==0 to get something 34226 that's true only with -std. */ 34227 int osf4_cc_array ['\x00' == 0 ? 1 : -1]; 34228 34229 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters 34230 inside strings and character constants. */ 34231 #define FOO(x) 'x' 34232 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; 34233 34234 int test (int i, double x); 34235 struct s1 {int (*f) (int a);}; 34236 struct s2 {int (*f) (double a);}; 34237 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); 34238 int argc; 34239 char **argv; 34240 int 34241 main () 34242 { 34243 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; 34244 ; 34245 return 0; 34246 } 34247 _ACEOF 34248 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ 34249 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" 34250 do 34251 CC="$ac_save_CC $ac_arg" 34252 if ac_fn_c_try_compile "$LINENO"; then : 34253 ac_cv_prog_cc_c89=$ac_arg 34254 fi 34255 rm -f core conftest.err conftest.$ac_objext 34256 test "x$ac_cv_prog_cc_c89" != "xno" && break 34257 done 34258 rm -f conftest.$ac_ext 34259 CC=$ac_save_CC 34260 34261 fi 34262 # AC_CACHE_VAL 34263 case "x$ac_cv_prog_cc_c89" in 34264 x) 34265 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 34266 $as_echo "none needed" >&6; } ;; 34267 xno) 34268 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 34269 $as_echo "unsupported" >&6; } ;; 34270 *) 34271 CC="$CC $ac_cv_prog_cc_c89" 34272 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 34273 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;; 34274 esac 34275 if test "x$ac_cv_prog_cc_c89" != xno; then : 34276 34277 fi 34278 34279 ac_ext=cpp 34280 ac_cpp='$CXXCPP $CPPFLAGS' 34281 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 34282 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 34283 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 34284 34285 34286 34287 COMPILER_NAME=C++ 34288 SEARCH_LIST="$TOOLCHAIN_CXX_BINARY" 34289 34290 if test "x$CXX" != x; then 34291 # User has supplied compiler name already, always let that override. 34292 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied compiler CXX=$CXX" >&5 34293 $as_echo "$as_me: Will use user supplied compiler CXX=$CXX" >&6;} 34294 if test "x`basename $CXX`" = "x$CXX"; then 34295 # A command without a complete path is provided, search $PATH. 34296 34297 for ac_prog in $CXX 34298 do 34299 # Extract the first word of "$ac_prog", so it can be a program name with args. 34300 set dummy $ac_prog; ac_word=$2 34301 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 34302 $as_echo_n "checking for $ac_word... " >&6; } 34303 if ${ac_cv_path_POTENTIAL_CXX+:} false; then : 34304 $as_echo_n "(cached) " >&6 34305 else 34306 case $POTENTIAL_CXX in 34307 [\\/]* | ?:[\\/]*) 34308 ac_cv_path_POTENTIAL_CXX="$POTENTIAL_CXX" # Let the user override the test with a path. 34309 ;; 34310 *) 34311 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 34312 for as_dir in $PATH 34313 do 34314 IFS=$as_save_IFS 34315 test -z "$as_dir" && as_dir=. 34316 for ac_exec_ext in '' $ac_executable_extensions; do 34317 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 34318 ac_cv_path_POTENTIAL_CXX="$as_dir/$ac_word$ac_exec_ext" 34319 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 34320 break 2 34321 fi 34322 done 34323 done 34324 IFS=$as_save_IFS 34325 34326 ;; 34327 esac 34328 fi 34329 POTENTIAL_CXX=$ac_cv_path_POTENTIAL_CXX 34330 if test -n "$POTENTIAL_CXX"; then 34331 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CXX" >&5 34332 $as_echo "$POTENTIAL_CXX" >&6; } 34333 else 34334 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 34335 $as_echo "no" >&6; } 34336 fi 34337 34338 34339 test -n "$POTENTIAL_CXX" && break 34340 done 34341 34342 if test "x$POTENTIAL_CXX" != x; then 34343 CXX=$POTENTIAL_CXX 34344 else 34345 as_fn_error $? "User supplied compiler CXX=$CXX could not be found" "$LINENO" 5 34346 fi 34347 else 34348 # Otherwise it might already be a complete path 34349 if test ! -x "$CXX"; then 34350 as_fn_error $? "User supplied compiler CXX=$CXX does not exist" "$LINENO" 5 34351 fi 34352 fi 34353 else 34354 # No user supplied value. Locate compiler ourselves. 34355 34356 # If we are cross compiling, assume cross compilation tools follows the 34357 # cross compilation standard where they are prefixed with the autoconf 34358 # standard name for the target. For example the binary 34359 # i686-sun-solaris2.10-gcc will cross compile for i686-sun-solaris2.10. 34360 # If we are not cross compiling, then the default compiler name will be 34361 # used. 34362 34363 CXX= 34364 # If TOOLCHAIN_PATH is set, check for all compiler names in there first 34365 # before checking the rest of the PATH. 34366 # FIXME: Now that we prefix the TOOLS_DIR to the PATH in the PRE_DETECTION 34367 # step, this should not be necessary. 34368 if test -n "$TOOLCHAIN_PATH"; then 34369 PATH_save="$PATH" 34370 PATH="$TOOLCHAIN_PATH" 34371 for ac_prog in $SEARCH_LIST 34372 do 34373 # Extract the first word of "$ac_prog", so it can be a program name with args. 34374 set dummy $ac_prog; ac_word=$2 34375 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 34376 $as_echo_n "checking for $ac_word... " >&6; } 34377 if ${ac_cv_path_TOOLCHAIN_PATH_CXX+:} false; then : 34378 $as_echo_n "(cached) " >&6 34379 else 34380 case $TOOLCHAIN_PATH_CXX in 34381 [\\/]* | ?:[\\/]*) 34382 ac_cv_path_TOOLCHAIN_PATH_CXX="$TOOLCHAIN_PATH_CXX" # Let the user override the test with a path. 34383 ;; 34384 *) 34385 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 34386 for as_dir in $PATH 34387 do 34388 IFS=$as_save_IFS 34389 test -z "$as_dir" && as_dir=. 34390 for ac_exec_ext in '' $ac_executable_extensions; do 34391 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 34392 ac_cv_path_TOOLCHAIN_PATH_CXX="$as_dir/$ac_word$ac_exec_ext" 34393 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 34394 break 2 34395 fi 34396 done 34397 done 34398 IFS=$as_save_IFS 34399 34400 ;; 34401 esac 34402 fi 34403 TOOLCHAIN_PATH_CXX=$ac_cv_path_TOOLCHAIN_PATH_CXX 34404 if test -n "$TOOLCHAIN_PATH_CXX"; then 34405 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLCHAIN_PATH_CXX" >&5 34406 $as_echo "$TOOLCHAIN_PATH_CXX" >&6; } 34407 else 34408 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 34409 $as_echo "no" >&6; } 34410 fi 34411 34412 34413 test -n "$TOOLCHAIN_PATH_CXX" && break 34414 done 34415 34416 CXX=$TOOLCHAIN_PATH_CXX 34417 PATH="$PATH_save" 34418 fi 34419 34420 # AC_PATH_PROGS can't be run multiple times with the same variable, 34421 # so create a new name for this run. 34422 if test "x$CXX" = x; then 34423 for ac_prog in $SEARCH_LIST 34424 do 34425 # Extract the first word of "$ac_prog", so it can be a program name with args. 34426 set dummy $ac_prog; ac_word=$2 34427 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 34428 $as_echo_n "checking for $ac_word... " >&6; } 34429 if ${ac_cv_path_POTENTIAL_CXX+:} false; then : 34430 $as_echo_n "(cached) " >&6 34431 else 34432 case $POTENTIAL_CXX in 34433 [\\/]* | ?:[\\/]*) 34434 ac_cv_path_POTENTIAL_CXX="$POTENTIAL_CXX" # Let the user override the test with a path. 34435 ;; 34436 *) 34437 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 34438 for as_dir in $PATH 34439 do 34440 IFS=$as_save_IFS 34441 test -z "$as_dir" && as_dir=. 34442 for ac_exec_ext in '' $ac_executable_extensions; do 34443 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 34444 ac_cv_path_POTENTIAL_CXX="$as_dir/$ac_word$ac_exec_ext" 34445 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 34446 break 2 34447 fi 34448 done 34449 done 34450 IFS=$as_save_IFS 34451 34452 ;; 34453 esac 34454 fi 34455 POTENTIAL_CXX=$ac_cv_path_POTENTIAL_CXX 34456 if test -n "$POTENTIAL_CXX"; then 34457 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CXX" >&5 34458 $as_echo "$POTENTIAL_CXX" >&6; } 34459 else 34460 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 34461 $as_echo "no" >&6; } 34462 fi 34463 34464 34465 test -n "$POTENTIAL_CXX" && break 34466 done 34467 34468 CXX=$POTENTIAL_CXX 34469 fi 34470 34471 if test "x$CXX" = x; then 34472 34473 # Print a helpful message on how to acquire the necessary build dependency. 34474 # devkit is the help tag: freetype, cups, alsa etc 34475 MISSING_DEPENDENCY=devkit 34476 34477 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34478 cygwin_help $MISSING_DEPENDENCY 34479 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34480 msys_help $MISSING_DEPENDENCY 34481 else 34482 PKGHANDLER_COMMAND= 34483 34484 case $PKGHANDLER in 34485 apt-get) 34486 apt_help $MISSING_DEPENDENCY ;; 34487 yum) 34488 yum_help $MISSING_DEPENDENCY ;; 34489 port) 34490 port_help $MISSING_DEPENDENCY ;; 34491 pkgutil) 34492 pkgutil_help $MISSING_DEPENDENCY ;; 34493 pkgadd) 34494 pkgadd_help $MISSING_DEPENDENCY ;; 34495 esac 34496 34497 if test "x$PKGHANDLER_COMMAND" != x; then 34498 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 34499 fi 34500 fi 34501 34502 as_fn_error $? "Could not find a $COMPILER_NAME compiler. $HELP_MSG" "$LINENO" 5 34503 fi 34504 fi 34505 34506 # Now we have a compiler binary in CXX. Make sure it's okay. 34507 34508 # Only process if variable expands to non-empty 34509 34510 if test "x$CXX" != x; then 34511 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34512 34513 # First separate the path from the arguments. This will split at the first 34514 # space. 34515 complete="$CXX" 34516 path="${complete%% *}" 34517 tmp="$complete EOL" 34518 arguments="${tmp#* }" 34519 34520 # Input might be given as Windows format, start by converting to 34521 # unix format. 34522 new_path=`$CYGPATH -u "$path"` 34523 34524 # Now try to locate executable using which 34525 new_path=`$WHICH "$new_path" 2> /dev/null` 34526 # bat and cmd files are not always considered executable in cygwin causing which 34527 # to not find them 34528 if test "x$new_path" = x \ 34529 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 34530 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 34531 new_path=`$CYGPATH -u "$path"` 34532 fi 34533 if test "x$new_path" = x; then 34534 # Oops. Which didn't find the executable. 34535 # The splitting of arguments from the executable at a space might have been incorrect, 34536 # since paths with space are more likely in Windows. Give it another try with the whole 34537 # argument. 34538 path="$complete" 34539 arguments="EOL" 34540 new_path=`$CYGPATH -u "$path"` 34541 new_path=`$WHICH "$new_path" 2> /dev/null` 34542 # bat and cmd files are not always considered executable in cygwin causing which 34543 # to not find them 34544 if test "x$new_path" = x \ 34545 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 34546 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 34547 new_path=`$CYGPATH -u "$path"` 34548 fi 34549 if test "x$new_path" = x; then 34550 # It's still not found. Now this is an unrecoverable error. 34551 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5 34552 $as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;} 34553 has_space=`$ECHO "$complete" | $GREP " "` 34554 if test "x$has_space" != x; then 34555 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 34556 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 34557 fi 34558 as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5 34559 fi 34560 fi 34561 34562 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 34563 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 34564 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 34565 # "foo.exe" is OK but "foo" is an error. 34566 # 34567 # This test is therefore slightly more accurate than "test -f" to check for file presence. 34568 # It is also a way to make sure we got the proper file name for the real test later on. 34569 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 34570 if test "x$test_shortpath" = x; then 34571 # Short path failed, file does not exist as specified. 34572 # Try adding .exe or .cmd 34573 if test -f "${new_path}.exe"; then 34574 input_to_shortpath="${new_path}.exe" 34575 elif test -f "${new_path}.cmd"; then 34576 input_to_shortpath="${new_path}.cmd" 34577 else 34578 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$new_path\", is invalid." >&5 34579 $as_echo "$as_me: The path of CXX, which resolves as \"$new_path\", is invalid." >&6;} 34580 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 34581 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 34582 as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5 34583 fi 34584 else 34585 input_to_shortpath="$new_path" 34586 fi 34587 34588 # Call helper function which possibly converts this using DOS-style short mode. 34589 # If so, the updated path is stored in $new_path. 34590 new_path="$input_to_shortpath" 34591 34592 input_path="$input_to_shortpath" 34593 # Check if we need to convert this using DOS-style short mode. If the path 34594 # contains just simple characters, use it. Otherwise (spaces, weird characters), 34595 # take no chances and rewrite it. 34596 # Note: m4 eats our [], so we need to use [ and ] instead. 34597 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 34598 if test "x$has_forbidden_chars" != x; then 34599 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 34600 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 34601 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 34602 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 34603 # Going to short mode and back again did indeed matter. Since short mode is 34604 # case insensitive, let's make it lowercase to improve readability. 34605 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 34606 # Now convert it back to Unix-style (cygpath) 34607 input_path=`$CYGPATH -u "$shortmode_path"` 34608 new_path="$input_path" 34609 fi 34610 fi 34611 34612 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 34613 if test "x$test_cygdrive_prefix" = x; then 34614 # As a simple fix, exclude /usr/bin since it's not a real path. 34615 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 34616 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 34617 # a path prefixed by /cygdrive for fixpath to work. 34618 new_path="$CYGWIN_ROOT_PATH$input_path" 34619 fi 34620 fi 34621 34622 # remove trailing .exe if any 34623 new_path="${new_path/%.exe/}" 34624 34625 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34626 34627 # First separate the path from the arguments. This will split at the first 34628 # space. 34629 complete="$CXX" 34630 path="${complete%% *}" 34631 tmp="$complete EOL" 34632 arguments="${tmp#* }" 34633 34634 # Input might be given as Windows format, start by converting to 34635 # unix format. 34636 new_path="$path" 34637 34638 windows_path="$new_path" 34639 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34640 unix_path=`$CYGPATH -u "$windows_path"` 34641 new_path="$unix_path" 34642 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34643 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 34644 new_path="$unix_path" 34645 fi 34646 34647 34648 # Now try to locate executable using which 34649 new_path=`$WHICH "$new_path" 2> /dev/null` 34650 34651 if test "x$new_path" = x; then 34652 # Oops. Which didn't find the executable. 34653 # The splitting of arguments from the executable at a space might have been incorrect, 34654 # since paths with space are more likely in Windows. Give it another try with the whole 34655 # argument. 34656 path="$complete" 34657 arguments="EOL" 34658 new_path="$path" 34659 34660 windows_path="$new_path" 34661 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34662 unix_path=`$CYGPATH -u "$windows_path"` 34663 new_path="$unix_path" 34664 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34665 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 34666 new_path="$unix_path" 34667 fi 34668 34669 34670 new_path=`$WHICH "$new_path" 2> /dev/null` 34671 # bat and cmd files are not always considered executable in MSYS causing which 34672 # to not find them 34673 if test "x$new_path" = x \ 34674 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 34675 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 34676 new_path="$path" 34677 34678 windows_path="$new_path" 34679 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34680 unix_path=`$CYGPATH -u "$windows_path"` 34681 new_path="$unix_path" 34682 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34683 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 34684 new_path="$unix_path" 34685 fi 34686 34687 fi 34688 34689 if test "x$new_path" = x; then 34690 # It's still not found. Now this is an unrecoverable error. 34691 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5 34692 $as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;} 34693 has_space=`$ECHO "$complete" | $GREP " "` 34694 if test "x$has_space" != x; then 34695 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 34696 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 34697 fi 34698 as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5 34699 fi 34700 fi 34701 34702 # Now new_path has a complete unix path to the binary 34703 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 34704 # Keep paths in /bin as-is, but remove trailing .exe if any 34705 new_path="${new_path/%.exe/}" 34706 # Do not save /bin paths to all_fixpath_prefixes! 34707 else 34708 # Not in mixed or Windows style, start by that. 34709 new_path=`cmd //c echo $new_path` 34710 34711 input_path="$new_path" 34712 # Check if we need to convert this using DOS-style short mode. If the path 34713 # contains just simple characters, use it. Otherwise (spaces, weird characters), 34714 # take no chances and rewrite it. 34715 # Note: m4 eats our [], so we need to use [ and ] instead. 34716 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 34717 if test "x$has_forbidden_chars" != x; then 34718 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 34719 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 34720 fi 34721 34722 # Output is in $new_path 34723 34724 windows_path="$new_path" 34725 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34726 unix_path=`$CYGPATH -u "$windows_path"` 34727 new_path="$unix_path" 34728 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34729 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 34730 new_path="$unix_path" 34731 fi 34732 34733 # remove trailing .exe if any 34734 new_path="${new_path/%.exe/}" 34735 34736 # Save the first 10 bytes of this path to the storage, so fixpath can work. 34737 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 34738 fi 34739 34740 else 34741 # We're on a unix platform. Hooray! :) 34742 # First separate the path from the arguments. This will split at the first 34743 # space. 34744 complete="$CXX" 34745 path="${complete%% *}" 34746 tmp="$complete EOL" 34747 arguments="${tmp#* }" 34748 34749 # Cannot rely on the command "which" here since it doesn't always work. 34750 is_absolute_path=`$ECHO "$path" | $GREP ^/` 34751 if test -z "$is_absolute_path"; then 34752 # Path to executable is not absolute. Find it. 34753 IFS_save="$IFS" 34754 IFS=: 34755 for p in $PATH; do 34756 if test -f "$p/$path" && test -x "$p/$path"; then 34757 new_path="$p/$path" 34758 break 34759 fi 34760 done 34761 IFS="$IFS_save" 34762 else 34763 # This is an absolute path, we can use it without further modifications. 34764 new_path="$path" 34765 fi 34766 34767 if test "x$new_path" = x; then 34768 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5 34769 $as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;} 34770 has_space=`$ECHO "$complete" | $GREP " "` 34771 if test "x$has_space" != x; then 34772 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 34773 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 34774 fi 34775 as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5 34776 fi 34777 fi 34778 34779 # Now join together the path and the arguments once again 34780 if test "x$arguments" != xEOL; then 34781 new_complete="$new_path ${arguments% *}" 34782 else 34783 new_complete="$new_path" 34784 fi 34785 34786 if test "x$complete" != "x$new_complete"; then 34787 CXX="$new_complete" 34788 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CXX to \"$new_complete\"" >&5 34789 $as_echo "$as_me: Rewriting CXX to \"$new_complete\"" >&6;} 34790 fi 34791 fi 34792 34793 TEST_COMPILER="$CXX" 34794 34795 { $as_echo "$as_me:${as_lineno-$LINENO}: checking resolved symbolic links for CXX" >&5 34796 $as_echo_n "checking resolved symbolic links for CXX... " >&6; } 34797 SYMLINK_ORIGINAL="$TEST_COMPILER" 34798 34799 if test "x$OPENJDK_BUILD_OS" != xwindows; then 34800 # Follow a chain of symbolic links. Use readlink 34801 # where it exists, else fall back to horribly 34802 # complicated shell code. 34803 if test "x$READLINK_TESTED" != yes; then 34804 # On MacOSX there is a readlink tool with a different 34805 # purpose than the GNU readlink tool. Check the found readlink. 34806 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 34807 if test "x$ISGNU" = x; then 34808 # A readlink that we do not know how to use. 34809 # Are there other non-GNU readlinks out there? 34810 READLINK_TESTED=yes 34811 READLINK= 34812 fi 34813 fi 34814 34815 if test "x$READLINK" != x; then 34816 SYMLINK_ORIGINAL=`$READLINK -f $SYMLINK_ORIGINAL` 34817 else 34818 # Save the current directory for restoring afterwards 34819 STARTDIR=$PWD 34820 COUNTER=0 34821 sym_link_dir=`$DIRNAME $SYMLINK_ORIGINAL` 34822 sym_link_file=`$BASENAME $SYMLINK_ORIGINAL` 34823 cd $sym_link_dir 34824 # Use -P flag to resolve symlinks in directories. 34825 cd `$THEPWDCMD -P` 34826 sym_link_dir=`$THEPWDCMD -P` 34827 # Resolve file symlinks 34828 while test $COUNTER -lt 20; do 34829 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 34830 if test "x$ISLINK" == x; then 34831 # This is not a symbolic link! We are done! 34832 break 34833 fi 34834 # Again resolve directory symlinks since the target of the just found 34835 # link could be in a different directory 34836 cd `$DIRNAME $ISLINK` 34837 sym_link_dir=`$THEPWDCMD -P` 34838 sym_link_file=`$BASENAME $ISLINK` 34839 let COUNTER=COUNTER+1 34840 done 34841 cd $STARTDIR 34842 SYMLINK_ORIGINAL=$sym_link_dir/$sym_link_file 34843 fi 34844 fi 34845 34846 if test "x$TEST_COMPILER" = "x$SYMLINK_ORIGINAL"; then 34847 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no symlink" >&5 34848 $as_echo "no symlink" >&6; } 34849 else 34850 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SYMLINK_ORIGINAL" >&5 34851 $as_echo "$SYMLINK_ORIGINAL" >&6; } 34852 34853 # We can't handle ccache by gcc wrappers, since we need to know if we're 34854 # using ccache. Instead ccache usage must be controlled by a configure option. 34855 COMPILER_BASENAME=`$BASENAME "$SYMLINK_ORIGINAL"` 34856 if test "x$COMPILER_BASENAME" = "xccache"; then 34857 { $as_echo "$as_me:${as_lineno-$LINENO}: Please use --enable-ccache instead of providing a wrapped compiler." >&5 34858 $as_echo "$as_me: Please use --enable-ccache instead of providing a wrapped compiler." >&6;} 34859 as_fn_error $? "$TEST_COMPILER is a symbolic link to ccache. This is not supported." "$LINENO" 5 34860 fi 34861 fi 34862 34863 34864 COMPILER=$CXX 34865 COMPILER_NAME=$COMPILER_NAME 34866 34867 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 34868 # cc -V output typically looks like 34869 # cc: Sun C 5.12 Linux_i386 2011/11/16 34870 COMPILER_VERSION_OUTPUT=`$COMPILER -V 2>&1` 34871 # Check that this is likely to be the Solaris Studio cc. 34872 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "^.*: Sun $COMPILER_NAME" > /dev/null 34873 if test $? -ne 0; then 34874 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 34875 { $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 34876 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 34877 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&5 34878 $as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 34879 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 34880 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 34881 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 34882 fi 34883 # Remove usage instructions (if present), and 34884 # collapse compiler output into a single line 34885 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34886 $SED -e 's/ *[Uu]sage:.*//'` 34887 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34888 $SED -e "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/"` 34889 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 34890 # xlc -qversion output typically looks like 34891 # IBM XL C/C++ for AIX, V11.1 (5724-X13) 34892 # Version: 11.01.0000.0015 34893 COMPILER_VERSION_OUTPUT=`$COMPILER -qversion 2>&1` 34894 # Check that this is likely to be the IBM XL C compiler. 34895 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "IBM XL C" > /dev/null 34896 if test $? -ne 0; then 34897 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 34898 { $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 34899 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 34900 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&5 34901 $as_echo "$as_me: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 34902 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 34903 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 34904 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 34905 fi 34906 # Collapse compiler output into a single line 34907 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 34908 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34909 $SED -e 's/^.*, V\([1-9][0-9.]*\).*$/\1/'` 34910 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 34911 # There is no specific version flag, but all output starts with a version string. 34912 # First line typically looks something like: 34913 # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86 34914 COMPILER_VERSION_OUTPUT=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'` 34915 # Check that this is likely to be Microsoft CL.EXE. 34916 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Microsoft.*Compiler" > /dev/null 34917 if test $? -ne 0; then 34918 { $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 34919 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 34920 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&5 34921 $as_echo "$as_me: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 34922 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 34923 fi 34924 # Collapse compiler output into a single line 34925 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 34926 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34927 $SED -e 's/^.*ersion.\([1-9][0-9.]*\) .*$/\1/'` 34928 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 34929 # gcc --version output typically looks like 34930 # gcc (Ubuntu/Linaro 4.8.1-10ubuntu9) 4.8.1 34931 # Copyright (C) 2013 Free Software Foundation, Inc. 34932 # This is free software; see the source for copying conditions. There is NO 34933 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 34934 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 34935 # Check that this is likely to be GCC. 34936 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Free Software Foundation" > /dev/null 34937 if test $? -ne 0; then 34938 { $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 34939 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 34940 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION\"" >&5 34941 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION\"" >&6;} 34942 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 34943 fi 34944 # Remove Copyright and legalese from version string, and 34945 # collapse into a single line 34946 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34947 $SED -e 's/ *Copyright .*//'` 34948 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34949 $SED -e 's/^.* \([1-9]\.[0-9.]*\)[^0-9.].*$/\1/'` 34950 elif test "x$TOOLCHAIN_TYPE" = xclang; then 34951 # clang --version output typically looks like 34952 # Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn) 34953 # clang version 3.3 (tags/RELEASE_33/final) 34954 # or 34955 # Debian clang version 3.2-7ubuntu1 (tags/RELEASE_32/final) (based on LLVM 3.2) 34956 # Target: x86_64-pc-linux-gnu 34957 # Thread model: posix 34958 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 34959 # Check that this is likely to be clang 34960 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "clang" > /dev/null 34961 if test $? -ne 0; then 34962 { $as_echo "$as_me:${as_lineno-$LINENO}: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&5 34963 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 34964 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&5 34965 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 34966 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 34967 fi 34968 # Collapse compiler output into a single line 34969 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 34970 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34971 $SED -e 's/^.* version \([1-9][0-9.]*\).*$/\1/'` 34972 else 34973 as_fn_error $? "Unknown toolchain type $TOOLCHAIN_TYPE." "$LINENO" 5 34974 fi 34975 # This sets CC_VERSION_NUMBER or CXX_VERSION_NUMBER. (This comment is a grep marker) 34976 CXX_VERSION_NUMBER="$COMPILER_VERSION_NUMBER" 34977 # This sets CC_VERSION_STRING or CXX_VERSION_STRING. (This comment is a grep marker) 34978 CXX_VERSION_STRING="$COMPILER_VERSION_STRING" 34979 34980 { $as_echo "$as_me:${as_lineno-$LINENO}: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&5 34981 $as_echo "$as_me: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&6;} 34982 34983 34984 # Now that we have resolved CXX ourself, let autoconf have its go at it 34985 ac_ext=cpp 34986 ac_cpp='$CXXCPP $CPPFLAGS' 34987 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 34988 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 34989 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 34990 if test -z "$CXX"; then 34991 if test -n "$CCC"; then 34992 CXX=$CCC 34993 else 34994 if test -n "$ac_tool_prefix"; then 34995 for ac_prog in $CXX 34996 do 34997 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 34998 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 34999 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 35000 $as_echo_n "checking for $ac_word... " >&6; } 35001 if ${ac_cv_prog_CXX+:} false; then : 35002 $as_echo_n "(cached) " >&6 35003 else 35004 if test -n "$CXX"; then 35005 ac_cv_prog_CXX="$CXX" # Let the user override the test. 35006 else 35007 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 35008 for as_dir in $PATH 35009 do 35010 IFS=$as_save_IFS 35011 test -z "$as_dir" && as_dir=. 35012 for ac_exec_ext in '' $ac_executable_extensions; do 35013 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 35014 ac_cv_prog_CXX="$ac_tool_prefix$ac_prog" 35015 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 35016 break 2 35017 fi 35018 done 35019 done 35020 IFS=$as_save_IFS 35021 35022 fi 35023 fi 35024 CXX=$ac_cv_prog_CXX 35025 if test -n "$CXX"; then 35026 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 35027 $as_echo "$CXX" >&6; } 35028 else 35029 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 35030 $as_echo "no" >&6; } 35031 fi 35032 35033 35034 test -n "$CXX" && break 35035 done 35036 fi 35037 if test -z "$CXX"; then 35038 ac_ct_CXX=$CXX 35039 for ac_prog in $CXX 35040 do 35041 # Extract the first word of "$ac_prog", so it can be a program name with args. 35042 set dummy $ac_prog; ac_word=$2 35043 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 35044 $as_echo_n "checking for $ac_word... " >&6; } 35045 if ${ac_cv_prog_ac_ct_CXX+:} false; then : 35046 $as_echo_n "(cached) " >&6 35047 else 35048 if test -n "$ac_ct_CXX"; then 35049 ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test. 35050 else 35051 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 35052 for as_dir in $PATH 35053 do 35054 IFS=$as_save_IFS 35055 test -z "$as_dir" && as_dir=. 35056 for ac_exec_ext in '' $ac_executable_extensions; do 35057 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 35058 ac_cv_prog_ac_ct_CXX="$ac_prog" 35059 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 35060 break 2 35061 fi 35062 done 35063 done 35064 IFS=$as_save_IFS 35065 35066 fi 35067 fi 35068 ac_ct_CXX=$ac_cv_prog_ac_ct_CXX 35069 if test -n "$ac_ct_CXX"; then 35070 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5 35071 $as_echo "$ac_ct_CXX" >&6; } 35072 else 35073 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 35074 $as_echo "no" >&6; } 35075 fi 35076 35077 35078 test -n "$ac_ct_CXX" && break 35079 done 35080 35081 if test "x$ac_ct_CXX" = x; then 35082 CXX="g++" 35083 else 35084 case $cross_compiling:$ac_tool_warned in 35085 yes:) 35086 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 35087 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 35088 ac_tool_warned=yes ;; 35089 esac 35090 CXX=$ac_ct_CXX 35091 fi 35092 fi 35093 35094 fi 35095 fi 35096 # Provide some information about the compiler. 35097 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5 35098 set X $ac_compile 35099 ac_compiler=$2 35100 for ac_option in --version -v -V -qversion; do 35101 { { ac_try="$ac_compiler $ac_option >&5" 35102 case "(($ac_try" in 35103 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 35104 *) ac_try_echo=$ac_try;; 35105 esac 35106 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 35107 $as_echo "$ac_try_echo"; } >&5 35108 (eval "$ac_compiler $ac_option >&5") 2>conftest.err 35109 ac_status=$? 35110 if test -s conftest.err; then 35111 sed '10a\ 35112 ... rest of stderr output deleted ... 35113 10q' conftest.err >conftest.er1 35114 cat conftest.er1 >&5 35115 fi 35116 rm -f conftest.er1 conftest.err 35117 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 35118 test $ac_status = 0; } 35119 done 35120 35121 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5 35122 $as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; } 35123 if ${ac_cv_cxx_compiler_gnu+:} false; then : 35124 $as_echo_n "(cached) " >&6 35125 else 35126 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35127 /* end confdefs.h. */ 35128 35129 int 35130 main () 35131 { 35132 #ifndef __GNUC__ 35133 choke me 35134 #endif 35135 35136 ; 35137 return 0; 35138 } 35139 _ACEOF 35140 if ac_fn_cxx_try_compile "$LINENO"; then : 35141 ac_compiler_gnu=yes 35142 else 35143 ac_compiler_gnu=no 35144 fi 35145 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 35146 ac_cv_cxx_compiler_gnu=$ac_compiler_gnu 35147 35148 fi 35149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5 35150 $as_echo "$ac_cv_cxx_compiler_gnu" >&6; } 35151 if test $ac_compiler_gnu = yes; then 35152 GXX=yes 35153 else 35154 GXX= 35155 fi 35156 ac_test_CXXFLAGS=${CXXFLAGS+set} 35157 ac_save_CXXFLAGS=$CXXFLAGS 35158 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5 35159 $as_echo_n "checking whether $CXX accepts -g... " >&6; } 35160 if ${ac_cv_prog_cxx_g+:} false; then : 35161 $as_echo_n "(cached) " >&6 35162 else 35163 ac_save_cxx_werror_flag=$ac_cxx_werror_flag 35164 ac_cxx_werror_flag=yes 35165 ac_cv_prog_cxx_g=no 35166 CXXFLAGS="-g" 35167 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35168 /* end confdefs.h. */ 35169 35170 int 35171 main () 35172 { 35173 35174 ; 35175 return 0; 35176 } 35177 _ACEOF 35178 if ac_fn_cxx_try_compile "$LINENO"; then : 35179 ac_cv_prog_cxx_g=yes 35180 else 35181 CXXFLAGS="" 35182 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35183 /* end confdefs.h. */ 35184 35185 int 35186 main () 35187 { 35188 35189 ; 35190 return 0; 35191 } 35192 _ACEOF 35193 if ac_fn_cxx_try_compile "$LINENO"; then : 35194 35195 else 35196 ac_cxx_werror_flag=$ac_save_cxx_werror_flag 35197 CXXFLAGS="-g" 35198 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35199 /* end confdefs.h. */ 35200 35201 int 35202 main () 35203 { 35204 35205 ; 35206 return 0; 35207 } 35208 _ACEOF 35209 if ac_fn_cxx_try_compile "$LINENO"; then : 35210 ac_cv_prog_cxx_g=yes 35211 fi 35212 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 35213 fi 35214 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 35215 fi 35216 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 35217 ac_cxx_werror_flag=$ac_save_cxx_werror_flag 35218 fi 35219 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5 35220 $as_echo "$ac_cv_prog_cxx_g" >&6; } 35221 if test "$ac_test_CXXFLAGS" = set; then 35222 CXXFLAGS=$ac_save_CXXFLAGS 35223 elif test $ac_cv_prog_cxx_g = yes; then 35224 if test "$GXX" = yes; then 35225 CXXFLAGS="-g -O2" 35226 else 35227 CXXFLAGS="-g" 35228 fi 35229 else 35230 if test "$GXX" = yes; then 35231 CXXFLAGS="-O2" 35232 else 35233 CXXFLAGS= 35234 fi 35235 fi 35236 ac_ext=cpp 35237 ac_cpp='$CXXCPP $CPPFLAGS' 35238 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 35239 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 35240 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 35241 35242 35243 # This is the compiler version number on the form X.Y[.Z] 35244 35245 35246 35247 35248 if test "x$CC_VERSION_NUMBER" != "x$CXX_VERSION_NUMBER"; then 35249 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: C and C++ compiler have different version numbers, $CC_VERSION_NUMBER vs $CXX_VERSION_NUMBER." >&5 35250 $as_echo "$as_me: WARNING: C and C++ compiler have different version numbers, $CC_VERSION_NUMBER vs $CXX_VERSION_NUMBER." >&2;} 35251 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This typically indicates a broken setup, and is not supported" >&5 35252 $as_echo "$as_me: WARNING: This typically indicates a broken setup, and is not supported" >&2;} 35253 fi 35254 35255 # We only check CC_VERSION_NUMBER since we assume CXX_VERSION_NUMBER is equal. 35256 if [[ "[$]CC_VERSION_NUMBER" =~ (.*\.){3} ]] ; then 35257 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: C compiler version number has more than three parts (X.Y.Z): $CC_VERSION_NUMBER. Comparisons might be wrong." >&5 35258 $as_echo "$as_me: WARNING: C compiler version number has more than three parts (X.Y.Z): $CC_VERSION_NUMBER. Comparisons might be wrong." >&2;} 35259 fi 35260 35261 if [[ "[$]CC_VERSION_NUMBER" =~ [0-9]{6} ]] ; then 35262 { $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 35263 $as_echo "$as_me: WARNING: C compiler version number has a part larger than 99999: $CC_VERSION_NUMBER. Comparisons might be wrong." >&2;} 35264 fi 35265 35266 COMPARABLE_ACTUAL_VERSION=`$AWK -F. '{ printf("%05d%05d%05d\n", $1, $2, $3) }' <<< "$CC_VERSION_NUMBER"` 35267 35268 35269 if test "x$TOOLCHAIN_MINIMUM_VERSION" != x; then 35270 35271 35272 35273 35274 35275 35276 35277 35278 35279 35280 35281 35282 35283 35284 35285 35286 35287 35288 35289 35290 35291 35292 35293 35294 35295 35296 35297 35298 35299 35300 35301 35302 35303 35304 35305 35306 35307 35308 35309 35310 35311 35312 35313 35314 35315 35316 35317 35318 35319 # Execute function body 35320 35321 # Need to assign to a variable since m4 is blocked from modifying parts in []. 35322 REFERENCE_VERSION=$TOOLCHAIN_MINIMUM_VERSION 35323 35324 if [[ "$REFERENCE_VERSION" =~ (.*\.){3} ]] ; then 35325 as_fn_error $? "Internal error: Cannot compare to $TOOLCHAIN_MINIMUM_VERSION, only three parts (X.Y.Z) is supported" "$LINENO" 5 35326 fi 35327 35328 if [[ "$REFERENCE_VERSION" =~ [0-9]{6} ]] ; then 35329 as_fn_error $? "Internal error: Cannot compare to $TOOLCHAIN_MINIMUM_VERSION, only parts < 99999 is supported" "$LINENO" 5 35330 fi 35331 35332 # Version comparison method inspired by http://stackoverflow.com/a/24067243 35333 COMPARABLE_REFERENCE_VERSION=`$AWK -F. '{ printf("%05d%05d%05d\n", $1, $2, $3) }' <<< "$REFERENCE_VERSION"` 35334 35335 if test $COMPARABLE_ACTUAL_VERSION -ge $COMPARABLE_REFERENCE_VERSION ; then 35336 : 35337 35338 else 35339 : 35340 35341 { $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 35342 $as_echo "$as_me: WARNING: You are using $TOOLCHAIN_TYPE older than $TOOLCHAIN_MINIMUM_VERSION. This is not a supported configuration." >&2;} 35343 35344 35345 fi 35346 35347 35348 35349 35350 35351 35352 35353 35354 35355 35356 35357 35358 35359 35360 fi 35361 35362 # 35363 # Setup the preprocessor (CPP and CXXCPP) 35364 # 35365 ac_ext=c 35366 ac_cpp='$CPP $CPPFLAGS' 35367 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 35368 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 35369 ac_compiler_gnu=$ac_cv_c_compiler_gnu 35370 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 35371 $as_echo_n "checking how to run the C preprocessor... " >&6; } 35372 # On Suns, sometimes $CPP names a directory. 35373 if test -n "$CPP" && test -d "$CPP"; then 35374 CPP= 35375 fi 35376 if test -z "$CPP"; then 35377 if ${ac_cv_prog_CPP+:} false; then : 35378 $as_echo_n "(cached) " >&6 35379 else 35380 # Double quotes because CPP needs to be expanded 35381 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" 35382 do 35383 ac_preproc_ok=false 35384 for ac_c_preproc_warn_flag in '' yes 35385 do 35386 # Use a header file that comes with gcc, so configuring glibc 35387 # with a fresh cross-compiler works. 35388 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 35389 # <limits.h> exists even on freestanding compilers. 35390 # On the NeXT, cc -E runs the code through the compiler's parser, 35391 # not just through cpp. "Syntax error" is here to catch this case. 35392 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35393 /* end confdefs.h. */ 35394 #ifdef __STDC__ 35395 # include <limits.h> 35396 #else 35397 # include <assert.h> 35398 #endif 35399 Syntax error 35400 _ACEOF 35401 if ac_fn_c_try_cpp "$LINENO"; then : 35402 35403 else 35404 # Broken: fails on valid input. 35405 continue 35406 fi 35407 rm -f conftest.err conftest.i conftest.$ac_ext 35408 35409 # OK, works on sane cases. Now check whether nonexistent headers 35410 # can be detected and how. 35411 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35412 /* end confdefs.h. */ 35413 #include <ac_nonexistent.h> 35414 _ACEOF 35415 if ac_fn_c_try_cpp "$LINENO"; then : 35416 # Broken: success on invalid input. 35417 continue 35418 else 35419 # Passes both tests. 35420 ac_preproc_ok=: 35421 break 35422 fi 35423 rm -f conftest.err conftest.i conftest.$ac_ext 35424 35425 done 35426 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 35427 rm -f conftest.i conftest.err conftest.$ac_ext 35428 if $ac_preproc_ok; then : 35429 break 35430 fi 35431 35432 done 35433 ac_cv_prog_CPP=$CPP 35434 35435 fi 35436 CPP=$ac_cv_prog_CPP 35437 else 35438 ac_cv_prog_CPP=$CPP 35439 fi 35440 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 35441 $as_echo "$CPP" >&6; } 35442 ac_preproc_ok=false 35443 for ac_c_preproc_warn_flag in '' yes 35444 do 35445 # Use a header file that comes with gcc, so configuring glibc 35446 # with a fresh cross-compiler works. 35447 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 35448 # <limits.h> exists even on freestanding compilers. 35449 # On the NeXT, cc -E runs the code through the compiler's parser, 35450 # not just through cpp. "Syntax error" is here to catch this case. 35451 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35452 /* end confdefs.h. */ 35453 #ifdef __STDC__ 35454 # include <limits.h> 35455 #else 35456 # include <assert.h> 35457 #endif 35458 Syntax error 35459 _ACEOF 35460 if ac_fn_c_try_cpp "$LINENO"; then : 35461 35462 else 35463 # Broken: fails on valid input. 35464 continue 35465 fi 35466 rm -f conftest.err conftest.i conftest.$ac_ext 35467 35468 # OK, works on sane cases. Now check whether nonexistent headers 35469 # can be detected and how. 35470 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35471 /* end confdefs.h. */ 35472 #include <ac_nonexistent.h> 35473 _ACEOF 35474 if ac_fn_c_try_cpp "$LINENO"; then : 35475 # Broken: success on invalid input. 35476 continue 35477 else 35478 # Passes both tests. 35479 ac_preproc_ok=: 35480 break 35481 fi 35482 rm -f conftest.err conftest.i conftest.$ac_ext 35483 35484 done 35485 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 35486 rm -f conftest.i conftest.err conftest.$ac_ext 35487 if $ac_preproc_ok; then : 35488 35489 else 35490 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 35491 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 35492 as_fn_error $? "C preprocessor \"$CPP\" fails sanity check 35493 See \`config.log' for more details" "$LINENO" 5; } 35494 fi 35495 35496 ac_ext=cpp 35497 ac_cpp='$CXXCPP $CPPFLAGS' 35498 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 35499 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 35500 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 35501 35502 35503 # Only process if variable expands to non-empty 35504 35505 if test "x$CPP" != x; then 35506 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35507 35508 # First separate the path from the arguments. This will split at the first 35509 # space. 35510 complete="$CPP" 35511 path="${complete%% *}" 35512 tmp="$complete EOL" 35513 arguments="${tmp#* }" 35514 35515 # Input might be given as Windows format, start by converting to 35516 # unix format. 35517 new_path=`$CYGPATH -u "$path"` 35518 35519 # Now try to locate executable using which 35520 new_path=`$WHICH "$new_path" 2> /dev/null` 35521 # bat and cmd files are not always considered executable in cygwin causing which 35522 # to not find them 35523 if test "x$new_path" = x \ 35524 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 35525 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 35526 new_path=`$CYGPATH -u "$path"` 35527 fi 35528 if test "x$new_path" = x; then 35529 # Oops. Which didn't find the executable. 35530 # The splitting of arguments from the executable at a space might have been incorrect, 35531 # since paths with space are more likely in Windows. Give it another try with the whole 35532 # argument. 35533 path="$complete" 35534 arguments="EOL" 35535 new_path=`$CYGPATH -u "$path"` 35536 new_path=`$WHICH "$new_path" 2> /dev/null` 35537 # bat and cmd files are not always considered executable in cygwin causing which 35538 # to not find them 35539 if test "x$new_path" = x \ 35540 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 35541 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 35542 new_path=`$CYGPATH -u "$path"` 35543 fi 35544 if test "x$new_path" = x; then 35545 # It's still not found. Now this is an unrecoverable error. 35546 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5 35547 $as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;} 35548 has_space=`$ECHO "$complete" | $GREP " "` 35549 if test "x$has_space" != x; then 35550 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 35551 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 35552 fi 35553 as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5 35554 fi 35555 fi 35556 35557 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 35558 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 35559 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 35560 # "foo.exe" is OK but "foo" is an error. 35561 # 35562 # This test is therefore slightly more accurate than "test -f" to check for file presence. 35563 # It is also a way to make sure we got the proper file name for the real test later on. 35564 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 35565 if test "x$test_shortpath" = x; then 35566 # Short path failed, file does not exist as specified. 35567 # Try adding .exe or .cmd 35568 if test -f "${new_path}.exe"; then 35569 input_to_shortpath="${new_path}.exe" 35570 elif test -f "${new_path}.cmd"; then 35571 input_to_shortpath="${new_path}.cmd" 35572 else 35573 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$new_path\", is invalid." >&5 35574 $as_echo "$as_me: The path of CPP, which resolves as \"$new_path\", is invalid." >&6;} 35575 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 35576 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 35577 as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5 35578 fi 35579 else 35580 input_to_shortpath="$new_path" 35581 fi 35582 35583 # Call helper function which possibly converts this using DOS-style short mode. 35584 # If so, the updated path is stored in $new_path. 35585 new_path="$input_to_shortpath" 35586 35587 input_path="$input_to_shortpath" 35588 # Check if we need to convert this using DOS-style short mode. If the path 35589 # contains just simple characters, use it. Otherwise (spaces, weird characters), 35590 # take no chances and rewrite it. 35591 # Note: m4 eats our [], so we need to use [ and ] instead. 35592 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 35593 if test "x$has_forbidden_chars" != x; then 35594 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 35595 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 35596 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 35597 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 35598 # Going to short mode and back again did indeed matter. Since short mode is 35599 # case insensitive, let's make it lowercase to improve readability. 35600 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 35601 # Now convert it back to Unix-style (cygpath) 35602 input_path=`$CYGPATH -u "$shortmode_path"` 35603 new_path="$input_path" 35604 fi 35605 fi 35606 35607 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 35608 if test "x$test_cygdrive_prefix" = x; then 35609 # As a simple fix, exclude /usr/bin since it's not a real path. 35610 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 35611 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 35612 # a path prefixed by /cygdrive for fixpath to work. 35613 new_path="$CYGWIN_ROOT_PATH$input_path" 35614 fi 35615 fi 35616 35617 # remove trailing .exe if any 35618 new_path="${new_path/%.exe/}" 35619 35620 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35621 35622 # First separate the path from the arguments. This will split at the first 35623 # space. 35624 complete="$CPP" 35625 path="${complete%% *}" 35626 tmp="$complete EOL" 35627 arguments="${tmp#* }" 35628 35629 # Input might be given as Windows format, start by converting to 35630 # unix format. 35631 new_path="$path" 35632 35633 windows_path="$new_path" 35634 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35635 unix_path=`$CYGPATH -u "$windows_path"` 35636 new_path="$unix_path" 35637 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35638 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 35639 new_path="$unix_path" 35640 fi 35641 35642 35643 # Now try to locate executable using which 35644 new_path=`$WHICH "$new_path" 2> /dev/null` 35645 35646 if test "x$new_path" = x; then 35647 # Oops. Which didn't find the executable. 35648 # The splitting of arguments from the executable at a space might have been incorrect, 35649 # since paths with space are more likely in Windows. Give it another try with the whole 35650 # argument. 35651 path="$complete" 35652 arguments="EOL" 35653 new_path="$path" 35654 35655 windows_path="$new_path" 35656 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35657 unix_path=`$CYGPATH -u "$windows_path"` 35658 new_path="$unix_path" 35659 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35660 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 35661 new_path="$unix_path" 35662 fi 35663 35664 35665 new_path=`$WHICH "$new_path" 2> /dev/null` 35666 # bat and cmd files are not always considered executable in MSYS causing which 35667 # to not find them 35668 if test "x$new_path" = x \ 35669 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 35670 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 35671 new_path="$path" 35672 35673 windows_path="$new_path" 35674 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35675 unix_path=`$CYGPATH -u "$windows_path"` 35676 new_path="$unix_path" 35677 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35678 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 35679 new_path="$unix_path" 35680 fi 35681 35682 fi 35683 35684 if test "x$new_path" = x; then 35685 # It's still not found. Now this is an unrecoverable error. 35686 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5 35687 $as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;} 35688 has_space=`$ECHO "$complete" | $GREP " "` 35689 if test "x$has_space" != x; then 35690 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 35691 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 35692 fi 35693 as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5 35694 fi 35695 fi 35696 35697 # Now new_path has a complete unix path to the binary 35698 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 35699 # Keep paths in /bin as-is, but remove trailing .exe if any 35700 new_path="${new_path/%.exe/}" 35701 # Do not save /bin paths to all_fixpath_prefixes! 35702 else 35703 # Not in mixed or Windows style, start by that. 35704 new_path=`cmd //c echo $new_path` 35705 35706 input_path="$new_path" 35707 # Check if we need to convert this using DOS-style short mode. If the path 35708 # contains just simple characters, use it. Otherwise (spaces, weird characters), 35709 # take no chances and rewrite it. 35710 # Note: m4 eats our [], so we need to use [ and ] instead. 35711 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 35712 if test "x$has_forbidden_chars" != x; then 35713 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 35714 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 35715 fi 35716 35717 # Output is in $new_path 35718 35719 windows_path="$new_path" 35720 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35721 unix_path=`$CYGPATH -u "$windows_path"` 35722 new_path="$unix_path" 35723 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35724 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 35725 new_path="$unix_path" 35726 fi 35727 35728 # remove trailing .exe if any 35729 new_path="${new_path/%.exe/}" 35730 35731 # Save the first 10 bytes of this path to the storage, so fixpath can work. 35732 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 35733 fi 35734 35735 else 35736 # We're on a unix platform. Hooray! :) 35737 # First separate the path from the arguments. This will split at the first 35738 # space. 35739 complete="$CPP" 35740 path="${complete%% *}" 35741 tmp="$complete EOL" 35742 arguments="${tmp#* }" 35743 35744 # Cannot rely on the command "which" here since it doesn't always work. 35745 is_absolute_path=`$ECHO "$path" | $GREP ^/` 35746 if test -z "$is_absolute_path"; then 35747 # Path to executable is not absolute. Find it. 35748 IFS_save="$IFS" 35749 IFS=: 35750 for p in $PATH; do 35751 if test -f "$p/$path" && test -x "$p/$path"; then 35752 new_path="$p/$path" 35753 break 35754 fi 35755 done 35756 IFS="$IFS_save" 35757 else 35758 # This is an absolute path, we can use it without further modifications. 35759 new_path="$path" 35760 fi 35761 35762 if test "x$new_path" = x; then 35763 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5 35764 $as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;} 35765 has_space=`$ECHO "$complete" | $GREP " "` 35766 if test "x$has_space" != x; then 35767 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 35768 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 35769 fi 35770 as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5 35771 fi 35772 fi 35773 35774 # Now join together the path and the arguments once again 35775 if test "x$arguments" != xEOL; then 35776 new_complete="$new_path ${arguments% *}" 35777 else 35778 new_complete="$new_path" 35779 fi 35780 35781 if test "x$complete" != "x$new_complete"; then 35782 CPP="$new_complete" 35783 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CPP to \"$new_complete\"" >&5 35784 $as_echo "$as_me: Rewriting CPP to \"$new_complete\"" >&6;} 35785 fi 35786 fi 35787 35788 ac_ext=cpp 35789 ac_cpp='$CXXCPP $CPPFLAGS' 35790 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 35791 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 35792 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 35793 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C++ preprocessor" >&5 35794 $as_echo_n "checking how to run the C++ preprocessor... " >&6; } 35795 if test -z "$CXXCPP"; then 35796 if ${ac_cv_prog_CXXCPP+:} false; then : 35797 $as_echo_n "(cached) " >&6 35798 else 35799 # Double quotes because CXXCPP needs to be expanded 35800 for CXXCPP in "$CXX -E" "/lib/cpp" 35801 do 35802 ac_preproc_ok=false 35803 for ac_cxx_preproc_warn_flag in '' yes 35804 do 35805 # Use a header file that comes with gcc, so configuring glibc 35806 # with a fresh cross-compiler works. 35807 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 35808 # <limits.h> exists even on freestanding compilers. 35809 # On the NeXT, cc -E runs the code through the compiler's parser, 35810 # not just through cpp. "Syntax error" is here to catch this case. 35811 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35812 /* end confdefs.h. */ 35813 #ifdef __STDC__ 35814 # include <limits.h> 35815 #else 35816 # include <assert.h> 35817 #endif 35818 Syntax error 35819 _ACEOF 35820 if ac_fn_cxx_try_cpp "$LINENO"; then : 35821 35822 else 35823 # Broken: fails on valid input. 35824 continue 35825 fi 35826 rm -f conftest.err conftest.i conftest.$ac_ext 35827 35828 # OK, works on sane cases. Now check whether nonexistent headers 35829 # can be detected and how. 35830 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35831 /* end confdefs.h. */ 35832 #include <ac_nonexistent.h> 35833 _ACEOF 35834 if ac_fn_cxx_try_cpp "$LINENO"; then : 35835 # Broken: success on invalid input. 35836 continue 35837 else 35838 # Passes both tests. 35839 ac_preproc_ok=: 35840 break 35841 fi 35842 rm -f conftest.err conftest.i conftest.$ac_ext 35843 35844 done 35845 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 35846 rm -f conftest.i conftest.err conftest.$ac_ext 35847 if $ac_preproc_ok; then : 35848 break 35849 fi 35850 35851 done 35852 ac_cv_prog_CXXCPP=$CXXCPP 35853 35854 fi 35855 CXXCPP=$ac_cv_prog_CXXCPP 35856 else 35857 ac_cv_prog_CXXCPP=$CXXCPP 35858 fi 35859 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXXCPP" >&5 35860 $as_echo "$CXXCPP" >&6; } 35861 ac_preproc_ok=false 35862 for ac_cxx_preproc_warn_flag in '' yes 35863 do 35864 # Use a header file that comes with gcc, so configuring glibc 35865 # with a fresh cross-compiler works. 35866 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 35867 # <limits.h> exists even on freestanding compilers. 35868 # On the NeXT, cc -E runs the code through the compiler's parser, 35869 # not just through cpp. "Syntax error" is here to catch this case. 35870 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35871 /* end confdefs.h. */ 35872 #ifdef __STDC__ 35873 # include <limits.h> 35874 #else 35875 # include <assert.h> 35876 #endif 35877 Syntax error 35878 _ACEOF 35879 if ac_fn_cxx_try_cpp "$LINENO"; then : 35880 35881 else 35882 # Broken: fails on valid input. 35883 continue 35884 fi 35885 rm -f conftest.err conftest.i conftest.$ac_ext 35886 35887 # OK, works on sane cases. Now check whether nonexistent headers 35888 # can be detected and how. 35889 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35890 /* end confdefs.h. */ 35891 #include <ac_nonexistent.h> 35892 _ACEOF 35893 if ac_fn_cxx_try_cpp "$LINENO"; then : 35894 # Broken: success on invalid input. 35895 continue 35896 else 35897 # Passes both tests. 35898 ac_preproc_ok=: 35899 break 35900 fi 35901 rm -f conftest.err conftest.i conftest.$ac_ext 35902 35903 done 35904 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 35905 rm -f conftest.i conftest.err conftest.$ac_ext 35906 if $ac_preproc_ok; then : 35907 35908 else 35909 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 35910 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 35911 as_fn_error $? "C++ preprocessor \"$CXXCPP\" fails sanity check 35912 See \`config.log' for more details" "$LINENO" 5; } 35913 fi 35914 35915 ac_ext=cpp 35916 ac_cpp='$CXXCPP $CPPFLAGS' 35917 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 35918 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 35919 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 35920 35921 35922 # Only process if variable expands to non-empty 35923 35924 if test "x$CXXCPP" != x; then 35925 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35926 35927 # First separate the path from the arguments. This will split at the first 35928 # space. 35929 complete="$CXXCPP" 35930 path="${complete%% *}" 35931 tmp="$complete EOL" 35932 arguments="${tmp#* }" 35933 35934 # Input might be given as Windows format, start by converting to 35935 # unix format. 35936 new_path=`$CYGPATH -u "$path"` 35937 35938 # Now try to locate executable using which 35939 new_path=`$WHICH "$new_path" 2> /dev/null` 35940 # bat and cmd files are not always considered executable in cygwin causing which 35941 # to not find them 35942 if test "x$new_path" = x \ 35943 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 35944 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 35945 new_path=`$CYGPATH -u "$path"` 35946 fi 35947 if test "x$new_path" = x; then 35948 # Oops. Which didn't find the executable. 35949 # The splitting of arguments from the executable at a space might have been incorrect, 35950 # since paths with space are more likely in Windows. Give it another try with the whole 35951 # argument. 35952 path="$complete" 35953 arguments="EOL" 35954 new_path=`$CYGPATH -u "$path"` 35955 new_path=`$WHICH "$new_path" 2> /dev/null` 35956 # bat and cmd files are not always considered executable in cygwin causing which 35957 # to not find them 35958 if test "x$new_path" = x \ 35959 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 35960 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 35961 new_path=`$CYGPATH -u "$path"` 35962 fi 35963 if test "x$new_path" = x; then 35964 # It's still not found. Now this is an unrecoverable error. 35965 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5 35966 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;} 35967 has_space=`$ECHO "$complete" | $GREP " "` 35968 if test "x$has_space" != x; then 35969 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 35970 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 35971 fi 35972 as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5 35973 fi 35974 fi 35975 35976 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 35977 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 35978 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 35979 # "foo.exe" is OK but "foo" is an error. 35980 # 35981 # This test is therefore slightly more accurate than "test -f" to check for file presence. 35982 # It is also a way to make sure we got the proper file name for the real test later on. 35983 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 35984 if test "x$test_shortpath" = x; then 35985 # Short path failed, file does not exist as specified. 35986 # Try adding .exe or .cmd 35987 if test -f "${new_path}.exe"; then 35988 input_to_shortpath="${new_path}.exe" 35989 elif test -f "${new_path}.cmd"; then 35990 input_to_shortpath="${new_path}.cmd" 35991 else 35992 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$new_path\", is invalid." >&5 35993 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$new_path\", is invalid." >&6;} 35994 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 35995 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 35996 as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5 35997 fi 35998 else 35999 input_to_shortpath="$new_path" 36000 fi 36001 36002 # Call helper function which possibly converts this using DOS-style short mode. 36003 # If so, the updated path is stored in $new_path. 36004 new_path="$input_to_shortpath" 36005 36006 input_path="$input_to_shortpath" 36007 # Check if we need to convert this using DOS-style short mode. If the path 36008 # contains just simple characters, use it. Otherwise (spaces, weird characters), 36009 # take no chances and rewrite it. 36010 # Note: m4 eats our [], so we need to use [ and ] instead. 36011 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 36012 if test "x$has_forbidden_chars" != x; then 36013 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 36014 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 36015 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 36016 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 36017 # Going to short mode and back again did indeed matter. Since short mode is 36018 # case insensitive, let's make it lowercase to improve readability. 36019 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 36020 # Now convert it back to Unix-style (cygpath) 36021 input_path=`$CYGPATH -u "$shortmode_path"` 36022 new_path="$input_path" 36023 fi 36024 fi 36025 36026 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 36027 if test "x$test_cygdrive_prefix" = x; then 36028 # As a simple fix, exclude /usr/bin since it's not a real path. 36029 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 36030 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 36031 # a path prefixed by /cygdrive for fixpath to work. 36032 new_path="$CYGWIN_ROOT_PATH$input_path" 36033 fi 36034 fi 36035 36036 # remove trailing .exe if any 36037 new_path="${new_path/%.exe/}" 36038 36039 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36040 36041 # First separate the path from the arguments. This will split at the first 36042 # space. 36043 complete="$CXXCPP" 36044 path="${complete%% *}" 36045 tmp="$complete EOL" 36046 arguments="${tmp#* }" 36047 36048 # Input might be given as Windows format, start by converting to 36049 # unix format. 36050 new_path="$path" 36051 36052 windows_path="$new_path" 36053 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36054 unix_path=`$CYGPATH -u "$windows_path"` 36055 new_path="$unix_path" 36056 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36057 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36058 new_path="$unix_path" 36059 fi 36060 36061 36062 # Now try to locate executable using which 36063 new_path=`$WHICH "$new_path" 2> /dev/null` 36064 36065 if test "x$new_path" = x; then 36066 # Oops. Which didn't find the executable. 36067 # The splitting of arguments from the executable at a space might have been incorrect, 36068 # since paths with space are more likely in Windows. Give it another try with the whole 36069 # argument. 36070 path="$complete" 36071 arguments="EOL" 36072 new_path="$path" 36073 36074 windows_path="$new_path" 36075 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36076 unix_path=`$CYGPATH -u "$windows_path"` 36077 new_path="$unix_path" 36078 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36079 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36080 new_path="$unix_path" 36081 fi 36082 36083 36084 new_path=`$WHICH "$new_path" 2> /dev/null` 36085 # bat and cmd files are not always considered executable in MSYS causing which 36086 # to not find them 36087 if test "x$new_path" = x \ 36088 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36089 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36090 new_path="$path" 36091 36092 windows_path="$new_path" 36093 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36094 unix_path=`$CYGPATH -u "$windows_path"` 36095 new_path="$unix_path" 36096 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36097 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36098 new_path="$unix_path" 36099 fi 36100 36101 fi 36102 36103 if test "x$new_path" = x; then 36104 # It's still not found. Now this is an unrecoverable error. 36105 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5 36106 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;} 36107 has_space=`$ECHO "$complete" | $GREP " "` 36108 if test "x$has_space" != x; then 36109 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 36110 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 36111 fi 36112 as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5 36113 fi 36114 fi 36115 36116 # Now new_path has a complete unix path to the binary 36117 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 36118 # Keep paths in /bin as-is, but remove trailing .exe if any 36119 new_path="${new_path/%.exe/}" 36120 # Do not save /bin paths to all_fixpath_prefixes! 36121 else 36122 # Not in mixed or Windows style, start by that. 36123 new_path=`cmd //c echo $new_path` 36124 36125 input_path="$new_path" 36126 # Check if we need to convert this using DOS-style short mode. If the path 36127 # contains just simple characters, use it. Otherwise (spaces, weird characters), 36128 # take no chances and rewrite it. 36129 # Note: m4 eats our [], so we need to use [ and ] instead. 36130 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 36131 if test "x$has_forbidden_chars" != x; then 36132 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 36133 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 36134 fi 36135 36136 # Output is in $new_path 36137 36138 windows_path="$new_path" 36139 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36140 unix_path=`$CYGPATH -u "$windows_path"` 36141 new_path="$unix_path" 36142 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36143 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36144 new_path="$unix_path" 36145 fi 36146 36147 # remove trailing .exe if any 36148 new_path="${new_path/%.exe/}" 36149 36150 # Save the first 10 bytes of this path to the storage, so fixpath can work. 36151 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 36152 fi 36153 36154 else 36155 # We're on a unix platform. Hooray! :) 36156 # First separate the path from the arguments. This will split at the first 36157 # space. 36158 complete="$CXXCPP" 36159 path="${complete%% *}" 36160 tmp="$complete EOL" 36161 arguments="${tmp#* }" 36162 36163 # Cannot rely on the command "which" here since it doesn't always work. 36164 is_absolute_path=`$ECHO "$path" | $GREP ^/` 36165 if test -z "$is_absolute_path"; then 36166 # Path to executable is not absolute. Find it. 36167 IFS_save="$IFS" 36168 IFS=: 36169 for p in $PATH; do 36170 if test -f "$p/$path" && test -x "$p/$path"; then 36171 new_path="$p/$path" 36172 break 36173 fi 36174 done 36175 IFS="$IFS_save" 36176 else 36177 # This is an absolute path, we can use it without further modifications. 36178 new_path="$path" 36179 fi 36180 36181 if test "x$new_path" = x; then 36182 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5 36183 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;} 36184 has_space=`$ECHO "$complete" | $GREP " "` 36185 if test "x$has_space" != x; then 36186 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 36187 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 36188 fi 36189 as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5 36190 fi 36191 fi 36192 36193 # Now join together the path and the arguments once again 36194 if test "x$arguments" != xEOL; then 36195 new_complete="$new_path ${arguments% *}" 36196 else 36197 new_complete="$new_path" 36198 fi 36199 36200 if test "x$complete" != "x$new_complete"; then 36201 CXXCPP="$new_complete" 36202 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CXXCPP to \"$new_complete\"" >&5 36203 $as_echo "$as_me: Rewriting CXXCPP to \"$new_complete\"" >&6;} 36204 fi 36205 fi 36206 36207 36208 # 36209 # Setup the linker (LD) 36210 # 36211 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 36212 # In the Microsoft toolchain we have a separate LD command "link". 36213 # Make sure we reject /usr/bin/link (as determined in CYGWIN_LINK), which is 36214 # a cygwin program for something completely different. 36215 # Extract the first word of "link", so it can be a program name with args. 36216 set dummy link; ac_word=$2 36217 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 36218 $as_echo_n "checking for $ac_word... " >&6; } 36219 if ${ac_cv_prog_LD+:} false; then : 36220 $as_echo_n "(cached) " >&6 36221 else 36222 if test -n "$LD"; then 36223 ac_cv_prog_LD="$LD" # Let the user override the test. 36224 else 36225 ac_prog_rejected=no 36226 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 36227 for as_dir in $PATH 36228 do 36229 IFS=$as_save_IFS 36230 test -z "$as_dir" && as_dir=. 36231 for ac_exec_ext in '' $ac_executable_extensions; do 36232 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 36233 if test "$as_dir/$ac_word$ac_exec_ext" = "$CYGWIN_LINK"; then 36234 ac_prog_rejected=yes 36235 continue 36236 fi 36237 ac_cv_prog_LD="link" 36238 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 36239 break 2 36240 fi 36241 done 36242 done 36243 IFS=$as_save_IFS 36244 36245 if test $ac_prog_rejected = yes; then 36246 # We found a bogon in the path, so make sure we never use it. 36247 set dummy $ac_cv_prog_LD 36248 shift 36249 if test $# != 0; then 36250 # We chose a different compiler from the bogus one. 36251 # However, it has the same basename, so the bogon will be chosen 36252 # first if we set LD to just the basename; use the full file name. 36253 shift 36254 ac_cv_prog_LD="$as_dir/$ac_word${1+' '}$@" 36255 fi 36256 fi 36257 fi 36258 fi 36259 LD=$ac_cv_prog_LD 36260 if test -n "$LD"; then 36261 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5 36262 $as_echo "$LD" >&6; } 36263 else 36264 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 36265 $as_echo "no" >&6; } 36266 fi 36267 36268 36269 36270 # Only process if variable expands to non-empty 36271 36272 if test "x$LD" != x; then 36273 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36274 36275 # First separate the path from the arguments. This will split at the first 36276 # space. 36277 complete="$LD" 36278 path="${complete%% *}" 36279 tmp="$complete EOL" 36280 arguments="${tmp#* }" 36281 36282 # Input might be given as Windows format, start by converting to 36283 # unix format. 36284 new_path=`$CYGPATH -u "$path"` 36285 36286 # Now try to locate executable using which 36287 new_path=`$WHICH "$new_path" 2> /dev/null` 36288 # bat and cmd files are not always considered executable in cygwin causing which 36289 # to not find them 36290 if test "x$new_path" = x \ 36291 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36292 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36293 new_path=`$CYGPATH -u "$path"` 36294 fi 36295 if test "x$new_path" = x; then 36296 # Oops. Which didn't find the executable. 36297 # The splitting of arguments from the executable at a space might have been incorrect, 36298 # since paths with space are more likely in Windows. Give it another try with the whole 36299 # argument. 36300 path="$complete" 36301 arguments="EOL" 36302 new_path=`$CYGPATH -u "$path"` 36303 new_path=`$WHICH "$new_path" 2> /dev/null` 36304 # bat and cmd files are not always considered executable in cygwin causing which 36305 # to not find them 36306 if test "x$new_path" = x \ 36307 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36308 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36309 new_path=`$CYGPATH -u "$path"` 36310 fi 36311 if test "x$new_path" = x; then 36312 # It's still not found. Now this is an unrecoverable error. 36313 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$complete\", is not found." >&5 36314 $as_echo "$as_me: The path of LD, which resolves as \"$complete\", is not found." >&6;} 36315 has_space=`$ECHO "$complete" | $GREP " "` 36316 if test "x$has_space" != x; then 36317 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 36318 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 36319 fi 36320 as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5 36321 fi 36322 fi 36323 36324 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 36325 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 36326 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 36327 # "foo.exe" is OK but "foo" is an error. 36328 # 36329 # This test is therefore slightly more accurate than "test -f" to check for file presence. 36330 # It is also a way to make sure we got the proper file name for the real test later on. 36331 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 36332 if test "x$test_shortpath" = x; then 36333 # Short path failed, file does not exist as specified. 36334 # Try adding .exe or .cmd 36335 if test -f "${new_path}.exe"; then 36336 input_to_shortpath="${new_path}.exe" 36337 elif test -f "${new_path}.cmd"; then 36338 input_to_shortpath="${new_path}.cmd" 36339 else 36340 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$new_path\", is invalid." >&5 36341 $as_echo "$as_me: The path of LD, which resolves as \"$new_path\", is invalid." >&6;} 36342 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 36343 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 36344 as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5 36345 fi 36346 else 36347 input_to_shortpath="$new_path" 36348 fi 36349 36350 # Call helper function which possibly converts this using DOS-style short mode. 36351 # If so, the updated path is stored in $new_path. 36352 new_path="$input_to_shortpath" 36353 36354 input_path="$input_to_shortpath" 36355 # Check if we need to convert this using DOS-style short mode. If the path 36356 # contains just simple characters, use it. Otherwise (spaces, weird characters), 36357 # take no chances and rewrite it. 36358 # Note: m4 eats our [], so we need to use [ and ] instead. 36359 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 36360 if test "x$has_forbidden_chars" != x; then 36361 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 36362 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 36363 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 36364 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 36365 # Going to short mode and back again did indeed matter. Since short mode is 36366 # case insensitive, let's make it lowercase to improve readability. 36367 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 36368 # Now convert it back to Unix-style (cygpath) 36369 input_path=`$CYGPATH -u "$shortmode_path"` 36370 new_path="$input_path" 36371 fi 36372 fi 36373 36374 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 36375 if test "x$test_cygdrive_prefix" = x; then 36376 # As a simple fix, exclude /usr/bin since it's not a real path. 36377 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 36378 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 36379 # a path prefixed by /cygdrive for fixpath to work. 36380 new_path="$CYGWIN_ROOT_PATH$input_path" 36381 fi 36382 fi 36383 36384 # remove trailing .exe if any 36385 new_path="${new_path/%.exe/}" 36386 36387 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36388 36389 # First separate the path from the arguments. This will split at the first 36390 # space. 36391 complete="$LD" 36392 path="${complete%% *}" 36393 tmp="$complete EOL" 36394 arguments="${tmp#* }" 36395 36396 # Input might be given as Windows format, start by converting to 36397 # unix format. 36398 new_path="$path" 36399 36400 windows_path="$new_path" 36401 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36402 unix_path=`$CYGPATH -u "$windows_path"` 36403 new_path="$unix_path" 36404 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36405 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36406 new_path="$unix_path" 36407 fi 36408 36409 36410 # Now try to locate executable using which 36411 new_path=`$WHICH "$new_path" 2> /dev/null` 36412 36413 if test "x$new_path" = x; then 36414 # Oops. Which didn't find the executable. 36415 # The splitting of arguments from the executable at a space might have been incorrect, 36416 # since paths with space are more likely in Windows. Give it another try with the whole 36417 # argument. 36418 path="$complete" 36419 arguments="EOL" 36420 new_path="$path" 36421 36422 windows_path="$new_path" 36423 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36424 unix_path=`$CYGPATH -u "$windows_path"` 36425 new_path="$unix_path" 36426 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36427 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36428 new_path="$unix_path" 36429 fi 36430 36431 36432 new_path=`$WHICH "$new_path" 2> /dev/null` 36433 # bat and cmd files are not always considered executable in MSYS causing which 36434 # to not find them 36435 if test "x$new_path" = x \ 36436 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36437 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36438 new_path="$path" 36439 36440 windows_path="$new_path" 36441 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36442 unix_path=`$CYGPATH -u "$windows_path"` 36443 new_path="$unix_path" 36444 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36445 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36446 new_path="$unix_path" 36447 fi 36448 36449 fi 36450 36451 if test "x$new_path" = x; then 36452 # It's still not found. Now this is an unrecoverable error. 36453 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$complete\", is not found." >&5 36454 $as_echo "$as_me: The path of LD, which resolves as \"$complete\", is not found." >&6;} 36455 has_space=`$ECHO "$complete" | $GREP " "` 36456 if test "x$has_space" != x; then 36457 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 36458 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 36459 fi 36460 as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5 36461 fi 36462 fi 36463 36464 # Now new_path has a complete unix path to the binary 36465 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 36466 # Keep paths in /bin as-is, but remove trailing .exe if any 36467 new_path="${new_path/%.exe/}" 36468 # Do not save /bin paths to all_fixpath_prefixes! 36469 else 36470 # Not in mixed or Windows style, start by that. 36471 new_path=`cmd //c echo $new_path` 36472 36473 input_path="$new_path" 36474 # Check if we need to convert this using DOS-style short mode. If the path 36475 # contains just simple characters, use it. Otherwise (spaces, weird characters), 36476 # take no chances and rewrite it. 36477 # Note: m4 eats our [], so we need to use [ and ] instead. 36478 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 36479 if test "x$has_forbidden_chars" != x; then 36480 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 36481 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 36482 fi 36483 36484 # Output is in $new_path 36485 36486 windows_path="$new_path" 36487 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36488 unix_path=`$CYGPATH -u "$windows_path"` 36489 new_path="$unix_path" 36490 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36491 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36492 new_path="$unix_path" 36493 fi 36494 36495 # remove trailing .exe if any 36496 new_path="${new_path/%.exe/}" 36497 36498 # Save the first 10 bytes of this path to the storage, so fixpath can work. 36499 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 36500 fi 36501 36502 else 36503 # We're on a unix platform. Hooray! :) 36504 # First separate the path from the arguments. This will split at the first 36505 # space. 36506 complete="$LD" 36507 path="${complete%% *}" 36508 tmp="$complete EOL" 36509 arguments="${tmp#* }" 36510 36511 # Cannot rely on the command "which" here since it doesn't always work. 36512 is_absolute_path=`$ECHO "$path" | $GREP ^/` 36513 if test -z "$is_absolute_path"; then 36514 # Path to executable is not absolute. Find it. 36515 IFS_save="$IFS" 36516 IFS=: 36517 for p in $PATH; do 36518 if test -f "$p/$path" && test -x "$p/$path"; then 36519 new_path="$p/$path" 36520 break 36521 fi 36522 done 36523 IFS="$IFS_save" 36524 else 36525 # This is an absolute path, we can use it without further modifications. 36526 new_path="$path" 36527 fi 36528 36529 if test "x$new_path" = x; then 36530 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$complete\", is not found." >&5 36531 $as_echo "$as_me: The path of LD, which resolves as \"$complete\", is not found." >&6;} 36532 has_space=`$ECHO "$complete" | $GREP " "` 36533 if test "x$has_space" != x; then 36534 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 36535 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 36536 fi 36537 as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5 36538 fi 36539 fi 36540 36541 # Now join together the path and the arguments once again 36542 if test "x$arguments" != xEOL; then 36543 new_complete="$new_path ${arguments% *}" 36544 else 36545 new_complete="$new_path" 36546 fi 36547 36548 if test "x$complete" != "x$new_complete"; then 36549 LD="$new_complete" 36550 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting LD to \"$new_complete\"" >&5 36551 $as_echo "$as_me: Rewriting LD to \"$new_complete\"" >&6;} 36552 fi 36553 fi 36554 36555 # Verify that we indeed succeeded with this trick. 36556 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the found link.exe is actually the Visual Studio linker" >&5 36557 $as_echo_n "checking if the found link.exe is actually the Visual Studio linker... " >&6; } 36558 "$LD" --version > /dev/null 36559 if test $? -eq 0 ; then 36560 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 36561 $as_echo "no" >&6; } 36562 as_fn_error $? "This is the Cygwin link tool. Please check your PATH and rerun configure." "$LINENO" 5 36563 else 36564 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 36565 $as_echo "yes" >&6; } 36566 fi 36567 LDCXX="$LD" 36568 else 36569 # All other toolchains use the compiler to link. 36570 LD="$CC" 36571 LDCXX="$CXX" 36572 fi 36573 36574 # FIXME: it should be CXXLD, according to standard (cf CXXCPP) 36575 36576 36577 # 36578 # Setup the assembler (AS) 36579 # 36580 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 36581 36582 36583 # Publish this variable in the help. 36584 36585 36586 if [ -z "${AS+x}" ]; then 36587 # The variable is not set by user, try to locate tool using the code snippet 36588 for ac_prog in as 36589 do 36590 # Extract the first word of "$ac_prog", so it can be a program name with args. 36591 set dummy $ac_prog; ac_word=$2 36592 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 36593 $as_echo_n "checking for $ac_word... " >&6; } 36594 if ${ac_cv_path_AS+:} false; then : 36595 $as_echo_n "(cached) " >&6 36596 else 36597 case $AS in 36598 [\\/]* | ?:[\\/]*) 36599 ac_cv_path_AS="$AS" # Let the user override the test with a path. 36600 ;; 36601 *) 36602 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 36603 for as_dir in $PATH 36604 do 36605 IFS=$as_save_IFS 36606 test -z "$as_dir" && as_dir=. 36607 for ac_exec_ext in '' $ac_executable_extensions; do 36608 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 36609 ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext" 36610 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 36611 break 2 36612 fi 36613 done 36614 done 36615 IFS=$as_save_IFS 36616 36617 ;; 36618 esac 36619 fi 36620 AS=$ac_cv_path_AS 36621 if test -n "$AS"; then 36622 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5 36623 $as_echo "$AS" >&6; } 36624 else 36625 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 36626 $as_echo "no" >&6; } 36627 fi 36628 36629 36630 test -n "$AS" && break 36631 done 36632 36633 else 36634 # The variable is set, but is it from the command line or the environment? 36635 36636 # Try to remove the string !AS! from our list. 36637 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AS!/} 36638 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 36639 # If it failed, the variable was not from the command line. Ignore it, 36640 # but warn the user (except for BASH, which is always set by the calling BASH). 36641 if test "xAS" != xBASH; then 36642 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AS from the environment. Use command line variables instead." >&5 36643 $as_echo "$as_me: WARNING: Ignoring value of AS from the environment. Use command line variables instead." >&2;} 36644 fi 36645 # Try to locate tool using the code snippet 36646 for ac_prog in as 36647 do 36648 # Extract the first word of "$ac_prog", so it can be a program name with args. 36649 set dummy $ac_prog; ac_word=$2 36650 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 36651 $as_echo_n "checking for $ac_word... " >&6; } 36652 if ${ac_cv_path_AS+:} false; then : 36653 $as_echo_n "(cached) " >&6 36654 else 36655 case $AS in 36656 [\\/]* | ?:[\\/]*) 36657 ac_cv_path_AS="$AS" # Let the user override the test with a path. 36658 ;; 36659 *) 36660 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 36661 for as_dir in $PATH 36662 do 36663 IFS=$as_save_IFS 36664 test -z "$as_dir" && as_dir=. 36665 for ac_exec_ext in '' $ac_executable_extensions; do 36666 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 36667 ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext" 36668 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 36669 break 2 36670 fi 36671 done 36672 done 36673 IFS=$as_save_IFS 36674 36675 ;; 36676 esac 36677 fi 36678 AS=$ac_cv_path_AS 36679 if test -n "$AS"; then 36680 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5 36681 $as_echo "$AS" >&6; } 36682 else 36683 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 36684 $as_echo "no" >&6; } 36685 fi 36686 36687 36688 test -n "$AS" && break 36689 done 36690 36691 else 36692 # If it succeeded, then it was overridden by the user. We will use it 36693 # for the tool. 36694 36695 # First remove it from the list of overridden variables, so we can test 36696 # for unknown variables in the end. 36697 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 36698 36699 # Check if we try to supply an empty value 36700 if test "x$AS" = x; then 36701 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool AS= (no value)" >&5 36702 $as_echo "$as_me: Setting user supplied tool AS= (no value)" >&6;} 36703 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AS" >&5 36704 $as_echo_n "checking for AS... " >&6; } 36705 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 36706 $as_echo "disabled" >&6; } 36707 else 36708 # Check if the provided tool contains a complete path. 36709 tool_specified="$AS" 36710 tool_basename="${tool_specified##*/}" 36711 if test "x$tool_basename" = "x$tool_specified"; then 36712 # A command without a complete path is provided, search $PATH. 36713 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AS=$tool_basename" >&5 36714 $as_echo "$as_me: Will search for user supplied tool AS=$tool_basename" >&6;} 36715 # Extract the first word of "$tool_basename", so it can be a program name with args. 36716 set dummy $tool_basename; ac_word=$2 36717 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 36718 $as_echo_n "checking for $ac_word... " >&6; } 36719 if ${ac_cv_path_AS+:} false; then : 36720 $as_echo_n "(cached) " >&6 36721 else 36722 case $AS in 36723 [\\/]* | ?:[\\/]*) 36724 ac_cv_path_AS="$AS" # Let the user override the test with a path. 36725 ;; 36726 *) 36727 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 36728 for as_dir in $PATH 36729 do 36730 IFS=$as_save_IFS 36731 test -z "$as_dir" && as_dir=. 36732 for ac_exec_ext in '' $ac_executable_extensions; do 36733 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 36734 ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext" 36735 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 36736 break 2 36737 fi 36738 done 36739 done 36740 IFS=$as_save_IFS 36741 36742 ;; 36743 esac 36744 fi 36745 AS=$ac_cv_path_AS 36746 if test -n "$AS"; then 36747 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5 36748 $as_echo "$AS" >&6; } 36749 else 36750 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 36751 $as_echo "no" >&6; } 36752 fi 36753 36754 36755 if test "x$AS" = x; then 36756 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 36757 fi 36758 else 36759 # Otherwise we believe it is a complete path. Use it as it is. 36760 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AS=$tool_specified" >&5 36761 $as_echo "$as_me: Will use user supplied tool AS=$tool_specified" >&6;} 36762 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AS" >&5 36763 $as_echo_n "checking for AS... " >&6; } 36764 if test ! -x "$tool_specified"; then 36765 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 36766 $as_echo "not found" >&6; } 36767 as_fn_error $? "User supplied tool AS=$tool_specified does not exist or is not executable" "$LINENO" 5 36768 fi 36769 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 36770 $as_echo "$tool_specified" >&6; } 36771 fi 36772 fi 36773 fi 36774 36775 fi 36776 36777 36778 36779 # Only process if variable expands to non-empty 36780 36781 if test "x$AS" != x; then 36782 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36783 36784 # First separate the path from the arguments. This will split at the first 36785 # space. 36786 complete="$AS" 36787 path="${complete%% *}" 36788 tmp="$complete EOL" 36789 arguments="${tmp#* }" 36790 36791 # Input might be given as Windows format, start by converting to 36792 # unix format. 36793 new_path=`$CYGPATH -u "$path"` 36794 36795 # Now try to locate executable using which 36796 new_path=`$WHICH "$new_path" 2> /dev/null` 36797 # bat and cmd files are not always considered executable in cygwin causing which 36798 # to not find them 36799 if test "x$new_path" = x \ 36800 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36801 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36802 new_path=`$CYGPATH -u "$path"` 36803 fi 36804 if test "x$new_path" = x; then 36805 # Oops. Which didn't find the executable. 36806 # The splitting of arguments from the executable at a space might have been incorrect, 36807 # since paths with space are more likely in Windows. Give it another try with the whole 36808 # argument. 36809 path="$complete" 36810 arguments="EOL" 36811 new_path=`$CYGPATH -u "$path"` 36812 new_path=`$WHICH "$new_path" 2> /dev/null` 36813 # bat and cmd files are not always considered executable in cygwin causing which 36814 # to not find them 36815 if test "x$new_path" = x \ 36816 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36817 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36818 new_path=`$CYGPATH -u "$path"` 36819 fi 36820 if test "x$new_path" = x; then 36821 # It's still not found. Now this is an unrecoverable error. 36822 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5 36823 $as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;} 36824 has_space=`$ECHO "$complete" | $GREP " "` 36825 if test "x$has_space" != x; then 36826 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 36827 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 36828 fi 36829 as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5 36830 fi 36831 fi 36832 36833 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 36834 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 36835 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 36836 # "foo.exe" is OK but "foo" is an error. 36837 # 36838 # This test is therefore slightly more accurate than "test -f" to check for file presence. 36839 # It is also a way to make sure we got the proper file name for the real test later on. 36840 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 36841 if test "x$test_shortpath" = x; then 36842 # Short path failed, file does not exist as specified. 36843 # Try adding .exe or .cmd 36844 if test -f "${new_path}.exe"; then 36845 input_to_shortpath="${new_path}.exe" 36846 elif test -f "${new_path}.cmd"; then 36847 input_to_shortpath="${new_path}.cmd" 36848 else 36849 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$new_path\", is invalid." >&5 36850 $as_echo "$as_me: The path of AS, which resolves as \"$new_path\", is invalid." >&6;} 36851 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 36852 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 36853 as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5 36854 fi 36855 else 36856 input_to_shortpath="$new_path" 36857 fi 36858 36859 # Call helper function which possibly converts this using DOS-style short mode. 36860 # If so, the updated path is stored in $new_path. 36861 new_path="$input_to_shortpath" 36862 36863 input_path="$input_to_shortpath" 36864 # Check if we need to convert this using DOS-style short mode. If the path 36865 # contains just simple characters, use it. Otherwise (spaces, weird characters), 36866 # take no chances and rewrite it. 36867 # Note: m4 eats our [], so we need to use [ and ] instead. 36868 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 36869 if test "x$has_forbidden_chars" != x; then 36870 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 36871 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 36872 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 36873 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 36874 # Going to short mode and back again did indeed matter. Since short mode is 36875 # case insensitive, let's make it lowercase to improve readability. 36876 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 36877 # Now convert it back to Unix-style (cygpath) 36878 input_path=`$CYGPATH -u "$shortmode_path"` 36879 new_path="$input_path" 36880 fi 36881 fi 36882 36883 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 36884 if test "x$test_cygdrive_prefix" = x; then 36885 # As a simple fix, exclude /usr/bin since it's not a real path. 36886 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 36887 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 36888 # a path prefixed by /cygdrive for fixpath to work. 36889 new_path="$CYGWIN_ROOT_PATH$input_path" 36890 fi 36891 fi 36892 36893 # remove trailing .exe if any 36894 new_path="${new_path/%.exe/}" 36895 36896 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36897 36898 # First separate the path from the arguments. This will split at the first 36899 # space. 36900 complete="$AS" 36901 path="${complete%% *}" 36902 tmp="$complete EOL" 36903 arguments="${tmp#* }" 36904 36905 # Input might be given as Windows format, start by converting to 36906 # unix format. 36907 new_path="$path" 36908 36909 windows_path="$new_path" 36910 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36911 unix_path=`$CYGPATH -u "$windows_path"` 36912 new_path="$unix_path" 36913 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36914 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36915 new_path="$unix_path" 36916 fi 36917 36918 36919 # Now try to locate executable using which 36920 new_path=`$WHICH "$new_path" 2> /dev/null` 36921 36922 if test "x$new_path" = x; then 36923 # Oops. Which didn't find the executable. 36924 # The splitting of arguments from the executable at a space might have been incorrect, 36925 # since paths with space are more likely in Windows. Give it another try with the whole 36926 # argument. 36927 path="$complete" 36928 arguments="EOL" 36929 new_path="$path" 36930 36931 windows_path="$new_path" 36932 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36933 unix_path=`$CYGPATH -u "$windows_path"` 36934 new_path="$unix_path" 36935 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36936 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36937 new_path="$unix_path" 36938 fi 36939 36940 36941 new_path=`$WHICH "$new_path" 2> /dev/null` 36942 # bat and cmd files are not always considered executable in MSYS causing which 36943 # to not find them 36944 if test "x$new_path" = x \ 36945 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36946 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36947 new_path="$path" 36948 36949 windows_path="$new_path" 36950 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36951 unix_path=`$CYGPATH -u "$windows_path"` 36952 new_path="$unix_path" 36953 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36954 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36955 new_path="$unix_path" 36956 fi 36957 36958 fi 36959 36960 if test "x$new_path" = x; then 36961 # It's still not found. Now this is an unrecoverable error. 36962 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5 36963 $as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;} 36964 has_space=`$ECHO "$complete" | $GREP " "` 36965 if test "x$has_space" != x; then 36966 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 36967 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 36968 fi 36969 as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5 36970 fi 36971 fi 36972 36973 # Now new_path has a complete unix path to the binary 36974 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 36975 # Keep paths in /bin as-is, but remove trailing .exe if any 36976 new_path="${new_path/%.exe/}" 36977 # Do not save /bin paths to all_fixpath_prefixes! 36978 else 36979 # Not in mixed or Windows style, start by that. 36980 new_path=`cmd //c echo $new_path` 36981 36982 input_path="$new_path" 36983 # Check if we need to convert this using DOS-style short mode. If the path 36984 # contains just simple characters, use it. Otherwise (spaces, weird characters), 36985 # take no chances and rewrite it. 36986 # Note: m4 eats our [], so we need to use [ and ] instead. 36987 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 36988 if test "x$has_forbidden_chars" != x; then 36989 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 36990 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 36991 fi 36992 36993 # Output is in $new_path 36994 36995 windows_path="$new_path" 36996 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36997 unix_path=`$CYGPATH -u "$windows_path"` 36998 new_path="$unix_path" 36999 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37000 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37001 new_path="$unix_path" 37002 fi 37003 37004 # remove trailing .exe if any 37005 new_path="${new_path/%.exe/}" 37006 37007 # Save the first 10 bytes of this path to the storage, so fixpath can work. 37008 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 37009 fi 37010 37011 else 37012 # We're on a unix platform. Hooray! :) 37013 # First separate the path from the arguments. This will split at the first 37014 # space. 37015 complete="$AS" 37016 path="${complete%% *}" 37017 tmp="$complete EOL" 37018 arguments="${tmp#* }" 37019 37020 # Cannot rely on the command "which" here since it doesn't always work. 37021 is_absolute_path=`$ECHO "$path" | $GREP ^/` 37022 if test -z "$is_absolute_path"; then 37023 # Path to executable is not absolute. Find it. 37024 IFS_save="$IFS" 37025 IFS=: 37026 for p in $PATH; do 37027 if test -f "$p/$path" && test -x "$p/$path"; then 37028 new_path="$p/$path" 37029 break 37030 fi 37031 done 37032 IFS="$IFS_save" 37033 else 37034 # This is an absolute path, we can use it without further modifications. 37035 new_path="$path" 37036 fi 37037 37038 if test "x$new_path" = x; then 37039 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5 37040 $as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;} 37041 has_space=`$ECHO "$complete" | $GREP " "` 37042 if test "x$has_space" != x; then 37043 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 37044 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 37045 fi 37046 as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5 37047 fi 37048 fi 37049 37050 # Now join together the path and the arguments once again 37051 if test "x$arguments" != xEOL; then 37052 new_complete="$new_path ${arguments% *}" 37053 else 37054 new_complete="$new_path" 37055 fi 37056 37057 if test "x$complete" != "x$new_complete"; then 37058 AS="$new_complete" 37059 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting AS to \"$new_complete\"" >&5 37060 $as_echo "$as_me: Rewriting AS to \"$new_complete\"" >&6;} 37061 fi 37062 fi 37063 37064 if test "x$AS" = x; then 37065 as_fn_error $? "Solaris assembler (as) is required. Please install via \"pkg install pkg:/developer/assembler\"." "$LINENO" 5 37066 fi 37067 else 37068 # FIXME: is this correct for microsoft? 37069 AS="$CC -c" 37070 fi 37071 37072 37073 # 37074 # Setup the archiver (AR) 37075 # 37076 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 37077 # The corresponding ar tool is lib.exe (used to create static libraries) 37078 # Extract the first word of "lib", so it can be a program name with args. 37079 set dummy lib; ac_word=$2 37080 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37081 $as_echo_n "checking for $ac_word... " >&6; } 37082 if ${ac_cv_prog_AR+:} false; then : 37083 $as_echo_n "(cached) " >&6 37084 else 37085 if test -n "$AR"; then 37086 ac_cv_prog_AR="$AR" # Let the user override the test. 37087 else 37088 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37089 for as_dir in $PATH 37090 do 37091 IFS=$as_save_IFS 37092 test -z "$as_dir" && as_dir=. 37093 for ac_exec_ext in '' $ac_executable_extensions; do 37094 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37095 ac_cv_prog_AR="lib" 37096 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37097 break 2 37098 fi 37099 done 37100 done 37101 IFS=$as_save_IFS 37102 37103 fi 37104 fi 37105 AR=$ac_cv_prog_AR 37106 if test -n "$AR"; then 37107 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 37108 $as_echo "$AR" >&6; } 37109 else 37110 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37111 $as_echo "no" >&6; } 37112 fi 37113 37114 37115 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 37116 37117 37118 # Publish this variable in the help. 37119 37120 37121 if [ -z "${AR+x}" ]; then 37122 # The variable is not set by user, try to locate tool using the code snippet 37123 if test -n "$ac_tool_prefix"; then 37124 for ac_prog in ar gcc-ar 37125 do 37126 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 37127 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 37128 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37129 $as_echo_n "checking for $ac_word... " >&6; } 37130 if ${ac_cv_prog_AR+:} false; then : 37131 $as_echo_n "(cached) " >&6 37132 else 37133 if test -n "$AR"; then 37134 ac_cv_prog_AR="$AR" # Let the user override the test. 37135 else 37136 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37137 for as_dir in $PATH 37138 do 37139 IFS=$as_save_IFS 37140 test -z "$as_dir" && as_dir=. 37141 for ac_exec_ext in '' $ac_executable_extensions; do 37142 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37143 ac_cv_prog_AR="$ac_tool_prefix$ac_prog" 37144 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37145 break 2 37146 fi 37147 done 37148 done 37149 IFS=$as_save_IFS 37150 37151 fi 37152 fi 37153 AR=$ac_cv_prog_AR 37154 if test -n "$AR"; then 37155 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 37156 $as_echo "$AR" >&6; } 37157 else 37158 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37159 $as_echo "no" >&6; } 37160 fi 37161 37162 37163 test -n "$AR" && break 37164 done 37165 fi 37166 if test -z "$AR"; then 37167 ac_ct_AR=$AR 37168 for ac_prog in ar gcc-ar 37169 do 37170 # Extract the first word of "$ac_prog", so it can be a program name with args. 37171 set dummy $ac_prog; ac_word=$2 37172 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37173 $as_echo_n "checking for $ac_word... " >&6; } 37174 if ${ac_cv_prog_ac_ct_AR+:} false; then : 37175 $as_echo_n "(cached) " >&6 37176 else 37177 if test -n "$ac_ct_AR"; then 37178 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. 37179 else 37180 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37181 for as_dir in $PATH 37182 do 37183 IFS=$as_save_IFS 37184 test -z "$as_dir" && as_dir=. 37185 for ac_exec_ext in '' $ac_executable_extensions; do 37186 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37187 ac_cv_prog_ac_ct_AR="$ac_prog" 37188 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37189 break 2 37190 fi 37191 done 37192 done 37193 IFS=$as_save_IFS 37194 37195 fi 37196 fi 37197 ac_ct_AR=$ac_cv_prog_ac_ct_AR 37198 if test -n "$ac_ct_AR"; then 37199 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 37200 $as_echo "$ac_ct_AR" >&6; } 37201 else 37202 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37203 $as_echo "no" >&6; } 37204 fi 37205 37206 37207 test -n "$ac_ct_AR" && break 37208 done 37209 37210 if test "x$ac_ct_AR" = x; then 37211 AR="" 37212 else 37213 case $cross_compiling:$ac_tool_warned in 37214 yes:) 37215 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 37216 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 37217 ac_tool_warned=yes ;; 37218 esac 37219 AR=$ac_ct_AR 37220 fi 37221 fi 37222 37223 else 37224 # The variable is set, but is it from the command line or the environment? 37225 37226 # Try to remove the string !AR! from our list. 37227 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AR!/} 37228 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 37229 # If it failed, the variable was not from the command line. Ignore it, 37230 # but warn the user (except for BASH, which is always set by the calling BASH). 37231 if test "xAR" != xBASH; then 37232 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&5 37233 $as_echo "$as_me: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&2;} 37234 fi 37235 # Try to locate tool using the code snippet 37236 if test -n "$ac_tool_prefix"; then 37237 for ac_prog in ar gcc-ar 37238 do 37239 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 37240 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 37241 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37242 $as_echo_n "checking for $ac_word... " >&6; } 37243 if ${ac_cv_prog_AR+:} false; then : 37244 $as_echo_n "(cached) " >&6 37245 else 37246 if test -n "$AR"; then 37247 ac_cv_prog_AR="$AR" # Let the user override the test. 37248 else 37249 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37250 for as_dir in $PATH 37251 do 37252 IFS=$as_save_IFS 37253 test -z "$as_dir" && as_dir=. 37254 for ac_exec_ext in '' $ac_executable_extensions; do 37255 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37256 ac_cv_prog_AR="$ac_tool_prefix$ac_prog" 37257 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37258 break 2 37259 fi 37260 done 37261 done 37262 IFS=$as_save_IFS 37263 37264 fi 37265 fi 37266 AR=$ac_cv_prog_AR 37267 if test -n "$AR"; then 37268 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 37269 $as_echo "$AR" >&6; } 37270 else 37271 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37272 $as_echo "no" >&6; } 37273 fi 37274 37275 37276 test -n "$AR" && break 37277 done 37278 fi 37279 if test -z "$AR"; then 37280 ac_ct_AR=$AR 37281 for ac_prog in ar gcc-ar 37282 do 37283 # Extract the first word of "$ac_prog", so it can be a program name with args. 37284 set dummy $ac_prog; ac_word=$2 37285 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37286 $as_echo_n "checking for $ac_word... " >&6; } 37287 if ${ac_cv_prog_ac_ct_AR+:} false; then : 37288 $as_echo_n "(cached) " >&6 37289 else 37290 if test -n "$ac_ct_AR"; then 37291 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. 37292 else 37293 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37294 for as_dir in $PATH 37295 do 37296 IFS=$as_save_IFS 37297 test -z "$as_dir" && as_dir=. 37298 for ac_exec_ext in '' $ac_executable_extensions; do 37299 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37300 ac_cv_prog_ac_ct_AR="$ac_prog" 37301 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37302 break 2 37303 fi 37304 done 37305 done 37306 IFS=$as_save_IFS 37307 37308 fi 37309 fi 37310 ac_ct_AR=$ac_cv_prog_ac_ct_AR 37311 if test -n "$ac_ct_AR"; then 37312 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 37313 $as_echo "$ac_ct_AR" >&6; } 37314 else 37315 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37316 $as_echo "no" >&6; } 37317 fi 37318 37319 37320 test -n "$ac_ct_AR" && break 37321 done 37322 37323 if test "x$ac_ct_AR" = x; then 37324 AR="" 37325 else 37326 case $cross_compiling:$ac_tool_warned in 37327 yes:) 37328 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 37329 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 37330 ac_tool_warned=yes ;; 37331 esac 37332 AR=$ac_ct_AR 37333 fi 37334 fi 37335 37336 else 37337 # If it succeeded, then it was overridden by the user. We will use it 37338 # for the tool. 37339 37340 # First remove it from the list of overridden variables, so we can test 37341 # for unknown variables in the end. 37342 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 37343 37344 # Check if we try to supply an empty value 37345 if test "x$AR" = x; then 37346 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool AR= (no value)" >&5 37347 $as_echo "$as_me: Setting user supplied tool AR= (no value)" >&6;} 37348 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AR" >&5 37349 $as_echo_n "checking for AR... " >&6; } 37350 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 37351 $as_echo "disabled" >&6; } 37352 else 37353 # Check if the provided tool contains a complete path. 37354 tool_specified="$AR" 37355 tool_basename="${tool_specified##*/}" 37356 if test "x$tool_basename" = "x$tool_specified"; then 37357 # A command without a complete path is provided, search $PATH. 37358 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AR=$tool_basename" >&5 37359 $as_echo "$as_me: Will search for user supplied tool AR=$tool_basename" >&6;} 37360 # Extract the first word of "$tool_basename", so it can be a program name with args. 37361 set dummy $tool_basename; ac_word=$2 37362 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37363 $as_echo_n "checking for $ac_word... " >&6; } 37364 if ${ac_cv_path_AR+:} false; then : 37365 $as_echo_n "(cached) " >&6 37366 else 37367 case $AR in 37368 [\\/]* | ?:[\\/]*) 37369 ac_cv_path_AR="$AR" # Let the user override the test with a path. 37370 ;; 37371 *) 37372 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37373 for as_dir in $PATH 37374 do 37375 IFS=$as_save_IFS 37376 test -z "$as_dir" && as_dir=. 37377 for ac_exec_ext in '' $ac_executable_extensions; do 37378 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37379 ac_cv_path_AR="$as_dir/$ac_word$ac_exec_ext" 37380 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37381 break 2 37382 fi 37383 done 37384 done 37385 IFS=$as_save_IFS 37386 37387 ;; 37388 esac 37389 fi 37390 AR=$ac_cv_path_AR 37391 if test -n "$AR"; then 37392 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 37393 $as_echo "$AR" >&6; } 37394 else 37395 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37396 $as_echo "no" >&6; } 37397 fi 37398 37399 37400 if test "x$AR" = x; then 37401 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 37402 fi 37403 else 37404 # Otherwise we believe it is a complete path. Use it as it is. 37405 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AR=$tool_specified" >&5 37406 $as_echo "$as_me: Will use user supplied tool AR=$tool_specified" >&6;} 37407 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AR" >&5 37408 $as_echo_n "checking for AR... " >&6; } 37409 if test ! -x "$tool_specified"; then 37410 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 37411 $as_echo "not found" >&6; } 37412 as_fn_error $? "User supplied tool AR=$tool_specified does not exist or is not executable" "$LINENO" 5 37413 fi 37414 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 37415 $as_echo "$tool_specified" >&6; } 37416 fi 37417 fi 37418 fi 37419 37420 fi 37421 37422 37423 else 37424 37425 37426 # Publish this variable in the help. 37427 37428 37429 if [ -z "${AR+x}" ]; then 37430 # The variable is not set by user, try to locate tool using the code snippet 37431 if test -n "$ac_tool_prefix"; then 37432 for ac_prog in ar 37433 do 37434 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 37435 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 37436 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37437 $as_echo_n "checking for $ac_word... " >&6; } 37438 if ${ac_cv_prog_AR+:} false; then : 37439 $as_echo_n "(cached) " >&6 37440 else 37441 if test -n "$AR"; then 37442 ac_cv_prog_AR="$AR" # Let the user override the test. 37443 else 37444 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37445 for as_dir in $PATH 37446 do 37447 IFS=$as_save_IFS 37448 test -z "$as_dir" && as_dir=. 37449 for ac_exec_ext in '' $ac_executable_extensions; do 37450 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37451 ac_cv_prog_AR="$ac_tool_prefix$ac_prog" 37452 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37453 break 2 37454 fi 37455 done 37456 done 37457 IFS=$as_save_IFS 37458 37459 fi 37460 fi 37461 AR=$ac_cv_prog_AR 37462 if test -n "$AR"; then 37463 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 37464 $as_echo "$AR" >&6; } 37465 else 37466 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37467 $as_echo "no" >&6; } 37468 fi 37469 37470 37471 test -n "$AR" && break 37472 done 37473 fi 37474 if test -z "$AR"; then 37475 ac_ct_AR=$AR 37476 for ac_prog in ar 37477 do 37478 # Extract the first word of "$ac_prog", so it can be a program name with args. 37479 set dummy $ac_prog; ac_word=$2 37480 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37481 $as_echo_n "checking for $ac_word... " >&6; } 37482 if ${ac_cv_prog_ac_ct_AR+:} false; then : 37483 $as_echo_n "(cached) " >&6 37484 else 37485 if test -n "$ac_ct_AR"; then 37486 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. 37487 else 37488 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37489 for as_dir in $PATH 37490 do 37491 IFS=$as_save_IFS 37492 test -z "$as_dir" && as_dir=. 37493 for ac_exec_ext in '' $ac_executable_extensions; do 37494 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37495 ac_cv_prog_ac_ct_AR="$ac_prog" 37496 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37497 break 2 37498 fi 37499 done 37500 done 37501 IFS=$as_save_IFS 37502 37503 fi 37504 fi 37505 ac_ct_AR=$ac_cv_prog_ac_ct_AR 37506 if test -n "$ac_ct_AR"; then 37507 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 37508 $as_echo "$ac_ct_AR" >&6; } 37509 else 37510 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37511 $as_echo "no" >&6; } 37512 fi 37513 37514 37515 test -n "$ac_ct_AR" && break 37516 done 37517 37518 if test "x$ac_ct_AR" = x; then 37519 AR="" 37520 else 37521 case $cross_compiling:$ac_tool_warned in 37522 yes:) 37523 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 37524 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 37525 ac_tool_warned=yes ;; 37526 esac 37527 AR=$ac_ct_AR 37528 fi 37529 fi 37530 37531 else 37532 # The variable is set, but is it from the command line or the environment? 37533 37534 # Try to remove the string !AR! from our list. 37535 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AR!/} 37536 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 37537 # If it failed, the variable was not from the command line. Ignore it, 37538 # but warn the user (except for BASH, which is always set by the calling BASH). 37539 if test "xAR" != xBASH; then 37540 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&5 37541 $as_echo "$as_me: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&2;} 37542 fi 37543 # Try to locate tool using the code snippet 37544 if test -n "$ac_tool_prefix"; then 37545 for ac_prog in ar 37546 do 37547 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 37548 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 37549 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37550 $as_echo_n "checking for $ac_word... " >&6; } 37551 if ${ac_cv_prog_AR+:} false; then : 37552 $as_echo_n "(cached) " >&6 37553 else 37554 if test -n "$AR"; then 37555 ac_cv_prog_AR="$AR" # Let the user override the test. 37556 else 37557 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37558 for as_dir in $PATH 37559 do 37560 IFS=$as_save_IFS 37561 test -z "$as_dir" && as_dir=. 37562 for ac_exec_ext in '' $ac_executable_extensions; do 37563 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37564 ac_cv_prog_AR="$ac_tool_prefix$ac_prog" 37565 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37566 break 2 37567 fi 37568 done 37569 done 37570 IFS=$as_save_IFS 37571 37572 fi 37573 fi 37574 AR=$ac_cv_prog_AR 37575 if test -n "$AR"; then 37576 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 37577 $as_echo "$AR" >&6; } 37578 else 37579 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37580 $as_echo "no" >&6; } 37581 fi 37582 37583 37584 test -n "$AR" && break 37585 done 37586 fi 37587 if test -z "$AR"; then 37588 ac_ct_AR=$AR 37589 for ac_prog in ar 37590 do 37591 # Extract the first word of "$ac_prog", so it can be a program name with args. 37592 set dummy $ac_prog; ac_word=$2 37593 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37594 $as_echo_n "checking for $ac_word... " >&6; } 37595 if ${ac_cv_prog_ac_ct_AR+:} false; then : 37596 $as_echo_n "(cached) " >&6 37597 else 37598 if test -n "$ac_ct_AR"; then 37599 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. 37600 else 37601 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37602 for as_dir in $PATH 37603 do 37604 IFS=$as_save_IFS 37605 test -z "$as_dir" && as_dir=. 37606 for ac_exec_ext in '' $ac_executable_extensions; do 37607 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37608 ac_cv_prog_ac_ct_AR="$ac_prog" 37609 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37610 break 2 37611 fi 37612 done 37613 done 37614 IFS=$as_save_IFS 37615 37616 fi 37617 fi 37618 ac_ct_AR=$ac_cv_prog_ac_ct_AR 37619 if test -n "$ac_ct_AR"; then 37620 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 37621 $as_echo "$ac_ct_AR" >&6; } 37622 else 37623 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37624 $as_echo "no" >&6; } 37625 fi 37626 37627 37628 test -n "$ac_ct_AR" && break 37629 done 37630 37631 if test "x$ac_ct_AR" = x; then 37632 AR="" 37633 else 37634 case $cross_compiling:$ac_tool_warned in 37635 yes:) 37636 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 37637 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 37638 ac_tool_warned=yes ;; 37639 esac 37640 AR=$ac_ct_AR 37641 fi 37642 fi 37643 37644 else 37645 # If it succeeded, then it was overridden by the user. We will use it 37646 # for the tool. 37647 37648 # First remove it from the list of overridden variables, so we can test 37649 # for unknown variables in the end. 37650 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 37651 37652 # Check if we try to supply an empty value 37653 if test "x$AR" = x; then 37654 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool AR= (no value)" >&5 37655 $as_echo "$as_me: Setting user supplied tool AR= (no value)" >&6;} 37656 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AR" >&5 37657 $as_echo_n "checking for AR... " >&6; } 37658 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 37659 $as_echo "disabled" >&6; } 37660 else 37661 # Check if the provided tool contains a complete path. 37662 tool_specified="$AR" 37663 tool_basename="${tool_specified##*/}" 37664 if test "x$tool_basename" = "x$tool_specified"; then 37665 # A command without a complete path is provided, search $PATH. 37666 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AR=$tool_basename" >&5 37667 $as_echo "$as_me: Will search for user supplied tool AR=$tool_basename" >&6;} 37668 # Extract the first word of "$tool_basename", so it can be a program name with args. 37669 set dummy $tool_basename; ac_word=$2 37670 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37671 $as_echo_n "checking for $ac_word... " >&6; } 37672 if ${ac_cv_path_AR+:} false; then : 37673 $as_echo_n "(cached) " >&6 37674 else 37675 case $AR in 37676 [\\/]* | ?:[\\/]*) 37677 ac_cv_path_AR="$AR" # Let the user override the test with a path. 37678 ;; 37679 *) 37680 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37681 for as_dir in $PATH 37682 do 37683 IFS=$as_save_IFS 37684 test -z "$as_dir" && as_dir=. 37685 for ac_exec_ext in '' $ac_executable_extensions; do 37686 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37687 ac_cv_path_AR="$as_dir/$ac_word$ac_exec_ext" 37688 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37689 break 2 37690 fi 37691 done 37692 done 37693 IFS=$as_save_IFS 37694 37695 ;; 37696 esac 37697 fi 37698 AR=$ac_cv_path_AR 37699 if test -n "$AR"; then 37700 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 37701 $as_echo "$AR" >&6; } 37702 else 37703 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37704 $as_echo "no" >&6; } 37705 fi 37706 37707 37708 if test "x$AR" = x; then 37709 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 37710 fi 37711 else 37712 # Otherwise we believe it is a complete path. Use it as it is. 37713 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AR=$tool_specified" >&5 37714 $as_echo "$as_me: Will use user supplied tool AR=$tool_specified" >&6;} 37715 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AR" >&5 37716 $as_echo_n "checking for AR... " >&6; } 37717 if test ! -x "$tool_specified"; then 37718 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 37719 $as_echo "not found" >&6; } 37720 as_fn_error $? "User supplied tool AR=$tool_specified does not exist or is not executable" "$LINENO" 5 37721 fi 37722 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 37723 $as_echo "$tool_specified" >&6; } 37724 fi 37725 fi 37726 fi 37727 37728 fi 37729 37730 37731 fi 37732 37733 # Only process if variable expands to non-empty 37734 37735 if test "x$AR" != x; then 37736 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37737 37738 # First separate the path from the arguments. This will split at the first 37739 # space. 37740 complete="$AR" 37741 path="${complete%% *}" 37742 tmp="$complete EOL" 37743 arguments="${tmp#* }" 37744 37745 # Input might be given as Windows format, start by converting to 37746 # unix format. 37747 new_path=`$CYGPATH -u "$path"` 37748 37749 # Now try to locate executable using which 37750 new_path=`$WHICH "$new_path" 2> /dev/null` 37751 # bat and cmd files are not always considered executable in cygwin causing which 37752 # to not find them 37753 if test "x$new_path" = x \ 37754 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37755 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 37756 new_path=`$CYGPATH -u "$path"` 37757 fi 37758 if test "x$new_path" = x; then 37759 # Oops. Which didn't find the executable. 37760 # The splitting of arguments from the executable at a space might have been incorrect, 37761 # since paths with space are more likely in Windows. Give it another try with the whole 37762 # argument. 37763 path="$complete" 37764 arguments="EOL" 37765 new_path=`$CYGPATH -u "$path"` 37766 new_path=`$WHICH "$new_path" 2> /dev/null` 37767 # bat and cmd files are not always considered executable in cygwin causing which 37768 # to not find them 37769 if test "x$new_path" = x \ 37770 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37771 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 37772 new_path=`$CYGPATH -u "$path"` 37773 fi 37774 if test "x$new_path" = x; then 37775 # It's still not found. Now this is an unrecoverable error. 37776 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5 37777 $as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;} 37778 has_space=`$ECHO "$complete" | $GREP " "` 37779 if test "x$has_space" != x; then 37780 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 37781 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 37782 fi 37783 as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5 37784 fi 37785 fi 37786 37787 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 37788 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 37789 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 37790 # "foo.exe" is OK but "foo" is an error. 37791 # 37792 # This test is therefore slightly more accurate than "test -f" to check for file presence. 37793 # It is also a way to make sure we got the proper file name for the real test later on. 37794 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 37795 if test "x$test_shortpath" = x; then 37796 # Short path failed, file does not exist as specified. 37797 # Try adding .exe or .cmd 37798 if test -f "${new_path}.exe"; then 37799 input_to_shortpath="${new_path}.exe" 37800 elif test -f "${new_path}.cmd"; then 37801 input_to_shortpath="${new_path}.cmd" 37802 else 37803 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$new_path\", is invalid." >&5 37804 $as_echo "$as_me: The path of AR, which resolves as \"$new_path\", is invalid." >&6;} 37805 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 37806 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 37807 as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5 37808 fi 37809 else 37810 input_to_shortpath="$new_path" 37811 fi 37812 37813 # Call helper function which possibly converts this using DOS-style short mode. 37814 # If so, the updated path is stored in $new_path. 37815 new_path="$input_to_shortpath" 37816 37817 input_path="$input_to_shortpath" 37818 # Check if we need to convert this using DOS-style short mode. If the path 37819 # contains just simple characters, use it. Otherwise (spaces, weird characters), 37820 # take no chances and rewrite it. 37821 # Note: m4 eats our [], so we need to use [ and ] instead. 37822 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 37823 if test "x$has_forbidden_chars" != x; then 37824 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 37825 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 37826 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 37827 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 37828 # Going to short mode and back again did indeed matter. Since short mode is 37829 # case insensitive, let's make it lowercase to improve readability. 37830 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 37831 # Now convert it back to Unix-style (cygpath) 37832 input_path=`$CYGPATH -u "$shortmode_path"` 37833 new_path="$input_path" 37834 fi 37835 fi 37836 37837 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 37838 if test "x$test_cygdrive_prefix" = x; then 37839 # As a simple fix, exclude /usr/bin since it's not a real path. 37840 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 37841 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 37842 # a path prefixed by /cygdrive for fixpath to work. 37843 new_path="$CYGWIN_ROOT_PATH$input_path" 37844 fi 37845 fi 37846 37847 # remove trailing .exe if any 37848 new_path="${new_path/%.exe/}" 37849 37850 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37851 37852 # First separate the path from the arguments. This will split at the first 37853 # space. 37854 complete="$AR" 37855 path="${complete%% *}" 37856 tmp="$complete EOL" 37857 arguments="${tmp#* }" 37858 37859 # Input might be given as Windows format, start by converting to 37860 # unix format. 37861 new_path="$path" 37862 37863 windows_path="$new_path" 37864 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37865 unix_path=`$CYGPATH -u "$windows_path"` 37866 new_path="$unix_path" 37867 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37868 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37869 new_path="$unix_path" 37870 fi 37871 37872 37873 # Now try to locate executable using which 37874 new_path=`$WHICH "$new_path" 2> /dev/null` 37875 37876 if test "x$new_path" = x; then 37877 # Oops. Which didn't find the executable. 37878 # The splitting of arguments from the executable at a space might have been incorrect, 37879 # since paths with space are more likely in Windows. Give it another try with the whole 37880 # argument. 37881 path="$complete" 37882 arguments="EOL" 37883 new_path="$path" 37884 37885 windows_path="$new_path" 37886 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37887 unix_path=`$CYGPATH -u "$windows_path"` 37888 new_path="$unix_path" 37889 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37890 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37891 new_path="$unix_path" 37892 fi 37893 37894 37895 new_path=`$WHICH "$new_path" 2> /dev/null` 37896 # bat and cmd files are not always considered executable in MSYS causing which 37897 # to not find them 37898 if test "x$new_path" = x \ 37899 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37900 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 37901 new_path="$path" 37902 37903 windows_path="$new_path" 37904 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37905 unix_path=`$CYGPATH -u "$windows_path"` 37906 new_path="$unix_path" 37907 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37908 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37909 new_path="$unix_path" 37910 fi 37911 37912 fi 37913 37914 if test "x$new_path" = x; then 37915 # It's still not found. Now this is an unrecoverable error. 37916 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5 37917 $as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;} 37918 has_space=`$ECHO "$complete" | $GREP " "` 37919 if test "x$has_space" != x; then 37920 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 37921 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 37922 fi 37923 as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5 37924 fi 37925 fi 37926 37927 # Now new_path has a complete unix path to the binary 37928 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 37929 # Keep paths in /bin as-is, but remove trailing .exe if any 37930 new_path="${new_path/%.exe/}" 37931 # Do not save /bin paths to all_fixpath_prefixes! 37932 else 37933 # Not in mixed or Windows style, start by that. 37934 new_path=`cmd //c echo $new_path` 37935 37936 input_path="$new_path" 37937 # Check if we need to convert this using DOS-style short mode. If the path 37938 # contains just simple characters, use it. Otherwise (spaces, weird characters), 37939 # take no chances and rewrite it. 37940 # Note: m4 eats our [], so we need to use [ and ] instead. 37941 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 37942 if test "x$has_forbidden_chars" != x; then 37943 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 37944 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 37945 fi 37946 37947 # Output is in $new_path 37948 37949 windows_path="$new_path" 37950 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37951 unix_path=`$CYGPATH -u "$windows_path"` 37952 new_path="$unix_path" 37953 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37954 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37955 new_path="$unix_path" 37956 fi 37957 37958 # remove trailing .exe if any 37959 new_path="${new_path/%.exe/}" 37960 37961 # Save the first 10 bytes of this path to the storage, so fixpath can work. 37962 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 37963 fi 37964 37965 else 37966 # We're on a unix platform. Hooray! :) 37967 # First separate the path from the arguments. This will split at the first 37968 # space. 37969 complete="$AR" 37970 path="${complete%% *}" 37971 tmp="$complete EOL" 37972 arguments="${tmp#* }" 37973 37974 # Cannot rely on the command "which" here since it doesn't always work. 37975 is_absolute_path=`$ECHO "$path" | $GREP ^/` 37976 if test -z "$is_absolute_path"; then 37977 # Path to executable is not absolute. Find it. 37978 IFS_save="$IFS" 37979 IFS=: 37980 for p in $PATH; do 37981 if test -f "$p/$path" && test -x "$p/$path"; then 37982 new_path="$p/$path" 37983 break 37984 fi 37985 done 37986 IFS="$IFS_save" 37987 else 37988 # This is an absolute path, we can use it without further modifications. 37989 new_path="$path" 37990 fi 37991 37992 if test "x$new_path" = x; then 37993 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5 37994 $as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;} 37995 has_space=`$ECHO "$complete" | $GREP " "` 37996 if test "x$has_space" != x; then 37997 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 37998 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 37999 fi 38000 as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5 38001 fi 38002 fi 38003 38004 # Now join together the path and the arguments once again 38005 if test "x$arguments" != xEOL; then 38006 new_complete="$new_path ${arguments% *}" 38007 else 38008 new_complete="$new_path" 38009 fi 38010 38011 if test "x$complete" != "x$new_complete"; then 38012 AR="$new_complete" 38013 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting AR to \"$new_complete\"" >&5 38014 $as_echo "$as_me: Rewriting AR to \"$new_complete\"" >&6;} 38015 fi 38016 fi 38017 38018 38019 38020 if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then 38021 38022 38023 # Publish this variable in the help. 38024 38025 38026 if [ -z "${LIPO+x}" ]; then 38027 # The variable is not set by user, try to locate tool using the code snippet 38028 for ac_prog in lipo 38029 do 38030 # Extract the first word of "$ac_prog", so it can be a program name with args. 38031 set dummy $ac_prog; ac_word=$2 38032 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38033 $as_echo_n "checking for $ac_word... " >&6; } 38034 if ${ac_cv_path_LIPO+:} false; then : 38035 $as_echo_n "(cached) " >&6 38036 else 38037 case $LIPO in 38038 [\\/]* | ?:[\\/]*) 38039 ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path. 38040 ;; 38041 *) 38042 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38043 for as_dir in $PATH 38044 do 38045 IFS=$as_save_IFS 38046 test -z "$as_dir" && as_dir=. 38047 for ac_exec_ext in '' $ac_executable_extensions; do 38048 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38049 ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext" 38050 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38051 break 2 38052 fi 38053 done 38054 done 38055 IFS=$as_save_IFS 38056 38057 ;; 38058 esac 38059 fi 38060 LIPO=$ac_cv_path_LIPO 38061 if test -n "$LIPO"; then 38062 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 38063 $as_echo "$LIPO" >&6; } 38064 else 38065 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38066 $as_echo "no" >&6; } 38067 fi 38068 38069 38070 test -n "$LIPO" && break 38071 done 38072 38073 else 38074 # The variable is set, but is it from the command line or the environment? 38075 38076 # Try to remove the string !LIPO! from our list. 38077 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LIPO!/} 38078 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 38079 # If it failed, the variable was not from the command line. Ignore it, 38080 # but warn the user (except for BASH, which is always set by the calling BASH). 38081 if test "xLIPO" != xBASH; then 38082 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LIPO from the environment. Use command line variables instead." >&5 38083 $as_echo "$as_me: WARNING: Ignoring value of LIPO from the environment. Use command line variables instead." >&2;} 38084 fi 38085 # Try to locate tool using the code snippet 38086 for ac_prog in lipo 38087 do 38088 # Extract the first word of "$ac_prog", so it can be a program name with args. 38089 set dummy $ac_prog; ac_word=$2 38090 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38091 $as_echo_n "checking for $ac_word... " >&6; } 38092 if ${ac_cv_path_LIPO+:} false; then : 38093 $as_echo_n "(cached) " >&6 38094 else 38095 case $LIPO in 38096 [\\/]* | ?:[\\/]*) 38097 ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path. 38098 ;; 38099 *) 38100 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38101 for as_dir in $PATH 38102 do 38103 IFS=$as_save_IFS 38104 test -z "$as_dir" && as_dir=. 38105 for ac_exec_ext in '' $ac_executable_extensions; do 38106 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38107 ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext" 38108 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38109 break 2 38110 fi 38111 done 38112 done 38113 IFS=$as_save_IFS 38114 38115 ;; 38116 esac 38117 fi 38118 LIPO=$ac_cv_path_LIPO 38119 if test -n "$LIPO"; then 38120 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 38121 $as_echo "$LIPO" >&6; } 38122 else 38123 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38124 $as_echo "no" >&6; } 38125 fi 38126 38127 38128 test -n "$LIPO" && break 38129 done 38130 38131 else 38132 # If it succeeded, then it was overridden by the user. We will use it 38133 # for the tool. 38134 38135 # First remove it from the list of overridden variables, so we can test 38136 # for unknown variables in the end. 38137 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 38138 38139 # Check if we try to supply an empty value 38140 if test "x$LIPO" = x; then 38141 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool LIPO= (no value)" >&5 38142 $as_echo "$as_me: Setting user supplied tool LIPO= (no value)" >&6;} 38143 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIPO" >&5 38144 $as_echo_n "checking for LIPO... " >&6; } 38145 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 38146 $as_echo "disabled" >&6; } 38147 else 38148 # Check if the provided tool contains a complete path. 38149 tool_specified="$LIPO" 38150 tool_basename="${tool_specified##*/}" 38151 if test "x$tool_basename" = "x$tool_specified"; then 38152 # A command without a complete path is provided, search $PATH. 38153 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LIPO=$tool_basename" >&5 38154 $as_echo "$as_me: Will search for user supplied tool LIPO=$tool_basename" >&6;} 38155 # Extract the first word of "$tool_basename", so it can be a program name with args. 38156 set dummy $tool_basename; ac_word=$2 38157 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38158 $as_echo_n "checking for $ac_word... " >&6; } 38159 if ${ac_cv_path_LIPO+:} false; then : 38160 $as_echo_n "(cached) " >&6 38161 else 38162 case $LIPO in 38163 [\\/]* | ?:[\\/]*) 38164 ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path. 38165 ;; 38166 *) 38167 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38168 for as_dir in $PATH 38169 do 38170 IFS=$as_save_IFS 38171 test -z "$as_dir" && as_dir=. 38172 for ac_exec_ext in '' $ac_executable_extensions; do 38173 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38174 ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext" 38175 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38176 break 2 38177 fi 38178 done 38179 done 38180 IFS=$as_save_IFS 38181 38182 ;; 38183 esac 38184 fi 38185 LIPO=$ac_cv_path_LIPO 38186 if test -n "$LIPO"; then 38187 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 38188 $as_echo "$LIPO" >&6; } 38189 else 38190 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38191 $as_echo "no" >&6; } 38192 fi 38193 38194 38195 if test "x$LIPO" = x; then 38196 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 38197 fi 38198 else 38199 # Otherwise we believe it is a complete path. Use it as it is. 38200 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LIPO=$tool_specified" >&5 38201 $as_echo "$as_me: Will use user supplied tool LIPO=$tool_specified" >&6;} 38202 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIPO" >&5 38203 $as_echo_n "checking for LIPO... " >&6; } 38204 if test ! -x "$tool_specified"; then 38205 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 38206 $as_echo "not found" >&6; } 38207 as_fn_error $? "User supplied tool LIPO=$tool_specified does not exist or is not executable" "$LINENO" 5 38208 fi 38209 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 38210 $as_echo "$tool_specified" >&6; } 38211 fi 38212 fi 38213 fi 38214 38215 fi 38216 38217 38218 38219 # Only process if variable expands to non-empty 38220 38221 if test "x$LIPO" != x; then 38222 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38223 38224 # First separate the path from the arguments. This will split at the first 38225 # space. 38226 complete="$LIPO" 38227 path="${complete%% *}" 38228 tmp="$complete EOL" 38229 arguments="${tmp#* }" 38230 38231 # Input might be given as Windows format, start by converting to 38232 # unix format. 38233 new_path=`$CYGPATH -u "$path"` 38234 38235 # Now try to locate executable using which 38236 new_path=`$WHICH "$new_path" 2> /dev/null` 38237 # bat and cmd files are not always considered executable in cygwin causing which 38238 # to not find them 38239 if test "x$new_path" = x \ 38240 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38241 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38242 new_path=`$CYGPATH -u "$path"` 38243 fi 38244 if test "x$new_path" = x; then 38245 # Oops. Which didn't find the executable. 38246 # The splitting of arguments from the executable at a space might have been incorrect, 38247 # since paths with space are more likely in Windows. Give it another try with the whole 38248 # argument. 38249 path="$complete" 38250 arguments="EOL" 38251 new_path=`$CYGPATH -u "$path"` 38252 new_path=`$WHICH "$new_path" 2> /dev/null` 38253 # bat and cmd files are not always considered executable in cygwin causing which 38254 # to not find them 38255 if test "x$new_path" = x \ 38256 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38257 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38258 new_path=`$CYGPATH -u "$path"` 38259 fi 38260 if test "x$new_path" = x; then 38261 # It's still not found. Now this is an unrecoverable error. 38262 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5 38263 $as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;} 38264 has_space=`$ECHO "$complete" | $GREP " "` 38265 if test "x$has_space" != x; then 38266 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 38267 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 38268 fi 38269 as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5 38270 fi 38271 fi 38272 38273 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 38274 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 38275 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 38276 # "foo.exe" is OK but "foo" is an error. 38277 # 38278 # This test is therefore slightly more accurate than "test -f" to check for file presence. 38279 # It is also a way to make sure we got the proper file name for the real test later on. 38280 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 38281 if test "x$test_shortpath" = x; then 38282 # Short path failed, file does not exist as specified. 38283 # Try adding .exe or .cmd 38284 if test -f "${new_path}.exe"; then 38285 input_to_shortpath="${new_path}.exe" 38286 elif test -f "${new_path}.cmd"; then 38287 input_to_shortpath="${new_path}.cmd" 38288 else 38289 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$new_path\", is invalid." >&5 38290 $as_echo "$as_me: The path of LIPO, which resolves as \"$new_path\", is invalid." >&6;} 38291 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 38292 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 38293 as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5 38294 fi 38295 else 38296 input_to_shortpath="$new_path" 38297 fi 38298 38299 # Call helper function which possibly converts this using DOS-style short mode. 38300 # If so, the updated path is stored in $new_path. 38301 new_path="$input_to_shortpath" 38302 38303 input_path="$input_to_shortpath" 38304 # Check if we need to convert this using DOS-style short mode. If the path 38305 # contains just simple characters, use it. Otherwise (spaces, weird characters), 38306 # take no chances and rewrite it. 38307 # Note: m4 eats our [], so we need to use [ and ] instead. 38308 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 38309 if test "x$has_forbidden_chars" != x; then 38310 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 38311 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 38312 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 38313 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 38314 # Going to short mode and back again did indeed matter. Since short mode is 38315 # case insensitive, let's make it lowercase to improve readability. 38316 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 38317 # Now convert it back to Unix-style (cygpath) 38318 input_path=`$CYGPATH -u "$shortmode_path"` 38319 new_path="$input_path" 38320 fi 38321 fi 38322 38323 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 38324 if test "x$test_cygdrive_prefix" = x; then 38325 # As a simple fix, exclude /usr/bin since it's not a real path. 38326 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 38327 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 38328 # a path prefixed by /cygdrive for fixpath to work. 38329 new_path="$CYGWIN_ROOT_PATH$input_path" 38330 fi 38331 fi 38332 38333 # remove trailing .exe if any 38334 new_path="${new_path/%.exe/}" 38335 38336 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38337 38338 # First separate the path from the arguments. This will split at the first 38339 # space. 38340 complete="$LIPO" 38341 path="${complete%% *}" 38342 tmp="$complete EOL" 38343 arguments="${tmp#* }" 38344 38345 # Input might be given as Windows format, start by converting to 38346 # unix format. 38347 new_path="$path" 38348 38349 windows_path="$new_path" 38350 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38351 unix_path=`$CYGPATH -u "$windows_path"` 38352 new_path="$unix_path" 38353 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38354 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38355 new_path="$unix_path" 38356 fi 38357 38358 38359 # Now try to locate executable using which 38360 new_path=`$WHICH "$new_path" 2> /dev/null` 38361 38362 if test "x$new_path" = x; then 38363 # Oops. Which didn't find the executable. 38364 # The splitting of arguments from the executable at a space might have been incorrect, 38365 # since paths with space are more likely in Windows. Give it another try with the whole 38366 # argument. 38367 path="$complete" 38368 arguments="EOL" 38369 new_path="$path" 38370 38371 windows_path="$new_path" 38372 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38373 unix_path=`$CYGPATH -u "$windows_path"` 38374 new_path="$unix_path" 38375 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38376 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38377 new_path="$unix_path" 38378 fi 38379 38380 38381 new_path=`$WHICH "$new_path" 2> /dev/null` 38382 # bat and cmd files are not always considered executable in MSYS causing which 38383 # to not find them 38384 if test "x$new_path" = x \ 38385 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38386 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38387 new_path="$path" 38388 38389 windows_path="$new_path" 38390 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38391 unix_path=`$CYGPATH -u "$windows_path"` 38392 new_path="$unix_path" 38393 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38394 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38395 new_path="$unix_path" 38396 fi 38397 38398 fi 38399 38400 if test "x$new_path" = x; then 38401 # It's still not found. Now this is an unrecoverable error. 38402 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5 38403 $as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;} 38404 has_space=`$ECHO "$complete" | $GREP " "` 38405 if test "x$has_space" != x; then 38406 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 38407 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 38408 fi 38409 as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5 38410 fi 38411 fi 38412 38413 # Now new_path has a complete unix path to the binary 38414 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 38415 # Keep paths in /bin as-is, but remove trailing .exe if any 38416 new_path="${new_path/%.exe/}" 38417 # Do not save /bin paths to all_fixpath_prefixes! 38418 else 38419 # Not in mixed or Windows style, start by that. 38420 new_path=`cmd //c echo $new_path` 38421 38422 input_path="$new_path" 38423 # Check if we need to convert this using DOS-style short mode. If the path 38424 # contains just simple characters, use it. Otherwise (spaces, weird characters), 38425 # take no chances and rewrite it. 38426 # Note: m4 eats our [], so we need to use [ and ] instead. 38427 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 38428 if test "x$has_forbidden_chars" != x; then 38429 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 38430 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 38431 fi 38432 38433 # Output is in $new_path 38434 38435 windows_path="$new_path" 38436 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38437 unix_path=`$CYGPATH -u "$windows_path"` 38438 new_path="$unix_path" 38439 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38440 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38441 new_path="$unix_path" 38442 fi 38443 38444 # remove trailing .exe if any 38445 new_path="${new_path/%.exe/}" 38446 38447 # Save the first 10 bytes of this path to the storage, so fixpath can work. 38448 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 38449 fi 38450 38451 else 38452 # We're on a unix platform. Hooray! :) 38453 # First separate the path from the arguments. This will split at the first 38454 # space. 38455 complete="$LIPO" 38456 path="${complete%% *}" 38457 tmp="$complete EOL" 38458 arguments="${tmp#* }" 38459 38460 # Cannot rely on the command "which" here since it doesn't always work. 38461 is_absolute_path=`$ECHO "$path" | $GREP ^/` 38462 if test -z "$is_absolute_path"; then 38463 # Path to executable is not absolute. Find it. 38464 IFS_save="$IFS" 38465 IFS=: 38466 for p in $PATH; do 38467 if test -f "$p/$path" && test -x "$p/$path"; then 38468 new_path="$p/$path" 38469 break 38470 fi 38471 done 38472 IFS="$IFS_save" 38473 else 38474 # This is an absolute path, we can use it without further modifications. 38475 new_path="$path" 38476 fi 38477 38478 if test "x$new_path" = x; then 38479 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5 38480 $as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;} 38481 has_space=`$ECHO "$complete" | $GREP " "` 38482 if test "x$has_space" != x; then 38483 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 38484 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 38485 fi 38486 as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5 38487 fi 38488 fi 38489 38490 # Now join together the path and the arguments once again 38491 if test "x$arguments" != xEOL; then 38492 new_complete="$new_path ${arguments% *}" 38493 else 38494 new_complete="$new_path" 38495 fi 38496 38497 if test "x$complete" != "x$new_complete"; then 38498 LIPO="$new_complete" 38499 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting LIPO to \"$new_complete\"" >&5 38500 $as_echo "$as_me: Rewriting LIPO to \"$new_complete\"" >&6;} 38501 fi 38502 fi 38503 38504 fi 38505 38506 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 38507 # Extract the first word of "mt", so it can be a program name with args. 38508 set dummy mt; ac_word=$2 38509 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38510 $as_echo_n "checking for $ac_word... " >&6; } 38511 if ${ac_cv_prog_MT+:} false; then : 38512 $as_echo_n "(cached) " >&6 38513 else 38514 if test -n "$MT"; then 38515 ac_cv_prog_MT="$MT" # Let the user override the test. 38516 else 38517 ac_prog_rejected=no 38518 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38519 for as_dir in $PATH 38520 do 38521 IFS=$as_save_IFS 38522 test -z "$as_dir" && as_dir=. 38523 for ac_exec_ext in '' $ac_executable_extensions; do 38524 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38525 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/bin/mt"; then 38526 ac_prog_rejected=yes 38527 continue 38528 fi 38529 ac_cv_prog_MT="mt" 38530 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38531 break 2 38532 fi 38533 done 38534 done 38535 IFS=$as_save_IFS 38536 38537 if test $ac_prog_rejected = yes; then 38538 # We found a bogon in the path, so make sure we never use it. 38539 set dummy $ac_cv_prog_MT 38540 shift 38541 if test $# != 0; then 38542 # We chose a different compiler from the bogus one. 38543 # However, it has the same basename, so the bogon will be chosen 38544 # first if we set MT to just the basename; use the full file name. 38545 shift 38546 ac_cv_prog_MT="$as_dir/$ac_word${1+' '}$@" 38547 fi 38548 fi 38549 fi 38550 fi 38551 MT=$ac_cv_prog_MT 38552 if test -n "$MT"; then 38553 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MT" >&5 38554 $as_echo "$MT" >&6; } 38555 else 38556 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38557 $as_echo "no" >&6; } 38558 fi 38559 38560 38561 38562 # Only process if variable expands to non-empty 38563 38564 if test "x$MT" != x; then 38565 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38566 38567 # First separate the path from the arguments. This will split at the first 38568 # space. 38569 complete="$MT" 38570 path="${complete%% *}" 38571 tmp="$complete EOL" 38572 arguments="${tmp#* }" 38573 38574 # Input might be given as Windows format, start by converting to 38575 # unix format. 38576 new_path=`$CYGPATH -u "$path"` 38577 38578 # Now try to locate executable using which 38579 new_path=`$WHICH "$new_path" 2> /dev/null` 38580 # bat and cmd files are not always considered executable in cygwin causing which 38581 # to not find them 38582 if test "x$new_path" = x \ 38583 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38584 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38585 new_path=`$CYGPATH -u "$path"` 38586 fi 38587 if test "x$new_path" = x; then 38588 # Oops. Which didn't find the executable. 38589 # The splitting of arguments from the executable at a space might have been incorrect, 38590 # since paths with space are more likely in Windows. Give it another try with the whole 38591 # argument. 38592 path="$complete" 38593 arguments="EOL" 38594 new_path=`$CYGPATH -u "$path"` 38595 new_path=`$WHICH "$new_path" 2> /dev/null` 38596 # bat and cmd files are not always considered executable in cygwin causing which 38597 # to not find them 38598 if test "x$new_path" = x \ 38599 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38600 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38601 new_path=`$CYGPATH -u "$path"` 38602 fi 38603 if test "x$new_path" = x; then 38604 # It's still not found. Now this is an unrecoverable error. 38605 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5 38606 $as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;} 38607 has_space=`$ECHO "$complete" | $GREP " "` 38608 if test "x$has_space" != x; then 38609 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 38610 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 38611 fi 38612 as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5 38613 fi 38614 fi 38615 38616 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 38617 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 38618 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 38619 # "foo.exe" is OK but "foo" is an error. 38620 # 38621 # This test is therefore slightly more accurate than "test -f" to check for file presence. 38622 # It is also a way to make sure we got the proper file name for the real test later on. 38623 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 38624 if test "x$test_shortpath" = x; then 38625 # Short path failed, file does not exist as specified. 38626 # Try adding .exe or .cmd 38627 if test -f "${new_path}.exe"; then 38628 input_to_shortpath="${new_path}.exe" 38629 elif test -f "${new_path}.cmd"; then 38630 input_to_shortpath="${new_path}.cmd" 38631 else 38632 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$new_path\", is invalid." >&5 38633 $as_echo "$as_me: The path of MT, which resolves as \"$new_path\", is invalid." >&6;} 38634 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 38635 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 38636 as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5 38637 fi 38638 else 38639 input_to_shortpath="$new_path" 38640 fi 38641 38642 # Call helper function which possibly converts this using DOS-style short mode. 38643 # If so, the updated path is stored in $new_path. 38644 new_path="$input_to_shortpath" 38645 38646 input_path="$input_to_shortpath" 38647 # Check if we need to convert this using DOS-style short mode. If the path 38648 # contains just simple characters, use it. Otherwise (spaces, weird characters), 38649 # take no chances and rewrite it. 38650 # Note: m4 eats our [], so we need to use [ and ] instead. 38651 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 38652 if test "x$has_forbidden_chars" != x; then 38653 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 38654 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 38655 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 38656 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 38657 # Going to short mode and back again did indeed matter. Since short mode is 38658 # case insensitive, let's make it lowercase to improve readability. 38659 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 38660 # Now convert it back to Unix-style (cygpath) 38661 input_path=`$CYGPATH -u "$shortmode_path"` 38662 new_path="$input_path" 38663 fi 38664 fi 38665 38666 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 38667 if test "x$test_cygdrive_prefix" = x; then 38668 # As a simple fix, exclude /usr/bin since it's not a real path. 38669 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 38670 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 38671 # a path prefixed by /cygdrive for fixpath to work. 38672 new_path="$CYGWIN_ROOT_PATH$input_path" 38673 fi 38674 fi 38675 38676 # remove trailing .exe if any 38677 new_path="${new_path/%.exe/}" 38678 38679 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38680 38681 # First separate the path from the arguments. This will split at the first 38682 # space. 38683 complete="$MT" 38684 path="${complete%% *}" 38685 tmp="$complete EOL" 38686 arguments="${tmp#* }" 38687 38688 # Input might be given as Windows format, start by converting to 38689 # unix format. 38690 new_path="$path" 38691 38692 windows_path="$new_path" 38693 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38694 unix_path=`$CYGPATH -u "$windows_path"` 38695 new_path="$unix_path" 38696 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38697 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38698 new_path="$unix_path" 38699 fi 38700 38701 38702 # Now try to locate executable using which 38703 new_path=`$WHICH "$new_path" 2> /dev/null` 38704 38705 if test "x$new_path" = x; then 38706 # Oops. Which didn't find the executable. 38707 # The splitting of arguments from the executable at a space might have been incorrect, 38708 # since paths with space are more likely in Windows. Give it another try with the whole 38709 # argument. 38710 path="$complete" 38711 arguments="EOL" 38712 new_path="$path" 38713 38714 windows_path="$new_path" 38715 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38716 unix_path=`$CYGPATH -u "$windows_path"` 38717 new_path="$unix_path" 38718 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38719 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38720 new_path="$unix_path" 38721 fi 38722 38723 38724 new_path=`$WHICH "$new_path" 2> /dev/null` 38725 # bat and cmd files are not always considered executable in MSYS causing which 38726 # to not find them 38727 if test "x$new_path" = x \ 38728 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38729 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38730 new_path="$path" 38731 38732 windows_path="$new_path" 38733 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38734 unix_path=`$CYGPATH -u "$windows_path"` 38735 new_path="$unix_path" 38736 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38737 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38738 new_path="$unix_path" 38739 fi 38740 38741 fi 38742 38743 if test "x$new_path" = x; then 38744 # It's still not found. Now this is an unrecoverable error. 38745 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5 38746 $as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;} 38747 has_space=`$ECHO "$complete" | $GREP " "` 38748 if test "x$has_space" != x; then 38749 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 38750 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 38751 fi 38752 as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5 38753 fi 38754 fi 38755 38756 # Now new_path has a complete unix path to the binary 38757 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 38758 # Keep paths in /bin as-is, but remove trailing .exe if any 38759 new_path="${new_path/%.exe/}" 38760 # Do not save /bin paths to all_fixpath_prefixes! 38761 else 38762 # Not in mixed or Windows style, start by that. 38763 new_path=`cmd //c echo $new_path` 38764 38765 input_path="$new_path" 38766 # Check if we need to convert this using DOS-style short mode. If the path 38767 # contains just simple characters, use it. Otherwise (spaces, weird characters), 38768 # take no chances and rewrite it. 38769 # Note: m4 eats our [], so we need to use [ and ] instead. 38770 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 38771 if test "x$has_forbidden_chars" != x; then 38772 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 38773 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 38774 fi 38775 38776 # Output is in $new_path 38777 38778 windows_path="$new_path" 38779 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38780 unix_path=`$CYGPATH -u "$windows_path"` 38781 new_path="$unix_path" 38782 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38783 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38784 new_path="$unix_path" 38785 fi 38786 38787 # remove trailing .exe if any 38788 new_path="${new_path/%.exe/}" 38789 38790 # Save the first 10 bytes of this path to the storage, so fixpath can work. 38791 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 38792 fi 38793 38794 else 38795 # We're on a unix platform. Hooray! :) 38796 # First separate the path from the arguments. This will split at the first 38797 # space. 38798 complete="$MT" 38799 path="${complete%% *}" 38800 tmp="$complete EOL" 38801 arguments="${tmp#* }" 38802 38803 # Cannot rely on the command "which" here since it doesn't always work. 38804 is_absolute_path=`$ECHO "$path" | $GREP ^/` 38805 if test -z "$is_absolute_path"; then 38806 # Path to executable is not absolute. Find it. 38807 IFS_save="$IFS" 38808 IFS=: 38809 for p in $PATH; do 38810 if test -f "$p/$path" && test -x "$p/$path"; then 38811 new_path="$p/$path" 38812 break 38813 fi 38814 done 38815 IFS="$IFS_save" 38816 else 38817 # This is an absolute path, we can use it without further modifications. 38818 new_path="$path" 38819 fi 38820 38821 if test "x$new_path" = x; then 38822 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5 38823 $as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;} 38824 has_space=`$ECHO "$complete" | $GREP " "` 38825 if test "x$has_space" != x; then 38826 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 38827 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 38828 fi 38829 as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5 38830 fi 38831 fi 38832 38833 # Now join together the path and the arguments once again 38834 if test "x$arguments" != xEOL; then 38835 new_complete="$new_path ${arguments% *}" 38836 else 38837 new_complete="$new_path" 38838 fi 38839 38840 if test "x$complete" != "x$new_complete"; then 38841 MT="$new_complete" 38842 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MT to \"$new_complete\"" >&5 38843 $as_echo "$as_me: Rewriting MT to \"$new_complete\"" >&6;} 38844 fi 38845 fi 38846 38847 # Setup the resource compiler (RC) 38848 # Extract the first word of "rc", so it can be a program name with args. 38849 set dummy rc; ac_word=$2 38850 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38851 $as_echo_n "checking for $ac_word... " >&6; } 38852 if ${ac_cv_prog_RC+:} false; then : 38853 $as_echo_n "(cached) " >&6 38854 else 38855 if test -n "$RC"; then 38856 ac_cv_prog_RC="$RC" # Let the user override the test. 38857 else 38858 ac_prog_rejected=no 38859 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38860 for as_dir in $PATH 38861 do 38862 IFS=$as_save_IFS 38863 test -z "$as_dir" && as_dir=. 38864 for ac_exec_ext in '' $ac_executable_extensions; do 38865 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38866 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/bin/rc"; then 38867 ac_prog_rejected=yes 38868 continue 38869 fi 38870 ac_cv_prog_RC="rc" 38871 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38872 break 2 38873 fi 38874 done 38875 done 38876 IFS=$as_save_IFS 38877 38878 if test $ac_prog_rejected = yes; then 38879 # We found a bogon in the path, so make sure we never use it. 38880 set dummy $ac_cv_prog_RC 38881 shift 38882 if test $# != 0; then 38883 # We chose a different compiler from the bogus one. 38884 # However, it has the same basename, so the bogon will be chosen 38885 # first if we set RC to just the basename; use the full file name. 38886 shift 38887 ac_cv_prog_RC="$as_dir/$ac_word${1+' '}$@" 38888 fi 38889 fi 38890 fi 38891 fi 38892 RC=$ac_cv_prog_RC 38893 if test -n "$RC"; then 38894 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RC" >&5 38895 $as_echo "$RC" >&6; } 38896 else 38897 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38898 $as_echo "no" >&6; } 38899 fi 38900 38901 38902 38903 # Only process if variable expands to non-empty 38904 38905 if test "x$RC" != x; then 38906 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38907 38908 # First separate the path from the arguments. This will split at the first 38909 # space. 38910 complete="$RC" 38911 path="${complete%% *}" 38912 tmp="$complete EOL" 38913 arguments="${tmp#* }" 38914 38915 # Input might be given as Windows format, start by converting to 38916 # unix format. 38917 new_path=`$CYGPATH -u "$path"` 38918 38919 # Now try to locate executable using which 38920 new_path=`$WHICH "$new_path" 2> /dev/null` 38921 # bat and cmd files are not always considered executable in cygwin causing which 38922 # to not find them 38923 if test "x$new_path" = x \ 38924 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38925 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38926 new_path=`$CYGPATH -u "$path"` 38927 fi 38928 if test "x$new_path" = x; then 38929 # Oops. Which didn't find the executable. 38930 # The splitting of arguments from the executable at a space might have been incorrect, 38931 # since paths with space are more likely in Windows. Give it another try with the whole 38932 # argument. 38933 path="$complete" 38934 arguments="EOL" 38935 new_path=`$CYGPATH -u "$path"` 38936 new_path=`$WHICH "$new_path" 2> /dev/null` 38937 # bat and cmd files are not always considered executable in cygwin causing which 38938 # to not find them 38939 if test "x$new_path" = x \ 38940 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38941 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38942 new_path=`$CYGPATH -u "$path"` 38943 fi 38944 if test "x$new_path" = x; then 38945 # It's still not found. Now this is an unrecoverable error. 38946 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5 38947 $as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;} 38948 has_space=`$ECHO "$complete" | $GREP " "` 38949 if test "x$has_space" != x; then 38950 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 38951 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 38952 fi 38953 as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5 38954 fi 38955 fi 38956 38957 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 38958 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 38959 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 38960 # "foo.exe" is OK but "foo" is an error. 38961 # 38962 # This test is therefore slightly more accurate than "test -f" to check for file presence. 38963 # It is also a way to make sure we got the proper file name for the real test later on. 38964 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 38965 if test "x$test_shortpath" = x; then 38966 # Short path failed, file does not exist as specified. 38967 # Try adding .exe or .cmd 38968 if test -f "${new_path}.exe"; then 38969 input_to_shortpath="${new_path}.exe" 38970 elif test -f "${new_path}.cmd"; then 38971 input_to_shortpath="${new_path}.cmd" 38972 else 38973 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$new_path\", is invalid." >&5 38974 $as_echo "$as_me: The path of RC, which resolves as \"$new_path\", is invalid." >&6;} 38975 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 38976 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 38977 as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5 38978 fi 38979 else 38980 input_to_shortpath="$new_path" 38981 fi 38982 38983 # Call helper function which possibly converts this using DOS-style short mode. 38984 # If so, the updated path is stored in $new_path. 38985 new_path="$input_to_shortpath" 38986 38987 input_path="$input_to_shortpath" 38988 # Check if we need to convert this using DOS-style short mode. If the path 38989 # contains just simple characters, use it. Otherwise (spaces, weird characters), 38990 # take no chances and rewrite it. 38991 # Note: m4 eats our [], so we need to use [ and ] instead. 38992 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 38993 if test "x$has_forbidden_chars" != x; then 38994 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 38995 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 38996 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 38997 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 38998 # Going to short mode and back again did indeed matter. Since short mode is 38999 # case insensitive, let's make it lowercase to improve readability. 39000 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39001 # Now convert it back to Unix-style (cygpath) 39002 input_path=`$CYGPATH -u "$shortmode_path"` 39003 new_path="$input_path" 39004 fi 39005 fi 39006 39007 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 39008 if test "x$test_cygdrive_prefix" = x; then 39009 # As a simple fix, exclude /usr/bin since it's not a real path. 39010 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 39011 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 39012 # a path prefixed by /cygdrive for fixpath to work. 39013 new_path="$CYGWIN_ROOT_PATH$input_path" 39014 fi 39015 fi 39016 39017 # remove trailing .exe if any 39018 new_path="${new_path/%.exe/}" 39019 39020 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39021 39022 # First separate the path from the arguments. This will split at the first 39023 # space. 39024 complete="$RC" 39025 path="${complete%% *}" 39026 tmp="$complete EOL" 39027 arguments="${tmp#* }" 39028 39029 # Input might be given as Windows format, start by converting to 39030 # unix format. 39031 new_path="$path" 39032 39033 windows_path="$new_path" 39034 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39035 unix_path=`$CYGPATH -u "$windows_path"` 39036 new_path="$unix_path" 39037 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39038 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39039 new_path="$unix_path" 39040 fi 39041 39042 39043 # Now try to locate executable using which 39044 new_path=`$WHICH "$new_path" 2> /dev/null` 39045 39046 if test "x$new_path" = x; then 39047 # Oops. Which didn't find the executable. 39048 # The splitting of arguments from the executable at a space might have been incorrect, 39049 # since paths with space are more likely in Windows. Give it another try with the whole 39050 # argument. 39051 path="$complete" 39052 arguments="EOL" 39053 new_path="$path" 39054 39055 windows_path="$new_path" 39056 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39057 unix_path=`$CYGPATH -u "$windows_path"` 39058 new_path="$unix_path" 39059 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39060 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39061 new_path="$unix_path" 39062 fi 39063 39064 39065 new_path=`$WHICH "$new_path" 2> /dev/null` 39066 # bat and cmd files are not always considered executable in MSYS causing which 39067 # to not find them 39068 if test "x$new_path" = x \ 39069 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39070 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39071 new_path="$path" 39072 39073 windows_path="$new_path" 39074 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39075 unix_path=`$CYGPATH -u "$windows_path"` 39076 new_path="$unix_path" 39077 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39078 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39079 new_path="$unix_path" 39080 fi 39081 39082 fi 39083 39084 if test "x$new_path" = x; then 39085 # It's still not found. Now this is an unrecoverable error. 39086 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5 39087 $as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;} 39088 has_space=`$ECHO "$complete" | $GREP " "` 39089 if test "x$has_space" != x; then 39090 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 39091 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 39092 fi 39093 as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5 39094 fi 39095 fi 39096 39097 # Now new_path has a complete unix path to the binary 39098 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 39099 # Keep paths in /bin as-is, but remove trailing .exe if any 39100 new_path="${new_path/%.exe/}" 39101 # Do not save /bin paths to all_fixpath_prefixes! 39102 else 39103 # Not in mixed or Windows style, start by that. 39104 new_path=`cmd //c echo $new_path` 39105 39106 input_path="$new_path" 39107 # Check if we need to convert this using DOS-style short mode. If the path 39108 # contains just simple characters, use it. Otherwise (spaces, weird characters), 39109 # take no chances and rewrite it. 39110 # Note: m4 eats our [], so we need to use [ and ] instead. 39111 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 39112 if test "x$has_forbidden_chars" != x; then 39113 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 39114 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39115 fi 39116 39117 # Output is in $new_path 39118 39119 windows_path="$new_path" 39120 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39121 unix_path=`$CYGPATH -u "$windows_path"` 39122 new_path="$unix_path" 39123 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39124 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39125 new_path="$unix_path" 39126 fi 39127 39128 # remove trailing .exe if any 39129 new_path="${new_path/%.exe/}" 39130 39131 # Save the first 10 bytes of this path to the storage, so fixpath can work. 39132 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 39133 fi 39134 39135 else 39136 # We're on a unix platform. Hooray! :) 39137 # First separate the path from the arguments. This will split at the first 39138 # space. 39139 complete="$RC" 39140 path="${complete%% *}" 39141 tmp="$complete EOL" 39142 arguments="${tmp#* }" 39143 39144 # Cannot rely on the command "which" here since it doesn't always work. 39145 is_absolute_path=`$ECHO "$path" | $GREP ^/` 39146 if test -z "$is_absolute_path"; then 39147 # Path to executable is not absolute. Find it. 39148 IFS_save="$IFS" 39149 IFS=: 39150 for p in $PATH; do 39151 if test -f "$p/$path" && test -x "$p/$path"; then 39152 new_path="$p/$path" 39153 break 39154 fi 39155 done 39156 IFS="$IFS_save" 39157 else 39158 # This is an absolute path, we can use it without further modifications. 39159 new_path="$path" 39160 fi 39161 39162 if test "x$new_path" = x; then 39163 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5 39164 $as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;} 39165 has_space=`$ECHO "$complete" | $GREP " "` 39166 if test "x$has_space" != x; then 39167 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 39168 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 39169 fi 39170 as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5 39171 fi 39172 fi 39173 39174 # Now join together the path and the arguments once again 39175 if test "x$arguments" != xEOL; then 39176 new_complete="$new_path ${arguments% *}" 39177 else 39178 new_complete="$new_path" 39179 fi 39180 39181 if test "x$complete" != "x$new_complete"; then 39182 RC="$new_complete" 39183 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting RC to \"$new_complete\"" >&5 39184 $as_echo "$as_me: Rewriting RC to \"$new_complete\"" >&6;} 39185 fi 39186 fi 39187 39188 # Extract the first word of "dumpbin", so it can be a program name with args. 39189 set dummy dumpbin; ac_word=$2 39190 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 39191 $as_echo_n "checking for $ac_word... " >&6; } 39192 if ${ac_cv_prog_DUMPBIN+:} false; then : 39193 $as_echo_n "(cached) " >&6 39194 else 39195 if test -n "$DUMPBIN"; then 39196 ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test. 39197 else 39198 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 39199 for as_dir in $PATH 39200 do 39201 IFS=$as_save_IFS 39202 test -z "$as_dir" && as_dir=. 39203 for ac_exec_ext in '' $ac_executable_extensions; do 39204 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 39205 ac_cv_prog_DUMPBIN="dumpbin" 39206 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 39207 break 2 39208 fi 39209 done 39210 done 39211 IFS=$as_save_IFS 39212 39213 fi 39214 fi 39215 DUMPBIN=$ac_cv_prog_DUMPBIN 39216 if test -n "$DUMPBIN"; then 39217 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5 39218 $as_echo "$DUMPBIN" >&6; } 39219 else 39220 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 39221 $as_echo "no" >&6; } 39222 fi 39223 39224 39225 39226 # Only process if variable expands to non-empty 39227 39228 if test "x$DUMPBIN" != x; then 39229 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39230 39231 # First separate the path from the arguments. This will split at the first 39232 # space. 39233 complete="$DUMPBIN" 39234 path="${complete%% *}" 39235 tmp="$complete EOL" 39236 arguments="${tmp#* }" 39237 39238 # Input might be given as Windows format, start by converting to 39239 # unix format. 39240 new_path=`$CYGPATH -u "$path"` 39241 39242 # Now try to locate executable using which 39243 new_path=`$WHICH "$new_path" 2> /dev/null` 39244 # bat and cmd files are not always considered executable in cygwin causing which 39245 # to not find them 39246 if test "x$new_path" = x \ 39247 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39248 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39249 new_path=`$CYGPATH -u "$path"` 39250 fi 39251 if test "x$new_path" = x; then 39252 # Oops. Which didn't find the executable. 39253 # The splitting of arguments from the executable at a space might have been incorrect, 39254 # since paths with space are more likely in Windows. Give it another try with the whole 39255 # argument. 39256 path="$complete" 39257 arguments="EOL" 39258 new_path=`$CYGPATH -u "$path"` 39259 new_path=`$WHICH "$new_path" 2> /dev/null` 39260 # bat and cmd files are not always considered executable in cygwin causing which 39261 # to not find them 39262 if test "x$new_path" = x \ 39263 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39264 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39265 new_path=`$CYGPATH -u "$path"` 39266 fi 39267 if test "x$new_path" = x; then 39268 # It's still not found. Now this is an unrecoverable error. 39269 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5 39270 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;} 39271 has_space=`$ECHO "$complete" | $GREP " "` 39272 if test "x$has_space" != x; then 39273 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 39274 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 39275 fi 39276 as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5 39277 fi 39278 fi 39279 39280 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 39281 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 39282 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 39283 # "foo.exe" is OK but "foo" is an error. 39284 # 39285 # This test is therefore slightly more accurate than "test -f" to check for file presence. 39286 # It is also a way to make sure we got the proper file name for the real test later on. 39287 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 39288 if test "x$test_shortpath" = x; then 39289 # Short path failed, file does not exist as specified. 39290 # Try adding .exe or .cmd 39291 if test -f "${new_path}.exe"; then 39292 input_to_shortpath="${new_path}.exe" 39293 elif test -f "${new_path}.cmd"; then 39294 input_to_shortpath="${new_path}.cmd" 39295 else 39296 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$new_path\", is invalid." >&5 39297 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$new_path\", is invalid." >&6;} 39298 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 39299 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 39300 as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5 39301 fi 39302 else 39303 input_to_shortpath="$new_path" 39304 fi 39305 39306 # Call helper function which possibly converts this using DOS-style short mode. 39307 # If so, the updated path is stored in $new_path. 39308 new_path="$input_to_shortpath" 39309 39310 input_path="$input_to_shortpath" 39311 # Check if we need to convert this using DOS-style short mode. If the path 39312 # contains just simple characters, use it. Otherwise (spaces, weird characters), 39313 # take no chances and rewrite it. 39314 # Note: m4 eats our [], so we need to use [ and ] instead. 39315 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 39316 if test "x$has_forbidden_chars" != x; then 39317 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 39318 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 39319 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 39320 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 39321 # Going to short mode and back again did indeed matter. Since short mode is 39322 # case insensitive, let's make it lowercase to improve readability. 39323 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39324 # Now convert it back to Unix-style (cygpath) 39325 input_path=`$CYGPATH -u "$shortmode_path"` 39326 new_path="$input_path" 39327 fi 39328 fi 39329 39330 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 39331 if test "x$test_cygdrive_prefix" = x; then 39332 # As a simple fix, exclude /usr/bin since it's not a real path. 39333 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 39334 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 39335 # a path prefixed by /cygdrive for fixpath to work. 39336 new_path="$CYGWIN_ROOT_PATH$input_path" 39337 fi 39338 fi 39339 39340 # remove trailing .exe if any 39341 new_path="${new_path/%.exe/}" 39342 39343 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39344 39345 # First separate the path from the arguments. This will split at the first 39346 # space. 39347 complete="$DUMPBIN" 39348 path="${complete%% *}" 39349 tmp="$complete EOL" 39350 arguments="${tmp#* }" 39351 39352 # Input might be given as Windows format, start by converting to 39353 # unix format. 39354 new_path="$path" 39355 39356 windows_path="$new_path" 39357 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39358 unix_path=`$CYGPATH -u "$windows_path"` 39359 new_path="$unix_path" 39360 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39361 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39362 new_path="$unix_path" 39363 fi 39364 39365 39366 # Now try to locate executable using which 39367 new_path=`$WHICH "$new_path" 2> /dev/null` 39368 39369 if test "x$new_path" = x; then 39370 # Oops. Which didn't find the executable. 39371 # The splitting of arguments from the executable at a space might have been incorrect, 39372 # since paths with space are more likely in Windows. Give it another try with the whole 39373 # argument. 39374 path="$complete" 39375 arguments="EOL" 39376 new_path="$path" 39377 39378 windows_path="$new_path" 39379 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39380 unix_path=`$CYGPATH -u "$windows_path"` 39381 new_path="$unix_path" 39382 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39383 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39384 new_path="$unix_path" 39385 fi 39386 39387 39388 new_path=`$WHICH "$new_path" 2> /dev/null` 39389 # bat and cmd files are not always considered executable in MSYS causing which 39390 # to not find them 39391 if test "x$new_path" = x \ 39392 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39393 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39394 new_path="$path" 39395 39396 windows_path="$new_path" 39397 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39398 unix_path=`$CYGPATH -u "$windows_path"` 39399 new_path="$unix_path" 39400 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39401 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39402 new_path="$unix_path" 39403 fi 39404 39405 fi 39406 39407 if test "x$new_path" = x; then 39408 # It's still not found. Now this is an unrecoverable error. 39409 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5 39410 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;} 39411 has_space=`$ECHO "$complete" | $GREP " "` 39412 if test "x$has_space" != x; then 39413 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 39414 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 39415 fi 39416 as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5 39417 fi 39418 fi 39419 39420 # Now new_path has a complete unix path to the binary 39421 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 39422 # Keep paths in /bin as-is, but remove trailing .exe if any 39423 new_path="${new_path/%.exe/}" 39424 # Do not save /bin paths to all_fixpath_prefixes! 39425 else 39426 # Not in mixed or Windows style, start by that. 39427 new_path=`cmd //c echo $new_path` 39428 39429 input_path="$new_path" 39430 # Check if we need to convert this using DOS-style short mode. If the path 39431 # contains just simple characters, use it. Otherwise (spaces, weird characters), 39432 # take no chances and rewrite it. 39433 # Note: m4 eats our [], so we need to use [ and ] instead. 39434 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 39435 if test "x$has_forbidden_chars" != x; then 39436 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 39437 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39438 fi 39439 39440 # Output is in $new_path 39441 39442 windows_path="$new_path" 39443 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39444 unix_path=`$CYGPATH -u "$windows_path"` 39445 new_path="$unix_path" 39446 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39447 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39448 new_path="$unix_path" 39449 fi 39450 39451 # remove trailing .exe if any 39452 new_path="${new_path/%.exe/}" 39453 39454 # Save the first 10 bytes of this path to the storage, so fixpath can work. 39455 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 39456 fi 39457 39458 else 39459 # We're on a unix platform. Hooray! :) 39460 # First separate the path from the arguments. This will split at the first 39461 # space. 39462 complete="$DUMPBIN" 39463 path="${complete%% *}" 39464 tmp="$complete EOL" 39465 arguments="${tmp#* }" 39466 39467 # Cannot rely on the command "which" here since it doesn't always work. 39468 is_absolute_path=`$ECHO "$path" | $GREP ^/` 39469 if test -z "$is_absolute_path"; then 39470 # Path to executable is not absolute. Find it. 39471 IFS_save="$IFS" 39472 IFS=: 39473 for p in $PATH; do 39474 if test -f "$p/$path" && test -x "$p/$path"; then 39475 new_path="$p/$path" 39476 break 39477 fi 39478 done 39479 IFS="$IFS_save" 39480 else 39481 # This is an absolute path, we can use it without further modifications. 39482 new_path="$path" 39483 fi 39484 39485 if test "x$new_path" = x; then 39486 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5 39487 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;} 39488 has_space=`$ECHO "$complete" | $GREP " "` 39489 if test "x$has_space" != x; then 39490 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 39491 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 39492 fi 39493 as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5 39494 fi 39495 fi 39496 39497 # Now join together the path and the arguments once again 39498 if test "x$arguments" != xEOL; then 39499 new_complete="$new_path ${arguments% *}" 39500 else 39501 new_complete="$new_path" 39502 fi 39503 39504 if test "x$complete" != "x$new_complete"; then 39505 DUMPBIN="$new_complete" 39506 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting DUMPBIN to \"$new_complete\"" >&5 39507 $as_echo "$as_me: Rewriting DUMPBIN to \"$new_complete\"" >&6;} 39508 fi 39509 fi 39510 39511 # We need to check for 'msbuild.exe' because at the place where we expect to 39512 # find 'msbuild.exe' there's also a directory called 'msbuild' and configure 39513 # won't find the 'msbuild.exe' executable in that case (and the 39514 # 'ac_executable_extensions' is unusable due to performance reasons). 39515 # Notice that we intentionally don't fix up the path to MSBUILD because we 39516 # will call it in a DOS shell during freetype detection on Windows (see 39517 # 'LIB_SETUP_FREETYPE' in "libraries.m4" 39518 # Extract the first word of "msbuild.exe", so it can be a program name with args. 39519 set dummy msbuild.exe; ac_word=$2 39520 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 39521 $as_echo_n "checking for $ac_word... " >&6; } 39522 if ${ac_cv_prog_MSBUILD+:} false; then : 39523 $as_echo_n "(cached) " >&6 39524 else 39525 if test -n "$MSBUILD"; then 39526 ac_cv_prog_MSBUILD="$MSBUILD" # Let the user override the test. 39527 else 39528 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 39529 for as_dir in $PATH 39530 do 39531 IFS=$as_save_IFS 39532 test -z "$as_dir" && as_dir=. 39533 for ac_exec_ext in '' $ac_executable_extensions; do 39534 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 39535 ac_cv_prog_MSBUILD="msbuild.exe" 39536 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 39537 break 2 39538 fi 39539 done 39540 done 39541 IFS=$as_save_IFS 39542 39543 fi 39544 fi 39545 MSBUILD=$ac_cv_prog_MSBUILD 39546 if test -n "$MSBUILD"; then 39547 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSBUILD" >&5 39548 $as_echo "$MSBUILD" >&6; } 39549 else 39550 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 39551 $as_echo "no" >&6; } 39552 fi 39553 39554 39555 fi 39556 39557 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 39558 39559 39560 # Publish this variable in the help. 39561 39562 39563 if [ -z "${STRIP+x}" ]; then 39564 # The variable is not set by user, try to locate tool using the code snippet 39565 for ac_prog in strip 39566 do 39567 # Extract the first word of "$ac_prog", so it can be a program name with args. 39568 set dummy $ac_prog; ac_word=$2 39569 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 39570 $as_echo_n "checking for $ac_word... " >&6; } 39571 if ${ac_cv_path_STRIP+:} false; then : 39572 $as_echo_n "(cached) " >&6 39573 else 39574 case $STRIP in 39575 [\\/]* | ?:[\\/]*) 39576 ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path. 39577 ;; 39578 *) 39579 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 39580 for as_dir in $PATH 39581 do 39582 IFS=$as_save_IFS 39583 test -z "$as_dir" && as_dir=. 39584 for ac_exec_ext in '' $ac_executable_extensions; do 39585 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 39586 ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext" 39587 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 39588 break 2 39589 fi 39590 done 39591 done 39592 IFS=$as_save_IFS 39593 39594 ;; 39595 esac 39596 fi 39597 STRIP=$ac_cv_path_STRIP 39598 if test -n "$STRIP"; then 39599 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 39600 $as_echo "$STRIP" >&6; } 39601 else 39602 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 39603 $as_echo "no" >&6; } 39604 fi 39605 39606 39607 test -n "$STRIP" && break 39608 done 39609 39610 else 39611 # The variable is set, but is it from the command line or the environment? 39612 39613 # Try to remove the string !STRIP! from our list. 39614 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!STRIP!/} 39615 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 39616 # If it failed, the variable was not from the command line. Ignore it, 39617 # but warn the user (except for BASH, which is always set by the calling BASH). 39618 if test "xSTRIP" != xBASH; then 39619 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&5 39620 $as_echo "$as_me: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&2;} 39621 fi 39622 # Try to locate tool using the code snippet 39623 for ac_prog in strip 39624 do 39625 # Extract the first word of "$ac_prog", so it can be a program name with args. 39626 set dummy $ac_prog; ac_word=$2 39627 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 39628 $as_echo_n "checking for $ac_word... " >&6; } 39629 if ${ac_cv_path_STRIP+:} false; then : 39630 $as_echo_n "(cached) " >&6 39631 else 39632 case $STRIP in 39633 [\\/]* | ?:[\\/]*) 39634 ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path. 39635 ;; 39636 *) 39637 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 39638 for as_dir in $PATH 39639 do 39640 IFS=$as_save_IFS 39641 test -z "$as_dir" && as_dir=. 39642 for ac_exec_ext in '' $ac_executable_extensions; do 39643 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 39644 ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext" 39645 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 39646 break 2 39647 fi 39648 done 39649 done 39650 IFS=$as_save_IFS 39651 39652 ;; 39653 esac 39654 fi 39655 STRIP=$ac_cv_path_STRIP 39656 if test -n "$STRIP"; then 39657 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 39658 $as_echo "$STRIP" >&6; } 39659 else 39660 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 39661 $as_echo "no" >&6; } 39662 fi 39663 39664 39665 test -n "$STRIP" && break 39666 done 39667 39668 else 39669 # If it succeeded, then it was overridden by the user. We will use it 39670 # for the tool. 39671 39672 # First remove it from the list of overridden variables, so we can test 39673 # for unknown variables in the end. 39674 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 39675 39676 # Check if we try to supply an empty value 39677 if test "x$STRIP" = x; then 39678 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool STRIP= (no value)" >&5 39679 $as_echo "$as_me: Setting user supplied tool STRIP= (no value)" >&6;} 39680 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5 39681 $as_echo_n "checking for STRIP... " >&6; } 39682 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 39683 $as_echo "disabled" >&6; } 39684 else 39685 # Check if the provided tool contains a complete path. 39686 tool_specified="$STRIP" 39687 tool_basename="${tool_specified##*/}" 39688 if test "x$tool_basename" = "x$tool_specified"; then 39689 # A command without a complete path is provided, search $PATH. 39690 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool STRIP=$tool_basename" >&5 39691 $as_echo "$as_me: Will search for user supplied tool STRIP=$tool_basename" >&6;} 39692 # Extract the first word of "$tool_basename", so it can be a program name with args. 39693 set dummy $tool_basename; ac_word=$2 39694 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 39695 $as_echo_n "checking for $ac_word... " >&6; } 39696 if ${ac_cv_path_STRIP+:} false; then : 39697 $as_echo_n "(cached) " >&6 39698 else 39699 case $STRIP in 39700 [\\/]* | ?:[\\/]*) 39701 ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path. 39702 ;; 39703 *) 39704 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 39705 for as_dir in $PATH 39706 do 39707 IFS=$as_save_IFS 39708 test -z "$as_dir" && as_dir=. 39709 for ac_exec_ext in '' $ac_executable_extensions; do 39710 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 39711 ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext" 39712 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 39713 break 2 39714 fi 39715 done 39716 done 39717 IFS=$as_save_IFS 39718 39719 ;; 39720 esac 39721 fi 39722 STRIP=$ac_cv_path_STRIP 39723 if test -n "$STRIP"; then 39724 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 39725 $as_echo "$STRIP" >&6; } 39726 else 39727 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 39728 $as_echo "no" >&6; } 39729 fi 39730 39731 39732 if test "x$STRIP" = x; then 39733 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 39734 fi 39735 else 39736 # Otherwise we believe it is a complete path. Use it as it is. 39737 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool STRIP=$tool_specified" >&5 39738 $as_echo "$as_me: Will use user supplied tool STRIP=$tool_specified" >&6;} 39739 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5 39740 $as_echo_n "checking for STRIP... " >&6; } 39741 if test ! -x "$tool_specified"; then 39742 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 39743 $as_echo "not found" >&6; } 39744 as_fn_error $? "User supplied tool STRIP=$tool_specified does not exist or is not executable" "$LINENO" 5 39745 fi 39746 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 39747 $as_echo "$tool_specified" >&6; } 39748 fi 39749 fi 39750 fi 39751 39752 fi 39753 39754 39755 39756 # Only process if variable expands to non-empty 39757 39758 if test "x$STRIP" != x; then 39759 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39760 39761 # First separate the path from the arguments. This will split at the first 39762 # space. 39763 complete="$STRIP" 39764 path="${complete%% *}" 39765 tmp="$complete EOL" 39766 arguments="${tmp#* }" 39767 39768 # Input might be given as Windows format, start by converting to 39769 # unix format. 39770 new_path=`$CYGPATH -u "$path"` 39771 39772 # Now try to locate executable using which 39773 new_path=`$WHICH "$new_path" 2> /dev/null` 39774 # bat and cmd files are not always considered executable in cygwin causing which 39775 # to not find them 39776 if test "x$new_path" = x \ 39777 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39778 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39779 new_path=`$CYGPATH -u "$path"` 39780 fi 39781 if test "x$new_path" = x; then 39782 # Oops. Which didn't find the executable. 39783 # The splitting of arguments from the executable at a space might have been incorrect, 39784 # since paths with space are more likely in Windows. Give it another try with the whole 39785 # argument. 39786 path="$complete" 39787 arguments="EOL" 39788 new_path=`$CYGPATH -u "$path"` 39789 new_path=`$WHICH "$new_path" 2> /dev/null` 39790 # bat and cmd files are not always considered executable in cygwin causing which 39791 # to not find them 39792 if test "x$new_path" = x \ 39793 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39794 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39795 new_path=`$CYGPATH -u "$path"` 39796 fi 39797 if test "x$new_path" = x; then 39798 # It's still not found. Now this is an unrecoverable error. 39799 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 39800 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 39801 has_space=`$ECHO "$complete" | $GREP " "` 39802 if test "x$has_space" != x; then 39803 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 39804 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 39805 fi 39806 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 39807 fi 39808 fi 39809 39810 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 39811 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 39812 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 39813 # "foo.exe" is OK but "foo" is an error. 39814 # 39815 # This test is therefore slightly more accurate than "test -f" to check for file presence. 39816 # It is also a way to make sure we got the proper file name for the real test later on. 39817 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 39818 if test "x$test_shortpath" = x; then 39819 # Short path failed, file does not exist as specified. 39820 # Try adding .exe or .cmd 39821 if test -f "${new_path}.exe"; then 39822 input_to_shortpath="${new_path}.exe" 39823 elif test -f "${new_path}.cmd"; then 39824 input_to_shortpath="${new_path}.cmd" 39825 else 39826 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$new_path\", is invalid." >&5 39827 $as_echo "$as_me: The path of STRIP, which resolves as \"$new_path\", is invalid." >&6;} 39828 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 39829 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 39830 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 39831 fi 39832 else 39833 input_to_shortpath="$new_path" 39834 fi 39835 39836 # Call helper function which possibly converts this using DOS-style short mode. 39837 # If so, the updated path is stored in $new_path. 39838 new_path="$input_to_shortpath" 39839 39840 input_path="$input_to_shortpath" 39841 # Check if we need to convert this using DOS-style short mode. If the path 39842 # contains just simple characters, use it. Otherwise (spaces, weird characters), 39843 # take no chances and rewrite it. 39844 # Note: m4 eats our [], so we need to use [ and ] instead. 39845 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 39846 if test "x$has_forbidden_chars" != x; then 39847 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 39848 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 39849 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 39850 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 39851 # Going to short mode and back again did indeed matter. Since short mode is 39852 # case insensitive, let's make it lowercase to improve readability. 39853 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39854 # Now convert it back to Unix-style (cygpath) 39855 input_path=`$CYGPATH -u "$shortmode_path"` 39856 new_path="$input_path" 39857 fi 39858 fi 39859 39860 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 39861 if test "x$test_cygdrive_prefix" = x; then 39862 # As a simple fix, exclude /usr/bin since it's not a real path. 39863 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 39864 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 39865 # a path prefixed by /cygdrive for fixpath to work. 39866 new_path="$CYGWIN_ROOT_PATH$input_path" 39867 fi 39868 fi 39869 39870 # remove trailing .exe if any 39871 new_path="${new_path/%.exe/}" 39872 39873 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39874 39875 # First separate the path from the arguments. This will split at the first 39876 # space. 39877 complete="$STRIP" 39878 path="${complete%% *}" 39879 tmp="$complete EOL" 39880 arguments="${tmp#* }" 39881 39882 # Input might be given as Windows format, start by converting to 39883 # unix format. 39884 new_path="$path" 39885 39886 windows_path="$new_path" 39887 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39888 unix_path=`$CYGPATH -u "$windows_path"` 39889 new_path="$unix_path" 39890 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39891 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39892 new_path="$unix_path" 39893 fi 39894 39895 39896 # Now try to locate executable using which 39897 new_path=`$WHICH "$new_path" 2> /dev/null` 39898 39899 if test "x$new_path" = x; then 39900 # Oops. Which didn't find the executable. 39901 # The splitting of arguments from the executable at a space might have been incorrect, 39902 # since paths with space are more likely in Windows. Give it another try with the whole 39903 # argument. 39904 path="$complete" 39905 arguments="EOL" 39906 new_path="$path" 39907 39908 windows_path="$new_path" 39909 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39910 unix_path=`$CYGPATH -u "$windows_path"` 39911 new_path="$unix_path" 39912 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39913 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39914 new_path="$unix_path" 39915 fi 39916 39917 39918 new_path=`$WHICH "$new_path" 2> /dev/null` 39919 # bat and cmd files are not always considered executable in MSYS causing which 39920 # to not find them 39921 if test "x$new_path" = x \ 39922 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39923 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39924 new_path="$path" 39925 39926 windows_path="$new_path" 39927 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39928 unix_path=`$CYGPATH -u "$windows_path"` 39929 new_path="$unix_path" 39930 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39931 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39932 new_path="$unix_path" 39933 fi 39934 39935 fi 39936 39937 if test "x$new_path" = x; then 39938 # It's still not found. Now this is an unrecoverable error. 39939 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 39940 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 39941 has_space=`$ECHO "$complete" | $GREP " "` 39942 if test "x$has_space" != x; then 39943 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 39944 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 39945 fi 39946 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 39947 fi 39948 fi 39949 39950 # Now new_path has a complete unix path to the binary 39951 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 39952 # Keep paths in /bin as-is, but remove trailing .exe if any 39953 new_path="${new_path/%.exe/}" 39954 # Do not save /bin paths to all_fixpath_prefixes! 39955 else 39956 # Not in mixed or Windows style, start by that. 39957 new_path=`cmd //c echo $new_path` 39958 39959 input_path="$new_path" 39960 # Check if we need to convert this using DOS-style short mode. If the path 39961 # contains just simple characters, use it. Otherwise (spaces, weird characters), 39962 # take no chances and rewrite it. 39963 # Note: m4 eats our [], so we need to use [ and ] instead. 39964 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 39965 if test "x$has_forbidden_chars" != x; then 39966 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 39967 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39968 fi 39969 39970 # Output is in $new_path 39971 39972 windows_path="$new_path" 39973 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39974 unix_path=`$CYGPATH -u "$windows_path"` 39975 new_path="$unix_path" 39976 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39977 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39978 new_path="$unix_path" 39979 fi 39980 39981 # remove trailing .exe if any 39982 new_path="${new_path/%.exe/}" 39983 39984 # Save the first 10 bytes of this path to the storage, so fixpath can work. 39985 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 39986 fi 39987 39988 else 39989 # We're on a unix platform. Hooray! :) 39990 # First separate the path from the arguments. This will split at the first 39991 # space. 39992 complete="$STRIP" 39993 path="${complete%% *}" 39994 tmp="$complete EOL" 39995 arguments="${tmp#* }" 39996 39997 # Cannot rely on the command "which" here since it doesn't always work. 39998 is_absolute_path=`$ECHO "$path" | $GREP ^/` 39999 if test -z "$is_absolute_path"; then 40000 # Path to executable is not absolute. Find it. 40001 IFS_save="$IFS" 40002 IFS=: 40003 for p in $PATH; do 40004 if test -f "$p/$path" && test -x "$p/$path"; then 40005 new_path="$p/$path" 40006 break 40007 fi 40008 done 40009 IFS="$IFS_save" 40010 else 40011 # This is an absolute path, we can use it without further modifications. 40012 new_path="$path" 40013 fi 40014 40015 if test "x$new_path" = x; then 40016 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 40017 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 40018 has_space=`$ECHO "$complete" | $GREP " "` 40019 if test "x$has_space" != x; then 40020 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 40021 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 40022 fi 40023 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 40024 fi 40025 fi 40026 40027 # Now join together the path and the arguments once again 40028 if test "x$arguments" != xEOL; then 40029 new_complete="$new_path ${arguments% *}" 40030 else 40031 new_complete="$new_path" 40032 fi 40033 40034 if test "x$complete" != "x$new_complete"; then 40035 STRIP="$new_complete" 40036 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STRIP to \"$new_complete\"" >&5 40037 $as_echo "$as_me: Rewriting STRIP to \"$new_complete\"" >&6;} 40038 fi 40039 fi 40040 40041 40042 40043 # Publish this variable in the help. 40044 40045 40046 if [ -z "${NM+x}" ]; then 40047 # The variable is not set by user, try to locate tool using the code snippet 40048 for ac_prog in nm 40049 do 40050 # Extract the first word of "$ac_prog", so it can be a program name with args. 40051 set dummy $ac_prog; ac_word=$2 40052 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40053 $as_echo_n "checking for $ac_word... " >&6; } 40054 if ${ac_cv_path_NM+:} false; then : 40055 $as_echo_n "(cached) " >&6 40056 else 40057 case $NM in 40058 [\\/]* | ?:[\\/]*) 40059 ac_cv_path_NM="$NM" # Let the user override the test with a path. 40060 ;; 40061 *) 40062 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40063 for as_dir in $PATH 40064 do 40065 IFS=$as_save_IFS 40066 test -z "$as_dir" && as_dir=. 40067 for ac_exec_ext in '' $ac_executable_extensions; do 40068 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40069 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 40070 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40071 break 2 40072 fi 40073 done 40074 done 40075 IFS=$as_save_IFS 40076 40077 ;; 40078 esac 40079 fi 40080 NM=$ac_cv_path_NM 40081 if test -n "$NM"; then 40082 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 40083 $as_echo "$NM" >&6; } 40084 else 40085 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40086 $as_echo "no" >&6; } 40087 fi 40088 40089 40090 test -n "$NM" && break 40091 done 40092 40093 else 40094 # The variable is set, but is it from the command line or the environment? 40095 40096 # Try to remove the string !NM! from our list. 40097 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NM!/} 40098 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 40099 # If it failed, the variable was not from the command line. Ignore it, 40100 # but warn the user (except for BASH, which is always set by the calling BASH). 40101 if test "xNM" != xBASH; then 40102 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&5 40103 $as_echo "$as_me: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&2;} 40104 fi 40105 # Try to locate tool using the code snippet 40106 for ac_prog in nm 40107 do 40108 # Extract the first word of "$ac_prog", so it can be a program name with args. 40109 set dummy $ac_prog; ac_word=$2 40110 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40111 $as_echo_n "checking for $ac_word... " >&6; } 40112 if ${ac_cv_path_NM+:} false; then : 40113 $as_echo_n "(cached) " >&6 40114 else 40115 case $NM in 40116 [\\/]* | ?:[\\/]*) 40117 ac_cv_path_NM="$NM" # Let the user override the test with a path. 40118 ;; 40119 *) 40120 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40121 for as_dir in $PATH 40122 do 40123 IFS=$as_save_IFS 40124 test -z "$as_dir" && as_dir=. 40125 for ac_exec_ext in '' $ac_executable_extensions; do 40126 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40127 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 40128 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40129 break 2 40130 fi 40131 done 40132 done 40133 IFS=$as_save_IFS 40134 40135 ;; 40136 esac 40137 fi 40138 NM=$ac_cv_path_NM 40139 if test -n "$NM"; then 40140 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 40141 $as_echo "$NM" >&6; } 40142 else 40143 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40144 $as_echo "no" >&6; } 40145 fi 40146 40147 40148 test -n "$NM" && break 40149 done 40150 40151 else 40152 # If it succeeded, then it was overridden by the user. We will use it 40153 # for the tool. 40154 40155 # First remove it from the list of overridden variables, so we can test 40156 # for unknown variables in the end. 40157 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 40158 40159 # Check if we try to supply an empty value 40160 if test "x$NM" = x; then 40161 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool NM= (no value)" >&5 40162 $as_echo "$as_me: Setting user supplied tool NM= (no value)" >&6;} 40163 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 40164 $as_echo_n "checking for NM... " >&6; } 40165 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 40166 $as_echo "disabled" >&6; } 40167 else 40168 # Check if the provided tool contains a complete path. 40169 tool_specified="$NM" 40170 tool_basename="${tool_specified##*/}" 40171 if test "x$tool_basename" = "x$tool_specified"; then 40172 # A command without a complete path is provided, search $PATH. 40173 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NM=$tool_basename" >&5 40174 $as_echo "$as_me: Will search for user supplied tool NM=$tool_basename" >&6;} 40175 # Extract the first word of "$tool_basename", so it can be a program name with args. 40176 set dummy $tool_basename; ac_word=$2 40177 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40178 $as_echo_n "checking for $ac_word... " >&6; } 40179 if ${ac_cv_path_NM+:} false; then : 40180 $as_echo_n "(cached) " >&6 40181 else 40182 case $NM in 40183 [\\/]* | ?:[\\/]*) 40184 ac_cv_path_NM="$NM" # Let the user override the test with a path. 40185 ;; 40186 *) 40187 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40188 for as_dir in $PATH 40189 do 40190 IFS=$as_save_IFS 40191 test -z "$as_dir" && as_dir=. 40192 for ac_exec_ext in '' $ac_executable_extensions; do 40193 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40194 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 40195 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40196 break 2 40197 fi 40198 done 40199 done 40200 IFS=$as_save_IFS 40201 40202 ;; 40203 esac 40204 fi 40205 NM=$ac_cv_path_NM 40206 if test -n "$NM"; then 40207 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 40208 $as_echo "$NM" >&6; } 40209 else 40210 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40211 $as_echo "no" >&6; } 40212 fi 40213 40214 40215 if test "x$NM" = x; then 40216 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 40217 fi 40218 else 40219 # Otherwise we believe it is a complete path. Use it as it is. 40220 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NM=$tool_specified" >&5 40221 $as_echo "$as_me: Will use user supplied tool NM=$tool_specified" >&6;} 40222 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 40223 $as_echo_n "checking for NM... " >&6; } 40224 if test ! -x "$tool_specified"; then 40225 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 40226 $as_echo "not found" >&6; } 40227 as_fn_error $? "User supplied tool NM=$tool_specified does not exist or is not executable" "$LINENO" 5 40228 fi 40229 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 40230 $as_echo "$tool_specified" >&6; } 40231 fi 40232 fi 40233 fi 40234 40235 fi 40236 40237 40238 40239 # Only process if variable expands to non-empty 40240 40241 if test "x$NM" != x; then 40242 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40243 40244 # First separate the path from the arguments. This will split at the first 40245 # space. 40246 complete="$NM" 40247 path="${complete%% *}" 40248 tmp="$complete EOL" 40249 arguments="${tmp#* }" 40250 40251 # Input might be given as Windows format, start by converting to 40252 # unix format. 40253 new_path=`$CYGPATH -u "$path"` 40254 40255 # Now try to locate executable using which 40256 new_path=`$WHICH "$new_path" 2> /dev/null` 40257 # bat and cmd files are not always considered executable in cygwin causing which 40258 # to not find them 40259 if test "x$new_path" = x \ 40260 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40261 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40262 new_path=`$CYGPATH -u "$path"` 40263 fi 40264 if test "x$new_path" = x; then 40265 # Oops. Which didn't find the executable. 40266 # The splitting of arguments from the executable at a space might have been incorrect, 40267 # since paths with space are more likely in Windows. Give it another try with the whole 40268 # argument. 40269 path="$complete" 40270 arguments="EOL" 40271 new_path=`$CYGPATH -u "$path"` 40272 new_path=`$WHICH "$new_path" 2> /dev/null` 40273 # bat and cmd files are not always considered executable in cygwin causing which 40274 # to not find them 40275 if test "x$new_path" = x \ 40276 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40277 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40278 new_path=`$CYGPATH -u "$path"` 40279 fi 40280 if test "x$new_path" = x; then 40281 # It's still not found. Now this is an unrecoverable error. 40282 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 40283 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 40284 has_space=`$ECHO "$complete" | $GREP " "` 40285 if test "x$has_space" != x; then 40286 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 40287 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 40288 fi 40289 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 40290 fi 40291 fi 40292 40293 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 40294 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 40295 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 40296 # "foo.exe" is OK but "foo" is an error. 40297 # 40298 # This test is therefore slightly more accurate than "test -f" to check for file presence. 40299 # It is also a way to make sure we got the proper file name for the real test later on. 40300 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 40301 if test "x$test_shortpath" = x; then 40302 # Short path failed, file does not exist as specified. 40303 # Try adding .exe or .cmd 40304 if test -f "${new_path}.exe"; then 40305 input_to_shortpath="${new_path}.exe" 40306 elif test -f "${new_path}.cmd"; then 40307 input_to_shortpath="${new_path}.cmd" 40308 else 40309 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$new_path\", is invalid." >&5 40310 $as_echo "$as_me: The path of NM, which resolves as \"$new_path\", is invalid." >&6;} 40311 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 40312 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 40313 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 40314 fi 40315 else 40316 input_to_shortpath="$new_path" 40317 fi 40318 40319 # Call helper function which possibly converts this using DOS-style short mode. 40320 # If so, the updated path is stored in $new_path. 40321 new_path="$input_to_shortpath" 40322 40323 input_path="$input_to_shortpath" 40324 # Check if we need to convert this using DOS-style short mode. If the path 40325 # contains just simple characters, use it. Otherwise (spaces, weird characters), 40326 # take no chances and rewrite it. 40327 # Note: m4 eats our [], so we need to use [ and ] instead. 40328 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 40329 if test "x$has_forbidden_chars" != x; then 40330 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 40331 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 40332 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 40333 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 40334 # Going to short mode and back again did indeed matter. Since short mode is 40335 # case insensitive, let's make it lowercase to improve readability. 40336 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 40337 # Now convert it back to Unix-style (cygpath) 40338 input_path=`$CYGPATH -u "$shortmode_path"` 40339 new_path="$input_path" 40340 fi 40341 fi 40342 40343 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 40344 if test "x$test_cygdrive_prefix" = x; then 40345 # As a simple fix, exclude /usr/bin since it's not a real path. 40346 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 40347 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 40348 # a path prefixed by /cygdrive for fixpath to work. 40349 new_path="$CYGWIN_ROOT_PATH$input_path" 40350 fi 40351 fi 40352 40353 # remove trailing .exe if any 40354 new_path="${new_path/%.exe/}" 40355 40356 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40357 40358 # First separate the path from the arguments. This will split at the first 40359 # space. 40360 complete="$NM" 40361 path="${complete%% *}" 40362 tmp="$complete EOL" 40363 arguments="${tmp#* }" 40364 40365 # Input might be given as Windows format, start by converting to 40366 # unix format. 40367 new_path="$path" 40368 40369 windows_path="$new_path" 40370 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40371 unix_path=`$CYGPATH -u "$windows_path"` 40372 new_path="$unix_path" 40373 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40374 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40375 new_path="$unix_path" 40376 fi 40377 40378 40379 # Now try to locate executable using which 40380 new_path=`$WHICH "$new_path" 2> /dev/null` 40381 40382 if test "x$new_path" = x; then 40383 # Oops. Which didn't find the executable. 40384 # The splitting of arguments from the executable at a space might have been incorrect, 40385 # since paths with space are more likely in Windows. Give it another try with the whole 40386 # argument. 40387 path="$complete" 40388 arguments="EOL" 40389 new_path="$path" 40390 40391 windows_path="$new_path" 40392 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40393 unix_path=`$CYGPATH -u "$windows_path"` 40394 new_path="$unix_path" 40395 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40396 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40397 new_path="$unix_path" 40398 fi 40399 40400 40401 new_path=`$WHICH "$new_path" 2> /dev/null` 40402 # bat and cmd files are not always considered executable in MSYS causing which 40403 # to not find them 40404 if test "x$new_path" = x \ 40405 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40406 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40407 new_path="$path" 40408 40409 windows_path="$new_path" 40410 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40411 unix_path=`$CYGPATH -u "$windows_path"` 40412 new_path="$unix_path" 40413 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40414 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40415 new_path="$unix_path" 40416 fi 40417 40418 fi 40419 40420 if test "x$new_path" = x; then 40421 # It's still not found. Now this is an unrecoverable error. 40422 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 40423 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 40424 has_space=`$ECHO "$complete" | $GREP " "` 40425 if test "x$has_space" != x; then 40426 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 40427 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 40428 fi 40429 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 40430 fi 40431 fi 40432 40433 # Now new_path has a complete unix path to the binary 40434 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 40435 # Keep paths in /bin as-is, but remove trailing .exe if any 40436 new_path="${new_path/%.exe/}" 40437 # Do not save /bin paths to all_fixpath_prefixes! 40438 else 40439 # Not in mixed or Windows style, start by that. 40440 new_path=`cmd //c echo $new_path` 40441 40442 input_path="$new_path" 40443 # Check if we need to convert this using DOS-style short mode. If the path 40444 # contains just simple characters, use it. Otherwise (spaces, weird characters), 40445 # take no chances and rewrite it. 40446 # Note: m4 eats our [], so we need to use [ and ] instead. 40447 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 40448 if test "x$has_forbidden_chars" != x; then 40449 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 40450 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 40451 fi 40452 40453 # Output is in $new_path 40454 40455 windows_path="$new_path" 40456 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40457 unix_path=`$CYGPATH -u "$windows_path"` 40458 new_path="$unix_path" 40459 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40460 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40461 new_path="$unix_path" 40462 fi 40463 40464 # remove trailing .exe if any 40465 new_path="${new_path/%.exe/}" 40466 40467 # Save the first 10 bytes of this path to the storage, so fixpath can work. 40468 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 40469 fi 40470 40471 else 40472 # We're on a unix platform. Hooray! :) 40473 # First separate the path from the arguments. This will split at the first 40474 # space. 40475 complete="$NM" 40476 path="${complete%% *}" 40477 tmp="$complete EOL" 40478 arguments="${tmp#* }" 40479 40480 # Cannot rely on the command "which" here since it doesn't always work. 40481 is_absolute_path=`$ECHO "$path" | $GREP ^/` 40482 if test -z "$is_absolute_path"; then 40483 # Path to executable is not absolute. Find it. 40484 IFS_save="$IFS" 40485 IFS=: 40486 for p in $PATH; do 40487 if test -f "$p/$path" && test -x "$p/$path"; then 40488 new_path="$p/$path" 40489 break 40490 fi 40491 done 40492 IFS="$IFS_save" 40493 else 40494 # This is an absolute path, we can use it without further modifications. 40495 new_path="$path" 40496 fi 40497 40498 if test "x$new_path" = x; then 40499 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 40500 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 40501 has_space=`$ECHO "$complete" | $GREP " "` 40502 if test "x$has_space" != x; then 40503 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 40504 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 40505 fi 40506 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 40507 fi 40508 fi 40509 40510 # Now join together the path and the arguments once again 40511 if test "x$arguments" != xEOL; then 40512 new_complete="$new_path ${arguments% *}" 40513 else 40514 new_complete="$new_path" 40515 fi 40516 40517 if test "x$complete" != "x$new_complete"; then 40518 NM="$new_complete" 40519 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting NM to \"$new_complete\"" >&5 40520 $as_echo "$as_me: Rewriting NM to \"$new_complete\"" >&6;} 40521 fi 40522 fi 40523 40524 40525 40526 # Publish this variable in the help. 40527 40528 40529 if [ -z "${GNM+x}" ]; then 40530 # The variable is not set by user, try to locate tool using the code snippet 40531 for ac_prog in gnm 40532 do 40533 # Extract the first word of "$ac_prog", so it can be a program name with args. 40534 set dummy $ac_prog; ac_word=$2 40535 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40536 $as_echo_n "checking for $ac_word... " >&6; } 40537 if ${ac_cv_path_GNM+:} false; then : 40538 $as_echo_n "(cached) " >&6 40539 else 40540 case $GNM in 40541 [\\/]* | ?:[\\/]*) 40542 ac_cv_path_GNM="$GNM" # Let the user override the test with a path. 40543 ;; 40544 *) 40545 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40546 for as_dir in $PATH 40547 do 40548 IFS=$as_save_IFS 40549 test -z "$as_dir" && as_dir=. 40550 for ac_exec_ext in '' $ac_executable_extensions; do 40551 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40552 ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext" 40553 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40554 break 2 40555 fi 40556 done 40557 done 40558 IFS=$as_save_IFS 40559 40560 ;; 40561 esac 40562 fi 40563 GNM=$ac_cv_path_GNM 40564 if test -n "$GNM"; then 40565 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5 40566 $as_echo "$GNM" >&6; } 40567 else 40568 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40569 $as_echo "no" >&6; } 40570 fi 40571 40572 40573 test -n "$GNM" && break 40574 done 40575 40576 else 40577 # The variable is set, but is it from the command line or the environment? 40578 40579 # Try to remove the string !GNM! from our list. 40580 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!GNM!/} 40581 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 40582 # If it failed, the variable was not from the command line. Ignore it, 40583 # but warn the user (except for BASH, which is always set by the calling BASH). 40584 if test "xGNM" != xBASH; then 40585 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of GNM from the environment. Use command line variables instead." >&5 40586 $as_echo "$as_me: WARNING: Ignoring value of GNM from the environment. Use command line variables instead." >&2;} 40587 fi 40588 # Try to locate tool using the code snippet 40589 for ac_prog in gnm 40590 do 40591 # Extract the first word of "$ac_prog", so it can be a program name with args. 40592 set dummy $ac_prog; ac_word=$2 40593 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40594 $as_echo_n "checking for $ac_word... " >&6; } 40595 if ${ac_cv_path_GNM+:} false; then : 40596 $as_echo_n "(cached) " >&6 40597 else 40598 case $GNM in 40599 [\\/]* | ?:[\\/]*) 40600 ac_cv_path_GNM="$GNM" # Let the user override the test with a path. 40601 ;; 40602 *) 40603 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40604 for as_dir in $PATH 40605 do 40606 IFS=$as_save_IFS 40607 test -z "$as_dir" && as_dir=. 40608 for ac_exec_ext in '' $ac_executable_extensions; do 40609 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40610 ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext" 40611 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40612 break 2 40613 fi 40614 done 40615 done 40616 IFS=$as_save_IFS 40617 40618 ;; 40619 esac 40620 fi 40621 GNM=$ac_cv_path_GNM 40622 if test -n "$GNM"; then 40623 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5 40624 $as_echo "$GNM" >&6; } 40625 else 40626 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40627 $as_echo "no" >&6; } 40628 fi 40629 40630 40631 test -n "$GNM" && break 40632 done 40633 40634 else 40635 # If it succeeded, then it was overridden by the user. We will use it 40636 # for the tool. 40637 40638 # First remove it from the list of overridden variables, so we can test 40639 # for unknown variables in the end. 40640 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 40641 40642 # Check if we try to supply an empty value 40643 if test "x$GNM" = x; then 40644 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool GNM= (no value)" >&5 40645 $as_echo "$as_me: Setting user supplied tool GNM= (no value)" >&6;} 40646 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNM" >&5 40647 $as_echo_n "checking for GNM... " >&6; } 40648 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 40649 $as_echo "disabled" >&6; } 40650 else 40651 # Check if the provided tool contains a complete path. 40652 tool_specified="$GNM" 40653 tool_basename="${tool_specified##*/}" 40654 if test "x$tool_basename" = "x$tool_specified"; then 40655 # A command without a complete path is provided, search $PATH. 40656 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool GNM=$tool_basename" >&5 40657 $as_echo "$as_me: Will search for user supplied tool GNM=$tool_basename" >&6;} 40658 # Extract the first word of "$tool_basename", so it can be a program name with args. 40659 set dummy $tool_basename; ac_word=$2 40660 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40661 $as_echo_n "checking for $ac_word... " >&6; } 40662 if ${ac_cv_path_GNM+:} false; then : 40663 $as_echo_n "(cached) " >&6 40664 else 40665 case $GNM in 40666 [\\/]* | ?:[\\/]*) 40667 ac_cv_path_GNM="$GNM" # Let the user override the test with a path. 40668 ;; 40669 *) 40670 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40671 for as_dir in $PATH 40672 do 40673 IFS=$as_save_IFS 40674 test -z "$as_dir" && as_dir=. 40675 for ac_exec_ext in '' $ac_executable_extensions; do 40676 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40677 ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext" 40678 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40679 break 2 40680 fi 40681 done 40682 done 40683 IFS=$as_save_IFS 40684 40685 ;; 40686 esac 40687 fi 40688 GNM=$ac_cv_path_GNM 40689 if test -n "$GNM"; then 40690 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5 40691 $as_echo "$GNM" >&6; } 40692 else 40693 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40694 $as_echo "no" >&6; } 40695 fi 40696 40697 40698 if test "x$GNM" = x; then 40699 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 40700 fi 40701 else 40702 # Otherwise we believe it is a complete path. Use it as it is. 40703 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool GNM=$tool_specified" >&5 40704 $as_echo "$as_me: Will use user supplied tool GNM=$tool_specified" >&6;} 40705 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNM" >&5 40706 $as_echo_n "checking for GNM... " >&6; } 40707 if test ! -x "$tool_specified"; then 40708 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 40709 $as_echo "not found" >&6; } 40710 as_fn_error $? "User supplied tool GNM=$tool_specified does not exist or is not executable" "$LINENO" 5 40711 fi 40712 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 40713 $as_echo "$tool_specified" >&6; } 40714 fi 40715 fi 40716 fi 40717 40718 fi 40719 40720 40721 40722 # Only process if variable expands to non-empty 40723 40724 if test "x$GNM" != x; then 40725 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40726 40727 # First separate the path from the arguments. This will split at the first 40728 # space. 40729 complete="$GNM" 40730 path="${complete%% *}" 40731 tmp="$complete EOL" 40732 arguments="${tmp#* }" 40733 40734 # Input might be given as Windows format, start by converting to 40735 # unix format. 40736 new_path=`$CYGPATH -u "$path"` 40737 40738 # Now try to locate executable using which 40739 new_path=`$WHICH "$new_path" 2> /dev/null` 40740 # bat and cmd files are not always considered executable in cygwin causing which 40741 # to not find them 40742 if test "x$new_path" = x \ 40743 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40744 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40745 new_path=`$CYGPATH -u "$path"` 40746 fi 40747 if test "x$new_path" = x; then 40748 # Oops. Which didn't find the executable. 40749 # The splitting of arguments from the executable at a space might have been incorrect, 40750 # since paths with space are more likely in Windows. Give it another try with the whole 40751 # argument. 40752 path="$complete" 40753 arguments="EOL" 40754 new_path=`$CYGPATH -u "$path"` 40755 new_path=`$WHICH "$new_path" 2> /dev/null` 40756 # bat and cmd files are not always considered executable in cygwin causing which 40757 # to not find them 40758 if test "x$new_path" = x \ 40759 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40760 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40761 new_path=`$CYGPATH -u "$path"` 40762 fi 40763 if test "x$new_path" = x; then 40764 # It's still not found. Now this is an unrecoverable error. 40765 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5 40766 $as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;} 40767 has_space=`$ECHO "$complete" | $GREP " "` 40768 if test "x$has_space" != x; then 40769 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 40770 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 40771 fi 40772 as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5 40773 fi 40774 fi 40775 40776 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 40777 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 40778 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 40779 # "foo.exe" is OK but "foo" is an error. 40780 # 40781 # This test is therefore slightly more accurate than "test -f" to check for file presence. 40782 # It is also a way to make sure we got the proper file name for the real test later on. 40783 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 40784 if test "x$test_shortpath" = x; then 40785 # Short path failed, file does not exist as specified. 40786 # Try adding .exe or .cmd 40787 if test -f "${new_path}.exe"; then 40788 input_to_shortpath="${new_path}.exe" 40789 elif test -f "${new_path}.cmd"; then 40790 input_to_shortpath="${new_path}.cmd" 40791 else 40792 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$new_path\", is invalid." >&5 40793 $as_echo "$as_me: The path of GNM, which resolves as \"$new_path\", is invalid." >&6;} 40794 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 40795 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 40796 as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5 40797 fi 40798 else 40799 input_to_shortpath="$new_path" 40800 fi 40801 40802 # Call helper function which possibly converts this using DOS-style short mode. 40803 # If so, the updated path is stored in $new_path. 40804 new_path="$input_to_shortpath" 40805 40806 input_path="$input_to_shortpath" 40807 # Check if we need to convert this using DOS-style short mode. If the path 40808 # contains just simple characters, use it. Otherwise (spaces, weird characters), 40809 # take no chances and rewrite it. 40810 # Note: m4 eats our [], so we need to use [ and ] instead. 40811 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 40812 if test "x$has_forbidden_chars" != x; then 40813 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 40814 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 40815 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 40816 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 40817 # Going to short mode and back again did indeed matter. Since short mode is 40818 # case insensitive, let's make it lowercase to improve readability. 40819 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 40820 # Now convert it back to Unix-style (cygpath) 40821 input_path=`$CYGPATH -u "$shortmode_path"` 40822 new_path="$input_path" 40823 fi 40824 fi 40825 40826 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 40827 if test "x$test_cygdrive_prefix" = x; then 40828 # As a simple fix, exclude /usr/bin since it's not a real path. 40829 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 40830 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 40831 # a path prefixed by /cygdrive for fixpath to work. 40832 new_path="$CYGWIN_ROOT_PATH$input_path" 40833 fi 40834 fi 40835 40836 # remove trailing .exe if any 40837 new_path="${new_path/%.exe/}" 40838 40839 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40840 40841 # First separate the path from the arguments. This will split at the first 40842 # space. 40843 complete="$GNM" 40844 path="${complete%% *}" 40845 tmp="$complete EOL" 40846 arguments="${tmp#* }" 40847 40848 # Input might be given as Windows format, start by converting to 40849 # unix format. 40850 new_path="$path" 40851 40852 windows_path="$new_path" 40853 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40854 unix_path=`$CYGPATH -u "$windows_path"` 40855 new_path="$unix_path" 40856 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40857 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40858 new_path="$unix_path" 40859 fi 40860 40861 40862 # Now try to locate executable using which 40863 new_path=`$WHICH "$new_path" 2> /dev/null` 40864 40865 if test "x$new_path" = x; then 40866 # Oops. Which didn't find the executable. 40867 # The splitting of arguments from the executable at a space might have been incorrect, 40868 # since paths with space are more likely in Windows. Give it another try with the whole 40869 # argument. 40870 path="$complete" 40871 arguments="EOL" 40872 new_path="$path" 40873 40874 windows_path="$new_path" 40875 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40876 unix_path=`$CYGPATH -u "$windows_path"` 40877 new_path="$unix_path" 40878 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40879 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40880 new_path="$unix_path" 40881 fi 40882 40883 40884 new_path=`$WHICH "$new_path" 2> /dev/null` 40885 # bat and cmd files are not always considered executable in MSYS causing which 40886 # to not find them 40887 if test "x$new_path" = x \ 40888 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40889 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40890 new_path="$path" 40891 40892 windows_path="$new_path" 40893 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40894 unix_path=`$CYGPATH -u "$windows_path"` 40895 new_path="$unix_path" 40896 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40897 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40898 new_path="$unix_path" 40899 fi 40900 40901 fi 40902 40903 if test "x$new_path" = x; then 40904 # It's still not found. Now this is an unrecoverable error. 40905 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5 40906 $as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;} 40907 has_space=`$ECHO "$complete" | $GREP " "` 40908 if test "x$has_space" != x; then 40909 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 40910 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 40911 fi 40912 as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5 40913 fi 40914 fi 40915 40916 # Now new_path has a complete unix path to the binary 40917 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 40918 # Keep paths in /bin as-is, but remove trailing .exe if any 40919 new_path="${new_path/%.exe/}" 40920 # Do not save /bin paths to all_fixpath_prefixes! 40921 else 40922 # Not in mixed or Windows style, start by that. 40923 new_path=`cmd //c echo $new_path` 40924 40925 input_path="$new_path" 40926 # Check if we need to convert this using DOS-style short mode. If the path 40927 # contains just simple characters, use it. Otherwise (spaces, weird characters), 40928 # take no chances and rewrite it. 40929 # Note: m4 eats our [], so we need to use [ and ] instead. 40930 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 40931 if test "x$has_forbidden_chars" != x; then 40932 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 40933 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 40934 fi 40935 40936 # Output is in $new_path 40937 40938 windows_path="$new_path" 40939 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40940 unix_path=`$CYGPATH -u "$windows_path"` 40941 new_path="$unix_path" 40942 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40943 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40944 new_path="$unix_path" 40945 fi 40946 40947 # remove trailing .exe if any 40948 new_path="${new_path/%.exe/}" 40949 40950 # Save the first 10 bytes of this path to the storage, so fixpath can work. 40951 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 40952 fi 40953 40954 else 40955 # We're on a unix platform. Hooray! :) 40956 # First separate the path from the arguments. This will split at the first 40957 # space. 40958 complete="$GNM" 40959 path="${complete%% *}" 40960 tmp="$complete EOL" 40961 arguments="${tmp#* }" 40962 40963 # Cannot rely on the command "which" here since it doesn't always work. 40964 is_absolute_path=`$ECHO "$path" | $GREP ^/` 40965 if test -z "$is_absolute_path"; then 40966 # Path to executable is not absolute. Find it. 40967 IFS_save="$IFS" 40968 IFS=: 40969 for p in $PATH; do 40970 if test -f "$p/$path" && test -x "$p/$path"; then 40971 new_path="$p/$path" 40972 break 40973 fi 40974 done 40975 IFS="$IFS_save" 40976 else 40977 # This is an absolute path, we can use it without further modifications. 40978 new_path="$path" 40979 fi 40980 40981 if test "x$new_path" = x; then 40982 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5 40983 $as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;} 40984 has_space=`$ECHO "$complete" | $GREP " "` 40985 if test "x$has_space" != x; then 40986 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 40987 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 40988 fi 40989 as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5 40990 fi 40991 fi 40992 40993 # Now join together the path and the arguments once again 40994 if test "x$arguments" != xEOL; then 40995 new_complete="$new_path ${arguments% *}" 40996 else 40997 new_complete="$new_path" 40998 fi 40999 41000 if test "x$complete" != "x$new_complete"; then 41001 GNM="$new_complete" 41002 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting GNM to \"$new_complete\"" >&5 41003 $as_echo "$as_me: Rewriting GNM to \"$new_complete\"" >&6;} 41004 fi 41005 fi 41006 41007 elif test "x$OPENJDK_TARGET_OS" != xwindows; then 41008 # FIXME: we should unify this with the solaris case above. 41009 41010 41011 # Publish this variable in the help. 41012 41013 41014 if [ -z "${STRIP+x}" ]; then 41015 # The variable is not set by user, try to locate tool using the code snippet 41016 if test -n "$ac_tool_prefix"; then 41017 for ac_prog in strip 41018 do 41019 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 41020 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 41021 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41022 $as_echo_n "checking for $ac_word... " >&6; } 41023 if ${ac_cv_prog_STRIP+:} false; then : 41024 $as_echo_n "(cached) " >&6 41025 else 41026 if test -n "$STRIP"; then 41027 ac_cv_prog_STRIP="$STRIP" # Let the user override the test. 41028 else 41029 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41030 for as_dir in $PATH 41031 do 41032 IFS=$as_save_IFS 41033 test -z "$as_dir" && as_dir=. 41034 for ac_exec_ext in '' $ac_executable_extensions; do 41035 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41036 ac_cv_prog_STRIP="$ac_tool_prefix$ac_prog" 41037 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41038 break 2 41039 fi 41040 done 41041 done 41042 IFS=$as_save_IFS 41043 41044 fi 41045 fi 41046 STRIP=$ac_cv_prog_STRIP 41047 if test -n "$STRIP"; then 41048 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 41049 $as_echo "$STRIP" >&6; } 41050 else 41051 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41052 $as_echo "no" >&6; } 41053 fi 41054 41055 41056 test -n "$STRIP" && break 41057 done 41058 fi 41059 if test -z "$STRIP"; then 41060 ac_ct_STRIP=$STRIP 41061 for ac_prog in strip 41062 do 41063 # Extract the first word of "$ac_prog", so it can be a program name with args. 41064 set dummy $ac_prog; ac_word=$2 41065 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41066 $as_echo_n "checking for $ac_word... " >&6; } 41067 if ${ac_cv_prog_ac_ct_STRIP+:} false; then : 41068 $as_echo_n "(cached) " >&6 41069 else 41070 if test -n "$ac_ct_STRIP"; then 41071 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. 41072 else 41073 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41074 for as_dir in $PATH 41075 do 41076 IFS=$as_save_IFS 41077 test -z "$as_dir" && as_dir=. 41078 for ac_exec_ext in '' $ac_executable_extensions; do 41079 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41080 ac_cv_prog_ac_ct_STRIP="$ac_prog" 41081 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41082 break 2 41083 fi 41084 done 41085 done 41086 IFS=$as_save_IFS 41087 41088 fi 41089 fi 41090 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP 41091 if test -n "$ac_ct_STRIP"; then 41092 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 41093 $as_echo "$ac_ct_STRIP" >&6; } 41094 else 41095 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41096 $as_echo "no" >&6; } 41097 fi 41098 41099 41100 test -n "$ac_ct_STRIP" && break 41101 done 41102 41103 if test "x$ac_ct_STRIP" = x; then 41104 STRIP="" 41105 else 41106 case $cross_compiling:$ac_tool_warned in 41107 yes:) 41108 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 41109 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 41110 ac_tool_warned=yes ;; 41111 esac 41112 STRIP=$ac_ct_STRIP 41113 fi 41114 fi 41115 41116 else 41117 # The variable is set, but is it from the command line or the environment? 41118 41119 # Try to remove the string !STRIP! from our list. 41120 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!STRIP!/} 41121 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 41122 # If it failed, the variable was not from the command line. Ignore it, 41123 # but warn the user (except for BASH, which is always set by the calling BASH). 41124 if test "xSTRIP" != xBASH; then 41125 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&5 41126 $as_echo "$as_me: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&2;} 41127 fi 41128 # Try to locate tool using the code snippet 41129 if test -n "$ac_tool_prefix"; then 41130 for ac_prog in strip 41131 do 41132 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 41133 set dummy $ac_tool_prefix$ac_prog; 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_prog_STRIP+:} false; then : 41137 $as_echo_n "(cached) " >&6 41138 else 41139 if test -n "$STRIP"; then 41140 ac_cv_prog_STRIP="$STRIP" # Let the user override the test. 41141 else 41142 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41143 for as_dir in $PATH 41144 do 41145 IFS=$as_save_IFS 41146 test -z "$as_dir" && as_dir=. 41147 for ac_exec_ext in '' $ac_executable_extensions; do 41148 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41149 ac_cv_prog_STRIP="$ac_tool_prefix$ac_prog" 41150 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41151 break 2 41152 fi 41153 done 41154 done 41155 IFS=$as_save_IFS 41156 41157 fi 41158 fi 41159 STRIP=$ac_cv_prog_STRIP 41160 if test -n "$STRIP"; then 41161 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 41162 $as_echo "$STRIP" >&6; } 41163 else 41164 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41165 $as_echo "no" >&6; } 41166 fi 41167 41168 41169 test -n "$STRIP" && break 41170 done 41171 fi 41172 if test -z "$STRIP"; then 41173 ac_ct_STRIP=$STRIP 41174 for ac_prog in strip 41175 do 41176 # Extract the first word of "$ac_prog", so it can be a program name with args. 41177 set dummy $ac_prog; ac_word=$2 41178 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41179 $as_echo_n "checking for $ac_word... " >&6; } 41180 if ${ac_cv_prog_ac_ct_STRIP+:} false; then : 41181 $as_echo_n "(cached) " >&6 41182 else 41183 if test -n "$ac_ct_STRIP"; then 41184 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. 41185 else 41186 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41187 for as_dir in $PATH 41188 do 41189 IFS=$as_save_IFS 41190 test -z "$as_dir" && as_dir=. 41191 for ac_exec_ext in '' $ac_executable_extensions; do 41192 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41193 ac_cv_prog_ac_ct_STRIP="$ac_prog" 41194 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41195 break 2 41196 fi 41197 done 41198 done 41199 IFS=$as_save_IFS 41200 41201 fi 41202 fi 41203 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP 41204 if test -n "$ac_ct_STRIP"; then 41205 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 41206 $as_echo "$ac_ct_STRIP" >&6; } 41207 else 41208 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41209 $as_echo "no" >&6; } 41210 fi 41211 41212 41213 test -n "$ac_ct_STRIP" && break 41214 done 41215 41216 if test "x$ac_ct_STRIP" = x; then 41217 STRIP="" 41218 else 41219 case $cross_compiling:$ac_tool_warned in 41220 yes:) 41221 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 41222 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 41223 ac_tool_warned=yes ;; 41224 esac 41225 STRIP=$ac_ct_STRIP 41226 fi 41227 fi 41228 41229 else 41230 # If it succeeded, then it was overridden by the user. We will use it 41231 # for the tool. 41232 41233 # First remove it from the list of overridden variables, so we can test 41234 # for unknown variables in the end. 41235 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 41236 41237 # Check if we try to supply an empty value 41238 if test "x$STRIP" = x; then 41239 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool STRIP= (no value)" >&5 41240 $as_echo "$as_me: Setting user supplied tool STRIP= (no value)" >&6;} 41241 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5 41242 $as_echo_n "checking for STRIP... " >&6; } 41243 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 41244 $as_echo "disabled" >&6; } 41245 else 41246 # Check if the provided tool contains a complete path. 41247 tool_specified="$STRIP" 41248 tool_basename="${tool_specified##*/}" 41249 if test "x$tool_basename" = "x$tool_specified"; then 41250 # A command without a complete path is provided, search $PATH. 41251 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool STRIP=$tool_basename" >&5 41252 $as_echo "$as_me: Will search for user supplied tool STRIP=$tool_basename" >&6;} 41253 # Extract the first word of "$tool_basename", so it can be a program name with args. 41254 set dummy $tool_basename; ac_word=$2 41255 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41256 $as_echo_n "checking for $ac_word... " >&6; } 41257 if ${ac_cv_path_STRIP+:} false; then : 41258 $as_echo_n "(cached) " >&6 41259 else 41260 case $STRIP in 41261 [\\/]* | ?:[\\/]*) 41262 ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path. 41263 ;; 41264 *) 41265 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41266 for as_dir in $PATH 41267 do 41268 IFS=$as_save_IFS 41269 test -z "$as_dir" && as_dir=. 41270 for ac_exec_ext in '' $ac_executable_extensions; do 41271 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41272 ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext" 41273 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41274 break 2 41275 fi 41276 done 41277 done 41278 IFS=$as_save_IFS 41279 41280 ;; 41281 esac 41282 fi 41283 STRIP=$ac_cv_path_STRIP 41284 if test -n "$STRIP"; then 41285 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 41286 $as_echo "$STRIP" >&6; } 41287 else 41288 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41289 $as_echo "no" >&6; } 41290 fi 41291 41292 41293 if test "x$STRIP" = x; then 41294 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 41295 fi 41296 else 41297 # Otherwise we believe it is a complete path. Use it as it is. 41298 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool STRIP=$tool_specified" >&5 41299 $as_echo "$as_me: Will use user supplied tool STRIP=$tool_specified" >&6;} 41300 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5 41301 $as_echo_n "checking for STRIP... " >&6; } 41302 if test ! -x "$tool_specified"; then 41303 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 41304 $as_echo "not found" >&6; } 41305 as_fn_error $? "User supplied tool STRIP=$tool_specified does not exist or is not executable" "$LINENO" 5 41306 fi 41307 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 41308 $as_echo "$tool_specified" >&6; } 41309 fi 41310 fi 41311 fi 41312 41313 fi 41314 41315 41316 41317 # Only process if variable expands to non-empty 41318 41319 if test "x$STRIP" != x; then 41320 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41321 41322 # First separate the path from the arguments. This will split at the first 41323 # space. 41324 complete="$STRIP" 41325 path="${complete%% *}" 41326 tmp="$complete EOL" 41327 arguments="${tmp#* }" 41328 41329 # Input might be given as Windows format, start by converting to 41330 # unix format. 41331 new_path=`$CYGPATH -u "$path"` 41332 41333 # Now try to locate executable using which 41334 new_path=`$WHICH "$new_path" 2> /dev/null` 41335 # bat and cmd files are not always considered executable in cygwin causing which 41336 # to not find them 41337 if test "x$new_path" = x \ 41338 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 41339 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 41340 new_path=`$CYGPATH -u "$path"` 41341 fi 41342 if test "x$new_path" = x; then 41343 # Oops. Which didn't find the executable. 41344 # The splitting of arguments from the executable at a space might have been incorrect, 41345 # since paths with space are more likely in Windows. Give it another try with the whole 41346 # argument. 41347 path="$complete" 41348 arguments="EOL" 41349 new_path=`$CYGPATH -u "$path"` 41350 new_path=`$WHICH "$new_path" 2> /dev/null` 41351 # bat and cmd files are not always considered executable in cygwin causing which 41352 # to not find them 41353 if test "x$new_path" = x \ 41354 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 41355 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 41356 new_path=`$CYGPATH -u "$path"` 41357 fi 41358 if test "x$new_path" = x; then 41359 # It's still not found. Now this is an unrecoverable error. 41360 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 41361 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 41362 has_space=`$ECHO "$complete" | $GREP " "` 41363 if test "x$has_space" != x; then 41364 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 41365 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 41366 fi 41367 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 41368 fi 41369 fi 41370 41371 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 41372 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 41373 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 41374 # "foo.exe" is OK but "foo" is an error. 41375 # 41376 # This test is therefore slightly more accurate than "test -f" to check for file presence. 41377 # It is also a way to make sure we got the proper file name for the real test later on. 41378 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 41379 if test "x$test_shortpath" = x; then 41380 # Short path failed, file does not exist as specified. 41381 # Try adding .exe or .cmd 41382 if test -f "${new_path}.exe"; then 41383 input_to_shortpath="${new_path}.exe" 41384 elif test -f "${new_path}.cmd"; then 41385 input_to_shortpath="${new_path}.cmd" 41386 else 41387 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$new_path\", is invalid." >&5 41388 $as_echo "$as_me: The path of STRIP, which resolves as \"$new_path\", is invalid." >&6;} 41389 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 41390 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 41391 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 41392 fi 41393 else 41394 input_to_shortpath="$new_path" 41395 fi 41396 41397 # Call helper function which possibly converts this using DOS-style short mode. 41398 # If so, the updated path is stored in $new_path. 41399 new_path="$input_to_shortpath" 41400 41401 input_path="$input_to_shortpath" 41402 # Check if we need to convert this using DOS-style short mode. If the path 41403 # contains just simple characters, use it. Otherwise (spaces, weird characters), 41404 # take no chances and rewrite it. 41405 # Note: m4 eats our [], so we need to use [ and ] instead. 41406 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 41407 if test "x$has_forbidden_chars" != x; then 41408 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 41409 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 41410 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 41411 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 41412 # Going to short mode and back again did indeed matter. Since short mode is 41413 # case insensitive, let's make it lowercase to improve readability. 41414 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 41415 # Now convert it back to Unix-style (cygpath) 41416 input_path=`$CYGPATH -u "$shortmode_path"` 41417 new_path="$input_path" 41418 fi 41419 fi 41420 41421 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 41422 if test "x$test_cygdrive_prefix" = x; then 41423 # As a simple fix, exclude /usr/bin since it's not a real path. 41424 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 41425 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 41426 # a path prefixed by /cygdrive for fixpath to work. 41427 new_path="$CYGWIN_ROOT_PATH$input_path" 41428 fi 41429 fi 41430 41431 # remove trailing .exe if any 41432 new_path="${new_path/%.exe/}" 41433 41434 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41435 41436 # First separate the path from the arguments. This will split at the first 41437 # space. 41438 complete="$STRIP" 41439 path="${complete%% *}" 41440 tmp="$complete EOL" 41441 arguments="${tmp#* }" 41442 41443 # Input might be given as Windows format, start by converting to 41444 # unix format. 41445 new_path="$path" 41446 41447 windows_path="$new_path" 41448 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41449 unix_path=`$CYGPATH -u "$windows_path"` 41450 new_path="$unix_path" 41451 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41452 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41453 new_path="$unix_path" 41454 fi 41455 41456 41457 # Now try to locate executable using which 41458 new_path=`$WHICH "$new_path" 2> /dev/null` 41459 41460 if test "x$new_path" = x; then 41461 # Oops. Which didn't find the executable. 41462 # The splitting of arguments from the executable at a space might have been incorrect, 41463 # since paths with space are more likely in Windows. Give it another try with the whole 41464 # argument. 41465 path="$complete" 41466 arguments="EOL" 41467 new_path="$path" 41468 41469 windows_path="$new_path" 41470 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41471 unix_path=`$CYGPATH -u "$windows_path"` 41472 new_path="$unix_path" 41473 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41474 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41475 new_path="$unix_path" 41476 fi 41477 41478 41479 new_path=`$WHICH "$new_path" 2> /dev/null` 41480 # bat and cmd files are not always considered executable in MSYS causing which 41481 # to not find them 41482 if test "x$new_path" = x \ 41483 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 41484 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 41485 new_path="$path" 41486 41487 windows_path="$new_path" 41488 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41489 unix_path=`$CYGPATH -u "$windows_path"` 41490 new_path="$unix_path" 41491 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41492 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41493 new_path="$unix_path" 41494 fi 41495 41496 fi 41497 41498 if test "x$new_path" = x; then 41499 # It's still not found. Now this is an unrecoverable error. 41500 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 41501 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 41502 has_space=`$ECHO "$complete" | $GREP " "` 41503 if test "x$has_space" != x; then 41504 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 41505 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 41506 fi 41507 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 41508 fi 41509 fi 41510 41511 # Now new_path has a complete unix path to the binary 41512 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 41513 # Keep paths in /bin as-is, but remove trailing .exe if any 41514 new_path="${new_path/%.exe/}" 41515 # Do not save /bin paths to all_fixpath_prefixes! 41516 else 41517 # Not in mixed or Windows style, start by that. 41518 new_path=`cmd //c echo $new_path` 41519 41520 input_path="$new_path" 41521 # Check if we need to convert this using DOS-style short mode. If the path 41522 # contains just simple characters, use it. Otherwise (spaces, weird characters), 41523 # take no chances and rewrite it. 41524 # Note: m4 eats our [], so we need to use [ and ] instead. 41525 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 41526 if test "x$has_forbidden_chars" != x; then 41527 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 41528 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 41529 fi 41530 41531 # Output is in $new_path 41532 41533 windows_path="$new_path" 41534 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41535 unix_path=`$CYGPATH -u "$windows_path"` 41536 new_path="$unix_path" 41537 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41538 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41539 new_path="$unix_path" 41540 fi 41541 41542 # remove trailing .exe if any 41543 new_path="${new_path/%.exe/}" 41544 41545 # Save the first 10 bytes of this path to the storage, so fixpath can work. 41546 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 41547 fi 41548 41549 else 41550 # We're on a unix platform. Hooray! :) 41551 # First separate the path from the arguments. This will split at the first 41552 # space. 41553 complete="$STRIP" 41554 path="${complete%% *}" 41555 tmp="$complete EOL" 41556 arguments="${tmp#* }" 41557 41558 # Cannot rely on the command "which" here since it doesn't always work. 41559 is_absolute_path=`$ECHO "$path" | $GREP ^/` 41560 if test -z "$is_absolute_path"; then 41561 # Path to executable is not absolute. Find it. 41562 IFS_save="$IFS" 41563 IFS=: 41564 for p in $PATH; do 41565 if test -f "$p/$path" && test -x "$p/$path"; then 41566 new_path="$p/$path" 41567 break 41568 fi 41569 done 41570 IFS="$IFS_save" 41571 else 41572 # This is an absolute path, we can use it without further modifications. 41573 new_path="$path" 41574 fi 41575 41576 if test "x$new_path" = x; then 41577 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 41578 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 41579 has_space=`$ECHO "$complete" | $GREP " "` 41580 if test "x$has_space" != x; then 41581 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 41582 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 41583 fi 41584 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 41585 fi 41586 fi 41587 41588 # Now join together the path and the arguments once again 41589 if test "x$arguments" != xEOL; then 41590 new_complete="$new_path ${arguments% *}" 41591 else 41592 new_complete="$new_path" 41593 fi 41594 41595 if test "x$complete" != "x$new_complete"; then 41596 STRIP="$new_complete" 41597 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STRIP to \"$new_complete\"" >&5 41598 $as_echo "$as_me: Rewriting STRIP to \"$new_complete\"" >&6;} 41599 fi 41600 fi 41601 41602 if test "x$TOOLCHAIN_TYPE" = xgcc; then 41603 41604 41605 # Publish this variable in the help. 41606 41607 41608 if [ -z "${NM+x}" ]; then 41609 # The variable is not set by user, try to locate tool using the code snippet 41610 if test -n "$ac_tool_prefix"; then 41611 for ac_prog in nm gcc-nm 41612 do 41613 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 41614 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 41615 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41616 $as_echo_n "checking for $ac_word... " >&6; } 41617 if ${ac_cv_prog_NM+:} false; then : 41618 $as_echo_n "(cached) " >&6 41619 else 41620 if test -n "$NM"; then 41621 ac_cv_prog_NM="$NM" # Let the user override the test. 41622 else 41623 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41624 for as_dir in $PATH 41625 do 41626 IFS=$as_save_IFS 41627 test -z "$as_dir" && as_dir=. 41628 for ac_exec_ext in '' $ac_executable_extensions; do 41629 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41630 ac_cv_prog_NM="$ac_tool_prefix$ac_prog" 41631 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41632 break 2 41633 fi 41634 done 41635 done 41636 IFS=$as_save_IFS 41637 41638 fi 41639 fi 41640 NM=$ac_cv_prog_NM 41641 if test -n "$NM"; then 41642 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 41643 $as_echo "$NM" >&6; } 41644 else 41645 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41646 $as_echo "no" >&6; } 41647 fi 41648 41649 41650 test -n "$NM" && break 41651 done 41652 fi 41653 if test -z "$NM"; then 41654 ac_ct_NM=$NM 41655 for ac_prog in nm gcc-nm 41656 do 41657 # Extract the first word of "$ac_prog", so it can be a program name with args. 41658 set dummy $ac_prog; ac_word=$2 41659 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41660 $as_echo_n "checking for $ac_word... " >&6; } 41661 if ${ac_cv_prog_ac_ct_NM+:} false; then : 41662 $as_echo_n "(cached) " >&6 41663 else 41664 if test -n "$ac_ct_NM"; then 41665 ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test. 41666 else 41667 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41668 for as_dir in $PATH 41669 do 41670 IFS=$as_save_IFS 41671 test -z "$as_dir" && as_dir=. 41672 for ac_exec_ext in '' $ac_executable_extensions; do 41673 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41674 ac_cv_prog_ac_ct_NM="$ac_prog" 41675 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41676 break 2 41677 fi 41678 done 41679 done 41680 IFS=$as_save_IFS 41681 41682 fi 41683 fi 41684 ac_ct_NM=$ac_cv_prog_ac_ct_NM 41685 if test -n "$ac_ct_NM"; then 41686 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5 41687 $as_echo "$ac_ct_NM" >&6; } 41688 else 41689 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41690 $as_echo "no" >&6; } 41691 fi 41692 41693 41694 test -n "$ac_ct_NM" && break 41695 done 41696 41697 if test "x$ac_ct_NM" = x; then 41698 NM="" 41699 else 41700 case $cross_compiling:$ac_tool_warned in 41701 yes:) 41702 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 41703 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 41704 ac_tool_warned=yes ;; 41705 esac 41706 NM=$ac_ct_NM 41707 fi 41708 fi 41709 41710 else 41711 # The variable is set, but is it from the command line or the environment? 41712 41713 # Try to remove the string !NM! from our list. 41714 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NM!/} 41715 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 41716 # If it failed, the variable was not from the command line. Ignore it, 41717 # but warn the user (except for BASH, which is always set by the calling BASH). 41718 if test "xNM" != xBASH; then 41719 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&5 41720 $as_echo "$as_me: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&2;} 41721 fi 41722 # Try to locate tool using the code snippet 41723 if test -n "$ac_tool_prefix"; then 41724 for ac_prog in nm gcc-nm 41725 do 41726 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 41727 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 41728 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41729 $as_echo_n "checking for $ac_word... " >&6; } 41730 if ${ac_cv_prog_NM+:} false; then : 41731 $as_echo_n "(cached) " >&6 41732 else 41733 if test -n "$NM"; then 41734 ac_cv_prog_NM="$NM" # Let the user override the test. 41735 else 41736 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41737 for as_dir in $PATH 41738 do 41739 IFS=$as_save_IFS 41740 test -z "$as_dir" && as_dir=. 41741 for ac_exec_ext in '' $ac_executable_extensions; do 41742 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41743 ac_cv_prog_NM="$ac_tool_prefix$ac_prog" 41744 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41745 break 2 41746 fi 41747 done 41748 done 41749 IFS=$as_save_IFS 41750 41751 fi 41752 fi 41753 NM=$ac_cv_prog_NM 41754 if test -n "$NM"; then 41755 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 41756 $as_echo "$NM" >&6; } 41757 else 41758 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41759 $as_echo "no" >&6; } 41760 fi 41761 41762 41763 test -n "$NM" && break 41764 done 41765 fi 41766 if test -z "$NM"; then 41767 ac_ct_NM=$NM 41768 for ac_prog in nm gcc-nm 41769 do 41770 # Extract the first word of "$ac_prog", so it can be a program name with args. 41771 set dummy $ac_prog; ac_word=$2 41772 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41773 $as_echo_n "checking for $ac_word... " >&6; } 41774 if ${ac_cv_prog_ac_ct_NM+:} false; then : 41775 $as_echo_n "(cached) " >&6 41776 else 41777 if test -n "$ac_ct_NM"; then 41778 ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test. 41779 else 41780 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41781 for as_dir in $PATH 41782 do 41783 IFS=$as_save_IFS 41784 test -z "$as_dir" && as_dir=. 41785 for ac_exec_ext in '' $ac_executable_extensions; do 41786 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41787 ac_cv_prog_ac_ct_NM="$ac_prog" 41788 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41789 break 2 41790 fi 41791 done 41792 done 41793 IFS=$as_save_IFS 41794 41795 fi 41796 fi 41797 ac_ct_NM=$ac_cv_prog_ac_ct_NM 41798 if test -n "$ac_ct_NM"; then 41799 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5 41800 $as_echo "$ac_ct_NM" >&6; } 41801 else 41802 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41803 $as_echo "no" >&6; } 41804 fi 41805 41806 41807 test -n "$ac_ct_NM" && break 41808 done 41809 41810 if test "x$ac_ct_NM" = x; then 41811 NM="" 41812 else 41813 case $cross_compiling:$ac_tool_warned in 41814 yes:) 41815 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 41816 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 41817 ac_tool_warned=yes ;; 41818 esac 41819 NM=$ac_ct_NM 41820 fi 41821 fi 41822 41823 else 41824 # If it succeeded, then it was overridden by the user. We will use it 41825 # for the tool. 41826 41827 # First remove it from the list of overridden variables, so we can test 41828 # for unknown variables in the end. 41829 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 41830 41831 # Check if we try to supply an empty value 41832 if test "x$NM" = x; then 41833 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool NM= (no value)" >&5 41834 $as_echo "$as_me: Setting user supplied tool NM= (no value)" >&6;} 41835 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 41836 $as_echo_n "checking for NM... " >&6; } 41837 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 41838 $as_echo "disabled" >&6; } 41839 else 41840 # Check if the provided tool contains a complete path. 41841 tool_specified="$NM" 41842 tool_basename="${tool_specified##*/}" 41843 if test "x$tool_basename" = "x$tool_specified"; then 41844 # A command without a complete path is provided, search $PATH. 41845 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NM=$tool_basename" >&5 41846 $as_echo "$as_me: Will search for user supplied tool NM=$tool_basename" >&6;} 41847 # Extract the first word of "$tool_basename", so it can be a program name with args. 41848 set dummy $tool_basename; ac_word=$2 41849 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41850 $as_echo_n "checking for $ac_word... " >&6; } 41851 if ${ac_cv_path_NM+:} false; then : 41852 $as_echo_n "(cached) " >&6 41853 else 41854 case $NM in 41855 [\\/]* | ?:[\\/]*) 41856 ac_cv_path_NM="$NM" # Let the user override the test with a path. 41857 ;; 41858 *) 41859 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41860 for as_dir in $PATH 41861 do 41862 IFS=$as_save_IFS 41863 test -z "$as_dir" && as_dir=. 41864 for ac_exec_ext in '' $ac_executable_extensions; do 41865 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41866 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 41867 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41868 break 2 41869 fi 41870 done 41871 done 41872 IFS=$as_save_IFS 41873 41874 ;; 41875 esac 41876 fi 41877 NM=$ac_cv_path_NM 41878 if test -n "$NM"; then 41879 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 41880 $as_echo "$NM" >&6; } 41881 else 41882 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41883 $as_echo "no" >&6; } 41884 fi 41885 41886 41887 if test "x$NM" = x; then 41888 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 41889 fi 41890 else 41891 # Otherwise we believe it is a complete path. Use it as it is. 41892 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NM=$tool_specified" >&5 41893 $as_echo "$as_me: Will use user supplied tool NM=$tool_specified" >&6;} 41894 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 41895 $as_echo_n "checking for NM... " >&6; } 41896 if test ! -x "$tool_specified"; then 41897 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 41898 $as_echo "not found" >&6; } 41899 as_fn_error $? "User supplied tool NM=$tool_specified does not exist or is not executable" "$LINENO" 5 41900 fi 41901 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 41902 $as_echo "$tool_specified" >&6; } 41903 fi 41904 fi 41905 fi 41906 41907 fi 41908 41909 41910 else 41911 41912 41913 # Publish this variable in the help. 41914 41915 41916 if [ -z "${NM+x}" ]; then 41917 # The variable is not set by user, try to locate tool using the code snippet 41918 if test -n "$ac_tool_prefix"; then 41919 for ac_prog in nm 41920 do 41921 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 41922 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 41923 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41924 $as_echo_n "checking for $ac_word... " >&6; } 41925 if ${ac_cv_prog_NM+:} false; then : 41926 $as_echo_n "(cached) " >&6 41927 else 41928 if test -n "$NM"; then 41929 ac_cv_prog_NM="$NM" # Let the user override the test. 41930 else 41931 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41932 for as_dir in $PATH 41933 do 41934 IFS=$as_save_IFS 41935 test -z "$as_dir" && as_dir=. 41936 for ac_exec_ext in '' $ac_executable_extensions; do 41937 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41938 ac_cv_prog_NM="$ac_tool_prefix$ac_prog" 41939 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41940 break 2 41941 fi 41942 done 41943 done 41944 IFS=$as_save_IFS 41945 41946 fi 41947 fi 41948 NM=$ac_cv_prog_NM 41949 if test -n "$NM"; then 41950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 41951 $as_echo "$NM" >&6; } 41952 else 41953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41954 $as_echo "no" >&6; } 41955 fi 41956 41957 41958 test -n "$NM" && break 41959 done 41960 fi 41961 if test -z "$NM"; then 41962 ac_ct_NM=$NM 41963 for ac_prog in nm 41964 do 41965 # Extract the first word of "$ac_prog", so it can be a program name with args. 41966 set dummy $ac_prog; ac_word=$2 41967 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41968 $as_echo_n "checking for $ac_word... " >&6; } 41969 if ${ac_cv_prog_ac_ct_NM+:} false; then : 41970 $as_echo_n "(cached) " >&6 41971 else 41972 if test -n "$ac_ct_NM"; then 41973 ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test. 41974 else 41975 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41976 for as_dir in $PATH 41977 do 41978 IFS=$as_save_IFS 41979 test -z "$as_dir" && as_dir=. 41980 for ac_exec_ext in '' $ac_executable_extensions; do 41981 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41982 ac_cv_prog_ac_ct_NM="$ac_prog" 41983 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41984 break 2 41985 fi 41986 done 41987 done 41988 IFS=$as_save_IFS 41989 41990 fi 41991 fi 41992 ac_ct_NM=$ac_cv_prog_ac_ct_NM 41993 if test -n "$ac_ct_NM"; then 41994 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5 41995 $as_echo "$ac_ct_NM" >&6; } 41996 else 41997 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41998 $as_echo "no" >&6; } 41999 fi 42000 42001 42002 test -n "$ac_ct_NM" && break 42003 done 42004 42005 if test "x$ac_ct_NM" = x; then 42006 NM="" 42007 else 42008 case $cross_compiling:$ac_tool_warned in 42009 yes:) 42010 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 42011 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 42012 ac_tool_warned=yes ;; 42013 esac 42014 NM=$ac_ct_NM 42015 fi 42016 fi 42017 42018 else 42019 # The variable is set, but is it from the command line or the environment? 42020 42021 # Try to remove the string !NM! from our list. 42022 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NM!/} 42023 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 42024 # If it failed, the variable was not from the command line. Ignore it, 42025 # but warn the user (except for BASH, which is always set by the calling BASH). 42026 if test "xNM" != xBASH; then 42027 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&5 42028 $as_echo "$as_me: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&2;} 42029 fi 42030 # Try to locate tool using the code snippet 42031 if test -n "$ac_tool_prefix"; then 42032 for ac_prog in nm 42033 do 42034 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 42035 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 42036 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42037 $as_echo_n "checking for $ac_word... " >&6; } 42038 if ${ac_cv_prog_NM+:} false; then : 42039 $as_echo_n "(cached) " >&6 42040 else 42041 if test -n "$NM"; then 42042 ac_cv_prog_NM="$NM" # Let the user override the test. 42043 else 42044 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42045 for as_dir in $PATH 42046 do 42047 IFS=$as_save_IFS 42048 test -z "$as_dir" && as_dir=. 42049 for ac_exec_ext in '' $ac_executable_extensions; do 42050 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42051 ac_cv_prog_NM="$ac_tool_prefix$ac_prog" 42052 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42053 break 2 42054 fi 42055 done 42056 done 42057 IFS=$as_save_IFS 42058 42059 fi 42060 fi 42061 NM=$ac_cv_prog_NM 42062 if test -n "$NM"; then 42063 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 42064 $as_echo "$NM" >&6; } 42065 else 42066 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42067 $as_echo "no" >&6; } 42068 fi 42069 42070 42071 test -n "$NM" && break 42072 done 42073 fi 42074 if test -z "$NM"; then 42075 ac_ct_NM=$NM 42076 for ac_prog in nm 42077 do 42078 # Extract the first word of "$ac_prog", so it can be a program name with args. 42079 set dummy $ac_prog; ac_word=$2 42080 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42081 $as_echo_n "checking for $ac_word... " >&6; } 42082 if ${ac_cv_prog_ac_ct_NM+:} false; then : 42083 $as_echo_n "(cached) " >&6 42084 else 42085 if test -n "$ac_ct_NM"; then 42086 ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test. 42087 else 42088 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42089 for as_dir in $PATH 42090 do 42091 IFS=$as_save_IFS 42092 test -z "$as_dir" && as_dir=. 42093 for ac_exec_ext in '' $ac_executable_extensions; do 42094 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42095 ac_cv_prog_ac_ct_NM="$ac_prog" 42096 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42097 break 2 42098 fi 42099 done 42100 done 42101 IFS=$as_save_IFS 42102 42103 fi 42104 fi 42105 ac_ct_NM=$ac_cv_prog_ac_ct_NM 42106 if test -n "$ac_ct_NM"; then 42107 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5 42108 $as_echo "$ac_ct_NM" >&6; } 42109 else 42110 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42111 $as_echo "no" >&6; } 42112 fi 42113 42114 42115 test -n "$ac_ct_NM" && break 42116 done 42117 42118 if test "x$ac_ct_NM" = x; then 42119 NM="" 42120 else 42121 case $cross_compiling:$ac_tool_warned in 42122 yes:) 42123 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 42124 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 42125 ac_tool_warned=yes ;; 42126 esac 42127 NM=$ac_ct_NM 42128 fi 42129 fi 42130 42131 else 42132 # If it succeeded, then it was overridden by the user. We will use it 42133 # for the tool. 42134 42135 # First remove it from the list of overridden variables, so we can test 42136 # for unknown variables in the end. 42137 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 42138 42139 # Check if we try to supply an empty value 42140 if test "x$NM" = x; then 42141 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool NM= (no value)" >&5 42142 $as_echo "$as_me: Setting user supplied tool NM= (no value)" >&6;} 42143 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 42144 $as_echo_n "checking for NM... " >&6; } 42145 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 42146 $as_echo "disabled" >&6; } 42147 else 42148 # Check if the provided tool contains a complete path. 42149 tool_specified="$NM" 42150 tool_basename="${tool_specified##*/}" 42151 if test "x$tool_basename" = "x$tool_specified"; then 42152 # A command without a complete path is provided, search $PATH. 42153 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NM=$tool_basename" >&5 42154 $as_echo "$as_me: Will search for user supplied tool NM=$tool_basename" >&6;} 42155 # Extract the first word of "$tool_basename", so it can be a program name with args. 42156 set dummy $tool_basename; ac_word=$2 42157 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42158 $as_echo_n "checking for $ac_word... " >&6; } 42159 if ${ac_cv_path_NM+:} false; then : 42160 $as_echo_n "(cached) " >&6 42161 else 42162 case $NM in 42163 [\\/]* | ?:[\\/]*) 42164 ac_cv_path_NM="$NM" # Let the user override the test with a path. 42165 ;; 42166 *) 42167 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42168 for as_dir in $PATH 42169 do 42170 IFS=$as_save_IFS 42171 test -z "$as_dir" && as_dir=. 42172 for ac_exec_ext in '' $ac_executable_extensions; do 42173 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42174 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 42175 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42176 break 2 42177 fi 42178 done 42179 done 42180 IFS=$as_save_IFS 42181 42182 ;; 42183 esac 42184 fi 42185 NM=$ac_cv_path_NM 42186 if test -n "$NM"; then 42187 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 42188 $as_echo "$NM" >&6; } 42189 else 42190 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42191 $as_echo "no" >&6; } 42192 fi 42193 42194 42195 if test "x$NM" = x; then 42196 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 42197 fi 42198 else 42199 # Otherwise we believe it is a complete path. Use it as it is. 42200 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NM=$tool_specified" >&5 42201 $as_echo "$as_me: Will use user supplied tool NM=$tool_specified" >&6;} 42202 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 42203 $as_echo_n "checking for NM... " >&6; } 42204 if test ! -x "$tool_specified"; then 42205 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 42206 $as_echo "not found" >&6; } 42207 as_fn_error $? "User supplied tool NM=$tool_specified does not exist or is not executable" "$LINENO" 5 42208 fi 42209 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 42210 $as_echo "$tool_specified" >&6; } 42211 fi 42212 fi 42213 fi 42214 42215 fi 42216 42217 42218 fi 42219 42220 # Only process if variable expands to non-empty 42221 42222 if test "x$NM" != x; then 42223 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42224 42225 # First separate the path from the arguments. This will split at the first 42226 # space. 42227 complete="$NM" 42228 path="${complete%% *}" 42229 tmp="$complete EOL" 42230 arguments="${tmp#* }" 42231 42232 # Input might be given as Windows format, start by converting to 42233 # unix format. 42234 new_path=`$CYGPATH -u "$path"` 42235 42236 # Now try to locate executable using which 42237 new_path=`$WHICH "$new_path" 2> /dev/null` 42238 # bat and cmd files are not always considered executable in cygwin causing which 42239 # to not find them 42240 if test "x$new_path" = x \ 42241 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 42242 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 42243 new_path=`$CYGPATH -u "$path"` 42244 fi 42245 if test "x$new_path" = x; then 42246 # Oops. Which didn't find the executable. 42247 # The splitting of arguments from the executable at a space might have been incorrect, 42248 # since paths with space are more likely in Windows. Give it another try with the whole 42249 # argument. 42250 path="$complete" 42251 arguments="EOL" 42252 new_path=`$CYGPATH -u "$path"` 42253 new_path=`$WHICH "$new_path" 2> /dev/null` 42254 # bat and cmd files are not always considered executable in cygwin causing which 42255 # to not find them 42256 if test "x$new_path" = x \ 42257 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 42258 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 42259 new_path=`$CYGPATH -u "$path"` 42260 fi 42261 if test "x$new_path" = x; then 42262 # It's still not found. Now this is an unrecoverable error. 42263 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 42264 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 42265 has_space=`$ECHO "$complete" | $GREP " "` 42266 if test "x$has_space" != x; then 42267 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 42268 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 42269 fi 42270 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 42271 fi 42272 fi 42273 42274 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 42275 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 42276 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 42277 # "foo.exe" is OK but "foo" is an error. 42278 # 42279 # This test is therefore slightly more accurate than "test -f" to check for file presence. 42280 # It is also a way to make sure we got the proper file name for the real test later on. 42281 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 42282 if test "x$test_shortpath" = x; then 42283 # Short path failed, file does not exist as specified. 42284 # Try adding .exe or .cmd 42285 if test -f "${new_path}.exe"; then 42286 input_to_shortpath="${new_path}.exe" 42287 elif test -f "${new_path}.cmd"; then 42288 input_to_shortpath="${new_path}.cmd" 42289 else 42290 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$new_path\", is invalid." >&5 42291 $as_echo "$as_me: The path of NM, which resolves as \"$new_path\", is invalid." >&6;} 42292 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 42293 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 42294 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 42295 fi 42296 else 42297 input_to_shortpath="$new_path" 42298 fi 42299 42300 # Call helper function which possibly converts this using DOS-style short mode. 42301 # If so, the updated path is stored in $new_path. 42302 new_path="$input_to_shortpath" 42303 42304 input_path="$input_to_shortpath" 42305 # Check if we need to convert this using DOS-style short mode. If the path 42306 # contains just simple characters, use it. Otherwise (spaces, weird characters), 42307 # take no chances and rewrite it. 42308 # Note: m4 eats our [], so we need to use [ and ] instead. 42309 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 42310 if test "x$has_forbidden_chars" != x; then 42311 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 42312 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 42313 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 42314 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 42315 # Going to short mode and back again did indeed matter. Since short mode is 42316 # case insensitive, let's make it lowercase to improve readability. 42317 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 42318 # Now convert it back to Unix-style (cygpath) 42319 input_path=`$CYGPATH -u "$shortmode_path"` 42320 new_path="$input_path" 42321 fi 42322 fi 42323 42324 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 42325 if test "x$test_cygdrive_prefix" = x; then 42326 # As a simple fix, exclude /usr/bin since it's not a real path. 42327 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 42328 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 42329 # a path prefixed by /cygdrive for fixpath to work. 42330 new_path="$CYGWIN_ROOT_PATH$input_path" 42331 fi 42332 fi 42333 42334 # remove trailing .exe if any 42335 new_path="${new_path/%.exe/}" 42336 42337 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42338 42339 # First separate the path from the arguments. This will split at the first 42340 # space. 42341 complete="$NM" 42342 path="${complete%% *}" 42343 tmp="$complete EOL" 42344 arguments="${tmp#* }" 42345 42346 # Input might be given as Windows format, start by converting to 42347 # unix format. 42348 new_path="$path" 42349 42350 windows_path="$new_path" 42351 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42352 unix_path=`$CYGPATH -u "$windows_path"` 42353 new_path="$unix_path" 42354 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42355 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42356 new_path="$unix_path" 42357 fi 42358 42359 42360 # Now try to locate executable using which 42361 new_path=`$WHICH "$new_path" 2> /dev/null` 42362 42363 if test "x$new_path" = x; then 42364 # Oops. Which didn't find the executable. 42365 # The splitting of arguments from the executable at a space might have been incorrect, 42366 # since paths with space are more likely in Windows. Give it another try with the whole 42367 # argument. 42368 path="$complete" 42369 arguments="EOL" 42370 new_path="$path" 42371 42372 windows_path="$new_path" 42373 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42374 unix_path=`$CYGPATH -u "$windows_path"` 42375 new_path="$unix_path" 42376 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42377 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42378 new_path="$unix_path" 42379 fi 42380 42381 42382 new_path=`$WHICH "$new_path" 2> /dev/null` 42383 # bat and cmd files are not always considered executable in MSYS causing which 42384 # to not find them 42385 if test "x$new_path" = x \ 42386 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 42387 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 42388 new_path="$path" 42389 42390 windows_path="$new_path" 42391 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42392 unix_path=`$CYGPATH -u "$windows_path"` 42393 new_path="$unix_path" 42394 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42395 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42396 new_path="$unix_path" 42397 fi 42398 42399 fi 42400 42401 if test "x$new_path" = x; then 42402 # It's still not found. Now this is an unrecoverable error. 42403 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 42404 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 42405 has_space=`$ECHO "$complete" | $GREP " "` 42406 if test "x$has_space" != x; then 42407 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 42408 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 42409 fi 42410 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 42411 fi 42412 fi 42413 42414 # Now new_path has a complete unix path to the binary 42415 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 42416 # Keep paths in /bin as-is, but remove trailing .exe if any 42417 new_path="${new_path/%.exe/}" 42418 # Do not save /bin paths to all_fixpath_prefixes! 42419 else 42420 # Not in mixed or Windows style, start by that. 42421 new_path=`cmd //c echo $new_path` 42422 42423 input_path="$new_path" 42424 # Check if we need to convert this using DOS-style short mode. If the path 42425 # contains just simple characters, use it. Otherwise (spaces, weird characters), 42426 # take no chances and rewrite it. 42427 # Note: m4 eats our [], so we need to use [ and ] instead. 42428 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 42429 if test "x$has_forbidden_chars" != x; then 42430 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 42431 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 42432 fi 42433 42434 # Output is in $new_path 42435 42436 windows_path="$new_path" 42437 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42438 unix_path=`$CYGPATH -u "$windows_path"` 42439 new_path="$unix_path" 42440 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42441 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42442 new_path="$unix_path" 42443 fi 42444 42445 # remove trailing .exe if any 42446 new_path="${new_path/%.exe/}" 42447 42448 # Save the first 10 bytes of this path to the storage, so fixpath can work. 42449 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 42450 fi 42451 42452 else 42453 # We're on a unix platform. Hooray! :) 42454 # First separate the path from the arguments. This will split at the first 42455 # space. 42456 complete="$NM" 42457 path="${complete%% *}" 42458 tmp="$complete EOL" 42459 arguments="${tmp#* }" 42460 42461 # Cannot rely on the command "which" here since it doesn't always work. 42462 is_absolute_path=`$ECHO "$path" | $GREP ^/` 42463 if test -z "$is_absolute_path"; then 42464 # Path to executable is not absolute. Find it. 42465 IFS_save="$IFS" 42466 IFS=: 42467 for p in $PATH; do 42468 if test -f "$p/$path" && test -x "$p/$path"; then 42469 new_path="$p/$path" 42470 break 42471 fi 42472 done 42473 IFS="$IFS_save" 42474 else 42475 # This is an absolute path, we can use it without further modifications. 42476 new_path="$path" 42477 fi 42478 42479 if test "x$new_path" = x; then 42480 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 42481 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 42482 has_space=`$ECHO "$complete" | $GREP " "` 42483 if test "x$has_space" != x; then 42484 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 42485 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 42486 fi 42487 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 42488 fi 42489 fi 42490 42491 # Now join together the path and the arguments once again 42492 if test "x$arguments" != xEOL; then 42493 new_complete="$new_path ${arguments% *}" 42494 else 42495 new_complete="$new_path" 42496 fi 42497 42498 if test "x$complete" != "x$new_complete"; then 42499 NM="$new_complete" 42500 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting NM to \"$new_complete\"" >&5 42501 $as_echo "$as_me: Rewriting NM to \"$new_complete\"" >&6;} 42502 fi 42503 fi 42504 42505 GNM="$NM" 42506 42507 fi 42508 42509 # objcopy is used for moving debug symbols to separate files when 42510 # full debug symbols are enabled. 42511 if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xlinux; then 42512 42513 42514 # Publish this variable in the help. 42515 42516 42517 if [ -z "${OBJCOPY+x}" ]; then 42518 # The variable is not set by user, try to locate tool using the code snippet 42519 if test -n "$ac_tool_prefix"; then 42520 for ac_prog in gobjcopy objcopy 42521 do 42522 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 42523 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 42524 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42525 $as_echo_n "checking for $ac_word... " >&6; } 42526 if ${ac_cv_prog_OBJCOPY+:} false; then : 42527 $as_echo_n "(cached) " >&6 42528 else 42529 if test -n "$OBJCOPY"; then 42530 ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test. 42531 else 42532 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42533 for as_dir in $PATH 42534 do 42535 IFS=$as_save_IFS 42536 test -z "$as_dir" && as_dir=. 42537 for ac_exec_ext in '' $ac_executable_extensions; do 42538 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42539 ac_cv_prog_OBJCOPY="$ac_tool_prefix$ac_prog" 42540 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42541 break 2 42542 fi 42543 done 42544 done 42545 IFS=$as_save_IFS 42546 42547 fi 42548 fi 42549 OBJCOPY=$ac_cv_prog_OBJCOPY 42550 if test -n "$OBJCOPY"; then 42551 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5 42552 $as_echo "$OBJCOPY" >&6; } 42553 else 42554 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42555 $as_echo "no" >&6; } 42556 fi 42557 42558 42559 test -n "$OBJCOPY" && break 42560 done 42561 fi 42562 if test -z "$OBJCOPY"; then 42563 ac_ct_OBJCOPY=$OBJCOPY 42564 for ac_prog in gobjcopy objcopy 42565 do 42566 # Extract the first word of "$ac_prog", so it can be a program name with args. 42567 set dummy $ac_prog; ac_word=$2 42568 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42569 $as_echo_n "checking for $ac_word... " >&6; } 42570 if ${ac_cv_prog_ac_ct_OBJCOPY+:} false; then : 42571 $as_echo_n "(cached) " >&6 42572 else 42573 if test -n "$ac_ct_OBJCOPY"; then 42574 ac_cv_prog_ac_ct_OBJCOPY="$ac_ct_OBJCOPY" # Let the user override the test. 42575 else 42576 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42577 for as_dir in $PATH 42578 do 42579 IFS=$as_save_IFS 42580 test -z "$as_dir" && as_dir=. 42581 for ac_exec_ext in '' $ac_executable_extensions; do 42582 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42583 ac_cv_prog_ac_ct_OBJCOPY="$ac_prog" 42584 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42585 break 2 42586 fi 42587 done 42588 done 42589 IFS=$as_save_IFS 42590 42591 fi 42592 fi 42593 ac_ct_OBJCOPY=$ac_cv_prog_ac_ct_OBJCOPY 42594 if test -n "$ac_ct_OBJCOPY"; then 42595 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJCOPY" >&5 42596 $as_echo "$ac_ct_OBJCOPY" >&6; } 42597 else 42598 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42599 $as_echo "no" >&6; } 42600 fi 42601 42602 42603 test -n "$ac_ct_OBJCOPY" && break 42604 done 42605 42606 if test "x$ac_ct_OBJCOPY" = x; then 42607 OBJCOPY="" 42608 else 42609 case $cross_compiling:$ac_tool_warned in 42610 yes:) 42611 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 42612 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 42613 ac_tool_warned=yes ;; 42614 esac 42615 OBJCOPY=$ac_ct_OBJCOPY 42616 fi 42617 fi 42618 42619 else 42620 # The variable is set, but is it from the command line or the environment? 42621 42622 # Try to remove the string !OBJCOPY! from our list. 42623 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!OBJCOPY!/} 42624 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 42625 # If it failed, the variable was not from the command line. Ignore it, 42626 # but warn the user (except for BASH, which is always set by the calling BASH). 42627 if test "xOBJCOPY" != xBASH; then 42628 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of OBJCOPY from the environment. Use command line variables instead." >&5 42629 $as_echo "$as_me: WARNING: Ignoring value of OBJCOPY from the environment. Use command line variables instead." >&2;} 42630 fi 42631 # Try to locate tool using the code snippet 42632 if test -n "$ac_tool_prefix"; then 42633 for ac_prog in gobjcopy objcopy 42634 do 42635 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 42636 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 42637 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42638 $as_echo_n "checking for $ac_word... " >&6; } 42639 if ${ac_cv_prog_OBJCOPY+:} false; then : 42640 $as_echo_n "(cached) " >&6 42641 else 42642 if test -n "$OBJCOPY"; then 42643 ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test. 42644 else 42645 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42646 for as_dir in $PATH 42647 do 42648 IFS=$as_save_IFS 42649 test -z "$as_dir" && as_dir=. 42650 for ac_exec_ext in '' $ac_executable_extensions; do 42651 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42652 ac_cv_prog_OBJCOPY="$ac_tool_prefix$ac_prog" 42653 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42654 break 2 42655 fi 42656 done 42657 done 42658 IFS=$as_save_IFS 42659 42660 fi 42661 fi 42662 OBJCOPY=$ac_cv_prog_OBJCOPY 42663 if test -n "$OBJCOPY"; then 42664 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5 42665 $as_echo "$OBJCOPY" >&6; } 42666 else 42667 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42668 $as_echo "no" >&6; } 42669 fi 42670 42671 42672 test -n "$OBJCOPY" && break 42673 done 42674 fi 42675 if test -z "$OBJCOPY"; then 42676 ac_ct_OBJCOPY=$OBJCOPY 42677 for ac_prog in gobjcopy objcopy 42678 do 42679 # Extract the first word of "$ac_prog", so it can be a program name with args. 42680 set dummy $ac_prog; ac_word=$2 42681 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42682 $as_echo_n "checking for $ac_word... " >&6; } 42683 if ${ac_cv_prog_ac_ct_OBJCOPY+:} false; then : 42684 $as_echo_n "(cached) " >&6 42685 else 42686 if test -n "$ac_ct_OBJCOPY"; then 42687 ac_cv_prog_ac_ct_OBJCOPY="$ac_ct_OBJCOPY" # Let the user override the test. 42688 else 42689 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42690 for as_dir in $PATH 42691 do 42692 IFS=$as_save_IFS 42693 test -z "$as_dir" && as_dir=. 42694 for ac_exec_ext in '' $ac_executable_extensions; do 42695 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42696 ac_cv_prog_ac_ct_OBJCOPY="$ac_prog" 42697 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42698 break 2 42699 fi 42700 done 42701 done 42702 IFS=$as_save_IFS 42703 42704 fi 42705 fi 42706 ac_ct_OBJCOPY=$ac_cv_prog_ac_ct_OBJCOPY 42707 if test -n "$ac_ct_OBJCOPY"; then 42708 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJCOPY" >&5 42709 $as_echo "$ac_ct_OBJCOPY" >&6; } 42710 else 42711 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42712 $as_echo "no" >&6; } 42713 fi 42714 42715 42716 test -n "$ac_ct_OBJCOPY" && break 42717 done 42718 42719 if test "x$ac_ct_OBJCOPY" = x; then 42720 OBJCOPY="" 42721 else 42722 case $cross_compiling:$ac_tool_warned in 42723 yes:) 42724 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 42725 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 42726 ac_tool_warned=yes ;; 42727 esac 42728 OBJCOPY=$ac_ct_OBJCOPY 42729 fi 42730 fi 42731 42732 else 42733 # If it succeeded, then it was overridden by the user. We will use it 42734 # for the tool. 42735 42736 # First remove it from the list of overridden variables, so we can test 42737 # for unknown variables in the end. 42738 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 42739 42740 # Check if we try to supply an empty value 42741 if test "x$OBJCOPY" = x; then 42742 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool OBJCOPY= (no value)" >&5 42743 $as_echo "$as_me: Setting user supplied tool OBJCOPY= (no value)" >&6;} 42744 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJCOPY" >&5 42745 $as_echo_n "checking for OBJCOPY... " >&6; } 42746 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 42747 $as_echo "disabled" >&6; } 42748 else 42749 # Check if the provided tool contains a complete path. 42750 tool_specified="$OBJCOPY" 42751 tool_basename="${tool_specified##*/}" 42752 if test "x$tool_basename" = "x$tool_specified"; then 42753 # A command without a complete path is provided, search $PATH. 42754 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool OBJCOPY=$tool_basename" >&5 42755 $as_echo "$as_me: Will search for user supplied tool OBJCOPY=$tool_basename" >&6;} 42756 # Extract the first word of "$tool_basename", so it can be a program name with args. 42757 set dummy $tool_basename; ac_word=$2 42758 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42759 $as_echo_n "checking for $ac_word... " >&6; } 42760 if ${ac_cv_path_OBJCOPY+:} false; then : 42761 $as_echo_n "(cached) " >&6 42762 else 42763 case $OBJCOPY in 42764 [\\/]* | ?:[\\/]*) 42765 ac_cv_path_OBJCOPY="$OBJCOPY" # Let the user override the test with a path. 42766 ;; 42767 *) 42768 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42769 for as_dir in $PATH 42770 do 42771 IFS=$as_save_IFS 42772 test -z "$as_dir" && as_dir=. 42773 for ac_exec_ext in '' $ac_executable_extensions; do 42774 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42775 ac_cv_path_OBJCOPY="$as_dir/$ac_word$ac_exec_ext" 42776 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42777 break 2 42778 fi 42779 done 42780 done 42781 IFS=$as_save_IFS 42782 42783 ;; 42784 esac 42785 fi 42786 OBJCOPY=$ac_cv_path_OBJCOPY 42787 if test -n "$OBJCOPY"; then 42788 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5 42789 $as_echo "$OBJCOPY" >&6; } 42790 else 42791 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42792 $as_echo "no" >&6; } 42793 fi 42794 42795 42796 if test "x$OBJCOPY" = x; then 42797 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 42798 fi 42799 else 42800 # Otherwise we believe it is a complete path. Use it as it is. 42801 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool OBJCOPY=$tool_specified" >&5 42802 $as_echo "$as_me: Will use user supplied tool OBJCOPY=$tool_specified" >&6;} 42803 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJCOPY" >&5 42804 $as_echo_n "checking for OBJCOPY... " >&6; } 42805 if test ! -x "$tool_specified"; then 42806 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 42807 $as_echo "not found" >&6; } 42808 as_fn_error $? "User supplied tool OBJCOPY=$tool_specified does not exist or is not executable" "$LINENO" 5 42809 fi 42810 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 42811 $as_echo "$tool_specified" >&6; } 42812 fi 42813 fi 42814 fi 42815 42816 fi 42817 42818 42819 # Only call fixup if objcopy was found. 42820 if test -n "$OBJCOPY"; then 42821 42822 # Only process if variable expands to non-empty 42823 42824 if test "x$OBJCOPY" != x; then 42825 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42826 42827 # First separate the path from the arguments. This will split at the first 42828 # space. 42829 complete="$OBJCOPY" 42830 path="${complete%% *}" 42831 tmp="$complete EOL" 42832 arguments="${tmp#* }" 42833 42834 # Input might be given as Windows format, start by converting to 42835 # unix format. 42836 new_path=`$CYGPATH -u "$path"` 42837 42838 # Now try to locate executable using which 42839 new_path=`$WHICH "$new_path" 2> /dev/null` 42840 # bat and cmd files are not always considered executable in cygwin causing which 42841 # to not find them 42842 if test "x$new_path" = x \ 42843 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 42844 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 42845 new_path=`$CYGPATH -u "$path"` 42846 fi 42847 if test "x$new_path" = x; then 42848 # Oops. Which didn't find the executable. 42849 # The splitting of arguments from the executable at a space might have been incorrect, 42850 # since paths with space are more likely in Windows. Give it another try with the whole 42851 # argument. 42852 path="$complete" 42853 arguments="EOL" 42854 new_path=`$CYGPATH -u "$path"` 42855 new_path=`$WHICH "$new_path" 2> /dev/null` 42856 # bat and cmd files are not always considered executable in cygwin causing which 42857 # to not find them 42858 if test "x$new_path" = x \ 42859 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 42860 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 42861 new_path=`$CYGPATH -u "$path"` 42862 fi 42863 if test "x$new_path" = x; then 42864 # It's still not found. Now this is an unrecoverable error. 42865 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5 42866 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 42867 has_space=`$ECHO "$complete" | $GREP " "` 42868 if test "x$has_space" != x; then 42869 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 42870 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 42871 fi 42872 as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5 42873 fi 42874 fi 42875 42876 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 42877 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 42878 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 42879 # "foo.exe" is OK but "foo" is an error. 42880 # 42881 # This test is therefore slightly more accurate than "test -f" to check for file presence. 42882 # It is also a way to make sure we got the proper file name for the real test later on. 42883 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 42884 if test "x$test_shortpath" = x; then 42885 # Short path failed, file does not exist as specified. 42886 # Try adding .exe or .cmd 42887 if test -f "${new_path}.exe"; then 42888 input_to_shortpath="${new_path}.exe" 42889 elif test -f "${new_path}.cmd"; then 42890 input_to_shortpath="${new_path}.cmd" 42891 else 42892 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$new_path\", is invalid." >&5 42893 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$new_path\", is invalid." >&6;} 42894 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 42895 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 42896 as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5 42897 fi 42898 else 42899 input_to_shortpath="$new_path" 42900 fi 42901 42902 # Call helper function which possibly converts this using DOS-style short mode. 42903 # If so, the updated path is stored in $new_path. 42904 new_path="$input_to_shortpath" 42905 42906 input_path="$input_to_shortpath" 42907 # Check if we need to convert this using DOS-style short mode. If the path 42908 # contains just simple characters, use it. Otherwise (spaces, weird characters), 42909 # take no chances and rewrite it. 42910 # Note: m4 eats our [], so we need to use [ and ] instead. 42911 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 42912 if test "x$has_forbidden_chars" != x; then 42913 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 42914 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 42915 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 42916 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 42917 # Going to short mode and back again did indeed matter. Since short mode is 42918 # case insensitive, let's make it lowercase to improve readability. 42919 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 42920 # Now convert it back to Unix-style (cygpath) 42921 input_path=`$CYGPATH -u "$shortmode_path"` 42922 new_path="$input_path" 42923 fi 42924 fi 42925 42926 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 42927 if test "x$test_cygdrive_prefix" = x; then 42928 # As a simple fix, exclude /usr/bin since it's not a real path. 42929 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 42930 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 42931 # a path prefixed by /cygdrive for fixpath to work. 42932 new_path="$CYGWIN_ROOT_PATH$input_path" 42933 fi 42934 fi 42935 42936 # remove trailing .exe if any 42937 new_path="${new_path/%.exe/}" 42938 42939 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42940 42941 # First separate the path from the arguments. This will split at the first 42942 # space. 42943 complete="$OBJCOPY" 42944 path="${complete%% *}" 42945 tmp="$complete EOL" 42946 arguments="${tmp#* }" 42947 42948 # Input might be given as Windows format, start by converting to 42949 # unix format. 42950 new_path="$path" 42951 42952 windows_path="$new_path" 42953 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42954 unix_path=`$CYGPATH -u "$windows_path"` 42955 new_path="$unix_path" 42956 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42957 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42958 new_path="$unix_path" 42959 fi 42960 42961 42962 # Now try to locate executable using which 42963 new_path=`$WHICH "$new_path" 2> /dev/null` 42964 42965 if test "x$new_path" = x; then 42966 # Oops. Which didn't find the executable. 42967 # The splitting of arguments from the executable at a space might have been incorrect, 42968 # since paths with space are more likely in Windows. Give it another try with the whole 42969 # argument. 42970 path="$complete" 42971 arguments="EOL" 42972 new_path="$path" 42973 42974 windows_path="$new_path" 42975 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42976 unix_path=`$CYGPATH -u "$windows_path"` 42977 new_path="$unix_path" 42978 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42979 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42980 new_path="$unix_path" 42981 fi 42982 42983 42984 new_path=`$WHICH "$new_path" 2> /dev/null` 42985 # bat and cmd files are not always considered executable in MSYS causing which 42986 # to not find them 42987 if test "x$new_path" = x \ 42988 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 42989 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 42990 new_path="$path" 42991 42992 windows_path="$new_path" 42993 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42994 unix_path=`$CYGPATH -u "$windows_path"` 42995 new_path="$unix_path" 42996 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42997 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42998 new_path="$unix_path" 42999 fi 43000 43001 fi 43002 43003 if test "x$new_path" = x; then 43004 # It's still not found. Now this is an unrecoverable error. 43005 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5 43006 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 43007 has_space=`$ECHO "$complete" | $GREP " "` 43008 if test "x$has_space" != x; then 43009 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 43010 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 43011 fi 43012 as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5 43013 fi 43014 fi 43015 43016 # Now new_path has a complete unix path to the binary 43017 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 43018 # Keep paths in /bin as-is, but remove trailing .exe if any 43019 new_path="${new_path/%.exe/}" 43020 # Do not save /bin paths to all_fixpath_prefixes! 43021 else 43022 # Not in mixed or Windows style, start by that. 43023 new_path=`cmd //c echo $new_path` 43024 43025 input_path="$new_path" 43026 # Check if we need to convert this using DOS-style short mode. If the path 43027 # contains just simple characters, use it. Otherwise (spaces, weird characters), 43028 # take no chances and rewrite it. 43029 # Note: m4 eats our [], so we need to use [ and ] instead. 43030 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 43031 if test "x$has_forbidden_chars" != x; then 43032 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 43033 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 43034 fi 43035 43036 # Output is in $new_path 43037 43038 windows_path="$new_path" 43039 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43040 unix_path=`$CYGPATH -u "$windows_path"` 43041 new_path="$unix_path" 43042 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43043 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43044 new_path="$unix_path" 43045 fi 43046 43047 # remove trailing .exe if any 43048 new_path="${new_path/%.exe/}" 43049 43050 # Save the first 10 bytes of this path to the storage, so fixpath can work. 43051 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 43052 fi 43053 43054 else 43055 # We're on a unix platform. Hooray! :) 43056 # First separate the path from the arguments. This will split at the first 43057 # space. 43058 complete="$OBJCOPY" 43059 path="${complete%% *}" 43060 tmp="$complete EOL" 43061 arguments="${tmp#* }" 43062 43063 # Cannot rely on the command "which" here since it doesn't always work. 43064 is_absolute_path=`$ECHO "$path" | $GREP ^/` 43065 if test -z "$is_absolute_path"; then 43066 # Path to executable is not absolute. Find it. 43067 IFS_save="$IFS" 43068 IFS=: 43069 for p in $PATH; do 43070 if test -f "$p/$path" && test -x "$p/$path"; then 43071 new_path="$p/$path" 43072 break 43073 fi 43074 done 43075 IFS="$IFS_save" 43076 else 43077 # This is an absolute path, we can use it without further modifications. 43078 new_path="$path" 43079 fi 43080 43081 if test "x$new_path" = x; then 43082 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5 43083 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 43084 has_space=`$ECHO "$complete" | $GREP " "` 43085 if test "x$has_space" != x; then 43086 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 43087 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 43088 fi 43089 as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5 43090 fi 43091 fi 43092 43093 # Now join together the path and the arguments once again 43094 if test "x$arguments" != xEOL; then 43095 new_complete="$new_path ${arguments% *}" 43096 else 43097 new_complete="$new_path" 43098 fi 43099 43100 if test "x$complete" != "x$new_complete"; then 43101 OBJCOPY="$new_complete" 43102 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OBJCOPY to \"$new_complete\"" >&5 43103 $as_echo "$as_me: Rewriting OBJCOPY to \"$new_complete\"" >&6;} 43104 fi 43105 fi 43106 43107 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 43108 # objcopy prior to 2.21.1 on solaris is broken and is not usable. 43109 # Rewrite objcopy version output to VALID_VERSION or BAD_VERSION. 43110 # - version number is last blank separate word on first line 43111 # - version number formats that have been seen: 43112 # - <major>.<minor> 43113 # - <major>.<minor>.<micro> 43114 OBJCOPY_VERSION=`$OBJCOPY --version | $HEAD -n 1` 43115 # The outer [ ] is to prevent m4 from eating the [] in the sed expression. 43116 OBJCOPY_VERSION_CHECK=`$ECHO $OBJCOPY_VERSION | $SED -n \ 43117 -e 's/.* //' \ 43118 -e '/^[01]\./b bad' \ 43119 -e '/^2\./{' \ 43120 -e ' s/^2\.//' \ 43121 -e ' /^[0-9]$/b bad' \ 43122 -e ' /^[0-9]\./b bad' \ 43123 -e ' /^1[0-9]$/b bad' \ 43124 -e ' /^1[0-9]\./b bad' \ 43125 -e ' /^20\./b bad' \ 43126 -e ' /^21\.0$/b bad' \ 43127 -e ' /^21\.0\./b bad' \ 43128 -e '}' \ 43129 -e ':good' \ 43130 -e 's/.*/VALID_VERSION/p' \ 43131 -e 'q' \ 43132 -e ':bad' \ 43133 -e 's/.*/BAD_VERSION/p' \ 43134 -e 'q'` 43135 if test "x$OBJCOPY_VERSION_CHECK" = xBAD_VERSION; then 43136 OBJCOPY= 43137 { $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 43138 $as_echo "$as_me: WARNING: Ignoring found objcopy since it is broken (prior to 2.21.1). No debug symbols will be generated." >&2;} 43139 { $as_echo "$as_me:${as_lineno-$LINENO}: objcopy reports version $OBJCOPY_VERSION" >&5 43140 $as_echo "$as_me: objcopy reports version $OBJCOPY_VERSION" >&6;} 43141 { $as_echo "$as_me:${as_lineno-$LINENO}: Note: patch 149063-01 or newer contains the correct Solaris 10 SPARC version" >&5 43142 $as_echo "$as_me: Note: patch 149063-01 or newer contains the correct Solaris 10 SPARC version" >&6;} 43143 { $as_echo "$as_me:${as_lineno-$LINENO}: Note: patch 149064-01 or newer contains the correct Solaris 10 X86 version" >&5 43144 $as_echo "$as_me: Note: patch 149064-01 or newer contains the correct Solaris 10 X86 version" >&6;} 43145 { $as_echo "$as_me:${as_lineno-$LINENO}: Note: Solaris 11 Update 1 contains the correct version" >&5 43146 $as_echo "$as_me: Note: Solaris 11 Update 1 contains the correct version" >&6;} 43147 fi 43148 fi 43149 fi 43150 fi 43151 43152 43153 43154 # Publish this variable in the help. 43155 43156 43157 if [ -z "${OBJDUMP+x}" ]; then 43158 # The variable is not set by user, try to locate tool using the code snippet 43159 if test -n "$ac_tool_prefix"; then 43160 for ac_prog in gobjdump objdump 43161 do 43162 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 43163 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 43164 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43165 $as_echo_n "checking for $ac_word... " >&6; } 43166 if ${ac_cv_prog_OBJDUMP+:} false; then : 43167 $as_echo_n "(cached) " >&6 43168 else 43169 if test -n "$OBJDUMP"; then 43170 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. 43171 else 43172 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43173 for as_dir in $PATH 43174 do 43175 IFS=$as_save_IFS 43176 test -z "$as_dir" && as_dir=. 43177 for ac_exec_ext in '' $ac_executable_extensions; do 43178 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43179 ac_cv_prog_OBJDUMP="$ac_tool_prefix$ac_prog" 43180 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43181 break 2 43182 fi 43183 done 43184 done 43185 IFS=$as_save_IFS 43186 43187 fi 43188 fi 43189 OBJDUMP=$ac_cv_prog_OBJDUMP 43190 if test -n "$OBJDUMP"; then 43191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 43192 $as_echo "$OBJDUMP" >&6; } 43193 else 43194 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43195 $as_echo "no" >&6; } 43196 fi 43197 43198 43199 test -n "$OBJDUMP" && break 43200 done 43201 fi 43202 if test -z "$OBJDUMP"; then 43203 ac_ct_OBJDUMP=$OBJDUMP 43204 for ac_prog in gobjdump objdump 43205 do 43206 # Extract the first word of "$ac_prog", so it can be a program name with args. 43207 set dummy $ac_prog; ac_word=$2 43208 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43209 $as_echo_n "checking for $ac_word... " >&6; } 43210 if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then : 43211 $as_echo_n "(cached) " >&6 43212 else 43213 if test -n "$ac_ct_OBJDUMP"; then 43214 ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. 43215 else 43216 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43217 for as_dir in $PATH 43218 do 43219 IFS=$as_save_IFS 43220 test -z "$as_dir" && as_dir=. 43221 for ac_exec_ext in '' $ac_executable_extensions; do 43222 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43223 ac_cv_prog_ac_ct_OBJDUMP="$ac_prog" 43224 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43225 break 2 43226 fi 43227 done 43228 done 43229 IFS=$as_save_IFS 43230 43231 fi 43232 fi 43233 ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP 43234 if test -n "$ac_ct_OBJDUMP"; then 43235 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 43236 $as_echo "$ac_ct_OBJDUMP" >&6; } 43237 else 43238 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43239 $as_echo "no" >&6; } 43240 fi 43241 43242 43243 test -n "$ac_ct_OBJDUMP" && break 43244 done 43245 43246 if test "x$ac_ct_OBJDUMP" = x; then 43247 OBJDUMP="" 43248 else 43249 case $cross_compiling:$ac_tool_warned in 43250 yes:) 43251 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 43252 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 43253 ac_tool_warned=yes ;; 43254 esac 43255 OBJDUMP=$ac_ct_OBJDUMP 43256 fi 43257 fi 43258 43259 else 43260 # The variable is set, but is it from the command line or the environment? 43261 43262 # Try to remove the string !OBJDUMP! from our list. 43263 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!OBJDUMP!/} 43264 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 43265 # If it failed, the variable was not from the command line. Ignore it, 43266 # but warn the user (except for BASH, which is always set by the calling BASH). 43267 if test "xOBJDUMP" != xBASH; then 43268 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of OBJDUMP from the environment. Use command line variables instead." >&5 43269 $as_echo "$as_me: WARNING: Ignoring value of OBJDUMP from the environment. Use command line variables instead." >&2;} 43270 fi 43271 # Try to locate tool using the code snippet 43272 if test -n "$ac_tool_prefix"; then 43273 for ac_prog in gobjdump objdump 43274 do 43275 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 43276 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 43277 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43278 $as_echo_n "checking for $ac_word... " >&6; } 43279 if ${ac_cv_prog_OBJDUMP+:} false; then : 43280 $as_echo_n "(cached) " >&6 43281 else 43282 if test -n "$OBJDUMP"; then 43283 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. 43284 else 43285 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43286 for as_dir in $PATH 43287 do 43288 IFS=$as_save_IFS 43289 test -z "$as_dir" && as_dir=. 43290 for ac_exec_ext in '' $ac_executable_extensions; do 43291 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43292 ac_cv_prog_OBJDUMP="$ac_tool_prefix$ac_prog" 43293 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43294 break 2 43295 fi 43296 done 43297 done 43298 IFS=$as_save_IFS 43299 43300 fi 43301 fi 43302 OBJDUMP=$ac_cv_prog_OBJDUMP 43303 if test -n "$OBJDUMP"; then 43304 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 43305 $as_echo "$OBJDUMP" >&6; } 43306 else 43307 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43308 $as_echo "no" >&6; } 43309 fi 43310 43311 43312 test -n "$OBJDUMP" && break 43313 done 43314 fi 43315 if test -z "$OBJDUMP"; then 43316 ac_ct_OBJDUMP=$OBJDUMP 43317 for ac_prog in gobjdump objdump 43318 do 43319 # Extract the first word of "$ac_prog", so it can be a program name with args. 43320 set dummy $ac_prog; ac_word=$2 43321 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43322 $as_echo_n "checking for $ac_word... " >&6; } 43323 if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then : 43324 $as_echo_n "(cached) " >&6 43325 else 43326 if test -n "$ac_ct_OBJDUMP"; then 43327 ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. 43328 else 43329 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43330 for as_dir in $PATH 43331 do 43332 IFS=$as_save_IFS 43333 test -z "$as_dir" && as_dir=. 43334 for ac_exec_ext in '' $ac_executable_extensions; do 43335 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43336 ac_cv_prog_ac_ct_OBJDUMP="$ac_prog" 43337 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43338 break 2 43339 fi 43340 done 43341 done 43342 IFS=$as_save_IFS 43343 43344 fi 43345 fi 43346 ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP 43347 if test -n "$ac_ct_OBJDUMP"; then 43348 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 43349 $as_echo "$ac_ct_OBJDUMP" >&6; } 43350 else 43351 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43352 $as_echo "no" >&6; } 43353 fi 43354 43355 43356 test -n "$ac_ct_OBJDUMP" && break 43357 done 43358 43359 if test "x$ac_ct_OBJDUMP" = x; then 43360 OBJDUMP="" 43361 else 43362 case $cross_compiling:$ac_tool_warned in 43363 yes:) 43364 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 43365 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 43366 ac_tool_warned=yes ;; 43367 esac 43368 OBJDUMP=$ac_ct_OBJDUMP 43369 fi 43370 fi 43371 43372 else 43373 # If it succeeded, then it was overridden by the user. We will use it 43374 # for the tool. 43375 43376 # First remove it from the list of overridden variables, so we can test 43377 # for unknown variables in the end. 43378 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 43379 43380 # Check if we try to supply an empty value 43381 if test "x$OBJDUMP" = x; then 43382 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool OBJDUMP= (no value)" >&5 43383 $as_echo "$as_me: Setting user supplied tool OBJDUMP= (no value)" >&6;} 43384 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJDUMP" >&5 43385 $as_echo_n "checking for OBJDUMP... " >&6; } 43386 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 43387 $as_echo "disabled" >&6; } 43388 else 43389 # Check if the provided tool contains a complete path. 43390 tool_specified="$OBJDUMP" 43391 tool_basename="${tool_specified##*/}" 43392 if test "x$tool_basename" = "x$tool_specified"; then 43393 # A command without a complete path is provided, search $PATH. 43394 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool OBJDUMP=$tool_basename" >&5 43395 $as_echo "$as_me: Will search for user supplied tool OBJDUMP=$tool_basename" >&6;} 43396 # Extract the first word of "$tool_basename", so it can be a program name with args. 43397 set dummy $tool_basename; ac_word=$2 43398 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43399 $as_echo_n "checking for $ac_word... " >&6; } 43400 if ${ac_cv_path_OBJDUMP+:} false; then : 43401 $as_echo_n "(cached) " >&6 43402 else 43403 case $OBJDUMP in 43404 [\\/]* | ?:[\\/]*) 43405 ac_cv_path_OBJDUMP="$OBJDUMP" # Let the user override the test with a path. 43406 ;; 43407 *) 43408 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43409 for as_dir in $PATH 43410 do 43411 IFS=$as_save_IFS 43412 test -z "$as_dir" && as_dir=. 43413 for ac_exec_ext in '' $ac_executable_extensions; do 43414 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43415 ac_cv_path_OBJDUMP="$as_dir/$ac_word$ac_exec_ext" 43416 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43417 break 2 43418 fi 43419 done 43420 done 43421 IFS=$as_save_IFS 43422 43423 ;; 43424 esac 43425 fi 43426 OBJDUMP=$ac_cv_path_OBJDUMP 43427 if test -n "$OBJDUMP"; then 43428 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 43429 $as_echo "$OBJDUMP" >&6; } 43430 else 43431 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43432 $as_echo "no" >&6; } 43433 fi 43434 43435 43436 if test "x$OBJDUMP" = x; then 43437 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 43438 fi 43439 else 43440 # Otherwise we believe it is a complete path. Use it as it is. 43441 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool OBJDUMP=$tool_specified" >&5 43442 $as_echo "$as_me: Will use user supplied tool OBJDUMP=$tool_specified" >&6;} 43443 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJDUMP" >&5 43444 $as_echo_n "checking for OBJDUMP... " >&6; } 43445 if test ! -x "$tool_specified"; then 43446 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 43447 $as_echo "not found" >&6; } 43448 as_fn_error $? "User supplied tool OBJDUMP=$tool_specified does not exist or is not executable" "$LINENO" 5 43449 fi 43450 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 43451 $as_echo "$tool_specified" >&6; } 43452 fi 43453 fi 43454 fi 43455 43456 fi 43457 43458 43459 if test "x$OBJDUMP" != x; then 43460 # Only used for compare.sh; we can live without it. BASIC_FIXUP_EXECUTABLE 43461 # bails if argument is missing. 43462 43463 # Only process if variable expands to non-empty 43464 43465 if test "x$OBJDUMP" != x; then 43466 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43467 43468 # First separate the path from the arguments. This will split at the first 43469 # space. 43470 complete="$OBJDUMP" 43471 path="${complete%% *}" 43472 tmp="$complete EOL" 43473 arguments="${tmp#* }" 43474 43475 # Input might be given as Windows format, start by converting to 43476 # unix format. 43477 new_path=`$CYGPATH -u "$path"` 43478 43479 # Now try to locate executable using which 43480 new_path=`$WHICH "$new_path" 2> /dev/null` 43481 # bat and cmd files are not always considered executable in cygwin causing which 43482 # to not find them 43483 if test "x$new_path" = x \ 43484 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 43485 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 43486 new_path=`$CYGPATH -u "$path"` 43487 fi 43488 if test "x$new_path" = x; then 43489 # Oops. Which didn't find the executable. 43490 # The splitting of arguments from the executable at a space might have been incorrect, 43491 # since paths with space are more likely in Windows. Give it another try with the whole 43492 # argument. 43493 path="$complete" 43494 arguments="EOL" 43495 new_path=`$CYGPATH -u "$path"` 43496 new_path=`$WHICH "$new_path" 2> /dev/null` 43497 # bat and cmd files are not always considered executable in cygwin causing which 43498 # to not find them 43499 if test "x$new_path" = x \ 43500 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 43501 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 43502 new_path=`$CYGPATH -u "$path"` 43503 fi 43504 if test "x$new_path" = x; then 43505 # It's still not found. Now this is an unrecoverable error. 43506 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5 43507 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;} 43508 has_space=`$ECHO "$complete" | $GREP " "` 43509 if test "x$has_space" != x; then 43510 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 43511 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 43512 fi 43513 as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5 43514 fi 43515 fi 43516 43517 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 43518 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 43519 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 43520 # "foo.exe" is OK but "foo" is an error. 43521 # 43522 # This test is therefore slightly more accurate than "test -f" to check for file presence. 43523 # It is also a way to make sure we got the proper file name for the real test later on. 43524 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 43525 if test "x$test_shortpath" = x; then 43526 # Short path failed, file does not exist as specified. 43527 # Try adding .exe or .cmd 43528 if test -f "${new_path}.exe"; then 43529 input_to_shortpath="${new_path}.exe" 43530 elif test -f "${new_path}.cmd"; then 43531 input_to_shortpath="${new_path}.cmd" 43532 else 43533 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$new_path\", is invalid." >&5 43534 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$new_path\", is invalid." >&6;} 43535 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 43536 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 43537 as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5 43538 fi 43539 else 43540 input_to_shortpath="$new_path" 43541 fi 43542 43543 # Call helper function which possibly converts this using DOS-style short mode. 43544 # If so, the updated path is stored in $new_path. 43545 new_path="$input_to_shortpath" 43546 43547 input_path="$input_to_shortpath" 43548 # Check if we need to convert this using DOS-style short mode. If the path 43549 # contains just simple characters, use it. Otherwise (spaces, weird characters), 43550 # take no chances and rewrite it. 43551 # Note: m4 eats our [], so we need to use [ and ] instead. 43552 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 43553 if test "x$has_forbidden_chars" != x; then 43554 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 43555 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 43556 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 43557 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 43558 # Going to short mode and back again did indeed matter. Since short mode is 43559 # case insensitive, let's make it lowercase to improve readability. 43560 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 43561 # Now convert it back to Unix-style (cygpath) 43562 input_path=`$CYGPATH -u "$shortmode_path"` 43563 new_path="$input_path" 43564 fi 43565 fi 43566 43567 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 43568 if test "x$test_cygdrive_prefix" = x; then 43569 # As a simple fix, exclude /usr/bin since it's not a real path. 43570 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 43571 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 43572 # a path prefixed by /cygdrive for fixpath to work. 43573 new_path="$CYGWIN_ROOT_PATH$input_path" 43574 fi 43575 fi 43576 43577 # remove trailing .exe if any 43578 new_path="${new_path/%.exe/}" 43579 43580 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43581 43582 # First separate the path from the arguments. This will split at the first 43583 # space. 43584 complete="$OBJDUMP" 43585 path="${complete%% *}" 43586 tmp="$complete EOL" 43587 arguments="${tmp#* }" 43588 43589 # Input might be given as Windows format, start by converting to 43590 # unix format. 43591 new_path="$path" 43592 43593 windows_path="$new_path" 43594 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43595 unix_path=`$CYGPATH -u "$windows_path"` 43596 new_path="$unix_path" 43597 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43598 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43599 new_path="$unix_path" 43600 fi 43601 43602 43603 # Now try to locate executable using which 43604 new_path=`$WHICH "$new_path" 2> /dev/null` 43605 43606 if test "x$new_path" = x; then 43607 # Oops. Which didn't find the executable. 43608 # The splitting of arguments from the executable at a space might have been incorrect, 43609 # since paths with space are more likely in Windows. Give it another try with the whole 43610 # argument. 43611 path="$complete" 43612 arguments="EOL" 43613 new_path="$path" 43614 43615 windows_path="$new_path" 43616 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43617 unix_path=`$CYGPATH -u "$windows_path"` 43618 new_path="$unix_path" 43619 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43620 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43621 new_path="$unix_path" 43622 fi 43623 43624 43625 new_path=`$WHICH "$new_path" 2> /dev/null` 43626 # bat and cmd files are not always considered executable in MSYS causing which 43627 # to not find them 43628 if test "x$new_path" = x \ 43629 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 43630 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 43631 new_path="$path" 43632 43633 windows_path="$new_path" 43634 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43635 unix_path=`$CYGPATH -u "$windows_path"` 43636 new_path="$unix_path" 43637 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43638 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43639 new_path="$unix_path" 43640 fi 43641 43642 fi 43643 43644 if test "x$new_path" = x; then 43645 # It's still not found. Now this is an unrecoverable error. 43646 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5 43647 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;} 43648 has_space=`$ECHO "$complete" | $GREP " "` 43649 if test "x$has_space" != x; then 43650 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 43651 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 43652 fi 43653 as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5 43654 fi 43655 fi 43656 43657 # Now new_path has a complete unix path to the binary 43658 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 43659 # Keep paths in /bin as-is, but remove trailing .exe if any 43660 new_path="${new_path/%.exe/}" 43661 # Do not save /bin paths to all_fixpath_prefixes! 43662 else 43663 # Not in mixed or Windows style, start by that. 43664 new_path=`cmd //c echo $new_path` 43665 43666 input_path="$new_path" 43667 # Check if we need to convert this using DOS-style short mode. If the path 43668 # contains just simple characters, use it. Otherwise (spaces, weird characters), 43669 # take no chances and rewrite it. 43670 # Note: m4 eats our [], so we need to use [ and ] instead. 43671 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 43672 if test "x$has_forbidden_chars" != x; then 43673 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 43674 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 43675 fi 43676 43677 # Output is in $new_path 43678 43679 windows_path="$new_path" 43680 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43681 unix_path=`$CYGPATH -u "$windows_path"` 43682 new_path="$unix_path" 43683 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43684 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43685 new_path="$unix_path" 43686 fi 43687 43688 # remove trailing .exe if any 43689 new_path="${new_path/%.exe/}" 43690 43691 # Save the first 10 bytes of this path to the storage, so fixpath can work. 43692 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 43693 fi 43694 43695 else 43696 # We're on a unix platform. Hooray! :) 43697 # First separate the path from the arguments. This will split at the first 43698 # space. 43699 complete="$OBJDUMP" 43700 path="${complete%% *}" 43701 tmp="$complete EOL" 43702 arguments="${tmp#* }" 43703 43704 # Cannot rely on the command "which" here since it doesn't always work. 43705 is_absolute_path=`$ECHO "$path" | $GREP ^/` 43706 if test -z "$is_absolute_path"; then 43707 # Path to executable is not absolute. Find it. 43708 IFS_save="$IFS" 43709 IFS=: 43710 for p in $PATH; do 43711 if test -f "$p/$path" && test -x "$p/$path"; then 43712 new_path="$p/$path" 43713 break 43714 fi 43715 done 43716 IFS="$IFS_save" 43717 else 43718 # This is an absolute path, we can use it without further modifications. 43719 new_path="$path" 43720 fi 43721 43722 if test "x$new_path" = x; then 43723 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5 43724 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;} 43725 has_space=`$ECHO "$complete" | $GREP " "` 43726 if test "x$has_space" != x; then 43727 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 43728 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 43729 fi 43730 as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5 43731 fi 43732 fi 43733 43734 # Now join together the path and the arguments once again 43735 if test "x$arguments" != xEOL; then 43736 new_complete="$new_path ${arguments% *}" 43737 else 43738 new_complete="$new_path" 43739 fi 43740 43741 if test "x$complete" != "x$new_complete"; then 43742 OBJDUMP="$new_complete" 43743 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OBJDUMP to \"$new_complete\"" >&5 43744 $as_echo "$as_me: Rewriting OBJDUMP to \"$new_complete\"" >&6;} 43745 fi 43746 fi 43747 43748 fi 43749 43750 43751 # Restore old path, except for the microsoft toolchain, which requires VS_PATH 43752 # to remain in place. Otherwise the compiler will not work in some siutations 43753 # in later configure checks. 43754 if test "x$TOOLCHAIN_TYPE" != "xmicrosoft"; then 43755 PATH="$OLD_PATH" 43756 fi 43757 43758 # Restore the flags to the user specified values. 43759 # This is necessary since AC_PROG_CC defaults CFLAGS to "-g -O2" 43760 CFLAGS="$ORG_CFLAGS" 43761 CXXFLAGS="$ORG_CXXFLAGS" 43762 43763 43764 # Finally do some processing after the detection phase 43765 43766 if test "x$COMPILE_TYPE" = "xcross"; then 43767 # Now we need to find a C/C++ compiler that can build executables for the 43768 # build platform. We can't use the AC_PROG_CC macro, since it can only be 43769 # used once. Also, we need to do this without adding a tools dir to the 43770 # path, otherwise we might pick up cross-compilers which don't use standard 43771 # naming. 43772 43773 OLDPATH="$PATH" 43774 43775 43776 # Check whether --with-build-devkit was given. 43777 if test "${with_build_devkit+set}" = set; then : 43778 withval=$with_build_devkit; 43779 fi 43780 43781 if test "x$with_build_devkit" = "xyes"; then 43782 as_fn_error $? "--with-build-devkit must have a value" "$LINENO" 5 43783 elif test -n "$with_build_devkit"; then 43784 if test ! -d "$with_build_devkit"; then 43785 as_fn_error $? "--with-build-devkit points to non existing dir: $with_build_devkit" "$LINENO" 5 43786 else 43787 43788 # Only process if variable expands to non-empty 43789 43790 if test "x$with_build_devkit" != x; then 43791 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43792 43793 # Input might be given as Windows format, start by converting to 43794 # unix format. 43795 path="$with_build_devkit" 43796 new_path=`$CYGPATH -u "$path"` 43797 43798 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 43799 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 43800 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 43801 # "foo.exe" is OK but "foo" is an error. 43802 # 43803 # This test is therefore slightly more accurate than "test -f" to check for file precense. 43804 # It is also a way to make sure we got the proper file name for the real test later on. 43805 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 43806 if test "x$test_shortpath" = x; then 43807 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_build_devkit, which resolves as \"$path\", is invalid." >&5 43808 $as_echo "$as_me: The path of with_build_devkit, which resolves as \"$path\", is invalid." >&6;} 43809 as_fn_error $? "Cannot locate the the path of with_build_devkit" "$LINENO" 5 43810 fi 43811 43812 # Call helper function which possibly converts this using DOS-style short mode. 43813 # If so, the updated path is stored in $new_path. 43814 43815 input_path="$new_path" 43816 # Check if we need to convert this using DOS-style short mode. If the path 43817 # contains just simple characters, use it. Otherwise (spaces, weird characters), 43818 # take no chances and rewrite it. 43819 # Note: m4 eats our [], so we need to use [ and ] instead. 43820 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 43821 if test "x$has_forbidden_chars" != x; then 43822 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 43823 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 43824 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 43825 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 43826 # Going to short mode and back again did indeed matter. Since short mode is 43827 # case insensitive, let's make it lowercase to improve readability. 43828 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 43829 # Now convert it back to Unix-style (cygpath) 43830 input_path=`$CYGPATH -u "$shortmode_path"` 43831 new_path="$input_path" 43832 fi 43833 fi 43834 43835 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 43836 if test "x$test_cygdrive_prefix" = x; then 43837 # As a simple fix, exclude /usr/bin since it's not a real path. 43838 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 43839 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 43840 # a path prefixed by /cygdrive for fixpath to work. 43841 new_path="$CYGWIN_ROOT_PATH$input_path" 43842 fi 43843 fi 43844 43845 43846 if test "x$path" != "x$new_path"; then 43847 with_build_devkit="$new_path" 43848 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_build_devkit to \"$new_path\"" >&5 43849 $as_echo "$as_me: Rewriting with_build_devkit to \"$new_path\"" >&6;} 43850 fi 43851 43852 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43853 43854 path="$with_build_devkit" 43855 has_colon=`$ECHO $path | $GREP ^.:` 43856 new_path="$path" 43857 if test "x$has_colon" = x; then 43858 # Not in mixed or Windows style, start by that. 43859 new_path=`cmd //c echo $path` 43860 fi 43861 43862 43863 input_path="$new_path" 43864 # Check if we need to convert this using DOS-style short mode. If the path 43865 # contains just simple characters, use it. Otherwise (spaces, weird characters), 43866 # take no chances and rewrite it. 43867 # Note: m4 eats our [], so we need to use [ and ] instead. 43868 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 43869 if test "x$has_forbidden_chars" != x; then 43870 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 43871 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 43872 fi 43873 43874 43875 windows_path="$new_path" 43876 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43877 unix_path=`$CYGPATH -u "$windows_path"` 43878 new_path="$unix_path" 43879 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43880 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43881 new_path="$unix_path" 43882 fi 43883 43884 if test "x$path" != "x$new_path"; then 43885 with_build_devkit="$new_path" 43886 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_build_devkit to \"$new_path\"" >&5 43887 $as_echo "$as_me: Rewriting with_build_devkit to \"$new_path\"" >&6;} 43888 fi 43889 43890 # Save the first 10 bytes of this path to the storage, so fixpath can work. 43891 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 43892 43893 else 43894 # We're on a unix platform. Hooray! :) 43895 path="$with_build_devkit" 43896 has_space=`$ECHO "$path" | $GREP " "` 43897 if test "x$has_space" != x; then 43898 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_build_devkit, which resolves as \"$path\", is invalid." >&5 43899 $as_echo "$as_me: The path of with_build_devkit, which resolves as \"$path\", is invalid." >&6;} 43900 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 43901 fi 43902 43903 # Use eval to expand a potential ~ 43904 eval path="$path" 43905 if test ! -f "$path" && test ! -d "$path"; then 43906 as_fn_error $? "The path of with_build_devkit, which resolves as \"$path\", is not found." "$LINENO" 5 43907 fi 43908 43909 if test -d "$path"; then 43910 with_build_devkit="`cd "$path"; $THEPWDCMD -L`" 43911 else 43912 dir="`$DIRNAME "$path"`" 43913 base="`$BASENAME "$path"`" 43914 with_build_devkit="`cd "$dir"; $THEPWDCMD -L`/$base" 43915 fi 43916 fi 43917 fi 43918 43919 BUILD_DEVKIT_ROOT="$with_build_devkit" 43920 # Check for a meta data info file in the root of the devkit 43921 if test -f "$BUILD_DEVKIT_ROOT/devkit.info"; then 43922 # Process devkit.info so that existing devkit variables are not 43923 # modified by this 43924 $SED -e "s/^DEVKIT_/BUILD_DEVKIT_/g" \ 43925 -e "s/\$DEVKIT_ROOT/\$BUILD_DEVKIT_ROOT/g" \ 43926 -e "s/\$host/\$build/g" \ 43927 $BUILD_DEVKIT_ROOT/devkit.info \ 43928 > $CONFIGURESUPPORT_OUTPUTDIR/build-devkit.info 43929 . $CONFIGURESUPPORT_OUTPUTDIR/build-devkit.info 43930 # This potentially sets the following: 43931 # A descriptive name of the devkit 43932 43933 if test "x$BUILD_DEVKIT_NAME" = x; then 43934 eval BUILD_DEVKIT_NAME="\${BUILD_DEVKIT_NAME_${OPENJDK_TARGET_CPU}}" 43935 fi 43936 43937 # Corresponds to --with-extra-path 43938 43939 if test "x$BUILD_DEVKIT_EXTRA_PATH" = x; then 43940 eval BUILD_DEVKIT_EXTRA_PATH="\${BUILD_DEVKIT_EXTRA_PATH_${OPENJDK_TARGET_CPU}}" 43941 fi 43942 43943 # Corresponds to --with-toolchain-path 43944 43945 if test "x$BUILD_DEVKIT_TOOLCHAIN_PATH" = x; then 43946 eval BUILD_DEVKIT_TOOLCHAIN_PATH="\${BUILD_DEVKIT_TOOLCHAIN_PATH_${OPENJDK_TARGET_CPU}}" 43947 fi 43948 43949 # Corresponds to --with-sysroot 43950 43951 if test "x$BUILD_DEVKIT_SYSROOT" = x; then 43952 eval BUILD_DEVKIT_SYSROOT="\${BUILD_DEVKIT_SYSROOT_${OPENJDK_TARGET_CPU}}" 43953 fi 43954 43955 # Skip the Window specific parts 43956 fi 43957 43958 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for build platform devkit" >&5 43959 $as_echo_n "checking for build platform devkit... " >&6; } 43960 if test "x$BUILD_DEVKIT_NAME" != x; then 43961 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_DEVKIT_NAME in $BUILD_DEVKIT_ROOT" >&5 43962 $as_echo "$BUILD_DEVKIT_NAME in $BUILD_DEVKIT_ROOT" >&6; } 43963 else 43964 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_DEVKIT_ROOT" >&5 43965 $as_echo "$BUILD_DEVKIT_ROOT" >&6; } 43966 fi 43967 43968 BUILD_SYSROOT="$BUILD_DEVKIT_SYSROOT" 43969 43970 if test "x$BUILD_SYSROOT" != "x"; then 43971 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 43972 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 43973 # Solaris Studio does not have a concept of sysroot. Instead we must 43974 # make sure the default include and lib dirs are appended to each 43975 # compile and link command line. Must also add -I-xbuiltin to enable 43976 # inlining of system functions and intrinsics. 43977 BUILD_SYSROOT_CFLAGS="-I-xbuiltin -I$BUILD_SYSROOT/usr/include" 43978 BUILD_SYSROOT_LDFLAGS="-L$BUILD_SYSROOT/usr/lib$OPENJDK_TARGET_CPU_ISADIR \ 43979 -L$BUILD_SYSROOT/lib$OPENJDK_TARGET_CPU_ISADIR" 43980 fi 43981 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 43982 BUILD_SYSROOT_CFLAGS="--sysroot=$BUILD_SYSROOT" 43983 BUILD_SYSROOT_LDFLAGS="--sysroot=$BUILD_SYSROOT" 43984 elif test "x$TOOLCHAIN_TYPE" = xclang; then 43985 BUILD_SYSROOT_CFLAGS="-isysroot $BUILD_SYSROOT" 43986 BUILD_SYSROOT_LDFLAGS="-isysroot $BUILD_SYSROOT" 43987 fi 43988 # Propagate the sysroot args to hotspot 43989 BUILD_LEGACY_EXTRA_CFLAGS="$BUILD_LEGACY_EXTRA_CFLAGS $BUILD_SYSROOT_CFLAGS" 43990 BUILD_LEGACY_EXTRA_CXXFLAGS="$BUILD_LEGACY_EXTRA_CXXFLAGS $BUILD_SYSROOT_CFLAGS" 43991 BUILD_LEGACY_EXTRA_LDFLAGS="$BUILD_LEGACY_EXTRA_LDFLAGS $BUILD_SYSROOT_LDFLAGS" 43992 # The global CFLAGS and LDFLAGS variables need these for configure to function 43993 BUILD_CFLAGS="$BUILD_CFLAGS $BUILD_SYSROOT_CFLAGS" 43994 BUILD_CPPFLAGS="$BUILD_CPPFLAGS $BUILD_SYSROOT_CFLAGS" 43995 BUILD_CXXFLAGS="$BUILD_CXXFLAGS $BUILD_SYSROOT_CFLAGS" 43996 BUILD_LDFLAGS="$BUILD_LDFLAGS $BUILD_SYSROOT_LDFLAGS" 43997 fi 43998 43999 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 44000 # We also need -iframework<path>/System/Library/Frameworks 44001 BUILD_SYSROOT_CFLAGS="$BUILD_SYSROOT_CFLAGS -iframework $BUILD_SYSROOT/System/Library/Frameworks" 44002 BUILD_SYSROOT_LDFLAGS="$BUILD_SYSROOT_LDFLAGS -iframework $BUILD_SYSROOT/System/Library/Frameworks" 44003 # These always need to be set, or we can't find the frameworks embedded in JavaVM.framework 44004 # set this here so it doesn't have to be peppered throughout the forest 44005 BUILD_SYSROOT_CFLAGS="$BUILD_SYSROOT_CFLAGS -F $BUILD_SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks" 44006 BUILD_SYSROOT_LDFLAGS="$BUILD_SYSROOT_LDFLAGS -F $BUILD_SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks" 44007 fi 44008 44009 44010 44011 44012 44013 # Fallback default of just /bin if DEVKIT_PATH is not defined 44014 if test "x$BUILD_DEVKIT_TOOLCHAIN_PATH" = x; then 44015 BUILD_DEVKIT_TOOLCHAIN_PATH="$BUILD_DEVKIT_ROOT/bin" 44016 fi 44017 PATH="$BUILD_DEVKIT_TOOLCHAIN_PATH:$BUILD_DEVKIT_EXTRA_PATH" 44018 fi 44019 fi 44020 44021 # FIXME: we should list the discovered compilers as an exclude pattern! 44022 # If we do that, we can do this detection before POST_DETECTION, and still 44023 # find the build compilers in the tools dir, if needed. 44024 44025 44026 44027 # Publish this variable in the help. 44028 44029 44030 if [ -z "${BUILD_CC+x}" ]; then 44031 # The variable is not set by user, try to locate tool using the code snippet 44032 for ac_prog in cl cc gcc 44033 do 44034 # Extract the first word of "$ac_prog", so it can be a program name with args. 44035 set dummy $ac_prog; ac_word=$2 44036 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44037 $as_echo_n "checking for $ac_word... " >&6; } 44038 if ${ac_cv_path_BUILD_CC+:} false; then : 44039 $as_echo_n "(cached) " >&6 44040 else 44041 case $BUILD_CC in 44042 [\\/]* | ?:[\\/]*) 44043 ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path. 44044 ;; 44045 *) 44046 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44047 for as_dir in $PATH 44048 do 44049 IFS=$as_save_IFS 44050 test -z "$as_dir" && as_dir=. 44051 for ac_exec_ext in '' $ac_executable_extensions; do 44052 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44053 ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext" 44054 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44055 break 2 44056 fi 44057 done 44058 done 44059 IFS=$as_save_IFS 44060 44061 ;; 44062 esac 44063 fi 44064 BUILD_CC=$ac_cv_path_BUILD_CC 44065 if test -n "$BUILD_CC"; then 44066 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5 44067 $as_echo "$BUILD_CC" >&6; } 44068 else 44069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44070 $as_echo "no" >&6; } 44071 fi 44072 44073 44074 test -n "$BUILD_CC" && break 44075 done 44076 44077 else 44078 # The variable is set, but is it from the command line or the environment? 44079 44080 # Try to remove the string !BUILD_CC! from our list. 44081 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_CC!/} 44082 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 44083 # If it failed, the variable was not from the command line. Ignore it, 44084 # but warn the user (except for BASH, which is always set by the calling BASH). 44085 if test "xBUILD_CC" != xBASH; then 44086 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_CC from the environment. Use command line variables instead." >&5 44087 $as_echo "$as_me: WARNING: Ignoring value of BUILD_CC from the environment. Use command line variables instead." >&2;} 44088 fi 44089 # Try to locate tool using the code snippet 44090 for ac_prog in cl cc gcc 44091 do 44092 # Extract the first word of "$ac_prog", so it can be a program name with args. 44093 set dummy $ac_prog; ac_word=$2 44094 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44095 $as_echo_n "checking for $ac_word... " >&6; } 44096 if ${ac_cv_path_BUILD_CC+:} false; then : 44097 $as_echo_n "(cached) " >&6 44098 else 44099 case $BUILD_CC in 44100 [\\/]* | ?:[\\/]*) 44101 ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path. 44102 ;; 44103 *) 44104 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44105 for as_dir in $PATH 44106 do 44107 IFS=$as_save_IFS 44108 test -z "$as_dir" && as_dir=. 44109 for ac_exec_ext in '' $ac_executable_extensions; do 44110 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44111 ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext" 44112 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44113 break 2 44114 fi 44115 done 44116 done 44117 IFS=$as_save_IFS 44118 44119 ;; 44120 esac 44121 fi 44122 BUILD_CC=$ac_cv_path_BUILD_CC 44123 if test -n "$BUILD_CC"; then 44124 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5 44125 $as_echo "$BUILD_CC" >&6; } 44126 else 44127 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44128 $as_echo "no" >&6; } 44129 fi 44130 44131 44132 test -n "$BUILD_CC" && break 44133 done 44134 44135 else 44136 # If it succeeded, then it was overridden by the user. We will use it 44137 # for the tool. 44138 44139 # First remove it from the list of overridden variables, so we can test 44140 # for unknown variables in the end. 44141 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 44142 44143 # Check if we try to supply an empty value 44144 if test "x$BUILD_CC" = x; then 44145 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_CC= (no value)" >&5 44146 $as_echo "$as_me: Setting user supplied tool BUILD_CC= (no value)" >&6;} 44147 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CC" >&5 44148 $as_echo_n "checking for BUILD_CC... " >&6; } 44149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 44150 $as_echo "disabled" >&6; } 44151 else 44152 # Check if the provided tool contains a complete path. 44153 tool_specified="$BUILD_CC" 44154 tool_basename="${tool_specified##*/}" 44155 if test "x$tool_basename" = "x$tool_specified"; then 44156 # A command without a complete path is provided, search $PATH. 44157 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_CC=$tool_basename" >&5 44158 $as_echo "$as_me: Will search for user supplied tool BUILD_CC=$tool_basename" >&6;} 44159 # Extract the first word of "$tool_basename", so it can be a program name with args. 44160 set dummy $tool_basename; ac_word=$2 44161 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44162 $as_echo_n "checking for $ac_word... " >&6; } 44163 if ${ac_cv_path_BUILD_CC+:} false; then : 44164 $as_echo_n "(cached) " >&6 44165 else 44166 case $BUILD_CC in 44167 [\\/]* | ?:[\\/]*) 44168 ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path. 44169 ;; 44170 *) 44171 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44172 for as_dir in $PATH 44173 do 44174 IFS=$as_save_IFS 44175 test -z "$as_dir" && as_dir=. 44176 for ac_exec_ext in '' $ac_executable_extensions; do 44177 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44178 ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext" 44179 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44180 break 2 44181 fi 44182 done 44183 done 44184 IFS=$as_save_IFS 44185 44186 ;; 44187 esac 44188 fi 44189 BUILD_CC=$ac_cv_path_BUILD_CC 44190 if test -n "$BUILD_CC"; then 44191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5 44192 $as_echo "$BUILD_CC" >&6; } 44193 else 44194 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44195 $as_echo "no" >&6; } 44196 fi 44197 44198 44199 if test "x$BUILD_CC" = x; then 44200 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 44201 fi 44202 else 44203 # Otherwise we believe it is a complete path. Use it as it is. 44204 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_CC=$tool_specified" >&5 44205 $as_echo "$as_me: Will use user supplied tool BUILD_CC=$tool_specified" >&6;} 44206 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CC" >&5 44207 $as_echo_n "checking for BUILD_CC... " >&6; } 44208 if test ! -x "$tool_specified"; then 44209 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 44210 $as_echo "not found" >&6; } 44211 as_fn_error $? "User supplied tool BUILD_CC=$tool_specified does not exist or is not executable" "$LINENO" 5 44212 fi 44213 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 44214 $as_echo "$tool_specified" >&6; } 44215 fi 44216 fi 44217 fi 44218 44219 fi 44220 44221 44222 44223 if test "x$BUILD_CC" = x; then 44224 as_fn_error $? "Could not find required tool for BUILD_CC" "$LINENO" 5 44225 fi 44226 44227 44228 44229 # Only process if variable expands to non-empty 44230 44231 if test "x$BUILD_CC" != x; then 44232 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44233 44234 # First separate the path from the arguments. This will split at the first 44235 # space. 44236 complete="$BUILD_CC" 44237 path="${complete%% *}" 44238 tmp="$complete EOL" 44239 arguments="${tmp#* }" 44240 44241 # Input might be given as Windows format, start by converting to 44242 # unix format. 44243 new_path=`$CYGPATH -u "$path"` 44244 44245 # Now try to locate executable using which 44246 new_path=`$WHICH "$new_path" 2> /dev/null` 44247 # bat and cmd files are not always considered executable in cygwin causing which 44248 # to not find them 44249 if test "x$new_path" = x \ 44250 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44251 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44252 new_path=`$CYGPATH -u "$path"` 44253 fi 44254 if test "x$new_path" = x; then 44255 # Oops. Which didn't find the executable. 44256 # The splitting of arguments from the executable at a space might have been incorrect, 44257 # since paths with space are more likely in Windows. Give it another try with the whole 44258 # argument. 44259 path="$complete" 44260 arguments="EOL" 44261 new_path=`$CYGPATH -u "$path"` 44262 new_path=`$WHICH "$new_path" 2> /dev/null` 44263 # bat and cmd files are not always considered executable in cygwin causing which 44264 # to not find them 44265 if test "x$new_path" = x \ 44266 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44267 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44268 new_path=`$CYGPATH -u "$path"` 44269 fi 44270 if test "x$new_path" = x; then 44271 # It's still not found. Now this is an unrecoverable error. 44272 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5 44273 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;} 44274 has_space=`$ECHO "$complete" | $GREP " "` 44275 if test "x$has_space" != x; then 44276 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 44277 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 44278 fi 44279 as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5 44280 fi 44281 fi 44282 44283 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 44284 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 44285 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 44286 # "foo.exe" is OK but "foo" is an error. 44287 # 44288 # This test is therefore slightly more accurate than "test -f" to check for file presence. 44289 # It is also a way to make sure we got the proper file name for the real test later on. 44290 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 44291 if test "x$test_shortpath" = x; then 44292 # Short path failed, file does not exist as specified. 44293 # Try adding .exe or .cmd 44294 if test -f "${new_path}.exe"; then 44295 input_to_shortpath="${new_path}.exe" 44296 elif test -f "${new_path}.cmd"; then 44297 input_to_shortpath="${new_path}.cmd" 44298 else 44299 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$new_path\", is invalid." >&5 44300 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$new_path\", is invalid." >&6;} 44301 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 44302 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 44303 as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5 44304 fi 44305 else 44306 input_to_shortpath="$new_path" 44307 fi 44308 44309 # Call helper function which possibly converts this using DOS-style short mode. 44310 # If so, the updated path is stored in $new_path. 44311 new_path="$input_to_shortpath" 44312 44313 input_path="$input_to_shortpath" 44314 # Check if we need to convert this using DOS-style short mode. If the path 44315 # contains just simple characters, use it. Otherwise (spaces, weird characters), 44316 # take no chances and rewrite it. 44317 # Note: m4 eats our [], so we need to use [ and ] instead. 44318 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 44319 if test "x$has_forbidden_chars" != x; then 44320 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 44321 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 44322 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 44323 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 44324 # Going to short mode and back again did indeed matter. Since short mode is 44325 # case insensitive, let's make it lowercase to improve readability. 44326 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 44327 # Now convert it back to Unix-style (cygpath) 44328 input_path=`$CYGPATH -u "$shortmode_path"` 44329 new_path="$input_path" 44330 fi 44331 fi 44332 44333 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 44334 if test "x$test_cygdrive_prefix" = x; then 44335 # As a simple fix, exclude /usr/bin since it's not a real path. 44336 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 44337 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 44338 # a path prefixed by /cygdrive for fixpath to work. 44339 new_path="$CYGWIN_ROOT_PATH$input_path" 44340 fi 44341 fi 44342 44343 # remove trailing .exe if any 44344 new_path="${new_path/%.exe/}" 44345 44346 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44347 44348 # First separate the path from the arguments. This will split at the first 44349 # space. 44350 complete="$BUILD_CC" 44351 path="${complete%% *}" 44352 tmp="$complete EOL" 44353 arguments="${tmp#* }" 44354 44355 # Input might be given as Windows format, start by converting to 44356 # unix format. 44357 new_path="$path" 44358 44359 windows_path="$new_path" 44360 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44361 unix_path=`$CYGPATH -u "$windows_path"` 44362 new_path="$unix_path" 44363 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44364 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44365 new_path="$unix_path" 44366 fi 44367 44368 44369 # Now try to locate executable using which 44370 new_path=`$WHICH "$new_path" 2> /dev/null` 44371 44372 if test "x$new_path" = x; then 44373 # Oops. Which didn't find the executable. 44374 # The splitting of arguments from the executable at a space might have been incorrect, 44375 # since paths with space are more likely in Windows. Give it another try with the whole 44376 # argument. 44377 path="$complete" 44378 arguments="EOL" 44379 new_path="$path" 44380 44381 windows_path="$new_path" 44382 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44383 unix_path=`$CYGPATH -u "$windows_path"` 44384 new_path="$unix_path" 44385 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44386 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44387 new_path="$unix_path" 44388 fi 44389 44390 44391 new_path=`$WHICH "$new_path" 2> /dev/null` 44392 # bat and cmd files are not always considered executable in MSYS causing which 44393 # to not find them 44394 if test "x$new_path" = x \ 44395 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44396 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44397 new_path="$path" 44398 44399 windows_path="$new_path" 44400 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44401 unix_path=`$CYGPATH -u "$windows_path"` 44402 new_path="$unix_path" 44403 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44404 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44405 new_path="$unix_path" 44406 fi 44407 44408 fi 44409 44410 if test "x$new_path" = x; then 44411 # It's still not found. Now this is an unrecoverable error. 44412 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5 44413 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;} 44414 has_space=`$ECHO "$complete" | $GREP " "` 44415 if test "x$has_space" != x; then 44416 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 44417 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 44418 fi 44419 as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5 44420 fi 44421 fi 44422 44423 # Now new_path has a complete unix path to the binary 44424 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 44425 # Keep paths in /bin as-is, but remove trailing .exe if any 44426 new_path="${new_path/%.exe/}" 44427 # Do not save /bin paths to all_fixpath_prefixes! 44428 else 44429 # Not in mixed or Windows style, start by that. 44430 new_path=`cmd //c echo $new_path` 44431 44432 input_path="$new_path" 44433 # Check if we need to convert this using DOS-style short mode. If the path 44434 # contains just simple characters, use it. Otherwise (spaces, weird characters), 44435 # take no chances and rewrite it. 44436 # Note: m4 eats our [], so we need to use [ and ] instead. 44437 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 44438 if test "x$has_forbidden_chars" != x; then 44439 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 44440 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 44441 fi 44442 44443 # Output is in $new_path 44444 44445 windows_path="$new_path" 44446 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44447 unix_path=`$CYGPATH -u "$windows_path"` 44448 new_path="$unix_path" 44449 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44450 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44451 new_path="$unix_path" 44452 fi 44453 44454 # remove trailing .exe if any 44455 new_path="${new_path/%.exe/}" 44456 44457 # Save the first 10 bytes of this path to the storage, so fixpath can work. 44458 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 44459 fi 44460 44461 else 44462 # We're on a unix platform. Hooray! :) 44463 # First separate the path from the arguments. This will split at the first 44464 # space. 44465 complete="$BUILD_CC" 44466 path="${complete%% *}" 44467 tmp="$complete EOL" 44468 arguments="${tmp#* }" 44469 44470 # Cannot rely on the command "which" here since it doesn't always work. 44471 is_absolute_path=`$ECHO "$path" | $GREP ^/` 44472 if test -z "$is_absolute_path"; then 44473 # Path to executable is not absolute. Find it. 44474 IFS_save="$IFS" 44475 IFS=: 44476 for p in $PATH; do 44477 if test -f "$p/$path" && test -x "$p/$path"; then 44478 new_path="$p/$path" 44479 break 44480 fi 44481 done 44482 IFS="$IFS_save" 44483 else 44484 # This is an absolute path, we can use it without further modifications. 44485 new_path="$path" 44486 fi 44487 44488 if test "x$new_path" = x; then 44489 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5 44490 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;} 44491 has_space=`$ECHO "$complete" | $GREP " "` 44492 if test "x$has_space" != x; then 44493 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 44494 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 44495 fi 44496 as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5 44497 fi 44498 fi 44499 44500 # Now join together the path and the arguments once again 44501 if test "x$arguments" != xEOL; then 44502 new_complete="$new_path ${arguments% *}" 44503 else 44504 new_complete="$new_path" 44505 fi 44506 44507 if test "x$complete" != "x$new_complete"; then 44508 BUILD_CC="$new_complete" 44509 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_CC to \"$new_complete\"" >&5 44510 $as_echo "$as_me: Rewriting BUILD_CC to \"$new_complete\"" >&6;} 44511 fi 44512 fi 44513 44514 44515 44516 44517 # Publish this variable in the help. 44518 44519 44520 if [ -z "${BUILD_CXX+x}" ]; then 44521 # The variable is not set by user, try to locate tool using the code snippet 44522 for ac_prog in cl CC g++ 44523 do 44524 # Extract the first word of "$ac_prog", so it can be a program name with args. 44525 set dummy $ac_prog; ac_word=$2 44526 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44527 $as_echo_n "checking for $ac_word... " >&6; } 44528 if ${ac_cv_path_BUILD_CXX+:} false; then : 44529 $as_echo_n "(cached) " >&6 44530 else 44531 case $BUILD_CXX in 44532 [\\/]* | ?:[\\/]*) 44533 ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path. 44534 ;; 44535 *) 44536 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44537 for as_dir in $PATH 44538 do 44539 IFS=$as_save_IFS 44540 test -z "$as_dir" && as_dir=. 44541 for ac_exec_ext in '' $ac_executable_extensions; do 44542 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44543 ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext" 44544 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44545 break 2 44546 fi 44547 done 44548 done 44549 IFS=$as_save_IFS 44550 44551 ;; 44552 esac 44553 fi 44554 BUILD_CXX=$ac_cv_path_BUILD_CXX 44555 if test -n "$BUILD_CXX"; then 44556 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5 44557 $as_echo "$BUILD_CXX" >&6; } 44558 else 44559 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44560 $as_echo "no" >&6; } 44561 fi 44562 44563 44564 test -n "$BUILD_CXX" && break 44565 done 44566 44567 else 44568 # The variable is set, but is it from the command line or the environment? 44569 44570 # Try to remove the string !BUILD_CXX! from our list. 44571 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_CXX!/} 44572 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 44573 # If it failed, the variable was not from the command line. Ignore it, 44574 # but warn the user (except for BASH, which is always set by the calling BASH). 44575 if test "xBUILD_CXX" != xBASH; then 44576 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_CXX from the environment. Use command line variables instead." >&5 44577 $as_echo "$as_me: WARNING: Ignoring value of BUILD_CXX from the environment. Use command line variables instead." >&2;} 44578 fi 44579 # Try to locate tool using the code snippet 44580 for ac_prog in cl CC g++ 44581 do 44582 # Extract the first word of "$ac_prog", so it can be a program name with args. 44583 set dummy $ac_prog; ac_word=$2 44584 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44585 $as_echo_n "checking for $ac_word... " >&6; } 44586 if ${ac_cv_path_BUILD_CXX+:} false; then : 44587 $as_echo_n "(cached) " >&6 44588 else 44589 case $BUILD_CXX in 44590 [\\/]* | ?:[\\/]*) 44591 ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path. 44592 ;; 44593 *) 44594 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44595 for as_dir in $PATH 44596 do 44597 IFS=$as_save_IFS 44598 test -z "$as_dir" && as_dir=. 44599 for ac_exec_ext in '' $ac_executable_extensions; do 44600 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44601 ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext" 44602 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44603 break 2 44604 fi 44605 done 44606 done 44607 IFS=$as_save_IFS 44608 44609 ;; 44610 esac 44611 fi 44612 BUILD_CXX=$ac_cv_path_BUILD_CXX 44613 if test -n "$BUILD_CXX"; then 44614 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5 44615 $as_echo "$BUILD_CXX" >&6; } 44616 else 44617 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44618 $as_echo "no" >&6; } 44619 fi 44620 44621 44622 test -n "$BUILD_CXX" && break 44623 done 44624 44625 else 44626 # If it succeeded, then it was overridden by the user. We will use it 44627 # for the tool. 44628 44629 # First remove it from the list of overridden variables, so we can test 44630 # for unknown variables in the end. 44631 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 44632 44633 # Check if we try to supply an empty value 44634 if test "x$BUILD_CXX" = x; then 44635 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_CXX= (no value)" >&5 44636 $as_echo "$as_me: Setting user supplied tool BUILD_CXX= (no value)" >&6;} 44637 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CXX" >&5 44638 $as_echo_n "checking for BUILD_CXX... " >&6; } 44639 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 44640 $as_echo "disabled" >&6; } 44641 else 44642 # Check if the provided tool contains a complete path. 44643 tool_specified="$BUILD_CXX" 44644 tool_basename="${tool_specified##*/}" 44645 if test "x$tool_basename" = "x$tool_specified"; then 44646 # A command without a complete path is provided, search $PATH. 44647 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_CXX=$tool_basename" >&5 44648 $as_echo "$as_me: Will search for user supplied tool BUILD_CXX=$tool_basename" >&6;} 44649 # Extract the first word of "$tool_basename", so it can be a program name with args. 44650 set dummy $tool_basename; ac_word=$2 44651 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44652 $as_echo_n "checking for $ac_word... " >&6; } 44653 if ${ac_cv_path_BUILD_CXX+:} false; then : 44654 $as_echo_n "(cached) " >&6 44655 else 44656 case $BUILD_CXX in 44657 [\\/]* | ?:[\\/]*) 44658 ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path. 44659 ;; 44660 *) 44661 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44662 for as_dir in $PATH 44663 do 44664 IFS=$as_save_IFS 44665 test -z "$as_dir" && as_dir=. 44666 for ac_exec_ext in '' $ac_executable_extensions; do 44667 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44668 ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext" 44669 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44670 break 2 44671 fi 44672 done 44673 done 44674 IFS=$as_save_IFS 44675 44676 ;; 44677 esac 44678 fi 44679 BUILD_CXX=$ac_cv_path_BUILD_CXX 44680 if test -n "$BUILD_CXX"; then 44681 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5 44682 $as_echo "$BUILD_CXX" >&6; } 44683 else 44684 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44685 $as_echo "no" >&6; } 44686 fi 44687 44688 44689 if test "x$BUILD_CXX" = x; then 44690 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 44691 fi 44692 else 44693 # Otherwise we believe it is a complete path. Use it as it is. 44694 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_CXX=$tool_specified" >&5 44695 $as_echo "$as_me: Will use user supplied tool BUILD_CXX=$tool_specified" >&6;} 44696 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CXX" >&5 44697 $as_echo_n "checking for BUILD_CXX... " >&6; } 44698 if test ! -x "$tool_specified"; then 44699 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 44700 $as_echo "not found" >&6; } 44701 as_fn_error $? "User supplied tool BUILD_CXX=$tool_specified does not exist or is not executable" "$LINENO" 5 44702 fi 44703 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 44704 $as_echo "$tool_specified" >&6; } 44705 fi 44706 fi 44707 fi 44708 44709 fi 44710 44711 44712 44713 if test "x$BUILD_CXX" = x; then 44714 as_fn_error $? "Could not find required tool for BUILD_CXX" "$LINENO" 5 44715 fi 44716 44717 44718 44719 # Only process if variable expands to non-empty 44720 44721 if test "x$BUILD_CXX" != x; then 44722 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44723 44724 # First separate the path from the arguments. This will split at the first 44725 # space. 44726 complete="$BUILD_CXX" 44727 path="${complete%% *}" 44728 tmp="$complete EOL" 44729 arguments="${tmp#* }" 44730 44731 # Input might be given as Windows format, start by converting to 44732 # unix format. 44733 new_path=`$CYGPATH -u "$path"` 44734 44735 # Now try to locate executable using which 44736 new_path=`$WHICH "$new_path" 2> /dev/null` 44737 # bat and cmd files are not always considered executable in cygwin causing which 44738 # to not find them 44739 if test "x$new_path" = x \ 44740 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44741 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44742 new_path=`$CYGPATH -u "$path"` 44743 fi 44744 if test "x$new_path" = x; then 44745 # Oops. Which didn't find the executable. 44746 # The splitting of arguments from the executable at a space might have been incorrect, 44747 # since paths with space are more likely in Windows. Give it another try with the whole 44748 # argument. 44749 path="$complete" 44750 arguments="EOL" 44751 new_path=`$CYGPATH -u "$path"` 44752 new_path=`$WHICH "$new_path" 2> /dev/null` 44753 # bat and cmd files are not always considered executable in cygwin causing which 44754 # to not find them 44755 if test "x$new_path" = x \ 44756 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44757 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44758 new_path=`$CYGPATH -u "$path"` 44759 fi 44760 if test "x$new_path" = x; then 44761 # It's still not found. Now this is an unrecoverable error. 44762 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5 44763 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;} 44764 has_space=`$ECHO "$complete" | $GREP " "` 44765 if test "x$has_space" != x; then 44766 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 44767 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 44768 fi 44769 as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5 44770 fi 44771 fi 44772 44773 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 44774 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 44775 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 44776 # "foo.exe" is OK but "foo" is an error. 44777 # 44778 # This test is therefore slightly more accurate than "test -f" to check for file presence. 44779 # It is also a way to make sure we got the proper file name for the real test later on. 44780 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 44781 if test "x$test_shortpath" = x; then 44782 # Short path failed, file does not exist as specified. 44783 # Try adding .exe or .cmd 44784 if test -f "${new_path}.exe"; then 44785 input_to_shortpath="${new_path}.exe" 44786 elif test -f "${new_path}.cmd"; then 44787 input_to_shortpath="${new_path}.cmd" 44788 else 44789 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$new_path\", is invalid." >&5 44790 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$new_path\", is invalid." >&6;} 44791 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 44792 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 44793 as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5 44794 fi 44795 else 44796 input_to_shortpath="$new_path" 44797 fi 44798 44799 # Call helper function which possibly converts this using DOS-style short mode. 44800 # If so, the updated path is stored in $new_path. 44801 new_path="$input_to_shortpath" 44802 44803 input_path="$input_to_shortpath" 44804 # Check if we need to convert this using DOS-style short mode. If the path 44805 # contains just simple characters, use it. Otherwise (spaces, weird characters), 44806 # take no chances and rewrite it. 44807 # Note: m4 eats our [], so we need to use [ and ] instead. 44808 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 44809 if test "x$has_forbidden_chars" != x; then 44810 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 44811 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 44812 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 44813 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 44814 # Going to short mode and back again did indeed matter. Since short mode is 44815 # case insensitive, let's make it lowercase to improve readability. 44816 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 44817 # Now convert it back to Unix-style (cygpath) 44818 input_path=`$CYGPATH -u "$shortmode_path"` 44819 new_path="$input_path" 44820 fi 44821 fi 44822 44823 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 44824 if test "x$test_cygdrive_prefix" = x; then 44825 # As a simple fix, exclude /usr/bin since it's not a real path. 44826 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 44827 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 44828 # a path prefixed by /cygdrive for fixpath to work. 44829 new_path="$CYGWIN_ROOT_PATH$input_path" 44830 fi 44831 fi 44832 44833 # remove trailing .exe if any 44834 new_path="${new_path/%.exe/}" 44835 44836 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44837 44838 # First separate the path from the arguments. This will split at the first 44839 # space. 44840 complete="$BUILD_CXX" 44841 path="${complete%% *}" 44842 tmp="$complete EOL" 44843 arguments="${tmp#* }" 44844 44845 # Input might be given as Windows format, start by converting to 44846 # unix format. 44847 new_path="$path" 44848 44849 windows_path="$new_path" 44850 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44851 unix_path=`$CYGPATH -u "$windows_path"` 44852 new_path="$unix_path" 44853 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44854 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44855 new_path="$unix_path" 44856 fi 44857 44858 44859 # Now try to locate executable using which 44860 new_path=`$WHICH "$new_path" 2> /dev/null` 44861 44862 if test "x$new_path" = x; then 44863 # Oops. Which didn't find the executable. 44864 # The splitting of arguments from the executable at a space might have been incorrect, 44865 # since paths with space are more likely in Windows. Give it another try with the whole 44866 # argument. 44867 path="$complete" 44868 arguments="EOL" 44869 new_path="$path" 44870 44871 windows_path="$new_path" 44872 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44873 unix_path=`$CYGPATH -u "$windows_path"` 44874 new_path="$unix_path" 44875 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44876 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44877 new_path="$unix_path" 44878 fi 44879 44880 44881 new_path=`$WHICH "$new_path" 2> /dev/null` 44882 # bat and cmd files are not always considered executable in MSYS causing which 44883 # to not find them 44884 if test "x$new_path" = x \ 44885 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44886 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44887 new_path="$path" 44888 44889 windows_path="$new_path" 44890 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44891 unix_path=`$CYGPATH -u "$windows_path"` 44892 new_path="$unix_path" 44893 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44894 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44895 new_path="$unix_path" 44896 fi 44897 44898 fi 44899 44900 if test "x$new_path" = x; then 44901 # It's still not found. Now this is an unrecoverable error. 44902 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5 44903 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;} 44904 has_space=`$ECHO "$complete" | $GREP " "` 44905 if test "x$has_space" != x; then 44906 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 44907 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 44908 fi 44909 as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5 44910 fi 44911 fi 44912 44913 # Now new_path has a complete unix path to the binary 44914 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 44915 # Keep paths in /bin as-is, but remove trailing .exe if any 44916 new_path="${new_path/%.exe/}" 44917 # Do not save /bin paths to all_fixpath_prefixes! 44918 else 44919 # Not in mixed or Windows style, start by that. 44920 new_path=`cmd //c echo $new_path` 44921 44922 input_path="$new_path" 44923 # Check if we need to convert this using DOS-style short mode. If the path 44924 # contains just simple characters, use it. Otherwise (spaces, weird characters), 44925 # take no chances and rewrite it. 44926 # Note: m4 eats our [], so we need to use [ and ] instead. 44927 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 44928 if test "x$has_forbidden_chars" != x; then 44929 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 44930 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 44931 fi 44932 44933 # Output is in $new_path 44934 44935 windows_path="$new_path" 44936 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44937 unix_path=`$CYGPATH -u "$windows_path"` 44938 new_path="$unix_path" 44939 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44940 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44941 new_path="$unix_path" 44942 fi 44943 44944 # remove trailing .exe if any 44945 new_path="${new_path/%.exe/}" 44946 44947 # Save the first 10 bytes of this path to the storage, so fixpath can work. 44948 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 44949 fi 44950 44951 else 44952 # We're on a unix platform. Hooray! :) 44953 # First separate the path from the arguments. This will split at the first 44954 # space. 44955 complete="$BUILD_CXX" 44956 path="${complete%% *}" 44957 tmp="$complete EOL" 44958 arguments="${tmp#* }" 44959 44960 # Cannot rely on the command "which" here since it doesn't always work. 44961 is_absolute_path=`$ECHO "$path" | $GREP ^/` 44962 if test -z "$is_absolute_path"; then 44963 # Path to executable is not absolute. Find it. 44964 IFS_save="$IFS" 44965 IFS=: 44966 for p in $PATH; do 44967 if test -f "$p/$path" && test -x "$p/$path"; then 44968 new_path="$p/$path" 44969 break 44970 fi 44971 done 44972 IFS="$IFS_save" 44973 else 44974 # This is an absolute path, we can use it without further modifications. 44975 new_path="$path" 44976 fi 44977 44978 if test "x$new_path" = x; then 44979 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5 44980 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;} 44981 has_space=`$ECHO "$complete" | $GREP " "` 44982 if test "x$has_space" != x; then 44983 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 44984 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 44985 fi 44986 as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5 44987 fi 44988 fi 44989 44990 # Now join together the path and the arguments once again 44991 if test "x$arguments" != xEOL; then 44992 new_complete="$new_path ${arguments% *}" 44993 else 44994 new_complete="$new_path" 44995 fi 44996 44997 if test "x$complete" != "x$new_complete"; then 44998 BUILD_CXX="$new_complete" 44999 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_CXX to \"$new_complete\"" >&5 45000 $as_echo "$as_me: Rewriting BUILD_CXX to \"$new_complete\"" >&6;} 45001 fi 45002 fi 45003 45004 45005 45006 # Publish this variable in the help. 45007 45008 45009 if [ -z "${BUILD_NM+x}" ]; then 45010 # The variable is not set by user, try to locate tool using the code snippet 45011 for ac_prog in nm gcc-nm 45012 do 45013 # Extract the first word of "$ac_prog", so it can be a program name with args. 45014 set dummy $ac_prog; ac_word=$2 45015 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45016 $as_echo_n "checking for $ac_word... " >&6; } 45017 if ${ac_cv_path_BUILD_NM+:} false; then : 45018 $as_echo_n "(cached) " >&6 45019 else 45020 case $BUILD_NM in 45021 [\\/]* | ?:[\\/]*) 45022 ac_cv_path_BUILD_NM="$BUILD_NM" # Let the user override the test with a path. 45023 ;; 45024 *) 45025 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45026 for as_dir in $PATH 45027 do 45028 IFS=$as_save_IFS 45029 test -z "$as_dir" && as_dir=. 45030 for ac_exec_ext in '' $ac_executable_extensions; do 45031 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45032 ac_cv_path_BUILD_NM="$as_dir/$ac_word$ac_exec_ext" 45033 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45034 break 2 45035 fi 45036 done 45037 done 45038 IFS=$as_save_IFS 45039 45040 ;; 45041 esac 45042 fi 45043 BUILD_NM=$ac_cv_path_BUILD_NM 45044 if test -n "$BUILD_NM"; then 45045 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_NM" >&5 45046 $as_echo "$BUILD_NM" >&6; } 45047 else 45048 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45049 $as_echo "no" >&6; } 45050 fi 45051 45052 45053 test -n "$BUILD_NM" && break 45054 done 45055 45056 else 45057 # The variable is set, but is it from the command line or the environment? 45058 45059 # Try to remove the string !BUILD_NM! from our list. 45060 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_NM!/} 45061 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 45062 # If it failed, the variable was not from the command line. Ignore it, 45063 # but warn the user (except for BASH, which is always set by the calling BASH). 45064 if test "xBUILD_NM" != xBASH; then 45065 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_NM from the environment. Use command line variables instead." >&5 45066 $as_echo "$as_me: WARNING: Ignoring value of BUILD_NM from the environment. Use command line variables instead." >&2;} 45067 fi 45068 # Try to locate tool using the code snippet 45069 for ac_prog in nm gcc-nm 45070 do 45071 # Extract the first word of "$ac_prog", so it can be a program name with args. 45072 set dummy $ac_prog; ac_word=$2 45073 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45074 $as_echo_n "checking for $ac_word... " >&6; } 45075 if ${ac_cv_path_BUILD_NM+:} false; then : 45076 $as_echo_n "(cached) " >&6 45077 else 45078 case $BUILD_NM in 45079 [\\/]* | ?:[\\/]*) 45080 ac_cv_path_BUILD_NM="$BUILD_NM" # Let the user override the test with a path. 45081 ;; 45082 *) 45083 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45084 for as_dir in $PATH 45085 do 45086 IFS=$as_save_IFS 45087 test -z "$as_dir" && as_dir=. 45088 for ac_exec_ext in '' $ac_executable_extensions; do 45089 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45090 ac_cv_path_BUILD_NM="$as_dir/$ac_word$ac_exec_ext" 45091 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45092 break 2 45093 fi 45094 done 45095 done 45096 IFS=$as_save_IFS 45097 45098 ;; 45099 esac 45100 fi 45101 BUILD_NM=$ac_cv_path_BUILD_NM 45102 if test -n "$BUILD_NM"; then 45103 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_NM" >&5 45104 $as_echo "$BUILD_NM" >&6; } 45105 else 45106 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45107 $as_echo "no" >&6; } 45108 fi 45109 45110 45111 test -n "$BUILD_NM" && break 45112 done 45113 45114 else 45115 # If it succeeded, then it was overridden by the user. We will use it 45116 # for the tool. 45117 45118 # First remove it from the list of overridden variables, so we can test 45119 # for unknown variables in the end. 45120 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 45121 45122 # Check if we try to supply an empty value 45123 if test "x$BUILD_NM" = x; then 45124 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_NM= (no value)" >&5 45125 $as_echo "$as_me: Setting user supplied tool BUILD_NM= (no value)" >&6;} 45126 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_NM" >&5 45127 $as_echo_n "checking for BUILD_NM... " >&6; } 45128 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 45129 $as_echo "disabled" >&6; } 45130 else 45131 # Check if the provided tool contains a complete path. 45132 tool_specified="$BUILD_NM" 45133 tool_basename="${tool_specified##*/}" 45134 if test "x$tool_basename" = "x$tool_specified"; then 45135 # A command without a complete path is provided, search $PATH. 45136 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_NM=$tool_basename" >&5 45137 $as_echo "$as_me: Will search for user supplied tool BUILD_NM=$tool_basename" >&6;} 45138 # Extract the first word of "$tool_basename", so it can be a program name with args. 45139 set dummy $tool_basename; ac_word=$2 45140 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45141 $as_echo_n "checking for $ac_word... " >&6; } 45142 if ${ac_cv_path_BUILD_NM+:} false; then : 45143 $as_echo_n "(cached) " >&6 45144 else 45145 case $BUILD_NM in 45146 [\\/]* | ?:[\\/]*) 45147 ac_cv_path_BUILD_NM="$BUILD_NM" # Let the user override the test with a path. 45148 ;; 45149 *) 45150 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45151 for as_dir in $PATH 45152 do 45153 IFS=$as_save_IFS 45154 test -z "$as_dir" && as_dir=. 45155 for ac_exec_ext in '' $ac_executable_extensions; do 45156 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45157 ac_cv_path_BUILD_NM="$as_dir/$ac_word$ac_exec_ext" 45158 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45159 break 2 45160 fi 45161 done 45162 done 45163 IFS=$as_save_IFS 45164 45165 ;; 45166 esac 45167 fi 45168 BUILD_NM=$ac_cv_path_BUILD_NM 45169 if test -n "$BUILD_NM"; then 45170 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_NM" >&5 45171 $as_echo "$BUILD_NM" >&6; } 45172 else 45173 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45174 $as_echo "no" >&6; } 45175 fi 45176 45177 45178 if test "x$BUILD_NM" = x; then 45179 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 45180 fi 45181 else 45182 # Otherwise we believe it is a complete path. Use it as it is. 45183 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_NM=$tool_specified" >&5 45184 $as_echo "$as_me: Will use user supplied tool BUILD_NM=$tool_specified" >&6;} 45185 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_NM" >&5 45186 $as_echo_n "checking for BUILD_NM... " >&6; } 45187 if test ! -x "$tool_specified"; then 45188 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 45189 $as_echo "not found" >&6; } 45190 as_fn_error $? "User supplied tool BUILD_NM=$tool_specified does not exist or is not executable" "$LINENO" 5 45191 fi 45192 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 45193 $as_echo "$tool_specified" >&6; } 45194 fi 45195 fi 45196 fi 45197 45198 fi 45199 45200 45201 45202 # Only process if variable expands to non-empty 45203 45204 if test "x$BUILD_NM" != x; then 45205 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45206 45207 # First separate the path from the arguments. This will split at the first 45208 # space. 45209 complete="$BUILD_NM" 45210 path="${complete%% *}" 45211 tmp="$complete EOL" 45212 arguments="${tmp#* }" 45213 45214 # Input might be given as Windows format, start by converting to 45215 # unix format. 45216 new_path=`$CYGPATH -u "$path"` 45217 45218 # Now try to locate executable using which 45219 new_path=`$WHICH "$new_path" 2> /dev/null` 45220 # bat and cmd files are not always considered executable in cygwin causing which 45221 # to not find them 45222 if test "x$new_path" = x \ 45223 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 45224 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 45225 new_path=`$CYGPATH -u "$path"` 45226 fi 45227 if test "x$new_path" = x; then 45228 # Oops. Which didn't find the executable. 45229 # The splitting of arguments from the executable at a space might have been incorrect, 45230 # since paths with space are more likely in Windows. Give it another try with the whole 45231 # argument. 45232 path="$complete" 45233 arguments="EOL" 45234 new_path=`$CYGPATH -u "$path"` 45235 new_path=`$WHICH "$new_path" 2> /dev/null` 45236 # bat and cmd files are not always considered executable in cygwin causing which 45237 # to not find them 45238 if test "x$new_path" = x \ 45239 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 45240 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 45241 new_path=`$CYGPATH -u "$path"` 45242 fi 45243 if test "x$new_path" = x; then 45244 # It's still not found. Now this is an unrecoverable error. 45245 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&5 45246 $as_echo "$as_me: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&6;} 45247 has_space=`$ECHO "$complete" | $GREP " "` 45248 if test "x$has_space" != x; then 45249 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 45250 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 45251 fi 45252 as_fn_error $? "Cannot locate the the path of BUILD_NM" "$LINENO" 5 45253 fi 45254 fi 45255 45256 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 45257 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 45258 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 45259 # "foo.exe" is OK but "foo" is an error. 45260 # 45261 # This test is therefore slightly more accurate than "test -f" to check for file presence. 45262 # It is also a way to make sure we got the proper file name for the real test later on. 45263 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 45264 if test "x$test_shortpath" = x; then 45265 # Short path failed, file does not exist as specified. 45266 # Try adding .exe or .cmd 45267 if test -f "${new_path}.exe"; then 45268 input_to_shortpath="${new_path}.exe" 45269 elif test -f "${new_path}.cmd"; then 45270 input_to_shortpath="${new_path}.cmd" 45271 else 45272 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_NM, which resolves as \"$new_path\", is invalid." >&5 45273 $as_echo "$as_me: The path of BUILD_NM, which resolves as \"$new_path\", is invalid." >&6;} 45274 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 45275 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 45276 as_fn_error $? "Cannot locate the the path of BUILD_NM" "$LINENO" 5 45277 fi 45278 else 45279 input_to_shortpath="$new_path" 45280 fi 45281 45282 # Call helper function which possibly converts this using DOS-style short mode. 45283 # If so, the updated path is stored in $new_path. 45284 new_path="$input_to_shortpath" 45285 45286 input_path="$input_to_shortpath" 45287 # Check if we need to convert this using DOS-style short mode. If the path 45288 # contains just simple characters, use it. Otherwise (spaces, weird characters), 45289 # take no chances and rewrite it. 45290 # Note: m4 eats our [], so we need to use [ and ] instead. 45291 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 45292 if test "x$has_forbidden_chars" != x; then 45293 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 45294 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 45295 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 45296 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 45297 # Going to short mode and back again did indeed matter. Since short mode is 45298 # case insensitive, let's make it lowercase to improve readability. 45299 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 45300 # Now convert it back to Unix-style (cygpath) 45301 input_path=`$CYGPATH -u "$shortmode_path"` 45302 new_path="$input_path" 45303 fi 45304 fi 45305 45306 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 45307 if test "x$test_cygdrive_prefix" = x; then 45308 # As a simple fix, exclude /usr/bin since it's not a real path. 45309 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 45310 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 45311 # a path prefixed by /cygdrive for fixpath to work. 45312 new_path="$CYGWIN_ROOT_PATH$input_path" 45313 fi 45314 fi 45315 45316 # remove trailing .exe if any 45317 new_path="${new_path/%.exe/}" 45318 45319 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45320 45321 # First separate the path from the arguments. This will split at the first 45322 # space. 45323 complete="$BUILD_NM" 45324 path="${complete%% *}" 45325 tmp="$complete EOL" 45326 arguments="${tmp#* }" 45327 45328 # Input might be given as Windows format, start by converting to 45329 # unix format. 45330 new_path="$path" 45331 45332 windows_path="$new_path" 45333 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45334 unix_path=`$CYGPATH -u "$windows_path"` 45335 new_path="$unix_path" 45336 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45337 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45338 new_path="$unix_path" 45339 fi 45340 45341 45342 # Now try to locate executable using which 45343 new_path=`$WHICH "$new_path" 2> /dev/null` 45344 45345 if test "x$new_path" = x; then 45346 # Oops. Which didn't find the executable. 45347 # The splitting of arguments from the executable at a space might have been incorrect, 45348 # since paths with space are more likely in Windows. Give it another try with the whole 45349 # argument. 45350 path="$complete" 45351 arguments="EOL" 45352 new_path="$path" 45353 45354 windows_path="$new_path" 45355 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45356 unix_path=`$CYGPATH -u "$windows_path"` 45357 new_path="$unix_path" 45358 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45359 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45360 new_path="$unix_path" 45361 fi 45362 45363 45364 new_path=`$WHICH "$new_path" 2> /dev/null` 45365 # bat and cmd files are not always considered executable in MSYS causing which 45366 # to not find them 45367 if test "x$new_path" = x \ 45368 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 45369 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 45370 new_path="$path" 45371 45372 windows_path="$new_path" 45373 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45374 unix_path=`$CYGPATH -u "$windows_path"` 45375 new_path="$unix_path" 45376 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45377 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45378 new_path="$unix_path" 45379 fi 45380 45381 fi 45382 45383 if test "x$new_path" = x; then 45384 # It's still not found. Now this is an unrecoverable error. 45385 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&5 45386 $as_echo "$as_me: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&6;} 45387 has_space=`$ECHO "$complete" | $GREP " "` 45388 if test "x$has_space" != x; then 45389 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 45390 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 45391 fi 45392 as_fn_error $? "Cannot locate the the path of BUILD_NM" "$LINENO" 5 45393 fi 45394 fi 45395 45396 # Now new_path has a complete unix path to the binary 45397 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 45398 # Keep paths in /bin as-is, but remove trailing .exe if any 45399 new_path="${new_path/%.exe/}" 45400 # Do not save /bin paths to all_fixpath_prefixes! 45401 else 45402 # Not in mixed or Windows style, start by that. 45403 new_path=`cmd //c echo $new_path` 45404 45405 input_path="$new_path" 45406 # Check if we need to convert this using DOS-style short mode. If the path 45407 # contains just simple characters, use it. Otherwise (spaces, weird characters), 45408 # take no chances and rewrite it. 45409 # Note: m4 eats our [], so we need to use [ and ] instead. 45410 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 45411 if test "x$has_forbidden_chars" != x; then 45412 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 45413 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 45414 fi 45415 45416 # Output is in $new_path 45417 45418 windows_path="$new_path" 45419 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45420 unix_path=`$CYGPATH -u "$windows_path"` 45421 new_path="$unix_path" 45422 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45423 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45424 new_path="$unix_path" 45425 fi 45426 45427 # remove trailing .exe if any 45428 new_path="${new_path/%.exe/}" 45429 45430 # Save the first 10 bytes of this path to the storage, so fixpath can work. 45431 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 45432 fi 45433 45434 else 45435 # We're on a unix platform. Hooray! :) 45436 # First separate the path from the arguments. This will split at the first 45437 # space. 45438 complete="$BUILD_NM" 45439 path="${complete%% *}" 45440 tmp="$complete EOL" 45441 arguments="${tmp#* }" 45442 45443 # Cannot rely on the command "which" here since it doesn't always work. 45444 is_absolute_path=`$ECHO "$path" | $GREP ^/` 45445 if test -z "$is_absolute_path"; then 45446 # Path to executable is not absolute. Find it. 45447 IFS_save="$IFS" 45448 IFS=: 45449 for p in $PATH; do 45450 if test -f "$p/$path" && test -x "$p/$path"; then 45451 new_path="$p/$path" 45452 break 45453 fi 45454 done 45455 IFS="$IFS_save" 45456 else 45457 # This is an absolute path, we can use it without further modifications. 45458 new_path="$path" 45459 fi 45460 45461 if test "x$new_path" = x; then 45462 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&5 45463 $as_echo "$as_me: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&6;} 45464 has_space=`$ECHO "$complete" | $GREP " "` 45465 if test "x$has_space" != x; then 45466 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 45467 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 45468 fi 45469 as_fn_error $? "Cannot locate the the path of BUILD_NM" "$LINENO" 5 45470 fi 45471 fi 45472 45473 # Now join together the path and the arguments once again 45474 if test "x$arguments" != xEOL; then 45475 new_complete="$new_path ${arguments% *}" 45476 else 45477 new_complete="$new_path" 45478 fi 45479 45480 if test "x$complete" != "x$new_complete"; then 45481 BUILD_NM="$new_complete" 45482 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_NM to \"$new_complete\"" >&5 45483 $as_echo "$as_me: Rewriting BUILD_NM to \"$new_complete\"" >&6;} 45484 fi 45485 fi 45486 45487 45488 45489 # Publish this variable in the help. 45490 45491 45492 if [ -z "${BUILD_AR+x}" ]; then 45493 # The variable is not set by user, try to locate tool using the code snippet 45494 for ac_prog in ar gcc-ar 45495 do 45496 # Extract the first word of "$ac_prog", so it can be a program name with args. 45497 set dummy $ac_prog; ac_word=$2 45498 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45499 $as_echo_n "checking for $ac_word... " >&6; } 45500 if ${ac_cv_path_BUILD_AR+:} false; then : 45501 $as_echo_n "(cached) " >&6 45502 else 45503 case $BUILD_AR in 45504 [\\/]* | ?:[\\/]*) 45505 ac_cv_path_BUILD_AR="$BUILD_AR" # Let the user override the test with a path. 45506 ;; 45507 *) 45508 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45509 for as_dir in $PATH 45510 do 45511 IFS=$as_save_IFS 45512 test -z "$as_dir" && as_dir=. 45513 for ac_exec_ext in '' $ac_executable_extensions; do 45514 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45515 ac_cv_path_BUILD_AR="$as_dir/$ac_word$ac_exec_ext" 45516 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45517 break 2 45518 fi 45519 done 45520 done 45521 IFS=$as_save_IFS 45522 45523 ;; 45524 esac 45525 fi 45526 BUILD_AR=$ac_cv_path_BUILD_AR 45527 if test -n "$BUILD_AR"; then 45528 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_AR" >&5 45529 $as_echo "$BUILD_AR" >&6; } 45530 else 45531 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45532 $as_echo "no" >&6; } 45533 fi 45534 45535 45536 test -n "$BUILD_AR" && break 45537 done 45538 45539 else 45540 # The variable is set, but is it from the command line or the environment? 45541 45542 # Try to remove the string !BUILD_AR! from our list. 45543 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_AR!/} 45544 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 45545 # If it failed, the variable was not from the command line. Ignore it, 45546 # but warn the user (except for BASH, which is always set by the calling BASH). 45547 if test "xBUILD_AR" != xBASH; then 45548 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_AR from the environment. Use command line variables instead." >&5 45549 $as_echo "$as_me: WARNING: Ignoring value of BUILD_AR from the environment. Use command line variables instead." >&2;} 45550 fi 45551 # Try to locate tool using the code snippet 45552 for ac_prog in ar gcc-ar 45553 do 45554 # Extract the first word of "$ac_prog", so it can be a program name with args. 45555 set dummy $ac_prog; ac_word=$2 45556 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45557 $as_echo_n "checking for $ac_word... " >&6; } 45558 if ${ac_cv_path_BUILD_AR+:} false; then : 45559 $as_echo_n "(cached) " >&6 45560 else 45561 case $BUILD_AR in 45562 [\\/]* | ?:[\\/]*) 45563 ac_cv_path_BUILD_AR="$BUILD_AR" # Let the user override the test with a path. 45564 ;; 45565 *) 45566 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45567 for as_dir in $PATH 45568 do 45569 IFS=$as_save_IFS 45570 test -z "$as_dir" && as_dir=. 45571 for ac_exec_ext in '' $ac_executable_extensions; do 45572 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45573 ac_cv_path_BUILD_AR="$as_dir/$ac_word$ac_exec_ext" 45574 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45575 break 2 45576 fi 45577 done 45578 done 45579 IFS=$as_save_IFS 45580 45581 ;; 45582 esac 45583 fi 45584 BUILD_AR=$ac_cv_path_BUILD_AR 45585 if test -n "$BUILD_AR"; then 45586 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_AR" >&5 45587 $as_echo "$BUILD_AR" >&6; } 45588 else 45589 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45590 $as_echo "no" >&6; } 45591 fi 45592 45593 45594 test -n "$BUILD_AR" && break 45595 done 45596 45597 else 45598 # If it succeeded, then it was overridden by the user. We will use it 45599 # for the tool. 45600 45601 # First remove it from the list of overridden variables, so we can test 45602 # for unknown variables in the end. 45603 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 45604 45605 # Check if we try to supply an empty value 45606 if test "x$BUILD_AR" = x; then 45607 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_AR= (no value)" >&5 45608 $as_echo "$as_me: Setting user supplied tool BUILD_AR= (no value)" >&6;} 45609 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_AR" >&5 45610 $as_echo_n "checking for BUILD_AR... " >&6; } 45611 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 45612 $as_echo "disabled" >&6; } 45613 else 45614 # Check if the provided tool contains a complete path. 45615 tool_specified="$BUILD_AR" 45616 tool_basename="${tool_specified##*/}" 45617 if test "x$tool_basename" = "x$tool_specified"; then 45618 # A command without a complete path is provided, search $PATH. 45619 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_AR=$tool_basename" >&5 45620 $as_echo "$as_me: Will search for user supplied tool BUILD_AR=$tool_basename" >&6;} 45621 # Extract the first word of "$tool_basename", so it can be a program name with args. 45622 set dummy $tool_basename; ac_word=$2 45623 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45624 $as_echo_n "checking for $ac_word... " >&6; } 45625 if ${ac_cv_path_BUILD_AR+:} false; then : 45626 $as_echo_n "(cached) " >&6 45627 else 45628 case $BUILD_AR in 45629 [\\/]* | ?:[\\/]*) 45630 ac_cv_path_BUILD_AR="$BUILD_AR" # Let the user override the test with a path. 45631 ;; 45632 *) 45633 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45634 for as_dir in $PATH 45635 do 45636 IFS=$as_save_IFS 45637 test -z "$as_dir" && as_dir=. 45638 for ac_exec_ext in '' $ac_executable_extensions; do 45639 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45640 ac_cv_path_BUILD_AR="$as_dir/$ac_word$ac_exec_ext" 45641 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45642 break 2 45643 fi 45644 done 45645 done 45646 IFS=$as_save_IFS 45647 45648 ;; 45649 esac 45650 fi 45651 BUILD_AR=$ac_cv_path_BUILD_AR 45652 if test -n "$BUILD_AR"; then 45653 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_AR" >&5 45654 $as_echo "$BUILD_AR" >&6; } 45655 else 45656 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45657 $as_echo "no" >&6; } 45658 fi 45659 45660 45661 if test "x$BUILD_AR" = x; then 45662 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 45663 fi 45664 else 45665 # Otherwise we believe it is a complete path. Use it as it is. 45666 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_AR=$tool_specified" >&5 45667 $as_echo "$as_me: Will use user supplied tool BUILD_AR=$tool_specified" >&6;} 45668 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_AR" >&5 45669 $as_echo_n "checking for BUILD_AR... " >&6; } 45670 if test ! -x "$tool_specified"; then 45671 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 45672 $as_echo "not found" >&6; } 45673 as_fn_error $? "User supplied tool BUILD_AR=$tool_specified does not exist or is not executable" "$LINENO" 5 45674 fi 45675 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 45676 $as_echo "$tool_specified" >&6; } 45677 fi 45678 fi 45679 fi 45680 45681 fi 45682 45683 45684 45685 # Only process if variable expands to non-empty 45686 45687 if test "x$BUILD_AR" != x; then 45688 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45689 45690 # First separate the path from the arguments. This will split at the first 45691 # space. 45692 complete="$BUILD_AR" 45693 path="${complete%% *}" 45694 tmp="$complete EOL" 45695 arguments="${tmp#* }" 45696 45697 # Input might be given as Windows format, start by converting to 45698 # unix format. 45699 new_path=`$CYGPATH -u "$path"` 45700 45701 # Now try to locate executable using which 45702 new_path=`$WHICH "$new_path" 2> /dev/null` 45703 # bat and cmd files are not always considered executable in cygwin causing which 45704 # to not find them 45705 if test "x$new_path" = x \ 45706 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 45707 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 45708 new_path=`$CYGPATH -u "$path"` 45709 fi 45710 if test "x$new_path" = x; then 45711 # Oops. Which didn't find the executable. 45712 # The splitting of arguments from the executable at a space might have been incorrect, 45713 # since paths with space are more likely in Windows. Give it another try with the whole 45714 # argument. 45715 path="$complete" 45716 arguments="EOL" 45717 new_path=`$CYGPATH -u "$path"` 45718 new_path=`$WHICH "$new_path" 2> /dev/null` 45719 # bat and cmd files are not always considered executable in cygwin causing which 45720 # to not find them 45721 if test "x$new_path" = x \ 45722 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 45723 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 45724 new_path=`$CYGPATH -u "$path"` 45725 fi 45726 if test "x$new_path" = x; then 45727 # It's still not found. Now this is an unrecoverable error. 45728 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&5 45729 $as_echo "$as_me: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&6;} 45730 has_space=`$ECHO "$complete" | $GREP " "` 45731 if test "x$has_space" != x; then 45732 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 45733 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 45734 fi 45735 as_fn_error $? "Cannot locate the the path of BUILD_AR" "$LINENO" 5 45736 fi 45737 fi 45738 45739 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 45740 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 45741 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 45742 # "foo.exe" is OK but "foo" is an error. 45743 # 45744 # This test is therefore slightly more accurate than "test -f" to check for file presence. 45745 # It is also a way to make sure we got the proper file name for the real test later on. 45746 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 45747 if test "x$test_shortpath" = x; then 45748 # Short path failed, file does not exist as specified. 45749 # Try adding .exe or .cmd 45750 if test -f "${new_path}.exe"; then 45751 input_to_shortpath="${new_path}.exe" 45752 elif test -f "${new_path}.cmd"; then 45753 input_to_shortpath="${new_path}.cmd" 45754 else 45755 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_AR, which resolves as \"$new_path\", is invalid." >&5 45756 $as_echo "$as_me: The path of BUILD_AR, which resolves as \"$new_path\", is invalid." >&6;} 45757 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 45758 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 45759 as_fn_error $? "Cannot locate the the path of BUILD_AR" "$LINENO" 5 45760 fi 45761 else 45762 input_to_shortpath="$new_path" 45763 fi 45764 45765 # Call helper function which possibly converts this using DOS-style short mode. 45766 # If so, the updated path is stored in $new_path. 45767 new_path="$input_to_shortpath" 45768 45769 input_path="$input_to_shortpath" 45770 # Check if we need to convert this using DOS-style short mode. If the path 45771 # contains just simple characters, use it. Otherwise (spaces, weird characters), 45772 # take no chances and rewrite it. 45773 # Note: m4 eats our [], so we need to use [ and ] instead. 45774 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 45775 if test "x$has_forbidden_chars" != x; then 45776 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 45777 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 45778 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 45779 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 45780 # Going to short mode and back again did indeed matter. Since short mode is 45781 # case insensitive, let's make it lowercase to improve readability. 45782 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 45783 # Now convert it back to Unix-style (cygpath) 45784 input_path=`$CYGPATH -u "$shortmode_path"` 45785 new_path="$input_path" 45786 fi 45787 fi 45788 45789 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 45790 if test "x$test_cygdrive_prefix" = x; then 45791 # As a simple fix, exclude /usr/bin since it's not a real path. 45792 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 45793 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 45794 # a path prefixed by /cygdrive for fixpath to work. 45795 new_path="$CYGWIN_ROOT_PATH$input_path" 45796 fi 45797 fi 45798 45799 # remove trailing .exe if any 45800 new_path="${new_path/%.exe/}" 45801 45802 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45803 45804 # First separate the path from the arguments. This will split at the first 45805 # space. 45806 complete="$BUILD_AR" 45807 path="${complete%% *}" 45808 tmp="$complete EOL" 45809 arguments="${tmp#* }" 45810 45811 # Input might be given as Windows format, start by converting to 45812 # unix format. 45813 new_path="$path" 45814 45815 windows_path="$new_path" 45816 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45817 unix_path=`$CYGPATH -u "$windows_path"` 45818 new_path="$unix_path" 45819 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45820 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45821 new_path="$unix_path" 45822 fi 45823 45824 45825 # Now try to locate executable using which 45826 new_path=`$WHICH "$new_path" 2> /dev/null` 45827 45828 if test "x$new_path" = x; then 45829 # Oops. Which didn't find the executable. 45830 # The splitting of arguments from the executable at a space might have been incorrect, 45831 # since paths with space are more likely in Windows. Give it another try with the whole 45832 # argument. 45833 path="$complete" 45834 arguments="EOL" 45835 new_path="$path" 45836 45837 windows_path="$new_path" 45838 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45839 unix_path=`$CYGPATH -u "$windows_path"` 45840 new_path="$unix_path" 45841 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45842 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45843 new_path="$unix_path" 45844 fi 45845 45846 45847 new_path=`$WHICH "$new_path" 2> /dev/null` 45848 # bat and cmd files are not always considered executable in MSYS causing which 45849 # to not find them 45850 if test "x$new_path" = x \ 45851 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 45852 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 45853 new_path="$path" 45854 45855 windows_path="$new_path" 45856 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45857 unix_path=`$CYGPATH -u "$windows_path"` 45858 new_path="$unix_path" 45859 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45860 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45861 new_path="$unix_path" 45862 fi 45863 45864 fi 45865 45866 if test "x$new_path" = x; then 45867 # It's still not found. Now this is an unrecoverable error. 45868 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&5 45869 $as_echo "$as_me: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&6;} 45870 has_space=`$ECHO "$complete" | $GREP " "` 45871 if test "x$has_space" != x; then 45872 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 45873 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 45874 fi 45875 as_fn_error $? "Cannot locate the the path of BUILD_AR" "$LINENO" 5 45876 fi 45877 fi 45878 45879 # Now new_path has a complete unix path to the binary 45880 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 45881 # Keep paths in /bin as-is, but remove trailing .exe if any 45882 new_path="${new_path/%.exe/}" 45883 # Do not save /bin paths to all_fixpath_prefixes! 45884 else 45885 # Not in mixed or Windows style, start by that. 45886 new_path=`cmd //c echo $new_path` 45887 45888 input_path="$new_path" 45889 # Check if we need to convert this using DOS-style short mode. If the path 45890 # contains just simple characters, use it. Otherwise (spaces, weird characters), 45891 # take no chances and rewrite it. 45892 # Note: m4 eats our [], so we need to use [ and ] instead. 45893 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 45894 if test "x$has_forbidden_chars" != x; then 45895 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 45896 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 45897 fi 45898 45899 # Output is in $new_path 45900 45901 windows_path="$new_path" 45902 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45903 unix_path=`$CYGPATH -u "$windows_path"` 45904 new_path="$unix_path" 45905 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45906 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45907 new_path="$unix_path" 45908 fi 45909 45910 # remove trailing .exe if any 45911 new_path="${new_path/%.exe/}" 45912 45913 # Save the first 10 bytes of this path to the storage, so fixpath can work. 45914 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 45915 fi 45916 45917 else 45918 # We're on a unix platform. Hooray! :) 45919 # First separate the path from the arguments. This will split at the first 45920 # space. 45921 complete="$BUILD_AR" 45922 path="${complete%% *}" 45923 tmp="$complete EOL" 45924 arguments="${tmp#* }" 45925 45926 # Cannot rely on the command "which" here since it doesn't always work. 45927 is_absolute_path=`$ECHO "$path" | $GREP ^/` 45928 if test -z "$is_absolute_path"; then 45929 # Path to executable is not absolute. Find it. 45930 IFS_save="$IFS" 45931 IFS=: 45932 for p in $PATH; do 45933 if test -f "$p/$path" && test -x "$p/$path"; then 45934 new_path="$p/$path" 45935 break 45936 fi 45937 done 45938 IFS="$IFS_save" 45939 else 45940 # This is an absolute path, we can use it without further modifications. 45941 new_path="$path" 45942 fi 45943 45944 if test "x$new_path" = x; then 45945 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&5 45946 $as_echo "$as_me: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&6;} 45947 has_space=`$ECHO "$complete" | $GREP " "` 45948 if test "x$has_space" != x; then 45949 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 45950 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 45951 fi 45952 as_fn_error $? "Cannot locate the the path of BUILD_AR" "$LINENO" 5 45953 fi 45954 fi 45955 45956 # Now join together the path and the arguments once again 45957 if test "x$arguments" != xEOL; then 45958 new_complete="$new_path ${arguments% *}" 45959 else 45960 new_complete="$new_path" 45961 fi 45962 45963 if test "x$complete" != "x$new_complete"; then 45964 BUILD_AR="$new_complete" 45965 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_AR to \"$new_complete\"" >&5 45966 $as_echo "$as_me: Rewriting BUILD_AR to \"$new_complete\"" >&6;} 45967 fi 45968 fi 45969 45970 45971 45972 # Publish this variable in the help. 45973 45974 45975 if [ -z "${BUILD_OBJCOPY+x}" ]; then 45976 # The variable is not set by user, try to locate tool using the code snippet 45977 for ac_prog in objcopy 45978 do 45979 # Extract the first word of "$ac_prog", so it can be a program name with args. 45980 set dummy $ac_prog; ac_word=$2 45981 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45982 $as_echo_n "checking for $ac_word... " >&6; } 45983 if ${ac_cv_path_BUILD_OBJCOPY+:} false; then : 45984 $as_echo_n "(cached) " >&6 45985 else 45986 case $BUILD_OBJCOPY in 45987 [\\/]* | ?:[\\/]*) 45988 ac_cv_path_BUILD_OBJCOPY="$BUILD_OBJCOPY" # Let the user override the test with a path. 45989 ;; 45990 *) 45991 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45992 for as_dir in $PATH 45993 do 45994 IFS=$as_save_IFS 45995 test -z "$as_dir" && as_dir=. 45996 for ac_exec_ext in '' $ac_executable_extensions; do 45997 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45998 ac_cv_path_BUILD_OBJCOPY="$as_dir/$ac_word$ac_exec_ext" 45999 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46000 break 2 46001 fi 46002 done 46003 done 46004 IFS=$as_save_IFS 46005 46006 ;; 46007 esac 46008 fi 46009 BUILD_OBJCOPY=$ac_cv_path_BUILD_OBJCOPY 46010 if test -n "$BUILD_OBJCOPY"; then 46011 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_OBJCOPY" >&5 46012 $as_echo "$BUILD_OBJCOPY" >&6; } 46013 else 46014 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46015 $as_echo "no" >&6; } 46016 fi 46017 46018 46019 test -n "$BUILD_OBJCOPY" && break 46020 done 46021 46022 else 46023 # The variable is set, but is it from the command line or the environment? 46024 46025 # Try to remove the string !BUILD_OBJCOPY! from our list. 46026 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_OBJCOPY!/} 46027 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 46028 # If it failed, the variable was not from the command line. Ignore it, 46029 # but warn the user (except for BASH, which is always set by the calling BASH). 46030 if test "xBUILD_OBJCOPY" != xBASH; then 46031 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_OBJCOPY from the environment. Use command line variables instead." >&5 46032 $as_echo "$as_me: WARNING: Ignoring value of BUILD_OBJCOPY from the environment. Use command line variables instead." >&2;} 46033 fi 46034 # Try to locate tool using the code snippet 46035 for ac_prog in objcopy 46036 do 46037 # Extract the first word of "$ac_prog", so it can be a program name with args. 46038 set dummy $ac_prog; ac_word=$2 46039 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 46040 $as_echo_n "checking for $ac_word... " >&6; } 46041 if ${ac_cv_path_BUILD_OBJCOPY+:} false; then : 46042 $as_echo_n "(cached) " >&6 46043 else 46044 case $BUILD_OBJCOPY in 46045 [\\/]* | ?:[\\/]*) 46046 ac_cv_path_BUILD_OBJCOPY="$BUILD_OBJCOPY" # Let the user override the test with a path. 46047 ;; 46048 *) 46049 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46050 for as_dir in $PATH 46051 do 46052 IFS=$as_save_IFS 46053 test -z "$as_dir" && as_dir=. 46054 for ac_exec_ext in '' $ac_executable_extensions; do 46055 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46056 ac_cv_path_BUILD_OBJCOPY="$as_dir/$ac_word$ac_exec_ext" 46057 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46058 break 2 46059 fi 46060 done 46061 done 46062 IFS=$as_save_IFS 46063 46064 ;; 46065 esac 46066 fi 46067 BUILD_OBJCOPY=$ac_cv_path_BUILD_OBJCOPY 46068 if test -n "$BUILD_OBJCOPY"; then 46069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_OBJCOPY" >&5 46070 $as_echo "$BUILD_OBJCOPY" >&6; } 46071 else 46072 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46073 $as_echo "no" >&6; } 46074 fi 46075 46076 46077 test -n "$BUILD_OBJCOPY" && break 46078 done 46079 46080 else 46081 # If it succeeded, then it was overridden by the user. We will use it 46082 # for the tool. 46083 46084 # First remove it from the list of overridden variables, so we can test 46085 # for unknown variables in the end. 46086 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 46087 46088 # Check if we try to supply an empty value 46089 if test "x$BUILD_OBJCOPY" = x; then 46090 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_OBJCOPY= (no value)" >&5 46091 $as_echo "$as_me: Setting user supplied tool BUILD_OBJCOPY= (no value)" >&6;} 46092 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_OBJCOPY" >&5 46093 $as_echo_n "checking for BUILD_OBJCOPY... " >&6; } 46094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 46095 $as_echo "disabled" >&6; } 46096 else 46097 # Check if the provided tool contains a complete path. 46098 tool_specified="$BUILD_OBJCOPY" 46099 tool_basename="${tool_specified##*/}" 46100 if test "x$tool_basename" = "x$tool_specified"; then 46101 # A command without a complete path is provided, search $PATH. 46102 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_OBJCOPY=$tool_basename" >&5 46103 $as_echo "$as_me: Will search for user supplied tool BUILD_OBJCOPY=$tool_basename" >&6;} 46104 # Extract the first word of "$tool_basename", so it can be a program name with args. 46105 set dummy $tool_basename; ac_word=$2 46106 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 46107 $as_echo_n "checking for $ac_word... " >&6; } 46108 if ${ac_cv_path_BUILD_OBJCOPY+:} false; then : 46109 $as_echo_n "(cached) " >&6 46110 else 46111 case $BUILD_OBJCOPY in 46112 [\\/]* | ?:[\\/]*) 46113 ac_cv_path_BUILD_OBJCOPY="$BUILD_OBJCOPY" # Let the user override the test with a path. 46114 ;; 46115 *) 46116 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46117 for as_dir in $PATH 46118 do 46119 IFS=$as_save_IFS 46120 test -z "$as_dir" && as_dir=. 46121 for ac_exec_ext in '' $ac_executable_extensions; do 46122 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46123 ac_cv_path_BUILD_OBJCOPY="$as_dir/$ac_word$ac_exec_ext" 46124 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46125 break 2 46126 fi 46127 done 46128 done 46129 IFS=$as_save_IFS 46130 46131 ;; 46132 esac 46133 fi 46134 BUILD_OBJCOPY=$ac_cv_path_BUILD_OBJCOPY 46135 if test -n "$BUILD_OBJCOPY"; then 46136 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_OBJCOPY" >&5 46137 $as_echo "$BUILD_OBJCOPY" >&6; } 46138 else 46139 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46140 $as_echo "no" >&6; } 46141 fi 46142 46143 46144 if test "x$BUILD_OBJCOPY" = x; then 46145 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 46146 fi 46147 else 46148 # Otherwise we believe it is a complete path. Use it as it is. 46149 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_OBJCOPY=$tool_specified" >&5 46150 $as_echo "$as_me: Will use user supplied tool BUILD_OBJCOPY=$tool_specified" >&6;} 46151 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_OBJCOPY" >&5 46152 $as_echo_n "checking for BUILD_OBJCOPY... " >&6; } 46153 if test ! -x "$tool_specified"; then 46154 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 46155 $as_echo "not found" >&6; } 46156 as_fn_error $? "User supplied tool BUILD_OBJCOPY=$tool_specified does not exist or is not executable" "$LINENO" 5 46157 fi 46158 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 46159 $as_echo "$tool_specified" >&6; } 46160 fi 46161 fi 46162 fi 46163 46164 fi 46165 46166 46167 46168 # Only process if variable expands to non-empty 46169 46170 if test "x$BUILD_OBJCOPY" != x; then 46171 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46172 46173 # First separate the path from the arguments. This will split at the first 46174 # space. 46175 complete="$BUILD_OBJCOPY" 46176 path="${complete%% *}" 46177 tmp="$complete EOL" 46178 arguments="${tmp#* }" 46179 46180 # Input might be given as Windows format, start by converting to 46181 # unix format. 46182 new_path=`$CYGPATH -u "$path"` 46183 46184 # Now try to locate executable using which 46185 new_path=`$WHICH "$new_path" 2> /dev/null` 46186 # bat and cmd files are not always considered executable in cygwin causing which 46187 # to not find them 46188 if test "x$new_path" = x \ 46189 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46190 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46191 new_path=`$CYGPATH -u "$path"` 46192 fi 46193 if test "x$new_path" = x; then 46194 # Oops. Which didn't find the executable. 46195 # The splitting of arguments from the executable at a space might have been incorrect, 46196 # since paths with space are more likely in Windows. Give it another try with the whole 46197 # argument. 46198 path="$complete" 46199 arguments="EOL" 46200 new_path=`$CYGPATH -u "$path"` 46201 new_path=`$WHICH "$new_path" 2> /dev/null` 46202 # bat and cmd files are not always considered executable in cygwin causing which 46203 # to not find them 46204 if test "x$new_path" = x \ 46205 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46206 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46207 new_path=`$CYGPATH -u "$path"` 46208 fi 46209 if test "x$new_path" = x; then 46210 # It's still not found. Now this is an unrecoverable error. 46211 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&5 46212 $as_echo "$as_me: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 46213 has_space=`$ECHO "$complete" | $GREP " "` 46214 if test "x$has_space" != x; then 46215 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 46216 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 46217 fi 46218 as_fn_error $? "Cannot locate the the path of BUILD_OBJCOPY" "$LINENO" 5 46219 fi 46220 fi 46221 46222 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 46223 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 46224 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 46225 # "foo.exe" is OK but "foo" is an error. 46226 # 46227 # This test is therefore slightly more accurate than "test -f" to check for file presence. 46228 # It is also a way to make sure we got the proper file name for the real test later on. 46229 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 46230 if test "x$test_shortpath" = x; then 46231 # Short path failed, file does not exist as specified. 46232 # Try adding .exe or .cmd 46233 if test -f "${new_path}.exe"; then 46234 input_to_shortpath="${new_path}.exe" 46235 elif test -f "${new_path}.cmd"; then 46236 input_to_shortpath="${new_path}.cmd" 46237 else 46238 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_OBJCOPY, which resolves as \"$new_path\", is invalid." >&5 46239 $as_echo "$as_me: The path of BUILD_OBJCOPY, which resolves as \"$new_path\", is invalid." >&6;} 46240 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 46241 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 46242 as_fn_error $? "Cannot locate the the path of BUILD_OBJCOPY" "$LINENO" 5 46243 fi 46244 else 46245 input_to_shortpath="$new_path" 46246 fi 46247 46248 # Call helper function which possibly converts this using DOS-style short mode. 46249 # If so, the updated path is stored in $new_path. 46250 new_path="$input_to_shortpath" 46251 46252 input_path="$input_to_shortpath" 46253 # Check if we need to convert this using DOS-style short mode. If the path 46254 # contains just simple characters, use it. Otherwise (spaces, weird characters), 46255 # take no chances and rewrite it. 46256 # Note: m4 eats our [], so we need to use [ and ] instead. 46257 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 46258 if test "x$has_forbidden_chars" != x; then 46259 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 46260 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 46261 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 46262 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 46263 # Going to short mode and back again did indeed matter. Since short mode is 46264 # case insensitive, let's make it lowercase to improve readability. 46265 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 46266 # Now convert it back to Unix-style (cygpath) 46267 input_path=`$CYGPATH -u "$shortmode_path"` 46268 new_path="$input_path" 46269 fi 46270 fi 46271 46272 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 46273 if test "x$test_cygdrive_prefix" = x; then 46274 # As a simple fix, exclude /usr/bin since it's not a real path. 46275 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 46276 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 46277 # a path prefixed by /cygdrive for fixpath to work. 46278 new_path="$CYGWIN_ROOT_PATH$input_path" 46279 fi 46280 fi 46281 46282 # remove trailing .exe if any 46283 new_path="${new_path/%.exe/}" 46284 46285 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46286 46287 # First separate the path from the arguments. This will split at the first 46288 # space. 46289 complete="$BUILD_OBJCOPY" 46290 path="${complete%% *}" 46291 tmp="$complete EOL" 46292 arguments="${tmp#* }" 46293 46294 # Input might be given as Windows format, start by converting to 46295 # unix format. 46296 new_path="$path" 46297 46298 windows_path="$new_path" 46299 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46300 unix_path=`$CYGPATH -u "$windows_path"` 46301 new_path="$unix_path" 46302 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46303 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46304 new_path="$unix_path" 46305 fi 46306 46307 46308 # Now try to locate executable using which 46309 new_path=`$WHICH "$new_path" 2> /dev/null` 46310 46311 if test "x$new_path" = x; then 46312 # Oops. Which didn't find the executable. 46313 # The splitting of arguments from the executable at a space might have been incorrect, 46314 # since paths with space are more likely in Windows. Give it another try with the whole 46315 # argument. 46316 path="$complete" 46317 arguments="EOL" 46318 new_path="$path" 46319 46320 windows_path="$new_path" 46321 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46322 unix_path=`$CYGPATH -u "$windows_path"` 46323 new_path="$unix_path" 46324 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46325 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46326 new_path="$unix_path" 46327 fi 46328 46329 46330 new_path=`$WHICH "$new_path" 2> /dev/null` 46331 # bat and cmd files are not always considered executable in MSYS causing which 46332 # to not find them 46333 if test "x$new_path" = x \ 46334 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46335 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46336 new_path="$path" 46337 46338 windows_path="$new_path" 46339 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46340 unix_path=`$CYGPATH -u "$windows_path"` 46341 new_path="$unix_path" 46342 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46343 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46344 new_path="$unix_path" 46345 fi 46346 46347 fi 46348 46349 if test "x$new_path" = x; then 46350 # It's still not found. Now this is an unrecoverable error. 46351 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&5 46352 $as_echo "$as_me: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 46353 has_space=`$ECHO "$complete" | $GREP " "` 46354 if test "x$has_space" != x; then 46355 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 46356 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 46357 fi 46358 as_fn_error $? "Cannot locate the the path of BUILD_OBJCOPY" "$LINENO" 5 46359 fi 46360 fi 46361 46362 # Now new_path has a complete unix path to the binary 46363 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 46364 # Keep paths in /bin as-is, but remove trailing .exe if any 46365 new_path="${new_path/%.exe/}" 46366 # Do not save /bin paths to all_fixpath_prefixes! 46367 else 46368 # Not in mixed or Windows style, start by that. 46369 new_path=`cmd //c echo $new_path` 46370 46371 input_path="$new_path" 46372 # Check if we need to convert this using DOS-style short mode. If the path 46373 # contains just simple characters, use it. Otherwise (spaces, weird characters), 46374 # take no chances and rewrite it. 46375 # Note: m4 eats our [], so we need to use [ and ] instead. 46376 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 46377 if test "x$has_forbidden_chars" != x; then 46378 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 46379 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 46380 fi 46381 46382 # Output is in $new_path 46383 46384 windows_path="$new_path" 46385 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46386 unix_path=`$CYGPATH -u "$windows_path"` 46387 new_path="$unix_path" 46388 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46389 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46390 new_path="$unix_path" 46391 fi 46392 46393 # remove trailing .exe if any 46394 new_path="${new_path/%.exe/}" 46395 46396 # Save the first 10 bytes of this path to the storage, so fixpath can work. 46397 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 46398 fi 46399 46400 else 46401 # We're on a unix platform. Hooray! :) 46402 # First separate the path from the arguments. This will split at the first 46403 # space. 46404 complete="$BUILD_OBJCOPY" 46405 path="${complete%% *}" 46406 tmp="$complete EOL" 46407 arguments="${tmp#* }" 46408 46409 # Cannot rely on the command "which" here since it doesn't always work. 46410 is_absolute_path=`$ECHO "$path" | $GREP ^/` 46411 if test -z "$is_absolute_path"; then 46412 # Path to executable is not absolute. Find it. 46413 IFS_save="$IFS" 46414 IFS=: 46415 for p in $PATH; do 46416 if test -f "$p/$path" && test -x "$p/$path"; then 46417 new_path="$p/$path" 46418 break 46419 fi 46420 done 46421 IFS="$IFS_save" 46422 else 46423 # This is an absolute path, we can use it without further modifications. 46424 new_path="$path" 46425 fi 46426 46427 if test "x$new_path" = x; then 46428 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&5 46429 $as_echo "$as_me: The path of BUILD_OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 46430 has_space=`$ECHO "$complete" | $GREP " "` 46431 if test "x$has_space" != x; then 46432 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 46433 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 46434 fi 46435 as_fn_error $? "Cannot locate the the path of BUILD_OBJCOPY" "$LINENO" 5 46436 fi 46437 fi 46438 46439 # Now join together the path and the arguments once again 46440 if test "x$arguments" != xEOL; then 46441 new_complete="$new_path ${arguments% *}" 46442 else 46443 new_complete="$new_path" 46444 fi 46445 46446 if test "x$complete" != "x$new_complete"; then 46447 BUILD_OBJCOPY="$new_complete" 46448 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_OBJCOPY to \"$new_complete\"" >&5 46449 $as_echo "$as_me: Rewriting BUILD_OBJCOPY to \"$new_complete\"" >&6;} 46450 fi 46451 fi 46452 46453 46454 46455 # Publish this variable in the help. 46456 46457 46458 if [ -z "${BUILD_STRIP+x}" ]; then 46459 # The variable is not set by user, try to locate tool using the code snippet 46460 for ac_prog in strip 46461 do 46462 # Extract the first word of "$ac_prog", so it can be a program name with args. 46463 set dummy $ac_prog; ac_word=$2 46464 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 46465 $as_echo_n "checking for $ac_word... " >&6; } 46466 if ${ac_cv_path_BUILD_STRIP+:} false; then : 46467 $as_echo_n "(cached) " >&6 46468 else 46469 case $BUILD_STRIP in 46470 [\\/]* | ?:[\\/]*) 46471 ac_cv_path_BUILD_STRIP="$BUILD_STRIP" # Let the user override the test with a path. 46472 ;; 46473 *) 46474 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46475 for as_dir in $PATH 46476 do 46477 IFS=$as_save_IFS 46478 test -z "$as_dir" && as_dir=. 46479 for ac_exec_ext in '' $ac_executable_extensions; do 46480 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46481 ac_cv_path_BUILD_STRIP="$as_dir/$ac_word$ac_exec_ext" 46482 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46483 break 2 46484 fi 46485 done 46486 done 46487 IFS=$as_save_IFS 46488 46489 ;; 46490 esac 46491 fi 46492 BUILD_STRIP=$ac_cv_path_BUILD_STRIP 46493 if test -n "$BUILD_STRIP"; then 46494 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_STRIP" >&5 46495 $as_echo "$BUILD_STRIP" >&6; } 46496 else 46497 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46498 $as_echo "no" >&6; } 46499 fi 46500 46501 46502 test -n "$BUILD_STRIP" && break 46503 done 46504 46505 else 46506 # The variable is set, but is it from the command line or the environment? 46507 46508 # Try to remove the string !BUILD_STRIP! from our list. 46509 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_STRIP!/} 46510 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 46511 # If it failed, the variable was not from the command line. Ignore it, 46512 # but warn the user (except for BASH, which is always set by the calling BASH). 46513 if test "xBUILD_STRIP" != xBASH; then 46514 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_STRIP from the environment. Use command line variables instead." >&5 46515 $as_echo "$as_me: WARNING: Ignoring value of BUILD_STRIP from the environment. Use command line variables instead." >&2;} 46516 fi 46517 # Try to locate tool using the code snippet 46518 for ac_prog in strip 46519 do 46520 # Extract the first word of "$ac_prog", so it can be a program name with args. 46521 set dummy $ac_prog; ac_word=$2 46522 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 46523 $as_echo_n "checking for $ac_word... " >&6; } 46524 if ${ac_cv_path_BUILD_STRIP+:} false; then : 46525 $as_echo_n "(cached) " >&6 46526 else 46527 case $BUILD_STRIP in 46528 [\\/]* | ?:[\\/]*) 46529 ac_cv_path_BUILD_STRIP="$BUILD_STRIP" # Let the user override the test with a path. 46530 ;; 46531 *) 46532 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46533 for as_dir in $PATH 46534 do 46535 IFS=$as_save_IFS 46536 test -z "$as_dir" && as_dir=. 46537 for ac_exec_ext in '' $ac_executable_extensions; do 46538 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46539 ac_cv_path_BUILD_STRIP="$as_dir/$ac_word$ac_exec_ext" 46540 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46541 break 2 46542 fi 46543 done 46544 done 46545 IFS=$as_save_IFS 46546 46547 ;; 46548 esac 46549 fi 46550 BUILD_STRIP=$ac_cv_path_BUILD_STRIP 46551 if test -n "$BUILD_STRIP"; then 46552 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_STRIP" >&5 46553 $as_echo "$BUILD_STRIP" >&6; } 46554 else 46555 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46556 $as_echo "no" >&6; } 46557 fi 46558 46559 46560 test -n "$BUILD_STRIP" && break 46561 done 46562 46563 else 46564 # If it succeeded, then it was overridden by the user. We will use it 46565 # for the tool. 46566 46567 # First remove it from the list of overridden variables, so we can test 46568 # for unknown variables in the end. 46569 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 46570 46571 # Check if we try to supply an empty value 46572 if test "x$BUILD_STRIP" = x; then 46573 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_STRIP= (no value)" >&5 46574 $as_echo "$as_me: Setting user supplied tool BUILD_STRIP= (no value)" >&6;} 46575 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_STRIP" >&5 46576 $as_echo_n "checking for BUILD_STRIP... " >&6; } 46577 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 46578 $as_echo "disabled" >&6; } 46579 else 46580 # Check if the provided tool contains a complete path. 46581 tool_specified="$BUILD_STRIP" 46582 tool_basename="${tool_specified##*/}" 46583 if test "x$tool_basename" = "x$tool_specified"; then 46584 # A command without a complete path is provided, search $PATH. 46585 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_STRIP=$tool_basename" >&5 46586 $as_echo "$as_me: Will search for user supplied tool BUILD_STRIP=$tool_basename" >&6;} 46587 # Extract the first word of "$tool_basename", so it can be a program name with args. 46588 set dummy $tool_basename; ac_word=$2 46589 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 46590 $as_echo_n "checking for $ac_word... " >&6; } 46591 if ${ac_cv_path_BUILD_STRIP+:} false; then : 46592 $as_echo_n "(cached) " >&6 46593 else 46594 case $BUILD_STRIP in 46595 [\\/]* | ?:[\\/]*) 46596 ac_cv_path_BUILD_STRIP="$BUILD_STRIP" # Let the user override the test with a path. 46597 ;; 46598 *) 46599 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 46600 for as_dir in $PATH 46601 do 46602 IFS=$as_save_IFS 46603 test -z "$as_dir" && as_dir=. 46604 for ac_exec_ext in '' $ac_executable_extensions; do 46605 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 46606 ac_cv_path_BUILD_STRIP="$as_dir/$ac_word$ac_exec_ext" 46607 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 46608 break 2 46609 fi 46610 done 46611 done 46612 IFS=$as_save_IFS 46613 46614 ;; 46615 esac 46616 fi 46617 BUILD_STRIP=$ac_cv_path_BUILD_STRIP 46618 if test -n "$BUILD_STRIP"; then 46619 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_STRIP" >&5 46620 $as_echo "$BUILD_STRIP" >&6; } 46621 else 46622 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 46623 $as_echo "no" >&6; } 46624 fi 46625 46626 46627 if test "x$BUILD_STRIP" = x; then 46628 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 46629 fi 46630 else 46631 # Otherwise we believe it is a complete path. Use it as it is. 46632 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_STRIP=$tool_specified" >&5 46633 $as_echo "$as_me: Will use user supplied tool BUILD_STRIP=$tool_specified" >&6;} 46634 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_STRIP" >&5 46635 $as_echo_n "checking for BUILD_STRIP... " >&6; } 46636 if test ! -x "$tool_specified"; then 46637 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 46638 $as_echo "not found" >&6; } 46639 as_fn_error $? "User supplied tool BUILD_STRIP=$tool_specified does not exist or is not executable" "$LINENO" 5 46640 fi 46641 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 46642 $as_echo "$tool_specified" >&6; } 46643 fi 46644 fi 46645 fi 46646 46647 fi 46648 46649 46650 46651 # Only process if variable expands to non-empty 46652 46653 if test "x$BUILD_STRIP" != x; then 46654 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46655 46656 # First separate the path from the arguments. This will split at the first 46657 # space. 46658 complete="$BUILD_STRIP" 46659 path="${complete%% *}" 46660 tmp="$complete EOL" 46661 arguments="${tmp#* }" 46662 46663 # Input might be given as Windows format, start by converting to 46664 # unix format. 46665 new_path=`$CYGPATH -u "$path"` 46666 46667 # Now try to locate executable using which 46668 new_path=`$WHICH "$new_path" 2> /dev/null` 46669 # bat and cmd files are not always considered executable in cygwin causing which 46670 # to not find them 46671 if test "x$new_path" = x \ 46672 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46673 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46674 new_path=`$CYGPATH -u "$path"` 46675 fi 46676 if test "x$new_path" = x; then 46677 # Oops. Which didn't find the executable. 46678 # The splitting of arguments from the executable at a space might have been incorrect, 46679 # since paths with space are more likely in Windows. Give it another try with the whole 46680 # argument. 46681 path="$complete" 46682 arguments="EOL" 46683 new_path=`$CYGPATH -u "$path"` 46684 new_path=`$WHICH "$new_path" 2> /dev/null` 46685 # bat and cmd files are not always considered executable in cygwin causing which 46686 # to not find them 46687 if test "x$new_path" = x \ 46688 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46689 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46690 new_path=`$CYGPATH -u "$path"` 46691 fi 46692 if test "x$new_path" = x; then 46693 # It's still not found. Now this is an unrecoverable error. 46694 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&5 46695 $as_echo "$as_me: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&6;} 46696 has_space=`$ECHO "$complete" | $GREP " "` 46697 if test "x$has_space" != x; then 46698 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 46699 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 46700 fi 46701 as_fn_error $? "Cannot locate the the path of BUILD_STRIP" "$LINENO" 5 46702 fi 46703 fi 46704 46705 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 46706 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 46707 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 46708 # "foo.exe" is OK but "foo" is an error. 46709 # 46710 # This test is therefore slightly more accurate than "test -f" to check for file presence. 46711 # It is also a way to make sure we got the proper file name for the real test later on. 46712 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 46713 if test "x$test_shortpath" = x; then 46714 # Short path failed, file does not exist as specified. 46715 # Try adding .exe or .cmd 46716 if test -f "${new_path}.exe"; then 46717 input_to_shortpath="${new_path}.exe" 46718 elif test -f "${new_path}.cmd"; then 46719 input_to_shortpath="${new_path}.cmd" 46720 else 46721 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_STRIP, which resolves as \"$new_path\", is invalid." >&5 46722 $as_echo "$as_me: The path of BUILD_STRIP, which resolves as \"$new_path\", is invalid." >&6;} 46723 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 46724 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 46725 as_fn_error $? "Cannot locate the the path of BUILD_STRIP" "$LINENO" 5 46726 fi 46727 else 46728 input_to_shortpath="$new_path" 46729 fi 46730 46731 # Call helper function which possibly converts this using DOS-style short mode. 46732 # If so, the updated path is stored in $new_path. 46733 new_path="$input_to_shortpath" 46734 46735 input_path="$input_to_shortpath" 46736 # Check if we need to convert this using DOS-style short mode. If the path 46737 # contains just simple characters, use it. Otherwise (spaces, weird characters), 46738 # take no chances and rewrite it. 46739 # Note: m4 eats our [], so we need to use [ and ] instead. 46740 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 46741 if test "x$has_forbidden_chars" != x; then 46742 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 46743 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 46744 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 46745 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 46746 # Going to short mode and back again did indeed matter. Since short mode is 46747 # case insensitive, let's make it lowercase to improve readability. 46748 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 46749 # Now convert it back to Unix-style (cygpath) 46750 input_path=`$CYGPATH -u "$shortmode_path"` 46751 new_path="$input_path" 46752 fi 46753 fi 46754 46755 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 46756 if test "x$test_cygdrive_prefix" = x; then 46757 # As a simple fix, exclude /usr/bin since it's not a real path. 46758 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 46759 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 46760 # a path prefixed by /cygdrive for fixpath to work. 46761 new_path="$CYGWIN_ROOT_PATH$input_path" 46762 fi 46763 fi 46764 46765 # remove trailing .exe if any 46766 new_path="${new_path/%.exe/}" 46767 46768 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46769 46770 # First separate the path from the arguments. This will split at the first 46771 # space. 46772 complete="$BUILD_STRIP" 46773 path="${complete%% *}" 46774 tmp="$complete EOL" 46775 arguments="${tmp#* }" 46776 46777 # Input might be given as Windows format, start by converting to 46778 # unix format. 46779 new_path="$path" 46780 46781 windows_path="$new_path" 46782 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46783 unix_path=`$CYGPATH -u "$windows_path"` 46784 new_path="$unix_path" 46785 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46786 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46787 new_path="$unix_path" 46788 fi 46789 46790 46791 # Now try to locate executable using which 46792 new_path=`$WHICH "$new_path" 2> /dev/null` 46793 46794 if test "x$new_path" = x; then 46795 # Oops. Which didn't find the executable. 46796 # The splitting of arguments from the executable at a space might have been incorrect, 46797 # since paths with space are more likely in Windows. Give it another try with the whole 46798 # argument. 46799 path="$complete" 46800 arguments="EOL" 46801 new_path="$path" 46802 46803 windows_path="$new_path" 46804 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46805 unix_path=`$CYGPATH -u "$windows_path"` 46806 new_path="$unix_path" 46807 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46808 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46809 new_path="$unix_path" 46810 fi 46811 46812 46813 new_path=`$WHICH "$new_path" 2> /dev/null` 46814 # bat and cmd files are not always considered executable in MSYS causing which 46815 # to not find them 46816 if test "x$new_path" = x \ 46817 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 46818 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 46819 new_path="$path" 46820 46821 windows_path="$new_path" 46822 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46823 unix_path=`$CYGPATH -u "$windows_path"` 46824 new_path="$unix_path" 46825 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46826 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46827 new_path="$unix_path" 46828 fi 46829 46830 fi 46831 46832 if test "x$new_path" = x; then 46833 # It's still not found. Now this is an unrecoverable error. 46834 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&5 46835 $as_echo "$as_me: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&6;} 46836 has_space=`$ECHO "$complete" | $GREP " "` 46837 if test "x$has_space" != x; then 46838 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 46839 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 46840 fi 46841 as_fn_error $? "Cannot locate the the path of BUILD_STRIP" "$LINENO" 5 46842 fi 46843 fi 46844 46845 # Now new_path has a complete unix path to the binary 46846 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 46847 # Keep paths in /bin as-is, but remove trailing .exe if any 46848 new_path="${new_path/%.exe/}" 46849 # Do not save /bin paths to all_fixpath_prefixes! 46850 else 46851 # Not in mixed or Windows style, start by that. 46852 new_path=`cmd //c echo $new_path` 46853 46854 input_path="$new_path" 46855 # Check if we need to convert this using DOS-style short mode. If the path 46856 # contains just simple characters, use it. Otherwise (spaces, weird characters), 46857 # take no chances and rewrite it. 46858 # Note: m4 eats our [], so we need to use [ and ] instead. 46859 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 46860 if test "x$has_forbidden_chars" != x; then 46861 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 46862 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 46863 fi 46864 46865 # Output is in $new_path 46866 46867 windows_path="$new_path" 46868 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46869 unix_path=`$CYGPATH -u "$windows_path"` 46870 new_path="$unix_path" 46871 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46872 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 46873 new_path="$unix_path" 46874 fi 46875 46876 # remove trailing .exe if any 46877 new_path="${new_path/%.exe/}" 46878 46879 # Save the first 10 bytes of this path to the storage, so fixpath can work. 46880 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 46881 fi 46882 46883 else 46884 # We're on a unix platform. Hooray! :) 46885 # First separate the path from the arguments. This will split at the first 46886 # space. 46887 complete="$BUILD_STRIP" 46888 path="${complete%% *}" 46889 tmp="$complete EOL" 46890 arguments="${tmp#* }" 46891 46892 # Cannot rely on the command "which" here since it doesn't always work. 46893 is_absolute_path=`$ECHO "$path" | $GREP ^/` 46894 if test -z "$is_absolute_path"; then 46895 # Path to executable is not absolute. Find it. 46896 IFS_save="$IFS" 46897 IFS=: 46898 for p in $PATH; do 46899 if test -f "$p/$path" && test -x "$p/$path"; then 46900 new_path="$p/$path" 46901 break 46902 fi 46903 done 46904 IFS="$IFS_save" 46905 else 46906 # This is an absolute path, we can use it without further modifications. 46907 new_path="$path" 46908 fi 46909 46910 if test "x$new_path" = x; then 46911 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&5 46912 $as_echo "$as_me: The path of BUILD_STRIP, which resolves as \"$complete\", is not found." >&6;} 46913 has_space=`$ECHO "$complete" | $GREP " "` 46914 if test "x$has_space" != x; then 46915 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 46916 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 46917 fi 46918 as_fn_error $? "Cannot locate the the path of BUILD_STRIP" "$LINENO" 5 46919 fi 46920 fi 46921 46922 # Now join together the path and the arguments once again 46923 if test "x$arguments" != xEOL; then 46924 new_complete="$new_path ${arguments% *}" 46925 else 46926 new_complete="$new_path" 46927 fi 46928 46929 if test "x$complete" != "x$new_complete"; then 46930 BUILD_STRIP="$new_complete" 46931 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_STRIP to \"$new_complete\"" >&5 46932 $as_echo "$as_me: Rewriting BUILD_STRIP to \"$new_complete\"" >&6;} 46933 fi 46934 fi 46935 46936 # Assume the C compiler is the assembler 46937 BUILD_AS="$BUILD_CC -c" 46938 # Just like for the target compiler, use the compiler as linker 46939 BUILD_LD="$BUILD_CC" 46940 BUILD_LDCXX="$BUILD_CXX" 46941 46942 PATH="$OLDPATH" 46943 46944 46945 COMPILER=$BUILD_CC 46946 COMPILER_NAME=BuildC 46947 46948 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 46949 # cc -V output typically looks like 46950 # cc: Sun C 5.12 Linux_i386 2011/11/16 46951 COMPILER_VERSION_OUTPUT=`$COMPILER -V 2>&1` 46952 # Check that this is likely to be the Solaris Studio cc. 46953 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "^.*: Sun $COMPILER_NAME" > /dev/null 46954 if test $? -ne 0; then 46955 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 46956 { $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 46957 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 46958 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&5 46959 $as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 46960 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 46961 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 46962 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 46963 fi 46964 # Remove usage instructions (if present), and 46965 # collapse compiler output into a single line 46966 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 46967 $SED -e 's/ *[Uu]sage:.*//'` 46968 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 46969 $SED -e "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/"` 46970 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 46971 # xlc -qversion output typically looks like 46972 # IBM XL C/C++ for AIX, V11.1 (5724-X13) 46973 # Version: 11.01.0000.0015 46974 COMPILER_VERSION_OUTPUT=`$COMPILER -qversion 2>&1` 46975 # Check that this is likely to be the IBM XL C compiler. 46976 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "IBM XL C" > /dev/null 46977 if test $? -ne 0; then 46978 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 46979 { $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 46980 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 46981 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&5 46982 $as_echo "$as_me: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 46983 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 46984 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 46985 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 46986 fi 46987 # Collapse compiler output into a single line 46988 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 46989 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 46990 $SED -e 's/^.*, V\([1-9][0-9.]*\).*$/\1/'` 46991 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 46992 # There is no specific version flag, but all output starts with a version string. 46993 # First line typically looks something like: 46994 # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86 46995 COMPILER_VERSION_OUTPUT=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'` 46996 # Check that this is likely to be Microsoft CL.EXE. 46997 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Microsoft.*Compiler" > /dev/null 46998 if test $? -ne 0; then 46999 { $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 47000 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47001 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&5 47002 $as_echo "$as_me: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 47003 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47004 fi 47005 # Collapse compiler output into a single line 47006 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 47007 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47008 $SED -e 's/^.*ersion.\([1-9][0-9.]*\) .*$/\1/'` 47009 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 47010 # gcc --version output typically looks like 47011 # gcc (Ubuntu/Linaro 4.8.1-10ubuntu9) 4.8.1 47012 # Copyright (C) 2013 Free Software Foundation, Inc. 47013 # This is free software; see the source for copying conditions. There is NO 47014 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 47015 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 47016 # Check that this is likely to be GCC. 47017 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Free Software Foundation" > /dev/null 47018 if test $? -ne 0; then 47019 { $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 47020 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47021 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION\"" >&5 47022 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION\"" >&6;} 47023 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47024 fi 47025 # Remove Copyright and legalese from version string, and 47026 # collapse into a single line 47027 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47028 $SED -e 's/ *Copyright .*//'` 47029 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47030 $SED -e 's/^.* \([1-9]\.[0-9.]*\)[^0-9.].*$/\1/'` 47031 elif test "x$TOOLCHAIN_TYPE" = xclang; then 47032 # clang --version output typically looks like 47033 # Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn) 47034 # clang version 3.3 (tags/RELEASE_33/final) 47035 # or 47036 # Debian clang version 3.2-7ubuntu1 (tags/RELEASE_32/final) (based on LLVM 3.2) 47037 # Target: x86_64-pc-linux-gnu 47038 # Thread model: posix 47039 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 47040 # Check that this is likely to be clang 47041 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "clang" > /dev/null 47042 if test $? -ne 0; then 47043 { $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 47044 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47045 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&5 47046 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 47047 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47048 fi 47049 # Collapse compiler output into a single line 47050 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 47051 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47052 $SED -e 's/^.* version \([1-9][0-9.]*\).*$/\1/'` 47053 else 47054 as_fn_error $? "Unknown toolchain type $TOOLCHAIN_TYPE." "$LINENO" 5 47055 fi 47056 # This sets CC_VERSION_NUMBER or CXX_VERSION_NUMBER. (This comment is a grep marker) 47057 BUILD_CC_VERSION_NUMBER="$COMPILER_VERSION_NUMBER" 47058 # This sets CC_VERSION_STRING or CXX_VERSION_STRING. (This comment is a grep marker) 47059 BUILD_CC_VERSION_STRING="$COMPILER_VERSION_STRING" 47060 47061 { $as_echo "$as_me:${as_lineno-$LINENO}: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&5 47062 $as_echo "$as_me: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&6;} 47063 47064 47065 COMPILER=$BUILD_CXX 47066 COMPILER_NAME=BuildC++ 47067 47068 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 47069 # cc -V output typically looks like 47070 # cc: Sun C 5.12 Linux_i386 2011/11/16 47071 COMPILER_VERSION_OUTPUT=`$COMPILER -V 2>&1` 47072 # Check that this is likely to be the Solaris Studio cc. 47073 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "^.*: Sun $COMPILER_NAME" > /dev/null 47074 if test $? -ne 0; then 47075 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 47076 { $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 47077 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47078 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&5 47079 $as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 47080 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 47081 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 47082 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47083 fi 47084 # Remove usage instructions (if present), and 47085 # collapse compiler output into a single line 47086 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47087 $SED -e 's/ *[Uu]sage:.*//'` 47088 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47089 $SED -e "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/"` 47090 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 47091 # xlc -qversion output typically looks like 47092 # IBM XL C/C++ for AIX, V11.1 (5724-X13) 47093 # Version: 11.01.0000.0015 47094 COMPILER_VERSION_OUTPUT=`$COMPILER -qversion 2>&1` 47095 # Check that this is likely to be the IBM XL C compiler. 47096 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "IBM XL C" > /dev/null 47097 if test $? -ne 0; then 47098 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 47099 { $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 47100 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47101 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&5 47102 $as_echo "$as_me: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 47103 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 47104 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 47105 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47106 fi 47107 # Collapse compiler output into a single line 47108 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 47109 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47110 $SED -e 's/^.*, V\([1-9][0-9.]*\).*$/\1/'` 47111 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 47112 # There is no specific version flag, but all output starts with a version string. 47113 # First line typically looks something like: 47114 # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86 47115 COMPILER_VERSION_OUTPUT=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'` 47116 # Check that this is likely to be Microsoft CL.EXE. 47117 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Microsoft.*Compiler" > /dev/null 47118 if test $? -ne 0; then 47119 { $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 47120 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47121 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&5 47122 $as_echo "$as_me: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 47123 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47124 fi 47125 # Collapse compiler output into a single line 47126 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 47127 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47128 $SED -e 's/^.*ersion.\([1-9][0-9.]*\) .*$/\1/'` 47129 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 47130 # gcc --version output typically looks like 47131 # gcc (Ubuntu/Linaro 4.8.1-10ubuntu9) 4.8.1 47132 # Copyright (C) 2013 Free Software Foundation, Inc. 47133 # This is free software; see the source for copying conditions. There is NO 47134 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 47135 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 47136 # Check that this is likely to be GCC. 47137 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Free Software Foundation" > /dev/null 47138 if test $? -ne 0; then 47139 { $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 47140 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47141 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION\"" >&5 47142 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION\"" >&6;} 47143 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47144 fi 47145 # Remove Copyright and legalese from version string, and 47146 # collapse into a single line 47147 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47148 $SED -e 's/ *Copyright .*//'` 47149 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47150 $SED -e 's/^.* \([1-9]\.[0-9.]*\)[^0-9.].*$/\1/'` 47151 elif test "x$TOOLCHAIN_TYPE" = xclang; then 47152 # clang --version output typically looks like 47153 # Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn) 47154 # clang version 3.3 (tags/RELEASE_33/final) 47155 # or 47156 # Debian clang version 3.2-7ubuntu1 (tags/RELEASE_32/final) (based on LLVM 3.2) 47157 # Target: x86_64-pc-linux-gnu 47158 # Thread model: posix 47159 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 47160 # Check that this is likely to be clang 47161 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "clang" > /dev/null 47162 if test $? -ne 0; then 47163 { $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 47164 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 47165 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&5 47166 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 47167 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 47168 fi 47169 # Collapse compiler output into a single line 47170 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 47171 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 47172 $SED -e 's/^.* version \([1-9][0-9.]*\).*$/\1/'` 47173 else 47174 as_fn_error $? "Unknown toolchain type $TOOLCHAIN_TYPE." "$LINENO" 5 47175 fi 47176 # This sets CC_VERSION_NUMBER or CXX_VERSION_NUMBER. (This comment is a grep marker) 47177 BUILD_CXX_VERSION_NUMBER="$COMPILER_VERSION_NUMBER" 47178 # This sets CC_VERSION_STRING or CXX_VERSION_STRING. (This comment is a grep marker) 47179 BUILD_CXX_VERSION_STRING="$COMPILER_VERSION_STRING" 47180 47181 { $as_echo "$as_me:${as_lineno-$LINENO}: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&5 47182 $as_echo "$as_me: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&6;} 47183 47184 47185 if test "x$BUILD_CC_VERSION_NUMBER" != "x$BUILD_CXX_VERSION_NUMBER"; then 47186 { $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 47187 $as_echo "$as_me: WARNING: C and C++ compiler have different version numbers, $BUILD_CC_VERSION_NUMBER vs $BUILD_CXX_VERSION_NUMBER." >&2;} 47188 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This typically indicates a broken setup, and is not supported" >&5 47189 $as_echo "$as_me: WARNING: This typically indicates a broken setup, and is not supported" >&2;} 47190 fi 47191 47192 # We only check CC_VERSION_NUMBER since we assume CXX_VERSION_NUMBER is equal. 47193 if [[ "[$]BUILD_CC_VERSION_NUMBER" =~ (.*\.){3} ]] ; then 47194 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: C compiler version number has more than three parts (X.Y.Z): $BUILD_CC_VERSION_NUMBER. Comparisons might be wrong." >&5 47195 $as_echo "$as_me: WARNING: C compiler version number has more than three parts (X.Y.Z): $BUILD_CC_VERSION_NUMBER. Comparisons might be wrong." >&2;} 47196 fi 47197 47198 if [[ "[$]BUILD_CC_VERSION_NUMBER" =~ [0-9]{6} ]] ; then 47199 { $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 47200 $as_echo "$as_me: WARNING: C compiler version number has a part larger than 99999: $BUILD_CC_VERSION_NUMBER. Comparisons might be wrong." >&2;} 47201 fi 47202 47203 OPENJDK_BUILD_COMPARABLE_ACTUAL_VERSION=`$AWK -F. '{ printf("%05d%05d%05d\n", $1, $2, $3) }' <<< "$BUILD_CC_VERSION_NUMBER"` 47204 47205 else 47206 # If we are not cross compiling, use the normal target compilers for 47207 # building the build platform executables. 47208 BUILD_CC="$CC" 47209 BUILD_CXX="$CXX" 47210 BUILD_LD="$LD" 47211 BUILD_LDCXX="$LDCXX" 47212 BUILD_NM="$NM" 47213 BUILD_AS="$AS" 47214 BUILD_OBJCOPY="$OBJCOPY" 47215 BUILD_STRIP="$STRIP" 47216 BUILD_SYSROOT_CFLAGS="$SYSROOT_CFLAGS" 47217 BUILD_SYSROOT_LDFLAGS="$SYSROOT_LDFLAGS" 47218 BUILD_AR="$AR" 47219 47220 47221 if test "x$CC_VERSION_NUMBER" != "x$CXX_VERSION_NUMBER"; then 47222 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: C and C++ compiler have different version numbers, $CC_VERSION_NUMBER vs $CXX_VERSION_NUMBER." >&5 47223 $as_echo "$as_me: WARNING: C and C++ compiler have different version numbers, $CC_VERSION_NUMBER vs $CXX_VERSION_NUMBER." >&2;} 47224 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This typically indicates a broken setup, and is not supported" >&5 47225 $as_echo "$as_me: WARNING: This typically indicates a broken setup, and is not supported" >&2;} 47226 fi 47227 47228 # We only check CC_VERSION_NUMBER since we assume CXX_VERSION_NUMBER is equal. 47229 if [[ "[$]CC_VERSION_NUMBER" =~ (.*\.){3} ]] ; then 47230 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: C compiler version number has more than three parts (X.Y.Z): $CC_VERSION_NUMBER. Comparisons might be wrong." >&5 47231 $as_echo "$as_me: WARNING: C compiler version number has more than three parts (X.Y.Z): $CC_VERSION_NUMBER. Comparisons might be wrong." >&2;} 47232 fi 47233 47234 if [[ "[$]CC_VERSION_NUMBER" =~ [0-9]{6} ]] ; then 47235 { $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 47236 $as_echo "$as_me: WARNING: C compiler version number has a part larger than 99999: $CC_VERSION_NUMBER. Comparisons might be wrong." >&2;} 47237 fi 47238 47239 OPENJDK_BUILD_COMPARABLE_ACTUAL_VERSION=`$AWK -F. '{ printf("%05d%05d%05d\n", $1, $2, $3) }' <<< "$CC_VERSION_NUMBER"` 47240 47241 fi 47242 47243 47244 47245 47246 47247 47248 47249 47250 47251 47252 47253 47254 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 47255 # For hotspot, we need these in Windows mixed path, 47256 # so rewrite them all. Need added .exe suffix. 47257 HOTSPOT_CXX="$CXX.exe" 47258 HOTSPOT_LD="$LD.exe" 47259 HOTSPOT_MT="$MT.exe" 47260 HOTSPOT_RC="$RC.exe" 47261 47262 unix_path="$HOTSPOT_CXX" 47263 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47264 windows_path=`$CYGPATH -m "$unix_path"` 47265 HOTSPOT_CXX="$windows_path" 47266 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47267 windows_path=`cmd //c echo $unix_path` 47268 HOTSPOT_CXX="$windows_path" 47269 fi 47270 47271 47272 unix_path="$HOTSPOT_LD" 47273 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47274 windows_path=`$CYGPATH -m "$unix_path"` 47275 HOTSPOT_LD="$windows_path" 47276 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47277 windows_path=`cmd //c echo $unix_path` 47278 HOTSPOT_LD="$windows_path" 47279 fi 47280 47281 47282 unix_path="$HOTSPOT_MT" 47283 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47284 windows_path=`$CYGPATH -m "$unix_path"` 47285 HOTSPOT_MT="$windows_path" 47286 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47287 windows_path=`cmd //c echo $unix_path` 47288 HOTSPOT_MT="$windows_path" 47289 fi 47290 47291 47292 unix_path="$HOTSPOT_RC" 47293 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47294 windows_path=`$CYGPATH -m "$unix_path"` 47295 HOTSPOT_RC="$windows_path" 47296 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47297 windows_path=`cmd //c echo $unix_path` 47298 HOTSPOT_RC="$windows_path" 47299 fi 47300 47301 47302 47303 else 47304 HOTSPOT_CXX="$CXX" 47305 HOTSPOT_LD="$LD" 47306 fi 47307 47308 47309 47310 if test "x$TOOLCHAIN_TYPE" = xclang; then 47311 USE_CLANG=true 47312 fi 47313 47314 47315 47316 47317 47318 # The package path is used only on macosx? 47319 # FIXME: clean this up, and/or move it elsewhere. 47320 PACKAGE_PATH=/opt/local 47321 47322 47323 # Check for extra potential brokenness. 47324 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 47325 # On Windows, double-check that we got the right compiler. 47326 CC_VERSION_OUTPUT=`$CC 2>&1 | $HEAD -n 1 | $TR -d '\r'` 47327 COMPILER_CPU_TEST=`$ECHO $CC_VERSION_OUTPUT | $SED -n "s/^.* \(.*\)$/\1/p"` 47328 if test "x$OPENJDK_TARGET_CPU" = "xx86"; then 47329 if test "x$COMPILER_CPU_TEST" != "x80x86" -a "x$COMPILER_CPU_TEST" != "xx86"; then 47330 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 47331 fi 47332 elif test "x$OPENJDK_TARGET_CPU" = "xx86_64"; then 47333 if test "x$COMPILER_CPU_TEST" != "xx64"; then 47334 as_fn_error $? "Target CPU mismatch. We are building for $OPENJDK_TARGET_CPU but CL is for \"$COMPILER_CPU_TEST\"; expected \"x64\"." "$LINENO" 5 47335 fi 47336 fi 47337 fi 47338 47339 if test "x$TOOLCHAIN_TYPE" = xgcc; then 47340 # If this is a --hash-style=gnu system, use --hash-style=both, why? 47341 HAS_GNU_HASH=`$CC -dumpspecs 2>/dev/null | $GREP 'hash-style=gnu'` 47342 # This is later checked when setting flags. 47343 47344 # "-Og" suppported for GCC 4.8 and later 47345 CFLAG_OPTIMIZE_DEBUG_FLAG="-Og" 47346 47347 47348 47349 47350 47351 47352 47353 47354 47355 47356 47357 47358 47359 47360 47361 47362 47363 47364 47365 47366 47367 47368 47369 47370 47371 47372 47373 47374 47375 47376 47377 47378 47379 47380 47381 47382 47383 47384 47385 47386 47387 47388 47389 47390 47391 47392 47393 # Execute function body 47394 47395 47396 47397 47398 47399 47400 47401 47402 47403 47404 47405 47406 47407 47408 47409 47410 47411 47412 47413 47414 47415 47416 47417 47418 47419 47420 47421 47422 47423 47424 47425 47426 47427 47428 47429 47430 47431 47432 47433 47434 47435 47436 47437 47438 47439 47440 47441 47442 # Execute function body 47443 47444 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler supports \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"" >&5 47445 $as_echo_n "checking if the C compiler supports \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"... " >&6; } 47446 supports=yes 47447 47448 saved_cflags="$CFLAGS" 47449 CFLAGS="$CFLAGS $CFLAG_OPTIMIZE_DEBUG_FLAG" 47450 ac_ext=c 47451 ac_cpp='$CPP $CPPFLAGS' 47452 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47453 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47454 ac_compiler_gnu=$ac_cv_c_compiler_gnu 47455 47456 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 47457 /* end confdefs.h. */ 47458 int i; 47459 _ACEOF 47460 if ac_fn_c_try_compile "$LINENO"; then : 47461 47462 else 47463 supports=no 47464 fi 47465 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 47466 ac_ext=cpp 47467 ac_cpp='$CXXCPP $CPPFLAGS' 47468 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47469 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47470 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 47471 47472 CFLAGS="$saved_cflags" 47473 47474 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 47475 $as_echo "$supports" >&6; } 47476 if test "x$supports" = "xyes" ; then 47477 : 47478 C_COMP_SUPPORTS="yes" 47479 else 47480 : 47481 C_COMP_SUPPORTS="no" 47482 fi 47483 47484 47485 47486 47487 47488 47489 47490 47491 47492 47493 47494 47495 47496 47497 47498 47499 47500 47501 47502 47503 47504 47505 47506 47507 47508 47509 47510 47511 47512 47513 47514 47515 47516 47517 47518 47519 47520 47521 47522 47523 47524 47525 47526 47527 47528 47529 47530 47531 47532 47533 47534 47535 47536 47537 47538 47539 47540 47541 47542 # Execute function body 47543 47544 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"" >&5 47545 $as_echo_n "checking if the C++ compiler supports \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"... " >&6; } 47546 supports=yes 47547 47548 saved_cxxflags="$CXXFLAGS" 47549 CXXFLAGS="$CXXFLAG $CFLAG_OPTIMIZE_DEBUG_FLAG" 47550 ac_ext=cpp 47551 ac_cpp='$CXXCPP $CPPFLAGS' 47552 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47553 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47554 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 47555 47556 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 47557 /* end confdefs.h. */ 47558 int i; 47559 _ACEOF 47560 if ac_fn_cxx_try_compile "$LINENO"; then : 47561 47562 else 47563 supports=no 47564 fi 47565 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 47566 ac_ext=cpp 47567 ac_cpp='$CXXCPP $CPPFLAGS' 47568 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47569 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47570 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 47571 47572 CXXFLAGS="$saved_cxxflags" 47573 47574 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 47575 $as_echo "$supports" >&6; } 47576 if test "x$supports" = "xyes" ; then 47577 : 47578 CXX_COMP_SUPPORTS="yes" 47579 else 47580 : 47581 CXX_COMP_SUPPORTS="no" 47582 fi 47583 47584 47585 47586 47587 47588 47589 47590 47591 47592 47593 47594 47595 47596 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"" >&5 47597 $as_echo_n "checking if both compilers support \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"... " >&6; } 47598 supports=no 47599 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 47600 47601 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 47602 $as_echo "$supports" >&6; } 47603 if test "x$supports" = "xyes" ; then 47604 : 47605 HAS_CFLAG_OPTIMIZE_DEBUG=true 47606 else 47607 : 47608 HAS_CFLAG_OPTIMIZE_DEBUG=false 47609 fi 47610 47611 47612 47613 47614 47615 47616 47617 # "-z relro" supported in GNU binutils 2.17 and later 47618 LINKER_RELRO_FLAG="-Wl,-z,relro" 47619 47620 47621 47622 47623 47624 47625 47626 47627 47628 47629 47630 47631 47632 47633 47634 47635 47636 47637 47638 47639 47640 47641 47642 47643 47644 47645 47646 47647 47648 47649 47650 47651 47652 47653 47654 47655 47656 47657 47658 47659 47660 47661 47662 47663 47664 47665 47666 # Execute function body 47667 47668 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if linker supports \"$LINKER_RELRO_FLAG\"" >&5 47669 $as_echo_n "checking if linker supports \"$LINKER_RELRO_FLAG\"... " >&6; } 47670 supports=yes 47671 47672 saved_ldflags="$LDFLAGS" 47673 LDFLAGS="$LDFLAGS $LINKER_RELRO_FLAG" 47674 ac_ext=c 47675 ac_cpp='$CPP $CPPFLAGS' 47676 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47677 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47678 ac_compiler_gnu=$ac_cv_c_compiler_gnu 47679 47680 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 47681 /* end confdefs.h. */ 47682 47683 int 47684 main () 47685 { 47686 47687 ; 47688 return 0; 47689 } 47690 _ACEOF 47691 if ac_fn_c_try_link "$LINENO"; then : 47692 47693 else 47694 supports=no 47695 fi 47696 rm -f core conftest.err conftest.$ac_objext \ 47697 conftest$ac_exeext conftest.$ac_ext 47698 ac_ext=cpp 47699 ac_cpp='$CXXCPP $CPPFLAGS' 47700 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47701 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47702 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 47703 47704 LDFLAGS="$saved_ldflags" 47705 47706 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 47707 $as_echo "$supports" >&6; } 47708 if test "x$supports" = "xyes" ; then 47709 : 47710 HAS_LINKER_RELRO=true 47711 else 47712 : 47713 HAS_LINKER_RELRO=false 47714 fi 47715 47716 47717 47718 47719 47720 47721 47722 47723 47724 47725 47726 47727 47728 # "-z now" supported in GNU binutils 2.11 and later 47729 LINKER_NOW_FLAG="-Wl,-z,now" 47730 47731 47732 47733 47734 47735 47736 47737 47738 47739 47740 47741 47742 47743 47744 47745 47746 47747 47748 47749 47750 47751 47752 47753 47754 47755 47756 47757 47758 47759 47760 47761 47762 47763 47764 47765 47766 47767 47768 47769 47770 47771 47772 47773 47774 47775 47776 47777 # Execute function body 47778 47779 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if linker supports \"$LINKER_NOW_FLAG\"" >&5 47780 $as_echo_n "checking if linker supports \"$LINKER_NOW_FLAG\"... " >&6; } 47781 supports=yes 47782 47783 saved_ldflags="$LDFLAGS" 47784 LDFLAGS="$LDFLAGS $LINKER_NOW_FLAG" 47785 ac_ext=c 47786 ac_cpp='$CPP $CPPFLAGS' 47787 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47788 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47789 ac_compiler_gnu=$ac_cv_c_compiler_gnu 47790 47791 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 47792 /* end confdefs.h. */ 47793 47794 int 47795 main () 47796 { 47797 47798 ; 47799 return 0; 47800 } 47801 _ACEOF 47802 if ac_fn_c_try_link "$LINENO"; then : 47803 47804 else 47805 supports=no 47806 fi 47807 rm -f core conftest.err conftest.$ac_objext \ 47808 conftest$ac_exeext conftest.$ac_ext 47809 ac_ext=cpp 47810 ac_cpp='$CXXCPP $CPPFLAGS' 47811 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47812 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47813 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 47814 47815 LDFLAGS="$saved_ldflags" 47816 47817 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 47818 $as_echo "$supports" >&6; } 47819 if test "x$supports" = "xyes" ; then 47820 : 47821 HAS_LINKER_NOW=true 47822 else 47823 : 47824 HAS_LINKER_NOW=false 47825 fi 47826 47827 47828 47829 47830 47831 47832 47833 47834 47835 47836 47837 47838 fi 47839 47840 # Check for broken SuSE 'ld' for which 'Only anonymous version tag is allowed 47841 # in executable.' 47842 USING_BROKEN_SUSE_LD=no 47843 if test "x$OPENJDK_TARGET_OS" = xlinux && test "x$TOOLCHAIN_TYPE" = xgcc; then 47844 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken SuSE 'ld' which only understands anonymous version tags in executables" >&5 47845 $as_echo_n "checking for broken SuSE 'ld' which only understands anonymous version tags in executables... " >&6; } 47846 $ECHO "SUNWprivate_1.1 { local: *; };" > version-script.map 47847 $ECHO "int main() { }" > main.c 47848 if $CXX -Wl,-version-script=version-script.map main.c 2>&5 >&5; then 47849 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 47850 $as_echo "no" >&6; } 47851 USING_BROKEN_SUSE_LD=no 47852 else 47853 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 47854 $as_echo "yes" >&6; } 47855 USING_BROKEN_SUSE_LD=yes 47856 fi 47857 $RM version-script.map main.c a.out 47858 fi 47859 47860 47861 # Setup hotspot lecagy names for toolchains 47862 HOTSPOT_TOOLCHAIN_TYPE=$TOOLCHAIN_TYPE 47863 if test "x$TOOLCHAIN_TYPE" = xclang; then 47864 HOTSPOT_TOOLCHAIN_TYPE=gcc 47865 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 47866 HOTSPOT_TOOLCHAIN_TYPE=sparcWorks 47867 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 47868 HOTSPOT_TOOLCHAIN_TYPE=visCPP 47869 fi 47870 47871 47872 47873 # Setup the JTReg Regression Test Harness. 47874 47875 47876 # Check whether --with-jtreg was given. 47877 if test "${with_jtreg+set}" = set; then : 47878 withval=$with_jtreg; 47879 else 47880 with_jtreg=no 47881 fi 47882 47883 47884 if test "x$with_jtreg" = xno; then 47885 # jtreg disabled 47886 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jtreg" >&5 47887 $as_echo_n "checking for jtreg... " >&6; } 47888 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 47889 $as_echo "no" >&6; } 47890 else 47891 if test "x$with_jtreg" != xyes; then 47892 # with path specified. 47893 JT_HOME="$with_jtreg" 47894 fi 47895 47896 if test "x$JT_HOME" != x; then 47897 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jtreg" >&5 47898 $as_echo_n "checking for jtreg... " >&6; } 47899 47900 # use JT_HOME enviroment var. 47901 47902 # Only process if variable expands to non-empty 47903 47904 if test "x$JT_HOME" != x; then 47905 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47906 47907 # Input might be given as Windows format, start by converting to 47908 # unix format. 47909 path="$JT_HOME" 47910 new_path=`$CYGPATH -u "$path"` 47911 47912 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 47913 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 47914 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 47915 # "foo.exe" is OK but "foo" is an error. 47916 # 47917 # This test is therefore slightly more accurate than "test -f" to check for file precense. 47918 # It is also a way to make sure we got the proper file name for the real test later on. 47919 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 47920 if test "x$test_shortpath" = x; then 47921 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JT_HOME, which resolves as \"$path\", is invalid." >&5 47922 $as_echo "$as_me: The path of JT_HOME, which resolves as \"$path\", is invalid." >&6;} 47923 as_fn_error $? "Cannot locate the the path of JT_HOME" "$LINENO" 5 47924 fi 47925 47926 # Call helper function which possibly converts this using DOS-style short mode. 47927 # If so, the updated path is stored in $new_path. 47928 47929 input_path="$new_path" 47930 # Check if we need to convert this using DOS-style short mode. If the path 47931 # contains just simple characters, use it. Otherwise (spaces, weird characters), 47932 # take no chances and rewrite it. 47933 # Note: m4 eats our [], so we need to use [ and ] instead. 47934 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 47935 if test "x$has_forbidden_chars" != x; then 47936 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 47937 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 47938 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 47939 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 47940 # Going to short mode and back again did indeed matter. Since short mode is 47941 # case insensitive, let's make it lowercase to improve readability. 47942 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 47943 # Now convert it back to Unix-style (cygpath) 47944 input_path=`$CYGPATH -u "$shortmode_path"` 47945 new_path="$input_path" 47946 fi 47947 fi 47948 47949 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 47950 if test "x$test_cygdrive_prefix" = x; then 47951 # As a simple fix, exclude /usr/bin since it's not a real path. 47952 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 47953 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 47954 # a path prefixed by /cygdrive for fixpath to work. 47955 new_path="$CYGWIN_ROOT_PATH$input_path" 47956 fi 47957 fi 47958 47959 47960 if test "x$path" != "x$new_path"; then 47961 JT_HOME="$new_path" 47962 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JT_HOME to \"$new_path\"" >&5 47963 $as_echo "$as_me: Rewriting JT_HOME to \"$new_path\"" >&6;} 47964 fi 47965 47966 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47967 47968 path="$JT_HOME" 47969 has_colon=`$ECHO $path | $GREP ^.:` 47970 new_path="$path" 47971 if test "x$has_colon" = x; then 47972 # Not in mixed or Windows style, start by that. 47973 new_path=`cmd //c echo $path` 47974 fi 47975 47976 47977 input_path="$new_path" 47978 # Check if we need to convert this using DOS-style short mode. If the path 47979 # contains just simple characters, use it. Otherwise (spaces, weird characters), 47980 # take no chances and rewrite it. 47981 # Note: m4 eats our [], so we need to use [ and ] instead. 47982 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 47983 if test "x$has_forbidden_chars" != x; then 47984 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 47985 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 47986 fi 47987 47988 47989 windows_path="$new_path" 47990 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47991 unix_path=`$CYGPATH -u "$windows_path"` 47992 new_path="$unix_path" 47993 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47994 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 47995 new_path="$unix_path" 47996 fi 47997 47998 if test "x$path" != "x$new_path"; then 47999 JT_HOME="$new_path" 48000 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JT_HOME to \"$new_path\"" >&5 48001 $as_echo "$as_me: Rewriting JT_HOME to \"$new_path\"" >&6;} 48002 fi 48003 48004 # Save the first 10 bytes of this path to the storage, so fixpath can work. 48005 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 48006 48007 else 48008 # We're on a unix platform. Hooray! :) 48009 path="$JT_HOME" 48010 has_space=`$ECHO "$path" | $GREP " "` 48011 if test "x$has_space" != x; then 48012 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JT_HOME, which resolves as \"$path\", is invalid." >&5 48013 $as_echo "$as_me: The path of JT_HOME, which resolves as \"$path\", is invalid." >&6;} 48014 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 48015 fi 48016 48017 # Use eval to expand a potential ~ 48018 eval path="$path" 48019 if test ! -f "$path" && test ! -d "$path"; then 48020 as_fn_error $? "The path of JT_HOME, which resolves as \"$path\", is not found." "$LINENO" 5 48021 fi 48022 48023 if test -d "$path"; then 48024 JT_HOME="`cd "$path"; $THEPWDCMD -L`" 48025 else 48026 dir="`$DIRNAME "$path"`" 48027 base="`$BASENAME "$path"`" 48028 JT_HOME="`cd "$dir"; $THEPWDCMD -L`/$base" 48029 fi 48030 fi 48031 fi 48032 48033 48034 # jtreg win32 script works for everybody 48035 JTREGEXE="$JT_HOME/bin/jtreg" 48036 48037 if test ! -f "$JTREGEXE"; then 48038 as_fn_error $? "JTReg executable does not exist: $JTREGEXE" "$LINENO" 5 48039 fi 48040 48041 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5 48042 $as_echo "$JTREGEXE" >&6; } 48043 else 48044 # try to find jtreg on path 48045 48046 48047 48048 # Publish this variable in the help. 48049 48050 48051 if [ -z "${JTREGEXE+x}" ]; then 48052 # The variable is not set by user, try to locate tool using the code snippet 48053 for ac_prog in jtreg 48054 do 48055 # Extract the first word of "$ac_prog", so it can be a program name with args. 48056 set dummy $ac_prog; ac_word=$2 48057 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 48058 $as_echo_n "checking for $ac_word... " >&6; } 48059 if ${ac_cv_path_JTREGEXE+:} false; then : 48060 $as_echo_n "(cached) " >&6 48061 else 48062 case $JTREGEXE in 48063 [\\/]* | ?:[\\/]*) 48064 ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path. 48065 ;; 48066 *) 48067 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 48068 for as_dir in $PATH 48069 do 48070 IFS=$as_save_IFS 48071 test -z "$as_dir" && as_dir=. 48072 for ac_exec_ext in '' $ac_executable_extensions; do 48073 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 48074 ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext" 48075 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 48076 break 2 48077 fi 48078 done 48079 done 48080 IFS=$as_save_IFS 48081 48082 ;; 48083 esac 48084 fi 48085 JTREGEXE=$ac_cv_path_JTREGEXE 48086 if test -n "$JTREGEXE"; then 48087 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5 48088 $as_echo "$JTREGEXE" >&6; } 48089 else 48090 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 48091 $as_echo "no" >&6; } 48092 fi 48093 48094 48095 test -n "$JTREGEXE" && break 48096 done 48097 48098 else 48099 # The variable is set, but is it from the command line or the environment? 48100 48101 # Try to remove the string !JTREGEXE! from our list. 48102 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JTREGEXE!/} 48103 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 48104 # If it failed, the variable was not from the command line. Ignore it, 48105 # but warn the user (except for BASH, which is always set by the calling BASH). 48106 if test "xJTREGEXE" != xBASH; then 48107 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JTREGEXE from the environment. Use command line variables instead." >&5 48108 $as_echo "$as_me: WARNING: Ignoring value of JTREGEXE from the environment. Use command line variables instead." >&2;} 48109 fi 48110 # Try to locate tool using the code snippet 48111 for ac_prog in jtreg 48112 do 48113 # Extract the first word of "$ac_prog", so it can be a program name with args. 48114 set dummy $ac_prog; ac_word=$2 48115 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 48116 $as_echo_n "checking for $ac_word... " >&6; } 48117 if ${ac_cv_path_JTREGEXE+:} false; then : 48118 $as_echo_n "(cached) " >&6 48119 else 48120 case $JTREGEXE in 48121 [\\/]* | ?:[\\/]*) 48122 ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path. 48123 ;; 48124 *) 48125 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 48126 for as_dir in $PATH 48127 do 48128 IFS=$as_save_IFS 48129 test -z "$as_dir" && as_dir=. 48130 for ac_exec_ext in '' $ac_executable_extensions; do 48131 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 48132 ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext" 48133 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 48134 break 2 48135 fi 48136 done 48137 done 48138 IFS=$as_save_IFS 48139 48140 ;; 48141 esac 48142 fi 48143 JTREGEXE=$ac_cv_path_JTREGEXE 48144 if test -n "$JTREGEXE"; then 48145 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5 48146 $as_echo "$JTREGEXE" >&6; } 48147 else 48148 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 48149 $as_echo "no" >&6; } 48150 fi 48151 48152 48153 test -n "$JTREGEXE" && break 48154 done 48155 48156 else 48157 # If it succeeded, then it was overridden by the user. We will use it 48158 # for the tool. 48159 48160 # First remove it from the list of overridden variables, so we can test 48161 # for unknown variables in the end. 48162 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 48163 48164 # Check if we try to supply an empty value 48165 if test "x$JTREGEXE" = x; then 48166 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JTREGEXE= (no value)" >&5 48167 $as_echo "$as_me: Setting user supplied tool JTREGEXE= (no value)" >&6;} 48168 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JTREGEXE" >&5 48169 $as_echo_n "checking for JTREGEXE... " >&6; } 48170 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 48171 $as_echo "disabled" >&6; } 48172 else 48173 # Check if the provided tool contains a complete path. 48174 tool_specified="$JTREGEXE" 48175 tool_basename="${tool_specified##*/}" 48176 if test "x$tool_basename" = "x$tool_specified"; then 48177 # A command without a complete path is provided, search $PATH. 48178 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JTREGEXE=$tool_basename" >&5 48179 $as_echo "$as_me: Will search for user supplied tool JTREGEXE=$tool_basename" >&6;} 48180 # Extract the first word of "$tool_basename", so it can be a program name with args. 48181 set dummy $tool_basename; ac_word=$2 48182 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 48183 $as_echo_n "checking for $ac_word... " >&6; } 48184 if ${ac_cv_path_JTREGEXE+:} false; then : 48185 $as_echo_n "(cached) " >&6 48186 else 48187 case $JTREGEXE in 48188 [\\/]* | ?:[\\/]*) 48189 ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path. 48190 ;; 48191 *) 48192 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 48193 for as_dir in $PATH 48194 do 48195 IFS=$as_save_IFS 48196 test -z "$as_dir" && as_dir=. 48197 for ac_exec_ext in '' $ac_executable_extensions; do 48198 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 48199 ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext" 48200 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 48201 break 2 48202 fi 48203 done 48204 done 48205 IFS=$as_save_IFS 48206 48207 ;; 48208 esac 48209 fi 48210 JTREGEXE=$ac_cv_path_JTREGEXE 48211 if test -n "$JTREGEXE"; then 48212 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5 48213 $as_echo "$JTREGEXE" >&6; } 48214 else 48215 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 48216 $as_echo "no" >&6; } 48217 fi 48218 48219 48220 if test "x$JTREGEXE" = x; then 48221 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 48222 fi 48223 else 48224 # Otherwise we believe it is a complete path. Use it as it is. 48225 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JTREGEXE=$tool_specified" >&5 48226 $as_echo "$as_me: Will use user supplied tool JTREGEXE=$tool_specified" >&6;} 48227 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JTREGEXE" >&5 48228 $as_echo_n "checking for JTREGEXE... " >&6; } 48229 if test ! -x "$tool_specified"; then 48230 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 48231 $as_echo "not found" >&6; } 48232 as_fn_error $? "User supplied tool JTREGEXE=$tool_specified does not exist or is not executable" "$LINENO" 5 48233 fi 48234 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 48235 $as_echo "$tool_specified" >&6; } 48236 fi 48237 fi 48238 fi 48239 48240 fi 48241 48242 48243 48244 if test "x$JTREGEXE" = x; then 48245 as_fn_error $? "Could not find required tool for JTREGEXE" "$LINENO" 5 48246 fi 48247 48248 48249 JT_HOME="`$DIRNAME $JTREGEXE`" 48250 fi 48251 fi 48252 48253 48254 48255 48256 48257 48258 # COMPILER_TARGET_BITS_FLAG : option for selecting 32- or 64-bit output 48259 # COMPILER_COMMAND_FILE_FLAG : option for passing a command file to the compiler 48260 # COMPILER_BINDCMD_FILE_FLAG : option for specifying a file which saves the binder 48261 # commands produced by the link step (currently AIX only) 48262 if test "x$TOOLCHAIN_TYPE" = xxlc; then 48263 COMPILER_TARGET_BITS_FLAG="-q" 48264 COMPILER_COMMAND_FILE_FLAG="-f" 48265 COMPILER_BINDCMD_FILE_FLAG="-bloadmap:" 48266 else 48267 COMPILER_TARGET_BITS_FLAG="-m" 48268 COMPILER_COMMAND_FILE_FLAG="@" 48269 COMPILER_BINDCMD_FILE_FLAG="" 48270 48271 # The solstudio linker does not support @-files. 48272 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 48273 COMPILER_COMMAND_FILE_FLAG= 48274 fi 48275 48276 # Check if @file is supported by gcc 48277 if test "x$TOOLCHAIN_TYPE" = xgcc; then 48278 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if @file is supported by gcc" >&5 48279 $as_echo_n "checking if @file is supported by gcc... " >&6; } 48280 # Extra emtpy "" to prevent ECHO from interpreting '--version' as argument 48281 $ECHO "" "--version" > command.file 48282 if $CXX @command.file 2>&5 >&5; then 48283 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 48284 $as_echo "yes" >&6; } 48285 COMPILER_COMMAND_FILE_FLAG="@" 48286 else 48287 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 48288 $as_echo "no" >&6; } 48289 COMPILER_COMMAND_FILE_FLAG= 48290 fi 48291 $RM command.file 48292 fi 48293 fi 48294 48295 48296 48297 48298 # FIXME: figure out if we should select AR flags depending on OS or toolchain. 48299 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 48300 ARFLAGS="-r" 48301 elif test "x$OPENJDK_TARGET_OS" = xaix; then 48302 ARFLAGS="-X64" 48303 elif test "x$OPENJDK_TARGET_OS" = xwindows; then 48304 # lib.exe is used as AR to create static libraries. 48305 ARFLAGS="-nologo -NODEFAULTLIB:MSVCRT" 48306 else 48307 ARFLAGS="" 48308 fi 48309 48310 48311 ## Setup strip. 48312 # FIXME: should this really be per platform, or should it be per toolchain type? 48313 # strip is not provided by clang or solstudio; so guessing platform makes most sense. 48314 # FIXME: we should really only export STRIPFLAGS from here, not POST_STRIP_CMD. 48315 if test "x$OPENJDK_TARGET_OS" = xlinux; then 48316 STRIPFLAGS="-g" 48317 elif test "x$OPENJDK_TARGET_OS" = xsolaris; then 48318 STRIPFLAGS="-x" 48319 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 48320 STRIPFLAGS="-S" 48321 elif test "x$OPENJDK_TARGET_OS" = xaix; then 48322 STRIPFLAGS="-X32_64" 48323 fi 48324 48325 48326 48327 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 48328 CC_OUT_OPTION=-Fo 48329 EXE_OUT_OPTION=-out: 48330 LD_OUT_OPTION=-out: 48331 AR_OUT_OPTION=-out: 48332 else 48333 # The option used to specify the target .o,.a or .so file. 48334 # When compiling, how to specify the to be created object file. 48335 CC_OUT_OPTION='-o$(SPACE)' 48336 # When linking, how to specify the to be created executable. 48337 EXE_OUT_OPTION='-o$(SPACE)' 48338 # When linking, how to specify the to be created dynamically linkable library. 48339 LD_OUT_OPTION='-o$(SPACE)' 48340 # When archiving, how to specify the to be create static archive for object files. 48341 AR_OUT_OPTION='rcs$(SPACE)' 48342 fi 48343 48344 48345 48346 48347 48348 # On Windows, we need to set RC flags. 48349 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 48350 RC_FLAGS="-nologo -l0x409" 48351 JVM_RCFLAGS="-nologo" 48352 if test "x$DEBUG_LEVEL" = xrelease; then 48353 RC_FLAGS="$RC_FLAGS -DNDEBUG" 48354 JVM_RCFLAGS="$JVM_RCFLAGS -DNDEBUG" 48355 fi 48356 48357 # The version variables used to create RC_FLAGS may be overridden 48358 # in a custom configure script, or possibly the command line. 48359 # Let those variables be expanded at make time in spec.gmk. 48360 # The \$ are escaped to the shell, and the $(...) variables 48361 # are evaluated by make. 48362 RC_FLAGS="$RC_FLAGS \ 48363 -D\"JDK_VERSION_STRING=\$(VERSION_STRING)\" \ 48364 -D\"JDK_COMPANY=\$(COMPANY_NAME)\" \ 48365 -D\"JDK_COMPONENT=\$(PRODUCT_NAME) \$(JDK_RC_PLATFORM_NAME) binary\" \ 48366 -D\"JDK_VER=\$(VERSION_NUMBER)\" \ 48367 -D\"JDK_COPYRIGHT=Copyright \xA9 $COPYRIGHT_YEAR\" \ 48368 -D\"JDK_NAME=\$(PRODUCT_NAME) \$(JDK_RC_PLATFORM_NAME) \$(VERSION_MAJOR)\" \ 48369 -D\"JDK_FVER=\$(subst .,\$(COMMA),\$(VERSION_NUMBER_FOUR_POSITIONS))\"" 48370 48371 JVM_RCFLAGS="$JVM_RCFLAGS \ 48372 -D\"HS_BUILD_ID=\$(VERSION_STRING)\" \ 48373 -D\"HS_COMPANY=\$(COMPANY_NAME)\" \ 48374 -D\"JDK_DOTVER=\$(VERSION_NUMBER_FOUR_POSITIONS)\" \ 48375 -D\"HS_COPYRIGHT=Copyright $COPYRIGHT_YEAR\" \ 48376 -D\"HS_NAME=\$(PRODUCT_NAME) \$(VERSION_SHORT)\" \ 48377 -D\"JDK_VER=\$(subst .,\$(COMMA),\$(VERSION_NUMBER_FOUR_POSITIONS))\" \ 48378 -D\"HS_FNAME=jvm.dll\" \ 48379 -D\"HS_INTERNAL_NAME=jvm\"" 48380 fi 48381 48382 48383 48384 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 48385 # silence copyright notice and other headers. 48386 COMMON_CCXXFLAGS="$COMMON_CCXXFLAGS -nologo" 48387 fi 48388 48389 48390 # Now we can test some aspects on the target using configure macros. 48391 48392 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 48393 $as_echo_n "checking for ANSI C header files... " >&6; } 48394 if ${ac_cv_header_stdc+:} false; then : 48395 $as_echo_n "(cached) " >&6 48396 else 48397 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48398 /* end confdefs.h. */ 48399 #include <stdlib.h> 48400 #include <stdarg.h> 48401 #include <string.h> 48402 #include <float.h> 48403 48404 int 48405 main () 48406 { 48407 48408 ; 48409 return 0; 48410 } 48411 _ACEOF 48412 if ac_fn_cxx_try_compile "$LINENO"; then : 48413 ac_cv_header_stdc=yes 48414 else 48415 ac_cv_header_stdc=no 48416 fi 48417 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 48418 48419 if test $ac_cv_header_stdc = yes; then 48420 # SunOS 4.x string.h does not declare mem*, contrary to ANSI. 48421 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48422 /* end confdefs.h. */ 48423 #include <string.h> 48424 48425 _ACEOF 48426 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 48427 $EGREP "memchr" >/dev/null 2>&1; then : 48428 48429 else 48430 ac_cv_header_stdc=no 48431 fi 48432 rm -f conftest* 48433 48434 fi 48435 48436 if test $ac_cv_header_stdc = yes; then 48437 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. 48438 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48439 /* end confdefs.h. */ 48440 #include <stdlib.h> 48441 48442 _ACEOF 48443 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 48444 $EGREP "free" >/dev/null 2>&1; then : 48445 48446 else 48447 ac_cv_header_stdc=no 48448 fi 48449 rm -f conftest* 48450 48451 fi 48452 48453 if test $ac_cv_header_stdc = yes; then 48454 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. 48455 if test "$cross_compiling" = yes; then : 48456 : 48457 else 48458 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48459 /* end confdefs.h. */ 48460 #include <ctype.h> 48461 #include <stdlib.h> 48462 #if ((' ' & 0x0FF) == 0x020) 48463 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') 48464 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) 48465 #else 48466 # define ISLOWER(c) \ 48467 (('a' <= (c) && (c) <= 'i') \ 48468 || ('j' <= (c) && (c) <= 'r') \ 48469 || ('s' <= (c) && (c) <= 'z')) 48470 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) 48471 #endif 48472 48473 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) 48474 int 48475 main () 48476 { 48477 int i; 48478 for (i = 0; i < 256; i++) 48479 if (XOR (islower (i), ISLOWER (i)) 48480 || toupper (i) != TOUPPER (i)) 48481 return 2; 48482 return 0; 48483 } 48484 _ACEOF 48485 if ac_fn_cxx_try_run "$LINENO"; then : 48486 48487 else 48488 ac_cv_header_stdc=no 48489 fi 48490 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 48491 conftest.$ac_objext conftest.beam conftest.$ac_ext 48492 fi 48493 48494 fi 48495 fi 48496 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 48497 $as_echo "$ac_cv_header_stdc" >&6; } 48498 if test $ac_cv_header_stdc = yes; then 48499 48500 $as_echo "#define STDC_HEADERS 1" >>confdefs.h 48501 48502 fi 48503 48504 # On IRIX 5.3, sys/types and inttypes.h are conflicting. 48505 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ 48506 inttypes.h stdint.h unistd.h 48507 do : 48508 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` 48509 ac_fn_cxx_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default 48510 " 48511 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : 48512 cat >>confdefs.h <<_ACEOF 48513 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 48514 _ACEOF 48515 48516 fi 48517 48518 done 48519 48520 48521 48522 ############################################################################### 48523 # 48524 # Now we check if libjvm.so will use 32 or 64 bit pointers for the C/C++ code. 48525 # (The JVM can use 32 or 64 bit Java pointers but that decision 48526 # is made at runtime.) 48527 # 48528 48529 if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xaix; then 48530 # Always specify -m flag on Solaris 48531 # And -q on AIX because otherwise the compiler produces 32-bit objects by default 48532 48533 # When we add flags to the "official" CFLAGS etc, we need to 48534 # keep track of these additions in ADDED_CFLAGS etc. These 48535 # will later be checked to make sure only controlled additions 48536 # have been made to CFLAGS etc. 48537 ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48538 ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48539 ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48540 48541 CFLAGS="${CFLAGS}${ADDED_CFLAGS}" 48542 CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}" 48543 LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}" 48544 48545 CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}" 48546 CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}" 48547 LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}" 48548 48549 JVM_CFLAGS="$JVM_CFLAGS $ADDED_CFLAGS" 48550 JVM_LDFLAGS="$JVM_LDFLAGS $ADDED_LDFLAGS" 48551 JVM_ASFLAGS="$JVM_ASFLAGS $ADDED_CFLAGS" 48552 48553 elif test "x$COMPILE_TYPE" = xreduced; then 48554 if test "x$OPENJDK_TARGET_OS_TYPE" = xunix; then 48555 # Specify -m if running reduced on unix platforms 48556 48557 # When we add flags to the "official" CFLAGS etc, we need to 48558 # keep track of these additions in ADDED_CFLAGS etc. These 48559 # will later be checked to make sure only controlled additions 48560 # have been made to CFLAGS etc. 48561 ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48562 ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48563 ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48564 48565 CFLAGS="${CFLAGS}${ADDED_CFLAGS}" 48566 CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}" 48567 LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}" 48568 48569 CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}" 48570 CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}" 48571 LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}" 48572 48573 JVM_CFLAGS="$JVM_CFLAGS $ADDED_CFLAGS" 48574 JVM_LDFLAGS="$JVM_LDFLAGS $ADDED_LDFLAGS" 48575 JVM_ASFLAGS="$JVM_ASFLAGS $ADDED_CFLAGS" 48576 48577 fi 48578 fi 48579 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 48580 JVM_CFLAGS="$JVM_CFLAGS ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48581 JVM_LDFLAGS="$JVM_LDFLAGS ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48582 JVM_ASFLAGS="$JVM_ASFLAGS ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48583 fi 48584 48585 # Make compilation sanity check 48586 for ac_header in stdio.h 48587 do : 48588 ac_fn_cxx_check_header_mongrel "$LINENO" "stdio.h" "ac_cv_header_stdio_h" "$ac_includes_default" 48589 if test "x$ac_cv_header_stdio_h" = xyes; then : 48590 cat >>confdefs.h <<_ACEOF 48591 #define HAVE_STDIO_H 1 48592 _ACEOF 48593 48594 else 48595 48596 { $as_echo "$as_me:${as_lineno-$LINENO}: Failed to compile stdio.h. This likely implies missing compile dependencies." >&5 48597 $as_echo "$as_me: Failed to compile stdio.h. This likely implies missing compile dependencies." >&6;} 48598 if test "x$COMPILE_TYPE" = xreduced; then 48599 48600 # Print a helpful message on how to acquire the necessary build dependency. 48601 # reduced is the help tag: freetype, cups, alsa etc 48602 MISSING_DEPENDENCY=reduced 48603 48604 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 48605 cygwin_help $MISSING_DEPENDENCY 48606 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 48607 msys_help $MISSING_DEPENDENCY 48608 else 48609 PKGHANDLER_COMMAND= 48610 48611 case $PKGHANDLER in 48612 apt-get) 48613 apt_help $MISSING_DEPENDENCY ;; 48614 yum) 48615 yum_help $MISSING_DEPENDENCY ;; 48616 port) 48617 port_help $MISSING_DEPENDENCY ;; 48618 pkgutil) 48619 pkgutil_help $MISSING_DEPENDENCY ;; 48620 pkgadd) 48621 pkgadd_help $MISSING_DEPENDENCY ;; 48622 esac 48623 48624 if test "x$PKGHANDLER_COMMAND" != x; then 48625 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 48626 fi 48627 fi 48628 48629 { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a reduced build. Check that you have 32-bit libraries installed. $HELP_MSG" >&5 48630 $as_echo "$as_me: You are doing a reduced build. Check that you have 32-bit libraries installed. $HELP_MSG" >&6;} 48631 elif test "x$COMPILE_TYPE" = xcross; then 48632 { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&5 48633 $as_echo "$as_me: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&6;} 48634 fi 48635 as_fn_error $? "Cannot continue." "$LINENO" 5 48636 48637 fi 48638 48639 done 48640 48641 48642 # The cast to long int works around a bug in the HP C Compiler 48643 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects 48644 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. 48645 # This bug is HP SR number 8606223364. 48646 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int *" >&5 48647 $as_echo_n "checking size of int *... " >&6; } 48648 if ${ac_cv_sizeof_int_p+:} false; then : 48649 $as_echo_n "(cached) " >&6 48650 else 48651 if ac_fn_cxx_compute_int "$LINENO" "(long int) (sizeof (int *))" "ac_cv_sizeof_int_p" "$ac_includes_default"; then : 48652 48653 else 48654 if test "$ac_cv_type_int_p" = yes; then 48655 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 48656 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 48657 as_fn_error 77 "cannot compute sizeof (int *) 48658 See \`config.log' for more details" "$LINENO" 5; } 48659 else 48660 ac_cv_sizeof_int_p=0 48661 fi 48662 fi 48663 48664 fi 48665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int_p" >&5 48666 $as_echo "$ac_cv_sizeof_int_p" >&6; } 48667 48668 48669 48670 cat >>confdefs.h <<_ACEOF 48671 #define SIZEOF_INT_P $ac_cv_sizeof_int_p 48672 _ACEOF 48673 48674 48675 48676 # AC_CHECK_SIZEOF defines 'ac_cv_sizeof_int_p' to hold the number of bytes used by an 'int*' 48677 if test "x$ac_cv_sizeof_int_p" = x; then 48678 # The test failed, lets stick to the assumed value. 48679 { $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 48680 $as_echo "$as_me: WARNING: The number of bits in the target could not be determined, using $OPENJDK_TARGET_CPU_BITS." >&2;} 48681 else 48682 TESTED_TARGET_CPU_BITS=`expr 8 \* $ac_cv_sizeof_int_p` 48683 48684 if test "x$TESTED_TARGET_CPU_BITS" != "x$OPENJDK_TARGET_CPU_BITS"; then 48685 # This situation may happen on 64-bit platforms where the compiler by default only generates 32-bit objects 48686 # Let's try to implicitely set the compilers target architecture and retry the test 48687 { $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 48688 $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;} 48689 { $as_echo "$as_me:${as_lineno-$LINENO}: Retrying with platforms compiler target bits flag to ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" >&5 48690 $as_echo "$as_me: Retrying with platforms compiler target bits flag to ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" >&6;} 48691 48692 # When we add flags to the "official" CFLAGS etc, we need to 48693 # keep track of these additions in ADDED_CFLAGS etc. These 48694 # will later be checked to make sure only controlled additions 48695 # have been made to CFLAGS etc. 48696 ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48697 ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48698 ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 48699 48700 CFLAGS="${CFLAGS}${ADDED_CFLAGS}" 48701 CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}" 48702 LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}" 48703 48704 CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}" 48705 CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}" 48706 LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}" 48707 48708 JVM_CFLAGS="$JVM_CFLAGS $ADDED_CFLAGS" 48709 JVM_LDFLAGS="$JVM_LDFLAGS $ADDED_LDFLAGS" 48710 JVM_ASFLAGS="$JVM_ASFLAGS $ADDED_CFLAGS" 48711 48712 48713 # We have to unset 'ac_cv_sizeof_int_p' first, otherwise AC_CHECK_SIZEOF will use the previously cached value! 48714 unset ac_cv_sizeof_int_p 48715 # And we have to undef the definition of SIZEOF_INT_P in confdefs.h by the previous invocation of AC_CHECK_SIZEOF 48716 cat >>confdefs.h <<_ACEOF 48717 #undef SIZEOF_INT_P 48718 _ACEOF 48719 48720 # The cast to long int works around a bug in the HP C Compiler 48721 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects 48722 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. 48723 # This bug is HP SR number 8606223364. 48724 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int *" >&5 48725 $as_echo_n "checking size of int *... " >&6; } 48726 if ${ac_cv_sizeof_int_p+:} false; then : 48727 $as_echo_n "(cached) " >&6 48728 else 48729 if ac_fn_cxx_compute_int "$LINENO" "(long int) (sizeof (int *))" "ac_cv_sizeof_int_p" "$ac_includes_default"; then : 48730 48731 else 48732 if test "$ac_cv_type_int_p" = yes; then 48733 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 48734 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 48735 as_fn_error 77 "cannot compute sizeof (int *) 48736 See \`config.log' for more details" "$LINENO" 5; } 48737 else 48738 ac_cv_sizeof_int_p=0 48739 fi 48740 fi 48741 48742 fi 48743 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int_p" >&5 48744 $as_echo "$ac_cv_sizeof_int_p" >&6; } 48745 48746 48747 48748 cat >>confdefs.h <<_ACEOF 48749 #define SIZEOF_INT_P $ac_cv_sizeof_int_p 48750 _ACEOF 48751 48752 48753 48754 TESTED_TARGET_CPU_BITS=`expr 8 \* $ac_cv_sizeof_int_p` 48755 48756 if test "x$TESTED_TARGET_CPU_BITS" != "x$OPENJDK_TARGET_CPU_BITS"; then 48757 { $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 48758 $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;} 48759 if test "x$COMPILE_TYPE" = xreduced; then 48760 48761 # Print a helpful message on how to acquire the necessary build dependency. 48762 # reduced is the help tag: freetype, cups, alsa etc 48763 MISSING_DEPENDENCY=reduced 48764 48765 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 48766 cygwin_help $MISSING_DEPENDENCY 48767 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 48768 msys_help $MISSING_DEPENDENCY 48769 else 48770 PKGHANDLER_COMMAND= 48771 48772 case $PKGHANDLER in 48773 apt-get) 48774 apt_help $MISSING_DEPENDENCY ;; 48775 yum) 48776 yum_help $MISSING_DEPENDENCY ;; 48777 port) 48778 port_help $MISSING_DEPENDENCY ;; 48779 pkgutil) 48780 pkgutil_help $MISSING_DEPENDENCY ;; 48781 pkgadd) 48782 pkgadd_help $MISSING_DEPENDENCY ;; 48783 esac 48784 48785 if test "x$PKGHANDLER_COMMAND" != x; then 48786 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 48787 fi 48788 fi 48789 48790 { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a reduced build. Check that you have 32-bit libraries installed. $HELP_MSG" >&5 48791 $as_echo "$as_me: You are doing a reduced build. Check that you have 32-bit libraries installed. $HELP_MSG" >&6;} 48792 elif test "x$COMPILE_TYPE" = xcross; then 48793 { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&5 48794 $as_echo "$as_me: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&6;} 48795 fi 48796 as_fn_error $? "Cannot continue." "$LINENO" 5 48797 fi 48798 fi 48799 fi 48800 48801 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for target address size" >&5 48802 $as_echo_n "checking for target address size... " >&6; } 48803 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_TARGET_CPU_BITS bits" >&5 48804 $as_echo "$OPENJDK_TARGET_CPU_BITS bits" >&6; } 48805 48806 48807 ############################################################################### 48808 # 48809 # Is the target little of big endian? 48810 # 48811 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5 48812 $as_echo_n "checking whether byte ordering is bigendian... " >&6; } 48813 if ${ac_cv_c_bigendian+:} false; then : 48814 $as_echo_n "(cached) " >&6 48815 else 48816 ac_cv_c_bigendian=unknown 48817 # See if we're dealing with a universal compiler. 48818 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48819 /* end confdefs.h. */ 48820 #ifndef __APPLE_CC__ 48821 not a universal capable compiler 48822 #endif 48823 typedef int dummy; 48824 48825 _ACEOF 48826 if ac_fn_cxx_try_compile "$LINENO"; then : 48827 48828 # Check for potential -arch flags. It is not universal unless 48829 # there are at least two -arch flags with different values. 48830 ac_arch= 48831 ac_prev= 48832 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do 48833 if test -n "$ac_prev"; then 48834 case $ac_word in 48835 i?86 | x86_64 | ppc | ppc64) 48836 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then 48837 ac_arch=$ac_word 48838 else 48839 ac_cv_c_bigendian=universal 48840 break 48841 fi 48842 ;; 48843 esac 48844 ac_prev= 48845 elif test "x$ac_word" = "x-arch"; then 48846 ac_prev=arch 48847 fi 48848 done 48849 fi 48850 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 48851 if test $ac_cv_c_bigendian = unknown; then 48852 # See if sys/param.h defines the BYTE_ORDER macro. 48853 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48854 /* end confdefs.h. */ 48855 #include <sys/types.h> 48856 #include <sys/param.h> 48857 48858 int 48859 main () 48860 { 48861 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \ 48862 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \ 48863 && LITTLE_ENDIAN) 48864 bogus endian macros 48865 #endif 48866 48867 ; 48868 return 0; 48869 } 48870 _ACEOF 48871 if ac_fn_cxx_try_compile "$LINENO"; then : 48872 # It does; now see whether it defined to BIG_ENDIAN or not. 48873 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48874 /* end confdefs.h. */ 48875 #include <sys/types.h> 48876 #include <sys/param.h> 48877 48878 int 48879 main () 48880 { 48881 #if BYTE_ORDER != BIG_ENDIAN 48882 not big endian 48883 #endif 48884 48885 ; 48886 return 0; 48887 } 48888 _ACEOF 48889 if ac_fn_cxx_try_compile "$LINENO"; then : 48890 ac_cv_c_bigendian=yes 48891 else 48892 ac_cv_c_bigendian=no 48893 fi 48894 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 48895 fi 48896 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 48897 fi 48898 if test $ac_cv_c_bigendian = unknown; then 48899 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris). 48900 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48901 /* end confdefs.h. */ 48902 #include <limits.h> 48903 48904 int 48905 main () 48906 { 48907 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN) 48908 bogus endian macros 48909 #endif 48910 48911 ; 48912 return 0; 48913 } 48914 _ACEOF 48915 if ac_fn_cxx_try_compile "$LINENO"; then : 48916 # It does; now see whether it defined to _BIG_ENDIAN or not. 48917 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48918 /* end confdefs.h. */ 48919 #include <limits.h> 48920 48921 int 48922 main () 48923 { 48924 #ifndef _BIG_ENDIAN 48925 not big endian 48926 #endif 48927 48928 ; 48929 return 0; 48930 } 48931 _ACEOF 48932 if ac_fn_cxx_try_compile "$LINENO"; then : 48933 ac_cv_c_bigendian=yes 48934 else 48935 ac_cv_c_bigendian=no 48936 fi 48937 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 48938 fi 48939 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 48940 fi 48941 if test $ac_cv_c_bigendian = unknown; then 48942 # Compile a test program. 48943 if test "$cross_compiling" = yes; then : 48944 # Try to guess by grepping values from an object file. 48945 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48946 /* end confdefs.h. */ 48947 short int ascii_mm[] = 48948 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 }; 48949 short int ascii_ii[] = 48950 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 }; 48951 int use_ascii (int i) { 48952 return ascii_mm[i] + ascii_ii[i]; 48953 } 48954 short int ebcdic_ii[] = 48955 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 }; 48956 short int ebcdic_mm[] = 48957 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 }; 48958 int use_ebcdic (int i) { 48959 return ebcdic_mm[i] + ebcdic_ii[i]; 48960 } 48961 extern int foo; 48962 48963 int 48964 main () 48965 { 48966 return use_ascii (foo) == use_ebcdic (foo); 48967 ; 48968 return 0; 48969 } 48970 _ACEOF 48971 if ac_fn_cxx_try_compile "$LINENO"; then : 48972 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then 48973 ac_cv_c_bigendian=yes 48974 fi 48975 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then 48976 if test "$ac_cv_c_bigendian" = unknown; then 48977 ac_cv_c_bigendian=no 48978 else 48979 # finding both strings is unlikely to happen, but who knows? 48980 ac_cv_c_bigendian=unknown 48981 fi 48982 fi 48983 fi 48984 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 48985 else 48986 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48987 /* end confdefs.h. */ 48988 $ac_includes_default 48989 int 48990 main () 48991 { 48992 48993 /* Are we little or big endian? From Harbison&Steele. */ 48994 union 48995 { 48996 long int l; 48997 char c[sizeof (long int)]; 48998 } u; 48999 u.l = 1; 49000 return u.c[sizeof (long int) - 1] == 1; 49001 49002 ; 49003 return 0; 49004 } 49005 _ACEOF 49006 if ac_fn_cxx_try_run "$LINENO"; then : 49007 ac_cv_c_bigendian=no 49008 else 49009 ac_cv_c_bigendian=yes 49010 fi 49011 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 49012 conftest.$ac_objext conftest.beam conftest.$ac_ext 49013 fi 49014 49015 fi 49016 fi 49017 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5 49018 $as_echo "$ac_cv_c_bigendian" >&6; } 49019 case $ac_cv_c_bigendian in #( 49020 yes) 49021 ENDIAN="big";; #( 49022 no) 49023 ENDIAN="little" ;; #( 49024 universal) 49025 ENDIAN="universal_endianness" 49026 ;; #( 49027 *) 49028 ENDIAN="unknown" ;; 49029 esac 49030 49031 49032 if test "x$ENDIAN" = xuniversal_endianness; then 49033 as_fn_error $? "Building with both big and little endianness is not supported" "$LINENO" 5 49034 fi 49035 if test "x$ENDIAN" != "x$OPENJDK_TARGET_CPU_ENDIAN"; then 49036 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 49037 fi 49038 49039 49040 # Configure flags for the tools 49041 49042 ############################################################################### 49043 # 49044 # How to compile shared libraries. 49045 # 49046 49047 if test "x$TOOLCHAIN_TYPE" = xgcc; then 49048 PICFLAG="-fPIC" 49049 C_FLAG_REORDER='' 49050 CXX_FLAG_REORDER='' 49051 49052 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 49053 # Linking is different on MacOSX 49054 if test "x$STATIC_BUILD" = xtrue; then 49055 SHARED_LIBRARY_FLAGS ='-undefined dynamic_lookup' 49056 else 49057 SHARED_LIBRARY_FLAGS="-dynamiclib -compatibility_version 1.0.0 -current_version 1.0.0 $PICFLAG" 49058 JVM_CFLAGS="$JVM_CFLAGS $PICFLAG" 49059 fi 49060 SET_EXECUTABLE_ORIGIN='-Wl,-rpath,@loader_path/.' 49061 SET_SHARED_LIBRARY_ORIGIN="$SET_EXECUTABLE_ORIGIN" 49062 SET_SHARED_LIBRARY_NAME='-Wl,-install_name,@rpath/$1' 49063 SET_SHARED_LIBRARY_MAPFILE='-Wl,-exported_symbols_list,$1' 49064 else 49065 # Default works for linux, might work on other platforms as well. 49066 SHARED_LIBRARY_FLAGS='-shared' 49067 SET_EXECUTABLE_ORIGIN='-Wl,-rpath,\$$$$ORIGIN$1' 49068 SET_SHARED_LIBRARY_ORIGIN="-Wl,-z,origin $SET_EXECUTABLE_ORIGIN" 49069 SET_SHARED_LIBRARY_NAME='-Wl,-soname=$1' 49070 SET_SHARED_LIBRARY_MAPFILE='-Wl,-version-script=$1' 49071 fi 49072 elif test "x$TOOLCHAIN_TYPE" = xclang; then 49073 C_FLAG_REORDER='' 49074 CXX_FLAG_REORDER='' 49075 49076 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 49077 # Linking is different on MacOSX 49078 PICFLAG='' 49079 SHARED_LIBRARY_FLAGS="-dynamiclib -compatibility_version 1.0.0 -current_version 1.0.0 $PICFLAG" 49080 SET_EXECUTABLE_ORIGIN='-Wl,-rpath,@loader_path/.' 49081 SET_SHARED_LIBRARY_ORIGIN="$SET_EXECUTABLE_ORIGIN" 49082 SET_SHARED_LIBRARY_NAME='-Wl,-install_name,@rpath/$1' 49083 SET_SHARED_LIBRARY_MAPFILE='-Wl,-exported_symbols_list,$1' 49084 49085 if test "x$STATIC_BUILD" = xfalse; then 49086 JVM_CFLAGS="$JVM_CFLAGS -fPIC" 49087 fi 49088 else 49089 # Default works for linux, might work on other platforms as well. 49090 PICFLAG='-fPIC' 49091 SHARED_LIBRARY_FLAGS='-shared' 49092 SET_EXECUTABLE_ORIGIN='-Wl,-rpath,\$$$$ORIGIN$1' 49093 SET_SHARED_LIBRARY_ORIGIN="-Wl,-z,origin $SET_EXECUTABLE_ORIGIN" 49094 SET_SHARED_LIBRARY_NAME='-Wl,-soname=$1' 49095 SET_SHARED_LIBRARY_MAPFILE='-Wl,-version-script=$1' 49096 fi 49097 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 49098 PICFLAG="-KPIC" 49099 C_FLAG_REORDER='-xF' 49100 CXX_FLAG_REORDER='-xF' 49101 SHARED_LIBRARY_FLAGS="-G" 49102 SET_EXECUTABLE_ORIGIN='-R\$$$$ORIGIN$1' 49103 SET_SHARED_LIBRARY_ORIGIN="$SET_EXECUTABLE_ORIGIN" 49104 SET_SHARED_LIBRARY_NAME='-h $1' 49105 SET_SHARED_LIBRARY_MAPFILE='-M$1' 49106 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 49107 # '-qpic' defaults to 'qpic=small'. This means that the compiler generates only 49108 # one instruction for accessing the TOC. If the TOC grows larger than 64K, the linker 49109 # will have to patch this single instruction with a call to some out-of-order code which 49110 # does the load from the TOC. This is of course slow. But in that case we also would have 49111 # to use '-bbigtoc' for linking anyway so we could also change the PICFLAG to 'qpic=large'. 49112 # With 'qpic=large' the compiler will by default generate a two-instruction sequence which 49113 # can be patched directly by the linker and does not require a jump to out-of-order code. 49114 # Another alternative instead of using 'qpic=large -bbigtoc' may be to use '-qminimaltoc' 49115 # instead. This creates a distinct TOC for every compilation unit (and thus requires two 49116 # loads for accessing a global variable). But there are rumors that this may be seen as a 49117 # 'performance feature' because of improved code locality of the symbols used in a 49118 # compilation unit. 49119 PICFLAG="-qpic" 49120 JVM_CFLAGS="$JVM_CFLAGS $PICFLAG" 49121 C_FLAG_REORDER='' 49122 CXX_FLAG_REORDER='' 49123 SHARED_LIBRARY_FLAGS="-qmkshrobj -bM:SRE -bnoentry" 49124 SET_EXECUTABLE_ORIGIN="" 49125 SET_SHARED_LIBRARY_ORIGIN='' 49126 SET_SHARED_LIBRARY_NAME='' 49127 SET_SHARED_LIBRARY_MAPFILE='' 49128 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 49129 PICFLAG="" 49130 C_FLAG_REORDER='' 49131 CXX_FLAG_REORDER='' 49132 SHARED_LIBRARY_FLAGS="-dll" 49133 SET_EXECUTABLE_ORIGIN='' 49134 SET_SHARED_LIBRARY_ORIGIN='' 49135 SET_SHARED_LIBRARY_NAME='' 49136 SET_SHARED_LIBRARY_MAPFILE='-def:$1' 49137 fi 49138 49139 49140 49141 49142 49143 49144 49145 49146 49147 # The (cross) compiler is now configured, we can now test capabilities 49148 # of the target platform. 49149 49150 49151 49152 ############################################################################### 49153 # 49154 # Setup the opt flags for different compilers 49155 # and different operating systems. 49156 # 49157 49158 # FIXME: this was indirectly the old default, but just inherited. 49159 # if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 49160 # C_FLAG_DEPS="-MMD -MF" 49161 # fi 49162 49163 # Generate make dependency files 49164 if test "x$TOOLCHAIN_TYPE" = xgcc; then 49165 C_FLAG_DEPS="-MMD -MF" 49166 elif test "x$TOOLCHAIN_TYPE" = xclang; then 49167 C_FLAG_DEPS="-MMD -MF" 49168 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 49169 C_FLAG_DEPS="-xMMD -xMF" 49170 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 49171 C_FLAG_DEPS="-qmakedep=gcc -MF" 49172 fi 49173 CXX_FLAG_DEPS="$C_FLAG_DEPS" 49174 49175 49176 49177 # Debug symbols 49178 if test "x$TOOLCHAIN_TYPE" = xgcc; then 49179 if test "x$OPENJDK_TARGET_CPU_BITS" = "x64" && test "x$DEBUG_LEVEL" = "xfastdebug"; then 49180 # reduce from default "-g2" option to save space 49181 CFLAGS_DEBUG_SYMBOLS="-g1" 49182 CXXFLAGS_DEBUG_SYMBOLS="-g1" 49183 else 49184 CFLAGS_DEBUG_SYMBOLS="-g" 49185 CXXFLAGS_DEBUG_SYMBOLS="-g" 49186 fi 49187 elif test "x$TOOLCHAIN_TYPE" = xclang; then 49188 CFLAGS_DEBUG_SYMBOLS="-g" 49189 CXXFLAGS_DEBUG_SYMBOLS="-g" 49190 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 49191 CFLAGS_DEBUG_SYMBOLS="-g -xs" 49192 # -g0 enables debug symbols without disabling inlining. 49193 CXXFLAGS_DEBUG_SYMBOLS="-g0 -xs" 49194 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 49195 CFLAGS_DEBUG_SYMBOLS="-g" 49196 CXXFLAGS_DEBUG_SYMBOLS="-g" 49197 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 49198 CFLAGS_DEBUG_SYMBOLS="-Zi" 49199 CXXFLAGS_DEBUG_SYMBOLS="-Zi" 49200 fi 49201 49202 49203 49204 # Debug symbols for JVM_CFLAGS 49205 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 49206 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS -xs" 49207 if test "x$DEBUG_LEVEL" = xslowdebug; then 49208 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS -g" 49209 else 49210 # -g0 does not disable inlining, which -g does. 49211 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS -g0" 49212 fi 49213 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 49214 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS -Z7 -d2Zi+" 49215 else 49216 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS -g" 49217 fi 49218 49219 49220 # bounds, memory and behavior checking options 49221 if test "x$TOOLCHAIN_TYPE" = xgcc; then 49222 case $DEBUG_LEVEL in 49223 release ) 49224 # no adjustment 49225 ;; 49226 fastdebug ) 49227 # no adjustment 49228 ;; 49229 slowdebug ) 49230 # FIXME: By adding this to C(XX)FLAGS_DEBUG_OPTIONS/JVM_CFLAGS_SYMBOLS it 49231 # get's added conditionally on whether we produce debug symbols or not. 49232 # This is most likely not really correct. 49233 49234 # Add runtime stack smashing and undefined behavior checks. 49235 # Not all versions of gcc support -fstack-protector 49236 STACK_PROTECTOR_CFLAG="-fstack-protector-all" 49237 49238 49239 49240 49241 49242 49243 49244 49245 49246 49247 49248 49249 49250 49251 49252 49253 49254 49255 49256 49257 49258 49259 49260 49261 49262 49263 49264 49265 49266 49267 49268 49269 49270 49271 49272 49273 49274 49275 49276 49277 49278 49279 # Execute function body 49280 49281 49282 49283 49284 49285 49286 49287 49288 49289 49290 49291 49292 49293 49294 49295 49296 49297 49298 49299 49300 49301 49302 49303 49304 49305 49306 49307 49308 49309 49310 49311 49312 49313 49314 49315 49316 49317 49318 49319 49320 49321 49322 49323 49324 49325 49326 49327 49328 # Execute function body 49329 49330 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler supports \"$STACK_PROTECTOR_CFLAG -Werror\"" >&5 49331 $as_echo_n "checking if the C compiler supports \"$STACK_PROTECTOR_CFLAG -Werror\"... " >&6; } 49332 supports=yes 49333 49334 saved_cflags="$CFLAGS" 49335 CFLAGS="$CFLAGS $STACK_PROTECTOR_CFLAG -Werror" 49336 ac_ext=c 49337 ac_cpp='$CPP $CPPFLAGS' 49338 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 49339 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 49340 ac_compiler_gnu=$ac_cv_c_compiler_gnu 49341 49342 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 49343 /* end confdefs.h. */ 49344 int i; 49345 _ACEOF 49346 if ac_fn_c_try_compile "$LINENO"; then : 49347 49348 else 49349 supports=no 49350 fi 49351 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 49352 ac_ext=cpp 49353 ac_cpp='$CXXCPP $CPPFLAGS' 49354 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 49355 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 49356 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 49357 49358 CFLAGS="$saved_cflags" 49359 49360 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 49361 $as_echo "$supports" >&6; } 49362 if test "x$supports" = "xyes" ; then 49363 : 49364 C_COMP_SUPPORTS="yes" 49365 else 49366 : 49367 C_COMP_SUPPORTS="no" 49368 fi 49369 49370 49371 49372 49373 49374 49375 49376 49377 49378 49379 49380 49381 49382 49383 49384 49385 49386 49387 49388 49389 49390 49391 49392 49393 49394 49395 49396 49397 49398 49399 49400 49401 49402 49403 49404 49405 49406 49407 49408 49409 49410 49411 49412 49413 49414 49415 49416 49417 49418 49419 49420 49421 49422 49423 49424 49425 49426 49427 49428 # Execute function body 49429 49430 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"$STACK_PROTECTOR_CFLAG -Werror\"" >&5 49431 $as_echo_n "checking if the C++ compiler supports \"$STACK_PROTECTOR_CFLAG -Werror\"... " >&6; } 49432 supports=yes 49433 49434 saved_cxxflags="$CXXFLAGS" 49435 CXXFLAGS="$CXXFLAG $STACK_PROTECTOR_CFLAG -Werror" 49436 ac_ext=cpp 49437 ac_cpp='$CXXCPP $CPPFLAGS' 49438 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 49439 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 49440 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 49441 49442 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 49443 /* end confdefs.h. */ 49444 int i; 49445 _ACEOF 49446 if ac_fn_cxx_try_compile "$LINENO"; then : 49447 49448 else 49449 supports=no 49450 fi 49451 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 49452 ac_ext=cpp 49453 ac_cpp='$CXXCPP $CPPFLAGS' 49454 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 49455 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 49456 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 49457 49458 CXXFLAGS="$saved_cxxflags" 49459 49460 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 49461 $as_echo "$supports" >&6; } 49462 if test "x$supports" = "xyes" ; then 49463 : 49464 CXX_COMP_SUPPORTS="yes" 49465 else 49466 : 49467 CXX_COMP_SUPPORTS="no" 49468 fi 49469 49470 49471 49472 49473 49474 49475 49476 49477 49478 49479 49480 49481 49482 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"$STACK_PROTECTOR_CFLAG -Werror\"" >&5 49483 $as_echo_n "checking if both compilers support \"$STACK_PROTECTOR_CFLAG -Werror\"... " >&6; } 49484 supports=no 49485 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 49486 49487 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 49488 $as_echo "$supports" >&6; } 49489 if test "x$supports" = "xyes" ; then 49490 : 49491 49492 else 49493 : 49494 STACK_PROTECTOR_CFLAG="" 49495 fi 49496 49497 49498 49499 49500 49501 49502 49503 CFLAGS_DEBUG_OPTIONS="$STACK_PROTECTOR_CFLAG --param ssp-buffer-size=1" 49504 CXXFLAGS_DEBUG_OPTIONS="$STACK_PROTECTOR_CFLAG --param ssp-buffer-size=1" 49505 if test "x$STACK_PROTECTOR_CFLAG" != x; then 49506 JVM_CFLAGS_SYMBOLS="$JVM_CFLAGS_SYMBOLS $STACK_PROTECTOR_CFLAG --param ssp-buffer-size=1" 49507 fi 49508 ;; 49509 esac 49510 fi 49511 49512 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 49513 if test "x$DEBUG_LEVEL" != xrelease; then 49514 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 49515 JVM_CFLAGS="$JVM_CFLAGS -homeparams" 49516 fi 49517 fi 49518 fi 49519 49520 # Optimization levels 49521 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 49522 CC_HIGHEST="$CC_HIGHEST -fns -fsimple -fsingle -xbuiltin=%all -xdepend -xrestrict -xlibmil" 49523 49524 if test "x$OPENJDK_TARGET_CPU_ARCH" = "xx86"; then 49525 # FIXME: seems we always set -xregs=no%frameptr; put it elsewhere more global? 49526 C_O_FLAG_HIGHEST_JVM="-xO4" 49527 C_O_FLAG_HIGHEST="-xO4 -Wu,-O4~yz $CC_HIGHEST -xalias_level=basic -xregs=no%frameptr" 49528 C_O_FLAG_HI="-xO4 -Wu,-O4~yz -xregs=no%frameptr" 49529 C_O_FLAG_NORM="-xO2 -Wu,-O2~yz -xregs=no%frameptr" 49530 C_O_FLAG_DEBUG="-xregs=no%frameptr" 49531 C_O_FLAG_DEBUG_JVM="" 49532 C_O_FLAG_NONE="-xregs=no%frameptr" 49533 CXX_O_FLAG_HIGHEST_JVM="-xO4" 49534 CXX_O_FLAG_HIGHEST="-xO4 -Qoption ube -O4~yz $CC_HIGHEST -xregs=no%frameptr" 49535 CXX_O_FLAG_HI="-xO4 -Qoption ube -O4~yz -xregs=no%frameptr" 49536 CXX_O_FLAG_NORM="-xO2 -Qoption ube -O2~yz -xregs=no%frameptr" 49537 CXX_O_FLAG_DEBUG="-xregs=no%frameptr" 49538 CXX_O_FLAG_DEBUG_JVM="" 49539 CXX_O_FLAG_NONE="-xregs=no%frameptr" 49540 if test "x$OPENJDK_TARGET_CPU_BITS" = "x32"; then 49541 C_O_FLAG_HIGHEST="$C_O_FLAG_HIGHEST -xchip=pentium" 49542 CXX_O_FLAG_HIGHEST="$CXX_O_FLAG_HIGHEST -xchip=pentium" 49543 fi 49544 elif test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then 49545 C_O_FLAG_HIGHEST_JVM="-xO4" 49546 C_O_FLAG_HIGHEST="-xO4 -Wc,-Qrm-s -Wc,-Qiselect-T0 $CC_HIGHEST -xalias_level=basic -xprefetch=auto,explicit -xchip=ultra" 49547 C_O_FLAG_HI="-xO4 -Wc,-Qrm-s -Wc,-Qiselect-T0" 49548 C_O_FLAG_NORM="-xO2 -Wc,-Qrm-s -Wc,-Qiselect-T0" 49549 C_O_FLAG_DEBUG="" 49550 C_O_FLAG_DEBUG_JVM="" 49551 C_O_FLAG_NONE="" 49552 CXX_O_FLAG_HIGHEST_JVM="-xO4" 49553 CXX_O_FLAG_HIGHEST="-xO4 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0 $CC_HIGHEST -xprefetch=auto,explicit -xchip=ultra" 49554 CXX_O_FLAG_HI="-xO4 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0" 49555 CXX_O_FLAG_NORM="-xO2 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0" 49556 CXX_O_FLAG_DEBUG="" 49557 CXX_O_FLAG_DEBUG_JVM="" 49558 CXX_O_FLAG_NONE="" 49559 fi 49560 else 49561 # The remaining toolchains share opt flags between CC and CXX; 49562 # setup for C and duplicate afterwards. 49563 if test "x$TOOLCHAIN_TYPE" = xgcc; then 49564 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 49565 # On MacOSX we optimize for size, something 49566 # we should do for all platforms? 49567 C_O_FLAG_HIGHEST_JVM="-Os" 49568 C_O_FLAG_HIGHEST="-Os" 49569 C_O_FLAG_HI="-Os" 49570 C_O_FLAG_NORM="-Os" 49571 C_O_FLAG_SIZE="-Os" 49572 else 49573 C_O_FLAG_HIGHEST_JVM="-O3" 49574 C_O_FLAG_HIGHEST="-O3" 49575 C_O_FLAG_HI="-O3" 49576 C_O_FLAG_NORM="-O2" 49577 C_O_FLAG_SIZE="-Os" 49578 fi 49579 C_O_FLAG_DEBUG="-O0" 49580 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 49581 C_O_FLAG_DEBUG_JVM="" 49582 elif test "x$OPENJDK_TARGET_OS" = xlinux; then 49583 C_O_FLAG_DEBUG_JVM="-O0" 49584 fi 49585 C_O_FLAG_NONE="-O0" 49586 elif test "x$TOOLCHAIN_TYPE" = xclang; then 49587 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 49588 # On MacOSX we optimize for size, something 49589 # we should do for all platforms? 49590 C_O_FLAG_HIGHEST_JVM="-Os" 49591 C_O_FLAG_HIGHEST="-Os" 49592 C_O_FLAG_HI="-Os" 49593 C_O_FLAG_NORM="-Os" 49594 C_O_FLAG_SIZE="-Os" 49595 else 49596 C_O_FLAG_HIGHEST_JVM="-O3" 49597 C_O_FLAG_HIGHEST="-O3" 49598 C_O_FLAG_HI="-O3" 49599 C_O_FLAG_NORM="-O2" 49600 C_O_FLAG_SIZE="-Os" 49601 fi 49602 C_O_FLAG_DEBUG="-O0" 49603 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 49604 C_O_FLAG_DEBUG_JVM="" 49605 elif test "x$OPENJDK_TARGET_OS" = xlinux; then 49606 C_O_FLAG_DEBUG_JVM="-O0" 49607 fi 49608 C_O_FLAG_NONE="-O0" 49609 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 49610 C_O_FLAG_HIGHEST_JVM="-O3 -qhot=level=1 -qinline -qinlglue" 49611 C_O_FLAG_HIGHEST="-O3 -qhot=level=1 -qinline -qinlglue" 49612 C_O_FLAG_HI="-O3 -qinline -qinlglue" 49613 C_O_FLAG_NORM="-O2" 49614 C_O_FLAG_DEBUG="-qnoopt" 49615 # FIXME: Value below not verified. 49616 C_O_FLAG_DEBUG_JVM="" 49617 C_O_FLAG_NONE="-qnoopt" 49618 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 49619 C_O_FLAG_HIGHEST_JVM="-O2 -Oy-" 49620 C_O_FLAG_HIGHEST="-O2" 49621 C_O_FLAG_HI="-O1" 49622 C_O_FLAG_NORM="-O1" 49623 C_O_FLAG_DEBUG="-Od" 49624 C_O_FLAG_DEBUG_JVM="" 49625 C_O_FLAG_NONE="-Od" 49626 C_O_FLAG_SIZE="-Os" 49627 fi 49628 CXX_O_FLAG_HIGHEST_JVM="$C_O_FLAG_HIGHEST_JVM" 49629 CXX_O_FLAG_HIGHEST="$C_O_FLAG_HIGHEST" 49630 CXX_O_FLAG_HI="$C_O_FLAG_HI" 49631 CXX_O_FLAG_NORM="$C_O_FLAG_NORM" 49632 CXX_O_FLAG_DEBUG="$C_O_FLAG_DEBUG" 49633 CXX_O_FLAG_DEBUG_JVM="$C_O_FLAG_DEBUG_JVM" 49634 CXX_O_FLAG_NONE="$C_O_FLAG_NONE" 49635 CXX_O_FLAG_SIZE="$C_O_FLAG_SIZE" 49636 fi 49637 49638 # Adjust optimization flags according to debug level. 49639 case $DEBUG_LEVEL in 49640 release ) 49641 # no adjustment 49642 ;; 49643 fastdebug ) 49644 # Not quite so much optimization 49645 C_O_FLAG_HI="$C_O_FLAG_NORM" 49646 CXX_O_FLAG_HI="$CXX_O_FLAG_NORM" 49647 ;; 49648 slowdebug ) 49649 # Disable optimization 49650 C_O_FLAG_HIGHEST_JVM="$C_O_FLAG_DEBUG_JVM" 49651 C_O_FLAG_HIGHEST="$C_O_FLAG_DEBUG" 49652 C_O_FLAG_HI="$C_O_FLAG_DEBUG" 49653 C_O_FLAG_NORM="$C_O_FLAG_DEBUG" 49654 C_O_FLAG_SIZE="$C_O_FLAG_DEBUG" 49655 CXX_O_FLAG_HIGHEST_JVM="$CXX_O_FLAG_DEBUG_JVM" 49656 CXX_O_FLAG_HIGHEST="$CXX_O_FLAG_DEBUG" 49657 CXX_O_FLAG_HI="$CXX_O_FLAG_DEBUG" 49658 CXX_O_FLAG_NORM="$CXX_O_FLAG_DEBUG" 49659 CXX_O_FLAG_SIZE="$CXX_O_FLAG_DEBUG" 49660 ;; 49661 esac 49662 49663 49664 49665 49666 49667 49668 49669 49670 49671 49672 49673 49674 49675 49676 49677 49678 49679 49680 49681 # Special extras... 49682 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 49683 if test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then 49684 CFLAGS_JDKLIB_EXTRA="${CFLAGS_JDKLIB_EXTRA} -xregs=no%appl" 49685 CXXFLAGS_JDKLIB_EXTRA="${CXXFLAGS_JDKLIB_EXTRA} -xregs=no%appl" 49686 fi 49687 CFLAGS_JDKLIB_EXTRA="${CFLAGS_JDKLIB_EXTRA} -errtags=yes -errfmt" 49688 CXXFLAGS_JDKLIB_EXTRA="${CXXFLAGS_JDKLIB_EXTRA} -errtags=yes -errfmt" 49689 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 49690 CFLAGS_JDK="${CFLAGS_JDK} -qchars=signed -qfullpath -qsaveopt" 49691 CXXFLAGS_JDK="${CXXFLAGS_JDK} -qchars=signed -qfullpath -qsaveopt" 49692 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 49693 CXXSTD_CXXFLAG="-std=gnu++98" 49694 49695 49696 49697 49698 49699 49700 49701 49702 49703 49704 49705 49706 49707 49708 49709 49710 49711 49712 49713 49714 49715 49716 49717 49718 49719 49720 49721 49722 49723 49724 49725 49726 49727 49728 49729 49730 49731 49732 49733 49734 49735 49736 # Execute function body 49737 49738 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"$CXXSTD_CXXFLAG -Werror\"" >&5 49739 $as_echo_n "checking if the C++ compiler supports \"$CXXSTD_CXXFLAG -Werror\"... " >&6; } 49740 supports=yes 49741 49742 saved_cxxflags="$CXXFLAGS" 49743 CXXFLAGS="$CXXFLAG $CXXSTD_CXXFLAG -Werror" 49744 ac_ext=cpp 49745 ac_cpp='$CXXCPP $CPPFLAGS' 49746 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 49747 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 49748 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 49749 49750 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 49751 /* end confdefs.h. */ 49752 int i; 49753 _ACEOF 49754 if ac_fn_cxx_try_compile "$LINENO"; then : 49755 49756 else 49757 supports=no 49758 fi 49759 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 49760 ac_ext=cpp 49761 ac_cpp='$CXXCPP $CPPFLAGS' 49762 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 49763 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 49764 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 49765 49766 CXXFLAGS="$saved_cxxflags" 49767 49768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 49769 $as_echo "$supports" >&6; } 49770 if test "x$supports" = "xyes" ; then 49771 : 49772 49773 else 49774 : 49775 CXXSTD_CXXFLAG="" 49776 fi 49777 49778 49779 49780 49781 49782 49783 49784 49785 49786 49787 49788 49789 CXXFLAGS_JDK="${CXXFLAGS_JDK} ${CXXSTD_CXXFLAG}" 49790 JVM_CFLAGS="${JVM_CFLAGS} ${CXXSTD_CXXFLAG}" 49791 49792 fi 49793 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 49794 CFLAGS_JDK="${CFLAGS_JDK} -D__solaris__" 49795 CXXFLAGS_JDK="${CXXFLAGS_JDK} -D__solaris__" 49796 fi 49797 49798 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 49799 CFLAGS_JDK="${CFLAGS_JDK} -D__solaris__" 49800 CXXFLAGS_JDK="${CXXFLAGS_JDK} -D__solaris__" 49801 fi 49802 49803 CFLAGS_JDK="${CFLAGS_JDK} ${EXTRA_CFLAGS}" 49804 CXXFLAGS_JDK="${CXXFLAGS_JDK} ${EXTRA_CXXFLAGS}" 49805 LDFLAGS_JDK="${LDFLAGS_JDK} ${EXTRA_LDFLAGS}" 49806 49807 ############################################################################### 49808 # 49809 # Now setup the CFLAGS and LDFLAGS for the JDK build. 49810 # Later we will also have CFLAGS and LDFLAGS for the hotspot subrepo build. 49811 # 49812 49813 # Setup compiler/platform specific flags into 49814 # CFLAGS_JDK - C Compiler flags 49815 # CXXFLAGS_JDK - C++ Compiler flags 49816 # COMMON_CCXXFLAGS_JDK - common to C and C++ 49817 if test "x$TOOLCHAIN_TYPE" = xgcc; then 49818 JVM_CFLAGS="$JVM_CFLAGS -D_GNU_SOURCE" 49819 JVM_CFLAGS="$JVM_CFLAGS -D_REENTRANT" 49820 JVM_CFLAGS="$JVM_CFLAGS -fcheck-new" 49821 if test "x$OPENJDK_TARGET_CPU" = xx86; then 49822 # Force compatibility with i586 on 32 bit intel platforms. 49823 COMMON_CCXXFLAGS="${COMMON_CCXXFLAGS} -march=i586" 49824 JVM_CFLAGS="$JVM_CFLAGS -march=i586" 49825 fi 49826 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS $COMMON_CCXXFLAGS_JDK -Wall -Wextra -Wno-unused -Wno-unused-parameter -Wformat=2 \ 49827 -pipe -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE" 49828 case $OPENJDK_TARGET_CPU_ARCH in 49829 arm ) 49830 # on arm we don't prevent gcc to omit frame pointer but do prevent strict aliasing 49831 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 49832 ;; 49833 ppc ) 49834 # on ppc we don't prevent gcc to omit frame pointer but do prevent strict aliasing 49835 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 49836 ;; 49837 * ) 49838 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer" 49839 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 49840 ;; 49841 esac 49842 49843 49844 49845 49846 49847 49848 49849 49850 49851 49852 49853 49854 49855 49856 49857 49858 49859 49860 49861 49862 49863 49864 49865 49866 49867 49868 49869 49870 49871 49872 49873 49874 49875 49876 49877 49878 49879 49880 49881 49882 49883 49884 49885 49886 49887 49888 49889 49890 49891 49892 49893 49894 49895 49896 # Execute function body 49897 49898 # Need to assign to a variable since m4 is blocked from modifying parts in []. 49899 REFERENCE_VERSION=6 49900 49901 if [[ "$REFERENCE_VERSION" =~ (.*\.){3} ]] ; then 49902 as_fn_error $? "Internal error: Cannot compare to 6, only three parts (X.Y.Z) is supported" "$LINENO" 5 49903 fi 49904 49905 if [[ "$REFERENCE_VERSION" =~ [0-9]{6} ]] ; then 49906 as_fn_error $? "Internal error: Cannot compare to 6, only parts < 99999 is supported" "$LINENO" 5 49907 fi 49908 49909 # Version comparison method inspired by http://stackoverflow.com/a/24067243 49910 COMPARABLE_REFERENCE_VERSION=`$AWK -F. '{ printf("%05d%05d%05d\n", $1, $2, $3) }' <<< "$REFERENCE_VERSION"` 49911 49912 if test $COMPARABLE_ACTUAL_VERSION -ge $COMPARABLE_REFERENCE_VERSION ; then 49913 : 49914 49915 # These flags are required for GCC 6 builds as undefined behaviour in OpenJDK code 49916 # runs afoul of the more aggressive versions of these optimisations. 49917 # Notably, value range propagation now assumes that the this pointer of C++ 49918 # member functions is non-null. 49919 NO_DELETE_NULL_POINTER_CHECKS_CFLAG="-fno-delete-null-pointer-checks" 49920 NO_LIFETIME_DSE_CFLAG="-fno-lifetime-dse" 49921 { $as_echo "$as_me:${as_lineno-$LINENO}: GCC >= 6 detected; adding ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} and ${NO_LIFETIME_DSE_CFLAG}" >&5 49922 $as_echo "$as_me: GCC >= 6 detected; adding ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} and ${NO_LIFETIME_DSE_CFLAG}" >&6;} 49923 CFLAGS_JDK="$CFLAGS_JDK ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} ${NO_LIFETIME_DSE_CFLAG}" 49924 JVM_CFLAGS="$JVM_CFLAGS ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} ${NO_LIFETIME_DSE_CFLAG}" 49925 49926 else 49927 : 49928 49929 fi 49930 49931 49932 49933 49934 49935 49936 49937 49938 49939 49940 49941 49942 49943 49944 elif test "x$TOOLCHAIN_TYPE" = xclang; then 49945 JVM_CFLAGS="$JVM_CFLAGS -D_GNU_SOURCE" 49946 49947 # Restrict the debug information created by Clang to avoid 49948 # too big object files and speed the build up a little bit 49949 # (see http://llvm.org/bugs/show_bug.cgi?id=7554) 49950 JVM_CFLAGS="$JVM_CFLAGS -flimit-debug-info" 49951 if test "x$OPENJDK_TARGET_OS" = xlinux; then 49952 if test "x$OPENJDK_TARGET_CPU" = xx86; then 49953 # Force compatibility with i586 on 32 bit intel platforms. 49954 COMMON_CCXXFLAGS="${COMMON_CCXXFLAGS} -march=i586" 49955 JVM_CFLAGS="$JVM_CFLAGS -march=i586" 49956 fi 49957 JVM_CFLAGS="$JVM_CFLAGS -Wno-sometimes-uninitialized" 49958 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS $COMMON_CCXXFLAGS_JDK -Wall -Wextra -Wno-unused -Wno-unused-parameter -Wformat=2 \ 49959 -pipe -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE" 49960 case $OPENJDK_TARGET_CPU_ARCH in 49961 ppc ) 49962 # on ppc we don't prevent gcc to omit frame pointer but do prevent strict aliasing 49963 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 49964 ;; 49965 * ) 49966 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer" 49967 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 49968 ;; 49969 esac 49970 fi 49971 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 49972 JVM_CFLAGS="$JVM_CFLAGS -DSPARC_WORKS" 49973 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS $COMMON_CCXXFLAGS_JDK -DTRACING -DMACRO_MEMSYS_OPS -DBREAKPTS" 49974 if test "x$OPENJDK_TARGET_CPU_ARCH" = xx86; then 49975 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DcpuIntel -Di586 -D$OPENJDK_TARGET_CPU_LEGACY_LIB" 49976 fi 49977 49978 CFLAGS_JDK="$CFLAGS_JDK -xc99=%none -xCC -errshort=tags -Xa -v -mt -W0,-noglobal" 49979 CXXFLAGS_JDK="$CXXFLAGS_JDK -errtags=yes +w -mt -features=no%except -DCC_NOEX -norunpath -xnolib" 49980 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 49981 JVM_CFLAGS="$JVM_CFLAGS -D_REENTRANT -D__STDC_FORMAT_MACROS" 49982 CFLAGS_JDK="$CFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC" 49983 CXXFLAGS_JDK="$CXXFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC" 49984 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 49985 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS $COMMON_CCXXFLAGS_JDK \ 49986 -MD -Zc:wchar_t- -W3 -wd4800 \ 49987 -DWIN32_LEAN_AND_MEAN \ 49988 -D_CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE \ 49989 -D_WINSOCK_DEPRECATED_NO_WARNINGS \ 49990 -DWIN32 -DIAL" 49991 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 49992 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_AMD64_ -Damd64" 49993 else 49994 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_X86_ -Dx86" 49995 fi 49996 # If building with Visual Studio 2010, we can still use _STATIC_CPPLIB to 49997 # avoid bundling msvcpNNN.dll. Doesn't work with newer versions of visual 49998 # studio. 49999 if test "x$TOOLCHAIN_VERSION" = "x2010"; then 50000 STATIC_CPPLIB_FLAGS="-D_STATIC_CPPLIB -D_DISABLE_DEPRECATE_STATIC_CPPLIB" 50001 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK $STATIC_CPPLIB_FLAGS" 50002 JVM_CFLAGS="$JVM_CFLAGS $STATIC_CPPLIB_FLAGS" 50003 fi 50004 fi 50005 50006 ############################################################################### 50007 50008 # Adjust flags according to debug level. 50009 case $DEBUG_LEVEL in 50010 fastdebug | slowdebug ) 50011 CFLAGS_JDK="$CFLAGS_JDK $CFLAGS_DEBUG_SYMBOLS $CFLAGS_DEBUG_OPTIONS" 50012 CXXFLAGS_JDK="$CXXFLAGS_JDK $CXXFLAGS_DEBUG_SYMBOLS $CXXFLAGS_DEBUG_OPTIONS" 50013 JAVAC_FLAGS="$JAVAC_FLAGS -g" 50014 ;; 50015 release ) 50016 ;; 50017 * ) 50018 as_fn_error $? "Unrecognized \$DEBUG_LEVEL: $DEBUG_LEVEL" "$LINENO" 5 50019 ;; 50020 esac 50021 50022 # Set some common defines. These works for all compilers, but assume 50023 # -D is universally accepted. 50024 50025 # Setup endianness 50026 if test "x$OPENJDK_TARGET_CPU_ENDIAN" = xlittle; then 50027 # The macro _LITTLE_ENDIAN needs to be defined the same to avoid the 50028 # Sun C compiler warning message: warning: macro redefined: _LITTLE_ENDIAN 50029 # (The Solaris X86 system defines this in file /usr/include/sys/isa_defs.h). 50030 # Note: -Dmacro is the same as #define macro 1 50031 # -Dmacro= is the same as #define macro 50032 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 50033 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_LITTLE_ENDIAN=" 50034 else 50035 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_LITTLE_ENDIAN" 50036 fi 50037 else 50038 # Same goes for _BIG_ENDIAN. Do we really need to set *ENDIAN on Solaris if they 50039 # are defined in the system? 50040 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 50041 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_BIG_ENDIAN=" 50042 else 50043 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_BIG_ENDIAN" 50044 fi 50045 fi 50046 50047 # Setup target OS define. Use OS target name but in upper case. 50048 OPENJDK_TARGET_OS_UPPERCASE=`$ECHO $OPENJDK_TARGET_OS | $TR 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` 50049 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D$OPENJDK_TARGET_OS_UPPERCASE" 50050 50051 # Setup target CPU 50052 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK \ 50053 $OPENJDK_TARGET_ADD_LP64 \ 50054 -DARCH='\"$OPENJDK_TARGET_CPU_LEGACY\"' -D$OPENJDK_TARGET_CPU_LEGACY" 50055 50056 # Setup debug/release defines 50057 if test "x$DEBUG_LEVEL" = xrelease; then 50058 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DNDEBUG" 50059 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 50060 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DTRIMMED" 50061 fi 50062 else 50063 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DDEBUG" 50064 fi 50065 50066 # Set some additional per-OS defines. 50067 if test "x$OPENJDK_TARGET_OS" = xlinux; then 50068 JVM_CFLAGS="$JVM_CFLAGS -DLINUX" 50069 JVM_CFLAGS="$JVM_CFLAGS -pipe -fPIC -fno-rtti -fno-exceptions \ 50070 -fvisibility=hidden -fno-strict-aliasing -fno-omit-frame-pointer" 50071 elif test "x$OPENJDK_TARGET_OS" = xsolaris; then 50072 JVM_CFLAGS="$JVM_CFLAGS -DSOLARIS" 50073 JVM_CFLAGS="$JVM_CFLAGS -template=no%extdef -features=no%split_init \ 50074 -D_Crun_inline_placement -library=%none -KPIC -mt -xwe -features=no%except" 50075 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 50076 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE -D_DARWIN_UNLIMITED_SELECT" 50077 JVM_CFLAGS="$JVM_CFLAGS -D_ALLBSD_SOURCE" 50078 JVM_CFLAGS="$JVM_CFLAGS -D_DARWIN_C_SOURCE -D_XOPEN_SOURCE" 50079 JVM_CFLAGS="$JVM_CFLAGS -fno-rtti -fno-exceptions -fvisibility=hidden \ 50080 -mno-omit-leaf-frame-pointer -mstack-alignment=16 -pipe -fno-strict-aliasing \ 50081 -DMAC_OS_X_VERSION_MAX_ALLOWED=1070 -mmacosx-version-min=10.7.0 \ 50082 -fno-omit-frame-pointer" 50083 elif test "x$OPENJDK_TARGET_OS" = xaix; then 50084 JVM_CFLAGS="$JVM_CFLAGS -DAIX" 50085 # We may need '-qminimaltoc' or '-qpic=large -bbigtoc' if the TOC overflows. 50086 JVM_CFLAGS="$JVM_CFLAGS -qtune=balanced \ 50087 -qalias=noansi -qstrict -qtls=default -qlanglvl=c99vla \ 50088 -qlanglvl=noredefmac -qnortti -qnoeh -qignerrno" 50089 elif test "x$OPENJDK_TARGET_OS" = xbsd; then 50090 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE" 50091 elif test "x$OPENJDK_TARGET_OS" = xwindows; then 50092 JVM_CFLAGS="$JVM_CFLAGS -D_WINDOWS -DWIN32 -D_JNI_IMPLEMENTATION_" 50093 JVM_CFLAGS="$JVM_CFLAGS -nologo -W3 -MD -MP" 50094 fi 50095 50096 # Set some additional per-CPU defines. 50097 if test "x$OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" = xwindows-x86; then 50098 JVM_CFLAGS="$JVM_CFLAGS -arch:IA32" 50099 elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then 50100 JVM_CFLAGS="$JVM_CFLAGS -xarch=sparc" 50101 elif test "x$OPENJDK_TARGET_CPU" = xppc64; then 50102 if test "x$OPENJDK_TARGET_OS" = xlinux; then 50103 JVM_CFLAGS="$JVM_CFLAGS -minsert-sched-nops=regroup_exact -mno-multiple -mno-string" 50104 # fixes `relocation truncated to fit' error for gcc 4.1. 50105 JVM_CFLAGS="$JVM_CFLAGS -mminimal-toc" 50106 # Use ppc64 instructions, but schedule for power5 50107 JVM_CFLAGS="$JVM_CFLAGS -mcpu=powerpc64 -mtune=power5" 50108 elif test "x$OPENJDK_TARGET_OS" = xaix; then 50109 JVM_CFLAGS="$JVM_CFLAGS -qarch=ppc64" 50110 fi 50111 elif test "x$OPENJDK_TARGET_CPU" = xppc64le; then 50112 if test "x$OPENJDK_TARGET_OS" = xlinux; then 50113 JVM_CFLAGS="$JVM_CFLAGS -minsert-sched-nops=regroup_exact -mno-multiple -mno-string" 50114 # Little endian machine uses ELFv2 ABI. 50115 JVM_CFLAGS="$JVM_CFLAGS -DABI_ELFv2" 50116 # Use Power8, this is the first CPU to support PPC64 LE with ELFv2 ABI. 50117 JVM_CFLAGS="$JVM_CFLAGS -mcpu=power7 -mtune=power8" 50118 fi 50119 fi 50120 50121 if test "x$OPENJDK_TARGET_CPU_ENDIAN" = xlittle; then 50122 JVM_CFLAGS="$JVM_CFLAGS -DVM_LITTLE_ENDIAN" 50123 fi 50124 50125 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 50126 if test "x$OPENJDK_TARGET_OS" != xsolaris && test "x$OPENJDK_TARGET_OS" != xaix; then 50127 # Solaris does not have _LP64=1 in the old build. 50128 # xlc on AIX defines _LP64=1 by default and issues a warning if we redefine it. 50129 JVM_CFLAGS="$JVM_CFLAGS -D_LP64=1" 50130 fi 50131 fi 50132 50133 # Set JVM_CFLAGS warning handling 50134 if test "x$OPENJDK_TARGET_OS" = xlinux; then 50135 JVM_CFLAGS="$JVM_CFLAGS -Wpointer-arith -Wsign-compare -Wunused-function \ 50136 -Wunused-value -Woverloaded-virtual" 50137 50138 if test "x$TOOLCHAIN_TYPE" = xgcc; then 50139 50140 50141 50142 50143 50144 50145 50146 50147 50148 50149 50150 50151 50152 50153 50154 50155 50156 50157 50158 50159 50160 50161 50162 50163 50164 50165 50166 50167 50168 50169 50170 50171 50172 50173 50174 50175 50176 50177 50178 50179 50180 50181 50182 50183 50184 50185 50186 50187 50188 50189 50190 50191 50192 50193 # Execute function body 50194 50195 # Need to assign to a variable since m4 is blocked from modifying parts in []. 50196 REFERENCE_VERSION=4.8 50197 50198 if [[ "$REFERENCE_VERSION" =~ (.*\.){3} ]] ; then 50199 as_fn_error $? "Internal error: Cannot compare to 4.8, only three parts (X.Y.Z) is supported" "$LINENO" 5 50200 fi 50201 50202 if [[ "$REFERENCE_VERSION" =~ [0-9]{6} ]] ; then 50203 as_fn_error $? "Internal error: Cannot compare to 4.8, only parts < 99999 is supported" "$LINENO" 5 50204 fi 50205 50206 # Version comparison method inspired by http://stackoverflow.com/a/24067243 50207 COMPARABLE_REFERENCE_VERSION=`$AWK -F. '{ printf("%05d%05d%05d\n", $1, $2, $3) }' <<< "$REFERENCE_VERSION"` 50208 50209 if test $COMPARABLE_ACTUAL_VERSION -ge $COMPARABLE_REFERENCE_VERSION ; then 50210 : 50211 50212 # These flags either do not work or give spurious warnings prior to gcc 4.8. 50213 JVM_CFLAGS="$JVM_CFLAGS -Wno-format-zero-length -Wtype-limits -Wuninitialized" 50214 50215 50216 else 50217 : 50218 50219 fi 50220 50221 50222 50223 50224 50225 50226 50227 50228 50229 50230 50231 50232 50233 50234 fi 50235 if ! [[ " $JVM_VARIANTS " =~ " zero " ]] && ! [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 50236 # Non-zero builds have stricter warnings 50237 JVM_CFLAGS="$JVM_CFLAGS -Wreturn-type -Wundef -Wformat=2" 50238 else 50239 if test "x$TOOLCHAIN_TYPE" = xclang; then 50240 # Some versions of llvm do not like -Wundef 50241 JVM_CFLAGS="$JVM_CFLAGS -Wno-undef" 50242 fi 50243 fi 50244 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 50245 JVM_CFLAGS="$JVM_CFLAGS -Wno-deprecated -Wpointer-arith \ 50246 -Wsign-compare -Wundef -Wunused-function -Wformat=2" 50247 fi 50248 50249 # Additional macosx handling 50250 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 50251 # Setting these parameters makes it an error to link to macosx APIs that are 50252 # newer than the given OS version and makes the linked binaries compatible 50253 # even if built on a newer version of the OS. 50254 # The expected format is X.Y.Z 50255 MACOSX_VERSION_MIN=10.7.0 50256 50257 50258 # The macro takes the version with no dots, ex: 1070 50259 # Let the flags variables get resolved in make for easier override on make 50260 # command line. 50261 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DMAC_OS_X_VERSION_MAX_ALLOWED=\$(subst .,,\$(MACOSX_VERSION_MIN)) -mmacosx-version-min=\$(MACOSX_VERSION_MIN)" 50262 LDFLAGS_JDK="$LDFLAGS_JDK -mmacosx-version-min=\$(MACOSX_VERSION_MIN)" 50263 fi 50264 50265 # Setup some hard coded includes 50266 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK \ 50267 -I${JDK_TOPDIR}/src/java.base/share/native/include \ 50268 -I${JDK_TOPDIR}/src/java.base/$OPENJDK_TARGET_OS/native/include \ 50269 -I${JDK_TOPDIR}/src/java.base/$OPENJDK_TARGET_OS_TYPE/native/include \ 50270 -I${JDK_TOPDIR}/src/java.base/share/native/libjava \ 50271 -I${JDK_TOPDIR}/src/java.base/$OPENJDK_TARGET_OS_TYPE/native/libjava" 50272 50273 # The shared libraries are compiled using the picflag. 50274 CFLAGS_JDKLIB="$COMMON_CCXXFLAGS_JDK \ 50275 $CFLAGS_JDK $EXTRA_CFLAGS_JDK $PICFLAG $CFLAGS_JDKLIB_EXTRA" 50276 CXXFLAGS_JDKLIB="$COMMON_CCXXFLAGS_JDK \ 50277 $CXXFLAGS_JDK $EXTRA_CXXFLAGS_JDK $PICFLAG $CXXFLAGS_JDKLIB_EXTRA" 50278 50279 # Executable flags 50280 CFLAGS_JDKEXE="$COMMON_CCXXFLAGS_JDK $CFLAGS_JDK $EXTRA_CFLAGS_JDK" 50281 CXXFLAGS_JDKEXE="$COMMON_CCXXFLAGS_JDK $CXXFLAGS_JDK $EXTRA_CXXFLAGS_JDK" 50282 50283 50284 50285 50286 50287 50288 # Setup LDFLAGS et al. 50289 # 50290 50291 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 50292 LDFLAGS_MICROSOFT="-nologo -opt:ref" 50293 LDFLAGS_JDK="$LDFLAGS_JDK $LDFLAGS_MICROSOFT -incremental:no" 50294 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_MICROSOFT -opt:icf,8 -subsystem:windows -base:0x8000000" 50295 if test "x$OPENJDK_TARGET_CPU_BITS" = "x32"; then 50296 LDFLAGS_SAFESH="-safeseh" 50297 LDFLAGS_JDK="$LDFLAGS_JDK $LDFLAGS_SAFESH" 50298 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_SAFESH" 50299 # NOTE: Old build added -machine. Probably not needed. 50300 JVM_LDFLAGS="$JVM_LDFLAGS -machine:I386" 50301 else 50302 JVM_LDFLAGS="$JVM_LDFLAGS -machine:AMD64" 50303 fi 50304 elif test "x$TOOLCHAIN_TYPE" = xclang; then 50305 JVM_LDFLAGS="$JVM_LDFLAGS -mno-omit-leaf-frame-pointer -mstack-alignment=16 -stdlib=libstdc++ -fPIC" 50306 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 50307 # FIXME: We should really generalize SET_SHARED_LIBRARY_ORIGIN instead. 50308 JVM_LDFLAGS="$JVM_LDFLAGS -Wl,-rpath,@loader_path/. -Wl,-rpath,@loader_path/.." 50309 fi 50310 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 50311 # If this is a --hash-style=gnu system, use --hash-style=both, why? 50312 # We have previously set HAS_GNU_HASH if this is the case 50313 if test -n "$HAS_GNU_HASH"; then 50314 LDFLAGS_HASH_STYLE="-Wl,--hash-style=both" 50315 LDFLAGS_JDK="${LDFLAGS_JDK} $LDFLAGS_HASH_STYLE" 50316 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_HASH_STYLE" 50317 fi 50318 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 50319 JVM_LDFLAGS="$JVM_LDFLAGS -Wl,-rpath,@loader_path/. -Wl,-rpath,@loader_path/.." 50320 fi 50321 if test "x$OPENJDK_TARGET_OS" = xlinux; then 50322 # And since we now know that the linker is gnu, then add -z defs, to forbid 50323 # undefined symbols in object files. 50324 LDFLAGS_NO_UNDEF_SYM="-Wl,-z,defs" 50325 LDFLAGS_JDK="${LDFLAGS_JDK} $LDFLAGS_NO_UNDEF_SYM" 50326 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_NO_UNDEF_SYM" 50327 LDFLAGS_NO_EXEC_STACK="-Wl,-z,noexecstack" 50328 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_NO_EXEC_STACK" 50329 if test "x$OPENJDK_TARGET_CPU" = xx86; then 50330 JVM_LDFLAGS="$JVM_LDFLAGS -march=i586" 50331 fi 50332 case $DEBUG_LEVEL in 50333 release ) 50334 # tell linker to optimize libraries. 50335 # Should this be supplied to the OSS linker as well? 50336 LDFLAGS_DEBUGLEVEL_release="-Wl,-O1" 50337 LDFLAGS_JDK="${LDFLAGS_JDK} $LDFLAGS_DEBUGLEVEL_release" 50338 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_DEBUGLEVEL_release" 50339 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 50340 JVM_LDFLAGS="$JVM_LDFLAGS $LINKER_RELRO_FLAG" 50341 fi 50342 ;; 50343 slowdebug ) 50344 # Hotspot always let the linker optimize 50345 JVM_LDFLAGS="$JVM_LDFLAGS -Wl,-O1" 50346 if test "x$HAS_LINKER_NOW" = "xtrue"; then 50347 # do relocations at load 50348 LDFLAGS_JDK="$LDFLAGS_JDK $LINKER_NOW_FLAG" 50349 LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK $LINKER_NOW_FLAG" 50350 JVM_LDFLAGS="$JVM_LDFLAGS $LINKER_NOW_FLAG" 50351 fi 50352 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 50353 # mark relocations read only 50354 LDFLAGS_JDK="$LDFLAGS_JDK $LINKER_RELRO_FLAG" 50355 LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK $LINKER_RELRO_FLAG" 50356 JVM_LDFLAGS="$JVM_LDFLAGS $LINKER_RELRO_FLAG" 50357 fi 50358 ;; 50359 fastdebug ) 50360 # Hotspot always let the linker optimize 50361 JVM_LDFLAGS="$JVM_LDFLAGS -Wl,-O1" 50362 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 50363 # mark relocations read only 50364 LDFLAGS_JDK="$LDFLAGS_JDK $LINKER_RELRO_FLAG" 50365 LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK $LINKER_RELRO_FLAG" 50366 JVM_LDFLAGS="$JVM_LDFLAGS $LINKER_RELRO_FLAG" 50367 fi 50368 ;; 50369 * ) 50370 as_fn_error $? "Unrecognized \$DEBUG_LEVEL: $DEBUG_LEVEL" "$LINENO" 5 50371 ;; 50372 esac 50373 fi 50374 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 50375 LDFLAGS_SOLSTUDIO="-Wl,-z,defs" 50376 LDFLAGS_JDK="$LDFLAGS_JDK $LDFLAGS_SOLSTUDIO -ztext" 50377 LDFLAGS_CXX_SOLSTUDIO="-norunpath" 50378 LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK $LDFLAGS_CXX_SOLSTUDIO -xnolib" 50379 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_SOLSTUDIO -library=%none -mt $LDFLAGS_CXX_SOLSTUDIO -z noversion" 50380 if test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then 50381 JVM_LDFLAGS="$JVM_LDFLAGS -xarch=sparc" 50382 fi 50383 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 50384 LDFLAGS_XLC="-b64 -brtl -bnolibpath -bexpall -bernotok" 50385 LDFLAGS_JDK="${LDFLAGS_JDK} $LDFLAGS_XLC" 50386 JVM_LDFLAGS="$JVM_LDFLAGS $LDFLAGS_XLC" 50387 fi 50388 50389 # Customize LDFLAGS for executables 50390 50391 LDFLAGS_JDKEXE="${LDFLAGS_JDK}" 50392 50393 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 50394 if test "x$OPENJDK_TARGET_CPU_BITS" = "x64"; then 50395 LDFLAGS_STACK_SIZE=1048576 50396 else 50397 LDFLAGS_STACK_SIZE=327680 50398 fi 50399 LDFLAGS_JDKEXE="${LDFLAGS_JDKEXE} /STACK:$LDFLAGS_STACK_SIZE" 50400 elif test "x$OPENJDK_TARGET_OS" = xlinux; then 50401 LDFLAGS_JDKEXE="$LDFLAGS_JDKEXE -Wl,--allow-shlib-undefined" 50402 fi 50403 50404 LDFLAGS_JDKEXE="${LDFLAGS_JDKEXE} ${EXTRA_LDFLAGS_JDK}" 50405 50406 # Customize LDFLAGS for libs 50407 LDFLAGS_JDKLIB="${LDFLAGS_JDK}" 50408 50409 LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} ${SHARED_LIBRARY_FLAGS}" 50410 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 50411 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} \ 50412 -libpath:${OUTPUT_ROOT}/support/modules_libs/java.base" 50413 JDKLIB_LIBS="" 50414 else 50415 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} \ 50416 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_TARGET_CPU_LIBDIR)" 50417 50418 if test "xTARGET" = "xTARGET"; then 50419 # On some platforms (mac) the linker warns about non existing -L dirs. 50420 # Add server first if available. Linking aginst client does not always produce the same results. 50421 # Only add client/minimal dir if client/minimal is being built. 50422 # Default to server for other variants. 50423 if [[ " $JVM_VARIANTS " =~ " server " ]] ; then 50424 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_TARGET_CPU_LIBDIR)/server" 50425 elif [[ " $JVM_VARIANTS " =~ " client " ]] ; then 50426 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_TARGET_CPU_LIBDIR)/client" 50427 elif [[ " $JVM_VARIANTS " =~ " minimal " ]] ; then 50428 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_TARGET_CPU_LIBDIR)/minimal" 50429 else 50430 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_TARGET_CPU_LIBDIR)/server" 50431 fi 50432 elif test "xTARGET" = "xBUILD"; then 50433 # When building a buildjdk, it's always only the server variant 50434 JAVA_BASE_LDFLAGS="${JAVA_BASE_LDFLAGS} \ 50435 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_TARGET_CPU_LIBDIR)/server" 50436 fi 50437 50438 JDKLIB_LIBS="-ljava -ljvm" 50439 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 50440 JDKLIB_LIBS="$JDKLIB_LIBS -lc" 50441 fi 50442 50443 fi 50444 50445 LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} ${JAVA_BASE_LDFLAGS}" 50446 50447 # Set JVM_LIBS (per os) 50448 if test "x$OPENJDK_TARGET_OS" = xlinux; then 50449 JVM_LIBS="$JVM_LIBS -lm -ldl -lpthread" 50450 elif test "x$OPENJDK_TARGET_OS" = xsolaris; then 50451 # FIXME: This hard-coded path is not really proper. 50452 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 50453 SOLARIS_LIBM_LIBS="/usr/lib/amd64/libm.so.1" 50454 elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then 50455 SOLARIS_LIBM_LIBS="/usr/lib/sparcv9/libm.so.1" 50456 fi 50457 JVM_LIBS="$JVM_LIBS -lsocket -lsched -ldl $SOLARIS_LIBM_LIBS -lCrun \ 50458 -lthread -ldoor -lc -ldemangle -lnsl -lkstat -lrt" 50459 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 50460 JVM_LIBS="$JVM_LIBS -lm" 50461 elif test "x$OPENJDK_TARGET_OS" = xaix; then 50462 JVM_LIBS="$JVM_LIBS -Wl,-lC_r -lm -ldl -lpthread" 50463 elif test "x$OPENJDK_TARGET_OS" = xbsd; then 50464 JVM_LIBS="$JVM_LIBS -lm" 50465 elif test "x$OPENJDK_TARGET_OS" = xwindows; then 50466 JVM_LIBS="$JVM_LIBS kernel32.lib user32.lib gdi32.lib winspool.lib \ 50467 comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib \ 50468 wsock32.lib winmm.lib version.lib psapi.lib" 50469 fi 50470 50471 # Set JVM_ASFLAGS 50472 if test "x$OPENJDK_TARGET_OS" = xlinux; then 50473 if test "x$OPENJDK_TARGET_CPU" = xx86; then 50474 JVM_ASFLAGS="$JVM_ASFLAGS -march=i586" 50475 fi 50476 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 50477 JVM_ASFLAGS="$JVM_ASFLAGS -x assembler-with-cpp -mno-omit-leaf-frame-pointer -mstack-alignment=16" 50478 fi 50479 50480 LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} ${EXTRA_LDFLAGS_JDK}" 50481 50482 50483 50484 50485 50486 50487 50488 50489 50490 50491 50492 50493 50494 50495 50496 # Special extras... 50497 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 50498 if test "x$OPENJDK_BUILD_CPU_ARCH" = "xsparc"; then 50499 OPENJDK_BUILD_CFLAGS_JDKLIB_EXTRA="${OPENJDK_BUILD_CFLAGS_JDKLIB_EXTRA} -xregs=no%appl" 50500 OPENJDK_BUILD_CXXFLAGS_JDKLIB_EXTRA="${OPENJDK_BUILD_CXXFLAGS_JDKLIB_EXTRA} -xregs=no%appl" 50501 fi 50502 OPENJDK_BUILD_CFLAGS_JDKLIB_EXTRA="${OPENJDK_BUILD_CFLAGS_JDKLIB_EXTRA} -errtags=yes -errfmt" 50503 OPENJDK_BUILD_CXXFLAGS_JDKLIB_EXTRA="${OPENJDK_BUILD_CXXFLAGS_JDKLIB_EXTRA} -errtags=yes -errfmt" 50504 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 50505 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -qchars=signed -qfullpath -qsaveopt" 50506 OPENJDK_BUILD_CXXFLAGS_JDK="${OPENJDK_BUILD_CXXFLAGS_JDK} -qchars=signed -qfullpath -qsaveopt" 50507 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 50508 OPENJDK_BUILD_CXXSTD_CXXFLAG="-std=gnu++98" 50509 50510 50511 50512 50513 50514 50515 50516 50517 50518 50519 50520 50521 50522 50523 50524 50525 50526 50527 50528 50529 50530 50531 50532 50533 50534 50535 50536 50537 50538 50539 50540 50541 50542 50543 50544 50545 50546 50547 50548 50549 50550 50551 # Execute function body 50552 50553 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"$OPENJDK_BUILD_CXXSTD_CXXFLAG -Werror\"" >&5 50554 $as_echo_n "checking if the C++ compiler supports \"$OPENJDK_BUILD_CXXSTD_CXXFLAG -Werror\"... " >&6; } 50555 supports=yes 50556 50557 saved_cxxflags="$CXXFLAGS" 50558 CXXFLAGS="$CXXFLAG $OPENJDK_BUILD_CXXSTD_CXXFLAG -Werror" 50559 ac_ext=cpp 50560 ac_cpp='$CXXCPP $CPPFLAGS' 50561 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 50562 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 50563 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 50564 50565 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 50566 /* end confdefs.h. */ 50567 int i; 50568 _ACEOF 50569 if ac_fn_cxx_try_compile "$LINENO"; then : 50570 50571 else 50572 supports=no 50573 fi 50574 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 50575 ac_ext=cpp 50576 ac_cpp='$CXXCPP $CPPFLAGS' 50577 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 50578 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 50579 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 50580 50581 CXXFLAGS="$saved_cxxflags" 50582 50583 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 50584 $as_echo "$supports" >&6; } 50585 if test "x$supports" = "xyes" ; then 50586 : 50587 50588 else 50589 : 50590 OPENJDK_BUILD_CXXSTD_CXXFLAG="" 50591 fi 50592 50593 50594 50595 50596 50597 50598 50599 50600 50601 50602 50603 50604 OPENJDK_BUILD_CXXFLAGS_JDK="${OPENJDK_BUILD_CXXFLAGS_JDK} ${OPENJDK_BUILD_CXXSTD_CXXFLAG}" 50605 OPENJDK_BUILD_JVM_CFLAGS="${OPENJDK_BUILD_JVM_CFLAGS} ${OPENJDK_BUILD_CXXSTD_CXXFLAG}" 50606 50607 fi 50608 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 50609 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -D__solaris__" 50610 OPENJDK_BUILD_CXXFLAGS_JDK="${OPENJDK_BUILD_CXXFLAGS_JDK} -D__solaris__" 50611 fi 50612 50613 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 50614 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -D__solaris__" 50615 OPENJDK_BUILD_CXXFLAGS_JDK="${OPENJDK_BUILD_CXXFLAGS_JDK} -D__solaris__" 50616 fi 50617 50618 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} ${OPENJDK_BUILD_EXTRA_CFLAGS}" 50619 OPENJDK_BUILD_CXXFLAGS_JDK="${OPENJDK_BUILD_CXXFLAGS_JDK} ${OPENJDK_BUILD_EXTRA_CXXFLAGS}" 50620 OPENJDK_BUILD_LDFLAGS_JDK="${OPENJDK_BUILD_LDFLAGS_JDK} ${OPENJDK_BUILD_EXTRA_LDFLAGS}" 50621 50622 ############################################################################### 50623 # 50624 # Now setup the CFLAGS and LDFLAGS for the JDK build. 50625 # Later we will also have CFLAGS and LDFLAGS for the hotspot subrepo build. 50626 # 50627 50628 # Setup compiler/platform specific flags into 50629 # OPENJDK_BUILD_CFLAGS_JDK - C Compiler flags 50630 # OPENJDK_BUILD_CXXFLAGS_JDK - C++ Compiler flags 50631 # OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK - common to C and C++ 50632 if test "x$TOOLCHAIN_TYPE" = xgcc; then 50633 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_GNU_SOURCE" 50634 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_REENTRANT" 50635 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -fcheck-new" 50636 if test "x$OPENJDK_BUILD_CPU" = xx86; then 50637 # Force compatibility with i586 on 32 bit intel platforms. 50638 OPENJDK_BUILD_COMMON_CCXXFLAGS="${OPENJDK_BUILD_COMMON_CCXXFLAGS} -march=i586" 50639 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -march=i586" 50640 fi 50641 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS $OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -Wall -Wextra -Wno-unused -Wno-unused-parameter -Wformat=2 \ 50642 -pipe -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE" 50643 case $OPENJDK_BUILD_CPU_ARCH in 50644 arm ) 50645 # on arm we don't prevent gcc to omit frame pointer but do prevent strict aliasing 50646 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 50647 ;; 50648 ppc ) 50649 # on ppc we don't prevent gcc to omit frame pointer but do prevent strict aliasing 50650 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 50651 ;; 50652 * ) 50653 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer" 50654 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 50655 ;; 50656 esac 50657 50658 50659 50660 50661 50662 50663 50664 50665 50666 50667 50668 50669 50670 50671 50672 50673 50674 50675 50676 50677 50678 50679 50680 50681 50682 50683 50684 50685 50686 50687 50688 50689 50690 50691 50692 50693 50694 50695 50696 50697 50698 50699 50700 50701 50702 50703 50704 50705 50706 50707 50708 50709 50710 50711 # Execute function body 50712 50713 # Need to assign to a variable since m4 is blocked from modifying parts in []. 50714 REFERENCE_VERSION=6 50715 50716 if [[ "$REFERENCE_VERSION" =~ (.*\.){3} ]] ; then 50717 as_fn_error $? "Internal error: Cannot compare to 6, only three parts (X.Y.Z) is supported" "$LINENO" 5 50718 fi 50719 50720 if [[ "$REFERENCE_VERSION" =~ [0-9]{6} ]] ; then 50721 as_fn_error $? "Internal error: Cannot compare to 6, only parts < 99999 is supported" "$LINENO" 5 50722 fi 50723 50724 # Version comparison method inspired by http://stackoverflow.com/a/24067243 50725 COMPARABLE_REFERENCE_VERSION=`$AWK -F. '{ printf("%05d%05d%05d\n", $1, $2, $3) }' <<< "$REFERENCE_VERSION"` 50726 50727 if test $OPENJDK_BUILD_COMPARABLE_ACTUAL_VERSION -ge $COMPARABLE_REFERENCE_VERSION ; then 50728 : 50729 50730 # These flags are required for GCC 6 builds as undefined behaviour in OpenJDK code 50731 # runs afoul of the more aggressive versions of these optimisations. 50732 # Notably, value range propagation now assumes that the this pointer of C++ 50733 # member functions is non-null. 50734 NO_DELETE_NULL_POINTER_CHECKS_CFLAG="-fno-delete-null-pointer-checks" 50735 NO_LIFETIME_DSE_CFLAG="-fno-lifetime-dse" 50736 { $as_echo "$as_me:${as_lineno-$LINENO}: GCC >= 6 detected; adding ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} and ${NO_LIFETIME_DSE_CFLAG}" >&5 50737 $as_echo "$as_me: GCC >= 6 detected; adding ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} and ${NO_LIFETIME_DSE_CFLAG}" >&6;} 50738 OPENJDK_BUILD_CFLAGS_JDK="$OPENJDK_BUILD_CFLAGS_JDK ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} ${NO_LIFETIME_DSE_CFLAG}" 50739 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS ${NO_DELETE_NULL_POINTER_CHECKS_CFLAG} ${NO_LIFETIME_DSE_CFLAG}" 50740 50741 else 50742 : 50743 50744 fi 50745 50746 50747 50748 50749 50750 50751 50752 50753 50754 50755 50756 50757 50758 50759 elif test "x$TOOLCHAIN_TYPE" = xclang; then 50760 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_GNU_SOURCE" 50761 50762 # Restrict the debug information created by Clang to avoid 50763 # too big object files and speed the build up a little bit 50764 # (see http://llvm.org/bugs/show_bug.cgi?id=7554) 50765 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -flimit-debug-info" 50766 if test "x$OPENJDK_BUILD_OS" = xlinux; then 50767 if test "x$OPENJDK_BUILD_CPU" = xx86; then 50768 # Force compatibility with i586 on 32 bit intel platforms. 50769 OPENJDK_BUILD_COMMON_CCXXFLAGS="${OPENJDK_BUILD_COMMON_CCXXFLAGS} -march=i586" 50770 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -march=i586" 50771 fi 50772 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wno-sometimes-uninitialized" 50773 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS $OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -Wall -Wextra -Wno-unused -Wno-unused-parameter -Wformat=2 \ 50774 -pipe -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE" 50775 case $OPENJDK_BUILD_CPU_ARCH in 50776 ppc ) 50777 # on ppc we don't prevent gcc to omit frame pointer but do prevent strict aliasing 50778 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 50779 ;; 50780 * ) 50781 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer" 50782 OPENJDK_BUILD_CFLAGS_JDK="${OPENJDK_BUILD_CFLAGS_JDK} -fno-strict-aliasing" 50783 ;; 50784 esac 50785 fi 50786 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 50787 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DSPARC_WORKS" 50788 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS $OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DTRACING -DMACRO_MEMSYS_OPS -DBREAKPTS" 50789 if test "x$OPENJDK_BUILD_CPU_ARCH" = xx86; then 50790 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DcpuIntel -Di586 -D$OPENJDK_BUILD_CPU_LEGACY_LIB" 50791 fi 50792 50793 OPENJDK_BUILD_CFLAGS_JDK="$OPENJDK_BUILD_CFLAGS_JDK -xc99=%none -xCC -errshort=tags -Xa -v -mt -W0,-noglobal" 50794 OPENJDK_BUILD_CXXFLAGS_JDK="$OPENJDK_BUILD_CXXFLAGS_JDK -errtags=yes +w -mt -features=no%except -DCC_NOEX -norunpath -xnolib" 50795 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 50796 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_REENTRANT -D__STDC_FORMAT_MACROS" 50797 OPENJDK_BUILD_CFLAGS_JDK="$OPENJDK_BUILD_CFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC" 50798 OPENJDK_BUILD_CXXFLAGS_JDK="$OPENJDK_BUILD_CXXFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC" 50799 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 50800 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS $OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 50801 -MD -Zc:wchar_t- -W3 -wd4800 \ 50802 -DWIN32_LEAN_AND_MEAN \ 50803 -D_CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE \ 50804 -D_WINSOCK_DEPRECATED_NO_WARNINGS \ 50805 -DWIN32 -DIAL" 50806 if test "x$OPENJDK_BUILD_CPU" = xx86_64; then 50807 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_AMD64_ -Damd64" 50808 else 50809 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_X86_ -Dx86" 50810 fi 50811 # If building with Visual Studio 2010, we can still use _STATIC_CPPLIB to 50812 # avoid bundling msvcpNNN.dll. Doesn't work with newer versions of visual 50813 # studio. 50814 if test "x$TOOLCHAIN_VERSION" = "x2010"; then 50815 STATIC_CPPLIB_FLAGS="-D_STATIC_CPPLIB -D_DISABLE_DEPRECATE_STATIC_CPPLIB" 50816 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK $STATIC_CPPLIB_FLAGS" 50817 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS $STATIC_CPPLIB_FLAGS" 50818 fi 50819 fi 50820 50821 ############################################################################### 50822 50823 # Adjust flags according to debug level. 50824 case $DEBUG_LEVEL in 50825 fastdebug | slowdebug ) 50826 OPENJDK_BUILD_CFLAGS_JDK="$OPENJDK_BUILD_CFLAGS_JDK $CFLAGS_DEBUG_SYMBOLS $CFLAGS_DEBUG_OPTIONS" 50827 OPENJDK_BUILD_CXXFLAGS_JDK="$OPENJDK_BUILD_CXXFLAGS_JDK $CXXFLAGS_DEBUG_SYMBOLS $CXXFLAGS_DEBUG_OPTIONS" 50828 JAVAC_FLAGS="$JAVAC_FLAGS -g" 50829 ;; 50830 release ) 50831 ;; 50832 * ) 50833 as_fn_error $? "Unrecognized \$DEBUG_LEVEL: $DEBUG_LEVEL" "$LINENO" 5 50834 ;; 50835 esac 50836 50837 # Set some common defines. These works for all compilers, but assume 50838 # -D is universally accepted. 50839 50840 # Setup endianness 50841 if test "x$OPENJDK_BUILD_CPU_ENDIAN" = xlittle; then 50842 # The macro _LITTLE_ENDIAN needs to be defined the same to avoid the 50843 # Sun C compiler warning message: warning: macro redefined: _LITTLE_ENDIAN 50844 # (The Solaris X86 system defines this in file /usr/include/sys/isa_defs.h). 50845 # Note: -Dmacro is the same as #define macro 1 50846 # -Dmacro= is the same as #define macro 50847 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 50848 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_LITTLE_ENDIAN=" 50849 else 50850 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_LITTLE_ENDIAN" 50851 fi 50852 else 50853 # Same goes for _BIG_ENDIAN. Do we really need to set *ENDIAN on Solaris if they 50854 # are defined in the system? 50855 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 50856 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_BIG_ENDIAN=" 50857 else 50858 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_BIG_ENDIAN" 50859 fi 50860 fi 50861 50862 # Setup target OS define. Use OS target name but in upper case. 50863 OPENJDK_BUILD_OS_UPPERCASE=`$ECHO $OPENJDK_BUILD_OS | $TR 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` 50864 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D$OPENJDK_BUILD_OS_UPPERCASE" 50865 50866 # Setup target CPU 50867 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 50868 $OPENJDK_BUILD_ADD_LP64 \ 50869 -DARCH='\"$OPENJDK_BUILD_CPU_LEGACY\"' -D$OPENJDK_BUILD_CPU_LEGACY" 50870 50871 # Setup debug/release defines 50872 if test "x$DEBUG_LEVEL" = xrelease; then 50873 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DNDEBUG" 50874 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 50875 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DTRIMMED" 50876 fi 50877 else 50878 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -DDEBUG" 50879 fi 50880 50881 # Set some additional per-OS defines. 50882 if test "x$OPENJDK_BUILD_OS" = xlinux; then 50883 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DLINUX" 50884 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -pipe -fPIC -fno-rtti -fno-exceptions \ 50885 -fvisibility=hidden -fno-strict-aliasing -fno-omit-frame-pointer" 50886 elif test "x$OPENJDK_BUILD_OS" = xsolaris; then 50887 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DSOLARIS" 50888 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -template=no%extdef -features=no%split_init \ 50889 -D_Crun_inline_placement -library=%none -KPIC -mt -xwe -features=no%except" 50890 elif test "x$OPENJDK_BUILD_OS" = xmacosx; then 50891 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE -D_DARWIN_UNLIMITED_SELECT" 50892 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_ALLBSD_SOURCE" 50893 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_DARWIN_C_SOURCE -D_XOPEN_SOURCE" 50894 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -fno-rtti -fno-exceptions -fvisibility=hidden \ 50895 -mno-omit-leaf-frame-pointer -mstack-alignment=16 -pipe -fno-strict-aliasing \ 50896 -DMAC_OS_X_VERSION_MAX_ALLOWED=1070 -mmacosx-version-min=10.7.0 \ 50897 -fno-omit-frame-pointer" 50898 elif test "x$OPENJDK_BUILD_OS" = xaix; then 50899 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DAIX" 50900 # We may need '-qminimaltoc' or '-qpic=large -bbigtoc' if the TOC overflows. 50901 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -qtune=balanced \ 50902 -qalias=noansi -qstrict -qtls=default -qlanglvl=c99vla \ 50903 -qlanglvl=noredefmac -qnortti -qnoeh -qignerrno" 50904 elif test "x$OPENJDK_BUILD_OS" = xbsd; then 50905 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE" 50906 elif test "x$OPENJDK_BUILD_OS" = xwindows; then 50907 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_WINDOWS -DWIN32 -D_JNI_IMPLEMENTATION_" 50908 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -nologo -W3 -MD -MP" 50909 fi 50910 50911 # Set some additional per-CPU defines. 50912 if test "x$OPENJDK_BUILD_OS-$OPENJDK_BUILD_CPU" = xwindows-x86; then 50913 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -arch:IA32" 50914 elif test "x$OPENJDK_BUILD_CPU" = xsparcv9; then 50915 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -xarch=sparc" 50916 elif test "x$OPENJDK_BUILD_CPU" = xppc64; then 50917 if test "x$OPENJDK_BUILD_OS" = xlinux; then 50918 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -minsert-sched-nops=regroup_exact -mno-multiple -mno-string" 50919 # fixes `relocation truncated to fit' error for gcc 4.1. 50920 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -mminimal-toc" 50921 # Use ppc64 instructions, but schedule for power5 50922 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -mcpu=powerpc64 -mtune=power5" 50923 elif test "x$OPENJDK_BUILD_OS" = xaix; then 50924 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -qarch=ppc64" 50925 fi 50926 elif test "x$OPENJDK_BUILD_CPU" = xppc64le; then 50927 if test "x$OPENJDK_BUILD_OS" = xlinux; then 50928 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -minsert-sched-nops=regroup_exact -mno-multiple -mno-string" 50929 # Little endian machine uses ELFv2 ABI. 50930 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DABI_ELFv2" 50931 # Use Power8, this is the first CPU to support PPC64 LE with ELFv2 ABI. 50932 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -mcpu=power7 -mtune=power8" 50933 fi 50934 fi 50935 50936 if test "x$OPENJDK_BUILD_CPU_ENDIAN" = xlittle; then 50937 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -DVM_LITTLE_ENDIAN" 50938 fi 50939 50940 if test "x$OPENJDK_BUILD_CPU_BITS" = x64; then 50941 if test "x$OPENJDK_BUILD_OS" != xsolaris && test "x$OPENJDK_BUILD_OS" != xaix; then 50942 # Solaris does not have _LP64=1 in the old build. 50943 # xlc on AIX defines _LP64=1 by default and issues a warning if we redefine it. 50944 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -D_LP64=1" 50945 fi 50946 fi 50947 50948 # Set OPENJDK_BUILD_JVM_CFLAGS warning handling 50949 if test "x$OPENJDK_BUILD_OS" = xlinux; then 50950 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wpointer-arith -Wsign-compare -Wunused-function \ 50951 -Wunused-value -Woverloaded-virtual" 50952 50953 if test "x$TOOLCHAIN_TYPE" = xgcc; then 50954 50955 50956 50957 50958 50959 50960 50961 50962 50963 50964 50965 50966 50967 50968 50969 50970 50971 50972 50973 50974 50975 50976 50977 50978 50979 50980 50981 50982 50983 50984 50985 50986 50987 50988 50989 50990 50991 50992 50993 50994 50995 50996 50997 50998 50999 51000 51001 51002 51003 51004 51005 51006 51007 51008 # Execute function body 51009 51010 # Need to assign to a variable since m4 is blocked from modifying parts in []. 51011 REFERENCE_VERSION=4.8 51012 51013 if [[ "$REFERENCE_VERSION" =~ (.*\.){3} ]] ; then 51014 as_fn_error $? "Internal error: Cannot compare to 4.8, only three parts (X.Y.Z) is supported" "$LINENO" 5 51015 fi 51016 51017 if [[ "$REFERENCE_VERSION" =~ [0-9]{6} ]] ; then 51018 as_fn_error $? "Internal error: Cannot compare to 4.8, only parts < 99999 is supported" "$LINENO" 5 51019 fi 51020 51021 # Version comparison method inspired by http://stackoverflow.com/a/24067243 51022 COMPARABLE_REFERENCE_VERSION=`$AWK -F. '{ printf("%05d%05d%05d\n", $1, $2, $3) }' <<< "$REFERENCE_VERSION"` 51023 51024 if test $OPENJDK_BUILD_COMPARABLE_ACTUAL_VERSION -ge $COMPARABLE_REFERENCE_VERSION ; then 51025 : 51026 51027 # These flags either do not work or give spurious warnings prior to gcc 4.8. 51028 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wno-format-zero-length -Wtype-limits -Wuninitialized" 51029 51030 51031 else 51032 : 51033 51034 fi 51035 51036 51037 51038 51039 51040 51041 51042 51043 51044 51045 51046 51047 51048 51049 fi 51050 if ! [[ " $JVM_VARIANTS " =~ " zero " ]] && ! [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 51051 # Non-zero builds have stricter warnings 51052 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wreturn-type -Wundef -Wformat=2" 51053 else 51054 if test "x$TOOLCHAIN_TYPE" = xclang; then 51055 # Some versions of llvm do not like -Wundef 51056 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wno-undef" 51057 fi 51058 fi 51059 elif test "x$OPENJDK_BUILD_OS" = xmacosx; then 51060 OPENJDK_BUILD_JVM_CFLAGS="$OPENJDK_BUILD_JVM_CFLAGS -Wno-deprecated -Wpointer-arith \ 51061 -Wsign-compare -Wundef -Wunused-function -Wformat=2" 51062 fi 51063 51064 # Additional macosx handling 51065 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 51066 # Setting these parameters makes it an error to link to macosx APIs that are 51067 # newer than the given OS version and makes the linked binaries compatible 51068 # even if built on a newer version of the OS. 51069 # The expected format is X.Y.Z 51070 MACOSX_VERSION_MIN=10.7.0 51071 51072 51073 # The macro takes the version with no dots, ex: 1070 51074 # Let the flags variables get resolved in make for easier override on make 51075 # command line. 51076 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)" 51077 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK -mmacosx-version-min=\$(MACOSX_VERSION_MIN)" 51078 fi 51079 51080 # Setup some hard coded includes 51081 OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 51082 -I${JDK_TOPDIR}/src/java.base/share/native/include \ 51083 -I${JDK_TOPDIR}/src/java.base/$OPENJDK_BUILD_OS/native/include \ 51084 -I${JDK_TOPDIR}/src/java.base/$OPENJDK_BUILD_OS_TYPE/native/include \ 51085 -I${JDK_TOPDIR}/src/java.base/share/native/libjava \ 51086 -I${JDK_TOPDIR}/src/java.base/$OPENJDK_BUILD_OS_TYPE/native/libjava" 51087 51088 # The shared libraries are compiled using the picflag. 51089 OPENJDK_BUILD_CFLAGS_JDKLIB="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 51090 $OPENJDK_BUILD_CFLAGS_JDK $OPENJDK_BUILD_EXTRA_CFLAGS_JDK $PICFLAG $OPENJDK_BUILD_CFLAGS_JDKLIB_EXTRA" 51091 OPENJDK_BUILD_CXXFLAGS_JDKLIB="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK \ 51092 $OPENJDK_BUILD_CXXFLAGS_JDK $OPENJDK_BUILD_EXTRA_CXXFLAGS_JDK $PICFLAG $OPENJDK_BUILD_CXXFLAGS_JDKLIB_EXTRA" 51093 51094 # Executable flags 51095 OPENJDK_BUILD_CFLAGS_JDKEXE="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK $OPENJDK_BUILD_CFLAGS_JDK $OPENJDK_BUILD_EXTRA_CFLAGS_JDK" 51096 OPENJDK_BUILD_CXXFLAGS_JDKEXE="$OPENJDK_BUILD_COMMON_CCXXFLAGS_JDK $OPENJDK_BUILD_CXXFLAGS_JDK $OPENJDK_BUILD_EXTRA_CXXFLAGS_JDK" 51097 51098 51099 51100 51101 51102 51103 # Setup LDFLAGS et al. 51104 # 51105 51106 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 51107 LDFLAGS_MICROSOFT="-nologo -opt:ref" 51108 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LDFLAGS_MICROSOFT -incremental:no" 51109 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_MICROSOFT -opt:icf,8 -subsystem:windows -base:0x8000000" 51110 if test "x$OPENJDK_BUILD_CPU_BITS" = "x32"; then 51111 LDFLAGS_SAFESH="-safeseh" 51112 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LDFLAGS_SAFESH" 51113 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_SAFESH" 51114 # NOTE: Old build added -machine. Probably not needed. 51115 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -machine:I386" 51116 else 51117 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -machine:AMD64" 51118 fi 51119 elif test "x$TOOLCHAIN_TYPE" = xclang; then 51120 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -mno-omit-leaf-frame-pointer -mstack-alignment=16 -stdlib=libstdc++ -fPIC" 51121 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 51122 # FIXME: We should really generalize SET_SHARED_LIBRARY_ORIGIN instead. 51123 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -Wl,-rpath,@loader_path/. -Wl,-rpath,@loader_path/.." 51124 fi 51125 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 51126 # If this is a --hash-style=gnu system, use --hash-style=both, why? 51127 # We have previously set HAS_GNU_HASH if this is the case 51128 if test -n "$HAS_GNU_HASH"; then 51129 OPENJDK_BUILD_LDFLAGS_HASH_STYLE="-Wl,--hash-style=both" 51130 OPENJDK_BUILD_LDFLAGS_JDK="${OPENJDK_BUILD_LDFLAGS_JDK} $OPENJDK_BUILD_LDFLAGS_HASH_STYLE" 51131 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $OPENJDK_BUILD_LDFLAGS_HASH_STYLE" 51132 fi 51133 if test "x$OPENJDK_BUILD_OS" = xmacosx; then 51134 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -Wl,-rpath,@loader_path/. -Wl,-rpath,@loader_path/.." 51135 fi 51136 if test "x$OPENJDK_BUILD_OS" = xlinux; then 51137 # And since we now know that the linker is gnu, then add -z defs, to forbid 51138 # undefined symbols in object files. 51139 LDFLAGS_NO_UNDEF_SYM="-Wl,-z,defs" 51140 OPENJDK_BUILD_LDFLAGS_JDK="${OPENJDK_BUILD_LDFLAGS_JDK} $LDFLAGS_NO_UNDEF_SYM" 51141 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_NO_UNDEF_SYM" 51142 LDFLAGS_NO_EXEC_STACK="-Wl,-z,noexecstack" 51143 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_NO_EXEC_STACK" 51144 if test "x$OPENJDK_BUILD_CPU" = xx86; then 51145 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -march=i586" 51146 fi 51147 case $DEBUG_LEVEL in 51148 release ) 51149 # tell linker to optimize libraries. 51150 # Should this be supplied to the OSS linker as well? 51151 LDFLAGS_DEBUGLEVEL_release="-Wl,-O1" 51152 OPENJDK_BUILD_LDFLAGS_JDK="${OPENJDK_BUILD_LDFLAGS_JDK} $LDFLAGS_DEBUGLEVEL_release" 51153 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_DEBUGLEVEL_release" 51154 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 51155 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LINKER_RELRO_FLAG" 51156 fi 51157 ;; 51158 slowdebug ) 51159 # Hotspot always let the linker optimize 51160 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -Wl,-O1" 51161 if test "x$HAS_LINKER_NOW" = "xtrue"; then 51162 # do relocations at load 51163 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LINKER_NOW_FLAG" 51164 OPENJDK_BUILD_LDFLAGS_CXX_JDK="$OPENJDK_BUILD_LDFLAGS_CXX_JDK $LINKER_NOW_FLAG" 51165 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LINKER_NOW_FLAG" 51166 fi 51167 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 51168 # mark relocations read only 51169 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LINKER_RELRO_FLAG" 51170 OPENJDK_BUILD_LDFLAGS_CXX_JDK="$OPENJDK_BUILD_LDFLAGS_CXX_JDK $LINKER_RELRO_FLAG" 51171 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LINKER_RELRO_FLAG" 51172 fi 51173 ;; 51174 fastdebug ) 51175 # Hotspot always let the linker optimize 51176 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -Wl,-O1" 51177 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 51178 # mark relocations read only 51179 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LINKER_RELRO_FLAG" 51180 OPENJDK_BUILD_LDFLAGS_CXX_JDK="$OPENJDK_BUILD_LDFLAGS_CXX_JDK $LINKER_RELRO_FLAG" 51181 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LINKER_RELRO_FLAG" 51182 fi 51183 ;; 51184 * ) 51185 as_fn_error $? "Unrecognized \$DEBUG_LEVEL: $DEBUG_LEVEL" "$LINENO" 5 51186 ;; 51187 esac 51188 fi 51189 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 51190 LDFLAGS_SOLSTUDIO="-Wl,-z,defs" 51191 OPENJDK_BUILD_LDFLAGS_JDK="$OPENJDK_BUILD_LDFLAGS_JDK $LDFLAGS_SOLSTUDIO -ztext" 51192 LDFLAGS_CXX_SOLSTUDIO="-norunpath" 51193 OPENJDK_BUILD_LDFLAGS_CXX_JDK="$OPENJDK_BUILD_LDFLAGS_CXX_JDK $LDFLAGS_CXX_SOLSTUDIO -xnolib" 51194 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_SOLSTUDIO -library=%none -mt $LDFLAGS_CXX_SOLSTUDIO -z noversion" 51195 if test "x$OPENJDK_BUILD_CPU_ARCH" = "xsparc"; then 51196 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS -xarch=sparc" 51197 fi 51198 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 51199 LDFLAGS_XLC="-b64 -brtl -bnolibpath -bexpall -bernotok" 51200 OPENJDK_BUILD_LDFLAGS_JDK="${OPENJDK_BUILD_LDFLAGS_JDK} $LDFLAGS_XLC" 51201 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $LDFLAGS_XLC" 51202 fi 51203 51204 # Customize LDFLAGS for executables 51205 51206 OPENJDK_BUILD_LDFLAGS_JDKEXE="${OPENJDK_BUILD_LDFLAGS_JDK}" 51207 51208 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 51209 if test "x$OPENJDK_BUILD_CPU_BITS" = "x64"; then 51210 LDFLAGS_STACK_SIZE=1048576 51211 else 51212 LDFLAGS_STACK_SIZE=327680 51213 fi 51214 OPENJDK_BUILD_LDFLAGS_JDKEXE="${OPENJDK_BUILD_LDFLAGS_JDKEXE} /STACK:$LDFLAGS_STACK_SIZE" 51215 elif test "x$OPENJDK_BUILD_OS" = xlinux; then 51216 OPENJDK_BUILD_LDFLAGS_JDKEXE="$OPENJDK_BUILD_LDFLAGS_JDKEXE -Wl,--allow-shlib-undefined" 51217 fi 51218 51219 OPENJDK_BUILD_LDFLAGS_JDKEXE="${OPENJDK_BUILD_LDFLAGS_JDKEXE} ${OPENJDK_BUILD_EXTRA_LDFLAGS_JDK}" 51220 51221 # Customize LDFLAGS for libs 51222 OPENJDK_BUILD_LDFLAGS_JDKLIB="${OPENJDK_BUILD_LDFLAGS_JDK}" 51223 51224 OPENJDK_BUILD_LDFLAGS_JDKLIB="${OPENJDK_BUILD_LDFLAGS_JDKLIB} ${SHARED_LIBRARY_FLAGS}" 51225 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 51226 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} \ 51227 -libpath:${OUTPUT_ROOT}/support/modules_libs/java.base" 51228 OPENJDK_BUILD_JDKLIB_LIBS="" 51229 else 51230 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} \ 51231 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_BUILD_CPU_LIBDIR)" 51232 51233 if test "xBUILD" = "xTARGET"; then 51234 # On some platforms (mac) the linker warns about non existing -L dirs. 51235 # Add server first if available. Linking aginst client does not always produce the same results. 51236 # Only add client/minimal dir if client/minimal is being built. 51237 # Default to server for other variants. 51238 if [[ " $JVM_VARIANTS " =~ " server " ]] ; then 51239 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_BUILD_CPU_LIBDIR)/server" 51240 elif [[ " $JVM_VARIANTS " =~ " client " ]] ; then 51241 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_BUILD_CPU_LIBDIR)/client" 51242 elif [[ " $JVM_VARIANTS " =~ " minimal " ]] ; then 51243 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_BUILD_CPU_LIBDIR)/minimal" 51244 else 51245 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_BUILD_CPU_LIBDIR)/server" 51246 fi 51247 elif test "xBUILD" = "xBUILD"; then 51248 # When building a buildjdk, it's always only the server variant 51249 OPENJDK_BUILD_JAVA_BASE_LDFLAGS="${OPENJDK_BUILD_JAVA_BASE_LDFLAGS} \ 51250 -L\$(SUPPORT_OUTPUTDIR)/modules_libs/java.base\$(OPENJDK_BUILD_CPU_LIBDIR)/server" 51251 fi 51252 51253 OPENJDK_BUILD_JDKLIB_LIBS="-ljava -ljvm" 51254 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 51255 OPENJDK_BUILD_JDKLIB_LIBS="$OPENJDK_BUILD_JDKLIB_LIBS -lc" 51256 fi 51257 51258 fi 51259 51260 OPENJDK_BUILD_LDFLAGS_JDKLIB="${OPENJDK_BUILD_LDFLAGS_JDKLIB} ${OPENJDK_BUILD_JAVA_BASE_LDFLAGS}" 51261 51262 # Set OPENJDK_BUILD_JVM_LIBS (per os) 51263 if test "x$OPENJDK_BUILD_OS" = xlinux; then 51264 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS -lm -ldl -lpthread" 51265 elif test "x$OPENJDK_BUILD_OS" = xsolaris; then 51266 # FIXME: This hard-coded path is not really proper. 51267 if test "x$OPENJDK_BUILD_CPU" = xx86_64; then 51268 OPENJDK_BUILD_SOLARIS_LIBM_LIBS="/usr/lib/amd64/libm.so.1" 51269 elif test "x$OPENJDK_BUILD_CPU" = xsparcv9; then 51270 OPENJDK_BUILD_SOLARIS_LIBM_LIBS="/usr/lib/sparcv9/libm.so.1" 51271 fi 51272 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS -lsocket -lsched -ldl $SOLARIS_LIBM_LIBS -lCrun \ 51273 -lthread -ldoor -lc -ldemangle -lnsl -lkstat -lrt" 51274 elif test "x$OPENJDK_BUILD_OS" = xmacosx; then 51275 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS -lm" 51276 elif test "x$OPENJDK_BUILD_OS" = xaix; then 51277 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS -Wl,-lC_r -lm -ldl -lpthread" 51278 elif test "x$OPENJDK_BUILD_OS" = xbsd; then 51279 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS -lm" 51280 elif test "x$OPENJDK_BUILD_OS" = xwindows; then 51281 OPENJDK_BUILD_JVM_LIBS="$OPENJDK_BUILD_JVM_LIBS kernel32.lib user32.lib gdi32.lib winspool.lib \ 51282 comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib \ 51283 wsock32.lib winmm.lib version.lib psapi.lib" 51284 fi 51285 51286 # Set OPENJDK_BUILD_JVM_ASFLAGS 51287 if test "x$OPENJDK_BUILD_OS" = xlinux; then 51288 if test "x$OPENJDK_BUILD_CPU" = xx86; then 51289 OPENJDK_BUILD_JVM_ASFLAGS="$OPENJDK_BUILD_JVM_ASFLAGS -march=i586" 51290 fi 51291 elif test "x$OPENJDK_BUILD_OS" = xmacosx; then 51292 OPENJDK_BUILD_JVM_ASFLAGS="$OPENJDK_BUILD_JVM_ASFLAGS -x assembler-with-cpp -mno-omit-leaf-frame-pointer -mstack-alignment=16" 51293 fi 51294 51295 OPENJDK_BUILD_LDFLAGS_JDKLIB="${OPENJDK_BUILD_LDFLAGS_JDKLIB} ${OPENJDK_BUILD_EXTRA_LDFLAGS_JDK}" 51296 51297 51298 51299 51300 51301 51302 51303 51304 51305 51306 51307 51308 51309 51310 51311 # Tests are only ever compiled for TARGET 51312 # Flags for compiling test libraries 51313 CFLAGS_TESTLIB="$COMMON_CCXXFLAGS_JDK $CFLAGS_JDK $PICFLAG $CFLAGS_JDKLIB_EXTRA" 51314 CXXFLAGS_TESTLIB="$COMMON_CCXXFLAGS_JDK $CXXFLAGS_JDK $PICFLAG $CXXFLAGS_JDKLIB_EXTRA" 51315 51316 # Flags for compiling test executables 51317 CFLAGS_TESTEXE="$COMMON_CCXXFLAGS_JDK $CFLAGS_JDK" 51318 CXXFLAGS_TESTEXE="$COMMON_CCXXFLAGS_JDK $CXXFLAGS_JDK" 51319 51320 51321 51322 51323 51324 51325 LDFLAGS_TESTLIB="$LDFLAGS_JDKLIB" 51326 LDFLAGS_TESTEXE="$LDFLAGS_JDKEXE $JAVA_BASE_LDFLAGS" 51327 51328 51329 51330 51331 51332 51333 # Some Zero and Shark settings. 51334 # ZERO_ARCHFLAG tells the compiler which mode to build for 51335 case "${OPENJDK_TARGET_CPU}" in 51336 s390) 51337 ZERO_ARCHFLAG="${COMPILER_TARGET_BITS_FLAG}31" 51338 ;; 51339 *) 51340 ZERO_ARCHFLAG="${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 51341 esac 51342 51343 51344 51345 51346 51347 51348 51349 51350 51351 51352 51353 51354 51355 51356 51357 51358 51359 51360 51361 51362 51363 51364 51365 51366 51367 51368 51369 51370 51371 51372 51373 51374 51375 51376 51377 51378 51379 51380 51381 51382 51383 51384 # Execute function body 51385 51386 51387 51388 51389 51390 51391 51392 51393 51394 51395 51396 51397 51398 51399 51400 51401 51402 51403 51404 51405 51406 51407 51408 51409 51410 51411 51412 51413 51414 51415 51416 51417 51418 51419 51420 51421 51422 51423 51424 51425 51426 51427 51428 51429 51430 51431 51432 51433 # Execute function body 51434 51435 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler supports \"$ZERO_ARCHFLAG\"" >&5 51436 $as_echo_n "checking if the C compiler supports \"$ZERO_ARCHFLAG\"... " >&6; } 51437 supports=yes 51438 51439 saved_cflags="$CFLAGS" 51440 CFLAGS="$CFLAGS $ZERO_ARCHFLAG" 51441 ac_ext=c 51442 ac_cpp='$CPP $CPPFLAGS' 51443 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51444 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51445 ac_compiler_gnu=$ac_cv_c_compiler_gnu 51446 51447 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51448 /* end confdefs.h. */ 51449 int i; 51450 _ACEOF 51451 if ac_fn_c_try_compile "$LINENO"; then : 51452 51453 else 51454 supports=no 51455 fi 51456 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 51457 ac_ext=cpp 51458 ac_cpp='$CXXCPP $CPPFLAGS' 51459 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51460 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51461 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 51462 51463 CFLAGS="$saved_cflags" 51464 51465 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 51466 $as_echo "$supports" >&6; } 51467 if test "x$supports" = "xyes" ; then 51468 : 51469 C_COMP_SUPPORTS="yes" 51470 else 51471 : 51472 C_COMP_SUPPORTS="no" 51473 fi 51474 51475 51476 51477 51478 51479 51480 51481 51482 51483 51484 51485 51486 51487 51488 51489 51490 51491 51492 51493 51494 51495 51496 51497 51498 51499 51500 51501 51502 51503 51504 51505 51506 51507 51508 51509 51510 51511 51512 51513 51514 51515 51516 51517 51518 51519 51520 51521 51522 51523 51524 51525 51526 51527 51528 51529 51530 51531 51532 51533 # Execute function body 51534 51535 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"$ZERO_ARCHFLAG\"" >&5 51536 $as_echo_n "checking if the C++ compiler supports \"$ZERO_ARCHFLAG\"... " >&6; } 51537 supports=yes 51538 51539 saved_cxxflags="$CXXFLAGS" 51540 CXXFLAGS="$CXXFLAG $ZERO_ARCHFLAG" 51541 ac_ext=cpp 51542 ac_cpp='$CXXCPP $CPPFLAGS' 51543 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51544 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51545 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 51546 51547 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51548 /* end confdefs.h. */ 51549 int i; 51550 _ACEOF 51551 if ac_fn_cxx_try_compile "$LINENO"; then : 51552 51553 else 51554 supports=no 51555 fi 51556 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 51557 ac_ext=cpp 51558 ac_cpp='$CXXCPP $CPPFLAGS' 51559 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51560 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51561 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 51562 51563 CXXFLAGS="$saved_cxxflags" 51564 51565 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 51566 $as_echo "$supports" >&6; } 51567 if test "x$supports" = "xyes" ; then 51568 : 51569 CXX_COMP_SUPPORTS="yes" 51570 else 51571 : 51572 CXX_COMP_SUPPORTS="no" 51573 fi 51574 51575 51576 51577 51578 51579 51580 51581 51582 51583 51584 51585 51586 51587 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"$ZERO_ARCHFLAG\"" >&5 51588 $as_echo_n "checking if both compilers support \"$ZERO_ARCHFLAG\"... " >&6; } 51589 supports=no 51590 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 51591 51592 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 51593 $as_echo "$supports" >&6; } 51594 if test "x$supports" = "xyes" ; then 51595 : 51596 51597 else 51598 : 51599 ZERO_ARCHFLAG="" 51600 fi 51601 51602 51603 51604 51605 51606 51607 51608 51609 # Check that the compiler supports -mX (or -qX on AIX) flags 51610 # Set COMPILER_SUPPORTS_TARGET_BITS_FLAG to 'true' if it does 51611 51612 51613 51614 51615 51616 51617 51618 51619 51620 51621 51622 51623 51624 51625 51626 51627 51628 51629 51630 51631 51632 51633 51634 51635 51636 51637 51638 51639 51640 51641 51642 51643 51644 51645 51646 51647 51648 51649 51650 51651 51652 51653 51654 51655 51656 51657 51658 # Execute function body 51659 51660 51661 51662 51663 51664 51665 51666 51667 51668 51669 51670 51671 51672 51673 51674 51675 51676 51677 51678 51679 51680 51681 51682 51683 51684 51685 51686 51687 51688 51689 51690 51691 51692 51693 51694 51695 51696 51697 51698 51699 51700 51701 51702 51703 51704 51705 51706 51707 # Execute function body 51708 51709 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"" >&5 51710 $as_echo_n "checking if the C compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"... " >&6; } 51711 supports=yes 51712 51713 saved_cflags="$CFLAGS" 51714 CFLAGS="$CFLAGS ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 51715 ac_ext=c 51716 ac_cpp='$CPP $CPPFLAGS' 51717 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51718 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51719 ac_compiler_gnu=$ac_cv_c_compiler_gnu 51720 51721 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51722 /* end confdefs.h. */ 51723 int i; 51724 _ACEOF 51725 if ac_fn_c_try_compile "$LINENO"; then : 51726 51727 else 51728 supports=no 51729 fi 51730 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 51731 ac_ext=cpp 51732 ac_cpp='$CXXCPP $CPPFLAGS' 51733 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51734 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51735 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 51736 51737 CFLAGS="$saved_cflags" 51738 51739 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 51740 $as_echo "$supports" >&6; } 51741 if test "x$supports" = "xyes" ; then 51742 : 51743 C_COMP_SUPPORTS="yes" 51744 else 51745 : 51746 C_COMP_SUPPORTS="no" 51747 fi 51748 51749 51750 51751 51752 51753 51754 51755 51756 51757 51758 51759 51760 51761 51762 51763 51764 51765 51766 51767 51768 51769 51770 51771 51772 51773 51774 51775 51776 51777 51778 51779 51780 51781 51782 51783 51784 51785 51786 51787 51788 51789 51790 51791 51792 51793 51794 51795 51796 51797 51798 51799 51800 51801 51802 51803 51804 51805 51806 51807 # Execute function body 51808 51809 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"" >&5 51810 $as_echo_n "checking if the C++ compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"... " >&6; } 51811 supports=yes 51812 51813 saved_cxxflags="$CXXFLAGS" 51814 CXXFLAGS="$CXXFLAG ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 51815 ac_ext=cpp 51816 ac_cpp='$CXXCPP $CPPFLAGS' 51817 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51818 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51819 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 51820 51821 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51822 /* end confdefs.h. */ 51823 int i; 51824 _ACEOF 51825 if ac_fn_cxx_try_compile "$LINENO"; then : 51826 51827 else 51828 supports=no 51829 fi 51830 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 51831 ac_ext=cpp 51832 ac_cpp='$CXXCPP $CPPFLAGS' 51833 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51834 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51835 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 51836 51837 CXXFLAGS="$saved_cxxflags" 51838 51839 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 51840 $as_echo "$supports" >&6; } 51841 if test "x$supports" = "xyes" ; then 51842 : 51843 CXX_COMP_SUPPORTS="yes" 51844 else 51845 : 51846 CXX_COMP_SUPPORTS="no" 51847 fi 51848 51849 51850 51851 51852 51853 51854 51855 51856 51857 51858 51859 51860 51861 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"" >&5 51862 $as_echo_n "checking if both compilers support \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"... " >&6; } 51863 supports=no 51864 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 51865 51866 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 51867 $as_echo "$supports" >&6; } 51868 if test "x$supports" = "xyes" ; then 51869 : 51870 COMPILER_SUPPORTS_TARGET_BITS_FLAG=true 51871 else 51872 : 51873 COMPILER_SUPPORTS_TARGET_BITS_FLAG=false 51874 fi 51875 51876 51877 51878 51879 51880 51881 51882 51883 # Check whether --enable-warnings-as-errors was given. 51884 if test "${enable_warnings_as_errors+set}" = set; then : 51885 enableval=$enable_warnings_as_errors; 51886 fi 51887 51888 51889 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if native warnings are errors" >&5 51890 $as_echo_n "checking if native warnings are errors... " >&6; } 51891 if test "x$enable_warnings_as_errors" = "xyes"; then 51892 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (explicitely set)" >&5 51893 $as_echo "yes (explicitely set)" >&6; } 51894 WARNINGS_AS_ERRORS=true 51895 elif test "x$enable_warnings_as_errors" = "xno"; then 51896 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 51897 $as_echo "no" >&6; } 51898 WARNINGS_AS_ERRORS=false 51899 elif test "x$enable_warnings_as_errors" = "x"; then 51900 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (default)" >&5 51901 $as_echo "yes (default)" >&6; } 51902 WARNINGS_AS_ERRORS=true 51903 else 51904 as_fn_error $? "--enable-warnings-as-errors accepts no argument" "$LINENO" 5 51905 fi 51906 51907 if test "x$WARNINGS_AS_ERRORS" = "xfalse"; then 51908 # Set legacy hotspot variable 51909 HOTSPOT_SET_WARNINGS_AS_ERRORS="WARNINGS_ARE_ERRORS=" 51910 else 51911 HOTSPOT_SET_WARNINGS_AS_ERRORS="" 51912 fi 51913 51914 51915 51916 51917 case "${TOOLCHAIN_TYPE}" in 51918 microsoft) 51919 DISABLE_WARNING_PREFIX="-wd" 51920 CFLAGS_WARNINGS_ARE_ERRORS="-WX" 51921 ;; 51922 solstudio) 51923 DISABLE_WARNING_PREFIX="-erroff=" 51924 CFLAGS_WARNINGS_ARE_ERRORS="-errtags -errwarn=%all" 51925 ;; 51926 gcc) 51927 # Prior to gcc 4.4, a -Wno-X where X is unknown for that version of gcc will cause an error 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 51968 51969 51970 51971 51972 51973 51974 51975 # Execute function body 51976 51977 51978 51979 51980 51981 51982 51983 51984 51985 51986 51987 51988 51989 51990 51991 51992 51993 51994 51995 51996 51997 51998 51999 52000 52001 52002 52003 52004 52005 52006 52007 52008 52009 52010 52011 52012 52013 52014 52015 52016 52017 52018 52019 52020 52021 52022 52023 52024 # Execute function body 52025 52026 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 52027 $as_echo_n "checking if the C compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 52028 supports=yes 52029 52030 saved_cflags="$CFLAGS" 52031 CFLAGS="$CFLAGS -Wno-this-is-a-warning-that-do-not-exist" 52032 ac_ext=c 52033 ac_cpp='$CPP $CPPFLAGS' 52034 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52035 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52036 ac_compiler_gnu=$ac_cv_c_compiler_gnu 52037 52038 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 52039 /* end confdefs.h. */ 52040 int i; 52041 _ACEOF 52042 if ac_fn_c_try_compile "$LINENO"; then : 52043 52044 else 52045 supports=no 52046 fi 52047 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 52048 ac_ext=cpp 52049 ac_cpp='$CXXCPP $CPPFLAGS' 52050 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52051 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52052 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 52053 52054 CFLAGS="$saved_cflags" 52055 52056 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 52057 $as_echo "$supports" >&6; } 52058 if test "x$supports" = "xyes" ; then 52059 : 52060 C_COMP_SUPPORTS="yes" 52061 else 52062 : 52063 C_COMP_SUPPORTS="no" 52064 fi 52065 52066 52067 52068 52069 52070 52071 52072 52073 52074 52075 52076 52077 52078 52079 52080 52081 52082 52083 52084 52085 52086 52087 52088 52089 52090 52091 52092 52093 52094 52095 52096 52097 52098 52099 52100 52101 52102 52103 52104 52105 52106 52107 52108 52109 52110 52111 52112 52113 52114 52115 52116 52117 52118 52119 52120 52121 52122 52123 52124 # Execute function body 52125 52126 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 52127 $as_echo_n "checking if the C++ compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 52128 supports=yes 52129 52130 saved_cxxflags="$CXXFLAGS" 52131 CXXFLAGS="$CXXFLAG -Wno-this-is-a-warning-that-do-not-exist" 52132 ac_ext=cpp 52133 ac_cpp='$CXXCPP $CPPFLAGS' 52134 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52135 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52136 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 52137 52138 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 52139 /* end confdefs.h. */ 52140 int i; 52141 _ACEOF 52142 if ac_fn_cxx_try_compile "$LINENO"; then : 52143 52144 else 52145 supports=no 52146 fi 52147 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 52148 ac_ext=cpp 52149 ac_cpp='$CXXCPP $CPPFLAGS' 52150 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52151 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52152 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 52153 52154 CXXFLAGS="$saved_cxxflags" 52155 52156 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 52157 $as_echo "$supports" >&6; } 52158 if test "x$supports" = "xyes" ; then 52159 : 52160 CXX_COMP_SUPPORTS="yes" 52161 else 52162 : 52163 CXX_COMP_SUPPORTS="no" 52164 fi 52165 52166 52167 52168 52169 52170 52171 52172 52173 52174 52175 52176 52177 52178 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 52179 $as_echo_n "checking if both compilers support \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 52180 supports=no 52181 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 52182 52183 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 52184 $as_echo "$supports" >&6; } 52185 if test "x$supports" = "xyes" ; then 52186 : 52187 GCC_CAN_DISABLE_WARNINGS=true 52188 else 52189 : 52190 GCC_CAN_DISABLE_WARNINGS=false 52191 52192 fi 52193 52194 52195 52196 52197 52198 52199 if test "x$GCC_CAN_DISABLE_WARNINGS" = "xtrue"; then 52200 DISABLE_WARNING_PREFIX="-Wno-" 52201 else 52202 DISABLE_WARNING_PREFIX= 52203 fi 52204 CFLAGS_WARNINGS_ARE_ERRORS="-Werror" 52205 # Repeate the check for the BUILD_CC and BUILD_CXX. Need to also reset 52206 # CFLAGS since any target specific flags will likely not work with the 52207 # build compiler 52208 CC_OLD="$CC" 52209 CXX_OLD="$CXX" 52210 CC="$BUILD_CC" 52211 CXX="$BUILD_CXX" 52212 CFLAGS_OLD="$CFLAGS" 52213 CFLAGS="" 52214 52215 52216 52217 52218 52219 52220 52221 52222 52223 52224 52225 52226 52227 52228 52229 52230 52231 52232 52233 52234 52235 52236 52237 52238 52239 52240 52241 52242 52243 52244 52245 52246 52247 52248 52249 52250 52251 52252 52253 52254 52255 52256 52257 52258 52259 52260 52261 # Execute function body 52262 52263 52264 52265 52266 52267 52268 52269 52270 52271 52272 52273 52274 52275 52276 52277 52278 52279 52280 52281 52282 52283 52284 52285 52286 52287 52288 52289 52290 52291 52292 52293 52294 52295 52296 52297 52298 52299 52300 52301 52302 52303 52304 52305 52306 52307 52308 52309 52310 # Execute function body 52311 52312 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 52313 $as_echo_n "checking if the C compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 52314 supports=yes 52315 52316 saved_cflags="$CFLAGS" 52317 CFLAGS="$CFLAGS -Wno-this-is-a-warning-that-do-not-exist" 52318 ac_ext=c 52319 ac_cpp='$CPP $CPPFLAGS' 52320 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52321 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52322 ac_compiler_gnu=$ac_cv_c_compiler_gnu 52323 52324 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 52325 /* end confdefs.h. */ 52326 int i; 52327 _ACEOF 52328 if ac_fn_c_try_compile "$LINENO"; then : 52329 52330 else 52331 supports=no 52332 fi 52333 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 52334 ac_ext=cpp 52335 ac_cpp='$CXXCPP $CPPFLAGS' 52336 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52337 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52338 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 52339 52340 CFLAGS="$saved_cflags" 52341 52342 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 52343 $as_echo "$supports" >&6; } 52344 if test "x$supports" = "xyes" ; then 52345 : 52346 C_COMP_SUPPORTS="yes" 52347 else 52348 : 52349 C_COMP_SUPPORTS="no" 52350 fi 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 52377 52378 52379 52380 52381 52382 52383 52384 52385 52386 52387 52388 52389 52390 52391 52392 52393 52394 52395 52396 52397 52398 52399 52400 52401 52402 52403 52404 52405 52406 52407 52408 52409 52410 # Execute function body 52411 52412 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the C++ compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 52413 $as_echo_n "checking if the C++ compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 52414 supports=yes 52415 52416 saved_cxxflags="$CXXFLAGS" 52417 CXXFLAGS="$CXXFLAG -Wno-this-is-a-warning-that-do-not-exist" 52418 ac_ext=cpp 52419 ac_cpp='$CXXCPP $CPPFLAGS' 52420 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52421 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52422 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 52423 52424 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 52425 /* end confdefs.h. */ 52426 int i; 52427 _ACEOF 52428 if ac_fn_cxx_try_compile "$LINENO"; then : 52429 52430 else 52431 supports=no 52432 fi 52433 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 52434 ac_ext=cpp 52435 ac_cpp='$CXXCPP $CPPFLAGS' 52436 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 52437 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 52438 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 52439 52440 CXXFLAGS="$saved_cxxflags" 52441 52442 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 52443 $as_echo "$supports" >&6; } 52444 if test "x$supports" = "xyes" ; then 52445 : 52446 CXX_COMP_SUPPORTS="yes" 52447 else 52448 : 52449 CXX_COMP_SUPPORTS="no" 52450 fi 52451 52452 52453 52454 52455 52456 52457 52458 52459 52460 52461 52462 52463 52464 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if both compilers support \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 52465 $as_echo_n "checking if both compilers support \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 52466 supports=no 52467 if test "x$C_COMP_SUPPORTS" = "xyes" -a "x$CXX_COMP_SUPPORTS" = "xyes"; then supports=yes; fi 52468 52469 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 52470 $as_echo "$supports" >&6; } 52471 if test "x$supports" = "xyes" ; then 52472 : 52473 BUILD_CC_CAN_DISABLE_WARNINGS=true 52474 else 52475 : 52476 BUILD_CC_CAN_DISABLE_WARNINGS=false 52477 52478 fi 52479 52480 52481 52482 52483 52484 52485 if test "x$BUILD_CC_CAN_DISABLE_WARNINGS" = "xtrue"; then 52486 BUILD_CC_DISABLE_WARNING_PREFIX="-Wno-" 52487 else 52488 BUILD_CC_DISABLE_WARNING_PREFIX= 52489 fi 52490 CC="$CC_OLD" 52491 CXX="$CXX_OLD" 52492 CFLAGS="$CFLAGS_OLD" 52493 ;; 52494 clang) 52495 DISABLE_WARNING_PREFIX="-Wno-" 52496 CFLAGS_WARNINGS_ARE_ERRORS="-Werror" 52497 ;; 52498 xlc) 52499 DISABLE_WARNING_PREFIX="-qsuppress=" 52500 CFLAGS_WARNINGS_ARE_ERRORS="-qhalt=w" 52501 ;; 52502 esac 52503 52504 52505 52506 52507 52508 # Setup debug symbols (need objcopy from the toolchain for that) 52509 52510 # 52511 # NATIVE_DEBUG_SYMBOLS 52512 # This must be done after the toolchain is setup, since we're looking at objcopy. 52513 # 52514 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what type of native debug symbols to use" >&5 52515 $as_echo_n "checking what type of native debug symbols to use... " >&6; } 52516 52517 # Check whether --with-native-debug-symbols was given. 52518 if test "${with_native_debug_symbols+set}" = set; then : 52519 withval=$with_native_debug_symbols; 52520 if test "x$OPENJDK_TARGET_OS" = xaix; then 52521 if test "x$withval" = xexternal || test "x$withval" = xzipped; then 52522 as_fn_error $? "AIX only supports the parameters 'none' and 'internal' for --with-native-debug-symbols" "$LINENO" 5 52523 fi 52524 fi 52525 52526 else 52527 52528 if test "x$OPENJDK_TARGET_OS" = xaix; then 52529 # AIX doesn't support 'zipped' so use 'internal' as default 52530 with_native_debug_symbols="internal" 52531 else 52532 if test "x$STATIC_BUILD" = xtrue; then 52533 with_native_debug_symbols="none" 52534 else 52535 with_native_debug_symbols="zipped" 52536 fi 52537 fi 52538 52539 fi 52540 52541 NATIVE_DEBUG_SYMBOLS=$with_native_debug_symbols 52542 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NATIVE_DEBUG_SYMBOLS" >&5 52543 $as_echo "$NATIVE_DEBUG_SYMBOLS" >&6; } 52544 52545 if test "x$NATIVE_DEBUG_SYMBOLS" = xzipped; then 52546 52547 if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xlinux; then 52548 if test "x$OBJCOPY" = x; then 52549 # enabling of enable-debug-symbols and can't find objcopy 52550 # this is an error 52551 as_fn_error $? "Unable to find objcopy, cannot enable native debug symbols" "$LINENO" 5 52552 fi 52553 fi 52554 52555 COMPILE_WITH_DEBUG_SYMBOLS=true 52556 COPY_DEBUG_SYMBOLS=true 52557 ZIP_EXTERNAL_DEBUG_SYMBOLS=true 52558 52559 # Hotspot legacy support, not relevant with COPY_DEBUG_SYMBOLS=true 52560 DEBUG_BINARIES=false 52561 STRIP_POLICY=min_strip 52562 52563 elif test "x$NATIVE_DEBUG_SYMBOLS" = xnone; then 52564 COMPILE_WITH_DEBUG_SYMBOLS=false 52565 COPY_DEBUG_SYMBOLS=false 52566 ZIP_EXTERNAL_DEBUG_SYMBOLS=false 52567 52568 DEBUG_BINARIES=false 52569 STRIP_POLICY=no_strip 52570 elif test "x$NATIVE_DEBUG_SYMBOLS" = xinternal; then 52571 COMPILE_WITH_DEBUG_SYMBOLS=true 52572 COPY_DEBUG_SYMBOLS=false 52573 ZIP_EXTERNAL_DEBUG_SYMBOLS=false 52574 52575 # Hotspot legacy support, will turn on -g when COPY_DEBUG_SYMBOLS=false 52576 DEBUG_BINARIES=true 52577 STRIP_POLICY=no_strip 52578 STRIP="" 52579 52580 elif test "x$NATIVE_DEBUG_SYMBOLS" = xexternal; then 52581 52582 if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xlinux; then 52583 if test "x$OBJCOPY" = x; then 52584 # enabling of enable-debug-symbols and can't find objcopy 52585 # this is an error 52586 as_fn_error $? "Unable to find objcopy, cannot enable native debug symbols" "$LINENO" 5 52587 fi 52588 fi 52589 52590 COMPILE_WITH_DEBUG_SYMBOLS=true 52591 COPY_DEBUG_SYMBOLS=true 52592 ZIP_EXTERNAL_DEBUG_SYMBOLS=false 52593 52594 # Hotspot legacy support, not relevant with COPY_DEBUG_SYMBOLS=true 52595 DEBUG_BINARIES=false 52596 STRIP_POLICY=min_strip 52597 else 52598 as_fn_error $? "Allowed native debug symbols are: none, internal, external, zipped" "$LINENO" 5 52599 fi 52600 52601 # --enable-debug-symbols is deprecated. 52602 # Please use --with-native-debug-symbols=[internal,external,zipped] . 52603 52604 # Check whether --enable-debug-symbols was given. 52605 if test "${enable_debug_symbols+set}" = set; then : 52606 enableval=$enable_debug_symbols; 52607 fi 52608 52609 if test "x$enable_debug_symbols" != x; then 52610 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --enable-debug-symbols is deprecated and will be ignored." >&5 52611 $as_echo "$as_me: WARNING: Option --enable-debug-symbols is deprecated and will be ignored." >&2;} 52612 52613 if test "xPlease use --with-native-debug-symbols=[internal,external,zipped] ." != x; then 52614 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Please use --with-native-debug-symbols=[internal,external,zipped] ." >&5 52615 $as_echo "$as_me: WARNING: Please use --with-native-debug-symbols=[internal,external,zipped] ." >&2;} 52616 fi 52617 52618 fi 52619 52620 52621 # --enable-zip-debug-info is deprecated. 52622 # Please use --with-native-debug-symbols=zipped . 52623 52624 # Check whether --enable-zip-debug-info was given. 52625 if test "${enable_zip_debug_info+set}" = set; then : 52626 enableval=$enable_zip_debug_info; 52627 fi 52628 52629 if test "x$enable_zip_debug_info" != x; then 52630 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --enable-zip-debug-info is deprecated and will be ignored." >&5 52631 $as_echo "$as_me: WARNING: Option --enable-zip-debug-info is deprecated and will be ignored." >&2;} 52632 52633 if test "xPlease use --with-native-debug-symbols=zipped ." != x; then 52634 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Please use --with-native-debug-symbols=zipped ." >&5 52635 $as_echo "$as_me: WARNING: Please use --with-native-debug-symbols=zipped ." >&2;} 52636 fi 52637 52638 fi 52639 52640 52641 52642 52643 52644 52645 # Legacy values 52646 52647 52648 52649 52650 # Check whether --enable-native-coverage was given. 52651 if test "${enable_native_coverage+set}" = set; then : 52652 enableval=$enable_native_coverage; 52653 fi 52654 52655 GCOV_ENABLED="false" 52656 if test "x$enable_native_coverage" = "xyes"; then 52657 if test "x$TOOLCHAIN_TYPE" = "xgcc"; then 52658 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if native coverage is enabled" >&5 52659 $as_echo_n "checking if native coverage is enabled... " >&6; } 52660 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 52661 $as_echo "yes" >&6; } 52662 GCOV_CFLAGS="-fprofile-arcs -ftest-coverage -fno-inline" 52663 GCOV_LDFLAGS="-fprofile-arcs" 52664 LEGACY_EXTRA_CFLAGS="$LEGACY_EXTRA_CFLAGS $GCOV_CFLAGS" 52665 LEGACY_EXTRA_CXXFLAGS="$LEGACY_EXTRA_CXXFLAGS $GCOV_CFLAGS" 52666 LEGACY_EXTRA_LDFLAGS="$LEGACY_EXTRA_LDFLAGS $GCOV_LDFLAGS" 52667 CFLAGS_JDKLIB="$CFLAGS_JDKLIB $GCOV_CFLAGS" 52668 CFLAGS_JDKEXE="$CFLAGS_JDKEXE $GCOV_CFLAGS" 52669 CXXFLAGS_JDKLIB="$CXXFLAGS_JDKLIB $GCOV_CFLAGS" 52670 CXXFLAGS_JDKEXE="$CXXFLAGS_JDKEXE $GCOV_CFLAGS" 52671 LDFLAGS_JDKLIB="$LDFLAGS_JDKLIB $GCOV_LDFLAGS" 52672 LDFLAGS_JDKEXE="$LDFLAGS_JDKEXE $GCOV_LDFLAGS" 52673 GCOV_ENABLED="true" 52674 else 52675 as_fn_error $? "--enable-native-coverage only works with toolchain type gcc" "$LINENO" 5 52676 fi 52677 elif test "x$enable_native_coverage" = "xno"; then 52678 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if native coverage is enabled" >&5 52679 $as_echo_n "checking if native coverage is enabled... " >&6; } 52680 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 52681 $as_echo "no" >&6; } 52682 elif test "x$enable_native_coverage" != "x"; then 52683 as_fn_error $? "--enable-native-coverage can only be assigned \"yes\" or \"no\"" "$LINENO" 5 52684 fi 52685 52686 52687 52688 52689 # Need toolchain to setup dtrace 52690 52691 # Test for dtrace dependencies 52692 # Check whether --enable-dtrace was given. 52693 if test "${enable_dtrace+set}" = set; then : 52694 enableval=$enable_dtrace; 52695 fi 52696 52697 52698 DTRACE_DEP_MISSING=false 52699 52700 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dtrace tool" >&5 52701 $as_echo_n "checking for dtrace tool... " >&6; } 52702 if test "x$DTRACE" != "x" && test -x "$DTRACE"; then 52703 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DTRACE" >&5 52704 $as_echo "$DTRACE" >&6; } 52705 else 52706 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found, cannot build dtrace" >&5 52707 $as_echo "not found, cannot build dtrace" >&6; } 52708 DTRACE_DEP_MISSING=true 52709 fi 52710 52711 for ac_header in sys/sdt.h 52712 do : 52713 ac_fn_cxx_check_header_mongrel "$LINENO" "sys/sdt.h" "ac_cv_header_sys_sdt_h" "$ac_includes_default" 52714 if test "x$ac_cv_header_sys_sdt_h" = xyes; then : 52715 cat >>confdefs.h <<_ACEOF 52716 #define HAVE_SYS_SDT_H 1 52717 _ACEOF 52718 DTRACE_HEADERS_OK=yes 52719 else 52720 DTRACE_HEADERS_OK=no 52721 fi 52722 52723 done 52724 52725 if test "x$DTRACE_HEADERS_OK" != "xyes"; then 52726 DTRACE_DEP_MISSING=true 52727 fi 52728 52729 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if dtrace should be built" >&5 52730 $as_echo_n "checking if dtrace should be built... " >&6; } 52731 if test "x$enable_dtrace" = "xyes"; then 52732 if test "x$DTRACE_DEP_MISSING" = "xtrue"; then 52733 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, missing dependencies" >&5 52734 $as_echo "no, missing dependencies" >&6; } 52735 52736 # Print a helpful message on how to acquire the necessary build dependency. 52737 # dtrace is the help tag: freetype, cups, alsa etc 52738 MISSING_DEPENDENCY=dtrace 52739 52740 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 52741 cygwin_help $MISSING_DEPENDENCY 52742 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 52743 msys_help $MISSING_DEPENDENCY 52744 else 52745 PKGHANDLER_COMMAND= 52746 52747 case $PKGHANDLER in 52748 apt-get) 52749 apt_help $MISSING_DEPENDENCY ;; 52750 yum) 52751 yum_help $MISSING_DEPENDENCY ;; 52752 port) 52753 port_help $MISSING_DEPENDENCY ;; 52754 pkgutil) 52755 pkgutil_help $MISSING_DEPENDENCY ;; 52756 pkgadd) 52757 pkgadd_help $MISSING_DEPENDENCY ;; 52758 esac 52759 52760 if test "x$PKGHANDLER_COMMAND" != x; then 52761 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 52762 fi 52763 fi 52764 52765 as_fn_error $? "Cannot enable dtrace with missing dependencies. See above. $HELP_MSG" "$LINENO" 5 52766 else 52767 INCLUDE_DTRACE=true 52768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 52769 $as_echo "yes, forced" >&6; } 52770 fi 52771 elif test "x$enable_dtrace" = "xno"; then 52772 INCLUDE_DTRACE=false 52773 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 52774 $as_echo "no, forced" >&6; } 52775 elif test "x$enable_dtrace" = "xauto" || test "x$enable_dtrace" = "x"; then 52776 if test "x$DTRACE_DEP_MISSING" = "xtrue"; then 52777 INCLUDE_DTRACE=false 52778 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, missing dependencies" >&5 52779 $as_echo "no, missing dependencies" >&6; } 52780 else 52781 INCLUDE_DTRACE=true 52782 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, dependencies present" >&5 52783 $as_echo "yes, dependencies present" >&6; } 52784 fi 52785 else 52786 as_fn_error $? "Invalid value for --enable-dtrace: $enable_dtrace" "$LINENO" 5 52787 fi 52788 52789 52790 52791 # The user can in some cases supply additional jvm features. For the custom 52792 # variant, this defines the entire variant. 52793 52794 # Check whether --with-jvm-features was given. 52795 if test "${with_jvm_features+set}" = set; then : 52796 withval=$with_jvm_features; 52797 fi 52798 52799 if test "x$with_jvm_features" != x; then 52800 { $as_echo "$as_me:${as_lineno-$LINENO}: checking additional JVM features" >&5 52801 $as_echo_n "checking additional JVM features... " >&6; } 52802 JVM_FEATURES=`$ECHO $with_jvm_features | $SED -e 's/,/ /g'` 52803 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JVM_FEATURES" >&5 52804 $as_echo "$JVM_FEATURES" >&6; } 52805 fi 52806 52807 # Verify that dependencies are met for explicitly set features. 52808 if [[ " $JVM_FEATURES " =~ " jvmti " ]] && ! [[ " $JVM_FEATURES " =~ " services " ]] ; then 52809 as_fn_error $? "Specified JVM feature 'jvmti' requires feature 'services'" "$LINENO" 5 52810 fi 52811 52812 if [[ " $JVM_FEATURES " =~ " management " ]] && ! [[ " $JVM_FEATURES " =~ " nmt " ]] ; then 52813 as_fn_error $? "Specified JVM feature 'management' requires feature 'nmt'" "$LINENO" 5 52814 fi 52815 52816 if [[ " $JVM_FEATURES " =~ " jvmci " ]] && ! ( [[ " $JVM_FEATURES " =~ " compiler1 " ]] || [[ " $JVM_FEATURES " =~ " compiler2 " ]] ); then 52817 as_fn_error $? "Specified JVM feature 'jvmci' requires feature 'compiler2' or 'compiler1'" "$LINENO" 5 52818 fi 52819 52820 if [[ " $JVM_FEATURES " =~ " compiler2 " ]] && ! [[ " $JVM_FEATURES " =~ " all-gcs " ]] ; then 52821 as_fn_error $? "Specified JVM feature 'compiler2' requires feature 'all-gcs'" "$LINENO" 5 52822 fi 52823 52824 if [[ " $JVM_FEATURES " =~ " vm-structs " ]] && ! [[ " $JVM_FEATURES " =~ " all-gcs " ]] ; then 52825 as_fn_error $? "Specified JVM feature 'vm-structs' requires feature 'all-gcs'" "$LINENO" 5 52826 fi 52827 52828 # Turn on additional features based on other parts of configure 52829 if test "x$INCLUDE_DTRACE" = "xtrue"; then 52830 JVM_FEATURES="$JVM_FEATURES dtrace" 52831 else 52832 if [[ " $JVM_FEATURES " =~ " dtrace " ]] ; then 52833 as_fn_error $? "To enable dtrace, you must use --enable-dtrace" "$LINENO" 5 52834 fi 52835 fi 52836 52837 if test "x$STATIC_BUILD" = "xtrue"; then 52838 JVM_FEATURES="$JVM_FEATURES static-build" 52839 else 52840 if [[ " $JVM_FEATURES " =~ " static-build " ]] ; then 52841 as_fn_error $? "To enable static-build, you must use --enable-static-build" "$LINENO" 5 52842 fi 52843 fi 52844 52845 if ! [[ " $JVM_VARIANTS " =~ " zero " ]] && ! [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 52846 if [[ " $JVM_FEATURES " =~ " zero " ]] ; then 52847 as_fn_error $? "To enable zero/zeroshark, you must use --with-jvm-variants=zero/zeroshark" "$LINENO" 5 52848 fi 52849 fi 52850 52851 if ! [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 52852 if [[ " $JVM_FEATURES " =~ " shark " ]] ; then 52853 as_fn_error $? "To enable shark, you must use --with-jvm-variants=zeroshark" "$LINENO" 5 52854 fi 52855 fi 52856 52857 # Only enable jvmci on x86_64, sparcv9 and aarch64. 52858 if test "x$OPENJDK_TARGET_CPU" = "xx86_64" || \ 52859 test "x$OPENJDK_TARGET_CPU" = "xsparcv9" || \ 52860 test "x$OPENJDK_TARGET_CPU" = "xaarch64" ; then 52861 JVM_FEATURES_jvmci="jvmci" 52862 else 52863 JVM_FEATURES_jvmci="" 52864 fi 52865 52866 # All variants but minimal (and custom) get these features 52867 NON_MINIMAL_FEATURES="$NON_MINIMAL_FEATURES jvmti fprof vm-structs jni-check services management all-gcs nmt cds" 52868 52869 # Enable features depending on variant. 52870 JVM_FEATURES_server="compiler1 compiler2 $NON_MINIMAL_FEATURES $JVM_FEATURES $JVM_FEATURES_jvmci" 52871 JVM_FEATURES_client="compiler1 $NON_MINIMAL_FEATURES $JVM_FEATURES $JVM_FEATURES_jvmci" 52872 JVM_FEATURES_core="$NON_MINIMAL_FEATURES $JVM_FEATURES" 52873 JVM_FEATURES_minimal="compiler1 minimal $JVM_FEATURES" 52874 JVM_FEATURES_zero="zero $NON_MINIMAL_FEATURES $JVM_FEATURES" 52875 JVM_FEATURES_zeroshark="zero shark $NON_MINIMAL_FEATURES $JVM_FEATURES" 52876 JVM_FEATURES_custom="$JVM_FEATURES" 52877 52878 52879 52880 52881 52882 52883 52884 52885 52886 # Used for verification of Makefiles by check-jvm-feature 52887 52888 52889 # We don't support --with-jvm-interpreter anymore, use zero instead. 52890 52891 52892 # Check whether --with-jvm-interpreter was given. 52893 if test "${with_jvm_interpreter+set}" = set; then : 52894 withval=$with_jvm_interpreter; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-jvm-interpreter is deprecated and will be ignored." >&5 52895 $as_echo "$as_me: WARNING: Option --with-jvm-interpreter is deprecated and will be ignored." >&2;} 52896 fi 52897 52898 52899 52900 52901 # Check whether --enable-hotspot-gtest was given. 52902 if test "${enable_hotspot_gtest+set}" = set; then : 52903 enableval=$enable_hotspot_gtest; 52904 fi 52905 52906 52907 if test -e "$HOTSPOT_TOPDIR/test/native"; then 52908 GTEST_DIR_EXISTS="true" 52909 else 52910 GTEST_DIR_EXISTS="false" 52911 fi 52912 52913 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if Hotspot gtest unit tests should be built" >&5 52914 $as_echo_n "checking if Hotspot gtest unit tests should be built... " >&6; } 52915 if test "x$enable_hotspot_gtest" = "xyes"; then 52916 if test "x$GTEST_DIR_EXISTS" = "xtrue"; then 52917 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 52918 $as_echo "yes, forced" >&6; } 52919 BUILD_GTEST="true" 52920 else 52921 as_fn_error $? "Cannot build gtest without the test source" "$LINENO" 5 52922 fi 52923 elif test "x$enable_hotspot_gtest" = "xno"; then 52924 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 52925 $as_echo "no, forced" >&6; } 52926 BUILD_GTEST="false" 52927 elif test "x$enable_hotspot_gtest" = "x"; then 52928 if test "x$GTEST_DIR_EXISTS" = "xtrue" && test "x$OPENJDK_TARGET_OS" != "xaix"; then 52929 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 52930 $as_echo "yes" >&6; } 52931 BUILD_GTEST="true" 52932 else 52933 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 52934 $as_echo "no" >&6; } 52935 BUILD_GTEST="false" 52936 fi 52937 else 52938 as_fn_error $? "--enable-gtest must be either yes or no" "$LINENO" 5 52939 fi 52940 52941 52942 52943 52944 ############################################################################### 52945 # 52946 # Check dependencies for external and internal libraries. 52947 # 52948 ############################################################################### 52949 52950 # After we have toolchain, we can compile fixpath. It's needed by the lib checks. 52951 52952 # When using cygwin or msys, we need a wrapper binary that renames 52953 # /cygdrive/c/ arguments into c:/ arguments and peeks into 52954 # @files and rewrites these too! This wrapper binary is 52955 # called fixpath. 52956 FIXPATH= 52957 if test "x$OPENJDK_BUILD_OS" = xwindows; then 52958 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fixpath can be created" >&5 52959 $as_echo_n "checking if fixpath can be created... " >&6; } 52960 FIXPATH_SRC="$SRC_ROOT/common/src/fixpath.c" 52961 FIXPATH_BIN="$CONFIGURESUPPORT_OUTPUTDIR/bin/fixpath.exe" 52962 FIXPATH_DIR="$CONFIGURESUPPORT_OUTPUTDIR/fixpath" 52963 if test "x$OPENJDK_BUILD_OS_ENV" = xwindows.cygwin; then 52964 # Important to keep the .exe suffix on Cygwin for Hotspot makefiles 52965 FIXPATH="$FIXPATH_BIN -c" 52966 elif test "x$OPENJDK_BUILD_OS_ENV" = xwindows.msys; then 52967 # Take all collected prefixes and turn them into a -m/c/foo@/c/bar@... command line 52968 # @ was chosen as separator to minimize risk of other tools messing around with it 52969 all_unique_prefixes=`echo "${all_fixpath_prefixes[@]}" \ 52970 | tr ' ' '\n' | $GREP '^/./' | $SORT | $UNIQ` 52971 fixpath_argument_list=`echo $all_unique_prefixes | tr ' ' '@'` 52972 FIXPATH="$FIXPATH_BIN -m$fixpath_argument_list" 52973 fi 52974 FIXPATH_SRC_W="$FIXPATH_SRC" 52975 FIXPATH_BIN_W="$FIXPATH_BIN" 52976 52977 unix_path="$FIXPATH_SRC_W" 52978 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 52979 windows_path=`$CYGPATH -m "$unix_path"` 52980 FIXPATH_SRC_W="$windows_path" 52981 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 52982 windows_path=`cmd //c echo $unix_path` 52983 FIXPATH_SRC_W="$windows_path" 52984 fi 52985 52986 52987 unix_path="$FIXPATH_BIN_W" 52988 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 52989 windows_path=`$CYGPATH -m "$unix_path"` 52990 FIXPATH_BIN_W="$windows_path" 52991 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 52992 windows_path=`cmd //c echo $unix_path` 52993 FIXPATH_BIN_W="$windows_path" 52994 fi 52995 52996 $RM -rf $FIXPATH_BIN $FIXPATH_DIR 52997 $MKDIR -p $FIXPATH_DIR $CONFIGURESUPPORT_OUTPUTDIR/bin 52998 cd $FIXPATH_DIR 52999 $CC $FIXPATH_SRC_W -Fe$FIXPATH_BIN_W > $FIXPATH_DIR/fixpath1.log 2>&1 53000 cd $CURDIR 53001 53002 if test ! -x $FIXPATH_BIN; then 53003 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 53004 $as_echo "no" >&6; } 53005 cat $FIXPATH_DIR/fixpath1.log 53006 as_fn_error $? "Could not create $FIXPATH_BIN" "$LINENO" 5 53007 fi 53008 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 53009 $as_echo "yes" >&6; } 53010 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fixpath.exe works" >&5 53011 $as_echo_n "checking if fixpath.exe works... " >&6; } 53012 cd $FIXPATH_DIR 53013 $FIXPATH $CC $FIXPATH_SRC -Fe$FIXPATH_DIR/fixpath2.exe \ 53014 > $FIXPATH_DIR/fixpath2.log 2>&1 53015 cd $CURDIR 53016 if test ! -x $FIXPATH_DIR/fixpath2.exe; then 53017 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 53018 $as_echo "no" >&6; } 53019 cat $FIXPATH_DIR/fixpath2.log 53020 as_fn_error $? "fixpath did not work!" "$LINENO" 5 53021 fi 53022 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 53023 $as_echo "yes" >&6; } 53024 53025 FIXPATH_DETACH_FLAG="--detach" 53026 fi 53027 53028 53029 53030 53031 53032 53033 # Check if X11 is needed 53034 if test "x$OPENJDK_TARGET_OS" = xwindows || test "x$OPENJDK_TARGET_OS" = xmacosx; then 53035 # No X11 support on windows or macosx 53036 NEEDS_LIB_X11=false 53037 else 53038 # All other instances need X11, even if building headless only, libawt still 53039 # needs X11 headers. 53040 NEEDS_LIB_X11=true 53041 fi 53042 53043 # Check if cups is needed 53044 if test "x$OPENJDK_TARGET_OS" = xwindows; then 53045 # Windows have a separate print system 53046 NEEDS_LIB_CUPS=false 53047 else 53048 NEEDS_LIB_CUPS=true 53049 fi 53050 53051 # A custom hook may have set this already 53052 if test "x$NEEDS_LIB_FREETYPE" = "x"; then 53053 NEEDS_LIB_FREETYPE=true 53054 fi 53055 53056 # Check if alsa is needed 53057 if test "x$OPENJDK_TARGET_OS" = xlinux; then 53058 NEEDS_LIB_ALSA=true 53059 else 53060 NEEDS_LIB_ALSA=false 53061 fi 53062 53063 # Check if ffi is needed 53064 if [[ " $JVM_VARIANTS " =~ " zero " ]] || [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 53065 NEEDS_LIB_FFI=true 53066 else 53067 NEEDS_LIB_FFI=false 53068 fi 53069 53070 53071 # statically link libstdc++ before C++ ABI is stablized on Linux unless 53072 # dynamic build is configured on command line. 53073 53074 # Check whether --with-stdc++lib was given. 53075 if test "${with_stdc__lib+set}" = set; then : 53076 withval=$with_stdc__lib; 53077 if test "x$with_stdc__lib" != xdynamic && test "x$with_stdc__lib" != xstatic \ 53078 && test "x$with_stdc__lib" != xdefault; then 53079 as_fn_error $? "Bad parameter value --with-stdc++lib=$with_stdc__lib!" "$LINENO" 5 53080 fi 53081 53082 else 53083 with_stdc__lib=default 53084 53085 fi 53086 53087 53088 if test "x$OPENJDK_TARGET_OS" = xlinux; then 53089 # Test if stdc++ can be linked statically. 53090 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if static link of stdc++ is possible" >&5 53091 $as_echo_n "checking if static link of stdc++ is possible... " >&6; } 53092 STATIC_STDCXX_FLAGS="-static-libstdc++ -static-libgcc" 53093 ac_ext=cpp 53094 ac_cpp='$CXXCPP $CPPFLAGS' 53095 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 53096 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 53097 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 53098 53099 OLD_LIBS="$LIBS" 53100 LIBS="$STATIC_STDCXX_FLAGS" 53101 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 53102 /* end confdefs.h. */ 53103 53104 int 53105 main () 53106 { 53107 return 0; 53108 ; 53109 return 0; 53110 } 53111 _ACEOF 53112 if ac_fn_cxx_try_link "$LINENO"; then : 53113 has_static_libstdcxx=yes 53114 else 53115 has_static_libstdcxx=no 53116 fi 53117 rm -f core conftest.err conftest.$ac_objext \ 53118 conftest$ac_exeext conftest.$ac_ext 53119 LIBS="$OLD_LIBS" 53120 ac_ext=cpp 53121 ac_cpp='$CXXCPP $CPPFLAGS' 53122 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 53123 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 53124 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 53125 53126 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_static_libstdcxx" >&5 53127 $as_echo "$has_static_libstdcxx" >&6; } 53128 53129 if test "x$with_stdc__lib" = xstatic && test "x$has_static_libstdcxx" = xno; then 53130 as_fn_error $? "Static linking of libstdc++ was not possible!" "$LINENO" 5 53131 fi 53132 53133 # If dynamic was requested, it's available since it would fail above otherwise. 53134 # If dynamic wasn't requested, go with static unless it isn't available. 53135 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libstdc++" >&5 53136 $as_echo_n "checking how to link with libstdc++... " >&6; } 53137 if test "x$with_stdc__lib" = xdynamic || test "x$has_static_libstdcxx" = xno \ 53138 || [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 53139 # Ideally, we should test stdc++ for the BUILD toolchain separately. For now 53140 # just use the same setting as for the TARGET toolchain. 53141 { $as_echo "$as_me:${as_lineno-$LINENO}: result: dynamic" >&5 53142 $as_echo "dynamic" >&6; } 53143 else 53144 LIBCXX="$LIBCXX $STATIC_STDCXX_FLAGS" 53145 JVM_LDFLAGS="$JVM_LDFLAGS $STATIC_STDCXX_FLAGS" 53146 # Ideally, we should test stdc++ for the BUILD toolchain separately. For now 53147 # just use the same setting as for the TARGET toolchain. 53148 OPENJDK_BUILD_JVM_LDFLAGS="$OPENJDK_BUILD_JVM_LDFLAGS $STATIC_STDCXX_FLAGS" 53149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: static" >&5 53150 $as_echo "static" >&6; } 53151 fi 53152 fi 53153 53154 # libCrun is the c++ runtime-library with SunStudio (roughly the equivalent of gcc's libstdc++.so) 53155 if test "x$TOOLCHAIN_TYPE" = xsolstudio && test "x$LIBCXX" = x; then 53156 LIBCXX="${SYSROOT}/usr/lib${OPENJDK_TARGET_CPU_ISADIR}/libCrun.so.1" 53157 fi 53158 53159 53160 53161 # Setup Windows runtime dlls 53162 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 53163 53164 53165 # Check whether --with-msvcr-dll was given. 53166 if test "${with_msvcr_dll+set}" = set; then : 53167 withval=$with_msvcr_dll; 53168 fi 53169 53170 53171 if test "x$with_msvcr_dll" != x; then 53172 # If given explicitely by user, do not probe. If not present, fail directly. 53173 53174 DLL_NAME="$MSVCR_NAME" 53175 POSSIBLE_MSVC_DLL="$with_msvcr_dll" 53176 METHOD="--with-msvcr-dll" 53177 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 53178 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 53179 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 53180 53181 # Need to check if the found msvcr is correct architecture 53182 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 53183 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 53184 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 53185 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53186 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 53187 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 53188 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53189 CORRECT_MSVCR_ARCH="PE32 executable" 53190 else 53191 CORRECT_MSVCR_ARCH="PE32+ executable" 53192 fi 53193 else 53194 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53195 CORRECT_MSVCR_ARCH=386 53196 else 53197 CORRECT_MSVCR_ARCH=x86-64 53198 fi 53199 fi 53200 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 53201 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 53202 $as_echo "ok" >&6; } 53203 MSVC_DLL="$POSSIBLE_MSVC_DLL" 53204 53205 # Only process if variable expands to non-empty 53206 53207 if test "x$MSVC_DLL" != x; then 53208 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53209 53210 # Input might be given as Windows format, start by converting to 53211 # unix format. 53212 path="$MSVC_DLL" 53213 new_path=`$CYGPATH -u "$path"` 53214 53215 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 53216 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 53217 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 53218 # "foo.exe" is OK but "foo" is an error. 53219 # 53220 # This test is therefore slightly more accurate than "test -f" to check for file precense. 53221 # It is also a way to make sure we got the proper file name for the real test later on. 53222 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 53223 if test "x$test_shortpath" = x; then 53224 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 53225 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 53226 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 53227 fi 53228 53229 # Call helper function which possibly converts this using DOS-style short mode. 53230 # If so, the updated path is stored in $new_path. 53231 53232 input_path="$new_path" 53233 # Check if we need to convert this using DOS-style short mode. If the path 53234 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53235 # take no chances and rewrite it. 53236 # Note: m4 eats our [], so we need to use [ and ] instead. 53237 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 53238 if test "x$has_forbidden_chars" != x; then 53239 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53240 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 53241 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 53242 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 53243 # Going to short mode and back again did indeed matter. Since short mode is 53244 # case insensitive, let's make it lowercase to improve readability. 53245 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53246 # Now convert it back to Unix-style (cygpath) 53247 input_path=`$CYGPATH -u "$shortmode_path"` 53248 new_path="$input_path" 53249 fi 53250 fi 53251 53252 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 53253 if test "x$test_cygdrive_prefix" = x; then 53254 # As a simple fix, exclude /usr/bin since it's not a real path. 53255 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 53256 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 53257 # a path prefixed by /cygdrive for fixpath to work. 53258 new_path="$CYGWIN_ROOT_PATH$input_path" 53259 fi 53260 fi 53261 53262 53263 if test "x$path" != "x$new_path"; then 53264 MSVC_DLL="$new_path" 53265 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 53266 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 53267 fi 53268 53269 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53270 53271 path="$MSVC_DLL" 53272 has_colon=`$ECHO $path | $GREP ^.:` 53273 new_path="$path" 53274 if test "x$has_colon" = x; then 53275 # Not in mixed or Windows style, start by that. 53276 new_path=`cmd //c echo $path` 53277 fi 53278 53279 53280 input_path="$new_path" 53281 # Check if we need to convert this using DOS-style short mode. If the path 53282 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53283 # take no chances and rewrite it. 53284 # Note: m4 eats our [], so we need to use [ and ] instead. 53285 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 53286 if test "x$has_forbidden_chars" != x; then 53287 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53288 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53289 fi 53290 53291 53292 windows_path="$new_path" 53293 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53294 unix_path=`$CYGPATH -u "$windows_path"` 53295 new_path="$unix_path" 53296 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53297 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 53298 new_path="$unix_path" 53299 fi 53300 53301 if test "x$path" != "x$new_path"; then 53302 MSVC_DLL="$new_path" 53303 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 53304 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 53305 fi 53306 53307 # Save the first 10 bytes of this path to the storage, so fixpath can work. 53308 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 53309 53310 else 53311 # We're on a unix platform. Hooray! :) 53312 path="$MSVC_DLL" 53313 has_space=`$ECHO "$path" | $GREP " "` 53314 if test "x$has_space" != x; then 53315 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 53316 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 53317 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 53318 fi 53319 53320 # Use eval to expand a potential ~ 53321 eval path="$path" 53322 if test ! -f "$path" && test ! -d "$path"; then 53323 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 53324 fi 53325 53326 if test -d "$path"; then 53327 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 53328 else 53329 dir="`$DIRNAME "$path"`" 53330 base="`$BASENAME "$path"`" 53331 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 53332 fi 53333 fi 53334 fi 53335 53336 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 53337 $as_echo_n "checking for $DLL_NAME... " >&6; } 53338 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 53339 $as_echo "$MSVC_DLL" >&6; } 53340 else 53341 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 53342 $as_echo "incorrect, ignoring" >&6; } 53343 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 53344 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 53345 fi 53346 fi 53347 53348 if test "x$MSVC_DLL" = x; then 53349 as_fn_error $? "Could not find a proper $MSVCR_NAME as specified by --with-msvcr-dll" "$LINENO" 5 53350 fi 53351 MSVCR_DLL="$MSVC_DLL" 53352 elif test "x$DEVKIT_MSVCR_DLL" != x; then 53353 53354 DLL_NAME="$MSVCR_NAME" 53355 POSSIBLE_MSVC_DLL="$DEVKIT_MSVCR_DLL" 53356 METHOD="devkit" 53357 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 53358 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 53359 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 53360 53361 # Need to check if the found msvcr is correct architecture 53362 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 53363 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 53364 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 53365 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53366 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 53367 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 53368 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53369 CORRECT_MSVCR_ARCH="PE32 executable" 53370 else 53371 CORRECT_MSVCR_ARCH="PE32+ executable" 53372 fi 53373 else 53374 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53375 CORRECT_MSVCR_ARCH=386 53376 else 53377 CORRECT_MSVCR_ARCH=x86-64 53378 fi 53379 fi 53380 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 53381 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 53382 $as_echo "ok" >&6; } 53383 MSVC_DLL="$POSSIBLE_MSVC_DLL" 53384 53385 # Only process if variable expands to non-empty 53386 53387 if test "x$MSVC_DLL" != x; then 53388 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53389 53390 # Input might be given as Windows format, start by converting to 53391 # unix format. 53392 path="$MSVC_DLL" 53393 new_path=`$CYGPATH -u "$path"` 53394 53395 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 53396 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 53397 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 53398 # "foo.exe" is OK but "foo" is an error. 53399 # 53400 # This test is therefore slightly more accurate than "test -f" to check for file precense. 53401 # It is also a way to make sure we got the proper file name for the real test later on. 53402 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 53403 if test "x$test_shortpath" = x; then 53404 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 53405 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 53406 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 53407 fi 53408 53409 # Call helper function which possibly converts this using DOS-style short mode. 53410 # If so, the updated path is stored in $new_path. 53411 53412 input_path="$new_path" 53413 # Check if we need to convert this using DOS-style short mode. If the path 53414 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53415 # take no chances and rewrite it. 53416 # Note: m4 eats our [], so we need to use [ and ] instead. 53417 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 53418 if test "x$has_forbidden_chars" != x; then 53419 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53420 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 53421 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 53422 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 53423 # Going to short mode and back again did indeed matter. Since short mode is 53424 # case insensitive, let's make it lowercase to improve readability. 53425 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53426 # Now convert it back to Unix-style (cygpath) 53427 input_path=`$CYGPATH -u "$shortmode_path"` 53428 new_path="$input_path" 53429 fi 53430 fi 53431 53432 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 53433 if test "x$test_cygdrive_prefix" = x; then 53434 # As a simple fix, exclude /usr/bin since it's not a real path. 53435 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 53436 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 53437 # a path prefixed by /cygdrive for fixpath to work. 53438 new_path="$CYGWIN_ROOT_PATH$input_path" 53439 fi 53440 fi 53441 53442 53443 if test "x$path" != "x$new_path"; then 53444 MSVC_DLL="$new_path" 53445 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 53446 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 53447 fi 53448 53449 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53450 53451 path="$MSVC_DLL" 53452 has_colon=`$ECHO $path | $GREP ^.:` 53453 new_path="$path" 53454 if test "x$has_colon" = x; then 53455 # Not in mixed or Windows style, start by that. 53456 new_path=`cmd //c echo $path` 53457 fi 53458 53459 53460 input_path="$new_path" 53461 # Check if we need to convert this using DOS-style short mode. If the path 53462 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53463 # take no chances and rewrite it. 53464 # Note: m4 eats our [], so we need to use [ and ] instead. 53465 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 53466 if test "x$has_forbidden_chars" != x; then 53467 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53468 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53469 fi 53470 53471 53472 windows_path="$new_path" 53473 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53474 unix_path=`$CYGPATH -u "$windows_path"` 53475 new_path="$unix_path" 53476 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53477 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 53478 new_path="$unix_path" 53479 fi 53480 53481 if test "x$path" != "x$new_path"; then 53482 MSVC_DLL="$new_path" 53483 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 53484 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 53485 fi 53486 53487 # Save the first 10 bytes of this path to the storage, so fixpath can work. 53488 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 53489 53490 else 53491 # We're on a unix platform. Hooray! :) 53492 path="$MSVC_DLL" 53493 has_space=`$ECHO "$path" | $GREP " "` 53494 if test "x$has_space" != x; then 53495 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 53496 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 53497 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 53498 fi 53499 53500 # Use eval to expand a potential ~ 53501 eval path="$path" 53502 if test ! -f "$path" && test ! -d "$path"; then 53503 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 53504 fi 53505 53506 if test -d "$path"; then 53507 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 53508 else 53509 dir="`$DIRNAME "$path"`" 53510 base="`$BASENAME "$path"`" 53511 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 53512 fi 53513 fi 53514 fi 53515 53516 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 53517 $as_echo_n "checking for $DLL_NAME... " >&6; } 53518 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 53519 $as_echo "$MSVC_DLL" >&6; } 53520 else 53521 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 53522 $as_echo "incorrect, ignoring" >&6; } 53523 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 53524 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 53525 fi 53526 fi 53527 53528 if test "x$MSVC_DLL" = x; then 53529 as_fn_error $? "Could not find a proper $MSVCR_NAME as specified by devkit" "$LINENO" 5 53530 fi 53531 MSVCR_DLL="$MSVC_DLL" 53532 else 53533 53534 DLL_NAME="${MSVCR_NAME}" 53535 MSVC_DLL= 53536 53537 if test "x$MSVC_DLL" = x; then 53538 # Probe: Using well-known location from Visual Studio 10.0 53539 if test "x$VCINSTALLDIR" != x; then 53540 CYGWIN_VC_INSTALL_DIR="$VCINSTALLDIR" 53541 53542 windows_path="$CYGWIN_VC_INSTALL_DIR" 53543 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53544 unix_path=`$CYGPATH -u "$windows_path"` 53545 CYGWIN_VC_INSTALL_DIR="$unix_path" 53546 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53547 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 53548 CYGWIN_VC_INSTALL_DIR="$unix_path" 53549 fi 53550 53551 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 53552 POSSIBLE_MSVC_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x64/Microsoft.VC${VS_VERSION_INTERNAL}.CRT/$DLL_NAME" 53553 else 53554 POSSIBLE_MSVC_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x86/Microsoft.VC${VS_VERSION_INTERNAL}.CRT/$DLL_NAME" 53555 fi 53556 $ECHO "POSSIBLE_MSVC_DLL $POSSIBLEMSVC_DLL" 53557 53558 DLL_NAME="$DLL_NAME" 53559 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 53560 METHOD="well-known location in VCINSTALLDIR" 53561 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 53562 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 53563 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 53564 53565 # Need to check if the found msvcr is correct architecture 53566 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 53567 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 53568 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 53569 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53570 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 53571 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 53572 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53573 CORRECT_MSVCR_ARCH="PE32 executable" 53574 else 53575 CORRECT_MSVCR_ARCH="PE32+ executable" 53576 fi 53577 else 53578 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53579 CORRECT_MSVCR_ARCH=386 53580 else 53581 CORRECT_MSVCR_ARCH=x86-64 53582 fi 53583 fi 53584 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 53585 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 53586 $as_echo "ok" >&6; } 53587 MSVC_DLL="$POSSIBLE_MSVC_DLL" 53588 53589 # Only process if variable expands to non-empty 53590 53591 if test "x$MSVC_DLL" != x; then 53592 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53593 53594 # Input might be given as Windows format, start by converting to 53595 # unix format. 53596 path="$MSVC_DLL" 53597 new_path=`$CYGPATH -u "$path"` 53598 53599 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 53600 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 53601 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 53602 # "foo.exe" is OK but "foo" is an error. 53603 # 53604 # This test is therefore slightly more accurate than "test -f" to check for file precense. 53605 # It is also a way to make sure we got the proper file name for the real test later on. 53606 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 53607 if test "x$test_shortpath" = x; then 53608 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 53609 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 53610 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 53611 fi 53612 53613 # Call helper function which possibly converts this using DOS-style short mode. 53614 # If so, the updated path is stored in $new_path. 53615 53616 input_path="$new_path" 53617 # Check if we need to convert this using DOS-style short mode. If the path 53618 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53619 # take no chances and rewrite it. 53620 # Note: m4 eats our [], so we need to use [ and ] instead. 53621 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 53622 if test "x$has_forbidden_chars" != x; then 53623 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53624 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 53625 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 53626 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 53627 # Going to short mode and back again did indeed matter. Since short mode is 53628 # case insensitive, let's make it lowercase to improve readability. 53629 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53630 # Now convert it back to Unix-style (cygpath) 53631 input_path=`$CYGPATH -u "$shortmode_path"` 53632 new_path="$input_path" 53633 fi 53634 fi 53635 53636 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 53637 if test "x$test_cygdrive_prefix" = x; then 53638 # As a simple fix, exclude /usr/bin since it's not a real path. 53639 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 53640 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 53641 # a path prefixed by /cygdrive for fixpath to work. 53642 new_path="$CYGWIN_ROOT_PATH$input_path" 53643 fi 53644 fi 53645 53646 53647 if test "x$path" != "x$new_path"; then 53648 MSVC_DLL="$new_path" 53649 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 53650 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 53651 fi 53652 53653 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53654 53655 path="$MSVC_DLL" 53656 has_colon=`$ECHO $path | $GREP ^.:` 53657 new_path="$path" 53658 if test "x$has_colon" = x; then 53659 # Not in mixed or Windows style, start by that. 53660 new_path=`cmd //c echo $path` 53661 fi 53662 53663 53664 input_path="$new_path" 53665 # Check if we need to convert this using DOS-style short mode. If the path 53666 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53667 # take no chances and rewrite it. 53668 # Note: m4 eats our [], so we need to use [ and ] instead. 53669 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 53670 if test "x$has_forbidden_chars" != x; then 53671 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53672 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53673 fi 53674 53675 53676 windows_path="$new_path" 53677 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53678 unix_path=`$CYGPATH -u "$windows_path"` 53679 new_path="$unix_path" 53680 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53681 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 53682 new_path="$unix_path" 53683 fi 53684 53685 if test "x$path" != "x$new_path"; then 53686 MSVC_DLL="$new_path" 53687 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 53688 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 53689 fi 53690 53691 # Save the first 10 bytes of this path to the storage, so fixpath can work. 53692 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 53693 53694 else 53695 # We're on a unix platform. Hooray! :) 53696 path="$MSVC_DLL" 53697 has_space=`$ECHO "$path" | $GREP " "` 53698 if test "x$has_space" != x; then 53699 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 53700 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 53701 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 53702 fi 53703 53704 # Use eval to expand a potential ~ 53705 eval path="$path" 53706 if test ! -f "$path" && test ! -d "$path"; then 53707 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 53708 fi 53709 53710 if test -d "$path"; then 53711 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 53712 else 53713 dir="`$DIRNAME "$path"`" 53714 base="`$BASENAME "$path"`" 53715 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 53716 fi 53717 fi 53718 fi 53719 53720 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 53721 $as_echo_n "checking for $DLL_NAME... " >&6; } 53722 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 53723 $as_echo "$MSVC_DLL" >&6; } 53724 else 53725 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 53726 $as_echo "incorrect, ignoring" >&6; } 53727 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 53728 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 53729 fi 53730 fi 53731 53732 fi 53733 fi 53734 53735 if test "x$MSVC_DLL" = x; then 53736 # Probe: Check in the Boot JDK directory. 53737 POSSIBLE_MSVC_DLL="$BOOT_JDK/bin/$DLL_NAME" 53738 53739 DLL_NAME="$DLL_NAME" 53740 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 53741 METHOD="well-known location in Boot JDK" 53742 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 53743 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 53744 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 53745 53746 # Need to check if the found msvcr is correct architecture 53747 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 53748 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 53749 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 53750 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53751 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 53752 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 53753 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53754 CORRECT_MSVCR_ARCH="PE32 executable" 53755 else 53756 CORRECT_MSVCR_ARCH="PE32+ executable" 53757 fi 53758 else 53759 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53760 CORRECT_MSVCR_ARCH=386 53761 else 53762 CORRECT_MSVCR_ARCH=x86-64 53763 fi 53764 fi 53765 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 53766 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 53767 $as_echo "ok" >&6; } 53768 MSVC_DLL="$POSSIBLE_MSVC_DLL" 53769 53770 # Only process if variable expands to non-empty 53771 53772 if test "x$MSVC_DLL" != x; then 53773 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53774 53775 # Input might be given as Windows format, start by converting to 53776 # unix format. 53777 path="$MSVC_DLL" 53778 new_path=`$CYGPATH -u "$path"` 53779 53780 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 53781 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 53782 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 53783 # "foo.exe" is OK but "foo" is an error. 53784 # 53785 # This test is therefore slightly more accurate than "test -f" to check for file precense. 53786 # It is also a way to make sure we got the proper file name for the real test later on. 53787 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 53788 if test "x$test_shortpath" = x; then 53789 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 53790 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 53791 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 53792 fi 53793 53794 # Call helper function which possibly converts this using DOS-style short mode. 53795 # If so, the updated path is stored in $new_path. 53796 53797 input_path="$new_path" 53798 # Check if we need to convert this using DOS-style short mode. If the path 53799 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53800 # take no chances and rewrite it. 53801 # Note: m4 eats our [], so we need to use [ and ] instead. 53802 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 53803 if test "x$has_forbidden_chars" != x; then 53804 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53805 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 53806 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 53807 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 53808 # Going to short mode and back again did indeed matter. Since short mode is 53809 # case insensitive, let's make it lowercase to improve readability. 53810 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53811 # Now convert it back to Unix-style (cygpath) 53812 input_path=`$CYGPATH -u "$shortmode_path"` 53813 new_path="$input_path" 53814 fi 53815 fi 53816 53817 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 53818 if test "x$test_cygdrive_prefix" = x; then 53819 # As a simple fix, exclude /usr/bin since it's not a real path. 53820 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 53821 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 53822 # a path prefixed by /cygdrive for fixpath to work. 53823 new_path="$CYGWIN_ROOT_PATH$input_path" 53824 fi 53825 fi 53826 53827 53828 if test "x$path" != "x$new_path"; then 53829 MSVC_DLL="$new_path" 53830 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 53831 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 53832 fi 53833 53834 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53835 53836 path="$MSVC_DLL" 53837 has_colon=`$ECHO $path | $GREP ^.:` 53838 new_path="$path" 53839 if test "x$has_colon" = x; then 53840 # Not in mixed or Windows style, start by that. 53841 new_path=`cmd //c echo $path` 53842 fi 53843 53844 53845 input_path="$new_path" 53846 # Check if we need to convert this using DOS-style short mode. If the path 53847 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53848 # take no chances and rewrite it. 53849 # Note: m4 eats our [], so we need to use [ and ] instead. 53850 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 53851 if test "x$has_forbidden_chars" != x; then 53852 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53853 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53854 fi 53855 53856 53857 windows_path="$new_path" 53858 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53859 unix_path=`$CYGPATH -u "$windows_path"` 53860 new_path="$unix_path" 53861 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53862 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 53863 new_path="$unix_path" 53864 fi 53865 53866 if test "x$path" != "x$new_path"; then 53867 MSVC_DLL="$new_path" 53868 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 53869 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 53870 fi 53871 53872 # Save the first 10 bytes of this path to the storage, so fixpath can work. 53873 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 53874 53875 else 53876 # We're on a unix platform. Hooray! :) 53877 path="$MSVC_DLL" 53878 has_space=`$ECHO "$path" | $GREP " "` 53879 if test "x$has_space" != x; then 53880 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 53881 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 53882 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 53883 fi 53884 53885 # Use eval to expand a potential ~ 53886 eval path="$path" 53887 if test ! -f "$path" && test ! -d "$path"; then 53888 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 53889 fi 53890 53891 if test -d "$path"; then 53892 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 53893 else 53894 dir="`$DIRNAME "$path"`" 53895 base="`$BASENAME "$path"`" 53896 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 53897 fi 53898 fi 53899 fi 53900 53901 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 53902 $as_echo_n "checking for $DLL_NAME... " >&6; } 53903 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 53904 $as_echo "$MSVC_DLL" >&6; } 53905 else 53906 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 53907 $as_echo "incorrect, ignoring" >&6; } 53908 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 53909 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 53910 fi 53911 fi 53912 53913 fi 53914 53915 if test "x$MSVC_DLL" = x; then 53916 # Probe: Look in the Windows system32 directory 53917 CYGWIN_SYSTEMROOT="$SYSTEMROOT" 53918 53919 windows_path="$CYGWIN_SYSTEMROOT" 53920 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53921 unix_path=`$CYGPATH -u "$windows_path"` 53922 CYGWIN_SYSTEMROOT="$unix_path" 53923 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53924 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 53925 CYGWIN_SYSTEMROOT="$unix_path" 53926 fi 53927 53928 POSSIBLE_MSVC_DLL="$CYGWIN_SYSTEMROOT/system32/$DLL_NAME" 53929 53930 DLL_NAME="$DLL_NAME" 53931 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 53932 METHOD="well-known location in SYSTEMROOT" 53933 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 53934 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 53935 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 53936 53937 # Need to check if the found msvcr is correct architecture 53938 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 53939 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 53940 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 53941 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53942 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 53943 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 53944 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53945 CORRECT_MSVCR_ARCH="PE32 executable" 53946 else 53947 CORRECT_MSVCR_ARCH="PE32+ executable" 53948 fi 53949 else 53950 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 53951 CORRECT_MSVCR_ARCH=386 53952 else 53953 CORRECT_MSVCR_ARCH=x86-64 53954 fi 53955 fi 53956 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 53957 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 53958 $as_echo "ok" >&6; } 53959 MSVC_DLL="$POSSIBLE_MSVC_DLL" 53960 53961 # Only process if variable expands to non-empty 53962 53963 if test "x$MSVC_DLL" != x; then 53964 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53965 53966 # Input might be given as Windows format, start by converting to 53967 # unix format. 53968 path="$MSVC_DLL" 53969 new_path=`$CYGPATH -u "$path"` 53970 53971 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 53972 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 53973 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 53974 # "foo.exe" is OK but "foo" is an error. 53975 # 53976 # This test is therefore slightly more accurate than "test -f" to check for file precense. 53977 # It is also a way to make sure we got the proper file name for the real test later on. 53978 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 53979 if test "x$test_shortpath" = x; then 53980 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 53981 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 53982 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 53983 fi 53984 53985 # Call helper function which possibly converts this using DOS-style short mode. 53986 # If so, the updated path is stored in $new_path. 53987 53988 input_path="$new_path" 53989 # Check if we need to convert this using DOS-style short mode. If the path 53990 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53991 # take no chances and rewrite it. 53992 # Note: m4 eats our [], so we need to use [ and ] instead. 53993 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 53994 if test "x$has_forbidden_chars" != x; then 53995 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53996 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 53997 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 53998 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 53999 # Going to short mode and back again did indeed matter. Since short mode is 54000 # case insensitive, let's make it lowercase to improve readability. 54001 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54002 # Now convert it back to Unix-style (cygpath) 54003 input_path=`$CYGPATH -u "$shortmode_path"` 54004 new_path="$input_path" 54005 fi 54006 fi 54007 54008 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 54009 if test "x$test_cygdrive_prefix" = x; then 54010 # As a simple fix, exclude /usr/bin since it's not a real path. 54011 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 54012 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 54013 # a path prefixed by /cygdrive for fixpath to work. 54014 new_path="$CYGWIN_ROOT_PATH$input_path" 54015 fi 54016 fi 54017 54018 54019 if test "x$path" != "x$new_path"; then 54020 MSVC_DLL="$new_path" 54021 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54022 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54023 fi 54024 54025 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54026 54027 path="$MSVC_DLL" 54028 has_colon=`$ECHO $path | $GREP ^.:` 54029 new_path="$path" 54030 if test "x$has_colon" = x; then 54031 # Not in mixed or Windows style, start by that. 54032 new_path=`cmd //c echo $path` 54033 fi 54034 54035 54036 input_path="$new_path" 54037 # Check if we need to convert this using DOS-style short mode. If the path 54038 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54039 # take no chances and rewrite it. 54040 # Note: m4 eats our [], so we need to use [ and ] instead. 54041 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 54042 if test "x$has_forbidden_chars" != x; then 54043 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54044 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54045 fi 54046 54047 54048 windows_path="$new_path" 54049 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54050 unix_path=`$CYGPATH -u "$windows_path"` 54051 new_path="$unix_path" 54052 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54053 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54054 new_path="$unix_path" 54055 fi 54056 54057 if test "x$path" != "x$new_path"; then 54058 MSVC_DLL="$new_path" 54059 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54060 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54061 fi 54062 54063 # Save the first 10 bytes of this path to the storage, so fixpath can work. 54064 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 54065 54066 else 54067 # We're on a unix platform. Hooray! :) 54068 path="$MSVC_DLL" 54069 has_space=`$ECHO "$path" | $GREP " "` 54070 if test "x$has_space" != x; then 54071 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54072 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54073 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 54074 fi 54075 54076 # Use eval to expand a potential ~ 54077 eval path="$path" 54078 if test ! -f "$path" && test ! -d "$path"; then 54079 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 54080 fi 54081 54082 if test -d "$path"; then 54083 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 54084 else 54085 dir="`$DIRNAME "$path"`" 54086 base="`$BASENAME "$path"`" 54087 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 54088 fi 54089 fi 54090 fi 54091 54092 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 54093 $as_echo_n "checking for $DLL_NAME... " >&6; } 54094 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 54095 $as_echo "$MSVC_DLL" >&6; } 54096 else 54097 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 54098 $as_echo "incorrect, ignoring" >&6; } 54099 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 54100 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 54101 fi 54102 fi 54103 54104 fi 54105 54106 if test "x$MSVC_DLL" = x; then 54107 # Probe: If Visual Studio Express is installed, there is usually one with the debugger 54108 if test "x$VS100COMNTOOLS" != x; then 54109 CYGWIN_VS_TOOLS_DIR="$VS100COMNTOOLS/.." 54110 54111 windows_path="$CYGWIN_VS_TOOLS_DIR" 54112 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54113 unix_path=`$CYGPATH -u "$windows_path"` 54114 CYGWIN_VS_TOOLS_DIR="$unix_path" 54115 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54116 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54117 CYGWIN_VS_TOOLS_DIR="$unix_path" 54118 fi 54119 54120 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 54121 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name $DLL_NAME \ 54122 | $GREP -i /x64/ | $HEAD --lines 1` 54123 else 54124 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name $DLL_NAME \ 54125 | $GREP -i /x86/ | $HEAD --lines 1` 54126 fi 54127 54128 DLL_NAME="$DLL_NAME" 54129 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 54130 METHOD="search of VS100COMNTOOLS" 54131 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 54132 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 54133 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 54134 54135 # Need to check if the found msvcr is correct architecture 54136 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 54137 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 54138 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 54139 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54140 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 54141 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 54142 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54143 CORRECT_MSVCR_ARCH="PE32 executable" 54144 else 54145 CORRECT_MSVCR_ARCH="PE32+ executable" 54146 fi 54147 else 54148 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54149 CORRECT_MSVCR_ARCH=386 54150 else 54151 CORRECT_MSVCR_ARCH=x86-64 54152 fi 54153 fi 54154 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 54155 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 54156 $as_echo "ok" >&6; } 54157 MSVC_DLL="$POSSIBLE_MSVC_DLL" 54158 54159 # Only process if variable expands to non-empty 54160 54161 if test "x$MSVC_DLL" != x; then 54162 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54163 54164 # Input might be given as Windows format, start by converting to 54165 # unix format. 54166 path="$MSVC_DLL" 54167 new_path=`$CYGPATH -u "$path"` 54168 54169 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 54170 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 54171 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 54172 # "foo.exe" is OK but "foo" is an error. 54173 # 54174 # This test is therefore slightly more accurate than "test -f" to check for file precense. 54175 # It is also a way to make sure we got the proper file name for the real test later on. 54176 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 54177 if test "x$test_shortpath" = x; then 54178 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54179 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54180 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 54181 fi 54182 54183 # Call helper function which possibly converts this using DOS-style short mode. 54184 # If so, the updated path is stored in $new_path. 54185 54186 input_path="$new_path" 54187 # Check if we need to convert this using DOS-style short mode. If the path 54188 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54189 # take no chances and rewrite it. 54190 # Note: m4 eats our [], so we need to use [ and ] instead. 54191 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 54192 if test "x$has_forbidden_chars" != x; then 54193 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54194 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 54195 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 54196 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 54197 # Going to short mode and back again did indeed matter. Since short mode is 54198 # case insensitive, let's make it lowercase to improve readability. 54199 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54200 # Now convert it back to Unix-style (cygpath) 54201 input_path=`$CYGPATH -u "$shortmode_path"` 54202 new_path="$input_path" 54203 fi 54204 fi 54205 54206 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 54207 if test "x$test_cygdrive_prefix" = x; then 54208 # As a simple fix, exclude /usr/bin since it's not a real path. 54209 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 54210 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 54211 # a path prefixed by /cygdrive for fixpath to work. 54212 new_path="$CYGWIN_ROOT_PATH$input_path" 54213 fi 54214 fi 54215 54216 54217 if test "x$path" != "x$new_path"; then 54218 MSVC_DLL="$new_path" 54219 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54220 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54221 fi 54222 54223 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54224 54225 path="$MSVC_DLL" 54226 has_colon=`$ECHO $path | $GREP ^.:` 54227 new_path="$path" 54228 if test "x$has_colon" = x; then 54229 # Not in mixed or Windows style, start by that. 54230 new_path=`cmd //c echo $path` 54231 fi 54232 54233 54234 input_path="$new_path" 54235 # Check if we need to convert this using DOS-style short mode. If the path 54236 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54237 # take no chances and rewrite it. 54238 # Note: m4 eats our [], so we need to use [ and ] instead. 54239 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 54240 if test "x$has_forbidden_chars" != x; then 54241 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54242 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54243 fi 54244 54245 54246 windows_path="$new_path" 54247 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54248 unix_path=`$CYGPATH -u "$windows_path"` 54249 new_path="$unix_path" 54250 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54251 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54252 new_path="$unix_path" 54253 fi 54254 54255 if test "x$path" != "x$new_path"; then 54256 MSVC_DLL="$new_path" 54257 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54258 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54259 fi 54260 54261 # Save the first 10 bytes of this path to the storage, so fixpath can work. 54262 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 54263 54264 else 54265 # We're on a unix platform. Hooray! :) 54266 path="$MSVC_DLL" 54267 has_space=`$ECHO "$path" | $GREP " "` 54268 if test "x$has_space" != x; then 54269 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54270 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54271 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 54272 fi 54273 54274 # Use eval to expand a potential ~ 54275 eval path="$path" 54276 if test ! -f "$path" && test ! -d "$path"; then 54277 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 54278 fi 54279 54280 if test -d "$path"; then 54281 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 54282 else 54283 dir="`$DIRNAME "$path"`" 54284 base="`$BASENAME "$path"`" 54285 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 54286 fi 54287 fi 54288 fi 54289 54290 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 54291 $as_echo_n "checking for $DLL_NAME... " >&6; } 54292 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 54293 $as_echo "$MSVC_DLL" >&6; } 54294 else 54295 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 54296 $as_echo "incorrect, ignoring" >&6; } 54297 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 54298 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 54299 fi 54300 fi 54301 54302 fi 54303 fi 54304 54305 if test "x$MSVC_DLL" = x; then 54306 # Probe: Search wildly in the VCINSTALLDIR. We've probably lost by now. 54307 # (This was the original behaviour; kept since it might turn something up) 54308 if test "x$CYGWIN_VC_INSTALL_DIR" != x; then 54309 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 54310 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 54311 | $GREP x64 | $HEAD --lines 1` 54312 else 54313 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 54314 | $GREP x86 | $GREP -v ia64 | $GREP -v x64 | $HEAD --lines 1` 54315 if test "x$POSSIBLE_MSVC_DLL" = x; then 54316 # We're grasping at straws now... 54317 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 54318 | $HEAD --lines 1` 54319 fi 54320 fi 54321 54322 54323 DLL_NAME="$DLL_NAME" 54324 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 54325 METHOD="search of VCINSTALLDIR" 54326 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 54327 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 54328 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 54329 54330 # Need to check if the found msvcr is correct architecture 54331 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 54332 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 54333 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 54334 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54335 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 54336 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 54337 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54338 CORRECT_MSVCR_ARCH="PE32 executable" 54339 else 54340 CORRECT_MSVCR_ARCH="PE32+ executable" 54341 fi 54342 else 54343 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54344 CORRECT_MSVCR_ARCH=386 54345 else 54346 CORRECT_MSVCR_ARCH=x86-64 54347 fi 54348 fi 54349 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 54350 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 54351 $as_echo "ok" >&6; } 54352 MSVC_DLL="$POSSIBLE_MSVC_DLL" 54353 54354 # Only process if variable expands to non-empty 54355 54356 if test "x$MSVC_DLL" != x; then 54357 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54358 54359 # Input might be given as Windows format, start by converting to 54360 # unix format. 54361 path="$MSVC_DLL" 54362 new_path=`$CYGPATH -u "$path"` 54363 54364 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 54365 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 54366 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 54367 # "foo.exe" is OK but "foo" is an error. 54368 # 54369 # This test is therefore slightly more accurate than "test -f" to check for file precense. 54370 # It is also a way to make sure we got the proper file name for the real test later on. 54371 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 54372 if test "x$test_shortpath" = x; then 54373 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54374 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54375 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 54376 fi 54377 54378 # Call helper function which possibly converts this using DOS-style short mode. 54379 # If so, the updated path is stored in $new_path. 54380 54381 input_path="$new_path" 54382 # Check if we need to convert this using DOS-style short mode. If the path 54383 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54384 # take no chances and rewrite it. 54385 # Note: m4 eats our [], so we need to use [ and ] instead. 54386 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 54387 if test "x$has_forbidden_chars" != x; then 54388 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54389 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 54390 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 54391 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 54392 # Going to short mode and back again did indeed matter. Since short mode is 54393 # case insensitive, let's make it lowercase to improve readability. 54394 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54395 # Now convert it back to Unix-style (cygpath) 54396 input_path=`$CYGPATH -u "$shortmode_path"` 54397 new_path="$input_path" 54398 fi 54399 fi 54400 54401 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 54402 if test "x$test_cygdrive_prefix" = x; then 54403 # As a simple fix, exclude /usr/bin since it's not a real path. 54404 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 54405 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 54406 # a path prefixed by /cygdrive for fixpath to work. 54407 new_path="$CYGWIN_ROOT_PATH$input_path" 54408 fi 54409 fi 54410 54411 54412 if test "x$path" != "x$new_path"; then 54413 MSVC_DLL="$new_path" 54414 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54415 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54416 fi 54417 54418 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54419 54420 path="$MSVC_DLL" 54421 has_colon=`$ECHO $path | $GREP ^.:` 54422 new_path="$path" 54423 if test "x$has_colon" = x; then 54424 # Not in mixed or Windows style, start by that. 54425 new_path=`cmd //c echo $path` 54426 fi 54427 54428 54429 input_path="$new_path" 54430 # Check if we need to convert this using DOS-style short mode. If the path 54431 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54432 # take no chances and rewrite it. 54433 # Note: m4 eats our [], so we need to use [ and ] instead. 54434 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 54435 if test "x$has_forbidden_chars" != x; then 54436 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54437 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54438 fi 54439 54440 54441 windows_path="$new_path" 54442 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54443 unix_path=`$CYGPATH -u "$windows_path"` 54444 new_path="$unix_path" 54445 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54446 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54447 new_path="$unix_path" 54448 fi 54449 54450 if test "x$path" != "x$new_path"; then 54451 MSVC_DLL="$new_path" 54452 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54453 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54454 fi 54455 54456 # Save the first 10 bytes of this path to the storage, so fixpath can work. 54457 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 54458 54459 else 54460 # We're on a unix platform. Hooray! :) 54461 path="$MSVC_DLL" 54462 has_space=`$ECHO "$path" | $GREP " "` 54463 if test "x$has_space" != x; then 54464 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54465 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54466 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 54467 fi 54468 54469 # Use eval to expand a potential ~ 54470 eval path="$path" 54471 if test ! -f "$path" && test ! -d "$path"; then 54472 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 54473 fi 54474 54475 if test -d "$path"; then 54476 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 54477 else 54478 dir="`$DIRNAME "$path"`" 54479 base="`$BASENAME "$path"`" 54480 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 54481 fi 54482 fi 54483 fi 54484 54485 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 54486 $as_echo_n "checking for $DLL_NAME... " >&6; } 54487 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 54488 $as_echo "$MSVC_DLL" >&6; } 54489 else 54490 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 54491 $as_echo "incorrect, ignoring" >&6; } 54492 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 54493 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 54494 fi 54495 fi 54496 54497 fi 54498 fi 54499 54500 if test "x$MSVC_DLL" = x; then 54501 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 54502 $as_echo_n "checking for $DLL_NAME... " >&6; } 54503 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 54504 $as_echo "no" >&6; } 54505 as_fn_error $? "Could not find $DLL_NAME. Please specify using --with-msvcr-dll." "$LINENO" 5 54506 fi 54507 54508 MSVCR_DLL="$MSVC_DLL" 54509 fi 54510 54511 54512 54513 # Check whether --with-msvcp-dll was given. 54514 if test "${with_msvcp_dll+set}" = set; then : 54515 withval=$with_msvcp_dll; 54516 fi 54517 54518 54519 if test "x$MSVCP_NAME" != "x"; then 54520 if test "x$with_msvcp_dll" != x; then 54521 # If given explicitely by user, do not probe. If not present, fail directly. 54522 54523 DLL_NAME="$MSVCP_NAME" 54524 POSSIBLE_MSVC_DLL="$with_msvcp_dll" 54525 METHOD="--with-msvcp-dll" 54526 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 54527 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 54528 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 54529 54530 # Need to check if the found msvcr is correct architecture 54531 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 54532 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 54533 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 54534 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54535 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 54536 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 54537 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54538 CORRECT_MSVCR_ARCH="PE32 executable" 54539 else 54540 CORRECT_MSVCR_ARCH="PE32+ executable" 54541 fi 54542 else 54543 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54544 CORRECT_MSVCR_ARCH=386 54545 else 54546 CORRECT_MSVCR_ARCH=x86-64 54547 fi 54548 fi 54549 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 54550 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 54551 $as_echo "ok" >&6; } 54552 MSVC_DLL="$POSSIBLE_MSVC_DLL" 54553 54554 # Only process if variable expands to non-empty 54555 54556 if test "x$MSVC_DLL" != x; then 54557 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54558 54559 # Input might be given as Windows format, start by converting to 54560 # unix format. 54561 path="$MSVC_DLL" 54562 new_path=`$CYGPATH -u "$path"` 54563 54564 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 54565 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 54566 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 54567 # "foo.exe" is OK but "foo" is an error. 54568 # 54569 # This test is therefore slightly more accurate than "test -f" to check for file precense. 54570 # It is also a way to make sure we got the proper file name for the real test later on. 54571 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 54572 if test "x$test_shortpath" = x; then 54573 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54574 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54575 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 54576 fi 54577 54578 # Call helper function which possibly converts this using DOS-style short mode. 54579 # If so, the updated path is stored in $new_path. 54580 54581 input_path="$new_path" 54582 # Check if we need to convert this using DOS-style short mode. If the path 54583 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54584 # take no chances and rewrite it. 54585 # Note: m4 eats our [], so we need to use [ and ] instead. 54586 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 54587 if test "x$has_forbidden_chars" != x; then 54588 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54589 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 54590 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 54591 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 54592 # Going to short mode and back again did indeed matter. Since short mode is 54593 # case insensitive, let's make it lowercase to improve readability. 54594 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54595 # Now convert it back to Unix-style (cygpath) 54596 input_path=`$CYGPATH -u "$shortmode_path"` 54597 new_path="$input_path" 54598 fi 54599 fi 54600 54601 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 54602 if test "x$test_cygdrive_prefix" = x; then 54603 # As a simple fix, exclude /usr/bin since it's not a real path. 54604 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 54605 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 54606 # a path prefixed by /cygdrive for fixpath to work. 54607 new_path="$CYGWIN_ROOT_PATH$input_path" 54608 fi 54609 fi 54610 54611 54612 if test "x$path" != "x$new_path"; then 54613 MSVC_DLL="$new_path" 54614 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54615 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54616 fi 54617 54618 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54619 54620 path="$MSVC_DLL" 54621 has_colon=`$ECHO $path | $GREP ^.:` 54622 new_path="$path" 54623 if test "x$has_colon" = x; then 54624 # Not in mixed or Windows style, start by that. 54625 new_path=`cmd //c echo $path` 54626 fi 54627 54628 54629 input_path="$new_path" 54630 # Check if we need to convert this using DOS-style short mode. If the path 54631 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54632 # take no chances and rewrite it. 54633 # Note: m4 eats our [], so we need to use [ and ] instead. 54634 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 54635 if test "x$has_forbidden_chars" != x; then 54636 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54637 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54638 fi 54639 54640 54641 windows_path="$new_path" 54642 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54643 unix_path=`$CYGPATH -u "$windows_path"` 54644 new_path="$unix_path" 54645 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54646 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54647 new_path="$unix_path" 54648 fi 54649 54650 if test "x$path" != "x$new_path"; then 54651 MSVC_DLL="$new_path" 54652 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54653 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54654 fi 54655 54656 # Save the first 10 bytes of this path to the storage, so fixpath can work. 54657 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 54658 54659 else 54660 # We're on a unix platform. Hooray! :) 54661 path="$MSVC_DLL" 54662 has_space=`$ECHO "$path" | $GREP " "` 54663 if test "x$has_space" != x; then 54664 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54665 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54666 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 54667 fi 54668 54669 # Use eval to expand a potential ~ 54670 eval path="$path" 54671 if test ! -f "$path" && test ! -d "$path"; then 54672 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 54673 fi 54674 54675 if test -d "$path"; then 54676 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 54677 else 54678 dir="`$DIRNAME "$path"`" 54679 base="`$BASENAME "$path"`" 54680 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 54681 fi 54682 fi 54683 fi 54684 54685 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 54686 $as_echo_n "checking for $DLL_NAME... " >&6; } 54687 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 54688 $as_echo "$MSVC_DLL" >&6; } 54689 else 54690 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 54691 $as_echo "incorrect, ignoring" >&6; } 54692 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 54693 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 54694 fi 54695 fi 54696 54697 if test "x$MSVC_DLL" = x; then 54698 as_fn_error $? "Could not find a proper $MSVCP_NAME as specified by --with-msvcp-dll" "$LINENO" 5 54699 fi 54700 MSVCP_DLL="$MSVC_DLL" 54701 elif test "x$DEVKIT_MSVCP_DLL" != x; then 54702 54703 DLL_NAME="$MSVCP_NAME" 54704 POSSIBLE_MSVC_DLL="$DEVKIT_MSVCP_DLL" 54705 METHOD="devkit" 54706 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 54707 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 54708 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 54709 54710 # Need to check if the found msvcr is correct architecture 54711 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 54712 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 54713 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 54714 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54715 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 54716 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 54717 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54718 CORRECT_MSVCR_ARCH="PE32 executable" 54719 else 54720 CORRECT_MSVCR_ARCH="PE32+ executable" 54721 fi 54722 else 54723 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54724 CORRECT_MSVCR_ARCH=386 54725 else 54726 CORRECT_MSVCR_ARCH=x86-64 54727 fi 54728 fi 54729 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 54730 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 54731 $as_echo "ok" >&6; } 54732 MSVC_DLL="$POSSIBLE_MSVC_DLL" 54733 54734 # Only process if variable expands to non-empty 54735 54736 if test "x$MSVC_DLL" != x; then 54737 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54738 54739 # Input might be given as Windows format, start by converting to 54740 # unix format. 54741 path="$MSVC_DLL" 54742 new_path=`$CYGPATH -u "$path"` 54743 54744 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 54745 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 54746 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 54747 # "foo.exe" is OK but "foo" is an error. 54748 # 54749 # This test is therefore slightly more accurate than "test -f" to check for file precense. 54750 # It is also a way to make sure we got the proper file name for the real test later on. 54751 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 54752 if test "x$test_shortpath" = x; then 54753 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54754 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54755 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 54756 fi 54757 54758 # Call helper function which possibly converts this using DOS-style short mode. 54759 # If so, the updated path is stored in $new_path. 54760 54761 input_path="$new_path" 54762 # Check if we need to convert this using DOS-style short mode. If the path 54763 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54764 # take no chances and rewrite it. 54765 # Note: m4 eats our [], so we need to use [ and ] instead. 54766 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 54767 if test "x$has_forbidden_chars" != x; then 54768 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54769 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 54770 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 54771 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 54772 # Going to short mode and back again did indeed matter. Since short mode is 54773 # case insensitive, let's make it lowercase to improve readability. 54774 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54775 # Now convert it back to Unix-style (cygpath) 54776 input_path=`$CYGPATH -u "$shortmode_path"` 54777 new_path="$input_path" 54778 fi 54779 fi 54780 54781 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 54782 if test "x$test_cygdrive_prefix" = x; then 54783 # As a simple fix, exclude /usr/bin since it's not a real path. 54784 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 54785 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 54786 # a path prefixed by /cygdrive for fixpath to work. 54787 new_path="$CYGWIN_ROOT_PATH$input_path" 54788 fi 54789 fi 54790 54791 54792 if test "x$path" != "x$new_path"; then 54793 MSVC_DLL="$new_path" 54794 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54795 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54796 fi 54797 54798 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54799 54800 path="$MSVC_DLL" 54801 has_colon=`$ECHO $path | $GREP ^.:` 54802 new_path="$path" 54803 if test "x$has_colon" = x; then 54804 # Not in mixed or Windows style, start by that. 54805 new_path=`cmd //c echo $path` 54806 fi 54807 54808 54809 input_path="$new_path" 54810 # Check if we need to convert this using DOS-style short mode. If the path 54811 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54812 # take no chances and rewrite it. 54813 # Note: m4 eats our [], so we need to use [ and ] instead. 54814 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 54815 if test "x$has_forbidden_chars" != x; then 54816 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54817 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54818 fi 54819 54820 54821 windows_path="$new_path" 54822 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54823 unix_path=`$CYGPATH -u "$windows_path"` 54824 new_path="$unix_path" 54825 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54826 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54827 new_path="$unix_path" 54828 fi 54829 54830 if test "x$path" != "x$new_path"; then 54831 MSVC_DLL="$new_path" 54832 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54833 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 54834 fi 54835 54836 # Save the first 10 bytes of this path to the storage, so fixpath can work. 54837 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 54838 54839 else 54840 # We're on a unix platform. Hooray! :) 54841 path="$MSVC_DLL" 54842 has_space=`$ECHO "$path" | $GREP " "` 54843 if test "x$has_space" != x; then 54844 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54845 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54846 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 54847 fi 54848 54849 # Use eval to expand a potential ~ 54850 eval path="$path" 54851 if test ! -f "$path" && test ! -d "$path"; then 54852 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 54853 fi 54854 54855 if test -d "$path"; then 54856 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 54857 else 54858 dir="`$DIRNAME "$path"`" 54859 base="`$BASENAME "$path"`" 54860 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 54861 fi 54862 fi 54863 fi 54864 54865 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 54866 $as_echo_n "checking for $DLL_NAME... " >&6; } 54867 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 54868 $as_echo "$MSVC_DLL" >&6; } 54869 else 54870 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 54871 $as_echo "incorrect, ignoring" >&6; } 54872 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 54873 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 54874 fi 54875 fi 54876 54877 if test "x$MSVC_DLL" = x; then 54878 as_fn_error $? "Could not find a proper $MSVCP_NAME as specified by devkit" "$LINENO" 5 54879 fi 54880 MSVCP_DLL="$MSVC_DLL" 54881 else 54882 54883 DLL_NAME="${MSVCP_NAME}" 54884 MSVC_DLL= 54885 54886 if test "x$MSVC_DLL" = x; then 54887 # Probe: Using well-known location from Visual Studio 10.0 54888 if test "x$VCINSTALLDIR" != x; then 54889 CYGWIN_VC_INSTALL_DIR="$VCINSTALLDIR" 54890 54891 windows_path="$CYGWIN_VC_INSTALL_DIR" 54892 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54893 unix_path=`$CYGPATH -u "$windows_path"` 54894 CYGWIN_VC_INSTALL_DIR="$unix_path" 54895 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54896 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54897 CYGWIN_VC_INSTALL_DIR="$unix_path" 54898 fi 54899 54900 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 54901 POSSIBLE_MSVC_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x64/Microsoft.VC${VS_VERSION_INTERNAL}.CRT/$DLL_NAME" 54902 else 54903 POSSIBLE_MSVC_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x86/Microsoft.VC${VS_VERSION_INTERNAL}.CRT/$DLL_NAME" 54904 fi 54905 $ECHO "POSSIBLE_MSVC_DLL $POSSIBLEMSVC_DLL" 54906 54907 DLL_NAME="$DLL_NAME" 54908 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 54909 METHOD="well-known location in VCINSTALLDIR" 54910 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 54911 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 54912 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 54913 54914 # Need to check if the found msvcr is correct architecture 54915 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 54916 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 54917 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 54918 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54919 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 54920 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 54921 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54922 CORRECT_MSVCR_ARCH="PE32 executable" 54923 else 54924 CORRECT_MSVCR_ARCH="PE32+ executable" 54925 fi 54926 else 54927 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 54928 CORRECT_MSVCR_ARCH=386 54929 else 54930 CORRECT_MSVCR_ARCH=x86-64 54931 fi 54932 fi 54933 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 54934 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 54935 $as_echo "ok" >&6; } 54936 MSVC_DLL="$POSSIBLE_MSVC_DLL" 54937 54938 # Only process if variable expands to non-empty 54939 54940 if test "x$MSVC_DLL" != x; then 54941 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54942 54943 # Input might be given as Windows format, start by converting to 54944 # unix format. 54945 path="$MSVC_DLL" 54946 new_path=`$CYGPATH -u "$path"` 54947 54948 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 54949 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 54950 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 54951 # "foo.exe" is OK but "foo" is an error. 54952 # 54953 # This test is therefore slightly more accurate than "test -f" to check for file precense. 54954 # It is also a way to make sure we got the proper file name for the real test later on. 54955 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 54956 if test "x$test_shortpath" = x; then 54957 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 54958 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 54959 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 54960 fi 54961 54962 # Call helper function which possibly converts this using DOS-style short mode. 54963 # If so, the updated path is stored in $new_path. 54964 54965 input_path="$new_path" 54966 # Check if we need to convert this using DOS-style short mode. If the path 54967 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54968 # take no chances and rewrite it. 54969 # Note: m4 eats our [], so we need to use [ and ] instead. 54970 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 54971 if test "x$has_forbidden_chars" != x; then 54972 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54973 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 54974 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 54975 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 54976 # Going to short mode and back again did indeed matter. Since short mode is 54977 # case insensitive, let's make it lowercase to improve readability. 54978 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54979 # Now convert it back to Unix-style (cygpath) 54980 input_path=`$CYGPATH -u "$shortmode_path"` 54981 new_path="$input_path" 54982 fi 54983 fi 54984 54985 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 54986 if test "x$test_cygdrive_prefix" = x; then 54987 # As a simple fix, exclude /usr/bin since it's not a real path. 54988 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 54989 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 54990 # a path prefixed by /cygdrive for fixpath to work. 54991 new_path="$CYGWIN_ROOT_PATH$input_path" 54992 fi 54993 fi 54994 54995 54996 if test "x$path" != "x$new_path"; then 54997 MSVC_DLL="$new_path" 54998 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 54999 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55000 fi 55001 55002 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55003 55004 path="$MSVC_DLL" 55005 has_colon=`$ECHO $path | $GREP ^.:` 55006 new_path="$path" 55007 if test "x$has_colon" = x; then 55008 # Not in mixed or Windows style, start by that. 55009 new_path=`cmd //c echo $path` 55010 fi 55011 55012 55013 input_path="$new_path" 55014 # Check if we need to convert this using DOS-style short mode. If the path 55015 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55016 # take no chances and rewrite it. 55017 # Note: m4 eats our [], so we need to use [ and ] instead. 55018 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55019 if test "x$has_forbidden_chars" != x; then 55020 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55021 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55022 fi 55023 55024 55025 windows_path="$new_path" 55026 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55027 unix_path=`$CYGPATH -u "$windows_path"` 55028 new_path="$unix_path" 55029 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55030 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55031 new_path="$unix_path" 55032 fi 55033 55034 if test "x$path" != "x$new_path"; then 55035 MSVC_DLL="$new_path" 55036 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55037 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55038 fi 55039 55040 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55041 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55042 55043 else 55044 # We're on a unix platform. Hooray! :) 55045 path="$MSVC_DLL" 55046 has_space=`$ECHO "$path" | $GREP " "` 55047 if test "x$has_space" != x; then 55048 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55049 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55050 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55051 fi 55052 55053 # Use eval to expand a potential ~ 55054 eval path="$path" 55055 if test ! -f "$path" && test ! -d "$path"; then 55056 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 55057 fi 55058 55059 if test -d "$path"; then 55060 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 55061 else 55062 dir="`$DIRNAME "$path"`" 55063 base="`$BASENAME "$path"`" 55064 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 55065 fi 55066 fi 55067 fi 55068 55069 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55070 $as_echo_n "checking for $DLL_NAME... " >&6; } 55071 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 55072 $as_echo "$MSVC_DLL" >&6; } 55073 else 55074 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 55075 $as_echo "incorrect, ignoring" >&6; } 55076 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 55077 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 55078 fi 55079 fi 55080 55081 fi 55082 fi 55083 55084 if test "x$MSVC_DLL" = x; then 55085 # Probe: Check in the Boot JDK directory. 55086 POSSIBLE_MSVC_DLL="$BOOT_JDK/bin/$DLL_NAME" 55087 55088 DLL_NAME="$DLL_NAME" 55089 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 55090 METHOD="well-known location in Boot JDK" 55091 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 55092 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 55093 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 55094 55095 # Need to check if the found msvcr is correct architecture 55096 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 55097 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 55098 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 55099 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55100 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 55101 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 55102 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55103 CORRECT_MSVCR_ARCH="PE32 executable" 55104 else 55105 CORRECT_MSVCR_ARCH="PE32+ executable" 55106 fi 55107 else 55108 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55109 CORRECT_MSVCR_ARCH=386 55110 else 55111 CORRECT_MSVCR_ARCH=x86-64 55112 fi 55113 fi 55114 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 55115 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 55116 $as_echo "ok" >&6; } 55117 MSVC_DLL="$POSSIBLE_MSVC_DLL" 55118 55119 # Only process if variable expands to non-empty 55120 55121 if test "x$MSVC_DLL" != x; then 55122 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55123 55124 # Input might be given as Windows format, start by converting to 55125 # unix format. 55126 path="$MSVC_DLL" 55127 new_path=`$CYGPATH -u "$path"` 55128 55129 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55130 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55131 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55132 # "foo.exe" is OK but "foo" is an error. 55133 # 55134 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55135 # It is also a way to make sure we got the proper file name for the real test later on. 55136 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55137 if test "x$test_shortpath" = x; then 55138 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55139 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55140 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 55141 fi 55142 55143 # Call helper function which possibly converts this using DOS-style short mode. 55144 # If so, the updated path is stored in $new_path. 55145 55146 input_path="$new_path" 55147 # Check if we need to convert this using DOS-style short mode. If the path 55148 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55149 # take no chances and rewrite it. 55150 # Note: m4 eats our [], so we need to use [ and ] instead. 55151 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55152 if test "x$has_forbidden_chars" != x; then 55153 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55154 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55155 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55156 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55157 # Going to short mode and back again did indeed matter. Since short mode is 55158 # case insensitive, let's make it lowercase to improve readability. 55159 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55160 # Now convert it back to Unix-style (cygpath) 55161 input_path=`$CYGPATH -u "$shortmode_path"` 55162 new_path="$input_path" 55163 fi 55164 fi 55165 55166 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55167 if test "x$test_cygdrive_prefix" = x; then 55168 # As a simple fix, exclude /usr/bin since it's not a real path. 55169 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55170 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55171 # a path prefixed by /cygdrive for fixpath to work. 55172 new_path="$CYGWIN_ROOT_PATH$input_path" 55173 fi 55174 fi 55175 55176 55177 if test "x$path" != "x$new_path"; then 55178 MSVC_DLL="$new_path" 55179 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55180 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55181 fi 55182 55183 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55184 55185 path="$MSVC_DLL" 55186 has_colon=`$ECHO $path | $GREP ^.:` 55187 new_path="$path" 55188 if test "x$has_colon" = x; then 55189 # Not in mixed or Windows style, start by that. 55190 new_path=`cmd //c echo $path` 55191 fi 55192 55193 55194 input_path="$new_path" 55195 # Check if we need to convert this using DOS-style short mode. If the path 55196 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55197 # take no chances and rewrite it. 55198 # Note: m4 eats our [], so we need to use [ and ] instead. 55199 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55200 if test "x$has_forbidden_chars" != x; then 55201 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55202 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55203 fi 55204 55205 55206 windows_path="$new_path" 55207 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55208 unix_path=`$CYGPATH -u "$windows_path"` 55209 new_path="$unix_path" 55210 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55211 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55212 new_path="$unix_path" 55213 fi 55214 55215 if test "x$path" != "x$new_path"; then 55216 MSVC_DLL="$new_path" 55217 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55218 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55219 fi 55220 55221 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55222 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55223 55224 else 55225 # We're on a unix platform. Hooray! :) 55226 path="$MSVC_DLL" 55227 has_space=`$ECHO "$path" | $GREP " "` 55228 if test "x$has_space" != x; then 55229 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55230 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55231 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55232 fi 55233 55234 # Use eval to expand a potential ~ 55235 eval path="$path" 55236 if test ! -f "$path" && test ! -d "$path"; then 55237 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 55238 fi 55239 55240 if test -d "$path"; then 55241 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 55242 else 55243 dir="`$DIRNAME "$path"`" 55244 base="`$BASENAME "$path"`" 55245 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 55246 fi 55247 fi 55248 fi 55249 55250 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55251 $as_echo_n "checking for $DLL_NAME... " >&6; } 55252 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 55253 $as_echo "$MSVC_DLL" >&6; } 55254 else 55255 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 55256 $as_echo "incorrect, ignoring" >&6; } 55257 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 55258 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 55259 fi 55260 fi 55261 55262 fi 55263 55264 if test "x$MSVC_DLL" = x; then 55265 # Probe: Look in the Windows system32 directory 55266 CYGWIN_SYSTEMROOT="$SYSTEMROOT" 55267 55268 windows_path="$CYGWIN_SYSTEMROOT" 55269 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55270 unix_path=`$CYGPATH -u "$windows_path"` 55271 CYGWIN_SYSTEMROOT="$unix_path" 55272 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55273 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55274 CYGWIN_SYSTEMROOT="$unix_path" 55275 fi 55276 55277 POSSIBLE_MSVC_DLL="$CYGWIN_SYSTEMROOT/system32/$DLL_NAME" 55278 55279 DLL_NAME="$DLL_NAME" 55280 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 55281 METHOD="well-known location in SYSTEMROOT" 55282 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 55283 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 55284 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 55285 55286 # Need to check if the found msvcr is correct architecture 55287 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 55288 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 55289 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 55290 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55291 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 55292 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 55293 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55294 CORRECT_MSVCR_ARCH="PE32 executable" 55295 else 55296 CORRECT_MSVCR_ARCH="PE32+ executable" 55297 fi 55298 else 55299 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55300 CORRECT_MSVCR_ARCH=386 55301 else 55302 CORRECT_MSVCR_ARCH=x86-64 55303 fi 55304 fi 55305 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 55306 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 55307 $as_echo "ok" >&6; } 55308 MSVC_DLL="$POSSIBLE_MSVC_DLL" 55309 55310 # Only process if variable expands to non-empty 55311 55312 if test "x$MSVC_DLL" != x; then 55313 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55314 55315 # Input might be given as Windows format, start by converting to 55316 # unix format. 55317 path="$MSVC_DLL" 55318 new_path=`$CYGPATH -u "$path"` 55319 55320 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55321 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55322 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55323 # "foo.exe" is OK but "foo" is an error. 55324 # 55325 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55326 # It is also a way to make sure we got the proper file name for the real test later on. 55327 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55328 if test "x$test_shortpath" = x; then 55329 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55330 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55331 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 55332 fi 55333 55334 # Call helper function which possibly converts this using DOS-style short mode. 55335 # If so, the updated path is stored in $new_path. 55336 55337 input_path="$new_path" 55338 # Check if we need to convert this using DOS-style short mode. If the path 55339 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55340 # take no chances and rewrite it. 55341 # Note: m4 eats our [], so we need to use [ and ] instead. 55342 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55343 if test "x$has_forbidden_chars" != x; then 55344 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55345 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55346 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55347 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55348 # Going to short mode and back again did indeed matter. Since short mode is 55349 # case insensitive, let's make it lowercase to improve readability. 55350 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55351 # Now convert it back to Unix-style (cygpath) 55352 input_path=`$CYGPATH -u "$shortmode_path"` 55353 new_path="$input_path" 55354 fi 55355 fi 55356 55357 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55358 if test "x$test_cygdrive_prefix" = x; then 55359 # As a simple fix, exclude /usr/bin since it's not a real path. 55360 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55361 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55362 # a path prefixed by /cygdrive for fixpath to work. 55363 new_path="$CYGWIN_ROOT_PATH$input_path" 55364 fi 55365 fi 55366 55367 55368 if test "x$path" != "x$new_path"; then 55369 MSVC_DLL="$new_path" 55370 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55371 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55372 fi 55373 55374 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55375 55376 path="$MSVC_DLL" 55377 has_colon=`$ECHO $path | $GREP ^.:` 55378 new_path="$path" 55379 if test "x$has_colon" = x; then 55380 # Not in mixed or Windows style, start by that. 55381 new_path=`cmd //c echo $path` 55382 fi 55383 55384 55385 input_path="$new_path" 55386 # Check if we need to convert this using DOS-style short mode. If the path 55387 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55388 # take no chances and rewrite it. 55389 # Note: m4 eats our [], so we need to use [ and ] instead. 55390 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55391 if test "x$has_forbidden_chars" != x; then 55392 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55393 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55394 fi 55395 55396 55397 windows_path="$new_path" 55398 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55399 unix_path=`$CYGPATH -u "$windows_path"` 55400 new_path="$unix_path" 55401 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55402 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55403 new_path="$unix_path" 55404 fi 55405 55406 if test "x$path" != "x$new_path"; then 55407 MSVC_DLL="$new_path" 55408 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55409 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55410 fi 55411 55412 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55413 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55414 55415 else 55416 # We're on a unix platform. Hooray! :) 55417 path="$MSVC_DLL" 55418 has_space=`$ECHO "$path" | $GREP " "` 55419 if test "x$has_space" != x; then 55420 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55421 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55422 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55423 fi 55424 55425 # Use eval to expand a potential ~ 55426 eval path="$path" 55427 if test ! -f "$path" && test ! -d "$path"; then 55428 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 55429 fi 55430 55431 if test -d "$path"; then 55432 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 55433 else 55434 dir="`$DIRNAME "$path"`" 55435 base="`$BASENAME "$path"`" 55436 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 55437 fi 55438 fi 55439 fi 55440 55441 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55442 $as_echo_n "checking for $DLL_NAME... " >&6; } 55443 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 55444 $as_echo "$MSVC_DLL" >&6; } 55445 else 55446 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 55447 $as_echo "incorrect, ignoring" >&6; } 55448 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 55449 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 55450 fi 55451 fi 55452 55453 fi 55454 55455 if test "x$MSVC_DLL" = x; then 55456 # Probe: If Visual Studio Express is installed, there is usually one with the debugger 55457 if test "x$VS100COMNTOOLS" != x; then 55458 CYGWIN_VS_TOOLS_DIR="$VS100COMNTOOLS/.." 55459 55460 windows_path="$CYGWIN_VS_TOOLS_DIR" 55461 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55462 unix_path=`$CYGPATH -u "$windows_path"` 55463 CYGWIN_VS_TOOLS_DIR="$unix_path" 55464 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55465 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55466 CYGWIN_VS_TOOLS_DIR="$unix_path" 55467 fi 55468 55469 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 55470 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name $DLL_NAME \ 55471 | $GREP -i /x64/ | $HEAD --lines 1` 55472 else 55473 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name $DLL_NAME \ 55474 | $GREP -i /x86/ | $HEAD --lines 1` 55475 fi 55476 55477 DLL_NAME="$DLL_NAME" 55478 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 55479 METHOD="search of VS100COMNTOOLS" 55480 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 55481 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 55482 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 55483 55484 # Need to check if the found msvcr is correct architecture 55485 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 55486 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 55487 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 55488 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55489 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 55490 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 55491 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55492 CORRECT_MSVCR_ARCH="PE32 executable" 55493 else 55494 CORRECT_MSVCR_ARCH="PE32+ executable" 55495 fi 55496 else 55497 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55498 CORRECT_MSVCR_ARCH=386 55499 else 55500 CORRECT_MSVCR_ARCH=x86-64 55501 fi 55502 fi 55503 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 55504 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 55505 $as_echo "ok" >&6; } 55506 MSVC_DLL="$POSSIBLE_MSVC_DLL" 55507 55508 # Only process if variable expands to non-empty 55509 55510 if test "x$MSVC_DLL" != x; then 55511 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55512 55513 # Input might be given as Windows format, start by converting to 55514 # unix format. 55515 path="$MSVC_DLL" 55516 new_path=`$CYGPATH -u "$path"` 55517 55518 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55519 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55520 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55521 # "foo.exe" is OK but "foo" is an error. 55522 # 55523 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55524 # It is also a way to make sure we got the proper file name for the real test later on. 55525 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55526 if test "x$test_shortpath" = x; then 55527 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55528 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55529 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 55530 fi 55531 55532 # Call helper function which possibly converts this using DOS-style short mode. 55533 # If so, the updated path is stored in $new_path. 55534 55535 input_path="$new_path" 55536 # Check if we need to convert this using DOS-style short mode. If the path 55537 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55538 # take no chances and rewrite it. 55539 # Note: m4 eats our [], so we need to use [ and ] instead. 55540 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55541 if test "x$has_forbidden_chars" != x; then 55542 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55543 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55544 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55545 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55546 # Going to short mode and back again did indeed matter. Since short mode is 55547 # case insensitive, let's make it lowercase to improve readability. 55548 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55549 # Now convert it back to Unix-style (cygpath) 55550 input_path=`$CYGPATH -u "$shortmode_path"` 55551 new_path="$input_path" 55552 fi 55553 fi 55554 55555 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55556 if test "x$test_cygdrive_prefix" = x; then 55557 # As a simple fix, exclude /usr/bin since it's not a real path. 55558 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55559 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55560 # a path prefixed by /cygdrive for fixpath to work. 55561 new_path="$CYGWIN_ROOT_PATH$input_path" 55562 fi 55563 fi 55564 55565 55566 if test "x$path" != "x$new_path"; then 55567 MSVC_DLL="$new_path" 55568 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55569 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55570 fi 55571 55572 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55573 55574 path="$MSVC_DLL" 55575 has_colon=`$ECHO $path | $GREP ^.:` 55576 new_path="$path" 55577 if test "x$has_colon" = x; then 55578 # Not in mixed or Windows style, start by that. 55579 new_path=`cmd //c echo $path` 55580 fi 55581 55582 55583 input_path="$new_path" 55584 # Check if we need to convert this using DOS-style short mode. If the path 55585 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55586 # take no chances and rewrite it. 55587 # Note: m4 eats our [], so we need to use [ and ] instead. 55588 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55589 if test "x$has_forbidden_chars" != x; then 55590 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55591 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55592 fi 55593 55594 55595 windows_path="$new_path" 55596 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55597 unix_path=`$CYGPATH -u "$windows_path"` 55598 new_path="$unix_path" 55599 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55600 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55601 new_path="$unix_path" 55602 fi 55603 55604 if test "x$path" != "x$new_path"; then 55605 MSVC_DLL="$new_path" 55606 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55607 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55608 fi 55609 55610 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55611 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55612 55613 else 55614 # We're on a unix platform. Hooray! :) 55615 path="$MSVC_DLL" 55616 has_space=`$ECHO "$path" | $GREP " "` 55617 if test "x$has_space" != x; then 55618 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55619 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55620 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55621 fi 55622 55623 # Use eval to expand a potential ~ 55624 eval path="$path" 55625 if test ! -f "$path" && test ! -d "$path"; then 55626 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 55627 fi 55628 55629 if test -d "$path"; then 55630 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 55631 else 55632 dir="`$DIRNAME "$path"`" 55633 base="`$BASENAME "$path"`" 55634 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 55635 fi 55636 fi 55637 fi 55638 55639 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55640 $as_echo_n "checking for $DLL_NAME... " >&6; } 55641 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 55642 $as_echo "$MSVC_DLL" >&6; } 55643 else 55644 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 55645 $as_echo "incorrect, ignoring" >&6; } 55646 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 55647 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 55648 fi 55649 fi 55650 55651 fi 55652 fi 55653 55654 if test "x$MSVC_DLL" = x; then 55655 # Probe: Search wildly in the VCINSTALLDIR. We've probably lost by now. 55656 # (This was the original behaviour; kept since it might turn something up) 55657 if test "x$CYGWIN_VC_INSTALL_DIR" != x; then 55658 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 55659 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 55660 | $GREP x64 | $HEAD --lines 1` 55661 else 55662 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 55663 | $GREP x86 | $GREP -v ia64 | $GREP -v x64 | $HEAD --lines 1` 55664 if test "x$POSSIBLE_MSVC_DLL" = x; then 55665 # We're grasping at straws now... 55666 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 55667 | $HEAD --lines 1` 55668 fi 55669 fi 55670 55671 55672 DLL_NAME="$DLL_NAME" 55673 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 55674 METHOD="search of VCINSTALLDIR" 55675 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 55676 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 55677 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 55678 55679 # Need to check if the found msvcr is correct architecture 55680 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 55681 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 55682 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 55683 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55684 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 55685 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 55686 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55687 CORRECT_MSVCR_ARCH="PE32 executable" 55688 else 55689 CORRECT_MSVCR_ARCH="PE32+ executable" 55690 fi 55691 else 55692 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 55693 CORRECT_MSVCR_ARCH=386 55694 else 55695 CORRECT_MSVCR_ARCH=x86-64 55696 fi 55697 fi 55698 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 55699 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 55700 $as_echo "ok" >&6; } 55701 MSVC_DLL="$POSSIBLE_MSVC_DLL" 55702 55703 # Only process if variable expands to non-empty 55704 55705 if test "x$MSVC_DLL" != x; then 55706 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55707 55708 # Input might be given as Windows format, start by converting to 55709 # unix format. 55710 path="$MSVC_DLL" 55711 new_path=`$CYGPATH -u "$path"` 55712 55713 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55714 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55715 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55716 # "foo.exe" is OK but "foo" is an error. 55717 # 55718 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55719 # It is also a way to make sure we got the proper file name for the real test later on. 55720 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55721 if test "x$test_shortpath" = x; then 55722 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55723 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55724 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 55725 fi 55726 55727 # Call helper function which possibly converts this using DOS-style short mode. 55728 # If so, the updated path is stored in $new_path. 55729 55730 input_path="$new_path" 55731 # Check if we need to convert this using DOS-style short mode. If the path 55732 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55733 # take no chances and rewrite it. 55734 # Note: m4 eats our [], so we need to use [ and ] instead. 55735 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55736 if test "x$has_forbidden_chars" != x; then 55737 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55738 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55739 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55740 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55741 # Going to short mode and back again did indeed matter. Since short mode is 55742 # case insensitive, let's make it lowercase to improve readability. 55743 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55744 # Now convert it back to Unix-style (cygpath) 55745 input_path=`$CYGPATH -u "$shortmode_path"` 55746 new_path="$input_path" 55747 fi 55748 fi 55749 55750 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55751 if test "x$test_cygdrive_prefix" = x; then 55752 # As a simple fix, exclude /usr/bin since it's not a real path. 55753 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55754 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55755 # a path prefixed by /cygdrive for fixpath to work. 55756 new_path="$CYGWIN_ROOT_PATH$input_path" 55757 fi 55758 fi 55759 55760 55761 if test "x$path" != "x$new_path"; then 55762 MSVC_DLL="$new_path" 55763 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55764 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55765 fi 55766 55767 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55768 55769 path="$MSVC_DLL" 55770 has_colon=`$ECHO $path | $GREP ^.:` 55771 new_path="$path" 55772 if test "x$has_colon" = x; then 55773 # Not in mixed or Windows style, start by that. 55774 new_path=`cmd //c echo $path` 55775 fi 55776 55777 55778 input_path="$new_path" 55779 # Check if we need to convert this using DOS-style short mode. If the path 55780 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55781 # take no chances and rewrite it. 55782 # Note: m4 eats our [], so we need to use [ and ] instead. 55783 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55784 if test "x$has_forbidden_chars" != x; then 55785 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55786 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55787 fi 55788 55789 55790 windows_path="$new_path" 55791 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55792 unix_path=`$CYGPATH -u "$windows_path"` 55793 new_path="$unix_path" 55794 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55795 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55796 new_path="$unix_path" 55797 fi 55798 55799 if test "x$path" != "x$new_path"; then 55800 MSVC_DLL="$new_path" 55801 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 55802 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 55803 fi 55804 55805 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55806 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55807 55808 else 55809 # We're on a unix platform. Hooray! :) 55810 path="$MSVC_DLL" 55811 has_space=`$ECHO "$path" | $GREP " "` 55812 if test "x$has_space" != x; then 55813 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 55814 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 55815 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55816 fi 55817 55818 # Use eval to expand a potential ~ 55819 eval path="$path" 55820 if test ! -f "$path" && test ! -d "$path"; then 55821 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 55822 fi 55823 55824 if test -d "$path"; then 55825 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 55826 else 55827 dir="`$DIRNAME "$path"`" 55828 base="`$BASENAME "$path"`" 55829 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 55830 fi 55831 fi 55832 fi 55833 55834 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55835 $as_echo_n "checking for $DLL_NAME... " >&6; } 55836 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 55837 $as_echo "$MSVC_DLL" >&6; } 55838 else 55839 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 55840 $as_echo "incorrect, ignoring" >&6; } 55841 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 55842 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 55843 fi 55844 fi 55845 55846 fi 55847 fi 55848 55849 if test "x$MSVC_DLL" = x; then 55850 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 55851 $as_echo_n "checking for $DLL_NAME... " >&6; } 55852 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 55853 $as_echo "no" >&6; } 55854 as_fn_error $? "Could not find $DLL_NAME. Please specify using --with-msvcr-dll." "$LINENO" 5 55855 fi 55856 55857 MSVCP_DLL="$MSVC_DLL" 55858 fi 55859 55860 fi 55861 55862 fi 55863 55864 55865 if test "x$NEEDS_LIB_X11" = xfalse; then 55866 if (test "x${with_x}" != x && test "x${with_x}" != xno); then 55867 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: X11 is not used, so --with-x is ignored" >&5 55868 $as_echo "$as_me: WARNING: X11 is not used, so --with-x is ignored" >&2;} 55869 fi 55870 X_CFLAGS= 55871 X_LIBS= 55872 else 55873 55874 if test "x${with_x}" = xno; then 55875 as_fn_error $? "It is not possible to disable the use of X11. Remove the --without-x option." "$LINENO" 5 55876 fi 55877 55878 if test "x${with_x}" != x && test "x${with_x}" != xyes; then 55879 # The user has specified a X11 base directory. Use it for includes and 55880 # libraries, unless explicitely overridden. 55881 if test "x$x_includes" = xNONE; then 55882 x_includes="${with_x}/include" 55883 fi 55884 if test "x$x_libraries" = xNONE; then 55885 x_libraries="${with_x}/lib" 55886 fi 55887 else 55888 # Check if the user has specified sysroot, but not --with-x, --x-includes or --x-libraries. 55889 # Make a simple check for the libraries at the sysroot, and setup --x-includes and 55890 # --x-libraries for the sysroot, if that seems to be correct. 55891 if test "x$SYSROOT" != "x"; then 55892 if test "x$x_includes" = xNONE; then 55893 if test -f "$SYSROOT/usr/X11R6/include/X11/Xlib.h"; then 55894 x_includes="$SYSROOT/usr/X11R6/include" 55895 elif test -f "$SYSROOT/usr/include/X11/Xlib.h"; then 55896 x_includes="$SYSROOT/usr/include" 55897 fi 55898 fi 55899 if test "x$x_libraries" = xNONE; then 55900 if test -f "$SYSROOT/usr/X11R6/lib/libX11.so"; then 55901 x_libraries="$SYSROOT/usr/X11R6/lib" 55902 elif test -f "$SYSROOT/usr/lib64/libX11.so" && test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 55903 x_libraries="$SYSROOT/usr/lib64" 55904 elif test -f "$SYSROOT/usr/lib/libX11.so"; then 55905 x_libraries="$SYSROOT/usr/lib" 55906 fi 55907 fi 55908 fi 55909 fi 55910 55911 # Now let autoconf do it's magic 55912 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5 55913 $as_echo_n "checking for X... " >&6; } 55914 55915 55916 # Check whether --with-x was given. 55917 if test "${with_x+set}" = set; then : 55918 withval=$with_x; 55919 fi 55920 55921 # $have_x is `yes', `no', `disabled', or empty when we do not yet know. 55922 if test "x$with_x" = xno; then 55923 # The user explicitly disabled X. 55924 have_x=disabled 55925 else 55926 case $x_includes,$x_libraries in #( 55927 *\'*) as_fn_error $? "cannot use X directory names containing '" "$LINENO" 5;; #( 55928 *,NONE | NONE,*) if ${ac_cv_have_x+:} false; then : 55929 $as_echo_n "(cached) " >&6 55930 else 55931 # One or both of the vars are not set, and there is no cached value. 55932 ac_x_includes=no ac_x_libraries=no 55933 rm -f -r conftest.dir 55934 if mkdir conftest.dir; then 55935 cd conftest.dir 55936 cat >Imakefile <<'_ACEOF' 55937 incroot: 55938 @echo incroot='${INCROOT}' 55939 usrlibdir: 55940 @echo usrlibdir='${USRLIBDIR}' 55941 libdir: 55942 @echo libdir='${LIBDIR}' 55943 _ACEOF 55944 if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then 55945 # GNU make sometimes prints "make[1]: Entering ...", which would confuse us. 55946 for ac_var in incroot usrlibdir libdir; do 55947 eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`" 55948 done 55949 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR. 55950 for ac_extension in a so sl dylib la dll; do 55951 if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" && 55952 test -f "$ac_im_libdir/libX11.$ac_extension"; then 55953 ac_im_usrlibdir=$ac_im_libdir; break 55954 fi 55955 done 55956 # Screen out bogus values from the imake configuration. They are 55957 # bogus both because they are the default anyway, and because 55958 # using them would break gcc on systems where it needs fixed includes. 55959 case $ac_im_incroot in 55960 /usr/include) ac_x_includes= ;; 55961 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;; 55962 esac 55963 case $ac_im_usrlibdir in 55964 /usr/lib | /usr/lib64 | /lib | /lib64) ;; 55965 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;; 55966 esac 55967 fi 55968 cd .. 55969 rm -f -r conftest.dir 55970 fi 55971 55972 # Standard set of common directories for X headers. 55973 # Check X11 before X11Rn because it is often a symlink to the current release. 55974 ac_x_header_dirs=' 55975 /usr/X11/include 55976 /usr/X11R7/include 55977 /usr/X11R6/include 55978 /usr/X11R5/include 55979 /usr/X11R4/include 55980 55981 /usr/include/X11 55982 /usr/include/X11R7 55983 /usr/include/X11R6 55984 /usr/include/X11R5 55985 /usr/include/X11R4 55986 55987 /usr/local/X11/include 55988 /usr/local/X11R7/include 55989 /usr/local/X11R6/include 55990 /usr/local/X11R5/include 55991 /usr/local/X11R4/include 55992 55993 /usr/local/include/X11 55994 /usr/local/include/X11R7 55995 /usr/local/include/X11R6 55996 /usr/local/include/X11R5 55997 /usr/local/include/X11R4 55998 55999 /usr/X386/include 56000 /usr/x386/include 56001 /usr/XFree86/include/X11 56002 56003 /usr/include 56004 /usr/local/include 56005 /usr/unsupported/include 56006 /usr/athena/include 56007 /usr/local/x11r5/include 56008 /usr/lpp/Xamples/include 56009 56010 /usr/openwin/include 56011 /usr/openwin/share/include' 56012 56013 if test "$ac_x_includes" = no; then 56014 # Guess where to find include files, by looking for Xlib.h. 56015 # First, try using that file with no special directory specified. 56016 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56017 /* end confdefs.h. */ 56018 #include <X11/Xlib.h> 56019 _ACEOF 56020 if ac_fn_cxx_try_cpp "$LINENO"; then : 56021 # We can compile using X headers with no special include directory. 56022 ac_x_includes= 56023 else 56024 for ac_dir in $ac_x_header_dirs; do 56025 if test -r "$ac_dir/X11/Xlib.h"; then 56026 ac_x_includes=$ac_dir 56027 break 56028 fi 56029 done 56030 fi 56031 rm -f conftest.err conftest.i conftest.$ac_ext 56032 fi # $ac_x_includes = no 56033 56034 if test "$ac_x_libraries" = no; then 56035 # Check for the libraries. 56036 # See if we find them without any special options. 56037 # Don't add to $LIBS permanently. 56038 ac_save_LIBS=$LIBS 56039 LIBS="-lX11 $LIBS" 56040 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56041 /* end confdefs.h. */ 56042 #include <X11/Xlib.h> 56043 int 56044 main () 56045 { 56046 XrmInitialize () 56047 ; 56048 return 0; 56049 } 56050 _ACEOF 56051 if ac_fn_cxx_try_link "$LINENO"; then : 56052 LIBS=$ac_save_LIBS 56053 # We can link X programs with no special library path. 56054 ac_x_libraries= 56055 else 56056 LIBS=$ac_save_LIBS 56057 for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g` 56058 do 56059 # Don't even attempt the hair of trying to link an X program! 56060 for ac_extension in a so sl dylib la dll; do 56061 if test -r "$ac_dir/libX11.$ac_extension"; then 56062 ac_x_libraries=$ac_dir 56063 break 2 56064 fi 56065 done 56066 done 56067 fi 56068 rm -f core conftest.err conftest.$ac_objext \ 56069 conftest$ac_exeext conftest.$ac_ext 56070 fi # $ac_x_libraries = no 56071 56072 case $ac_x_includes,$ac_x_libraries in #( 56073 no,* | *,no | *\'*) 56074 # Didn't find X, or a directory has "'" in its name. 56075 ac_cv_have_x="have_x=no";; #( 56076 *) 56077 # Record where we found X for the cache. 56078 ac_cv_have_x="have_x=yes\ 56079 ac_x_includes='$ac_x_includes'\ 56080 ac_x_libraries='$ac_x_libraries'" 56081 esac 56082 fi 56083 ;; #( 56084 *) have_x=yes;; 56085 esac 56086 eval "$ac_cv_have_x" 56087 fi # $with_x != no 56088 56089 if test "$have_x" != yes; then 56090 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5 56091 $as_echo "$have_x" >&6; } 56092 no_x=yes 56093 else 56094 # If each of the values was on the command line, it overrides each guess. 56095 test "x$x_includes" = xNONE && x_includes=$ac_x_includes 56096 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries 56097 # Update the cache value to reflect the command line values. 56098 ac_cv_have_x="have_x=yes\ 56099 ac_x_includes='$x_includes'\ 56100 ac_x_libraries='$x_libraries'" 56101 { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5 56102 $as_echo "libraries $x_libraries, headers $x_includes" >&6; } 56103 fi 56104 56105 if test "$no_x" = yes; then 56106 # Not all programs may use this symbol, but it does not hurt to define it. 56107 56108 $as_echo "#define X_DISPLAY_MISSING 1" >>confdefs.h 56109 56110 X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS= 56111 else 56112 if test -n "$x_includes"; then 56113 X_CFLAGS="$X_CFLAGS -I$x_includes" 56114 fi 56115 56116 # It would also be nice to do this for all -L options, not just this one. 56117 if test -n "$x_libraries"; then 56118 X_LIBS="$X_LIBS -L$x_libraries" 56119 # For Solaris; some versions of Sun CC require a space after -R and 56120 # others require no space. Words are not sufficient . . . . 56121 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -R must be followed by a space" >&5 56122 $as_echo_n "checking whether -R must be followed by a space... " >&6; } 56123 ac_xsave_LIBS=$LIBS; LIBS="$LIBS -R$x_libraries" 56124 ac_xsave_cxx_werror_flag=$ac_cxx_werror_flag 56125 ac_cxx_werror_flag=yes 56126 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56127 /* end confdefs.h. */ 56128 56129 int 56130 main () 56131 { 56132 56133 ; 56134 return 0; 56135 } 56136 _ACEOF 56137 if ac_fn_cxx_try_link "$LINENO"; then : 56138 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 56139 $as_echo "no" >&6; } 56140 X_LIBS="$X_LIBS -R$x_libraries" 56141 else 56142 LIBS="$ac_xsave_LIBS -R $x_libraries" 56143 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56144 /* end confdefs.h. */ 56145 56146 int 56147 main () 56148 { 56149 56150 ; 56151 return 0; 56152 } 56153 _ACEOF 56154 if ac_fn_cxx_try_link "$LINENO"; then : 56155 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 56156 $as_echo "yes" >&6; } 56157 X_LIBS="$X_LIBS -R $x_libraries" 56158 else 56159 { $as_echo "$as_me:${as_lineno-$LINENO}: result: neither works" >&5 56160 $as_echo "neither works" >&6; } 56161 fi 56162 rm -f core conftest.err conftest.$ac_objext \ 56163 conftest$ac_exeext conftest.$ac_ext 56164 fi 56165 rm -f core conftest.err conftest.$ac_objext \ 56166 conftest$ac_exeext conftest.$ac_ext 56167 ac_cxx_werror_flag=$ac_xsave_cxx_werror_flag 56168 LIBS=$ac_xsave_LIBS 56169 fi 56170 56171 # Check for system-dependent libraries X programs must link with. 56172 # Do this before checking for the system-independent R6 libraries 56173 # (-lICE), since we may need -lsocket or whatever for X linking. 56174 56175 if test "$ISC" = yes; then 56176 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet" 56177 else 56178 # Martyn Johnson says this is needed for Ultrix, if the X 56179 # libraries were built with DECnet support. And Karl Berry says 56180 # the Alpha needs dnet_stub (dnet does not exist). 56181 ac_xsave_LIBS="$LIBS"; LIBS="$LIBS $X_LIBS -lX11" 56182 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56183 /* end confdefs.h. */ 56184 56185 /* Override any GCC internal prototype to avoid an error. 56186 Use char because int might match the return type of a GCC 56187 builtin and then its argument prototype would still apply. */ 56188 #ifdef __cplusplus 56189 extern "C" 56190 #endif 56191 char XOpenDisplay (); 56192 int 56193 main () 56194 { 56195 return XOpenDisplay (); 56196 ; 56197 return 0; 56198 } 56199 _ACEOF 56200 if ac_fn_cxx_try_link "$LINENO"; then : 56201 56202 else 56203 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet" >&5 56204 $as_echo_n "checking for dnet_ntoa in -ldnet... " >&6; } 56205 if ${ac_cv_lib_dnet_dnet_ntoa+:} false; then : 56206 $as_echo_n "(cached) " >&6 56207 else 56208 ac_check_lib_save_LIBS=$LIBS 56209 LIBS="-ldnet $LIBS" 56210 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56211 /* end confdefs.h. */ 56212 56213 /* Override any GCC internal prototype to avoid an error. 56214 Use char because int might match the return type of a GCC 56215 builtin and then its argument prototype would still apply. */ 56216 #ifdef __cplusplus 56217 extern "C" 56218 #endif 56219 char dnet_ntoa (); 56220 int 56221 main () 56222 { 56223 return dnet_ntoa (); 56224 ; 56225 return 0; 56226 } 56227 _ACEOF 56228 if ac_fn_cxx_try_link "$LINENO"; then : 56229 ac_cv_lib_dnet_dnet_ntoa=yes 56230 else 56231 ac_cv_lib_dnet_dnet_ntoa=no 56232 fi 56233 rm -f core conftest.err conftest.$ac_objext \ 56234 conftest$ac_exeext conftest.$ac_ext 56235 LIBS=$ac_check_lib_save_LIBS 56236 fi 56237 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_dnet_ntoa" >&5 56238 $as_echo "$ac_cv_lib_dnet_dnet_ntoa" >&6; } 56239 if test "x$ac_cv_lib_dnet_dnet_ntoa" = xyes; then : 56240 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet" 56241 fi 56242 56243 if test $ac_cv_lib_dnet_dnet_ntoa = no; then 56244 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet_stub" >&5 56245 $as_echo_n "checking for dnet_ntoa in -ldnet_stub... " >&6; } 56246 if ${ac_cv_lib_dnet_stub_dnet_ntoa+:} false; then : 56247 $as_echo_n "(cached) " >&6 56248 else 56249 ac_check_lib_save_LIBS=$LIBS 56250 LIBS="-ldnet_stub $LIBS" 56251 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56252 /* end confdefs.h. */ 56253 56254 /* Override any GCC internal prototype to avoid an error. 56255 Use char because int might match the return type of a GCC 56256 builtin and then its argument prototype would still apply. */ 56257 #ifdef __cplusplus 56258 extern "C" 56259 #endif 56260 char dnet_ntoa (); 56261 int 56262 main () 56263 { 56264 return dnet_ntoa (); 56265 ; 56266 return 0; 56267 } 56268 _ACEOF 56269 if ac_fn_cxx_try_link "$LINENO"; then : 56270 ac_cv_lib_dnet_stub_dnet_ntoa=yes 56271 else 56272 ac_cv_lib_dnet_stub_dnet_ntoa=no 56273 fi 56274 rm -f core conftest.err conftest.$ac_objext \ 56275 conftest$ac_exeext conftest.$ac_ext 56276 LIBS=$ac_check_lib_save_LIBS 56277 fi 56278 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_stub_dnet_ntoa" >&5 56279 $as_echo "$ac_cv_lib_dnet_stub_dnet_ntoa" >&6; } 56280 if test "x$ac_cv_lib_dnet_stub_dnet_ntoa" = xyes; then : 56281 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub" 56282 fi 56283 56284 fi 56285 fi 56286 rm -f core conftest.err conftest.$ac_objext \ 56287 conftest$ac_exeext conftest.$ac_ext 56288 LIBS="$ac_xsave_LIBS" 56289 56290 # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT, 56291 # to get the SysV transport functions. 56292 # Chad R. Larson says the Pyramis MIS-ES running DC/OSx (SVR4) 56293 # needs -lnsl. 56294 # The nsl library prevents programs from opening the X display 56295 # on Irix 5.2, according to T.E. Dickey. 56296 # The functions gethostbyname, getservbyname, and inet_addr are 56297 # in -lbsd on LynxOS 3.0.1/i386, according to Lars Hecking. 56298 ac_fn_cxx_check_func "$LINENO" "gethostbyname" "ac_cv_func_gethostbyname" 56299 if test "x$ac_cv_func_gethostbyname" = xyes; then : 56300 56301 fi 56302 56303 if test $ac_cv_func_gethostbyname = no; then 56304 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lnsl" >&5 56305 $as_echo_n "checking for gethostbyname in -lnsl... " >&6; } 56306 if ${ac_cv_lib_nsl_gethostbyname+:} false; then : 56307 $as_echo_n "(cached) " >&6 56308 else 56309 ac_check_lib_save_LIBS=$LIBS 56310 LIBS="-lnsl $LIBS" 56311 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56312 /* end confdefs.h. */ 56313 56314 /* Override any GCC internal prototype to avoid an error. 56315 Use char because int might match the return type of a GCC 56316 builtin and then its argument prototype would still apply. */ 56317 #ifdef __cplusplus 56318 extern "C" 56319 #endif 56320 char gethostbyname (); 56321 int 56322 main () 56323 { 56324 return gethostbyname (); 56325 ; 56326 return 0; 56327 } 56328 _ACEOF 56329 if ac_fn_cxx_try_link "$LINENO"; then : 56330 ac_cv_lib_nsl_gethostbyname=yes 56331 else 56332 ac_cv_lib_nsl_gethostbyname=no 56333 fi 56334 rm -f core conftest.err conftest.$ac_objext \ 56335 conftest$ac_exeext conftest.$ac_ext 56336 LIBS=$ac_check_lib_save_LIBS 56337 fi 56338 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_gethostbyname" >&5 56339 $as_echo "$ac_cv_lib_nsl_gethostbyname" >&6; } 56340 if test "x$ac_cv_lib_nsl_gethostbyname" = xyes; then : 56341 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl" 56342 fi 56343 56344 if test $ac_cv_lib_nsl_gethostbyname = no; then 56345 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lbsd" >&5 56346 $as_echo_n "checking for gethostbyname in -lbsd... " >&6; } 56347 if ${ac_cv_lib_bsd_gethostbyname+:} false; then : 56348 $as_echo_n "(cached) " >&6 56349 else 56350 ac_check_lib_save_LIBS=$LIBS 56351 LIBS="-lbsd $LIBS" 56352 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56353 /* end confdefs.h. */ 56354 56355 /* Override any GCC internal prototype to avoid an error. 56356 Use char because int might match the return type of a GCC 56357 builtin and then its argument prototype would still apply. */ 56358 #ifdef __cplusplus 56359 extern "C" 56360 #endif 56361 char gethostbyname (); 56362 int 56363 main () 56364 { 56365 return gethostbyname (); 56366 ; 56367 return 0; 56368 } 56369 _ACEOF 56370 if ac_fn_cxx_try_link "$LINENO"; then : 56371 ac_cv_lib_bsd_gethostbyname=yes 56372 else 56373 ac_cv_lib_bsd_gethostbyname=no 56374 fi 56375 rm -f core conftest.err conftest.$ac_objext \ 56376 conftest$ac_exeext conftest.$ac_ext 56377 LIBS=$ac_check_lib_save_LIBS 56378 fi 56379 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_gethostbyname" >&5 56380 $as_echo "$ac_cv_lib_bsd_gethostbyname" >&6; } 56381 if test "x$ac_cv_lib_bsd_gethostbyname" = xyes; then : 56382 X_EXTRA_LIBS="$X_EXTRA_LIBS -lbsd" 56383 fi 56384 56385 fi 56386 fi 56387 56388 # lieder@skyler.mavd.honeywell.com says without -lsocket, 56389 # socket/setsockopt and other routines are undefined under SCO ODT 56390 # 2.0. But -lsocket is broken on IRIX 5.2 (and is not necessary 56391 # on later versions), says Simon Leinen: it contains gethostby* 56392 # variants that don't use the name server (or something). -lsocket 56393 # must be given before -lnsl if both are needed. We assume that 56394 # if connect needs -lnsl, so does gethostbyname. 56395 ac_fn_cxx_check_func "$LINENO" "connect" "ac_cv_func_connect" 56396 if test "x$ac_cv_func_connect" = xyes; then : 56397 56398 fi 56399 56400 if test $ac_cv_func_connect = no; then 56401 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for connect in -lsocket" >&5 56402 $as_echo_n "checking for connect in -lsocket... " >&6; } 56403 if ${ac_cv_lib_socket_connect+:} false; then : 56404 $as_echo_n "(cached) " >&6 56405 else 56406 ac_check_lib_save_LIBS=$LIBS 56407 LIBS="-lsocket $X_EXTRA_LIBS $LIBS" 56408 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56409 /* end confdefs.h. */ 56410 56411 /* Override any GCC internal prototype to avoid an error. 56412 Use char because int might match the return type of a GCC 56413 builtin and then its argument prototype would still apply. */ 56414 #ifdef __cplusplus 56415 extern "C" 56416 #endif 56417 char connect (); 56418 int 56419 main () 56420 { 56421 return connect (); 56422 ; 56423 return 0; 56424 } 56425 _ACEOF 56426 if ac_fn_cxx_try_link "$LINENO"; then : 56427 ac_cv_lib_socket_connect=yes 56428 else 56429 ac_cv_lib_socket_connect=no 56430 fi 56431 rm -f core conftest.err conftest.$ac_objext \ 56432 conftest$ac_exeext conftest.$ac_ext 56433 LIBS=$ac_check_lib_save_LIBS 56434 fi 56435 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_connect" >&5 56436 $as_echo "$ac_cv_lib_socket_connect" >&6; } 56437 if test "x$ac_cv_lib_socket_connect" = xyes; then : 56438 X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS" 56439 fi 56440 56441 fi 56442 56443 # Guillermo Gomez says -lposix is necessary on A/UX. 56444 ac_fn_cxx_check_func "$LINENO" "remove" "ac_cv_func_remove" 56445 if test "x$ac_cv_func_remove" = xyes; then : 56446 56447 fi 56448 56449 if test $ac_cv_func_remove = no; then 56450 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for remove in -lposix" >&5 56451 $as_echo_n "checking for remove in -lposix... " >&6; } 56452 if ${ac_cv_lib_posix_remove+:} false; then : 56453 $as_echo_n "(cached) " >&6 56454 else 56455 ac_check_lib_save_LIBS=$LIBS 56456 LIBS="-lposix $LIBS" 56457 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56458 /* end confdefs.h. */ 56459 56460 /* Override any GCC internal prototype to avoid an error. 56461 Use char because int might match the return type of a GCC 56462 builtin and then its argument prototype would still apply. */ 56463 #ifdef __cplusplus 56464 extern "C" 56465 #endif 56466 char remove (); 56467 int 56468 main () 56469 { 56470 return remove (); 56471 ; 56472 return 0; 56473 } 56474 _ACEOF 56475 if ac_fn_cxx_try_link "$LINENO"; then : 56476 ac_cv_lib_posix_remove=yes 56477 else 56478 ac_cv_lib_posix_remove=no 56479 fi 56480 rm -f core conftest.err conftest.$ac_objext \ 56481 conftest$ac_exeext conftest.$ac_ext 56482 LIBS=$ac_check_lib_save_LIBS 56483 fi 56484 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_posix_remove" >&5 56485 $as_echo "$ac_cv_lib_posix_remove" >&6; } 56486 if test "x$ac_cv_lib_posix_remove" = xyes; then : 56487 X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix" 56488 fi 56489 56490 fi 56491 56492 # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay. 56493 ac_fn_cxx_check_func "$LINENO" "shmat" "ac_cv_func_shmat" 56494 if test "x$ac_cv_func_shmat" = xyes; then : 56495 56496 fi 56497 56498 if test $ac_cv_func_shmat = no; then 56499 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shmat in -lipc" >&5 56500 $as_echo_n "checking for shmat in -lipc... " >&6; } 56501 if ${ac_cv_lib_ipc_shmat+:} false; then : 56502 $as_echo_n "(cached) " >&6 56503 else 56504 ac_check_lib_save_LIBS=$LIBS 56505 LIBS="-lipc $LIBS" 56506 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56507 /* end confdefs.h. */ 56508 56509 /* Override any GCC internal prototype to avoid an error. 56510 Use char because int might match the return type of a GCC 56511 builtin and then its argument prototype would still apply. */ 56512 #ifdef __cplusplus 56513 extern "C" 56514 #endif 56515 char shmat (); 56516 int 56517 main () 56518 { 56519 return shmat (); 56520 ; 56521 return 0; 56522 } 56523 _ACEOF 56524 if ac_fn_cxx_try_link "$LINENO"; then : 56525 ac_cv_lib_ipc_shmat=yes 56526 else 56527 ac_cv_lib_ipc_shmat=no 56528 fi 56529 rm -f core conftest.err conftest.$ac_objext \ 56530 conftest$ac_exeext conftest.$ac_ext 56531 LIBS=$ac_check_lib_save_LIBS 56532 fi 56533 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ipc_shmat" >&5 56534 $as_echo "$ac_cv_lib_ipc_shmat" >&6; } 56535 if test "x$ac_cv_lib_ipc_shmat" = xyes; then : 56536 X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc" 56537 fi 56538 56539 fi 56540 fi 56541 56542 # Check for libraries that X11R6 Xt/Xaw programs need. 56543 ac_save_LDFLAGS=$LDFLAGS 56544 test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries" 56545 # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to 56546 # check for ICE first), but we must link in the order -lSM -lICE or 56547 # we get undefined symbols. So assume we have SM if we have ICE. 56548 # These have to be linked with before -lX11, unlike the other 56549 # libraries we check for below, so use a different variable. 56550 # John Interrante, Karl Berry 56551 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for IceConnectionNumber in -lICE" >&5 56552 $as_echo_n "checking for IceConnectionNumber in -lICE... " >&6; } 56553 if ${ac_cv_lib_ICE_IceConnectionNumber+:} false; then : 56554 $as_echo_n "(cached) " >&6 56555 else 56556 ac_check_lib_save_LIBS=$LIBS 56557 LIBS="-lICE $X_EXTRA_LIBS $LIBS" 56558 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56559 /* end confdefs.h. */ 56560 56561 /* Override any GCC internal prototype to avoid an error. 56562 Use char because int might match the return type of a GCC 56563 builtin and then its argument prototype would still apply. */ 56564 #ifdef __cplusplus 56565 extern "C" 56566 #endif 56567 char IceConnectionNumber (); 56568 int 56569 main () 56570 { 56571 return IceConnectionNumber (); 56572 ; 56573 return 0; 56574 } 56575 _ACEOF 56576 if ac_fn_cxx_try_link "$LINENO"; then : 56577 ac_cv_lib_ICE_IceConnectionNumber=yes 56578 else 56579 ac_cv_lib_ICE_IceConnectionNumber=no 56580 fi 56581 rm -f core conftest.err conftest.$ac_objext \ 56582 conftest$ac_exeext conftest.$ac_ext 56583 LIBS=$ac_check_lib_save_LIBS 56584 fi 56585 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ICE_IceConnectionNumber" >&5 56586 $as_echo "$ac_cv_lib_ICE_IceConnectionNumber" >&6; } 56587 if test "x$ac_cv_lib_ICE_IceConnectionNumber" = xyes; then : 56588 X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE" 56589 fi 56590 56591 LDFLAGS=$ac_save_LDFLAGS 56592 56593 fi 56594 56595 56596 # AC_PATH_XTRA creates X_LIBS and sometimes adds -R flags. When cross compiling 56597 # this doesn't make sense so we remove it. 56598 if test "x$COMPILE_TYPE" = xcross; then 56599 X_LIBS=`$ECHO $X_LIBS | $SED 's/-R \{0,1\}[^ ]*//g'` 56600 fi 56601 56602 if test "x$no_x" = xyes; then 56603 56604 # Print a helpful message on how to acquire the necessary build dependency. 56605 # x11 is the help tag: freetype, cups, alsa etc 56606 MISSING_DEPENDENCY=x11 56607 56608 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56609 cygwin_help $MISSING_DEPENDENCY 56610 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56611 msys_help $MISSING_DEPENDENCY 56612 else 56613 PKGHANDLER_COMMAND= 56614 56615 case $PKGHANDLER in 56616 apt-get) 56617 apt_help $MISSING_DEPENDENCY ;; 56618 yum) 56619 yum_help $MISSING_DEPENDENCY ;; 56620 port) 56621 port_help $MISSING_DEPENDENCY ;; 56622 pkgutil) 56623 pkgutil_help $MISSING_DEPENDENCY ;; 56624 pkgadd) 56625 pkgadd_help $MISSING_DEPENDENCY ;; 56626 esac 56627 56628 if test "x$PKGHANDLER_COMMAND" != x; then 56629 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 56630 fi 56631 fi 56632 56633 as_fn_error $? "Could not find X11 libraries. $HELP_MSG" "$LINENO" 5 56634 fi 56635 56636 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 56637 OPENWIN_HOME="/usr/openwin" 56638 X_CFLAGS="-I$SYSROOT$OPENWIN_HOME/include -I$SYSROOT$OPENWIN_HOME/include/X11/extensions" 56639 X_LIBS="-L$SYSROOT$OPENWIN_HOME/lib$OPENJDK_TARGET_CPU_ISADIR \ 56640 -R$OPENWIN_HOME/lib$OPENJDK_TARGET_CPU_ISADIR" 56641 fi 56642 56643 ac_ext=c 56644 ac_cpp='$CPP $CPPFLAGS' 56645 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 56646 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 56647 ac_compiler_gnu=$ac_cv_c_compiler_gnu 56648 56649 OLD_CFLAGS="$CFLAGS" 56650 CFLAGS="$CFLAGS $SYSROOT_CFLAGS $X_CFLAGS" 56651 56652 # Need to include Xlib.h and Xutil.h to avoid "present but cannot be compiled" warnings on Solaris 10 56653 for ac_header in X11/extensions/shape.h X11/extensions/Xrender.h X11/extensions/XTest.h X11/Intrinsic.h 56654 do : 56655 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` 56656 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" " 56657 # include <X11/Xlib.h> 56658 # include <X11/Xutil.h> 56659 56660 56661 " 56662 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : 56663 cat >>confdefs.h <<_ACEOF 56664 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 56665 _ACEOF 56666 X11_HEADERS_OK=yes 56667 else 56668 X11_HEADERS_OK=no; break 56669 fi 56670 56671 done 56672 56673 56674 if test "x$X11_HEADERS_OK" = xno; then 56675 56676 # Print a helpful message on how to acquire the necessary build dependency. 56677 # x11 is the help tag: freetype, cups, alsa etc 56678 MISSING_DEPENDENCY=x11 56679 56680 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56681 cygwin_help $MISSING_DEPENDENCY 56682 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56683 msys_help $MISSING_DEPENDENCY 56684 else 56685 PKGHANDLER_COMMAND= 56686 56687 case $PKGHANDLER in 56688 apt-get) 56689 apt_help $MISSING_DEPENDENCY ;; 56690 yum) 56691 yum_help $MISSING_DEPENDENCY ;; 56692 port) 56693 port_help $MISSING_DEPENDENCY ;; 56694 pkgutil) 56695 pkgutil_help $MISSING_DEPENDENCY ;; 56696 pkgadd) 56697 pkgadd_help $MISSING_DEPENDENCY ;; 56698 esac 56699 56700 if test "x$PKGHANDLER_COMMAND" != x; then 56701 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 56702 fi 56703 fi 56704 56705 as_fn_error $? "Could not find all X11 headers (shape.h Xrender.h XTest.h Intrinsic.h). $HELP_MSG" "$LINENO" 5 56706 fi 56707 56708 # If XLinearGradient isn't available in Xrender.h, signal that it needs to be 56709 # defined in libawt_xawt. 56710 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if XlinearGradient is defined in Xrender.h" >&5 56711 $as_echo_n "checking if XlinearGradient is defined in Xrender.h... " >&6; } 56712 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 56713 /* end confdefs.h. */ 56714 #include <X11/extensions/Xrender.h> 56715 int 56716 main () 56717 { 56718 XLinearGradient x; 56719 ; 56720 return 0; 56721 } 56722 _ACEOF 56723 if ac_fn_c_try_compile "$LINENO"; then : 56724 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 56725 $as_echo "yes" >&6; } 56726 else 56727 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 56728 $as_echo "no" >&6; } 56729 X_CFLAGS="$X_CFLAGS -DSOLARIS10_NO_XRENDER_STRUCTS" 56730 fi 56731 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 56732 56733 CFLAGS="$OLD_CFLAGS" 56734 ac_ext=cpp 56735 ac_cpp='$CXXCPP $CPPFLAGS' 56736 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 56737 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 56738 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 56739 56740 fi # NEEDS_LIB_X11 56741 56742 56743 56744 56745 56746 56747 # Check whether --with-cups was given. 56748 if test "${with_cups+set}" = set; then : 56749 withval=$with_cups; 56750 fi 56751 56752 56753 # Check whether --with-cups-include was given. 56754 if test "${with_cups_include+set}" = set; then : 56755 withval=$with_cups_include; 56756 fi 56757 56758 56759 if test "x$NEEDS_LIB_CUPS" = xfalse; then 56760 if (test "x${with_cups}" != x && test "x${with_cups}" != xno) || \ 56761 (test "x${with_cups_include}" != x && test "x${with_cups_include}" != xno); then 56762 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cups not used, so --with-cups[-*] is ignored" >&5 56763 $as_echo "$as_me: WARNING: cups not used, so --with-cups[-*] is ignored" >&2;} 56764 fi 56765 CUPS_CFLAGS= 56766 else 56767 CUPS_FOUND=no 56768 56769 if test "x${with_cups}" = xno || test "x${with_cups_include}" = xno; then 56770 as_fn_error $? "It is not possible to disable the use of cups. Remove the --without-cups option." "$LINENO" 5 56771 fi 56772 56773 if test "x${with_cups}" != x; then 56774 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cups headers" >&5 56775 $as_echo_n "checking for cups headers... " >&6; } 56776 if test -s "${with_cups}/include/cups/cups.h"; then 56777 CUPS_CFLAGS="-I${with_cups}/include" 56778 CUPS_FOUND=yes 56779 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUPS_FOUND" >&5 56780 $as_echo "$CUPS_FOUND" >&6; } 56781 else 56782 as_fn_error $? "Can't find 'include/cups/cups.h' under ${with_cups} given with the --with-cups option." "$LINENO" 5 56783 fi 56784 fi 56785 if test "x${with_cups_include}" != x; then 56786 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cups headers" >&5 56787 $as_echo_n "checking for cups headers... " >&6; } 56788 if test -s "${with_cups_include}/cups/cups.h"; then 56789 CUPS_CFLAGS="-I${with_cups_include}" 56790 CUPS_FOUND=yes 56791 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUPS_FOUND" >&5 56792 $as_echo "$CUPS_FOUND" >&6; } 56793 else 56794 as_fn_error $? "Can't find 'cups/cups.h' under ${with_cups_include} given with the --with-cups-include option." "$LINENO" 5 56795 fi 56796 fi 56797 if test "x$CUPS_FOUND" = xno; then 56798 # Are the cups headers installed in the default /usr/include location? 56799 for ac_header in cups/cups.h cups/ppd.h 56800 do : 56801 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` 56802 ac_fn_cxx_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" 56803 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : 56804 cat >>confdefs.h <<_ACEOF 56805 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 56806 _ACEOF 56807 56808 CUPS_FOUND=yes 56809 CUPS_CFLAGS= 56810 DEFAULT_CUPS=yes 56811 56812 fi 56813 56814 done 56815 56816 fi 56817 if test "x$CUPS_FOUND" = xno; then 56818 56819 # Print a helpful message on how to acquire the necessary build dependency. 56820 # cups is the help tag: freetype, cups, alsa etc 56821 MISSING_DEPENDENCY=cups 56822 56823 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56824 cygwin_help $MISSING_DEPENDENCY 56825 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56826 msys_help $MISSING_DEPENDENCY 56827 else 56828 PKGHANDLER_COMMAND= 56829 56830 case $PKGHANDLER in 56831 apt-get) 56832 apt_help $MISSING_DEPENDENCY ;; 56833 yum) 56834 yum_help $MISSING_DEPENDENCY ;; 56835 port) 56836 port_help $MISSING_DEPENDENCY ;; 56837 pkgutil) 56838 pkgutil_help $MISSING_DEPENDENCY ;; 56839 pkgadd) 56840 pkgadd_help $MISSING_DEPENDENCY ;; 56841 esac 56842 56843 if test "x$PKGHANDLER_COMMAND" != x; then 56844 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 56845 fi 56846 fi 56847 56848 as_fn_error $? "Could not find cups! $HELP_MSG " "$LINENO" 5 56849 fi 56850 fi 56851 56852 56853 56854 56855 56856 # Check whether --with-freetype was given. 56857 if test "${with_freetype+set}" = set; then : 56858 withval=$with_freetype; 56859 fi 56860 56861 56862 # Check whether --with-freetype-include was given. 56863 if test "${with_freetype_include+set}" = set; then : 56864 withval=$with_freetype_include; 56865 fi 56866 56867 56868 # Check whether --with-freetype-lib was given. 56869 if test "${with_freetype_lib+set}" = set; then : 56870 withval=$with_freetype_lib; 56871 fi 56872 56873 56874 # Check whether --with-freetype-src was given. 56875 if test "${with_freetype_src+set}" = set; then : 56876 withval=$with_freetype_src; 56877 fi 56878 56879 # Check whether --enable-freetype-bundling was given. 56880 if test "${enable_freetype_bundling+set}" = set; then : 56881 enableval=$enable_freetype_bundling; 56882 fi 56883 56884 56885 # Need to specify explicitly since it needs to be overridden on some versions of macosx 56886 FREETYPE_BASE_NAME=freetype 56887 FREETYPE_CFLAGS= 56888 FREETYPE_LIBS= 56889 FREETYPE_BUNDLE_LIB_PATH= 56890 56891 if test "x$NEEDS_LIB_FREETYPE" = xfalse; then 56892 if (test "x$with_freetype" != x && test "x$with_freetype" != xno) || \ 56893 (test "x$with_freetype_include" != x && test "x$with_freetype_include" != xno) || \ 56894 (test "x$with_freetype_lib" != x && test "x$with_freetype_lib" != xno) || \ 56895 (test "x$with_freetype_src" != x && test "x$with_freetype_src" != xno); then 56896 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: freetype not used, so --with-freetype[-*] is ignored" >&5 56897 $as_echo "$as_me: WARNING: freetype not used, so --with-freetype[-*] is ignored" >&2;} 56898 fi 56899 if (test "x$enable_freetype_bundling" != x && test "x$enable_freetype_bundling" != xno); then 56900 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: freetype not used, so --enable-freetype-bundling is ignored" >&5 56901 $as_echo "$as_me: WARNING: freetype not used, so --enable-freetype-bundling is ignored" >&2;} 56902 fi 56903 else 56904 # freetype is needed to build; go get it! 56905 56906 BUNDLE_FREETYPE="$enable_freetype_bundling" 56907 56908 if test "x$with_freetype_src" != x; then 56909 if test "x$OPENJDK_TARGET_OS" = xwindows; then 56910 # Try to build freetype if --with-freetype-src was given on Windows 56911 56912 FREETYPE_SRC_PATH="$with_freetype_src" 56913 BUILD_FREETYPE=yes 56914 56915 # Check if the freetype sources are acessible.. 56916 if ! test -d $FREETYPE_SRC_PATH; then 56917 { $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 56918 $as_echo "$as_me: WARNING: --with-freetype-src specified, but can not find path \"$FREETYPE_SRC_PATH\" - ignoring --with-freetype-src" >&2;} 56919 BUILD_FREETYPE=no 56920 fi 56921 # ..and contain a vc2010 project file 56922 vcxproj_path="$FREETYPE_SRC_PATH/builds/windows/vc2010/freetype.vcxproj" 56923 if test "x$BUILD_FREETYPE" = xyes && ! test -s $vcxproj_path; then 56924 { $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 56925 $as_echo "$as_me: WARNING: Can not find project file $vcxproj_path (you may try a newer freetype version) - ignoring --with-freetype-src" >&2;} 56926 BUILD_FREETYPE=no 56927 fi 56928 # Now check if configure found a version of 'msbuild.exe' 56929 if test "x$BUILD_FREETYPE" = xyes && test "x$MSBUILD" == x ; then 56930 { $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 56931 $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;} 56932 BUILD_FREETYPE=no 56933 fi 56934 56935 # Ready to go.. 56936 if test "x$BUILD_FREETYPE" = xyes; then 56937 # msbuild requires trailing slashes for output directories 56938 freetype_lib_path="$FREETYPE_SRC_PATH/lib$OPENJDK_TARGET_CPU_BITS/" 56939 freetype_lib_path_unix="$freetype_lib_path" 56940 freetype_obj_path="$FREETYPE_SRC_PATH/obj$OPENJDK_TARGET_CPU_BITS/" 56941 56942 unix_path="$vcxproj_path" 56943 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56944 windows_path=`$CYGPATH -m "$unix_path"` 56945 vcxproj_path="$windows_path" 56946 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56947 windows_path=`cmd //c echo $unix_path` 56948 vcxproj_path="$windows_path" 56949 fi 56950 56951 56952 unix_path="$freetype_lib_path" 56953 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56954 windows_path=`$CYGPATH -m "$unix_path"` 56955 freetype_lib_path="$windows_path" 56956 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56957 windows_path=`cmd //c echo $unix_path` 56958 freetype_lib_path="$windows_path" 56959 fi 56960 56961 56962 unix_path="$freetype_obj_path" 56963 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56964 windows_path=`$CYGPATH -m "$unix_path"` 56965 freetype_obj_path="$windows_path" 56966 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56967 windows_path=`cmd //c echo $unix_path` 56968 freetype_obj_path="$windows_path" 56969 fi 56970 56971 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 56972 freetype_platform=x64 56973 else 56974 freetype_platform=win32 56975 fi 56976 56977 # The original freetype project file is for VS 2010 (i.e. 'v100'), 56978 # so we have to adapt the toolset if building with any other toolsed (i.e. SDK). 56979 # Currently 'PLATFORM_TOOLSET' is set in 'TOOLCHAIN_CHECK_POSSIBLE_VISUAL_STUDIO_ROOT'/ 56980 # 'TOOLCHAIN_CHECK_POSSIBLE_WIN_SDK_ROOT' in toolchain_windows.m4 56981 { $as_echo "$as_me:${as_lineno-$LINENO}: Trying to compile freetype sources with PlatformToolset=$PLATFORM_TOOLSET to $freetype_lib_path_unix ..." >&5 56982 $as_echo "$as_me: Trying to compile freetype sources with PlatformToolset=$PLATFORM_TOOLSET to $freetype_lib_path_unix ..." >&6;} 56983 56984 # First we try to build the freetype.dll 56985 $ECHO -e "@echo off\n"\ 56986 "$MSBUILD $vcxproj_path "\ 56987 "/p:PlatformToolset=$PLATFORM_TOOLSET "\ 56988 "/p:Configuration=\"Release Multithreaded\" "\ 56989 "/p:Platform=$freetype_platform "\ 56990 "/p:ConfigurationType=DynamicLibrary "\ 56991 "/p:TargetName=freetype "\ 56992 "/p:OutDir=\"$freetype_lib_path\" "\ 56993 "/p:IntDir=\"$freetype_obj_path\" > freetype.log" > freetype.bat 56994 cmd /c freetype.bat 56995 56996 if test -s "$freetype_lib_path_unix/freetype.dll"; then 56997 # If that succeeds we also build freetype.lib 56998 $ECHO -e "@echo off\n"\ 56999 "$MSBUILD $vcxproj_path "\ 57000 "/p:PlatformToolset=$PLATFORM_TOOLSET "\ 57001 "/p:Configuration=\"Release Multithreaded\" "\ 57002 "/p:Platform=$freetype_platform "\ 57003 "/p:ConfigurationType=StaticLibrary "\ 57004 "/p:TargetName=freetype "\ 57005 "/p:OutDir=\"$freetype_lib_path\" "\ 57006 "/p:IntDir=\"$freetype_obj_path\" >> freetype.log" > freetype.bat 57007 cmd /c freetype.bat 57008 57009 if test -s "$freetype_lib_path_unix/freetype.lib"; then 57010 # Once we build both, lib and dll, set freetype lib and include path appropriately 57011 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_SRC_PATH/include" 57012 POTENTIAL_FREETYPE_LIB_PATH="$freetype_lib_path_unix" 57013 { $as_echo "$as_me:${as_lineno-$LINENO}: Compiling freetype sources succeeded! (see freetype.log for build results)" >&5 57014 $as_echo "$as_me: Compiling freetype sources succeeded! (see freetype.log for build results)" >&6;} 57015 else 57016 BUILD_FREETYPE=no 57017 fi 57018 else 57019 BUILD_FREETYPE=no 57020 fi 57021 fi 57022 57023 if test "x$BUILD_FREETYPE" = xyes; then 57024 # Okay, we built it. Check that it works. 57025 57026 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57027 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 57028 METHOD="--with-freetype-src" 57029 57030 # Let's start with an optimistic view of the world :-) 57031 FOUND_FREETYPE=yes 57032 57033 # First look for the canonical freetype main include file ft2build.h. 57034 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 57035 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 57036 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 57037 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 57038 # Fail. 57039 FOUND_FREETYPE=no 57040 fi 57041 fi 57042 57043 if test "x$FOUND_FREETYPE" = xyes; then 57044 # Include file found, let's continue the sanity check. 57045 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 57046 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 57047 57048 # Reset to default value 57049 FREETYPE_BASE_NAME=freetype 57050 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 57051 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 57052 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 57053 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 57054 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 57055 # for the .6 version explicitly. 57056 FREETYPE_BASE_NAME=freetype.6 57057 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 57058 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 57059 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 57060 else 57061 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 57062 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 57063 FOUND_FREETYPE=no 57064 fi 57065 else 57066 if test "x$OPENJDK_TARGET_OS" = xwindows; then 57067 # On Windows, we will need both .lib and .dll file. 57068 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 57069 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 57070 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 57071 FOUND_FREETYPE=no 57072 fi 57073 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 57074 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 57075 # Found lib in isa dir, use that instead. 57076 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 57077 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 57078 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 57079 fi 57080 fi 57081 fi 57082 57083 if test "x$FOUND_FREETYPE" = xyes; then 57084 57085 # Only process if variable expands to non-empty 57086 57087 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 57088 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57089 57090 # Input might be given as Windows format, start by converting to 57091 # unix format. 57092 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57093 new_path=`$CYGPATH -u "$path"` 57094 57095 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 57096 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 57097 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 57098 # "foo.exe" is OK but "foo" is an error. 57099 # 57100 # This test is therefore slightly more accurate than "test -f" to check for file precense. 57101 # It is also a way to make sure we got the proper file name for the real test later on. 57102 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 57103 if test "x$test_shortpath" = x; then 57104 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 57105 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 57106 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 57107 fi 57108 57109 # Call helper function which possibly converts this using DOS-style short mode. 57110 # If so, the updated path is stored in $new_path. 57111 57112 input_path="$new_path" 57113 # Check if we need to convert this using DOS-style short mode. If the path 57114 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57115 # take no chances and rewrite it. 57116 # Note: m4 eats our [], so we need to use [ and ] instead. 57117 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 57118 if test "x$has_forbidden_chars" != x; then 57119 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57120 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 57121 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 57122 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 57123 # Going to short mode and back again did indeed matter. Since short mode is 57124 # case insensitive, let's make it lowercase to improve readability. 57125 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57126 # Now convert it back to Unix-style (cygpath) 57127 input_path=`$CYGPATH -u "$shortmode_path"` 57128 new_path="$input_path" 57129 fi 57130 fi 57131 57132 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 57133 if test "x$test_cygdrive_prefix" = x; then 57134 # As a simple fix, exclude /usr/bin since it's not a real path. 57135 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 57136 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 57137 # a path prefixed by /cygdrive for fixpath to work. 57138 new_path="$CYGWIN_ROOT_PATH$input_path" 57139 fi 57140 fi 57141 57142 57143 if test "x$path" != "x$new_path"; then 57144 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 57145 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 57146 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 57147 fi 57148 57149 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57150 57151 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57152 has_colon=`$ECHO $path | $GREP ^.:` 57153 new_path="$path" 57154 if test "x$has_colon" = x; then 57155 # Not in mixed or Windows style, start by that. 57156 new_path=`cmd //c echo $path` 57157 fi 57158 57159 57160 input_path="$new_path" 57161 # Check if we need to convert this using DOS-style short mode. If the path 57162 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57163 # take no chances and rewrite it. 57164 # Note: m4 eats our [], so we need to use [ and ] instead. 57165 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 57166 if test "x$has_forbidden_chars" != x; then 57167 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57168 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57169 fi 57170 57171 57172 windows_path="$new_path" 57173 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57174 unix_path=`$CYGPATH -u "$windows_path"` 57175 new_path="$unix_path" 57176 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57177 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 57178 new_path="$unix_path" 57179 fi 57180 57181 if test "x$path" != "x$new_path"; then 57182 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 57183 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 57184 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 57185 fi 57186 57187 # Save the first 10 bytes of this path to the storage, so fixpath can work. 57188 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 57189 57190 else 57191 # We're on a unix platform. Hooray! :) 57192 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57193 has_space=`$ECHO "$path" | $GREP " "` 57194 if test "x$has_space" != x; then 57195 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 57196 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 57197 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 57198 fi 57199 57200 # Use eval to expand a potential ~ 57201 eval path="$path" 57202 if test ! -f "$path" && test ! -d "$path"; then 57203 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 57204 fi 57205 57206 if test -d "$path"; then 57207 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 57208 else 57209 dir="`$DIRNAME "$path"`" 57210 base="`$BASENAME "$path"`" 57211 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 57212 fi 57213 fi 57214 fi 57215 57216 57217 # Only process if variable expands to non-empty 57218 57219 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 57220 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57221 57222 # Input might be given as Windows format, start by converting to 57223 # unix format. 57224 path="$POTENTIAL_FREETYPE_LIB_PATH" 57225 new_path=`$CYGPATH -u "$path"` 57226 57227 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 57228 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 57229 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 57230 # "foo.exe" is OK but "foo" is an error. 57231 # 57232 # This test is therefore slightly more accurate than "test -f" to check for file precense. 57233 # It is also a way to make sure we got the proper file name for the real test later on. 57234 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 57235 if test "x$test_shortpath" = x; then 57236 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 57237 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 57238 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 57239 fi 57240 57241 # Call helper function which possibly converts this using DOS-style short mode. 57242 # If so, the updated path is stored in $new_path. 57243 57244 input_path="$new_path" 57245 # Check if we need to convert this using DOS-style short mode. If the path 57246 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57247 # take no chances and rewrite it. 57248 # Note: m4 eats our [], so we need to use [ and ] instead. 57249 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 57250 if test "x$has_forbidden_chars" != x; then 57251 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57252 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 57253 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 57254 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 57255 # Going to short mode and back again did indeed matter. Since short mode is 57256 # case insensitive, let's make it lowercase to improve readability. 57257 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57258 # Now convert it back to Unix-style (cygpath) 57259 input_path=`$CYGPATH -u "$shortmode_path"` 57260 new_path="$input_path" 57261 fi 57262 fi 57263 57264 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 57265 if test "x$test_cygdrive_prefix" = x; then 57266 # As a simple fix, exclude /usr/bin since it's not a real path. 57267 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 57268 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 57269 # a path prefixed by /cygdrive for fixpath to work. 57270 new_path="$CYGWIN_ROOT_PATH$input_path" 57271 fi 57272 fi 57273 57274 57275 if test "x$path" != "x$new_path"; then 57276 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 57277 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 57278 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 57279 fi 57280 57281 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57282 57283 path="$POTENTIAL_FREETYPE_LIB_PATH" 57284 has_colon=`$ECHO $path | $GREP ^.:` 57285 new_path="$path" 57286 if test "x$has_colon" = x; then 57287 # Not in mixed or Windows style, start by that. 57288 new_path=`cmd //c echo $path` 57289 fi 57290 57291 57292 input_path="$new_path" 57293 # Check if we need to convert this using DOS-style short mode. If the path 57294 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57295 # take no chances and rewrite it. 57296 # Note: m4 eats our [], so we need to use [ and ] instead. 57297 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 57298 if test "x$has_forbidden_chars" != x; then 57299 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57300 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57301 fi 57302 57303 57304 windows_path="$new_path" 57305 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57306 unix_path=`$CYGPATH -u "$windows_path"` 57307 new_path="$unix_path" 57308 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57309 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 57310 new_path="$unix_path" 57311 fi 57312 57313 if test "x$path" != "x$new_path"; then 57314 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 57315 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 57316 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 57317 fi 57318 57319 # Save the first 10 bytes of this path to the storage, so fixpath can work. 57320 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 57321 57322 else 57323 # We're on a unix platform. Hooray! :) 57324 path="$POTENTIAL_FREETYPE_LIB_PATH" 57325 has_space=`$ECHO "$path" | $GREP " "` 57326 if test "x$has_space" != x; then 57327 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 57328 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 57329 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 57330 fi 57331 57332 # Use eval to expand a potential ~ 57333 eval path="$path" 57334 if test ! -f "$path" && test ! -d "$path"; then 57335 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 57336 fi 57337 57338 if test -d "$path"; then 57339 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 57340 else 57341 dir="`$DIRNAME "$path"`" 57342 base="`$BASENAME "$path"`" 57343 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 57344 fi 57345 fi 57346 fi 57347 57348 57349 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57350 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 57351 $as_echo_n "checking for freetype includes... " >&6; } 57352 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 57353 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 57354 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 57355 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 57356 $as_echo_n "checking for freetype libraries... " >&6; } 57357 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 57358 $as_echo "$FREETYPE_LIB_PATH" >&6; } 57359 fi 57360 57361 if test "x$FOUND_FREETYPE" != xyes; then 57362 as_fn_error $? "Can not use the built freetype at location given by --with-freetype-src" "$LINENO" 5 57363 fi 57364 else 57365 { $as_echo "$as_me:${as_lineno-$LINENO}: User specified --with-freetype-src but building freetype failed. (see freetype.log for build results)" >&5 57366 $as_echo "$as_me: User specified --with-freetype-src but building freetype failed. (see freetype.log for build results)" >&6;} 57367 as_fn_error $? "Consider building freetype manually and using --with-freetype instead." "$LINENO" 5 57368 fi 57369 else 57370 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-freetype-src is currently only supported on Windows - ignoring" >&5 57371 $as_echo "$as_me: WARNING: --with-freetype-src is currently only supported on Windows - ignoring" >&2;} 57372 fi 57373 fi 57374 57375 if test "x$with_freetype" != x || test "x$with_freetype_include" != x || test "x$with_freetype_lib" != x; then 57376 # User has specified settings 57377 57378 if test "x$BUNDLE_FREETYPE" = x; then 57379 # If not specified, default is to bundle freetype 57380 BUNDLE_FREETYPE=yes 57381 fi 57382 57383 if test "x$with_freetype" != x; then 57384 POTENTIAL_FREETYPE_INCLUDE_PATH="$with_freetype/include" 57385 POTENTIAL_FREETYPE_LIB_PATH="$with_freetype/lib" 57386 fi 57387 57388 # Allow --with-freetype-lib and --with-freetype-include to override 57389 if test "x$with_freetype_include" != x; then 57390 POTENTIAL_FREETYPE_INCLUDE_PATH="$with_freetype_include" 57391 fi 57392 if test "x$with_freetype_lib" != x; then 57393 POTENTIAL_FREETYPE_LIB_PATH="$with_freetype_lib" 57394 fi 57395 57396 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x && test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 57397 # Okay, we got it. Check that it works. 57398 57399 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57400 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 57401 METHOD="--with-freetype" 57402 57403 # Let's start with an optimistic view of the world :-) 57404 FOUND_FREETYPE=yes 57405 57406 # First look for the canonical freetype main include file ft2build.h. 57407 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 57408 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 57409 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 57410 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 57411 # Fail. 57412 FOUND_FREETYPE=no 57413 fi 57414 fi 57415 57416 if test "x$FOUND_FREETYPE" = xyes; then 57417 # Include file found, let's continue the sanity check. 57418 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 57419 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 57420 57421 # Reset to default value 57422 FREETYPE_BASE_NAME=freetype 57423 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 57424 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 57425 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 57426 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 57427 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 57428 # for the .6 version explicitly. 57429 FREETYPE_BASE_NAME=freetype.6 57430 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 57431 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 57432 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 57433 else 57434 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 57435 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 57436 FOUND_FREETYPE=no 57437 fi 57438 else 57439 if test "x$OPENJDK_TARGET_OS" = xwindows; then 57440 # On Windows, we will need both .lib and .dll file. 57441 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 57442 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 57443 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 57444 FOUND_FREETYPE=no 57445 fi 57446 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 57447 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 57448 # Found lib in isa dir, use that instead. 57449 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 57450 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 57451 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 57452 fi 57453 fi 57454 fi 57455 57456 if test "x$FOUND_FREETYPE" = xyes; then 57457 57458 # Only process if variable expands to non-empty 57459 57460 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 57461 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57462 57463 # Input might be given as Windows format, start by converting to 57464 # unix format. 57465 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57466 new_path=`$CYGPATH -u "$path"` 57467 57468 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 57469 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 57470 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 57471 # "foo.exe" is OK but "foo" is an error. 57472 # 57473 # This test is therefore slightly more accurate than "test -f" to check for file precense. 57474 # It is also a way to make sure we got the proper file name for the real test later on. 57475 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 57476 if test "x$test_shortpath" = x; then 57477 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 57478 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 57479 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 57480 fi 57481 57482 # Call helper function which possibly converts this using DOS-style short mode. 57483 # If so, the updated path is stored in $new_path. 57484 57485 input_path="$new_path" 57486 # Check if we need to convert this using DOS-style short mode. If the path 57487 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57488 # take no chances and rewrite it. 57489 # Note: m4 eats our [], so we need to use [ and ] instead. 57490 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 57491 if test "x$has_forbidden_chars" != x; then 57492 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57493 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 57494 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 57495 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 57496 # Going to short mode and back again did indeed matter. Since short mode is 57497 # case insensitive, let's make it lowercase to improve readability. 57498 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57499 # Now convert it back to Unix-style (cygpath) 57500 input_path=`$CYGPATH -u "$shortmode_path"` 57501 new_path="$input_path" 57502 fi 57503 fi 57504 57505 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 57506 if test "x$test_cygdrive_prefix" = x; then 57507 # As a simple fix, exclude /usr/bin since it's not a real path. 57508 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 57509 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 57510 # a path prefixed by /cygdrive for fixpath to work. 57511 new_path="$CYGWIN_ROOT_PATH$input_path" 57512 fi 57513 fi 57514 57515 57516 if test "x$path" != "x$new_path"; then 57517 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 57518 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 57519 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 57520 fi 57521 57522 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57523 57524 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57525 has_colon=`$ECHO $path | $GREP ^.:` 57526 new_path="$path" 57527 if test "x$has_colon" = x; then 57528 # Not in mixed or Windows style, start by that. 57529 new_path=`cmd //c echo $path` 57530 fi 57531 57532 57533 input_path="$new_path" 57534 # Check if we need to convert this using DOS-style short mode. If the path 57535 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57536 # take no chances and rewrite it. 57537 # Note: m4 eats our [], so we need to use [ and ] instead. 57538 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 57539 if test "x$has_forbidden_chars" != x; then 57540 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57541 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57542 fi 57543 57544 57545 windows_path="$new_path" 57546 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57547 unix_path=`$CYGPATH -u "$windows_path"` 57548 new_path="$unix_path" 57549 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57550 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 57551 new_path="$unix_path" 57552 fi 57553 57554 if test "x$path" != "x$new_path"; then 57555 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 57556 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 57557 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 57558 fi 57559 57560 # Save the first 10 bytes of this path to the storage, so fixpath can work. 57561 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 57562 57563 else 57564 # We're on a unix platform. Hooray! :) 57565 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57566 has_space=`$ECHO "$path" | $GREP " "` 57567 if test "x$has_space" != x; then 57568 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 57569 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 57570 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 57571 fi 57572 57573 # Use eval to expand a potential ~ 57574 eval path="$path" 57575 if test ! -f "$path" && test ! -d "$path"; then 57576 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 57577 fi 57578 57579 if test -d "$path"; then 57580 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 57581 else 57582 dir="`$DIRNAME "$path"`" 57583 base="`$BASENAME "$path"`" 57584 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 57585 fi 57586 fi 57587 fi 57588 57589 57590 # Only process if variable expands to non-empty 57591 57592 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 57593 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57594 57595 # Input might be given as Windows format, start by converting to 57596 # unix format. 57597 path="$POTENTIAL_FREETYPE_LIB_PATH" 57598 new_path=`$CYGPATH -u "$path"` 57599 57600 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 57601 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 57602 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 57603 # "foo.exe" is OK but "foo" is an error. 57604 # 57605 # This test is therefore slightly more accurate than "test -f" to check for file precense. 57606 # It is also a way to make sure we got the proper file name for the real test later on. 57607 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 57608 if test "x$test_shortpath" = x; then 57609 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 57610 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 57611 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 57612 fi 57613 57614 # Call helper function which possibly converts this using DOS-style short mode. 57615 # If so, the updated path is stored in $new_path. 57616 57617 input_path="$new_path" 57618 # Check if we need to convert this using DOS-style short mode. If the path 57619 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57620 # take no chances and rewrite it. 57621 # Note: m4 eats our [], so we need to use [ and ] instead. 57622 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 57623 if test "x$has_forbidden_chars" != x; then 57624 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57625 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 57626 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 57627 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 57628 # Going to short mode and back again did indeed matter. Since short mode is 57629 # case insensitive, let's make it lowercase to improve readability. 57630 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57631 # Now convert it back to Unix-style (cygpath) 57632 input_path=`$CYGPATH -u "$shortmode_path"` 57633 new_path="$input_path" 57634 fi 57635 fi 57636 57637 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 57638 if test "x$test_cygdrive_prefix" = x; then 57639 # As a simple fix, exclude /usr/bin since it's not a real path. 57640 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 57641 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 57642 # a path prefixed by /cygdrive for fixpath to work. 57643 new_path="$CYGWIN_ROOT_PATH$input_path" 57644 fi 57645 fi 57646 57647 57648 if test "x$path" != "x$new_path"; then 57649 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 57650 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 57651 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 57652 fi 57653 57654 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57655 57656 path="$POTENTIAL_FREETYPE_LIB_PATH" 57657 has_colon=`$ECHO $path | $GREP ^.:` 57658 new_path="$path" 57659 if test "x$has_colon" = x; then 57660 # Not in mixed or Windows style, start by that. 57661 new_path=`cmd //c echo $path` 57662 fi 57663 57664 57665 input_path="$new_path" 57666 # Check if we need to convert this using DOS-style short mode. If the path 57667 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57668 # take no chances and rewrite it. 57669 # Note: m4 eats our [], so we need to use [ and ] instead. 57670 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 57671 if test "x$has_forbidden_chars" != x; then 57672 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57673 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57674 fi 57675 57676 57677 windows_path="$new_path" 57678 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57679 unix_path=`$CYGPATH -u "$windows_path"` 57680 new_path="$unix_path" 57681 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57682 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 57683 new_path="$unix_path" 57684 fi 57685 57686 if test "x$path" != "x$new_path"; then 57687 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 57688 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 57689 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 57690 fi 57691 57692 # Save the first 10 bytes of this path to the storage, so fixpath can work. 57693 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 57694 57695 else 57696 # We're on a unix platform. Hooray! :) 57697 path="$POTENTIAL_FREETYPE_LIB_PATH" 57698 has_space=`$ECHO "$path" | $GREP " "` 57699 if test "x$has_space" != x; then 57700 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 57701 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 57702 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 57703 fi 57704 57705 # Use eval to expand a potential ~ 57706 eval path="$path" 57707 if test ! -f "$path" && test ! -d "$path"; then 57708 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 57709 fi 57710 57711 if test -d "$path"; then 57712 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 57713 else 57714 dir="`$DIRNAME "$path"`" 57715 base="`$BASENAME "$path"`" 57716 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 57717 fi 57718 fi 57719 fi 57720 57721 57722 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57723 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 57724 $as_echo_n "checking for freetype includes... " >&6; } 57725 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 57726 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 57727 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 57728 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 57729 $as_echo_n "checking for freetype libraries... " >&6; } 57730 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 57731 $as_echo "$FREETYPE_LIB_PATH" >&6; } 57732 fi 57733 57734 if test "x$FOUND_FREETYPE" != xyes; then 57735 as_fn_error $? "Can not find or use freetype at location given by --with-freetype" "$LINENO" 5 57736 fi 57737 else 57738 # User specified only one of lib or include. This is an error. 57739 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" = x ; then 57740 { $as_echo "$as_me:${as_lineno-$LINENO}: User specified --with-freetype-lib but not --with-freetype-include" >&5 57741 $as_echo "$as_me: User specified --with-freetype-lib but not --with-freetype-include" >&6;} 57742 as_fn_error $? "Need both freetype lib and include paths. Consider using --with-freetype instead." "$LINENO" 5 57743 else 57744 { $as_echo "$as_me:${as_lineno-$LINENO}: User specified --with-freetype-include but not --with-freetype-lib" >&5 57745 $as_echo "$as_me: User specified --with-freetype-include but not --with-freetype-lib" >&6;} 57746 as_fn_error $? "Need both freetype lib and include paths. Consider using --with-freetype instead." "$LINENO" 5 57747 fi 57748 fi 57749 else 57750 # User did not specify settings, but we need freetype. Try to locate it. 57751 57752 if test "x$BUNDLE_FREETYPE" = x; then 57753 # If not specified, default is to bundle freetype only on windows 57754 if test "x$OPENJDK_TARGET_OS" = xwindows; then 57755 BUNDLE_FREETYPE=yes 57756 else 57757 BUNDLE_FREETYPE=no 57758 fi 57759 fi 57760 57761 # If we have a sysroot, assume that's where we are supposed to look and skip pkg-config. 57762 if test "x$SYSROOT" = x; then 57763 if test "x$FOUND_FREETYPE" != xyes; then 57764 # Check modules using pkg-config, but only if we have it (ugly output results otherwise) 57765 if test "x$PKG_CONFIG" != x; then 57766 57767 pkg_failed=no 57768 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FREETYPE" >&5 57769 $as_echo_n "checking for FREETYPE... " >&6; } 57770 57771 if test -n "$FREETYPE_CFLAGS"; then 57772 pkg_cv_FREETYPE_CFLAGS="$FREETYPE_CFLAGS" 57773 elif test -n "$PKG_CONFIG"; then 57774 if test -n "$PKG_CONFIG" && \ 57775 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"freetype2\""; } >&5 57776 ($PKG_CONFIG --exists --print-errors "freetype2") 2>&5 57777 ac_status=$? 57778 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 57779 test $ac_status = 0; }; then 57780 pkg_cv_FREETYPE_CFLAGS=`$PKG_CONFIG --cflags "freetype2" 2>/dev/null` 57781 else 57782 pkg_failed=yes 57783 fi 57784 else 57785 pkg_failed=untried 57786 fi 57787 if test -n "$FREETYPE_LIBS"; then 57788 pkg_cv_FREETYPE_LIBS="$FREETYPE_LIBS" 57789 elif test -n "$PKG_CONFIG"; then 57790 if test -n "$PKG_CONFIG" && \ 57791 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"freetype2\""; } >&5 57792 ($PKG_CONFIG --exists --print-errors "freetype2") 2>&5 57793 ac_status=$? 57794 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 57795 test $ac_status = 0; }; then 57796 pkg_cv_FREETYPE_LIBS=`$PKG_CONFIG --libs "freetype2" 2>/dev/null` 57797 else 57798 pkg_failed=yes 57799 fi 57800 else 57801 pkg_failed=untried 57802 fi 57803 57804 57805 57806 if test $pkg_failed = yes; then 57807 57808 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 57809 _pkg_short_errors_supported=yes 57810 else 57811 _pkg_short_errors_supported=no 57812 fi 57813 if test $_pkg_short_errors_supported = yes; then 57814 FREETYPE_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "freetype2" 2>&1` 57815 else 57816 FREETYPE_PKG_ERRORS=`$PKG_CONFIG --print-errors "freetype2" 2>&1` 57817 fi 57818 # Put the nasty error message in config.log where it belongs 57819 echo "$FREETYPE_PKG_ERRORS" >&5 57820 57821 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 57822 $as_echo "no" >&6; } 57823 FOUND_FREETYPE=no 57824 elif test $pkg_failed = untried; then 57825 FOUND_FREETYPE=no 57826 else 57827 FREETYPE_CFLAGS=$pkg_cv_FREETYPE_CFLAGS 57828 FREETYPE_LIBS=$pkg_cv_FREETYPE_LIBS 57829 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 57830 $as_echo "yes" >&6; } 57831 FOUND_FREETYPE=yes 57832 fi 57833 if test "x$FOUND_FREETYPE" = xyes; then 57834 # On solaris, pkg_check adds -lz to freetype libs, which isn't necessary for us. 57835 FREETYPE_LIBS=`$ECHO $FREETYPE_LIBS | $SED 's/-lz//g'` 57836 # 64-bit libs for Solaris x86 are installed in the amd64 subdirectory, change lib to lib/amd64 57837 if test "x$OPENJDK_TARGET_OS" = xsolaris && test "x$OPENJDK_TARGET_CPU" = xx86_64; then 57838 FREETYPE_LIBS=`$ECHO $FREETYPE_LIBS | $SED 's?/lib?/lib/amd64?g'` 57839 fi 57840 # PKG_CHECK_MODULES will set FREETYPE_CFLAGS and _LIBS, but we don't get a lib path for bundling. 57841 if test "x$BUNDLE_FREETYPE" = xyes; then 57842 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype using pkg-config, but ignoring since we can not bundle that" >&5 57843 $as_echo "$as_me: Found freetype using pkg-config, but ignoring since we can not bundle that" >&6;} 57844 FOUND_FREETYPE=no 57845 else 57846 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype" >&5 57847 $as_echo_n "checking for freetype... " >&6; } 57848 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (using pkg-config)" >&5 57849 $as_echo "yes (using pkg-config)" >&6; } 57850 fi 57851 fi 57852 fi 57853 fi 57854 fi 57855 57856 if test "x$FOUND_FREETYPE" != xyes; then 57857 # Check in well-known locations 57858 if test "x$OPENJDK_TARGET_OS" = xwindows; then 57859 FREETYPE_BASE_DIR="$PROGRAMFILES/GnuWin32" 57860 57861 windows_path="$FREETYPE_BASE_DIR" 57862 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57863 unix_path=`$CYGPATH -u "$windows_path"` 57864 FREETYPE_BASE_DIR="$unix_path" 57865 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57866 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 57867 FREETYPE_BASE_DIR="$unix_path" 57868 fi 57869 57870 57871 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 57872 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 57873 METHOD="well-known location" 57874 57875 # Let's start with an optimistic view of the world :-) 57876 FOUND_FREETYPE=yes 57877 57878 # First look for the canonical freetype main include file ft2build.h. 57879 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 57880 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 57881 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 57882 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 57883 # Fail. 57884 FOUND_FREETYPE=no 57885 fi 57886 fi 57887 57888 if test "x$FOUND_FREETYPE" = xyes; then 57889 # Include file found, let's continue the sanity check. 57890 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 57891 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 57892 57893 # Reset to default value 57894 FREETYPE_BASE_NAME=freetype 57895 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 57896 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 57897 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 57898 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 57899 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 57900 # for the .6 version explicitly. 57901 FREETYPE_BASE_NAME=freetype.6 57902 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 57903 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 57904 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 57905 else 57906 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 57907 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 57908 FOUND_FREETYPE=no 57909 fi 57910 else 57911 if test "x$OPENJDK_TARGET_OS" = xwindows; then 57912 # On Windows, we will need both .lib and .dll file. 57913 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 57914 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 57915 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 57916 FOUND_FREETYPE=no 57917 fi 57918 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 57919 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 57920 # Found lib in isa dir, use that instead. 57921 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 57922 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 57923 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 57924 fi 57925 fi 57926 fi 57927 57928 if test "x$FOUND_FREETYPE" = xyes; then 57929 57930 # Only process if variable expands to non-empty 57931 57932 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 57933 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57934 57935 # Input might be given as Windows format, start by converting to 57936 # unix format. 57937 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57938 new_path=`$CYGPATH -u "$path"` 57939 57940 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 57941 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 57942 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 57943 # "foo.exe" is OK but "foo" is an error. 57944 # 57945 # This test is therefore slightly more accurate than "test -f" to check for file precense. 57946 # It is also a way to make sure we got the proper file name for the real test later on. 57947 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 57948 if test "x$test_shortpath" = x; then 57949 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 57950 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 57951 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 57952 fi 57953 57954 # Call helper function which possibly converts this using DOS-style short mode. 57955 # If so, the updated path is stored in $new_path. 57956 57957 input_path="$new_path" 57958 # Check if we need to convert this using DOS-style short mode. If the path 57959 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57960 # take no chances and rewrite it. 57961 # Note: m4 eats our [], so we need to use [ and ] instead. 57962 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 57963 if test "x$has_forbidden_chars" != x; then 57964 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57965 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 57966 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 57967 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 57968 # Going to short mode and back again did indeed matter. Since short mode is 57969 # case insensitive, let's make it lowercase to improve readability. 57970 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57971 # Now convert it back to Unix-style (cygpath) 57972 input_path=`$CYGPATH -u "$shortmode_path"` 57973 new_path="$input_path" 57974 fi 57975 fi 57976 57977 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 57978 if test "x$test_cygdrive_prefix" = x; then 57979 # As a simple fix, exclude /usr/bin since it's not a real path. 57980 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 57981 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 57982 # a path prefixed by /cygdrive for fixpath to work. 57983 new_path="$CYGWIN_ROOT_PATH$input_path" 57984 fi 57985 fi 57986 57987 57988 if test "x$path" != "x$new_path"; then 57989 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 57990 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 57991 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 57992 fi 57993 57994 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57995 57996 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57997 has_colon=`$ECHO $path | $GREP ^.:` 57998 new_path="$path" 57999 if test "x$has_colon" = x; then 58000 # Not in mixed or Windows style, start by that. 58001 new_path=`cmd //c echo $path` 58002 fi 58003 58004 58005 input_path="$new_path" 58006 # Check if we need to convert this using DOS-style short mode. If the path 58007 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58008 # take no chances and rewrite it. 58009 # Note: m4 eats our [], so we need to use [ and ] instead. 58010 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 58011 if test "x$has_forbidden_chars" != x; then 58012 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58013 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58014 fi 58015 58016 58017 windows_path="$new_path" 58018 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58019 unix_path=`$CYGPATH -u "$windows_path"` 58020 new_path="$unix_path" 58021 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58022 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58023 new_path="$unix_path" 58024 fi 58025 58026 if test "x$path" != "x$new_path"; then 58027 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 58028 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 58029 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 58030 fi 58031 58032 # Save the first 10 bytes of this path to the storage, so fixpath can work. 58033 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 58034 58035 else 58036 # We're on a unix platform. Hooray! :) 58037 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58038 has_space=`$ECHO "$path" | $GREP " "` 58039 if test "x$has_space" != x; then 58040 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 58041 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 58042 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 58043 fi 58044 58045 # Use eval to expand a potential ~ 58046 eval path="$path" 58047 if test ! -f "$path" && test ! -d "$path"; then 58048 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 58049 fi 58050 58051 if test -d "$path"; then 58052 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 58053 else 58054 dir="`$DIRNAME "$path"`" 58055 base="`$BASENAME "$path"`" 58056 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 58057 fi 58058 fi 58059 fi 58060 58061 58062 # Only process if variable expands to non-empty 58063 58064 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 58065 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58066 58067 # Input might be given as Windows format, start by converting to 58068 # unix format. 58069 path="$POTENTIAL_FREETYPE_LIB_PATH" 58070 new_path=`$CYGPATH -u "$path"` 58071 58072 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 58073 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 58074 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 58075 # "foo.exe" is OK but "foo" is an error. 58076 # 58077 # This test is therefore slightly more accurate than "test -f" to check for file precense. 58078 # It is also a way to make sure we got the proper file name for the real test later on. 58079 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 58080 if test "x$test_shortpath" = x; then 58081 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 58082 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 58083 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 58084 fi 58085 58086 # Call helper function which possibly converts this using DOS-style short mode. 58087 # If so, the updated path is stored in $new_path. 58088 58089 input_path="$new_path" 58090 # Check if we need to convert this using DOS-style short mode. If the path 58091 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58092 # take no chances and rewrite it. 58093 # Note: m4 eats our [], so we need to use [ and ] instead. 58094 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 58095 if test "x$has_forbidden_chars" != x; then 58096 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58097 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 58098 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 58099 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 58100 # Going to short mode and back again did indeed matter. Since short mode is 58101 # case insensitive, let's make it lowercase to improve readability. 58102 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58103 # Now convert it back to Unix-style (cygpath) 58104 input_path=`$CYGPATH -u "$shortmode_path"` 58105 new_path="$input_path" 58106 fi 58107 fi 58108 58109 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 58110 if test "x$test_cygdrive_prefix" = x; then 58111 # As a simple fix, exclude /usr/bin since it's not a real path. 58112 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 58113 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 58114 # a path prefixed by /cygdrive for fixpath to work. 58115 new_path="$CYGWIN_ROOT_PATH$input_path" 58116 fi 58117 fi 58118 58119 58120 if test "x$path" != "x$new_path"; then 58121 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 58122 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 58123 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 58124 fi 58125 58126 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58127 58128 path="$POTENTIAL_FREETYPE_LIB_PATH" 58129 has_colon=`$ECHO $path | $GREP ^.:` 58130 new_path="$path" 58131 if test "x$has_colon" = x; then 58132 # Not in mixed or Windows style, start by that. 58133 new_path=`cmd //c echo $path` 58134 fi 58135 58136 58137 input_path="$new_path" 58138 # Check if we need to convert this using DOS-style short mode. If the path 58139 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58140 # take no chances and rewrite it. 58141 # Note: m4 eats our [], so we need to use [ and ] instead. 58142 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 58143 if test "x$has_forbidden_chars" != x; then 58144 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58145 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58146 fi 58147 58148 58149 windows_path="$new_path" 58150 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58151 unix_path=`$CYGPATH -u "$windows_path"` 58152 new_path="$unix_path" 58153 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58154 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58155 new_path="$unix_path" 58156 fi 58157 58158 if test "x$path" != "x$new_path"; then 58159 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 58160 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 58161 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 58162 fi 58163 58164 # Save the first 10 bytes of this path to the storage, so fixpath can work. 58165 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 58166 58167 else 58168 # We're on a unix platform. Hooray! :) 58169 path="$POTENTIAL_FREETYPE_LIB_PATH" 58170 has_space=`$ECHO "$path" | $GREP " "` 58171 if test "x$has_space" != x; then 58172 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 58173 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 58174 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 58175 fi 58176 58177 # Use eval to expand a potential ~ 58178 eval path="$path" 58179 if test ! -f "$path" && test ! -d "$path"; then 58180 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 58181 fi 58182 58183 if test -d "$path"; then 58184 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 58185 else 58186 dir="`$DIRNAME "$path"`" 58187 base="`$BASENAME "$path"`" 58188 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 58189 fi 58190 fi 58191 fi 58192 58193 58194 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58195 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 58196 $as_echo_n "checking for freetype includes... " >&6; } 58197 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 58198 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 58199 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 58200 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 58201 $as_echo_n "checking for freetype libraries... " >&6; } 58202 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 58203 $as_echo "$FREETYPE_LIB_PATH" >&6; } 58204 fi 58205 58206 if test "x$FOUND_FREETYPE" != xyes; then 58207 FREETYPE_BASE_DIR="$ProgramW6432/GnuWin32" 58208 58209 windows_path="$FREETYPE_BASE_DIR" 58210 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58211 unix_path=`$CYGPATH -u "$windows_path"` 58212 FREETYPE_BASE_DIR="$unix_path" 58213 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58214 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58215 FREETYPE_BASE_DIR="$unix_path" 58216 fi 58217 58218 58219 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 58220 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 58221 METHOD="well-known location" 58222 58223 # Let's start with an optimistic view of the world :-) 58224 FOUND_FREETYPE=yes 58225 58226 # First look for the canonical freetype main include file ft2build.h. 58227 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 58228 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 58229 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 58230 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 58231 # Fail. 58232 FOUND_FREETYPE=no 58233 fi 58234 fi 58235 58236 if test "x$FOUND_FREETYPE" = xyes; then 58237 # Include file found, let's continue the sanity check. 58238 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 58239 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 58240 58241 # Reset to default value 58242 FREETYPE_BASE_NAME=freetype 58243 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 58244 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 58245 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 58246 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 58247 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 58248 # for the .6 version explicitly. 58249 FREETYPE_BASE_NAME=freetype.6 58250 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 58251 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 58252 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 58253 else 58254 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 58255 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 58256 FOUND_FREETYPE=no 58257 fi 58258 else 58259 if test "x$OPENJDK_TARGET_OS" = xwindows; then 58260 # On Windows, we will need both .lib and .dll file. 58261 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 58262 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 58263 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 58264 FOUND_FREETYPE=no 58265 fi 58266 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 58267 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 58268 # Found lib in isa dir, use that instead. 58269 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 58270 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 58271 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 58272 fi 58273 fi 58274 fi 58275 58276 if test "x$FOUND_FREETYPE" = xyes; then 58277 58278 # Only process if variable expands to non-empty 58279 58280 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 58281 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58282 58283 # Input might be given as Windows format, start by converting to 58284 # unix format. 58285 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58286 new_path=`$CYGPATH -u "$path"` 58287 58288 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 58289 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 58290 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 58291 # "foo.exe" is OK but "foo" is an error. 58292 # 58293 # This test is therefore slightly more accurate than "test -f" to check for file precense. 58294 # It is also a way to make sure we got the proper file name for the real test later on. 58295 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 58296 if test "x$test_shortpath" = x; then 58297 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 58298 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 58299 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 58300 fi 58301 58302 # Call helper function which possibly converts this using DOS-style short mode. 58303 # If so, the updated path is stored in $new_path. 58304 58305 input_path="$new_path" 58306 # Check if we need to convert this using DOS-style short mode. If the path 58307 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58308 # take no chances and rewrite it. 58309 # Note: m4 eats our [], so we need to use [ and ] instead. 58310 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 58311 if test "x$has_forbidden_chars" != x; then 58312 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58313 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 58314 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 58315 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 58316 # Going to short mode and back again did indeed matter. Since short mode is 58317 # case insensitive, let's make it lowercase to improve readability. 58318 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58319 # Now convert it back to Unix-style (cygpath) 58320 input_path=`$CYGPATH -u "$shortmode_path"` 58321 new_path="$input_path" 58322 fi 58323 fi 58324 58325 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 58326 if test "x$test_cygdrive_prefix" = x; then 58327 # As a simple fix, exclude /usr/bin since it's not a real path. 58328 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 58329 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 58330 # a path prefixed by /cygdrive for fixpath to work. 58331 new_path="$CYGWIN_ROOT_PATH$input_path" 58332 fi 58333 fi 58334 58335 58336 if test "x$path" != "x$new_path"; then 58337 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 58338 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 58339 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 58340 fi 58341 58342 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58343 58344 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58345 has_colon=`$ECHO $path | $GREP ^.:` 58346 new_path="$path" 58347 if test "x$has_colon" = x; then 58348 # Not in mixed or Windows style, start by that. 58349 new_path=`cmd //c echo $path` 58350 fi 58351 58352 58353 input_path="$new_path" 58354 # Check if we need to convert this using DOS-style short mode. If the path 58355 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58356 # take no chances and rewrite it. 58357 # Note: m4 eats our [], so we need to use [ and ] instead. 58358 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 58359 if test "x$has_forbidden_chars" != x; then 58360 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58361 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58362 fi 58363 58364 58365 windows_path="$new_path" 58366 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58367 unix_path=`$CYGPATH -u "$windows_path"` 58368 new_path="$unix_path" 58369 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58370 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58371 new_path="$unix_path" 58372 fi 58373 58374 if test "x$path" != "x$new_path"; then 58375 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 58376 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 58377 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 58378 fi 58379 58380 # Save the first 10 bytes of this path to the storage, so fixpath can work. 58381 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 58382 58383 else 58384 # We're on a unix platform. Hooray! :) 58385 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58386 has_space=`$ECHO "$path" | $GREP " "` 58387 if test "x$has_space" != x; then 58388 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 58389 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 58390 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 58391 fi 58392 58393 # Use eval to expand a potential ~ 58394 eval path="$path" 58395 if test ! -f "$path" && test ! -d "$path"; then 58396 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 58397 fi 58398 58399 if test -d "$path"; then 58400 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 58401 else 58402 dir="`$DIRNAME "$path"`" 58403 base="`$BASENAME "$path"`" 58404 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 58405 fi 58406 fi 58407 fi 58408 58409 58410 # Only process if variable expands to non-empty 58411 58412 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 58413 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58414 58415 # Input might be given as Windows format, start by converting to 58416 # unix format. 58417 path="$POTENTIAL_FREETYPE_LIB_PATH" 58418 new_path=`$CYGPATH -u "$path"` 58419 58420 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 58421 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 58422 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 58423 # "foo.exe" is OK but "foo" is an error. 58424 # 58425 # This test is therefore slightly more accurate than "test -f" to check for file precense. 58426 # It is also a way to make sure we got the proper file name for the real test later on. 58427 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 58428 if test "x$test_shortpath" = x; then 58429 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 58430 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 58431 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 58432 fi 58433 58434 # Call helper function which possibly converts this using DOS-style short mode. 58435 # If so, the updated path is stored in $new_path. 58436 58437 input_path="$new_path" 58438 # Check if we need to convert this using DOS-style short mode. If the path 58439 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58440 # take no chances and rewrite it. 58441 # Note: m4 eats our [], so we need to use [ and ] instead. 58442 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 58443 if test "x$has_forbidden_chars" != x; then 58444 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58445 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 58446 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 58447 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 58448 # Going to short mode and back again did indeed matter. Since short mode is 58449 # case insensitive, let's make it lowercase to improve readability. 58450 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58451 # Now convert it back to Unix-style (cygpath) 58452 input_path=`$CYGPATH -u "$shortmode_path"` 58453 new_path="$input_path" 58454 fi 58455 fi 58456 58457 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 58458 if test "x$test_cygdrive_prefix" = x; then 58459 # As a simple fix, exclude /usr/bin since it's not a real path. 58460 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 58461 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 58462 # a path prefixed by /cygdrive for fixpath to work. 58463 new_path="$CYGWIN_ROOT_PATH$input_path" 58464 fi 58465 fi 58466 58467 58468 if test "x$path" != "x$new_path"; then 58469 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 58470 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 58471 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 58472 fi 58473 58474 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58475 58476 path="$POTENTIAL_FREETYPE_LIB_PATH" 58477 has_colon=`$ECHO $path | $GREP ^.:` 58478 new_path="$path" 58479 if test "x$has_colon" = x; then 58480 # Not in mixed or Windows style, start by that. 58481 new_path=`cmd //c echo $path` 58482 fi 58483 58484 58485 input_path="$new_path" 58486 # Check if we need to convert this using DOS-style short mode. If the path 58487 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58488 # take no chances and rewrite it. 58489 # Note: m4 eats our [], so we need to use [ and ] instead. 58490 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 58491 if test "x$has_forbidden_chars" != x; then 58492 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58493 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58494 fi 58495 58496 58497 windows_path="$new_path" 58498 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58499 unix_path=`$CYGPATH -u "$windows_path"` 58500 new_path="$unix_path" 58501 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58502 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58503 new_path="$unix_path" 58504 fi 58505 58506 if test "x$path" != "x$new_path"; then 58507 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 58508 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 58509 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 58510 fi 58511 58512 # Save the first 10 bytes of this path to the storage, so fixpath can work. 58513 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 58514 58515 else 58516 # We're on a unix platform. Hooray! :) 58517 path="$POTENTIAL_FREETYPE_LIB_PATH" 58518 has_space=`$ECHO "$path" | $GREP " "` 58519 if test "x$has_space" != x; then 58520 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 58521 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 58522 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 58523 fi 58524 58525 # Use eval to expand a potential ~ 58526 eval path="$path" 58527 if test ! -f "$path" && test ! -d "$path"; then 58528 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 58529 fi 58530 58531 if test -d "$path"; then 58532 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 58533 else 58534 dir="`$DIRNAME "$path"`" 58535 base="`$BASENAME "$path"`" 58536 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 58537 fi 58538 fi 58539 fi 58540 58541 58542 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58543 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 58544 $as_echo_n "checking for freetype includes... " >&6; } 58545 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 58546 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 58547 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 58548 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 58549 $as_echo_n "checking for freetype libraries... " >&6; } 58550 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 58551 $as_echo "$FREETYPE_LIB_PATH" >&6; } 58552 fi 58553 58554 fi 58555 if test "x$FOUND_FREETYPE" != xyes; then 58556 FREETYPE_BASE_DIR="$HOME/freetype" 58557 58558 windows_path="$FREETYPE_BASE_DIR" 58559 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58560 unix_path=`$CYGPATH -u "$windows_path"` 58561 FREETYPE_BASE_DIR="$unix_path" 58562 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58563 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58564 FREETYPE_BASE_DIR="$unix_path" 58565 fi 58566 58567 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 58568 58569 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 58570 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib64" 58571 METHOD="well-known location" 58572 58573 # Let's start with an optimistic view of the world :-) 58574 FOUND_FREETYPE=yes 58575 58576 # First look for the canonical freetype main include file ft2build.h. 58577 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 58578 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 58579 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 58580 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 58581 # Fail. 58582 FOUND_FREETYPE=no 58583 fi 58584 fi 58585 58586 if test "x$FOUND_FREETYPE" = xyes; then 58587 # Include file found, let's continue the sanity check. 58588 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 58589 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 58590 58591 # Reset to default value 58592 FREETYPE_BASE_NAME=freetype 58593 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 58594 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 58595 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 58596 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 58597 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 58598 # for the .6 version explicitly. 58599 FREETYPE_BASE_NAME=freetype.6 58600 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 58601 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 58602 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 58603 else 58604 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 58605 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 58606 FOUND_FREETYPE=no 58607 fi 58608 else 58609 if test "x$OPENJDK_TARGET_OS" = xwindows; then 58610 # On Windows, we will need both .lib and .dll file. 58611 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 58612 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 58613 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 58614 FOUND_FREETYPE=no 58615 fi 58616 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 58617 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 58618 # Found lib in isa dir, use that instead. 58619 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 58620 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 58621 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 58622 fi 58623 fi 58624 fi 58625 58626 if test "x$FOUND_FREETYPE" = xyes; then 58627 58628 # Only process if variable expands to non-empty 58629 58630 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 58631 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58632 58633 # Input might be given as Windows format, start by converting to 58634 # unix format. 58635 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58636 new_path=`$CYGPATH -u "$path"` 58637 58638 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 58639 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 58640 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 58641 # "foo.exe" is OK but "foo" is an error. 58642 # 58643 # This test is therefore slightly more accurate than "test -f" to check for file precense. 58644 # It is also a way to make sure we got the proper file name for the real test later on. 58645 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 58646 if test "x$test_shortpath" = x; then 58647 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 58648 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 58649 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 58650 fi 58651 58652 # Call helper function which possibly converts this using DOS-style short mode. 58653 # If so, the updated path is stored in $new_path. 58654 58655 input_path="$new_path" 58656 # Check if we need to convert this using DOS-style short mode. If the path 58657 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58658 # take no chances and rewrite it. 58659 # Note: m4 eats our [], so we need to use [ and ] instead. 58660 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 58661 if test "x$has_forbidden_chars" != x; then 58662 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58663 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 58664 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 58665 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 58666 # Going to short mode and back again did indeed matter. Since short mode is 58667 # case insensitive, let's make it lowercase to improve readability. 58668 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58669 # Now convert it back to Unix-style (cygpath) 58670 input_path=`$CYGPATH -u "$shortmode_path"` 58671 new_path="$input_path" 58672 fi 58673 fi 58674 58675 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 58676 if test "x$test_cygdrive_prefix" = x; then 58677 # As a simple fix, exclude /usr/bin since it's not a real path. 58678 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 58679 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 58680 # a path prefixed by /cygdrive for fixpath to work. 58681 new_path="$CYGWIN_ROOT_PATH$input_path" 58682 fi 58683 fi 58684 58685 58686 if test "x$path" != "x$new_path"; then 58687 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 58688 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 58689 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 58690 fi 58691 58692 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58693 58694 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58695 has_colon=`$ECHO $path | $GREP ^.:` 58696 new_path="$path" 58697 if test "x$has_colon" = x; then 58698 # Not in mixed or Windows style, start by that. 58699 new_path=`cmd //c echo $path` 58700 fi 58701 58702 58703 input_path="$new_path" 58704 # Check if we need to convert this using DOS-style short mode. If the path 58705 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58706 # take no chances and rewrite it. 58707 # Note: m4 eats our [], so we need to use [ and ] instead. 58708 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 58709 if test "x$has_forbidden_chars" != x; then 58710 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58711 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58712 fi 58713 58714 58715 windows_path="$new_path" 58716 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58717 unix_path=`$CYGPATH -u "$windows_path"` 58718 new_path="$unix_path" 58719 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58720 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58721 new_path="$unix_path" 58722 fi 58723 58724 if test "x$path" != "x$new_path"; then 58725 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 58726 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 58727 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 58728 fi 58729 58730 # Save the first 10 bytes of this path to the storage, so fixpath can work. 58731 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 58732 58733 else 58734 # We're on a unix platform. Hooray! :) 58735 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58736 has_space=`$ECHO "$path" | $GREP " "` 58737 if test "x$has_space" != x; then 58738 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 58739 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 58740 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 58741 fi 58742 58743 # Use eval to expand a potential ~ 58744 eval path="$path" 58745 if test ! -f "$path" && test ! -d "$path"; then 58746 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 58747 fi 58748 58749 if test -d "$path"; then 58750 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 58751 else 58752 dir="`$DIRNAME "$path"`" 58753 base="`$BASENAME "$path"`" 58754 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 58755 fi 58756 fi 58757 fi 58758 58759 58760 # Only process if variable expands to non-empty 58761 58762 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 58763 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58764 58765 # Input might be given as Windows format, start by converting to 58766 # unix format. 58767 path="$POTENTIAL_FREETYPE_LIB_PATH" 58768 new_path=`$CYGPATH -u "$path"` 58769 58770 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 58771 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 58772 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 58773 # "foo.exe" is OK but "foo" is an error. 58774 # 58775 # This test is therefore slightly more accurate than "test -f" to check for file precense. 58776 # It is also a way to make sure we got the proper file name for the real test later on. 58777 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 58778 if test "x$test_shortpath" = x; then 58779 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 58780 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 58781 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 58782 fi 58783 58784 # Call helper function which possibly converts this using DOS-style short mode. 58785 # If so, the updated path is stored in $new_path. 58786 58787 input_path="$new_path" 58788 # Check if we need to convert this using DOS-style short mode. If the path 58789 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58790 # take no chances and rewrite it. 58791 # Note: m4 eats our [], so we need to use [ and ] instead. 58792 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 58793 if test "x$has_forbidden_chars" != x; then 58794 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58795 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 58796 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 58797 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 58798 # Going to short mode and back again did indeed matter. Since short mode is 58799 # case insensitive, let's make it lowercase to improve readability. 58800 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58801 # Now convert it back to Unix-style (cygpath) 58802 input_path=`$CYGPATH -u "$shortmode_path"` 58803 new_path="$input_path" 58804 fi 58805 fi 58806 58807 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 58808 if test "x$test_cygdrive_prefix" = x; then 58809 # As a simple fix, exclude /usr/bin since it's not a real path. 58810 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 58811 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 58812 # a path prefixed by /cygdrive for fixpath to work. 58813 new_path="$CYGWIN_ROOT_PATH$input_path" 58814 fi 58815 fi 58816 58817 58818 if test "x$path" != "x$new_path"; then 58819 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 58820 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 58821 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 58822 fi 58823 58824 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58825 58826 path="$POTENTIAL_FREETYPE_LIB_PATH" 58827 has_colon=`$ECHO $path | $GREP ^.:` 58828 new_path="$path" 58829 if test "x$has_colon" = x; then 58830 # Not in mixed or Windows style, start by that. 58831 new_path=`cmd //c echo $path` 58832 fi 58833 58834 58835 input_path="$new_path" 58836 # Check if we need to convert this using DOS-style short mode. If the path 58837 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58838 # take no chances and rewrite it. 58839 # Note: m4 eats our [], so we need to use [ and ] instead. 58840 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 58841 if test "x$has_forbidden_chars" != x; then 58842 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 58843 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 58844 fi 58845 58846 58847 windows_path="$new_path" 58848 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58849 unix_path=`$CYGPATH -u "$windows_path"` 58850 new_path="$unix_path" 58851 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 58852 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 58853 new_path="$unix_path" 58854 fi 58855 58856 if test "x$path" != "x$new_path"; then 58857 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 58858 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 58859 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 58860 fi 58861 58862 # Save the first 10 bytes of this path to the storage, so fixpath can work. 58863 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 58864 58865 else 58866 # We're on a unix platform. Hooray! :) 58867 path="$POTENTIAL_FREETYPE_LIB_PATH" 58868 has_space=`$ECHO "$path" | $GREP " "` 58869 if test "x$has_space" != x; then 58870 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 58871 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 58872 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 58873 fi 58874 58875 # Use eval to expand a potential ~ 58876 eval path="$path" 58877 if test ! -f "$path" && test ! -d "$path"; then 58878 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 58879 fi 58880 58881 if test -d "$path"; then 58882 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 58883 else 58884 dir="`$DIRNAME "$path"`" 58885 base="`$BASENAME "$path"`" 58886 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 58887 fi 58888 fi 58889 fi 58890 58891 58892 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58893 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 58894 $as_echo_n "checking for freetype includes... " >&6; } 58895 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 58896 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 58897 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 58898 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 58899 $as_echo_n "checking for freetype libraries... " >&6; } 58900 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 58901 $as_echo "$FREETYPE_LIB_PATH" >&6; } 58902 fi 58903 58904 else 58905 58906 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 58907 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib32" 58908 METHOD="well-known location" 58909 58910 # Let's start with an optimistic view of the world :-) 58911 FOUND_FREETYPE=yes 58912 58913 # First look for the canonical freetype main include file ft2build.h. 58914 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 58915 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 58916 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 58917 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 58918 # Fail. 58919 FOUND_FREETYPE=no 58920 fi 58921 fi 58922 58923 if test "x$FOUND_FREETYPE" = xyes; then 58924 # Include file found, let's continue the sanity check. 58925 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 58926 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 58927 58928 # Reset to default value 58929 FREETYPE_BASE_NAME=freetype 58930 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 58931 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 58932 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 58933 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 58934 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 58935 # for the .6 version explicitly. 58936 FREETYPE_BASE_NAME=freetype.6 58937 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 58938 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 58939 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 58940 else 58941 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 58942 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 58943 FOUND_FREETYPE=no 58944 fi 58945 else 58946 if test "x$OPENJDK_TARGET_OS" = xwindows; then 58947 # On Windows, we will need both .lib and .dll file. 58948 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 58949 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 58950 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 58951 FOUND_FREETYPE=no 58952 fi 58953 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 58954 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 58955 # Found lib in isa dir, use that instead. 58956 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 58957 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 58958 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 58959 fi 58960 fi 58961 fi 58962 58963 if test "x$FOUND_FREETYPE" = xyes; then 58964 58965 # Only process if variable expands to non-empty 58966 58967 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 58968 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 58969 58970 # Input might be given as Windows format, start by converting to 58971 # unix format. 58972 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 58973 new_path=`$CYGPATH -u "$path"` 58974 58975 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 58976 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 58977 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 58978 # "foo.exe" is OK but "foo" is an error. 58979 # 58980 # This test is therefore slightly more accurate than "test -f" to check for file precense. 58981 # It is also a way to make sure we got the proper file name for the real test later on. 58982 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 58983 if test "x$test_shortpath" = x; then 58984 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 58985 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 58986 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 58987 fi 58988 58989 # Call helper function which possibly converts this using DOS-style short mode. 58990 # If so, the updated path is stored in $new_path. 58991 58992 input_path="$new_path" 58993 # Check if we need to convert this using DOS-style short mode. If the path 58994 # contains just simple characters, use it. Otherwise (spaces, weird characters), 58995 # take no chances and rewrite it. 58996 # Note: m4 eats our [], so we need to use [ and ] instead. 58997 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 58998 if test "x$has_forbidden_chars" != x; then 58999 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59000 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 59001 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 59002 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 59003 # Going to short mode and back again did indeed matter. Since short mode is 59004 # case insensitive, let's make it lowercase to improve readability. 59005 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59006 # Now convert it back to Unix-style (cygpath) 59007 input_path=`$CYGPATH -u "$shortmode_path"` 59008 new_path="$input_path" 59009 fi 59010 fi 59011 59012 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 59013 if test "x$test_cygdrive_prefix" = x; then 59014 # As a simple fix, exclude /usr/bin since it's not a real path. 59015 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 59016 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 59017 # a path prefixed by /cygdrive for fixpath to work. 59018 new_path="$CYGWIN_ROOT_PATH$input_path" 59019 fi 59020 fi 59021 59022 59023 if test "x$path" != "x$new_path"; then 59024 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 59025 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 59026 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 59027 fi 59028 59029 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59030 59031 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59032 has_colon=`$ECHO $path | $GREP ^.:` 59033 new_path="$path" 59034 if test "x$has_colon" = x; then 59035 # Not in mixed or Windows style, start by that. 59036 new_path=`cmd //c echo $path` 59037 fi 59038 59039 59040 input_path="$new_path" 59041 # Check if we need to convert this using DOS-style short mode. If the path 59042 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59043 # take no chances and rewrite it. 59044 # Note: m4 eats our [], so we need to use [ and ] instead. 59045 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 59046 if test "x$has_forbidden_chars" != x; then 59047 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59048 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59049 fi 59050 59051 59052 windows_path="$new_path" 59053 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59054 unix_path=`$CYGPATH -u "$windows_path"` 59055 new_path="$unix_path" 59056 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59057 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59058 new_path="$unix_path" 59059 fi 59060 59061 if test "x$path" != "x$new_path"; then 59062 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 59063 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 59064 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 59065 fi 59066 59067 # Save the first 10 bytes of this path to the storage, so fixpath can work. 59068 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 59069 59070 else 59071 # We're on a unix platform. Hooray! :) 59072 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59073 has_space=`$ECHO "$path" | $GREP " "` 59074 if test "x$has_space" != x; then 59075 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 59076 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 59077 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 59078 fi 59079 59080 # Use eval to expand a potential ~ 59081 eval path="$path" 59082 if test ! -f "$path" && test ! -d "$path"; then 59083 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 59084 fi 59085 59086 if test -d "$path"; then 59087 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 59088 else 59089 dir="`$DIRNAME "$path"`" 59090 base="`$BASENAME "$path"`" 59091 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 59092 fi 59093 fi 59094 fi 59095 59096 59097 # Only process if variable expands to non-empty 59098 59099 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 59100 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59101 59102 # Input might be given as Windows format, start by converting to 59103 # unix format. 59104 path="$POTENTIAL_FREETYPE_LIB_PATH" 59105 new_path=`$CYGPATH -u "$path"` 59106 59107 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 59108 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 59109 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 59110 # "foo.exe" is OK but "foo" is an error. 59111 # 59112 # This test is therefore slightly more accurate than "test -f" to check for file precense. 59113 # It is also a way to make sure we got the proper file name for the real test later on. 59114 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 59115 if test "x$test_shortpath" = x; then 59116 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 59117 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 59118 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 59119 fi 59120 59121 # Call helper function which possibly converts this using DOS-style short mode. 59122 # If so, the updated path is stored in $new_path. 59123 59124 input_path="$new_path" 59125 # Check if we need to convert this using DOS-style short mode. If the path 59126 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59127 # take no chances and rewrite it. 59128 # Note: m4 eats our [], so we need to use [ and ] instead. 59129 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 59130 if test "x$has_forbidden_chars" != x; then 59131 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59132 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 59133 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 59134 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 59135 # Going to short mode and back again did indeed matter. Since short mode is 59136 # case insensitive, let's make it lowercase to improve readability. 59137 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59138 # Now convert it back to Unix-style (cygpath) 59139 input_path=`$CYGPATH -u "$shortmode_path"` 59140 new_path="$input_path" 59141 fi 59142 fi 59143 59144 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 59145 if test "x$test_cygdrive_prefix" = x; then 59146 # As a simple fix, exclude /usr/bin since it's not a real path. 59147 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 59148 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 59149 # a path prefixed by /cygdrive for fixpath to work. 59150 new_path="$CYGWIN_ROOT_PATH$input_path" 59151 fi 59152 fi 59153 59154 59155 if test "x$path" != "x$new_path"; then 59156 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 59157 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 59158 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 59159 fi 59160 59161 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59162 59163 path="$POTENTIAL_FREETYPE_LIB_PATH" 59164 has_colon=`$ECHO $path | $GREP ^.:` 59165 new_path="$path" 59166 if test "x$has_colon" = x; then 59167 # Not in mixed or Windows style, start by that. 59168 new_path=`cmd //c echo $path` 59169 fi 59170 59171 59172 input_path="$new_path" 59173 # Check if we need to convert this using DOS-style short mode. If the path 59174 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59175 # take no chances and rewrite it. 59176 # Note: m4 eats our [], so we need to use [ and ] instead. 59177 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 59178 if test "x$has_forbidden_chars" != x; then 59179 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59180 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59181 fi 59182 59183 59184 windows_path="$new_path" 59185 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59186 unix_path=`$CYGPATH -u "$windows_path"` 59187 new_path="$unix_path" 59188 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59189 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59190 new_path="$unix_path" 59191 fi 59192 59193 if test "x$path" != "x$new_path"; then 59194 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 59195 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 59196 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 59197 fi 59198 59199 # Save the first 10 bytes of this path to the storage, so fixpath can work. 59200 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 59201 59202 else 59203 # We're on a unix platform. Hooray! :) 59204 path="$POTENTIAL_FREETYPE_LIB_PATH" 59205 has_space=`$ECHO "$path" | $GREP " "` 59206 if test "x$has_space" != x; then 59207 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 59208 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 59209 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 59210 fi 59211 59212 # Use eval to expand a potential ~ 59213 eval path="$path" 59214 if test ! -f "$path" && test ! -d "$path"; then 59215 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 59216 fi 59217 59218 if test -d "$path"; then 59219 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 59220 else 59221 dir="`$DIRNAME "$path"`" 59222 base="`$BASENAME "$path"`" 59223 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 59224 fi 59225 fi 59226 fi 59227 59228 59229 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59230 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 59231 $as_echo_n "checking for freetype includes... " >&6; } 59232 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 59233 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 59234 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 59235 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 59236 $as_echo_n "checking for freetype libraries... " >&6; } 59237 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 59238 $as_echo "$FREETYPE_LIB_PATH" >&6; } 59239 fi 59240 59241 fi 59242 if test "x$FOUND_FREETYPE" != xyes && test -d $FREETYPE_BASE_DIR \ 59243 && test -s "$FREETYPE_BASE_DIR/builds/windows/vc2010/freetype.vcxproj" && test "x$MSBUILD" != x; then 59244 # Source is available, as a last resort try to build freetype in default location 59245 59246 FREETYPE_SRC_PATH="$FREETYPE_BASE_DIR" 59247 BUILD_FREETYPE=yes 59248 59249 # Check if the freetype sources are acessible.. 59250 if ! test -d $FREETYPE_SRC_PATH; then 59251 { $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 59252 $as_echo "$as_me: WARNING: --with-freetype-src specified, but can not find path \"$FREETYPE_SRC_PATH\" - ignoring --with-freetype-src" >&2;} 59253 BUILD_FREETYPE=no 59254 fi 59255 # ..and contain a vc2010 project file 59256 vcxproj_path="$FREETYPE_SRC_PATH/builds/windows/vc2010/freetype.vcxproj" 59257 if test "x$BUILD_FREETYPE" = xyes && ! test -s $vcxproj_path; then 59258 { $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 59259 $as_echo "$as_me: WARNING: Can not find project file $vcxproj_path (you may try a newer freetype version) - ignoring --with-freetype-src" >&2;} 59260 BUILD_FREETYPE=no 59261 fi 59262 # Now check if configure found a version of 'msbuild.exe' 59263 if test "x$BUILD_FREETYPE" = xyes && test "x$MSBUILD" == x ; then 59264 { $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 59265 $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;} 59266 BUILD_FREETYPE=no 59267 fi 59268 59269 # Ready to go.. 59270 if test "x$BUILD_FREETYPE" = xyes; then 59271 # msbuild requires trailing slashes for output directories 59272 freetype_lib_path="$FREETYPE_SRC_PATH/lib$OPENJDK_TARGET_CPU_BITS/" 59273 freetype_lib_path_unix="$freetype_lib_path" 59274 freetype_obj_path="$FREETYPE_SRC_PATH/obj$OPENJDK_TARGET_CPU_BITS/" 59275 59276 unix_path="$vcxproj_path" 59277 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59278 windows_path=`$CYGPATH -m "$unix_path"` 59279 vcxproj_path="$windows_path" 59280 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59281 windows_path=`cmd //c echo $unix_path` 59282 vcxproj_path="$windows_path" 59283 fi 59284 59285 59286 unix_path="$freetype_lib_path" 59287 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59288 windows_path=`$CYGPATH -m "$unix_path"` 59289 freetype_lib_path="$windows_path" 59290 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59291 windows_path=`cmd //c echo $unix_path` 59292 freetype_lib_path="$windows_path" 59293 fi 59294 59295 59296 unix_path="$freetype_obj_path" 59297 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59298 windows_path=`$CYGPATH -m "$unix_path"` 59299 freetype_obj_path="$windows_path" 59300 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59301 windows_path=`cmd //c echo $unix_path` 59302 freetype_obj_path="$windows_path" 59303 fi 59304 59305 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 59306 freetype_platform=x64 59307 else 59308 freetype_platform=win32 59309 fi 59310 59311 # The original freetype project file is for VS 2010 (i.e. 'v100'), 59312 # so we have to adapt the toolset if building with any other toolsed (i.e. SDK). 59313 # Currently 'PLATFORM_TOOLSET' is set in 'TOOLCHAIN_CHECK_POSSIBLE_VISUAL_STUDIO_ROOT'/ 59314 # 'TOOLCHAIN_CHECK_POSSIBLE_WIN_SDK_ROOT' in toolchain_windows.m4 59315 { $as_echo "$as_me:${as_lineno-$LINENO}: Trying to compile freetype sources with PlatformToolset=$PLATFORM_TOOLSET to $freetype_lib_path_unix ..." >&5 59316 $as_echo "$as_me: Trying to compile freetype sources with PlatformToolset=$PLATFORM_TOOLSET to $freetype_lib_path_unix ..." >&6;} 59317 59318 # First we try to build the freetype.dll 59319 $ECHO -e "@echo off\n"\ 59320 "$MSBUILD $vcxproj_path "\ 59321 "/p:PlatformToolset=$PLATFORM_TOOLSET "\ 59322 "/p:Configuration=\"Release Multithreaded\" "\ 59323 "/p:Platform=$freetype_platform "\ 59324 "/p:ConfigurationType=DynamicLibrary "\ 59325 "/p:TargetName=freetype "\ 59326 "/p:OutDir=\"$freetype_lib_path\" "\ 59327 "/p:IntDir=\"$freetype_obj_path\" > freetype.log" > freetype.bat 59328 cmd /c freetype.bat 59329 59330 if test -s "$freetype_lib_path_unix/freetype.dll"; then 59331 # If that succeeds we also build freetype.lib 59332 $ECHO -e "@echo off\n"\ 59333 "$MSBUILD $vcxproj_path "\ 59334 "/p:PlatformToolset=$PLATFORM_TOOLSET "\ 59335 "/p:Configuration=\"Release Multithreaded\" "\ 59336 "/p:Platform=$freetype_platform "\ 59337 "/p:ConfigurationType=StaticLibrary "\ 59338 "/p:TargetName=freetype "\ 59339 "/p:OutDir=\"$freetype_lib_path\" "\ 59340 "/p:IntDir=\"$freetype_obj_path\" >> freetype.log" > freetype.bat 59341 cmd /c freetype.bat 59342 59343 if test -s "$freetype_lib_path_unix/freetype.lib"; then 59344 # Once we build both, lib and dll, set freetype lib and include path appropriately 59345 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_SRC_PATH/include" 59346 POTENTIAL_FREETYPE_LIB_PATH="$freetype_lib_path_unix" 59347 { $as_echo "$as_me:${as_lineno-$LINENO}: Compiling freetype sources succeeded! (see freetype.log for build results)" >&5 59348 $as_echo "$as_me: Compiling freetype sources succeeded! (see freetype.log for build results)" >&6;} 59349 else 59350 BUILD_FREETYPE=no 59351 fi 59352 else 59353 BUILD_FREETYPE=no 59354 fi 59355 fi 59356 59357 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 59358 59359 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 59360 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib64" 59361 METHOD="well-known location" 59362 59363 # Let's start with an optimistic view of the world :-) 59364 FOUND_FREETYPE=yes 59365 59366 # First look for the canonical freetype main include file ft2build.h. 59367 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59368 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 59369 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 59370 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59371 # Fail. 59372 FOUND_FREETYPE=no 59373 fi 59374 fi 59375 59376 if test "x$FOUND_FREETYPE" = xyes; then 59377 # Include file found, let's continue the sanity check. 59378 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 59379 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 59380 59381 # Reset to default value 59382 FREETYPE_BASE_NAME=freetype 59383 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59384 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 59385 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 59386 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 59387 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 59388 # for the .6 version explicitly. 59389 FREETYPE_BASE_NAME=freetype.6 59390 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59391 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 59392 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 59393 else 59394 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 59395 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 59396 FOUND_FREETYPE=no 59397 fi 59398 else 59399 if test "x$OPENJDK_TARGET_OS" = xwindows; then 59400 # On Windows, we will need both .lib and .dll file. 59401 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 59402 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 59403 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 59404 FOUND_FREETYPE=no 59405 fi 59406 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 59407 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 59408 # Found lib in isa dir, use that instead. 59409 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 59410 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 59411 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 59412 fi 59413 fi 59414 fi 59415 59416 if test "x$FOUND_FREETYPE" = xyes; then 59417 59418 # Only process if variable expands to non-empty 59419 59420 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 59421 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59422 59423 # Input might be given as Windows format, start by converting to 59424 # unix format. 59425 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59426 new_path=`$CYGPATH -u "$path"` 59427 59428 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 59429 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 59430 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 59431 # "foo.exe" is OK but "foo" is an error. 59432 # 59433 # This test is therefore slightly more accurate than "test -f" to check for file precense. 59434 # It is also a way to make sure we got the proper file name for the real test later on. 59435 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 59436 if test "x$test_shortpath" = x; then 59437 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 59438 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 59439 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 59440 fi 59441 59442 # Call helper function which possibly converts this using DOS-style short mode. 59443 # If so, the updated path is stored in $new_path. 59444 59445 input_path="$new_path" 59446 # Check if we need to convert this using DOS-style short mode. If the path 59447 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59448 # take no chances and rewrite it. 59449 # Note: m4 eats our [], so we need to use [ and ] instead. 59450 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 59451 if test "x$has_forbidden_chars" != x; then 59452 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59453 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 59454 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 59455 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 59456 # Going to short mode and back again did indeed matter. Since short mode is 59457 # case insensitive, let's make it lowercase to improve readability. 59458 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59459 # Now convert it back to Unix-style (cygpath) 59460 input_path=`$CYGPATH -u "$shortmode_path"` 59461 new_path="$input_path" 59462 fi 59463 fi 59464 59465 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 59466 if test "x$test_cygdrive_prefix" = x; then 59467 # As a simple fix, exclude /usr/bin since it's not a real path. 59468 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 59469 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 59470 # a path prefixed by /cygdrive for fixpath to work. 59471 new_path="$CYGWIN_ROOT_PATH$input_path" 59472 fi 59473 fi 59474 59475 59476 if test "x$path" != "x$new_path"; then 59477 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 59478 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 59479 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 59480 fi 59481 59482 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59483 59484 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59485 has_colon=`$ECHO $path | $GREP ^.:` 59486 new_path="$path" 59487 if test "x$has_colon" = x; then 59488 # Not in mixed or Windows style, start by that. 59489 new_path=`cmd //c echo $path` 59490 fi 59491 59492 59493 input_path="$new_path" 59494 # Check if we need to convert this using DOS-style short mode. If the path 59495 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59496 # take no chances and rewrite it. 59497 # Note: m4 eats our [], so we need to use [ and ] instead. 59498 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 59499 if test "x$has_forbidden_chars" != x; then 59500 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59501 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59502 fi 59503 59504 59505 windows_path="$new_path" 59506 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59507 unix_path=`$CYGPATH -u "$windows_path"` 59508 new_path="$unix_path" 59509 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59510 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59511 new_path="$unix_path" 59512 fi 59513 59514 if test "x$path" != "x$new_path"; then 59515 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 59516 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 59517 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 59518 fi 59519 59520 # Save the first 10 bytes of this path to the storage, so fixpath can work. 59521 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 59522 59523 else 59524 # We're on a unix platform. Hooray! :) 59525 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59526 has_space=`$ECHO "$path" | $GREP " "` 59527 if test "x$has_space" != x; then 59528 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 59529 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 59530 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 59531 fi 59532 59533 # Use eval to expand a potential ~ 59534 eval path="$path" 59535 if test ! -f "$path" && test ! -d "$path"; then 59536 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 59537 fi 59538 59539 if test -d "$path"; then 59540 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 59541 else 59542 dir="`$DIRNAME "$path"`" 59543 base="`$BASENAME "$path"`" 59544 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 59545 fi 59546 fi 59547 fi 59548 59549 59550 # Only process if variable expands to non-empty 59551 59552 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 59553 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59554 59555 # Input might be given as Windows format, start by converting to 59556 # unix format. 59557 path="$POTENTIAL_FREETYPE_LIB_PATH" 59558 new_path=`$CYGPATH -u "$path"` 59559 59560 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 59561 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 59562 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 59563 # "foo.exe" is OK but "foo" is an error. 59564 # 59565 # This test is therefore slightly more accurate than "test -f" to check for file precense. 59566 # It is also a way to make sure we got the proper file name for the real test later on. 59567 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 59568 if test "x$test_shortpath" = x; then 59569 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 59570 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 59571 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 59572 fi 59573 59574 # Call helper function which possibly converts this using DOS-style short mode. 59575 # If so, the updated path is stored in $new_path. 59576 59577 input_path="$new_path" 59578 # Check if we need to convert this using DOS-style short mode. If the path 59579 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59580 # take no chances and rewrite it. 59581 # Note: m4 eats our [], so we need to use [ and ] instead. 59582 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 59583 if test "x$has_forbidden_chars" != x; then 59584 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59585 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 59586 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 59587 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 59588 # Going to short mode and back again did indeed matter. Since short mode is 59589 # case insensitive, let's make it lowercase to improve readability. 59590 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59591 # Now convert it back to Unix-style (cygpath) 59592 input_path=`$CYGPATH -u "$shortmode_path"` 59593 new_path="$input_path" 59594 fi 59595 fi 59596 59597 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 59598 if test "x$test_cygdrive_prefix" = x; then 59599 # As a simple fix, exclude /usr/bin since it's not a real path. 59600 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 59601 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 59602 # a path prefixed by /cygdrive for fixpath to work. 59603 new_path="$CYGWIN_ROOT_PATH$input_path" 59604 fi 59605 fi 59606 59607 59608 if test "x$path" != "x$new_path"; then 59609 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 59610 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 59611 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 59612 fi 59613 59614 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59615 59616 path="$POTENTIAL_FREETYPE_LIB_PATH" 59617 has_colon=`$ECHO $path | $GREP ^.:` 59618 new_path="$path" 59619 if test "x$has_colon" = x; then 59620 # Not in mixed or Windows style, start by that. 59621 new_path=`cmd //c echo $path` 59622 fi 59623 59624 59625 input_path="$new_path" 59626 # Check if we need to convert this using DOS-style short mode. If the path 59627 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59628 # take no chances and rewrite it. 59629 # Note: m4 eats our [], so we need to use [ and ] instead. 59630 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 59631 if test "x$has_forbidden_chars" != x; then 59632 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59633 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59634 fi 59635 59636 59637 windows_path="$new_path" 59638 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59639 unix_path=`$CYGPATH -u "$windows_path"` 59640 new_path="$unix_path" 59641 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59642 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59643 new_path="$unix_path" 59644 fi 59645 59646 if test "x$path" != "x$new_path"; then 59647 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 59648 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 59649 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 59650 fi 59651 59652 # Save the first 10 bytes of this path to the storage, so fixpath can work. 59653 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 59654 59655 else 59656 # We're on a unix platform. Hooray! :) 59657 path="$POTENTIAL_FREETYPE_LIB_PATH" 59658 has_space=`$ECHO "$path" | $GREP " "` 59659 if test "x$has_space" != x; then 59660 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 59661 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 59662 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 59663 fi 59664 59665 # Use eval to expand a potential ~ 59666 eval path="$path" 59667 if test ! -f "$path" && test ! -d "$path"; then 59668 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 59669 fi 59670 59671 if test -d "$path"; then 59672 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 59673 else 59674 dir="`$DIRNAME "$path"`" 59675 base="`$BASENAME "$path"`" 59676 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 59677 fi 59678 fi 59679 fi 59680 59681 59682 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59683 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 59684 $as_echo_n "checking for freetype includes... " >&6; } 59685 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 59686 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 59687 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 59688 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 59689 $as_echo_n "checking for freetype libraries... " >&6; } 59690 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 59691 $as_echo "$FREETYPE_LIB_PATH" >&6; } 59692 fi 59693 59694 else 59695 59696 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 59697 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib32" 59698 METHOD="well-known location" 59699 59700 # Let's start with an optimistic view of the world :-) 59701 FOUND_FREETYPE=yes 59702 59703 # First look for the canonical freetype main include file ft2build.h. 59704 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59705 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 59706 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 59707 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 59708 # Fail. 59709 FOUND_FREETYPE=no 59710 fi 59711 fi 59712 59713 if test "x$FOUND_FREETYPE" = xyes; then 59714 # Include file found, let's continue the sanity check. 59715 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 59716 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 59717 59718 # Reset to default value 59719 FREETYPE_BASE_NAME=freetype 59720 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59721 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 59722 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 59723 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 59724 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 59725 # for the .6 version explicitly. 59726 FREETYPE_BASE_NAME=freetype.6 59727 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 59728 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 59729 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 59730 else 59731 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 59732 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 59733 FOUND_FREETYPE=no 59734 fi 59735 else 59736 if test "x$OPENJDK_TARGET_OS" = xwindows; then 59737 # On Windows, we will need both .lib and .dll file. 59738 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 59739 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 59740 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 59741 FOUND_FREETYPE=no 59742 fi 59743 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 59744 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 59745 # Found lib in isa dir, use that instead. 59746 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 59747 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 59748 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 59749 fi 59750 fi 59751 fi 59752 59753 if test "x$FOUND_FREETYPE" = xyes; then 59754 59755 # Only process if variable expands to non-empty 59756 59757 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 59758 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59759 59760 # Input might be given as Windows format, start by converting to 59761 # unix format. 59762 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59763 new_path=`$CYGPATH -u "$path"` 59764 59765 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 59766 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 59767 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 59768 # "foo.exe" is OK but "foo" is an error. 59769 # 59770 # This test is therefore slightly more accurate than "test -f" to check for file precense. 59771 # It is also a way to make sure we got the proper file name for the real test later on. 59772 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 59773 if test "x$test_shortpath" = x; then 59774 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 59775 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 59776 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 59777 fi 59778 59779 # Call helper function which possibly converts this using DOS-style short mode. 59780 # If so, the updated path is stored in $new_path. 59781 59782 input_path="$new_path" 59783 # Check if we need to convert this using DOS-style short mode. If the path 59784 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59785 # take no chances and rewrite it. 59786 # Note: m4 eats our [], so we need to use [ and ] instead. 59787 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 59788 if test "x$has_forbidden_chars" != x; then 59789 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59790 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 59791 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 59792 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 59793 # Going to short mode and back again did indeed matter. Since short mode is 59794 # case insensitive, let's make it lowercase to improve readability. 59795 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59796 # Now convert it back to Unix-style (cygpath) 59797 input_path=`$CYGPATH -u "$shortmode_path"` 59798 new_path="$input_path" 59799 fi 59800 fi 59801 59802 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 59803 if test "x$test_cygdrive_prefix" = x; then 59804 # As a simple fix, exclude /usr/bin since it's not a real path. 59805 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 59806 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 59807 # a path prefixed by /cygdrive for fixpath to work. 59808 new_path="$CYGWIN_ROOT_PATH$input_path" 59809 fi 59810 fi 59811 59812 59813 if test "x$path" != "x$new_path"; then 59814 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 59815 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 59816 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 59817 fi 59818 59819 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59820 59821 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59822 has_colon=`$ECHO $path | $GREP ^.:` 59823 new_path="$path" 59824 if test "x$has_colon" = x; then 59825 # Not in mixed or Windows style, start by that. 59826 new_path=`cmd //c echo $path` 59827 fi 59828 59829 59830 input_path="$new_path" 59831 # Check if we need to convert this using DOS-style short mode. If the path 59832 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59833 # take no chances and rewrite it. 59834 # Note: m4 eats our [], so we need to use [ and ] instead. 59835 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 59836 if test "x$has_forbidden_chars" != x; then 59837 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59838 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59839 fi 59840 59841 59842 windows_path="$new_path" 59843 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59844 unix_path=`$CYGPATH -u "$windows_path"` 59845 new_path="$unix_path" 59846 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59847 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59848 new_path="$unix_path" 59849 fi 59850 59851 if test "x$path" != "x$new_path"; then 59852 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 59853 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 59854 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 59855 fi 59856 59857 # Save the first 10 bytes of this path to the storage, so fixpath can work. 59858 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 59859 59860 else 59861 # We're on a unix platform. Hooray! :) 59862 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 59863 has_space=`$ECHO "$path" | $GREP " "` 59864 if test "x$has_space" != x; then 59865 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 59866 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 59867 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 59868 fi 59869 59870 # Use eval to expand a potential ~ 59871 eval path="$path" 59872 if test ! -f "$path" && test ! -d "$path"; then 59873 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 59874 fi 59875 59876 if test -d "$path"; then 59877 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 59878 else 59879 dir="`$DIRNAME "$path"`" 59880 base="`$BASENAME "$path"`" 59881 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 59882 fi 59883 fi 59884 fi 59885 59886 59887 # Only process if variable expands to non-empty 59888 59889 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 59890 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59891 59892 # Input might be given as Windows format, start by converting to 59893 # unix format. 59894 path="$POTENTIAL_FREETYPE_LIB_PATH" 59895 new_path=`$CYGPATH -u "$path"` 59896 59897 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 59898 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 59899 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 59900 # "foo.exe" is OK but "foo" is an error. 59901 # 59902 # This test is therefore slightly more accurate than "test -f" to check for file precense. 59903 # It is also a way to make sure we got the proper file name for the real test later on. 59904 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 59905 if test "x$test_shortpath" = x; then 59906 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 59907 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 59908 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 59909 fi 59910 59911 # Call helper function which possibly converts this using DOS-style short mode. 59912 # If so, the updated path is stored in $new_path. 59913 59914 input_path="$new_path" 59915 # Check if we need to convert this using DOS-style short mode. If the path 59916 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59917 # take no chances and rewrite it. 59918 # Note: m4 eats our [], so we need to use [ and ] instead. 59919 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 59920 if test "x$has_forbidden_chars" != x; then 59921 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59922 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 59923 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 59924 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 59925 # Going to short mode and back again did indeed matter. Since short mode is 59926 # case insensitive, let's make it lowercase to improve readability. 59927 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59928 # Now convert it back to Unix-style (cygpath) 59929 input_path=`$CYGPATH -u "$shortmode_path"` 59930 new_path="$input_path" 59931 fi 59932 fi 59933 59934 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 59935 if test "x$test_cygdrive_prefix" = x; then 59936 # As a simple fix, exclude /usr/bin since it's not a real path. 59937 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 59938 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 59939 # a path prefixed by /cygdrive for fixpath to work. 59940 new_path="$CYGWIN_ROOT_PATH$input_path" 59941 fi 59942 fi 59943 59944 59945 if test "x$path" != "x$new_path"; then 59946 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 59947 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 59948 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 59949 fi 59950 59951 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59952 59953 path="$POTENTIAL_FREETYPE_LIB_PATH" 59954 has_colon=`$ECHO $path | $GREP ^.:` 59955 new_path="$path" 59956 if test "x$has_colon" = x; then 59957 # Not in mixed or Windows style, start by that. 59958 new_path=`cmd //c echo $path` 59959 fi 59960 59961 59962 input_path="$new_path" 59963 # Check if we need to convert this using DOS-style short mode. If the path 59964 # contains just simple characters, use it. Otherwise (spaces, weird characters), 59965 # take no chances and rewrite it. 59966 # Note: m4 eats our [], so we need to use [ and ] instead. 59967 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 59968 if test "x$has_forbidden_chars" != x; then 59969 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 59970 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 59971 fi 59972 59973 59974 windows_path="$new_path" 59975 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 59976 unix_path=`$CYGPATH -u "$windows_path"` 59977 new_path="$unix_path" 59978 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 59979 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 59980 new_path="$unix_path" 59981 fi 59982 59983 if test "x$path" != "x$new_path"; then 59984 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 59985 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 59986 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 59987 fi 59988 59989 # Save the first 10 bytes of this path to the storage, so fixpath can work. 59990 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 59991 59992 else 59993 # We're on a unix platform. Hooray! :) 59994 path="$POTENTIAL_FREETYPE_LIB_PATH" 59995 has_space=`$ECHO "$path" | $GREP " "` 59996 if test "x$has_space" != x; then 59997 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 59998 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 59999 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60000 fi 60001 60002 # Use eval to expand a potential ~ 60003 eval path="$path" 60004 if test ! -f "$path" && test ! -d "$path"; then 60005 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60006 fi 60007 60008 if test -d "$path"; then 60009 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 60010 else 60011 dir="`$DIRNAME "$path"`" 60012 base="`$BASENAME "$path"`" 60013 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60014 fi 60015 fi 60016 fi 60017 60018 60019 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60020 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 60021 $as_echo_n "checking for freetype includes... " >&6; } 60022 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 60023 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 60024 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 60025 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 60026 $as_echo_n "checking for freetype libraries... " >&6; } 60027 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 60028 $as_echo "$FREETYPE_LIB_PATH" >&6; } 60029 fi 60030 60031 fi 60032 fi 60033 fi 60034 else 60035 FREETYPE_BASE_DIR="$SYSROOT/usr" 60036 60037 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 60038 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 60039 METHOD="well-known location" 60040 60041 # Let's start with an optimistic view of the world :-) 60042 FOUND_FREETYPE=yes 60043 60044 # First look for the canonical freetype main include file ft2build.h. 60045 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60046 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 60047 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 60048 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60049 # Fail. 60050 FOUND_FREETYPE=no 60051 fi 60052 fi 60053 60054 if test "x$FOUND_FREETYPE" = xyes; then 60055 # Include file found, let's continue the sanity check. 60056 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 60057 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 60058 60059 # Reset to default value 60060 FREETYPE_BASE_NAME=freetype 60061 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60062 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 60063 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 60064 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 60065 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 60066 # for the .6 version explicitly. 60067 FREETYPE_BASE_NAME=freetype.6 60068 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60069 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 60070 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 60071 else 60072 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 60073 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 60074 FOUND_FREETYPE=no 60075 fi 60076 else 60077 if test "x$OPENJDK_TARGET_OS" = xwindows; then 60078 # On Windows, we will need both .lib and .dll file. 60079 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 60080 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 60081 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 60082 FOUND_FREETYPE=no 60083 fi 60084 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 60085 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 60086 # Found lib in isa dir, use that instead. 60087 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 60088 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 60089 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 60090 fi 60091 fi 60092 fi 60093 60094 if test "x$FOUND_FREETYPE" = xyes; then 60095 60096 # Only process if variable expands to non-empty 60097 60098 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 60099 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60100 60101 # Input might be given as Windows format, start by converting to 60102 # unix format. 60103 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60104 new_path=`$CYGPATH -u "$path"` 60105 60106 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60107 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60108 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60109 # "foo.exe" is OK but "foo" is an error. 60110 # 60111 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60112 # It is also a way to make sure we got the proper file name for the real test later on. 60113 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60114 if test "x$test_shortpath" = x; then 60115 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60116 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60117 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 60118 fi 60119 60120 # Call helper function which possibly converts this using DOS-style short mode. 60121 # If so, the updated path is stored in $new_path. 60122 60123 input_path="$new_path" 60124 # Check if we need to convert this using DOS-style short mode. If the path 60125 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60126 # take no chances and rewrite it. 60127 # Note: m4 eats our [], so we need to use [ and ] instead. 60128 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60129 if test "x$has_forbidden_chars" != x; then 60130 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60131 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60132 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60133 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60134 # Going to short mode and back again did indeed matter. Since short mode is 60135 # case insensitive, let's make it lowercase to improve readability. 60136 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60137 # Now convert it back to Unix-style (cygpath) 60138 input_path=`$CYGPATH -u "$shortmode_path"` 60139 new_path="$input_path" 60140 fi 60141 fi 60142 60143 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60144 if test "x$test_cygdrive_prefix" = x; then 60145 # As a simple fix, exclude /usr/bin since it's not a real path. 60146 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60147 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60148 # a path prefixed by /cygdrive for fixpath to work. 60149 new_path="$CYGWIN_ROOT_PATH$input_path" 60150 fi 60151 fi 60152 60153 60154 if test "x$path" != "x$new_path"; then 60155 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60156 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60157 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60158 fi 60159 60160 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60161 60162 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60163 has_colon=`$ECHO $path | $GREP ^.:` 60164 new_path="$path" 60165 if test "x$has_colon" = x; then 60166 # Not in mixed or Windows style, start by that. 60167 new_path=`cmd //c echo $path` 60168 fi 60169 60170 60171 input_path="$new_path" 60172 # Check if we need to convert this using DOS-style short mode. If the path 60173 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60174 # take no chances and rewrite it. 60175 # Note: m4 eats our [], so we need to use [ and ] instead. 60176 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60177 if test "x$has_forbidden_chars" != x; then 60178 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60179 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60180 fi 60181 60182 60183 windows_path="$new_path" 60184 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60185 unix_path=`$CYGPATH -u "$windows_path"` 60186 new_path="$unix_path" 60187 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60188 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60189 new_path="$unix_path" 60190 fi 60191 60192 if test "x$path" != "x$new_path"; then 60193 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60194 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60195 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60196 fi 60197 60198 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60199 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60200 60201 else 60202 # We're on a unix platform. Hooray! :) 60203 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60204 has_space=`$ECHO "$path" | $GREP " "` 60205 if test "x$has_space" != x; then 60206 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60207 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60208 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60209 fi 60210 60211 # Use eval to expand a potential ~ 60212 eval path="$path" 60213 if test ! -f "$path" && test ! -d "$path"; then 60214 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60215 fi 60216 60217 if test -d "$path"; then 60218 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 60219 else 60220 dir="`$DIRNAME "$path"`" 60221 base="`$BASENAME "$path"`" 60222 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60223 fi 60224 fi 60225 fi 60226 60227 60228 # Only process if variable expands to non-empty 60229 60230 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 60231 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60232 60233 # Input might be given as Windows format, start by converting to 60234 # unix format. 60235 path="$POTENTIAL_FREETYPE_LIB_PATH" 60236 new_path=`$CYGPATH -u "$path"` 60237 60238 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60239 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60240 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60241 # "foo.exe" is OK but "foo" is an error. 60242 # 60243 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60244 # It is also a way to make sure we got the proper file name for the real test later on. 60245 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60246 if test "x$test_shortpath" = x; then 60247 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60248 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60249 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 60250 fi 60251 60252 # Call helper function which possibly converts this using DOS-style short mode. 60253 # If so, the updated path is stored in $new_path. 60254 60255 input_path="$new_path" 60256 # Check if we need to convert this using DOS-style short mode. If the path 60257 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60258 # take no chances and rewrite it. 60259 # Note: m4 eats our [], so we need to use [ and ] instead. 60260 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60261 if test "x$has_forbidden_chars" != x; then 60262 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60263 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60264 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60265 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60266 # Going to short mode and back again did indeed matter. Since short mode is 60267 # case insensitive, let's make it lowercase to improve readability. 60268 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60269 # Now convert it back to Unix-style (cygpath) 60270 input_path=`$CYGPATH -u "$shortmode_path"` 60271 new_path="$input_path" 60272 fi 60273 fi 60274 60275 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60276 if test "x$test_cygdrive_prefix" = x; then 60277 # As a simple fix, exclude /usr/bin since it's not a real path. 60278 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60279 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60280 # a path prefixed by /cygdrive for fixpath to work. 60281 new_path="$CYGWIN_ROOT_PATH$input_path" 60282 fi 60283 fi 60284 60285 60286 if test "x$path" != "x$new_path"; then 60287 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60288 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60289 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60290 fi 60291 60292 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60293 60294 path="$POTENTIAL_FREETYPE_LIB_PATH" 60295 has_colon=`$ECHO $path | $GREP ^.:` 60296 new_path="$path" 60297 if test "x$has_colon" = x; then 60298 # Not in mixed or Windows style, start by that. 60299 new_path=`cmd //c echo $path` 60300 fi 60301 60302 60303 input_path="$new_path" 60304 # Check if we need to convert this using DOS-style short mode. If the path 60305 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60306 # take no chances and rewrite it. 60307 # Note: m4 eats our [], so we need to use [ and ] instead. 60308 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60309 if test "x$has_forbidden_chars" != x; then 60310 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60311 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60312 fi 60313 60314 60315 windows_path="$new_path" 60316 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60317 unix_path=`$CYGPATH -u "$windows_path"` 60318 new_path="$unix_path" 60319 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60320 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60321 new_path="$unix_path" 60322 fi 60323 60324 if test "x$path" != "x$new_path"; then 60325 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60326 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60327 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60328 fi 60329 60330 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60331 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60332 60333 else 60334 # We're on a unix platform. Hooray! :) 60335 path="$POTENTIAL_FREETYPE_LIB_PATH" 60336 has_space=`$ECHO "$path" | $GREP " "` 60337 if test "x$has_space" != x; then 60338 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60339 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60340 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60341 fi 60342 60343 # Use eval to expand a potential ~ 60344 eval path="$path" 60345 if test ! -f "$path" && test ! -d "$path"; then 60346 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60347 fi 60348 60349 if test -d "$path"; then 60350 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 60351 else 60352 dir="`$DIRNAME "$path"`" 60353 base="`$BASENAME "$path"`" 60354 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60355 fi 60356 fi 60357 fi 60358 60359 60360 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60361 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 60362 $as_echo_n "checking for freetype includes... " >&6; } 60363 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 60364 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 60365 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 60366 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 60367 $as_echo_n "checking for freetype libraries... " >&6; } 60368 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 60369 $as_echo "$FREETYPE_LIB_PATH" >&6; } 60370 fi 60371 60372 60373 if test "x$FOUND_FREETYPE" != xyes; then 60374 FREETYPE_BASE_DIR="$SYSROOT/usr/X11" 60375 60376 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 60377 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 60378 METHOD="well-known location" 60379 60380 # Let's start with an optimistic view of the world :-) 60381 FOUND_FREETYPE=yes 60382 60383 # First look for the canonical freetype main include file ft2build.h. 60384 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60385 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 60386 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 60387 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60388 # Fail. 60389 FOUND_FREETYPE=no 60390 fi 60391 fi 60392 60393 if test "x$FOUND_FREETYPE" = xyes; then 60394 # Include file found, let's continue the sanity check. 60395 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 60396 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 60397 60398 # Reset to default value 60399 FREETYPE_BASE_NAME=freetype 60400 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60401 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 60402 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 60403 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 60404 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 60405 # for the .6 version explicitly. 60406 FREETYPE_BASE_NAME=freetype.6 60407 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60408 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 60409 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 60410 else 60411 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 60412 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 60413 FOUND_FREETYPE=no 60414 fi 60415 else 60416 if test "x$OPENJDK_TARGET_OS" = xwindows; then 60417 # On Windows, we will need both .lib and .dll file. 60418 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 60419 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 60420 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 60421 FOUND_FREETYPE=no 60422 fi 60423 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 60424 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 60425 # Found lib in isa dir, use that instead. 60426 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 60427 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 60428 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 60429 fi 60430 fi 60431 fi 60432 60433 if test "x$FOUND_FREETYPE" = xyes; then 60434 60435 # Only process if variable expands to non-empty 60436 60437 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 60438 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60439 60440 # Input might be given as Windows format, start by converting to 60441 # unix format. 60442 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60443 new_path=`$CYGPATH -u "$path"` 60444 60445 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60446 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60447 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60448 # "foo.exe" is OK but "foo" is an error. 60449 # 60450 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60451 # It is also a way to make sure we got the proper file name for the real test later on. 60452 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60453 if test "x$test_shortpath" = x; then 60454 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60455 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60456 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 60457 fi 60458 60459 # Call helper function which possibly converts this using DOS-style short mode. 60460 # If so, the updated path is stored in $new_path. 60461 60462 input_path="$new_path" 60463 # Check if we need to convert this using DOS-style short mode. If the path 60464 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60465 # take no chances and rewrite it. 60466 # Note: m4 eats our [], so we need to use [ and ] instead. 60467 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60468 if test "x$has_forbidden_chars" != x; then 60469 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60470 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60471 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60472 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60473 # Going to short mode and back again did indeed matter. Since short mode is 60474 # case insensitive, let's make it lowercase to improve readability. 60475 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60476 # Now convert it back to Unix-style (cygpath) 60477 input_path=`$CYGPATH -u "$shortmode_path"` 60478 new_path="$input_path" 60479 fi 60480 fi 60481 60482 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60483 if test "x$test_cygdrive_prefix" = x; then 60484 # As a simple fix, exclude /usr/bin since it's not a real path. 60485 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60486 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60487 # a path prefixed by /cygdrive for fixpath to work. 60488 new_path="$CYGWIN_ROOT_PATH$input_path" 60489 fi 60490 fi 60491 60492 60493 if test "x$path" != "x$new_path"; then 60494 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60495 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60496 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60497 fi 60498 60499 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60500 60501 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60502 has_colon=`$ECHO $path | $GREP ^.:` 60503 new_path="$path" 60504 if test "x$has_colon" = x; then 60505 # Not in mixed or Windows style, start by that. 60506 new_path=`cmd //c echo $path` 60507 fi 60508 60509 60510 input_path="$new_path" 60511 # Check if we need to convert this using DOS-style short mode. If the path 60512 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60513 # take no chances and rewrite it. 60514 # Note: m4 eats our [], so we need to use [ and ] instead. 60515 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60516 if test "x$has_forbidden_chars" != x; then 60517 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60518 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60519 fi 60520 60521 60522 windows_path="$new_path" 60523 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60524 unix_path=`$CYGPATH -u "$windows_path"` 60525 new_path="$unix_path" 60526 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60527 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60528 new_path="$unix_path" 60529 fi 60530 60531 if test "x$path" != "x$new_path"; then 60532 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60533 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60534 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60535 fi 60536 60537 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60538 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60539 60540 else 60541 # We're on a unix platform. Hooray! :) 60542 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60543 has_space=`$ECHO "$path" | $GREP " "` 60544 if test "x$has_space" != x; then 60545 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60546 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60547 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60548 fi 60549 60550 # Use eval to expand a potential ~ 60551 eval path="$path" 60552 if test ! -f "$path" && test ! -d "$path"; then 60553 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60554 fi 60555 60556 if test -d "$path"; then 60557 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 60558 else 60559 dir="`$DIRNAME "$path"`" 60560 base="`$BASENAME "$path"`" 60561 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60562 fi 60563 fi 60564 fi 60565 60566 60567 # Only process if variable expands to non-empty 60568 60569 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 60570 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60571 60572 # Input might be given as Windows format, start by converting to 60573 # unix format. 60574 path="$POTENTIAL_FREETYPE_LIB_PATH" 60575 new_path=`$CYGPATH -u "$path"` 60576 60577 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60578 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60579 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60580 # "foo.exe" is OK but "foo" is an error. 60581 # 60582 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60583 # It is also a way to make sure we got the proper file name for the real test later on. 60584 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60585 if test "x$test_shortpath" = x; then 60586 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60587 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60588 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 60589 fi 60590 60591 # Call helper function which possibly converts this using DOS-style short mode. 60592 # If so, the updated path is stored in $new_path. 60593 60594 input_path="$new_path" 60595 # Check if we need to convert this using DOS-style short mode. If the path 60596 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60597 # take no chances and rewrite it. 60598 # Note: m4 eats our [], so we need to use [ and ] instead. 60599 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60600 if test "x$has_forbidden_chars" != x; then 60601 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60602 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60603 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60604 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60605 # Going to short mode and back again did indeed matter. Since short mode is 60606 # case insensitive, let's make it lowercase to improve readability. 60607 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60608 # Now convert it back to Unix-style (cygpath) 60609 input_path=`$CYGPATH -u "$shortmode_path"` 60610 new_path="$input_path" 60611 fi 60612 fi 60613 60614 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60615 if test "x$test_cygdrive_prefix" = x; then 60616 # As a simple fix, exclude /usr/bin since it's not a real path. 60617 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60618 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60619 # a path prefixed by /cygdrive for fixpath to work. 60620 new_path="$CYGWIN_ROOT_PATH$input_path" 60621 fi 60622 fi 60623 60624 60625 if test "x$path" != "x$new_path"; then 60626 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60627 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60628 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60629 fi 60630 60631 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60632 60633 path="$POTENTIAL_FREETYPE_LIB_PATH" 60634 has_colon=`$ECHO $path | $GREP ^.:` 60635 new_path="$path" 60636 if test "x$has_colon" = x; then 60637 # Not in mixed or Windows style, start by that. 60638 new_path=`cmd //c echo $path` 60639 fi 60640 60641 60642 input_path="$new_path" 60643 # Check if we need to convert this using DOS-style short mode. If the path 60644 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60645 # take no chances and rewrite it. 60646 # Note: m4 eats our [], so we need to use [ and ] instead. 60647 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60648 if test "x$has_forbidden_chars" != x; then 60649 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60650 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60651 fi 60652 60653 60654 windows_path="$new_path" 60655 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60656 unix_path=`$CYGPATH -u "$windows_path"` 60657 new_path="$unix_path" 60658 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60659 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60660 new_path="$unix_path" 60661 fi 60662 60663 if test "x$path" != "x$new_path"; then 60664 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60665 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60666 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60667 fi 60668 60669 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60670 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60671 60672 else 60673 # We're on a unix platform. Hooray! :) 60674 path="$POTENTIAL_FREETYPE_LIB_PATH" 60675 has_space=`$ECHO "$path" | $GREP " "` 60676 if test "x$has_space" != x; then 60677 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60678 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60679 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60680 fi 60681 60682 # Use eval to expand a potential ~ 60683 eval path="$path" 60684 if test ! -f "$path" && test ! -d "$path"; then 60685 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60686 fi 60687 60688 if test -d "$path"; then 60689 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 60690 else 60691 dir="`$DIRNAME "$path"`" 60692 base="`$BASENAME "$path"`" 60693 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60694 fi 60695 fi 60696 fi 60697 60698 60699 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60700 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 60701 $as_echo_n "checking for freetype includes... " >&6; } 60702 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 60703 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 60704 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 60705 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 60706 $as_echo_n "checking for freetype libraries... " >&6; } 60707 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 60708 $as_echo "$FREETYPE_LIB_PATH" >&6; } 60709 fi 60710 60711 fi 60712 60713 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 60714 if test "x$FOUND_FREETYPE" != xyes; then 60715 # Due to changes in OSX 10.11 XQuartz now installs to /opt/X11 60716 FREETYPE_BASE_DIR="$SYSROOT/opt/X11" 60717 60718 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 60719 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 60720 METHOD="well-known location" 60721 60722 # Let's start with an optimistic view of the world :-) 60723 FOUND_FREETYPE=yes 60724 60725 # First look for the canonical freetype main include file ft2build.h. 60726 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60727 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 60728 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 60729 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 60730 # Fail. 60731 FOUND_FREETYPE=no 60732 fi 60733 fi 60734 60735 if test "x$FOUND_FREETYPE" = xyes; then 60736 # Include file found, let's continue the sanity check. 60737 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 60738 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 60739 60740 # Reset to default value 60741 FREETYPE_BASE_NAME=freetype 60742 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60743 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 60744 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 60745 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 60746 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 60747 # for the .6 version explicitly. 60748 FREETYPE_BASE_NAME=freetype.6 60749 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 60750 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 60751 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 60752 else 60753 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 60754 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 60755 FOUND_FREETYPE=no 60756 fi 60757 else 60758 if test "x$OPENJDK_TARGET_OS" = xwindows; then 60759 # On Windows, we will need both .lib and .dll file. 60760 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 60761 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 60762 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 60763 FOUND_FREETYPE=no 60764 fi 60765 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 60766 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 60767 # Found lib in isa dir, use that instead. 60768 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 60769 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 60770 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 60771 fi 60772 fi 60773 fi 60774 60775 if test "x$FOUND_FREETYPE" = xyes; then 60776 60777 # Only process if variable expands to non-empty 60778 60779 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 60780 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60781 60782 # Input might be given as Windows format, start by converting to 60783 # unix format. 60784 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60785 new_path=`$CYGPATH -u "$path"` 60786 60787 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60788 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60789 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60790 # "foo.exe" is OK but "foo" is an error. 60791 # 60792 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60793 # It is also a way to make sure we got the proper file name for the real test later on. 60794 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60795 if test "x$test_shortpath" = x; then 60796 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60797 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60798 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 60799 fi 60800 60801 # Call helper function which possibly converts this using DOS-style short mode. 60802 # If so, the updated path is stored in $new_path. 60803 60804 input_path="$new_path" 60805 # Check if we need to convert this using DOS-style short mode. If the path 60806 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60807 # take no chances and rewrite it. 60808 # Note: m4 eats our [], so we need to use [ and ] instead. 60809 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60810 if test "x$has_forbidden_chars" != x; then 60811 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60812 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60813 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60814 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60815 # Going to short mode and back again did indeed matter. Since short mode is 60816 # case insensitive, let's make it lowercase to improve readability. 60817 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60818 # Now convert it back to Unix-style (cygpath) 60819 input_path=`$CYGPATH -u "$shortmode_path"` 60820 new_path="$input_path" 60821 fi 60822 fi 60823 60824 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60825 if test "x$test_cygdrive_prefix" = x; then 60826 # As a simple fix, exclude /usr/bin since it's not a real path. 60827 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60828 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60829 # a path prefixed by /cygdrive for fixpath to work. 60830 new_path="$CYGWIN_ROOT_PATH$input_path" 60831 fi 60832 fi 60833 60834 60835 if test "x$path" != "x$new_path"; then 60836 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60837 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60838 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60839 fi 60840 60841 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60842 60843 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60844 has_colon=`$ECHO $path | $GREP ^.:` 60845 new_path="$path" 60846 if test "x$has_colon" = x; then 60847 # Not in mixed or Windows style, start by that. 60848 new_path=`cmd //c echo $path` 60849 fi 60850 60851 60852 input_path="$new_path" 60853 # Check if we need to convert this using DOS-style short mode. If the path 60854 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60855 # take no chances and rewrite it. 60856 # Note: m4 eats our [], so we need to use [ and ] instead. 60857 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60858 if test "x$has_forbidden_chars" != x; then 60859 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60860 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60861 fi 60862 60863 60864 windows_path="$new_path" 60865 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60866 unix_path=`$CYGPATH -u "$windows_path"` 60867 new_path="$unix_path" 60868 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60869 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 60870 new_path="$unix_path" 60871 fi 60872 60873 if test "x$path" != "x$new_path"; then 60874 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 60875 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 60876 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 60877 fi 60878 60879 # Save the first 10 bytes of this path to the storage, so fixpath can work. 60880 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 60881 60882 else 60883 # We're on a unix platform. Hooray! :) 60884 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 60885 has_space=`$ECHO "$path" | $GREP " "` 60886 if test "x$has_space" != x; then 60887 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 60888 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 60889 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 60890 fi 60891 60892 # Use eval to expand a potential ~ 60893 eval path="$path" 60894 if test ! -f "$path" && test ! -d "$path"; then 60895 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 60896 fi 60897 60898 if test -d "$path"; then 60899 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 60900 else 60901 dir="`$DIRNAME "$path"`" 60902 base="`$BASENAME "$path"`" 60903 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 60904 fi 60905 fi 60906 fi 60907 60908 60909 # Only process if variable expands to non-empty 60910 60911 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 60912 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60913 60914 # Input might be given as Windows format, start by converting to 60915 # unix format. 60916 path="$POTENTIAL_FREETYPE_LIB_PATH" 60917 new_path=`$CYGPATH -u "$path"` 60918 60919 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 60920 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 60921 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 60922 # "foo.exe" is OK but "foo" is an error. 60923 # 60924 # This test is therefore slightly more accurate than "test -f" to check for file precense. 60925 # It is also a way to make sure we got the proper file name for the real test later on. 60926 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 60927 if test "x$test_shortpath" = x; then 60928 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 60929 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 60930 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 60931 fi 60932 60933 # Call helper function which possibly converts this using DOS-style short mode. 60934 # If so, the updated path is stored in $new_path. 60935 60936 input_path="$new_path" 60937 # Check if we need to convert this using DOS-style short mode. If the path 60938 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60939 # take no chances and rewrite it. 60940 # Note: m4 eats our [], so we need to use [ and ] instead. 60941 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 60942 if test "x$has_forbidden_chars" != x; then 60943 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60944 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 60945 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 60946 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 60947 # Going to short mode and back again did indeed matter. Since short mode is 60948 # case insensitive, let's make it lowercase to improve readability. 60949 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60950 # Now convert it back to Unix-style (cygpath) 60951 input_path=`$CYGPATH -u "$shortmode_path"` 60952 new_path="$input_path" 60953 fi 60954 fi 60955 60956 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 60957 if test "x$test_cygdrive_prefix" = x; then 60958 # As a simple fix, exclude /usr/bin since it's not a real path. 60959 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 60960 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 60961 # a path prefixed by /cygdrive for fixpath to work. 60962 new_path="$CYGWIN_ROOT_PATH$input_path" 60963 fi 60964 fi 60965 60966 60967 if test "x$path" != "x$new_path"; then 60968 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 60969 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 60970 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 60971 fi 60972 60973 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60974 60975 path="$POTENTIAL_FREETYPE_LIB_PATH" 60976 has_colon=`$ECHO $path | $GREP ^.:` 60977 new_path="$path" 60978 if test "x$has_colon" = x; then 60979 # Not in mixed or Windows style, start by that. 60980 new_path=`cmd //c echo $path` 60981 fi 60982 60983 60984 input_path="$new_path" 60985 # Check if we need to convert this using DOS-style short mode. If the path 60986 # contains just simple characters, use it. Otherwise (spaces, weird characters), 60987 # take no chances and rewrite it. 60988 # Note: m4 eats our [], so we need to use [ and ] instead. 60989 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 60990 if test "x$has_forbidden_chars" != x; then 60991 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 60992 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 60993 fi 60994 60995 60996 windows_path="$new_path" 60997 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60998 unix_path=`$CYGPATH -u "$windows_path"` 60999 new_path="$unix_path" 61000 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61001 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61002 new_path="$unix_path" 61003 fi 61004 61005 if test "x$path" != "x$new_path"; then 61006 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61007 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61008 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61009 fi 61010 61011 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61012 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61013 61014 else 61015 # We're on a unix platform. Hooray! :) 61016 path="$POTENTIAL_FREETYPE_LIB_PATH" 61017 has_space=`$ECHO "$path" | $GREP " "` 61018 if test "x$has_space" != x; then 61019 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61020 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61021 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61022 fi 61023 61024 # Use eval to expand a potential ~ 61025 eval path="$path" 61026 if test ! -f "$path" && test ! -d "$path"; then 61027 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61028 fi 61029 61030 if test -d "$path"; then 61031 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 61032 else 61033 dir="`$DIRNAME "$path"`" 61034 base="`$BASENAME "$path"`" 61035 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61036 fi 61037 fi 61038 fi 61039 61040 61041 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61042 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 61043 $as_echo_n "checking for freetype includes... " >&6; } 61044 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 61045 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 61046 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 61047 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 61048 $as_echo_n "checking for freetype libraries... " >&6; } 61049 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 61050 $as_echo "$FREETYPE_LIB_PATH" >&6; } 61051 fi 61052 61053 fi 61054 fi 61055 61056 if test "x$FOUND_FREETYPE" != xyes; then 61057 FREETYPE_BASE_DIR="$SYSROOT/usr" 61058 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 61059 61060 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 61061 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib/x86_64-linux-gnu" 61062 METHOD="well-known location" 61063 61064 # Let's start with an optimistic view of the world :-) 61065 FOUND_FREETYPE=yes 61066 61067 # First look for the canonical freetype main include file ft2build.h. 61068 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61069 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 61070 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 61071 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61072 # Fail. 61073 FOUND_FREETYPE=no 61074 fi 61075 fi 61076 61077 if test "x$FOUND_FREETYPE" = xyes; then 61078 # Include file found, let's continue the sanity check. 61079 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 61080 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 61081 61082 # Reset to default value 61083 FREETYPE_BASE_NAME=freetype 61084 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61085 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 61086 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 61087 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 61088 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 61089 # for the .6 version explicitly. 61090 FREETYPE_BASE_NAME=freetype.6 61091 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61092 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 61093 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 61094 else 61095 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 61096 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 61097 FOUND_FREETYPE=no 61098 fi 61099 else 61100 if test "x$OPENJDK_TARGET_OS" = xwindows; then 61101 # On Windows, we will need both .lib and .dll file. 61102 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 61103 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 61104 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 61105 FOUND_FREETYPE=no 61106 fi 61107 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 61108 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 61109 # Found lib in isa dir, use that instead. 61110 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 61111 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 61112 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 61113 fi 61114 fi 61115 fi 61116 61117 if test "x$FOUND_FREETYPE" = xyes; then 61118 61119 # Only process if variable expands to non-empty 61120 61121 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 61122 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61123 61124 # Input might be given as Windows format, start by converting to 61125 # unix format. 61126 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61127 new_path=`$CYGPATH -u "$path"` 61128 61129 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61130 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61131 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61132 # "foo.exe" is OK but "foo" is an error. 61133 # 61134 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61135 # It is also a way to make sure we got the proper file name for the real test later on. 61136 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61137 if test "x$test_shortpath" = x; then 61138 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61139 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61140 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 61141 fi 61142 61143 # Call helper function which possibly converts this using DOS-style short mode. 61144 # If so, the updated path is stored in $new_path. 61145 61146 input_path="$new_path" 61147 # Check if we need to convert this using DOS-style short mode. If the path 61148 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61149 # take no chances and rewrite it. 61150 # Note: m4 eats our [], so we need to use [ and ] instead. 61151 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61152 if test "x$has_forbidden_chars" != x; then 61153 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61154 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61155 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61156 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61157 # Going to short mode and back again did indeed matter. Since short mode is 61158 # case insensitive, let's make it lowercase to improve readability. 61159 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61160 # Now convert it back to Unix-style (cygpath) 61161 input_path=`$CYGPATH -u "$shortmode_path"` 61162 new_path="$input_path" 61163 fi 61164 fi 61165 61166 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61167 if test "x$test_cygdrive_prefix" = x; then 61168 # As a simple fix, exclude /usr/bin since it's not a real path. 61169 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61170 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61171 # a path prefixed by /cygdrive for fixpath to work. 61172 new_path="$CYGWIN_ROOT_PATH$input_path" 61173 fi 61174 fi 61175 61176 61177 if test "x$path" != "x$new_path"; then 61178 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61179 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61180 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61181 fi 61182 61183 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61184 61185 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61186 has_colon=`$ECHO $path | $GREP ^.:` 61187 new_path="$path" 61188 if test "x$has_colon" = x; then 61189 # Not in mixed or Windows style, start by that. 61190 new_path=`cmd //c echo $path` 61191 fi 61192 61193 61194 input_path="$new_path" 61195 # Check if we need to convert this using DOS-style short mode. If the path 61196 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61197 # take no chances and rewrite it. 61198 # Note: m4 eats our [], so we need to use [ and ] instead. 61199 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 61200 if test "x$has_forbidden_chars" != x; then 61201 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61202 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61203 fi 61204 61205 61206 windows_path="$new_path" 61207 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61208 unix_path=`$CYGPATH -u "$windows_path"` 61209 new_path="$unix_path" 61210 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61211 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61212 new_path="$unix_path" 61213 fi 61214 61215 if test "x$path" != "x$new_path"; then 61216 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61217 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61218 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61219 fi 61220 61221 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61222 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61223 61224 else 61225 # We're on a unix platform. Hooray! :) 61226 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61227 has_space=`$ECHO "$path" | $GREP " "` 61228 if test "x$has_space" != x; then 61229 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61230 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61231 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61232 fi 61233 61234 # Use eval to expand a potential ~ 61235 eval path="$path" 61236 if test ! -f "$path" && test ! -d "$path"; then 61237 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61238 fi 61239 61240 if test -d "$path"; then 61241 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 61242 else 61243 dir="`$DIRNAME "$path"`" 61244 base="`$BASENAME "$path"`" 61245 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61246 fi 61247 fi 61248 fi 61249 61250 61251 # Only process if variable expands to non-empty 61252 61253 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 61254 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61255 61256 # Input might be given as Windows format, start by converting to 61257 # unix format. 61258 path="$POTENTIAL_FREETYPE_LIB_PATH" 61259 new_path=`$CYGPATH -u "$path"` 61260 61261 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61262 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61263 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61264 # "foo.exe" is OK but "foo" is an error. 61265 # 61266 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61267 # It is also a way to make sure we got the proper file name for the real test later on. 61268 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61269 if test "x$test_shortpath" = x; then 61270 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61271 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61272 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 61273 fi 61274 61275 # Call helper function which possibly converts this using DOS-style short mode. 61276 # If so, the updated path is stored in $new_path. 61277 61278 input_path="$new_path" 61279 # Check if we need to convert this using DOS-style short mode. If the path 61280 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61281 # take no chances and rewrite it. 61282 # Note: m4 eats our [], so we need to use [ and ] instead. 61283 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61284 if test "x$has_forbidden_chars" != x; then 61285 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61286 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61287 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61288 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61289 # Going to short mode and back again did indeed matter. Since short mode is 61290 # case insensitive, let's make it lowercase to improve readability. 61291 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61292 # Now convert it back to Unix-style (cygpath) 61293 input_path=`$CYGPATH -u "$shortmode_path"` 61294 new_path="$input_path" 61295 fi 61296 fi 61297 61298 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61299 if test "x$test_cygdrive_prefix" = x; then 61300 # As a simple fix, exclude /usr/bin since it's not a real path. 61301 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61302 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61303 # a path prefixed by /cygdrive for fixpath to work. 61304 new_path="$CYGWIN_ROOT_PATH$input_path" 61305 fi 61306 fi 61307 61308 61309 if test "x$path" != "x$new_path"; then 61310 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61311 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61312 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61313 fi 61314 61315 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61316 61317 path="$POTENTIAL_FREETYPE_LIB_PATH" 61318 has_colon=`$ECHO $path | $GREP ^.:` 61319 new_path="$path" 61320 if test "x$has_colon" = x; then 61321 # Not in mixed or Windows style, start by that. 61322 new_path=`cmd //c echo $path` 61323 fi 61324 61325 61326 input_path="$new_path" 61327 # Check if we need to convert this using DOS-style short mode. If the path 61328 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61329 # take no chances and rewrite it. 61330 # Note: m4 eats our [], so we need to use [ and ] instead. 61331 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 61332 if test "x$has_forbidden_chars" != x; then 61333 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61334 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61335 fi 61336 61337 61338 windows_path="$new_path" 61339 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61340 unix_path=`$CYGPATH -u "$windows_path"` 61341 new_path="$unix_path" 61342 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61343 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61344 new_path="$unix_path" 61345 fi 61346 61347 if test "x$path" != "x$new_path"; then 61348 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61349 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61350 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61351 fi 61352 61353 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61354 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61355 61356 else 61357 # We're on a unix platform. Hooray! :) 61358 path="$POTENTIAL_FREETYPE_LIB_PATH" 61359 has_space=`$ECHO "$path" | $GREP " "` 61360 if test "x$has_space" != x; then 61361 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61362 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61363 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61364 fi 61365 61366 # Use eval to expand a potential ~ 61367 eval path="$path" 61368 if test ! -f "$path" && test ! -d "$path"; then 61369 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61370 fi 61371 61372 if test -d "$path"; then 61373 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 61374 else 61375 dir="`$DIRNAME "$path"`" 61376 base="`$BASENAME "$path"`" 61377 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61378 fi 61379 fi 61380 fi 61381 61382 61383 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61384 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 61385 $as_echo_n "checking for freetype includes... " >&6; } 61386 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 61387 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 61388 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 61389 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 61390 $as_echo_n "checking for freetype libraries... " >&6; } 61391 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 61392 $as_echo "$FREETYPE_LIB_PATH" >&6; } 61393 fi 61394 61395 else 61396 61397 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 61398 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib/i386-linux-gnu" 61399 METHOD="well-known location" 61400 61401 # Let's start with an optimistic view of the world :-) 61402 FOUND_FREETYPE=yes 61403 61404 # First look for the canonical freetype main include file ft2build.h. 61405 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61406 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 61407 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 61408 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61409 # Fail. 61410 FOUND_FREETYPE=no 61411 fi 61412 fi 61413 61414 if test "x$FOUND_FREETYPE" = xyes; then 61415 # Include file found, let's continue the sanity check. 61416 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 61417 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 61418 61419 # Reset to default value 61420 FREETYPE_BASE_NAME=freetype 61421 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61422 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 61423 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 61424 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 61425 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 61426 # for the .6 version explicitly. 61427 FREETYPE_BASE_NAME=freetype.6 61428 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61429 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 61430 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 61431 else 61432 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 61433 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 61434 FOUND_FREETYPE=no 61435 fi 61436 else 61437 if test "x$OPENJDK_TARGET_OS" = xwindows; then 61438 # On Windows, we will need both .lib and .dll file. 61439 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 61440 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 61441 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 61442 FOUND_FREETYPE=no 61443 fi 61444 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 61445 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 61446 # Found lib in isa dir, use that instead. 61447 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 61448 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 61449 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 61450 fi 61451 fi 61452 fi 61453 61454 if test "x$FOUND_FREETYPE" = xyes; then 61455 61456 # Only process if variable expands to non-empty 61457 61458 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 61459 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61460 61461 # Input might be given as Windows format, start by converting to 61462 # unix format. 61463 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61464 new_path=`$CYGPATH -u "$path"` 61465 61466 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61467 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61468 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61469 # "foo.exe" is OK but "foo" is an error. 61470 # 61471 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61472 # It is also a way to make sure we got the proper file name for the real test later on. 61473 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61474 if test "x$test_shortpath" = x; then 61475 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61476 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61477 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 61478 fi 61479 61480 # Call helper function which possibly converts this using DOS-style short mode. 61481 # If so, the updated path is stored in $new_path. 61482 61483 input_path="$new_path" 61484 # Check if we need to convert this using DOS-style short mode. If the path 61485 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61486 # take no chances and rewrite it. 61487 # Note: m4 eats our [], so we need to use [ and ] instead. 61488 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61489 if test "x$has_forbidden_chars" != x; then 61490 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61491 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61492 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61493 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61494 # Going to short mode and back again did indeed matter. Since short mode is 61495 # case insensitive, let's make it lowercase to improve readability. 61496 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61497 # Now convert it back to Unix-style (cygpath) 61498 input_path=`$CYGPATH -u "$shortmode_path"` 61499 new_path="$input_path" 61500 fi 61501 fi 61502 61503 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61504 if test "x$test_cygdrive_prefix" = x; then 61505 # As a simple fix, exclude /usr/bin since it's not a real path. 61506 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61507 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61508 # a path prefixed by /cygdrive for fixpath to work. 61509 new_path="$CYGWIN_ROOT_PATH$input_path" 61510 fi 61511 fi 61512 61513 61514 if test "x$path" != "x$new_path"; then 61515 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61516 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61517 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61518 fi 61519 61520 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61521 61522 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61523 has_colon=`$ECHO $path | $GREP ^.:` 61524 new_path="$path" 61525 if test "x$has_colon" = x; then 61526 # Not in mixed or Windows style, start by that. 61527 new_path=`cmd //c echo $path` 61528 fi 61529 61530 61531 input_path="$new_path" 61532 # Check if we need to convert this using DOS-style short mode. If the path 61533 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61534 # take no chances and rewrite it. 61535 # Note: m4 eats our [], so we need to use [ and ] instead. 61536 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 61537 if test "x$has_forbidden_chars" != x; then 61538 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61539 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61540 fi 61541 61542 61543 windows_path="$new_path" 61544 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61545 unix_path=`$CYGPATH -u "$windows_path"` 61546 new_path="$unix_path" 61547 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61548 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61549 new_path="$unix_path" 61550 fi 61551 61552 if test "x$path" != "x$new_path"; then 61553 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61554 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61555 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61556 fi 61557 61558 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61559 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61560 61561 else 61562 # We're on a unix platform. Hooray! :) 61563 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61564 has_space=`$ECHO "$path" | $GREP " "` 61565 if test "x$has_space" != x; then 61566 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61567 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61568 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61569 fi 61570 61571 # Use eval to expand a potential ~ 61572 eval path="$path" 61573 if test ! -f "$path" && test ! -d "$path"; then 61574 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61575 fi 61576 61577 if test -d "$path"; then 61578 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 61579 else 61580 dir="`$DIRNAME "$path"`" 61581 base="`$BASENAME "$path"`" 61582 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61583 fi 61584 fi 61585 fi 61586 61587 61588 # Only process if variable expands to non-empty 61589 61590 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 61591 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61592 61593 # Input might be given as Windows format, start by converting to 61594 # unix format. 61595 path="$POTENTIAL_FREETYPE_LIB_PATH" 61596 new_path=`$CYGPATH -u "$path"` 61597 61598 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61599 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61600 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61601 # "foo.exe" is OK but "foo" is an error. 61602 # 61603 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61604 # It is also a way to make sure we got the proper file name for the real test later on. 61605 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61606 if test "x$test_shortpath" = x; then 61607 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61608 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61609 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 61610 fi 61611 61612 # Call helper function which possibly converts this using DOS-style short mode. 61613 # If so, the updated path is stored in $new_path. 61614 61615 input_path="$new_path" 61616 # Check if we need to convert this using DOS-style short mode. If the path 61617 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61618 # take no chances and rewrite it. 61619 # Note: m4 eats our [], so we need to use [ and ] instead. 61620 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61621 if test "x$has_forbidden_chars" != x; then 61622 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61623 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61624 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61625 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61626 # Going to short mode and back again did indeed matter. Since short mode is 61627 # case insensitive, let's make it lowercase to improve readability. 61628 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61629 # Now convert it back to Unix-style (cygpath) 61630 input_path=`$CYGPATH -u "$shortmode_path"` 61631 new_path="$input_path" 61632 fi 61633 fi 61634 61635 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61636 if test "x$test_cygdrive_prefix" = x; then 61637 # As a simple fix, exclude /usr/bin since it's not a real path. 61638 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61639 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61640 # a path prefixed by /cygdrive for fixpath to work. 61641 new_path="$CYGWIN_ROOT_PATH$input_path" 61642 fi 61643 fi 61644 61645 61646 if test "x$path" != "x$new_path"; then 61647 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61648 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61649 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61650 fi 61651 61652 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61653 61654 path="$POTENTIAL_FREETYPE_LIB_PATH" 61655 has_colon=`$ECHO $path | $GREP ^.:` 61656 new_path="$path" 61657 if test "x$has_colon" = x; then 61658 # Not in mixed or Windows style, start by that. 61659 new_path=`cmd //c echo $path` 61660 fi 61661 61662 61663 input_path="$new_path" 61664 # Check if we need to convert this using DOS-style short mode. If the path 61665 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61666 # take no chances and rewrite it. 61667 # Note: m4 eats our [], so we need to use [ and ] instead. 61668 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 61669 if test "x$has_forbidden_chars" != x; then 61670 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61671 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61672 fi 61673 61674 61675 windows_path="$new_path" 61676 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61677 unix_path=`$CYGPATH -u "$windows_path"` 61678 new_path="$unix_path" 61679 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61680 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61681 new_path="$unix_path" 61682 fi 61683 61684 if test "x$path" != "x$new_path"; then 61685 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61686 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61687 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61688 fi 61689 61690 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61691 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61692 61693 else 61694 # We're on a unix platform. Hooray! :) 61695 path="$POTENTIAL_FREETYPE_LIB_PATH" 61696 has_space=`$ECHO "$path" | $GREP " "` 61697 if test "x$has_space" != x; then 61698 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61699 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61700 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61701 fi 61702 61703 # Use eval to expand a potential ~ 61704 eval path="$path" 61705 if test ! -f "$path" && test ! -d "$path"; then 61706 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61707 fi 61708 61709 if test -d "$path"; then 61710 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 61711 else 61712 dir="`$DIRNAME "$path"`" 61713 base="`$BASENAME "$path"`" 61714 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61715 fi 61716 fi 61717 fi 61718 61719 61720 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61721 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 61722 $as_echo_n "checking for freetype includes... " >&6; } 61723 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 61724 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 61725 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 61726 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 61727 $as_echo_n "checking for freetype libraries... " >&6; } 61728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 61729 $as_echo "$FREETYPE_LIB_PATH" >&6; } 61730 fi 61731 61732 if test "x$FOUND_FREETYPE" != xyes; then 61733 61734 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 61735 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib32" 61736 METHOD="well-known location" 61737 61738 # Let's start with an optimistic view of the world :-) 61739 FOUND_FREETYPE=yes 61740 61741 # First look for the canonical freetype main include file ft2build.h. 61742 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61743 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 61744 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 61745 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 61746 # Fail. 61747 FOUND_FREETYPE=no 61748 fi 61749 fi 61750 61751 if test "x$FOUND_FREETYPE" = xyes; then 61752 # Include file found, let's continue the sanity check. 61753 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 61754 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 61755 61756 # Reset to default value 61757 FREETYPE_BASE_NAME=freetype 61758 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61759 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 61760 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 61761 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 61762 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 61763 # for the .6 version explicitly. 61764 FREETYPE_BASE_NAME=freetype.6 61765 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 61766 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 61767 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 61768 else 61769 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 61770 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 61771 FOUND_FREETYPE=no 61772 fi 61773 else 61774 if test "x$OPENJDK_TARGET_OS" = xwindows; then 61775 # On Windows, we will need both .lib and .dll file. 61776 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 61777 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 61778 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 61779 FOUND_FREETYPE=no 61780 fi 61781 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 61782 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 61783 # Found lib in isa dir, use that instead. 61784 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 61785 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 61786 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 61787 fi 61788 fi 61789 fi 61790 61791 if test "x$FOUND_FREETYPE" = xyes; then 61792 61793 # Only process if variable expands to non-empty 61794 61795 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 61796 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61797 61798 # Input might be given as Windows format, start by converting to 61799 # unix format. 61800 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61801 new_path=`$CYGPATH -u "$path"` 61802 61803 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61804 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61805 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61806 # "foo.exe" is OK but "foo" is an error. 61807 # 61808 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61809 # It is also a way to make sure we got the proper file name for the real test later on. 61810 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61811 if test "x$test_shortpath" = x; then 61812 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61813 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61814 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 61815 fi 61816 61817 # Call helper function which possibly converts this using DOS-style short mode. 61818 # If so, the updated path is stored in $new_path. 61819 61820 input_path="$new_path" 61821 # Check if we need to convert this using DOS-style short mode. If the path 61822 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61823 # take no chances and rewrite it. 61824 # Note: m4 eats our [], so we need to use [ and ] instead. 61825 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61826 if test "x$has_forbidden_chars" != x; then 61827 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61828 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61829 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61830 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61831 # Going to short mode and back again did indeed matter. Since short mode is 61832 # case insensitive, let's make it lowercase to improve readability. 61833 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61834 # Now convert it back to Unix-style (cygpath) 61835 input_path=`$CYGPATH -u "$shortmode_path"` 61836 new_path="$input_path" 61837 fi 61838 fi 61839 61840 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61841 if test "x$test_cygdrive_prefix" = x; then 61842 # As a simple fix, exclude /usr/bin since it's not a real path. 61843 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61844 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61845 # a path prefixed by /cygdrive for fixpath to work. 61846 new_path="$CYGWIN_ROOT_PATH$input_path" 61847 fi 61848 fi 61849 61850 61851 if test "x$path" != "x$new_path"; then 61852 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61853 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61854 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61855 fi 61856 61857 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61858 61859 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61860 has_colon=`$ECHO $path | $GREP ^.:` 61861 new_path="$path" 61862 if test "x$has_colon" = x; then 61863 # Not in mixed or Windows style, start by that. 61864 new_path=`cmd //c echo $path` 61865 fi 61866 61867 61868 input_path="$new_path" 61869 # Check if we need to convert this using DOS-style short mode. If the path 61870 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61871 # take no chances and rewrite it. 61872 # Note: m4 eats our [], so we need to use [ and ] instead. 61873 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 61874 if test "x$has_forbidden_chars" != x; then 61875 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61876 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61877 fi 61878 61879 61880 windows_path="$new_path" 61881 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61882 unix_path=`$CYGPATH -u "$windows_path"` 61883 new_path="$unix_path" 61884 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61885 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 61886 new_path="$unix_path" 61887 fi 61888 61889 if test "x$path" != "x$new_path"; then 61890 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 61891 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 61892 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 61893 fi 61894 61895 # Save the first 10 bytes of this path to the storage, so fixpath can work. 61896 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 61897 61898 else 61899 # We're on a unix platform. Hooray! :) 61900 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 61901 has_space=`$ECHO "$path" | $GREP " "` 61902 if test "x$has_space" != x; then 61903 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 61904 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 61905 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 61906 fi 61907 61908 # Use eval to expand a potential ~ 61909 eval path="$path" 61910 if test ! -f "$path" && test ! -d "$path"; then 61911 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 61912 fi 61913 61914 if test -d "$path"; then 61915 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 61916 else 61917 dir="`$DIRNAME "$path"`" 61918 base="`$BASENAME "$path"`" 61919 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 61920 fi 61921 fi 61922 fi 61923 61924 61925 # Only process if variable expands to non-empty 61926 61927 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 61928 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 61929 61930 # Input might be given as Windows format, start by converting to 61931 # unix format. 61932 path="$POTENTIAL_FREETYPE_LIB_PATH" 61933 new_path=`$CYGPATH -u "$path"` 61934 61935 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 61936 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 61937 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 61938 # "foo.exe" is OK but "foo" is an error. 61939 # 61940 # This test is therefore slightly more accurate than "test -f" to check for file precense. 61941 # It is also a way to make sure we got the proper file name for the real test later on. 61942 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 61943 if test "x$test_shortpath" = x; then 61944 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 61945 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 61946 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 61947 fi 61948 61949 # Call helper function which possibly converts this using DOS-style short mode. 61950 # If so, the updated path is stored in $new_path. 61951 61952 input_path="$new_path" 61953 # Check if we need to convert this using DOS-style short mode. If the path 61954 # contains just simple characters, use it. Otherwise (spaces, weird characters), 61955 # take no chances and rewrite it. 61956 # Note: m4 eats our [], so we need to use [ and ] instead. 61957 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 61958 if test "x$has_forbidden_chars" != x; then 61959 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 61960 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 61961 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 61962 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 61963 # Going to short mode and back again did indeed matter. Since short mode is 61964 # case insensitive, let's make it lowercase to improve readability. 61965 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 61966 # Now convert it back to Unix-style (cygpath) 61967 input_path=`$CYGPATH -u "$shortmode_path"` 61968 new_path="$input_path" 61969 fi 61970 fi 61971 61972 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 61973 if test "x$test_cygdrive_prefix" = x; then 61974 # As a simple fix, exclude /usr/bin since it's not a real path. 61975 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 61976 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 61977 # a path prefixed by /cygdrive for fixpath to work. 61978 new_path="$CYGWIN_ROOT_PATH$input_path" 61979 fi 61980 fi 61981 61982 61983 if test "x$path" != "x$new_path"; then 61984 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 61985 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 61986 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 61987 fi 61988 61989 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 61990 61991 path="$POTENTIAL_FREETYPE_LIB_PATH" 61992 has_colon=`$ECHO $path | $GREP ^.:` 61993 new_path="$path" 61994 if test "x$has_colon" = x; then 61995 # Not in mixed or Windows style, start by that. 61996 new_path=`cmd //c echo $path` 61997 fi 61998 61999 62000 input_path="$new_path" 62001 # Check if we need to convert this using DOS-style short mode. If the path 62002 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62003 # take no chances and rewrite it. 62004 # Note: m4 eats our [], so we need to use [ and ] instead. 62005 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 62006 if test "x$has_forbidden_chars" != x; then 62007 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62008 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62009 fi 62010 62011 62012 windows_path="$new_path" 62013 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62014 unix_path=`$CYGPATH -u "$windows_path"` 62015 new_path="$unix_path" 62016 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62017 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62018 new_path="$unix_path" 62019 fi 62020 62021 if test "x$path" != "x$new_path"; then 62022 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 62023 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 62024 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62025 fi 62026 62027 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62028 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62029 62030 else 62031 # We're on a unix platform. Hooray! :) 62032 path="$POTENTIAL_FREETYPE_LIB_PATH" 62033 has_space=`$ECHO "$path" | $GREP " "` 62034 if test "x$has_space" != x; then 62035 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62036 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62037 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62038 fi 62039 62040 # Use eval to expand a potential ~ 62041 eval path="$path" 62042 if test ! -f "$path" && test ! -d "$path"; then 62043 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62044 fi 62045 62046 if test -d "$path"; then 62047 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 62048 else 62049 dir="`$DIRNAME "$path"`" 62050 base="`$BASENAME "$path"`" 62051 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62052 fi 62053 fi 62054 fi 62055 62056 62057 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 62058 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 62059 $as_echo_n "checking for freetype includes... " >&6; } 62060 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 62061 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 62062 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 62063 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 62064 $as_echo_n "checking for freetype libraries... " >&6; } 62065 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 62066 $as_echo "$FREETYPE_LIB_PATH" >&6; } 62067 fi 62068 62069 fi 62070 fi 62071 fi 62072 fi 62073 fi # end check in well-known locations 62074 62075 if test "x$FOUND_FREETYPE" != xyes; then 62076 62077 # Print a helpful message on how to acquire the necessary build dependency. 62078 # freetype is the help tag: freetype, cups, alsa etc 62079 MISSING_DEPENDENCY=freetype 62080 62081 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62082 cygwin_help $MISSING_DEPENDENCY 62083 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62084 msys_help $MISSING_DEPENDENCY 62085 else 62086 PKGHANDLER_COMMAND= 62087 62088 case $PKGHANDLER in 62089 apt-get) 62090 apt_help $MISSING_DEPENDENCY ;; 62091 yum) 62092 yum_help $MISSING_DEPENDENCY ;; 62093 port) 62094 port_help $MISSING_DEPENDENCY ;; 62095 pkgutil) 62096 pkgutil_help $MISSING_DEPENDENCY ;; 62097 pkgadd) 62098 pkgadd_help $MISSING_DEPENDENCY ;; 62099 esac 62100 62101 if test "x$PKGHANDLER_COMMAND" != x; then 62102 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 62103 fi 62104 fi 62105 62106 as_fn_error $? "Could not find freetype! $HELP_MSG " "$LINENO" 5 62107 fi 62108 fi # end user specified settings 62109 62110 # Set FREETYPE_CFLAGS, _LIBS and _LIB_PATH from include and lib dir. 62111 if test "x$FREETYPE_CFLAGS" = x; then 62112 62113 # Only process if variable expands to non-empty 62114 62115 if test "x$FREETYPE_INCLUDE_PATH" != x; then 62116 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62117 62118 # Input might be given as Windows format, start by converting to 62119 # unix format. 62120 path="$FREETYPE_INCLUDE_PATH" 62121 new_path=`$CYGPATH -u "$path"` 62122 62123 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 62124 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 62125 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 62126 # "foo.exe" is OK but "foo" is an error. 62127 # 62128 # This test is therefore slightly more accurate than "test -f" to check for file precense. 62129 # It is also a way to make sure we got the proper file name for the real test later on. 62130 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 62131 if test "x$test_shortpath" = x; then 62132 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 62133 $as_echo "$as_me: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 62134 as_fn_error $? "Cannot locate the the path of FREETYPE_INCLUDE_PATH" "$LINENO" 5 62135 fi 62136 62137 # Call helper function which possibly converts this using DOS-style short mode. 62138 # If so, the updated path is stored in $new_path. 62139 62140 input_path="$new_path" 62141 # Check if we need to convert this using DOS-style short mode. If the path 62142 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62143 # take no chances and rewrite it. 62144 # Note: m4 eats our [], so we need to use [ and ] instead. 62145 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 62146 if test "x$has_forbidden_chars" != x; then 62147 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62148 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 62149 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 62150 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 62151 # Going to short mode and back again did indeed matter. Since short mode is 62152 # case insensitive, let's make it lowercase to improve readability. 62153 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62154 # Now convert it back to Unix-style (cygpath) 62155 input_path=`$CYGPATH -u "$shortmode_path"` 62156 new_path="$input_path" 62157 fi 62158 fi 62159 62160 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 62161 if test "x$test_cygdrive_prefix" = x; then 62162 # As a simple fix, exclude /usr/bin since it's not a real path. 62163 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 62164 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 62165 # a path prefixed by /cygdrive for fixpath to work. 62166 new_path="$CYGWIN_ROOT_PATH$input_path" 62167 fi 62168 fi 62169 62170 62171 if test "x$path" != "x$new_path"; then 62172 FREETYPE_INCLUDE_PATH="$new_path" 62173 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 62174 $as_echo "$as_me: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 62175 fi 62176 62177 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62178 62179 path="$FREETYPE_INCLUDE_PATH" 62180 has_colon=`$ECHO $path | $GREP ^.:` 62181 new_path="$path" 62182 if test "x$has_colon" = x; then 62183 # Not in mixed or Windows style, start by that. 62184 new_path=`cmd //c echo $path` 62185 fi 62186 62187 62188 input_path="$new_path" 62189 # Check if we need to convert this using DOS-style short mode. If the path 62190 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62191 # take no chances and rewrite it. 62192 # Note: m4 eats our [], so we need to use [ and ] instead. 62193 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 62194 if test "x$has_forbidden_chars" != x; then 62195 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62196 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62197 fi 62198 62199 62200 windows_path="$new_path" 62201 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62202 unix_path=`$CYGPATH -u "$windows_path"` 62203 new_path="$unix_path" 62204 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62205 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62206 new_path="$unix_path" 62207 fi 62208 62209 if test "x$path" != "x$new_path"; then 62210 FREETYPE_INCLUDE_PATH="$new_path" 62211 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 62212 $as_echo "$as_me: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 62213 fi 62214 62215 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62216 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62217 62218 else 62219 # We're on a unix platform. Hooray! :) 62220 path="$FREETYPE_INCLUDE_PATH" 62221 has_space=`$ECHO "$path" | $GREP " "` 62222 if test "x$has_space" != x; then 62223 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 62224 $as_echo "$as_me: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 62225 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62226 fi 62227 62228 # Use eval to expand a potential ~ 62229 eval path="$path" 62230 if test ! -f "$path" && test ! -d "$path"; then 62231 as_fn_error $? "The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62232 fi 62233 62234 if test -d "$path"; then 62235 FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 62236 else 62237 dir="`$DIRNAME "$path"`" 62238 base="`$BASENAME "$path"`" 62239 FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62240 fi 62241 fi 62242 fi 62243 62244 if test -d $FREETYPE_INCLUDE_PATH/freetype2/freetype; then 62245 FREETYPE_CFLAGS="-I$FREETYPE_INCLUDE_PATH/freetype2 -I$FREETYPE_INCLUDE_PATH" 62246 else 62247 FREETYPE_CFLAGS="-I$FREETYPE_INCLUDE_PATH" 62248 fi 62249 fi 62250 62251 if test "x$FREETYPE_LIBS" = x; then 62252 62253 # Only process if variable expands to non-empty 62254 62255 if test "x$FREETYPE_LIB_PATH" != x; then 62256 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62257 62258 # Input might be given as Windows format, start by converting to 62259 # unix format. 62260 path="$FREETYPE_LIB_PATH" 62261 new_path=`$CYGPATH -u "$path"` 62262 62263 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 62264 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 62265 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 62266 # "foo.exe" is OK but "foo" is an error. 62267 # 62268 # This test is therefore slightly more accurate than "test -f" to check for file precense. 62269 # It is also a way to make sure we got the proper file name for the real test later on. 62270 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 62271 if test "x$test_shortpath" = x; then 62272 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62273 $as_echo "$as_me: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62274 as_fn_error $? "Cannot locate the the path of FREETYPE_LIB_PATH" "$LINENO" 5 62275 fi 62276 62277 # Call helper function which possibly converts this using DOS-style short mode. 62278 # If so, the updated path is stored in $new_path. 62279 62280 input_path="$new_path" 62281 # Check if we need to convert this using DOS-style short mode. If the path 62282 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62283 # take no chances and rewrite it. 62284 # Note: m4 eats our [], so we need to use [ and ] instead. 62285 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 62286 if test "x$has_forbidden_chars" != x; then 62287 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62288 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 62289 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 62290 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 62291 # Going to short mode and back again did indeed matter. Since short mode is 62292 # case insensitive, let's make it lowercase to improve readability. 62293 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62294 # Now convert it back to Unix-style (cygpath) 62295 input_path=`$CYGPATH -u "$shortmode_path"` 62296 new_path="$input_path" 62297 fi 62298 fi 62299 62300 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 62301 if test "x$test_cygdrive_prefix" = x; then 62302 # As a simple fix, exclude /usr/bin since it's not a real path. 62303 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 62304 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 62305 # a path prefixed by /cygdrive for fixpath to work. 62306 new_path="$CYGWIN_ROOT_PATH$input_path" 62307 fi 62308 fi 62309 62310 62311 if test "x$path" != "x$new_path"; then 62312 FREETYPE_LIB_PATH="$new_path" 62313 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&5 62314 $as_echo "$as_me: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62315 fi 62316 62317 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62318 62319 path="$FREETYPE_LIB_PATH" 62320 has_colon=`$ECHO $path | $GREP ^.:` 62321 new_path="$path" 62322 if test "x$has_colon" = x; then 62323 # Not in mixed or Windows style, start by that. 62324 new_path=`cmd //c echo $path` 62325 fi 62326 62327 62328 input_path="$new_path" 62329 # Check if we need to convert this using DOS-style short mode. If the path 62330 # contains just simple characters, use it. Otherwise (spaces, weird characters), 62331 # take no chances and rewrite it. 62332 # Note: m4 eats our [], so we need to use [ and ] instead. 62333 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 62334 if test "x$has_forbidden_chars" != x; then 62335 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 62336 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 62337 fi 62338 62339 62340 windows_path="$new_path" 62341 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62342 unix_path=`$CYGPATH -u "$windows_path"` 62343 new_path="$unix_path" 62344 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62345 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 62346 new_path="$unix_path" 62347 fi 62348 62349 if test "x$path" != "x$new_path"; then 62350 FREETYPE_LIB_PATH="$new_path" 62351 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&5 62352 $as_echo "$as_me: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 62353 fi 62354 62355 # Save the first 10 bytes of this path to the storage, so fixpath can work. 62356 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 62357 62358 else 62359 # We're on a unix platform. Hooray! :) 62360 path="$FREETYPE_LIB_PATH" 62361 has_space=`$ECHO "$path" | $GREP " "` 62362 if test "x$has_space" != x; then 62363 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 62364 $as_echo "$as_me: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 62365 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 62366 fi 62367 62368 # Use eval to expand a potential ~ 62369 eval path="$path" 62370 if test ! -f "$path" && test ! -d "$path"; then 62371 as_fn_error $? "The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 62372 fi 62373 62374 if test -d "$path"; then 62375 FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 62376 else 62377 dir="`$DIRNAME "$path"`" 62378 base="`$BASENAME "$path"`" 62379 FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 62380 fi 62381 fi 62382 fi 62383 62384 if test "x$OPENJDK_TARGET_OS" = xwindows; then 62385 FREETYPE_LIBS="$FREETYPE_LIB_PATH/$FREETYPE_BASE_NAME.lib" 62386 else 62387 FREETYPE_LIBS="-L$FREETYPE_LIB_PATH -l$FREETYPE_BASE_NAME" 62388 fi 62389 fi 62390 62391 # Try to compile it 62392 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can compile and link with freetype" >&5 62393 $as_echo_n "checking if we can compile and link with freetype... " >&6; } 62394 ac_ext=cpp 62395 ac_cpp='$CXXCPP $CPPFLAGS' 62396 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 62397 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 62398 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 62399 62400 PREV_CXXCFLAGS="$CXXFLAGS" 62401 PREV_LIBS="$LIBS" 62402 PREV_CXX="$CXX" 62403 CXXFLAGS="$CXXFLAGS $FREETYPE_CFLAGS" 62404 LIBS="$LIBS $FREETYPE_LIBS" 62405 CXX="$FIXPATH $CXX" 62406 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 62407 /* end confdefs.h. */ 62408 62409 #include<ft2build.h> 62410 #include FT_FREETYPE_H 62411 int main () { 62412 FT_Init_FreeType(NULL); 62413 return 0; 62414 } 62415 62416 _ACEOF 62417 if ac_fn_cxx_try_link "$LINENO"; then : 62418 62419 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 62420 $as_echo "yes" >&6; } 62421 62422 else 62423 62424 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 62425 $as_echo "no" >&6; } 62426 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not compile and link with freetype. This might be a 32/64-bit mismatch." >&5 62427 $as_echo "$as_me: Could not compile and link with freetype. This might be a 32/64-bit mismatch." >&6;} 62428 { $as_echo "$as_me:${as_lineno-$LINENO}: Using FREETYPE_CFLAGS=$FREETYPE_CFLAGS and FREETYPE_LIBS=$FREETYPE_LIBS" >&5 62429 $as_echo "$as_me: Using FREETYPE_CFLAGS=$FREETYPE_CFLAGS and FREETYPE_LIBS=$FREETYPE_LIBS" >&6;} 62430 62431 62432 # Print a helpful message on how to acquire the necessary build dependency. 62433 # freetype is the help tag: freetype, cups, alsa etc 62434 MISSING_DEPENDENCY=freetype 62435 62436 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62437 cygwin_help $MISSING_DEPENDENCY 62438 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62439 msys_help $MISSING_DEPENDENCY 62440 else 62441 PKGHANDLER_COMMAND= 62442 62443 case $PKGHANDLER in 62444 apt-get) 62445 apt_help $MISSING_DEPENDENCY ;; 62446 yum) 62447 yum_help $MISSING_DEPENDENCY ;; 62448 port) 62449 port_help $MISSING_DEPENDENCY ;; 62450 pkgutil) 62451 pkgutil_help $MISSING_DEPENDENCY ;; 62452 pkgadd) 62453 pkgadd_help $MISSING_DEPENDENCY ;; 62454 esac 62455 62456 if test "x$PKGHANDLER_COMMAND" != x; then 62457 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 62458 fi 62459 fi 62460 62461 62462 as_fn_error $? "Can not continue without freetype. $HELP_MSG" "$LINENO" 5 62463 62464 62465 fi 62466 rm -f core conftest.err conftest.$ac_objext \ 62467 conftest$ac_exeext conftest.$ac_ext 62468 CXXCFLAGS="$PREV_CXXFLAGS" 62469 LIBS="$PREV_LIBS" 62470 CXX="$PREV_CXX" 62471 ac_ext=cpp 62472 ac_cpp='$CXXCPP $CPPFLAGS' 62473 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 62474 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 62475 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 62476 62477 62478 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should bundle freetype" >&5 62479 $as_echo_n "checking if we should bundle freetype... " >&6; } 62480 if test "x$BUNDLE_FREETYPE" = xyes; then 62481 FREETYPE_BUNDLE_LIB_PATH="$FREETYPE_LIB_PATH" 62482 fi 62483 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUNDLE_FREETYPE" >&5 62484 $as_echo "$BUNDLE_FREETYPE" >&6; } 62485 62486 fi # end freetype needed 62487 62488 62489 62490 62491 62492 62493 62494 # Check whether --with-alsa was given. 62495 if test "${with_alsa+set}" = set; then : 62496 withval=$with_alsa; 62497 fi 62498 62499 62500 # Check whether --with-alsa-include was given. 62501 if test "${with_alsa_include+set}" = set; then : 62502 withval=$with_alsa_include; 62503 fi 62504 62505 62506 # Check whether --with-alsa-lib was given. 62507 if test "${with_alsa_lib+set}" = set; then : 62508 withval=$with_alsa_lib; 62509 fi 62510 62511 62512 if test "x$NEEDS_LIB_ALSA" = xfalse; then 62513 if (test "x${with_alsa}" != x && test "x${with_alsa}" != xno) || \ 62514 (test "x${with_alsa_include}" != x && test "x${with_alsa_include}" != xno) || \ 62515 (test "x${with_alsa_lib}" != x && test "x${with_alsa_lib}" != xno); then 62516 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: alsa not used, so --with-alsa[-*] is ignored" >&5 62517 $as_echo "$as_me: WARNING: alsa not used, so --with-alsa[-*] is ignored" >&2;} 62518 fi 62519 ALSA_CFLAGS= 62520 ALSA_LIBS= 62521 else 62522 ALSA_FOUND=no 62523 62524 if test "x${with_alsa}" = xno || test "x${with_alsa_include}" = xno || test "x${with_alsa_lib}" = xno; then 62525 as_fn_error $? "It is not possible to disable the use of alsa. Remove the --without-alsa option." "$LINENO" 5 62526 fi 62527 62528 if test "x${with_alsa}" != x; then 62529 ALSA_LIBS="-L${with_alsa}/lib -lasound" 62530 ALSA_CFLAGS="-I${with_alsa}/include" 62531 ALSA_FOUND=yes 62532 fi 62533 if test "x${with_alsa_include}" != x; then 62534 ALSA_CFLAGS="-I${with_alsa_include}" 62535 ALSA_FOUND=yes 62536 fi 62537 if test "x${with_alsa_lib}" != x; then 62538 ALSA_LIBS="-L${with_alsa_lib} -lasound" 62539 ALSA_FOUND=yes 62540 fi 62541 # Do not try pkg-config if we have a sysroot set. 62542 if test "x$SYSROOT" = x; then 62543 if test "x$ALSA_FOUND" = xno; then 62544 62545 pkg_failed=no 62546 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ALSA" >&5 62547 $as_echo_n "checking for ALSA... " >&6; } 62548 62549 if test -n "$ALSA_CFLAGS"; then 62550 pkg_cv_ALSA_CFLAGS="$ALSA_CFLAGS" 62551 elif test -n "$PKG_CONFIG"; then 62552 if test -n "$PKG_CONFIG" && \ 62553 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"alsa\""; } >&5 62554 ($PKG_CONFIG --exists --print-errors "alsa") 2>&5 62555 ac_status=$? 62556 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 62557 test $ac_status = 0; }; then 62558 pkg_cv_ALSA_CFLAGS=`$PKG_CONFIG --cflags "alsa" 2>/dev/null` 62559 else 62560 pkg_failed=yes 62561 fi 62562 else 62563 pkg_failed=untried 62564 fi 62565 if test -n "$ALSA_LIBS"; then 62566 pkg_cv_ALSA_LIBS="$ALSA_LIBS" 62567 elif test -n "$PKG_CONFIG"; then 62568 if test -n "$PKG_CONFIG" && \ 62569 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"alsa\""; } >&5 62570 ($PKG_CONFIG --exists --print-errors "alsa") 2>&5 62571 ac_status=$? 62572 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 62573 test $ac_status = 0; }; then 62574 pkg_cv_ALSA_LIBS=`$PKG_CONFIG --libs "alsa" 2>/dev/null` 62575 else 62576 pkg_failed=yes 62577 fi 62578 else 62579 pkg_failed=untried 62580 fi 62581 62582 62583 62584 if test $pkg_failed = yes; then 62585 62586 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 62587 _pkg_short_errors_supported=yes 62588 else 62589 _pkg_short_errors_supported=no 62590 fi 62591 if test $_pkg_short_errors_supported = yes; then 62592 ALSA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "alsa" 2>&1` 62593 else 62594 ALSA_PKG_ERRORS=`$PKG_CONFIG --print-errors "alsa" 2>&1` 62595 fi 62596 # Put the nasty error message in config.log where it belongs 62597 echo "$ALSA_PKG_ERRORS" >&5 62598 62599 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 62600 $as_echo "no" >&6; } 62601 ALSA_FOUND=no 62602 elif test $pkg_failed = untried; then 62603 ALSA_FOUND=no 62604 else 62605 ALSA_CFLAGS=$pkg_cv_ALSA_CFLAGS 62606 ALSA_LIBS=$pkg_cv_ALSA_LIBS 62607 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 62608 $as_echo "yes" >&6; } 62609 ALSA_FOUND=yes 62610 fi 62611 fi 62612 fi 62613 if test "x$ALSA_FOUND" = xno; then 62614 for ac_header in alsa/asoundlib.h 62615 do : 62616 ac_fn_cxx_check_header_mongrel "$LINENO" "alsa/asoundlib.h" "ac_cv_header_alsa_asoundlib_h" "$ac_includes_default" 62617 if test "x$ac_cv_header_alsa_asoundlib_h" = xyes; then : 62618 cat >>confdefs.h <<_ACEOF 62619 #define HAVE_ALSA_ASOUNDLIB_H 1 62620 _ACEOF 62621 62622 ALSA_FOUND=yes 62623 ALSA_CFLAGS=-Iignoreme 62624 ALSA_LIBS=-lasound 62625 DEFAULT_ALSA=yes 62626 62627 else 62628 ALSA_FOUND=no 62629 62630 fi 62631 62632 done 62633 62634 fi 62635 if test "x$ALSA_FOUND" = xno; then 62636 62637 # Print a helpful message on how to acquire the necessary build dependency. 62638 # alsa is the help tag: freetype, cups, alsa etc 62639 MISSING_DEPENDENCY=alsa 62640 62641 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62642 cygwin_help $MISSING_DEPENDENCY 62643 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62644 msys_help $MISSING_DEPENDENCY 62645 else 62646 PKGHANDLER_COMMAND= 62647 62648 case $PKGHANDLER in 62649 apt-get) 62650 apt_help $MISSING_DEPENDENCY ;; 62651 yum) 62652 yum_help $MISSING_DEPENDENCY ;; 62653 port) 62654 port_help $MISSING_DEPENDENCY ;; 62655 pkgutil) 62656 pkgutil_help $MISSING_DEPENDENCY ;; 62657 pkgadd) 62658 pkgadd_help $MISSING_DEPENDENCY ;; 62659 esac 62660 62661 if test "x$PKGHANDLER_COMMAND" != x; then 62662 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 62663 fi 62664 fi 62665 62666 as_fn_error $? "Could not find alsa! $HELP_MSG" "$LINENO" 5 62667 fi 62668 fi 62669 62670 62671 62672 62673 62674 62675 # Check whether --with-libffi was given. 62676 if test "${with_libffi+set}" = set; then : 62677 withval=$with_libffi; 62678 fi 62679 62680 62681 # Check whether --with-libffi-include was given. 62682 if test "${with_libffi_include+set}" = set; then : 62683 withval=$with_libffi_include; 62684 fi 62685 62686 62687 # Check whether --with-libffi-lib was given. 62688 if test "${with_libffi_lib+set}" = set; then : 62689 withval=$with_libffi_lib; 62690 fi 62691 62692 62693 if test "x$NEEDS_LIB_FFI" = xfalse; then 62694 if (test "x${with_libffi}" != x && test "x${with_libffi}" != xno) || \ 62695 (test "x${with_libffi_include}" != x && test "x${with_libffi_include}" != xno) || \ 62696 (test "x${with_libffi_lib}" != x && test "x${with_libffi_lib}" != xno); then 62697 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libffi not used, so --with-libffi[-*] is ignored" >&5 62698 $as_echo "$as_me: WARNING: libffi not used, so --with-libffi[-*] is ignored" >&2;} 62699 fi 62700 LIBFFI_CFLAGS= 62701 LIBFFI_LIBS= 62702 else 62703 LIBFFI_FOUND=no 62704 62705 if test "x${with_libffi}" = xno || test "x${with_libffi_include}" = xno || test "x${with_libffi_lib}" = xno; then 62706 as_fn_error $? "It is not possible to disable the use of libffi. Remove the --without-libffi option." "$LINENO" 5 62707 fi 62708 62709 if test "x${with_libffi}" != x; then 62710 LIBFFI_LIBS="-L${with_libffi}/lib -lffi" 62711 LIBFFI_CFLAGS="-I${with_libffi}/include" 62712 LIBFFI_FOUND=yes 62713 fi 62714 if test "x${with_libffi_include}" != x; then 62715 LIBFFI_CFLAGS="-I${with_libffi_include}" 62716 LIBFFI_FOUND=yes 62717 fi 62718 if test "x${with_libffi_lib}" != x; then 62719 LIBFFI_LIBS="-L${with_libffi_lib} -lffi" 62720 LIBFFI_FOUND=yes 62721 fi 62722 # Do not try pkg-config if we have a sysroot set. 62723 if test "x$SYSROOT" = x; then 62724 if test "x$LIBFFI_FOUND" = xno; then 62725 # Figure out LIBFFI_CFLAGS and LIBFFI_LIBS 62726 62727 pkg_failed=no 62728 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIBFFI" >&5 62729 $as_echo_n "checking for LIBFFI... " >&6; } 62730 62731 if test -n "$LIBFFI_CFLAGS"; then 62732 pkg_cv_LIBFFI_CFLAGS="$LIBFFI_CFLAGS" 62733 elif test -n "$PKG_CONFIG"; then 62734 if test -n "$PKG_CONFIG" && \ 62735 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libffi\""; } >&5 62736 ($PKG_CONFIG --exists --print-errors "libffi") 2>&5 62737 ac_status=$? 62738 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 62739 test $ac_status = 0; }; then 62740 pkg_cv_LIBFFI_CFLAGS=`$PKG_CONFIG --cflags "libffi" 2>/dev/null` 62741 else 62742 pkg_failed=yes 62743 fi 62744 else 62745 pkg_failed=untried 62746 fi 62747 if test -n "$LIBFFI_LIBS"; then 62748 pkg_cv_LIBFFI_LIBS="$LIBFFI_LIBS" 62749 elif test -n "$PKG_CONFIG"; then 62750 if test -n "$PKG_CONFIG" && \ 62751 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libffi\""; } >&5 62752 ($PKG_CONFIG --exists --print-errors "libffi") 2>&5 62753 ac_status=$? 62754 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 62755 test $ac_status = 0; }; then 62756 pkg_cv_LIBFFI_LIBS=`$PKG_CONFIG --libs "libffi" 2>/dev/null` 62757 else 62758 pkg_failed=yes 62759 fi 62760 else 62761 pkg_failed=untried 62762 fi 62763 62764 62765 62766 if test $pkg_failed = yes; then 62767 62768 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 62769 _pkg_short_errors_supported=yes 62770 else 62771 _pkg_short_errors_supported=no 62772 fi 62773 if test $_pkg_short_errors_supported = yes; then 62774 LIBFFI_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "libffi" 2>&1` 62775 else 62776 LIBFFI_PKG_ERRORS=`$PKG_CONFIG --print-errors "libffi" 2>&1` 62777 fi 62778 # Put the nasty error message in config.log where it belongs 62779 echo "$LIBFFI_PKG_ERRORS" >&5 62780 62781 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 62782 $as_echo "no" >&6; } 62783 LIBFFI_FOUND=no 62784 elif test $pkg_failed = untried; then 62785 LIBFFI_FOUND=no 62786 else 62787 LIBFFI_CFLAGS=$pkg_cv_LIBFFI_CFLAGS 62788 LIBFFI_LIBS=$pkg_cv_LIBFFI_LIBS 62789 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 62790 $as_echo "yes" >&6; } 62791 LIBFFI_FOUND=yes 62792 fi 62793 fi 62794 fi 62795 if test "x$LIBFFI_FOUND" = xno; then 62796 for ac_header in ffi.h 62797 do : 62798 ac_fn_cxx_check_header_mongrel "$LINENO" "ffi.h" "ac_cv_header_ffi_h" "$ac_includes_default" 62799 if test "x$ac_cv_header_ffi_h" = xyes; then : 62800 cat >>confdefs.h <<_ACEOF 62801 #define HAVE_FFI_H 1 62802 _ACEOF 62803 62804 LIBFFI_FOUND=yes 62805 LIBFFI_CFLAGS= 62806 LIBFFI_LIBS=-lffi 62807 62808 else 62809 LIBFFI_FOUND=no 62810 62811 fi 62812 62813 done 62814 62815 fi 62816 if test "x$LIBFFI_FOUND" = xno; then 62817 62818 # Print a helpful message on how to acquire the necessary build dependency. 62819 # ffi is the help tag: freetype, cups, alsa etc 62820 MISSING_DEPENDENCY=ffi 62821 62822 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62823 cygwin_help $MISSING_DEPENDENCY 62824 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62825 msys_help $MISSING_DEPENDENCY 62826 else 62827 PKGHANDLER_COMMAND= 62828 62829 case $PKGHANDLER in 62830 apt-get) 62831 apt_help $MISSING_DEPENDENCY ;; 62832 yum) 62833 yum_help $MISSING_DEPENDENCY ;; 62834 port) 62835 port_help $MISSING_DEPENDENCY ;; 62836 pkgutil) 62837 pkgutil_help $MISSING_DEPENDENCY ;; 62838 pkgadd) 62839 pkgadd_help $MISSING_DEPENDENCY ;; 62840 esac 62841 62842 if test "x$PKGHANDLER_COMMAND" != x; then 62843 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 62844 fi 62845 fi 62846 62847 as_fn_error $? "Could not find libffi! $HELP_MSG" "$LINENO" 5 62848 fi 62849 62850 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libffi works" >&5 62851 $as_echo_n "checking if libffi works... " >&6; } 62852 ac_ext=c 62853 ac_cpp='$CPP $CPPFLAGS' 62854 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 62855 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 62856 ac_compiler_gnu=$ac_cv_c_compiler_gnu 62857 62858 OLD_CFLAGS="$CFLAGS" 62859 CFLAGS="$CFLAGS $LIBFFI_CFLAGS" 62860 OLD_LIBS="$LIBS" 62861 LIBS="$LIBS $LIBFFI_LIBS" 62862 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 62863 /* end confdefs.h. */ 62864 #include <ffi.h> 62865 int 62866 main () 62867 { 62868 62869 ffi_call(NULL, NULL, NULL, NULL); 62870 return 0; 62871 62872 ; 62873 return 0; 62874 } 62875 _ACEOF 62876 if ac_fn_c_try_link "$LINENO"; then : 62877 LIBFFI_WORKS=yes 62878 else 62879 LIBFFI_WORKS=no 62880 62881 fi 62882 rm -f core conftest.err conftest.$ac_objext \ 62883 conftest$ac_exeext conftest.$ac_ext 62884 CFLAGS="$OLD_CFLAGS" 62885 LIBS="$OLD_LIBS" 62886 ac_ext=cpp 62887 ac_cpp='$CXXCPP $CPPFLAGS' 62888 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 62889 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 62890 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 62891 62892 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBFFI_WORKS" >&5 62893 $as_echo "$LIBFFI_WORKS" >&6; } 62894 62895 if test "x$LIBFFI_WORKS" = xno; then 62896 62897 # Print a helpful message on how to acquire the necessary build dependency. 62898 # ffi is the help tag: freetype, cups, alsa etc 62899 MISSING_DEPENDENCY=ffi 62900 62901 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 62902 cygwin_help $MISSING_DEPENDENCY 62903 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 62904 msys_help $MISSING_DEPENDENCY 62905 else 62906 PKGHANDLER_COMMAND= 62907 62908 case $PKGHANDLER in 62909 apt-get) 62910 apt_help $MISSING_DEPENDENCY ;; 62911 yum) 62912 yum_help $MISSING_DEPENDENCY ;; 62913 port) 62914 port_help $MISSING_DEPENDENCY ;; 62915 pkgutil) 62916 pkgutil_help $MISSING_DEPENDENCY ;; 62917 pkgadd) 62918 pkgadd_help $MISSING_DEPENDENCY ;; 62919 esac 62920 62921 if test "x$PKGHANDLER_COMMAND" != x; then 62922 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 62923 fi 62924 fi 62925 62926 as_fn_error $? "Found libffi but could not link and compile with it. $HELP_MSG" "$LINENO" 5 62927 fi 62928 fi 62929 62930 62931 62932 62933 62934 if [[ " $JVM_VARIANTS " =~ " zeroshark " ]] ; then 62935 # Extract the first word of "llvm-config", so it can be a program name with args. 62936 set dummy llvm-config; ac_word=$2 62937 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 62938 $as_echo_n "checking for $ac_word... " >&6; } 62939 if ${ac_cv_prog_LLVM_CONFIG+:} false; then : 62940 $as_echo_n "(cached) " >&6 62941 else 62942 if test -n "$LLVM_CONFIG"; then 62943 ac_cv_prog_LLVM_CONFIG="$LLVM_CONFIG" # Let the user override the test. 62944 else 62945 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 62946 for as_dir in $PATH 62947 do 62948 IFS=$as_save_IFS 62949 test -z "$as_dir" && as_dir=. 62950 for ac_exec_ext in '' $ac_executable_extensions; do 62951 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 62952 ac_cv_prog_LLVM_CONFIG="llvm-config" 62953 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 62954 break 2 62955 fi 62956 done 62957 done 62958 IFS=$as_save_IFS 62959 62960 fi 62961 fi 62962 LLVM_CONFIG=$ac_cv_prog_LLVM_CONFIG 62963 if test -n "$LLVM_CONFIG"; then 62964 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LLVM_CONFIG" >&5 62965 $as_echo "$LLVM_CONFIG" >&6; } 62966 else 62967 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 62968 $as_echo "no" >&6; } 62969 fi 62970 62971 62972 62973 if test "x$LLVM_CONFIG" != xllvm-config; then 62974 as_fn_error $? "llvm-config not found in $PATH." "$LINENO" 5 62975 fi 62976 62977 llvm_components="jit mcjit engine nativecodegen native" 62978 unset LLVM_CFLAGS 62979 for flag in $("$LLVM_CONFIG" --cxxflags); do 62980 if echo "${flag}" | grep -q '^-[ID]'; then 62981 if test "${flag}" != "-D_DEBUG" ; then 62982 if test "${LLVM_CFLAGS}" != "" ; then 62983 LLVM_CFLAGS="${LLVM_CFLAGS} " 62984 fi 62985 LLVM_CFLAGS="${LLVM_CFLAGS}${flag}" 62986 fi 62987 fi 62988 done 62989 llvm_version=$("${LLVM_CONFIG}" --version | $SED 's/\.//; s/svn.*//') 62990 LLVM_CFLAGS="${LLVM_CFLAGS} -DSHARK_LLVM_VERSION=${llvm_version}" 62991 62992 unset LLVM_LDFLAGS 62993 for flag in $("${LLVM_CONFIG}" --ldflags); do 62994 if echo "${flag}" | grep -q '^-L'; then 62995 if test "${LLVM_LDFLAGS}" != ""; then 62996 LLVM_LDFLAGS="${LLVM_LDFLAGS} " 62997 fi 62998 LLVM_LDFLAGS="${LLVM_LDFLAGS}${flag}" 62999 fi 63000 done 63001 63002 unset LLVM_LIBS 63003 for flag in $("${LLVM_CONFIG}" --libs ${llvm_components}); do 63004 if echo "${flag}" | grep -q '^-l'; then 63005 if test "${LLVM_LIBS}" != ""; then 63006 LLVM_LIBS="${LLVM_LIBS} " 63007 fi 63008 LLVM_LIBS="${LLVM_LIBS}${flag}" 63009 fi 63010 done 63011 63012 # Due to https://llvm.org/bugs/show_bug.cgi?id=16902, llvm does not 63013 # always properly detect -ltinfo 63014 LLVM_LIBS="${LLVM_LIBS} -ltinfo" 63015 63016 63017 63018 63019 fi 63020 63021 63022 63023 # Check whether --with-libjpeg was given. 63024 if test "${with_libjpeg+set}" = set; then : 63025 withval=$with_libjpeg; 63026 fi 63027 63028 63029 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which libjpeg to use" >&5 63030 $as_echo_n "checking for which libjpeg to use... " >&6; } 63031 # default is bundled 63032 DEFAULT_LIBJPEG=bundled 63033 # if user didn't specify, use DEFAULT_LIBJPEG 63034 if test "x${with_libjpeg}" = "x"; then 63035 with_libjpeg=${DEFAULT_LIBJPEG} 63036 fi 63037 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_libjpeg}" >&5 63038 $as_echo "${with_libjpeg}" >&6; } 63039 63040 if test "x${with_libjpeg}" = "xbundled"; then 63041 USE_EXTERNAL_LIBJPEG=false 63042 elif test "x${with_libjpeg}" = "xsystem"; then 63043 ac_fn_cxx_check_header_mongrel "$LINENO" "jpeglib.h" "ac_cv_header_jpeglib_h" "$ac_includes_default" 63044 if test "x$ac_cv_header_jpeglib_h" = xyes; then : 63045 63046 else 63047 as_fn_error $? "--with-libjpeg=system specified, but jpeglib.h not found!" "$LINENO" 5 63048 fi 63049 63050 63051 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jpeg_CreateDecompress in -ljpeg" >&5 63052 $as_echo_n "checking for jpeg_CreateDecompress in -ljpeg... " >&6; } 63053 if ${ac_cv_lib_jpeg_jpeg_CreateDecompress+:} false; then : 63054 $as_echo_n "(cached) " >&6 63055 else 63056 ac_check_lib_save_LIBS=$LIBS 63057 LIBS="-ljpeg $LIBS" 63058 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 63059 /* end confdefs.h. */ 63060 63061 /* Override any GCC internal prototype to avoid an error. 63062 Use char because int might match the return type of a GCC 63063 builtin and then its argument prototype would still apply. */ 63064 #ifdef __cplusplus 63065 extern "C" 63066 #endif 63067 char jpeg_CreateDecompress (); 63068 int 63069 main () 63070 { 63071 return jpeg_CreateDecompress (); 63072 ; 63073 return 0; 63074 } 63075 _ACEOF 63076 if ac_fn_cxx_try_link "$LINENO"; then : 63077 ac_cv_lib_jpeg_jpeg_CreateDecompress=yes 63078 else 63079 ac_cv_lib_jpeg_jpeg_CreateDecompress=no 63080 fi 63081 rm -f core conftest.err conftest.$ac_objext \ 63082 conftest$ac_exeext conftest.$ac_ext 63083 LIBS=$ac_check_lib_save_LIBS 63084 fi 63085 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_jpeg_jpeg_CreateDecompress" >&5 63086 $as_echo "$ac_cv_lib_jpeg_jpeg_CreateDecompress" >&6; } 63087 if test "x$ac_cv_lib_jpeg_jpeg_CreateDecompress" = xyes; then : 63088 cat >>confdefs.h <<_ACEOF 63089 #define HAVE_LIBJPEG 1 63090 _ACEOF 63091 63092 LIBS="-ljpeg $LIBS" 63093 63094 else 63095 as_fn_error $? "--with-libjpeg=system specified, but no libjpeg found" "$LINENO" 5 63096 fi 63097 63098 63099 USE_EXTERNAL_LIBJPEG=true 63100 else 63101 as_fn_error $? "Invalid use of --with-libjpeg: ${with_libjpeg}, use 'system' or 'bundled'" "$LINENO" 5 63102 fi 63103 63104 63105 63106 63107 63108 # Check whether --with-giflib was given. 63109 if test "${with_giflib+set}" = set; then : 63110 withval=$with_giflib; 63111 fi 63112 63113 63114 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which giflib to use" >&5 63115 $as_echo_n "checking for which giflib to use... " >&6; } 63116 # default is bundled 63117 DEFAULT_GIFLIB=bundled 63118 # if user didn't specify, use DEFAULT_GIFLIB 63119 if test "x${with_giflib}" = "x"; then 63120 with_giflib=${DEFAULT_GIFLIB} 63121 fi 63122 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_giflib}" >&5 63123 $as_echo "${with_giflib}" >&6; } 63124 63125 if test "x${with_giflib}" = "xbundled"; then 63126 USE_EXTERNAL_LIBGIF=false 63127 elif test "x${with_giflib}" = "xsystem"; then 63128 ac_fn_cxx_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default" 63129 if test "x$ac_cv_header_gif_lib_h" = xyes; then : 63130 63131 else 63132 as_fn_error $? "--with-giflib=system specified, but gif_lib.h not found!" "$LINENO" 5 63133 fi 63134 63135 63136 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DGifGetCode in -lgif" >&5 63137 $as_echo_n "checking for DGifGetCode in -lgif... " >&6; } 63138 if ${ac_cv_lib_gif_DGifGetCode+:} false; then : 63139 $as_echo_n "(cached) " >&6 63140 else 63141 ac_check_lib_save_LIBS=$LIBS 63142 LIBS="-lgif $LIBS" 63143 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 63144 /* end confdefs.h. */ 63145 63146 /* Override any GCC internal prototype to avoid an error. 63147 Use char because int might match the return type of a GCC 63148 builtin and then its argument prototype would still apply. */ 63149 #ifdef __cplusplus 63150 extern "C" 63151 #endif 63152 char DGifGetCode (); 63153 int 63154 main () 63155 { 63156 return DGifGetCode (); 63157 ; 63158 return 0; 63159 } 63160 _ACEOF 63161 if ac_fn_cxx_try_link "$LINENO"; then : 63162 ac_cv_lib_gif_DGifGetCode=yes 63163 else 63164 ac_cv_lib_gif_DGifGetCode=no 63165 fi 63166 rm -f core conftest.err conftest.$ac_objext \ 63167 conftest$ac_exeext conftest.$ac_ext 63168 LIBS=$ac_check_lib_save_LIBS 63169 fi 63170 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gif_DGifGetCode" >&5 63171 $as_echo "$ac_cv_lib_gif_DGifGetCode" >&6; } 63172 if test "x$ac_cv_lib_gif_DGifGetCode" = xyes; then : 63173 cat >>confdefs.h <<_ACEOF 63174 #define HAVE_LIBGIF 1 63175 _ACEOF 63176 63177 LIBS="-lgif $LIBS" 63178 63179 else 63180 as_fn_error $? "--with-giflib=system specified, but no giflib found!" "$LINENO" 5 63181 fi 63182 63183 63184 USE_EXTERNAL_LIBGIF=true 63185 else 63186 as_fn_error $? "Invalid value of --with-giflib: ${with_giflib}, use 'system' or 'bundled'" "$LINENO" 5 63187 fi 63188 63189 63190 63191 63192 63193 # Check whether --with-libpng was given. 63194 if test "${with_libpng+set}" = set; then : 63195 withval=$with_libpng; 63196 fi 63197 63198 63199 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which libpng to use" >&5 63200 $as_echo_n "checking for which libpng to use... " >&6; } 63201 63202 # default is bundled 63203 DEFAULT_LIBPNG=bundled 63204 # if user didn't specify, use DEFAULT_LIBPNG 63205 if test "x${with_libpng}" = "x"; then 63206 with_libpng=${DEFAULT_LIBPNG} 63207 fi 63208 63209 if test "x${with_libpng}" = "xbundled"; then 63210 USE_EXTERNAL_LIBPNG=false 63211 { $as_echo "$as_me:${as_lineno-$LINENO}: result: bundled" >&5 63212 $as_echo "bundled" >&6; } 63213 elif test "x${with_libpng}" = "xsystem"; then 63214 63215 pkg_failed=no 63216 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PNG" >&5 63217 $as_echo_n "checking for PNG... " >&6; } 63218 63219 if test -n "$PNG_CFLAGS"; then 63220 pkg_cv_PNG_CFLAGS="$PNG_CFLAGS" 63221 elif test -n "$PKG_CONFIG"; then 63222 if test -n "$PKG_CONFIG" && \ 63223 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libpng\""; } >&5 63224 ($PKG_CONFIG --exists --print-errors "libpng") 2>&5 63225 ac_status=$? 63226 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 63227 test $ac_status = 0; }; then 63228 pkg_cv_PNG_CFLAGS=`$PKG_CONFIG --cflags "libpng" 2>/dev/null` 63229 else 63230 pkg_failed=yes 63231 fi 63232 else 63233 pkg_failed=untried 63234 fi 63235 if test -n "$PNG_LIBS"; then 63236 pkg_cv_PNG_LIBS="$PNG_LIBS" 63237 elif test -n "$PKG_CONFIG"; then 63238 if test -n "$PKG_CONFIG" && \ 63239 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libpng\""; } >&5 63240 ($PKG_CONFIG --exists --print-errors "libpng") 2>&5 63241 ac_status=$? 63242 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 63243 test $ac_status = 0; }; then 63244 pkg_cv_PNG_LIBS=`$PKG_CONFIG --libs "libpng" 2>/dev/null` 63245 else 63246 pkg_failed=yes 63247 fi 63248 else 63249 pkg_failed=untried 63250 fi 63251 63252 63253 63254 if test $pkg_failed = yes; then 63255 63256 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 63257 _pkg_short_errors_supported=yes 63258 else 63259 _pkg_short_errors_supported=no 63260 fi 63261 if test $_pkg_short_errors_supported = yes; then 63262 PNG_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "libpng" 2>&1` 63263 else 63264 PNG_PKG_ERRORS=`$PKG_CONFIG --print-errors "libpng" 2>&1` 63265 fi 63266 # Put the nasty error message in config.log where it belongs 63267 echo "$PNG_PKG_ERRORS" >&5 63268 63269 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 63270 $as_echo "no" >&6; } 63271 LIBPNG_FOUND=no 63272 elif test $pkg_failed = untried; then 63273 LIBPNG_FOUND=no 63274 else 63275 PNG_CFLAGS=$pkg_cv_PNG_CFLAGS 63276 PNG_LIBS=$pkg_cv_PNG_LIBS 63277 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 63278 $as_echo "yes" >&6; } 63279 LIBPNG_FOUND=yes 63280 fi 63281 if test "x${LIBPNG_FOUND}" = "xyes"; then 63282 USE_EXTERNAL_LIBPNG=true 63283 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system" >&5 63284 $as_echo "system" >&6; } 63285 else 63286 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system not found" >&5 63287 $as_echo "system not found" >&6; } 63288 as_fn_error $? "--with-libpng=system specified, but no libpng found!" "$LINENO" 5 63289 fi 63290 else 63291 as_fn_error $? "Invalid value of --with-libpng: ${with_libpng}, use 'system' or 'bundled'" "$LINENO" 5 63292 fi 63293 63294 63295 63296 63297 63298 # Check whether --with-zlib was given. 63299 if test "${with_zlib+set}" = set; then : 63300 withval=$with_zlib; 63301 fi 63302 63303 63304 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compress in -lz" >&5 63305 $as_echo_n "checking for compress in -lz... " >&6; } 63306 if ${ac_cv_lib_z_compress+:} false; then : 63307 $as_echo_n "(cached) " >&6 63308 else 63309 ac_check_lib_save_LIBS=$LIBS 63310 LIBS="-lz $LIBS" 63311 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 63312 /* end confdefs.h. */ 63313 63314 /* Override any GCC internal prototype to avoid an error. 63315 Use char because int might match the return type of a GCC 63316 builtin and then its argument prototype would still apply. */ 63317 #ifdef __cplusplus 63318 extern "C" 63319 #endif 63320 char compress (); 63321 int 63322 main () 63323 { 63324 return compress (); 63325 ; 63326 return 0; 63327 } 63328 _ACEOF 63329 if ac_fn_cxx_try_link "$LINENO"; then : 63330 ac_cv_lib_z_compress=yes 63331 else 63332 ac_cv_lib_z_compress=no 63333 fi 63334 rm -f core conftest.err conftest.$ac_objext \ 63335 conftest$ac_exeext conftest.$ac_ext 63336 LIBS=$ac_check_lib_save_LIBS 63337 fi 63338 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_compress" >&5 63339 $as_echo "$ac_cv_lib_z_compress" >&6; } 63340 if test "x$ac_cv_lib_z_compress" = xyes; then : 63341 ZLIB_FOUND=yes 63342 else 63343 ZLIB_FOUND=no 63344 fi 63345 63346 63347 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which zlib to use" >&5 63348 $as_echo_n "checking for which zlib to use... " >&6; } 63349 63350 DEFAULT_ZLIB=system 63351 if test "x$OPENJDK_TARGET_OS" = xwindows; then 63352 # On windows default is bundled...on others default is system 63353 DEFAULT_ZLIB=bundled 63354 fi 63355 63356 if test "x${ZLIB_FOUND}" != "xyes"; then 63357 # If we don't find any system...set default to bundled 63358 DEFAULT_ZLIB=bundled 63359 fi 63360 63361 # If user didn't specify, use DEFAULT_ZLIB 63362 if test "x${with_zlib}" = "x"; then 63363 with_zlib=${DEFAULT_ZLIB} 63364 fi 63365 63366 if test "x${with_zlib}" = "xbundled"; then 63367 USE_EXTERNAL_LIBZ=false 63368 { $as_echo "$as_me:${as_lineno-$LINENO}: result: bundled" >&5 63369 $as_echo "bundled" >&6; } 63370 elif test "x${with_zlib}" = "xsystem"; then 63371 if test "x${ZLIB_FOUND}" = "xyes"; then 63372 USE_EXTERNAL_LIBZ=true 63373 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system" >&5 63374 $as_echo "system" >&6; } 63375 else 63376 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system not found" >&5 63377 $as_echo "system not found" >&6; } 63378 as_fn_error $? "--with-zlib=system specified, but no zlib found!" "$LINENO" 5 63379 fi 63380 else 63381 as_fn_error $? "Invalid value for --with-zlib: ${with_zlib}, use 'system' or 'bundled'" "$LINENO" 5 63382 fi 63383 63384 63385 63386 63387 63388 # Check whether --with-lcms was given. 63389 if test "${with_lcms+set}" = set; then : 63390 withval=$with_lcms; 63391 fi 63392 63393 63394 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which lcms to use" >&5 63395 $as_echo_n "checking for which lcms to use... " >&6; } 63396 63397 DEFAULT_LCMS=bundled 63398 # If user didn't specify, use DEFAULT_LCMS 63399 if test "x${with_lcms}" = "x"; then 63400 with_lcms=${DEFAULT_LCMS} 63401 fi 63402 63403 if test "x${with_lcms}" = "xbundled"; then 63404 USE_EXTERNAL_LCMS=false 63405 { $as_echo "$as_me:${as_lineno-$LINENO}: result: bundled" >&5 63406 $as_echo "bundled" >&6; } 63407 elif test "x${with_lcms}" = "xsystem"; then 63408 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system" >&5 63409 $as_echo "system" >&6; } 63410 63411 pkg_failed=no 63412 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LCMS" >&5 63413 $as_echo_n "checking for LCMS... " >&6; } 63414 63415 if test -n "$LCMS_CFLAGS"; then 63416 pkg_cv_LCMS_CFLAGS="$LCMS_CFLAGS" 63417 elif test -n "$PKG_CONFIG"; then 63418 if test -n "$PKG_CONFIG" && \ 63419 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lcms2\""; } >&5 63420 ($PKG_CONFIG --exists --print-errors "lcms2") 2>&5 63421 ac_status=$? 63422 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 63423 test $ac_status = 0; }; then 63424 pkg_cv_LCMS_CFLAGS=`$PKG_CONFIG --cflags "lcms2" 2>/dev/null` 63425 else 63426 pkg_failed=yes 63427 fi 63428 else 63429 pkg_failed=untried 63430 fi 63431 if test -n "$LCMS_LIBS"; then 63432 pkg_cv_LCMS_LIBS="$LCMS_LIBS" 63433 elif test -n "$PKG_CONFIG"; then 63434 if test -n "$PKG_CONFIG" && \ 63435 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lcms2\""; } >&5 63436 ($PKG_CONFIG --exists --print-errors "lcms2") 2>&5 63437 ac_status=$? 63438 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 63439 test $ac_status = 0; }; then 63440 pkg_cv_LCMS_LIBS=`$PKG_CONFIG --libs "lcms2" 2>/dev/null` 63441 else 63442 pkg_failed=yes 63443 fi 63444 else 63445 pkg_failed=untried 63446 fi 63447 63448 63449 63450 if test $pkg_failed = yes; then 63451 63452 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 63453 _pkg_short_errors_supported=yes 63454 else 63455 _pkg_short_errors_supported=no 63456 fi 63457 if test $_pkg_short_errors_supported = yes; then 63458 LCMS_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lcms2" 2>&1` 63459 else 63460 LCMS_PKG_ERRORS=`$PKG_CONFIG --print-errors "lcms2" 2>&1` 63461 fi 63462 # Put the nasty error message in config.log where it belongs 63463 echo "$LCMS_PKG_ERRORS" >&5 63464 63465 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 63466 $as_echo "no" >&6; } 63467 LCMS_FOUND=no 63468 elif test $pkg_failed = untried; then 63469 LCMS_FOUND=no 63470 else 63471 LCMS_CFLAGS=$pkg_cv_LCMS_CFLAGS 63472 LCMS_LIBS=$pkg_cv_LCMS_LIBS 63473 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 63474 $as_echo "yes" >&6; } 63475 LCMS_FOUND=yes 63476 fi 63477 if test "x${LCMS_FOUND}" = "xyes"; then 63478 USE_EXTERNAL_LCMS=true 63479 else 63480 as_fn_error $? "--with-lcms=system specified, but no lcms found!" "$LINENO" 5 63481 fi 63482 else 63483 as_fn_error $? "Invalid value for --with-lcms: ${with_lcms}, use 'system' or 'bundled'" "$LINENO" 5 63484 fi 63485 63486 63487 63488 63489 63490 63491 63492 63493 63494 63495 63496 # Setup libm (the maths library) 63497 if test "x$OPENJDK_TARGET_OS" != "xwindows"; then 63498 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cos in -lm" >&5 63499 $as_echo_n "checking for cos in -lm... " >&6; } 63500 if ${ac_cv_lib_m_cos+:} false; then : 63501 $as_echo_n "(cached) " >&6 63502 else 63503 ac_check_lib_save_LIBS=$LIBS 63504 LIBS="-lm $LIBS" 63505 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 63506 /* end confdefs.h. */ 63507 63508 /* Override any GCC internal prototype to avoid an error. 63509 Use char because int might match the return type of a GCC 63510 builtin and then its argument prototype would still apply. */ 63511 #ifdef __cplusplus 63512 extern "C" 63513 #endif 63514 char cos (); 63515 int 63516 main () 63517 { 63518 return cos (); 63519 ; 63520 return 0; 63521 } 63522 _ACEOF 63523 if ac_fn_cxx_try_link "$LINENO"; then : 63524 ac_cv_lib_m_cos=yes 63525 else 63526 ac_cv_lib_m_cos=no 63527 fi 63528 rm -f core conftest.err conftest.$ac_objext \ 63529 conftest$ac_exeext conftest.$ac_ext 63530 LIBS=$ac_check_lib_save_LIBS 63531 fi 63532 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_cos" >&5 63533 $as_echo "$ac_cv_lib_m_cos" >&6; } 63534 if test "x$ac_cv_lib_m_cos" = xyes; then : 63535 cat >>confdefs.h <<_ACEOF 63536 #define HAVE_LIBM 1 63537 _ACEOF 63538 63539 LIBS="-lm $LIBS" 63540 63541 else 63542 63543 { $as_echo "$as_me:${as_lineno-$LINENO}: Maths library was not found" >&5 63544 $as_echo "$as_me: Maths library was not found" >&6;} 63545 63546 fi 63547 63548 LIBM="-lm" 63549 else 63550 LIBM="" 63551 fi 63552 63553 63554 # Setup libdl (for dynamic library loading) 63555 save_LIBS="$LIBS" 63556 LIBS="" 63557 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 63558 $as_echo_n "checking for dlopen in -ldl... " >&6; } 63559 if ${ac_cv_lib_dl_dlopen+:} false; then : 63560 $as_echo_n "(cached) " >&6 63561 else 63562 ac_check_lib_save_LIBS=$LIBS 63563 LIBS="-ldl $LIBS" 63564 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 63565 /* end confdefs.h. */ 63566 63567 /* Override any GCC internal prototype to avoid an error. 63568 Use char because int might match the return type of a GCC 63569 builtin and then its argument prototype would still apply. */ 63570 #ifdef __cplusplus 63571 extern "C" 63572 #endif 63573 char dlopen (); 63574 int 63575 main () 63576 { 63577 return dlopen (); 63578 ; 63579 return 0; 63580 } 63581 _ACEOF 63582 if ac_fn_cxx_try_link "$LINENO"; then : 63583 ac_cv_lib_dl_dlopen=yes 63584 else 63585 ac_cv_lib_dl_dlopen=no 63586 fi 63587 rm -f core conftest.err conftest.$ac_objext \ 63588 conftest$ac_exeext conftest.$ac_ext 63589 LIBS=$ac_check_lib_save_LIBS 63590 fi 63591 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 63592 $as_echo "$ac_cv_lib_dl_dlopen" >&6; } 63593 if test "x$ac_cv_lib_dl_dlopen" = xyes; then : 63594 cat >>confdefs.h <<_ACEOF 63595 #define HAVE_LIBDL 1 63596 _ACEOF 63597 63598 LIBS="-ldl $LIBS" 63599 63600 fi 63601 63602 LIBDL="$LIBS" 63603 63604 LIBS="$save_LIBS" 63605 63606 # Deprecated libraries, keep the flags for backwards compatibility 63607 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 63608 63609 63610 # Check whether --with-dxsdk was given. 63611 if test "${with_dxsdk+set}" = set; then : 63612 withval=$with_dxsdk; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk is deprecated and will be ignored." >&5 63613 $as_echo "$as_me: WARNING: Option --with-dxsdk is deprecated and will be ignored." >&2;} 63614 fi 63615 63616 63617 63618 63619 # Check whether --with-dxsdk-lib was given. 63620 if test "${with_dxsdk_lib+set}" = set; then : 63621 withval=$with_dxsdk_lib; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk-lib is deprecated and will be ignored." >&5 63622 $as_echo "$as_me: WARNING: Option --with-dxsdk-lib is deprecated and will be ignored." >&2;} 63623 fi 63624 63625 63626 63627 63628 # Check whether --with-dxsdk-include was given. 63629 if test "${with_dxsdk_include+set}" = set; then : 63630 withval=$with_dxsdk_include; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk-include is deprecated and will be ignored." >&5 63631 $as_echo "$as_me: WARNING: Option --with-dxsdk-include is deprecated and will be ignored." >&2;} 63632 fi 63633 63634 63635 fi 63636 63637 # Control if libzip can use mmap. Available for purposes of overriding. 63638 LIBZIP_CAN_USE_MMAP=true 63639 63640 63641 63642 if test "$OPENJDK_TARGET_OS" = "solaris" && test "x$BUILD_GTEST" = "xtrue"; then 63643 # Find the root of the Solaris Studio installation from the compiler path 63644 SOLARIS_STUDIO_DIR="$(dirname $CC)/.." 63645 STLPORT_LIB="$SOLARIS_STUDIO_DIR/lib/stlport4$OPENJDK_TARGET_CPU_ISADIR/libstlport.so.1" 63646 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for libstlport.so.1" >&5 63647 $as_echo_n "checking for libstlport.so.1... " >&6; } 63648 if ! test -f "$STLPORT_LIB" && test "x$OPENJDK_TARGET_CPU_ISADIR" = "x/sparcv9"; then 63649 # SS12u3 has libstlport under 'stlport4/v9' instead of 'stlport4/sparcv9' 63650 STLPORT_LIB="$SOLARIS_STUDIO_DIR/lib/stlport4/v9/libstlport.so.1" 63651 fi 63652 if test -f "$STLPORT_LIB"; then 63653 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, $STLPORT_LIB" >&5 63654 $as_echo "yes, $STLPORT_LIB" >&6; } 63655 63656 # Only process if variable expands to non-empty 63657 63658 if test "x$STLPORT_LIB" != x; then 63659 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63660 63661 # Input might be given as Windows format, start by converting to 63662 # unix format. 63663 path="$STLPORT_LIB" 63664 new_path=`$CYGPATH -u "$path"` 63665 63666 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 63667 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 63668 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 63669 # "foo.exe" is OK but "foo" is an error. 63670 # 63671 # This test is therefore slightly more accurate than "test -f" to check for file precense. 63672 # It is also a way to make sure we got the proper file name for the real test later on. 63673 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 63674 if test "x$test_shortpath" = x; then 63675 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STLPORT_LIB, which resolves as \"$path\", is invalid." >&5 63676 $as_echo "$as_me: The path of STLPORT_LIB, which resolves as \"$path\", is invalid." >&6;} 63677 as_fn_error $? "Cannot locate the the path of STLPORT_LIB" "$LINENO" 5 63678 fi 63679 63680 # Call helper function which possibly converts this using DOS-style short mode. 63681 # If so, the updated path is stored in $new_path. 63682 63683 input_path="$new_path" 63684 # Check if we need to convert this using DOS-style short mode. If the path 63685 # contains just simple characters, use it. Otherwise (spaces, weird characters), 63686 # take no chances and rewrite it. 63687 # Note: m4 eats our [], so we need to use [ and ] instead. 63688 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 63689 if test "x$has_forbidden_chars" != x; then 63690 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 63691 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 63692 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 63693 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 63694 # Going to short mode and back again did indeed matter. Since short mode is 63695 # case insensitive, let's make it lowercase to improve readability. 63696 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 63697 # Now convert it back to Unix-style (cygpath) 63698 input_path=`$CYGPATH -u "$shortmode_path"` 63699 new_path="$input_path" 63700 fi 63701 fi 63702 63703 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 63704 if test "x$test_cygdrive_prefix" = x; then 63705 # As a simple fix, exclude /usr/bin since it's not a real path. 63706 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 63707 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 63708 # a path prefixed by /cygdrive for fixpath to work. 63709 new_path="$CYGWIN_ROOT_PATH$input_path" 63710 fi 63711 fi 63712 63713 63714 if test "x$path" != "x$new_path"; then 63715 STLPORT_LIB="$new_path" 63716 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STLPORT_LIB to \"$new_path\"" >&5 63717 $as_echo "$as_me: Rewriting STLPORT_LIB to \"$new_path\"" >&6;} 63718 fi 63719 63720 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63721 63722 path="$STLPORT_LIB" 63723 has_colon=`$ECHO $path | $GREP ^.:` 63724 new_path="$path" 63725 if test "x$has_colon" = x; then 63726 # Not in mixed or Windows style, start by that. 63727 new_path=`cmd //c echo $path` 63728 fi 63729 63730 63731 input_path="$new_path" 63732 # Check if we need to convert this using DOS-style short mode. If the path 63733 # contains just simple characters, use it. Otherwise (spaces, weird characters), 63734 # take no chances and rewrite it. 63735 # Note: m4 eats our [], so we need to use [ and ] instead. 63736 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 63737 if test "x$has_forbidden_chars" != x; then 63738 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 63739 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 63740 fi 63741 63742 63743 windows_path="$new_path" 63744 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 63745 unix_path=`$CYGPATH -u "$windows_path"` 63746 new_path="$unix_path" 63747 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 63748 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 63749 new_path="$unix_path" 63750 fi 63751 63752 if test "x$path" != "x$new_path"; then 63753 STLPORT_LIB="$new_path" 63754 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STLPORT_LIB to \"$new_path\"" >&5 63755 $as_echo "$as_me: Rewriting STLPORT_LIB to \"$new_path\"" >&6;} 63756 fi 63757 63758 # Save the first 10 bytes of this path to the storage, so fixpath can work. 63759 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 63760 63761 else 63762 # We're on a unix platform. Hooray! :) 63763 path="$STLPORT_LIB" 63764 has_space=`$ECHO "$path" | $GREP " "` 63765 if test "x$has_space" != x; then 63766 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STLPORT_LIB, which resolves as \"$path\", is invalid." >&5 63767 $as_echo "$as_me: The path of STLPORT_LIB, which resolves as \"$path\", is invalid." >&6;} 63768 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 63769 fi 63770 63771 # Use eval to expand a potential ~ 63772 eval path="$path" 63773 if test ! -f "$path" && test ! -d "$path"; then 63774 as_fn_error $? "The path of STLPORT_LIB, which resolves as \"$path\", is not found." "$LINENO" 5 63775 fi 63776 63777 if test -d "$path"; then 63778 STLPORT_LIB="`cd "$path"; $THEPWDCMD -L`" 63779 else 63780 dir="`$DIRNAME "$path"`" 63781 base="`$BASENAME "$path"`" 63782 STLPORT_LIB="`cd "$dir"; $THEPWDCMD -L`/$base" 63783 fi 63784 fi 63785 fi 63786 63787 else 63788 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, not found at $STLPORT_LIB" >&5 63789 $as_echo "no, not found at $STLPORT_LIB" >&6; } 63790 as_fn_error $? "Failed to find libstlport.so.1, cannot build Hotspot gtests" "$LINENO" 5 63791 fi 63792 63793 fi 63794 63795 63796 63797 63798 63799 63800 63801 63802 63803 63804 63805 63806 63807 63808 ############################################################################### 63809 # 63810 # We need to do some final tweaking, when everything else is done. 63811 # 63812 ############################################################################### 63813 63814 63815 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if elliptic curve crypto implementation is present" >&5 63816 $as_echo_n "checking if elliptic curve crypto implementation is present... " >&6; } 63817 63818 if test -d "${SRC_ROOT}/jdk/src/jdk.crypto.ec/share/native/libsunec/impl"; then 63819 ENABLE_INTREE_EC=yes 63820 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 63821 $as_echo "yes" >&6; } 63822 else 63823 ENABLE_INTREE_EC=no 63824 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 63825 $as_echo "no" >&6; } 63826 fi 63827 63828 63829 63830 63831 # Check whether --enable-jtreg-failure-handler was given. 63832 if test "${enable_jtreg_failure_handler+set}" = set; then : 63833 enableval=$enable_jtreg_failure_handler; 63834 fi 63835 63836 63837 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if jtreg failure handler should be built" >&5 63838 $as_echo_n "checking if jtreg failure handler should be built... " >&6; } 63839 63840 if test "x$enable_jtreg_failure_handler" = "xyes"; then 63841 if test "x$JT_HOME" = "x"; then 63842 as_fn_error $? "Cannot enable jtreg failure handler without jtreg." "$LINENO" 5 63843 else 63844 BUILD_FAILURE_HANDLER=true 63845 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 63846 $as_echo "yes, forced" >&6; } 63847 fi 63848 elif test "x$enable_jtreg_failure_handler" = "xno"; then 63849 BUILD_FAILURE_HANDLER=false 63850 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 63851 $as_echo "no, forced" >&6; } 63852 elif test "x$enable_jtreg_failure_handler" = "xauto" \ 63853 || test "x$enable_jtreg_failure_handler" = "x"; then 63854 if test "x$JT_HOME" = "x"; then 63855 BUILD_FAILURE_HANDLER=false 63856 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, missing jtreg" >&5 63857 $as_echo "no, missing jtreg" >&6; } 63858 else 63859 BUILD_FAILURE_HANDLER=true 63860 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, jtreg present" >&5 63861 $as_echo "yes, jtreg present" >&6; } 63862 fi 63863 else 63864 as_fn_error $? "Invalid value for --enable-jtreg-failure-handler: $enable_jtreg_failure_handler" "$LINENO" 5 63865 fi 63866 63867 63868 63869 63870 # Check whether --enable-generate-classlist was given. 63871 if test "${enable_generate_classlist+set}" = set; then : 63872 enableval=$enable_generate_classlist; 63873 fi 63874 63875 63876 # Check if it's likely that it's possible to generate the classlist. Depending 63877 # on exact jvm configuration it could be possible anyway. 63878 if [[ " $JVM_VARIANTS " =~ " server " ]] || [[ " $JVM_VARIANTS " =~ " client " ]] ; then 63879 ENABLE_GENERATE_CLASSLIST_POSSIBLE="true" 63880 else 63881 ENABLE_GENERATE_CLASSLIST_POSSIBLE="false" 63882 fi 63883 63884 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the CDS classlist generation should be enabled" >&5 63885 $as_echo_n "checking if the CDS classlist generation should be enabled... " >&6; } 63886 if test "x$enable_generate_classlist" = "xyes"; then 63887 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, forced" >&5 63888 $as_echo "yes, forced" >&6; } 63889 ENABLE_GENERATE_CLASSLIST="true" 63890 if test "x$ENABLE_GENERATE_CLASSLIST_POSSIBLE" = "xfalse"; then 63891 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Generation of classlist might not be possible with JVM Variants $JVM_VARIANTS" >&5 63892 $as_echo "$as_me: WARNING: Generation of classlist might not be possible with JVM Variants $JVM_VARIANTS" >&2;} 63893 fi 63894 elif test "x$enable_generate_classlist" = "xno"; then 63895 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 63896 $as_echo "no, forced" >&6; } 63897 ENABLE_GENERATE_CLASSLIST="false" 63898 elif test "x$enable_generate_classlist" = "x"; then 63899 if test "x$ENABLE_GENERATE_CLASSLIST_POSSIBLE" = "xtrue"; then 63900 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 63901 $as_echo "yes" >&6; } 63902 ENABLE_GENERATE_CLASSLIST="true" 63903 else 63904 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 63905 $as_echo "no" >&6; } 63906 ENABLE_GENERATE_CLASSLIST="false" 63907 fi 63908 else 63909 as_fn_error $? "Invalid value for --enable-generate-classlist: $enable_generate_classlist" "$LINENO" 5 63910 fi 63911 63912 63913 63914 63915 ############################################################################### 63916 # 63917 # Configure parts of the build that only affect the build performance, 63918 # not the result. 63919 # 63920 ############################################################################### 63921 63922 63923 # How many cores do we have on this build system? 63924 63925 # Check whether --with-num-cores was given. 63926 if test "${with_num_cores+set}" = set; then : 63927 withval=$with_num_cores; 63928 fi 63929 63930 if test "x$with_num_cores" = x; then 63931 # The number of cores were not specified, try to probe them. 63932 63933 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for number of cores" >&5 63934 $as_echo_n "checking for number of cores... " >&6; } 63935 NUM_CORES=1 63936 FOUND_CORES=no 63937 63938 if test -f /proc/cpuinfo; then 63939 # Looks like a Linux (or cygwin) system 63940 NUM_CORES=`cat /proc/cpuinfo | grep -c processor` 63941 FOUND_CORES=yes 63942 elif test -x /usr/sbin/psrinfo; then 63943 # Looks like a Solaris system 63944 NUM_CORES=`LC_MESSAGES=C /usr/sbin/psrinfo -v | grep -c on-line` 63945 FOUND_CORES=yes 63946 elif test -x /usr/sbin/sysctl; then 63947 # Looks like a MacOSX system 63948 NUM_CORES=`/usr/sbin/sysctl -n hw.ncpu` 63949 FOUND_CORES=yes 63950 elif test "x$OPENJDK_BUILD_OS" = xaix ; then 63951 NUM_CORES=`/usr/sbin/prtconf | grep "^Number Of Processors" | awk '{ print $4 }'` 63952 FOUND_CORES=yes 63953 elif test -n "$NUMBER_OF_PROCESSORS"; then 63954 # On windows, look in the env 63955 NUM_CORES=$NUMBER_OF_PROCESSORS 63956 FOUND_CORES=yes 63957 fi 63958 63959 if test "x$FOUND_CORES" = xyes; then 63960 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NUM_CORES" >&5 63961 $as_echo "$NUM_CORES" >&6; } 63962 else 63963 { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not detect number of cores, defaulting to 1" >&5 63964 $as_echo "could not detect number of cores, defaulting to 1" >&6; } 63965 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This will disable all parallelism from build!" >&5 63966 $as_echo "$as_me: WARNING: This will disable all parallelism from build!" >&2;} 63967 fi 63968 63969 else 63970 NUM_CORES=$with_num_cores 63971 fi 63972 63973 63974 63975 # How much memory do we have on this build system? 63976 63977 # Check whether --with-memory-size was given. 63978 if test "${with_memory_size+set}" = set; then : 63979 withval=$with_memory_size; 63980 fi 63981 63982 if test "x$with_memory_size" = x; then 63983 # The memory size was not specified, try to probe it. 63984 63985 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for memory size" >&5 63986 $as_echo_n "checking for memory size... " >&6; } 63987 # Default to 1024 MB 63988 MEMORY_SIZE=1024 63989 FOUND_MEM=no 63990 63991 if test -f /proc/meminfo; then 63992 # Looks like a Linux (or cygwin) system 63993 MEMORY_SIZE=`cat /proc/meminfo | grep MemTotal | awk '{print $2}'` 63994 MEMORY_SIZE=`expr $MEMORY_SIZE / 1024` 63995 FOUND_MEM=yes 63996 elif test -x /usr/sbin/prtconf; then 63997 # Looks like a Solaris or AIX system 63998 MEMORY_SIZE=`/usr/sbin/prtconf 2> /dev/null | grep "^Memory [Ss]ize" | awk '{ print $3 }'` 63999 FOUND_MEM=yes 64000 elif test -x /usr/sbin/sysctl; then 64001 # Looks like a MacOSX system 64002 MEMORY_SIZE=`/usr/sbin/sysctl -n hw.memsize` 64003 MEMORY_SIZE=`expr $MEMORY_SIZE / 1024 / 1024` 64004 FOUND_MEM=yes 64005 elif test "x$OPENJDK_BUILD_OS" = xwindows; then 64006 # Windows, but without cygwin 64007 MEMORY_SIZE=`wmic computersystem get totalphysicalmemory -value | grep = | cut -d "=" -f 2-` 64008 MEMORY_SIZE=`expr $MEMORY_SIZE / 1024 / 1024` 64009 FOUND_MEM=yes 64010 fi 64011 64012 if test "x$FOUND_MEM" = xyes; then 64013 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MEMORY_SIZE MB" >&5 64014 $as_echo "$MEMORY_SIZE MB" >&6; } 64015 else 64016 { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not detect memory size, defaulting to $MEMORY_SIZE MB" >&5 64017 $as_echo "could not detect memory size, defaulting to $MEMORY_SIZE MB" >&6; } 64018 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This might seriously impact build performance!" >&5 64019 $as_echo "$as_me: WARNING: This might seriously impact build performance!" >&2;} 64020 fi 64021 64022 else 64023 MEMORY_SIZE=$with_memory_size 64024 fi 64025 64026 64027 64028 # Provide a decent default number of parallel jobs for make depending on 64029 # number of cores, amount of memory and machine architecture. 64030 64031 # Check whether --with-jobs was given. 64032 if test "${with_jobs+set}" = set; then : 64033 withval=$with_jobs; 64034 fi 64035 64036 if test "x$with_jobs" = x; then 64037 # Number of jobs was not specified, calculate. 64038 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for appropriate number of jobs to run in parallel" >&5 64039 $as_echo_n "checking for appropriate number of jobs to run in parallel... " >&6; } 64040 # Approximate memory in GB. 64041 memory_gb=`expr $MEMORY_SIZE / 1024` 64042 # Pick the lowest of memory in gb and number of cores. 64043 if test "$memory_gb" -lt "$NUM_CORES"; then 64044 JOBS="$memory_gb" 64045 else 64046 JOBS="$NUM_CORES" 64047 fi 64048 if test "$JOBS" -eq "0"; then 64049 JOBS=1 64050 fi 64051 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JOBS" >&5 64052 $as_echo "$JOBS" >&6; } 64053 else 64054 JOBS=$with_jobs 64055 fi 64056 64057 64058 64059 # The number of test jobs will be chosen automatically if TEST_JOBS is 0 64060 64061 # Check whether --with-test-jobs was given. 64062 if test "${with_test_jobs+set}" = set; then : 64063 withval=$with_test_jobs; 64064 fi 64065 64066 if test "x$with_test_jobs" = x; then 64067 TEST_JOBS=0 64068 else 64069 TEST_JOBS=$with_test_jobs 64070 fi 64071 64072 64073 64074 # Setup arguments for the boot jdk (after cores and memory have been setup) 64075 64076 ############################################################################## 64077 # 64078 # Specify jvm options for anything that is run with the Boot JDK. 64079 # Not all JVM:s accept the same arguments on the command line. 64080 # 64081 64082 # Check whether --with-boot-jdk-jvmargs was given. 64083 if test "${with_boot_jdk_jvmargs+set}" = set; then : 64084 withval=$with_boot_jdk_jvmargs; 64085 fi 64086 64087 64088 { $as_echo "$as_me:${as_lineno-$LINENO}: checking flags for boot jdk java command " >&5 64089 $as_echo_n "checking flags for boot jdk java command ... " >&6; } 64090 64091 # Disable special log output when a debug build is used as Boot JDK... 64092 64093 $ECHO "Check if jvm arg is ok: -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput" >&5 64094 $ECHO "Command: $JAVA -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput -version" >&5 64095 OUTPUT=`$JAVA -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput -version 2>&1` 64096 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64097 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64098 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64099 boot_jdk_jvmargs="$boot_jdk_jvmargs -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput" 64100 JVM_ARG_OK=true 64101 else 64102 $ECHO "Arg failed:" >&5 64103 $ECHO "$OUTPUT" >&5 64104 JVM_ARG_OK=false 64105 fi 64106 64107 64108 # Force en-US environment 64109 64110 $ECHO "Check if jvm arg is ok: -Duser.language=en -Duser.country=US" >&5 64111 $ECHO "Command: $JAVA -Duser.language=en -Duser.country=US -version" >&5 64112 OUTPUT=`$JAVA -Duser.language=en -Duser.country=US -version 2>&1` 64113 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64114 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64115 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64116 boot_jdk_jvmargs="$boot_jdk_jvmargs -Duser.language=en -Duser.country=US" 64117 JVM_ARG_OK=true 64118 else 64119 $ECHO "Arg failed:" >&5 64120 $ECHO "$OUTPUT" >&5 64121 JVM_ARG_OK=false 64122 fi 64123 64124 64125 # Apply user provided options. 64126 64127 $ECHO "Check if jvm arg is ok: $with_boot_jdk_jvmargs" >&5 64128 $ECHO "Command: $JAVA $with_boot_jdk_jvmargs -version" >&5 64129 OUTPUT=`$JAVA $with_boot_jdk_jvmargs -version 2>&1` 64130 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64131 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64132 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64133 boot_jdk_jvmargs="$boot_jdk_jvmargs $with_boot_jdk_jvmargs" 64134 JVM_ARG_OK=true 64135 else 64136 $ECHO "Arg failed:" >&5 64137 $ECHO "$OUTPUT" >&5 64138 JVM_ARG_OK=false 64139 fi 64140 64141 64142 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $boot_jdk_jvmargs" >&5 64143 $as_echo "$boot_jdk_jvmargs" >&6; } 64144 64145 # For now, general JAVA_FLAGS are the same as the boot jdk jvmargs 64146 JAVA_FLAGS=$boot_jdk_jvmargs 64147 64148 64149 64150 { $as_echo "$as_me:${as_lineno-$LINENO}: checking flags for boot jdk java command for big workloads" >&5 64151 $as_echo_n "checking flags for boot jdk java command for big workloads... " >&6; } 64152 64153 # Starting amount of heap memory. 64154 64155 $ECHO "Check if jvm arg is ok: -Xms64M" >&5 64156 $ECHO "Command: $JAVA -Xms64M -version" >&5 64157 OUTPUT=`$JAVA -Xms64M -version 2>&1` 64158 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64159 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64160 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64161 boot_jdk_jvmargs_big="$boot_jdk_jvmargs_big -Xms64M" 64162 JVM_ARG_OK=true 64163 else 64164 $ECHO "Arg failed:" >&5 64165 $ECHO "$OUTPUT" >&5 64166 JVM_ARG_OK=false 64167 fi 64168 64169 BOOTCYCLE_JVM_ARGS_BIG=-Xms64M 64170 64171 # Maximum amount of heap memory and stack size. 64172 JVM_HEAP_LIMIT_32="1024" 64173 # Running a 64 bit JVM allows for and requires a bigger heap 64174 JVM_HEAP_LIMIT_64="1600" 64175 STACK_SIZE_32=768 64176 STACK_SIZE_64=1536 64177 JVM_HEAP_LIMIT_GLOBAL=`expr $MEMORY_SIZE / 2` 64178 if test "$JVM_HEAP_LIMIT_GLOBAL" -lt "$JVM_HEAP_LIMIT_32"; then 64179 JVM_HEAP_LIMIT_32=$JVM_HEAP_LIMIT_GLOBAL 64180 fi 64181 if test "$JVM_HEAP_LIMIT_GLOBAL" -lt "$JVM_HEAP_LIMIT_64"; then 64182 JVM_HEAP_LIMIT_64=$JVM_HEAP_LIMIT_GLOBAL 64183 fi 64184 if test "$JVM_HEAP_LIMIT_GLOBAL" -lt "512"; then 64185 JVM_HEAP_LIMIT_32=512 64186 JVM_HEAP_LIMIT_64=512 64187 fi 64188 64189 if test "x$BOOT_JDK_BITS" = "x32"; then 64190 STACK_SIZE=$STACK_SIZE_32 64191 JVM_MAX_HEAP=$JVM_HEAP_LIMIT_32 64192 else 64193 STACK_SIZE=$STACK_SIZE_64 64194 JVM_MAX_HEAP=$JVM_HEAP_LIMIT_64 64195 fi 64196 64197 $ECHO "Check if jvm arg is ok: -Xmx${JVM_MAX_HEAP}M" >&5 64198 $ECHO "Command: $JAVA -Xmx${JVM_MAX_HEAP}M -version" >&5 64199 OUTPUT=`$JAVA -Xmx${JVM_MAX_HEAP}M -version 2>&1` 64200 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64201 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64202 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64203 boot_jdk_jvmargs_big="$boot_jdk_jvmargs_big -Xmx${JVM_MAX_HEAP}M" 64204 JVM_ARG_OK=true 64205 else 64206 $ECHO "Arg failed:" >&5 64207 $ECHO "$OUTPUT" >&5 64208 JVM_ARG_OK=false 64209 fi 64210 64211 64212 $ECHO "Check if jvm arg is ok: -XX:ThreadStackSize=$STACK_SIZE" >&5 64213 $ECHO "Command: $JAVA -XX:ThreadStackSize=$STACK_SIZE -version" >&5 64214 OUTPUT=`$JAVA -XX:ThreadStackSize=$STACK_SIZE -version 2>&1` 64215 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64216 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64217 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64218 boot_jdk_jvmargs_big="$boot_jdk_jvmargs_big -XX:ThreadStackSize=$STACK_SIZE" 64219 JVM_ARG_OK=true 64220 else 64221 $ECHO "Arg failed:" >&5 64222 $ECHO "$OUTPUT" >&5 64223 JVM_ARG_OK=false 64224 fi 64225 64226 64227 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $boot_jdk_jvmargs_big" >&5 64228 $as_echo "$boot_jdk_jvmargs_big" >&6; } 64229 64230 JAVA_FLAGS_BIG=$boot_jdk_jvmargs_big 64231 64232 64233 if test "x$OPENJDK_TARGET_CPU_BITS" = "x32"; then 64234 BOOTCYCLE_MAX_HEAP=$JVM_HEAP_LIMIT_32 64235 BOOTCYCLE_STACK_SIZE=$STACK_SIZE_32 64236 else 64237 BOOTCYCLE_MAX_HEAP=$JVM_HEAP_LIMIT_64 64238 BOOTCYCLE_STACK_SIZE=$STACK_SIZE_64 64239 fi 64240 BOOTCYCLE_JVM_ARGS_BIG="$BOOTCYCLE_JVM_ARGS_BIG -Xmx${BOOTCYCLE_MAX_HEAP}M" 64241 BOOTCYCLE_JVM_ARGS_BIG="$BOOTCYCLE_JVM_ARGS_BIG -XX:ThreadStackSize=$BOOTCYCLE_STACK_SIZE" 64242 { $as_echo "$as_me:${as_lineno-$LINENO}: checking flags for bootcycle boot jdk java command for big workloads" >&5 64243 $as_echo_n "checking flags for bootcycle boot jdk java command for big workloads... " >&6; } 64244 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOTCYCLE_JVM_ARGS_BIG" >&5 64245 $as_echo "$BOOTCYCLE_JVM_ARGS_BIG" >&6; } 64246 64247 64248 # By default, the main javac compilations use big 64249 JAVA_FLAGS_JAVAC="$JAVA_FLAGS_BIG" 64250 64251 64252 { $as_echo "$as_me:${as_lineno-$LINENO}: checking flags for boot jdk java command for small workloads" >&5 64253 $as_echo_n "checking flags for boot jdk java command for small workloads... " >&6; } 64254 64255 # Use serial gc for small short lived tools if possible 64256 64257 $ECHO "Check if jvm arg is ok: -XX:+UseSerialGC" >&5 64258 $ECHO "Command: $JAVA -XX:+UseSerialGC -version" >&5 64259 OUTPUT=`$JAVA -XX:+UseSerialGC -version 2>&1` 64260 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64261 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64262 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64263 boot_jdk_jvmargs_small="$boot_jdk_jvmargs_small -XX:+UseSerialGC" 64264 JVM_ARG_OK=true 64265 else 64266 $ECHO "Arg failed:" >&5 64267 $ECHO "$OUTPUT" >&5 64268 JVM_ARG_OK=false 64269 fi 64270 64271 64272 $ECHO "Check if jvm arg is ok: -Xms32M" >&5 64273 $ECHO "Command: $JAVA -Xms32M -version" >&5 64274 OUTPUT=`$JAVA -Xms32M -version 2>&1` 64275 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64276 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64277 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64278 boot_jdk_jvmargs_small="$boot_jdk_jvmargs_small -Xms32M" 64279 JVM_ARG_OK=true 64280 else 64281 $ECHO "Arg failed:" >&5 64282 $ECHO "$OUTPUT" >&5 64283 JVM_ARG_OK=false 64284 fi 64285 64286 64287 $ECHO "Check if jvm arg is ok: -Xmx512M" >&5 64288 $ECHO "Command: $JAVA -Xmx512M -version" >&5 64289 OUTPUT=`$JAVA -Xmx512M -version 2>&1` 64290 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64291 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64292 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64293 boot_jdk_jvmargs_small="$boot_jdk_jvmargs_small -Xmx512M" 64294 JVM_ARG_OK=true 64295 else 64296 $ECHO "Arg failed:" >&5 64297 $ECHO "$OUTPUT" >&5 64298 JVM_ARG_OK=false 64299 fi 64300 64301 64302 $ECHO "Check if jvm arg is ok: -XX:TieredStopAtLevel=1" >&5 64303 $ECHO "Command: $JAVA -XX:TieredStopAtLevel=1 -version" >&5 64304 OUTPUT=`$JAVA -XX:TieredStopAtLevel=1 -version 2>&1` 64305 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64306 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64307 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64308 boot_jdk_jvmargs_small="$boot_jdk_jvmargs_small -XX:TieredStopAtLevel=1" 64309 JVM_ARG_OK=true 64310 else 64311 $ECHO "Arg failed:" >&5 64312 $ECHO "$OUTPUT" >&5 64313 JVM_ARG_OK=false 64314 fi 64315 64316 64317 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $boot_jdk_jvmargs_small" >&5 64318 $as_echo "$boot_jdk_jvmargs_small" >&6; } 64319 64320 JAVA_FLAGS_SMALL=$boot_jdk_jvmargs_small 64321 64322 64323 JAVA_TOOL_FLAGS_SMALL="" 64324 for f in $JAVA_FLAGS_SMALL; do 64325 JAVA_TOOL_FLAGS_SMALL="$JAVA_TOOL_FLAGS_SMALL -J$f" 64326 done 64327 64328 64329 64330 # Setup smart javac (after cores and memory have been setup) 64331 64332 64333 # Check whether --with-sjavac-server-java was given. 64334 if test "${with_sjavac_server_java+set}" = set; then : 64335 withval=$with_sjavac_server_java; 64336 fi 64337 64338 64339 if test "x$with_sjavac_server_java" != x; then 64340 SJAVAC_SERVER_JAVA="$with_sjavac_server_java" 64341 FOUND_VERSION=`$SJAVAC_SERVER_JAVA -version 2>&1 | grep " version \""` 64342 if test "x$FOUND_VERSION" = x; then 64343 as_fn_error $? "Could not execute server java: $SJAVAC_SERVER_JAVA" "$LINENO" 5 64344 fi 64345 else 64346 SJAVAC_SERVER_JAVA="$JAVA" 64347 fi 64348 64349 64350 if test "$MEMORY_SIZE" -gt "3000"; then 64351 64352 $ECHO "Check if jvm arg is ok: -d64" >&5 64353 $ECHO "Command: $SJAVAC_SERVER_JAVA -d64 -version" >&5 64354 OUTPUT=`$SJAVAC_SERVER_JAVA -d64 -version 2>&1` 64355 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64356 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64357 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64358 SJAVAC_SERVER_JAVA_FLAGS="$SJAVAC_SERVER_JAVA_FLAGS -d64" 64359 JVM_ARG_OK=true 64360 else 64361 $ECHO "Arg failed:" >&5 64362 $ECHO "$OUTPUT" >&5 64363 JVM_ARG_OK=false 64364 fi 64365 64366 if test "$JVM_ARG_OK" = true; then 64367 JVM_64BIT=true 64368 JVM_ARG_OK=false 64369 fi 64370 fi 64371 64372 MX_VALUE=`expr $MEMORY_SIZE / 2` 64373 if test "$JVM_64BIT" = true; then 64374 # Set ms lower than mx since more than one instance of the server might 64375 # get launched at the same time before they figure out which instance won. 64376 MS_VALUE=512 64377 if test "$MX_VALUE" -gt "2048"; then 64378 MX_VALUE=2048 64379 fi 64380 else 64381 MS_VALUE=256 64382 if test "$MX_VALUE" -gt "1500"; then 64383 MX_VALUE=1500 64384 fi 64385 fi 64386 if test "$MX_VALUE" -lt "512"; then 64387 MX_VALUE=512 64388 fi 64389 64390 $ECHO "Check if jvm arg is ok: -Xms${MS_VALUE}M -Xmx${MX_VALUE}M" >&5 64391 $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms${MS_VALUE}M -Xmx${MX_VALUE}M -version" >&5 64392 OUTPUT=`$SJAVAC_SERVER_JAVA -Xms${MS_VALUE}M -Xmx${MX_VALUE}M -version 2>&1` 64393 FOUND_WARN=`$ECHO "$OUTPUT" | $GREP -i warn` 64394 FOUND_VERSION=`$ECHO $OUTPUT | $GREP " version \""` 64395 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 64396 SJAVAC_SERVER_JAVA_FLAGS="$SJAVAC_SERVER_JAVA_FLAGS -Xms${MS_VALUE}M -Xmx${MX_VALUE}M" 64397 JVM_ARG_OK=true 64398 else 64399 $ECHO "Arg failed:" >&5 64400 $ECHO "$OUTPUT" >&5 64401 JVM_ARG_OK=false 64402 fi 64403 64404 64405 64406 # Check whether --enable-sjavac was given. 64407 if test "${enable_sjavac+set}" = set; then : 64408 enableval=$enable_sjavac; ENABLE_SJAVAC="${enableval}" 64409 else 64410 ENABLE_SJAVAC="no" 64411 fi 64412 64413 if test "x$JVM_ARG_OK" = "xfalse"; then 64414 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Could not set -Xms${MS_VALUE}M -Xmx${MX_VALUE}M, disabling sjavac" >&5 64415 $as_echo "$as_me: WARNING: Could not set -Xms${MS_VALUE}M -Xmx${MX_VALUE}M, disabling sjavac" >&2;} 64416 ENABLE_SJAVAC="no" 64417 fi 64418 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use sjavac" >&5 64419 $as_echo_n "checking whether to use sjavac... " >&6; } 64420 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ENABLE_SJAVAC" >&5 64421 $as_echo "$ENABLE_SJAVAC" >&6; } 64422 64423 64424 # Check whether --enable-javac-server was given. 64425 if test "${enable_javac_server+set}" = set; then : 64426 enableval=$enable_javac_server; ENABLE_JAVAC_SERVER="${enableval}" 64427 else 64428 ENABLE_JAVAC_SERVER="yes" 64429 fi 64430 64431 if test "x$JVM_ARG_OK" = "xfalse"; then 64432 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Could not set -Xms${MS_VALUE}M -Xmx${MX_VALUE}M, disabling javac server" >&5 64433 $as_echo "$as_me: WARNING: Could not set -Xms${MS_VALUE}M -Xmx${MX_VALUE}M, disabling javac server" >&2;} 64434 ENABLE_JAVAC_SERVER="no" 64435 fi 64436 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use javac server" >&5 64437 $as_echo_n "checking whether to use javac server... " >&6; } 64438 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ENABLE_JAVAC_SERVER" >&5 64439 $as_echo "$ENABLE_JAVAC_SERVER" >&6; } 64440 64441 64442 if test "x$ENABLE_JAVAC_SERVER" = "xyes" || test "x$ENABLE_SJAVAC" = "xyes"; then 64443 # When using a server javac, the small client instances do not need much 64444 # resources. 64445 JAVA_FLAGS_JAVAC="$JAVA_FLAGS_SMALL" 64446 fi 64447 64448 64449 # Setup use of icecc if requested 64450 64451 # Check whether --enable-icecc was given. 64452 if test "${enable_icecc+set}" = set; then : 64453 enableval=$enable_icecc; 64454 fi 64455 64456 64457 if test "x${enable_icecc}" = "xyes"; then 64458 64459 64460 64461 # Publish this variable in the help. 64462 64463 64464 if [ -z "${ICECC_CMD+x}" ]; then 64465 # The variable is not set by user, try to locate tool using the code snippet 64466 for ac_prog in icecc 64467 do 64468 # Extract the first word of "$ac_prog", so it can be a program name with args. 64469 set dummy $ac_prog; ac_word=$2 64470 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 64471 $as_echo_n "checking for $ac_word... " >&6; } 64472 if ${ac_cv_path_ICECC_CMD+:} false; then : 64473 $as_echo_n "(cached) " >&6 64474 else 64475 case $ICECC_CMD in 64476 [\\/]* | ?:[\\/]*) 64477 ac_cv_path_ICECC_CMD="$ICECC_CMD" # Let the user override the test with a path. 64478 ;; 64479 *) 64480 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 64481 for as_dir in $PATH 64482 do 64483 IFS=$as_save_IFS 64484 test -z "$as_dir" && as_dir=. 64485 for ac_exec_ext in '' $ac_executable_extensions; do 64486 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 64487 ac_cv_path_ICECC_CMD="$as_dir/$ac_word$ac_exec_ext" 64488 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 64489 break 2 64490 fi 64491 done 64492 done 64493 IFS=$as_save_IFS 64494 64495 ;; 64496 esac 64497 fi 64498 ICECC_CMD=$ac_cv_path_ICECC_CMD 64499 if test -n "$ICECC_CMD"; then 64500 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CMD" >&5 64501 $as_echo "$ICECC_CMD" >&6; } 64502 else 64503 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 64504 $as_echo "no" >&6; } 64505 fi 64506 64507 64508 test -n "$ICECC_CMD" && break 64509 done 64510 64511 else 64512 # The variable is set, but is it from the command line or the environment? 64513 64514 # Try to remove the string !ICECC_CMD! from our list. 64515 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ICECC_CMD!/} 64516 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 64517 # If it failed, the variable was not from the command line. Ignore it, 64518 # but warn the user (except for BASH, which is always set by the calling BASH). 64519 if test "xICECC_CMD" != xBASH; then 64520 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ICECC_CMD from the environment. Use command line variables instead." >&5 64521 $as_echo "$as_me: WARNING: Ignoring value of ICECC_CMD from the environment. Use command line variables instead." >&2;} 64522 fi 64523 # Try to locate tool using the code snippet 64524 for ac_prog in icecc 64525 do 64526 # Extract the first word of "$ac_prog", so it can be a program name with args. 64527 set dummy $ac_prog; ac_word=$2 64528 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 64529 $as_echo_n "checking for $ac_word... " >&6; } 64530 if ${ac_cv_path_ICECC_CMD+:} false; then : 64531 $as_echo_n "(cached) " >&6 64532 else 64533 case $ICECC_CMD in 64534 [\\/]* | ?:[\\/]*) 64535 ac_cv_path_ICECC_CMD="$ICECC_CMD" # Let the user override the test with a path. 64536 ;; 64537 *) 64538 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 64539 for as_dir in $PATH 64540 do 64541 IFS=$as_save_IFS 64542 test -z "$as_dir" && as_dir=. 64543 for ac_exec_ext in '' $ac_executable_extensions; do 64544 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 64545 ac_cv_path_ICECC_CMD="$as_dir/$ac_word$ac_exec_ext" 64546 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 64547 break 2 64548 fi 64549 done 64550 done 64551 IFS=$as_save_IFS 64552 64553 ;; 64554 esac 64555 fi 64556 ICECC_CMD=$ac_cv_path_ICECC_CMD 64557 if test -n "$ICECC_CMD"; then 64558 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CMD" >&5 64559 $as_echo "$ICECC_CMD" >&6; } 64560 else 64561 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 64562 $as_echo "no" >&6; } 64563 fi 64564 64565 64566 test -n "$ICECC_CMD" && break 64567 done 64568 64569 else 64570 # If it succeeded, then it was overridden by the user. We will use it 64571 # for the tool. 64572 64573 # First remove it from the list of overridden variables, so we can test 64574 # for unknown variables in the end. 64575 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 64576 64577 # Check if we try to supply an empty value 64578 if test "x$ICECC_CMD" = x; then 64579 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ICECC_CMD= (no value)" >&5 64580 $as_echo "$as_me: Setting user supplied tool ICECC_CMD= (no value)" >&6;} 64581 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_CMD" >&5 64582 $as_echo_n "checking for ICECC_CMD... " >&6; } 64583 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 64584 $as_echo "disabled" >&6; } 64585 else 64586 # Check if the provided tool contains a complete path. 64587 tool_specified="$ICECC_CMD" 64588 tool_basename="${tool_specified##*/}" 64589 if test "x$tool_basename" = "x$tool_specified"; then 64590 # A command without a complete path is provided, search $PATH. 64591 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ICECC_CMD=$tool_basename" >&5 64592 $as_echo "$as_me: Will search for user supplied tool ICECC_CMD=$tool_basename" >&6;} 64593 # Extract the first word of "$tool_basename", so it can be a program name with args. 64594 set dummy $tool_basename; ac_word=$2 64595 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 64596 $as_echo_n "checking for $ac_word... " >&6; } 64597 if ${ac_cv_path_ICECC_CMD+:} false; then : 64598 $as_echo_n "(cached) " >&6 64599 else 64600 case $ICECC_CMD in 64601 [\\/]* | ?:[\\/]*) 64602 ac_cv_path_ICECC_CMD="$ICECC_CMD" # Let the user override the test with a path. 64603 ;; 64604 *) 64605 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 64606 for as_dir in $PATH 64607 do 64608 IFS=$as_save_IFS 64609 test -z "$as_dir" && as_dir=. 64610 for ac_exec_ext in '' $ac_executable_extensions; do 64611 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 64612 ac_cv_path_ICECC_CMD="$as_dir/$ac_word$ac_exec_ext" 64613 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 64614 break 2 64615 fi 64616 done 64617 done 64618 IFS=$as_save_IFS 64619 64620 ;; 64621 esac 64622 fi 64623 ICECC_CMD=$ac_cv_path_ICECC_CMD 64624 if test -n "$ICECC_CMD"; then 64625 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CMD" >&5 64626 $as_echo "$ICECC_CMD" >&6; } 64627 else 64628 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 64629 $as_echo "no" >&6; } 64630 fi 64631 64632 64633 if test "x$ICECC_CMD" = x; then 64634 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 64635 fi 64636 else 64637 # Otherwise we believe it is a complete path. Use it as it is. 64638 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ICECC_CMD=$tool_specified" >&5 64639 $as_echo "$as_me: Will use user supplied tool ICECC_CMD=$tool_specified" >&6;} 64640 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_CMD" >&5 64641 $as_echo_n "checking for ICECC_CMD... " >&6; } 64642 if test ! -x "$tool_specified"; then 64643 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 64644 $as_echo "not found" >&6; } 64645 as_fn_error $? "User supplied tool ICECC_CMD=$tool_specified does not exist or is not executable" "$LINENO" 5 64646 fi 64647 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 64648 $as_echo "$tool_specified" >&6; } 64649 fi 64650 fi 64651 fi 64652 64653 fi 64654 64655 64656 64657 if test "x$ICECC_CMD" = x; then 64658 as_fn_error $? "Could not find required tool for ICECC_CMD" "$LINENO" 5 64659 fi 64660 64661 64662 old_path="$PATH" 64663 64664 # Look for icecc-create-env in some known places 64665 PATH="$PATH:/usr/lib/icecc:/usr/lib64/icecc" 64666 64667 64668 64669 # Publish this variable in the help. 64670 64671 64672 if [ -z "${ICECC_CREATE_ENV+x}" ]; then 64673 # The variable is not set by user, try to locate tool using the code snippet 64674 for ac_prog in icecc-create-env 64675 do 64676 # Extract the first word of "$ac_prog", so it can be a program name with args. 64677 set dummy $ac_prog; ac_word=$2 64678 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 64679 $as_echo_n "checking for $ac_word... " >&6; } 64680 if ${ac_cv_path_ICECC_CREATE_ENV+:} false; then : 64681 $as_echo_n "(cached) " >&6 64682 else 64683 case $ICECC_CREATE_ENV in 64684 [\\/]* | ?:[\\/]*) 64685 ac_cv_path_ICECC_CREATE_ENV="$ICECC_CREATE_ENV" # Let the user override the test with a path. 64686 ;; 64687 *) 64688 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 64689 for as_dir in $PATH 64690 do 64691 IFS=$as_save_IFS 64692 test -z "$as_dir" && as_dir=. 64693 for ac_exec_ext in '' $ac_executable_extensions; do 64694 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 64695 ac_cv_path_ICECC_CREATE_ENV="$as_dir/$ac_word$ac_exec_ext" 64696 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 64697 break 2 64698 fi 64699 done 64700 done 64701 IFS=$as_save_IFS 64702 64703 ;; 64704 esac 64705 fi 64706 ICECC_CREATE_ENV=$ac_cv_path_ICECC_CREATE_ENV 64707 if test -n "$ICECC_CREATE_ENV"; then 64708 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CREATE_ENV" >&5 64709 $as_echo "$ICECC_CREATE_ENV" >&6; } 64710 else 64711 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 64712 $as_echo "no" >&6; } 64713 fi 64714 64715 64716 test -n "$ICECC_CREATE_ENV" && break 64717 done 64718 64719 else 64720 # The variable is set, but is it from the command line or the environment? 64721 64722 # Try to remove the string !ICECC_CREATE_ENV! from our list. 64723 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ICECC_CREATE_ENV!/} 64724 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 64725 # If it failed, the variable was not from the command line. Ignore it, 64726 # but warn the user (except for BASH, which is always set by the calling BASH). 64727 if test "xICECC_CREATE_ENV" != xBASH; then 64728 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ICECC_CREATE_ENV from the environment. Use command line variables instead." >&5 64729 $as_echo "$as_me: WARNING: Ignoring value of ICECC_CREATE_ENV from the environment. Use command line variables instead." >&2;} 64730 fi 64731 # Try to locate tool using the code snippet 64732 for ac_prog in icecc-create-env 64733 do 64734 # Extract the first word of "$ac_prog", so it can be a program name with args. 64735 set dummy $ac_prog; ac_word=$2 64736 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 64737 $as_echo_n "checking for $ac_word... " >&6; } 64738 if ${ac_cv_path_ICECC_CREATE_ENV+:} false; then : 64739 $as_echo_n "(cached) " >&6 64740 else 64741 case $ICECC_CREATE_ENV in 64742 [\\/]* | ?:[\\/]*) 64743 ac_cv_path_ICECC_CREATE_ENV="$ICECC_CREATE_ENV" # Let the user override the test with a path. 64744 ;; 64745 *) 64746 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 64747 for as_dir in $PATH 64748 do 64749 IFS=$as_save_IFS 64750 test -z "$as_dir" && as_dir=. 64751 for ac_exec_ext in '' $ac_executable_extensions; do 64752 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 64753 ac_cv_path_ICECC_CREATE_ENV="$as_dir/$ac_word$ac_exec_ext" 64754 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 64755 break 2 64756 fi 64757 done 64758 done 64759 IFS=$as_save_IFS 64760 64761 ;; 64762 esac 64763 fi 64764 ICECC_CREATE_ENV=$ac_cv_path_ICECC_CREATE_ENV 64765 if test -n "$ICECC_CREATE_ENV"; then 64766 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CREATE_ENV" >&5 64767 $as_echo "$ICECC_CREATE_ENV" >&6; } 64768 else 64769 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 64770 $as_echo "no" >&6; } 64771 fi 64772 64773 64774 test -n "$ICECC_CREATE_ENV" && break 64775 done 64776 64777 else 64778 # If it succeeded, then it was overridden by the user. We will use it 64779 # for the tool. 64780 64781 # First remove it from the list of overridden variables, so we can test 64782 # for unknown variables in the end. 64783 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 64784 64785 # Check if we try to supply an empty value 64786 if test "x$ICECC_CREATE_ENV" = x; then 64787 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ICECC_CREATE_ENV= (no value)" >&5 64788 $as_echo "$as_me: Setting user supplied tool ICECC_CREATE_ENV= (no value)" >&6;} 64789 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_CREATE_ENV" >&5 64790 $as_echo_n "checking for ICECC_CREATE_ENV... " >&6; } 64791 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 64792 $as_echo "disabled" >&6; } 64793 else 64794 # Check if the provided tool contains a complete path. 64795 tool_specified="$ICECC_CREATE_ENV" 64796 tool_basename="${tool_specified##*/}" 64797 if test "x$tool_basename" = "x$tool_specified"; then 64798 # A command without a complete path is provided, search $PATH. 64799 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ICECC_CREATE_ENV=$tool_basename" >&5 64800 $as_echo "$as_me: Will search for user supplied tool ICECC_CREATE_ENV=$tool_basename" >&6;} 64801 # Extract the first word of "$tool_basename", so it can be a program name with args. 64802 set dummy $tool_basename; ac_word=$2 64803 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 64804 $as_echo_n "checking for $ac_word... " >&6; } 64805 if ${ac_cv_path_ICECC_CREATE_ENV+:} false; then : 64806 $as_echo_n "(cached) " >&6 64807 else 64808 case $ICECC_CREATE_ENV in 64809 [\\/]* | ?:[\\/]*) 64810 ac_cv_path_ICECC_CREATE_ENV="$ICECC_CREATE_ENV" # Let the user override the test with a path. 64811 ;; 64812 *) 64813 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 64814 for as_dir in $PATH 64815 do 64816 IFS=$as_save_IFS 64817 test -z "$as_dir" && as_dir=. 64818 for ac_exec_ext in '' $ac_executable_extensions; do 64819 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 64820 ac_cv_path_ICECC_CREATE_ENV="$as_dir/$ac_word$ac_exec_ext" 64821 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 64822 break 2 64823 fi 64824 done 64825 done 64826 IFS=$as_save_IFS 64827 64828 ;; 64829 esac 64830 fi 64831 ICECC_CREATE_ENV=$ac_cv_path_ICECC_CREATE_ENV 64832 if test -n "$ICECC_CREATE_ENV"; then 64833 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CREATE_ENV" >&5 64834 $as_echo "$ICECC_CREATE_ENV" >&6; } 64835 else 64836 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 64837 $as_echo "no" >&6; } 64838 fi 64839 64840 64841 if test "x$ICECC_CREATE_ENV" = x; then 64842 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 64843 fi 64844 else 64845 # Otherwise we believe it is a complete path. Use it as it is. 64846 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ICECC_CREATE_ENV=$tool_specified" >&5 64847 $as_echo "$as_me: Will use user supplied tool ICECC_CREATE_ENV=$tool_specified" >&6;} 64848 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_CREATE_ENV" >&5 64849 $as_echo_n "checking for ICECC_CREATE_ENV... " >&6; } 64850 if test ! -x "$tool_specified"; then 64851 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 64852 $as_echo "not found" >&6; } 64853 as_fn_error $? "User supplied tool ICECC_CREATE_ENV=$tool_specified does not exist or is not executable" "$LINENO" 5 64854 fi 64855 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 64856 $as_echo "$tool_specified" >&6; } 64857 fi 64858 fi 64859 fi 64860 64861 fi 64862 64863 64864 64865 if test "x$ICECC_CREATE_ENV" = x; then 64866 as_fn_error $? "Could not find required tool for ICECC_CREATE_ENV" "$LINENO" 5 64867 fi 64868 64869 64870 # Use icecc-create-env to create a minimal compilation environment that can 64871 # be sent to the other hosts in the icecream cluster. 64872 icecc_create_env_log="${CONFIGURESUPPORT_OUTPUTDIR}/icecc/icecc_create_env.log" 64873 ${MKDIR} -p ${CONFIGURESUPPORT_OUTPUTDIR}/icecc 64874 # Older versions of icecc does not have the --gcc parameter 64875 if ${ICECC_CREATE_ENV} | $GREP -q -e --gcc; then 64876 icecc_gcc_arg="--gcc" 64877 fi 64878 if test "x${TOOLCHAIN_TYPE}" = "xgcc"; then 64879 64880 ( cd ${CONFIGURESUPPORT_OUTPUTDIR}/icecc \ 64881 && ${ICECC_CREATE_ENV} ${icecc_gcc_arg} ${CC} ${CXX} > \ 64882 ${icecc_create_env_log} 2>&1 ) 64883 if test "$?" != "0"; then 64884 { $as_echo "$as_me:${as_lineno-$LINENO}: icecc-create-env output:" >&5 64885 $as_echo "$as_me: icecc-create-env output:" >&6;} 64886 cat \ 64887 ${icecc_create_env_log} 64888 as_fn_error $? "Failed to create icecc compiler environment" "$LINENO" 5 64889 fi 64890 64891 elif test "x$TOOLCHAIN_TYPE" = "xclang"; then 64892 # For clang, the icecc compilerwrapper is needed. It usually resides next 64893 # to icecc-create-env. 64894 64895 64896 64897 # Publish this variable in the help. 64898 64899 64900 if [ -z "${ICECC_WRAPPER+x}" ]; then 64901 # The variable is not set by user, try to locate tool using the code snippet 64902 for ac_prog in compilerwrapper 64903 do 64904 # Extract the first word of "$ac_prog", so it can be a program name with args. 64905 set dummy $ac_prog; ac_word=$2 64906 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 64907 $as_echo_n "checking for $ac_word... " >&6; } 64908 if ${ac_cv_path_ICECC_WRAPPER+:} false; then : 64909 $as_echo_n "(cached) " >&6 64910 else 64911 case $ICECC_WRAPPER in 64912 [\\/]* | ?:[\\/]*) 64913 ac_cv_path_ICECC_WRAPPER="$ICECC_WRAPPER" # Let the user override the test with a path. 64914 ;; 64915 *) 64916 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 64917 for as_dir in $PATH 64918 do 64919 IFS=$as_save_IFS 64920 test -z "$as_dir" && as_dir=. 64921 for ac_exec_ext in '' $ac_executable_extensions; do 64922 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 64923 ac_cv_path_ICECC_WRAPPER="$as_dir/$ac_word$ac_exec_ext" 64924 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 64925 break 2 64926 fi 64927 done 64928 done 64929 IFS=$as_save_IFS 64930 64931 ;; 64932 esac 64933 fi 64934 ICECC_WRAPPER=$ac_cv_path_ICECC_WRAPPER 64935 if test -n "$ICECC_WRAPPER"; then 64936 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_WRAPPER" >&5 64937 $as_echo "$ICECC_WRAPPER" >&6; } 64938 else 64939 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 64940 $as_echo "no" >&6; } 64941 fi 64942 64943 64944 test -n "$ICECC_WRAPPER" && break 64945 done 64946 64947 else 64948 # The variable is set, but is it from the command line or the environment? 64949 64950 # Try to remove the string !ICECC_WRAPPER! from our list. 64951 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ICECC_WRAPPER!/} 64952 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 64953 # If it failed, the variable was not from the command line. Ignore it, 64954 # but warn the user (except for BASH, which is always set by the calling BASH). 64955 if test "xICECC_WRAPPER" != xBASH; then 64956 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ICECC_WRAPPER from the environment. Use command line variables instead." >&5 64957 $as_echo "$as_me: WARNING: Ignoring value of ICECC_WRAPPER from the environment. Use command line variables instead." >&2;} 64958 fi 64959 # Try to locate tool using the code snippet 64960 for ac_prog in compilerwrapper 64961 do 64962 # Extract the first word of "$ac_prog", so it can be a program name with args. 64963 set dummy $ac_prog; ac_word=$2 64964 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 64965 $as_echo_n "checking for $ac_word... " >&6; } 64966 if ${ac_cv_path_ICECC_WRAPPER+:} false; then : 64967 $as_echo_n "(cached) " >&6 64968 else 64969 case $ICECC_WRAPPER in 64970 [\\/]* | ?:[\\/]*) 64971 ac_cv_path_ICECC_WRAPPER="$ICECC_WRAPPER" # Let the user override the test with a path. 64972 ;; 64973 *) 64974 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 64975 for as_dir in $PATH 64976 do 64977 IFS=$as_save_IFS 64978 test -z "$as_dir" && as_dir=. 64979 for ac_exec_ext in '' $ac_executable_extensions; do 64980 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 64981 ac_cv_path_ICECC_WRAPPER="$as_dir/$ac_word$ac_exec_ext" 64982 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 64983 break 2 64984 fi 64985 done 64986 done 64987 IFS=$as_save_IFS 64988 64989 ;; 64990 esac 64991 fi 64992 ICECC_WRAPPER=$ac_cv_path_ICECC_WRAPPER 64993 if test -n "$ICECC_WRAPPER"; then 64994 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_WRAPPER" >&5 64995 $as_echo "$ICECC_WRAPPER" >&6; } 64996 else 64997 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 64998 $as_echo "no" >&6; } 64999 fi 65000 65001 65002 test -n "$ICECC_WRAPPER" && break 65003 done 65004 65005 else 65006 # If it succeeded, then it was overridden by the user. We will use it 65007 # for the tool. 65008 65009 # First remove it from the list of overridden variables, so we can test 65010 # for unknown variables in the end. 65011 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 65012 65013 # Check if we try to supply an empty value 65014 if test "x$ICECC_WRAPPER" = x; then 65015 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ICECC_WRAPPER= (no value)" >&5 65016 $as_echo "$as_me: Setting user supplied tool ICECC_WRAPPER= (no value)" >&6;} 65017 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_WRAPPER" >&5 65018 $as_echo_n "checking for ICECC_WRAPPER... " >&6; } 65019 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 65020 $as_echo "disabled" >&6; } 65021 else 65022 # Check if the provided tool contains a complete path. 65023 tool_specified="$ICECC_WRAPPER" 65024 tool_basename="${tool_specified##*/}" 65025 if test "x$tool_basename" = "x$tool_specified"; then 65026 # A command without a complete path is provided, search $PATH. 65027 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ICECC_WRAPPER=$tool_basename" >&5 65028 $as_echo "$as_me: Will search for user supplied tool ICECC_WRAPPER=$tool_basename" >&6;} 65029 # Extract the first word of "$tool_basename", so it can be a program name with args. 65030 set dummy $tool_basename; ac_word=$2 65031 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 65032 $as_echo_n "checking for $ac_word... " >&6; } 65033 if ${ac_cv_path_ICECC_WRAPPER+:} false; then : 65034 $as_echo_n "(cached) " >&6 65035 else 65036 case $ICECC_WRAPPER in 65037 [\\/]* | ?:[\\/]*) 65038 ac_cv_path_ICECC_WRAPPER="$ICECC_WRAPPER" # Let the user override the test with a path. 65039 ;; 65040 *) 65041 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 65042 for as_dir in $PATH 65043 do 65044 IFS=$as_save_IFS 65045 test -z "$as_dir" && as_dir=. 65046 for ac_exec_ext in '' $ac_executable_extensions; do 65047 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 65048 ac_cv_path_ICECC_WRAPPER="$as_dir/$ac_word$ac_exec_ext" 65049 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 65050 break 2 65051 fi 65052 done 65053 done 65054 IFS=$as_save_IFS 65055 65056 ;; 65057 esac 65058 fi 65059 ICECC_WRAPPER=$ac_cv_path_ICECC_WRAPPER 65060 if test -n "$ICECC_WRAPPER"; then 65061 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_WRAPPER" >&5 65062 $as_echo "$ICECC_WRAPPER" >&6; } 65063 else 65064 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65065 $as_echo "no" >&6; } 65066 fi 65067 65068 65069 if test "x$ICECC_WRAPPER" = x; then 65070 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 65071 fi 65072 else 65073 # Otherwise we believe it is a complete path. Use it as it is. 65074 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ICECC_WRAPPER=$tool_specified" >&5 65075 $as_echo "$as_me: Will use user supplied tool ICECC_WRAPPER=$tool_specified" >&6;} 65076 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_WRAPPER" >&5 65077 $as_echo_n "checking for ICECC_WRAPPER... " >&6; } 65078 if test ! -x "$tool_specified"; then 65079 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 65080 $as_echo "not found" >&6; } 65081 as_fn_error $? "User supplied tool ICECC_WRAPPER=$tool_specified does not exist or is not executable" "$LINENO" 5 65082 fi 65083 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 65084 $as_echo "$tool_specified" >&6; } 65085 fi 65086 fi 65087 fi 65088 65089 fi 65090 65091 65092 65093 if test "x$ICECC_WRAPPER" = x; then 65094 as_fn_error $? "Could not find required tool for ICECC_WRAPPER" "$LINENO" 5 65095 fi 65096 65097 65098 65099 ( cd ${CONFIGURESUPPORT_OUTPUTDIR}/icecc \ 65100 && ${ICECC_CREATE_ENV} --clang ${CC} ${ICECC_WRAPPER} > ${icecc_create_env_log} 2>&1 ) 65101 if test "$?" != "0"; then 65102 { $as_echo "$as_me:${as_lineno-$LINENO}: icecc-create-env output:" >&5 65103 $as_echo "$as_me: icecc-create-env output:" >&6;} 65104 cat ${icecc_create_env_log} 65105 as_fn_error $? "Failed to create icecc compiler environment" "$LINENO" 5 65106 fi 65107 65108 else 65109 as_fn_error $? "Can only create icecc compiler packages for toolchain types gcc and clang" "$LINENO" 5 65110 fi 65111 PATH="$old_path" 65112 # The bundle with the compiler gets a name based on checksums. Parse log file 65113 # to find it. 65114 ICECC_ENV_BUNDLE_BASENAME="`${SED} -n '/^creating/s/creating //p' ${icecc_create_env_log}`" 65115 ICECC_ENV_BUNDLE="${CONFIGURESUPPORT_OUTPUTDIR}/icecc/${ICECC_ENV_BUNDLE_BASENAME}" 65116 if test ! -f ${ICECC_ENV_BUNDLE}; then 65117 as_fn_error $? "icecc-create-env did not produce an environment ${ICECC_ENV_BUNDLE}" "$LINENO" 5 65118 fi 65119 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for icecc build environment for target compiler" >&5 65120 $as_echo_n "checking for icecc build environment for target compiler... " >&6; } 65121 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${ICECC_ENV_BUNDLE}" >&5 65122 $as_echo "${ICECC_ENV_BUNDLE}" >&6; } 65123 ICECC="ICECC_VERSION=${ICECC_ENV_BUNDLE} ICECC_CC=${CC} ICECC_CXX=${CXX} ${ICECC_CMD}" 65124 65125 if test "x${COMPILE_TYPE}" = "xcross"; then 65126 # If cross compiling, create a separate env package for the build compiler 65127 # Assume "gcc" or "cc" is gcc and "clang" is clang. Otherwise bail. 65128 icecc_create_env_log_build="${CONFIGURESUPPORT_OUTPUTDIR}/icecc/icecc_create_env_build.log" 65129 if test "x${BUILD_CC##*/}" = "xgcc" || test "x${BUILD_CC##*/}" = "xcc"; then 65130 65131 ( cd ${CONFIGURESUPPORT_OUTPUTDIR}/icecc \ 65132 && ${ICECC_CREATE_ENV} ${icecc_gcc_arg} ${BUILD_CC} ${BUILD_CXX} > \ 65133 ${icecc_create_env_log_build} 2>&1 ) 65134 if test "$?" != "0"; then 65135 { $as_echo "$as_me:${as_lineno-$LINENO}: icecc-create-env output:" >&5 65136 $as_echo "$as_me: icecc-create-env output:" >&6;} 65137 cat \ 65138 ${icecc_create_env_log_build} 65139 as_fn_error $? "Failed to create icecc compiler environment" "$LINENO" 5 65140 fi 65141 65142 elif test "x${BUILD_CC##*/}" = "xclang"; then 65143 65144 ( cd ${CONFIGURESUPPORT_OUTPUTDIR}/icecc \ 65145 && ${ICECC_CREATE_ENV} --clang ${BUILD_CC} ${ICECC_WRAPPER} > ${icecc_create_env_log_build} 2>&1 ) 65146 if test "$?" != "0"; then 65147 { $as_echo "$as_me:${as_lineno-$LINENO}: icecc-create-env output:" >&5 65148 $as_echo "$as_me: icecc-create-env output:" >&6;} 65149 cat ${icecc_create_env_log_build} 65150 as_fn_error $? "Failed to create icecc compiler environment" "$LINENO" 5 65151 fi 65152 65153 else 65154 as_fn_error $? "Cannot create icecc compiler package for ${BUILD_CC}" "$LINENO" 5 65155 fi 65156 ICECC_ENV_BUNDLE_BASENAME="`${SED} -n '/^creating/s/creating //p' ${icecc_create_env_log_build}`" 65157 ICECC_ENV_BUNDLE="${CONFIGURESUPPORT_OUTPUTDIR}/icecc/${ICECC_ENV_BUNDLE_BASENAME}" 65158 if test ! -f ${ICECC_ENV_BUNDLE}; then 65159 as_fn_error $? "icecc-create-env did not produce an environment ${ICECC_ENV_BUNDLE}" "$LINENO" 5 65160 fi 65161 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for icecc build environment for build compiler" >&5 65162 $as_echo_n "checking for icecc build environment for build compiler... " >&6; } 65163 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${ICECC_ENV_BUNDLE}" >&5 65164 $as_echo "${ICECC_ENV_BUNDLE}" >&6; } 65165 BUILD_ICECC="ICECC_VERSION=${ICECC_ENV_BUNDLE} ICECC_CC=${BUILD_CC} \ 65166 ICECC_CXX=${BUILD_CXX} ${ICECC_CMD}" 65167 else 65168 BUILD_ICECC="${ICECC}" 65169 fi 65170 65171 65172 fi 65173 65174 65175 # Can the C/C++ compiler use precompiled headers? 65176 65177 65178 ############################################################################### 65179 # 65180 # Can the C/C++ compiler use precompiled headers? 65181 # 65182 # Check whether --enable-precompiled-headers was given. 65183 if test "${enable_precompiled_headers+set}" = set; then : 65184 enableval=$enable_precompiled_headers; ENABLE_PRECOMPH=${enable_precompiled_headers} 65185 else 65186 ENABLE_PRECOMPH=yes 65187 fi 65188 65189 65190 USE_PRECOMPILED_HEADER=1 65191 { $as_echo "$as_me:${as_lineno-$LINENO}: checking If precompiled header is enabled" >&5 65192 $as_echo_n "checking If precompiled header is enabled... " >&6; } 65193 if test "x$ENABLE_PRECOMPH" = xno; then 65194 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 65195 $as_echo "no, forced" >&6; } 65196 USE_PRECOMPILED_HEADER=0 65197 elif test "x$ICECC" != "x"; then 65198 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, does not work effectively with icecc" >&5 65199 $as_echo "no, does not work effectively with icecc" >&6; } 65200 USE_PRECOMPILED_HEADER=0 65201 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 65202 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, does not work with Solaris Studio" >&5 65203 $as_echo "no, does not work with Solaris Studio" >&6; } 65204 USE_PRECOMPILED_HEADER=0 65205 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 65206 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, does not work with xlc" >&5 65207 $as_echo "no, does not work with xlc" >&6; } 65208 USE_PRECOMPILED_HEADER=0 65209 else 65210 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 65211 $as_echo "yes" >&6; } 65212 fi 65213 65214 if test "x$ENABLE_PRECOMPH" = xyes; then 65215 # Check that the compiler actually supports precomp headers. 65216 if test "x$TOOLCHAIN_TYPE" = xgcc; then 65217 { $as_echo "$as_me:${as_lineno-$LINENO}: checking that precompiled headers work" >&5 65218 $as_echo_n "checking that precompiled headers work... " >&6; } 65219 echo "int alfa();" > conftest.h 65220 $CXX -x c++-header conftest.h -o conftest.hpp.gch 2>&5 >&5 65221 if test ! -f conftest.hpp.gch; then 65222 USE_PRECOMPILED_HEADER=0 65223 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65224 $as_echo "no" >&6; } 65225 else 65226 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 65227 $as_echo "yes" >&6; } 65228 fi 65229 $RM conftest.h conftest.hpp.gch 65230 fi 65231 fi 65232 65233 65234 65235 65236 # Setup use of ccache, if available 65237 65238 # Check whether --enable-ccache was given. 65239 if test "${enable_ccache+set}" = set; then : 65240 enableval=$enable_ccache; 65241 fi 65242 65243 65244 CCACHE= 65245 CCACHE_STATUS= 65246 { $as_echo "$as_me:${as_lineno-$LINENO}: checking is ccache enabled" >&5 65247 $as_echo_n "checking is ccache enabled... " >&6; } 65248 if test "x$enable_ccache" = xyes; then 65249 if test "x$TOOLCHAIN_TYPE" = "xgcc" -o "x$TOOLCHAIN_TYPE" = "xclang"; then 65250 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 65251 $as_echo "yes" >&6; } 65252 OLD_PATH="$PATH" 65253 if test "x$TOOLCHAIN_PATH" != x; then 65254 PATH=$TOOLCHAIN_PATH:$PATH 65255 fi 65256 65257 65258 65259 # Publish this variable in the help. 65260 65261 65262 if [ -z "${CCACHE+x}" ]; then 65263 # The variable is not set by user, try to locate tool using the code snippet 65264 for ac_prog in ccache 65265 do 65266 # Extract the first word of "$ac_prog", so it can be a program name with args. 65267 set dummy $ac_prog; ac_word=$2 65268 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 65269 $as_echo_n "checking for $ac_word... " >&6; } 65270 if ${ac_cv_path_CCACHE+:} false; then : 65271 $as_echo_n "(cached) " >&6 65272 else 65273 case $CCACHE in 65274 [\\/]* | ?:[\\/]*) 65275 ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path. 65276 ;; 65277 *) 65278 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 65279 for as_dir in $PATH 65280 do 65281 IFS=$as_save_IFS 65282 test -z "$as_dir" && as_dir=. 65283 for ac_exec_ext in '' $ac_executable_extensions; do 65284 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 65285 ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext" 65286 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 65287 break 2 65288 fi 65289 done 65290 done 65291 IFS=$as_save_IFS 65292 65293 ;; 65294 esac 65295 fi 65296 CCACHE=$ac_cv_path_CCACHE 65297 if test -n "$CCACHE"; then 65298 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5 65299 $as_echo "$CCACHE" >&6; } 65300 else 65301 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65302 $as_echo "no" >&6; } 65303 fi 65304 65305 65306 test -n "$CCACHE" && break 65307 done 65308 65309 else 65310 # The variable is set, but is it from the command line or the environment? 65311 65312 # Try to remove the string !CCACHE! from our list. 65313 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CCACHE!/} 65314 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 65315 # If it failed, the variable was not from the command line. Ignore it, 65316 # but warn the user (except for BASH, which is always set by the calling BASH). 65317 if test "xCCACHE" != xBASH; then 65318 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CCACHE from the environment. Use command line variables instead." >&5 65319 $as_echo "$as_me: WARNING: Ignoring value of CCACHE from the environment. Use command line variables instead." >&2;} 65320 fi 65321 # Try to locate tool using the code snippet 65322 for ac_prog in ccache 65323 do 65324 # Extract the first word of "$ac_prog", so it can be a program name with args. 65325 set dummy $ac_prog; ac_word=$2 65326 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 65327 $as_echo_n "checking for $ac_word... " >&6; } 65328 if ${ac_cv_path_CCACHE+:} false; then : 65329 $as_echo_n "(cached) " >&6 65330 else 65331 case $CCACHE in 65332 [\\/]* | ?:[\\/]*) 65333 ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path. 65334 ;; 65335 *) 65336 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 65337 for as_dir in $PATH 65338 do 65339 IFS=$as_save_IFS 65340 test -z "$as_dir" && as_dir=. 65341 for ac_exec_ext in '' $ac_executable_extensions; do 65342 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 65343 ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext" 65344 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 65345 break 2 65346 fi 65347 done 65348 done 65349 IFS=$as_save_IFS 65350 65351 ;; 65352 esac 65353 fi 65354 CCACHE=$ac_cv_path_CCACHE 65355 if test -n "$CCACHE"; then 65356 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5 65357 $as_echo "$CCACHE" >&6; } 65358 else 65359 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65360 $as_echo "no" >&6; } 65361 fi 65362 65363 65364 test -n "$CCACHE" && break 65365 done 65366 65367 else 65368 # If it succeeded, then it was overridden by the user. We will use it 65369 # for the tool. 65370 65371 # First remove it from the list of overridden variables, so we can test 65372 # for unknown variables in the end. 65373 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 65374 65375 # Check if we try to supply an empty value 65376 if test "x$CCACHE" = x; then 65377 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CCACHE= (no value)" >&5 65378 $as_echo "$as_me: Setting user supplied tool CCACHE= (no value)" >&6;} 65379 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CCACHE" >&5 65380 $as_echo_n "checking for CCACHE... " >&6; } 65381 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 65382 $as_echo "disabled" >&6; } 65383 else 65384 # Check if the provided tool contains a complete path. 65385 tool_specified="$CCACHE" 65386 tool_basename="${tool_specified##*/}" 65387 if test "x$tool_basename" = "x$tool_specified"; then 65388 # A command without a complete path is provided, search $PATH. 65389 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CCACHE=$tool_basename" >&5 65390 $as_echo "$as_me: Will search for user supplied tool CCACHE=$tool_basename" >&6;} 65391 # Extract the first word of "$tool_basename", so it can be a program name with args. 65392 set dummy $tool_basename; ac_word=$2 65393 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 65394 $as_echo_n "checking for $ac_word... " >&6; } 65395 if ${ac_cv_path_CCACHE+:} false; then : 65396 $as_echo_n "(cached) " >&6 65397 else 65398 case $CCACHE in 65399 [\\/]* | ?:[\\/]*) 65400 ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path. 65401 ;; 65402 *) 65403 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 65404 for as_dir in $PATH 65405 do 65406 IFS=$as_save_IFS 65407 test -z "$as_dir" && as_dir=. 65408 for ac_exec_ext in '' $ac_executable_extensions; do 65409 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 65410 ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext" 65411 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 65412 break 2 65413 fi 65414 done 65415 done 65416 IFS=$as_save_IFS 65417 65418 ;; 65419 esac 65420 fi 65421 CCACHE=$ac_cv_path_CCACHE 65422 if test -n "$CCACHE"; then 65423 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5 65424 $as_echo "$CCACHE" >&6; } 65425 else 65426 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65427 $as_echo "no" >&6; } 65428 fi 65429 65430 65431 if test "x$CCACHE" = x; then 65432 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 65433 fi 65434 else 65435 # Otherwise we believe it is a complete path. Use it as it is. 65436 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CCACHE=$tool_specified" >&5 65437 $as_echo "$as_me: Will use user supplied tool CCACHE=$tool_specified" >&6;} 65438 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CCACHE" >&5 65439 $as_echo_n "checking for CCACHE... " >&6; } 65440 if test ! -x "$tool_specified"; then 65441 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 65442 $as_echo "not found" >&6; } 65443 as_fn_error $? "User supplied tool CCACHE=$tool_specified does not exist or is not executable" "$LINENO" 5 65444 fi 65445 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 65446 $as_echo "$tool_specified" >&6; } 65447 fi 65448 fi 65449 fi 65450 65451 fi 65452 65453 65454 65455 if test "x$CCACHE" = x; then 65456 as_fn_error $? "Could not find required tool for CCACHE" "$LINENO" 5 65457 fi 65458 65459 65460 PATH="$OLD_PATH" 65461 CCACHE_VERSION=`$CCACHE --version | head -n1 | $SED 's/[A-Za-z ]*//'` 65462 CCACHE_STATUS="Active ($CCACHE_VERSION)" 65463 else 65464 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65465 $as_echo "no" >&6; } 65466 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: ccache is not supported with toolchain type $TOOLCHAIN_TYPE" >&5 65467 $as_echo "$as_me: WARNING: ccache is not supported with toolchain type $TOOLCHAIN_TYPE" >&2;} 65468 fi 65469 elif test "x$enable_ccache" = xno; then 65470 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, explicitly disabled" >&5 65471 $as_echo "no, explicitly disabled" >&6; } 65472 CCACHE_STATUS="Disabled" 65473 elif test "x$enable_ccache" = x; then 65474 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65475 $as_echo "no" >&6; } 65476 else 65477 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unknown" >&5 65478 $as_echo "unknown" >&6; } 65479 as_fn_error $? "--enable-ccache does not accept any parameters" "$LINENO" 5 65480 fi 65481 65482 65483 65484 # Check whether --with-ccache-dir was given. 65485 if test "${with_ccache_dir+set}" = set; then : 65486 withval=$with_ccache_dir; 65487 fi 65488 65489 65490 if test "x$with_ccache_dir" != x; then 65491 # When using a non home ccache directory, assume the use is to share ccache files 65492 # with other users. Thus change the umask. 65493 SET_CCACHE_DIR="CCACHE_DIR=$with_ccache_dir CCACHE_UMASK=002" 65494 if test "x$CCACHE" = x; then 65495 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-ccache-dir has no meaning when ccache is not enabled" >&5 65496 $as_echo "$as_me: WARNING: --with-ccache-dir has no meaning when ccache is not enabled" >&2;} 65497 fi 65498 fi 65499 65500 if test "x$CCACHE" != x; then 65501 65502 if test "x$CCACHE" != x; then 65503 if test "x$USE_PRECOMPILED_HEADER" = "x1"; then 65504 HAS_BAD_CCACHE=`$ECHO $CCACHE_VERSION | \ 65505 $GREP -e '^1.*' -e '^2.*' -e '^3\.0.*' -e '^3\.1\.[0123]$'` 65506 if test "x$HAS_BAD_CCACHE" != "x"; then 65507 as_fn_error $? "Precompiled headers requires ccache 3.1.4 or later, found $CCACHE_VERSION" "$LINENO" 5 65508 fi 65509 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if C-compiler supports ccache precompiled headers" >&5 65510 $as_echo_n "checking if C-compiler supports ccache precompiled headers... " >&6; } 65511 CCACHE_PRECOMP_FLAG="-fpch-preprocess" 65512 PUSHED_FLAGS="$CXXFLAGS" 65513 CXXFLAGS="$CCACHE_PRECOMP_FLAG $CXXFLAGS" 65514 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 65515 /* end confdefs.h. */ 65516 65517 int 65518 main () 65519 { 65520 65521 ; 65522 return 0; 65523 } 65524 _ACEOF 65525 if ac_fn_cxx_try_compile "$LINENO"; then : 65526 CC_KNOWS_CCACHE_TRICK=yes 65527 else 65528 CC_KNOWS_CCACHE_TRICK=no 65529 fi 65530 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 65531 CXXFLAGS="$PUSHED_FLAGS" 65532 if test "x$CC_KNOWS_CCACHE_TRICK" = xyes; then 65533 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 65534 $as_echo "yes" >&6; } 65535 CFLAGS_CCACHE="$CCACHE_PRECOMP_FLAG" 65536 65537 CCACHE_SLOPPINESS=pch_defines,time_macros 65538 else 65539 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 65540 $as_echo "no" >&6; } 65541 as_fn_error $? "Cannot use ccache with precompiled headers without compiler support for $CCACHE_PRECOMP_FLAG" "$LINENO" 5 65542 fi 65543 fi 65544 65545 CCACHE="CCACHE_COMPRESS=1 $SET_CCACHE_DIR \ 65546 CCACHE_SLOPPINESS=$CCACHE_SLOPPINESS CCACHE_BASEDIR=$TOPDIR $CCACHE" 65547 65548 if test "x$SET_CCACHE_DIR" != x; then 65549 mkdir -p $CCACHE_DIR > /dev/null 2>&1 65550 chmod a+rwxs $CCACHE_DIR > /dev/null 2>&1 65551 fi 65552 fi 65553 65554 fi 65555 65556 65557 ############################################################################### 65558 # 65559 # And now the finish... 65560 # 65561 ############################################################################### 65562 65563 # Check for some common pitfalls 65564 65565 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 65566 file_to_test="$SRC_ROOT/LICENSE" 65567 if test `$STAT -c '%a' "$file_to_test"` -lt 400; then 65568 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 65569 fi 65570 fi 65571 65572 65573 # Did user specify any unknown variables? 65574 65575 if test "x$CONFIGURE_OVERRIDDEN_VARIABLES" != x; then 65576 # Replace the separating ! with spaces before presenting for end user. 65577 unknown_variables=${CONFIGURE_OVERRIDDEN_VARIABLES//!/ } 65578 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: The following variables might be unknown to configure: $unknown_variables" >&5 65579 $as_echo "$as_me: WARNING: The following variables might be unknown to configure: $unknown_variables" >&2;} 65580 fi 65581 65582 65583 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if build directory is on local disk" >&5 65584 $as_echo_n "checking if build directory is on local disk... " >&6; } 65585 65586 # df -l lists only local disks; if the given directory is not found then 65587 # a non-zero exit code is given 65588 if test "x$DF" = x; then 65589 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 65590 # msys does not have df; use Windows "net use" instead. 65591 IS_NETWORK_DISK=`net use | grep \`pwd -W | cut -d ":" -f 1 | tr a-z A-Z\`:` 65592 if test "x$IS_NETWORK_DISK" = x; then 65593 OUTPUT_DIR_IS_LOCAL="yes" 65594 else 65595 OUTPUT_DIR_IS_LOCAL="no" 65596 fi 65597 else 65598 # No df here, say it's local 65599 OUTPUT_DIR_IS_LOCAL="yes" 65600 fi 65601 else 65602 if $DF -l $OUTPUT_ROOT > /dev/null 2>&1; then 65603 OUTPUT_DIR_IS_LOCAL="yes" 65604 else 65605 OUTPUT_DIR_IS_LOCAL="no" 65606 fi 65607 fi 65608 65609 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OUTPUT_DIR_IS_LOCAL" >&5 65610 $as_echo "$OUTPUT_DIR_IS_LOCAL" >&6; } 65611 65612 65613 65614 # Check if the user has any old-style ALT_ variables set. 65615 FOUND_ALT_VARIABLES=`env | grep ^ALT_` 65616 65617 # Before generating output files, test if they exist. If they do, this is a reconfigure. 65618 # Since we can't properly handle the dependencies for this, warn the user about the situation 65619 if test -e $OUTPUT_ROOT/spec.gmk; then 65620 IS_RECONFIGURE=yes 65621 else 65622 IS_RECONFIGURE=no 65623 fi 65624 65625 65626 # At the end, call the custom hook. (Dummy macro if no custom sources available) 65627 65628 65629 # This needs to be done after CUSTOM_LATE_HOOK since we can setup custom features. 65630 65631 # Keep feature lists sorted and free of duplicates 65632 JVM_FEATURES_server="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_server | $SORT -u))" 65633 JVM_FEATURES_client="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_client | $SORT -u))" 65634 JVM_FEATURES_core="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_core | $SORT -u))" 65635 JVM_FEATURES_minimal="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_minimal | $SORT -u))" 65636 JVM_FEATURES_zero="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_zero | $SORT -u))" 65637 JVM_FEATURES_zeroshark="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_zeroshark | $SORT -u))" 65638 JVM_FEATURES_custom="$($ECHO $($PRINTF '%s\n' $JVM_FEATURES_custom | $SORT -u))" 65639 65640 # Validate features 65641 for variant in $JVM_VARIANTS; do 65642 { $as_echo "$as_me:${as_lineno-$LINENO}: checking JVM features for JVM variant '$variant'" >&5 65643 $as_echo_n "checking JVM features for JVM variant '$variant'... " >&6; } 65644 features_var_name=JVM_FEATURES_$variant 65645 JVM_FEATURES_TO_TEST=${!features_var_name} 65646 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JVM_FEATURES_TO_TEST" >&5 65647 $as_echo "$JVM_FEATURES_TO_TEST" >&6; } 65648 NEEDLE=${VALID_JVM_FEATURES// /$'\n'} 65649 STACK=${JVM_FEATURES_TO_TEST// /$'\n'} 65650 INVALID_FEATURES=`$GREP -Fvx "${NEEDLE}" <<< "${STACK}"` 65651 if test "x$INVALID_FEATURES" != x; then 65652 as_fn_error $? "Invalid JVM feature(s): $INVALID_FEATURES" "$LINENO" 5 65653 fi 65654 done 65655 65656 65657 # We're messing a bit with internal autoconf variables to put the config.status 65658 # in the output directory instead of the current directory. 65659 CONFIG_STATUS="$CONFIGURESUPPORT_OUTPUTDIR/config.status" 65660 65661 # Create the actual output files. Now the main work of configure is done. 65662 cat >confcache <<\_ACEOF 65663 # This file is a shell script that caches the results of configure 65664 # tests run on this system so they can be shared between configure 65665 # scripts and configure runs, see configure's option --config-cache. 65666 # It is not useful on other systems. If it contains results you don't 65667 # want to keep, you may remove or edit it. 65668 # 65669 # config.status only pays attention to the cache file if you give it 65670 # the --recheck option to rerun configure. 65671 # 65672 # `ac_cv_env_foo' variables (set or unset) will be overridden when 65673 # loading this file, other *unset* `ac_cv_foo' will be assigned the 65674 # following values. 65675 65676 _ACEOF 65677 65678 # The following way of writing the cache mishandles newlines in values, 65679 # but we know of no workaround that is simple, portable, and efficient. 65680 # So, we kill variables containing newlines. 65681 # Ultrix sh set writes to stderr and can't be redirected directly, 65682 # and sets the high bit in the cache file unless we assign to the vars. 65683 ( 65684 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do 65685 eval ac_val=\$$ac_var 65686 case $ac_val in #( 65687 *${as_nl}*) 65688 case $ac_var in #( 65689 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 65690 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; 65691 esac 65692 case $ac_var in #( 65693 _ | IFS | as_nl) ;; #( 65694 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( 65695 *) { eval $ac_var=; unset $ac_var;} ;; 65696 esac ;; 65697 esac 65698 done 65699 65700 (set) 2>&1 | 65701 case $as_nl`(ac_space=' '; set) 2>&1` in #( 65702 *${as_nl}ac_space=\ *) 65703 # `set' does not quote correctly, so add quotes: double-quote 65704 # substitution turns \\\\ into \\, and sed turns \\ into \. 65705 sed -n \ 65706 "s/'/'\\\\''/g; 65707 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" 65708 ;; #( 65709 *) 65710 # `set' quotes correctly as required by POSIX, so do not add quotes. 65711 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" 65712 ;; 65713 esac | 65714 sort 65715 ) | 65716 sed ' 65717 /^ac_cv_env_/b end 65718 t clear 65719 :clear 65720 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ 65721 t end 65722 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ 65723 :end' >>confcache 65724 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else 65725 if test -w "$cache_file"; then 65726 if test "x$cache_file" != "x/dev/null"; then 65727 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 65728 $as_echo "$as_me: updating cache $cache_file" >&6;} 65729 if test ! -f "$cache_file" || test -h "$cache_file"; then 65730 cat confcache >"$cache_file" 65731 else 65732 case $cache_file in #( 65733 */* | ?:*) 65734 mv -f confcache "$cache_file"$$ && 65735 mv -f "$cache_file"$$ "$cache_file" ;; #( 65736 *) 65737 mv -f confcache "$cache_file" ;; 65738 esac 65739 fi 65740 fi 65741 else 65742 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 65743 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} 65744 fi 65745 fi 65746 rm -f confcache 65747 65748 test "x$prefix" = xNONE && prefix=$ac_default_prefix 65749 # Let make expand exec_prefix. 65750 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' 65751 65752 # Transform confdefs.h into DEFS. 65753 # Protect against shell expansion while executing Makefile rules. 65754 # Protect against Makefile macro expansion. 65755 # 65756 # If the first sed substitution is executed (which looks for macros that 65757 # take arguments), then branch to the quote section. Otherwise, 65758 # look for a macro that doesn't take arguments. 65759 ac_script=' 65760 :mline 65761 /\\$/{ 65762 N 65763 s,\\\n,, 65764 b mline 65765 } 65766 t clear 65767 :clear 65768 s/^[ ]*#[ ]*define[ ][ ]*\([^ (][^ (]*([^)]*)\)[ ]*\(.*\)/-D\1=\2/g 65769 t quote 65770 s/^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)/-D\1=\2/g 65771 t quote 65772 b any 65773 :quote 65774 s/[ `~#$^&*(){}\\|;'\''"<>?]/\\&/g 65775 s/\[/\\&/g 65776 s/\]/\\&/g 65777 s/\$/$$/g 65778 H 65779 :any 65780 ${ 65781 g 65782 s/^\n// 65783 s/\n/ /g 65784 p 65785 } 65786 ' 65787 DEFS=`sed -n "$ac_script" confdefs.h` 65788 65789 65790 ac_libobjs= 65791 ac_ltlibobjs= 65792 U= 65793 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue 65794 # 1. Remove the extension, and $U if already installed. 65795 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' 65796 ac_i=`$as_echo "$ac_i" | sed "$ac_script"` 65797 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR 65798 # will be set to the directory where LIBOBJS objects are built. 65799 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" 65800 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' 65801 done 65802 LIBOBJS=$ac_libobjs 65803 65804 LTLIBOBJS=$ac_ltlibobjs 65805 65806 65807 65808 : "${CONFIG_STATUS=./config.status}" 65809 ac_write_fail=0 65810 ac_clean_files_save=$ac_clean_files 65811 ac_clean_files="$ac_clean_files $CONFIG_STATUS" 65812 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 65813 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;} 65814 as_write_fail=0 65815 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 65816 #! $SHELL 65817 # Generated by $as_me. 65818 # Run this file to recreate the current configuration. 65819 # Compiler output produced by configure, useful for debugging 65820 # configure, is in config.log if it exists. 65821 65822 debug=false 65823 ac_cs_recheck=false 65824 ac_cs_silent=false 65825 65826 SHELL=\${CONFIG_SHELL-$SHELL} 65827 export SHELL 65828 _ASEOF 65829 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 65830 ## -------------------- ## 65831 ## M4sh Initialization. ## 65832 ## -------------------- ## 65833 65834 # Be more Bourne compatible 65835 DUALCASE=1; export DUALCASE # for MKS sh 65836 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : 65837 emulate sh 65838 NULLCMD=: 65839 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which 65840 # is contrary to our usage. Disable this feature. 65841 alias -g '${1+"$@"}'='"$@"' 65842 setopt NO_GLOB_SUBST 65843 else 65844 case `(set -o) 2>/dev/null` in #( 65845 *posix*) : 65846 set -o posix ;; #( 65847 *) : 65848 ;; 65849 esac 65850 fi 65851 65852 65853 as_nl=' 65854 ' 65855 export as_nl 65856 # Printing a long string crashes Solaris 7 /usr/bin/printf. 65857 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' 65858 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo 65859 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo 65860 # Prefer a ksh shell builtin over an external printf program on Solaris, 65861 # but without wasting forks for bash or zsh. 65862 if test -z "$BASH_VERSION$ZSH_VERSION" \ 65863 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then 65864 as_echo='print -r --' 65865 as_echo_n='print -rn --' 65866 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then 65867 as_echo='printf %s\n' 65868 as_echo_n='printf %s' 65869 else 65870 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then 65871 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' 65872 as_echo_n='/usr/ucb/echo -n' 65873 else 65874 as_echo_body='eval expr "X$1" : "X\\(.*\\)"' 65875 as_echo_n_body='eval 65876 arg=$1; 65877 case $arg in #( 65878 *"$as_nl"*) 65879 expr "X$arg" : "X\\(.*\\)$as_nl"; 65880 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; 65881 esac; 65882 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" 65883 ' 65884 export as_echo_n_body 65885 as_echo_n='sh -c $as_echo_n_body as_echo' 65886 fi 65887 export as_echo_body 65888 as_echo='sh -c $as_echo_body as_echo' 65889 fi 65890 65891 # The user is always right. 65892 if test "${PATH_SEPARATOR+set}" != set; then 65893 PATH_SEPARATOR=: 65894 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { 65895 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || 65896 PATH_SEPARATOR=';' 65897 } 65898 fi 65899 65900 65901 # IFS 65902 # We need space, tab and new line, in precisely that order. Quoting is 65903 # there to prevent editors from complaining about space-tab. 65904 # (If _AS_PATH_WALK were called with IFS unset, it would disable word 65905 # splitting by setting IFS to empty value.) 65906 IFS=" "" $as_nl" 65907 65908 # Find who we are. Look in the path if we contain no directory separator. 65909 as_myself= 65910 case $0 in #(( 65911 *[\\/]* ) as_myself=$0 ;; 65912 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 65913 for as_dir in $PATH 65914 do 65915 IFS=$as_save_IFS 65916 test -z "$as_dir" && as_dir=. 65917 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break 65918 done 65919 IFS=$as_save_IFS 65920 65921 ;; 65922 esac 65923 # We did not find ourselves, most probably we were run as `sh COMMAND' 65924 # in which case we are not to be found in the path. 65925 if test "x$as_myself" = x; then 65926 as_myself=$0 65927 fi 65928 if test ! -f "$as_myself"; then 65929 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 65930 exit 1 65931 fi 65932 65933 # Unset variables that we do not need and which cause bugs (e.g. in 65934 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" 65935 # suppresses any "Segmentation fault" message there. '((' could 65936 # trigger a bug in pdksh 5.2.14. 65937 for as_var in BASH_ENV ENV MAIL MAILPATH 65938 do eval test x\${$as_var+set} = xset \ 65939 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : 65940 done 65941 PS1='$ ' 65942 PS2='> ' 65943 PS4='+ ' 65944 65945 # NLS nuisances. 65946 LC_ALL=C 65947 export LC_ALL 65948 LANGUAGE=C 65949 export LANGUAGE 65950 65951 # CDPATH. 65952 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH 65953 65954 65955 # as_fn_error STATUS ERROR [LINENO LOG_FD] 65956 # ---------------------------------------- 65957 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are 65958 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the 65959 # script with STATUS, using 1 if that was 0. 65960 as_fn_error () 65961 { 65962 as_status=$1; test $as_status -eq 0 && as_status=1 65963 if test "$4"; then 65964 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 65965 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 65966 fi 65967 $as_echo "$as_me: error: $2" >&2 65968 as_fn_exit $as_status 65969 } # as_fn_error 65970 65971 65972 # as_fn_set_status STATUS 65973 # ----------------------- 65974 # Set $? to STATUS, without forking. 65975 as_fn_set_status () 65976 { 65977 return $1 65978 } # as_fn_set_status 65979 65980 # as_fn_exit STATUS 65981 # ----------------- 65982 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. 65983 as_fn_exit () 65984 { 65985 set +e 65986 as_fn_set_status $1 65987 exit $1 65988 } # as_fn_exit 65989 65990 # as_fn_unset VAR 65991 # --------------- 65992 # Portably unset VAR. 65993 as_fn_unset () 65994 { 65995 { eval $1=; unset $1;} 65996 } 65997 as_unset=as_fn_unset 65998 # as_fn_append VAR VALUE 65999 # ---------------------- 66000 # Append the text in VALUE to the end of the definition contained in VAR. Take 66001 # advantage of any shell optimizations that allow amortized linear growth over 66002 # repeated appends, instead of the typical quadratic growth present in naive 66003 # implementations. 66004 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : 66005 eval 'as_fn_append () 66006 { 66007 eval $1+=\$2 66008 }' 66009 else 66010 as_fn_append () 66011 { 66012 eval $1=\$$1\$2 66013 } 66014 fi # as_fn_append 66015 66016 # as_fn_arith ARG... 66017 # ------------------ 66018 # Perform arithmetic evaluation on the ARGs, and store the result in the 66019 # global $as_val. Take advantage of shells that can avoid forks. The arguments 66020 # must be portable across $(()) and expr. 66021 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : 66022 eval 'as_fn_arith () 66023 { 66024 as_val=$(( $* )) 66025 }' 66026 else 66027 as_fn_arith () 66028 { 66029 as_val=`expr "$@" || test $? -eq 1` 66030 } 66031 fi # as_fn_arith 66032 66033 66034 if expr a : '\(a\)' >/dev/null 2>&1 && 66035 test "X`expr 00001 : '.*\(...\)'`" = X001; then 66036 as_expr=expr 66037 else 66038 as_expr=false 66039 fi 66040 66041 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then 66042 as_basename=basename 66043 else 66044 as_basename=false 66045 fi 66046 66047 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then 66048 as_dirname=dirname 66049 else 66050 as_dirname=false 66051 fi 66052 66053 as_me=`$as_basename -- "$0" || 66054 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ 66055 X"$0" : 'X\(//\)$' \| \ 66056 X"$0" : 'X\(/\)' \| . 2>/dev/null || 66057 $as_echo X/"$0" | 66058 sed '/^.*\/\([^/][^/]*\)\/*$/{ 66059 s//\1/ 66060 q 66061 } 66062 /^X\/\(\/\/\)$/{ 66063 s//\1/ 66064 q 66065 } 66066 /^X\/\(\/\).*/{ 66067 s//\1/ 66068 q 66069 } 66070 s/.*/./; q'` 66071 66072 # Avoid depending upon Character Ranges. 66073 as_cr_letters='abcdefghijklmnopqrstuvwxyz' 66074 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' 66075 as_cr_Letters=$as_cr_letters$as_cr_LETTERS 66076 as_cr_digits='0123456789' 66077 as_cr_alnum=$as_cr_Letters$as_cr_digits 66078 66079 ECHO_C= ECHO_N= ECHO_T= 66080 case `echo -n x` in #((((( 66081 -n*) 66082 case `echo 'xy\c'` in 66083 *c*) ECHO_T=' ';; # ECHO_T is single tab character. 66084 xy) ECHO_C='\c';; 66085 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null 66086 ECHO_T=' ';; 66087 esac;; 66088 *) 66089 ECHO_N='-n';; 66090 esac 66091 66092 rm -f conf$$ conf$$.exe conf$$.file 66093 if test -d conf$$.dir; then 66094 rm -f conf$$.dir/conf$$.file 66095 else 66096 rm -f conf$$.dir 66097 mkdir conf$$.dir 2>/dev/null 66098 fi 66099 if (echo >conf$$.file) 2>/dev/null; then 66100 if ln -s conf$$.file conf$$ 2>/dev/null; then 66101 as_ln_s='ln -s' 66102 # ... but there are two gotchas: 66103 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. 66104 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. 66105 # In both cases, we have to default to `cp -pR'. 66106 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || 66107 as_ln_s='cp -pR' 66108 elif ln conf$$.file conf$$ 2>/dev/null; then 66109 as_ln_s=ln 66110 else 66111 as_ln_s='cp -pR' 66112 fi 66113 else 66114 as_ln_s='cp -pR' 66115 fi 66116 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file 66117 rmdir conf$$.dir 2>/dev/null 66118 66119 66120 # as_fn_mkdir_p 66121 # ------------- 66122 # Create "$as_dir" as a directory, including parents if necessary. 66123 as_fn_mkdir_p () 66124 { 66125 66126 case $as_dir in #( 66127 -*) as_dir=./$as_dir;; 66128 esac 66129 test -d "$as_dir" || eval $as_mkdir_p || { 66130 as_dirs= 66131 while :; do 66132 case $as_dir in #( 66133 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( 66134 *) as_qdir=$as_dir;; 66135 esac 66136 as_dirs="'$as_qdir' $as_dirs" 66137 as_dir=`$as_dirname -- "$as_dir" || 66138 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 66139 X"$as_dir" : 'X\(//\)[^/]' \| \ 66140 X"$as_dir" : 'X\(//\)$' \| \ 66141 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || 66142 $as_echo X"$as_dir" | 66143 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 66144 s//\1/ 66145 q 66146 } 66147 /^X\(\/\/\)[^/].*/{ 66148 s//\1/ 66149 q 66150 } 66151 /^X\(\/\/\)$/{ 66152 s//\1/ 66153 q 66154 } 66155 /^X\(\/\).*/{ 66156 s//\1/ 66157 q 66158 } 66159 s/.*/./; q'` 66160 test -d "$as_dir" && break 66161 done 66162 test -z "$as_dirs" || eval "mkdir $as_dirs" 66163 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" 66164 66165 66166 } # as_fn_mkdir_p 66167 if mkdir -p . 2>/dev/null; then 66168 as_mkdir_p='mkdir -p "$as_dir"' 66169 else 66170 test -d ./-p && rmdir ./-p 66171 as_mkdir_p=false 66172 fi 66173 66174 66175 # as_fn_executable_p FILE 66176 # ----------------------- 66177 # Test if FILE is an executable regular file. 66178 as_fn_executable_p () 66179 { 66180 test -f "$1" && test -x "$1" 66181 } # as_fn_executable_p 66182 as_test_x='test -x' 66183 as_executable_p=as_fn_executable_p 66184 66185 # Sed expression to map a string onto a valid CPP name. 66186 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" 66187 66188 # Sed expression to map a string onto a valid variable name. 66189 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" 66190 66191 66192 exec 6>&1 66193 ## ----------------------------------- ## 66194 ## Main body of $CONFIG_STATUS script. ## 66195 ## ----------------------------------- ## 66196 _ASEOF 66197 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 66198 66199 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 66200 # Save the log message, to keep $0 and so on meaningful, and to 66201 # report actual input values of CONFIG_FILES etc. instead of their 66202 # values after options handling. 66203 ac_log=" 66204 This file was extended by OpenJDK $as_me jdk9, which was 66205 generated by GNU Autoconf 2.69. Invocation command line was 66206 66207 CONFIG_FILES = $CONFIG_FILES 66208 CONFIG_HEADERS = $CONFIG_HEADERS 66209 CONFIG_LINKS = $CONFIG_LINKS 66210 CONFIG_COMMANDS = $CONFIG_COMMANDS 66211 $ $0 $@ 66212 66213 on `(hostname || uname -n) 2>/dev/null | sed 1q` 66214 " 66215 66216 _ACEOF 66217 66218 case $ac_config_files in *" 66219 "*) set x $ac_config_files; shift; ac_config_files=$*;; 66220 esac 66221 66222 66223 66224 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 66225 # Files that config.status was made for. 66226 config_files="$ac_config_files" 66227 66228 _ACEOF 66229 66230 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 66231 ac_cs_usage="\ 66232 \`$as_me' instantiates files and other configuration actions 66233 from templates according to the current configuration. Unless the files 66234 and actions are specified as TAGs, all are instantiated by default. 66235 66236 Usage: $0 [OPTION]... [TAG]... 66237 66238 -h, --help print this help, then exit 66239 -V, --version print version number and configuration settings, then exit 66240 --config print configuration, then exit 66241 -q, --quiet, --silent 66242 do not print progress messages 66243 -d, --debug don't remove temporary files 66244 --recheck update $as_me by reconfiguring in the same conditions 66245 --file=FILE[:TEMPLATE] 66246 instantiate the configuration file FILE 66247 66248 Configuration files: 66249 $config_files 66250 66251 Report bugs to <build-dev@openjdk.java.net>. 66252 OpenJDK home page: <http://openjdk.java.net>." 66253 66254 _ACEOF 66255 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 66256 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" 66257 ac_cs_version="\\ 66258 OpenJDK config.status jdk9 66259 configured by $0, generated by GNU Autoconf 2.69, 66260 with options \\"\$ac_cs_config\\" 66261 66262 Copyright (C) 2012 Free Software Foundation, Inc. 66263 This config.status script is free software; the Free Software Foundation 66264 gives unlimited permission to copy, distribute and modify it." 66265 66266 ac_pwd='$ac_pwd' 66267 srcdir='$srcdir' 66268 AWK='$AWK' 66269 test -n "\$AWK" || AWK=awk 66270 _ACEOF 66271 66272 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 66273 # The default lists apply if the user does not specify any file. 66274 ac_need_defaults=: 66275 while test $# != 0 66276 do 66277 case $1 in 66278 --*=?*) 66279 ac_option=`expr "X$1" : 'X\([^=]*\)='` 66280 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` 66281 ac_shift=: 66282 ;; 66283 --*=) 66284 ac_option=`expr "X$1" : 'X\([^=]*\)='` 66285 ac_optarg= 66286 ac_shift=: 66287 ;; 66288 *) 66289 ac_option=$1 66290 ac_optarg=$2 66291 ac_shift=shift 66292 ;; 66293 esac 66294 66295 case $ac_option in 66296 # Handling of the options. 66297 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) 66298 ac_cs_recheck=: ;; 66299 --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) 66300 $as_echo "$ac_cs_version"; exit ;; 66301 --config | --confi | --conf | --con | --co | --c ) 66302 $as_echo "$ac_cs_config"; exit ;; 66303 --debug | --debu | --deb | --de | --d | -d ) 66304 debug=: ;; 66305 --file | --fil | --fi | --f ) 66306 $ac_shift 66307 case $ac_optarg in 66308 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; 66309 '') as_fn_error $? "missing file argument" ;; 66310 esac 66311 as_fn_append CONFIG_FILES " '$ac_optarg'" 66312 ac_need_defaults=false;; 66313 --he | --h | --help | --hel | -h ) 66314 $as_echo "$ac_cs_usage"; exit ;; 66315 -q | -quiet | --quiet | --quie | --qui | --qu | --q \ 66316 | -silent | --silent | --silen | --sile | --sil | --si | --s) 66317 ac_cs_silent=: ;; 66318 66319 # This is an error. 66320 -*) as_fn_error $? "unrecognized option: \`$1' 66321 Try \`$0 --help' for more information." ;; 66322 66323 *) as_fn_append ac_config_targets " $1" 66324 ac_need_defaults=false ;; 66325 66326 esac 66327 shift 66328 done 66329 66330 ac_configure_extra_args= 66331 66332 if $ac_cs_silent; then 66333 exec 6>/dev/null 66334 ac_configure_extra_args="$ac_configure_extra_args --silent" 66335 fi 66336 66337 _ACEOF 66338 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 66339 if \$ac_cs_recheck; then 66340 set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion 66341 shift 66342 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 66343 CONFIG_SHELL='$SHELL' 66344 export CONFIG_SHELL 66345 exec "\$@" 66346 fi 66347 66348 _ACEOF 66349 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 66350 exec 5>>config.log 66351 { 66352 echo 66353 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX 66354 ## Running $as_me. ## 66355 _ASBOX 66356 $as_echo "$ac_log" 66357 } >&5 66358 66359 _ACEOF 66360 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 66361 _ACEOF 66362 66363 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 66364 66365 # Handling of arguments. 66366 for ac_config_target in $ac_config_targets 66367 do 66368 case $ac_config_target in 66369 "$OUTPUT_ROOT/spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/spec.gmk:$AUTOCONF_DIR/spec.gmk.in" ;; 66370 "$OUTPUT_ROOT/bootcycle-spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/bootcycle-spec.gmk:$AUTOCONF_DIR/bootcycle-spec.gmk.in" ;; 66371 "$OUTPUT_ROOT/buildjdk-spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/buildjdk-spec.gmk:$AUTOCONF_DIR/buildjdk-spec.gmk.in" ;; 66372 "$OUTPUT_ROOT/compare.sh") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/compare.sh:$AUTOCONF_DIR/compare.sh.in" ;; 66373 "$OUTPUT_ROOT/Makefile") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/Makefile:$AUTOCONF_DIR/Makefile.in" ;; 66374 66375 *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; 66376 esac 66377 done 66378 66379 66380 # If the user did not use the arguments to specify the items to instantiate, 66381 # then the envvar interface is used. Set only those that are not. 66382 # We use the long form for the default assignment because of an extremely 66383 # bizarre bug on SunOS 4.1.3. 66384 if $ac_need_defaults; then 66385 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files 66386 fi 66387 66388 # Have a temporary directory for convenience. Make it in the build tree 66389 # simply because there is no reason against having it here, and in addition, 66390 # creating and moving files from /tmp can sometimes cause problems. 66391 # Hook for its removal unless debugging. 66392 # Note that there is a small window in which the directory will not be cleaned: 66393 # after its creation but before its name has been assigned to `$tmp'. 66394 $debug || 66395 { 66396 tmp= ac_tmp= 66397 trap 'exit_status=$? 66398 : "${ac_tmp:=$tmp}" 66399 { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status 66400 ' 0 66401 trap 'as_fn_exit 1' 1 2 13 15 66402 } 66403 # Create a (secure) tmp directory for tmp files. 66404 66405 { 66406 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && 66407 test -d "$tmp" 66408 } || 66409 { 66410 tmp=./conf$$-$RANDOM 66411 (umask 077 && mkdir "$tmp") 66412 } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 66413 ac_tmp=$tmp 66414 66415 # Set up the scripts for CONFIG_FILES section. 66416 # No need to generate them if there are no CONFIG_FILES. 66417 # This happens for instance with `./config.status config.h'. 66418 if test -n "$CONFIG_FILES"; then 66419 66420 66421 ac_cr=`echo X | tr X '\015'` 66422 # On cygwin, bash can eat \r inside `` if the user requested igncr. 66423 # But we know of no other shell where ac_cr would be empty at this 66424 # point, so we can use a bashism as a fallback. 66425 if test "x$ac_cr" = x; then 66426 eval ac_cr=\$\'\\r\' 66427 fi 66428 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null` 66429 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then 66430 ac_cs_awk_cr='\\r' 66431 else 66432 ac_cs_awk_cr=$ac_cr 66433 fi 66434 66435 echo 'BEGIN {' >"$ac_tmp/subs1.awk" && 66436 _ACEOF 66437 66438 66439 { 66440 echo "cat >conf$$subs.awk <<_ACEOF" && 66441 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && 66442 echo "_ACEOF" 66443 } >conf$$subs.sh || 66444 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 66445 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` 66446 ac_delim='%!_!# ' 66447 for ac_last_try in false false false false false :; do 66448 . ./conf$$subs.sh || 66449 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 66450 66451 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` 66452 if test $ac_delim_n = $ac_delim_num; then 66453 break 66454 elif $ac_last_try; then 66455 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 66456 else 66457 ac_delim="$ac_delim!$ac_delim _$ac_delim!! " 66458 fi 66459 done 66460 rm -f conf$$subs.sh 66461 66462 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 66463 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && 66464 _ACEOF 66465 sed -n ' 66466 h 66467 s/^/S["/; s/!.*/"]=/ 66468 p 66469 g 66470 s/^[^!]*!// 66471 :repl 66472 t repl 66473 s/'"$ac_delim"'$// 66474 t delim 66475 :nl 66476 h 66477 s/\(.\{148\}\)..*/\1/ 66478 t more1 66479 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ 66480 p 66481 n 66482 b repl 66483 :more1 66484 s/["\\]/\\&/g; s/^/"/; s/$/"\\/ 66485 p 66486 g 66487 s/.\{148\}// 66488 t nl 66489 :delim 66490 h 66491 s/\(.\{148\}\)..*/\1/ 66492 t more2 66493 s/["\\]/\\&/g; s/^/"/; s/$/"/ 66494 p 66495 b 66496 :more2 66497 s/["\\]/\\&/g; s/^/"/; s/$/"\\/ 66498 p 66499 g 66500 s/.\{148\}// 66501 t delim 66502 ' <conf$$subs.awk | sed ' 66503 /^[^""]/{ 66504 N 66505 s/\n// 66506 } 66507 ' >>$CONFIG_STATUS || ac_write_fail=1 66508 rm -f conf$$subs.awk 66509 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 66510 _ACAWK 66511 cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && 66512 for (key in S) S_is_set[key] = 1 66513 FS = "" 66514 66515 } 66516 { 66517 line = $ 0 66518 nfields = split(line, field, "@") 66519 substed = 0 66520 len = length(field[1]) 66521 for (i = 2; i < nfields; i++) { 66522 key = field[i] 66523 keylen = length(key) 66524 if (S_is_set[key]) { 66525 value = S[key] 66526 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) 66527 len += length(value) + length(field[++i]) 66528 substed = 1 66529 } else 66530 len += 1 + keylen 66531 } 66532 66533 print line 66534 } 66535 66536 _ACAWK 66537 _ACEOF 66538 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 66539 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then 66540 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" 66541 else 66542 cat 66543 fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ 66544 || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 66545 _ACEOF 66546 66547 # VPATH may cause trouble with some makes, so we remove sole $(srcdir), 66548 # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and 66549 # trailing colons and then remove the whole line if VPATH becomes empty 66550 # (actually we leave an empty line to preserve line numbers). 66551 if test "x$srcdir" = x.; then 66552 ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ 66553 h 66554 s/// 66555 s/^/:/ 66556 s/[ ]*$/:/ 66557 s/:\$(srcdir):/:/g 66558 s/:\${srcdir}:/:/g 66559 s/:@srcdir@:/:/g 66560 s/^:*// 66561 s/:*$// 66562 x 66563 s/\(=[ ]*\).*/\1/ 66564 G 66565 s/\n// 66566 s/^[^=]*=[ ]*$// 66567 }' 66568 fi 66569 66570 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 66571 fi # test -n "$CONFIG_FILES" 66572 66573 66574 eval set X " :F $CONFIG_FILES " 66575 shift 66576 for ac_tag 66577 do 66578 case $ac_tag in 66579 :[FHLC]) ac_mode=$ac_tag; continue;; 66580 esac 66581 case $ac_mode$ac_tag in 66582 :[FHL]*:*);; 66583 :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; 66584 :[FH]-) ac_tag=-:-;; 66585 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; 66586 esac 66587 ac_save_IFS=$IFS 66588 IFS=: 66589 set x $ac_tag 66590 IFS=$ac_save_IFS 66591 shift 66592 ac_file=$1 66593 shift 66594 66595 case $ac_mode in 66596 :L) ac_source=$1;; 66597 :[FH]) 66598 ac_file_inputs= 66599 for ac_f 66600 do 66601 case $ac_f in 66602 -) ac_f="$ac_tmp/stdin";; 66603 *) # Look for the file first in the build tree, then in the source tree 66604 # (if the path is not absolute). The absolute path cannot be DOS-style, 66605 # because $ac_f cannot contain `:'. 66606 test -f "$ac_f" || 66607 case $ac_f in 66608 [\\/$]*) false;; 66609 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; 66610 esac || 66611 as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; 66612 esac 66613 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac 66614 as_fn_append ac_file_inputs " '$ac_f'" 66615 done 66616 66617 # Let's still pretend it is `configure' which instantiates (i.e., don't 66618 # use $as_me), people would be surprised to read: 66619 # /* config.h. Generated by config.status. */ 66620 configure_input='Generated from '` 66621 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' 66622 `' by configure.' 66623 if test x"$ac_file" != x-; then 66624 configure_input="$ac_file. $configure_input" 66625 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 66626 $as_echo "$as_me: creating $ac_file" >&6;} 66627 fi 66628 # Neutralize special characters interpreted by sed in replacement strings. 66629 case $configure_input in #( 66630 *\&* | *\|* | *\\* ) 66631 ac_sed_conf_input=`$as_echo "$configure_input" | 66632 sed 's/[\\\\&|]/\\\\&/g'`;; #( 66633 *) ac_sed_conf_input=$configure_input;; 66634 esac 66635 66636 case $ac_tag in 66637 *:-:* | *:-) cat >"$ac_tmp/stdin" \ 66638 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; 66639 esac 66640 ;; 66641 esac 66642 66643 ac_dir=`$as_dirname -- "$ac_file" || 66644 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 66645 X"$ac_file" : 'X\(//\)[^/]' \| \ 66646 X"$ac_file" : 'X\(//\)$' \| \ 66647 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || 66648 $as_echo X"$ac_file" | 66649 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 66650 s//\1/ 66651 q 66652 } 66653 /^X\(\/\/\)[^/].*/{ 66654 s//\1/ 66655 q 66656 } 66657 /^X\(\/\/\)$/{ 66658 s//\1/ 66659 q 66660 } 66661 /^X\(\/\).*/{ 66662 s//\1/ 66663 q 66664 } 66665 s/.*/./; q'` 66666 as_dir="$ac_dir"; as_fn_mkdir_p 66667 ac_builddir=. 66668 66669 case "$ac_dir" in 66670 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; 66671 *) 66672 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` 66673 # A ".." for each directory in $ac_dir_suffix. 66674 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` 66675 case $ac_top_builddir_sub in 66676 "") ac_top_builddir_sub=. ac_top_build_prefix= ;; 66677 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; 66678 esac ;; 66679 esac 66680 ac_abs_top_builddir=$ac_pwd 66681 ac_abs_builddir=$ac_pwd$ac_dir_suffix 66682 # for backward compatibility: 66683 ac_top_builddir=$ac_top_build_prefix 66684 66685 case $srcdir in 66686 .) # We are building in place. 66687 ac_srcdir=. 66688 ac_top_srcdir=$ac_top_builddir_sub 66689 ac_abs_top_srcdir=$ac_pwd ;; 66690 [\\/]* | ?:[\\/]* ) # Absolute name. 66691 ac_srcdir=$srcdir$ac_dir_suffix; 66692 ac_top_srcdir=$srcdir 66693 ac_abs_top_srcdir=$srcdir ;; 66694 *) # Relative name. 66695 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix 66696 ac_top_srcdir=$ac_top_build_prefix$srcdir 66697 ac_abs_top_srcdir=$ac_pwd/$srcdir ;; 66698 esac 66699 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix 66700 66701 66702 case $ac_mode in 66703 :F) 66704 # 66705 # CONFIG_FILE 66706 # 66707 66708 _ACEOF 66709 66710 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 66711 # If the template does not know about datarootdir, expand it. 66712 # FIXME: This hack should be removed a few years after 2.60. 66713 ac_datarootdir_hack=; ac_datarootdir_seen= 66714 ac_sed_dataroot=' 66715 /datarootdir/ { 66716 p 66717 q 66718 } 66719 /@datadir@/p 66720 /@docdir@/p 66721 /@infodir@/p 66722 /@localedir@/p 66723 /@mandir@/p' 66724 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in 66725 *datarootdir*) ac_datarootdir_seen=yes;; 66726 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) 66727 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 66728 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} 66729 _ACEOF 66730 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 66731 ac_datarootdir_hack=' 66732 s&@datadir@&$datadir&g 66733 s&@docdir@&$docdir&g 66734 s&@infodir@&$infodir&g 66735 s&@localedir@&$localedir&g 66736 s&@mandir@&$mandir&g 66737 s&\\\${datarootdir}&$datarootdir&g' ;; 66738 esac 66739 _ACEOF 66740 66741 # Neutralize VPATH when `$srcdir' = `.'. 66742 # Shell code in configure.ac might set extrasub. 66743 # FIXME: do we really want to maintain this feature? 66744 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 66745 ac_sed_extra="$ac_vpsub 66746 $extrasub 66747 _ACEOF 66748 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 66749 :t 66750 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b 66751 s|@configure_input@|$ac_sed_conf_input|;t t 66752 s&@top_builddir@&$ac_top_builddir_sub&;t t 66753 s&@top_build_prefix@&$ac_top_build_prefix&;t t 66754 s&@srcdir@&$ac_srcdir&;t t 66755 s&@abs_srcdir@&$ac_abs_srcdir&;t t 66756 s&@top_srcdir@&$ac_top_srcdir&;t t 66757 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t 66758 s&@builddir@&$ac_builddir&;t t 66759 s&@abs_builddir@&$ac_abs_builddir&;t t 66760 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t 66761 $ac_datarootdir_hack 66762 " 66763 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ 66764 >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 66765 66766 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && 66767 { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && 66768 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ 66769 "$ac_tmp/out"`; test -z "$ac_out"; } && 66770 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' 66771 which seems to be undefined. Please make sure it is defined" >&5 66772 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' 66773 which seems to be undefined. Please make sure it is defined" >&2;} 66774 66775 rm -f "$ac_tmp/stdin" 66776 case $ac_file in 66777 -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; 66778 *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; 66779 esac \ 66780 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 66781 ;; 66782 66783 66784 66785 esac 66786 66787 done # for ac_tag 66788 66789 66790 as_fn_exit 0 66791 _ACEOF 66792 ac_clean_files=$ac_clean_files_save 66793 66794 test $ac_write_fail = 0 || 66795 as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 66796 66797 66798 # configure is writing to config.log, and then calls config.status. 66799 # config.status does its own redirection, appending to config.log. 66800 # Unfortunately, on DOS this fails, as config.log is still kept open 66801 # by configure, so config.status won't be able to write to it; its 66802 # output is simply discarded. So we exec the FD to /dev/null, 66803 # effectively closing config.log, so it can be properly (re)opened and 66804 # appended to by config.status. When coming back to configure, we 66805 # need to make the FD available again. 66806 if test "$no_create" != yes; then 66807 ac_cs_success=: 66808 ac_config_status_args= 66809 test "$silent" = yes && 66810 ac_config_status_args="$ac_config_status_args --quiet" 66811 exec 5>/dev/null 66812 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false 66813 exec 5>>config.log 66814 # Use ||, not &&, to avoid exiting from the if with $? = 1, which 66815 # would make configure fail if this is the last instruction. 66816 $ac_cs_success || as_fn_exit 1 66817 fi 66818 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then 66819 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 66820 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} 66821 fi 66822 66823 66824 # After AC_OUTPUT, we need to do final work 66825 66826 66827 # Try to move config.log (generated by autoconf) to the configure-support directory. 66828 if test -e ./config.log; then 66829 $MV -f ./config.log "$CONFIGURESUPPORT_OUTPUTDIR/config.log" 2> /dev/null 66830 fi 66831 66832 # Rotate our log file (configure.log) 66833 if test -e "$OUTPUT_ROOT/configure.log.old"; then 66834 $RM -f "$OUTPUT_ROOT/configure.log.old" 66835 fi 66836 if test -e "$OUTPUT_ROOT/configure.log"; then 66837 $MV -f "$OUTPUT_ROOT/configure.log" "$OUTPUT_ROOT/configure.log.old" 2> /dev/null 66838 fi 66839 66840 # Move configure.log from current directory to the build output root 66841 if test -e ./configure.log; then 66842 $MV -f ./configure.log "$OUTPUT_ROOT/configure.log" 2> /dev/null 66843 fi 66844 66845 # Make the compare script executable 66846 $CHMOD +x $OUTPUT_ROOT/compare.sh 66847 66848 66849 # Finally output some useful information to the user 66850 66851 # Finally output some useful information to the user 66852 66853 printf "\n" 66854 printf "====================================================\n" 66855 if test "x$no_create" != "xyes"; then 66856 if test "x$IS_RECONFIGURE" != "xyes"; then 66857 printf "A new configuration has been successfully created in\n%s\n" "$OUTPUT_ROOT" 66858 else 66859 printf "The existing configuration has been successfully updated in\n%s\n" "$OUTPUT_ROOT" 66860 fi 66861 else 66862 if test "x$IS_RECONFIGURE" != "xyes"; then 66863 printf "A configuration has been successfully checked but not created\n" 66864 else 66865 printf "The existing configuration has been successfully checked in\n%s\n" "$OUTPUT_ROOT" 66866 fi 66867 fi 66868 if test "x$CONFIGURE_COMMAND_LINE" != x; then 66869 printf "using configure arguments '$CONFIGURE_COMMAND_LINE'.\n" 66870 else 66871 printf "using default settings.\n" 66872 fi 66873 66874 printf "\n" 66875 printf "Configuration summary:\n" 66876 printf "* Debug level: $DEBUG_LEVEL\n" 66877 printf "* HS debug level: $HOTSPOT_DEBUG_LEVEL\n" 66878 printf "* JDK variant: $JDK_VARIANT\n" 66879 printf "* JVM variants: $JVM_VARIANTS\n" 66880 printf "* OpenJDK target: OS: $OPENJDK_TARGET_OS, CPU architecture: $OPENJDK_TARGET_CPU_ARCH, address length: $OPENJDK_TARGET_CPU_BITS\n" 66881 printf "* Version string: $VERSION_STRING ($VERSION_SHORT)\n" 66882 66883 printf "\n" 66884 printf "Tools summary:\n" 66885 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 66886 printf "* Environment: $WINDOWS_ENV_VENDOR version $WINDOWS_ENV_VERSION (root at $WINDOWS_ENV_ROOT_PATH)\n" 66887 fi 66888 printf "* Boot JDK: $BOOT_JDK_VERSION (at $BOOT_JDK)\n" 66889 if test "x$TOOLCHAIN_VERSION" != "x"; then 66890 print_version=" $TOOLCHAIN_VERSION" 66891 fi 66892 printf "* Toolchain: $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION$print_version)\n" 66893 printf "* C Compiler: Version $CC_VERSION_NUMBER (at $CC)\n" 66894 printf "* C++ Compiler: Version $CXX_VERSION_NUMBER (at $CXX)\n" 66895 66896 printf "\n" 66897 printf "Build performance summary:\n" 66898 printf "* Cores to use: $JOBS\n" 66899 printf "* Memory limit: $MEMORY_SIZE MB\n" 66900 if test "x$CCACHE_STATUS" != "x"; then 66901 printf "* ccache status: $CCACHE_STATUS\n" 66902 fi 66903 printf "\n" 66904 66905 if test "x$BUILDING_MULTIPLE_JVM_VARIANTS" = "xtrue"; then 66906 printf "NOTE: You have requested to build more than one version of the JVM, which\n" 66907 printf "will result in longer build times.\n" 66908 printf "\n" 66909 fi 66910 66911 if test "x$FOUND_ALT_VARIABLES" != "x"; then 66912 printf "WARNING: You have old-style ALT_ environment variables set.\n" 66913 printf "These are not respected, and will be ignored. It is recommended\n" 66914 printf "that you clean your environment. The following variables are set:\n" 66915 printf "$FOUND_ALT_VARIABLES\n" 66916 printf "\n" 66917 fi 66918 66919 if test "x$OUTPUT_DIR_IS_LOCAL" != "xyes"; then 66920 printf "WARNING: Your build output directory is not on a local disk.\n" 66921 printf "This will severely degrade build performance!\n" 66922 printf "It is recommended that you create an output directory on a local disk,\n" 66923 printf "and run the configure script again from that directory.\n" 66924 printf "\n" 66925 fi 66926 66927 if test "x$IS_RECONFIGURE" = "xyes" && test "x$no_create" != "xyes"; then 66928 printf "WARNING: The result of this configuration has overridden an older\n" 66929 printf "configuration. You *should* run 'make clean' to make sure you get a\n" 66930 printf "proper build. Failure to do so might result in strange build problems.\n" 66931 printf "\n" 66932 fi 66933 66934 if test "x$IS_RECONFIGURE" != "xyes" && test "x$no_create" = "xyes"; then 66935 printf "WARNING: The result of this configuration was not saved.\n" 66936 printf "You should run without '--no-create | -n' to create the configuration.\n" 66937 printf "\n" 66938 fi 66939 66940 66941 66942 # Locate config.log. 66943 if test -e "$CONFIGURESUPPORT_OUTPUTDIR/config.log"; then 66944 CONFIG_LOG_PATH="$CONFIGURESUPPORT_OUTPUTDIR" 66945 elif test -e "./config.log"; then 66946 CONFIG_LOG_PATH="." 66947 fi 66948 66949 if test -e "$CONFIG_LOG_PATH/config.log"; then 66950 $GREP '^configure:.*: WARNING:' "$CONFIG_LOG_PATH/config.log" > /dev/null 2>&1 66951 if test $? -eq 0; then 66952 printf "The following warnings were produced. Repeated here for convenience:\n" 66953 # We must quote sed expression (using []) to stop m4 from eating the []. 66954 $GREP '^configure:.*: WARNING:' "$CONFIG_LOG_PATH/config.log" | $SED -e 's/^configure:[0-9]*: //' 66955 printf "\n" 66956 fi 66957 fi 66958