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 JAVA_FLAGS_BIG 648 JAVA_FLAGS 649 TEST_JOBS 650 JOBS 651 MEMORY_SIZE 652 NUM_CORES 653 ENABLE_INTREE_EC 654 HOTSPOT_MAKE_ARGS 655 LIBZIP_CAN_USE_MMAP 656 LIBDL 657 LIBM 658 USE_EXTERNAL_LCMS 659 LCMS_LIBS 660 LCMS_CFLAGS 661 USE_EXTERNAL_LIBZ 662 USE_EXTERNAL_LIBPNG 663 PNG_LIBS 664 PNG_CFLAGS 665 USE_EXTERNAL_LIBGIF 666 USE_EXTERNAL_LIBJPEG 667 LLVM_LIBS 668 LLVM_LDFLAGS 669 LLVM_CFLAGS 670 LLVM_CONFIG 671 LIBFFI_LIBS 672 LIBFFI_CFLAGS 673 ALSA_LIBS 674 ALSA_CFLAGS 675 FREETYPE_BUNDLE_LIB_PATH 676 FREETYPE_LIBS 677 FREETYPE_CFLAGS 678 CUPS_CFLAGS 679 X_EXTRA_LIBS 680 X_LIBS 681 X_PRE_LIBS 682 X_CFLAGS 683 XMKMF 684 MSVCP_DLL 685 MSVCR_DLL 686 LIBCXX 687 STATIC_CXX_SETTING 688 FIXPATH_DETACH_FLAG 689 FIXPATH 690 GCOV_ENABLED 691 ZIP_DEBUGINFO_FILES 692 ENABLE_DEBUG_SYMBOLS 693 STRIP_POLICY 694 DEBUG_BINARIES 695 NATIVE_DEBUG_SYMBOLS 696 CFLAGS_WARNINGS_ARE_ERRORS 697 DISABLE_WARNING_PREFIX 698 HOTSPOT_SET_WARNINGS_AS_ERRORS 699 WARNINGS_AS_ERRORS 700 COMPILER_SUPPORTS_TARGET_BITS_FLAG 701 ZERO_ARCHFLAG 702 LDFLAGS_TESTEXE 703 LDFLAGS_TESTLIB 704 LDFLAGS_CXX_JDK 705 JDKEXE_LIBS 706 JDKLIB_LIBS 707 LDFLAGS_JDKEXE 708 LDFLAGS_JDKLIB 709 CXXFLAGS_TESTEXE 710 CXXFLAGS_TESTLIB 711 CFLAGS_TESTEXE 712 CFLAGS_TESTLIB 713 CXXFLAGS_JDKEXE 714 CXXFLAGS_JDKLIB 715 CFLAGS_JDKEXE 716 CFLAGS_JDKLIB 717 MACOSX_VERSION_MIN 718 CXX_O_FLAG_NONE 719 CXX_O_FLAG_DEBUG 720 CXX_O_FLAG_NORM 721 CXX_O_FLAG_HI 722 CXX_O_FLAG_HIGHEST 723 C_O_FLAG_NONE 724 C_O_FLAG_DEBUG 725 C_O_FLAG_NORM 726 C_O_FLAG_HI 727 C_O_FLAG_HIGHEST 728 CXXFLAGS_DEBUG_SYMBOLS 729 CFLAGS_DEBUG_SYMBOLS 730 CXX_FLAG_DEPS 731 C_FLAG_DEPS 732 SHARED_LIBRARY_FLAGS 733 SET_SHARED_LIBRARY_MAPFILE 734 SET_SHARED_LIBRARY_NAME 735 SET_SHARED_LIBRARY_ORIGIN 736 SET_EXECUTABLE_ORIGIN 737 CXX_FLAG_REORDER 738 C_FLAG_REORDER 739 RC_FLAGS 740 AR_OUT_OPTION 741 LD_OUT_OPTION 742 EXE_OUT_OPTION 743 CC_OUT_OPTION 744 STRIPFLAGS 745 ARFLAGS 746 COMPILER_COMMAND_FILE_FLAG 747 COMPILER_TARGET_BITS_FLAG 748 JT_HOME 749 JTREGEXE 750 USING_BROKEN_SUSE_LD 751 PACKAGE_PATH 752 USE_CLANG 753 HOTSPOT_LD 754 HOTSPOT_CXX 755 HOTSPOT_RC 756 HOTSPOT_MT 757 BUILD_AS 758 BUILD_LDCXX 759 BUILD_LD 760 BUILD_AR 761 BUILD_NM 762 BUILD_CXX 763 BUILD_CC 764 BUILD_SYSROOT_LDFLAGS 765 BUILD_SYSROOT_CFLAGS 766 ac_ct_OBJDUMP 767 OBJDUMP 768 ac_ct_OBJCOPY 769 OBJCOPY 770 ac_ct_NM 771 ac_ct_STRIP 772 GNM 773 NM 774 STRIP 775 MSBUILD 776 DUMPBIN 777 RC 778 MT 779 LIPO 780 ac_ct_AR 781 AR 782 AS 783 LDCXX 784 LD 785 CXXCPP 786 CPP 787 ac_ct_CXX 788 CXXFLAGS 789 CXX 790 ac_ct_PROPER_COMPILER_CXX 791 PROPER_COMPILER_CXX 792 TOOLCHAIN_PATH_CXX 793 POTENTIAL_CXX 794 OBJEXT 795 EXEEXT 796 ac_ct_CC 797 CPPFLAGS 798 LDFLAGS 799 CFLAGS 800 CC 801 ac_ct_PROPER_COMPILER_CC 802 PROPER_COMPILER_CC 803 TOOLCHAIN_PATH_CC 804 POTENTIAL_CC 805 TOOLCHAIN_VERSION 806 VS_LIB 807 VS_INCLUDE 808 VS_PATH 809 CYGWIN_LINK 810 SYSROOT_LDFLAGS 811 SYSROOT_CFLAGS 812 LEGACY_EXTRA_LDFLAGS 813 LEGACY_EXTRA_CXXFLAGS 814 LEGACY_EXTRA_CFLAGS 815 EXE_SUFFIX 816 OBJ_SUFFIX 817 STATIC_LIBRARY 818 SHARED_LIBRARY 819 STATIC_LIBRARY_SUFFIX 820 SHARED_LIBRARY_SUFFIX 821 LIBRARY_PREFIX 822 TOOLCHAIN_TYPE 823 STATIC_BUILD 824 BUILD_HOTSPOT 825 HOTSPOT_DIST 826 BUILD_OUTPUT 827 JDK_TOPDIR 828 NASHORN_TOPDIR 829 HOTSPOT_TOPDIR 830 JAXWS_TOPDIR 831 JAXP_TOPDIR 832 CORBA_TOPDIR 833 LANGTOOLS_TOPDIR 834 BOOT_JDK_BITS 835 JAVAC_FLAGS 836 BOOT_JDK_SOURCETARGET 837 JARSIGNER 838 JAR 839 JAVAH 840 JAVAC 841 JAVA 842 BOOT_JDK 843 JAVA_CHECK 844 JAVAC_CHECK 845 VERSION_IS_GA 846 VERSION_SHORT 847 VERSION_STRING 848 VERSION_NUMBER_FOUR_POSITIONS 849 VERSION_NUMBER 850 VERSION_OPT 851 VERSION_BUILD 852 VERSION_PRE 853 VERSION_PATCH 854 VERSION_SECURITY 855 VERSION_MINOR 856 VERSION_MAJOR 857 MACOSX_BUNDLE_ID_BASE 858 MACOSX_BUNDLE_NAME_BASE 859 COMPANY_NAME 860 JDK_RC_PLATFORM_NAME 861 PRODUCT_SUFFIX 862 PRODUCT_NAME 863 LAUNCHER_NAME 864 TEST_IN_BUILD 865 COPYRIGHT_YEAR 866 COMPRESS_JARS 867 UNLIMITED_CRYPTO 868 CACERTS_FILE 869 BUILD_HEADLESS 870 SUPPORT_HEADFUL 871 SUPPORT_HEADLESS 872 DEFAULT_MAKE_TARGET 873 OS_VERSION_MICRO 874 OS_VERSION_MINOR 875 OS_VERSION_MAJOR 876 PKG_CONFIG 877 BASH_ARGS 878 SETFILE 879 CODESIGN 880 XATTR 881 DSYMUTIL 882 IS_GNU_TIME 883 PATCH 884 TIME 885 STAT 886 HG 887 READELF 888 OTOOL 889 LDD 890 ZIP 891 UNZIP 892 FIND_DELETE 893 OUTPUT_SYNC 894 OUTPUT_SYNC_SUPPORTED 895 CHECK_TOOLSDIR_MAKE 896 CHECK_TOOLSDIR_GMAKE 897 CHECK_MAKE 898 CHECK_GMAKE 899 MAKE 900 PKGHANDLER 901 CONFIGURESUPPORT_OUTPUTDIR 902 OUTPUT_ROOT 903 CONF_NAME 904 SPEC 905 SDKROOT 906 XCODEBUILD 907 BUILD_VARIANT_RELEASE 908 DEBUG_CLASSFILES 909 FASTDEBUG 910 VARIANT 911 DEBUG_LEVEL 912 MACOSX_UNIVERSAL 913 INCLUDE_SA 914 JVM_VARIANT_CORE 915 JVM_VARIANT_ZEROSHARK 916 JVM_VARIANT_ZERO 917 JVM_VARIANT_MINIMAL1 918 JVM_VARIANT_CLIENT 919 JVM_VARIANT_SERVER 920 JVM_VARIANTS 921 JVM_INTERPRETER 922 JDK_VARIANT 923 SET_OPENJDK 924 CANONICAL_TOPDIR 925 ORIGINAL_TOPDIR 926 TOPDIR 927 PATH_SEP 928 ZERO_ARCHDEF 929 DEFINE_CROSS_COMPILE_ARCH 930 LP64 931 OPENJDK_TARGET_OS_EXPORT_DIR 932 OPENJDK_TARGET_CPU_JLI_CFLAGS 933 OPENJDK_TARGET_CPU_OSARCH 934 OPENJDK_TARGET_CPU_ISADIR 935 OPENJDK_TARGET_CPU_LIBDIR 936 OPENJDK_TARGET_CPU_LEGACY_LIB 937 OPENJDK_TARGET_CPU_LEGACY 938 REQUIRED_OS_VERSION 939 REQUIRED_OS_NAME 940 COMPILE_TYPE 941 OPENJDK_TARGET_CPU_ENDIAN 942 OPENJDK_TARGET_CPU_BITS 943 OPENJDK_TARGET_CPU_ARCH 944 OPENJDK_TARGET_CPU 945 OPENJDK_TARGET_OS_ENV 946 OPENJDK_TARGET_OS_TYPE 947 OPENJDK_TARGET_OS 948 OPENJDK_BUILD_CPU_ENDIAN 949 OPENJDK_BUILD_CPU_BITS 950 OPENJDK_BUILD_CPU_ARCH 951 OPENJDK_BUILD_CPU 952 OPENJDK_BUILD_OS_ENV 953 OPENJDK_BUILD_OS_TYPE 954 OPENJDK_BUILD_OS 955 OPENJDK_BUILD_AUTOCONF_NAME 956 OPENJDK_TARGET_AUTOCONF_NAME 957 target_os 958 target_vendor 959 target_cpu 960 target 961 host_os 962 host_vendor 963 host_cpu 964 host 965 build_os 966 build_vendor 967 build_cpu 968 build 969 NICE 970 CPIO 971 DF 972 READLINK 973 CYGPATH 974 SED 975 FGREP 976 EGREP 977 GREP 978 AWK 979 XARGS 980 WHICH 981 WC 982 UNIQ 983 UNAME 984 TR 985 TOUCH 986 TEE 987 TAR 988 TAIL 989 SORT 990 SH 991 RMDIR 992 RM 993 PRINTF 994 NAWK 995 MV 996 MKTEMP 997 MKDIR 998 LS 999 LN 1000 HEAD 1001 FIND 1002 FILE 1003 EXPR 1004 ECHO 1005 DIRNAME 1006 DIFF 1007 DATE 1008 CUT 1009 CP 1010 COMM 1011 CMP 1012 CHMOD 1013 CAT 1014 BASH 1015 BASENAME 1016 DATE_WHEN_CONFIGURED 1017 ORIGINAL_PATH 1018 CONFIGURE_COMMAND_LINE 1019 target_alias 1020 host_alias 1021 build_alias 1022 LIBS 1023 ECHO_T 1024 ECHO_N 1025 ECHO_C 1026 DEFS 1027 mandir 1028 localedir 1029 libdir 1030 psdir 1031 pdfdir 1032 dvidir 1033 htmldir 1034 infodir 1035 docdir 1036 oldincludedir 1037 includedir 1038 localstatedir 1039 sharedstatedir 1040 sysconfdir 1041 datadir 1042 datarootdir 1043 libexecdir 1044 sbindir 1045 bindir 1046 program_transform_name 1047 prefix 1048 exec_prefix 1049 PACKAGE_URL 1050 PACKAGE_BUGREPORT 1051 PACKAGE_STRING 1052 PACKAGE_VERSION 1053 PACKAGE_TARNAME 1054 PACKAGE_NAME 1055 PATH_SEPARATOR 1056 SHELL' 1057 ac_subst_files='' 1058 ac_user_opts=' 1059 enable_option_checking 1060 with_target_bits 1061 enable_openjdk_only 1062 with_custom_make_dir 1063 with_jdk_variant 1064 with_jvm_interpreter 1065 with_jvm_variants 1066 enable_debug 1067 with_debug_level 1068 with_devkit 1069 with_sys_root 1070 with_sysroot 1071 with_tools_dir 1072 with_toolchain_path 1073 with_extra_path 1074 with_sdk_name 1075 with_conf_name 1076 with_output_sync 1077 with_default_make_target 1078 enable_headful 1079 with_cacerts_file 1080 enable_unlimited_crypto 1081 with_copyright_year 1082 enable_hotspot_test_in_build 1083 with_milestone 1084 with_update_version 1085 with_user_release_suffix 1086 with_build_number 1087 with_version_string 1088 with_version_pre 1089 with_version_opt 1090 with_version_build 1091 with_version_major 1092 with_version_minor 1093 with_version_security 1094 with_version_patch 1095 with_boot_jdk 1096 with_add_source_root 1097 with_override_source_root 1098 with_adds_and_overrides 1099 with_override_langtools 1100 with_override_corba 1101 with_override_jaxp 1102 with_override_jaxws 1103 with_override_hotspot 1104 with_override_nashorn 1105 with_override_jdk 1106 with_import_hotspot 1107 enable_static_build 1108 with_toolchain_type 1109 with_extra_cflags 1110 with_extra_cxxflags 1111 with_extra_ldflags 1112 with_toolchain_version 1113 with_build_devkit 1114 with_jtreg 1115 enable_warnings_as_errors 1116 with_native_debug_symbols 1117 enable_debug_symbols 1118 enable_zip_debug_info 1119 enable_native_coverage 1120 with_stdc__lib 1121 with_msvcr_dll 1122 with_msvcp_dll 1123 with_x 1124 with_cups 1125 with_cups_include 1126 with_freetype 1127 with_freetype_include 1128 with_freetype_lib 1129 with_freetype_src 1130 enable_freetype_bundling 1131 with_alsa 1132 with_alsa_include 1133 with_alsa_lib 1134 with_libffi 1135 with_libffi_include 1136 with_libffi_lib 1137 with_libjpeg 1138 with_giflib 1139 with_libpng 1140 with_zlib 1141 with_lcms 1142 with_dxsdk 1143 with_dxsdk_lib 1144 with_dxsdk_include 1145 with_num_cores 1146 with_memory_size 1147 with_jobs 1148 with_test_jobs 1149 with_boot_jdk_jvmargs 1150 with_sjavac_server_java 1151 enable_sjavac 1152 enable_javac_server 1153 enable_icecc 1154 enable_precompiled_headers 1155 enable_ccache 1156 with_ccache_dir 1157 ' 1158 ac_precious_vars='build_alias 1159 host_alias 1160 target_alias 1161 BASENAME 1162 BASH 1163 CAT 1164 CHMOD 1165 CMP 1166 COMM 1167 CP 1168 CUT 1169 DATE 1170 DIFF 1171 DIRNAME 1172 ECHO 1173 EXPR 1174 FILE 1175 FIND 1176 HEAD 1177 LN 1178 LS 1179 MKDIR 1180 MKTEMP 1181 MV 1182 NAWK 1183 PRINTF 1184 RM 1185 RMDIR 1186 SH 1187 SORT 1188 TAIL 1189 TAR 1190 TEE 1191 TOUCH 1192 TR 1193 UNAME 1194 UNIQ 1195 WC 1196 WHICH 1197 XARGS 1198 AWK 1199 GREP 1200 EGREP 1201 FGREP 1202 SED 1203 CYGPATH 1204 READLINK 1205 DF 1206 CPIO 1207 NICE 1208 MAKE 1209 UNZIP 1210 ZIP 1211 LDD 1212 OTOOL 1213 READELF 1214 HG 1215 STAT 1216 TIME 1217 PATCH 1218 DSYMUTIL 1219 XATTR 1220 CODESIGN 1221 SETFILE 1222 PKG_CONFIG 1223 JAVA 1224 JAVAC 1225 JAVAH 1226 JAR 1227 JARSIGNER 1228 CC 1229 CFLAGS 1230 LDFLAGS 1231 LIBS 1232 CPPFLAGS 1233 CXX 1234 CXXFLAGS 1235 CCC 1236 CPP 1237 CXXCPP 1238 AS 1239 AR 1240 LIPO 1241 STRIP 1242 NM 1243 GNM 1244 OBJCOPY 1245 OBJDUMP 1246 BUILD_CC 1247 BUILD_CXX 1248 BUILD_NM 1249 BUILD_AR 1250 JTREGEXE 1251 XMKMF 1252 FREETYPE_CFLAGS 1253 FREETYPE_LIBS 1254 ALSA_CFLAGS 1255 ALSA_LIBS 1256 LIBFFI_CFLAGS 1257 LIBFFI_LIBS 1258 PNG_CFLAGS 1259 PNG_LIBS 1260 LCMS_CFLAGS 1261 LCMS_LIBS 1262 ICECC_CMD 1263 ICECC_CREATE_ENV 1264 ICECC_WRAPPER 1265 CCACHE' 1266 1267 1268 # Initialize some variables set by options. 1269 ac_init_help= 1270 ac_init_version=false 1271 ac_unrecognized_opts= 1272 ac_unrecognized_sep= 1273 # The variables have the same names as the options, with 1274 # dashes changed to underlines. 1275 cache_file=/dev/null 1276 exec_prefix=NONE 1277 no_create= 1278 no_recursion= 1279 prefix=NONE 1280 program_prefix=NONE 1281 program_suffix=NONE 1282 program_transform_name=s,x,x, 1283 silent= 1284 site= 1285 srcdir= 1286 verbose= 1287 x_includes=NONE 1288 x_libraries=NONE 1289 1290 # Installation directory options. 1291 # These are left unexpanded so users can "make install exec_prefix=/foo" 1292 # and all the variables that are supposed to be based on exec_prefix 1293 # by default will actually change. 1294 # Use braces instead of parens because sh, perl, etc. also accept them. 1295 # (The list follows the same order as the GNU Coding Standards.) 1296 bindir='${exec_prefix}/bin' 1297 sbindir='${exec_prefix}/sbin' 1298 libexecdir='${exec_prefix}/libexec' 1299 datarootdir='${prefix}/share' 1300 datadir='${datarootdir}' 1301 sysconfdir='${prefix}/etc' 1302 sharedstatedir='${prefix}/com' 1303 localstatedir='${prefix}/var' 1304 includedir='${prefix}/include' 1305 oldincludedir='/usr/include' 1306 docdir='${datarootdir}/doc/${PACKAGE_TARNAME}' 1307 infodir='${datarootdir}/info' 1308 htmldir='${docdir}' 1309 dvidir='${docdir}' 1310 pdfdir='${docdir}' 1311 psdir='${docdir}' 1312 libdir='${exec_prefix}/lib' 1313 localedir='${datarootdir}/locale' 1314 mandir='${datarootdir}/man' 1315 1316 ac_prev= 1317 ac_dashdash= 1318 for ac_option 1319 do 1320 # If the previous option needs an argument, assign it. 1321 if test -n "$ac_prev"; then 1322 eval $ac_prev=\$ac_option 1323 ac_prev= 1324 continue 1325 fi 1326 1327 case $ac_option in 1328 *=?*) ac_optarg=`expr "X$ac_option" : '[^=]*=\(.*\)'` ;; 1329 *=) ac_optarg= ;; 1330 *) ac_optarg=yes ;; 1331 esac 1332 1333 # Accept the important Cygnus configure options, so we can diagnose typos. 1334 1335 case $ac_dashdash$ac_option in 1336 --) 1337 ac_dashdash=yes ;; 1338 1339 -bindir | --bindir | --bindi | --bind | --bin | --bi) 1340 ac_prev=bindir ;; 1341 -bindir=* | --bindir=* | --bindi=* | --bind=* | --bin=* | --bi=*) 1342 bindir=$ac_optarg ;; 1343 1344 -build | --build | --buil | --bui | --bu) 1345 ac_prev=build_alias ;; 1346 -build=* | --build=* | --buil=* | --bui=* | --bu=*) 1347 build_alias=$ac_optarg ;; 1348 1349 -cache-file | --cache-file | --cache-fil | --cache-fi \ 1350 | --cache-f | --cache- | --cache | --cach | --cac | --ca | --c) 1351 ac_prev=cache_file ;; 1352 -cache-file=* | --cache-file=* | --cache-fil=* | --cache-fi=* \ 1353 | --cache-f=* | --cache-=* | --cache=* | --cach=* | --cac=* | --ca=* | --c=*) 1354 cache_file=$ac_optarg ;; 1355 1356 --config-cache | -C) 1357 cache_file=config.cache ;; 1358 1359 -datadir | --datadir | --datadi | --datad) 1360 ac_prev=datadir ;; 1361 -datadir=* | --datadir=* | --datadi=* | --datad=*) 1362 datadir=$ac_optarg ;; 1363 1364 -datarootdir | --datarootdir | --datarootdi | --datarootd | --dataroot \ 1365 | --dataroo | --dataro | --datar) 1366 ac_prev=datarootdir ;; 1367 -datarootdir=* | --datarootdir=* | --datarootdi=* | --datarootd=* \ 1368 | --dataroot=* | --dataroo=* | --dataro=* | --datar=*) 1369 datarootdir=$ac_optarg ;; 1370 1371 -disable-* | --disable-*) 1372 ac_useropt=`expr "x$ac_option" : 'x-*disable-\(.*\)'` 1373 # Reject names that are not valid shell variable names. 1374 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1375 as_fn_error $? "invalid feature name: $ac_useropt" 1376 ac_useropt_orig=$ac_useropt 1377 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` 1378 case $ac_user_opts in 1379 *" 1380 "enable_$ac_useropt" 1381 "*) ;; 1382 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--disable-$ac_useropt_orig" 1383 ac_unrecognized_sep=', ';; 1384 esac 1385 eval enable_$ac_useropt=no ;; 1386 1387 -docdir | --docdir | --docdi | --doc | --do) 1388 ac_prev=docdir ;; 1389 -docdir=* | --docdir=* | --docdi=* | --doc=* | --do=*) 1390 docdir=$ac_optarg ;; 1391 1392 -dvidir | --dvidir | --dvidi | --dvid | --dvi | --dv) 1393 ac_prev=dvidir ;; 1394 -dvidir=* | --dvidir=* | --dvidi=* | --dvid=* | --dvi=* | --dv=*) 1395 dvidir=$ac_optarg ;; 1396 1397 -enable-* | --enable-*) 1398 ac_useropt=`expr "x$ac_option" : 'x-*enable-\([^=]*\)'` 1399 # Reject names that are not valid shell variable names. 1400 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1401 as_fn_error $? "invalid feature name: $ac_useropt" 1402 ac_useropt_orig=$ac_useropt 1403 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` 1404 case $ac_user_opts in 1405 *" 1406 "enable_$ac_useropt" 1407 "*) ;; 1408 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--enable-$ac_useropt_orig" 1409 ac_unrecognized_sep=', ';; 1410 esac 1411 eval enable_$ac_useropt=\$ac_optarg ;; 1412 1413 -exec-prefix | --exec_prefix | --exec-prefix | --exec-prefi \ 1414 | --exec-pref | --exec-pre | --exec-pr | --exec-p | --exec- \ 1415 | --exec | --exe | --ex) 1416 ac_prev=exec_prefix ;; 1417 -exec-prefix=* | --exec_prefix=* | --exec-prefix=* | --exec-prefi=* \ 1418 | --exec-pref=* | --exec-pre=* | --exec-pr=* | --exec-p=* | --exec-=* \ 1419 | --exec=* | --exe=* | --ex=*) 1420 exec_prefix=$ac_optarg ;; 1421 1422 -gas | --gas | --ga | --g) 1423 # Obsolete; use --with-gas. 1424 with_gas=yes ;; 1425 1426 -help | --help | --hel | --he | -h) 1427 ac_init_help=long ;; 1428 -help=r* | --help=r* | --hel=r* | --he=r* | -hr*) 1429 ac_init_help=recursive ;; 1430 -help=s* | --help=s* | --hel=s* | --he=s* | -hs*) 1431 ac_init_help=short ;; 1432 1433 -host | --host | --hos | --ho) 1434 ac_prev=host_alias ;; 1435 -host=* | --host=* | --hos=* | --ho=*) 1436 host_alias=$ac_optarg ;; 1437 1438 -htmldir | --htmldir | --htmldi | --htmld | --html | --htm | --ht) 1439 ac_prev=htmldir ;; 1440 -htmldir=* | --htmldir=* | --htmldi=* | --htmld=* | --html=* | --htm=* \ 1441 | --ht=*) 1442 htmldir=$ac_optarg ;; 1443 1444 -includedir | --includedir | --includedi | --included | --include \ 1445 | --includ | --inclu | --incl | --inc) 1446 ac_prev=includedir ;; 1447 -includedir=* | --includedir=* | --includedi=* | --included=* | --include=* \ 1448 | --includ=* | --inclu=* | --incl=* | --inc=*) 1449 includedir=$ac_optarg ;; 1450 1451 -infodir | --infodir | --infodi | --infod | --info | --inf) 1452 ac_prev=infodir ;; 1453 -infodir=* | --infodir=* | --infodi=* | --infod=* | --info=* | --inf=*) 1454 infodir=$ac_optarg ;; 1455 1456 -libdir | --libdir | --libdi | --libd) 1457 ac_prev=libdir ;; 1458 -libdir=* | --libdir=* | --libdi=* | --libd=*) 1459 libdir=$ac_optarg ;; 1460 1461 -libexecdir | --libexecdir | --libexecdi | --libexecd | --libexec \ 1462 | --libexe | --libex | --libe) 1463 ac_prev=libexecdir ;; 1464 -libexecdir=* | --libexecdir=* | --libexecdi=* | --libexecd=* | --libexec=* \ 1465 | --libexe=* | --libex=* | --libe=*) 1466 libexecdir=$ac_optarg ;; 1467 1468 -localedir | --localedir | --localedi | --localed | --locale) 1469 ac_prev=localedir ;; 1470 -localedir=* | --localedir=* | --localedi=* | --localed=* | --locale=*) 1471 localedir=$ac_optarg ;; 1472 1473 -localstatedir | --localstatedir | --localstatedi | --localstated \ 1474 | --localstate | --localstat | --localsta | --localst | --locals) 1475 ac_prev=localstatedir ;; 1476 -localstatedir=* | --localstatedir=* | --localstatedi=* | --localstated=* \ 1477 | --localstate=* | --localstat=* | --localsta=* | --localst=* | --locals=*) 1478 localstatedir=$ac_optarg ;; 1479 1480 -mandir | --mandir | --mandi | --mand | --man | --ma | --m) 1481 ac_prev=mandir ;; 1482 -mandir=* | --mandir=* | --mandi=* | --mand=* | --man=* | --ma=* | --m=*) 1483 mandir=$ac_optarg ;; 1484 1485 -nfp | --nfp | --nf) 1486 # Obsolete; use --without-fp. 1487 with_fp=no ;; 1488 1489 -no-create | --no-create | --no-creat | --no-crea | --no-cre \ 1490 | --no-cr | --no-c | -n) 1491 no_create=yes ;; 1492 1493 -no-recursion | --no-recursion | --no-recursio | --no-recursi \ 1494 | --no-recurs | --no-recur | --no-recu | --no-rec | --no-re | --no-r) 1495 no_recursion=yes ;; 1496 1497 -oldincludedir | --oldincludedir | --oldincludedi | --oldincluded \ 1498 | --oldinclude | --oldinclud | --oldinclu | --oldincl | --oldinc \ 1499 | --oldin | --oldi | --old | --ol | --o) 1500 ac_prev=oldincludedir ;; 1501 -oldincludedir=* | --oldincludedir=* | --oldincludedi=* | --oldincluded=* \ 1502 | --oldinclude=* | --oldinclud=* | --oldinclu=* | --oldincl=* | --oldinc=* \ 1503 | --oldin=* | --oldi=* | --old=* | --ol=* | --o=*) 1504 oldincludedir=$ac_optarg ;; 1505 1506 -prefix | --prefix | --prefi | --pref | --pre | --pr | --p) 1507 ac_prev=prefix ;; 1508 -prefix=* | --prefix=* | --prefi=* | --pref=* | --pre=* | --pr=* | --p=*) 1509 prefix=$ac_optarg ;; 1510 1511 -program-prefix | --program-prefix | --program-prefi | --program-pref \ 1512 | --program-pre | --program-pr | --program-p) 1513 ac_prev=program_prefix ;; 1514 -program-prefix=* | --program-prefix=* | --program-prefi=* \ 1515 | --program-pref=* | --program-pre=* | --program-pr=* | --program-p=*) 1516 program_prefix=$ac_optarg ;; 1517 1518 -program-suffix | --program-suffix | --program-suffi | --program-suff \ 1519 | --program-suf | --program-su | --program-s) 1520 ac_prev=program_suffix ;; 1521 -program-suffix=* | --program-suffix=* | --program-suffi=* \ 1522 | --program-suff=* | --program-suf=* | --program-su=* | --program-s=*) 1523 program_suffix=$ac_optarg ;; 1524 1525 -program-transform-name | --program-transform-name \ 1526 | --program-transform-nam | --program-transform-na \ 1527 | --program-transform-n | --program-transform- \ 1528 | --program-transform | --program-transfor \ 1529 | --program-transfo | --program-transf \ 1530 | --program-trans | --program-tran \ 1531 | --progr-tra | --program-tr | --program-t) 1532 ac_prev=program_transform_name ;; 1533 -program-transform-name=* | --program-transform-name=* \ 1534 | --program-transform-nam=* | --program-transform-na=* \ 1535 | --program-transform-n=* | --program-transform-=* \ 1536 | --program-transform=* | --program-transfor=* \ 1537 | --program-transfo=* | --program-transf=* \ 1538 | --program-trans=* | --program-tran=* \ 1539 | --progr-tra=* | --program-tr=* | --program-t=*) 1540 program_transform_name=$ac_optarg ;; 1541 1542 -pdfdir | --pdfdir | --pdfdi | --pdfd | --pdf | --pd) 1543 ac_prev=pdfdir ;; 1544 -pdfdir=* | --pdfdir=* | --pdfdi=* | --pdfd=* | --pdf=* | --pd=*) 1545 pdfdir=$ac_optarg ;; 1546 1547 -psdir | --psdir | --psdi | --psd | --ps) 1548 ac_prev=psdir ;; 1549 -psdir=* | --psdir=* | --psdi=* | --psd=* | --ps=*) 1550 psdir=$ac_optarg ;; 1551 1552 -q | -quiet | --quiet | --quie | --qui | --qu | --q \ 1553 | -silent | --silent | --silen | --sile | --sil) 1554 silent=yes ;; 1555 1556 -sbindir | --sbindir | --sbindi | --sbind | --sbin | --sbi | --sb) 1557 ac_prev=sbindir ;; 1558 -sbindir=* | --sbindir=* | --sbindi=* | --sbind=* | --sbin=* \ 1559 | --sbi=* | --sb=*) 1560 sbindir=$ac_optarg ;; 1561 1562 -sharedstatedir | --sharedstatedir | --sharedstatedi \ 1563 | --sharedstated | --sharedstate | --sharedstat | --sharedsta \ 1564 | --sharedst | --shareds | --shared | --share | --shar \ 1565 | --sha | --sh) 1566 ac_prev=sharedstatedir ;; 1567 -sharedstatedir=* | --sharedstatedir=* | --sharedstatedi=* \ 1568 | --sharedstated=* | --sharedstate=* | --sharedstat=* | --sharedsta=* \ 1569 | --sharedst=* | --shareds=* | --shared=* | --share=* | --shar=* \ 1570 | --sha=* | --sh=*) 1571 sharedstatedir=$ac_optarg ;; 1572 1573 -site | --site | --sit) 1574 ac_prev=site ;; 1575 -site=* | --site=* | --sit=*) 1576 site=$ac_optarg ;; 1577 1578 -srcdir | --srcdir | --srcdi | --srcd | --src | --sr) 1579 ac_prev=srcdir ;; 1580 -srcdir=* | --srcdir=* | --srcdi=* | --srcd=* | --src=* | --sr=*) 1581 srcdir=$ac_optarg ;; 1582 1583 -sysconfdir | --sysconfdir | --sysconfdi | --sysconfd | --sysconf \ 1584 | --syscon | --sysco | --sysc | --sys | --sy) 1585 ac_prev=sysconfdir ;; 1586 -sysconfdir=* | --sysconfdir=* | --sysconfdi=* | --sysconfd=* | --sysconf=* \ 1587 | --syscon=* | --sysco=* | --sysc=* | --sys=* | --sy=*) 1588 sysconfdir=$ac_optarg ;; 1589 1590 -target | --target | --targe | --targ | --tar | --ta | --t) 1591 ac_prev=target_alias ;; 1592 -target=* | --target=* | --targe=* | --targ=* | --tar=* | --ta=* | --t=*) 1593 target_alias=$ac_optarg ;; 1594 1595 -v | -verbose | --verbose | --verbos | --verbo | --verb) 1596 verbose=yes ;; 1597 1598 -version | --version | --versio | --versi | --vers | -V) 1599 ac_init_version=: ;; 1600 1601 -with-* | --with-*) 1602 ac_useropt=`expr "x$ac_option" : 'x-*with-\([^=]*\)'` 1603 # Reject names that are not valid shell variable names. 1604 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1605 as_fn_error $? "invalid package name: $ac_useropt" 1606 ac_useropt_orig=$ac_useropt 1607 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` 1608 case $ac_user_opts in 1609 *" 1610 "with_$ac_useropt" 1611 "*) ;; 1612 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--with-$ac_useropt_orig" 1613 ac_unrecognized_sep=', ';; 1614 esac 1615 eval with_$ac_useropt=\$ac_optarg ;; 1616 1617 -without-* | --without-*) 1618 ac_useropt=`expr "x$ac_option" : 'x-*without-\(.*\)'` 1619 # Reject names that are not valid shell variable names. 1620 expr "x$ac_useropt" : ".*[^-+._$as_cr_alnum]" >/dev/null && 1621 as_fn_error $? "invalid package name: $ac_useropt" 1622 ac_useropt_orig=$ac_useropt 1623 ac_useropt=`$as_echo "$ac_useropt" | sed 's/[-+.]/_/g'` 1624 case $ac_user_opts in 1625 *" 1626 "with_$ac_useropt" 1627 "*) ;; 1628 *) ac_unrecognized_opts="$ac_unrecognized_opts$ac_unrecognized_sep--without-$ac_useropt_orig" 1629 ac_unrecognized_sep=', ';; 1630 esac 1631 eval with_$ac_useropt=no ;; 1632 1633 --x) 1634 # Obsolete; use --with-x. 1635 with_x=yes ;; 1636 1637 -x-includes | --x-includes | --x-include | --x-includ | --x-inclu \ 1638 | --x-incl | --x-inc | --x-in | --x-i) 1639 ac_prev=x_includes ;; 1640 -x-includes=* | --x-includes=* | --x-include=* | --x-includ=* | --x-inclu=* \ 1641 | --x-incl=* | --x-inc=* | --x-in=* | --x-i=*) 1642 x_includes=$ac_optarg ;; 1643 1644 -x-libraries | --x-libraries | --x-librarie | --x-librari \ 1645 | --x-librar | --x-libra | --x-libr | --x-lib | --x-li | --x-l) 1646 ac_prev=x_libraries ;; 1647 -x-libraries=* | --x-libraries=* | --x-librarie=* | --x-librari=* \ 1648 | --x-librar=* | --x-libra=* | --x-libr=* | --x-lib=* | --x-li=* | --x-l=*) 1649 x_libraries=$ac_optarg ;; 1650 1651 -*) as_fn_error $? "unrecognized option: \`$ac_option' 1652 Try \`$0 --help' for more information" 1653 ;; 1654 1655 *=*) 1656 ac_envvar=`expr "x$ac_option" : 'x\([^=]*\)='` 1657 # Reject names that are not valid shell variable names. 1658 case $ac_envvar in #( 1659 '' | [0-9]* | *[!_$as_cr_alnum]* ) 1660 as_fn_error $? "invalid variable name: \`$ac_envvar'" ;; 1661 esac 1662 eval $ac_envvar=\$ac_optarg 1663 export $ac_envvar ;; 1664 1665 *) 1666 # FIXME: should be removed in autoconf 3.0. 1667 $as_echo "$as_me: WARNING: you should use --build, --host, --target" >&2 1668 expr "x$ac_option" : ".*[^-._$as_cr_alnum]" >/dev/null && 1669 $as_echo "$as_me: WARNING: invalid host type: $ac_option" >&2 1670 : "${build_alias=$ac_option} ${host_alias=$ac_option} ${target_alias=$ac_option}" 1671 ;; 1672 1673 esac 1674 done 1675 1676 if test -n "$ac_prev"; then 1677 ac_option=--`echo $ac_prev | sed 's/_/-/g'` 1678 as_fn_error $? "missing argument to $ac_option" 1679 fi 1680 1681 if test -n "$ac_unrecognized_opts"; then 1682 case $enable_option_checking in 1683 no) ;; 1684 fatal) as_fn_error $? "unrecognized options: $ac_unrecognized_opts" ;; 1685 *) $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2 ;; 1686 esac 1687 fi 1688 1689 # Check all directory arguments for consistency. 1690 for ac_var in exec_prefix prefix bindir sbindir libexecdir datarootdir \ 1691 datadir sysconfdir sharedstatedir localstatedir includedir \ 1692 oldincludedir docdir infodir htmldir dvidir pdfdir psdir \ 1693 libdir localedir mandir 1694 do 1695 eval ac_val=\$$ac_var 1696 # Remove trailing slashes. 1697 case $ac_val in 1698 */ ) 1699 ac_val=`expr "X$ac_val" : 'X\(.*[^/]\)' \| "X$ac_val" : 'X\(.*\)'` 1700 eval $ac_var=\$ac_val;; 1701 esac 1702 # Be sure to have absolute directory names. 1703 case $ac_val in 1704 [\\/$]* | ?:[\\/]* ) continue;; 1705 NONE | '' ) case $ac_var in *prefix ) continue;; esac;; 1706 esac 1707 as_fn_error $? "expected an absolute directory name for --$ac_var: $ac_val" 1708 done 1709 1710 # There might be people who depend on the old broken behavior: `$host' 1711 # used to hold the argument of --host etc. 1712 # FIXME: To remove some day. 1713 build=$build_alias 1714 host=$host_alias 1715 target=$target_alias 1716 1717 # FIXME: To remove some day. 1718 if test "x$host_alias" != x; then 1719 if test "x$build_alias" = x; then 1720 cross_compiling=maybe 1721 elif test "x$build_alias" != "x$host_alias"; then 1722 cross_compiling=yes 1723 fi 1724 fi 1725 1726 ac_tool_prefix= 1727 test -n "$host_alias" && ac_tool_prefix=$host_alias- 1728 1729 test "$silent" = yes && exec 6>/dev/null 1730 1731 1732 ac_pwd=`pwd` && test -n "$ac_pwd" && 1733 ac_ls_di=`ls -di .` && 1734 ac_pwd_ls_di=`cd "$ac_pwd" && ls -di .` || 1735 as_fn_error $? "working directory cannot be determined" 1736 test "X$ac_ls_di" = "X$ac_pwd_ls_di" || 1737 as_fn_error $? "pwd does not report name of working directory" 1738 1739 1740 # Find the source files, if location was not specified. 1741 if test -z "$srcdir"; then 1742 ac_srcdir_defaulted=yes 1743 # Try the directory containing this script, then the parent directory. 1744 ac_confdir=`$as_dirname -- "$as_myself" || 1745 $as_expr X"$as_myself" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 1746 X"$as_myself" : 'X\(//\)[^/]' \| \ 1747 X"$as_myself" : 'X\(//\)$' \| \ 1748 X"$as_myself" : 'X\(/\)' \| . 2>/dev/null || 1749 $as_echo X"$as_myself" | 1750 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 1751 s//\1/ 1752 q 1753 } 1754 /^X\(\/\/\)[^/].*/{ 1755 s//\1/ 1756 q 1757 } 1758 /^X\(\/\/\)$/{ 1759 s//\1/ 1760 q 1761 } 1762 /^X\(\/\).*/{ 1763 s//\1/ 1764 q 1765 } 1766 s/.*/./; q'` 1767 srcdir=$ac_confdir 1768 if test ! -r "$srcdir/$ac_unique_file"; then 1769 srcdir=.. 1770 fi 1771 else 1772 ac_srcdir_defaulted=no 1773 fi 1774 if test ! -r "$srcdir/$ac_unique_file"; then 1775 test "$ac_srcdir_defaulted" = yes && srcdir="$ac_confdir or .." 1776 as_fn_error $? "cannot find sources ($ac_unique_file) in $srcdir" 1777 fi 1778 ac_msg="sources are in $srcdir, but \`cd $srcdir' does not work" 1779 ac_abs_confdir=`( 1780 cd "$srcdir" && test -r "./$ac_unique_file" || as_fn_error $? "$ac_msg" 1781 pwd)` 1782 # When building in place, set srcdir=. 1783 if test "$ac_abs_confdir" = "$ac_pwd"; then 1784 srcdir=. 1785 fi 1786 # Remove unnecessary trailing slashes from srcdir. 1787 # Double slashes in file names in object file debugging info 1788 # mess up M-x gdb in Emacs. 1789 case $srcdir in 1790 */) srcdir=`expr "X$srcdir" : 'X\(.*[^/]\)' \| "X$srcdir" : 'X\(.*\)'`;; 1791 esac 1792 for ac_var in $ac_precious_vars; do 1793 eval ac_env_${ac_var}_set=\${${ac_var}+set} 1794 eval ac_env_${ac_var}_value=\$${ac_var} 1795 eval ac_cv_env_${ac_var}_set=\${${ac_var}+set} 1796 eval ac_cv_env_${ac_var}_value=\$${ac_var} 1797 done 1798 1799 # 1800 # Report the --help message. 1801 # 1802 if test "$ac_init_help" = "long"; then 1803 # Omit some internal or obsolete options to make the list less imposing. 1804 # This message is too long to be a string in the A/UX 3.1 sh. 1805 cat <<_ACEOF 1806 \`configure' configures OpenJDK jdk9 to adapt to many kinds of systems. 1807 1808 Usage: $0 [OPTION]... [VAR=VALUE]... 1809 1810 To assign environment variables (e.g., CC, CFLAGS...), specify them as 1811 VAR=VALUE. See below for descriptions of some of the useful variables. 1812 1813 Defaults for the options are specified in brackets. 1814 1815 Configuration: 1816 -h, --help display this help and exit 1817 --help=short display options specific to this package 1818 --help=recursive display the short help of all the included packages 1819 -V, --version display version information and exit 1820 -q, --quiet, --silent do not print \`checking ...' messages 1821 --cache-file=FILE cache test results in FILE [disabled] 1822 -C, --config-cache alias for \`--cache-file=config.cache' 1823 -n, --no-create do not create output files 1824 --srcdir=DIR find the sources in DIR [configure dir or \`..'] 1825 1826 Installation directories: 1827 --prefix=PREFIX install architecture-independent files in PREFIX 1828 [$ac_default_prefix] 1829 --exec-prefix=EPREFIX install architecture-dependent files in EPREFIX 1830 [PREFIX] 1831 1832 By default, \`make install' will install all the files in 1833 \`$ac_default_prefix/bin', \`$ac_default_prefix/lib' etc. You can specify 1834 an installation prefix other than \`$ac_default_prefix' using \`--prefix', 1835 for instance \`--prefix=\$HOME'. 1836 1837 For better control, use the options below. 1838 1839 Fine tuning of the installation directories: 1840 --bindir=DIR user executables [EPREFIX/bin] 1841 --sbindir=DIR system admin executables [EPREFIX/sbin] 1842 --libexecdir=DIR program executables [EPREFIX/libexec] 1843 --sysconfdir=DIR read-only single-machine data [PREFIX/etc] 1844 --sharedstatedir=DIR modifiable architecture-independent data [PREFIX/com] 1845 --localstatedir=DIR modifiable single-machine data [PREFIX/var] 1846 --libdir=DIR object code libraries [EPREFIX/lib] 1847 --includedir=DIR C header files [PREFIX/include] 1848 --oldincludedir=DIR C header files for non-gcc [/usr/include] 1849 --datarootdir=DIR read-only arch.-independent data root [PREFIX/share] 1850 --datadir=DIR read-only architecture-independent data [DATAROOTDIR] 1851 --infodir=DIR info documentation [DATAROOTDIR/info] 1852 --localedir=DIR locale-dependent data [DATAROOTDIR/locale] 1853 --mandir=DIR man documentation [DATAROOTDIR/man] 1854 --docdir=DIR documentation root [DATAROOTDIR/doc/openjdk] 1855 --htmldir=DIR html documentation [DOCDIR] 1856 --dvidir=DIR dvi documentation [DOCDIR] 1857 --pdfdir=DIR pdf documentation [DOCDIR] 1858 --psdir=DIR ps documentation [DOCDIR] 1859 _ACEOF 1860 1861 cat <<\_ACEOF 1862 1863 X features: 1864 --x-includes=DIR X include files are in DIR 1865 --x-libraries=DIR X library files are in DIR 1866 1867 System types: 1868 --build=BUILD configure for building on BUILD [guessed] 1869 --host=HOST cross-compile to build programs to run on HOST [BUILD] 1870 --target=TARGET configure for building compilers for TARGET [HOST] 1871 _ACEOF 1872 fi 1873 1874 if test -n "$ac_init_help"; then 1875 case $ac_init_help in 1876 short | recursive ) echo "Configuration of OpenJDK jdk9:";; 1877 esac 1878 cat <<\_ACEOF 1879 1880 Optional Features: 1881 --disable-option-checking ignore unrecognized --enable/--with options 1882 --disable-FEATURE do not include FEATURE (same as --enable-FEATURE=no) 1883 --enable-FEATURE[=ARG] include FEATURE [ARG=yes] 1884 --enable-openjdk-only suppress building custom source even if present 1885 [disabled] 1886 --enable-debug set the debug level to fastdebug (shorthand for 1887 --with-debug-level=fastdebug) [disabled] 1888 --disable-headful disable building headful support (graphical UI 1889 support) [enabled] 1890 --enable-unlimited-crypto 1891 Enable unlimited crypto policy [disabled] 1892 --enable-hotspot-test-in-build 1893 run the Queens test after Hotspot build [disabled] 1894 --enable-static-build enable static library build [disabled] 1895 --disable-warnings-as-errors 1896 do not consider native warnings to be an error 1897 [enabled] 1898 --enable-debug-symbols Deprecated. Option is kept for backwards 1899 compatibility and is ignored 1900 --enable-zip-debug-info Deprecated. Option is kept for backwards 1901 compatibility and is ignored 1902 --enable-native-coverage 1903 enable native compilation with code coverage 1904 data[disabled] 1905 --disable-freetype-bundling 1906 disable bundling of the freetype library with the 1907 build result [enabled on Windows or when using 1908 --with-freetype, disabled otherwise] 1909 --enable-sjavac use sjavac to do fast incremental compiles 1910 [disabled] 1911 --disable-javac-server disable javac server [enabled] 1912 --enable-icecc enable distribted compilation of native code using 1913 icecc/icecream [disabled] 1914 --disable-precompiled-headers 1915 disable using precompiled headers when compiling C++ 1916 [enabled] 1917 --enable-ccache enable using ccache to speed up recompilations 1918 [disabled] 1919 1920 Optional Packages: 1921 --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] 1922 --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) 1923 --with-target-bits build 32-bit or 64-bit binaries (for platforms that 1924 support it), e.g. --with-target-bits=32 [guessed] 1925 --with-custom-make-dir Deprecated. Option is kept for backwards 1926 compatibility and is ignored 1927 --with-jdk-variant JDK variant to build (normal) [normal] 1928 --with-jvm-interpreter JVM interpreter to build (template, cpp) [template] 1929 --with-jvm-variants JVM variants (separated by commas) to build (server, 1930 client, minimal1, zero, zeroshark, core) [server] 1931 --with-debug-level set the debug level (release, fastdebug, slowdebug, 1932 optimized (HotSpot build only)) [release] 1933 --with-devkit use this devkit for compilers, tools and resources 1934 --with-sys-root alias for --with-sysroot for backwards compatability 1935 --with-sysroot use this directory as sysroot 1936 --with-tools-dir alias for --with-toolchain-path for backwards 1937 compatibility 1938 --with-toolchain-path prepend these directories when searching for 1939 toolchain binaries (compilers etc) 1940 --with-extra-path prepend these directories to the default path 1941 --with-sdk-name use the platform SDK of the given name. [macosx] 1942 --with-conf-name use this as the name of the configuration [generated 1943 from important configuration options] 1944 --with-output-sync set make output sync type if supported by make. 1945 [recurse] 1946 --with-default-make-target 1947 set the default make target [exploded-image] 1948 --with-cacerts-file specify alternative cacerts file 1949 --with-copyright-year Set copyright year value for build [current year] 1950 --with-milestone Deprecated. Option is kept for backwards 1951 compatibility and is ignored 1952 --with-update-version Deprecated. Option is kept for backwards 1953 compatibility and is ignored 1954 --with-user-release-suffix 1955 Deprecated. Option is kept for backwards 1956 compatibility and is ignored 1957 --with-build-number Deprecated. Option is kept for backwards 1958 compatibility and is ignored 1959 --with-version-string Set version string [calculated] 1960 --with-version-pre Set the base part of the version 'PRE' field 1961 (pre-release identifier) ['internal'] 1962 --with-version-opt Set version 'OPT' field (build metadata) 1963 [<timestamp>.<user>.<dirname>] 1964 --with-version-build Set version 'BUILD' field (build number) [not 1965 specified] 1966 --with-version-major Set version 'MAJOR' field (first number) [current 1967 source value] 1968 --with-version-minor Set version 'MINOR' field (second number) [current 1969 source value] 1970 --with-version-security Set version 'SECURITY' field (third number) [current 1971 source value] 1972 --with-version-patch Set version 'PATCH' field (fourth number) [not 1973 specified] 1974 --with-boot-jdk path to Boot JDK (used to bootstrap build) [probed] 1975 --with-add-source-root Deprecated. Option is kept for backwards 1976 compatibility and is ignored 1977 --with-override-source-root 1978 Deprecated. Option is kept for backwards 1979 compatibility and is ignored 1980 --with-adds-and-overrides 1981 Deprecated. Option is kept for backwards 1982 compatibility and is ignored 1983 --with-override-langtools 1984 Deprecated. Option is kept for backwards 1985 compatibility and is ignored 1986 --with-override-corba Deprecated. Option is kept for backwards 1987 compatibility and is ignored 1988 --with-override-jaxp Deprecated. Option is kept for backwards 1989 compatibility and is ignored 1990 --with-override-jaxws Deprecated. Option is kept for backwards 1991 compatibility and is ignored 1992 --with-override-hotspot Deprecated. Option is kept for backwards 1993 compatibility and is ignored 1994 --with-override-nashorn Deprecated. Option is kept for backwards 1995 compatibility and is ignored 1996 --with-override-jdk Deprecated. Option is kept for backwards 1997 compatibility and is ignored 1998 --with-import-hotspot import hotspot binaries from this jdk image or 1999 hotspot build dist dir instead of building from 2000 source 2001 --with-toolchain-type the toolchain type (or family) to use, use '--help' 2002 to show possible values [platform dependent] 2003 --with-extra-cflags extra flags to be used when compiling jdk c-files 2004 --with-extra-cxxflags extra flags to be used when compiling jdk c++-files 2005 --with-extra-ldflags extra flags to be used when linking jdk 2006 --with-toolchain-version 2007 the version of the toolchain to look for, use 2008 '--help' to show possible values [platform 2009 dependent] 2010 --with-build-devkit Devkit to use for the build platform toolchain 2011 --with-jtreg Regression Test Harness [probed] 2012 --with-native-debug-symbols 2013 set the native debug symbol configuration (none, 2014 internal, external, zipped) [zipped] 2015 --with-stdc++lib=<static>,<dynamic>,<default> 2016 force linking of the C++ runtime on Linux to either 2017 static or dynamic, default is static with dynamic as 2018 fallback 2019 --with-msvcr-dll path to microsoft C runtime dll (msvcr*.dll) 2020 (Windows only) [probed] 2021 --with-msvcp-dll path to microsoft C++ runtime dll (msvcp*.dll) 2022 (Windows only) [probed] 2023 --with-x use the X Window System 2024 --with-cups specify prefix directory for the cups package 2025 (expecting the headers under PATH/include) 2026 --with-cups-include specify directory for the cups include files 2027 --with-freetype specify prefix directory for the freetype package 2028 (expecting the libraries under PATH/lib and the 2029 headers under PATH/include) 2030 --with-freetype-include specify directory for the freetype include files 2031 --with-freetype-lib specify directory for the freetype library 2032 --with-freetype-src specify directory with freetype sources to 2033 automatically build the library (experimental, 2034 Windows-only) 2035 --with-alsa specify prefix directory for the alsa package 2036 (expecting the libraries under PATH/lib and the 2037 headers under PATH/include) 2038 --with-alsa-include specify directory for the alsa include files 2039 --with-alsa-lib specify directory for the alsa library 2040 --with-libffi specify prefix directory for the libffi package 2041 (expecting the libraries under PATH/lib and the 2042 headers under PATH/include) 2043 --with-libffi-include specify directory for the libffi include files 2044 --with-libffi-lib specify directory for the libffi library 2045 --with-libjpeg use libjpeg from build system or OpenJDK source 2046 (system, bundled) [bundled] 2047 --with-giflib use giflib from build system or OpenJDK source 2048 (system, bundled) [bundled] 2049 --with-libpng use libpng from build system or OpenJDK source 2050 (system, bundled) [bundled] 2051 --with-zlib use zlib from build system or OpenJDK source 2052 (system, bundled) [bundled] 2053 --with-lcms use lcms2 from build system or OpenJDK source 2054 (system, bundled) [bundled] 2055 --with-dxsdk Deprecated. Option is kept for backwards 2056 compatibility and is ignored 2057 --with-dxsdk-lib Deprecated. Option is kept for backwards 2058 compatibility and is ignored 2059 --with-dxsdk-include Deprecated. Option is kept for backwards 2060 compatibility and is ignored 2061 --with-num-cores number of cores in the build system, e.g. 2062 --with-num-cores=8 [probed] 2063 --with-memory-size memory (in MB) available in the build system, e.g. 2064 --with-memory-size=1024 [probed] 2065 --with-jobs number of parallel jobs to let make run [calculated 2066 based on cores and memory] 2067 --with-test-jobs number of parallel tests jobs to run [based on build 2068 jobs] 2069 --with-boot-jdk-jvmargs specify JVM arguments to be passed to all java 2070 invocations of boot JDK, overriding the default 2071 values, e.g --with-boot-jdk-jvmargs="-Xmx8G 2072 -enableassertions" 2073 --with-sjavac-server-java 2074 use this java binary for running the sjavac 2075 background server [Boot JDK java] 2076 --with-ccache-dir where to store ccache files [~/.ccache] 2077 2078 Some influential environment variables: 2079 BASENAME Override default value for BASENAME 2080 BASH Override default value for BASH 2081 CAT Override default value for CAT 2082 CHMOD Override default value for CHMOD 2083 CMP Override default value for CMP 2084 COMM Override default value for COMM 2085 CP Override default value for CP 2086 CUT Override default value for CUT 2087 DATE Override default value for DATE 2088 DIFF Override default value for DIFF 2089 DIRNAME Override default value for DIRNAME 2090 ECHO Override default value for ECHO 2091 EXPR Override default value for EXPR 2092 FILE Override default value for FILE 2093 FIND Override default value for FIND 2094 HEAD Override default value for HEAD 2095 LN Override default value for LN 2096 LS Override default value for LS 2097 MKDIR Override default value for MKDIR 2098 MKTEMP Override default value for MKTEMP 2099 MV Override default value for MV 2100 NAWK Override default value for NAWK 2101 PRINTF Override default value for PRINTF 2102 RM Override default value for RM 2103 RMDIR Override default value for RMDIR 2104 SH Override default value for SH 2105 SORT Override default value for SORT 2106 TAIL Override default value for TAIL 2107 TAR Override default value for TAR 2108 TEE Override default value for TEE 2109 TOUCH Override default value for TOUCH 2110 TR Override default value for TR 2111 UNAME Override default value for UNAME 2112 UNIQ Override default value for UNIQ 2113 WC Override default value for WC 2114 WHICH Override default value for WHICH 2115 XARGS Override default value for XARGS 2116 AWK Override default value for AWK 2117 GREP Override default value for GREP 2118 EGREP Override default value for EGREP 2119 FGREP Override default value for FGREP 2120 SED Override default value for SED 2121 CYGPATH Override default value for CYGPATH 2122 READLINK Override default value for READLINK 2123 DF Override default value for DF 2124 CPIO Override default value for CPIO 2125 NICE Override default value for NICE 2126 MAKE Override default value for MAKE 2127 UNZIP Override default value for UNZIP 2128 ZIP Override default value for ZIP 2129 LDD Override default value for LDD 2130 OTOOL Override default value for OTOOL 2131 READELF Override default value for READELF 2132 HG Override default value for HG 2133 STAT Override default value for STAT 2134 TIME Override default value for TIME 2135 PATCH Override default value for PATCH 2136 DSYMUTIL Override default value for DSYMUTIL 2137 XATTR Override default value for XATTR 2138 CODESIGN Override default value for CODESIGN 2139 SETFILE Override default value for SETFILE 2140 PKG_CONFIG path to pkg-config utility 2141 JAVA Override default value for JAVA 2142 JAVAC Override default value for JAVAC 2143 JAVAH Override default value for JAVAH 2144 JAR Override default value for JAR 2145 JARSIGNER Override default value for JARSIGNER 2146 CC C compiler command 2147 CFLAGS C compiler flags 2148 LDFLAGS linker flags, e.g. -L<lib dir> if you have libraries in a 2149 nonstandard directory <lib dir> 2150 LIBS libraries to pass to the linker, e.g. -l<library> 2151 CPPFLAGS (Objective) C/C++ preprocessor flags, e.g. -I<include dir> if 2152 you have headers in a nonstandard directory <include dir> 2153 CXX C++ compiler command 2154 CXXFLAGS C++ compiler flags 2155 CPP C preprocessor 2156 CXXCPP C++ preprocessor 2157 AS Override default value for AS 2158 AR Override default value for AR 2159 LIPO Override default value for LIPO 2160 STRIP Override default value for STRIP 2161 NM Override default value for NM 2162 GNM Override default value for GNM 2163 OBJCOPY Override default value for OBJCOPY 2164 OBJDUMP Override default value for OBJDUMP 2165 BUILD_CC Override default value for BUILD_CC 2166 BUILD_CXX Override default value for BUILD_CXX 2167 BUILD_NM Override default value for BUILD_NM 2168 BUILD_AR Override default value for BUILD_AR 2169 JTREGEXE Override default value for JTREGEXE 2170 XMKMF Path to xmkmf, Makefile generator for X Window System 2171 FREETYPE_CFLAGS 2172 C compiler flags for FREETYPE, overriding pkg-config 2173 FREETYPE_LIBS 2174 linker flags for FREETYPE, overriding pkg-config 2175 ALSA_CFLAGS C compiler flags for ALSA, overriding pkg-config 2176 ALSA_LIBS linker flags for ALSA, overriding pkg-config 2177 LIBFFI_CFLAGS 2178 C compiler flags for LIBFFI, overriding pkg-config 2179 LIBFFI_LIBS linker flags for LIBFFI, overriding pkg-config 2180 PNG_CFLAGS C compiler flags for PNG, overriding pkg-config 2181 PNG_LIBS linker flags for PNG, overriding pkg-config 2182 LCMS_CFLAGS C compiler flags for LCMS, overriding pkg-config 2183 LCMS_LIBS linker flags for LCMS, overriding pkg-config 2184 ICECC_CMD Override default value for ICECC_CMD 2185 ICECC_CREATE_ENV 2186 Override default value for ICECC_CREATE_ENV 2187 ICECC_WRAPPER 2188 Override default value for ICECC_WRAPPER 2189 CCACHE Override default value for CCACHE 2190 2191 Use these variables to override the choices made by `configure' or to help 2192 it to find libraries and programs with nonstandard names/locations. 2193 2194 Report bugs to <build-dev@openjdk.java.net>. 2195 OpenJDK home page: <http://openjdk.java.net>. 2196 _ACEOF 2197 ac_status=$? 2198 fi 2199 2200 if test "$ac_init_help" = "recursive"; then 2201 # If there are subdirs, report their specific --help. 2202 for ac_dir in : $ac_subdirs_all; do test "x$ac_dir" = x: && continue 2203 test -d "$ac_dir" || 2204 { cd "$srcdir" && ac_pwd=`pwd` && srcdir=. && test -d "$ac_dir"; } || 2205 continue 2206 ac_builddir=. 2207 2208 case "$ac_dir" in 2209 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; 2210 *) 2211 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` 2212 # A ".." for each directory in $ac_dir_suffix. 2213 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` 2214 case $ac_top_builddir_sub in 2215 "") ac_top_builddir_sub=. ac_top_build_prefix= ;; 2216 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; 2217 esac ;; 2218 esac 2219 ac_abs_top_builddir=$ac_pwd 2220 ac_abs_builddir=$ac_pwd$ac_dir_suffix 2221 # for backward compatibility: 2222 ac_top_builddir=$ac_top_build_prefix 2223 2224 case $srcdir in 2225 .) # We are building in place. 2226 ac_srcdir=. 2227 ac_top_srcdir=$ac_top_builddir_sub 2228 ac_abs_top_srcdir=$ac_pwd ;; 2229 [\\/]* | ?:[\\/]* ) # Absolute name. 2230 ac_srcdir=$srcdir$ac_dir_suffix; 2231 ac_top_srcdir=$srcdir 2232 ac_abs_top_srcdir=$srcdir ;; 2233 *) # Relative name. 2234 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix 2235 ac_top_srcdir=$ac_top_build_prefix$srcdir 2236 ac_abs_top_srcdir=$ac_pwd/$srcdir ;; 2237 esac 2238 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix 2239 2240 cd "$ac_dir" || { ac_status=$?; continue; } 2241 # Check for guested configure. 2242 if test -f "$ac_srcdir/configure.gnu"; then 2243 echo && 2244 $SHELL "$ac_srcdir/configure.gnu" --help=recursive 2245 elif test -f "$ac_srcdir/configure"; then 2246 echo && 2247 $SHELL "$ac_srcdir/configure" --help=recursive 2248 else 2249 $as_echo "$as_me: WARNING: no configuration information is in $ac_dir" >&2 2250 fi || ac_status=$? 2251 cd "$ac_pwd" || { ac_status=$?; break; } 2252 done 2253 fi 2254 2255 test -n "$ac_init_help" && exit $ac_status 2256 if $ac_init_version; then 2257 cat <<\_ACEOF 2258 OpenJDK configure jdk9 2259 generated by GNU Autoconf 2.69 2260 2261 Copyright (C) 2012 Free Software Foundation, Inc. 2262 This configure script is free software; the Free Software Foundation 2263 gives unlimited permission to copy, distribute and modify it. 2264 _ACEOF 2265 exit 2266 fi 2267 2268 ## ------------------------ ## 2269 ## Autoconf initialization. ## 2270 ## ------------------------ ## 2271 2272 # ac_fn_c_try_compile LINENO 2273 # -------------------------- 2274 # Try to compile conftest.$ac_ext, and return whether this succeeded. 2275 ac_fn_c_try_compile () 2276 { 2277 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2278 rm -f conftest.$ac_objext 2279 if { { ac_try="$ac_compile" 2280 case "(($ac_try" in 2281 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2282 *) ac_try_echo=$ac_try;; 2283 esac 2284 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2285 $as_echo "$ac_try_echo"; } >&5 2286 (eval "$ac_compile") 2>conftest.err 2287 ac_status=$? 2288 if test -s conftest.err; then 2289 grep -v '^ *+' conftest.err >conftest.er1 2290 cat conftest.er1 >&5 2291 mv -f conftest.er1 conftest.err 2292 fi 2293 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2294 test $ac_status = 0; } && { 2295 test -z "$ac_c_werror_flag" || 2296 test ! -s conftest.err 2297 } && test -s conftest.$ac_objext; then : 2298 ac_retval=0 2299 else 2300 $as_echo "$as_me: failed program was:" >&5 2301 sed 's/^/| /' conftest.$ac_ext >&5 2302 2303 ac_retval=1 2304 fi 2305 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2306 as_fn_set_status $ac_retval 2307 2308 } # ac_fn_c_try_compile 2309 2310 # ac_fn_cxx_try_compile LINENO 2311 # ---------------------------- 2312 # Try to compile conftest.$ac_ext, and return whether this succeeded. 2313 ac_fn_cxx_try_compile () 2314 { 2315 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2316 rm -f conftest.$ac_objext 2317 if { { ac_try="$ac_compile" 2318 case "(($ac_try" in 2319 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2320 *) ac_try_echo=$ac_try;; 2321 esac 2322 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2323 $as_echo "$ac_try_echo"; } >&5 2324 (eval "$ac_compile") 2>conftest.err 2325 ac_status=$? 2326 if test -s conftest.err; then 2327 grep -v '^ *+' conftest.err >conftest.er1 2328 cat conftest.er1 >&5 2329 mv -f conftest.er1 conftest.err 2330 fi 2331 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2332 test $ac_status = 0; } && { 2333 test -z "$ac_cxx_werror_flag" || 2334 test ! -s conftest.err 2335 } && test -s conftest.$ac_objext; then : 2336 ac_retval=0 2337 else 2338 $as_echo "$as_me: failed program was:" >&5 2339 sed 's/^/| /' conftest.$ac_ext >&5 2340 2341 ac_retval=1 2342 fi 2343 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2344 as_fn_set_status $ac_retval 2345 2346 } # ac_fn_cxx_try_compile 2347 2348 # ac_fn_c_try_cpp LINENO 2349 # ---------------------- 2350 # Try to preprocess conftest.$ac_ext, and return whether this succeeded. 2351 ac_fn_c_try_cpp () 2352 { 2353 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2354 if { { ac_try="$ac_cpp conftest.$ac_ext" 2355 case "(($ac_try" in 2356 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2357 *) ac_try_echo=$ac_try;; 2358 esac 2359 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2360 $as_echo "$ac_try_echo"; } >&5 2361 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err 2362 ac_status=$? 2363 if test -s conftest.err; then 2364 grep -v '^ *+' conftest.err >conftest.er1 2365 cat conftest.er1 >&5 2366 mv -f conftest.er1 conftest.err 2367 fi 2368 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2369 test $ac_status = 0; } > conftest.i && { 2370 test -z "$ac_c_preproc_warn_flag$ac_c_werror_flag" || 2371 test ! -s conftest.err 2372 }; then : 2373 ac_retval=0 2374 else 2375 $as_echo "$as_me: failed program was:" >&5 2376 sed 's/^/| /' conftest.$ac_ext >&5 2377 2378 ac_retval=1 2379 fi 2380 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2381 as_fn_set_status $ac_retval 2382 2383 } # ac_fn_c_try_cpp 2384 2385 # ac_fn_cxx_try_cpp LINENO 2386 # ------------------------ 2387 # Try to preprocess conftest.$ac_ext, and return whether this succeeded. 2388 ac_fn_cxx_try_cpp () 2389 { 2390 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2391 if { { ac_try="$ac_cpp conftest.$ac_ext" 2392 case "(($ac_try" in 2393 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2394 *) ac_try_echo=$ac_try;; 2395 esac 2396 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2397 $as_echo "$ac_try_echo"; } >&5 2398 (eval "$ac_cpp conftest.$ac_ext") 2>conftest.err 2399 ac_status=$? 2400 if test -s conftest.err; then 2401 grep -v '^ *+' conftest.err >conftest.er1 2402 cat conftest.er1 >&5 2403 mv -f conftest.er1 conftest.err 2404 fi 2405 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2406 test $ac_status = 0; } > conftest.i && { 2407 test -z "$ac_cxx_preproc_warn_flag$ac_cxx_werror_flag" || 2408 test ! -s conftest.err 2409 }; then : 2410 ac_retval=0 2411 else 2412 $as_echo "$as_me: failed program was:" >&5 2413 sed 's/^/| /' conftest.$ac_ext >&5 2414 2415 ac_retval=1 2416 fi 2417 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2418 as_fn_set_status $ac_retval 2419 2420 } # ac_fn_cxx_try_cpp 2421 2422 # ac_fn_c_try_link LINENO 2423 # ----------------------- 2424 # Try to link conftest.$ac_ext, and return whether this succeeded. 2425 ac_fn_c_try_link () 2426 { 2427 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2428 rm -f conftest.$ac_objext conftest$ac_exeext 2429 if { { ac_try="$ac_link" 2430 case "(($ac_try" in 2431 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2432 *) ac_try_echo=$ac_try;; 2433 esac 2434 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2435 $as_echo "$ac_try_echo"; } >&5 2436 (eval "$ac_link") 2>conftest.err 2437 ac_status=$? 2438 if test -s conftest.err; then 2439 grep -v '^ *+' conftest.err >conftest.er1 2440 cat conftest.er1 >&5 2441 mv -f conftest.er1 conftest.err 2442 fi 2443 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2444 test $ac_status = 0; } && { 2445 test -z "$ac_c_werror_flag" || 2446 test ! -s conftest.err 2447 } && test -s conftest$ac_exeext && { 2448 test "$cross_compiling" = yes || 2449 test -x conftest$ac_exeext 2450 }; 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 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information 2459 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would 2460 # interfere with the next link command; also delete a directory that is 2461 # left behind by Apple's compiler. We do this before executing the actions. 2462 rm -rf conftest.dSYM conftest_ipa8_conftest.oo 2463 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2464 as_fn_set_status $ac_retval 2465 2466 } # ac_fn_c_try_link 2467 2468 # ac_fn_cxx_check_header_mongrel LINENO HEADER VAR INCLUDES 2469 # --------------------------------------------------------- 2470 # Tests whether HEADER exists, giving a warning if it cannot be compiled using 2471 # the include files in INCLUDES and setting the cache variable VAR 2472 # accordingly. 2473 ac_fn_cxx_check_header_mongrel () 2474 { 2475 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2476 if eval \${$3+:} false; then : 2477 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2478 $as_echo_n "checking for $2... " >&6; } 2479 if eval \${$3+:} false; then : 2480 $as_echo_n "(cached) " >&6 2481 fi 2482 eval ac_res=\$$3 2483 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 2484 $as_echo "$ac_res" >&6; } 2485 else 2486 # Is the header compilable? 2487 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 usability" >&5 2488 $as_echo_n "checking $2 usability... " >&6; } 2489 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2490 /* end confdefs.h. */ 2491 $4 2492 #include <$2> 2493 _ACEOF 2494 if ac_fn_cxx_try_compile "$LINENO"; then : 2495 ac_header_compiler=yes 2496 else 2497 ac_header_compiler=no 2498 fi 2499 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2500 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_compiler" >&5 2501 $as_echo "$ac_header_compiler" >&6; } 2502 2503 # Is the header present? 2504 { $as_echo "$as_me:${as_lineno-$LINENO}: checking $2 presence" >&5 2505 $as_echo_n "checking $2 presence... " >&6; } 2506 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2507 /* end confdefs.h. */ 2508 #include <$2> 2509 _ACEOF 2510 if ac_fn_cxx_try_cpp "$LINENO"; then : 2511 ac_header_preproc=yes 2512 else 2513 ac_header_preproc=no 2514 fi 2515 rm -f conftest.err conftest.i conftest.$ac_ext 2516 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_header_preproc" >&5 2517 $as_echo "$ac_header_preproc" >&6; } 2518 2519 # So? What about this header? 2520 case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in #(( 2521 yes:no: ) 2522 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&5 2523 $as_echo "$as_me: WARNING: $2: accepted by the compiler, rejected by the preprocessor!" >&2;} 2524 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 2525 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} 2526 ;; 2527 no:yes:* ) 2528 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: present but cannot be compiled" >&5 2529 $as_echo "$as_me: WARNING: $2: present but cannot be compiled" >&2;} 2530 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: check for missing prerequisite headers?" >&5 2531 $as_echo "$as_me: WARNING: $2: check for missing prerequisite headers?" >&2;} 2532 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: see the Autoconf documentation" >&5 2533 $as_echo "$as_me: WARNING: $2: see the Autoconf documentation" >&2;} 2534 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&5 2535 $as_echo "$as_me: WARNING: $2: section \"Present But Cannot Be Compiled\"" >&2;} 2536 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $2: proceeding with the compiler's result" >&5 2537 $as_echo "$as_me: WARNING: $2: proceeding with the compiler's result" >&2;} 2538 ( $as_echo "## ----------------------------------------- ## 2539 ## Report this to build-dev@openjdk.java.net ## 2540 ## ----------------------------------------- ##" 2541 ) | sed "s/^/$as_me: WARNING: /" >&2 2542 ;; 2543 esac 2544 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2545 $as_echo_n "checking for $2... " >&6; } 2546 if eval \${$3+:} false; then : 2547 $as_echo_n "(cached) " >&6 2548 else 2549 eval "$3=\$ac_header_compiler" 2550 fi 2551 eval ac_res=\$$3 2552 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 2553 $as_echo "$ac_res" >&6; } 2554 fi 2555 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2556 2557 } # ac_fn_cxx_check_header_mongrel 2558 2559 # ac_fn_cxx_try_run LINENO 2560 # ------------------------ 2561 # Try to link conftest.$ac_ext, and return whether this succeeded. Assumes 2562 # that executables *can* be run. 2563 ac_fn_cxx_try_run () 2564 { 2565 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2566 if { { ac_try="$ac_link" 2567 case "(($ac_try" in 2568 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2569 *) ac_try_echo=$ac_try;; 2570 esac 2571 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2572 $as_echo "$ac_try_echo"; } >&5 2573 (eval "$ac_link") 2>&5 2574 ac_status=$? 2575 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2576 test $ac_status = 0; } && { ac_try='./conftest$ac_exeext' 2577 { { case "(($ac_try" in 2578 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2579 *) ac_try_echo=$ac_try;; 2580 esac 2581 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2582 $as_echo "$ac_try_echo"; } >&5 2583 (eval "$ac_try") 2>&5 2584 ac_status=$? 2585 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2586 test $ac_status = 0; }; }; then : 2587 ac_retval=0 2588 else 2589 $as_echo "$as_me: program exited with status $ac_status" >&5 2590 $as_echo "$as_me: failed program was:" >&5 2591 sed 's/^/| /' conftest.$ac_ext >&5 2592 2593 ac_retval=$ac_status 2594 fi 2595 rm -rf conftest.dSYM conftest_ipa8_conftest.oo 2596 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2597 as_fn_set_status $ac_retval 2598 2599 } # ac_fn_cxx_try_run 2600 2601 # ac_fn_cxx_check_header_compile LINENO HEADER VAR INCLUDES 2602 # --------------------------------------------------------- 2603 # Tests whether HEADER exists and can be compiled using the include files in 2604 # INCLUDES, setting the cache variable VAR accordingly. 2605 ac_fn_cxx_check_header_compile () 2606 { 2607 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2608 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2609 $as_echo_n "checking for $2... " >&6; } 2610 if eval \${$3+:} false; then : 2611 $as_echo_n "(cached) " >&6 2612 else 2613 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2614 /* end confdefs.h. */ 2615 $4 2616 #include <$2> 2617 _ACEOF 2618 if ac_fn_cxx_try_compile "$LINENO"; then : 2619 eval "$3=yes" 2620 else 2621 eval "$3=no" 2622 fi 2623 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2624 fi 2625 eval ac_res=\$$3 2626 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 2627 $as_echo "$ac_res" >&6; } 2628 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2629 2630 } # ac_fn_cxx_check_header_compile 2631 2632 # ac_fn_cxx_compute_int LINENO EXPR VAR INCLUDES 2633 # ---------------------------------------------- 2634 # Tries to find the compile-time value of EXPR in a program that includes 2635 # INCLUDES, setting VAR accordingly. Returns whether the value could be 2636 # computed 2637 ac_fn_cxx_compute_int () 2638 { 2639 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2640 if test "$cross_compiling" = yes; then 2641 # Depending upon the size, compute the lo and hi bounds. 2642 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2643 /* end confdefs.h. */ 2644 $4 2645 int 2646 main () 2647 { 2648 static int test_array [1 - 2 * !(($2) >= 0)]; 2649 test_array [0] = 0; 2650 return test_array [0]; 2651 2652 ; 2653 return 0; 2654 } 2655 _ACEOF 2656 if ac_fn_cxx_try_compile "$LINENO"; then : 2657 ac_lo=0 ac_mid=0 2658 while :; do 2659 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2660 /* end confdefs.h. */ 2661 $4 2662 int 2663 main () 2664 { 2665 static int test_array [1 - 2 * !(($2) <= $ac_mid)]; 2666 test_array [0] = 0; 2667 return test_array [0]; 2668 2669 ; 2670 return 0; 2671 } 2672 _ACEOF 2673 if ac_fn_cxx_try_compile "$LINENO"; then : 2674 ac_hi=$ac_mid; break 2675 else 2676 as_fn_arith $ac_mid + 1 && ac_lo=$as_val 2677 if test $ac_lo -le $ac_mid; then 2678 ac_lo= ac_hi= 2679 break 2680 fi 2681 as_fn_arith 2 '*' $ac_mid + 1 && ac_mid=$as_val 2682 fi 2683 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2684 done 2685 else 2686 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2687 /* end confdefs.h. */ 2688 $4 2689 int 2690 main () 2691 { 2692 static int test_array [1 - 2 * !(($2) < 0)]; 2693 test_array [0] = 0; 2694 return test_array [0]; 2695 2696 ; 2697 return 0; 2698 } 2699 _ACEOF 2700 if ac_fn_cxx_try_compile "$LINENO"; then : 2701 ac_hi=-1 ac_mid=-1 2702 while :; do 2703 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2704 /* end confdefs.h. */ 2705 $4 2706 int 2707 main () 2708 { 2709 static int test_array [1 - 2 * !(($2) >= $ac_mid)]; 2710 test_array [0] = 0; 2711 return test_array [0]; 2712 2713 ; 2714 return 0; 2715 } 2716 _ACEOF 2717 if ac_fn_cxx_try_compile "$LINENO"; then : 2718 ac_lo=$ac_mid; break 2719 else 2720 as_fn_arith '(' $ac_mid ')' - 1 && ac_hi=$as_val 2721 if test $ac_mid -le $ac_hi; then 2722 ac_lo= ac_hi= 2723 break 2724 fi 2725 as_fn_arith 2 '*' $ac_mid && ac_mid=$as_val 2726 fi 2727 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2728 done 2729 else 2730 ac_lo= ac_hi= 2731 fi 2732 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2733 fi 2734 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2735 # Binary search between lo and hi bounds. 2736 while test "x$ac_lo" != "x$ac_hi"; do 2737 as_fn_arith '(' $ac_hi - $ac_lo ')' / 2 + $ac_lo && ac_mid=$as_val 2738 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2739 /* end confdefs.h. */ 2740 $4 2741 int 2742 main () 2743 { 2744 static int test_array [1 - 2 * !(($2) <= $ac_mid)]; 2745 test_array [0] = 0; 2746 return test_array [0]; 2747 2748 ; 2749 return 0; 2750 } 2751 _ACEOF 2752 if ac_fn_cxx_try_compile "$LINENO"; then : 2753 ac_hi=$ac_mid 2754 else 2755 as_fn_arith '(' $ac_mid ')' + 1 && ac_lo=$as_val 2756 fi 2757 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2758 done 2759 case $ac_lo in #(( 2760 ?*) eval "$3=\$ac_lo"; ac_retval=0 ;; 2761 '') ac_retval=1 ;; 2762 esac 2763 else 2764 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2765 /* end confdefs.h. */ 2766 $4 2767 static long int longval () { return $2; } 2768 static unsigned long int ulongval () { return $2; } 2769 #include <stdio.h> 2770 #include <stdlib.h> 2771 int 2772 main () 2773 { 2774 2775 FILE *f = fopen ("conftest.val", "w"); 2776 if (! f) 2777 return 1; 2778 if (($2) < 0) 2779 { 2780 long int i = longval (); 2781 if (i != ($2)) 2782 return 1; 2783 fprintf (f, "%ld", i); 2784 } 2785 else 2786 { 2787 unsigned long int i = ulongval (); 2788 if (i != ($2)) 2789 return 1; 2790 fprintf (f, "%lu", i); 2791 } 2792 /* Do not output a trailing newline, as this causes \r\n confusion 2793 on some platforms. */ 2794 return ferror (f) || fclose (f) != 0; 2795 2796 ; 2797 return 0; 2798 } 2799 _ACEOF 2800 if ac_fn_cxx_try_run "$LINENO"; then : 2801 echo >>conftest.val; read $3 <conftest.val; ac_retval=0 2802 else 2803 ac_retval=1 2804 fi 2805 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 2806 conftest.$ac_objext conftest.beam conftest.$ac_ext 2807 rm -f conftest.val 2808 2809 fi 2810 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2811 as_fn_set_status $ac_retval 2812 2813 } # ac_fn_cxx_compute_int 2814 2815 # ac_fn_cxx_try_link LINENO 2816 # ------------------------- 2817 # Try to link conftest.$ac_ext, and return whether this succeeded. 2818 ac_fn_cxx_try_link () 2819 { 2820 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2821 rm -f conftest.$ac_objext conftest$ac_exeext 2822 if { { ac_try="$ac_link" 2823 case "(($ac_try" in 2824 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 2825 *) ac_try_echo=$ac_try;; 2826 esac 2827 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 2828 $as_echo "$ac_try_echo"; } >&5 2829 (eval "$ac_link") 2>conftest.err 2830 ac_status=$? 2831 if test -s conftest.err; then 2832 grep -v '^ *+' conftest.err >conftest.er1 2833 cat conftest.er1 >&5 2834 mv -f conftest.er1 conftest.err 2835 fi 2836 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 2837 test $ac_status = 0; } && { 2838 test -z "$ac_cxx_werror_flag" || 2839 test ! -s conftest.err 2840 } && test -s conftest$ac_exeext && { 2841 test "$cross_compiling" = yes || 2842 test -x conftest$ac_exeext 2843 }; then : 2844 ac_retval=0 2845 else 2846 $as_echo "$as_me: failed program was:" >&5 2847 sed 's/^/| /' conftest.$ac_ext >&5 2848 2849 ac_retval=1 2850 fi 2851 # Delete the IPA/IPO (Inter Procedural Analysis/Optimization) information 2852 # created by the PGI compiler (conftest_ipa8_conftest.oo), as it would 2853 # interfere with the next link command; also delete a directory that is 2854 # left behind by Apple's compiler. We do this before executing the actions. 2855 rm -rf conftest.dSYM conftest_ipa8_conftest.oo 2856 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2857 as_fn_set_status $ac_retval 2858 2859 } # ac_fn_cxx_try_link 2860 2861 # ac_fn_cxx_check_func LINENO FUNC VAR 2862 # ------------------------------------ 2863 # Tests whether FUNC exists, setting the cache variable VAR accordingly 2864 ac_fn_cxx_check_func () 2865 { 2866 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2867 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2868 $as_echo_n "checking for $2... " >&6; } 2869 if eval \${$3+:} false; then : 2870 $as_echo_n "(cached) " >&6 2871 else 2872 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2873 /* end confdefs.h. */ 2874 /* Define $2 to an innocuous variant, in case <limits.h> declares $2. 2875 For example, HP-UX 11i <limits.h> declares gettimeofday. */ 2876 #define $2 innocuous_$2 2877 2878 /* System header to define __stub macros and hopefully few prototypes, 2879 which can conflict with char $2 (); below. 2880 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 2881 <limits.h> exists even on freestanding compilers. */ 2882 2883 #ifdef __STDC__ 2884 # include <limits.h> 2885 #else 2886 # include <assert.h> 2887 #endif 2888 2889 #undef $2 2890 2891 /* Override any GCC internal prototype to avoid an error. 2892 Use char because int might match the return type of a GCC 2893 builtin and then its argument prototype would still apply. */ 2894 #ifdef __cplusplus 2895 extern "C" 2896 #endif 2897 char $2 (); 2898 /* The GNU C library defines this for functions which it implements 2899 to always fail with ENOSYS. Some functions are actually named 2900 something starting with __ and the normal name is an alias. */ 2901 #if defined __stub_$2 || defined __stub___$2 2902 choke me 2903 #endif 2904 2905 int 2906 main () 2907 { 2908 return $2 (); 2909 ; 2910 return 0; 2911 } 2912 _ACEOF 2913 if ac_fn_cxx_try_link "$LINENO"; then : 2914 eval "$3=yes" 2915 else 2916 eval "$3=no" 2917 fi 2918 rm -f core conftest.err conftest.$ac_objext \ 2919 conftest$ac_exeext conftest.$ac_ext 2920 fi 2921 eval ac_res=\$$3 2922 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 2923 $as_echo "$ac_res" >&6; } 2924 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2925 2926 } # ac_fn_cxx_check_func 2927 2928 # ac_fn_c_check_header_compile LINENO HEADER VAR INCLUDES 2929 # ------------------------------------------------------- 2930 # Tests whether HEADER exists and can be compiled using the include files in 2931 # INCLUDES, setting the cache variable VAR accordingly. 2932 ac_fn_c_check_header_compile () 2933 { 2934 as_lineno=${as_lineno-"$1"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 2935 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $2" >&5 2936 $as_echo_n "checking for $2... " >&6; } 2937 if eval \${$3+:} false; then : 2938 $as_echo_n "(cached) " >&6 2939 else 2940 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 2941 /* end confdefs.h. */ 2942 $4 2943 #include <$2> 2944 _ACEOF 2945 if ac_fn_c_try_compile "$LINENO"; then : 2946 eval "$3=yes" 2947 else 2948 eval "$3=no" 2949 fi 2950 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 2951 fi 2952 eval ac_res=\$$3 2953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 2954 $as_echo "$ac_res" >&6; } 2955 eval $as_lineno_stack; ${as_lineno_stack:+:} unset as_lineno 2956 2957 } # ac_fn_c_check_header_compile 2958 cat >config.log <<_ACEOF 2959 This file contains any messages produced by compilers while 2960 running configure, to aid debugging if configure makes a mistake. 2961 2962 It was created by OpenJDK $as_me jdk9, which was 2963 generated by GNU Autoconf 2.69. Invocation command line was 2964 2965 $ $0 $@ 2966 2967 _ACEOF 2968 exec 5>>config.log 2969 { 2970 cat <<_ASUNAME 2971 ## --------- ## 2972 ## Platform. ## 2973 ## --------- ## 2974 2975 hostname = `(hostname || uname -n) 2>/dev/null | sed 1q` 2976 uname -m = `(uname -m) 2>/dev/null || echo unknown` 2977 uname -r = `(uname -r) 2>/dev/null || echo unknown` 2978 uname -s = `(uname -s) 2>/dev/null || echo unknown` 2979 uname -v = `(uname -v) 2>/dev/null || echo unknown` 2980 2981 /usr/bin/uname -p = `(/usr/bin/uname -p) 2>/dev/null || echo unknown` 2982 /bin/uname -X = `(/bin/uname -X) 2>/dev/null || echo unknown` 2983 2984 /bin/arch = `(/bin/arch) 2>/dev/null || echo unknown` 2985 /usr/bin/arch -k = `(/usr/bin/arch -k) 2>/dev/null || echo unknown` 2986 /usr/convex/getsysinfo = `(/usr/convex/getsysinfo) 2>/dev/null || echo unknown` 2987 /usr/bin/hostinfo = `(/usr/bin/hostinfo) 2>/dev/null || echo unknown` 2988 /bin/machine = `(/bin/machine) 2>/dev/null || echo unknown` 2989 /usr/bin/oslevel = `(/usr/bin/oslevel) 2>/dev/null || echo unknown` 2990 /bin/universe = `(/bin/universe) 2>/dev/null || echo unknown` 2991 2992 _ASUNAME 2993 2994 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 2995 for as_dir in $PATH 2996 do 2997 IFS=$as_save_IFS 2998 test -z "$as_dir" && as_dir=. 2999 $as_echo "PATH: $as_dir" 3000 done 3001 IFS=$as_save_IFS 3002 3003 } >&5 3004 3005 cat >&5 <<_ACEOF 3006 3007 3008 ## ----------- ## 3009 ## Core tests. ## 3010 ## ----------- ## 3011 3012 _ACEOF 3013 3014 3015 # Keep a trace of the command line. 3016 # Strip out --no-create and --no-recursion so they do not pile up. 3017 # Strip out --silent because we don't want to record it for future runs. 3018 # Also quote any args containing shell meta-characters. 3019 # Make two passes to allow for proper duplicate-argument suppression. 3020 ac_configure_args= 3021 ac_configure_args0= 3022 ac_configure_args1= 3023 ac_must_keep_next=false 3024 for ac_pass in 1 2 3025 do 3026 for ac_arg 3027 do 3028 case $ac_arg in 3029 -no-create | --no-c* | -n | -no-recursion | --no-r*) continue ;; 3030 -q | -quiet | --quiet | --quie | --qui | --qu | --q \ 3031 | -silent | --silent | --silen | --sile | --sil) 3032 continue ;; 3033 *\'*) 3034 ac_arg=`$as_echo "$ac_arg" | sed "s/'/'\\\\\\\\''/g"` ;; 3035 esac 3036 case $ac_pass in 3037 1) as_fn_append ac_configure_args0 " '$ac_arg'" ;; 3038 2) 3039 as_fn_append ac_configure_args1 " '$ac_arg'" 3040 if test $ac_must_keep_next = true; then 3041 ac_must_keep_next=false # Got value, back to normal. 3042 else 3043 case $ac_arg in 3044 *=* | --config-cache | -C | -disable-* | --disable-* \ 3045 | -enable-* | --enable-* | -gas | --g* | -nfp | --nf* \ 3046 | -q | -quiet | --q* | -silent | --sil* | -v | -verb* \ 3047 | -with-* | --with-* | -without-* | --without-* | --x) 3048 case "$ac_configure_args0 " in 3049 "$ac_configure_args1"*" '$ac_arg' "* ) continue ;; 3050 esac 3051 ;; 3052 -* ) ac_must_keep_next=true ;; 3053 esac 3054 fi 3055 as_fn_append ac_configure_args " '$ac_arg'" 3056 ;; 3057 esac 3058 done 3059 done 3060 { ac_configure_args0=; unset ac_configure_args0;} 3061 { ac_configure_args1=; unset ac_configure_args1;} 3062 3063 # When interrupted or exit'd, cleanup temporary files, and complete 3064 # config.log. We remove comments because anyway the quotes in there 3065 # would cause problems or look ugly. 3066 # WARNING: Use '\'' to represent an apostrophe within the trap. 3067 # WARNING: Do not start the trap code with a newline, due to a FreeBSD 4.0 bug. 3068 trap 'exit_status=$? 3069 # Save into config.log some information that might help in debugging. 3070 { 3071 echo 3072 3073 $as_echo "## ---------------- ## 3074 ## Cache variables. ## 3075 ## ---------------- ##" 3076 echo 3077 # The following way of writing the cache mishandles newlines in values, 3078 ( 3079 for ac_var in `(set) 2>&1 | sed -n '\''s/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'\''`; do 3080 eval ac_val=\$$ac_var 3081 case $ac_val in #( 3082 *${as_nl}*) 3083 case $ac_var in #( 3084 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 3085 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; 3086 esac 3087 case $ac_var in #( 3088 _ | IFS | as_nl) ;; #( 3089 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( 3090 *) { eval $ac_var=; unset $ac_var;} ;; 3091 esac ;; 3092 esac 3093 done 3094 (set) 2>&1 | 3095 case $as_nl`(ac_space='\'' '\''; set) 2>&1` in #( 3096 *${as_nl}ac_space=\ *) 3097 sed -n \ 3098 "s/'\''/'\''\\\\'\'''\''/g; 3099 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\''\\2'\''/p" 3100 ;; #( 3101 *) 3102 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" 3103 ;; 3104 esac | 3105 sort 3106 ) 3107 echo 3108 3109 $as_echo "## ----------------- ## 3110 ## Output variables. ## 3111 ## ----------------- ##" 3112 echo 3113 for ac_var in $ac_subst_vars 3114 do 3115 eval ac_val=\$$ac_var 3116 case $ac_val in 3117 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; 3118 esac 3119 $as_echo "$ac_var='\''$ac_val'\''" 3120 done | sort 3121 echo 3122 3123 if test -n "$ac_subst_files"; then 3124 $as_echo "## ------------------- ## 3125 ## File substitutions. ## 3126 ## ------------------- ##" 3127 echo 3128 for ac_var in $ac_subst_files 3129 do 3130 eval ac_val=\$$ac_var 3131 case $ac_val in 3132 *\'\''*) ac_val=`$as_echo "$ac_val" | sed "s/'\''/'\''\\\\\\\\'\'''\''/g"`;; 3133 esac 3134 $as_echo "$ac_var='\''$ac_val'\''" 3135 done | sort 3136 echo 3137 fi 3138 3139 if test -s confdefs.h; then 3140 $as_echo "## ----------- ## 3141 ## confdefs.h. ## 3142 ## ----------- ##" 3143 echo 3144 cat confdefs.h 3145 echo 3146 fi 3147 test "$ac_signal" != 0 && 3148 $as_echo "$as_me: caught signal $ac_signal" 3149 $as_echo "$as_me: exit $exit_status" 3150 } >&5 3151 rm -f core *.core core.conftest.* && 3152 rm -f -r conftest* confdefs* conf$$* $ac_clean_files && 3153 exit $exit_status 3154 ' 0 3155 for ac_signal in 1 2 13 15; do 3156 trap 'ac_signal='$ac_signal'; as_fn_exit 1' $ac_signal 3157 done 3158 ac_signal=0 3159 3160 # confdefs.h avoids OS command line length limits that DEFS can exceed. 3161 rm -f -r conftest* confdefs.h 3162 3163 $as_echo "/* confdefs.h */" > confdefs.h 3164 3165 # Predefined preprocessor variables. 3166 3167 cat >>confdefs.h <<_ACEOF 3168 #define PACKAGE_NAME "$PACKAGE_NAME" 3169 _ACEOF 3170 3171 cat >>confdefs.h <<_ACEOF 3172 #define PACKAGE_TARNAME "$PACKAGE_TARNAME" 3173 _ACEOF 3174 3175 cat >>confdefs.h <<_ACEOF 3176 #define PACKAGE_VERSION "$PACKAGE_VERSION" 3177 _ACEOF 3178 3179 cat >>confdefs.h <<_ACEOF 3180 #define PACKAGE_STRING "$PACKAGE_STRING" 3181 _ACEOF 3182 3183 cat >>confdefs.h <<_ACEOF 3184 #define PACKAGE_BUGREPORT "$PACKAGE_BUGREPORT" 3185 _ACEOF 3186 3187 cat >>confdefs.h <<_ACEOF 3188 #define PACKAGE_URL "$PACKAGE_URL" 3189 _ACEOF 3190 3191 3192 # Let the site file select an alternate cache file if it wants to. 3193 # Prefer an explicitly selected file to automatically selected ones. 3194 ac_site_file1=NONE 3195 ac_site_file2=NONE 3196 if test -n "$CONFIG_SITE"; then 3197 # We do not want a PATH search for config.site. 3198 case $CONFIG_SITE in #(( 3199 -*) ac_site_file1=./$CONFIG_SITE;; 3200 */*) ac_site_file1=$CONFIG_SITE;; 3201 *) ac_site_file1=./$CONFIG_SITE;; 3202 esac 3203 elif test "x$prefix" != xNONE; then 3204 ac_site_file1=$prefix/share/config.site 3205 ac_site_file2=$prefix/etc/config.site 3206 else 3207 ac_site_file1=$ac_default_prefix/share/config.site 3208 ac_site_file2=$ac_default_prefix/etc/config.site 3209 fi 3210 for ac_site_file in "$ac_site_file1" "$ac_site_file2" 3211 do 3212 test "x$ac_site_file" = xNONE && continue 3213 if test /dev/null != "$ac_site_file" && test -r "$ac_site_file"; then 3214 { $as_echo "$as_me:${as_lineno-$LINENO}: loading site script $ac_site_file" >&5 3215 $as_echo "$as_me: loading site script $ac_site_file" >&6;} 3216 sed 's/^/| /' "$ac_site_file" >&5 3217 . "$ac_site_file" \ 3218 || { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 3219 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 3220 as_fn_error $? "failed to load site script $ac_site_file 3221 See \`config.log' for more details" "$LINENO" 5; } 3222 fi 3223 done 3224 3225 if test -r "$cache_file"; then 3226 # Some versions of bash will fail to source /dev/null (special files 3227 # actually), so we avoid doing that. DJGPP emulates it as a regular file. 3228 if test /dev/null != "$cache_file" && test -f "$cache_file"; then 3229 { $as_echo "$as_me:${as_lineno-$LINENO}: loading cache $cache_file" >&5 3230 $as_echo "$as_me: loading cache $cache_file" >&6;} 3231 case $cache_file in 3232 [\\/]* | ?:[\\/]* ) . "$cache_file";; 3233 *) . "./$cache_file";; 3234 esac 3235 fi 3236 else 3237 { $as_echo "$as_me:${as_lineno-$LINENO}: creating cache $cache_file" >&5 3238 $as_echo "$as_me: creating cache $cache_file" >&6;} 3239 >$cache_file 3240 fi 3241 3242 # Check that the precious variables saved in the cache have kept the same 3243 # value. 3244 ac_cache_corrupted=false 3245 for ac_var in $ac_precious_vars; do 3246 eval ac_old_set=\$ac_cv_env_${ac_var}_set 3247 eval ac_new_set=\$ac_env_${ac_var}_set 3248 eval ac_old_val=\$ac_cv_env_${ac_var}_value 3249 eval ac_new_val=\$ac_env_${ac_var}_value 3250 case $ac_old_set,$ac_new_set in 3251 set,) 3252 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&5 3253 $as_echo "$as_me: error: \`$ac_var' was set to \`$ac_old_val' in the previous run" >&2;} 3254 ac_cache_corrupted=: ;; 3255 ,set) 3256 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' was not set in the previous run" >&5 3257 $as_echo "$as_me: error: \`$ac_var' was not set in the previous run" >&2;} 3258 ac_cache_corrupted=: ;; 3259 ,);; 3260 *) 3261 if test "x$ac_old_val" != "x$ac_new_val"; then 3262 # differences in whitespace do not lead to failure. 3263 ac_old_val_w=`echo x $ac_old_val` 3264 ac_new_val_w=`echo x $ac_new_val` 3265 if test "$ac_old_val_w" != "$ac_new_val_w"; then 3266 { $as_echo "$as_me:${as_lineno-$LINENO}: error: \`$ac_var' has changed since the previous run:" >&5 3267 $as_echo "$as_me: error: \`$ac_var' has changed since the previous run:" >&2;} 3268 ac_cache_corrupted=: 3269 else 3270 { $as_echo "$as_me:${as_lineno-$LINENO}: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&5 3271 $as_echo "$as_me: warning: ignoring whitespace changes in \`$ac_var' since the previous run:" >&2;} 3272 eval $ac_var=\$ac_old_val 3273 fi 3274 { $as_echo "$as_me:${as_lineno-$LINENO}: former value: \`$ac_old_val'" >&5 3275 $as_echo "$as_me: former value: \`$ac_old_val'" >&2;} 3276 { $as_echo "$as_me:${as_lineno-$LINENO}: current value: \`$ac_new_val'" >&5 3277 $as_echo "$as_me: current value: \`$ac_new_val'" >&2;} 3278 fi;; 3279 esac 3280 # Pass precious variables to config.status. 3281 if test "$ac_new_set" = set; then 3282 case $ac_new_val in 3283 *\'*) ac_arg=$ac_var=`$as_echo "$ac_new_val" | sed "s/'/'\\\\\\\\''/g"` ;; 3284 *) ac_arg=$ac_var=$ac_new_val ;; 3285 esac 3286 case " $ac_configure_args " in 3287 *" '$ac_arg' "*) ;; # Avoid dups. Use of quotes ensures accuracy. 3288 *) as_fn_append ac_configure_args " '$ac_arg'" ;; 3289 esac 3290 fi 3291 done 3292 if $ac_cache_corrupted; then 3293 { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 3294 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 3295 { $as_echo "$as_me:${as_lineno-$LINENO}: error: changes in the environment can compromise the build" >&5 3296 $as_echo "$as_me: error: changes in the environment can compromise the build" >&2;} 3297 as_fn_error $? "run \`make distclean' and/or \`rm $cache_file' and start over" "$LINENO" 5 3298 fi 3299 ## -------------------- ## 3300 ## Main body of script. ## 3301 ## -------------------- ## 3302 3303 ac_ext=c 3304 ac_cpp='$CPP $CPPFLAGS' 3305 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 3306 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 3307 ac_compiler_gnu=$ac_cv_c_compiler_gnu 3308 3309 3310 3311 ac_aux_dir= 3312 for ac_dir in $TOPDIR/common/autoconf/build-aux "$srcdir"/$TOPDIR/common/autoconf/build-aux; do 3313 if test -f "$ac_dir/install-sh"; then 3314 ac_aux_dir=$ac_dir 3315 ac_install_sh="$ac_aux_dir/install-sh -c" 3316 break 3317 elif test -f "$ac_dir/install.sh"; then 3318 ac_aux_dir=$ac_dir 3319 ac_install_sh="$ac_aux_dir/install.sh -c" 3320 break 3321 elif test -f "$ac_dir/shtool"; then 3322 ac_aux_dir=$ac_dir 3323 ac_install_sh="$ac_aux_dir/shtool install -c" 3324 break 3325 fi 3326 done 3327 if test -z "$ac_aux_dir"; then 3328 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 3329 fi 3330 3331 # These three variables are undocumented and unsupported, 3332 # and are intended to be withdrawn in a future Autoconf release. 3333 # They can cause serious problems if a builder's source tree is in a directory 3334 # whose full name contains unusual characters. 3335 ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. 3336 ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. 3337 ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. 3338 3339 3340 # pkg.m4 - Macros to locate and utilise pkg-config. -*- Autoconf -*- 3341 3342 # 3343 # Copyright (c) 2012, 2013, Oracle and/or its affiliates. All rights reserved. 3344 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3345 # 3346 # This code is free software; you can redistribute it and/or modify it 3347 # under the terms of the GNU General Public License version 2 only, as 3348 # published by the Free Software Foundation. Oracle designates this 3349 # particular file as subject to the "Classpath" exception as provided 3350 # by Oracle in the LICENSE file that accompanied this code. 3351 # 3352 # This code is distributed in the hope that it will be useful, but WITHOUT 3353 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3354 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3355 # version 2 for more details (a copy is included in the LICENSE file that 3356 # accompanied this code). 3357 # 3358 # You should have received a copy of the GNU General Public License version 3359 # 2 along with this work; if not, write to the Free Software Foundation, 3360 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3361 # 3362 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3363 # or visit www.oracle.com if you need additional information or have any 3364 # questions. 3365 # 3366 3367 # 3368 # Copyright © 2004 Scott James Remnant <scott@netsplit.com>. 3369 # 3370 # This program is free software; you can redistribute it and/or modify 3371 # it under the terms of the GNU General Public License as published by 3372 # the Free Software Foundation; either version 2 of the License, or 3373 # (at your option) any later version. 3374 # 3375 # This program is distributed in the hope that it will be useful, but 3376 # WITHOUT ANY WARRANTY; without even the implied warranty of 3377 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 3378 # General Public License for more details. 3379 # 3380 # You should have received a copy of the GNU General Public License 3381 # along with this program; if not, write to the Free Software 3382 # Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 3383 # 3384 # As a special exception to the GNU General Public License, if you 3385 # distribute this file as part of a program that contains a 3386 # configuration script generated by Autoconf, you may include it under 3387 # the same distribution terms that you use for the rest of that program. 3388 3389 # PKG_PROG_PKG_CONFIG([MIN-VERSION]) 3390 # ---------------------------------- 3391 # PKG_PROG_PKG_CONFIG 3392 3393 # PKG_CHECK_EXISTS(MODULES, [ACTION-IF-FOUND], [ACTION-IF-NOT-FOUND]) 3394 # 3395 # Check to see whether a particular set of modules exists. Similar 3396 # to PKG_CHECK_MODULES(), but does not set variables or print errors. 3397 # 3398 # 3399 # Similar to PKG_CHECK_MODULES, make sure that the first instance of 3400 # this or PKG_CHECK_MODULES is called, or make sure to call 3401 # PKG_CHECK_EXISTS manually 3402 # -------------------------------------------------------------- 3403 3404 3405 3406 # _PKG_CONFIG([VARIABLE], [COMMAND], [MODULES]) 3407 # --------------------------------------------- 3408 # _PKG_CONFIG 3409 3410 # _PKG_SHORT_ERRORS_SUPPORTED 3411 # ----------------------------- 3412 # _PKG_SHORT_ERRORS_SUPPORTED 3413 3414 3415 # PKG_CHECK_MODULES(VARIABLE-PREFIX, MODULES, [ACTION-IF-FOUND], 3416 # [ACTION-IF-NOT-FOUND]) 3417 # 3418 # 3419 # Note that if there is a possibility the first call to 3420 # PKG_CHECK_MODULES might not happen, you should be sure to include an 3421 # explicit call to PKG_PROG_PKG_CONFIG in your configure.ac 3422 # 3423 # 3424 # -------------------------------------------------------------- 3425 # PKG_CHECK_MODULES 3426 3427 3428 # Include these first... 3429 # 3430 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. 3431 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3432 # 3433 # This code is free software; you can redistribute it and/or modify it 3434 # under the terms of the GNU General Public License version 2 only, as 3435 # published by the Free Software Foundation. Oracle designates this 3436 # particular file as subject to the "Classpath" exception as provided 3437 # by Oracle in the LICENSE file that accompanied this code. 3438 # 3439 # This code is distributed in the hope that it will be useful, but WITHOUT 3440 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3441 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3442 # version 2 for more details (a copy is included in the LICENSE file that 3443 # accompanied this code). 3444 # 3445 # You should have received a copy of the GNU General Public License version 3446 # 2 along with this work; if not, write to the Free Software Foundation, 3447 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3448 # 3449 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3450 # or visit www.oracle.com if you need additional information or have any 3451 # questions. 3452 # 3453 3454 # Test if $1 is a valid argument to $3 (often is $JAVA passed as $3) 3455 # If so, then append $1 to $2 \ 3456 # Also set JVM_ARG_OK to true/false depending on outcome. 3457 3458 3459 # Appends a string to a path variable, only adding the : when needed. 3460 3461 3462 # Prepends a string to a path variable, only adding the : when needed. 3463 3464 3465 # This will make sure the given variable points to a full and proper 3466 # path. This means: 3467 # 1) There will be no spaces in the path. On unix platforms, 3468 # spaces in the path will result in an error. On Windows, 3469 # the path will be rewritten using short-style to be space-free. 3470 # 2) The path will be absolute, and it will be in unix-style (on 3471 # cygwin). 3472 # $1: The name of the variable to fix 3473 3474 3475 # This will make sure the given variable points to a executable 3476 # with a full and proper path. This means: 3477 # 1) There will be no spaces in the path. On unix platforms, 3478 # spaces in the path will result in an error. On Windows, 3479 # the path will be rewritten using short-style to be space-free. 3480 # 2) The path will be absolute, and it will be in unix-style (on 3481 # cygwin). 3482 # Any arguments given to the executable is preserved. 3483 # If the input variable does not have a directory specification, then 3484 # it need to be in the PATH. 3485 # $1: The name of the variable to fix 3486 3487 3488 3489 3490 # Register a --with argument but mark it as deprecated 3491 # $1: The name of the with argument to deprecate, not including --with- 3492 3493 3494 # Register a --enable argument but mark it as deprecated 3495 # $1: The name of the with argument to deprecate, not including --enable- 3496 # $2: The name of the argument to deprecate, in shell variable style (i.e. with _ instead of -) 3497 # $3: Messages to user. 3498 3499 3500 3501 3502 # Test that variable $1 denoting a program is not empty. If empty, exit with an error. 3503 # $1: variable to check 3504 3505 3506 # Check that there are no unprocessed overridden variables left. 3507 # If so, they are an incorrect argument and we will exit with an error. 3508 3509 3510 # Setup a tool for the given variable. If correctly specified by the user, 3511 # use that value, otherwise search for the tool using the supplied code snippet. 3512 # $1: variable to set 3513 # $2: code snippet to call to look for the tool 3514 # $3: code snippet to call if variable was used to find tool 3515 3516 3517 # Call BASIC_SETUP_TOOL with AC_PATH_PROGS to locate the tool 3518 # $1: variable to set 3519 # $2: executable name (or list of names) to look for 3520 3521 3522 # Call BASIC_SETUP_TOOL with AC_CHECK_TOOLS to locate the tool 3523 # $1: variable to set 3524 # $2: executable name (or list of names) to look for 3525 3526 3527 # Like BASIC_PATH_PROGS but fails if no tool was found. 3528 # $1: variable to set 3529 # $2: executable name (or list of names) to look for 3530 3531 3532 # Like BASIC_SETUP_TOOL but fails if no tool was found. 3533 # $1: variable to set 3534 # $2: autoconf macro to call to look for the special tool 3535 3536 3537 # Setup the most fundamental tools that relies on not much else to set up, 3538 # but is used by much of the early bootstrap code. 3539 3540 3541 # Setup basic configuration paths, and platform-specific stuff related to PATHs. 3542 3543 3544 # Evaluates platform specific overrides for devkit variables. 3545 # $1: Name of variable 3546 3547 3548 3549 3550 3551 3552 #%%% Simple tools %%% 3553 3554 # Check if we have found a usable version of make 3555 # $1: the path to a potential make binary (or empty) 3556 # $2: the description on how we found this 3557 3558 3559 3560 3561 # Goes looking for a usable version of GNU make. 3562 3563 3564 3565 3566 3567 3568 # Check if build directory is on local disk. If not possible to determine, 3569 # we prefer to claim it's local. 3570 # Argument 1: directory to test 3571 # Argument 2: what to do if it is on local disk 3572 # Argument 3: what to do otherwise (remote disk or failure) 3573 3574 3575 # Check that source files have basic read permissions set. This might 3576 # not be the case in cygwin in certain conditions. 3577 3578 3579 3580 3581 # Check for support for specific options in bash 3582 3583 3584 ################################################################################ 3585 # 3586 # Default make target 3587 # 3588 3589 3590 # Code to run after AC_OUTPUT 3591 3592 3593 # 3594 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. 3595 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3596 # 3597 # This code is free software; you can redistribute it and/or modify it 3598 # under the terms of the GNU General Public License version 2 only, as 3599 # published by the Free Software Foundation. Oracle designates this 3600 # particular file as subject to the "Classpath" exception as provided 3601 # by Oracle in the LICENSE file that accompanied this code. 3602 # 3603 # This code is distributed in the hope that it will be useful, but WITHOUT 3604 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3605 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3606 # version 2 for more details (a copy is included in the LICENSE file that 3607 # accompanied this code). 3608 # 3609 # You should have received a copy of the GNU General Public License version 3610 # 2 along with this work; if not, write to the Free Software Foundation, 3611 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3612 # 3613 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3614 # or visit www.oracle.com if you need additional information or have any 3615 # questions. 3616 # 3617 3618 3619 3620 3621 3622 # Helper function which possibly converts a path using DOS-style short mode. 3623 # If so, the updated path is stored in $new_path. 3624 # $1: The path to check 3625 3626 3627 # Helper function which possibly converts a path using DOS-style short mode. 3628 # If so, the updated path is stored in $new_path. 3629 # $1: The path to check 3630 3631 3632 # FIXME: The BASIC_FIXUP_*_CYGWIN/MSYS is most likely too convoluted 3633 # and could probably be heavily simplified. However, all changes in this 3634 # area tend to need lot of testing in different scenarios, and in lack of 3635 # proper unit testing, cleaning this up has not been deemed worth the effort 3636 # at the moment. 3637 3638 3639 3640 3641 3642 3643 3644 3645 3646 # Setup basic configuration paths, and platform-specific stuff related to PATHs. 3647 3648 3649 3650 3651 # ... then the rest 3652 # 3653 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. 3654 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3655 # 3656 # This code is free software; you can redistribute it and/or modify it 3657 # under the terms of the GNU General Public License version 2 only, as 3658 # published by the Free Software Foundation. Oracle designates this 3659 # particular file as subject to the "Classpath" exception as provided 3660 # by Oracle in the LICENSE file that accompanied this code. 3661 # 3662 # This code is distributed in the hope that it will be useful, but WITHOUT 3663 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3664 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3665 # version 2 for more details (a copy is included in the LICENSE file that 3666 # accompanied this code). 3667 # 3668 # You should have received a copy of the GNU General Public License version 3669 # 2 along with this work; if not, write to the Free Software Foundation, 3670 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3671 # 3672 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3673 # or visit www.oracle.com if you need additional information or have any 3674 # questions. 3675 # 3676 3677 ######################################################################## 3678 # This file handles detection of the Boot JDK. The Boot JDK detection 3679 # process has been developed as a response to solve a complex real-world 3680 # problem. Initially, it was simple, but it has grown as platform after 3681 # platform, idiosyncracy after idiosyncracy has been supported. 3682 # 3683 # The basic idea is this: 3684 # 1) You need an acceptable *) JDK to use as a Boot JDK 3685 # 2) There are several ways to locate a JDK, that are mostly platform 3686 # dependent **) 3687 # 3) You can have multiple JDKs installed 3688 # 4) If possible, configure should try to dig out an acceptable JDK 3689 # automatically, without having to resort to command-line options 3690 # 3691 # *) acceptable means e.g. JDK7 for building JDK8, a complete JDK (with 3692 # javac) and not a JRE, etc. 3693 # 3694 # **) On Windows we typically use a well-known path. 3695 # On MacOSX we typically use the tool java_home. 3696 # On Linux we typically find javac in the $PATH, and then follow a 3697 # chain of symlinks that often ends up in a real JDK. 3698 # 3699 # This leads to the code where we check in different ways to locate a 3700 # JDK, and if one is found, check if it is acceptable. If not, we print 3701 # our reasons for rejecting it (useful when debugging non-working 3702 # configure situations) and continue checking the next one. 3703 ######################################################################## 3704 3705 # Execute the check given as argument, and verify the result 3706 # If the Boot JDK was previously found, do nothing 3707 # $1 A command line (typically autoconf macro) to execute 3708 3709 3710 # Test: Is bootjdk explicitely set by command line arguments? 3711 3712 3713 # Test: Is $JAVA_HOME set? 3714 3715 3716 # Test: Is there a java or javac in the PATH, which is a symlink to the JDK? 3717 3718 3719 # Test: Is there a /usr/libexec/java_home? (Typically on MacOSX) 3720 # $1: Argument to the java_home binary (optional) 3721 3722 3723 # Test: On MacOS X, can we find a boot jdk using /usr/libexec/java_home? 3724 3725 3726 # Look for a jdk in the given path. If there are multiple, try to select the newest. 3727 # If found, set BOOT_JDK and BOOT_JDK_FOUND. 3728 # $1 = Path to directory containing jdk installations. 3729 # $2 = String to append to the found JDK directory to get the proper JDK home 3730 3731 3732 # Call BOOTJDK_FIND_BEST_JDK_IN_DIRECTORY, but use the given 3733 # environmental variable as base for where to look. 3734 # $1 Name of an environmal variable, assumed to point to the Program Files directory. 3735 3736 3737 # Test: Is there a JDK installed in default, well-known locations? 3738 3739 3740 # Check that a command-line tool in the Boot JDK is correct 3741 # $1 = name of variable to assign 3742 # $2 = name of binary 3743 3744 3745 ############################################################################### 3746 # 3747 # We need a Boot JDK to bootstrap the build. 3748 # 3749 3750 3751 3752 3753 3754 # 3755 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. 3756 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3757 # 3758 # This code is free software; you can redistribute it and/or modify it 3759 # under the terms of the GNU General Public License version 2 only, as 3760 # published by the Free Software Foundation. Oracle designates this 3761 # particular file as subject to the "Classpath" exception as provided 3762 # by Oracle in the LICENSE file that accompanied this code. 3763 # 3764 # This code is distributed in the hope that it will be useful, but WITHOUT 3765 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3766 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3767 # version 2 for more details (a copy is included in the LICENSE file that 3768 # accompanied this code). 3769 # 3770 # You should have received a copy of the GNU General Public License version 3771 # 2 along with this work; if not, write to the Free Software Foundation, 3772 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3773 # 3774 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3775 # or visit www.oracle.com if you need additional information or have any 3776 # questions. 3777 # 3778 3779 3780 3781 3782 3783 3784 3785 3786 3787 3788 3789 3790 3791 3792 3793 3794 3795 ################################################################################ 3796 # 3797 # Runs icecc-create-env once and prints the error if it fails 3798 # 3799 # $1: arguments to icecc-create-env 3800 # $2: log file 3801 # 3802 3803 3804 ################################################################################ 3805 # 3806 # Optionally enable distributed compilation of native code using icecc/icecream 3807 # 3808 3809 3810 3811 3812 3813 3814 3815 # 3816 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. 3817 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3818 # 3819 # This code is free software; you can redistribute it and/or modify it 3820 # under the terms of the GNU General Public License version 2 only, as 3821 # published by the Free Software Foundation. Oracle designates this 3822 # particular file as subject to the "Classpath" exception as provided 3823 # by Oracle in the LICENSE file that accompanied this code. 3824 # 3825 # This code is distributed in the hope that it will be useful, but WITHOUT 3826 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3827 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3828 # version 2 for more details (a copy is included in the LICENSE file that 3829 # accompanied this code). 3830 # 3831 # You should have received a copy of the GNU General Public License version 3832 # 2 along with this work; if not, write to the Free Software Foundation, 3833 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3834 # 3835 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3836 # or visit www.oracle.com if you need additional information or have any 3837 # questions. 3838 # 3839 3840 # Reset the global CFLAGS/LDFLAGS variables and initialize them with the 3841 # corresponding configure arguments instead 3842 3843 3844 # Setup the sysroot flags and add them to global CFLAGS and LDFLAGS so 3845 # that configure can use them while detecting compilers. 3846 # TOOLCHAIN_TYPE is available here. 3847 # Param 1 - Optional prefix to all variables. (e.g BUILD_) 3848 3849 3850 3851 3852 3853 3854 # Documentation on common flags used for solstudio in HIGHEST. 3855 # 3856 # WARNING: Use of OPTIMIZATION_LEVEL=HIGHEST in your Makefile needs to be 3857 # done with care, there are some assumptions below that need to 3858 # be understood about the use of pointers, and IEEE behavior. 3859 # 3860 # -fns: Use non-standard floating point mode (not IEEE 754) 3861 # -fsimple: Do some simplification of floating point arithmetic (not IEEE 754) 3862 # -fsingle: Use single precision floating point with 'float' 3863 # -xalias_level=basic: Assume memory references via basic pointer types do not alias 3864 # (Source with excessing pointer casting and data access with mixed 3865 # pointer types are not recommended) 3866 # -xbuiltin=%all: Use intrinsic or inline versions for math/std functions 3867 # (If you expect perfect errno behavior, do not use this) 3868 # -xdepend: Loop data dependency optimizations (need -xO3 or higher) 3869 # -xrestrict: Pointer parameters to functions do not overlap 3870 # (Similar to -xalias_level=basic usage, but less obvious sometimes. 3871 # If you pass in multiple pointers to the same data, do not use this) 3872 # -xlibmil: Inline some library routines 3873 # (If you expect perfect errno behavior, do not use this) 3874 # -xlibmopt: Use optimized math routines (CURRENTLY DISABLED) 3875 # (If you expect perfect errno behavior, do not use this) 3876 # Can cause undefined external on Solaris 8 X86 on __sincos, removing for now 3877 3878 # FIXME: this will never happen since sparc != sparcv9, ie 32 bit, which we don't build anymore. 3879 # Bug? 3880 #if test "x$OPENJDK_TARGET_CPU" = xsparc; then 3881 # CFLAGS_JDK="${CFLAGS_JDK} -xmemalign=4s" 3882 # CXXFLAGS_JDK="${CXXFLAGS_JDK} -xmemalign=4s" 3883 #fi 3884 3885 3886 3887 3888 3889 # FLAGS_COMPILER_CHECK_ARGUMENTS([ARGUMENT], [RUN-IF-TRUE], 3890 # [RUN-IF-FALSE]) 3891 # ------------------------------------------------------------ 3892 # Check that the c and c++ compilers support an argument 3893 3894 3895 # FLAGS_LINKER_CHECK_ARGUMENTS([ARGUMENT], [RUN-IF-TRUE], 3896 # [RUN-IF-FALSE]) 3897 # ------------------------------------------------------------ 3898 # Check that the linker support an argument 3899 3900 3901 3902 3903 # 3904 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. 3905 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3906 # 3907 # This code is free software; you can redistribute it and/or modify it 3908 # under the terms of the GNU General Public License version 2 only, as 3909 # published by the Free Software Foundation. Oracle designates this 3910 # particular file as subject to the "Classpath" exception as provided 3911 # by Oracle in the LICENSE file that accompanied this code. 3912 # 3913 # This code is distributed in the hope that it will be useful, but WITHOUT 3914 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 3915 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 3916 # version 2 for more details (a copy is included in the LICENSE file that 3917 # accompanied this code). 3918 # 3919 # You should have received a copy of the GNU General Public License version 3920 # 2 along with this work; if not, write to the Free Software Foundation, 3921 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 3922 # 3923 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 3924 # or visit www.oracle.com if you need additional information or have any 3925 # questions. 3926 # 3927 3928 3929 3930 3931 3932 cygwin_help() { 3933 case $1 in 3934 unzip) 3935 PKGHANDLER_COMMAND="( cd <location of cygwin setup.exe> && cmd /c setup -q -P unzip )" 3936 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 3937 ;; 3938 zip) 3939 PKGHANDLER_COMMAND="( cd <location of cygwin setup.exe> && cmd /c setup -q -P zip )" 3940 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 3941 ;; 3942 make) 3943 PKGHANDLER_COMMAND="( cd <location of cygwin setup.exe> && cmd /c setup -q -P make )" 3944 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 3945 ;; 3946 freetype) 3947 HELP_MSG=" 3948 The freetype library can now be build during the configure process. 3949 Download the freetype sources and unpack them into an arbitrary directory: 3950 3951 wget http://download.savannah.gnu.org/releases/freetype/freetype-2.5.3.tar.gz 3952 tar -xzf freetype-2.5.3.tar.gz 3953 3954 Then run configure with '--with-freetype-src=<freetype_src>'. This will 3955 automatically build the freetype library into '<freetype_src>/lib64' for 64-bit 3956 builds or into '<freetype_src>/lib32' for 32-bit builds. 3957 Afterwards you can always use '--with-freetype-include=<freetype_src>/include' 3958 and '--with-freetype-lib=<freetype_src>/lib32|64' for other builds. 3959 3960 Alternatively you can unpack the sources like this to use the default directory: 3961 3962 tar --one-top-level=$HOME/freetype --strip-components=1 -xzf freetype-2.5.3.tar.gz" 3963 ;; 3964 esac 3965 } 3966 3967 msys_help() { 3968 PKGHANDLER_COMMAND="" 3969 } 3970 3971 apt_help() { 3972 case $1 in 3973 reduced) 3974 PKGHANDLER_COMMAND="sudo apt-get install gcc-multilib g++-multilib" ;; 3975 devkit) 3976 PKGHANDLER_COMMAND="sudo apt-get install build-essential" ;; 3977 openjdk) 3978 PKGHANDLER_COMMAND="sudo apt-get install openjdk-7-jdk" ;; 3979 alsa) 3980 PKGHANDLER_COMMAND="sudo apt-get install libasound2-dev" ;; 3981 cups) 3982 PKGHANDLER_COMMAND="sudo apt-get install libcups2-dev" ;; 3983 freetype) 3984 PKGHANDLER_COMMAND="sudo apt-get install libfreetype6-dev" ;; 3985 ffi) 3986 PKGHANDLER_COMMAND="sudo apt-get install libffi-dev" ;; 3987 x11) 3988 PKGHANDLER_COMMAND="sudo apt-get install libX11-dev libxext-dev libxrender-dev libxtst-dev libxt-dev" ;; 3989 ccache) 3990 PKGHANDLER_COMMAND="sudo apt-get install ccache" ;; 3991 esac 3992 } 3993 3994 yum_help() { 3995 case $1 in 3996 devkit) 3997 PKGHANDLER_COMMAND="sudo yum groupinstall \"Development Tools\"" ;; 3998 openjdk) 3999 PKGHANDLER_COMMAND="sudo yum install java-1.7.0-openjdk" ;; 4000 alsa) 4001 PKGHANDLER_COMMAND="sudo yum install alsa-lib-devel" ;; 4002 cups) 4003 PKGHANDLER_COMMAND="sudo yum install cups-devel" ;; 4004 freetype) 4005 PKGHANDLER_COMMAND="sudo yum install freetype-devel" ;; 4006 x11) 4007 PKGHANDLER_COMMAND="sudo yum install libXtst-devel libXt-devel libXrender-devel libXi-devel" ;; 4008 ccache) 4009 PKGHANDLER_COMMAND="sudo yum install ccache" ;; 4010 esac 4011 } 4012 4013 port_help() { 4014 PKGHANDLER_COMMAND="" 4015 } 4016 4017 pkgutil_help() { 4018 PKGHANDLER_COMMAND="" 4019 } 4020 4021 pkgadd_help() { 4022 PKGHANDLER_COMMAND="" 4023 } 4024 4025 # This function will check if we're called from the "configure" wrapper while 4026 # printing --help. If so, we will print out additional information that can 4027 # only be extracted within the autoconf script, and then exit. This must be 4028 # called at the very beginning in configure.ac. 4029 4030 4031 4032 4033 4034 4035 # 4036 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. 4037 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4038 # 4039 # This code is free software; you can redistribute it and/or modify it 4040 # under the terms of the GNU General Public License version 2 only, as 4041 # published by the Free Software Foundation. Oracle designates this 4042 # particular file as subject to the "Classpath" exception as provided 4043 # by Oracle in the LICENSE file that accompanied this code. 4044 # 4045 # This code is distributed in the hope that it will be useful, but WITHOUT 4046 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4047 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4048 # version 2 for more details (a copy is included in the LICENSE file that 4049 # accompanied this code). 4050 # 4051 # You should have received a copy of the GNU General Public License version 4052 # 2 along with this work; if not, write to the Free Software Foundation, 4053 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4054 # 4055 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4056 # or visit www.oracle.com if you need additional information or have any 4057 # questions. 4058 # 4059 4060 ############################################################################### 4061 # Check which interpreter of the JVM we want to build. 4062 # Currently we have: 4063 # template: Template interpreter (the default) 4064 # cpp : C++ interpreter 4065 4066 4067 ############################################################################### 4068 # Check which variants of the JVM that we want to build. 4069 # Currently we have: 4070 # server: normal interpreter and a C2 or tiered C1/C2 compiler 4071 # client: normal interpreter and C1 (no C2 compiler) (only 32-bit platforms) 4072 # minimal1: reduced form of client with optional VM services and features stripped out 4073 # zero: no machine code interpreter, no compiler 4074 # zeroshark: zero interpreter and shark/llvm compiler backend 4075 # core: interpreter only, no compiler (only works on some platforms) 4076 4077 4078 4079 ############################################################################### 4080 # Setup legacy vars/targets and new vars to deal with different debug levels. 4081 # 4082 # release: no debug information, all optimizations, no asserts. 4083 # optimized: no debug information, all optimizations, no asserts, HotSpot target is 'optimized'. 4084 # fastdebug: debug information (-g), all optimizations, all asserts 4085 # slowdebug: debug information (-g), no optimizations, all asserts 4086 # 4087 4088 4089 4090 4091 4092 4093 # 4094 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. 4095 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4096 # 4097 # This code is free software; you can redistribute it and/or modify it 4098 # under the terms of the GNU General Public License version 2 only, as 4099 # published by the Free Software Foundation. Oracle designates this 4100 # particular file as subject to the "Classpath" exception as provided 4101 # by Oracle in the LICENSE file that accompanied this code. 4102 # 4103 # This code is distributed in the hope that it will be useful, but WITHOUT 4104 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4105 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4106 # version 2 for more details (a copy is included in the LICENSE file that 4107 # accompanied this code). 4108 # 4109 # You should have received a copy of the GNU General Public License version 4110 # 2 along with this work; if not, write to the Free Software Foundation, 4111 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4112 # 4113 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4114 # or visit www.oracle.com if you need additional information or have any 4115 # questions. 4116 # 4117 4118 ############################################################################### 4119 # Check which variant of the JDK that we want to build. 4120 # Currently we have: 4121 # normal: standard edition 4122 # but the custom make system may add other variants 4123 # 4124 # Effectively the JDK variant gives a name to a specific set of 4125 # modules to compile into the JDK. 4126 4127 4128 ############################################################################### 4129 # Set the debug level 4130 # release: no debug information, all optimizations, no asserts. 4131 # optimized: no debug information, all optimizations, no asserts, HotSpot target is 'optimized'. 4132 # fastdebug: debug information (-g), all optimizations, all asserts 4133 # slowdebug: debug information (-g), no optimizations, all asserts 4134 4135 4136 ############################################################################### 4137 # 4138 # Should we build only OpenJDK even if closed sources are present? 4139 # 4140 4141 4142 4143 4144 ############################################################################### 4145 # 4146 # Enable or disable the elliptic curve crypto implementation 4147 # 4148 4149 4150 4151 4152 ################################################################################ 4153 # 4154 # Gcov coverage data for hotspot 4155 # 4156 4157 4158 ################################################################################ 4159 # 4160 # Static build support. When enabled will generate static 4161 # libraries instead of shared libraries for all JDK libs. 4162 # 4163 4164 4165 # 4166 # Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. 4167 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4168 # 4169 # This code is free software; you can redistribute it and/or modify it 4170 # under the terms of the GNU General Public License version 2 only, as 4171 # published by the Free Software Foundation. Oracle designates this 4172 # particular file as subject to the "Classpath" exception as provided 4173 # by Oracle in the LICENSE file that accompanied this code. 4174 # 4175 # This code is distributed in the hope that it will be useful, but WITHOUT 4176 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4177 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4178 # version 2 for more details (a copy is included in the LICENSE file that 4179 # accompanied this code). 4180 # 4181 # You should have received a copy of the GNU General Public License version 4182 # 2 along with this work; if not, write to the Free Software Foundation, 4183 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4184 # 4185 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4186 # or visit www.oracle.com if you need additional information or have any 4187 # questions. 4188 # 4189 4190 ############################################################################### 4191 # 4192 # Setup version numbers 4193 # 4194 4195 # Verify that a given string represents a valid version number, and assign it 4196 # to a variable. 4197 4198 # Argument 1: the variable to assign to 4199 # Argument 2: the value given by the user 4200 4201 4202 4203 4204 # 4205 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. 4206 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4207 # 4208 # This code is free software; you can redistribute it and/or modify it 4209 # under the terms of the GNU General Public License version 2 only, as 4210 # published by the Free Software Foundation. Oracle designates this 4211 # particular file as subject to the "Classpath" exception as provided 4212 # by Oracle in the LICENSE file that accompanied this code. 4213 # 4214 # This code is distributed in the hope that it will be useful, but WITHOUT 4215 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4216 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4217 # version 2 for more details (a copy is included in the LICENSE file that 4218 # accompanied this code). 4219 # 4220 # You should have received a copy of the GNU General Public License version 4221 # 2 along with this work; if not, write to the Free Software Foundation, 4222 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4223 # 4224 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4225 # or visit www.oracle.com if you need additional information or have any 4226 # questions. 4227 # 4228 4229 # Major library component reside in separate files. 4230 # 4231 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. 4232 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4233 # 4234 # This code is free software; you can redistribute it and/or modify it 4235 # under the terms of the GNU General Public License version 2 only, as 4236 # published by the Free Software Foundation. Oracle designates this 4237 # particular file as subject to the "Classpath" exception as provided 4238 # by Oracle in the LICENSE file that accompanied this code. 4239 # 4240 # This code is distributed in the hope that it will be useful, but WITHOUT 4241 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4242 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4243 # version 2 for more details (a copy is included in the LICENSE file that 4244 # accompanied this code). 4245 # 4246 # You should have received a copy of the GNU General Public License version 4247 # 2 along with this work; if not, write to the Free Software Foundation, 4248 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4249 # 4250 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4251 # or visit www.oracle.com if you need additional information or have any 4252 # questions. 4253 # 4254 4255 ################################################################################ 4256 # Setup alsa (Advanced Linux Sound Architecture) 4257 ################################################################################ 4258 4259 4260 # 4261 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. 4262 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4263 # 4264 # This code is free software; you can redistribute it and/or modify it 4265 # under the terms of the GNU General Public License version 2 only, as 4266 # published by the Free Software Foundation. Oracle designates this 4267 # particular file as subject to the "Classpath" exception as provided 4268 # by Oracle in the LICENSE file that accompanied this code. 4269 # 4270 # This code is distributed in the hope that it will be useful, but WITHOUT 4271 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4272 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4273 # version 2 for more details (a copy is included in the LICENSE file that 4274 # accompanied this code). 4275 # 4276 # You should have received a copy of the GNU General Public License version 4277 # 2 along with this work; if not, write to the Free Software Foundation, 4278 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4279 # 4280 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4281 # or visit www.oracle.com if you need additional information or have any 4282 # questions. 4283 # 4284 4285 ################################################################################ 4286 # Setup bundled libraries. 4287 # 4288 # For libjpeg, giflib, libpng, lcms2 and zlib, the source is present in the 4289 # OpenJDK repository. Default is to use these libraries as bundled, but they 4290 # might be replaced by en external version by the user. 4291 ################################################################################ 4292 4293 4294 ################################################################################ 4295 # Setup libjpeg 4296 ################################################################################ 4297 4298 4299 ################################################################################ 4300 # Setup giflib 4301 ################################################################################ 4302 4303 4304 ################################################################################ 4305 # Setup libpng 4306 ################################################################################ 4307 4308 4309 ################################################################################ 4310 # Setup zlib 4311 ################################################################################ 4312 4313 4314 ################################################################################ 4315 # Setup lcms (Little CMS) 4316 ################################################################################ 4317 4318 4319 # 4320 # Copyright (c) 2011, 2016, Oracle and/or its affiliates. All rights reserved. 4321 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4322 # 4323 # This code is free software; you can redistribute it and/or modify it 4324 # under the terms of the GNU General Public License version 2 only, as 4325 # published by the Free Software Foundation. Oracle designates this 4326 # particular file as subject to the "Classpath" exception as provided 4327 # by Oracle in the LICENSE file that accompanied this code. 4328 # 4329 # This code is distributed in the hope that it will be useful, but WITHOUT 4330 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4331 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4332 # version 2 for more details (a copy is included in the LICENSE file that 4333 # accompanied this code). 4334 # 4335 # You should have received a copy of the GNU General Public License version 4336 # 2 along with this work; if not, write to the Free Software Foundation, 4337 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4338 # 4339 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4340 # or visit www.oracle.com if you need additional information or have any 4341 # questions. 4342 # 4343 4344 ################################################################################ 4345 # Setup cups (Common Unix Printing System) 4346 ################################################################################ 4347 4348 4349 # 4350 # Copyright (c) 2015, Oracle and/or its affiliates. All rights reserved. 4351 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4352 # 4353 # This code is free software; you can redistribute it and/or modify it 4354 # under the terms of the GNU General Public License version 2 only, as 4355 # published by the Free Software Foundation. Oracle designates this 4356 # particular file as subject to the "Classpath" exception as provided 4357 # by Oracle in the LICENSE file that accompanied this code. 4358 # 4359 # This code is distributed in the hope that it will be useful, but WITHOUT 4360 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4361 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4362 # version 2 for more details (a copy is included in the LICENSE file that 4363 # accompanied this code). 4364 # 4365 # You should have received a copy of the GNU General Public License version 4366 # 2 along with this work; if not, write to the Free Software Foundation, 4367 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4368 # 4369 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4370 # or visit www.oracle.com if you need additional information or have any 4371 # questions. 4372 # 4373 4374 ################################################################################ 4375 # Setup libffi (Foreign Function Interface) 4376 ################################################################################ 4377 4378 4379 # 4380 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. 4381 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4382 # 4383 # This code is free software; you can redistribute it and/or modify it 4384 # under the terms of the GNU General Public License version 2 only, as 4385 # published by the Free Software Foundation. Oracle designates this 4386 # particular file as subject to the "Classpath" exception as provided 4387 # by Oracle in the LICENSE file that accompanied this code. 4388 # 4389 # This code is distributed in the hope that it will be useful, but WITHOUT 4390 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4391 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4392 # version 2 for more details (a copy is included in the LICENSE file that 4393 # accompanied this code). 4394 # 4395 # You should have received a copy of the GNU General Public License version 4396 # 2 along with this work; if not, write to the Free Software Foundation, 4397 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4398 # 4399 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4400 # or visit www.oracle.com if you need additional information or have any 4401 # questions. 4402 # 4403 4404 ################################################################################ 4405 # Build the freetype lib from source 4406 ################################################################################ 4407 4408 4409 ################################################################################ 4410 # Check if a potential freeype library match is correct and usable 4411 ################################################################################ 4412 4413 4414 ################################################################################ 4415 # Setup freetype (The FreeType2 font rendering library) 4416 ################################################################################ 4417 4418 4419 # 4420 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. 4421 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4422 # 4423 # This code is free software; you can redistribute it and/or modify it 4424 # under the terms of the GNU General Public License version 2 only, as 4425 # published by the Free Software Foundation. Oracle designates this 4426 # particular file as subject to the "Classpath" exception as provided 4427 # by Oracle in the LICENSE file that accompanied this code. 4428 # 4429 # This code is distributed in the hope that it will be useful, but WITHOUT 4430 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4431 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4432 # version 2 for more details (a copy is included in the LICENSE file that 4433 # accompanied this code). 4434 # 4435 # You should have received a copy of the GNU General Public License version 4436 # 2 along with this work; if not, write to the Free Software Foundation, 4437 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4438 # 4439 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4440 # or visit www.oracle.com if you need additional information or have any 4441 # questions. 4442 # 4443 4444 ################################################################################ 4445 # Setup the standard C/C++ runtime libraries. 4446 # 4447 # Most importantly, determine if stdc++ should be linked statically or 4448 # dynamically. 4449 ################################################################################ 4450 4451 4452 # 4453 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. 4454 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4455 # 4456 # This code is free software; you can redistribute it and/or modify it 4457 # under the terms of the GNU General Public License version 2 only, as 4458 # published by the Free Software Foundation. Oracle designates this 4459 # particular file as subject to the "Classpath" exception as provided 4460 # by Oracle in the LICENSE file that accompanied this code. 4461 # 4462 # This code is distributed in the hope that it will be useful, but WITHOUT 4463 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4464 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4465 # version 2 for more details (a copy is included in the LICENSE file that 4466 # accompanied this code). 4467 # 4468 # You should have received a copy of the GNU General Public License version 4469 # 2 along with this work; if not, write to the Free Software Foundation, 4470 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4471 # 4472 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4473 # or visit www.oracle.com if you need additional information or have any 4474 # questions. 4475 # 4476 4477 ################################################################################ 4478 # Setup X11 Windows system 4479 ################################################################################ 4480 4481 4482 4483 ################################################################################ 4484 # Determine which libraries are needed for this configuration 4485 ################################################################################ 4486 4487 4488 ################################################################################ 4489 # Parse library options, and setup needed libraries 4490 ################################################################################ 4491 4492 4493 ################################################################################ 4494 # Setup llvm (Low-Level VM) 4495 ################################################################################ 4496 4497 4498 ################################################################################ 4499 # Setup various libraries, typically small system libraries 4500 ################################################################################ 4501 4502 4503 # 4504 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. 4505 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4506 # 4507 # This code is free software; you can redistribute it and/or modify it 4508 # under the terms of the GNU General Public License version 2 only, as 4509 # published by the Free Software Foundation. Oracle designates this 4510 # particular file as subject to the "Classpath" exception as provided 4511 # by Oracle in the LICENSE file that accompanied this code. 4512 # 4513 # This code is distributed in the hope that it will be useful, but WITHOUT 4514 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4515 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4516 # version 2 for more details (a copy is included in the LICENSE file that 4517 # accompanied this code). 4518 # 4519 # You should have received a copy of the GNU General Public License version 4520 # 2 along with this work; if not, write to the Free Software Foundation, 4521 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4522 # 4523 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4524 # or visit www.oracle.com if you need additional information or have any 4525 # questions. 4526 # 4527 4528 # Support macro for PLATFORM_EXTRACT_TARGET_AND_BUILD. 4529 # Converts autoconf style CPU name to OpenJDK style, into 4530 # VAR_CPU, VAR_CPU_ARCH, VAR_CPU_BITS and VAR_CPU_ENDIAN. 4531 4532 4533 # Support macro for PLATFORM_EXTRACT_TARGET_AND_BUILD. 4534 # Converts autoconf style OS name to OpenJDK style, into 4535 # VAR_OS, VAR_OS_TYPE and VAR_OS_ENV. 4536 4537 4538 # Expects $host_os $host_cpu $build_os and $build_cpu 4539 # and $with_target_bits to have been setup! 4540 # 4541 # Translate the standard triplet(quadruplet) definition 4542 # of the target/build system into OPENJDK_TARGET_OS, OPENJDK_TARGET_CPU, 4543 # OPENJDK_BUILD_OS, etc. 4544 4545 4546 # Check if a reduced build (32-bit on 64-bit platforms) is requested, and modify behaviour 4547 # accordingly. Must be done after setting up build and target system, but before 4548 # doing anything else with these values. 4549 4550 4551 # Setup the legacy variables, for controlling the old makefiles. 4552 # 4553 4554 4555 4556 4557 #%%% Build and target systems %%% 4558 4559 4560 4561 4562 # Support macro for PLATFORM_SETUP_OPENJDK_TARGET_BITS. 4563 # Add -mX to various FLAGS variables. 4564 4565 4566 4567 4568 4569 4570 # 4571 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. 4572 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4573 # 4574 # This code is free software; you can redistribute it and/or modify it 4575 # under the terms of the GNU General Public License version 2 only, as 4576 # published by the Free Software Foundation. Oracle designates this 4577 # particular file as subject to the "Classpath" exception as provided 4578 # by Oracle in the LICENSE file that accompanied this code. 4579 # 4580 # This code is distributed in the hope that it will be useful, but WITHOUT 4581 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4582 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4583 # version 2 for more details (a copy is included in the LICENSE file that 4584 # accompanied this code). 4585 # 4586 # You should have received a copy of the GNU General Public License version 4587 # 2 along with this work; if not, write to the Free Software Foundation, 4588 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4589 # 4590 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4591 # or visit www.oracle.com if you need additional information or have any 4592 # questions. 4593 # 4594 4595 4596 4597 4598 4599 4600 4601 # 4602 # Copyright (c) 2011, 2015, Oracle and/or its affiliates. All rights reserved. 4603 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4604 # 4605 # This code is free software; you can redistribute it and/or modify it 4606 # under the terms of the GNU General Public License version 2 only, as 4607 # published by the Free Software Foundation. Oracle designates this 4608 # particular file as subject to the "Classpath" exception as provided 4609 # by Oracle in the LICENSE file that accompanied this code. 4610 # 4611 # This code is distributed in the hope that it will be useful, but WITHOUT 4612 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4613 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4614 # version 2 for more details (a copy is included in the LICENSE file that 4615 # accompanied this code). 4616 # 4617 # You should have received a copy of the GNU General Public License version 4618 # 2 along with this work; if not, write to the Free Software Foundation, 4619 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4620 # 4621 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4622 # or visit www.oracle.com if you need additional information or have any 4623 # questions. 4624 # 4625 4626 ######################################################################## 4627 # This file is responsible for detecting, verifying and setting up the 4628 # toolchain, i.e. the compiler, linker and related utilities. It will setup 4629 # proper paths to the binaries, but it will not setup any flags. 4630 # 4631 # The binaries used is determined by the toolchain type, which is the family of 4632 # compilers and related tools that are used. 4633 ######################################################################## 4634 4635 4636 # All valid toolchains, regardless of platform (used by help.m4) 4637 VALID_TOOLCHAINS_all="gcc clang solstudio xlc microsoft" 4638 4639 # These toolchains are valid on different platforms 4640 VALID_TOOLCHAINS_linux="gcc clang" 4641 VALID_TOOLCHAINS_solaris="solstudio" 4642 VALID_TOOLCHAINS_macosx="gcc clang" 4643 VALID_TOOLCHAINS_aix="xlc" 4644 VALID_TOOLCHAINS_windows="microsoft" 4645 4646 # Toolchain descriptions 4647 TOOLCHAIN_DESCRIPTION_clang="clang/LLVM" 4648 TOOLCHAIN_DESCRIPTION_gcc="GNU Compiler Collection" 4649 TOOLCHAIN_DESCRIPTION_microsoft="Microsoft Visual Studio" 4650 TOOLCHAIN_DESCRIPTION_solstudio="Oracle Solaris Studio" 4651 TOOLCHAIN_DESCRIPTION_xlc="IBM XL C/C++" 4652 4653 # Setup a number of variables describing how native output files are 4654 # named on this platform/toolchain. 4655 4656 4657 # Determine which toolchain type to use, and make sure it is valid for this 4658 # platform. Setup various information about the selected toolchain. 4659 4660 4661 # Before we start detecting the toolchain executables, we might need some 4662 # special setup, e.g. additional paths etc. 4663 4664 4665 # Restore path, etc 4666 4667 4668 # Check if a compiler is of the toolchain type we expect, and save the version 4669 # information from it. If the compiler does not match the expected type, 4670 # this function will abort using AC_MSG_ERROR. If it matches, the version will 4671 # be stored in CC_VERSION_NUMBER/CXX_VERSION_NUMBER (as a dotted number), and 4672 # the full version string in CC_VERSION_STRING/CXX_VERSION_STRING. 4673 # 4674 # $1 = compiler to test (CC or CXX) 4675 # $2 = human readable name of compiler (C or C++) 4676 4677 4678 # Try to locate the given C or C++ compiler in the path, or otherwise. 4679 # 4680 # $1 = compiler to test (CC or CXX) 4681 # $2 = human readable name of compiler (C or C++) 4682 # $3 = list of compiler names to search for 4683 4684 4685 # Detect the core components of the toolchain, i.e. the compilers (CC and CXX), 4686 # preprocessor (CPP and CXXCPP), the linker (LD), the assembler (AS) and the 4687 # archiver (AR). Verify that the compilers are correct according to the 4688 # toolchain type. 4689 4690 4691 # Setup additional tools that is considered a part of the toolchain, but not the 4692 # core part. Many of these are highly platform-specific and do not exist, 4693 # and/or are not needed on all platforms. 4694 4695 4696 # Setup the build tools (i.e, the compiler and linker used to build programs 4697 # that should be run on the build platform, not the target platform, as a build 4698 # helper). Since the non-cross-compile case uses the normal, target compilers 4699 # for this, we can only do this after these have been setup. 4700 4701 4702 # Setup legacy variables that are still needed as alternative ways to refer to 4703 # parts of the toolchain. 4704 4705 4706 # Do some additional checks on the detected tools. 4707 4708 4709 # Setup the JTReg Regression Test Harness. 4710 4711 4712 # 4713 # Copyright (c) 2011, 2012, Oracle and/or its affiliates. All rights reserved. 4714 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4715 # 4716 # This code is free software; you can redistribute it and/or modify it 4717 # under the terms of the GNU General Public License version 2 only, as 4718 # published by the Free Software Foundation. Oracle designates this 4719 # particular file as subject to the "Classpath" exception as provided 4720 # by Oracle in the LICENSE file that accompanied this code. 4721 # 4722 # This code is distributed in the hope that it will be useful, but WITHOUT 4723 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 4724 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 4725 # version 2 for more details (a copy is included in the LICENSE file that 4726 # accompanied this code). 4727 # 4728 # You should have received a copy of the GNU General Public License version 4729 # 2 along with this work; if not, write to the Free Software Foundation, 4730 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 4731 # 4732 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 4733 # or visit www.oracle.com if you need additional information or have any 4734 # questions. 4735 # 4736 4737 ################################################################################ 4738 # The order of these defines the priority by which we try to find them. 4739 VALID_VS_VERSIONS="2013 2012 2010" 4740 4741 VS_DESCRIPTION_2010="Microsoft Visual Studio 2010" 4742 VS_VERSION_INTERNAL_2010=100 4743 VS_MSVCR_2010=msvcr100.dll 4744 # We don't use msvcp on Visual Studio 2010 4745 #VS_MSVCP_2010=msvcp100.dll 4746 VS_ENVVAR_2010="VS100COMNTOOLS" 4747 VS_VS_INSTALLDIR_2010="Microsoft Visual Studio 10.0" 4748 VS_SDK_INSTALLDIR_2010="Microsoft SDKs/Windows/v7.1" 4749 VS_VS_PLATFORM_NAME_2010="v100" 4750 VS_SDK_PLATFORM_NAME_2010="Windows7.1SDK" 4751 4752 VS_DESCRIPTION_2012="Microsoft Visual Studio 2012" 4753 VS_VERSION_INTERNAL_2012=110 4754 VS_MSVCR_2012=msvcr110.dll 4755 VS_MSVCP_2012=msvcp110.dll 4756 VS_ENVVAR_2012="VS110COMNTOOLS" 4757 VS_VS_INSTALLDIR_2012="Microsoft Visual Studio 11.0" 4758 VS_SDK_INSTALLDIR_2012= 4759 VS_VS_PLATFORM_NAME_2012="v110" 4760 VS_SDK_PLATFORM_NAME_2012= 4761 4762 VS_DESCRIPTION_2013="Microsoft Visual Studio 2013" 4763 VS_VERSION_INTERNAL_2013=120 4764 VS_MSVCR_2013=msvcr120.dll 4765 VS_MSVCP_2013=msvcp120.dll 4766 VS_ENVVAR_2013="VS120COMNTOOLS" 4767 VS_VS_INSTALLDIR_2013="Microsoft Visual Studio 12.0" 4768 VS_SDK_INSTALLDIR_2013= 4769 VS_VS_PLATFORM_NAME_2013="v120" 4770 VS_SDK_PLATFORM_NAME_2013= 4771 4772 ################################################################################ 4773 4774 4775 4776 ################################################################################ 4777 4778 4779 4780 ################################################################################ 4781 # Finds the bat or cmd file in Visual Studio or the SDK that sets up a proper 4782 # build environment and assigns it to VS_ENV_CMD 4783 4784 4785 ################################################################################ 4786 4787 4788 4789 ################################################################################ 4790 # Check if the VS env variables were setup prior to running configure. 4791 # If not, then find vcvarsall.bat and run it automatically, and integrate 4792 # the set env variables into the spec file. 4793 4794 4795 4796 4797 4798 4799 4800 4801 4802 4803 4804 4805 4806 4807 # This line needs to be here, verbatim, after all includes and the dummy hook 4808 # definitions. It is replaced with custom functionality when building 4809 # custom sources. 4810 #CUSTOM_AUTOCONF_INCLUDE 4811 4812 # Do not change or remove the following line, it is needed for consistency checks: 4813 DATE_WHEN_GENERATED=1452261921 4814 4815 ############################################################################### 4816 # 4817 # Initialization / Boot-strapping 4818 # 4819 # The bootstrapping process needs to solve the "chicken or the egg" problem, 4820 # thus it jumps back and forth, each time gaining something needed later on. 4821 # 4822 ############################################################################### 4823 4824 # If we are requested to print additional help, do that and then exit. 4825 # This must be the very first call. 4826 4827 if test "x$CONFIGURE_PRINT_TOOLCHAIN_LIST" != x; then 4828 $PRINTF "The following toolchains are available as arguments to --with-toolchain-type.\n" 4829 $PRINTF "Which are valid to use depends on the build platform.\n" 4830 for toolchain in $VALID_TOOLCHAINS_all; do 4831 # Use indirect variable referencing 4832 toolchain_var_name=TOOLCHAIN_DESCRIPTION_$toolchain 4833 TOOLCHAIN_DESCRIPTION=${!toolchain_var_name} 4834 $PRINTF " %-10s %s\n" $toolchain "$TOOLCHAIN_DESCRIPTION" 4835 done 4836 4837 # And now exit directly 4838 exit 0 4839 fi 4840 4841 4842 # Basic initialization that must happen first of all in the normal process. 4843 4844 # Save the original command line. This is passed to us by the wrapper configure script. 4845 4846 # Save the path variable before it gets changed 4847 ORIGINAL_PATH="$PATH" 4848 4849 DATE_WHEN_CONFIGURED=`LANG=C date` 4850 4851 { $as_echo "$as_me:${as_lineno-$LINENO}: Configuration created at $DATE_WHEN_CONFIGURED." >&5 4852 $as_echo "$as_me: Configuration created at $DATE_WHEN_CONFIGURED." >&6;} 4853 { $as_echo "$as_me:${as_lineno-$LINENO}: configure script generated at timestamp $DATE_WHEN_GENERATED." >&5 4854 $as_echo "$as_me: configure script generated at timestamp $DATE_WHEN_GENERATED." >&6;} 4855 4856 4857 # Start with tools that do not need have cross compilation support 4858 # and can be expected to be found in the default PATH. These tools are 4859 # used by configure. 4860 4861 # First are all the simple required tools. 4862 4863 4864 4865 # Publish this variable in the help. 4866 4867 4868 if [ -z "${BASENAME+x}" ]; then 4869 # The variable is not set by user, try to locate tool using the code snippet 4870 for ac_prog in basename 4871 do 4872 # Extract the first word of "$ac_prog", so it can be a program name with args. 4873 set dummy $ac_prog; ac_word=$2 4874 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4875 $as_echo_n "checking for $ac_word... " >&6; } 4876 if ${ac_cv_path_BASENAME+:} false; then : 4877 $as_echo_n "(cached) " >&6 4878 else 4879 case $BASENAME in 4880 [\\/]* | ?:[\\/]*) 4881 ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path. 4882 ;; 4883 *) 4884 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4885 for as_dir in $PATH 4886 do 4887 IFS=$as_save_IFS 4888 test -z "$as_dir" && as_dir=. 4889 for ac_exec_ext in '' $ac_executable_extensions; do 4890 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 4891 ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext" 4892 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 4893 break 2 4894 fi 4895 done 4896 done 4897 IFS=$as_save_IFS 4898 4899 ;; 4900 esac 4901 fi 4902 BASENAME=$ac_cv_path_BASENAME 4903 if test -n "$BASENAME"; then 4904 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5 4905 $as_echo "$BASENAME" >&6; } 4906 else 4907 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 4908 $as_echo "no" >&6; } 4909 fi 4910 4911 4912 test -n "$BASENAME" && break 4913 done 4914 4915 else 4916 # The variable is set, but is it from the command line or the environment? 4917 4918 # Try to remove the string !BASENAME! from our list. 4919 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BASENAME!/} 4920 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 4921 # If it failed, the variable was not from the command line. Ignore it, 4922 # but warn the user (except for BASH, which is always set by the calling BASH). 4923 if test "xBASENAME" != xBASH; then 4924 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BASENAME from the environment. Use command line variables instead." >&5 4925 $as_echo "$as_me: WARNING: Ignoring value of BASENAME from the environment. Use command line variables instead." >&2;} 4926 fi 4927 # Try to locate tool using the code snippet 4928 for ac_prog in basename 4929 do 4930 # Extract the first word of "$ac_prog", so it can be a program name with args. 4931 set dummy $ac_prog; ac_word=$2 4932 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 4933 $as_echo_n "checking for $ac_word... " >&6; } 4934 if ${ac_cv_path_BASENAME+:} false; then : 4935 $as_echo_n "(cached) " >&6 4936 else 4937 case $BASENAME in 4938 [\\/]* | ?:[\\/]*) 4939 ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path. 4940 ;; 4941 *) 4942 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 4943 for as_dir in $PATH 4944 do 4945 IFS=$as_save_IFS 4946 test -z "$as_dir" && as_dir=. 4947 for ac_exec_ext in '' $ac_executable_extensions; do 4948 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 4949 ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext" 4950 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 4951 break 2 4952 fi 4953 done 4954 done 4955 IFS=$as_save_IFS 4956 4957 ;; 4958 esac 4959 fi 4960 BASENAME=$ac_cv_path_BASENAME 4961 if test -n "$BASENAME"; then 4962 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5 4963 $as_echo "$BASENAME" >&6; } 4964 else 4965 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 4966 $as_echo "no" >&6; } 4967 fi 4968 4969 4970 test -n "$BASENAME" && break 4971 done 4972 4973 else 4974 # If it succeeded, then it was overridden by the user. We will use it 4975 # for the tool. 4976 4977 # First remove it from the list of overridden variables, so we can test 4978 # for unknown variables in the end. 4979 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 4980 4981 # Check if we try to supply an empty value 4982 if test "x$BASENAME" = x; then 4983 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BASENAME= (no value)" >&5 4984 $as_echo "$as_me: Setting user supplied tool BASENAME= (no value)" >&6;} 4985 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASENAME" >&5 4986 $as_echo_n "checking for BASENAME... " >&6; } 4987 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 4988 $as_echo "disabled" >&6; } 4989 else 4990 # Check if the provided tool contains a complete path. 4991 tool_specified="$BASENAME" 4992 tool_basename="${tool_specified##*/}" 4993 if test "x$tool_basename" = "x$tool_specified"; then 4994 # A command without a complete path is provided, search $PATH. 4995 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BASENAME=$tool_basename" >&5 4996 $as_echo "$as_me: Will search for user supplied tool BASENAME=$tool_basename" >&6;} 4997 # Extract the first word of "$tool_basename", so it can be a program name with args. 4998 set dummy $tool_basename; ac_word=$2 4999 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5000 $as_echo_n "checking for $ac_word... " >&6; } 5001 if ${ac_cv_path_BASENAME+:} false; then : 5002 $as_echo_n "(cached) " >&6 5003 else 5004 case $BASENAME in 5005 [\\/]* | ?:[\\/]*) 5006 ac_cv_path_BASENAME="$BASENAME" # Let the user override the test with a path. 5007 ;; 5008 *) 5009 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5010 for as_dir in $PATH 5011 do 5012 IFS=$as_save_IFS 5013 test -z "$as_dir" && as_dir=. 5014 for ac_exec_ext in '' $ac_executable_extensions; do 5015 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5016 ac_cv_path_BASENAME="$as_dir/$ac_word$ac_exec_ext" 5017 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5018 break 2 5019 fi 5020 done 5021 done 5022 IFS=$as_save_IFS 5023 5024 ;; 5025 esac 5026 fi 5027 BASENAME=$ac_cv_path_BASENAME 5028 if test -n "$BASENAME"; then 5029 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASENAME" >&5 5030 $as_echo "$BASENAME" >&6; } 5031 else 5032 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5033 $as_echo "no" >&6; } 5034 fi 5035 5036 5037 if test "x$BASENAME" = x; then 5038 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 5039 fi 5040 else 5041 # Otherwise we believe it is a complete path. Use it as it is. 5042 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BASENAME=$tool_specified" >&5 5043 $as_echo "$as_me: Will use user supplied tool BASENAME=$tool_specified" >&6;} 5044 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASENAME" >&5 5045 $as_echo_n "checking for BASENAME... " >&6; } 5046 if test ! -x "$tool_specified"; then 5047 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 5048 $as_echo "not found" >&6; } 5049 as_fn_error $? "User supplied tool BASENAME=$tool_specified does not exist or is not executable" "$LINENO" 5 5050 fi 5051 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 5052 $as_echo "$tool_specified" >&6; } 5053 fi 5054 fi 5055 fi 5056 5057 fi 5058 5059 5060 5061 if test "x$BASENAME" = x; then 5062 as_fn_error $? "Could not find required tool for BASENAME" "$LINENO" 5 5063 fi 5064 5065 5066 5067 5068 5069 # Publish this variable in the help. 5070 5071 5072 if [ -z "${BASH+x}" ]; then 5073 # The variable is not set by user, try to locate tool using the code snippet 5074 for ac_prog in bash 5075 do 5076 # Extract the first word of "$ac_prog", so it can be a program name with args. 5077 set dummy $ac_prog; ac_word=$2 5078 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5079 $as_echo_n "checking for $ac_word... " >&6; } 5080 if ${ac_cv_path_BASH+:} false; then : 5081 $as_echo_n "(cached) " >&6 5082 else 5083 case $BASH in 5084 [\\/]* | ?:[\\/]*) 5085 ac_cv_path_BASH="$BASH" # Let the user override the test with a path. 5086 ;; 5087 *) 5088 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5089 for as_dir in $PATH 5090 do 5091 IFS=$as_save_IFS 5092 test -z "$as_dir" && as_dir=. 5093 for ac_exec_ext in '' $ac_executable_extensions; do 5094 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5095 ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext" 5096 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5097 break 2 5098 fi 5099 done 5100 done 5101 IFS=$as_save_IFS 5102 5103 ;; 5104 esac 5105 fi 5106 BASH=$ac_cv_path_BASH 5107 if test -n "$BASH"; then 5108 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5 5109 $as_echo "$BASH" >&6; } 5110 else 5111 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5112 $as_echo "no" >&6; } 5113 fi 5114 5115 5116 test -n "$BASH" && break 5117 done 5118 5119 else 5120 # The variable is set, but is it from the command line or the environment? 5121 5122 # Try to remove the string !BASH! from our list. 5123 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BASH!/} 5124 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 5125 # If it failed, the variable was not from the command line. Ignore it, 5126 # but warn the user (except for BASH, which is always set by the calling BASH). 5127 if test "xBASH" != xBASH; then 5128 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BASH from the environment. Use command line variables instead." >&5 5129 $as_echo "$as_me: WARNING: Ignoring value of BASH from the environment. Use command line variables instead." >&2;} 5130 fi 5131 # Try to locate tool using the code snippet 5132 for ac_prog in bash 5133 do 5134 # Extract the first word of "$ac_prog", so it can be a program name with args. 5135 set dummy $ac_prog; ac_word=$2 5136 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5137 $as_echo_n "checking for $ac_word... " >&6; } 5138 if ${ac_cv_path_BASH+:} false; then : 5139 $as_echo_n "(cached) " >&6 5140 else 5141 case $BASH in 5142 [\\/]* | ?:[\\/]*) 5143 ac_cv_path_BASH="$BASH" # Let the user override the test with a path. 5144 ;; 5145 *) 5146 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5147 for as_dir in $PATH 5148 do 5149 IFS=$as_save_IFS 5150 test -z "$as_dir" && as_dir=. 5151 for ac_exec_ext in '' $ac_executable_extensions; do 5152 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5153 ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext" 5154 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5155 break 2 5156 fi 5157 done 5158 done 5159 IFS=$as_save_IFS 5160 5161 ;; 5162 esac 5163 fi 5164 BASH=$ac_cv_path_BASH 5165 if test -n "$BASH"; then 5166 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5 5167 $as_echo "$BASH" >&6; } 5168 else 5169 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5170 $as_echo "no" >&6; } 5171 fi 5172 5173 5174 test -n "$BASH" && break 5175 done 5176 5177 else 5178 # If it succeeded, then it was overridden by the user. We will use it 5179 # for the tool. 5180 5181 # First remove it from the list of overridden variables, so we can test 5182 # for unknown variables in the end. 5183 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 5184 5185 # Check if we try to supply an empty value 5186 if test "x$BASH" = x; then 5187 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BASH= (no value)" >&5 5188 $as_echo "$as_me: Setting user supplied tool BASH= (no value)" >&6;} 5189 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASH" >&5 5190 $as_echo_n "checking for BASH... " >&6; } 5191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 5192 $as_echo "disabled" >&6; } 5193 else 5194 # Check if the provided tool contains a complete path. 5195 tool_specified="$BASH" 5196 tool_basename="${tool_specified##*/}" 5197 if test "x$tool_basename" = "x$tool_specified"; then 5198 # A command without a complete path is provided, search $PATH. 5199 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BASH=$tool_basename" >&5 5200 $as_echo "$as_me: Will search for user supplied tool BASH=$tool_basename" >&6;} 5201 # Extract the first word of "$tool_basename", so it can be a program name with args. 5202 set dummy $tool_basename; ac_word=$2 5203 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5204 $as_echo_n "checking for $ac_word... " >&6; } 5205 if ${ac_cv_path_BASH+:} false; then : 5206 $as_echo_n "(cached) " >&6 5207 else 5208 case $BASH in 5209 [\\/]* | ?:[\\/]*) 5210 ac_cv_path_BASH="$BASH" # Let the user override the test with a path. 5211 ;; 5212 *) 5213 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5214 for as_dir in $PATH 5215 do 5216 IFS=$as_save_IFS 5217 test -z "$as_dir" && as_dir=. 5218 for ac_exec_ext in '' $ac_executable_extensions; do 5219 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5220 ac_cv_path_BASH="$as_dir/$ac_word$ac_exec_ext" 5221 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5222 break 2 5223 fi 5224 done 5225 done 5226 IFS=$as_save_IFS 5227 5228 ;; 5229 esac 5230 fi 5231 BASH=$ac_cv_path_BASH 5232 if test -n "$BASH"; then 5233 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BASH" >&5 5234 $as_echo "$BASH" >&6; } 5235 else 5236 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5237 $as_echo "no" >&6; } 5238 fi 5239 5240 5241 if test "x$BASH" = x; then 5242 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 5243 fi 5244 else 5245 # Otherwise we believe it is a complete path. Use it as it is. 5246 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BASH=$tool_specified" >&5 5247 $as_echo "$as_me: Will use user supplied tool BASH=$tool_specified" >&6;} 5248 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BASH" >&5 5249 $as_echo_n "checking for BASH... " >&6; } 5250 if test ! -x "$tool_specified"; then 5251 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 5252 $as_echo "not found" >&6; } 5253 as_fn_error $? "User supplied tool BASH=$tool_specified does not exist or is not executable" "$LINENO" 5 5254 fi 5255 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 5256 $as_echo "$tool_specified" >&6; } 5257 fi 5258 fi 5259 fi 5260 5261 fi 5262 5263 5264 5265 if test "x$BASH" = x; then 5266 as_fn_error $? "Could not find required tool for BASH" "$LINENO" 5 5267 fi 5268 5269 5270 5271 5272 5273 # Publish this variable in the help. 5274 5275 5276 if [ -z "${CAT+x}" ]; then 5277 # The variable is not set by user, try to locate tool using the code snippet 5278 for ac_prog in cat 5279 do 5280 # Extract the first word of "$ac_prog", so it can be a program name with args. 5281 set dummy $ac_prog; ac_word=$2 5282 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5283 $as_echo_n "checking for $ac_word... " >&6; } 5284 if ${ac_cv_path_CAT+:} false; then : 5285 $as_echo_n "(cached) " >&6 5286 else 5287 case $CAT in 5288 [\\/]* | ?:[\\/]*) 5289 ac_cv_path_CAT="$CAT" # Let the user override the test with a path. 5290 ;; 5291 *) 5292 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5293 for as_dir in $PATH 5294 do 5295 IFS=$as_save_IFS 5296 test -z "$as_dir" && as_dir=. 5297 for ac_exec_ext in '' $ac_executable_extensions; do 5298 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5299 ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext" 5300 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5301 break 2 5302 fi 5303 done 5304 done 5305 IFS=$as_save_IFS 5306 5307 ;; 5308 esac 5309 fi 5310 CAT=$ac_cv_path_CAT 5311 if test -n "$CAT"; then 5312 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5 5313 $as_echo "$CAT" >&6; } 5314 else 5315 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5316 $as_echo "no" >&6; } 5317 fi 5318 5319 5320 test -n "$CAT" && break 5321 done 5322 5323 else 5324 # The variable is set, but is it from the command line or the environment? 5325 5326 # Try to remove the string !CAT! from our list. 5327 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CAT!/} 5328 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 5329 # If it failed, the variable was not from the command line. Ignore it, 5330 # but warn the user (except for BASH, which is always set by the calling BASH). 5331 if test "xCAT" != xBASH; then 5332 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CAT from the environment. Use command line variables instead." >&5 5333 $as_echo "$as_me: WARNING: Ignoring value of CAT from the environment. Use command line variables instead." >&2;} 5334 fi 5335 # Try to locate tool using the code snippet 5336 for ac_prog in cat 5337 do 5338 # Extract the first word of "$ac_prog", so it can be a program name with args. 5339 set dummy $ac_prog; ac_word=$2 5340 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5341 $as_echo_n "checking for $ac_word... " >&6; } 5342 if ${ac_cv_path_CAT+:} false; then : 5343 $as_echo_n "(cached) " >&6 5344 else 5345 case $CAT in 5346 [\\/]* | ?:[\\/]*) 5347 ac_cv_path_CAT="$CAT" # Let the user override the test with a path. 5348 ;; 5349 *) 5350 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5351 for as_dir in $PATH 5352 do 5353 IFS=$as_save_IFS 5354 test -z "$as_dir" && as_dir=. 5355 for ac_exec_ext in '' $ac_executable_extensions; do 5356 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5357 ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext" 5358 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5359 break 2 5360 fi 5361 done 5362 done 5363 IFS=$as_save_IFS 5364 5365 ;; 5366 esac 5367 fi 5368 CAT=$ac_cv_path_CAT 5369 if test -n "$CAT"; then 5370 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5 5371 $as_echo "$CAT" >&6; } 5372 else 5373 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5374 $as_echo "no" >&6; } 5375 fi 5376 5377 5378 test -n "$CAT" && break 5379 done 5380 5381 else 5382 # If it succeeded, then it was overridden by the user. We will use it 5383 # for the tool. 5384 5385 # First remove it from the list of overridden variables, so we can test 5386 # for unknown variables in the end. 5387 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 5388 5389 # Check if we try to supply an empty value 5390 if test "x$CAT" = x; then 5391 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CAT= (no value)" >&5 5392 $as_echo "$as_me: Setting user supplied tool CAT= (no value)" >&6;} 5393 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CAT" >&5 5394 $as_echo_n "checking for CAT... " >&6; } 5395 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 5396 $as_echo "disabled" >&6; } 5397 else 5398 # Check if the provided tool contains a complete path. 5399 tool_specified="$CAT" 5400 tool_basename="${tool_specified##*/}" 5401 if test "x$tool_basename" = "x$tool_specified"; then 5402 # A command without a complete path is provided, search $PATH. 5403 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CAT=$tool_basename" >&5 5404 $as_echo "$as_me: Will search for user supplied tool CAT=$tool_basename" >&6;} 5405 # Extract the first word of "$tool_basename", so it can be a program name with args. 5406 set dummy $tool_basename; ac_word=$2 5407 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5408 $as_echo_n "checking for $ac_word... " >&6; } 5409 if ${ac_cv_path_CAT+:} false; then : 5410 $as_echo_n "(cached) " >&6 5411 else 5412 case $CAT in 5413 [\\/]* | ?:[\\/]*) 5414 ac_cv_path_CAT="$CAT" # Let the user override the test with a path. 5415 ;; 5416 *) 5417 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5418 for as_dir in $PATH 5419 do 5420 IFS=$as_save_IFS 5421 test -z "$as_dir" && as_dir=. 5422 for ac_exec_ext in '' $ac_executable_extensions; do 5423 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5424 ac_cv_path_CAT="$as_dir/$ac_word$ac_exec_ext" 5425 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5426 break 2 5427 fi 5428 done 5429 done 5430 IFS=$as_save_IFS 5431 5432 ;; 5433 esac 5434 fi 5435 CAT=$ac_cv_path_CAT 5436 if test -n "$CAT"; then 5437 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CAT" >&5 5438 $as_echo "$CAT" >&6; } 5439 else 5440 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5441 $as_echo "no" >&6; } 5442 fi 5443 5444 5445 if test "x$CAT" = x; then 5446 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 5447 fi 5448 else 5449 # Otherwise we believe it is a complete path. Use it as it is. 5450 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CAT=$tool_specified" >&5 5451 $as_echo "$as_me: Will use user supplied tool CAT=$tool_specified" >&6;} 5452 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CAT" >&5 5453 $as_echo_n "checking for CAT... " >&6; } 5454 if test ! -x "$tool_specified"; then 5455 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 5456 $as_echo "not found" >&6; } 5457 as_fn_error $? "User supplied tool CAT=$tool_specified does not exist or is not executable" "$LINENO" 5 5458 fi 5459 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 5460 $as_echo "$tool_specified" >&6; } 5461 fi 5462 fi 5463 fi 5464 5465 fi 5466 5467 5468 5469 if test "x$CAT" = x; then 5470 as_fn_error $? "Could not find required tool for CAT" "$LINENO" 5 5471 fi 5472 5473 5474 5475 5476 5477 # Publish this variable in the help. 5478 5479 5480 if [ -z "${CHMOD+x}" ]; then 5481 # The variable is not set by user, try to locate tool using the code snippet 5482 for ac_prog in chmod 5483 do 5484 # Extract the first word of "$ac_prog", so it can be a program name with args. 5485 set dummy $ac_prog; ac_word=$2 5486 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5487 $as_echo_n "checking for $ac_word... " >&6; } 5488 if ${ac_cv_path_CHMOD+:} false; then : 5489 $as_echo_n "(cached) " >&6 5490 else 5491 case $CHMOD in 5492 [\\/]* | ?:[\\/]*) 5493 ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path. 5494 ;; 5495 *) 5496 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5497 for as_dir in $PATH 5498 do 5499 IFS=$as_save_IFS 5500 test -z "$as_dir" && as_dir=. 5501 for ac_exec_ext in '' $ac_executable_extensions; do 5502 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5503 ac_cv_path_CHMOD="$as_dir/$ac_word$ac_exec_ext" 5504 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5505 break 2 5506 fi 5507 done 5508 done 5509 IFS=$as_save_IFS 5510 5511 ;; 5512 esac 5513 fi 5514 CHMOD=$ac_cv_path_CHMOD 5515 if test -n "$CHMOD"; then 5516 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5 5517 $as_echo "$CHMOD" >&6; } 5518 else 5519 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5520 $as_echo "no" >&6; } 5521 fi 5522 5523 5524 test -n "$CHMOD" && break 5525 done 5526 5527 else 5528 # The variable is set, but is it from the command line or the environment? 5529 5530 # Try to remove the string !CHMOD! from our list. 5531 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CHMOD!/} 5532 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 5533 # If it failed, the variable was not from the command line. Ignore it, 5534 # but warn the user (except for BASH, which is always set by the calling BASH). 5535 if test "xCHMOD" != xBASH; then 5536 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CHMOD from the environment. Use command line variables instead." >&5 5537 $as_echo "$as_me: WARNING: Ignoring value of CHMOD from the environment. Use command line variables instead." >&2;} 5538 fi 5539 # Try to locate tool using the code snippet 5540 for ac_prog in chmod 5541 do 5542 # Extract the first word of "$ac_prog", so it can be a program name with args. 5543 set dummy $ac_prog; ac_word=$2 5544 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5545 $as_echo_n "checking for $ac_word... " >&6; } 5546 if ${ac_cv_path_CHMOD+:} false; then : 5547 $as_echo_n "(cached) " >&6 5548 else 5549 case $CHMOD in 5550 [\\/]* | ?:[\\/]*) 5551 ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path. 5552 ;; 5553 *) 5554 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5555 for as_dir in $PATH 5556 do 5557 IFS=$as_save_IFS 5558 test -z "$as_dir" && as_dir=. 5559 for ac_exec_ext in '' $ac_executable_extensions; do 5560 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5561 ac_cv_path_CHMOD="$as_dir/$ac_word$ac_exec_ext" 5562 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5563 break 2 5564 fi 5565 done 5566 done 5567 IFS=$as_save_IFS 5568 5569 ;; 5570 esac 5571 fi 5572 CHMOD=$ac_cv_path_CHMOD 5573 if test -n "$CHMOD"; then 5574 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5 5575 $as_echo "$CHMOD" >&6; } 5576 else 5577 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5578 $as_echo "no" >&6; } 5579 fi 5580 5581 5582 test -n "$CHMOD" && break 5583 done 5584 5585 else 5586 # If it succeeded, then it was overridden by the user. We will use it 5587 # for the tool. 5588 5589 # First remove it from the list of overridden variables, so we can test 5590 # for unknown variables in the end. 5591 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 5592 5593 # Check if we try to supply an empty value 5594 if test "x$CHMOD" = x; then 5595 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CHMOD= (no value)" >&5 5596 $as_echo "$as_me: Setting user supplied tool CHMOD= (no value)" >&6;} 5597 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CHMOD" >&5 5598 $as_echo_n "checking for CHMOD... " >&6; } 5599 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 5600 $as_echo "disabled" >&6; } 5601 else 5602 # Check if the provided tool contains a complete path. 5603 tool_specified="$CHMOD" 5604 tool_basename="${tool_specified##*/}" 5605 if test "x$tool_basename" = "x$tool_specified"; then 5606 # A command without a complete path is provided, search $PATH. 5607 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CHMOD=$tool_basename" >&5 5608 $as_echo "$as_me: Will search for user supplied tool CHMOD=$tool_basename" >&6;} 5609 # Extract the first word of "$tool_basename", so it can be a program name with args. 5610 set dummy $tool_basename; ac_word=$2 5611 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5612 $as_echo_n "checking for $ac_word... " >&6; } 5613 if ${ac_cv_path_CHMOD+:} false; then : 5614 $as_echo_n "(cached) " >&6 5615 else 5616 case $CHMOD in 5617 [\\/]* | ?:[\\/]*) 5618 ac_cv_path_CHMOD="$CHMOD" # Let the user override the test with a path. 5619 ;; 5620 *) 5621 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5622 for as_dir in $PATH 5623 do 5624 IFS=$as_save_IFS 5625 test -z "$as_dir" && as_dir=. 5626 for ac_exec_ext in '' $ac_executable_extensions; do 5627 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5628 ac_cv_path_CHMOD="$as_dir/$ac_word$ac_exec_ext" 5629 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5630 break 2 5631 fi 5632 done 5633 done 5634 IFS=$as_save_IFS 5635 5636 ;; 5637 esac 5638 fi 5639 CHMOD=$ac_cv_path_CHMOD 5640 if test -n "$CHMOD"; then 5641 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHMOD" >&5 5642 $as_echo "$CHMOD" >&6; } 5643 else 5644 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5645 $as_echo "no" >&6; } 5646 fi 5647 5648 5649 if test "x$CHMOD" = x; then 5650 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 5651 fi 5652 else 5653 # Otherwise we believe it is a complete path. Use it as it is. 5654 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CHMOD=$tool_specified" >&5 5655 $as_echo "$as_me: Will use user supplied tool CHMOD=$tool_specified" >&6;} 5656 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CHMOD" >&5 5657 $as_echo_n "checking for CHMOD... " >&6; } 5658 if test ! -x "$tool_specified"; then 5659 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 5660 $as_echo "not found" >&6; } 5661 as_fn_error $? "User supplied tool CHMOD=$tool_specified does not exist or is not executable" "$LINENO" 5 5662 fi 5663 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 5664 $as_echo "$tool_specified" >&6; } 5665 fi 5666 fi 5667 fi 5668 5669 fi 5670 5671 5672 5673 if test "x$CHMOD" = x; then 5674 as_fn_error $? "Could not find required tool for CHMOD" "$LINENO" 5 5675 fi 5676 5677 5678 5679 5680 5681 # Publish this variable in the help. 5682 5683 5684 if [ -z "${CMP+x}" ]; then 5685 # The variable is not set by user, try to locate tool using the code snippet 5686 for ac_prog in cmp 5687 do 5688 # Extract the first word of "$ac_prog", so it can be a program name with args. 5689 set dummy $ac_prog; ac_word=$2 5690 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5691 $as_echo_n "checking for $ac_word... " >&6; } 5692 if ${ac_cv_path_CMP+:} false; then : 5693 $as_echo_n "(cached) " >&6 5694 else 5695 case $CMP in 5696 [\\/]* | ?:[\\/]*) 5697 ac_cv_path_CMP="$CMP" # Let the user override the test with a path. 5698 ;; 5699 *) 5700 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5701 for as_dir in $PATH 5702 do 5703 IFS=$as_save_IFS 5704 test -z "$as_dir" && as_dir=. 5705 for ac_exec_ext in '' $ac_executable_extensions; do 5706 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5707 ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext" 5708 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5709 break 2 5710 fi 5711 done 5712 done 5713 IFS=$as_save_IFS 5714 5715 ;; 5716 esac 5717 fi 5718 CMP=$ac_cv_path_CMP 5719 if test -n "$CMP"; then 5720 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5 5721 $as_echo "$CMP" >&6; } 5722 else 5723 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5724 $as_echo "no" >&6; } 5725 fi 5726 5727 5728 test -n "$CMP" && break 5729 done 5730 5731 else 5732 # The variable is set, but is it from the command line or the environment? 5733 5734 # Try to remove the string !CMP! from our list. 5735 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CMP!/} 5736 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 5737 # If it failed, the variable was not from the command line. Ignore it, 5738 # but warn the user (except for BASH, which is always set by the calling BASH). 5739 if test "xCMP" != xBASH; then 5740 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CMP from the environment. Use command line variables instead." >&5 5741 $as_echo "$as_me: WARNING: Ignoring value of CMP from the environment. Use command line variables instead." >&2;} 5742 fi 5743 # Try to locate tool using the code snippet 5744 for ac_prog in cmp 5745 do 5746 # Extract the first word of "$ac_prog", so it can be a program name with args. 5747 set dummy $ac_prog; ac_word=$2 5748 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5749 $as_echo_n "checking for $ac_word... " >&6; } 5750 if ${ac_cv_path_CMP+:} false; then : 5751 $as_echo_n "(cached) " >&6 5752 else 5753 case $CMP in 5754 [\\/]* | ?:[\\/]*) 5755 ac_cv_path_CMP="$CMP" # Let the user override the test with a path. 5756 ;; 5757 *) 5758 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5759 for as_dir in $PATH 5760 do 5761 IFS=$as_save_IFS 5762 test -z "$as_dir" && as_dir=. 5763 for ac_exec_ext in '' $ac_executable_extensions; do 5764 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5765 ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext" 5766 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5767 break 2 5768 fi 5769 done 5770 done 5771 IFS=$as_save_IFS 5772 5773 ;; 5774 esac 5775 fi 5776 CMP=$ac_cv_path_CMP 5777 if test -n "$CMP"; then 5778 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5 5779 $as_echo "$CMP" >&6; } 5780 else 5781 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5782 $as_echo "no" >&6; } 5783 fi 5784 5785 5786 test -n "$CMP" && break 5787 done 5788 5789 else 5790 # If it succeeded, then it was overridden by the user. We will use it 5791 # for the tool. 5792 5793 # First remove it from the list of overridden variables, so we can test 5794 # for unknown variables in the end. 5795 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 5796 5797 # Check if we try to supply an empty value 5798 if test "x$CMP" = x; then 5799 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CMP= (no value)" >&5 5800 $as_echo "$as_me: Setting user supplied tool CMP= (no value)" >&6;} 5801 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CMP" >&5 5802 $as_echo_n "checking for CMP... " >&6; } 5803 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 5804 $as_echo "disabled" >&6; } 5805 else 5806 # Check if the provided tool contains a complete path. 5807 tool_specified="$CMP" 5808 tool_basename="${tool_specified##*/}" 5809 if test "x$tool_basename" = "x$tool_specified"; then 5810 # A command without a complete path is provided, search $PATH. 5811 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CMP=$tool_basename" >&5 5812 $as_echo "$as_me: Will search for user supplied tool CMP=$tool_basename" >&6;} 5813 # Extract the first word of "$tool_basename", so it can be a program name with args. 5814 set dummy $tool_basename; ac_word=$2 5815 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5816 $as_echo_n "checking for $ac_word... " >&6; } 5817 if ${ac_cv_path_CMP+:} false; then : 5818 $as_echo_n "(cached) " >&6 5819 else 5820 case $CMP in 5821 [\\/]* | ?:[\\/]*) 5822 ac_cv_path_CMP="$CMP" # Let the user override the test with a path. 5823 ;; 5824 *) 5825 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5826 for as_dir in $PATH 5827 do 5828 IFS=$as_save_IFS 5829 test -z "$as_dir" && as_dir=. 5830 for ac_exec_ext in '' $ac_executable_extensions; do 5831 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5832 ac_cv_path_CMP="$as_dir/$ac_word$ac_exec_ext" 5833 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5834 break 2 5835 fi 5836 done 5837 done 5838 IFS=$as_save_IFS 5839 5840 ;; 5841 esac 5842 fi 5843 CMP=$ac_cv_path_CMP 5844 if test -n "$CMP"; then 5845 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CMP" >&5 5846 $as_echo "$CMP" >&6; } 5847 else 5848 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5849 $as_echo "no" >&6; } 5850 fi 5851 5852 5853 if test "x$CMP" = x; then 5854 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 5855 fi 5856 else 5857 # Otherwise we believe it is a complete path. Use it as it is. 5858 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CMP=$tool_specified" >&5 5859 $as_echo "$as_me: Will use user supplied tool CMP=$tool_specified" >&6;} 5860 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CMP" >&5 5861 $as_echo_n "checking for CMP... " >&6; } 5862 if test ! -x "$tool_specified"; then 5863 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 5864 $as_echo "not found" >&6; } 5865 as_fn_error $? "User supplied tool CMP=$tool_specified does not exist or is not executable" "$LINENO" 5 5866 fi 5867 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 5868 $as_echo "$tool_specified" >&6; } 5869 fi 5870 fi 5871 fi 5872 5873 fi 5874 5875 5876 5877 if test "x$CMP" = x; then 5878 as_fn_error $? "Could not find required tool for CMP" "$LINENO" 5 5879 fi 5880 5881 5882 5883 5884 5885 # Publish this variable in the help. 5886 5887 5888 if [ -z "${COMM+x}" ]; then 5889 # The variable is not set by user, try to locate tool using the code snippet 5890 for ac_prog in comm 5891 do 5892 # Extract the first word of "$ac_prog", so it can be a program name with args. 5893 set dummy $ac_prog; ac_word=$2 5894 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5895 $as_echo_n "checking for $ac_word... " >&6; } 5896 if ${ac_cv_path_COMM+:} false; then : 5897 $as_echo_n "(cached) " >&6 5898 else 5899 case $COMM in 5900 [\\/]* | ?:[\\/]*) 5901 ac_cv_path_COMM="$COMM" # Let the user override the test with a path. 5902 ;; 5903 *) 5904 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5905 for as_dir in $PATH 5906 do 5907 IFS=$as_save_IFS 5908 test -z "$as_dir" && as_dir=. 5909 for ac_exec_ext in '' $ac_executable_extensions; do 5910 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5911 ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext" 5912 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5913 break 2 5914 fi 5915 done 5916 done 5917 IFS=$as_save_IFS 5918 5919 ;; 5920 esac 5921 fi 5922 COMM=$ac_cv_path_COMM 5923 if test -n "$COMM"; then 5924 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5 5925 $as_echo "$COMM" >&6; } 5926 else 5927 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5928 $as_echo "no" >&6; } 5929 fi 5930 5931 5932 test -n "$COMM" && break 5933 done 5934 5935 else 5936 # The variable is set, but is it from the command line or the environment? 5937 5938 # Try to remove the string !COMM! from our list. 5939 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!COMM!/} 5940 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 5941 # If it failed, the variable was not from the command line. Ignore it, 5942 # but warn the user (except for BASH, which is always set by the calling BASH). 5943 if test "xCOMM" != xBASH; then 5944 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of COMM from the environment. Use command line variables instead." >&5 5945 $as_echo "$as_me: WARNING: Ignoring value of COMM from the environment. Use command line variables instead." >&2;} 5946 fi 5947 # Try to locate tool using the code snippet 5948 for ac_prog in comm 5949 do 5950 # Extract the first word of "$ac_prog", so it can be a program name with args. 5951 set dummy $ac_prog; ac_word=$2 5952 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 5953 $as_echo_n "checking for $ac_word... " >&6; } 5954 if ${ac_cv_path_COMM+:} false; then : 5955 $as_echo_n "(cached) " >&6 5956 else 5957 case $COMM in 5958 [\\/]* | ?:[\\/]*) 5959 ac_cv_path_COMM="$COMM" # Let the user override the test with a path. 5960 ;; 5961 *) 5962 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 5963 for as_dir in $PATH 5964 do 5965 IFS=$as_save_IFS 5966 test -z "$as_dir" && as_dir=. 5967 for ac_exec_ext in '' $ac_executable_extensions; do 5968 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 5969 ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext" 5970 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 5971 break 2 5972 fi 5973 done 5974 done 5975 IFS=$as_save_IFS 5976 5977 ;; 5978 esac 5979 fi 5980 COMM=$ac_cv_path_COMM 5981 if test -n "$COMM"; then 5982 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5 5983 $as_echo "$COMM" >&6; } 5984 else 5985 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 5986 $as_echo "no" >&6; } 5987 fi 5988 5989 5990 test -n "$COMM" && break 5991 done 5992 5993 else 5994 # If it succeeded, then it was overridden by the user. We will use it 5995 # for the tool. 5996 5997 # First remove it from the list of overridden variables, so we can test 5998 # for unknown variables in the end. 5999 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 6000 6001 # Check if we try to supply an empty value 6002 if test "x$COMM" = x; then 6003 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool COMM= (no value)" >&5 6004 $as_echo "$as_me: Setting user supplied tool COMM= (no value)" >&6;} 6005 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for COMM" >&5 6006 $as_echo_n "checking for COMM... " >&6; } 6007 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 6008 $as_echo "disabled" >&6; } 6009 else 6010 # Check if the provided tool contains a complete path. 6011 tool_specified="$COMM" 6012 tool_basename="${tool_specified##*/}" 6013 if test "x$tool_basename" = "x$tool_specified"; then 6014 # A command without a complete path is provided, search $PATH. 6015 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool COMM=$tool_basename" >&5 6016 $as_echo "$as_me: Will search for user supplied tool COMM=$tool_basename" >&6;} 6017 # Extract the first word of "$tool_basename", so it can be a program name with args. 6018 set dummy $tool_basename; ac_word=$2 6019 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6020 $as_echo_n "checking for $ac_word... " >&6; } 6021 if ${ac_cv_path_COMM+:} false; then : 6022 $as_echo_n "(cached) " >&6 6023 else 6024 case $COMM in 6025 [\\/]* | ?:[\\/]*) 6026 ac_cv_path_COMM="$COMM" # Let the user override the test with a path. 6027 ;; 6028 *) 6029 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6030 for as_dir in $PATH 6031 do 6032 IFS=$as_save_IFS 6033 test -z "$as_dir" && as_dir=. 6034 for ac_exec_ext in '' $ac_executable_extensions; do 6035 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6036 ac_cv_path_COMM="$as_dir/$ac_word$ac_exec_ext" 6037 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6038 break 2 6039 fi 6040 done 6041 done 6042 IFS=$as_save_IFS 6043 6044 ;; 6045 esac 6046 fi 6047 COMM=$ac_cv_path_COMM 6048 if test -n "$COMM"; then 6049 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMM" >&5 6050 $as_echo "$COMM" >&6; } 6051 else 6052 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6053 $as_echo "no" >&6; } 6054 fi 6055 6056 6057 if test "x$COMM" = x; then 6058 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 6059 fi 6060 else 6061 # Otherwise we believe it is a complete path. Use it as it is. 6062 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool COMM=$tool_specified" >&5 6063 $as_echo "$as_me: Will use user supplied tool COMM=$tool_specified" >&6;} 6064 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for COMM" >&5 6065 $as_echo_n "checking for COMM... " >&6; } 6066 if test ! -x "$tool_specified"; then 6067 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 6068 $as_echo "not found" >&6; } 6069 as_fn_error $? "User supplied tool COMM=$tool_specified does not exist or is not executable" "$LINENO" 5 6070 fi 6071 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 6072 $as_echo "$tool_specified" >&6; } 6073 fi 6074 fi 6075 fi 6076 6077 fi 6078 6079 6080 6081 if test "x$COMM" = x; then 6082 as_fn_error $? "Could not find required tool for COMM" "$LINENO" 5 6083 fi 6084 6085 6086 6087 6088 6089 # Publish this variable in the help. 6090 6091 6092 if [ -z "${CP+x}" ]; then 6093 # The variable is not set by user, try to locate tool using the code snippet 6094 for ac_prog in cp 6095 do 6096 # Extract the first word of "$ac_prog", so it can be a program name with args. 6097 set dummy $ac_prog; ac_word=$2 6098 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6099 $as_echo_n "checking for $ac_word... " >&6; } 6100 if ${ac_cv_path_CP+:} false; then : 6101 $as_echo_n "(cached) " >&6 6102 else 6103 case $CP in 6104 [\\/]* | ?:[\\/]*) 6105 ac_cv_path_CP="$CP" # Let the user override the test with a path. 6106 ;; 6107 *) 6108 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6109 for as_dir in $PATH 6110 do 6111 IFS=$as_save_IFS 6112 test -z "$as_dir" && as_dir=. 6113 for ac_exec_ext in '' $ac_executable_extensions; do 6114 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6115 ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext" 6116 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6117 break 2 6118 fi 6119 done 6120 done 6121 IFS=$as_save_IFS 6122 6123 ;; 6124 esac 6125 fi 6126 CP=$ac_cv_path_CP 6127 if test -n "$CP"; then 6128 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CP" >&5 6129 $as_echo "$CP" >&6; } 6130 else 6131 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6132 $as_echo "no" >&6; } 6133 fi 6134 6135 6136 test -n "$CP" && break 6137 done 6138 6139 else 6140 # The variable is set, but is it from the command line or the environment? 6141 6142 # Try to remove the string !CP! from our list. 6143 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CP!/} 6144 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 6145 # If it failed, the variable was not from the command line. Ignore it, 6146 # but warn the user (except for BASH, which is always set by the calling BASH). 6147 if test "xCP" != xBASH; then 6148 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CP from the environment. Use command line variables instead." >&5 6149 $as_echo "$as_me: WARNING: Ignoring value of CP from the environment. Use command line variables instead." >&2;} 6150 fi 6151 # Try to locate tool using the code snippet 6152 for ac_prog in cp 6153 do 6154 # Extract the first word of "$ac_prog", so it can be a program name with args. 6155 set dummy $ac_prog; ac_word=$2 6156 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6157 $as_echo_n "checking for $ac_word... " >&6; } 6158 if ${ac_cv_path_CP+:} false; then : 6159 $as_echo_n "(cached) " >&6 6160 else 6161 case $CP in 6162 [\\/]* | ?:[\\/]*) 6163 ac_cv_path_CP="$CP" # Let the user override the test with a path. 6164 ;; 6165 *) 6166 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6167 for as_dir in $PATH 6168 do 6169 IFS=$as_save_IFS 6170 test -z "$as_dir" && as_dir=. 6171 for ac_exec_ext in '' $ac_executable_extensions; do 6172 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6173 ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext" 6174 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6175 break 2 6176 fi 6177 done 6178 done 6179 IFS=$as_save_IFS 6180 6181 ;; 6182 esac 6183 fi 6184 CP=$ac_cv_path_CP 6185 if test -n "$CP"; then 6186 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CP" >&5 6187 $as_echo "$CP" >&6; } 6188 else 6189 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6190 $as_echo "no" >&6; } 6191 fi 6192 6193 6194 test -n "$CP" && break 6195 done 6196 6197 else 6198 # If it succeeded, then it was overridden by the user. We will use it 6199 # for the tool. 6200 6201 # First remove it from the list of overridden variables, so we can test 6202 # for unknown variables in the end. 6203 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 6204 6205 # Check if we try to supply an empty value 6206 if test "x$CP" = x; then 6207 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CP= (no value)" >&5 6208 $as_echo "$as_me: Setting user supplied tool CP= (no value)" >&6;} 6209 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CP" >&5 6210 $as_echo_n "checking for CP... " >&6; } 6211 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 6212 $as_echo "disabled" >&6; } 6213 else 6214 # Check if the provided tool contains a complete path. 6215 tool_specified="$CP" 6216 tool_basename="${tool_specified##*/}" 6217 if test "x$tool_basename" = "x$tool_specified"; then 6218 # A command without a complete path is provided, search $PATH. 6219 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CP=$tool_basename" >&5 6220 $as_echo "$as_me: Will search for user supplied tool CP=$tool_basename" >&6;} 6221 # Extract the first word of "$tool_basename", so it can be a program name with args. 6222 set dummy $tool_basename; ac_word=$2 6223 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6224 $as_echo_n "checking for $ac_word... " >&6; } 6225 if ${ac_cv_path_CP+:} false; then : 6226 $as_echo_n "(cached) " >&6 6227 else 6228 case $CP in 6229 [\\/]* | ?:[\\/]*) 6230 ac_cv_path_CP="$CP" # Let the user override the test with a path. 6231 ;; 6232 *) 6233 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6234 for as_dir in $PATH 6235 do 6236 IFS=$as_save_IFS 6237 test -z "$as_dir" && as_dir=. 6238 for ac_exec_ext in '' $ac_executable_extensions; do 6239 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6240 ac_cv_path_CP="$as_dir/$ac_word$ac_exec_ext" 6241 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6242 break 2 6243 fi 6244 done 6245 done 6246 IFS=$as_save_IFS 6247 6248 ;; 6249 esac 6250 fi 6251 CP=$ac_cv_path_CP 6252 if test -n "$CP"; then 6253 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CP" >&5 6254 $as_echo "$CP" >&6; } 6255 else 6256 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6257 $as_echo "no" >&6; } 6258 fi 6259 6260 6261 if test "x$CP" = x; then 6262 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 6263 fi 6264 else 6265 # Otherwise we believe it is a complete path. Use it as it is. 6266 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CP=$tool_specified" >&5 6267 $as_echo "$as_me: Will use user supplied tool CP=$tool_specified" >&6;} 6268 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CP" >&5 6269 $as_echo_n "checking for CP... " >&6; } 6270 if test ! -x "$tool_specified"; then 6271 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 6272 $as_echo "not found" >&6; } 6273 as_fn_error $? "User supplied tool CP=$tool_specified does not exist or is not executable" "$LINENO" 5 6274 fi 6275 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 6276 $as_echo "$tool_specified" >&6; } 6277 fi 6278 fi 6279 fi 6280 6281 fi 6282 6283 6284 6285 if test "x$CP" = x; then 6286 as_fn_error $? "Could not find required tool for CP" "$LINENO" 5 6287 fi 6288 6289 6290 6291 6292 6293 # Publish this variable in the help. 6294 6295 6296 if [ -z "${CUT+x}" ]; then 6297 # The variable is not set by user, try to locate tool using the code snippet 6298 for ac_prog in cut 6299 do 6300 # Extract the first word of "$ac_prog", so it can be a program name with args. 6301 set dummy $ac_prog; ac_word=$2 6302 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6303 $as_echo_n "checking for $ac_word... " >&6; } 6304 if ${ac_cv_path_CUT+:} false; then : 6305 $as_echo_n "(cached) " >&6 6306 else 6307 case $CUT in 6308 [\\/]* | ?:[\\/]*) 6309 ac_cv_path_CUT="$CUT" # Let the user override the test with a path. 6310 ;; 6311 *) 6312 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6313 for as_dir in $PATH 6314 do 6315 IFS=$as_save_IFS 6316 test -z "$as_dir" && as_dir=. 6317 for ac_exec_ext in '' $ac_executable_extensions; do 6318 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6319 ac_cv_path_CUT="$as_dir/$ac_word$ac_exec_ext" 6320 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6321 break 2 6322 fi 6323 done 6324 done 6325 IFS=$as_save_IFS 6326 6327 ;; 6328 esac 6329 fi 6330 CUT=$ac_cv_path_CUT 6331 if test -n "$CUT"; then 6332 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUT" >&5 6333 $as_echo "$CUT" >&6; } 6334 else 6335 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6336 $as_echo "no" >&6; } 6337 fi 6338 6339 6340 test -n "$CUT" && break 6341 done 6342 6343 else 6344 # The variable is set, but is it from the command line or the environment? 6345 6346 # Try to remove the string !CUT! from our list. 6347 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CUT!/} 6348 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 6349 # If it failed, the variable was not from the command line. Ignore it, 6350 # but warn the user (except for BASH, which is always set by the calling BASH). 6351 if test "xCUT" != xBASH; then 6352 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CUT from the environment. Use command line variables instead." >&5 6353 $as_echo "$as_me: WARNING: Ignoring value of CUT from the environment. Use command line variables instead." >&2;} 6354 fi 6355 # Try to locate tool using the code snippet 6356 for ac_prog in cut 6357 do 6358 # Extract the first word of "$ac_prog", so it can be a program name with args. 6359 set dummy $ac_prog; ac_word=$2 6360 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6361 $as_echo_n "checking for $ac_word... " >&6; } 6362 if ${ac_cv_path_CUT+:} false; then : 6363 $as_echo_n "(cached) " >&6 6364 else 6365 case $CUT in 6366 [\\/]* | ?:[\\/]*) 6367 ac_cv_path_CUT="$CUT" # Let the user override the test with a path. 6368 ;; 6369 *) 6370 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6371 for as_dir in $PATH 6372 do 6373 IFS=$as_save_IFS 6374 test -z "$as_dir" && as_dir=. 6375 for ac_exec_ext in '' $ac_executable_extensions; do 6376 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6377 ac_cv_path_CUT="$as_dir/$ac_word$ac_exec_ext" 6378 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6379 break 2 6380 fi 6381 done 6382 done 6383 IFS=$as_save_IFS 6384 6385 ;; 6386 esac 6387 fi 6388 CUT=$ac_cv_path_CUT 6389 if test -n "$CUT"; then 6390 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUT" >&5 6391 $as_echo "$CUT" >&6; } 6392 else 6393 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6394 $as_echo "no" >&6; } 6395 fi 6396 6397 6398 test -n "$CUT" && break 6399 done 6400 6401 else 6402 # If it succeeded, then it was overridden by the user. We will use it 6403 # for the tool. 6404 6405 # First remove it from the list of overridden variables, so we can test 6406 # for unknown variables in the end. 6407 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 6408 6409 # Check if we try to supply an empty value 6410 if test "x$CUT" = x; then 6411 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CUT= (no value)" >&5 6412 $as_echo "$as_me: Setting user supplied tool CUT= (no value)" >&6;} 6413 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CUT" >&5 6414 $as_echo_n "checking for CUT... " >&6; } 6415 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 6416 $as_echo "disabled" >&6; } 6417 else 6418 # Check if the provided tool contains a complete path. 6419 tool_specified="$CUT" 6420 tool_basename="${tool_specified##*/}" 6421 if test "x$tool_basename" = "x$tool_specified"; then 6422 # A command without a complete path is provided, search $PATH. 6423 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CUT=$tool_basename" >&5 6424 $as_echo "$as_me: Will search for user supplied tool CUT=$tool_basename" >&6;} 6425 # Extract the first word of "$tool_basename", so it can be a program name with args. 6426 set dummy $tool_basename; ac_word=$2 6427 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6428 $as_echo_n "checking for $ac_word... " >&6; } 6429 if ${ac_cv_path_CUT+:} false; then : 6430 $as_echo_n "(cached) " >&6 6431 else 6432 case $CUT in 6433 [\\/]* | ?:[\\/]*) 6434 ac_cv_path_CUT="$CUT" # Let the user override the test with a path. 6435 ;; 6436 *) 6437 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6438 for as_dir in $PATH 6439 do 6440 IFS=$as_save_IFS 6441 test -z "$as_dir" && as_dir=. 6442 for ac_exec_ext in '' $ac_executable_extensions; do 6443 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6444 ac_cv_path_CUT="$as_dir/$ac_word$ac_exec_ext" 6445 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6446 break 2 6447 fi 6448 done 6449 done 6450 IFS=$as_save_IFS 6451 6452 ;; 6453 esac 6454 fi 6455 CUT=$ac_cv_path_CUT 6456 if test -n "$CUT"; then 6457 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUT" >&5 6458 $as_echo "$CUT" >&6; } 6459 else 6460 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6461 $as_echo "no" >&6; } 6462 fi 6463 6464 6465 if test "x$CUT" = x; then 6466 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 6467 fi 6468 else 6469 # Otherwise we believe it is a complete path. Use it as it is. 6470 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CUT=$tool_specified" >&5 6471 $as_echo "$as_me: Will use user supplied tool CUT=$tool_specified" >&6;} 6472 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CUT" >&5 6473 $as_echo_n "checking for CUT... " >&6; } 6474 if test ! -x "$tool_specified"; then 6475 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 6476 $as_echo "not found" >&6; } 6477 as_fn_error $? "User supplied tool CUT=$tool_specified does not exist or is not executable" "$LINENO" 5 6478 fi 6479 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 6480 $as_echo "$tool_specified" >&6; } 6481 fi 6482 fi 6483 fi 6484 6485 fi 6486 6487 6488 6489 if test "x$CUT" = x; then 6490 as_fn_error $? "Could not find required tool for CUT" "$LINENO" 5 6491 fi 6492 6493 6494 6495 6496 6497 # Publish this variable in the help. 6498 6499 6500 if [ -z "${DATE+x}" ]; then 6501 # The variable is not set by user, try to locate tool using the code snippet 6502 for ac_prog in date 6503 do 6504 # Extract the first word of "$ac_prog", so it can be a program name with args. 6505 set dummy $ac_prog; ac_word=$2 6506 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6507 $as_echo_n "checking for $ac_word... " >&6; } 6508 if ${ac_cv_path_DATE+:} false; then : 6509 $as_echo_n "(cached) " >&6 6510 else 6511 case $DATE in 6512 [\\/]* | ?:[\\/]*) 6513 ac_cv_path_DATE="$DATE" # Let the user override the test with a path. 6514 ;; 6515 *) 6516 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6517 for as_dir in $PATH 6518 do 6519 IFS=$as_save_IFS 6520 test -z "$as_dir" && as_dir=. 6521 for ac_exec_ext in '' $ac_executable_extensions; do 6522 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6523 ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext" 6524 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6525 break 2 6526 fi 6527 done 6528 done 6529 IFS=$as_save_IFS 6530 6531 ;; 6532 esac 6533 fi 6534 DATE=$ac_cv_path_DATE 6535 if test -n "$DATE"; then 6536 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DATE" >&5 6537 $as_echo "$DATE" >&6; } 6538 else 6539 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6540 $as_echo "no" >&6; } 6541 fi 6542 6543 6544 test -n "$DATE" && break 6545 done 6546 6547 else 6548 # The variable is set, but is it from the command line or the environment? 6549 6550 # Try to remove the string !DATE! from our list. 6551 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DATE!/} 6552 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 6553 # If it failed, the variable was not from the command line. Ignore it, 6554 # but warn the user (except for BASH, which is always set by the calling BASH). 6555 if test "xDATE" != xBASH; then 6556 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DATE from the environment. Use command line variables instead." >&5 6557 $as_echo "$as_me: WARNING: Ignoring value of DATE from the environment. Use command line variables instead." >&2;} 6558 fi 6559 # Try to locate tool using the code snippet 6560 for ac_prog in date 6561 do 6562 # Extract the first word of "$ac_prog", so it can be a program name with args. 6563 set dummy $ac_prog; ac_word=$2 6564 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6565 $as_echo_n "checking for $ac_word... " >&6; } 6566 if ${ac_cv_path_DATE+:} false; then : 6567 $as_echo_n "(cached) " >&6 6568 else 6569 case $DATE in 6570 [\\/]* | ?:[\\/]*) 6571 ac_cv_path_DATE="$DATE" # Let the user override the test with a path. 6572 ;; 6573 *) 6574 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6575 for as_dir in $PATH 6576 do 6577 IFS=$as_save_IFS 6578 test -z "$as_dir" && as_dir=. 6579 for ac_exec_ext in '' $ac_executable_extensions; do 6580 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6581 ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext" 6582 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6583 break 2 6584 fi 6585 done 6586 done 6587 IFS=$as_save_IFS 6588 6589 ;; 6590 esac 6591 fi 6592 DATE=$ac_cv_path_DATE 6593 if test -n "$DATE"; then 6594 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DATE" >&5 6595 $as_echo "$DATE" >&6; } 6596 else 6597 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6598 $as_echo "no" >&6; } 6599 fi 6600 6601 6602 test -n "$DATE" && break 6603 done 6604 6605 else 6606 # If it succeeded, then it was overridden by the user. We will use it 6607 # for the tool. 6608 6609 # First remove it from the list of overridden variables, so we can test 6610 # for unknown variables in the end. 6611 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 6612 6613 # Check if we try to supply an empty value 6614 if test "x$DATE" = x; then 6615 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DATE= (no value)" >&5 6616 $as_echo "$as_me: Setting user supplied tool DATE= (no value)" >&6;} 6617 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DATE" >&5 6618 $as_echo_n "checking for DATE... " >&6; } 6619 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 6620 $as_echo "disabled" >&6; } 6621 else 6622 # Check if the provided tool contains a complete path. 6623 tool_specified="$DATE" 6624 tool_basename="${tool_specified##*/}" 6625 if test "x$tool_basename" = "x$tool_specified"; then 6626 # A command without a complete path is provided, search $PATH. 6627 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DATE=$tool_basename" >&5 6628 $as_echo "$as_me: Will search for user supplied tool DATE=$tool_basename" >&6;} 6629 # Extract the first word of "$tool_basename", so it can be a program name with args. 6630 set dummy $tool_basename; ac_word=$2 6631 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6632 $as_echo_n "checking for $ac_word... " >&6; } 6633 if ${ac_cv_path_DATE+:} false; then : 6634 $as_echo_n "(cached) " >&6 6635 else 6636 case $DATE in 6637 [\\/]* | ?:[\\/]*) 6638 ac_cv_path_DATE="$DATE" # Let the user override the test with a path. 6639 ;; 6640 *) 6641 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6642 for as_dir in $PATH 6643 do 6644 IFS=$as_save_IFS 6645 test -z "$as_dir" && as_dir=. 6646 for ac_exec_ext in '' $ac_executable_extensions; do 6647 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6648 ac_cv_path_DATE="$as_dir/$ac_word$ac_exec_ext" 6649 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6650 break 2 6651 fi 6652 done 6653 done 6654 IFS=$as_save_IFS 6655 6656 ;; 6657 esac 6658 fi 6659 DATE=$ac_cv_path_DATE 6660 if test -n "$DATE"; then 6661 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DATE" >&5 6662 $as_echo "$DATE" >&6; } 6663 else 6664 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6665 $as_echo "no" >&6; } 6666 fi 6667 6668 6669 if test "x$DATE" = x; then 6670 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 6671 fi 6672 else 6673 # Otherwise we believe it is a complete path. Use it as it is. 6674 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DATE=$tool_specified" >&5 6675 $as_echo "$as_me: Will use user supplied tool DATE=$tool_specified" >&6;} 6676 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DATE" >&5 6677 $as_echo_n "checking for DATE... " >&6; } 6678 if test ! -x "$tool_specified"; then 6679 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 6680 $as_echo "not found" >&6; } 6681 as_fn_error $? "User supplied tool DATE=$tool_specified does not exist or is not executable" "$LINENO" 5 6682 fi 6683 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 6684 $as_echo "$tool_specified" >&6; } 6685 fi 6686 fi 6687 fi 6688 6689 fi 6690 6691 6692 6693 if test "x$DATE" = x; then 6694 as_fn_error $? "Could not find required tool for DATE" "$LINENO" 5 6695 fi 6696 6697 6698 6699 6700 6701 # Publish this variable in the help. 6702 6703 6704 if [ -z "${DIFF+x}" ]; then 6705 # The variable is not set by user, try to locate tool using the code snippet 6706 for ac_prog in gdiff diff 6707 do 6708 # Extract the first word of "$ac_prog", so it can be a program name with args. 6709 set dummy $ac_prog; ac_word=$2 6710 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6711 $as_echo_n "checking for $ac_word... " >&6; } 6712 if ${ac_cv_path_DIFF+:} false; then : 6713 $as_echo_n "(cached) " >&6 6714 else 6715 case $DIFF in 6716 [\\/]* | ?:[\\/]*) 6717 ac_cv_path_DIFF="$DIFF" # Let the user override the test with a path. 6718 ;; 6719 *) 6720 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6721 for as_dir in $PATH 6722 do 6723 IFS=$as_save_IFS 6724 test -z "$as_dir" && as_dir=. 6725 for ac_exec_ext in '' $ac_executable_extensions; do 6726 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6727 ac_cv_path_DIFF="$as_dir/$ac_word$ac_exec_ext" 6728 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6729 break 2 6730 fi 6731 done 6732 done 6733 IFS=$as_save_IFS 6734 6735 ;; 6736 esac 6737 fi 6738 DIFF=$ac_cv_path_DIFF 6739 if test -n "$DIFF"; then 6740 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIFF" >&5 6741 $as_echo "$DIFF" >&6; } 6742 else 6743 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6744 $as_echo "no" >&6; } 6745 fi 6746 6747 6748 test -n "$DIFF" && break 6749 done 6750 6751 else 6752 # The variable is set, but is it from the command line or the environment? 6753 6754 # Try to remove the string !DIFF! from our list. 6755 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DIFF!/} 6756 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 6757 # If it failed, the variable was not from the command line. Ignore it, 6758 # but warn the user (except for BASH, which is always set by the calling BASH). 6759 if test "xDIFF" != xBASH; then 6760 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DIFF from the environment. Use command line variables instead." >&5 6761 $as_echo "$as_me: WARNING: Ignoring value of DIFF from the environment. Use command line variables instead." >&2;} 6762 fi 6763 # Try to locate tool using the code snippet 6764 for ac_prog in gdiff diff 6765 do 6766 # Extract the first word of "$ac_prog", so it can be a program name with args. 6767 set dummy $ac_prog; ac_word=$2 6768 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6769 $as_echo_n "checking for $ac_word... " >&6; } 6770 if ${ac_cv_path_DIFF+:} false; then : 6771 $as_echo_n "(cached) " >&6 6772 else 6773 case $DIFF in 6774 [\\/]* | ?:[\\/]*) 6775 ac_cv_path_DIFF="$DIFF" # Let the user override the test with a path. 6776 ;; 6777 *) 6778 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6779 for as_dir in $PATH 6780 do 6781 IFS=$as_save_IFS 6782 test -z "$as_dir" && as_dir=. 6783 for ac_exec_ext in '' $ac_executable_extensions; do 6784 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6785 ac_cv_path_DIFF="$as_dir/$ac_word$ac_exec_ext" 6786 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6787 break 2 6788 fi 6789 done 6790 done 6791 IFS=$as_save_IFS 6792 6793 ;; 6794 esac 6795 fi 6796 DIFF=$ac_cv_path_DIFF 6797 if test -n "$DIFF"; then 6798 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIFF" >&5 6799 $as_echo "$DIFF" >&6; } 6800 else 6801 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6802 $as_echo "no" >&6; } 6803 fi 6804 6805 6806 test -n "$DIFF" && break 6807 done 6808 6809 else 6810 # If it succeeded, then it was overridden by the user. We will use it 6811 # for the tool. 6812 6813 # First remove it from the list of overridden variables, so we can test 6814 # for unknown variables in the end. 6815 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 6816 6817 # Check if we try to supply an empty value 6818 if test "x$DIFF" = x; then 6819 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DIFF= (no value)" >&5 6820 $as_echo "$as_me: Setting user supplied tool DIFF= (no value)" >&6;} 6821 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIFF" >&5 6822 $as_echo_n "checking for DIFF... " >&6; } 6823 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 6824 $as_echo "disabled" >&6; } 6825 else 6826 # Check if the provided tool contains a complete path. 6827 tool_specified="$DIFF" 6828 tool_basename="${tool_specified##*/}" 6829 if test "x$tool_basename" = "x$tool_specified"; then 6830 # A command without a complete path is provided, search $PATH. 6831 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DIFF=$tool_basename" >&5 6832 $as_echo "$as_me: Will search for user supplied tool DIFF=$tool_basename" >&6;} 6833 # Extract the first word of "$tool_basename", so it can be a program name with args. 6834 set dummy $tool_basename; ac_word=$2 6835 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6836 $as_echo_n "checking for $ac_word... " >&6; } 6837 if ${ac_cv_path_DIFF+:} false; then : 6838 $as_echo_n "(cached) " >&6 6839 else 6840 case $DIFF in 6841 [\\/]* | ?:[\\/]*) 6842 ac_cv_path_DIFF="$DIFF" # Let the user override the test with a path. 6843 ;; 6844 *) 6845 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6846 for as_dir in $PATH 6847 do 6848 IFS=$as_save_IFS 6849 test -z "$as_dir" && as_dir=. 6850 for ac_exec_ext in '' $ac_executable_extensions; do 6851 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6852 ac_cv_path_DIFF="$as_dir/$ac_word$ac_exec_ext" 6853 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6854 break 2 6855 fi 6856 done 6857 done 6858 IFS=$as_save_IFS 6859 6860 ;; 6861 esac 6862 fi 6863 DIFF=$ac_cv_path_DIFF 6864 if test -n "$DIFF"; then 6865 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIFF" >&5 6866 $as_echo "$DIFF" >&6; } 6867 else 6868 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6869 $as_echo "no" >&6; } 6870 fi 6871 6872 6873 if test "x$DIFF" = x; then 6874 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 6875 fi 6876 else 6877 # Otherwise we believe it is a complete path. Use it as it is. 6878 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DIFF=$tool_specified" >&5 6879 $as_echo "$as_me: Will use user supplied tool DIFF=$tool_specified" >&6;} 6880 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIFF" >&5 6881 $as_echo_n "checking for DIFF... " >&6; } 6882 if test ! -x "$tool_specified"; then 6883 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 6884 $as_echo "not found" >&6; } 6885 as_fn_error $? "User supplied tool DIFF=$tool_specified does not exist or is not executable" "$LINENO" 5 6886 fi 6887 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 6888 $as_echo "$tool_specified" >&6; } 6889 fi 6890 fi 6891 fi 6892 6893 fi 6894 6895 6896 6897 if test "x$DIFF" = x; then 6898 as_fn_error $? "Could not find required tool for DIFF" "$LINENO" 5 6899 fi 6900 6901 6902 6903 6904 6905 # Publish this variable in the help. 6906 6907 6908 if [ -z "${DIRNAME+x}" ]; then 6909 # The variable is not set by user, try to locate tool using the code snippet 6910 for ac_prog in dirname 6911 do 6912 # Extract the first word of "$ac_prog", so it can be a program name with args. 6913 set dummy $ac_prog; ac_word=$2 6914 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6915 $as_echo_n "checking for $ac_word... " >&6; } 6916 if ${ac_cv_path_DIRNAME+:} false; then : 6917 $as_echo_n "(cached) " >&6 6918 else 6919 case $DIRNAME in 6920 [\\/]* | ?:[\\/]*) 6921 ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path. 6922 ;; 6923 *) 6924 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6925 for as_dir in $PATH 6926 do 6927 IFS=$as_save_IFS 6928 test -z "$as_dir" && as_dir=. 6929 for ac_exec_ext in '' $ac_executable_extensions; do 6930 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6931 ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext" 6932 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6933 break 2 6934 fi 6935 done 6936 done 6937 IFS=$as_save_IFS 6938 6939 ;; 6940 esac 6941 fi 6942 DIRNAME=$ac_cv_path_DIRNAME 6943 if test -n "$DIRNAME"; then 6944 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5 6945 $as_echo "$DIRNAME" >&6; } 6946 else 6947 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 6948 $as_echo "no" >&6; } 6949 fi 6950 6951 6952 test -n "$DIRNAME" && break 6953 done 6954 6955 else 6956 # The variable is set, but is it from the command line or the environment? 6957 6958 # Try to remove the string !DIRNAME! from our list. 6959 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DIRNAME!/} 6960 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 6961 # If it failed, the variable was not from the command line. Ignore it, 6962 # but warn the user (except for BASH, which is always set by the calling BASH). 6963 if test "xDIRNAME" != xBASH; then 6964 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DIRNAME from the environment. Use command line variables instead." >&5 6965 $as_echo "$as_me: WARNING: Ignoring value of DIRNAME from the environment. Use command line variables instead." >&2;} 6966 fi 6967 # Try to locate tool using the code snippet 6968 for ac_prog in dirname 6969 do 6970 # Extract the first word of "$ac_prog", so it can be a program name with args. 6971 set dummy $ac_prog; ac_word=$2 6972 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 6973 $as_echo_n "checking for $ac_word... " >&6; } 6974 if ${ac_cv_path_DIRNAME+:} false; then : 6975 $as_echo_n "(cached) " >&6 6976 else 6977 case $DIRNAME in 6978 [\\/]* | ?:[\\/]*) 6979 ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path. 6980 ;; 6981 *) 6982 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 6983 for as_dir in $PATH 6984 do 6985 IFS=$as_save_IFS 6986 test -z "$as_dir" && as_dir=. 6987 for ac_exec_ext in '' $ac_executable_extensions; do 6988 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 6989 ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext" 6990 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 6991 break 2 6992 fi 6993 done 6994 done 6995 IFS=$as_save_IFS 6996 6997 ;; 6998 esac 6999 fi 7000 DIRNAME=$ac_cv_path_DIRNAME 7001 if test -n "$DIRNAME"; then 7002 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5 7003 $as_echo "$DIRNAME" >&6; } 7004 else 7005 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7006 $as_echo "no" >&6; } 7007 fi 7008 7009 7010 test -n "$DIRNAME" && break 7011 done 7012 7013 else 7014 # If it succeeded, then it was overridden by the user. We will use it 7015 # for the tool. 7016 7017 # First remove it from the list of overridden variables, so we can test 7018 # for unknown variables in the end. 7019 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 7020 7021 # Check if we try to supply an empty value 7022 if test "x$DIRNAME" = x; then 7023 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DIRNAME= (no value)" >&5 7024 $as_echo "$as_me: Setting user supplied tool DIRNAME= (no value)" >&6;} 7025 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIRNAME" >&5 7026 $as_echo_n "checking for DIRNAME... " >&6; } 7027 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 7028 $as_echo "disabled" >&6; } 7029 else 7030 # Check if the provided tool contains a complete path. 7031 tool_specified="$DIRNAME" 7032 tool_basename="${tool_specified##*/}" 7033 if test "x$tool_basename" = "x$tool_specified"; then 7034 # A command without a complete path is provided, search $PATH. 7035 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DIRNAME=$tool_basename" >&5 7036 $as_echo "$as_me: Will search for user supplied tool DIRNAME=$tool_basename" >&6;} 7037 # Extract the first word of "$tool_basename", so it can be a program name with args. 7038 set dummy $tool_basename; ac_word=$2 7039 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7040 $as_echo_n "checking for $ac_word... " >&6; } 7041 if ${ac_cv_path_DIRNAME+:} false; then : 7042 $as_echo_n "(cached) " >&6 7043 else 7044 case $DIRNAME in 7045 [\\/]* | ?:[\\/]*) 7046 ac_cv_path_DIRNAME="$DIRNAME" # Let the user override the test with a path. 7047 ;; 7048 *) 7049 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7050 for as_dir in $PATH 7051 do 7052 IFS=$as_save_IFS 7053 test -z "$as_dir" && as_dir=. 7054 for ac_exec_ext in '' $ac_executable_extensions; do 7055 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7056 ac_cv_path_DIRNAME="$as_dir/$ac_word$ac_exec_ext" 7057 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7058 break 2 7059 fi 7060 done 7061 done 7062 IFS=$as_save_IFS 7063 7064 ;; 7065 esac 7066 fi 7067 DIRNAME=$ac_cv_path_DIRNAME 7068 if test -n "$DIRNAME"; then 7069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DIRNAME" >&5 7070 $as_echo "$DIRNAME" >&6; } 7071 else 7072 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7073 $as_echo "no" >&6; } 7074 fi 7075 7076 7077 if test "x$DIRNAME" = x; then 7078 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 7079 fi 7080 else 7081 # Otherwise we believe it is a complete path. Use it as it is. 7082 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DIRNAME=$tool_specified" >&5 7083 $as_echo "$as_me: Will use user supplied tool DIRNAME=$tool_specified" >&6;} 7084 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DIRNAME" >&5 7085 $as_echo_n "checking for DIRNAME... " >&6; } 7086 if test ! -x "$tool_specified"; then 7087 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 7088 $as_echo "not found" >&6; } 7089 as_fn_error $? "User supplied tool DIRNAME=$tool_specified does not exist or is not executable" "$LINENO" 5 7090 fi 7091 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 7092 $as_echo "$tool_specified" >&6; } 7093 fi 7094 fi 7095 fi 7096 7097 fi 7098 7099 7100 7101 if test "x$DIRNAME" = x; then 7102 as_fn_error $? "Could not find required tool for DIRNAME" "$LINENO" 5 7103 fi 7104 7105 7106 7107 7108 7109 # Publish this variable in the help. 7110 7111 7112 if [ -z "${ECHO+x}" ]; then 7113 # The variable is not set by user, try to locate tool using the code snippet 7114 for ac_prog in echo 7115 do 7116 # Extract the first word of "$ac_prog", so it can be a program name with args. 7117 set dummy $ac_prog; ac_word=$2 7118 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7119 $as_echo_n "checking for $ac_word... " >&6; } 7120 if ${ac_cv_path_ECHO+:} false; then : 7121 $as_echo_n "(cached) " >&6 7122 else 7123 case $ECHO in 7124 [\\/]* | ?:[\\/]*) 7125 ac_cv_path_ECHO="$ECHO" # Let the user override the test with a path. 7126 ;; 7127 *) 7128 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7129 for as_dir in $PATH 7130 do 7131 IFS=$as_save_IFS 7132 test -z "$as_dir" && as_dir=. 7133 for ac_exec_ext in '' $ac_executable_extensions; do 7134 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7135 ac_cv_path_ECHO="$as_dir/$ac_word$ac_exec_ext" 7136 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7137 break 2 7138 fi 7139 done 7140 done 7141 IFS=$as_save_IFS 7142 7143 ;; 7144 esac 7145 fi 7146 ECHO=$ac_cv_path_ECHO 7147 if test -n "$ECHO"; then 7148 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ECHO" >&5 7149 $as_echo "$ECHO" >&6; } 7150 else 7151 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7152 $as_echo "no" >&6; } 7153 fi 7154 7155 7156 test -n "$ECHO" && break 7157 done 7158 7159 else 7160 # The variable is set, but is it from the command line or the environment? 7161 7162 # Try to remove the string !ECHO! from our list. 7163 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ECHO!/} 7164 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 7165 # If it failed, the variable was not from the command line. Ignore it, 7166 # but warn the user (except for BASH, which is always set by the calling BASH). 7167 if test "xECHO" != xBASH; then 7168 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ECHO from the environment. Use command line variables instead." >&5 7169 $as_echo "$as_me: WARNING: Ignoring value of ECHO from the environment. Use command line variables instead." >&2;} 7170 fi 7171 # Try to locate tool using the code snippet 7172 for ac_prog in echo 7173 do 7174 # Extract the first word of "$ac_prog", so it can be a program name with args. 7175 set dummy $ac_prog; ac_word=$2 7176 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7177 $as_echo_n "checking for $ac_word... " >&6; } 7178 if ${ac_cv_path_ECHO+:} false; then : 7179 $as_echo_n "(cached) " >&6 7180 else 7181 case $ECHO in 7182 [\\/]* | ?:[\\/]*) 7183 ac_cv_path_ECHO="$ECHO" # Let the user override the test with a path. 7184 ;; 7185 *) 7186 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7187 for as_dir in $PATH 7188 do 7189 IFS=$as_save_IFS 7190 test -z "$as_dir" && as_dir=. 7191 for ac_exec_ext in '' $ac_executable_extensions; do 7192 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7193 ac_cv_path_ECHO="$as_dir/$ac_word$ac_exec_ext" 7194 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7195 break 2 7196 fi 7197 done 7198 done 7199 IFS=$as_save_IFS 7200 7201 ;; 7202 esac 7203 fi 7204 ECHO=$ac_cv_path_ECHO 7205 if test -n "$ECHO"; then 7206 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ECHO" >&5 7207 $as_echo "$ECHO" >&6; } 7208 else 7209 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7210 $as_echo "no" >&6; } 7211 fi 7212 7213 7214 test -n "$ECHO" && break 7215 done 7216 7217 else 7218 # If it succeeded, then it was overridden by the user. We will use it 7219 # for the tool. 7220 7221 # First remove it from the list of overridden variables, so we can test 7222 # for unknown variables in the end. 7223 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 7224 7225 # Check if we try to supply an empty value 7226 if test "x$ECHO" = x; then 7227 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ECHO= (no value)" >&5 7228 $as_echo "$as_me: Setting user supplied tool ECHO= (no value)" >&6;} 7229 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ECHO" >&5 7230 $as_echo_n "checking for ECHO... " >&6; } 7231 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 7232 $as_echo "disabled" >&6; } 7233 else 7234 # Check if the provided tool contains a complete path. 7235 tool_specified="$ECHO" 7236 tool_basename="${tool_specified##*/}" 7237 if test "x$tool_basename" = "x$tool_specified"; then 7238 # A command without a complete path is provided, search $PATH. 7239 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ECHO=$tool_basename" >&5 7240 $as_echo "$as_me: Will search for user supplied tool ECHO=$tool_basename" >&6;} 7241 # Extract the first word of "$tool_basename", so it can be a program name with args. 7242 set dummy $tool_basename; ac_word=$2 7243 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7244 $as_echo_n "checking for $ac_word... " >&6; } 7245 if ${ac_cv_path_ECHO+:} false; then : 7246 $as_echo_n "(cached) " >&6 7247 else 7248 case $ECHO in 7249 [\\/]* | ?:[\\/]*) 7250 ac_cv_path_ECHO="$ECHO" # Let the user override the test with a path. 7251 ;; 7252 *) 7253 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7254 for as_dir in $PATH 7255 do 7256 IFS=$as_save_IFS 7257 test -z "$as_dir" && as_dir=. 7258 for ac_exec_ext in '' $ac_executable_extensions; do 7259 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7260 ac_cv_path_ECHO="$as_dir/$ac_word$ac_exec_ext" 7261 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7262 break 2 7263 fi 7264 done 7265 done 7266 IFS=$as_save_IFS 7267 7268 ;; 7269 esac 7270 fi 7271 ECHO=$ac_cv_path_ECHO 7272 if test -n "$ECHO"; then 7273 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ECHO" >&5 7274 $as_echo "$ECHO" >&6; } 7275 else 7276 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7277 $as_echo "no" >&6; } 7278 fi 7279 7280 7281 if test "x$ECHO" = x; then 7282 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 7283 fi 7284 else 7285 # Otherwise we believe it is a complete path. Use it as it is. 7286 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ECHO=$tool_specified" >&5 7287 $as_echo "$as_me: Will use user supplied tool ECHO=$tool_specified" >&6;} 7288 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ECHO" >&5 7289 $as_echo_n "checking for ECHO... " >&6; } 7290 if test ! -x "$tool_specified"; then 7291 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 7292 $as_echo "not found" >&6; } 7293 as_fn_error $? "User supplied tool ECHO=$tool_specified does not exist or is not executable" "$LINENO" 5 7294 fi 7295 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 7296 $as_echo "$tool_specified" >&6; } 7297 fi 7298 fi 7299 fi 7300 7301 fi 7302 7303 7304 7305 if test "x$ECHO" = x; then 7306 as_fn_error $? "Could not find required tool for ECHO" "$LINENO" 5 7307 fi 7308 7309 7310 7311 7312 7313 # Publish this variable in the help. 7314 7315 7316 if [ -z "${EXPR+x}" ]; then 7317 # The variable is not set by user, try to locate tool using the code snippet 7318 for ac_prog in expr 7319 do 7320 # Extract the first word of "$ac_prog", so it can be a program name with args. 7321 set dummy $ac_prog; ac_word=$2 7322 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7323 $as_echo_n "checking for $ac_word... " >&6; } 7324 if ${ac_cv_path_EXPR+:} false; then : 7325 $as_echo_n "(cached) " >&6 7326 else 7327 case $EXPR in 7328 [\\/]* | ?:[\\/]*) 7329 ac_cv_path_EXPR="$EXPR" # Let the user override the test with a path. 7330 ;; 7331 *) 7332 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7333 for as_dir in $PATH 7334 do 7335 IFS=$as_save_IFS 7336 test -z "$as_dir" && as_dir=. 7337 for ac_exec_ext in '' $ac_executable_extensions; do 7338 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7339 ac_cv_path_EXPR="$as_dir/$ac_word$ac_exec_ext" 7340 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7341 break 2 7342 fi 7343 done 7344 done 7345 IFS=$as_save_IFS 7346 7347 ;; 7348 esac 7349 fi 7350 EXPR=$ac_cv_path_EXPR 7351 if test -n "$EXPR"; then 7352 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPR" >&5 7353 $as_echo "$EXPR" >&6; } 7354 else 7355 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7356 $as_echo "no" >&6; } 7357 fi 7358 7359 7360 test -n "$EXPR" && break 7361 done 7362 7363 else 7364 # The variable is set, but is it from the command line or the environment? 7365 7366 # Try to remove the string !EXPR! from our list. 7367 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!EXPR!/} 7368 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 7369 # If it failed, the variable was not from the command line. Ignore it, 7370 # but warn the user (except for BASH, which is always set by the calling BASH). 7371 if test "xEXPR" != xBASH; then 7372 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of EXPR from the environment. Use command line variables instead." >&5 7373 $as_echo "$as_me: WARNING: Ignoring value of EXPR from the environment. Use command line variables instead." >&2;} 7374 fi 7375 # Try to locate tool using the code snippet 7376 for ac_prog in expr 7377 do 7378 # Extract the first word of "$ac_prog", so it can be a program name with args. 7379 set dummy $ac_prog; ac_word=$2 7380 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7381 $as_echo_n "checking for $ac_word... " >&6; } 7382 if ${ac_cv_path_EXPR+:} false; then : 7383 $as_echo_n "(cached) " >&6 7384 else 7385 case $EXPR in 7386 [\\/]* | ?:[\\/]*) 7387 ac_cv_path_EXPR="$EXPR" # Let the user override the test with a path. 7388 ;; 7389 *) 7390 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7391 for as_dir in $PATH 7392 do 7393 IFS=$as_save_IFS 7394 test -z "$as_dir" && as_dir=. 7395 for ac_exec_ext in '' $ac_executable_extensions; do 7396 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7397 ac_cv_path_EXPR="$as_dir/$ac_word$ac_exec_ext" 7398 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7399 break 2 7400 fi 7401 done 7402 done 7403 IFS=$as_save_IFS 7404 7405 ;; 7406 esac 7407 fi 7408 EXPR=$ac_cv_path_EXPR 7409 if test -n "$EXPR"; then 7410 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPR" >&5 7411 $as_echo "$EXPR" >&6; } 7412 else 7413 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7414 $as_echo "no" >&6; } 7415 fi 7416 7417 7418 test -n "$EXPR" && break 7419 done 7420 7421 else 7422 # If it succeeded, then it was overridden by the user. We will use it 7423 # for the tool. 7424 7425 # First remove it from the list of overridden variables, so we can test 7426 # for unknown variables in the end. 7427 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 7428 7429 # Check if we try to supply an empty value 7430 if test "x$EXPR" = x; then 7431 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool EXPR= (no value)" >&5 7432 $as_echo "$as_me: Setting user supplied tool EXPR= (no value)" >&6;} 7433 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EXPR" >&5 7434 $as_echo_n "checking for EXPR... " >&6; } 7435 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 7436 $as_echo "disabled" >&6; } 7437 else 7438 # Check if the provided tool contains a complete path. 7439 tool_specified="$EXPR" 7440 tool_basename="${tool_specified##*/}" 7441 if test "x$tool_basename" = "x$tool_specified"; then 7442 # A command without a complete path is provided, search $PATH. 7443 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool EXPR=$tool_basename" >&5 7444 $as_echo "$as_me: Will search for user supplied tool EXPR=$tool_basename" >&6;} 7445 # Extract the first word of "$tool_basename", so it can be a program name with args. 7446 set dummy $tool_basename; ac_word=$2 7447 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7448 $as_echo_n "checking for $ac_word... " >&6; } 7449 if ${ac_cv_path_EXPR+:} false; then : 7450 $as_echo_n "(cached) " >&6 7451 else 7452 case $EXPR in 7453 [\\/]* | ?:[\\/]*) 7454 ac_cv_path_EXPR="$EXPR" # Let the user override the test with a path. 7455 ;; 7456 *) 7457 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7458 for as_dir in $PATH 7459 do 7460 IFS=$as_save_IFS 7461 test -z "$as_dir" && as_dir=. 7462 for ac_exec_ext in '' $ac_executable_extensions; do 7463 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7464 ac_cv_path_EXPR="$as_dir/$ac_word$ac_exec_ext" 7465 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7466 break 2 7467 fi 7468 done 7469 done 7470 IFS=$as_save_IFS 7471 7472 ;; 7473 esac 7474 fi 7475 EXPR=$ac_cv_path_EXPR 7476 if test -n "$EXPR"; then 7477 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXPR" >&5 7478 $as_echo "$EXPR" >&6; } 7479 else 7480 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7481 $as_echo "no" >&6; } 7482 fi 7483 7484 7485 if test "x$EXPR" = x; then 7486 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 7487 fi 7488 else 7489 # Otherwise we believe it is a complete path. Use it as it is. 7490 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool EXPR=$tool_specified" >&5 7491 $as_echo "$as_me: Will use user supplied tool EXPR=$tool_specified" >&6;} 7492 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EXPR" >&5 7493 $as_echo_n "checking for EXPR... " >&6; } 7494 if test ! -x "$tool_specified"; then 7495 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 7496 $as_echo "not found" >&6; } 7497 as_fn_error $? "User supplied tool EXPR=$tool_specified does not exist or is not executable" "$LINENO" 5 7498 fi 7499 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 7500 $as_echo "$tool_specified" >&6; } 7501 fi 7502 fi 7503 fi 7504 7505 fi 7506 7507 7508 7509 if test "x$EXPR" = x; then 7510 as_fn_error $? "Could not find required tool for EXPR" "$LINENO" 5 7511 fi 7512 7513 7514 7515 7516 7517 # Publish this variable in the help. 7518 7519 7520 if [ -z "${FILE+x}" ]; then 7521 # The variable is not set by user, try to locate tool using the code snippet 7522 for ac_prog in file 7523 do 7524 # Extract the first word of "$ac_prog", so it can be a program name with args. 7525 set dummy $ac_prog; ac_word=$2 7526 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7527 $as_echo_n "checking for $ac_word... " >&6; } 7528 if ${ac_cv_path_FILE+:} false; then : 7529 $as_echo_n "(cached) " >&6 7530 else 7531 case $FILE in 7532 [\\/]* | ?:[\\/]*) 7533 ac_cv_path_FILE="$FILE" # Let the user override the test with a path. 7534 ;; 7535 *) 7536 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7537 for as_dir in $PATH 7538 do 7539 IFS=$as_save_IFS 7540 test -z "$as_dir" && as_dir=. 7541 for ac_exec_ext in '' $ac_executable_extensions; do 7542 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7543 ac_cv_path_FILE="$as_dir/$ac_word$ac_exec_ext" 7544 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7545 break 2 7546 fi 7547 done 7548 done 7549 IFS=$as_save_IFS 7550 7551 ;; 7552 esac 7553 fi 7554 FILE=$ac_cv_path_FILE 7555 if test -n "$FILE"; then 7556 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILE" >&5 7557 $as_echo "$FILE" >&6; } 7558 else 7559 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7560 $as_echo "no" >&6; } 7561 fi 7562 7563 7564 test -n "$FILE" && break 7565 done 7566 7567 else 7568 # The variable is set, but is it from the command line or the environment? 7569 7570 # Try to remove the string !FILE! from our list. 7571 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FILE!/} 7572 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 7573 # If it failed, the variable was not from the command line. Ignore it, 7574 # but warn the user (except for BASH, which is always set by the calling BASH). 7575 if test "xFILE" != xBASH; then 7576 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FILE from the environment. Use command line variables instead." >&5 7577 $as_echo "$as_me: WARNING: Ignoring value of FILE from the environment. Use command line variables instead." >&2;} 7578 fi 7579 # Try to locate tool using the code snippet 7580 for ac_prog in file 7581 do 7582 # Extract the first word of "$ac_prog", so it can be a program name with args. 7583 set dummy $ac_prog; ac_word=$2 7584 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7585 $as_echo_n "checking for $ac_word... " >&6; } 7586 if ${ac_cv_path_FILE+:} false; then : 7587 $as_echo_n "(cached) " >&6 7588 else 7589 case $FILE in 7590 [\\/]* | ?:[\\/]*) 7591 ac_cv_path_FILE="$FILE" # Let the user override the test with a path. 7592 ;; 7593 *) 7594 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7595 for as_dir in $PATH 7596 do 7597 IFS=$as_save_IFS 7598 test -z "$as_dir" && as_dir=. 7599 for ac_exec_ext in '' $ac_executable_extensions; do 7600 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7601 ac_cv_path_FILE="$as_dir/$ac_word$ac_exec_ext" 7602 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7603 break 2 7604 fi 7605 done 7606 done 7607 IFS=$as_save_IFS 7608 7609 ;; 7610 esac 7611 fi 7612 FILE=$ac_cv_path_FILE 7613 if test -n "$FILE"; then 7614 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILE" >&5 7615 $as_echo "$FILE" >&6; } 7616 else 7617 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7618 $as_echo "no" >&6; } 7619 fi 7620 7621 7622 test -n "$FILE" && break 7623 done 7624 7625 else 7626 # If it succeeded, then it was overridden by the user. We will use it 7627 # for the tool. 7628 7629 # First remove it from the list of overridden variables, so we can test 7630 # for unknown variables in the end. 7631 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 7632 7633 # Check if we try to supply an empty value 7634 if test "x$FILE" = x; then 7635 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool FILE= (no value)" >&5 7636 $as_echo "$as_me: Setting user supplied tool FILE= (no value)" >&6;} 7637 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FILE" >&5 7638 $as_echo_n "checking for FILE... " >&6; } 7639 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 7640 $as_echo "disabled" >&6; } 7641 else 7642 # Check if the provided tool contains a complete path. 7643 tool_specified="$FILE" 7644 tool_basename="${tool_specified##*/}" 7645 if test "x$tool_basename" = "x$tool_specified"; then 7646 # A command without a complete path is provided, search $PATH. 7647 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FILE=$tool_basename" >&5 7648 $as_echo "$as_me: Will search for user supplied tool FILE=$tool_basename" >&6;} 7649 # Extract the first word of "$tool_basename", so it can be a program name with args. 7650 set dummy $tool_basename; ac_word=$2 7651 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7652 $as_echo_n "checking for $ac_word... " >&6; } 7653 if ${ac_cv_path_FILE+:} false; then : 7654 $as_echo_n "(cached) " >&6 7655 else 7656 case $FILE in 7657 [\\/]* | ?:[\\/]*) 7658 ac_cv_path_FILE="$FILE" # Let the user override the test with a path. 7659 ;; 7660 *) 7661 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7662 for as_dir in $PATH 7663 do 7664 IFS=$as_save_IFS 7665 test -z "$as_dir" && as_dir=. 7666 for ac_exec_ext in '' $ac_executable_extensions; do 7667 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7668 ac_cv_path_FILE="$as_dir/$ac_word$ac_exec_ext" 7669 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7670 break 2 7671 fi 7672 done 7673 done 7674 IFS=$as_save_IFS 7675 7676 ;; 7677 esac 7678 fi 7679 FILE=$ac_cv_path_FILE 7680 if test -n "$FILE"; then 7681 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FILE" >&5 7682 $as_echo "$FILE" >&6; } 7683 else 7684 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7685 $as_echo "no" >&6; } 7686 fi 7687 7688 7689 if test "x$FILE" = x; then 7690 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 7691 fi 7692 else 7693 # Otherwise we believe it is a complete path. Use it as it is. 7694 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FILE=$tool_specified" >&5 7695 $as_echo "$as_me: Will use user supplied tool FILE=$tool_specified" >&6;} 7696 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FILE" >&5 7697 $as_echo_n "checking for FILE... " >&6; } 7698 if test ! -x "$tool_specified"; then 7699 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 7700 $as_echo "not found" >&6; } 7701 as_fn_error $? "User supplied tool FILE=$tool_specified does not exist or is not executable" "$LINENO" 5 7702 fi 7703 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 7704 $as_echo "$tool_specified" >&6; } 7705 fi 7706 fi 7707 fi 7708 7709 fi 7710 7711 7712 7713 if test "x$FILE" = x; then 7714 as_fn_error $? "Could not find required tool for FILE" "$LINENO" 5 7715 fi 7716 7717 7718 7719 7720 7721 # Publish this variable in the help. 7722 7723 7724 if [ -z "${FIND+x}" ]; then 7725 # The variable is not set by user, try to locate tool using the code snippet 7726 for ac_prog in find 7727 do 7728 # Extract the first word of "$ac_prog", so it can be a program name with args. 7729 set dummy $ac_prog; ac_word=$2 7730 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7731 $as_echo_n "checking for $ac_word... " >&6; } 7732 if ${ac_cv_path_FIND+:} false; then : 7733 $as_echo_n "(cached) " >&6 7734 else 7735 case $FIND in 7736 [\\/]* | ?:[\\/]*) 7737 ac_cv_path_FIND="$FIND" # Let the user override the test with a path. 7738 ;; 7739 *) 7740 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7741 for as_dir in $PATH 7742 do 7743 IFS=$as_save_IFS 7744 test -z "$as_dir" && as_dir=. 7745 for ac_exec_ext in '' $ac_executable_extensions; do 7746 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7747 ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext" 7748 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7749 break 2 7750 fi 7751 done 7752 done 7753 IFS=$as_save_IFS 7754 7755 ;; 7756 esac 7757 fi 7758 FIND=$ac_cv_path_FIND 7759 if test -n "$FIND"; then 7760 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5 7761 $as_echo "$FIND" >&6; } 7762 else 7763 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7764 $as_echo "no" >&6; } 7765 fi 7766 7767 7768 test -n "$FIND" && break 7769 done 7770 7771 else 7772 # The variable is set, but is it from the command line or the environment? 7773 7774 # Try to remove the string !FIND! from our list. 7775 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FIND!/} 7776 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 7777 # If it failed, the variable was not from the command line. Ignore it, 7778 # but warn the user (except for BASH, which is always set by the calling BASH). 7779 if test "xFIND" != xBASH; then 7780 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FIND from the environment. Use command line variables instead." >&5 7781 $as_echo "$as_me: WARNING: Ignoring value of FIND from the environment. Use command line variables instead." >&2;} 7782 fi 7783 # Try to locate tool using the code snippet 7784 for ac_prog in find 7785 do 7786 # Extract the first word of "$ac_prog", so it can be a program name with args. 7787 set dummy $ac_prog; ac_word=$2 7788 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7789 $as_echo_n "checking for $ac_word... " >&6; } 7790 if ${ac_cv_path_FIND+:} false; then : 7791 $as_echo_n "(cached) " >&6 7792 else 7793 case $FIND in 7794 [\\/]* | ?:[\\/]*) 7795 ac_cv_path_FIND="$FIND" # Let the user override the test with a path. 7796 ;; 7797 *) 7798 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7799 for as_dir in $PATH 7800 do 7801 IFS=$as_save_IFS 7802 test -z "$as_dir" && as_dir=. 7803 for ac_exec_ext in '' $ac_executable_extensions; do 7804 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7805 ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext" 7806 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7807 break 2 7808 fi 7809 done 7810 done 7811 IFS=$as_save_IFS 7812 7813 ;; 7814 esac 7815 fi 7816 FIND=$ac_cv_path_FIND 7817 if test -n "$FIND"; then 7818 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5 7819 $as_echo "$FIND" >&6; } 7820 else 7821 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7822 $as_echo "no" >&6; } 7823 fi 7824 7825 7826 test -n "$FIND" && break 7827 done 7828 7829 else 7830 # If it succeeded, then it was overridden by the user. We will use it 7831 # for the tool. 7832 7833 # First remove it from the list of overridden variables, so we can test 7834 # for unknown variables in the end. 7835 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 7836 7837 # Check if we try to supply an empty value 7838 if test "x$FIND" = x; then 7839 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool FIND= (no value)" >&5 7840 $as_echo "$as_me: Setting user supplied tool FIND= (no value)" >&6;} 7841 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FIND" >&5 7842 $as_echo_n "checking for FIND... " >&6; } 7843 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 7844 $as_echo "disabled" >&6; } 7845 else 7846 # Check if the provided tool contains a complete path. 7847 tool_specified="$FIND" 7848 tool_basename="${tool_specified##*/}" 7849 if test "x$tool_basename" = "x$tool_specified"; then 7850 # A command without a complete path is provided, search $PATH. 7851 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FIND=$tool_basename" >&5 7852 $as_echo "$as_me: Will search for user supplied tool FIND=$tool_basename" >&6;} 7853 # Extract the first word of "$tool_basename", so it can be a program name with args. 7854 set dummy $tool_basename; ac_word=$2 7855 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7856 $as_echo_n "checking for $ac_word... " >&6; } 7857 if ${ac_cv_path_FIND+:} false; then : 7858 $as_echo_n "(cached) " >&6 7859 else 7860 case $FIND in 7861 [\\/]* | ?:[\\/]*) 7862 ac_cv_path_FIND="$FIND" # Let the user override the test with a path. 7863 ;; 7864 *) 7865 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7866 for as_dir in $PATH 7867 do 7868 IFS=$as_save_IFS 7869 test -z "$as_dir" && as_dir=. 7870 for ac_exec_ext in '' $ac_executable_extensions; do 7871 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7872 ac_cv_path_FIND="$as_dir/$ac_word$ac_exec_ext" 7873 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7874 break 2 7875 fi 7876 done 7877 done 7878 IFS=$as_save_IFS 7879 7880 ;; 7881 esac 7882 fi 7883 FIND=$ac_cv_path_FIND 7884 if test -n "$FIND"; then 7885 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FIND" >&5 7886 $as_echo "$FIND" >&6; } 7887 else 7888 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7889 $as_echo "no" >&6; } 7890 fi 7891 7892 7893 if test "x$FIND" = x; then 7894 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 7895 fi 7896 else 7897 # Otherwise we believe it is a complete path. Use it as it is. 7898 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FIND=$tool_specified" >&5 7899 $as_echo "$as_me: Will use user supplied tool FIND=$tool_specified" >&6;} 7900 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FIND" >&5 7901 $as_echo_n "checking for FIND... " >&6; } 7902 if test ! -x "$tool_specified"; then 7903 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 7904 $as_echo "not found" >&6; } 7905 as_fn_error $? "User supplied tool FIND=$tool_specified does not exist or is not executable" "$LINENO" 5 7906 fi 7907 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 7908 $as_echo "$tool_specified" >&6; } 7909 fi 7910 fi 7911 fi 7912 7913 fi 7914 7915 7916 7917 if test "x$FIND" = x; then 7918 as_fn_error $? "Could not find required tool for FIND" "$LINENO" 5 7919 fi 7920 7921 7922 7923 7924 7925 # Publish this variable in the help. 7926 7927 7928 if [ -z "${HEAD+x}" ]; then 7929 # The variable is not set by user, try to locate tool using the code snippet 7930 for ac_prog in head 7931 do 7932 # Extract the first word of "$ac_prog", so it can be a program name with args. 7933 set dummy $ac_prog; ac_word=$2 7934 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7935 $as_echo_n "checking for $ac_word... " >&6; } 7936 if ${ac_cv_path_HEAD+:} false; then : 7937 $as_echo_n "(cached) " >&6 7938 else 7939 case $HEAD in 7940 [\\/]* | ?:[\\/]*) 7941 ac_cv_path_HEAD="$HEAD" # Let the user override the test with a path. 7942 ;; 7943 *) 7944 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 7945 for as_dir in $PATH 7946 do 7947 IFS=$as_save_IFS 7948 test -z "$as_dir" && as_dir=. 7949 for ac_exec_ext in '' $ac_executable_extensions; do 7950 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 7951 ac_cv_path_HEAD="$as_dir/$ac_word$ac_exec_ext" 7952 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 7953 break 2 7954 fi 7955 done 7956 done 7957 IFS=$as_save_IFS 7958 7959 ;; 7960 esac 7961 fi 7962 HEAD=$ac_cv_path_HEAD 7963 if test -n "$HEAD"; then 7964 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HEAD" >&5 7965 $as_echo "$HEAD" >&6; } 7966 else 7967 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 7968 $as_echo "no" >&6; } 7969 fi 7970 7971 7972 test -n "$HEAD" && break 7973 done 7974 7975 else 7976 # The variable is set, but is it from the command line or the environment? 7977 7978 # Try to remove the string !HEAD! from our list. 7979 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!HEAD!/} 7980 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 7981 # If it failed, the variable was not from the command line. Ignore it, 7982 # but warn the user (except for BASH, which is always set by the calling BASH). 7983 if test "xHEAD" != xBASH; then 7984 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of HEAD from the environment. Use command line variables instead." >&5 7985 $as_echo "$as_me: WARNING: Ignoring value of HEAD from the environment. Use command line variables instead." >&2;} 7986 fi 7987 # Try to locate tool using the code snippet 7988 for ac_prog in head 7989 do 7990 # Extract the first word of "$ac_prog", so it can be a program name with args. 7991 set dummy $ac_prog; ac_word=$2 7992 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 7993 $as_echo_n "checking for $ac_word... " >&6; } 7994 if ${ac_cv_path_HEAD+:} false; then : 7995 $as_echo_n "(cached) " >&6 7996 else 7997 case $HEAD in 7998 [\\/]* | ?:[\\/]*) 7999 ac_cv_path_HEAD="$HEAD" # Let the user override the test with a path. 8000 ;; 8001 *) 8002 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8003 for as_dir in $PATH 8004 do 8005 IFS=$as_save_IFS 8006 test -z "$as_dir" && as_dir=. 8007 for ac_exec_ext in '' $ac_executable_extensions; do 8008 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8009 ac_cv_path_HEAD="$as_dir/$ac_word$ac_exec_ext" 8010 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8011 break 2 8012 fi 8013 done 8014 done 8015 IFS=$as_save_IFS 8016 8017 ;; 8018 esac 8019 fi 8020 HEAD=$ac_cv_path_HEAD 8021 if test -n "$HEAD"; then 8022 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HEAD" >&5 8023 $as_echo "$HEAD" >&6; } 8024 else 8025 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8026 $as_echo "no" >&6; } 8027 fi 8028 8029 8030 test -n "$HEAD" && break 8031 done 8032 8033 else 8034 # If it succeeded, then it was overridden by the user. We will use it 8035 # for the tool. 8036 8037 # First remove it from the list of overridden variables, so we can test 8038 # for unknown variables in the end. 8039 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 8040 8041 # Check if we try to supply an empty value 8042 if test "x$HEAD" = x; then 8043 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool HEAD= (no value)" >&5 8044 $as_echo "$as_me: Setting user supplied tool HEAD= (no value)" >&6;} 8045 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HEAD" >&5 8046 $as_echo_n "checking for HEAD... " >&6; } 8047 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 8048 $as_echo "disabled" >&6; } 8049 else 8050 # Check if the provided tool contains a complete path. 8051 tool_specified="$HEAD" 8052 tool_basename="${tool_specified##*/}" 8053 if test "x$tool_basename" = "x$tool_specified"; then 8054 # A command without a complete path is provided, search $PATH. 8055 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool HEAD=$tool_basename" >&5 8056 $as_echo "$as_me: Will search for user supplied tool HEAD=$tool_basename" >&6;} 8057 # Extract the first word of "$tool_basename", so it can be a program name with args. 8058 set dummy $tool_basename; ac_word=$2 8059 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8060 $as_echo_n "checking for $ac_word... " >&6; } 8061 if ${ac_cv_path_HEAD+:} false; then : 8062 $as_echo_n "(cached) " >&6 8063 else 8064 case $HEAD in 8065 [\\/]* | ?:[\\/]*) 8066 ac_cv_path_HEAD="$HEAD" # Let the user override the test with a path. 8067 ;; 8068 *) 8069 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8070 for as_dir in $PATH 8071 do 8072 IFS=$as_save_IFS 8073 test -z "$as_dir" && as_dir=. 8074 for ac_exec_ext in '' $ac_executable_extensions; do 8075 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8076 ac_cv_path_HEAD="$as_dir/$ac_word$ac_exec_ext" 8077 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8078 break 2 8079 fi 8080 done 8081 done 8082 IFS=$as_save_IFS 8083 8084 ;; 8085 esac 8086 fi 8087 HEAD=$ac_cv_path_HEAD 8088 if test -n "$HEAD"; then 8089 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HEAD" >&5 8090 $as_echo "$HEAD" >&6; } 8091 else 8092 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8093 $as_echo "no" >&6; } 8094 fi 8095 8096 8097 if test "x$HEAD" = x; then 8098 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 8099 fi 8100 else 8101 # Otherwise we believe it is a complete path. Use it as it is. 8102 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool HEAD=$tool_specified" >&5 8103 $as_echo "$as_me: Will use user supplied tool HEAD=$tool_specified" >&6;} 8104 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HEAD" >&5 8105 $as_echo_n "checking for HEAD... " >&6; } 8106 if test ! -x "$tool_specified"; then 8107 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 8108 $as_echo "not found" >&6; } 8109 as_fn_error $? "User supplied tool HEAD=$tool_specified does not exist or is not executable" "$LINENO" 5 8110 fi 8111 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 8112 $as_echo "$tool_specified" >&6; } 8113 fi 8114 fi 8115 fi 8116 8117 fi 8118 8119 8120 8121 if test "x$HEAD" = x; then 8122 as_fn_error $? "Could not find required tool for HEAD" "$LINENO" 5 8123 fi 8124 8125 8126 8127 8128 8129 # Publish this variable in the help. 8130 8131 8132 if [ -z "${LN+x}" ]; then 8133 # The variable is not set by user, try to locate tool using the code snippet 8134 for ac_prog in ln 8135 do 8136 # Extract the first word of "$ac_prog", so it can be a program name with args. 8137 set dummy $ac_prog; ac_word=$2 8138 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8139 $as_echo_n "checking for $ac_word... " >&6; } 8140 if ${ac_cv_path_LN+:} false; then : 8141 $as_echo_n "(cached) " >&6 8142 else 8143 case $LN in 8144 [\\/]* | ?:[\\/]*) 8145 ac_cv_path_LN="$LN" # Let the user override the test with a path. 8146 ;; 8147 *) 8148 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8149 for as_dir in $PATH 8150 do 8151 IFS=$as_save_IFS 8152 test -z "$as_dir" && as_dir=. 8153 for ac_exec_ext in '' $ac_executable_extensions; do 8154 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8155 ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext" 8156 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8157 break 2 8158 fi 8159 done 8160 done 8161 IFS=$as_save_IFS 8162 8163 ;; 8164 esac 8165 fi 8166 LN=$ac_cv_path_LN 8167 if test -n "$LN"; then 8168 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5 8169 $as_echo "$LN" >&6; } 8170 else 8171 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8172 $as_echo "no" >&6; } 8173 fi 8174 8175 8176 test -n "$LN" && break 8177 done 8178 8179 else 8180 # The variable is set, but is it from the command line or the environment? 8181 8182 # Try to remove the string !LN! from our list. 8183 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LN!/} 8184 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 8185 # If it failed, the variable was not from the command line. Ignore it, 8186 # but warn the user (except for BASH, which is always set by the calling BASH). 8187 if test "xLN" != xBASH; then 8188 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LN from the environment. Use command line variables instead." >&5 8189 $as_echo "$as_me: WARNING: Ignoring value of LN from the environment. Use command line variables instead." >&2;} 8190 fi 8191 # Try to locate tool using the code snippet 8192 for ac_prog in ln 8193 do 8194 # Extract the first word of "$ac_prog", so it can be a program name with args. 8195 set dummy $ac_prog; ac_word=$2 8196 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8197 $as_echo_n "checking for $ac_word... " >&6; } 8198 if ${ac_cv_path_LN+:} false; then : 8199 $as_echo_n "(cached) " >&6 8200 else 8201 case $LN in 8202 [\\/]* | ?:[\\/]*) 8203 ac_cv_path_LN="$LN" # Let the user override the test with a path. 8204 ;; 8205 *) 8206 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8207 for as_dir in $PATH 8208 do 8209 IFS=$as_save_IFS 8210 test -z "$as_dir" && as_dir=. 8211 for ac_exec_ext in '' $ac_executable_extensions; do 8212 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8213 ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext" 8214 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8215 break 2 8216 fi 8217 done 8218 done 8219 IFS=$as_save_IFS 8220 8221 ;; 8222 esac 8223 fi 8224 LN=$ac_cv_path_LN 8225 if test -n "$LN"; then 8226 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5 8227 $as_echo "$LN" >&6; } 8228 else 8229 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8230 $as_echo "no" >&6; } 8231 fi 8232 8233 8234 test -n "$LN" && break 8235 done 8236 8237 else 8238 # If it succeeded, then it was overridden by the user. We will use it 8239 # for the tool. 8240 8241 # First remove it from the list of overridden variables, so we can test 8242 # for unknown variables in the end. 8243 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 8244 8245 # Check if we try to supply an empty value 8246 if test "x$LN" = x; then 8247 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool LN= (no value)" >&5 8248 $as_echo "$as_me: Setting user supplied tool LN= (no value)" >&6;} 8249 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LN" >&5 8250 $as_echo_n "checking for LN... " >&6; } 8251 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 8252 $as_echo "disabled" >&6; } 8253 else 8254 # Check if the provided tool contains a complete path. 8255 tool_specified="$LN" 8256 tool_basename="${tool_specified##*/}" 8257 if test "x$tool_basename" = "x$tool_specified"; then 8258 # A command without a complete path is provided, search $PATH. 8259 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LN=$tool_basename" >&5 8260 $as_echo "$as_me: Will search for user supplied tool LN=$tool_basename" >&6;} 8261 # Extract the first word of "$tool_basename", so it can be a program name with args. 8262 set dummy $tool_basename; ac_word=$2 8263 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8264 $as_echo_n "checking for $ac_word... " >&6; } 8265 if ${ac_cv_path_LN+:} false; then : 8266 $as_echo_n "(cached) " >&6 8267 else 8268 case $LN in 8269 [\\/]* | ?:[\\/]*) 8270 ac_cv_path_LN="$LN" # Let the user override the test with a path. 8271 ;; 8272 *) 8273 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8274 for as_dir in $PATH 8275 do 8276 IFS=$as_save_IFS 8277 test -z "$as_dir" && as_dir=. 8278 for ac_exec_ext in '' $ac_executable_extensions; do 8279 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8280 ac_cv_path_LN="$as_dir/$ac_word$ac_exec_ext" 8281 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8282 break 2 8283 fi 8284 done 8285 done 8286 IFS=$as_save_IFS 8287 8288 ;; 8289 esac 8290 fi 8291 LN=$ac_cv_path_LN 8292 if test -n "$LN"; then 8293 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LN" >&5 8294 $as_echo "$LN" >&6; } 8295 else 8296 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8297 $as_echo "no" >&6; } 8298 fi 8299 8300 8301 if test "x$LN" = x; then 8302 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 8303 fi 8304 else 8305 # Otherwise we believe it is a complete path. Use it as it is. 8306 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LN=$tool_specified" >&5 8307 $as_echo "$as_me: Will use user supplied tool LN=$tool_specified" >&6;} 8308 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LN" >&5 8309 $as_echo_n "checking for LN... " >&6; } 8310 if test ! -x "$tool_specified"; then 8311 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 8312 $as_echo "not found" >&6; } 8313 as_fn_error $? "User supplied tool LN=$tool_specified does not exist or is not executable" "$LINENO" 5 8314 fi 8315 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 8316 $as_echo "$tool_specified" >&6; } 8317 fi 8318 fi 8319 fi 8320 8321 fi 8322 8323 8324 8325 if test "x$LN" = x; then 8326 as_fn_error $? "Could not find required tool for LN" "$LINENO" 5 8327 fi 8328 8329 8330 8331 8332 8333 # Publish this variable in the help. 8334 8335 8336 if [ -z "${LS+x}" ]; then 8337 # The variable is not set by user, try to locate tool using the code snippet 8338 for ac_prog in ls 8339 do 8340 # Extract the first word of "$ac_prog", so it can be a program name with args. 8341 set dummy $ac_prog; ac_word=$2 8342 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8343 $as_echo_n "checking for $ac_word... " >&6; } 8344 if ${ac_cv_path_LS+:} false; then : 8345 $as_echo_n "(cached) " >&6 8346 else 8347 case $LS in 8348 [\\/]* | ?:[\\/]*) 8349 ac_cv_path_LS="$LS" # Let the user override the test with a path. 8350 ;; 8351 *) 8352 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8353 for as_dir in $PATH 8354 do 8355 IFS=$as_save_IFS 8356 test -z "$as_dir" && as_dir=. 8357 for ac_exec_ext in '' $ac_executable_extensions; do 8358 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8359 ac_cv_path_LS="$as_dir/$ac_word$ac_exec_ext" 8360 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8361 break 2 8362 fi 8363 done 8364 done 8365 IFS=$as_save_IFS 8366 8367 ;; 8368 esac 8369 fi 8370 LS=$ac_cv_path_LS 8371 if test -n "$LS"; then 8372 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LS" >&5 8373 $as_echo "$LS" >&6; } 8374 else 8375 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8376 $as_echo "no" >&6; } 8377 fi 8378 8379 8380 test -n "$LS" && break 8381 done 8382 8383 else 8384 # The variable is set, but is it from the command line or the environment? 8385 8386 # Try to remove the string !LS! from our list. 8387 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LS!/} 8388 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 8389 # If it failed, the variable was not from the command line. Ignore it, 8390 # but warn the user (except for BASH, which is always set by the calling BASH). 8391 if test "xLS" != xBASH; then 8392 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LS from the environment. Use command line variables instead." >&5 8393 $as_echo "$as_me: WARNING: Ignoring value of LS from the environment. Use command line variables instead." >&2;} 8394 fi 8395 # Try to locate tool using the code snippet 8396 for ac_prog in ls 8397 do 8398 # Extract the first word of "$ac_prog", so it can be a program name with args. 8399 set dummy $ac_prog; ac_word=$2 8400 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8401 $as_echo_n "checking for $ac_word... " >&6; } 8402 if ${ac_cv_path_LS+:} false; then : 8403 $as_echo_n "(cached) " >&6 8404 else 8405 case $LS in 8406 [\\/]* | ?:[\\/]*) 8407 ac_cv_path_LS="$LS" # Let the user override the test with a path. 8408 ;; 8409 *) 8410 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8411 for as_dir in $PATH 8412 do 8413 IFS=$as_save_IFS 8414 test -z "$as_dir" && as_dir=. 8415 for ac_exec_ext in '' $ac_executable_extensions; do 8416 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8417 ac_cv_path_LS="$as_dir/$ac_word$ac_exec_ext" 8418 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8419 break 2 8420 fi 8421 done 8422 done 8423 IFS=$as_save_IFS 8424 8425 ;; 8426 esac 8427 fi 8428 LS=$ac_cv_path_LS 8429 if test -n "$LS"; then 8430 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LS" >&5 8431 $as_echo "$LS" >&6; } 8432 else 8433 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8434 $as_echo "no" >&6; } 8435 fi 8436 8437 8438 test -n "$LS" && break 8439 done 8440 8441 else 8442 # If it succeeded, then it was overridden by the user. We will use it 8443 # for the tool. 8444 8445 # First remove it from the list of overridden variables, so we can test 8446 # for unknown variables in the end. 8447 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 8448 8449 # Check if we try to supply an empty value 8450 if test "x$LS" = x; then 8451 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool LS= (no value)" >&5 8452 $as_echo "$as_me: Setting user supplied tool LS= (no value)" >&6;} 8453 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LS" >&5 8454 $as_echo_n "checking for LS... " >&6; } 8455 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 8456 $as_echo "disabled" >&6; } 8457 else 8458 # Check if the provided tool contains a complete path. 8459 tool_specified="$LS" 8460 tool_basename="${tool_specified##*/}" 8461 if test "x$tool_basename" = "x$tool_specified"; then 8462 # A command without a complete path is provided, search $PATH. 8463 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LS=$tool_basename" >&5 8464 $as_echo "$as_me: Will search for user supplied tool LS=$tool_basename" >&6;} 8465 # Extract the first word of "$tool_basename", so it can be a program name with args. 8466 set dummy $tool_basename; ac_word=$2 8467 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8468 $as_echo_n "checking for $ac_word... " >&6; } 8469 if ${ac_cv_path_LS+:} false; then : 8470 $as_echo_n "(cached) " >&6 8471 else 8472 case $LS in 8473 [\\/]* | ?:[\\/]*) 8474 ac_cv_path_LS="$LS" # Let the user override the test with a path. 8475 ;; 8476 *) 8477 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8478 for as_dir in $PATH 8479 do 8480 IFS=$as_save_IFS 8481 test -z "$as_dir" && as_dir=. 8482 for ac_exec_ext in '' $ac_executable_extensions; do 8483 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8484 ac_cv_path_LS="$as_dir/$ac_word$ac_exec_ext" 8485 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8486 break 2 8487 fi 8488 done 8489 done 8490 IFS=$as_save_IFS 8491 8492 ;; 8493 esac 8494 fi 8495 LS=$ac_cv_path_LS 8496 if test -n "$LS"; then 8497 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LS" >&5 8498 $as_echo "$LS" >&6; } 8499 else 8500 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8501 $as_echo "no" >&6; } 8502 fi 8503 8504 8505 if test "x$LS" = x; then 8506 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 8507 fi 8508 else 8509 # Otherwise we believe it is a complete path. Use it as it is. 8510 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LS=$tool_specified" >&5 8511 $as_echo "$as_me: Will use user supplied tool LS=$tool_specified" >&6;} 8512 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LS" >&5 8513 $as_echo_n "checking for LS... " >&6; } 8514 if test ! -x "$tool_specified"; then 8515 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 8516 $as_echo "not found" >&6; } 8517 as_fn_error $? "User supplied tool LS=$tool_specified does not exist or is not executable" "$LINENO" 5 8518 fi 8519 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 8520 $as_echo "$tool_specified" >&6; } 8521 fi 8522 fi 8523 fi 8524 8525 fi 8526 8527 8528 8529 if test "x$LS" = x; then 8530 as_fn_error $? "Could not find required tool for LS" "$LINENO" 5 8531 fi 8532 8533 8534 8535 8536 8537 # Publish this variable in the help. 8538 8539 8540 if [ -z "${MKDIR+x}" ]; then 8541 # The variable is not set by user, try to locate tool using the code snippet 8542 for ac_prog in mkdir 8543 do 8544 # Extract the first word of "$ac_prog", so it can be a program name with args. 8545 set dummy $ac_prog; ac_word=$2 8546 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8547 $as_echo_n "checking for $ac_word... " >&6; } 8548 if ${ac_cv_path_MKDIR+:} false; then : 8549 $as_echo_n "(cached) " >&6 8550 else 8551 case $MKDIR in 8552 [\\/]* | ?:[\\/]*) 8553 ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path. 8554 ;; 8555 *) 8556 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8557 for as_dir in $PATH 8558 do 8559 IFS=$as_save_IFS 8560 test -z "$as_dir" && as_dir=. 8561 for ac_exec_ext in '' $ac_executable_extensions; do 8562 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8563 ac_cv_path_MKDIR="$as_dir/$ac_word$ac_exec_ext" 8564 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8565 break 2 8566 fi 8567 done 8568 done 8569 IFS=$as_save_IFS 8570 8571 ;; 8572 esac 8573 fi 8574 MKDIR=$ac_cv_path_MKDIR 8575 if test -n "$MKDIR"; then 8576 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR" >&5 8577 $as_echo "$MKDIR" >&6; } 8578 else 8579 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8580 $as_echo "no" >&6; } 8581 fi 8582 8583 8584 test -n "$MKDIR" && break 8585 done 8586 8587 else 8588 # The variable is set, but is it from the command line or the environment? 8589 8590 # Try to remove the string !MKDIR! from our list. 8591 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MKDIR!/} 8592 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 8593 # If it failed, the variable was not from the command line. Ignore it, 8594 # but warn the user (except for BASH, which is always set by the calling BASH). 8595 if test "xMKDIR" != xBASH; then 8596 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MKDIR from the environment. Use command line variables instead." >&5 8597 $as_echo "$as_me: WARNING: Ignoring value of MKDIR from the environment. Use command line variables instead." >&2;} 8598 fi 8599 # Try to locate tool using the code snippet 8600 for ac_prog in mkdir 8601 do 8602 # Extract the first word of "$ac_prog", so it can be a program name with args. 8603 set dummy $ac_prog; ac_word=$2 8604 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8605 $as_echo_n "checking for $ac_word... " >&6; } 8606 if ${ac_cv_path_MKDIR+:} false; then : 8607 $as_echo_n "(cached) " >&6 8608 else 8609 case $MKDIR in 8610 [\\/]* | ?:[\\/]*) 8611 ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path. 8612 ;; 8613 *) 8614 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8615 for as_dir in $PATH 8616 do 8617 IFS=$as_save_IFS 8618 test -z "$as_dir" && as_dir=. 8619 for ac_exec_ext in '' $ac_executable_extensions; do 8620 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8621 ac_cv_path_MKDIR="$as_dir/$ac_word$ac_exec_ext" 8622 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8623 break 2 8624 fi 8625 done 8626 done 8627 IFS=$as_save_IFS 8628 8629 ;; 8630 esac 8631 fi 8632 MKDIR=$ac_cv_path_MKDIR 8633 if test -n "$MKDIR"; then 8634 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR" >&5 8635 $as_echo "$MKDIR" >&6; } 8636 else 8637 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8638 $as_echo "no" >&6; } 8639 fi 8640 8641 8642 test -n "$MKDIR" && break 8643 done 8644 8645 else 8646 # If it succeeded, then it was overridden by the user. We will use it 8647 # for the tool. 8648 8649 # First remove it from the list of overridden variables, so we can test 8650 # for unknown variables in the end. 8651 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 8652 8653 # Check if we try to supply an empty value 8654 if test "x$MKDIR" = x; then 8655 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool MKDIR= (no value)" >&5 8656 $as_echo "$as_me: Setting user supplied tool MKDIR= (no value)" >&6;} 8657 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKDIR" >&5 8658 $as_echo_n "checking for MKDIR... " >&6; } 8659 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 8660 $as_echo "disabled" >&6; } 8661 else 8662 # Check if the provided tool contains a complete path. 8663 tool_specified="$MKDIR" 8664 tool_basename="${tool_specified##*/}" 8665 if test "x$tool_basename" = "x$tool_specified"; then 8666 # A command without a complete path is provided, search $PATH. 8667 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MKDIR=$tool_basename" >&5 8668 $as_echo "$as_me: Will search for user supplied tool MKDIR=$tool_basename" >&6;} 8669 # Extract the first word of "$tool_basename", so it can be a program name with args. 8670 set dummy $tool_basename; ac_word=$2 8671 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8672 $as_echo_n "checking for $ac_word... " >&6; } 8673 if ${ac_cv_path_MKDIR+:} false; then : 8674 $as_echo_n "(cached) " >&6 8675 else 8676 case $MKDIR in 8677 [\\/]* | ?:[\\/]*) 8678 ac_cv_path_MKDIR="$MKDIR" # Let the user override the test with a path. 8679 ;; 8680 *) 8681 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8682 for as_dir in $PATH 8683 do 8684 IFS=$as_save_IFS 8685 test -z "$as_dir" && as_dir=. 8686 for ac_exec_ext in '' $ac_executable_extensions; do 8687 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8688 ac_cv_path_MKDIR="$as_dir/$ac_word$ac_exec_ext" 8689 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8690 break 2 8691 fi 8692 done 8693 done 8694 IFS=$as_save_IFS 8695 8696 ;; 8697 esac 8698 fi 8699 MKDIR=$ac_cv_path_MKDIR 8700 if test -n "$MKDIR"; then 8701 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKDIR" >&5 8702 $as_echo "$MKDIR" >&6; } 8703 else 8704 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8705 $as_echo "no" >&6; } 8706 fi 8707 8708 8709 if test "x$MKDIR" = x; then 8710 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 8711 fi 8712 else 8713 # Otherwise we believe it is a complete path. Use it as it is. 8714 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MKDIR=$tool_specified" >&5 8715 $as_echo "$as_me: Will use user supplied tool MKDIR=$tool_specified" >&6;} 8716 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKDIR" >&5 8717 $as_echo_n "checking for MKDIR... " >&6; } 8718 if test ! -x "$tool_specified"; then 8719 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 8720 $as_echo "not found" >&6; } 8721 as_fn_error $? "User supplied tool MKDIR=$tool_specified does not exist or is not executable" "$LINENO" 5 8722 fi 8723 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 8724 $as_echo "$tool_specified" >&6; } 8725 fi 8726 fi 8727 fi 8728 8729 fi 8730 8731 8732 8733 if test "x$MKDIR" = x; then 8734 as_fn_error $? "Could not find required tool for MKDIR" "$LINENO" 5 8735 fi 8736 8737 8738 8739 8740 8741 # Publish this variable in the help. 8742 8743 8744 if [ -z "${MKTEMP+x}" ]; then 8745 # The variable is not set by user, try to locate tool using the code snippet 8746 for ac_prog in mktemp 8747 do 8748 # Extract the first word of "$ac_prog", so it can be a program name with args. 8749 set dummy $ac_prog; ac_word=$2 8750 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8751 $as_echo_n "checking for $ac_word... " >&6; } 8752 if ${ac_cv_path_MKTEMP+:} false; then : 8753 $as_echo_n "(cached) " >&6 8754 else 8755 case $MKTEMP in 8756 [\\/]* | ?:[\\/]*) 8757 ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path. 8758 ;; 8759 *) 8760 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8761 for as_dir in $PATH 8762 do 8763 IFS=$as_save_IFS 8764 test -z "$as_dir" && as_dir=. 8765 for ac_exec_ext in '' $ac_executable_extensions; do 8766 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8767 ac_cv_path_MKTEMP="$as_dir/$ac_word$ac_exec_ext" 8768 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8769 break 2 8770 fi 8771 done 8772 done 8773 IFS=$as_save_IFS 8774 8775 ;; 8776 esac 8777 fi 8778 MKTEMP=$ac_cv_path_MKTEMP 8779 if test -n "$MKTEMP"; then 8780 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKTEMP" >&5 8781 $as_echo "$MKTEMP" >&6; } 8782 else 8783 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8784 $as_echo "no" >&6; } 8785 fi 8786 8787 8788 test -n "$MKTEMP" && break 8789 done 8790 8791 else 8792 # The variable is set, but is it from the command line or the environment? 8793 8794 # Try to remove the string !MKTEMP! from our list. 8795 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MKTEMP!/} 8796 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 8797 # If it failed, the variable was not from the command line. Ignore it, 8798 # but warn the user (except for BASH, which is always set by the calling BASH). 8799 if test "xMKTEMP" != xBASH; then 8800 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MKTEMP from the environment. Use command line variables instead." >&5 8801 $as_echo "$as_me: WARNING: Ignoring value of MKTEMP from the environment. Use command line variables instead." >&2;} 8802 fi 8803 # Try to locate tool using the code snippet 8804 for ac_prog in mktemp 8805 do 8806 # Extract the first word of "$ac_prog", so it can be a program name with args. 8807 set dummy $ac_prog; ac_word=$2 8808 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8809 $as_echo_n "checking for $ac_word... " >&6; } 8810 if ${ac_cv_path_MKTEMP+:} false; then : 8811 $as_echo_n "(cached) " >&6 8812 else 8813 case $MKTEMP in 8814 [\\/]* | ?:[\\/]*) 8815 ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path. 8816 ;; 8817 *) 8818 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8819 for as_dir in $PATH 8820 do 8821 IFS=$as_save_IFS 8822 test -z "$as_dir" && as_dir=. 8823 for ac_exec_ext in '' $ac_executable_extensions; do 8824 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8825 ac_cv_path_MKTEMP="$as_dir/$ac_word$ac_exec_ext" 8826 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8827 break 2 8828 fi 8829 done 8830 done 8831 IFS=$as_save_IFS 8832 8833 ;; 8834 esac 8835 fi 8836 MKTEMP=$ac_cv_path_MKTEMP 8837 if test -n "$MKTEMP"; then 8838 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKTEMP" >&5 8839 $as_echo "$MKTEMP" >&6; } 8840 else 8841 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8842 $as_echo "no" >&6; } 8843 fi 8844 8845 8846 test -n "$MKTEMP" && break 8847 done 8848 8849 else 8850 # If it succeeded, then it was overridden by the user. We will use it 8851 # for the tool. 8852 8853 # First remove it from the list of overridden variables, so we can test 8854 # for unknown variables in the end. 8855 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 8856 8857 # Check if we try to supply an empty value 8858 if test "x$MKTEMP" = x; then 8859 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool MKTEMP= (no value)" >&5 8860 $as_echo "$as_me: Setting user supplied tool MKTEMP= (no value)" >&6;} 8861 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKTEMP" >&5 8862 $as_echo_n "checking for MKTEMP... " >&6; } 8863 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 8864 $as_echo "disabled" >&6; } 8865 else 8866 # Check if the provided tool contains a complete path. 8867 tool_specified="$MKTEMP" 8868 tool_basename="${tool_specified##*/}" 8869 if test "x$tool_basename" = "x$tool_specified"; then 8870 # A command without a complete path is provided, search $PATH. 8871 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MKTEMP=$tool_basename" >&5 8872 $as_echo "$as_me: Will search for user supplied tool MKTEMP=$tool_basename" >&6;} 8873 # Extract the first word of "$tool_basename", so it can be a program name with args. 8874 set dummy $tool_basename; ac_word=$2 8875 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8876 $as_echo_n "checking for $ac_word... " >&6; } 8877 if ${ac_cv_path_MKTEMP+:} false; then : 8878 $as_echo_n "(cached) " >&6 8879 else 8880 case $MKTEMP in 8881 [\\/]* | ?:[\\/]*) 8882 ac_cv_path_MKTEMP="$MKTEMP" # Let the user override the test with a path. 8883 ;; 8884 *) 8885 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8886 for as_dir in $PATH 8887 do 8888 IFS=$as_save_IFS 8889 test -z "$as_dir" && as_dir=. 8890 for ac_exec_ext in '' $ac_executable_extensions; do 8891 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8892 ac_cv_path_MKTEMP="$as_dir/$ac_word$ac_exec_ext" 8893 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8894 break 2 8895 fi 8896 done 8897 done 8898 IFS=$as_save_IFS 8899 8900 ;; 8901 esac 8902 fi 8903 MKTEMP=$ac_cv_path_MKTEMP 8904 if test -n "$MKTEMP"; then 8905 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MKTEMP" >&5 8906 $as_echo "$MKTEMP" >&6; } 8907 else 8908 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8909 $as_echo "no" >&6; } 8910 fi 8911 8912 8913 if test "x$MKTEMP" = x; then 8914 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 8915 fi 8916 else 8917 # Otherwise we believe it is a complete path. Use it as it is. 8918 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MKTEMP=$tool_specified" >&5 8919 $as_echo "$as_me: Will use user supplied tool MKTEMP=$tool_specified" >&6;} 8920 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MKTEMP" >&5 8921 $as_echo_n "checking for MKTEMP... " >&6; } 8922 if test ! -x "$tool_specified"; then 8923 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 8924 $as_echo "not found" >&6; } 8925 as_fn_error $? "User supplied tool MKTEMP=$tool_specified does not exist or is not executable" "$LINENO" 5 8926 fi 8927 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 8928 $as_echo "$tool_specified" >&6; } 8929 fi 8930 fi 8931 fi 8932 8933 fi 8934 8935 8936 8937 if test "x$MKTEMP" = x; then 8938 as_fn_error $? "Could not find required tool for MKTEMP" "$LINENO" 5 8939 fi 8940 8941 8942 8943 8944 8945 # Publish this variable in the help. 8946 8947 8948 if [ -z "${MV+x}" ]; then 8949 # The variable is not set by user, try to locate tool using the code snippet 8950 for ac_prog in mv 8951 do 8952 # Extract the first word of "$ac_prog", so it can be a program name with args. 8953 set dummy $ac_prog; ac_word=$2 8954 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 8955 $as_echo_n "checking for $ac_word... " >&6; } 8956 if ${ac_cv_path_MV+:} false; then : 8957 $as_echo_n "(cached) " >&6 8958 else 8959 case $MV in 8960 [\\/]* | ?:[\\/]*) 8961 ac_cv_path_MV="$MV" # Let the user override the test with a path. 8962 ;; 8963 *) 8964 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 8965 for as_dir in $PATH 8966 do 8967 IFS=$as_save_IFS 8968 test -z "$as_dir" && as_dir=. 8969 for ac_exec_ext in '' $ac_executable_extensions; do 8970 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 8971 ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext" 8972 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 8973 break 2 8974 fi 8975 done 8976 done 8977 IFS=$as_save_IFS 8978 8979 ;; 8980 esac 8981 fi 8982 MV=$ac_cv_path_MV 8983 if test -n "$MV"; then 8984 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MV" >&5 8985 $as_echo "$MV" >&6; } 8986 else 8987 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 8988 $as_echo "no" >&6; } 8989 fi 8990 8991 8992 test -n "$MV" && break 8993 done 8994 8995 else 8996 # The variable is set, but is it from the command line or the environment? 8997 8998 # Try to remove the string !MV! from our list. 8999 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MV!/} 9000 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 9001 # If it failed, the variable was not from the command line. Ignore it, 9002 # but warn the user (except for BASH, which is always set by the calling BASH). 9003 if test "xMV" != xBASH; then 9004 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MV from the environment. Use command line variables instead." >&5 9005 $as_echo "$as_me: WARNING: Ignoring value of MV from the environment. Use command line variables instead." >&2;} 9006 fi 9007 # Try to locate tool using the code snippet 9008 for ac_prog in mv 9009 do 9010 # Extract the first word of "$ac_prog", so it can be a program name with args. 9011 set dummy $ac_prog; ac_word=$2 9012 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9013 $as_echo_n "checking for $ac_word... " >&6; } 9014 if ${ac_cv_path_MV+:} false; then : 9015 $as_echo_n "(cached) " >&6 9016 else 9017 case $MV in 9018 [\\/]* | ?:[\\/]*) 9019 ac_cv_path_MV="$MV" # Let the user override the test with a path. 9020 ;; 9021 *) 9022 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9023 for as_dir in $PATH 9024 do 9025 IFS=$as_save_IFS 9026 test -z "$as_dir" && as_dir=. 9027 for ac_exec_ext in '' $ac_executable_extensions; do 9028 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9029 ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext" 9030 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9031 break 2 9032 fi 9033 done 9034 done 9035 IFS=$as_save_IFS 9036 9037 ;; 9038 esac 9039 fi 9040 MV=$ac_cv_path_MV 9041 if test -n "$MV"; then 9042 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MV" >&5 9043 $as_echo "$MV" >&6; } 9044 else 9045 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9046 $as_echo "no" >&6; } 9047 fi 9048 9049 9050 test -n "$MV" && break 9051 done 9052 9053 else 9054 # If it succeeded, then it was overridden by the user. We will use it 9055 # for the tool. 9056 9057 # First remove it from the list of overridden variables, so we can test 9058 # for unknown variables in the end. 9059 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 9060 9061 # Check if we try to supply an empty value 9062 if test "x$MV" = x; then 9063 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool MV= (no value)" >&5 9064 $as_echo "$as_me: Setting user supplied tool MV= (no value)" >&6;} 9065 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MV" >&5 9066 $as_echo_n "checking for MV... " >&6; } 9067 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 9068 $as_echo "disabled" >&6; } 9069 else 9070 # Check if the provided tool contains a complete path. 9071 tool_specified="$MV" 9072 tool_basename="${tool_specified##*/}" 9073 if test "x$tool_basename" = "x$tool_specified"; then 9074 # A command without a complete path is provided, search $PATH. 9075 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MV=$tool_basename" >&5 9076 $as_echo "$as_me: Will search for user supplied tool MV=$tool_basename" >&6;} 9077 # Extract the first word of "$tool_basename", so it can be a program name with args. 9078 set dummy $tool_basename; ac_word=$2 9079 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9080 $as_echo_n "checking for $ac_word... " >&6; } 9081 if ${ac_cv_path_MV+:} false; then : 9082 $as_echo_n "(cached) " >&6 9083 else 9084 case $MV in 9085 [\\/]* | ?:[\\/]*) 9086 ac_cv_path_MV="$MV" # Let the user override the test with a path. 9087 ;; 9088 *) 9089 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9090 for as_dir in $PATH 9091 do 9092 IFS=$as_save_IFS 9093 test -z "$as_dir" && as_dir=. 9094 for ac_exec_ext in '' $ac_executable_extensions; do 9095 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9096 ac_cv_path_MV="$as_dir/$ac_word$ac_exec_ext" 9097 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9098 break 2 9099 fi 9100 done 9101 done 9102 IFS=$as_save_IFS 9103 9104 ;; 9105 esac 9106 fi 9107 MV=$ac_cv_path_MV 9108 if test -n "$MV"; then 9109 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MV" >&5 9110 $as_echo "$MV" >&6; } 9111 else 9112 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9113 $as_echo "no" >&6; } 9114 fi 9115 9116 9117 if test "x$MV" = x; then 9118 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 9119 fi 9120 else 9121 # Otherwise we believe it is a complete path. Use it as it is. 9122 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MV=$tool_specified" >&5 9123 $as_echo "$as_me: Will use user supplied tool MV=$tool_specified" >&6;} 9124 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MV" >&5 9125 $as_echo_n "checking for MV... " >&6; } 9126 if test ! -x "$tool_specified"; then 9127 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 9128 $as_echo "not found" >&6; } 9129 as_fn_error $? "User supplied tool MV=$tool_specified does not exist or is not executable" "$LINENO" 5 9130 fi 9131 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 9132 $as_echo "$tool_specified" >&6; } 9133 fi 9134 fi 9135 fi 9136 9137 fi 9138 9139 9140 9141 if test "x$MV" = x; then 9142 as_fn_error $? "Could not find required tool for MV" "$LINENO" 5 9143 fi 9144 9145 9146 9147 9148 9149 # Publish this variable in the help. 9150 9151 9152 if [ -z "${NAWK+x}" ]; then 9153 # The variable is not set by user, try to locate tool using the code snippet 9154 for ac_prog in nawk gawk awk 9155 do 9156 # Extract the first word of "$ac_prog", so it can be a program name with args. 9157 set dummy $ac_prog; ac_word=$2 9158 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9159 $as_echo_n "checking for $ac_word... " >&6; } 9160 if ${ac_cv_path_NAWK+:} false; then : 9161 $as_echo_n "(cached) " >&6 9162 else 9163 case $NAWK in 9164 [\\/]* | ?:[\\/]*) 9165 ac_cv_path_NAWK="$NAWK" # Let the user override the test with a path. 9166 ;; 9167 *) 9168 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9169 for as_dir in $PATH 9170 do 9171 IFS=$as_save_IFS 9172 test -z "$as_dir" && as_dir=. 9173 for ac_exec_ext in '' $ac_executable_extensions; do 9174 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9175 ac_cv_path_NAWK="$as_dir/$ac_word$ac_exec_ext" 9176 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9177 break 2 9178 fi 9179 done 9180 done 9181 IFS=$as_save_IFS 9182 9183 ;; 9184 esac 9185 fi 9186 NAWK=$ac_cv_path_NAWK 9187 if test -n "$NAWK"; then 9188 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NAWK" >&5 9189 $as_echo "$NAWK" >&6; } 9190 else 9191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9192 $as_echo "no" >&6; } 9193 fi 9194 9195 9196 test -n "$NAWK" && break 9197 done 9198 9199 else 9200 # The variable is set, but is it from the command line or the environment? 9201 9202 # Try to remove the string !NAWK! from our list. 9203 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NAWK!/} 9204 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 9205 # If it failed, the variable was not from the command line. Ignore it, 9206 # but warn the user (except for BASH, which is always set by the calling BASH). 9207 if test "xNAWK" != xBASH; then 9208 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NAWK from the environment. Use command line variables instead." >&5 9209 $as_echo "$as_me: WARNING: Ignoring value of NAWK from the environment. Use command line variables instead." >&2;} 9210 fi 9211 # Try to locate tool using the code snippet 9212 for ac_prog in nawk gawk awk 9213 do 9214 # Extract the first word of "$ac_prog", so it can be a program name with args. 9215 set dummy $ac_prog; ac_word=$2 9216 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9217 $as_echo_n "checking for $ac_word... " >&6; } 9218 if ${ac_cv_path_NAWK+:} false; then : 9219 $as_echo_n "(cached) " >&6 9220 else 9221 case $NAWK in 9222 [\\/]* | ?:[\\/]*) 9223 ac_cv_path_NAWK="$NAWK" # Let the user override the test with a path. 9224 ;; 9225 *) 9226 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9227 for as_dir in $PATH 9228 do 9229 IFS=$as_save_IFS 9230 test -z "$as_dir" && as_dir=. 9231 for ac_exec_ext in '' $ac_executable_extensions; do 9232 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9233 ac_cv_path_NAWK="$as_dir/$ac_word$ac_exec_ext" 9234 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9235 break 2 9236 fi 9237 done 9238 done 9239 IFS=$as_save_IFS 9240 9241 ;; 9242 esac 9243 fi 9244 NAWK=$ac_cv_path_NAWK 9245 if test -n "$NAWK"; then 9246 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NAWK" >&5 9247 $as_echo "$NAWK" >&6; } 9248 else 9249 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9250 $as_echo "no" >&6; } 9251 fi 9252 9253 9254 test -n "$NAWK" && break 9255 done 9256 9257 else 9258 # If it succeeded, then it was overridden by the user. We will use it 9259 # for the tool. 9260 9261 # First remove it from the list of overridden variables, so we can test 9262 # for unknown variables in the end. 9263 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 9264 9265 # Check if we try to supply an empty value 9266 if test "x$NAWK" = x; then 9267 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool NAWK= (no value)" >&5 9268 $as_echo "$as_me: Setting user supplied tool NAWK= (no value)" >&6;} 9269 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NAWK" >&5 9270 $as_echo_n "checking for NAWK... " >&6; } 9271 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 9272 $as_echo "disabled" >&6; } 9273 else 9274 # Check if the provided tool contains a complete path. 9275 tool_specified="$NAWK" 9276 tool_basename="${tool_specified##*/}" 9277 if test "x$tool_basename" = "x$tool_specified"; then 9278 # A command without a complete path is provided, search $PATH. 9279 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NAWK=$tool_basename" >&5 9280 $as_echo "$as_me: Will search for user supplied tool NAWK=$tool_basename" >&6;} 9281 # Extract the first word of "$tool_basename", so it can be a program name with args. 9282 set dummy $tool_basename; ac_word=$2 9283 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9284 $as_echo_n "checking for $ac_word... " >&6; } 9285 if ${ac_cv_path_NAWK+:} false; then : 9286 $as_echo_n "(cached) " >&6 9287 else 9288 case $NAWK in 9289 [\\/]* | ?:[\\/]*) 9290 ac_cv_path_NAWK="$NAWK" # Let the user override the test with a path. 9291 ;; 9292 *) 9293 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9294 for as_dir in $PATH 9295 do 9296 IFS=$as_save_IFS 9297 test -z "$as_dir" && as_dir=. 9298 for ac_exec_ext in '' $ac_executable_extensions; do 9299 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9300 ac_cv_path_NAWK="$as_dir/$ac_word$ac_exec_ext" 9301 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9302 break 2 9303 fi 9304 done 9305 done 9306 IFS=$as_save_IFS 9307 9308 ;; 9309 esac 9310 fi 9311 NAWK=$ac_cv_path_NAWK 9312 if test -n "$NAWK"; then 9313 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NAWK" >&5 9314 $as_echo "$NAWK" >&6; } 9315 else 9316 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9317 $as_echo "no" >&6; } 9318 fi 9319 9320 9321 if test "x$NAWK" = x; then 9322 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 9323 fi 9324 else 9325 # Otherwise we believe it is a complete path. Use it as it is. 9326 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NAWK=$tool_specified" >&5 9327 $as_echo "$as_me: Will use user supplied tool NAWK=$tool_specified" >&6;} 9328 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NAWK" >&5 9329 $as_echo_n "checking for NAWK... " >&6; } 9330 if test ! -x "$tool_specified"; then 9331 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 9332 $as_echo "not found" >&6; } 9333 as_fn_error $? "User supplied tool NAWK=$tool_specified does not exist or is not executable" "$LINENO" 5 9334 fi 9335 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 9336 $as_echo "$tool_specified" >&6; } 9337 fi 9338 fi 9339 fi 9340 9341 fi 9342 9343 9344 9345 if test "x$NAWK" = x; then 9346 as_fn_error $? "Could not find required tool for NAWK" "$LINENO" 5 9347 fi 9348 9349 9350 9351 9352 9353 # Publish this variable in the help. 9354 9355 9356 if [ -z "${PRINTF+x}" ]; then 9357 # The variable is not set by user, try to locate tool using the code snippet 9358 for ac_prog in printf 9359 do 9360 # Extract the first word of "$ac_prog", so it can be a program name with args. 9361 set dummy $ac_prog; ac_word=$2 9362 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9363 $as_echo_n "checking for $ac_word... " >&6; } 9364 if ${ac_cv_path_PRINTF+:} false; then : 9365 $as_echo_n "(cached) " >&6 9366 else 9367 case $PRINTF in 9368 [\\/]* | ?:[\\/]*) 9369 ac_cv_path_PRINTF="$PRINTF" # Let the user override the test with a path. 9370 ;; 9371 *) 9372 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9373 for as_dir in $PATH 9374 do 9375 IFS=$as_save_IFS 9376 test -z "$as_dir" && as_dir=. 9377 for ac_exec_ext in '' $ac_executable_extensions; do 9378 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9379 ac_cv_path_PRINTF="$as_dir/$ac_word$ac_exec_ext" 9380 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9381 break 2 9382 fi 9383 done 9384 done 9385 IFS=$as_save_IFS 9386 9387 ;; 9388 esac 9389 fi 9390 PRINTF=$ac_cv_path_PRINTF 9391 if test -n "$PRINTF"; then 9392 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRINTF" >&5 9393 $as_echo "$PRINTF" >&6; } 9394 else 9395 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9396 $as_echo "no" >&6; } 9397 fi 9398 9399 9400 test -n "$PRINTF" && break 9401 done 9402 9403 else 9404 # The variable is set, but is it from the command line or the environment? 9405 9406 # Try to remove the string !PRINTF! from our list. 9407 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!PRINTF!/} 9408 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 9409 # If it failed, the variable was not from the command line. Ignore it, 9410 # but warn the user (except for BASH, which is always set by the calling BASH). 9411 if test "xPRINTF" != xBASH; then 9412 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of PRINTF from the environment. Use command line variables instead." >&5 9413 $as_echo "$as_me: WARNING: Ignoring value of PRINTF from the environment. Use command line variables instead." >&2;} 9414 fi 9415 # Try to locate tool using the code snippet 9416 for ac_prog in printf 9417 do 9418 # Extract the first word of "$ac_prog", so it can be a program name with args. 9419 set dummy $ac_prog; ac_word=$2 9420 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9421 $as_echo_n "checking for $ac_word... " >&6; } 9422 if ${ac_cv_path_PRINTF+:} false; then : 9423 $as_echo_n "(cached) " >&6 9424 else 9425 case $PRINTF in 9426 [\\/]* | ?:[\\/]*) 9427 ac_cv_path_PRINTF="$PRINTF" # Let the user override the test with a path. 9428 ;; 9429 *) 9430 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9431 for as_dir in $PATH 9432 do 9433 IFS=$as_save_IFS 9434 test -z "$as_dir" && as_dir=. 9435 for ac_exec_ext in '' $ac_executable_extensions; do 9436 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9437 ac_cv_path_PRINTF="$as_dir/$ac_word$ac_exec_ext" 9438 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9439 break 2 9440 fi 9441 done 9442 done 9443 IFS=$as_save_IFS 9444 9445 ;; 9446 esac 9447 fi 9448 PRINTF=$ac_cv_path_PRINTF 9449 if test -n "$PRINTF"; then 9450 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRINTF" >&5 9451 $as_echo "$PRINTF" >&6; } 9452 else 9453 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9454 $as_echo "no" >&6; } 9455 fi 9456 9457 9458 test -n "$PRINTF" && break 9459 done 9460 9461 else 9462 # If it succeeded, then it was overridden by the user. We will use it 9463 # for the tool. 9464 9465 # First remove it from the list of overridden variables, so we can test 9466 # for unknown variables in the end. 9467 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 9468 9469 # Check if we try to supply an empty value 9470 if test "x$PRINTF" = x; then 9471 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool PRINTF= (no value)" >&5 9472 $as_echo "$as_me: Setting user supplied tool PRINTF= (no value)" >&6;} 9473 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PRINTF" >&5 9474 $as_echo_n "checking for PRINTF... " >&6; } 9475 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 9476 $as_echo "disabled" >&6; } 9477 else 9478 # Check if the provided tool contains a complete path. 9479 tool_specified="$PRINTF" 9480 tool_basename="${tool_specified##*/}" 9481 if test "x$tool_basename" = "x$tool_specified"; then 9482 # A command without a complete path is provided, search $PATH. 9483 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool PRINTF=$tool_basename" >&5 9484 $as_echo "$as_me: Will search for user supplied tool PRINTF=$tool_basename" >&6;} 9485 # Extract the first word of "$tool_basename", so it can be a program name with args. 9486 set dummy $tool_basename; ac_word=$2 9487 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9488 $as_echo_n "checking for $ac_word... " >&6; } 9489 if ${ac_cv_path_PRINTF+:} false; then : 9490 $as_echo_n "(cached) " >&6 9491 else 9492 case $PRINTF in 9493 [\\/]* | ?:[\\/]*) 9494 ac_cv_path_PRINTF="$PRINTF" # Let the user override the test with a path. 9495 ;; 9496 *) 9497 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9498 for as_dir in $PATH 9499 do 9500 IFS=$as_save_IFS 9501 test -z "$as_dir" && as_dir=. 9502 for ac_exec_ext in '' $ac_executable_extensions; do 9503 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9504 ac_cv_path_PRINTF="$as_dir/$ac_word$ac_exec_ext" 9505 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9506 break 2 9507 fi 9508 done 9509 done 9510 IFS=$as_save_IFS 9511 9512 ;; 9513 esac 9514 fi 9515 PRINTF=$ac_cv_path_PRINTF 9516 if test -n "$PRINTF"; then 9517 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PRINTF" >&5 9518 $as_echo "$PRINTF" >&6; } 9519 else 9520 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9521 $as_echo "no" >&6; } 9522 fi 9523 9524 9525 if test "x$PRINTF" = x; then 9526 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 9527 fi 9528 else 9529 # Otherwise we believe it is a complete path. Use it as it is. 9530 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool PRINTF=$tool_specified" >&5 9531 $as_echo "$as_me: Will use user supplied tool PRINTF=$tool_specified" >&6;} 9532 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PRINTF" >&5 9533 $as_echo_n "checking for PRINTF... " >&6; } 9534 if test ! -x "$tool_specified"; then 9535 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 9536 $as_echo "not found" >&6; } 9537 as_fn_error $? "User supplied tool PRINTF=$tool_specified does not exist or is not executable" "$LINENO" 5 9538 fi 9539 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 9540 $as_echo "$tool_specified" >&6; } 9541 fi 9542 fi 9543 fi 9544 9545 fi 9546 9547 9548 9549 if test "x$PRINTF" = x; then 9550 as_fn_error $? "Could not find required tool for PRINTF" "$LINENO" 5 9551 fi 9552 9553 9554 9555 9556 9557 # Publish this variable in the help. 9558 9559 9560 if [ -z "${RM+x}" ]; then 9561 # The variable is not set by user, try to locate tool using the code snippet 9562 for ac_prog in rm 9563 do 9564 # Extract the first word of "$ac_prog", so it can be a program name with args. 9565 set dummy $ac_prog; ac_word=$2 9566 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9567 $as_echo_n "checking for $ac_word... " >&6; } 9568 if ${ac_cv_path_RM+:} false; then : 9569 $as_echo_n "(cached) " >&6 9570 else 9571 case $RM in 9572 [\\/]* | ?:[\\/]*) 9573 ac_cv_path_RM="$RM" # Let the user override the test with a path. 9574 ;; 9575 *) 9576 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9577 for as_dir in $PATH 9578 do 9579 IFS=$as_save_IFS 9580 test -z "$as_dir" && as_dir=. 9581 for ac_exec_ext in '' $ac_executable_extensions; do 9582 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9583 ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext" 9584 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9585 break 2 9586 fi 9587 done 9588 done 9589 IFS=$as_save_IFS 9590 9591 ;; 9592 esac 9593 fi 9594 RM=$ac_cv_path_RM 9595 if test -n "$RM"; then 9596 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RM" >&5 9597 $as_echo "$RM" >&6; } 9598 else 9599 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9600 $as_echo "no" >&6; } 9601 fi 9602 9603 9604 test -n "$RM" && break 9605 done 9606 9607 else 9608 # The variable is set, but is it from the command line or the environment? 9609 9610 # Try to remove the string !RM! from our list. 9611 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!RM!/} 9612 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 9613 # If it failed, the variable was not from the command line. Ignore it, 9614 # but warn the user (except for BASH, which is always set by the calling BASH). 9615 if test "xRM" != xBASH; then 9616 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of RM from the environment. Use command line variables instead." >&5 9617 $as_echo "$as_me: WARNING: Ignoring value of RM from the environment. Use command line variables instead." >&2;} 9618 fi 9619 # Try to locate tool using the code snippet 9620 for ac_prog in rm 9621 do 9622 # Extract the first word of "$ac_prog", so it can be a program name with args. 9623 set dummy $ac_prog; ac_word=$2 9624 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9625 $as_echo_n "checking for $ac_word... " >&6; } 9626 if ${ac_cv_path_RM+:} false; then : 9627 $as_echo_n "(cached) " >&6 9628 else 9629 case $RM in 9630 [\\/]* | ?:[\\/]*) 9631 ac_cv_path_RM="$RM" # Let the user override the test with a path. 9632 ;; 9633 *) 9634 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9635 for as_dir in $PATH 9636 do 9637 IFS=$as_save_IFS 9638 test -z "$as_dir" && as_dir=. 9639 for ac_exec_ext in '' $ac_executable_extensions; do 9640 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9641 ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext" 9642 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9643 break 2 9644 fi 9645 done 9646 done 9647 IFS=$as_save_IFS 9648 9649 ;; 9650 esac 9651 fi 9652 RM=$ac_cv_path_RM 9653 if test -n "$RM"; then 9654 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RM" >&5 9655 $as_echo "$RM" >&6; } 9656 else 9657 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9658 $as_echo "no" >&6; } 9659 fi 9660 9661 9662 test -n "$RM" && break 9663 done 9664 9665 else 9666 # If it succeeded, then it was overridden by the user. We will use it 9667 # for the tool. 9668 9669 # First remove it from the list of overridden variables, so we can test 9670 # for unknown variables in the end. 9671 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 9672 9673 # Check if we try to supply an empty value 9674 if test "x$RM" = x; then 9675 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool RM= (no value)" >&5 9676 $as_echo "$as_me: Setting user supplied tool RM= (no value)" >&6;} 9677 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RM" >&5 9678 $as_echo_n "checking for RM... " >&6; } 9679 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 9680 $as_echo "disabled" >&6; } 9681 else 9682 # Check if the provided tool contains a complete path. 9683 tool_specified="$RM" 9684 tool_basename="${tool_specified##*/}" 9685 if test "x$tool_basename" = "x$tool_specified"; then 9686 # A command without a complete path is provided, search $PATH. 9687 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool RM=$tool_basename" >&5 9688 $as_echo "$as_me: Will search for user supplied tool RM=$tool_basename" >&6;} 9689 # Extract the first word of "$tool_basename", so it can be a program name with args. 9690 set dummy $tool_basename; ac_word=$2 9691 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9692 $as_echo_n "checking for $ac_word... " >&6; } 9693 if ${ac_cv_path_RM+:} false; then : 9694 $as_echo_n "(cached) " >&6 9695 else 9696 case $RM in 9697 [\\/]* | ?:[\\/]*) 9698 ac_cv_path_RM="$RM" # Let the user override the test with a path. 9699 ;; 9700 *) 9701 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9702 for as_dir in $PATH 9703 do 9704 IFS=$as_save_IFS 9705 test -z "$as_dir" && as_dir=. 9706 for ac_exec_ext in '' $ac_executable_extensions; do 9707 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9708 ac_cv_path_RM="$as_dir/$ac_word$ac_exec_ext" 9709 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9710 break 2 9711 fi 9712 done 9713 done 9714 IFS=$as_save_IFS 9715 9716 ;; 9717 esac 9718 fi 9719 RM=$ac_cv_path_RM 9720 if test -n "$RM"; then 9721 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RM" >&5 9722 $as_echo "$RM" >&6; } 9723 else 9724 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9725 $as_echo "no" >&6; } 9726 fi 9727 9728 9729 if test "x$RM" = x; then 9730 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 9731 fi 9732 else 9733 # Otherwise we believe it is a complete path. Use it as it is. 9734 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool RM=$tool_specified" >&5 9735 $as_echo "$as_me: Will use user supplied tool RM=$tool_specified" >&6;} 9736 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RM" >&5 9737 $as_echo_n "checking for RM... " >&6; } 9738 if test ! -x "$tool_specified"; then 9739 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 9740 $as_echo "not found" >&6; } 9741 as_fn_error $? "User supplied tool RM=$tool_specified does not exist or is not executable" "$LINENO" 5 9742 fi 9743 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 9744 $as_echo "$tool_specified" >&6; } 9745 fi 9746 fi 9747 fi 9748 9749 fi 9750 9751 9752 9753 if test "x$RM" = x; then 9754 as_fn_error $? "Could not find required tool for RM" "$LINENO" 5 9755 fi 9756 9757 9758 9759 9760 9761 # Publish this variable in the help. 9762 9763 9764 if [ -z "${RMDIR+x}" ]; then 9765 # The variable is not set by user, try to locate tool using the code snippet 9766 for ac_prog in rmdir 9767 do 9768 # Extract the first word of "$ac_prog", so it can be a program name with args. 9769 set dummy $ac_prog; ac_word=$2 9770 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9771 $as_echo_n "checking for $ac_word... " >&6; } 9772 if ${ac_cv_path_RMDIR+:} false; then : 9773 $as_echo_n "(cached) " >&6 9774 else 9775 case $RMDIR in 9776 [\\/]* | ?:[\\/]*) 9777 ac_cv_path_RMDIR="$RMDIR" # Let the user override the test with a path. 9778 ;; 9779 *) 9780 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9781 for as_dir in $PATH 9782 do 9783 IFS=$as_save_IFS 9784 test -z "$as_dir" && as_dir=. 9785 for ac_exec_ext in '' $ac_executable_extensions; do 9786 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9787 ac_cv_path_RMDIR="$as_dir/$ac_word$ac_exec_ext" 9788 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9789 break 2 9790 fi 9791 done 9792 done 9793 IFS=$as_save_IFS 9794 9795 ;; 9796 esac 9797 fi 9798 RMDIR=$ac_cv_path_RMDIR 9799 if test -n "$RMDIR"; then 9800 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RMDIR" >&5 9801 $as_echo "$RMDIR" >&6; } 9802 else 9803 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9804 $as_echo "no" >&6; } 9805 fi 9806 9807 9808 test -n "$RMDIR" && break 9809 done 9810 9811 else 9812 # The variable is set, but is it from the command line or the environment? 9813 9814 # Try to remove the string !RMDIR! from our list. 9815 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!RMDIR!/} 9816 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 9817 # If it failed, the variable was not from the command line. Ignore it, 9818 # but warn the user (except for BASH, which is always set by the calling BASH). 9819 if test "xRMDIR" != xBASH; then 9820 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of RMDIR from the environment. Use command line variables instead." >&5 9821 $as_echo "$as_me: WARNING: Ignoring value of RMDIR from the environment. Use command line variables instead." >&2;} 9822 fi 9823 # Try to locate tool using the code snippet 9824 for ac_prog in rmdir 9825 do 9826 # Extract the first word of "$ac_prog", so it can be a program name with args. 9827 set dummy $ac_prog; ac_word=$2 9828 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9829 $as_echo_n "checking for $ac_word... " >&6; } 9830 if ${ac_cv_path_RMDIR+:} false; then : 9831 $as_echo_n "(cached) " >&6 9832 else 9833 case $RMDIR in 9834 [\\/]* | ?:[\\/]*) 9835 ac_cv_path_RMDIR="$RMDIR" # Let the user override the test with a path. 9836 ;; 9837 *) 9838 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9839 for as_dir in $PATH 9840 do 9841 IFS=$as_save_IFS 9842 test -z "$as_dir" && as_dir=. 9843 for ac_exec_ext in '' $ac_executable_extensions; do 9844 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9845 ac_cv_path_RMDIR="$as_dir/$ac_word$ac_exec_ext" 9846 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9847 break 2 9848 fi 9849 done 9850 done 9851 IFS=$as_save_IFS 9852 9853 ;; 9854 esac 9855 fi 9856 RMDIR=$ac_cv_path_RMDIR 9857 if test -n "$RMDIR"; then 9858 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RMDIR" >&5 9859 $as_echo "$RMDIR" >&6; } 9860 else 9861 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9862 $as_echo "no" >&6; } 9863 fi 9864 9865 9866 test -n "$RMDIR" && break 9867 done 9868 9869 else 9870 # If it succeeded, then it was overridden by the user. We will use it 9871 # for the tool. 9872 9873 # First remove it from the list of overridden variables, so we can test 9874 # for unknown variables in the end. 9875 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 9876 9877 # Check if we try to supply an empty value 9878 if test "x$RMDIR" = x; then 9879 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool RMDIR= (no value)" >&5 9880 $as_echo "$as_me: Setting user supplied tool RMDIR= (no value)" >&6;} 9881 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RMDIR" >&5 9882 $as_echo_n "checking for RMDIR... " >&6; } 9883 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 9884 $as_echo "disabled" >&6; } 9885 else 9886 # Check if the provided tool contains a complete path. 9887 tool_specified="$RMDIR" 9888 tool_basename="${tool_specified##*/}" 9889 if test "x$tool_basename" = "x$tool_specified"; then 9890 # A command without a complete path is provided, search $PATH. 9891 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool RMDIR=$tool_basename" >&5 9892 $as_echo "$as_me: Will search for user supplied tool RMDIR=$tool_basename" >&6;} 9893 # Extract the first word of "$tool_basename", so it can be a program name with args. 9894 set dummy $tool_basename; ac_word=$2 9895 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9896 $as_echo_n "checking for $ac_word... " >&6; } 9897 if ${ac_cv_path_RMDIR+:} false; then : 9898 $as_echo_n "(cached) " >&6 9899 else 9900 case $RMDIR in 9901 [\\/]* | ?:[\\/]*) 9902 ac_cv_path_RMDIR="$RMDIR" # Let the user override the test with a path. 9903 ;; 9904 *) 9905 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9906 for as_dir in $PATH 9907 do 9908 IFS=$as_save_IFS 9909 test -z "$as_dir" && as_dir=. 9910 for ac_exec_ext in '' $ac_executable_extensions; do 9911 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9912 ac_cv_path_RMDIR="$as_dir/$ac_word$ac_exec_ext" 9913 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9914 break 2 9915 fi 9916 done 9917 done 9918 IFS=$as_save_IFS 9919 9920 ;; 9921 esac 9922 fi 9923 RMDIR=$ac_cv_path_RMDIR 9924 if test -n "$RMDIR"; then 9925 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RMDIR" >&5 9926 $as_echo "$RMDIR" >&6; } 9927 else 9928 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 9929 $as_echo "no" >&6; } 9930 fi 9931 9932 9933 if test "x$RMDIR" = x; then 9934 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 9935 fi 9936 else 9937 # Otherwise we believe it is a complete path. Use it as it is. 9938 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool RMDIR=$tool_specified" >&5 9939 $as_echo "$as_me: Will use user supplied tool RMDIR=$tool_specified" >&6;} 9940 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for RMDIR" >&5 9941 $as_echo_n "checking for RMDIR... " >&6; } 9942 if test ! -x "$tool_specified"; then 9943 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 9944 $as_echo "not found" >&6; } 9945 as_fn_error $? "User supplied tool RMDIR=$tool_specified does not exist or is not executable" "$LINENO" 5 9946 fi 9947 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 9948 $as_echo "$tool_specified" >&6; } 9949 fi 9950 fi 9951 fi 9952 9953 fi 9954 9955 9956 9957 if test "x$RMDIR" = x; then 9958 as_fn_error $? "Could not find required tool for RMDIR" "$LINENO" 5 9959 fi 9960 9961 9962 9963 9964 9965 # Publish this variable in the help. 9966 9967 9968 if [ -z "${SH+x}" ]; then 9969 # The variable is not set by user, try to locate tool using the code snippet 9970 for ac_prog in sh 9971 do 9972 # Extract the first word of "$ac_prog", so it can be a program name with args. 9973 set dummy $ac_prog; ac_word=$2 9974 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 9975 $as_echo_n "checking for $ac_word... " >&6; } 9976 if ${ac_cv_path_SH+:} false; then : 9977 $as_echo_n "(cached) " >&6 9978 else 9979 case $SH in 9980 [\\/]* | ?:[\\/]*) 9981 ac_cv_path_SH="$SH" # Let the user override the test with a path. 9982 ;; 9983 *) 9984 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 9985 for as_dir in $PATH 9986 do 9987 IFS=$as_save_IFS 9988 test -z "$as_dir" && as_dir=. 9989 for ac_exec_ext in '' $ac_executable_extensions; do 9990 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 9991 ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext" 9992 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 9993 break 2 9994 fi 9995 done 9996 done 9997 IFS=$as_save_IFS 9998 9999 ;; 10000 esac 10001 fi 10002 SH=$ac_cv_path_SH 10003 if test -n "$SH"; then 10004 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5 10005 $as_echo "$SH" >&6; } 10006 else 10007 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10008 $as_echo "no" >&6; } 10009 fi 10010 10011 10012 test -n "$SH" && break 10013 done 10014 10015 else 10016 # The variable is set, but is it from the command line or the environment? 10017 10018 # Try to remove the string !SH! from our list. 10019 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SH!/} 10020 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 10021 # If it failed, the variable was not from the command line. Ignore it, 10022 # but warn the user (except for BASH, which is always set by the calling BASH). 10023 if test "xSH" != xBASH; then 10024 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SH from the environment. Use command line variables instead." >&5 10025 $as_echo "$as_me: WARNING: Ignoring value of SH from the environment. Use command line variables instead." >&2;} 10026 fi 10027 # Try to locate tool using the code snippet 10028 for ac_prog in sh 10029 do 10030 # Extract the first word of "$ac_prog", so it can be a program name with args. 10031 set dummy $ac_prog; ac_word=$2 10032 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10033 $as_echo_n "checking for $ac_word... " >&6; } 10034 if ${ac_cv_path_SH+:} false; then : 10035 $as_echo_n "(cached) " >&6 10036 else 10037 case $SH in 10038 [\\/]* | ?:[\\/]*) 10039 ac_cv_path_SH="$SH" # Let the user override the test with a path. 10040 ;; 10041 *) 10042 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10043 for as_dir in $PATH 10044 do 10045 IFS=$as_save_IFS 10046 test -z "$as_dir" && as_dir=. 10047 for ac_exec_ext in '' $ac_executable_extensions; do 10048 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10049 ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext" 10050 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10051 break 2 10052 fi 10053 done 10054 done 10055 IFS=$as_save_IFS 10056 10057 ;; 10058 esac 10059 fi 10060 SH=$ac_cv_path_SH 10061 if test -n "$SH"; then 10062 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5 10063 $as_echo "$SH" >&6; } 10064 else 10065 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10066 $as_echo "no" >&6; } 10067 fi 10068 10069 10070 test -n "$SH" && break 10071 done 10072 10073 else 10074 # If it succeeded, then it was overridden by the user. We will use it 10075 # for the tool. 10076 10077 # First remove it from the list of overridden variables, so we can test 10078 # for unknown variables in the end. 10079 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 10080 10081 # Check if we try to supply an empty value 10082 if test "x$SH" = x; then 10083 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool SH= (no value)" >&5 10084 $as_echo "$as_me: Setting user supplied tool SH= (no value)" >&6;} 10085 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SH" >&5 10086 $as_echo_n "checking for SH... " >&6; } 10087 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 10088 $as_echo "disabled" >&6; } 10089 else 10090 # Check if the provided tool contains a complete path. 10091 tool_specified="$SH" 10092 tool_basename="${tool_specified##*/}" 10093 if test "x$tool_basename" = "x$tool_specified"; then 10094 # A command without a complete path is provided, search $PATH. 10095 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SH=$tool_basename" >&5 10096 $as_echo "$as_me: Will search for user supplied tool SH=$tool_basename" >&6;} 10097 # Extract the first word of "$tool_basename", so it can be a program name with args. 10098 set dummy $tool_basename; ac_word=$2 10099 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10100 $as_echo_n "checking for $ac_word... " >&6; } 10101 if ${ac_cv_path_SH+:} false; then : 10102 $as_echo_n "(cached) " >&6 10103 else 10104 case $SH in 10105 [\\/]* | ?:[\\/]*) 10106 ac_cv_path_SH="$SH" # Let the user override the test with a path. 10107 ;; 10108 *) 10109 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10110 for as_dir in $PATH 10111 do 10112 IFS=$as_save_IFS 10113 test -z "$as_dir" && as_dir=. 10114 for ac_exec_ext in '' $ac_executable_extensions; do 10115 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10116 ac_cv_path_SH="$as_dir/$ac_word$ac_exec_ext" 10117 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10118 break 2 10119 fi 10120 done 10121 done 10122 IFS=$as_save_IFS 10123 10124 ;; 10125 esac 10126 fi 10127 SH=$ac_cv_path_SH 10128 if test -n "$SH"; then 10129 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SH" >&5 10130 $as_echo "$SH" >&6; } 10131 else 10132 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10133 $as_echo "no" >&6; } 10134 fi 10135 10136 10137 if test "x$SH" = x; then 10138 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 10139 fi 10140 else 10141 # Otherwise we believe it is a complete path. Use it as it is. 10142 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SH=$tool_specified" >&5 10143 $as_echo "$as_me: Will use user supplied tool SH=$tool_specified" >&6;} 10144 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SH" >&5 10145 $as_echo_n "checking for SH... " >&6; } 10146 if test ! -x "$tool_specified"; then 10147 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 10148 $as_echo "not found" >&6; } 10149 as_fn_error $? "User supplied tool SH=$tool_specified does not exist or is not executable" "$LINENO" 5 10150 fi 10151 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 10152 $as_echo "$tool_specified" >&6; } 10153 fi 10154 fi 10155 fi 10156 10157 fi 10158 10159 10160 10161 if test "x$SH" = x; then 10162 as_fn_error $? "Could not find required tool for SH" "$LINENO" 5 10163 fi 10164 10165 10166 10167 10168 10169 # Publish this variable in the help. 10170 10171 10172 if [ -z "${SORT+x}" ]; then 10173 # The variable is not set by user, try to locate tool using the code snippet 10174 for ac_prog in sort 10175 do 10176 # Extract the first word of "$ac_prog", so it can be a program name with args. 10177 set dummy $ac_prog; ac_word=$2 10178 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10179 $as_echo_n "checking for $ac_word... " >&6; } 10180 if ${ac_cv_path_SORT+:} false; then : 10181 $as_echo_n "(cached) " >&6 10182 else 10183 case $SORT in 10184 [\\/]* | ?:[\\/]*) 10185 ac_cv_path_SORT="$SORT" # Let the user override the test with a path. 10186 ;; 10187 *) 10188 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10189 for as_dir in $PATH 10190 do 10191 IFS=$as_save_IFS 10192 test -z "$as_dir" && as_dir=. 10193 for ac_exec_ext in '' $ac_executable_extensions; do 10194 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10195 ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext" 10196 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10197 break 2 10198 fi 10199 done 10200 done 10201 IFS=$as_save_IFS 10202 10203 ;; 10204 esac 10205 fi 10206 SORT=$ac_cv_path_SORT 10207 if test -n "$SORT"; then 10208 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5 10209 $as_echo "$SORT" >&6; } 10210 else 10211 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10212 $as_echo "no" >&6; } 10213 fi 10214 10215 10216 test -n "$SORT" && break 10217 done 10218 10219 else 10220 # The variable is set, but is it from the command line or the environment? 10221 10222 # Try to remove the string !SORT! from our list. 10223 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SORT!/} 10224 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 10225 # If it failed, the variable was not from the command line. Ignore it, 10226 # but warn the user (except for BASH, which is always set by the calling BASH). 10227 if test "xSORT" != xBASH; then 10228 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SORT from the environment. Use command line variables instead." >&5 10229 $as_echo "$as_me: WARNING: Ignoring value of SORT from the environment. Use command line variables instead." >&2;} 10230 fi 10231 # Try to locate tool using the code snippet 10232 for ac_prog in sort 10233 do 10234 # Extract the first word of "$ac_prog", so it can be a program name with args. 10235 set dummy $ac_prog; ac_word=$2 10236 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10237 $as_echo_n "checking for $ac_word... " >&6; } 10238 if ${ac_cv_path_SORT+:} false; then : 10239 $as_echo_n "(cached) " >&6 10240 else 10241 case $SORT in 10242 [\\/]* | ?:[\\/]*) 10243 ac_cv_path_SORT="$SORT" # Let the user override the test with a path. 10244 ;; 10245 *) 10246 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10247 for as_dir in $PATH 10248 do 10249 IFS=$as_save_IFS 10250 test -z "$as_dir" && as_dir=. 10251 for ac_exec_ext in '' $ac_executable_extensions; do 10252 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10253 ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext" 10254 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10255 break 2 10256 fi 10257 done 10258 done 10259 IFS=$as_save_IFS 10260 10261 ;; 10262 esac 10263 fi 10264 SORT=$ac_cv_path_SORT 10265 if test -n "$SORT"; then 10266 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5 10267 $as_echo "$SORT" >&6; } 10268 else 10269 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10270 $as_echo "no" >&6; } 10271 fi 10272 10273 10274 test -n "$SORT" && break 10275 done 10276 10277 else 10278 # If it succeeded, then it was overridden by the user. We will use it 10279 # for the tool. 10280 10281 # First remove it from the list of overridden variables, so we can test 10282 # for unknown variables in the end. 10283 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 10284 10285 # Check if we try to supply an empty value 10286 if test "x$SORT" = x; then 10287 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool SORT= (no value)" >&5 10288 $as_echo "$as_me: Setting user supplied tool SORT= (no value)" >&6;} 10289 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SORT" >&5 10290 $as_echo_n "checking for SORT... " >&6; } 10291 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 10292 $as_echo "disabled" >&6; } 10293 else 10294 # Check if the provided tool contains a complete path. 10295 tool_specified="$SORT" 10296 tool_basename="${tool_specified##*/}" 10297 if test "x$tool_basename" = "x$tool_specified"; then 10298 # A command without a complete path is provided, search $PATH. 10299 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SORT=$tool_basename" >&5 10300 $as_echo "$as_me: Will search for user supplied tool SORT=$tool_basename" >&6;} 10301 # Extract the first word of "$tool_basename", so it can be a program name with args. 10302 set dummy $tool_basename; ac_word=$2 10303 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10304 $as_echo_n "checking for $ac_word... " >&6; } 10305 if ${ac_cv_path_SORT+:} false; then : 10306 $as_echo_n "(cached) " >&6 10307 else 10308 case $SORT in 10309 [\\/]* | ?:[\\/]*) 10310 ac_cv_path_SORT="$SORT" # Let the user override the test with a path. 10311 ;; 10312 *) 10313 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10314 for as_dir in $PATH 10315 do 10316 IFS=$as_save_IFS 10317 test -z "$as_dir" && as_dir=. 10318 for ac_exec_ext in '' $ac_executable_extensions; do 10319 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10320 ac_cv_path_SORT="$as_dir/$ac_word$ac_exec_ext" 10321 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10322 break 2 10323 fi 10324 done 10325 done 10326 IFS=$as_save_IFS 10327 10328 ;; 10329 esac 10330 fi 10331 SORT=$ac_cv_path_SORT 10332 if test -n "$SORT"; then 10333 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SORT" >&5 10334 $as_echo "$SORT" >&6; } 10335 else 10336 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10337 $as_echo "no" >&6; } 10338 fi 10339 10340 10341 if test "x$SORT" = x; then 10342 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 10343 fi 10344 else 10345 # Otherwise we believe it is a complete path. Use it as it is. 10346 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SORT=$tool_specified" >&5 10347 $as_echo "$as_me: Will use user supplied tool SORT=$tool_specified" >&6;} 10348 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SORT" >&5 10349 $as_echo_n "checking for SORT... " >&6; } 10350 if test ! -x "$tool_specified"; then 10351 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 10352 $as_echo "not found" >&6; } 10353 as_fn_error $? "User supplied tool SORT=$tool_specified does not exist or is not executable" "$LINENO" 5 10354 fi 10355 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 10356 $as_echo "$tool_specified" >&6; } 10357 fi 10358 fi 10359 fi 10360 10361 fi 10362 10363 10364 10365 if test "x$SORT" = x; then 10366 as_fn_error $? "Could not find required tool for SORT" "$LINENO" 5 10367 fi 10368 10369 10370 10371 10372 10373 # Publish this variable in the help. 10374 10375 10376 if [ -z "${TAIL+x}" ]; then 10377 # The variable is not set by user, try to locate tool using the code snippet 10378 for ac_prog in tail 10379 do 10380 # Extract the first word of "$ac_prog", so it can be a program name with args. 10381 set dummy $ac_prog; ac_word=$2 10382 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10383 $as_echo_n "checking for $ac_word... " >&6; } 10384 if ${ac_cv_path_TAIL+:} false; then : 10385 $as_echo_n "(cached) " >&6 10386 else 10387 case $TAIL in 10388 [\\/]* | ?:[\\/]*) 10389 ac_cv_path_TAIL="$TAIL" # Let the user override the test with a path. 10390 ;; 10391 *) 10392 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10393 for as_dir in $PATH 10394 do 10395 IFS=$as_save_IFS 10396 test -z "$as_dir" && as_dir=. 10397 for ac_exec_ext in '' $ac_executable_extensions; do 10398 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10399 ac_cv_path_TAIL="$as_dir/$ac_word$ac_exec_ext" 10400 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10401 break 2 10402 fi 10403 done 10404 done 10405 IFS=$as_save_IFS 10406 10407 ;; 10408 esac 10409 fi 10410 TAIL=$ac_cv_path_TAIL 10411 if test -n "$TAIL"; then 10412 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAIL" >&5 10413 $as_echo "$TAIL" >&6; } 10414 else 10415 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10416 $as_echo "no" >&6; } 10417 fi 10418 10419 10420 test -n "$TAIL" && break 10421 done 10422 10423 else 10424 # The variable is set, but is it from the command line or the environment? 10425 10426 # Try to remove the string !TAIL! from our list. 10427 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TAIL!/} 10428 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 10429 # If it failed, the variable was not from the command line. Ignore it, 10430 # but warn the user (except for BASH, which is always set by the calling BASH). 10431 if test "xTAIL" != xBASH; then 10432 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TAIL from the environment. Use command line variables instead." >&5 10433 $as_echo "$as_me: WARNING: Ignoring value of TAIL from the environment. Use command line variables instead." >&2;} 10434 fi 10435 # Try to locate tool using the code snippet 10436 for ac_prog in tail 10437 do 10438 # Extract the first word of "$ac_prog", so it can be a program name with args. 10439 set dummy $ac_prog; ac_word=$2 10440 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10441 $as_echo_n "checking for $ac_word... " >&6; } 10442 if ${ac_cv_path_TAIL+:} false; then : 10443 $as_echo_n "(cached) " >&6 10444 else 10445 case $TAIL in 10446 [\\/]* | ?:[\\/]*) 10447 ac_cv_path_TAIL="$TAIL" # Let the user override the test with a path. 10448 ;; 10449 *) 10450 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10451 for as_dir in $PATH 10452 do 10453 IFS=$as_save_IFS 10454 test -z "$as_dir" && as_dir=. 10455 for ac_exec_ext in '' $ac_executable_extensions; do 10456 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10457 ac_cv_path_TAIL="$as_dir/$ac_word$ac_exec_ext" 10458 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10459 break 2 10460 fi 10461 done 10462 done 10463 IFS=$as_save_IFS 10464 10465 ;; 10466 esac 10467 fi 10468 TAIL=$ac_cv_path_TAIL 10469 if test -n "$TAIL"; then 10470 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAIL" >&5 10471 $as_echo "$TAIL" >&6; } 10472 else 10473 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10474 $as_echo "no" >&6; } 10475 fi 10476 10477 10478 test -n "$TAIL" && break 10479 done 10480 10481 else 10482 # If it succeeded, then it was overridden by the user. We will use it 10483 # for the tool. 10484 10485 # First remove it from the list of overridden variables, so we can test 10486 # for unknown variables in the end. 10487 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 10488 10489 # Check if we try to supply an empty value 10490 if test "x$TAIL" = x; then 10491 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TAIL= (no value)" >&5 10492 $as_echo "$as_me: Setting user supplied tool TAIL= (no value)" >&6;} 10493 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAIL" >&5 10494 $as_echo_n "checking for TAIL... " >&6; } 10495 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 10496 $as_echo "disabled" >&6; } 10497 else 10498 # Check if the provided tool contains a complete path. 10499 tool_specified="$TAIL" 10500 tool_basename="${tool_specified##*/}" 10501 if test "x$tool_basename" = "x$tool_specified"; then 10502 # A command without a complete path is provided, search $PATH. 10503 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TAIL=$tool_basename" >&5 10504 $as_echo "$as_me: Will search for user supplied tool TAIL=$tool_basename" >&6;} 10505 # Extract the first word of "$tool_basename", so it can be a program name with args. 10506 set dummy $tool_basename; ac_word=$2 10507 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10508 $as_echo_n "checking for $ac_word... " >&6; } 10509 if ${ac_cv_path_TAIL+:} false; then : 10510 $as_echo_n "(cached) " >&6 10511 else 10512 case $TAIL in 10513 [\\/]* | ?:[\\/]*) 10514 ac_cv_path_TAIL="$TAIL" # Let the user override the test with a path. 10515 ;; 10516 *) 10517 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10518 for as_dir in $PATH 10519 do 10520 IFS=$as_save_IFS 10521 test -z "$as_dir" && as_dir=. 10522 for ac_exec_ext in '' $ac_executable_extensions; do 10523 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10524 ac_cv_path_TAIL="$as_dir/$ac_word$ac_exec_ext" 10525 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10526 break 2 10527 fi 10528 done 10529 done 10530 IFS=$as_save_IFS 10531 10532 ;; 10533 esac 10534 fi 10535 TAIL=$ac_cv_path_TAIL 10536 if test -n "$TAIL"; then 10537 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAIL" >&5 10538 $as_echo "$TAIL" >&6; } 10539 else 10540 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10541 $as_echo "no" >&6; } 10542 fi 10543 10544 10545 if test "x$TAIL" = x; then 10546 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 10547 fi 10548 else 10549 # Otherwise we believe it is a complete path. Use it as it is. 10550 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TAIL=$tool_specified" >&5 10551 $as_echo "$as_me: Will use user supplied tool TAIL=$tool_specified" >&6;} 10552 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAIL" >&5 10553 $as_echo_n "checking for TAIL... " >&6; } 10554 if test ! -x "$tool_specified"; then 10555 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 10556 $as_echo "not found" >&6; } 10557 as_fn_error $? "User supplied tool TAIL=$tool_specified does not exist or is not executable" "$LINENO" 5 10558 fi 10559 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 10560 $as_echo "$tool_specified" >&6; } 10561 fi 10562 fi 10563 fi 10564 10565 fi 10566 10567 10568 10569 if test "x$TAIL" = x; then 10570 as_fn_error $? "Could not find required tool for TAIL" "$LINENO" 5 10571 fi 10572 10573 10574 10575 10576 10577 # Publish this variable in the help. 10578 10579 10580 if [ -z "${TAR+x}" ]; then 10581 # The variable is not set by user, try to locate tool using the code snippet 10582 for ac_prog in tar 10583 do 10584 # Extract the first word of "$ac_prog", so it can be a program name with args. 10585 set dummy $ac_prog; ac_word=$2 10586 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10587 $as_echo_n "checking for $ac_word... " >&6; } 10588 if ${ac_cv_path_TAR+:} false; then : 10589 $as_echo_n "(cached) " >&6 10590 else 10591 case $TAR in 10592 [\\/]* | ?:[\\/]*) 10593 ac_cv_path_TAR="$TAR" # Let the user override the test with a path. 10594 ;; 10595 *) 10596 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10597 for as_dir in $PATH 10598 do 10599 IFS=$as_save_IFS 10600 test -z "$as_dir" && as_dir=. 10601 for ac_exec_ext in '' $ac_executable_extensions; do 10602 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10603 ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext" 10604 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10605 break 2 10606 fi 10607 done 10608 done 10609 IFS=$as_save_IFS 10610 10611 ;; 10612 esac 10613 fi 10614 TAR=$ac_cv_path_TAR 10615 if test -n "$TAR"; then 10616 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5 10617 $as_echo "$TAR" >&6; } 10618 else 10619 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10620 $as_echo "no" >&6; } 10621 fi 10622 10623 10624 test -n "$TAR" && break 10625 done 10626 10627 else 10628 # The variable is set, but is it from the command line or the environment? 10629 10630 # Try to remove the string !TAR! from our list. 10631 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TAR!/} 10632 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 10633 # If it failed, the variable was not from the command line. Ignore it, 10634 # but warn the user (except for BASH, which is always set by the calling BASH). 10635 if test "xTAR" != xBASH; then 10636 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TAR from the environment. Use command line variables instead." >&5 10637 $as_echo "$as_me: WARNING: Ignoring value of TAR from the environment. Use command line variables instead." >&2;} 10638 fi 10639 # Try to locate tool using the code snippet 10640 for ac_prog in tar 10641 do 10642 # Extract the first word of "$ac_prog", so it can be a program name with args. 10643 set dummy $ac_prog; ac_word=$2 10644 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10645 $as_echo_n "checking for $ac_word... " >&6; } 10646 if ${ac_cv_path_TAR+:} false; then : 10647 $as_echo_n "(cached) " >&6 10648 else 10649 case $TAR in 10650 [\\/]* | ?:[\\/]*) 10651 ac_cv_path_TAR="$TAR" # Let the user override the test with a path. 10652 ;; 10653 *) 10654 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10655 for as_dir in $PATH 10656 do 10657 IFS=$as_save_IFS 10658 test -z "$as_dir" && as_dir=. 10659 for ac_exec_ext in '' $ac_executable_extensions; do 10660 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10661 ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext" 10662 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10663 break 2 10664 fi 10665 done 10666 done 10667 IFS=$as_save_IFS 10668 10669 ;; 10670 esac 10671 fi 10672 TAR=$ac_cv_path_TAR 10673 if test -n "$TAR"; then 10674 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5 10675 $as_echo "$TAR" >&6; } 10676 else 10677 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10678 $as_echo "no" >&6; } 10679 fi 10680 10681 10682 test -n "$TAR" && break 10683 done 10684 10685 else 10686 # If it succeeded, then it was overridden by the user. We will use it 10687 # for the tool. 10688 10689 # First remove it from the list of overridden variables, so we can test 10690 # for unknown variables in the end. 10691 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 10692 10693 # Check if we try to supply an empty value 10694 if test "x$TAR" = x; then 10695 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TAR= (no value)" >&5 10696 $as_echo "$as_me: Setting user supplied tool TAR= (no value)" >&6;} 10697 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAR" >&5 10698 $as_echo_n "checking for TAR... " >&6; } 10699 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 10700 $as_echo "disabled" >&6; } 10701 else 10702 # Check if the provided tool contains a complete path. 10703 tool_specified="$TAR" 10704 tool_basename="${tool_specified##*/}" 10705 if test "x$tool_basename" = "x$tool_specified"; then 10706 # A command without a complete path is provided, search $PATH. 10707 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TAR=$tool_basename" >&5 10708 $as_echo "$as_me: Will search for user supplied tool TAR=$tool_basename" >&6;} 10709 # Extract the first word of "$tool_basename", so it can be a program name with args. 10710 set dummy $tool_basename; ac_word=$2 10711 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10712 $as_echo_n "checking for $ac_word... " >&6; } 10713 if ${ac_cv_path_TAR+:} false; then : 10714 $as_echo_n "(cached) " >&6 10715 else 10716 case $TAR in 10717 [\\/]* | ?:[\\/]*) 10718 ac_cv_path_TAR="$TAR" # Let the user override the test with a path. 10719 ;; 10720 *) 10721 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10722 for as_dir in $PATH 10723 do 10724 IFS=$as_save_IFS 10725 test -z "$as_dir" && as_dir=. 10726 for ac_exec_ext in '' $ac_executable_extensions; do 10727 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10728 ac_cv_path_TAR="$as_dir/$ac_word$ac_exec_ext" 10729 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10730 break 2 10731 fi 10732 done 10733 done 10734 IFS=$as_save_IFS 10735 10736 ;; 10737 esac 10738 fi 10739 TAR=$ac_cv_path_TAR 10740 if test -n "$TAR"; then 10741 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TAR" >&5 10742 $as_echo "$TAR" >&6; } 10743 else 10744 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10745 $as_echo "no" >&6; } 10746 fi 10747 10748 10749 if test "x$TAR" = x; then 10750 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 10751 fi 10752 else 10753 # Otherwise we believe it is a complete path. Use it as it is. 10754 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TAR=$tool_specified" >&5 10755 $as_echo "$as_me: Will use user supplied tool TAR=$tool_specified" >&6;} 10756 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TAR" >&5 10757 $as_echo_n "checking for TAR... " >&6; } 10758 if test ! -x "$tool_specified"; then 10759 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 10760 $as_echo "not found" >&6; } 10761 as_fn_error $? "User supplied tool TAR=$tool_specified does not exist or is not executable" "$LINENO" 5 10762 fi 10763 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 10764 $as_echo "$tool_specified" >&6; } 10765 fi 10766 fi 10767 fi 10768 10769 fi 10770 10771 10772 10773 if test "x$TAR" = x; then 10774 as_fn_error $? "Could not find required tool for TAR" "$LINENO" 5 10775 fi 10776 10777 10778 10779 10780 10781 # Publish this variable in the help. 10782 10783 10784 if [ -z "${TEE+x}" ]; then 10785 # The variable is not set by user, try to locate tool using the code snippet 10786 for ac_prog in tee 10787 do 10788 # Extract the first word of "$ac_prog", so it can be a program name with args. 10789 set dummy $ac_prog; ac_word=$2 10790 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10791 $as_echo_n "checking for $ac_word... " >&6; } 10792 if ${ac_cv_path_TEE+:} false; then : 10793 $as_echo_n "(cached) " >&6 10794 else 10795 case $TEE in 10796 [\\/]* | ?:[\\/]*) 10797 ac_cv_path_TEE="$TEE" # Let the user override the test with a path. 10798 ;; 10799 *) 10800 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10801 for as_dir in $PATH 10802 do 10803 IFS=$as_save_IFS 10804 test -z "$as_dir" && as_dir=. 10805 for ac_exec_ext in '' $ac_executable_extensions; do 10806 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10807 ac_cv_path_TEE="$as_dir/$ac_word$ac_exec_ext" 10808 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10809 break 2 10810 fi 10811 done 10812 done 10813 IFS=$as_save_IFS 10814 10815 ;; 10816 esac 10817 fi 10818 TEE=$ac_cv_path_TEE 10819 if test -n "$TEE"; then 10820 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5 10821 $as_echo "$TEE" >&6; } 10822 else 10823 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10824 $as_echo "no" >&6; } 10825 fi 10826 10827 10828 test -n "$TEE" && break 10829 done 10830 10831 else 10832 # The variable is set, but is it from the command line or the environment? 10833 10834 # Try to remove the string !TEE! from our list. 10835 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TEE!/} 10836 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 10837 # If it failed, the variable was not from the command line. Ignore it, 10838 # but warn the user (except for BASH, which is always set by the calling BASH). 10839 if test "xTEE" != xBASH; then 10840 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TEE from the environment. Use command line variables instead." >&5 10841 $as_echo "$as_me: WARNING: Ignoring value of TEE from the environment. Use command line variables instead." >&2;} 10842 fi 10843 # Try to locate tool using the code snippet 10844 for ac_prog in tee 10845 do 10846 # Extract the first word of "$ac_prog", so it can be a program name with args. 10847 set dummy $ac_prog; ac_word=$2 10848 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10849 $as_echo_n "checking for $ac_word... " >&6; } 10850 if ${ac_cv_path_TEE+:} false; then : 10851 $as_echo_n "(cached) " >&6 10852 else 10853 case $TEE in 10854 [\\/]* | ?:[\\/]*) 10855 ac_cv_path_TEE="$TEE" # Let the user override the test with a path. 10856 ;; 10857 *) 10858 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10859 for as_dir in $PATH 10860 do 10861 IFS=$as_save_IFS 10862 test -z "$as_dir" && as_dir=. 10863 for ac_exec_ext in '' $ac_executable_extensions; do 10864 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10865 ac_cv_path_TEE="$as_dir/$ac_word$ac_exec_ext" 10866 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10867 break 2 10868 fi 10869 done 10870 done 10871 IFS=$as_save_IFS 10872 10873 ;; 10874 esac 10875 fi 10876 TEE=$ac_cv_path_TEE 10877 if test -n "$TEE"; then 10878 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5 10879 $as_echo "$TEE" >&6; } 10880 else 10881 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10882 $as_echo "no" >&6; } 10883 fi 10884 10885 10886 test -n "$TEE" && break 10887 done 10888 10889 else 10890 # If it succeeded, then it was overridden by the user. We will use it 10891 # for the tool. 10892 10893 # First remove it from the list of overridden variables, so we can test 10894 # for unknown variables in the end. 10895 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 10896 10897 # Check if we try to supply an empty value 10898 if test "x$TEE" = x; then 10899 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TEE= (no value)" >&5 10900 $as_echo "$as_me: Setting user supplied tool TEE= (no value)" >&6;} 10901 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TEE" >&5 10902 $as_echo_n "checking for TEE... " >&6; } 10903 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 10904 $as_echo "disabled" >&6; } 10905 else 10906 # Check if the provided tool contains a complete path. 10907 tool_specified="$TEE" 10908 tool_basename="${tool_specified##*/}" 10909 if test "x$tool_basename" = "x$tool_specified"; then 10910 # A command without a complete path is provided, search $PATH. 10911 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TEE=$tool_basename" >&5 10912 $as_echo "$as_me: Will search for user supplied tool TEE=$tool_basename" >&6;} 10913 # Extract the first word of "$tool_basename", so it can be a program name with args. 10914 set dummy $tool_basename; ac_word=$2 10915 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10916 $as_echo_n "checking for $ac_word... " >&6; } 10917 if ${ac_cv_path_TEE+:} false; then : 10918 $as_echo_n "(cached) " >&6 10919 else 10920 case $TEE in 10921 [\\/]* | ?:[\\/]*) 10922 ac_cv_path_TEE="$TEE" # Let the user override the test with a path. 10923 ;; 10924 *) 10925 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 10926 for as_dir in $PATH 10927 do 10928 IFS=$as_save_IFS 10929 test -z "$as_dir" && as_dir=. 10930 for ac_exec_ext in '' $ac_executable_extensions; do 10931 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 10932 ac_cv_path_TEE="$as_dir/$ac_word$ac_exec_ext" 10933 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 10934 break 2 10935 fi 10936 done 10937 done 10938 IFS=$as_save_IFS 10939 10940 ;; 10941 esac 10942 fi 10943 TEE=$ac_cv_path_TEE 10944 if test -n "$TEE"; then 10945 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEE" >&5 10946 $as_echo "$TEE" >&6; } 10947 else 10948 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 10949 $as_echo "no" >&6; } 10950 fi 10951 10952 10953 if test "x$TEE" = x; then 10954 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 10955 fi 10956 else 10957 # Otherwise we believe it is a complete path. Use it as it is. 10958 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TEE=$tool_specified" >&5 10959 $as_echo "$as_me: Will use user supplied tool TEE=$tool_specified" >&6;} 10960 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TEE" >&5 10961 $as_echo_n "checking for TEE... " >&6; } 10962 if test ! -x "$tool_specified"; then 10963 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 10964 $as_echo "not found" >&6; } 10965 as_fn_error $? "User supplied tool TEE=$tool_specified does not exist or is not executable" "$LINENO" 5 10966 fi 10967 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 10968 $as_echo "$tool_specified" >&6; } 10969 fi 10970 fi 10971 fi 10972 10973 fi 10974 10975 10976 10977 if test "x$TEE" = x; then 10978 as_fn_error $? "Could not find required tool for TEE" "$LINENO" 5 10979 fi 10980 10981 10982 10983 10984 10985 # Publish this variable in the help. 10986 10987 10988 if [ -z "${TOUCH+x}" ]; then 10989 # The variable is not set by user, try to locate tool using the code snippet 10990 for ac_prog in touch 10991 do 10992 # Extract the first word of "$ac_prog", so it can be a program name with args. 10993 set dummy $ac_prog; ac_word=$2 10994 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 10995 $as_echo_n "checking for $ac_word... " >&6; } 10996 if ${ac_cv_path_TOUCH+:} false; then : 10997 $as_echo_n "(cached) " >&6 10998 else 10999 case $TOUCH in 11000 [\\/]* | ?:[\\/]*) 11001 ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path. 11002 ;; 11003 *) 11004 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11005 for as_dir in $PATH 11006 do 11007 IFS=$as_save_IFS 11008 test -z "$as_dir" && as_dir=. 11009 for ac_exec_ext in '' $ac_executable_extensions; do 11010 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11011 ac_cv_path_TOUCH="$as_dir/$ac_word$ac_exec_ext" 11012 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11013 break 2 11014 fi 11015 done 11016 done 11017 IFS=$as_save_IFS 11018 11019 ;; 11020 esac 11021 fi 11022 TOUCH=$ac_cv_path_TOUCH 11023 if test -n "$TOUCH"; then 11024 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOUCH" >&5 11025 $as_echo "$TOUCH" >&6; } 11026 else 11027 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11028 $as_echo "no" >&6; } 11029 fi 11030 11031 11032 test -n "$TOUCH" && break 11033 done 11034 11035 else 11036 # The variable is set, but is it from the command line or the environment? 11037 11038 # Try to remove the string !TOUCH! from our list. 11039 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TOUCH!/} 11040 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 11041 # If it failed, the variable was not from the command line. Ignore it, 11042 # but warn the user (except for BASH, which is always set by the calling BASH). 11043 if test "xTOUCH" != xBASH; then 11044 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TOUCH from the environment. Use command line variables instead." >&5 11045 $as_echo "$as_me: WARNING: Ignoring value of TOUCH from the environment. Use command line variables instead." >&2;} 11046 fi 11047 # Try to locate tool using the code snippet 11048 for ac_prog in touch 11049 do 11050 # Extract the first word of "$ac_prog", so it can be a program name with args. 11051 set dummy $ac_prog; ac_word=$2 11052 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11053 $as_echo_n "checking for $ac_word... " >&6; } 11054 if ${ac_cv_path_TOUCH+:} false; then : 11055 $as_echo_n "(cached) " >&6 11056 else 11057 case $TOUCH in 11058 [\\/]* | ?:[\\/]*) 11059 ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path. 11060 ;; 11061 *) 11062 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11063 for as_dir in $PATH 11064 do 11065 IFS=$as_save_IFS 11066 test -z "$as_dir" && as_dir=. 11067 for ac_exec_ext in '' $ac_executable_extensions; do 11068 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11069 ac_cv_path_TOUCH="$as_dir/$ac_word$ac_exec_ext" 11070 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11071 break 2 11072 fi 11073 done 11074 done 11075 IFS=$as_save_IFS 11076 11077 ;; 11078 esac 11079 fi 11080 TOUCH=$ac_cv_path_TOUCH 11081 if test -n "$TOUCH"; then 11082 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOUCH" >&5 11083 $as_echo "$TOUCH" >&6; } 11084 else 11085 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11086 $as_echo "no" >&6; } 11087 fi 11088 11089 11090 test -n "$TOUCH" && break 11091 done 11092 11093 else 11094 # If it succeeded, then it was overridden by the user. We will use it 11095 # for the tool. 11096 11097 # First remove it from the list of overridden variables, so we can test 11098 # for unknown variables in the end. 11099 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 11100 11101 # Check if we try to supply an empty value 11102 if test "x$TOUCH" = x; then 11103 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TOUCH= (no value)" >&5 11104 $as_echo "$as_me: Setting user supplied tool TOUCH= (no value)" >&6;} 11105 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TOUCH" >&5 11106 $as_echo_n "checking for TOUCH... " >&6; } 11107 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 11108 $as_echo "disabled" >&6; } 11109 else 11110 # Check if the provided tool contains a complete path. 11111 tool_specified="$TOUCH" 11112 tool_basename="${tool_specified##*/}" 11113 if test "x$tool_basename" = "x$tool_specified"; then 11114 # A command without a complete path is provided, search $PATH. 11115 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TOUCH=$tool_basename" >&5 11116 $as_echo "$as_me: Will search for user supplied tool TOUCH=$tool_basename" >&6;} 11117 # Extract the first word of "$tool_basename", so it can be a program name with args. 11118 set dummy $tool_basename; ac_word=$2 11119 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11120 $as_echo_n "checking for $ac_word... " >&6; } 11121 if ${ac_cv_path_TOUCH+:} false; then : 11122 $as_echo_n "(cached) " >&6 11123 else 11124 case $TOUCH in 11125 [\\/]* | ?:[\\/]*) 11126 ac_cv_path_TOUCH="$TOUCH" # Let the user override the test with a path. 11127 ;; 11128 *) 11129 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11130 for as_dir in $PATH 11131 do 11132 IFS=$as_save_IFS 11133 test -z "$as_dir" && as_dir=. 11134 for ac_exec_ext in '' $ac_executable_extensions; do 11135 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11136 ac_cv_path_TOUCH="$as_dir/$ac_word$ac_exec_ext" 11137 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11138 break 2 11139 fi 11140 done 11141 done 11142 IFS=$as_save_IFS 11143 11144 ;; 11145 esac 11146 fi 11147 TOUCH=$ac_cv_path_TOUCH 11148 if test -n "$TOUCH"; then 11149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOUCH" >&5 11150 $as_echo "$TOUCH" >&6; } 11151 else 11152 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11153 $as_echo "no" >&6; } 11154 fi 11155 11156 11157 if test "x$TOUCH" = x; then 11158 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 11159 fi 11160 else 11161 # Otherwise we believe it is a complete path. Use it as it is. 11162 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TOUCH=$tool_specified" >&5 11163 $as_echo "$as_me: Will use user supplied tool TOUCH=$tool_specified" >&6;} 11164 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TOUCH" >&5 11165 $as_echo_n "checking for TOUCH... " >&6; } 11166 if test ! -x "$tool_specified"; then 11167 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 11168 $as_echo "not found" >&6; } 11169 as_fn_error $? "User supplied tool TOUCH=$tool_specified does not exist or is not executable" "$LINENO" 5 11170 fi 11171 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 11172 $as_echo "$tool_specified" >&6; } 11173 fi 11174 fi 11175 fi 11176 11177 fi 11178 11179 11180 11181 if test "x$TOUCH" = x; then 11182 as_fn_error $? "Could not find required tool for TOUCH" "$LINENO" 5 11183 fi 11184 11185 11186 11187 11188 11189 # Publish this variable in the help. 11190 11191 11192 if [ -z "${TR+x}" ]; then 11193 # The variable is not set by user, try to locate tool using the code snippet 11194 for ac_prog in tr 11195 do 11196 # Extract the first word of "$ac_prog", so it can be a program name with args. 11197 set dummy $ac_prog; ac_word=$2 11198 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11199 $as_echo_n "checking for $ac_word... " >&6; } 11200 if ${ac_cv_path_TR+:} false; then : 11201 $as_echo_n "(cached) " >&6 11202 else 11203 case $TR in 11204 [\\/]* | ?:[\\/]*) 11205 ac_cv_path_TR="$TR" # Let the user override the test with a path. 11206 ;; 11207 *) 11208 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11209 for as_dir in $PATH 11210 do 11211 IFS=$as_save_IFS 11212 test -z "$as_dir" && as_dir=. 11213 for ac_exec_ext in '' $ac_executable_extensions; do 11214 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11215 ac_cv_path_TR="$as_dir/$ac_word$ac_exec_ext" 11216 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11217 break 2 11218 fi 11219 done 11220 done 11221 IFS=$as_save_IFS 11222 11223 ;; 11224 esac 11225 fi 11226 TR=$ac_cv_path_TR 11227 if test -n "$TR"; then 11228 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TR" >&5 11229 $as_echo "$TR" >&6; } 11230 else 11231 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11232 $as_echo "no" >&6; } 11233 fi 11234 11235 11236 test -n "$TR" && break 11237 done 11238 11239 else 11240 # The variable is set, but is it from the command line or the environment? 11241 11242 # Try to remove the string !TR! from our list. 11243 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TR!/} 11244 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 11245 # If it failed, the variable was not from the command line. Ignore it, 11246 # but warn the user (except for BASH, which is always set by the calling BASH). 11247 if test "xTR" != xBASH; then 11248 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TR from the environment. Use command line variables instead." >&5 11249 $as_echo "$as_me: WARNING: Ignoring value of TR from the environment. Use command line variables instead." >&2;} 11250 fi 11251 # Try to locate tool using the code snippet 11252 for ac_prog in tr 11253 do 11254 # Extract the first word of "$ac_prog", so it can be a program name with args. 11255 set dummy $ac_prog; ac_word=$2 11256 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11257 $as_echo_n "checking for $ac_word... " >&6; } 11258 if ${ac_cv_path_TR+:} false; then : 11259 $as_echo_n "(cached) " >&6 11260 else 11261 case $TR in 11262 [\\/]* | ?:[\\/]*) 11263 ac_cv_path_TR="$TR" # Let the user override the test with a path. 11264 ;; 11265 *) 11266 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11267 for as_dir in $PATH 11268 do 11269 IFS=$as_save_IFS 11270 test -z "$as_dir" && as_dir=. 11271 for ac_exec_ext in '' $ac_executable_extensions; do 11272 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11273 ac_cv_path_TR="$as_dir/$ac_word$ac_exec_ext" 11274 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11275 break 2 11276 fi 11277 done 11278 done 11279 IFS=$as_save_IFS 11280 11281 ;; 11282 esac 11283 fi 11284 TR=$ac_cv_path_TR 11285 if test -n "$TR"; then 11286 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TR" >&5 11287 $as_echo "$TR" >&6; } 11288 else 11289 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11290 $as_echo "no" >&6; } 11291 fi 11292 11293 11294 test -n "$TR" && break 11295 done 11296 11297 else 11298 # If it succeeded, then it was overridden by the user. We will use it 11299 # for the tool. 11300 11301 # First remove it from the list of overridden variables, so we can test 11302 # for unknown variables in the end. 11303 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 11304 11305 # Check if we try to supply an empty value 11306 if test "x$TR" = x; then 11307 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TR= (no value)" >&5 11308 $as_echo "$as_me: Setting user supplied tool TR= (no value)" >&6;} 11309 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TR" >&5 11310 $as_echo_n "checking for TR... " >&6; } 11311 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 11312 $as_echo "disabled" >&6; } 11313 else 11314 # Check if the provided tool contains a complete path. 11315 tool_specified="$TR" 11316 tool_basename="${tool_specified##*/}" 11317 if test "x$tool_basename" = "x$tool_specified"; then 11318 # A command without a complete path is provided, search $PATH. 11319 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TR=$tool_basename" >&5 11320 $as_echo "$as_me: Will search for user supplied tool TR=$tool_basename" >&6;} 11321 # Extract the first word of "$tool_basename", so it can be a program name with args. 11322 set dummy $tool_basename; ac_word=$2 11323 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11324 $as_echo_n "checking for $ac_word... " >&6; } 11325 if ${ac_cv_path_TR+:} false; then : 11326 $as_echo_n "(cached) " >&6 11327 else 11328 case $TR in 11329 [\\/]* | ?:[\\/]*) 11330 ac_cv_path_TR="$TR" # Let the user override the test with a path. 11331 ;; 11332 *) 11333 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11334 for as_dir in $PATH 11335 do 11336 IFS=$as_save_IFS 11337 test -z "$as_dir" && as_dir=. 11338 for ac_exec_ext in '' $ac_executable_extensions; do 11339 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11340 ac_cv_path_TR="$as_dir/$ac_word$ac_exec_ext" 11341 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11342 break 2 11343 fi 11344 done 11345 done 11346 IFS=$as_save_IFS 11347 11348 ;; 11349 esac 11350 fi 11351 TR=$ac_cv_path_TR 11352 if test -n "$TR"; then 11353 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TR" >&5 11354 $as_echo "$TR" >&6; } 11355 else 11356 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11357 $as_echo "no" >&6; } 11358 fi 11359 11360 11361 if test "x$TR" = x; then 11362 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 11363 fi 11364 else 11365 # Otherwise we believe it is a complete path. Use it as it is. 11366 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TR=$tool_specified" >&5 11367 $as_echo "$as_me: Will use user supplied tool TR=$tool_specified" >&6;} 11368 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TR" >&5 11369 $as_echo_n "checking for TR... " >&6; } 11370 if test ! -x "$tool_specified"; then 11371 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 11372 $as_echo "not found" >&6; } 11373 as_fn_error $? "User supplied tool TR=$tool_specified does not exist or is not executable" "$LINENO" 5 11374 fi 11375 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 11376 $as_echo "$tool_specified" >&6; } 11377 fi 11378 fi 11379 fi 11380 11381 fi 11382 11383 11384 11385 if test "x$TR" = x; then 11386 as_fn_error $? "Could not find required tool for TR" "$LINENO" 5 11387 fi 11388 11389 11390 11391 11392 11393 # Publish this variable in the help. 11394 11395 11396 if [ -z "${UNAME+x}" ]; then 11397 # The variable is not set by user, try to locate tool using the code snippet 11398 for ac_prog in uname 11399 do 11400 # Extract the first word of "$ac_prog", so it can be a program name with args. 11401 set dummy $ac_prog; ac_word=$2 11402 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11403 $as_echo_n "checking for $ac_word... " >&6; } 11404 if ${ac_cv_path_UNAME+:} false; then : 11405 $as_echo_n "(cached) " >&6 11406 else 11407 case $UNAME in 11408 [\\/]* | ?:[\\/]*) 11409 ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path. 11410 ;; 11411 *) 11412 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11413 for as_dir in $PATH 11414 do 11415 IFS=$as_save_IFS 11416 test -z "$as_dir" && as_dir=. 11417 for ac_exec_ext in '' $ac_executable_extensions; do 11418 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11419 ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext" 11420 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11421 break 2 11422 fi 11423 done 11424 done 11425 IFS=$as_save_IFS 11426 11427 ;; 11428 esac 11429 fi 11430 UNAME=$ac_cv_path_UNAME 11431 if test -n "$UNAME"; then 11432 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5 11433 $as_echo "$UNAME" >&6; } 11434 else 11435 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11436 $as_echo "no" >&6; } 11437 fi 11438 11439 11440 test -n "$UNAME" && break 11441 done 11442 11443 else 11444 # The variable is set, but is it from the command line or the environment? 11445 11446 # Try to remove the string !UNAME! from our list. 11447 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!UNAME!/} 11448 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 11449 # If it failed, the variable was not from the command line. Ignore it, 11450 # but warn the user (except for BASH, which is always set by the calling BASH). 11451 if test "xUNAME" != xBASH; then 11452 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of UNAME from the environment. Use command line variables instead." >&5 11453 $as_echo "$as_me: WARNING: Ignoring value of UNAME from the environment. Use command line variables instead." >&2;} 11454 fi 11455 # Try to locate tool using the code snippet 11456 for ac_prog in uname 11457 do 11458 # Extract the first word of "$ac_prog", so it can be a program name with args. 11459 set dummy $ac_prog; ac_word=$2 11460 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11461 $as_echo_n "checking for $ac_word... " >&6; } 11462 if ${ac_cv_path_UNAME+:} false; then : 11463 $as_echo_n "(cached) " >&6 11464 else 11465 case $UNAME in 11466 [\\/]* | ?:[\\/]*) 11467 ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path. 11468 ;; 11469 *) 11470 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11471 for as_dir in $PATH 11472 do 11473 IFS=$as_save_IFS 11474 test -z "$as_dir" && as_dir=. 11475 for ac_exec_ext in '' $ac_executable_extensions; do 11476 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11477 ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext" 11478 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11479 break 2 11480 fi 11481 done 11482 done 11483 IFS=$as_save_IFS 11484 11485 ;; 11486 esac 11487 fi 11488 UNAME=$ac_cv_path_UNAME 11489 if test -n "$UNAME"; then 11490 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5 11491 $as_echo "$UNAME" >&6; } 11492 else 11493 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11494 $as_echo "no" >&6; } 11495 fi 11496 11497 11498 test -n "$UNAME" && break 11499 done 11500 11501 else 11502 # If it succeeded, then it was overridden by the user. We will use it 11503 # for the tool. 11504 11505 # First remove it from the list of overridden variables, so we can test 11506 # for unknown variables in the end. 11507 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 11508 11509 # Check if we try to supply an empty value 11510 if test "x$UNAME" = x; then 11511 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool UNAME= (no value)" >&5 11512 $as_echo "$as_me: Setting user supplied tool UNAME= (no value)" >&6;} 11513 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNAME" >&5 11514 $as_echo_n "checking for UNAME... " >&6; } 11515 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 11516 $as_echo "disabled" >&6; } 11517 else 11518 # Check if the provided tool contains a complete path. 11519 tool_specified="$UNAME" 11520 tool_basename="${tool_specified##*/}" 11521 if test "x$tool_basename" = "x$tool_specified"; then 11522 # A command without a complete path is provided, search $PATH. 11523 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool UNAME=$tool_basename" >&5 11524 $as_echo "$as_me: Will search for user supplied tool UNAME=$tool_basename" >&6;} 11525 # Extract the first word of "$tool_basename", so it can be a program name with args. 11526 set dummy $tool_basename; ac_word=$2 11527 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11528 $as_echo_n "checking for $ac_word... " >&6; } 11529 if ${ac_cv_path_UNAME+:} false; then : 11530 $as_echo_n "(cached) " >&6 11531 else 11532 case $UNAME in 11533 [\\/]* | ?:[\\/]*) 11534 ac_cv_path_UNAME="$UNAME" # Let the user override the test with a path. 11535 ;; 11536 *) 11537 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11538 for as_dir in $PATH 11539 do 11540 IFS=$as_save_IFS 11541 test -z "$as_dir" && as_dir=. 11542 for ac_exec_ext in '' $ac_executable_extensions; do 11543 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11544 ac_cv_path_UNAME="$as_dir/$ac_word$ac_exec_ext" 11545 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11546 break 2 11547 fi 11548 done 11549 done 11550 IFS=$as_save_IFS 11551 11552 ;; 11553 esac 11554 fi 11555 UNAME=$ac_cv_path_UNAME 11556 if test -n "$UNAME"; then 11557 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNAME" >&5 11558 $as_echo "$UNAME" >&6; } 11559 else 11560 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11561 $as_echo "no" >&6; } 11562 fi 11563 11564 11565 if test "x$UNAME" = x; then 11566 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 11567 fi 11568 else 11569 # Otherwise we believe it is a complete path. Use it as it is. 11570 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool UNAME=$tool_specified" >&5 11571 $as_echo "$as_me: Will use user supplied tool UNAME=$tool_specified" >&6;} 11572 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNAME" >&5 11573 $as_echo_n "checking for UNAME... " >&6; } 11574 if test ! -x "$tool_specified"; then 11575 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 11576 $as_echo "not found" >&6; } 11577 as_fn_error $? "User supplied tool UNAME=$tool_specified does not exist or is not executable" "$LINENO" 5 11578 fi 11579 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 11580 $as_echo "$tool_specified" >&6; } 11581 fi 11582 fi 11583 fi 11584 11585 fi 11586 11587 11588 11589 if test "x$UNAME" = x; then 11590 as_fn_error $? "Could not find required tool for UNAME" "$LINENO" 5 11591 fi 11592 11593 11594 11595 11596 11597 # Publish this variable in the help. 11598 11599 11600 if [ -z "${UNIQ+x}" ]; then 11601 # The variable is not set by user, try to locate tool using the code snippet 11602 for ac_prog in uniq 11603 do 11604 # Extract the first word of "$ac_prog", so it can be a program name with args. 11605 set dummy $ac_prog; ac_word=$2 11606 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11607 $as_echo_n "checking for $ac_word... " >&6; } 11608 if ${ac_cv_path_UNIQ+:} false; then : 11609 $as_echo_n "(cached) " >&6 11610 else 11611 case $UNIQ in 11612 [\\/]* | ?:[\\/]*) 11613 ac_cv_path_UNIQ="$UNIQ" # Let the user override the test with a path. 11614 ;; 11615 *) 11616 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11617 for as_dir in $PATH 11618 do 11619 IFS=$as_save_IFS 11620 test -z "$as_dir" && as_dir=. 11621 for ac_exec_ext in '' $ac_executable_extensions; do 11622 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11623 ac_cv_path_UNIQ="$as_dir/$ac_word$ac_exec_ext" 11624 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11625 break 2 11626 fi 11627 done 11628 done 11629 IFS=$as_save_IFS 11630 11631 ;; 11632 esac 11633 fi 11634 UNIQ=$ac_cv_path_UNIQ 11635 if test -n "$UNIQ"; then 11636 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNIQ" >&5 11637 $as_echo "$UNIQ" >&6; } 11638 else 11639 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11640 $as_echo "no" >&6; } 11641 fi 11642 11643 11644 test -n "$UNIQ" && break 11645 done 11646 11647 else 11648 # The variable is set, but is it from the command line or the environment? 11649 11650 # Try to remove the string !UNIQ! from our list. 11651 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!UNIQ!/} 11652 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 11653 # If it failed, the variable was not from the command line. Ignore it, 11654 # but warn the user (except for BASH, which is always set by the calling BASH). 11655 if test "xUNIQ" != xBASH; then 11656 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of UNIQ from the environment. Use command line variables instead." >&5 11657 $as_echo "$as_me: WARNING: Ignoring value of UNIQ from the environment. Use command line variables instead." >&2;} 11658 fi 11659 # Try to locate tool using the code snippet 11660 for ac_prog in uniq 11661 do 11662 # Extract the first word of "$ac_prog", so it can be a program name with args. 11663 set dummy $ac_prog; ac_word=$2 11664 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11665 $as_echo_n "checking for $ac_word... " >&6; } 11666 if ${ac_cv_path_UNIQ+:} false; then : 11667 $as_echo_n "(cached) " >&6 11668 else 11669 case $UNIQ in 11670 [\\/]* | ?:[\\/]*) 11671 ac_cv_path_UNIQ="$UNIQ" # Let the user override the test with a path. 11672 ;; 11673 *) 11674 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11675 for as_dir in $PATH 11676 do 11677 IFS=$as_save_IFS 11678 test -z "$as_dir" && as_dir=. 11679 for ac_exec_ext in '' $ac_executable_extensions; do 11680 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11681 ac_cv_path_UNIQ="$as_dir/$ac_word$ac_exec_ext" 11682 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11683 break 2 11684 fi 11685 done 11686 done 11687 IFS=$as_save_IFS 11688 11689 ;; 11690 esac 11691 fi 11692 UNIQ=$ac_cv_path_UNIQ 11693 if test -n "$UNIQ"; then 11694 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNIQ" >&5 11695 $as_echo "$UNIQ" >&6; } 11696 else 11697 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11698 $as_echo "no" >&6; } 11699 fi 11700 11701 11702 test -n "$UNIQ" && break 11703 done 11704 11705 else 11706 # If it succeeded, then it was overridden by the user. We will use it 11707 # for the tool. 11708 11709 # First remove it from the list of overridden variables, so we can test 11710 # for unknown variables in the end. 11711 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 11712 11713 # Check if we try to supply an empty value 11714 if test "x$UNIQ" = x; then 11715 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool UNIQ= (no value)" >&5 11716 $as_echo "$as_me: Setting user supplied tool UNIQ= (no value)" >&6;} 11717 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNIQ" >&5 11718 $as_echo_n "checking for UNIQ... " >&6; } 11719 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 11720 $as_echo "disabled" >&6; } 11721 else 11722 # Check if the provided tool contains a complete path. 11723 tool_specified="$UNIQ" 11724 tool_basename="${tool_specified##*/}" 11725 if test "x$tool_basename" = "x$tool_specified"; then 11726 # A command without a complete path is provided, search $PATH. 11727 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool UNIQ=$tool_basename" >&5 11728 $as_echo "$as_me: Will search for user supplied tool UNIQ=$tool_basename" >&6;} 11729 # Extract the first word of "$tool_basename", so it can be a program name with args. 11730 set dummy $tool_basename; ac_word=$2 11731 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11732 $as_echo_n "checking for $ac_word... " >&6; } 11733 if ${ac_cv_path_UNIQ+:} false; then : 11734 $as_echo_n "(cached) " >&6 11735 else 11736 case $UNIQ in 11737 [\\/]* | ?:[\\/]*) 11738 ac_cv_path_UNIQ="$UNIQ" # Let the user override the test with a path. 11739 ;; 11740 *) 11741 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11742 for as_dir in $PATH 11743 do 11744 IFS=$as_save_IFS 11745 test -z "$as_dir" && as_dir=. 11746 for ac_exec_ext in '' $ac_executable_extensions; do 11747 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11748 ac_cv_path_UNIQ="$as_dir/$ac_word$ac_exec_ext" 11749 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11750 break 2 11751 fi 11752 done 11753 done 11754 IFS=$as_save_IFS 11755 11756 ;; 11757 esac 11758 fi 11759 UNIQ=$ac_cv_path_UNIQ 11760 if test -n "$UNIQ"; then 11761 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNIQ" >&5 11762 $as_echo "$UNIQ" >&6; } 11763 else 11764 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11765 $as_echo "no" >&6; } 11766 fi 11767 11768 11769 if test "x$UNIQ" = x; then 11770 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 11771 fi 11772 else 11773 # Otherwise we believe it is a complete path. Use it as it is. 11774 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool UNIQ=$tool_specified" >&5 11775 $as_echo "$as_me: Will use user supplied tool UNIQ=$tool_specified" >&6;} 11776 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNIQ" >&5 11777 $as_echo_n "checking for UNIQ... " >&6; } 11778 if test ! -x "$tool_specified"; then 11779 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 11780 $as_echo "not found" >&6; } 11781 as_fn_error $? "User supplied tool UNIQ=$tool_specified does not exist or is not executable" "$LINENO" 5 11782 fi 11783 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 11784 $as_echo "$tool_specified" >&6; } 11785 fi 11786 fi 11787 fi 11788 11789 fi 11790 11791 11792 11793 if test "x$UNIQ" = x; then 11794 as_fn_error $? "Could not find required tool for UNIQ" "$LINENO" 5 11795 fi 11796 11797 11798 11799 11800 11801 # Publish this variable in the help. 11802 11803 11804 if [ -z "${WC+x}" ]; then 11805 # The variable is not set by user, try to locate tool using the code snippet 11806 for ac_prog in wc 11807 do 11808 # Extract the first word of "$ac_prog", so it can be a program name with args. 11809 set dummy $ac_prog; ac_word=$2 11810 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11811 $as_echo_n "checking for $ac_word... " >&6; } 11812 if ${ac_cv_path_WC+:} false; then : 11813 $as_echo_n "(cached) " >&6 11814 else 11815 case $WC in 11816 [\\/]* | ?:[\\/]*) 11817 ac_cv_path_WC="$WC" # Let the user override the test with a path. 11818 ;; 11819 *) 11820 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11821 for as_dir in $PATH 11822 do 11823 IFS=$as_save_IFS 11824 test -z "$as_dir" && as_dir=. 11825 for ac_exec_ext in '' $ac_executable_extensions; do 11826 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11827 ac_cv_path_WC="$as_dir/$ac_word$ac_exec_ext" 11828 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11829 break 2 11830 fi 11831 done 11832 done 11833 IFS=$as_save_IFS 11834 11835 ;; 11836 esac 11837 fi 11838 WC=$ac_cv_path_WC 11839 if test -n "$WC"; then 11840 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WC" >&5 11841 $as_echo "$WC" >&6; } 11842 else 11843 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11844 $as_echo "no" >&6; } 11845 fi 11846 11847 11848 test -n "$WC" && break 11849 done 11850 11851 else 11852 # The variable is set, but is it from the command line or the environment? 11853 11854 # Try to remove the string !WC! from our list. 11855 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!WC!/} 11856 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 11857 # If it failed, the variable was not from the command line. Ignore it, 11858 # but warn the user (except for BASH, which is always set by the calling BASH). 11859 if test "xWC" != xBASH; then 11860 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of WC from the environment. Use command line variables instead." >&5 11861 $as_echo "$as_me: WARNING: Ignoring value of WC from the environment. Use command line variables instead." >&2;} 11862 fi 11863 # Try to locate tool using the code snippet 11864 for ac_prog in wc 11865 do 11866 # Extract the first word of "$ac_prog", so it can be a program name with args. 11867 set dummy $ac_prog; ac_word=$2 11868 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11869 $as_echo_n "checking for $ac_word... " >&6; } 11870 if ${ac_cv_path_WC+:} false; then : 11871 $as_echo_n "(cached) " >&6 11872 else 11873 case $WC in 11874 [\\/]* | ?:[\\/]*) 11875 ac_cv_path_WC="$WC" # Let the user override the test with a path. 11876 ;; 11877 *) 11878 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11879 for as_dir in $PATH 11880 do 11881 IFS=$as_save_IFS 11882 test -z "$as_dir" && as_dir=. 11883 for ac_exec_ext in '' $ac_executable_extensions; do 11884 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11885 ac_cv_path_WC="$as_dir/$ac_word$ac_exec_ext" 11886 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11887 break 2 11888 fi 11889 done 11890 done 11891 IFS=$as_save_IFS 11892 11893 ;; 11894 esac 11895 fi 11896 WC=$ac_cv_path_WC 11897 if test -n "$WC"; then 11898 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WC" >&5 11899 $as_echo "$WC" >&6; } 11900 else 11901 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11902 $as_echo "no" >&6; } 11903 fi 11904 11905 11906 test -n "$WC" && break 11907 done 11908 11909 else 11910 # If it succeeded, then it was overridden by the user. We will use it 11911 # for the tool. 11912 11913 # First remove it from the list of overridden variables, so we can test 11914 # for unknown variables in the end. 11915 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 11916 11917 # Check if we try to supply an empty value 11918 if test "x$WC" = x; then 11919 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool WC= (no value)" >&5 11920 $as_echo "$as_me: Setting user supplied tool WC= (no value)" >&6;} 11921 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WC" >&5 11922 $as_echo_n "checking for WC... " >&6; } 11923 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 11924 $as_echo "disabled" >&6; } 11925 else 11926 # Check if the provided tool contains a complete path. 11927 tool_specified="$WC" 11928 tool_basename="${tool_specified##*/}" 11929 if test "x$tool_basename" = "x$tool_specified"; then 11930 # A command without a complete path is provided, search $PATH. 11931 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool WC=$tool_basename" >&5 11932 $as_echo "$as_me: Will search for user supplied tool WC=$tool_basename" >&6;} 11933 # Extract the first word of "$tool_basename", so it can be a program name with args. 11934 set dummy $tool_basename; ac_word=$2 11935 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 11936 $as_echo_n "checking for $ac_word... " >&6; } 11937 if ${ac_cv_path_WC+:} false; then : 11938 $as_echo_n "(cached) " >&6 11939 else 11940 case $WC in 11941 [\\/]* | ?:[\\/]*) 11942 ac_cv_path_WC="$WC" # Let the user override the test with a path. 11943 ;; 11944 *) 11945 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 11946 for as_dir in $PATH 11947 do 11948 IFS=$as_save_IFS 11949 test -z "$as_dir" && as_dir=. 11950 for ac_exec_ext in '' $ac_executable_extensions; do 11951 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 11952 ac_cv_path_WC="$as_dir/$ac_word$ac_exec_ext" 11953 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 11954 break 2 11955 fi 11956 done 11957 done 11958 IFS=$as_save_IFS 11959 11960 ;; 11961 esac 11962 fi 11963 WC=$ac_cv_path_WC 11964 if test -n "$WC"; then 11965 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WC" >&5 11966 $as_echo "$WC" >&6; } 11967 else 11968 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 11969 $as_echo "no" >&6; } 11970 fi 11971 11972 11973 if test "x$WC" = x; then 11974 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 11975 fi 11976 else 11977 # Otherwise we believe it is a complete path. Use it as it is. 11978 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool WC=$tool_specified" >&5 11979 $as_echo "$as_me: Will use user supplied tool WC=$tool_specified" >&6;} 11980 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WC" >&5 11981 $as_echo_n "checking for WC... " >&6; } 11982 if test ! -x "$tool_specified"; then 11983 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 11984 $as_echo "not found" >&6; } 11985 as_fn_error $? "User supplied tool WC=$tool_specified does not exist or is not executable" "$LINENO" 5 11986 fi 11987 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 11988 $as_echo "$tool_specified" >&6; } 11989 fi 11990 fi 11991 fi 11992 11993 fi 11994 11995 11996 11997 if test "x$WC" = x; then 11998 as_fn_error $? "Could not find required tool for WC" "$LINENO" 5 11999 fi 12000 12001 12002 12003 12004 12005 # Publish this variable in the help. 12006 12007 12008 if [ -z "${WHICH+x}" ]; then 12009 # The variable is not set by user, try to locate tool using the code snippet 12010 for ac_prog in which 12011 do 12012 # Extract the first word of "$ac_prog", so it can be a program name with args. 12013 set dummy $ac_prog; ac_word=$2 12014 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12015 $as_echo_n "checking for $ac_word... " >&6; } 12016 if ${ac_cv_path_WHICH+:} false; then : 12017 $as_echo_n "(cached) " >&6 12018 else 12019 case $WHICH in 12020 [\\/]* | ?:[\\/]*) 12021 ac_cv_path_WHICH="$WHICH" # Let the user override the test with a path. 12022 ;; 12023 *) 12024 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12025 for as_dir in $PATH 12026 do 12027 IFS=$as_save_IFS 12028 test -z "$as_dir" && as_dir=. 12029 for ac_exec_ext in '' $ac_executable_extensions; do 12030 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12031 ac_cv_path_WHICH="$as_dir/$ac_word$ac_exec_ext" 12032 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12033 break 2 12034 fi 12035 done 12036 done 12037 IFS=$as_save_IFS 12038 12039 ;; 12040 esac 12041 fi 12042 WHICH=$ac_cv_path_WHICH 12043 if test -n "$WHICH"; then 12044 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WHICH" >&5 12045 $as_echo "$WHICH" >&6; } 12046 else 12047 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12048 $as_echo "no" >&6; } 12049 fi 12050 12051 12052 test -n "$WHICH" && break 12053 done 12054 12055 else 12056 # The variable is set, but is it from the command line or the environment? 12057 12058 # Try to remove the string !WHICH! from our list. 12059 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!WHICH!/} 12060 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 12061 # If it failed, the variable was not from the command line. Ignore it, 12062 # but warn the user (except for BASH, which is always set by the calling BASH). 12063 if test "xWHICH" != xBASH; then 12064 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of WHICH from the environment. Use command line variables instead." >&5 12065 $as_echo "$as_me: WARNING: Ignoring value of WHICH from the environment. Use command line variables instead." >&2;} 12066 fi 12067 # Try to locate tool using the code snippet 12068 for ac_prog in which 12069 do 12070 # Extract the first word of "$ac_prog", so it can be a program name with args. 12071 set dummy $ac_prog; ac_word=$2 12072 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12073 $as_echo_n "checking for $ac_word... " >&6; } 12074 if ${ac_cv_path_WHICH+:} false; then : 12075 $as_echo_n "(cached) " >&6 12076 else 12077 case $WHICH in 12078 [\\/]* | ?:[\\/]*) 12079 ac_cv_path_WHICH="$WHICH" # Let the user override the test with a path. 12080 ;; 12081 *) 12082 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12083 for as_dir in $PATH 12084 do 12085 IFS=$as_save_IFS 12086 test -z "$as_dir" && as_dir=. 12087 for ac_exec_ext in '' $ac_executable_extensions; do 12088 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12089 ac_cv_path_WHICH="$as_dir/$ac_word$ac_exec_ext" 12090 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12091 break 2 12092 fi 12093 done 12094 done 12095 IFS=$as_save_IFS 12096 12097 ;; 12098 esac 12099 fi 12100 WHICH=$ac_cv_path_WHICH 12101 if test -n "$WHICH"; then 12102 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WHICH" >&5 12103 $as_echo "$WHICH" >&6; } 12104 else 12105 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12106 $as_echo "no" >&6; } 12107 fi 12108 12109 12110 test -n "$WHICH" && break 12111 done 12112 12113 else 12114 # If it succeeded, then it was overridden by the user. We will use it 12115 # for the tool. 12116 12117 # First remove it from the list of overridden variables, so we can test 12118 # for unknown variables in the end. 12119 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 12120 12121 # Check if we try to supply an empty value 12122 if test "x$WHICH" = x; then 12123 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool WHICH= (no value)" >&5 12124 $as_echo "$as_me: Setting user supplied tool WHICH= (no value)" >&6;} 12125 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WHICH" >&5 12126 $as_echo_n "checking for WHICH... " >&6; } 12127 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 12128 $as_echo "disabled" >&6; } 12129 else 12130 # Check if the provided tool contains a complete path. 12131 tool_specified="$WHICH" 12132 tool_basename="${tool_specified##*/}" 12133 if test "x$tool_basename" = "x$tool_specified"; then 12134 # A command without a complete path is provided, search $PATH. 12135 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool WHICH=$tool_basename" >&5 12136 $as_echo "$as_me: Will search for user supplied tool WHICH=$tool_basename" >&6;} 12137 # Extract the first word of "$tool_basename", so it can be a program name with args. 12138 set dummy $tool_basename; ac_word=$2 12139 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12140 $as_echo_n "checking for $ac_word... " >&6; } 12141 if ${ac_cv_path_WHICH+:} false; then : 12142 $as_echo_n "(cached) " >&6 12143 else 12144 case $WHICH in 12145 [\\/]* | ?:[\\/]*) 12146 ac_cv_path_WHICH="$WHICH" # Let the user override the test with a path. 12147 ;; 12148 *) 12149 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12150 for as_dir in $PATH 12151 do 12152 IFS=$as_save_IFS 12153 test -z "$as_dir" && as_dir=. 12154 for ac_exec_ext in '' $ac_executable_extensions; do 12155 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12156 ac_cv_path_WHICH="$as_dir/$ac_word$ac_exec_ext" 12157 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12158 break 2 12159 fi 12160 done 12161 done 12162 IFS=$as_save_IFS 12163 12164 ;; 12165 esac 12166 fi 12167 WHICH=$ac_cv_path_WHICH 12168 if test -n "$WHICH"; then 12169 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $WHICH" >&5 12170 $as_echo "$WHICH" >&6; } 12171 else 12172 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12173 $as_echo "no" >&6; } 12174 fi 12175 12176 12177 if test "x$WHICH" = x; then 12178 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 12179 fi 12180 else 12181 # Otherwise we believe it is a complete path. Use it as it is. 12182 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool WHICH=$tool_specified" >&5 12183 $as_echo "$as_me: Will use user supplied tool WHICH=$tool_specified" >&6;} 12184 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for WHICH" >&5 12185 $as_echo_n "checking for WHICH... " >&6; } 12186 if test ! -x "$tool_specified"; then 12187 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 12188 $as_echo "not found" >&6; } 12189 as_fn_error $? "User supplied tool WHICH=$tool_specified does not exist or is not executable" "$LINENO" 5 12190 fi 12191 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 12192 $as_echo "$tool_specified" >&6; } 12193 fi 12194 fi 12195 fi 12196 12197 fi 12198 12199 12200 12201 if test "x$WHICH" = x; then 12202 as_fn_error $? "Could not find required tool for WHICH" "$LINENO" 5 12203 fi 12204 12205 12206 12207 12208 12209 # Publish this variable in the help. 12210 12211 12212 if [ -z "${XARGS+x}" ]; then 12213 # The variable is not set by user, try to locate tool using the code snippet 12214 for ac_prog in xargs 12215 do 12216 # Extract the first word of "$ac_prog", so it can be a program name with args. 12217 set dummy $ac_prog; ac_word=$2 12218 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12219 $as_echo_n "checking for $ac_word... " >&6; } 12220 if ${ac_cv_path_XARGS+:} false; then : 12221 $as_echo_n "(cached) " >&6 12222 else 12223 case $XARGS in 12224 [\\/]* | ?:[\\/]*) 12225 ac_cv_path_XARGS="$XARGS" # Let the user override the test with a path. 12226 ;; 12227 *) 12228 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12229 for as_dir in $PATH 12230 do 12231 IFS=$as_save_IFS 12232 test -z "$as_dir" && as_dir=. 12233 for ac_exec_ext in '' $ac_executable_extensions; do 12234 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12235 ac_cv_path_XARGS="$as_dir/$ac_word$ac_exec_ext" 12236 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12237 break 2 12238 fi 12239 done 12240 done 12241 IFS=$as_save_IFS 12242 12243 ;; 12244 esac 12245 fi 12246 XARGS=$ac_cv_path_XARGS 12247 if test -n "$XARGS"; then 12248 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XARGS" >&5 12249 $as_echo "$XARGS" >&6; } 12250 else 12251 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12252 $as_echo "no" >&6; } 12253 fi 12254 12255 12256 test -n "$XARGS" && break 12257 done 12258 12259 else 12260 # The variable is set, but is it from the command line or the environment? 12261 12262 # Try to remove the string !XARGS! from our list. 12263 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!XARGS!/} 12264 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 12265 # If it failed, the variable was not from the command line. Ignore it, 12266 # but warn the user (except for BASH, which is always set by the calling BASH). 12267 if test "xXARGS" != xBASH; then 12268 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of XARGS from the environment. Use command line variables instead." >&5 12269 $as_echo "$as_me: WARNING: Ignoring value of XARGS from the environment. Use command line variables instead." >&2;} 12270 fi 12271 # Try to locate tool using the code snippet 12272 for ac_prog in xargs 12273 do 12274 # Extract the first word of "$ac_prog", so it can be a program name with args. 12275 set dummy $ac_prog; ac_word=$2 12276 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12277 $as_echo_n "checking for $ac_word... " >&6; } 12278 if ${ac_cv_path_XARGS+:} false; then : 12279 $as_echo_n "(cached) " >&6 12280 else 12281 case $XARGS in 12282 [\\/]* | ?:[\\/]*) 12283 ac_cv_path_XARGS="$XARGS" # Let the user override the test with a path. 12284 ;; 12285 *) 12286 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12287 for as_dir in $PATH 12288 do 12289 IFS=$as_save_IFS 12290 test -z "$as_dir" && as_dir=. 12291 for ac_exec_ext in '' $ac_executable_extensions; do 12292 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12293 ac_cv_path_XARGS="$as_dir/$ac_word$ac_exec_ext" 12294 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12295 break 2 12296 fi 12297 done 12298 done 12299 IFS=$as_save_IFS 12300 12301 ;; 12302 esac 12303 fi 12304 XARGS=$ac_cv_path_XARGS 12305 if test -n "$XARGS"; then 12306 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XARGS" >&5 12307 $as_echo "$XARGS" >&6; } 12308 else 12309 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12310 $as_echo "no" >&6; } 12311 fi 12312 12313 12314 test -n "$XARGS" && break 12315 done 12316 12317 else 12318 # If it succeeded, then it was overridden by the user. We will use it 12319 # for the tool. 12320 12321 # First remove it from the list of overridden variables, so we can test 12322 # for unknown variables in the end. 12323 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 12324 12325 # Check if we try to supply an empty value 12326 if test "x$XARGS" = x; then 12327 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool XARGS= (no value)" >&5 12328 $as_echo "$as_me: Setting user supplied tool XARGS= (no value)" >&6;} 12329 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XARGS" >&5 12330 $as_echo_n "checking for XARGS... " >&6; } 12331 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 12332 $as_echo "disabled" >&6; } 12333 else 12334 # Check if the provided tool contains a complete path. 12335 tool_specified="$XARGS" 12336 tool_basename="${tool_specified##*/}" 12337 if test "x$tool_basename" = "x$tool_specified"; then 12338 # A command without a complete path is provided, search $PATH. 12339 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool XARGS=$tool_basename" >&5 12340 $as_echo "$as_me: Will search for user supplied tool XARGS=$tool_basename" >&6;} 12341 # Extract the first word of "$tool_basename", so it can be a program name with args. 12342 set dummy $tool_basename; ac_word=$2 12343 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12344 $as_echo_n "checking for $ac_word... " >&6; } 12345 if ${ac_cv_path_XARGS+:} false; then : 12346 $as_echo_n "(cached) " >&6 12347 else 12348 case $XARGS in 12349 [\\/]* | ?:[\\/]*) 12350 ac_cv_path_XARGS="$XARGS" # Let the user override the test with a path. 12351 ;; 12352 *) 12353 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12354 for as_dir in $PATH 12355 do 12356 IFS=$as_save_IFS 12357 test -z "$as_dir" && as_dir=. 12358 for ac_exec_ext in '' $ac_executable_extensions; do 12359 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12360 ac_cv_path_XARGS="$as_dir/$ac_word$ac_exec_ext" 12361 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12362 break 2 12363 fi 12364 done 12365 done 12366 IFS=$as_save_IFS 12367 12368 ;; 12369 esac 12370 fi 12371 XARGS=$ac_cv_path_XARGS 12372 if test -n "$XARGS"; then 12373 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XARGS" >&5 12374 $as_echo "$XARGS" >&6; } 12375 else 12376 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12377 $as_echo "no" >&6; } 12378 fi 12379 12380 12381 if test "x$XARGS" = x; then 12382 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 12383 fi 12384 else 12385 # Otherwise we believe it is a complete path. Use it as it is. 12386 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool XARGS=$tool_specified" >&5 12387 $as_echo "$as_me: Will use user supplied tool XARGS=$tool_specified" >&6;} 12388 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XARGS" >&5 12389 $as_echo_n "checking for XARGS... " >&6; } 12390 if test ! -x "$tool_specified"; then 12391 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 12392 $as_echo "not found" >&6; } 12393 as_fn_error $? "User supplied tool XARGS=$tool_specified does not exist or is not executable" "$LINENO" 5 12394 fi 12395 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 12396 $as_echo "$tool_specified" >&6; } 12397 fi 12398 fi 12399 fi 12400 12401 fi 12402 12403 12404 12405 if test "x$XARGS" = x; then 12406 as_fn_error $? "Could not find required tool for XARGS" "$LINENO" 5 12407 fi 12408 12409 12410 12411 # Then required tools that require some special treatment. 12412 12413 12414 # Publish this variable in the help. 12415 12416 12417 if [ -z "${AWK+x}" ]; then 12418 # The variable is not set by user, try to locate tool using the code snippet 12419 for ac_prog in gawk mawk nawk awk 12420 do 12421 # Extract the first word of "$ac_prog", so it can be a program name with args. 12422 set dummy $ac_prog; ac_word=$2 12423 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12424 $as_echo_n "checking for $ac_word... " >&6; } 12425 if ${ac_cv_prog_AWK+:} false; then : 12426 $as_echo_n "(cached) " >&6 12427 else 12428 if test -n "$AWK"; then 12429 ac_cv_prog_AWK="$AWK" # Let the user override the test. 12430 else 12431 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12432 for as_dir in $PATH 12433 do 12434 IFS=$as_save_IFS 12435 test -z "$as_dir" && as_dir=. 12436 for ac_exec_ext in '' $ac_executable_extensions; do 12437 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12438 ac_cv_prog_AWK="$ac_prog" 12439 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12440 break 2 12441 fi 12442 done 12443 done 12444 IFS=$as_save_IFS 12445 12446 fi 12447 fi 12448 AWK=$ac_cv_prog_AWK 12449 if test -n "$AWK"; then 12450 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 12451 $as_echo "$AWK" >&6; } 12452 else 12453 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12454 $as_echo "no" >&6; } 12455 fi 12456 12457 12458 test -n "$AWK" && break 12459 done 12460 12461 else 12462 # The variable is set, but is it from the command line or the environment? 12463 12464 # Try to remove the string !AWK! from our list. 12465 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AWK!/} 12466 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 12467 # If it failed, the variable was not from the command line. Ignore it, 12468 # but warn the user (except for BASH, which is always set by the calling BASH). 12469 if test "xAWK" != xBASH; then 12470 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AWK from the environment. Use command line variables instead." >&5 12471 $as_echo "$as_me: WARNING: Ignoring value of AWK from the environment. Use command line variables instead." >&2;} 12472 fi 12473 # Try to locate tool using the code snippet 12474 for ac_prog in gawk mawk nawk awk 12475 do 12476 # Extract the first word of "$ac_prog", so it can be a program name with args. 12477 set dummy $ac_prog; ac_word=$2 12478 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12479 $as_echo_n "checking for $ac_word... " >&6; } 12480 if ${ac_cv_prog_AWK+:} false; then : 12481 $as_echo_n "(cached) " >&6 12482 else 12483 if test -n "$AWK"; then 12484 ac_cv_prog_AWK="$AWK" # Let the user override the test. 12485 else 12486 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12487 for as_dir in $PATH 12488 do 12489 IFS=$as_save_IFS 12490 test -z "$as_dir" && as_dir=. 12491 for ac_exec_ext in '' $ac_executable_extensions; do 12492 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12493 ac_cv_prog_AWK="$ac_prog" 12494 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12495 break 2 12496 fi 12497 done 12498 done 12499 IFS=$as_save_IFS 12500 12501 fi 12502 fi 12503 AWK=$ac_cv_prog_AWK 12504 if test -n "$AWK"; then 12505 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 12506 $as_echo "$AWK" >&6; } 12507 else 12508 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12509 $as_echo "no" >&6; } 12510 fi 12511 12512 12513 test -n "$AWK" && break 12514 done 12515 12516 else 12517 # If it succeeded, then it was overridden by the user. We will use it 12518 # for the tool. 12519 12520 # First remove it from the list of overridden variables, so we can test 12521 # for unknown variables in the end. 12522 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 12523 12524 # Check if we try to supply an empty value 12525 if test "x$AWK" = x; then 12526 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool AWK= (no value)" >&5 12527 $as_echo "$as_me: Setting user supplied tool AWK= (no value)" >&6;} 12528 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AWK" >&5 12529 $as_echo_n "checking for AWK... " >&6; } 12530 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 12531 $as_echo "disabled" >&6; } 12532 else 12533 # Check if the provided tool contains a complete path. 12534 tool_specified="$AWK" 12535 tool_basename="${tool_specified##*/}" 12536 if test "x$tool_basename" = "x$tool_specified"; then 12537 # A command without a complete path is provided, search $PATH. 12538 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AWK=$tool_basename" >&5 12539 $as_echo "$as_me: Will search for user supplied tool AWK=$tool_basename" >&6;} 12540 # Extract the first word of "$tool_basename", so it can be a program name with args. 12541 set dummy $tool_basename; ac_word=$2 12542 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12543 $as_echo_n "checking for $ac_word... " >&6; } 12544 if ${ac_cv_path_AWK+:} false; then : 12545 $as_echo_n "(cached) " >&6 12546 else 12547 case $AWK in 12548 [\\/]* | ?:[\\/]*) 12549 ac_cv_path_AWK="$AWK" # Let the user override the test with a path. 12550 ;; 12551 *) 12552 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12553 for as_dir in $PATH 12554 do 12555 IFS=$as_save_IFS 12556 test -z "$as_dir" && as_dir=. 12557 for ac_exec_ext in '' $ac_executable_extensions; do 12558 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12559 ac_cv_path_AWK="$as_dir/$ac_word$ac_exec_ext" 12560 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12561 break 2 12562 fi 12563 done 12564 done 12565 IFS=$as_save_IFS 12566 12567 ;; 12568 esac 12569 fi 12570 AWK=$ac_cv_path_AWK 12571 if test -n "$AWK"; then 12572 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AWK" >&5 12573 $as_echo "$AWK" >&6; } 12574 else 12575 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12576 $as_echo "no" >&6; } 12577 fi 12578 12579 12580 if test "x$AWK" = x; then 12581 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 12582 fi 12583 else 12584 # Otherwise we believe it is a complete path. Use it as it is. 12585 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AWK=$tool_specified" >&5 12586 $as_echo "$as_me: Will use user supplied tool AWK=$tool_specified" >&6;} 12587 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AWK" >&5 12588 $as_echo_n "checking for AWK... " >&6; } 12589 if test ! -x "$tool_specified"; then 12590 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 12591 $as_echo "not found" >&6; } 12592 as_fn_error $? "User supplied tool AWK=$tool_specified does not exist or is not executable" "$LINENO" 5 12593 fi 12594 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 12595 $as_echo "$tool_specified" >&6; } 12596 fi 12597 fi 12598 fi 12599 12600 fi 12601 12602 12603 if test "x$AWK" = x; then 12604 as_fn_error $? "Could not find required tool for AWK" "$LINENO" 5 12605 fi 12606 12607 12608 12609 12610 # Publish this variable in the help. 12611 12612 12613 if [ -z "${GREP+x}" ]; then 12614 # The variable is not set by user, try to locate tool using the code snippet 12615 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 12616 $as_echo_n "checking for grep that handles long lines and -e... " >&6; } 12617 if ${ac_cv_path_GREP+:} false; then : 12618 $as_echo_n "(cached) " >&6 12619 else 12620 if test -z "$GREP"; then 12621 ac_path_GREP_found=false 12622 # Loop through the user's path and test for each of PROGNAME-LIST 12623 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12624 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 12625 do 12626 IFS=$as_save_IFS 12627 test -z "$as_dir" && as_dir=. 12628 for ac_prog in grep ggrep; do 12629 for ac_exec_ext in '' $ac_executable_extensions; do 12630 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" 12631 as_fn_executable_p "$ac_path_GREP" || continue 12632 # Check for GNU ac_path_GREP and select it if it is found. 12633 # Check for GNU $ac_path_GREP 12634 case `"$ac_path_GREP" --version 2>&1` in 12635 *GNU*) 12636 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; 12637 *) 12638 ac_count=0 12639 $as_echo_n 0123456789 >"conftest.in" 12640 while : 12641 do 12642 cat "conftest.in" "conftest.in" >"conftest.tmp" 12643 mv "conftest.tmp" "conftest.in" 12644 cp "conftest.in" "conftest.nl" 12645 $as_echo 'GREP' >> "conftest.nl" 12646 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break 12647 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 12648 as_fn_arith $ac_count + 1 && ac_count=$as_val 12649 if test $ac_count -gt ${ac_path_GREP_max-0}; then 12650 # Best one so far, save it but keep looking for a better one 12651 ac_cv_path_GREP="$ac_path_GREP" 12652 ac_path_GREP_max=$ac_count 12653 fi 12654 # 10*(2^10) chars as input seems more than enough 12655 test $ac_count -gt 10 && break 12656 done 12657 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 12658 esac 12659 12660 $ac_path_GREP_found && break 3 12661 done 12662 done 12663 done 12664 IFS=$as_save_IFS 12665 if test -z "$ac_cv_path_GREP"; then 12666 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 12667 fi 12668 else 12669 ac_cv_path_GREP=$GREP 12670 fi 12671 12672 fi 12673 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 12674 $as_echo "$ac_cv_path_GREP" >&6; } 12675 GREP="$ac_cv_path_GREP" 12676 12677 12678 else 12679 # The variable is set, but is it from the command line or the environment? 12680 12681 # Try to remove the string !GREP! from our list. 12682 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!GREP!/} 12683 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 12684 # If it failed, the variable was not from the command line. Ignore it, 12685 # but warn the user (except for BASH, which is always set by the calling BASH). 12686 if test "xGREP" != xBASH; then 12687 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of GREP from the environment. Use command line variables instead." >&5 12688 $as_echo "$as_me: WARNING: Ignoring value of GREP from the environment. Use command line variables instead." >&2;} 12689 fi 12690 # Try to locate tool using the code snippet 12691 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for grep that handles long lines and -e" >&5 12692 $as_echo_n "checking for grep that handles long lines and -e... " >&6; } 12693 if ${ac_cv_path_GREP+:} false; then : 12694 $as_echo_n "(cached) " >&6 12695 else 12696 if test -z "$GREP"; then 12697 ac_path_GREP_found=false 12698 # Loop through the user's path and test for each of PROGNAME-LIST 12699 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12700 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 12701 do 12702 IFS=$as_save_IFS 12703 test -z "$as_dir" && as_dir=. 12704 for ac_prog in grep ggrep; do 12705 for ac_exec_ext in '' $ac_executable_extensions; do 12706 ac_path_GREP="$as_dir/$ac_prog$ac_exec_ext" 12707 as_fn_executable_p "$ac_path_GREP" || continue 12708 # Check for GNU ac_path_GREP and select it if it is found. 12709 # Check for GNU $ac_path_GREP 12710 case `"$ac_path_GREP" --version 2>&1` in 12711 *GNU*) 12712 ac_cv_path_GREP="$ac_path_GREP" ac_path_GREP_found=:;; 12713 *) 12714 ac_count=0 12715 $as_echo_n 0123456789 >"conftest.in" 12716 while : 12717 do 12718 cat "conftest.in" "conftest.in" >"conftest.tmp" 12719 mv "conftest.tmp" "conftest.in" 12720 cp "conftest.in" "conftest.nl" 12721 $as_echo 'GREP' >> "conftest.nl" 12722 "$ac_path_GREP" -e 'GREP$' -e '-(cannot match)-' < "conftest.nl" >"conftest.out" 2>/dev/null || break 12723 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 12724 as_fn_arith $ac_count + 1 && ac_count=$as_val 12725 if test $ac_count -gt ${ac_path_GREP_max-0}; then 12726 # Best one so far, save it but keep looking for a better one 12727 ac_cv_path_GREP="$ac_path_GREP" 12728 ac_path_GREP_max=$ac_count 12729 fi 12730 # 10*(2^10) chars as input seems more than enough 12731 test $ac_count -gt 10 && break 12732 done 12733 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 12734 esac 12735 12736 $ac_path_GREP_found && break 3 12737 done 12738 done 12739 done 12740 IFS=$as_save_IFS 12741 if test -z "$ac_cv_path_GREP"; then 12742 as_fn_error $? "no acceptable grep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 12743 fi 12744 else 12745 ac_cv_path_GREP=$GREP 12746 fi 12747 12748 fi 12749 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_GREP" >&5 12750 $as_echo "$ac_cv_path_GREP" >&6; } 12751 GREP="$ac_cv_path_GREP" 12752 12753 12754 else 12755 # If it succeeded, then it was overridden by the user. We will use it 12756 # for the tool. 12757 12758 # First remove it from the list of overridden variables, so we can test 12759 # for unknown variables in the end. 12760 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 12761 12762 # Check if we try to supply an empty value 12763 if test "x$GREP" = x; then 12764 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool GREP= (no value)" >&5 12765 $as_echo "$as_me: Setting user supplied tool GREP= (no value)" >&6;} 12766 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GREP" >&5 12767 $as_echo_n "checking for GREP... " >&6; } 12768 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 12769 $as_echo "disabled" >&6; } 12770 else 12771 # Check if the provided tool contains a complete path. 12772 tool_specified="$GREP" 12773 tool_basename="${tool_specified##*/}" 12774 if test "x$tool_basename" = "x$tool_specified"; then 12775 # A command without a complete path is provided, search $PATH. 12776 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool GREP=$tool_basename" >&5 12777 $as_echo "$as_me: Will search for user supplied tool GREP=$tool_basename" >&6;} 12778 # Extract the first word of "$tool_basename", so it can be a program name with args. 12779 set dummy $tool_basename; ac_word=$2 12780 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 12781 $as_echo_n "checking for $ac_word... " >&6; } 12782 if ${ac_cv_path_GREP+:} false; then : 12783 $as_echo_n "(cached) " >&6 12784 else 12785 case $GREP in 12786 [\\/]* | ?:[\\/]*) 12787 ac_cv_path_GREP="$GREP" # Let the user override the test with a path. 12788 ;; 12789 *) 12790 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12791 for as_dir in $PATH 12792 do 12793 IFS=$as_save_IFS 12794 test -z "$as_dir" && as_dir=. 12795 for ac_exec_ext in '' $ac_executable_extensions; do 12796 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 12797 ac_cv_path_GREP="$as_dir/$ac_word$ac_exec_ext" 12798 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 12799 break 2 12800 fi 12801 done 12802 done 12803 IFS=$as_save_IFS 12804 12805 ;; 12806 esac 12807 fi 12808 GREP=$ac_cv_path_GREP 12809 if test -n "$GREP"; then 12810 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GREP" >&5 12811 $as_echo "$GREP" >&6; } 12812 else 12813 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 12814 $as_echo "no" >&6; } 12815 fi 12816 12817 12818 if test "x$GREP" = x; then 12819 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 12820 fi 12821 else 12822 # Otherwise we believe it is a complete path. Use it as it is. 12823 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool GREP=$tool_specified" >&5 12824 $as_echo "$as_me: Will use user supplied tool GREP=$tool_specified" >&6;} 12825 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GREP" >&5 12826 $as_echo_n "checking for GREP... " >&6; } 12827 if test ! -x "$tool_specified"; then 12828 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 12829 $as_echo "not found" >&6; } 12830 as_fn_error $? "User supplied tool GREP=$tool_specified does not exist or is not executable" "$LINENO" 5 12831 fi 12832 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 12833 $as_echo "$tool_specified" >&6; } 12834 fi 12835 fi 12836 fi 12837 12838 fi 12839 12840 12841 if test "x$GREP" = x; then 12842 as_fn_error $? "Could not find required tool for GREP" "$LINENO" 5 12843 fi 12844 12845 12846 12847 12848 # Publish this variable in the help. 12849 12850 12851 if [ -z "${EGREP+x}" ]; then 12852 # The variable is not set by user, try to locate tool using the code snippet 12853 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 12854 $as_echo_n "checking for egrep... " >&6; } 12855 if ${ac_cv_path_EGREP+:} false; then : 12856 $as_echo_n "(cached) " >&6 12857 else 12858 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 12859 then ac_cv_path_EGREP="$GREP -E" 12860 else 12861 if test -z "$EGREP"; then 12862 ac_path_EGREP_found=false 12863 # Loop through the user's path and test for each of PROGNAME-LIST 12864 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12865 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 12866 do 12867 IFS=$as_save_IFS 12868 test -z "$as_dir" && as_dir=. 12869 for ac_prog in egrep; do 12870 for ac_exec_ext in '' $ac_executable_extensions; do 12871 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" 12872 as_fn_executable_p "$ac_path_EGREP" || continue 12873 # Check for GNU ac_path_EGREP and select it if it is found. 12874 # Check for GNU $ac_path_EGREP 12875 case `"$ac_path_EGREP" --version 2>&1` in 12876 *GNU*) 12877 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; 12878 *) 12879 ac_count=0 12880 $as_echo_n 0123456789 >"conftest.in" 12881 while : 12882 do 12883 cat "conftest.in" "conftest.in" >"conftest.tmp" 12884 mv "conftest.tmp" "conftest.in" 12885 cp "conftest.in" "conftest.nl" 12886 $as_echo 'EGREP' >> "conftest.nl" 12887 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break 12888 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 12889 as_fn_arith $ac_count + 1 && ac_count=$as_val 12890 if test $ac_count -gt ${ac_path_EGREP_max-0}; then 12891 # Best one so far, save it but keep looking for a better one 12892 ac_cv_path_EGREP="$ac_path_EGREP" 12893 ac_path_EGREP_max=$ac_count 12894 fi 12895 # 10*(2^10) chars as input seems more than enough 12896 test $ac_count -gt 10 && break 12897 done 12898 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 12899 esac 12900 12901 $ac_path_EGREP_found && break 3 12902 done 12903 done 12904 done 12905 IFS=$as_save_IFS 12906 if test -z "$ac_cv_path_EGREP"; then 12907 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 12908 fi 12909 else 12910 ac_cv_path_EGREP=$EGREP 12911 fi 12912 12913 fi 12914 fi 12915 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 12916 $as_echo "$ac_cv_path_EGREP" >&6; } 12917 EGREP="$ac_cv_path_EGREP" 12918 12919 12920 else 12921 # The variable is set, but is it from the command line or the environment? 12922 12923 # Try to remove the string !EGREP! from our list. 12924 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!EGREP!/} 12925 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 12926 # If it failed, the variable was not from the command line. Ignore it, 12927 # but warn the user (except for BASH, which is always set by the calling BASH). 12928 if test "xEGREP" != xBASH; then 12929 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of EGREP from the environment. Use command line variables instead." >&5 12930 $as_echo "$as_me: WARNING: Ignoring value of EGREP from the environment. Use command line variables instead." >&2;} 12931 fi 12932 # Try to locate tool using the code snippet 12933 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for egrep" >&5 12934 $as_echo_n "checking for egrep... " >&6; } 12935 if ${ac_cv_path_EGREP+:} false; then : 12936 $as_echo_n "(cached) " >&6 12937 else 12938 if echo a | $GREP -E '(a|b)' >/dev/null 2>&1 12939 then ac_cv_path_EGREP="$GREP -E" 12940 else 12941 if test -z "$EGREP"; then 12942 ac_path_EGREP_found=false 12943 # Loop through the user's path and test for each of PROGNAME-LIST 12944 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 12945 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 12946 do 12947 IFS=$as_save_IFS 12948 test -z "$as_dir" && as_dir=. 12949 for ac_prog in egrep; do 12950 for ac_exec_ext in '' $ac_executable_extensions; do 12951 ac_path_EGREP="$as_dir/$ac_prog$ac_exec_ext" 12952 as_fn_executable_p "$ac_path_EGREP" || continue 12953 # Check for GNU ac_path_EGREP and select it if it is found. 12954 # Check for GNU $ac_path_EGREP 12955 case `"$ac_path_EGREP" --version 2>&1` in 12956 *GNU*) 12957 ac_cv_path_EGREP="$ac_path_EGREP" ac_path_EGREP_found=:;; 12958 *) 12959 ac_count=0 12960 $as_echo_n 0123456789 >"conftest.in" 12961 while : 12962 do 12963 cat "conftest.in" "conftest.in" >"conftest.tmp" 12964 mv "conftest.tmp" "conftest.in" 12965 cp "conftest.in" "conftest.nl" 12966 $as_echo 'EGREP' >> "conftest.nl" 12967 "$ac_path_EGREP" 'EGREP$' < "conftest.nl" >"conftest.out" 2>/dev/null || break 12968 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 12969 as_fn_arith $ac_count + 1 && ac_count=$as_val 12970 if test $ac_count -gt ${ac_path_EGREP_max-0}; then 12971 # Best one so far, save it but keep looking for a better one 12972 ac_cv_path_EGREP="$ac_path_EGREP" 12973 ac_path_EGREP_max=$ac_count 12974 fi 12975 # 10*(2^10) chars as input seems more than enough 12976 test $ac_count -gt 10 && break 12977 done 12978 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 12979 esac 12980 12981 $ac_path_EGREP_found && break 3 12982 done 12983 done 12984 done 12985 IFS=$as_save_IFS 12986 if test -z "$ac_cv_path_EGREP"; then 12987 as_fn_error $? "no acceptable egrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 12988 fi 12989 else 12990 ac_cv_path_EGREP=$EGREP 12991 fi 12992 12993 fi 12994 fi 12995 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_EGREP" >&5 12996 $as_echo "$ac_cv_path_EGREP" >&6; } 12997 EGREP="$ac_cv_path_EGREP" 12998 12999 13000 else 13001 # If it succeeded, then it was overridden by the user. We will use it 13002 # for the tool. 13003 13004 # First remove it from the list of overridden variables, so we can test 13005 # for unknown variables in the end. 13006 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 13007 13008 # Check if we try to supply an empty value 13009 if test "x$EGREP" = x; then 13010 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool EGREP= (no value)" >&5 13011 $as_echo "$as_me: Setting user supplied tool EGREP= (no value)" >&6;} 13012 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGREP" >&5 13013 $as_echo_n "checking for EGREP... " >&6; } 13014 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 13015 $as_echo "disabled" >&6; } 13016 else 13017 # Check if the provided tool contains a complete path. 13018 tool_specified="$EGREP" 13019 tool_basename="${tool_specified##*/}" 13020 if test "x$tool_basename" = "x$tool_specified"; then 13021 # A command without a complete path is provided, search $PATH. 13022 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool EGREP=$tool_basename" >&5 13023 $as_echo "$as_me: Will search for user supplied tool EGREP=$tool_basename" >&6;} 13024 # Extract the first word of "$tool_basename", so it can be a program name with args. 13025 set dummy $tool_basename; ac_word=$2 13026 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13027 $as_echo_n "checking for $ac_word... " >&6; } 13028 if ${ac_cv_path_EGREP+:} false; then : 13029 $as_echo_n "(cached) " >&6 13030 else 13031 case $EGREP in 13032 [\\/]* | ?:[\\/]*) 13033 ac_cv_path_EGREP="$EGREP" # Let the user override the test with a path. 13034 ;; 13035 *) 13036 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13037 for as_dir in $PATH 13038 do 13039 IFS=$as_save_IFS 13040 test -z "$as_dir" && as_dir=. 13041 for ac_exec_ext in '' $ac_executable_extensions; do 13042 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13043 ac_cv_path_EGREP="$as_dir/$ac_word$ac_exec_ext" 13044 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13045 break 2 13046 fi 13047 done 13048 done 13049 IFS=$as_save_IFS 13050 13051 ;; 13052 esac 13053 fi 13054 EGREP=$ac_cv_path_EGREP 13055 if test -n "$EGREP"; then 13056 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EGREP" >&5 13057 $as_echo "$EGREP" >&6; } 13058 else 13059 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13060 $as_echo "no" >&6; } 13061 fi 13062 13063 13064 if test "x$EGREP" = x; then 13065 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 13066 fi 13067 else 13068 # Otherwise we believe it is a complete path. Use it as it is. 13069 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool EGREP=$tool_specified" >&5 13070 $as_echo "$as_me: Will use user supplied tool EGREP=$tool_specified" >&6;} 13071 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for EGREP" >&5 13072 $as_echo_n "checking for EGREP... " >&6; } 13073 if test ! -x "$tool_specified"; then 13074 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 13075 $as_echo "not found" >&6; } 13076 as_fn_error $? "User supplied tool EGREP=$tool_specified does not exist or is not executable" "$LINENO" 5 13077 fi 13078 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 13079 $as_echo "$tool_specified" >&6; } 13080 fi 13081 fi 13082 fi 13083 13084 fi 13085 13086 13087 if test "x$EGREP" = x; then 13088 as_fn_error $? "Could not find required tool for EGREP" "$LINENO" 5 13089 fi 13090 13091 13092 13093 13094 # Publish this variable in the help. 13095 13096 13097 if [ -z "${FGREP+x}" ]; then 13098 # The variable is not set by user, try to locate tool using the code snippet 13099 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5 13100 $as_echo_n "checking for fgrep... " >&6; } 13101 if ${ac_cv_path_FGREP+:} false; then : 13102 $as_echo_n "(cached) " >&6 13103 else 13104 if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1 13105 then ac_cv_path_FGREP="$GREP -F" 13106 else 13107 if test -z "$FGREP"; then 13108 ac_path_FGREP_found=false 13109 # Loop through the user's path and test for each of PROGNAME-LIST 13110 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13111 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13112 do 13113 IFS=$as_save_IFS 13114 test -z "$as_dir" && as_dir=. 13115 for ac_prog in fgrep; do 13116 for ac_exec_ext in '' $ac_executable_extensions; do 13117 ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext" 13118 as_fn_executable_p "$ac_path_FGREP" || continue 13119 # Check for GNU ac_path_FGREP and select it if it is found. 13120 # Check for GNU $ac_path_FGREP 13121 case `"$ac_path_FGREP" --version 2>&1` in 13122 *GNU*) 13123 ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;; 13124 *) 13125 ac_count=0 13126 $as_echo_n 0123456789 >"conftest.in" 13127 while : 13128 do 13129 cat "conftest.in" "conftest.in" >"conftest.tmp" 13130 mv "conftest.tmp" "conftest.in" 13131 cp "conftest.in" "conftest.nl" 13132 $as_echo 'FGREP' >> "conftest.nl" 13133 "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break 13134 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13135 as_fn_arith $ac_count + 1 && ac_count=$as_val 13136 if test $ac_count -gt ${ac_path_FGREP_max-0}; then 13137 # Best one so far, save it but keep looking for a better one 13138 ac_cv_path_FGREP="$ac_path_FGREP" 13139 ac_path_FGREP_max=$ac_count 13140 fi 13141 # 10*(2^10) chars as input seems more than enough 13142 test $ac_count -gt 10 && break 13143 done 13144 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13145 esac 13146 13147 $ac_path_FGREP_found && break 3 13148 done 13149 done 13150 done 13151 IFS=$as_save_IFS 13152 if test -z "$ac_cv_path_FGREP"; then 13153 as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13154 fi 13155 else 13156 ac_cv_path_FGREP=$FGREP 13157 fi 13158 13159 fi 13160 fi 13161 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5 13162 $as_echo "$ac_cv_path_FGREP" >&6; } 13163 FGREP="$ac_cv_path_FGREP" 13164 13165 13166 else 13167 # The variable is set, but is it from the command line or the environment? 13168 13169 # Try to remove the string !FGREP! from our list. 13170 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!FGREP!/} 13171 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 13172 # If it failed, the variable was not from the command line. Ignore it, 13173 # but warn the user (except for BASH, which is always set by the calling BASH). 13174 if test "xFGREP" != xBASH; then 13175 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of FGREP from the environment. Use command line variables instead." >&5 13176 $as_echo "$as_me: WARNING: Ignoring value of FGREP from the environment. Use command line variables instead." >&2;} 13177 fi 13178 # Try to locate tool using the code snippet 13179 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for fgrep" >&5 13180 $as_echo_n "checking for fgrep... " >&6; } 13181 if ${ac_cv_path_FGREP+:} false; then : 13182 $as_echo_n "(cached) " >&6 13183 else 13184 if echo 'ab*c' | $GREP -F 'ab*c' >/dev/null 2>&1 13185 then ac_cv_path_FGREP="$GREP -F" 13186 else 13187 if test -z "$FGREP"; then 13188 ac_path_FGREP_found=false 13189 # Loop through the user's path and test for each of PROGNAME-LIST 13190 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13191 for as_dir in $PATH$PATH_SEPARATOR/usr/xpg4/bin 13192 do 13193 IFS=$as_save_IFS 13194 test -z "$as_dir" && as_dir=. 13195 for ac_prog in fgrep; do 13196 for ac_exec_ext in '' $ac_executable_extensions; do 13197 ac_path_FGREP="$as_dir/$ac_prog$ac_exec_ext" 13198 as_fn_executable_p "$ac_path_FGREP" || continue 13199 # Check for GNU ac_path_FGREP and select it if it is found. 13200 # Check for GNU $ac_path_FGREP 13201 case `"$ac_path_FGREP" --version 2>&1` in 13202 *GNU*) 13203 ac_cv_path_FGREP="$ac_path_FGREP" ac_path_FGREP_found=:;; 13204 *) 13205 ac_count=0 13206 $as_echo_n 0123456789 >"conftest.in" 13207 while : 13208 do 13209 cat "conftest.in" "conftest.in" >"conftest.tmp" 13210 mv "conftest.tmp" "conftest.in" 13211 cp "conftest.in" "conftest.nl" 13212 $as_echo 'FGREP' >> "conftest.nl" 13213 "$ac_path_FGREP" FGREP < "conftest.nl" >"conftest.out" 2>/dev/null || break 13214 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13215 as_fn_arith $ac_count + 1 && ac_count=$as_val 13216 if test $ac_count -gt ${ac_path_FGREP_max-0}; then 13217 # Best one so far, save it but keep looking for a better one 13218 ac_cv_path_FGREP="$ac_path_FGREP" 13219 ac_path_FGREP_max=$ac_count 13220 fi 13221 # 10*(2^10) chars as input seems more than enough 13222 test $ac_count -gt 10 && break 13223 done 13224 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13225 esac 13226 13227 $ac_path_FGREP_found && break 3 13228 done 13229 done 13230 done 13231 IFS=$as_save_IFS 13232 if test -z "$ac_cv_path_FGREP"; then 13233 as_fn_error $? "no acceptable fgrep could be found in $PATH$PATH_SEPARATOR/usr/xpg4/bin" "$LINENO" 5 13234 fi 13235 else 13236 ac_cv_path_FGREP=$FGREP 13237 fi 13238 13239 fi 13240 fi 13241 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_FGREP" >&5 13242 $as_echo "$ac_cv_path_FGREP" >&6; } 13243 FGREP="$ac_cv_path_FGREP" 13244 13245 13246 else 13247 # If it succeeded, then it was overridden by the user. We will use it 13248 # for the tool. 13249 13250 # First remove it from the list of overridden variables, so we can test 13251 # for unknown variables in the end. 13252 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 13253 13254 # Check if we try to supply an empty value 13255 if test "x$FGREP" = x; then 13256 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool FGREP= (no value)" >&5 13257 $as_echo "$as_me: Setting user supplied tool FGREP= (no value)" >&6;} 13258 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FGREP" >&5 13259 $as_echo_n "checking for FGREP... " >&6; } 13260 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 13261 $as_echo "disabled" >&6; } 13262 else 13263 # Check if the provided tool contains a complete path. 13264 tool_specified="$FGREP" 13265 tool_basename="${tool_specified##*/}" 13266 if test "x$tool_basename" = "x$tool_specified"; then 13267 # A command without a complete path is provided, search $PATH. 13268 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool FGREP=$tool_basename" >&5 13269 $as_echo "$as_me: Will search for user supplied tool FGREP=$tool_basename" >&6;} 13270 # Extract the first word of "$tool_basename", so it can be a program name with args. 13271 set dummy $tool_basename; ac_word=$2 13272 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13273 $as_echo_n "checking for $ac_word... " >&6; } 13274 if ${ac_cv_path_FGREP+:} false; then : 13275 $as_echo_n "(cached) " >&6 13276 else 13277 case $FGREP in 13278 [\\/]* | ?:[\\/]*) 13279 ac_cv_path_FGREP="$FGREP" # Let the user override the test with a path. 13280 ;; 13281 *) 13282 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13283 for as_dir in $PATH 13284 do 13285 IFS=$as_save_IFS 13286 test -z "$as_dir" && as_dir=. 13287 for ac_exec_ext in '' $ac_executable_extensions; do 13288 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13289 ac_cv_path_FGREP="$as_dir/$ac_word$ac_exec_ext" 13290 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13291 break 2 13292 fi 13293 done 13294 done 13295 IFS=$as_save_IFS 13296 13297 ;; 13298 esac 13299 fi 13300 FGREP=$ac_cv_path_FGREP 13301 if test -n "$FGREP"; then 13302 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FGREP" >&5 13303 $as_echo "$FGREP" >&6; } 13304 else 13305 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13306 $as_echo "no" >&6; } 13307 fi 13308 13309 13310 if test "x$FGREP" = x; then 13311 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 13312 fi 13313 else 13314 # Otherwise we believe it is a complete path. Use it as it is. 13315 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool FGREP=$tool_specified" >&5 13316 $as_echo "$as_me: Will use user supplied tool FGREP=$tool_specified" >&6;} 13317 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FGREP" >&5 13318 $as_echo_n "checking for FGREP... " >&6; } 13319 if test ! -x "$tool_specified"; then 13320 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 13321 $as_echo "not found" >&6; } 13322 as_fn_error $? "User supplied tool FGREP=$tool_specified does not exist or is not executable" "$LINENO" 5 13323 fi 13324 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 13325 $as_echo "$tool_specified" >&6; } 13326 fi 13327 fi 13328 fi 13329 13330 fi 13331 13332 13333 if test "x$FGREP" = x; then 13334 as_fn_error $? "Could not find required tool for FGREP" "$LINENO" 5 13335 fi 13336 13337 13338 13339 13340 # Publish this variable in the help. 13341 13342 13343 if [ -z "${SED+x}" ]; then 13344 # The variable is not set by user, try to locate tool using the code snippet 13345 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 13346 $as_echo_n "checking for a sed that does not truncate output... " >&6; } 13347 if ${ac_cv_path_SED+:} false; then : 13348 $as_echo_n "(cached) " >&6 13349 else 13350 ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ 13351 for ac_i in 1 2 3 4 5 6 7; do 13352 ac_script="$ac_script$as_nl$ac_script" 13353 done 13354 echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed 13355 { ac_script=; unset ac_script;} 13356 if test -z "$SED"; then 13357 ac_path_SED_found=false 13358 # Loop through the user's path and test for each of PROGNAME-LIST 13359 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13360 for as_dir in $PATH 13361 do 13362 IFS=$as_save_IFS 13363 test -z "$as_dir" && as_dir=. 13364 for ac_prog in sed gsed; do 13365 for ac_exec_ext in '' $ac_executable_extensions; do 13366 ac_path_SED="$as_dir/$ac_prog$ac_exec_ext" 13367 as_fn_executable_p "$ac_path_SED" || continue 13368 # Check for GNU ac_path_SED and select it if it is found. 13369 # Check for GNU $ac_path_SED 13370 case `"$ac_path_SED" --version 2>&1` in 13371 *GNU*) 13372 ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;; 13373 *) 13374 ac_count=0 13375 $as_echo_n 0123456789 >"conftest.in" 13376 while : 13377 do 13378 cat "conftest.in" "conftest.in" >"conftest.tmp" 13379 mv "conftest.tmp" "conftest.in" 13380 cp "conftest.in" "conftest.nl" 13381 $as_echo '' >> "conftest.nl" 13382 "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break 13383 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13384 as_fn_arith $ac_count + 1 && ac_count=$as_val 13385 if test $ac_count -gt ${ac_path_SED_max-0}; then 13386 # Best one so far, save it but keep looking for a better one 13387 ac_cv_path_SED="$ac_path_SED" 13388 ac_path_SED_max=$ac_count 13389 fi 13390 # 10*(2^10) chars as input seems more than enough 13391 test $ac_count -gt 10 && break 13392 done 13393 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13394 esac 13395 13396 $ac_path_SED_found && break 3 13397 done 13398 done 13399 done 13400 IFS=$as_save_IFS 13401 if test -z "$ac_cv_path_SED"; then 13402 as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5 13403 fi 13404 else 13405 ac_cv_path_SED=$SED 13406 fi 13407 13408 fi 13409 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5 13410 $as_echo "$ac_cv_path_SED" >&6; } 13411 SED="$ac_cv_path_SED" 13412 rm -f conftest.sed 13413 13414 else 13415 # The variable is set, but is it from the command line or the environment? 13416 13417 # Try to remove the string !SED! from our list. 13418 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SED!/} 13419 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 13420 # If it failed, the variable was not from the command line. Ignore it, 13421 # but warn the user (except for BASH, which is always set by the calling BASH). 13422 if test "xSED" != xBASH; then 13423 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SED from the environment. Use command line variables instead." >&5 13424 $as_echo "$as_me: WARNING: Ignoring value of SED from the environment. Use command line variables instead." >&2;} 13425 fi 13426 # Try to locate tool using the code snippet 13427 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a sed that does not truncate output" >&5 13428 $as_echo_n "checking for a sed that does not truncate output... " >&6; } 13429 if ${ac_cv_path_SED+:} false; then : 13430 $as_echo_n "(cached) " >&6 13431 else 13432 ac_script=s/aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/bbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbb/ 13433 for ac_i in 1 2 3 4 5 6 7; do 13434 ac_script="$ac_script$as_nl$ac_script" 13435 done 13436 echo "$ac_script" 2>/dev/null | sed 99q >conftest.sed 13437 { ac_script=; unset ac_script;} 13438 if test -z "$SED"; then 13439 ac_path_SED_found=false 13440 # Loop through the user's path and test for each of PROGNAME-LIST 13441 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13442 for as_dir in $PATH 13443 do 13444 IFS=$as_save_IFS 13445 test -z "$as_dir" && as_dir=. 13446 for ac_prog in sed gsed; do 13447 for ac_exec_ext in '' $ac_executable_extensions; do 13448 ac_path_SED="$as_dir/$ac_prog$ac_exec_ext" 13449 as_fn_executable_p "$ac_path_SED" || continue 13450 # Check for GNU ac_path_SED and select it if it is found. 13451 # Check for GNU $ac_path_SED 13452 case `"$ac_path_SED" --version 2>&1` in 13453 *GNU*) 13454 ac_cv_path_SED="$ac_path_SED" ac_path_SED_found=:;; 13455 *) 13456 ac_count=0 13457 $as_echo_n 0123456789 >"conftest.in" 13458 while : 13459 do 13460 cat "conftest.in" "conftest.in" >"conftest.tmp" 13461 mv "conftest.tmp" "conftest.in" 13462 cp "conftest.in" "conftest.nl" 13463 $as_echo '' >> "conftest.nl" 13464 "$ac_path_SED" -f conftest.sed < "conftest.nl" >"conftest.out" 2>/dev/null || break 13465 diff "conftest.out" "conftest.nl" >/dev/null 2>&1 || break 13466 as_fn_arith $ac_count + 1 && ac_count=$as_val 13467 if test $ac_count -gt ${ac_path_SED_max-0}; then 13468 # Best one so far, save it but keep looking for a better one 13469 ac_cv_path_SED="$ac_path_SED" 13470 ac_path_SED_max=$ac_count 13471 fi 13472 # 10*(2^10) chars as input seems more than enough 13473 test $ac_count -gt 10 && break 13474 done 13475 rm -f conftest.in conftest.tmp conftest.nl conftest.out;; 13476 esac 13477 13478 $ac_path_SED_found && break 3 13479 done 13480 done 13481 done 13482 IFS=$as_save_IFS 13483 if test -z "$ac_cv_path_SED"; then 13484 as_fn_error $? "no acceptable sed could be found in \$PATH" "$LINENO" 5 13485 fi 13486 else 13487 ac_cv_path_SED=$SED 13488 fi 13489 13490 fi 13491 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_path_SED" >&5 13492 $as_echo "$ac_cv_path_SED" >&6; } 13493 SED="$ac_cv_path_SED" 13494 rm -f conftest.sed 13495 13496 else 13497 # If it succeeded, then it was overridden by the user. We will use it 13498 # for the tool. 13499 13500 # First remove it from the list of overridden variables, so we can test 13501 # for unknown variables in the end. 13502 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 13503 13504 # Check if we try to supply an empty value 13505 if test "x$SED" = x; then 13506 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool SED= (no value)" >&5 13507 $as_echo "$as_me: Setting user supplied tool SED= (no value)" >&6;} 13508 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SED" >&5 13509 $as_echo_n "checking for SED... " >&6; } 13510 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 13511 $as_echo "disabled" >&6; } 13512 else 13513 # Check if the provided tool contains a complete path. 13514 tool_specified="$SED" 13515 tool_basename="${tool_specified##*/}" 13516 if test "x$tool_basename" = "x$tool_specified"; then 13517 # A command without a complete path is provided, search $PATH. 13518 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SED=$tool_basename" >&5 13519 $as_echo "$as_me: Will search for user supplied tool SED=$tool_basename" >&6;} 13520 # Extract the first word of "$tool_basename", so it can be a program name with args. 13521 set dummy $tool_basename; ac_word=$2 13522 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13523 $as_echo_n "checking for $ac_word... " >&6; } 13524 if ${ac_cv_path_SED+:} false; then : 13525 $as_echo_n "(cached) " >&6 13526 else 13527 case $SED in 13528 [\\/]* | ?:[\\/]*) 13529 ac_cv_path_SED="$SED" # Let the user override the test with a path. 13530 ;; 13531 *) 13532 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13533 for as_dir in $PATH 13534 do 13535 IFS=$as_save_IFS 13536 test -z "$as_dir" && as_dir=. 13537 for ac_exec_ext in '' $ac_executable_extensions; do 13538 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13539 ac_cv_path_SED="$as_dir/$ac_word$ac_exec_ext" 13540 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13541 break 2 13542 fi 13543 done 13544 done 13545 IFS=$as_save_IFS 13546 13547 ;; 13548 esac 13549 fi 13550 SED=$ac_cv_path_SED 13551 if test -n "$SED"; then 13552 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SED" >&5 13553 $as_echo "$SED" >&6; } 13554 else 13555 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13556 $as_echo "no" >&6; } 13557 fi 13558 13559 13560 if test "x$SED" = x; then 13561 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 13562 fi 13563 else 13564 # Otherwise we believe it is a complete path. Use it as it is. 13565 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SED=$tool_specified" >&5 13566 $as_echo "$as_me: Will use user supplied tool SED=$tool_specified" >&6;} 13567 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SED" >&5 13568 $as_echo_n "checking for SED... " >&6; } 13569 if test ! -x "$tool_specified"; then 13570 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 13571 $as_echo "not found" >&6; } 13572 as_fn_error $? "User supplied tool SED=$tool_specified does not exist or is not executable" "$LINENO" 5 13573 fi 13574 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 13575 $as_echo "$tool_specified" >&6; } 13576 fi 13577 fi 13578 fi 13579 13580 fi 13581 13582 13583 if test "x$SED" = x; then 13584 as_fn_error $? "Could not find required tool for SED" "$LINENO" 5 13585 fi 13586 13587 13588 13589 # Always force rm. 13590 RM="$RM -f" 13591 13592 # pwd behaves differently on various platforms and some don't support the -L flag. 13593 # Always use the bash builtin pwd to get uniform behavior. 13594 THEPWDCMD=pwd 13595 13596 # These are not required on all platforms 13597 13598 13599 # Publish this variable in the help. 13600 13601 13602 if [ -z "${CYGPATH+x}" ]; then 13603 # The variable is not set by user, try to locate tool using the code snippet 13604 for ac_prog in cygpath 13605 do 13606 # Extract the first word of "$ac_prog", so it can be a program name with args. 13607 set dummy $ac_prog; ac_word=$2 13608 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13609 $as_echo_n "checking for $ac_word... " >&6; } 13610 if ${ac_cv_path_CYGPATH+:} false; then : 13611 $as_echo_n "(cached) " >&6 13612 else 13613 case $CYGPATH in 13614 [\\/]* | ?:[\\/]*) 13615 ac_cv_path_CYGPATH="$CYGPATH" # Let the user override the test with a path. 13616 ;; 13617 *) 13618 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13619 for as_dir in $PATH 13620 do 13621 IFS=$as_save_IFS 13622 test -z "$as_dir" && as_dir=. 13623 for ac_exec_ext in '' $ac_executable_extensions; do 13624 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13625 ac_cv_path_CYGPATH="$as_dir/$ac_word$ac_exec_ext" 13626 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13627 break 2 13628 fi 13629 done 13630 done 13631 IFS=$as_save_IFS 13632 13633 ;; 13634 esac 13635 fi 13636 CYGPATH=$ac_cv_path_CYGPATH 13637 if test -n "$CYGPATH"; then 13638 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5 13639 $as_echo "$CYGPATH" >&6; } 13640 else 13641 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13642 $as_echo "no" >&6; } 13643 fi 13644 13645 13646 test -n "$CYGPATH" && break 13647 done 13648 13649 else 13650 # The variable is set, but is it from the command line or the environment? 13651 13652 # Try to remove the string !CYGPATH! from our list. 13653 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CYGPATH!/} 13654 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 13655 # If it failed, the variable was not from the command line. Ignore it, 13656 # but warn the user (except for BASH, which is always set by the calling BASH). 13657 if test "xCYGPATH" != xBASH; then 13658 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CYGPATH from the environment. Use command line variables instead." >&5 13659 $as_echo "$as_me: WARNING: Ignoring value of CYGPATH from the environment. Use command line variables instead." >&2;} 13660 fi 13661 # Try to locate tool using the code snippet 13662 for ac_prog in cygpath 13663 do 13664 # Extract the first word of "$ac_prog", so it can be a program name with args. 13665 set dummy $ac_prog; ac_word=$2 13666 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13667 $as_echo_n "checking for $ac_word... " >&6; } 13668 if ${ac_cv_path_CYGPATH+:} false; then : 13669 $as_echo_n "(cached) " >&6 13670 else 13671 case $CYGPATH in 13672 [\\/]* | ?:[\\/]*) 13673 ac_cv_path_CYGPATH="$CYGPATH" # Let the user override the test with a path. 13674 ;; 13675 *) 13676 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13677 for as_dir in $PATH 13678 do 13679 IFS=$as_save_IFS 13680 test -z "$as_dir" && as_dir=. 13681 for ac_exec_ext in '' $ac_executable_extensions; do 13682 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13683 ac_cv_path_CYGPATH="$as_dir/$ac_word$ac_exec_ext" 13684 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13685 break 2 13686 fi 13687 done 13688 done 13689 IFS=$as_save_IFS 13690 13691 ;; 13692 esac 13693 fi 13694 CYGPATH=$ac_cv_path_CYGPATH 13695 if test -n "$CYGPATH"; then 13696 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5 13697 $as_echo "$CYGPATH" >&6; } 13698 else 13699 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13700 $as_echo "no" >&6; } 13701 fi 13702 13703 13704 test -n "$CYGPATH" && break 13705 done 13706 13707 else 13708 # If it succeeded, then it was overridden by the user. We will use it 13709 # for the tool. 13710 13711 # First remove it from the list of overridden variables, so we can test 13712 # for unknown variables in the end. 13713 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 13714 13715 # Check if we try to supply an empty value 13716 if test "x$CYGPATH" = x; then 13717 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CYGPATH= (no value)" >&5 13718 $as_echo "$as_me: Setting user supplied tool CYGPATH= (no value)" >&6;} 13719 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CYGPATH" >&5 13720 $as_echo_n "checking for CYGPATH... " >&6; } 13721 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 13722 $as_echo "disabled" >&6; } 13723 else 13724 # Check if the provided tool contains a complete path. 13725 tool_specified="$CYGPATH" 13726 tool_basename="${tool_specified##*/}" 13727 if test "x$tool_basename" = "x$tool_specified"; then 13728 # A command without a complete path is provided, search $PATH. 13729 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CYGPATH=$tool_basename" >&5 13730 $as_echo "$as_me: Will search for user supplied tool CYGPATH=$tool_basename" >&6;} 13731 # Extract the first word of "$tool_basename", so it can be a program name with args. 13732 set dummy $tool_basename; ac_word=$2 13733 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13734 $as_echo_n "checking for $ac_word... " >&6; } 13735 if ${ac_cv_path_CYGPATH+:} false; then : 13736 $as_echo_n "(cached) " >&6 13737 else 13738 case $CYGPATH in 13739 [\\/]* | ?:[\\/]*) 13740 ac_cv_path_CYGPATH="$CYGPATH" # Let the user override the test with a path. 13741 ;; 13742 *) 13743 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13744 for as_dir in $PATH 13745 do 13746 IFS=$as_save_IFS 13747 test -z "$as_dir" && as_dir=. 13748 for ac_exec_ext in '' $ac_executable_extensions; do 13749 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13750 ac_cv_path_CYGPATH="$as_dir/$ac_word$ac_exec_ext" 13751 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13752 break 2 13753 fi 13754 done 13755 done 13756 IFS=$as_save_IFS 13757 13758 ;; 13759 esac 13760 fi 13761 CYGPATH=$ac_cv_path_CYGPATH 13762 if test -n "$CYGPATH"; then 13763 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGPATH" >&5 13764 $as_echo "$CYGPATH" >&6; } 13765 else 13766 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13767 $as_echo "no" >&6; } 13768 fi 13769 13770 13771 if test "x$CYGPATH" = x; then 13772 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 13773 fi 13774 else 13775 # Otherwise we believe it is a complete path. Use it as it is. 13776 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CYGPATH=$tool_specified" >&5 13777 $as_echo "$as_me: Will use user supplied tool CYGPATH=$tool_specified" >&6;} 13778 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CYGPATH" >&5 13779 $as_echo_n "checking for CYGPATH... " >&6; } 13780 if test ! -x "$tool_specified"; then 13781 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 13782 $as_echo "not found" >&6; } 13783 as_fn_error $? "User supplied tool CYGPATH=$tool_specified does not exist or is not executable" "$LINENO" 5 13784 fi 13785 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 13786 $as_echo "$tool_specified" >&6; } 13787 fi 13788 fi 13789 fi 13790 13791 fi 13792 13793 13794 13795 13796 # Publish this variable in the help. 13797 13798 13799 if [ -z "${READLINK+x}" ]; then 13800 # The variable is not set by user, try to locate tool using the code snippet 13801 for ac_prog in greadlink readlink 13802 do 13803 # Extract the first word of "$ac_prog", so it can be a program name with args. 13804 set dummy $ac_prog; ac_word=$2 13805 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13806 $as_echo_n "checking for $ac_word... " >&6; } 13807 if ${ac_cv_path_READLINK+:} false; then : 13808 $as_echo_n "(cached) " >&6 13809 else 13810 case $READLINK in 13811 [\\/]* | ?:[\\/]*) 13812 ac_cv_path_READLINK="$READLINK" # Let the user override the test with a path. 13813 ;; 13814 *) 13815 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13816 for as_dir in $PATH 13817 do 13818 IFS=$as_save_IFS 13819 test -z "$as_dir" && as_dir=. 13820 for ac_exec_ext in '' $ac_executable_extensions; do 13821 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13822 ac_cv_path_READLINK="$as_dir/$ac_word$ac_exec_ext" 13823 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13824 break 2 13825 fi 13826 done 13827 done 13828 IFS=$as_save_IFS 13829 13830 ;; 13831 esac 13832 fi 13833 READLINK=$ac_cv_path_READLINK 13834 if test -n "$READLINK"; then 13835 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINK" >&5 13836 $as_echo "$READLINK" >&6; } 13837 else 13838 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13839 $as_echo "no" >&6; } 13840 fi 13841 13842 13843 test -n "$READLINK" && break 13844 done 13845 13846 else 13847 # The variable is set, but is it from the command line or the environment? 13848 13849 # Try to remove the string !READLINK! from our list. 13850 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!READLINK!/} 13851 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 13852 # If it failed, the variable was not from the command line. Ignore it, 13853 # but warn the user (except for BASH, which is always set by the calling BASH). 13854 if test "xREADLINK" != xBASH; then 13855 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of READLINK from the environment. Use command line variables instead." >&5 13856 $as_echo "$as_me: WARNING: Ignoring value of READLINK from the environment. Use command line variables instead." >&2;} 13857 fi 13858 # Try to locate tool using the code snippet 13859 for ac_prog in greadlink readlink 13860 do 13861 # Extract the first word of "$ac_prog", so it can be a program name with args. 13862 set dummy $ac_prog; ac_word=$2 13863 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13864 $as_echo_n "checking for $ac_word... " >&6; } 13865 if ${ac_cv_path_READLINK+:} false; then : 13866 $as_echo_n "(cached) " >&6 13867 else 13868 case $READLINK in 13869 [\\/]* | ?:[\\/]*) 13870 ac_cv_path_READLINK="$READLINK" # Let the user override the test with a path. 13871 ;; 13872 *) 13873 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13874 for as_dir in $PATH 13875 do 13876 IFS=$as_save_IFS 13877 test -z "$as_dir" && as_dir=. 13878 for ac_exec_ext in '' $ac_executable_extensions; do 13879 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13880 ac_cv_path_READLINK="$as_dir/$ac_word$ac_exec_ext" 13881 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13882 break 2 13883 fi 13884 done 13885 done 13886 IFS=$as_save_IFS 13887 13888 ;; 13889 esac 13890 fi 13891 READLINK=$ac_cv_path_READLINK 13892 if test -n "$READLINK"; then 13893 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINK" >&5 13894 $as_echo "$READLINK" >&6; } 13895 else 13896 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13897 $as_echo "no" >&6; } 13898 fi 13899 13900 13901 test -n "$READLINK" && break 13902 done 13903 13904 else 13905 # If it succeeded, then it was overridden by the user. We will use it 13906 # for the tool. 13907 13908 # First remove it from the list of overridden variables, so we can test 13909 # for unknown variables in the end. 13910 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 13911 13912 # Check if we try to supply an empty value 13913 if test "x$READLINK" = x; then 13914 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool READLINK= (no value)" >&5 13915 $as_echo "$as_me: Setting user supplied tool READLINK= (no value)" >&6;} 13916 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READLINK" >&5 13917 $as_echo_n "checking for READLINK... " >&6; } 13918 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 13919 $as_echo "disabled" >&6; } 13920 else 13921 # Check if the provided tool contains a complete path. 13922 tool_specified="$READLINK" 13923 tool_basename="${tool_specified##*/}" 13924 if test "x$tool_basename" = "x$tool_specified"; then 13925 # A command without a complete path is provided, search $PATH. 13926 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool READLINK=$tool_basename" >&5 13927 $as_echo "$as_me: Will search for user supplied tool READLINK=$tool_basename" >&6;} 13928 # Extract the first word of "$tool_basename", so it can be a program name with args. 13929 set dummy $tool_basename; ac_word=$2 13930 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 13931 $as_echo_n "checking for $ac_word... " >&6; } 13932 if ${ac_cv_path_READLINK+:} false; then : 13933 $as_echo_n "(cached) " >&6 13934 else 13935 case $READLINK in 13936 [\\/]* | ?:[\\/]*) 13937 ac_cv_path_READLINK="$READLINK" # Let the user override the test with a path. 13938 ;; 13939 *) 13940 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 13941 for as_dir in $PATH 13942 do 13943 IFS=$as_save_IFS 13944 test -z "$as_dir" && as_dir=. 13945 for ac_exec_ext in '' $ac_executable_extensions; do 13946 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 13947 ac_cv_path_READLINK="$as_dir/$ac_word$ac_exec_ext" 13948 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 13949 break 2 13950 fi 13951 done 13952 done 13953 IFS=$as_save_IFS 13954 13955 ;; 13956 esac 13957 fi 13958 READLINK=$ac_cv_path_READLINK 13959 if test -n "$READLINK"; then 13960 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READLINK" >&5 13961 $as_echo "$READLINK" >&6; } 13962 else 13963 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 13964 $as_echo "no" >&6; } 13965 fi 13966 13967 13968 if test "x$READLINK" = x; then 13969 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 13970 fi 13971 else 13972 # Otherwise we believe it is a complete path. Use it as it is. 13973 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool READLINK=$tool_specified" >&5 13974 $as_echo "$as_me: Will use user supplied tool READLINK=$tool_specified" >&6;} 13975 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READLINK" >&5 13976 $as_echo_n "checking for READLINK... " >&6; } 13977 if test ! -x "$tool_specified"; then 13978 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 13979 $as_echo "not found" >&6; } 13980 as_fn_error $? "User supplied tool READLINK=$tool_specified does not exist or is not executable" "$LINENO" 5 13981 fi 13982 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 13983 $as_echo "$tool_specified" >&6; } 13984 fi 13985 fi 13986 fi 13987 13988 fi 13989 13990 13991 13992 13993 # Publish this variable in the help. 13994 13995 13996 if [ -z "${DF+x}" ]; then 13997 # The variable is not set by user, try to locate tool using the code snippet 13998 for ac_prog in df 13999 do 14000 # Extract the first word of "$ac_prog", so it can be a program name with args. 14001 set dummy $ac_prog; ac_word=$2 14002 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14003 $as_echo_n "checking for $ac_word... " >&6; } 14004 if ${ac_cv_path_DF+:} false; then : 14005 $as_echo_n "(cached) " >&6 14006 else 14007 case $DF in 14008 [\\/]* | ?:[\\/]*) 14009 ac_cv_path_DF="$DF" # Let the user override the test with a path. 14010 ;; 14011 *) 14012 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14013 for as_dir in $PATH 14014 do 14015 IFS=$as_save_IFS 14016 test -z "$as_dir" && as_dir=. 14017 for ac_exec_ext in '' $ac_executable_extensions; do 14018 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14019 ac_cv_path_DF="$as_dir/$ac_word$ac_exec_ext" 14020 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14021 break 2 14022 fi 14023 done 14024 done 14025 IFS=$as_save_IFS 14026 14027 ;; 14028 esac 14029 fi 14030 DF=$ac_cv_path_DF 14031 if test -n "$DF"; then 14032 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DF" >&5 14033 $as_echo "$DF" >&6; } 14034 else 14035 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14036 $as_echo "no" >&6; } 14037 fi 14038 14039 14040 test -n "$DF" && break 14041 done 14042 14043 else 14044 # The variable is set, but is it from the command line or the environment? 14045 14046 # Try to remove the string !DF! from our list. 14047 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DF!/} 14048 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 14049 # If it failed, the variable was not from the command line. Ignore it, 14050 # but warn the user (except for BASH, which is always set by the calling BASH). 14051 if test "xDF" != xBASH; then 14052 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DF from the environment. Use command line variables instead." >&5 14053 $as_echo "$as_me: WARNING: Ignoring value of DF from the environment. Use command line variables instead." >&2;} 14054 fi 14055 # Try to locate tool using the code snippet 14056 for ac_prog in df 14057 do 14058 # Extract the first word of "$ac_prog", so it can be a program name with args. 14059 set dummy $ac_prog; ac_word=$2 14060 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14061 $as_echo_n "checking for $ac_word... " >&6; } 14062 if ${ac_cv_path_DF+:} false; then : 14063 $as_echo_n "(cached) " >&6 14064 else 14065 case $DF in 14066 [\\/]* | ?:[\\/]*) 14067 ac_cv_path_DF="$DF" # Let the user override the test with a path. 14068 ;; 14069 *) 14070 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14071 for as_dir in $PATH 14072 do 14073 IFS=$as_save_IFS 14074 test -z "$as_dir" && as_dir=. 14075 for ac_exec_ext in '' $ac_executable_extensions; do 14076 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14077 ac_cv_path_DF="$as_dir/$ac_word$ac_exec_ext" 14078 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14079 break 2 14080 fi 14081 done 14082 done 14083 IFS=$as_save_IFS 14084 14085 ;; 14086 esac 14087 fi 14088 DF=$ac_cv_path_DF 14089 if test -n "$DF"; then 14090 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DF" >&5 14091 $as_echo "$DF" >&6; } 14092 else 14093 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14094 $as_echo "no" >&6; } 14095 fi 14096 14097 14098 test -n "$DF" && break 14099 done 14100 14101 else 14102 # If it succeeded, then it was overridden by the user. We will use it 14103 # for the tool. 14104 14105 # First remove it from the list of overridden variables, so we can test 14106 # for unknown variables in the end. 14107 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 14108 14109 # Check if we try to supply an empty value 14110 if test "x$DF" = x; then 14111 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DF= (no value)" >&5 14112 $as_echo "$as_me: Setting user supplied tool DF= (no value)" >&6;} 14113 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DF" >&5 14114 $as_echo_n "checking for DF... " >&6; } 14115 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 14116 $as_echo "disabled" >&6; } 14117 else 14118 # Check if the provided tool contains a complete path. 14119 tool_specified="$DF" 14120 tool_basename="${tool_specified##*/}" 14121 if test "x$tool_basename" = "x$tool_specified"; then 14122 # A command without a complete path is provided, search $PATH. 14123 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DF=$tool_basename" >&5 14124 $as_echo "$as_me: Will search for user supplied tool DF=$tool_basename" >&6;} 14125 # Extract the first word of "$tool_basename", so it can be a program name with args. 14126 set dummy $tool_basename; ac_word=$2 14127 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14128 $as_echo_n "checking for $ac_word... " >&6; } 14129 if ${ac_cv_path_DF+:} false; then : 14130 $as_echo_n "(cached) " >&6 14131 else 14132 case $DF in 14133 [\\/]* | ?:[\\/]*) 14134 ac_cv_path_DF="$DF" # Let the user override the test with a path. 14135 ;; 14136 *) 14137 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14138 for as_dir in $PATH 14139 do 14140 IFS=$as_save_IFS 14141 test -z "$as_dir" && as_dir=. 14142 for ac_exec_ext in '' $ac_executable_extensions; do 14143 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14144 ac_cv_path_DF="$as_dir/$ac_word$ac_exec_ext" 14145 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14146 break 2 14147 fi 14148 done 14149 done 14150 IFS=$as_save_IFS 14151 14152 ;; 14153 esac 14154 fi 14155 DF=$ac_cv_path_DF 14156 if test -n "$DF"; then 14157 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DF" >&5 14158 $as_echo "$DF" >&6; } 14159 else 14160 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14161 $as_echo "no" >&6; } 14162 fi 14163 14164 14165 if test "x$DF" = x; then 14166 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 14167 fi 14168 else 14169 # Otherwise we believe it is a complete path. Use it as it is. 14170 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DF=$tool_specified" >&5 14171 $as_echo "$as_me: Will use user supplied tool DF=$tool_specified" >&6;} 14172 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DF" >&5 14173 $as_echo_n "checking for DF... " >&6; } 14174 if test ! -x "$tool_specified"; then 14175 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 14176 $as_echo "not found" >&6; } 14177 as_fn_error $? "User supplied tool DF=$tool_specified does not exist or is not executable" "$LINENO" 5 14178 fi 14179 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 14180 $as_echo "$tool_specified" >&6; } 14181 fi 14182 fi 14183 fi 14184 14185 fi 14186 14187 14188 14189 14190 # Publish this variable in the help. 14191 14192 14193 if [ -z "${CPIO+x}" ]; then 14194 # The variable is not set by user, try to locate tool using the code snippet 14195 for ac_prog in cpio bsdcpio 14196 do 14197 # Extract the first word of "$ac_prog", so it can be a program name with args. 14198 set dummy $ac_prog; ac_word=$2 14199 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14200 $as_echo_n "checking for $ac_word... " >&6; } 14201 if ${ac_cv_path_CPIO+:} false; then : 14202 $as_echo_n "(cached) " >&6 14203 else 14204 case $CPIO in 14205 [\\/]* | ?:[\\/]*) 14206 ac_cv_path_CPIO="$CPIO" # Let the user override the test with a path. 14207 ;; 14208 *) 14209 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14210 for as_dir in $PATH 14211 do 14212 IFS=$as_save_IFS 14213 test -z "$as_dir" && as_dir=. 14214 for ac_exec_ext in '' $ac_executable_extensions; do 14215 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14216 ac_cv_path_CPIO="$as_dir/$ac_word$ac_exec_ext" 14217 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14218 break 2 14219 fi 14220 done 14221 done 14222 IFS=$as_save_IFS 14223 14224 ;; 14225 esac 14226 fi 14227 CPIO=$ac_cv_path_CPIO 14228 if test -n "$CPIO"; then 14229 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPIO" >&5 14230 $as_echo "$CPIO" >&6; } 14231 else 14232 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14233 $as_echo "no" >&6; } 14234 fi 14235 14236 14237 test -n "$CPIO" && break 14238 done 14239 14240 else 14241 # The variable is set, but is it from the command line or the environment? 14242 14243 # Try to remove the string !CPIO! from our list. 14244 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CPIO!/} 14245 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 14246 # If it failed, the variable was not from the command line. Ignore it, 14247 # but warn the user (except for BASH, which is always set by the calling BASH). 14248 if test "xCPIO" != xBASH; then 14249 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CPIO from the environment. Use command line variables instead." >&5 14250 $as_echo "$as_me: WARNING: Ignoring value of CPIO from the environment. Use command line variables instead." >&2;} 14251 fi 14252 # Try to locate tool using the code snippet 14253 for ac_prog in cpio bsdcpio 14254 do 14255 # Extract the first word of "$ac_prog", so it can be a program name with args. 14256 set dummy $ac_prog; ac_word=$2 14257 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14258 $as_echo_n "checking for $ac_word... " >&6; } 14259 if ${ac_cv_path_CPIO+:} false; then : 14260 $as_echo_n "(cached) " >&6 14261 else 14262 case $CPIO in 14263 [\\/]* | ?:[\\/]*) 14264 ac_cv_path_CPIO="$CPIO" # Let the user override the test with a path. 14265 ;; 14266 *) 14267 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14268 for as_dir in $PATH 14269 do 14270 IFS=$as_save_IFS 14271 test -z "$as_dir" && as_dir=. 14272 for ac_exec_ext in '' $ac_executable_extensions; do 14273 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14274 ac_cv_path_CPIO="$as_dir/$ac_word$ac_exec_ext" 14275 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14276 break 2 14277 fi 14278 done 14279 done 14280 IFS=$as_save_IFS 14281 14282 ;; 14283 esac 14284 fi 14285 CPIO=$ac_cv_path_CPIO 14286 if test -n "$CPIO"; then 14287 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPIO" >&5 14288 $as_echo "$CPIO" >&6; } 14289 else 14290 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14291 $as_echo "no" >&6; } 14292 fi 14293 14294 14295 test -n "$CPIO" && break 14296 done 14297 14298 else 14299 # If it succeeded, then it was overridden by the user. We will use it 14300 # for the tool. 14301 14302 # First remove it from the list of overridden variables, so we can test 14303 # for unknown variables in the end. 14304 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 14305 14306 # Check if we try to supply an empty value 14307 if test "x$CPIO" = x; then 14308 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CPIO= (no value)" >&5 14309 $as_echo "$as_me: Setting user supplied tool CPIO= (no value)" >&6;} 14310 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CPIO" >&5 14311 $as_echo_n "checking for CPIO... " >&6; } 14312 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 14313 $as_echo "disabled" >&6; } 14314 else 14315 # Check if the provided tool contains a complete path. 14316 tool_specified="$CPIO" 14317 tool_basename="${tool_specified##*/}" 14318 if test "x$tool_basename" = "x$tool_specified"; then 14319 # A command without a complete path is provided, search $PATH. 14320 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CPIO=$tool_basename" >&5 14321 $as_echo "$as_me: Will search for user supplied tool CPIO=$tool_basename" >&6;} 14322 # Extract the first word of "$tool_basename", so it can be a program name with args. 14323 set dummy $tool_basename; ac_word=$2 14324 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14325 $as_echo_n "checking for $ac_word... " >&6; } 14326 if ${ac_cv_path_CPIO+:} false; then : 14327 $as_echo_n "(cached) " >&6 14328 else 14329 case $CPIO in 14330 [\\/]* | ?:[\\/]*) 14331 ac_cv_path_CPIO="$CPIO" # Let the user override the test with a path. 14332 ;; 14333 *) 14334 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14335 for as_dir in $PATH 14336 do 14337 IFS=$as_save_IFS 14338 test -z "$as_dir" && as_dir=. 14339 for ac_exec_ext in '' $ac_executable_extensions; do 14340 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14341 ac_cv_path_CPIO="$as_dir/$ac_word$ac_exec_ext" 14342 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14343 break 2 14344 fi 14345 done 14346 done 14347 IFS=$as_save_IFS 14348 14349 ;; 14350 esac 14351 fi 14352 CPIO=$ac_cv_path_CPIO 14353 if test -n "$CPIO"; then 14354 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPIO" >&5 14355 $as_echo "$CPIO" >&6; } 14356 else 14357 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14358 $as_echo "no" >&6; } 14359 fi 14360 14361 14362 if test "x$CPIO" = x; then 14363 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 14364 fi 14365 else 14366 # Otherwise we believe it is a complete path. Use it as it is. 14367 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CPIO=$tool_specified" >&5 14368 $as_echo "$as_me: Will use user supplied tool CPIO=$tool_specified" >&6;} 14369 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CPIO" >&5 14370 $as_echo_n "checking for CPIO... " >&6; } 14371 if test ! -x "$tool_specified"; then 14372 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 14373 $as_echo "not found" >&6; } 14374 as_fn_error $? "User supplied tool CPIO=$tool_specified does not exist or is not executable" "$LINENO" 5 14375 fi 14376 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 14377 $as_echo "$tool_specified" >&6; } 14378 fi 14379 fi 14380 fi 14381 14382 fi 14383 14384 14385 14386 14387 # Publish this variable in the help. 14388 14389 14390 if [ -z "${NICE+x}" ]; then 14391 # The variable is not set by user, try to locate tool using the code snippet 14392 for ac_prog in nice 14393 do 14394 # Extract the first word of "$ac_prog", so it can be a program name with args. 14395 set dummy $ac_prog; ac_word=$2 14396 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14397 $as_echo_n "checking for $ac_word... " >&6; } 14398 if ${ac_cv_path_NICE+:} false; then : 14399 $as_echo_n "(cached) " >&6 14400 else 14401 case $NICE in 14402 [\\/]* | ?:[\\/]*) 14403 ac_cv_path_NICE="$NICE" # Let the user override the test with a path. 14404 ;; 14405 *) 14406 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14407 for as_dir in $PATH 14408 do 14409 IFS=$as_save_IFS 14410 test -z "$as_dir" && as_dir=. 14411 for ac_exec_ext in '' $ac_executable_extensions; do 14412 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14413 ac_cv_path_NICE="$as_dir/$ac_word$ac_exec_ext" 14414 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14415 break 2 14416 fi 14417 done 14418 done 14419 IFS=$as_save_IFS 14420 14421 ;; 14422 esac 14423 fi 14424 NICE=$ac_cv_path_NICE 14425 if test -n "$NICE"; then 14426 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NICE" >&5 14427 $as_echo "$NICE" >&6; } 14428 else 14429 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14430 $as_echo "no" >&6; } 14431 fi 14432 14433 14434 test -n "$NICE" && break 14435 done 14436 14437 else 14438 # The variable is set, but is it from the command line or the environment? 14439 14440 # Try to remove the string !NICE! from our list. 14441 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NICE!/} 14442 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 14443 # If it failed, the variable was not from the command line. Ignore it, 14444 # but warn the user (except for BASH, which is always set by the calling BASH). 14445 if test "xNICE" != xBASH; then 14446 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NICE from the environment. Use command line variables instead." >&5 14447 $as_echo "$as_me: WARNING: Ignoring value of NICE from the environment. Use command line variables instead." >&2;} 14448 fi 14449 # Try to locate tool using the code snippet 14450 for ac_prog in nice 14451 do 14452 # Extract the first word of "$ac_prog", so it can be a program name with args. 14453 set dummy $ac_prog; ac_word=$2 14454 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14455 $as_echo_n "checking for $ac_word... " >&6; } 14456 if ${ac_cv_path_NICE+:} false; then : 14457 $as_echo_n "(cached) " >&6 14458 else 14459 case $NICE in 14460 [\\/]* | ?:[\\/]*) 14461 ac_cv_path_NICE="$NICE" # Let the user override the test with a path. 14462 ;; 14463 *) 14464 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14465 for as_dir in $PATH 14466 do 14467 IFS=$as_save_IFS 14468 test -z "$as_dir" && as_dir=. 14469 for ac_exec_ext in '' $ac_executable_extensions; do 14470 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14471 ac_cv_path_NICE="$as_dir/$ac_word$ac_exec_ext" 14472 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14473 break 2 14474 fi 14475 done 14476 done 14477 IFS=$as_save_IFS 14478 14479 ;; 14480 esac 14481 fi 14482 NICE=$ac_cv_path_NICE 14483 if test -n "$NICE"; then 14484 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NICE" >&5 14485 $as_echo "$NICE" >&6; } 14486 else 14487 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14488 $as_echo "no" >&6; } 14489 fi 14490 14491 14492 test -n "$NICE" && break 14493 done 14494 14495 else 14496 # If it succeeded, then it was overridden by the user. We will use it 14497 # for the tool. 14498 14499 # First remove it from the list of overridden variables, so we can test 14500 # for unknown variables in the end. 14501 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 14502 14503 # Check if we try to supply an empty value 14504 if test "x$NICE" = x; then 14505 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool NICE= (no value)" >&5 14506 $as_echo "$as_me: Setting user supplied tool NICE= (no value)" >&6;} 14507 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NICE" >&5 14508 $as_echo_n "checking for NICE... " >&6; } 14509 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 14510 $as_echo "disabled" >&6; } 14511 else 14512 # Check if the provided tool contains a complete path. 14513 tool_specified="$NICE" 14514 tool_basename="${tool_specified##*/}" 14515 if test "x$tool_basename" = "x$tool_specified"; then 14516 # A command without a complete path is provided, search $PATH. 14517 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NICE=$tool_basename" >&5 14518 $as_echo "$as_me: Will search for user supplied tool NICE=$tool_basename" >&6;} 14519 # Extract the first word of "$tool_basename", so it can be a program name with args. 14520 set dummy $tool_basename; ac_word=$2 14521 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 14522 $as_echo_n "checking for $ac_word... " >&6; } 14523 if ${ac_cv_path_NICE+:} false; then : 14524 $as_echo_n "(cached) " >&6 14525 else 14526 case $NICE in 14527 [\\/]* | ?:[\\/]*) 14528 ac_cv_path_NICE="$NICE" # Let the user override the test with a path. 14529 ;; 14530 *) 14531 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 14532 for as_dir in $PATH 14533 do 14534 IFS=$as_save_IFS 14535 test -z "$as_dir" && as_dir=. 14536 for ac_exec_ext in '' $ac_executable_extensions; do 14537 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 14538 ac_cv_path_NICE="$as_dir/$ac_word$ac_exec_ext" 14539 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 14540 break 2 14541 fi 14542 done 14543 done 14544 IFS=$as_save_IFS 14545 14546 ;; 14547 esac 14548 fi 14549 NICE=$ac_cv_path_NICE 14550 if test -n "$NICE"; then 14551 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NICE" >&5 14552 $as_echo "$NICE" >&6; } 14553 else 14554 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 14555 $as_echo "no" >&6; } 14556 fi 14557 14558 14559 if test "x$NICE" = x; then 14560 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 14561 fi 14562 else 14563 # Otherwise we believe it is a complete path. Use it as it is. 14564 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NICE=$tool_specified" >&5 14565 $as_echo "$as_me: Will use user supplied tool NICE=$tool_specified" >&6;} 14566 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NICE" >&5 14567 $as_echo_n "checking for NICE... " >&6; } 14568 if test ! -x "$tool_specified"; then 14569 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 14570 $as_echo "not found" >&6; } 14571 as_fn_error $? "User supplied tool NICE=$tool_specified does not exist or is not executable" "$LINENO" 5 14572 fi 14573 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 14574 $as_echo "$tool_specified" >&6; } 14575 fi 14576 fi 14577 fi 14578 14579 fi 14580 14581 14582 14583 14584 # Now we can determine OpenJDK build and target platforms. This is required to 14585 # have early on. 14586 # Make sure we can run config.sub. 14587 $SHELL "$ac_aux_dir/config.sub" sun4 >/dev/null 2>&1 || 14588 as_fn_error $? "cannot run $SHELL $ac_aux_dir/config.sub" "$LINENO" 5 14589 14590 { $as_echo "$as_me:${as_lineno-$LINENO}: checking build system type" >&5 14591 $as_echo_n "checking build system type... " >&6; } 14592 if ${ac_cv_build+:} false; then : 14593 $as_echo_n "(cached) " >&6 14594 else 14595 ac_build_alias=$build_alias 14596 test "x$ac_build_alias" = x && 14597 ac_build_alias=`$SHELL "$ac_aux_dir/config.guess"` 14598 test "x$ac_build_alias" = x && 14599 as_fn_error $? "cannot guess build type; you must specify one" "$LINENO" 5 14600 ac_cv_build=`$SHELL "$ac_aux_dir/config.sub" $ac_build_alias` || 14601 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $ac_build_alias failed" "$LINENO" 5 14602 14603 fi 14604 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_build" >&5 14605 $as_echo "$ac_cv_build" >&6; } 14606 case $ac_cv_build in 14607 *-*-*) ;; 14608 *) as_fn_error $? "invalid value of canonical build" "$LINENO" 5;; 14609 esac 14610 build=$ac_cv_build 14611 ac_save_IFS=$IFS; IFS='-' 14612 set x $ac_cv_build 14613 shift 14614 build_cpu=$1 14615 build_vendor=$2 14616 shift; shift 14617 # Remember, the first character of IFS is used to create $*, 14618 # except with old shells: 14619 build_os=$* 14620 IFS=$ac_save_IFS 14621 case $build_os in *\ *) build_os=`echo "$build_os" | sed 's/ /-/g'`;; esac 14622 14623 14624 { $as_echo "$as_me:${as_lineno-$LINENO}: checking host system type" >&5 14625 $as_echo_n "checking host system type... " >&6; } 14626 if ${ac_cv_host+:} false; then : 14627 $as_echo_n "(cached) " >&6 14628 else 14629 if test "x$host_alias" = x; then 14630 ac_cv_host=$ac_cv_build 14631 else 14632 ac_cv_host=`$SHELL "$ac_aux_dir/config.sub" $host_alias` || 14633 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $host_alias failed" "$LINENO" 5 14634 fi 14635 14636 fi 14637 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_host" >&5 14638 $as_echo "$ac_cv_host" >&6; } 14639 case $ac_cv_host in 14640 *-*-*) ;; 14641 *) as_fn_error $? "invalid value of canonical host" "$LINENO" 5;; 14642 esac 14643 host=$ac_cv_host 14644 ac_save_IFS=$IFS; IFS='-' 14645 set x $ac_cv_host 14646 shift 14647 host_cpu=$1 14648 host_vendor=$2 14649 shift; shift 14650 # Remember, the first character of IFS is used to create $*, 14651 # except with old shells: 14652 host_os=$* 14653 IFS=$ac_save_IFS 14654 case $host_os in *\ *) host_os=`echo "$host_os" | sed 's/ /-/g'`;; esac 14655 14656 14657 { $as_echo "$as_me:${as_lineno-$LINENO}: checking target system type" >&5 14658 $as_echo_n "checking target system type... " >&6; } 14659 if ${ac_cv_target+:} false; then : 14660 $as_echo_n "(cached) " >&6 14661 else 14662 if test "x$target_alias" = x; then 14663 ac_cv_target=$ac_cv_host 14664 else 14665 ac_cv_target=`$SHELL "$ac_aux_dir/config.sub" $target_alias` || 14666 as_fn_error $? "$SHELL $ac_aux_dir/config.sub $target_alias failed" "$LINENO" 5 14667 fi 14668 14669 fi 14670 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_target" >&5 14671 $as_echo "$ac_cv_target" >&6; } 14672 case $ac_cv_target in 14673 *-*-*) ;; 14674 *) as_fn_error $? "invalid value of canonical target" "$LINENO" 5;; 14675 esac 14676 target=$ac_cv_target 14677 ac_save_IFS=$IFS; IFS='-' 14678 set x $ac_cv_target 14679 shift 14680 target_cpu=$1 14681 target_vendor=$2 14682 shift; shift 14683 # Remember, the first character of IFS is used to create $*, 14684 # except with old shells: 14685 target_os=$* 14686 IFS=$ac_save_IFS 14687 case $target_os in *\ *) target_os=`echo "$target_os" | sed 's/ /-/g'`;; esac 14688 14689 14690 # The aliases save the names the user supplied, while $host etc. 14691 # will get canonicalized. 14692 test -n "$target_alias" && 14693 test "$program_prefix$program_suffix$program_transform_name" = \ 14694 NONENONEs,x,x, && 14695 program_prefix=${target_alias}- 14696 14697 # Figure out the build and target systems. # Note that in autoconf terminology, "build" is obvious, but "target" 14698 # is confusing; it assumes you are cross-compiling a cross-compiler (!) and "target" is thus the target of the 14699 # product you're building. The target of this build is called "host". Since this is confusing to most people, we 14700 # have not adopted that system, but use "target" as the platform we are building for. In some places though we need 14701 # to use the configure naming style. 14702 14703 14704 14705 14706 14707 # Copy the autoconf trip/quadruplet verbatim to OPENJDK_TARGET_AUTOCONF_NAME 14708 # (from the autoconf "host") and OPENJDK_BUILD_AUTOCONF_NAME 14709 # Note that we might later on rewrite e.g. OPENJDK_TARGET_CPU due to reduced build, 14710 # but this will not change the value of OPENJDK_TARGET_AUTOCONF_NAME. 14711 OPENJDK_TARGET_AUTOCONF_NAME="$host" 14712 OPENJDK_BUILD_AUTOCONF_NAME="$build" 14713 14714 14715 14716 # Convert the autoconf OS/CPU value to our own data, into the VAR_OS/CPU variables. 14717 14718 case "$build_os" in 14719 *linux*) 14720 VAR_OS=linux 14721 VAR_OS_TYPE=unix 14722 ;; 14723 *solaris*) 14724 VAR_OS=solaris 14725 VAR_OS_TYPE=unix 14726 ;; 14727 *darwin*) 14728 VAR_OS=macosx 14729 VAR_OS_TYPE=unix 14730 ;; 14731 *bsd*) 14732 VAR_OS=bsd 14733 VAR_OS_TYPE=unix 14734 ;; 14735 *cygwin*) 14736 VAR_OS=windows 14737 VAR_OS_ENV=windows.cygwin 14738 ;; 14739 *mingw*) 14740 VAR_OS=windows 14741 VAR_OS_ENV=windows.msys 14742 ;; 14743 *aix*) 14744 VAR_OS=aix 14745 VAR_OS_TYPE=unix 14746 ;; 14747 *) 14748 as_fn_error $? "unsupported operating system $build_os" "$LINENO" 5 14749 ;; 14750 esac 14751 14752 14753 # First argument is the cpu name from the trip/quad 14754 case "$build_cpu" in 14755 x86_64) 14756 VAR_CPU=x86_64 14757 VAR_CPU_ARCH=x86 14758 VAR_CPU_BITS=64 14759 VAR_CPU_ENDIAN=little 14760 ;; 14761 i?86) 14762 VAR_CPU=x86 14763 VAR_CPU_ARCH=x86 14764 VAR_CPU_BITS=32 14765 VAR_CPU_ENDIAN=little 14766 ;; 14767 arm*) 14768 VAR_CPU=arm 14769 VAR_CPU_ARCH=arm 14770 VAR_CPU_BITS=32 14771 VAR_CPU_ENDIAN=little 14772 ;; 14773 aarch64) 14774 VAR_CPU=aarch64 14775 VAR_CPU_ARCH=aarch64 14776 VAR_CPU_BITS=64 14777 VAR_CPU_ENDIAN=little 14778 ;; 14779 powerpc) 14780 VAR_CPU=ppc 14781 VAR_CPU_ARCH=ppc 14782 VAR_CPU_BITS=32 14783 VAR_CPU_ENDIAN=big 14784 ;; 14785 powerpc64) 14786 VAR_CPU=ppc64 14787 VAR_CPU_ARCH=ppc 14788 VAR_CPU_BITS=64 14789 VAR_CPU_ENDIAN=big 14790 ;; 14791 powerpc64le) 14792 VAR_CPU=ppc64 14793 VAR_CPU_ARCH=ppc 14794 VAR_CPU_BITS=64 14795 VAR_CPU_ENDIAN=little 14796 ;; 14797 s390) 14798 VAR_CPU=s390 14799 VAR_CPU_ARCH=s390 14800 VAR_CPU_BITS=32 14801 VAR_CPU_ENDIAN=big 14802 ;; 14803 s390x) 14804 VAR_CPU=s390x 14805 VAR_CPU_ARCH=s390 14806 VAR_CPU_BITS=64 14807 VAR_CPU_ENDIAN=big 14808 ;; 14809 sparc) 14810 VAR_CPU=sparc 14811 VAR_CPU_ARCH=sparc 14812 VAR_CPU_BITS=32 14813 VAR_CPU_ENDIAN=big 14814 ;; 14815 sparcv9|sparc64) 14816 VAR_CPU=sparcv9 14817 VAR_CPU_ARCH=sparc 14818 VAR_CPU_BITS=64 14819 VAR_CPU_ENDIAN=big 14820 ;; 14821 *) 14822 as_fn_error $? "unsupported cpu $build_cpu" "$LINENO" 5 14823 ;; 14824 esac 14825 14826 # ..and setup our own variables. (Do this explicitely to facilitate searching) 14827 OPENJDK_BUILD_OS="$VAR_OS" 14828 if test "x$VAR_OS_TYPE" != x; then 14829 OPENJDK_BUILD_OS_TYPE="$VAR_OS_TYPE" 14830 else 14831 OPENJDK_BUILD_OS_TYPE="$VAR_OS" 14832 fi 14833 if test "x$VAR_OS_ENV" != x; then 14834 OPENJDK_BUILD_OS_ENV="$VAR_OS_ENV" 14835 else 14836 OPENJDK_BUILD_OS_ENV="$VAR_OS" 14837 fi 14838 OPENJDK_BUILD_CPU="$VAR_CPU" 14839 OPENJDK_BUILD_CPU_ARCH="$VAR_CPU_ARCH" 14840 OPENJDK_BUILD_CPU_BITS="$VAR_CPU_BITS" 14841 OPENJDK_BUILD_CPU_ENDIAN="$VAR_CPU_ENDIAN" 14842 14843 14844 14845 14846 14847 14848 14849 14850 { $as_echo "$as_me:${as_lineno-$LINENO}: checking openjdk-build os-cpu" >&5 14851 $as_echo_n "checking openjdk-build os-cpu... " >&6; } 14852 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_BUILD_OS-$OPENJDK_BUILD_CPU" >&5 14853 $as_echo "$OPENJDK_BUILD_OS-$OPENJDK_BUILD_CPU" >&6; } 14854 14855 # Convert the autoconf OS/CPU value to our own data, into the VAR_OS/CPU variables. 14856 14857 case "$host_os" in 14858 *linux*) 14859 VAR_OS=linux 14860 VAR_OS_TYPE=unix 14861 ;; 14862 *solaris*) 14863 VAR_OS=solaris 14864 VAR_OS_TYPE=unix 14865 ;; 14866 *darwin*) 14867 VAR_OS=macosx 14868 VAR_OS_TYPE=unix 14869 ;; 14870 *bsd*) 14871 VAR_OS=bsd 14872 VAR_OS_TYPE=unix 14873 ;; 14874 *cygwin*) 14875 VAR_OS=windows 14876 VAR_OS_ENV=windows.cygwin 14877 ;; 14878 *mingw*) 14879 VAR_OS=windows 14880 VAR_OS_ENV=windows.msys 14881 ;; 14882 *aix*) 14883 VAR_OS=aix 14884 VAR_OS_TYPE=unix 14885 ;; 14886 *) 14887 as_fn_error $? "unsupported operating system $host_os" "$LINENO" 5 14888 ;; 14889 esac 14890 14891 14892 # First argument is the cpu name from the trip/quad 14893 case "$host_cpu" in 14894 x86_64) 14895 VAR_CPU=x86_64 14896 VAR_CPU_ARCH=x86 14897 VAR_CPU_BITS=64 14898 VAR_CPU_ENDIAN=little 14899 ;; 14900 i?86) 14901 VAR_CPU=x86 14902 VAR_CPU_ARCH=x86 14903 VAR_CPU_BITS=32 14904 VAR_CPU_ENDIAN=little 14905 ;; 14906 arm*) 14907 VAR_CPU=arm 14908 VAR_CPU_ARCH=arm 14909 VAR_CPU_BITS=32 14910 VAR_CPU_ENDIAN=little 14911 ;; 14912 aarch64) 14913 VAR_CPU=aarch64 14914 VAR_CPU_ARCH=aarch64 14915 VAR_CPU_BITS=64 14916 VAR_CPU_ENDIAN=little 14917 ;; 14918 powerpc) 14919 VAR_CPU=ppc 14920 VAR_CPU_ARCH=ppc 14921 VAR_CPU_BITS=32 14922 VAR_CPU_ENDIAN=big 14923 ;; 14924 powerpc64) 14925 VAR_CPU=ppc64 14926 VAR_CPU_ARCH=ppc 14927 VAR_CPU_BITS=64 14928 VAR_CPU_ENDIAN=big 14929 ;; 14930 powerpc64le) 14931 VAR_CPU=ppc64 14932 VAR_CPU_ARCH=ppc 14933 VAR_CPU_BITS=64 14934 VAR_CPU_ENDIAN=little 14935 ;; 14936 s390) 14937 VAR_CPU=s390 14938 VAR_CPU_ARCH=s390 14939 VAR_CPU_BITS=32 14940 VAR_CPU_ENDIAN=big 14941 ;; 14942 s390x) 14943 VAR_CPU=s390x 14944 VAR_CPU_ARCH=s390 14945 VAR_CPU_BITS=64 14946 VAR_CPU_ENDIAN=big 14947 ;; 14948 sparc) 14949 VAR_CPU=sparc 14950 VAR_CPU_ARCH=sparc 14951 VAR_CPU_BITS=32 14952 VAR_CPU_ENDIAN=big 14953 ;; 14954 sparcv9|sparc64) 14955 VAR_CPU=sparcv9 14956 VAR_CPU_ARCH=sparc 14957 VAR_CPU_BITS=64 14958 VAR_CPU_ENDIAN=big 14959 ;; 14960 *) 14961 as_fn_error $? "unsupported cpu $host_cpu" "$LINENO" 5 14962 ;; 14963 esac 14964 14965 # ... and setup our own variables. (Do this explicitely to facilitate searching) 14966 OPENJDK_TARGET_OS="$VAR_OS" 14967 if test "x$VAR_OS_TYPE" != x; then 14968 OPENJDK_TARGET_OS_TYPE="$VAR_OS_TYPE" 14969 else 14970 OPENJDK_TARGET_OS_TYPE="$VAR_OS" 14971 fi 14972 if test "x$VAR_OS_ENV" != x; then 14973 OPENJDK_TARGET_OS_ENV="$VAR_OS_ENV" 14974 else 14975 OPENJDK_TARGET_OS_ENV="$VAR_OS" 14976 fi 14977 OPENJDK_TARGET_CPU="$VAR_CPU" 14978 OPENJDK_TARGET_CPU_ARCH="$VAR_CPU_ARCH" 14979 OPENJDK_TARGET_CPU_BITS="$VAR_CPU_BITS" 14980 OPENJDK_TARGET_CPU_ENDIAN="$VAR_CPU_ENDIAN" 14981 14982 14983 14984 14985 14986 14987 14988 14989 { $as_echo "$as_me:${as_lineno-$LINENO}: checking openjdk-target os-cpu" >&5 14990 $as_echo_n "checking openjdk-target os-cpu... " >&6; } 14991 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" >&5 14992 $as_echo "$OPENJDK_TARGET_OS-$OPENJDK_TARGET_CPU" >&6; } 14993 14994 14995 14996 # Check whether --with-target-bits was given. 14997 if test "${with_target_bits+set}" = set; then : 14998 withval=$with_target_bits; 14999 fi 15000 15001 15002 # We have three types of compiles: 15003 # native == normal compilation, target system == build system 15004 # cross == traditional cross compilation, target system != build system; special toolchain needed 15005 # reduced == using native compilers, but with special flags (e.g. -m32) to produce 32-bit builds on 64-bit machines 15006 # 15007 if test "x$OPENJDK_BUILD_AUTOCONF_NAME" != "x$OPENJDK_TARGET_AUTOCONF_NAME"; then 15008 # We're doing a proper cross-compilation 15009 COMPILE_TYPE="cross" 15010 else 15011 COMPILE_TYPE="native" 15012 fi 15013 15014 if test "x$with_target_bits" != x; then 15015 if test "x$COMPILE_TYPE" = "xcross"; then 15016 as_fn_error $? "It is not possible to combine --with-target-bits=X and proper cross-compilation. Choose either." "$LINENO" 5 15017 fi 15018 15019 if test "x$with_target_bits" = x32 && test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 15020 # A reduced build is requested 15021 COMPILE_TYPE="reduced" 15022 OPENJDK_TARGET_CPU_BITS=32 15023 if test "x$OPENJDK_TARGET_CPU_ARCH" = "xx86"; then 15024 OPENJDK_TARGET_CPU=x86 15025 elif test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then 15026 OPENJDK_TARGET_CPU=sparc 15027 else 15028 as_fn_error $? "Reduced build (--with-target-bits=32) is only supported on x86_64 and sparcv9" "$LINENO" 5 15029 fi 15030 elif test "x$with_target_bits" = x64 && test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 15031 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 15032 elif test "x$with_target_bits" = "x$OPENJDK_TARGET_CPU_BITS"; then 15033 { $as_echo "$as_me:${as_lineno-$LINENO}: --with-target-bits are set to build platform address size; argument has no meaning" >&5 15034 $as_echo "$as_me: --with-target-bits are set to build platform address size; argument has no meaning" >&6;} 15035 else 15036 as_fn_error $? "--with-target-bits can only be 32 or 64, you specified $with_target_bits!" "$LINENO" 5 15037 fi 15038 fi 15039 15040 15041 { $as_echo "$as_me:${as_lineno-$LINENO}: checking compilation type" >&5 15042 $as_echo_n "checking compilation type... " >&6; } 15043 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $COMPILE_TYPE" >&5 15044 $as_echo "$COMPILE_TYPE" >&6; } 15045 15046 15047 if test "x$OPENJDK_TARGET_OS" = "xsolaris"; then 15048 REQUIRED_OS_NAME=SunOS 15049 REQUIRED_OS_VERSION=5.10 15050 fi 15051 if test "x$OPENJDK_TARGET_OS" = "xlinux"; then 15052 REQUIRED_OS_NAME=Linux 15053 REQUIRED_OS_VERSION=2.6 15054 fi 15055 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 15056 REQUIRED_OS_NAME=Windows 15057 if test "x$OPENJDK_TARGET_CPU_BITS" = "x64"; then 15058 REQUIRED_OS_VERSION=5.2 15059 else 15060 REQUIRED_OS_VERSION=5.1 15061 fi 15062 fi 15063 if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then 15064 REQUIRED_OS_NAME=Darwin 15065 REQUIRED_OS_VERSION=11.2 15066 fi 15067 15068 15069 15070 15071 15072 # Also store the legacy naming of the cpu. 15073 # Ie i586 and amd64 instead of x86 and x86_64 15074 OPENJDK_TARGET_CPU_LEGACY="$OPENJDK_TARGET_CPU" 15075 if test "x$OPENJDK_TARGET_CPU" = xx86; then 15076 OPENJDK_TARGET_CPU_LEGACY="i586" 15077 elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then 15078 # On all platforms except MacOSX replace x86_64 with amd64. 15079 OPENJDK_TARGET_CPU_LEGACY="amd64" 15080 fi 15081 15082 15083 # And the second legacy naming of the cpu. 15084 # Ie i386 and amd64 instead of x86 and x86_64. 15085 OPENJDK_TARGET_CPU_LEGACY_LIB="$OPENJDK_TARGET_CPU" 15086 if test "x$OPENJDK_TARGET_CPU" = xx86; then 15087 OPENJDK_TARGET_CPU_LEGACY_LIB="i386" 15088 elif test "x$OPENJDK_TARGET_CPU" = xx86_64; then 15089 OPENJDK_TARGET_CPU_LEGACY_LIB="amd64" 15090 fi 15091 15092 15093 # This is the name of the cpu (but using i386 and amd64 instead of 15094 # x86 and x86_64, respectively), preceeded by a /, to be used when 15095 # locating libraries. On macosx, it's empty, though. 15096 OPENJDK_TARGET_CPU_LIBDIR="/$OPENJDK_TARGET_CPU_LEGACY_LIB" 15097 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 15098 OPENJDK_TARGET_CPU_LIBDIR="" 15099 fi 15100 15101 15102 # OPENJDK_TARGET_CPU_ISADIR is normally empty. On 64-bit Solaris systems, it is set to 15103 # /amd64 or /sparcv9. This string is appended to some library paths, like this: 15104 # /usr/lib${OPENJDK_TARGET_CPU_ISADIR}/libexample.so 15105 OPENJDK_TARGET_CPU_ISADIR="" 15106 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 15107 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 15108 OPENJDK_TARGET_CPU_ISADIR="/amd64" 15109 elif test "x$OPENJDK_TARGET_CPU" = xsparcv9; then 15110 OPENJDK_TARGET_CPU_ISADIR="/sparcv9" 15111 fi 15112 fi 15113 15114 15115 # Setup OPENJDK_TARGET_CPU_OSARCH, which is used to set the os.arch Java system property 15116 OPENJDK_TARGET_CPU_OSARCH="$OPENJDK_TARGET_CPU" 15117 if test "x$OPENJDK_TARGET_OS" = xlinux && test "x$OPENJDK_TARGET_CPU" = xx86; then 15118 # On linux only, we replace x86 with i386. 15119 OPENJDK_TARGET_CPU_OSARCH="i386" 15120 elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then 15121 # On all platforms except macosx, we replace x86_64 with amd64. 15122 OPENJDK_TARGET_CPU_OSARCH="amd64" 15123 fi 15124 15125 15126 OPENJDK_TARGET_CPU_JLI="$OPENJDK_TARGET_CPU" 15127 if test "x$OPENJDK_TARGET_CPU" = xx86; then 15128 OPENJDK_TARGET_CPU_JLI="i386" 15129 elif test "x$OPENJDK_TARGET_OS" != xmacosx && test "x$OPENJDK_TARGET_CPU" = xx86_64; then 15130 # On all platforms except macosx, we replace x86_64 with amd64. 15131 OPENJDK_TARGET_CPU_JLI="amd64" 15132 fi 15133 # Now setup the -D flags for building libjli. 15134 OPENJDK_TARGET_CPU_JLI_CFLAGS="-DLIBARCHNAME='\"$OPENJDK_TARGET_CPU_JLI\"'" 15135 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 15136 if test "x$OPENJDK_TARGET_CPU_ARCH" = xsparc; then 15137 OPENJDK_TARGET_CPU_JLI_CFLAGS="$OPENJDK_TARGET_CPU_JLI_CFLAGS -DLIBARCH32NAME='\"sparc\"' -DLIBARCH64NAME='\"sparcv9\"'" 15138 elif test "x$OPENJDK_TARGET_CPU_ARCH" = xx86; then 15139 OPENJDK_TARGET_CPU_JLI_CFLAGS="$OPENJDK_TARGET_CPU_JLI_CFLAGS -DLIBARCH32NAME='\"i386\"' -DLIBARCH64NAME='\"amd64\"'" 15140 fi 15141 fi 15142 15143 15144 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 15145 OPENJDK_TARGET_OS_EXPORT_DIR=macosx 15146 else 15147 OPENJDK_TARGET_OS_EXPORT_DIR=${OPENJDK_TARGET_OS_TYPE} 15148 fi 15149 15150 15151 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 15152 A_LP64="LP64:=" 15153 # -D_LP64=1 is only set on linux and mac. Setting on windows causes diff in 15154 # unpack200.exe 15155 if test "x$OPENJDK_TARGET_OS" = xlinux || test "x$OPENJDK_TARGET_OS" = xmacosx; then 15156 ADD_LP64="-D_LP64=1" 15157 fi 15158 fi 15159 LP64=$A_LP64 15160 15161 15162 if test "x$COMPILE_TYPE" = "xcross"; then 15163 # FIXME: ... or should this include reduced builds..? 15164 DEFINE_CROSS_COMPILE_ARCH="CROSS_COMPILE_ARCH:=$OPENJDK_TARGET_CPU_LEGACY" 15165 else 15166 DEFINE_CROSS_COMPILE_ARCH="" 15167 fi 15168 15169 15170 # ZERO_ARCHDEF is used to enable architecture-specific code 15171 case "${OPENJDK_TARGET_CPU}" in 15172 ppc) ZERO_ARCHDEF=PPC32 ;; 15173 ppc64) ZERO_ARCHDEF=PPC64 ;; 15174 s390*) ZERO_ARCHDEF=S390 ;; 15175 sparc*) ZERO_ARCHDEF=SPARC ;; 15176 x86_64*) ZERO_ARCHDEF=AMD64 ;; 15177 x86) ZERO_ARCHDEF=IA32 ;; 15178 *) ZERO_ARCHDEF=$(echo "${OPENJDK_TARGET_CPU_LEGACY_LIB}" | tr a-z A-Z) 15179 esac 15180 15181 15182 15183 15184 # Continue setting up basic stuff. Most remaining code require fundamental tools. 15185 15186 # Save the current directory this script was started from 15187 CURDIR="$PWD" 15188 15189 # We might need to rewrite ORIGINAL_PATH, if it includes "#", to quote them 15190 # for make. We couldn't do this when we retrieved ORIGINAL_PATH, since SED 15191 # was not available at that time. 15192 REWRITTEN_PATH=`$ECHO "$ORIGINAL_PATH" | $SED -e 's/#/\\\\#/g'` 15193 if test "x$REWRITTEN_PATH" != "x$ORIGINAL_PATH"; then 15194 ORIGINAL_PATH="$REWRITTEN_PATH" 15195 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting ORIGINAL_PATH to $REWRITTEN_PATH" >&5 15196 $as_echo "$as_me: Rewriting ORIGINAL_PATH to $REWRITTEN_PATH" >&6;} 15197 fi 15198 15199 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 15200 PATH_SEP=";" 15201 15202 SRC_ROOT_LENGTH=`$THEPWDCMD -L|$WC -m` 15203 if test $SRC_ROOT_LENGTH -gt 100; then 15204 as_fn_error $? "Your base path is too long. It is $SRC_ROOT_LENGTH characters long, but only 100 is supported" "$LINENO" 5 15205 fi 15206 15207 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 15208 { $as_echo "$as_me:${as_lineno-$LINENO}: checking cygwin release" >&5 15209 $as_echo_n "checking cygwin release... " >&6; } 15210 CYGWIN_VERSION=`$UNAME -r` 15211 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_VERSION" >&5 15212 $as_echo "$CYGWIN_VERSION" >&6; } 15213 WINDOWS_ENV_VENDOR='cygwin' 15214 WINDOWS_ENV_VERSION="$CYGWIN_VERSION" 15215 15216 CYGWIN_VERSION_OLD=`$ECHO $CYGWIN_VERSION | $GREP -e '^1\.0-6'` 15217 if test "x$CYGWIN_VERSION_OLD" != x; then 15218 { $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 15219 $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;} 15220 as_fn_error $? "Cannot continue" "$LINENO" 5 15221 fi 15222 if test "x$CYGPATH" = x; then 15223 as_fn_error $? "Something is wrong with your cygwin installation since I cannot find cygpath.exe in your path" "$LINENO" 5 15224 fi 15225 { $as_echo "$as_me:${as_lineno-$LINENO}: checking cygwin root directory as unix-style path" >&5 15226 $as_echo_n "checking cygwin root directory as unix-style path... " >&6; } 15227 # The cmd output ends with Windows line endings (CR/LF), the grep command will strip that away 15228 cygwin_winpath_root=`cd / ; cmd /c cd | grep ".*"` 15229 # Force cygpath to report the proper root by including a trailing space, and then stripping it off again. 15230 CYGWIN_ROOT_PATH=`$CYGPATH -u "$cygwin_winpath_root " | $CUT -f 1 -d " "` 15231 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_ROOT_PATH" >&5 15232 $as_echo "$CYGWIN_ROOT_PATH" >&6; } 15233 WINDOWS_ENV_ROOT_PATH="$CYGWIN_ROOT_PATH" 15234 test_cygdrive_prefix=`$ECHO $CYGWIN_ROOT_PATH | $GREP ^/cygdrive/` 15235 if test "x$test_cygdrive_prefix" = x; then 15236 as_fn_error $? "Your cygdrive prefix is not /cygdrive. This is currently not supported. Change with mount -c." "$LINENO" 5 15237 fi 15238 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 15239 { $as_echo "$as_me:${as_lineno-$LINENO}: checking msys release" >&5 15240 $as_echo_n "checking msys release... " >&6; } 15241 MSYS_VERSION=`$UNAME -r` 15242 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSYS_VERSION" >&5 15243 $as_echo "$MSYS_VERSION" >&6; } 15244 15245 WINDOWS_ENV_VENDOR='msys' 15246 WINDOWS_ENV_VERSION="$MSYS_VERSION" 15247 15248 { $as_echo "$as_me:${as_lineno-$LINENO}: checking msys root directory as unix-style path" >&5 15249 $as_echo_n "checking msys root directory as unix-style path... " >&6; } 15250 # The cmd output ends with Windows line endings (CR/LF), the grep command will strip that away 15251 MSYS_ROOT_PATH=`cd / ; cmd /c cd | grep ".*"` 15252 15253 windows_path="$MSYS_ROOT_PATH" 15254 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 15255 unix_path=`$CYGPATH -u "$windows_path"` 15256 MSYS_ROOT_PATH="$unix_path" 15257 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 15258 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 15259 MSYS_ROOT_PATH="$unix_path" 15260 fi 15261 15262 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSYS_ROOT_PATH" >&5 15263 $as_echo "$MSYS_ROOT_PATH" >&6; } 15264 WINDOWS_ENV_ROOT_PATH="$MSYS_ROOT_PATH" 15265 else 15266 as_fn_error $? "Unknown Windows environment. Neither cygwin nor msys was detected." "$LINENO" 5 15267 fi 15268 15269 # Test if windows or unix (cygwin/msys) find is first in path. 15270 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what kind of 'find' is first on the PATH" >&5 15271 $as_echo_n "checking what kind of 'find' is first on the PATH... " >&6; } 15272 FIND_BINARY_OUTPUT=`find --version 2>&1` 15273 if test "x`echo $FIND_BINARY_OUTPUT | $GREP GNU`" != x; then 15274 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unix style" >&5 15275 $as_echo "unix style" >&6; } 15276 elif test "x`echo $FIND_BINARY_OUTPUT | $GREP FIND`" != x; then 15277 { $as_echo "$as_me:${as_lineno-$LINENO}: result: Windows" >&5 15278 $as_echo "Windows" >&6; } 15279 { $as_echo "$as_me:${as_lineno-$LINENO}: Your path contains Windows tools (C:\Windows\system32) before your unix (cygwin or msys) tools." >&5 15280 $as_echo "$as_me: Your path contains Windows tools (C:\Windows\system32) before your unix (cygwin or msys) tools." >&6;} 15281 { $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 15282 $as_echo "$as_me: This will not work. Please correct and make sure /usr/bin (or similar) is first in path." >&6;} 15283 as_fn_error $? "Cannot continue" "$LINENO" 5 15284 else 15285 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unknown" >&5 15286 $as_echo "unknown" >&6; } 15287 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: It seems that your find utility is non-standard." >&5 15288 $as_echo "$as_me: WARNING: It seems that your find utility is non-standard." >&2;} 15289 fi 15290 15291 else 15292 PATH_SEP=":" 15293 fi 15294 15295 15296 # We get the top-level directory from the supporting wrappers. 15297 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for top-level directory" >&5 15298 $as_echo_n "checking for top-level directory... " >&6; } 15299 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOPDIR" >&5 15300 $as_echo "$TOPDIR" >&6; } 15301 15302 15303 # Save the original version of TOPDIR for string comparisons 15304 ORIGINAL_TOPDIR="$TOPDIR" 15305 15306 15307 # We can only call BASIC_FIXUP_PATH after BASIC_CHECK_PATHS_WINDOWS. 15308 15309 # Only process if variable expands to non-empty 15310 15311 if test "x$CURDIR" != x; then 15312 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 15313 15314 # Input might be given as Windows format, start by converting to 15315 # unix format. 15316 path="$CURDIR" 15317 new_path=`$CYGPATH -u "$path"` 15318 15319 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 15320 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 15321 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 15322 # "foo.exe" is OK but "foo" is an error. 15323 # 15324 # This test is therefore slightly more accurate than "test -f" to check for file precense. 15325 # It is also a way to make sure we got the proper file name for the real test later on. 15326 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 15327 if test "x$test_shortpath" = x; then 15328 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CURDIR, which resolves as \"$path\", is invalid." >&5 15329 $as_echo "$as_me: The path of CURDIR, which resolves as \"$path\", is invalid." >&6;} 15330 as_fn_error $? "Cannot locate the the path of CURDIR" "$LINENO" 5 15331 fi 15332 15333 # Call helper function which possibly converts this using DOS-style short mode. 15334 # If so, the updated path is stored in $new_path. 15335 15336 input_path="$new_path" 15337 # Check if we need to convert this using DOS-style short mode. If the path 15338 # contains just simple characters, use it. Otherwise (spaces, weird characters), 15339 # take no chances and rewrite it. 15340 # Note: m4 eats our [], so we need to use [ and ] instead. 15341 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 15342 if test "x$has_forbidden_chars" != x; then 15343 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 15344 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 15345 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 15346 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 15347 # Going to short mode and back again did indeed matter. Since short mode is 15348 # case insensitive, let's make it lowercase to improve readability. 15349 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 15350 # Now convert it back to Unix-style (cygpath) 15351 input_path=`$CYGPATH -u "$shortmode_path"` 15352 new_path="$input_path" 15353 fi 15354 fi 15355 15356 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 15357 if test "x$test_cygdrive_prefix" = x; then 15358 # As a simple fix, exclude /usr/bin since it's not a real path. 15359 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 15360 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 15361 # a path prefixed by /cygdrive for fixpath to work. 15362 new_path="$CYGWIN_ROOT_PATH$input_path" 15363 fi 15364 fi 15365 15366 15367 if test "x$path" != "x$new_path"; then 15368 CURDIR="$new_path" 15369 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CURDIR to \"$new_path\"" >&5 15370 $as_echo "$as_me: Rewriting CURDIR to \"$new_path\"" >&6;} 15371 fi 15372 15373 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 15374 15375 path="$CURDIR" 15376 has_colon=`$ECHO $path | $GREP ^.:` 15377 new_path="$path" 15378 if test "x$has_colon" = x; then 15379 # Not in mixed or Windows style, start by that. 15380 new_path=`cmd //c echo $path` 15381 fi 15382 15383 15384 input_path="$new_path" 15385 # Check if we need to convert this using DOS-style short mode. If the path 15386 # contains just simple characters, use it. Otherwise (spaces, weird characters), 15387 # take no chances and rewrite it. 15388 # Note: m4 eats our [], so we need to use [ and ] instead. 15389 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 15390 if test "x$has_forbidden_chars" != x; then 15391 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 15392 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 15393 fi 15394 15395 15396 windows_path="$new_path" 15397 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 15398 unix_path=`$CYGPATH -u "$windows_path"` 15399 new_path="$unix_path" 15400 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 15401 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 15402 new_path="$unix_path" 15403 fi 15404 15405 if test "x$path" != "x$new_path"; then 15406 CURDIR="$new_path" 15407 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CURDIR to \"$new_path\"" >&5 15408 $as_echo "$as_me: Rewriting CURDIR to \"$new_path\"" >&6;} 15409 fi 15410 15411 # Save the first 10 bytes of this path to the storage, so fixpath can work. 15412 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 15413 15414 else 15415 # We're on a unix platform. Hooray! :) 15416 path="$CURDIR" 15417 has_space=`$ECHO "$path" | $GREP " "` 15418 if test "x$has_space" != x; then 15419 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CURDIR, which resolves as \"$path\", is invalid." >&5 15420 $as_echo "$as_me: The path of CURDIR, which resolves as \"$path\", is invalid." >&6;} 15421 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 15422 fi 15423 15424 # Use eval to expand a potential ~ 15425 eval path="$path" 15426 if test ! -f "$path" && test ! -d "$path"; then 15427 as_fn_error $? "The path of CURDIR, which resolves as \"$path\", is not found." "$LINENO" 5 15428 fi 15429 15430 if test -d "$path"; then 15431 CURDIR="`cd "$path"; $THEPWDCMD -L`" 15432 else 15433 dir="`$DIRNAME "$path"`" 15434 base="`$BASENAME "$path"`" 15435 CURDIR="`cd "$dir"; $THEPWDCMD -L`/$base" 15436 fi 15437 fi 15438 fi 15439 15440 15441 # Only process if variable expands to non-empty 15442 15443 if test "x$TOPDIR" != x; then 15444 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 15445 15446 # Input might be given as Windows format, start by converting to 15447 # unix format. 15448 path="$TOPDIR" 15449 new_path=`$CYGPATH -u "$path"` 15450 15451 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 15452 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 15453 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 15454 # "foo.exe" is OK but "foo" is an error. 15455 # 15456 # This test is therefore slightly more accurate than "test -f" to check for file precense. 15457 # It is also a way to make sure we got the proper file name for the real test later on. 15458 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 15459 if test "x$test_shortpath" = x; then 15460 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of TOPDIR, which resolves as \"$path\", is invalid." >&5 15461 $as_echo "$as_me: The path of TOPDIR, which resolves as \"$path\", is invalid." >&6;} 15462 as_fn_error $? "Cannot locate the the path of TOPDIR" "$LINENO" 5 15463 fi 15464 15465 # Call helper function which possibly converts this using DOS-style short mode. 15466 # If so, the updated path is stored in $new_path. 15467 15468 input_path="$new_path" 15469 # Check if we need to convert this using DOS-style short mode. If the path 15470 # contains just simple characters, use it. Otherwise (spaces, weird characters), 15471 # take no chances and rewrite it. 15472 # Note: m4 eats our [], so we need to use [ and ] instead. 15473 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 15474 if test "x$has_forbidden_chars" != x; then 15475 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 15476 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 15477 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 15478 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 15479 # Going to short mode and back again did indeed matter. Since short mode is 15480 # case insensitive, let's make it lowercase to improve readability. 15481 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 15482 # Now convert it back to Unix-style (cygpath) 15483 input_path=`$CYGPATH -u "$shortmode_path"` 15484 new_path="$input_path" 15485 fi 15486 fi 15487 15488 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 15489 if test "x$test_cygdrive_prefix" = x; then 15490 # As a simple fix, exclude /usr/bin since it's not a real path. 15491 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 15492 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 15493 # a path prefixed by /cygdrive for fixpath to work. 15494 new_path="$CYGWIN_ROOT_PATH$input_path" 15495 fi 15496 fi 15497 15498 15499 if test "x$path" != "x$new_path"; then 15500 TOPDIR="$new_path" 15501 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting TOPDIR to \"$new_path\"" >&5 15502 $as_echo "$as_me: Rewriting TOPDIR to \"$new_path\"" >&6;} 15503 fi 15504 15505 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 15506 15507 path="$TOPDIR" 15508 has_colon=`$ECHO $path | $GREP ^.:` 15509 new_path="$path" 15510 if test "x$has_colon" = x; then 15511 # Not in mixed or Windows style, start by that. 15512 new_path=`cmd //c echo $path` 15513 fi 15514 15515 15516 input_path="$new_path" 15517 # Check if we need to convert this using DOS-style short mode. If the path 15518 # contains just simple characters, use it. Otherwise (spaces, weird characters), 15519 # take no chances and rewrite it. 15520 # Note: m4 eats our [], so we need to use [ and ] instead. 15521 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 15522 if test "x$has_forbidden_chars" != x; then 15523 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 15524 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 15525 fi 15526 15527 15528 windows_path="$new_path" 15529 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 15530 unix_path=`$CYGPATH -u "$windows_path"` 15531 new_path="$unix_path" 15532 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 15533 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 15534 new_path="$unix_path" 15535 fi 15536 15537 if test "x$path" != "x$new_path"; then 15538 TOPDIR="$new_path" 15539 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting TOPDIR to \"$new_path\"" >&5 15540 $as_echo "$as_me: Rewriting TOPDIR to \"$new_path\"" >&6;} 15541 fi 15542 15543 # Save the first 10 bytes of this path to the storage, so fixpath can work. 15544 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 15545 15546 else 15547 # We're on a unix platform. Hooray! :) 15548 path="$TOPDIR" 15549 has_space=`$ECHO "$path" | $GREP " "` 15550 if test "x$has_space" != x; then 15551 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of TOPDIR, which resolves as \"$path\", is invalid." >&5 15552 $as_echo "$as_me: The path of TOPDIR, which resolves as \"$path\", is invalid." >&6;} 15553 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 15554 fi 15555 15556 # Use eval to expand a potential ~ 15557 eval path="$path" 15558 if test ! -f "$path" && test ! -d "$path"; then 15559 as_fn_error $? "The path of TOPDIR, which resolves as \"$path\", is not found." "$LINENO" 5 15560 fi 15561 15562 if test -d "$path"; then 15563 TOPDIR="`cd "$path"; $THEPWDCMD -L`" 15564 else 15565 dir="`$DIRNAME "$path"`" 15566 base="`$BASENAME "$path"`" 15567 TOPDIR="`cd "$dir"; $THEPWDCMD -L`/$base" 15568 fi 15569 fi 15570 fi 15571 15572 # SRC_ROOT is a traditional alias for TOPDIR. 15573 SRC_ROOT=$TOPDIR 15574 15575 # Calculate a canonical version of TOPDIR for string comparisons 15576 CANONICAL_TOPDIR=$TOPDIR 15577 15578 if test "x$OPENJDK_BUILD_OS" != xwindows; then 15579 # Follow a chain of symbolic links. Use readlink 15580 # where it exists, else fall back to horribly 15581 # complicated shell code. 15582 if test "x$READLINK_TESTED" != yes; then 15583 # On MacOSX there is a readlink tool with a different 15584 # purpose than the GNU readlink tool. Check the found readlink. 15585 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 15586 if test "x$ISGNU" = x; then 15587 # A readlink that we do not know how to use. 15588 # Are there other non-GNU readlinks out there? 15589 READLINK_TESTED=yes 15590 READLINK= 15591 fi 15592 fi 15593 15594 if test "x$READLINK" != x; then 15595 CANONICAL_TOPDIR=`$READLINK -f $CANONICAL_TOPDIR` 15596 else 15597 # Save the current directory for restoring afterwards 15598 STARTDIR=$PWD 15599 COUNTER=0 15600 sym_link_dir=`$DIRNAME $CANONICAL_TOPDIR` 15601 sym_link_file=`$BASENAME $CANONICAL_TOPDIR` 15602 cd $sym_link_dir 15603 # Use -P flag to resolve symlinks in directories. 15604 cd `$THEPWDCMD -P` 15605 sym_link_dir=`$THEPWDCMD -P` 15606 # Resolve file symlinks 15607 while test $COUNTER -lt 20; do 15608 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 15609 if test "x$ISLINK" == x; then 15610 # This is not a symbolic link! We are done! 15611 break 15612 fi 15613 # Again resolve directory symlinks since the target of the just found 15614 # link could be in a different directory 15615 cd `$DIRNAME $ISLINK` 15616 sym_link_dir=`$THEPWDCMD -P` 15617 sym_link_file=`$BASENAME $ISLINK` 15618 let COUNTER=COUNTER+1 15619 done 15620 cd $STARTDIR 15621 CANONICAL_TOPDIR=$sym_link_dir/$sym_link_file 15622 fi 15623 fi 15624 15625 15626 15627 # Locate the directory of this script. 15628 AUTOCONF_DIR=$TOPDIR/common/autoconf 15629 15630 15631 # Check if it's a pure open build or if custom sources are to be used. 15632 15633 # Check whether --enable-openjdk-only was given. 15634 if test "${enable_openjdk_only+set}" = set; then : 15635 enableval=$enable_openjdk_only; 15636 else 15637 enable_openjdk_only="no" 15638 fi 15639 15640 15641 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for presence of closed sources" >&5 15642 $as_echo_n "checking for presence of closed sources... " >&6; } 15643 if test -d "$SRC_ROOT/jdk/src/closed"; then 15644 CLOSED_SOURCE_PRESENT=yes 15645 else 15646 CLOSED_SOURCE_PRESENT=no 15647 fi 15648 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CLOSED_SOURCE_PRESENT" >&5 15649 $as_echo "$CLOSED_SOURCE_PRESENT" >&6; } 15650 15651 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if closed source is suppressed (openjdk-only)" >&5 15652 $as_echo_n "checking if closed source is suppressed (openjdk-only)... " >&6; } 15653 SUPPRESS_CLOSED_SOURCE="$enable_openjdk_only" 15654 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SUPPRESS_CLOSED_SOURCE" >&5 15655 $as_echo "$SUPPRESS_CLOSED_SOURCE" >&6; } 15656 15657 if test "x$CLOSED_SOURCE_PRESENT" = xno; then 15658 OPENJDK=true 15659 if test "x$SUPPRESS_CLOSED_SOURCE" = "xyes"; then 15660 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: No closed source present, --enable-openjdk-only makes no sense" >&5 15661 $as_echo "$as_me: WARNING: No closed source present, --enable-openjdk-only makes no sense" >&2;} 15662 fi 15663 else 15664 if test "x$SUPPRESS_CLOSED_SOURCE" = "xyes"; then 15665 OPENJDK=true 15666 else 15667 OPENJDK=false 15668 fi 15669 fi 15670 15671 if test "x$OPENJDK" = "xtrue"; then 15672 SET_OPENJDK="OPENJDK=true" 15673 fi 15674 15675 15676 15677 # custom-make-dir is deprecated. Please use your custom-hook.m4 to override 15678 # the IncludeCustomExtension macro. 15679 15680 15681 # Check whether --with-custom-make-dir was given. 15682 if test "${with_custom_make_dir+set}" = set; then : 15683 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 15684 $as_echo "$as_me: WARNING: Option --with-custom-make-dir is deprecated and will be ignored." >&2;} 15685 fi 15686 15687 15688 15689 15690 # These are needed to be able to create a configuration name (and thus the output directory) 15691 15692 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variant of the JDK to build" >&5 15693 $as_echo_n "checking which variant of the JDK to build... " >&6; } 15694 15695 # Check whether --with-jdk-variant was given. 15696 if test "${with_jdk_variant+set}" = set; then : 15697 withval=$with_jdk_variant; 15698 fi 15699 15700 15701 if test "x$with_jdk_variant" = xnormal || test "x$with_jdk_variant" = x; then 15702 JDK_VARIANT="normal" 15703 else 15704 as_fn_error $? "The available JDK variants are: normal" "$LINENO" 5 15705 fi 15706 15707 15708 15709 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JDK_VARIANT" >&5 15710 $as_echo "$JDK_VARIANT" >&6; } 15711 15712 15713 15714 # Check whether --with-jvm-interpreter was given. 15715 if test "${with_jvm_interpreter+set}" = set; then : 15716 withval=$with_jvm_interpreter; 15717 fi 15718 15719 15720 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which interpreter of the JVM to build" >&5 15721 $as_echo_n "checking which interpreter of the JVM to build... " >&6; } 15722 if test "x$with_jvm_interpreter" = x; then 15723 JVM_INTERPRETER="template" 15724 else 15725 JVM_INTERPRETER="$with_jvm_interpreter" 15726 fi 15727 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JVM_INTERPRETER" >&5 15728 $as_echo "$JVM_INTERPRETER" >&6; } 15729 15730 if test "x$JVM_INTERPRETER" != xtemplate && test "x$JVM_INTERPRETER" != xcpp; then 15731 as_fn_error $? "The available JVM interpreters are: template, cpp" "$LINENO" 5 15732 fi 15733 15734 15735 15736 15737 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which variants of the JVM to build" >&5 15738 $as_echo_n "checking which variants of the JVM to build... " >&6; } 15739 15740 # Check whether --with-jvm-variants was given. 15741 if test "${with_jvm_variants+set}" = set; then : 15742 withval=$with_jvm_variants; 15743 fi 15744 15745 15746 if test "x$with_jvm_variants" = x; then 15747 with_jvm_variants="server" 15748 fi 15749 15750 JVM_VARIANTS=",$with_jvm_variants," 15751 TEST_VARIANTS=`$ECHO "$JVM_VARIANTS" | $SED -e 's/server,//' -e 's/client,//' -e 's/minimal1,//' -e 's/zero,//' -e 's/zeroshark,//' -e 's/core,//'` 15752 15753 if test "x$TEST_VARIANTS" != "x,"; then 15754 as_fn_error $? "The available JVM variants are: server, client, minimal1, zero, zeroshark, core" "$LINENO" 5 15755 fi 15756 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $with_jvm_variants" >&5 15757 $as_echo "$with_jvm_variants" >&6; } 15758 15759 JVM_VARIANT_SERVER=`$ECHO "$JVM_VARIANTS" | $SED -e '/,server,/!s/.*/false/g' -e '/,server,/s/.*/true/g'` 15760 JVM_VARIANT_CLIENT=`$ECHO "$JVM_VARIANTS" | $SED -e '/,client,/!s/.*/false/g' -e '/,client,/s/.*/true/g'` 15761 JVM_VARIANT_MINIMAL1=`$ECHO "$JVM_VARIANTS" | $SED -e '/,minimal1,/!s/.*/false/g' -e '/,minimal1,/s/.*/true/g'` 15762 JVM_VARIANT_ZERO=`$ECHO "$JVM_VARIANTS" | $SED -e '/,zero,/!s/.*/false/g' -e '/,zero,/s/.*/true/g'` 15763 JVM_VARIANT_ZEROSHARK=`$ECHO "$JVM_VARIANTS" | $SED -e '/,zeroshark,/!s/.*/false/g' -e '/,zeroshark,/s/.*/true/g'` 15764 JVM_VARIANT_CORE=`$ECHO "$JVM_VARIANTS" | $SED -e '/,core,/!s/.*/false/g' -e '/,core,/s/.*/true/g'` 15765 15766 if test "x$JVM_VARIANT_CLIENT" = xtrue; then 15767 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 15768 as_fn_error $? "You cannot build a client JVM for a 64-bit machine." "$LINENO" 5 15769 fi 15770 fi 15771 if test "x$JVM_VARIANT_MINIMAL1" = xtrue; then 15772 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 15773 as_fn_error $? "You cannot build a minimal JVM for a 64-bit machine." "$LINENO" 5 15774 fi 15775 fi 15776 15777 # Replace the commas with AND for use in the build directory name. 15778 ANDED_JVM_VARIANTS=`$ECHO "$JVM_VARIANTS" | $SED -e 's/^,//' -e 's/,$//' -e 's/,/AND/g'` 15779 COUNT_VARIANTS=`$ECHO "$JVM_VARIANTS" | $SED -e 's/server,/1/' -e 's/client,/1/' -e 's/minimal1,/1/' -e 's/zero,/1/' -e 's/zeroshark,/1/' -e 's/core,/1/'` 15780 if test "x$COUNT_VARIANTS" != "x,1"; then 15781 BUILDING_MULTIPLE_JVM_VARIANTS=yes 15782 else 15783 BUILDING_MULTIPLE_JVM_VARIANTS=no 15784 fi 15785 15786 if test "x$JVM_VARIANT_ZERO" = xtrue && test "x$BUILDING_MULTIPLE_JVM_VARIANTS" = xyes; then 15787 as_fn_error $? "You cannot build multiple variants with zero." "$LINENO" 5 15788 fi 15789 15790 15791 15792 15793 15794 15795 15796 15797 15798 INCLUDE_SA=true 15799 if test "x$JVM_VARIANT_ZERO" = xtrue ; then 15800 INCLUDE_SA=false 15801 fi 15802 if test "x$JVM_VARIANT_ZEROSHARK" = xtrue ; then 15803 INCLUDE_SA=false 15804 fi 15805 if test "x$OPENJDK_TARGET_OS" = xaix ; then 15806 INCLUDE_SA=false 15807 fi 15808 if test "x$OPENJDK_TARGET_CPU" = xaarch64; then 15809 INCLUDE_SA=false 15810 fi 15811 15812 15813 if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then 15814 MACOSX_UNIVERSAL="true" 15815 fi 15816 15817 15818 15819 15820 DEBUG_LEVEL="release" 15821 { $as_echo "$as_me:${as_lineno-$LINENO}: checking which debug level to use" >&5 15822 $as_echo_n "checking which debug level to use... " >&6; } 15823 # Check whether --enable-debug was given. 15824 if test "${enable_debug+set}" = set; then : 15825 enableval=$enable_debug; 15826 ENABLE_DEBUG="${enableval}" 15827 DEBUG_LEVEL="fastdebug" 15828 15829 else 15830 ENABLE_DEBUG="no" 15831 fi 15832 15833 15834 15835 # Check whether --with-debug-level was given. 15836 if test "${with_debug_level+set}" = set; then : 15837 withval=$with_debug_level; 15838 DEBUG_LEVEL="${withval}" 15839 if test "x$ENABLE_DEBUG" = xyes; then 15840 as_fn_error $? "You cannot use both --enable-debug and --with-debug-level at the same time." "$LINENO" 5 15841 fi 15842 15843 fi 15844 15845 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEBUG_LEVEL" >&5 15846 $as_echo "$DEBUG_LEVEL" >&6; } 15847 15848 if test "x$DEBUG_LEVEL" != xrelease && \ 15849 test "x$DEBUG_LEVEL" != xoptimized && \ 15850 test "x$DEBUG_LEVEL" != xfastdebug && \ 15851 test "x$DEBUG_LEVEL" != xslowdebug; then 15852 as_fn_error $? "Allowed debug levels are: release, fastdebug and slowdebug" "$LINENO" 5 15853 fi 15854 15855 15856 case $DEBUG_LEVEL in 15857 release ) 15858 VARIANT="OPT" 15859 FASTDEBUG="false" 15860 DEBUG_CLASSFILES="false" 15861 BUILD_VARIANT_RELEASE="" 15862 HOTSPOT_DEBUG_LEVEL="product" 15863 HOTSPOT_EXPORT="product" 15864 ;; 15865 fastdebug ) 15866 VARIANT="DBG" 15867 FASTDEBUG="true" 15868 DEBUG_CLASSFILES="true" 15869 BUILD_VARIANT_RELEASE="-fastdebug" 15870 HOTSPOT_DEBUG_LEVEL="fastdebug" 15871 HOTSPOT_EXPORT="fastdebug" 15872 ;; 15873 slowdebug ) 15874 VARIANT="DBG" 15875 FASTDEBUG="false" 15876 DEBUG_CLASSFILES="true" 15877 BUILD_VARIANT_RELEASE="-debug" 15878 HOTSPOT_DEBUG_LEVEL="debug" 15879 HOTSPOT_EXPORT="debug" 15880 ;; 15881 optimized ) 15882 VARIANT="OPT" 15883 FASTDEBUG="false" 15884 DEBUG_CLASSFILES="false" 15885 BUILD_VARIANT_RELEASE="-optimized" 15886 HOTSPOT_DEBUG_LEVEL="optimized" 15887 HOTSPOT_EXPORT="optimized" 15888 ;; 15889 esac 15890 15891 # The debug level 'optimized' is a little special because it is currently only 15892 # applicable to the HotSpot build where it means to build a completely 15893 # optimized version of the VM without any debugging code (like for the 15894 # 'release' debug level which is called 'product' in the HotSpot build) but 15895 # with the exception that it can contain additional code which is otherwise 15896 # protected by '#ifndef PRODUCT' macros. These 'optimized' builds are used to 15897 # test new and/or experimental features which are not intended for customer 15898 # shipment. Because these new features need to be tested and benchmarked in 15899 # real world scenarios, we want to build the containing JDK at the 'release' 15900 # debug level. 15901 if test "x$DEBUG_LEVEL" = xoptimized; then 15902 DEBUG_LEVEL="release" 15903 fi 15904 15905 ##### 15906 # Generate the legacy makefile targets for hotspot. 15907 # The hotspot api for selecting the build artifacts, really, needs to be improved. 15908 # JDK-7195896 will fix this on the hotspot side by using the JVM_VARIANT_* variables to 15909 # determine what needs to be built. All we will need to set here is all_product, all_fastdebug etc 15910 # But until then ... 15911 HOTSPOT_TARGET="" 15912 15913 if test "x$JVM_VARIANT_SERVER" = xtrue; then 15914 HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL} " 15915 fi 15916 15917 if test "x$JVM_VARIANT_CLIENT" = xtrue; then 15918 HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}1 " 15919 fi 15920 15921 if test "x$JVM_VARIANT_MINIMAL1" = xtrue; then 15922 HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}minimal1 " 15923 fi 15924 15925 if test "x$JVM_VARIANT_ZERO" = xtrue; then 15926 HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}zero " 15927 fi 15928 15929 if test "x$JVM_VARIANT_ZEROSHARK" = xtrue; then 15930 HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}shark " 15931 fi 15932 15933 if test "x$JVM_VARIANT_CORE" = xtrue; then 15934 HOTSPOT_TARGET="$HOTSPOT_TARGET${HOTSPOT_DEBUG_LEVEL}core " 15935 fi 15936 15937 HOTSPOT_TARGET="$HOTSPOT_TARGET docs export_$HOTSPOT_EXPORT" 15938 15939 # On Macosx universal binaries are produced, but they only contain 15940 # 64 bit intel. This invalidates control of which jvms are built 15941 # from configure, but only server is valid anyway. Fix this 15942 # when hotspot makefiles are rewritten. 15943 if test "x$MACOSX_UNIVERSAL" = xtrue; then 15944 HOTSPOT_TARGET=universal_${HOTSPOT_EXPORT} 15945 fi 15946 15947 ##### 15948 15949 15950 15951 15952 15953 15954 15955 15956 # With basic setup done, call the custom early hook. 15957 15958 15959 # Check if we have devkits, extra paths or sysroot set. 15960 15961 15962 # Check whether --with-devkit was given. 15963 if test "${with_devkit+set}" = set; then : 15964 withval=$with_devkit; 15965 15966 # Only process if variable expands to non-empty 15967 15968 if test "x$with_devkit" != x; then 15969 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 15970 15971 # Input might be given as Windows format, start by converting to 15972 # unix format. 15973 path="$with_devkit" 15974 new_path=`$CYGPATH -u "$path"` 15975 15976 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 15977 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 15978 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 15979 # "foo.exe" is OK but "foo" is an error. 15980 # 15981 # This test is therefore slightly more accurate than "test -f" to check for file precense. 15982 # It is also a way to make sure we got the proper file name for the real test later on. 15983 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 15984 if test "x$test_shortpath" = x; then 15985 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_devkit, which resolves as \"$path\", is invalid." >&5 15986 $as_echo "$as_me: The path of with_devkit, which resolves as \"$path\", is invalid." >&6;} 15987 as_fn_error $? "Cannot locate the the path of with_devkit" "$LINENO" 5 15988 fi 15989 15990 # Call helper function which possibly converts this using DOS-style short mode. 15991 # If so, the updated path is stored in $new_path. 15992 15993 input_path="$new_path" 15994 # Check if we need to convert this using DOS-style short mode. If the path 15995 # contains just simple characters, use it. Otherwise (spaces, weird characters), 15996 # take no chances and rewrite it. 15997 # Note: m4 eats our [], so we need to use [ and ] instead. 15998 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 15999 if test "x$has_forbidden_chars" != x; then 16000 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16001 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 16002 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 16003 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 16004 # Going to short mode and back again did indeed matter. Since short mode is 16005 # case insensitive, let's make it lowercase to improve readability. 16006 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16007 # Now convert it back to Unix-style (cygpath) 16008 input_path=`$CYGPATH -u "$shortmode_path"` 16009 new_path="$input_path" 16010 fi 16011 fi 16012 16013 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 16014 if test "x$test_cygdrive_prefix" = x; then 16015 # As a simple fix, exclude /usr/bin since it's not a real path. 16016 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 16017 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 16018 # a path prefixed by /cygdrive for fixpath to work. 16019 new_path="$CYGWIN_ROOT_PATH$input_path" 16020 fi 16021 fi 16022 16023 16024 if test "x$path" != "x$new_path"; then 16025 with_devkit="$new_path" 16026 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_devkit to \"$new_path\"" >&5 16027 $as_echo "$as_me: Rewriting with_devkit to \"$new_path\"" >&6;} 16028 fi 16029 16030 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16031 16032 path="$with_devkit" 16033 has_colon=`$ECHO $path | $GREP ^.:` 16034 new_path="$path" 16035 if test "x$has_colon" = x; then 16036 # Not in mixed or Windows style, start by that. 16037 new_path=`cmd //c echo $path` 16038 fi 16039 16040 16041 input_path="$new_path" 16042 # Check if we need to convert this using DOS-style short mode. If the path 16043 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16044 # take no chances and rewrite it. 16045 # Note: m4 eats our [], so we need to use [ and ] instead. 16046 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 16047 if test "x$has_forbidden_chars" != x; then 16048 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16049 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16050 fi 16051 16052 16053 windows_path="$new_path" 16054 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16055 unix_path=`$CYGPATH -u "$windows_path"` 16056 new_path="$unix_path" 16057 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16058 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16059 new_path="$unix_path" 16060 fi 16061 16062 if test "x$path" != "x$new_path"; then 16063 with_devkit="$new_path" 16064 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_devkit to \"$new_path\"" >&5 16065 $as_echo "$as_me: Rewriting with_devkit to \"$new_path\"" >&6;} 16066 fi 16067 16068 # Save the first 10 bytes of this path to the storage, so fixpath can work. 16069 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 16070 16071 else 16072 # We're on a unix platform. Hooray! :) 16073 path="$with_devkit" 16074 has_space=`$ECHO "$path" | $GREP " "` 16075 if test "x$has_space" != x; then 16076 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_devkit, which resolves as \"$path\", is invalid." >&5 16077 $as_echo "$as_me: The path of with_devkit, which resolves as \"$path\", is invalid." >&6;} 16078 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 16079 fi 16080 16081 # Use eval to expand a potential ~ 16082 eval path="$path" 16083 if test ! -f "$path" && test ! -d "$path"; then 16084 as_fn_error $? "The path of with_devkit, which resolves as \"$path\", is not found." "$LINENO" 5 16085 fi 16086 16087 if test -d "$path"; then 16088 with_devkit="`cd "$path"; $THEPWDCMD -L`" 16089 else 16090 dir="`$DIRNAME "$path"`" 16091 base="`$BASENAME "$path"`" 16092 with_devkit="`cd "$dir"; $THEPWDCMD -L`/$base" 16093 fi 16094 fi 16095 fi 16096 16097 DEVKIT_ROOT="$with_devkit" 16098 # Check for a meta data info file in the root of the devkit 16099 if test -f "$DEVKIT_ROOT/devkit.info"; then 16100 . $DEVKIT_ROOT/devkit.info 16101 # This potentially sets the following: 16102 # A descriptive name of the devkit 16103 16104 if test "x$DEVKIT_NAME" = x; then 16105 eval DEVKIT_NAME="\${DEVKIT_NAME_${OPENJDK_TARGET_CPU}}" 16106 fi 16107 16108 # Corresponds to --with-extra-path 16109 16110 if test "x$DEVKIT_EXTRA_PATH" = x; then 16111 eval DEVKIT_EXTRA_PATH="\${DEVKIT_EXTRA_PATH_${OPENJDK_TARGET_CPU}}" 16112 fi 16113 16114 # Corresponds to --with-toolchain-path 16115 16116 if test "x$DEVKIT_TOOLCHAIN_PATH" = x; then 16117 eval DEVKIT_TOOLCHAIN_PATH="\${DEVKIT_TOOLCHAIN_PATH_${OPENJDK_TARGET_CPU}}" 16118 fi 16119 16120 # Corresponds to --with-sysroot 16121 16122 if test "x$DEVKIT_SYSROOT" = x; then 16123 eval DEVKIT_SYSROOT="\${DEVKIT_SYSROOT_${OPENJDK_TARGET_CPU}}" 16124 fi 16125 16126 16127 # Identifies the Visual Studio version in the devkit 16128 16129 if test "x$DEVKIT_VS_VERSION" = x; then 16130 eval DEVKIT_VS_VERSION="\${DEVKIT_VS_VERSION_${OPENJDK_TARGET_CPU}}" 16131 fi 16132 16133 # The Visual Studio include environment variable 16134 16135 if test "x$DEVKIT_VS_INCLUDE" = x; then 16136 eval DEVKIT_VS_INCLUDE="\${DEVKIT_VS_INCLUDE_${OPENJDK_TARGET_CPU}}" 16137 fi 16138 16139 # The Visual Studio lib environment variable 16140 16141 if test "x$DEVKIT_VS_LIB" = x; then 16142 eval DEVKIT_VS_LIB="\${DEVKIT_VS_LIB_${OPENJDK_TARGET_CPU}}" 16143 fi 16144 16145 # Corresponds to --with-msvcr-dll 16146 16147 if test "x$DEVKIT_MSVCR_DLL" = x; then 16148 eval DEVKIT_MSVCR_DLL="\${DEVKIT_MSVCR_DLL_${OPENJDK_TARGET_CPU}}" 16149 fi 16150 16151 # Corresponds to --with-msvcp-dll 16152 16153 if test "x$DEVKIT_MSVCP_DLL" = x; then 16154 eval DEVKIT_MSVCP_DLL="\${DEVKIT_MSVCP_DLL_${OPENJDK_TARGET_CPU}}" 16155 fi 16156 16157 fi 16158 16159 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for devkit" >&5 16160 $as_echo_n "checking for devkit... " >&6; } 16161 if test "x$DEVKIT_NAME" != x; then 16162 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEVKIT_NAME in $DEVKIT_ROOT" >&5 16163 $as_echo "$DEVKIT_NAME in $DEVKIT_ROOT" >&6; } 16164 else 16165 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEVKIT_ROOT" >&5 16166 $as_echo "$DEVKIT_ROOT" >&6; } 16167 fi 16168 16169 16170 if test "x$DEVKIT_EXTRA_PATH" != x; then 16171 if test "x$EXTRA_PATH" = x; then 16172 EXTRA_PATH="$DEVKIT_EXTRA_PATH" 16173 else 16174 EXTRA_PATH="$DEVKIT_EXTRA_PATH:$EXTRA_PATH" 16175 fi 16176 fi 16177 16178 16179 # Fallback default of just /bin if DEVKIT_PATH is not defined 16180 if test "x$DEVKIT_TOOLCHAIN_PATH" = x; then 16181 DEVKIT_TOOLCHAIN_PATH="$DEVKIT_ROOT/bin" 16182 fi 16183 16184 if test "x$DEVKIT_TOOLCHAIN_PATH" != x; then 16185 if test "x$TOOLCHAIN_PATH" = x; then 16186 TOOLCHAIN_PATH="$DEVKIT_TOOLCHAIN_PATH" 16187 else 16188 TOOLCHAIN_PATH="$DEVKIT_TOOLCHAIN_PATH:$TOOLCHAIN_PATH" 16189 fi 16190 fi 16191 16192 16193 # If DEVKIT_SYSROOT is set, use that, otherwise try a couple of known 16194 # places for backwards compatiblity. 16195 if test "x$DEVKIT_SYSROOT" != x; then 16196 SYSROOT="$DEVKIT_SYSROOT" 16197 elif test -d "$DEVKIT_ROOT/$host_alias/libc"; then 16198 SYSROOT="$DEVKIT_ROOT/$host_alias/libc" 16199 elif test -d "$DEVKIT_ROOT/$host/sys-root"; then 16200 SYSROOT="$DEVKIT_ROOT/$host/sys-root" 16201 fi 16202 16203 16204 fi 16205 16206 16207 # You can force the sysroot if the sysroot encoded into the compiler tools 16208 # is not correct. 16209 16210 # Check whether --with-sys-root was given. 16211 if test "${with_sys_root+set}" = set; then : 16212 withval=$with_sys_root; SYSROOT=$with_sys_root 16213 16214 fi 16215 16216 16217 16218 # Check whether --with-sysroot was given. 16219 if test "${with_sysroot+set}" = set; then : 16220 withval=$with_sysroot; SYSROOT=$with_sysroot 16221 16222 fi 16223 16224 16225 16226 # Check whether --with-tools-dir was given. 16227 if test "${with_tools_dir+set}" = set; then : 16228 withval=$with_tools_dir; 16229 if test "x$with_tools_dir" != x; then 16230 if test "x$TOOLCHAIN_PATH" = x; then 16231 TOOLCHAIN_PATH="$with_tools_dir" 16232 else 16233 TOOLCHAIN_PATH="$with_tools_dir:$TOOLCHAIN_PATH" 16234 fi 16235 fi 16236 16237 16238 fi 16239 16240 16241 16242 # Check whether --with-toolchain-path was given. 16243 if test "${with_toolchain_path+set}" = set; then : 16244 withval=$with_toolchain_path; 16245 if test "x$with_toolchain_path" != x; then 16246 if test "x$TOOLCHAIN_PATH" = x; then 16247 TOOLCHAIN_PATH="$with_toolchain_path" 16248 else 16249 TOOLCHAIN_PATH="$with_toolchain_path:$TOOLCHAIN_PATH" 16250 fi 16251 fi 16252 16253 16254 fi 16255 16256 16257 16258 # Check whether --with-extra-path was given. 16259 if test "${with_extra_path+set}" = set; then : 16260 withval=$with_extra_path; 16261 if test "x$with_extra_path" != x; then 16262 if test "x$EXTRA_PATH" = x; then 16263 EXTRA_PATH="$with_extra_path" 16264 else 16265 EXTRA_PATH="$with_extra_path:$EXTRA_PATH" 16266 fi 16267 fi 16268 16269 16270 fi 16271 16272 16273 if test "x$OPENJDK_BUILD_OS" = "xmacosx"; then 16274 # If a devkit has been supplied, find xcodebuild in the toolchain_path. 16275 # If not, detect if Xcode is installed by running xcodebuild -version 16276 # if no Xcode installed, xcodebuild exits with 1 16277 # if Xcode is installed, even if xcode-select is misconfigured, then it exits with 0 16278 if test "x$DEVKIT_ROOT" != x || /usr/bin/xcodebuild -version >/dev/null 2>&1; then 16279 # We need to use xcodebuild in the toolchain dir provided by the user, this will 16280 # fall back on the stub binary in /usr/bin/xcodebuild 16281 # Extract the first word of "xcodebuild", so it can be a program name with args. 16282 set dummy xcodebuild; ac_word=$2 16283 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 16284 $as_echo_n "checking for $ac_word... " >&6; } 16285 if ${ac_cv_path_XCODEBUILD+:} false; then : 16286 $as_echo_n "(cached) " >&6 16287 else 16288 case $XCODEBUILD in 16289 [\\/]* | ?:[\\/]*) 16290 ac_cv_path_XCODEBUILD="$XCODEBUILD" # Let the user override the test with a path. 16291 ;; 16292 *) 16293 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 16294 for as_dir in $TOOLCHAIN_PATH 16295 do 16296 IFS=$as_save_IFS 16297 test -z "$as_dir" && as_dir=. 16298 for ac_exec_ext in '' $ac_executable_extensions; do 16299 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 16300 ac_cv_path_XCODEBUILD="$as_dir/$ac_word$ac_exec_ext" 16301 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 16302 break 2 16303 fi 16304 done 16305 done 16306 IFS=$as_save_IFS 16307 16308 test -z "$ac_cv_path_XCODEBUILD" && ac_cv_path_XCODEBUILD="/usr/bin/xcodebuild" 16309 ;; 16310 esac 16311 fi 16312 XCODEBUILD=$ac_cv_path_XCODEBUILD 16313 if test -n "$XCODEBUILD"; then 16314 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XCODEBUILD" >&5 16315 $as_echo "$XCODEBUILD" >&6; } 16316 else 16317 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 16318 $as_echo "no" >&6; } 16319 fi 16320 16321 16322 else 16323 # this should result in SYSROOT being empty, unless --with-sysroot is provided 16324 # when only the command line tools are installed there are no SDKs, so headers 16325 # are copied into the system frameworks 16326 XCODEBUILD= 16327 16328 fi 16329 16330 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sdk name" >&5 16331 $as_echo_n "checking for sdk name... " >&6; } 16332 16333 # Check whether --with-sdk-name was given. 16334 if test "${with_sdk_name+set}" = set; then : 16335 withval=$with_sdk_name; SDKNAME=$with_sdk_name 16336 16337 fi 16338 16339 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SDKNAME" >&5 16340 $as_echo "$SDKNAME" >&6; } 16341 16342 # if toolchain path is specified then don't rely on system headers, they may not compile 16343 HAVE_SYSTEM_FRAMEWORK_HEADERS=0 16344 test -z "$TOOLCHAIN_PATH" && \ 16345 HAVE_SYSTEM_FRAMEWORK_HEADERS=`test ! -f /System/Library/Frameworks/Foundation.framework/Headers/Foundation.h; echo $?` 16346 16347 if test -z "$SYSROOT"; then 16348 if test -n "$XCODEBUILD"; then 16349 # if we don't have system headers, use default SDK name (last resort) 16350 if test -z "$SDKNAME" -a $HAVE_SYSTEM_FRAMEWORK_HEADERS -eq 0; then 16351 SDKNAME=${SDKNAME:-macosx} 16352 fi 16353 16354 if test -n "$SDKNAME"; then 16355 # Call xcodebuild to determine SYSROOT 16356 SYSROOT=`"$XCODEBUILD" -sdk $SDKNAME -version | grep '^Path: ' | sed 's/Path: //'` 16357 fi 16358 else 16359 if test $HAVE_SYSTEM_FRAMEWORK_HEADERS -eq 0; then 16360 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 16361 fi 16362 fi 16363 else 16364 # warn user if --with-sdk-name was also set 16365 if test -n "$with_sdk_name"; then 16366 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Both SYSROOT and --with-sdk-name are set, only SYSROOT will be used" >&5 16367 $as_echo "$as_me: WARNING: Both SYSROOT and --with-sdk-name are set, only SYSROOT will be used" >&2;} 16368 fi 16369 fi 16370 16371 if test $HAVE_SYSTEM_FRAMEWORK_HEADERS -eq 0 -a -z "$SYSROOT"; then 16372 # If no system framework headers, then SYSROOT must be set, or we won't build 16373 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 16374 fi 16375 16376 # Perform a basic sanity test 16377 if test ! -f "$SYSROOT/System/Library/Frameworks/Foundation.framework/Headers/Foundation.h"; then 16378 if test -z "$SYSROOT"; then 16379 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 16380 else 16381 as_fn_error $? "Invalid SDK or SYSROOT path, dependent framework headers not found" "$LINENO" 5 16382 fi 16383 fi 16384 16385 # set SDKROOT too, Xcode tools will pick it up 16386 SDKROOT=$SYSROOT 16387 16388 fi 16389 16390 # Prepend the extra path to the global path 16391 16392 if test "x$EXTRA_PATH" != x; then 16393 if test "x$PATH" = x; then 16394 PATH="$EXTRA_PATH" 16395 else 16396 PATH="$EXTRA_PATH:$PATH" 16397 fi 16398 fi 16399 16400 16401 if test "x$OPENJDK_BUILD_OS" = "xsolaris"; then 16402 # Add extra search paths on solaris for utilities like ar and as etc... 16403 PATH="$PATH:/usr/ccs/bin:/usr/sfw/bin:/opt/csw/bin" 16404 fi 16405 16406 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5 16407 $as_echo_n "checking for sysroot... " >&6; } 16408 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SYSROOT" >&5 16409 $as_echo "$SYSROOT" >&6; } 16410 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for toolchain path" >&5 16411 $as_echo_n "checking for toolchain path... " >&6; } 16412 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLCHAIN_PATH" >&5 16413 $as_echo "$TOOLCHAIN_PATH" >&6; } 16414 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for extra path" >&5 16415 $as_echo_n "checking for extra path... " >&6; } 16416 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXTRA_PATH" >&5 16417 $as_echo "$EXTRA_PATH" >&6; } 16418 16419 16420 # To properly create a configuration name, we need to have the OpenJDK target 16421 # and options (variants and debug level) parsed. 16422 16423 16424 16425 # Check whether --with-conf-name was given. 16426 if test "${with_conf_name+set}" = set; then : 16427 withval=$with_conf_name; CONF_NAME=${with_conf_name} 16428 fi 16429 16430 16431 # Test from where we are running configure, in or outside of src root. 16432 { $as_echo "$as_me:${as_lineno-$LINENO}: checking where to store configuration" >&5 16433 $as_echo_n "checking where to store configuration... " >&6; } 16434 if test "x$CURDIR" = "x$SRC_ROOT" || test "x$CURDIR" = "x$SRC_ROOT/common" \ 16435 || test "x$CURDIR" = "x$SRC_ROOT/common/autoconf" \ 16436 || test "x$CURDIR" = "x$SRC_ROOT/make" ; then 16437 # We are running configure from the src root. 16438 # Create a default ./build/target-variant-debuglevel output root. 16439 if test "x${CONF_NAME}" = x; then 16440 { $as_echo "$as_me:${as_lineno-$LINENO}: result: in default location" >&5 16441 $as_echo "in default location" >&6; } 16442 CONF_NAME="${OPENJDK_TARGET_OS}-${OPENJDK_TARGET_CPU}-${JDK_VARIANT}-${ANDED_JVM_VARIANTS}-${DEBUG_LEVEL}" 16443 else 16444 { $as_echo "$as_me:${as_lineno-$LINENO}: result: in build directory with custom name" >&5 16445 $as_echo "in build directory with custom name" >&6; } 16446 fi 16447 OUTPUT_ROOT="$SRC_ROOT/build/${CONF_NAME}" 16448 $MKDIR -p "$OUTPUT_ROOT" 16449 if test ! -d "$OUTPUT_ROOT"; then 16450 as_fn_error $? "Could not create build directory $OUTPUT_ROOT" "$LINENO" 5 16451 fi 16452 else 16453 # We are running configure from outside of the src dir. 16454 # Then use the current directory as output dir! 16455 # If configuration is situated in normal build directory, just use the build 16456 # directory name as configuration name, otherwise use the complete path. 16457 if test "x${CONF_NAME}" = x; then 16458 CONF_NAME=`$ECHO $CURDIR | $SED -e "s!^${SRC_ROOT}/build/!!"` 16459 fi 16460 OUTPUT_ROOT="$CURDIR" 16461 { $as_echo "$as_me:${as_lineno-$LINENO}: result: in current directory" >&5 16462 $as_echo "in current directory" >&6; } 16463 16464 # WARNING: This might be a bad thing to do. You need to be sure you want to 16465 # have a configuration in this directory. Do some sanity checks! 16466 16467 if test ! -e "$OUTPUT_ROOT/spec.gmk"; then 16468 # If we have a spec.gmk, we have run here before and we are OK. Otherwise, check for 16469 # other files 16470 files_present=`$LS $OUTPUT_ROOT` 16471 # Configure has already touched config.log and confdefs.h in the current dir when this check 16472 # is performed. 16473 filtered_files=`$ECHO "$files_present" \ 16474 | $SED -e 's/config.log//g' \ 16475 -e 's/configure.log//g' \ 16476 -e 's/confdefs.h//g' \ 16477 -e 's/ //g' \ 16478 | $TR -d '\n'` 16479 if test "x$filtered_files" != x; then 16480 { $as_echo "$as_me:${as_lineno-$LINENO}: Current directory is $CURDIR." >&5 16481 $as_echo "$as_me: Current directory is $CURDIR." >&6;} 16482 { $as_echo "$as_me:${as_lineno-$LINENO}: Since this is not the source root, configure will output the configuration here" >&5 16483 $as_echo "$as_me: Since this is not the source root, configure will output the configuration here" >&6;} 16484 { $as_echo "$as_me:${as_lineno-$LINENO}: (as opposed to creating a configuration in <src_root>/build/<conf-name>)." >&5 16485 $as_echo "$as_me: (as opposed to creating a configuration in <src_root>/build/<conf-name>)." >&6;} 16486 { $as_echo "$as_me:${as_lineno-$LINENO}: However, this directory is not empty. This is not allowed, since it could" >&5 16487 $as_echo "$as_me: However, this directory is not empty. This is not allowed, since it could" >&6;} 16488 { $as_echo "$as_me:${as_lineno-$LINENO}: seriously mess up just about everything." >&5 16489 $as_echo "$as_me: seriously mess up just about everything." >&6;} 16490 { $as_echo "$as_me:${as_lineno-$LINENO}: Try 'cd $SRC_ROOT' and restart configure" >&5 16491 $as_echo "$as_me: Try 'cd $SRC_ROOT' and restart configure" >&6;} 16492 { $as_echo "$as_me:${as_lineno-$LINENO}: (or create a new empty directory and cd to it)." >&5 16493 $as_echo "$as_me: (or create a new empty directory and cd to it)." >&6;} 16494 as_fn_error $? "Will not continue creating configuration in $CURDIR" "$LINENO" 5 16495 fi 16496 fi 16497 fi 16498 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what configuration name to use" >&5 16499 $as_echo_n "checking what configuration name to use... " >&6; } 16500 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CONF_NAME" >&5 16501 $as_echo "$CONF_NAME" >&6; } 16502 16503 16504 # Only process if variable expands to non-empty 16505 16506 if test "x$OUTPUT_ROOT" != x; then 16507 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16508 16509 # Input might be given as Windows format, start by converting to 16510 # unix format. 16511 path="$OUTPUT_ROOT" 16512 new_path=`$CYGPATH -u "$path"` 16513 16514 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 16515 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 16516 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 16517 # "foo.exe" is OK but "foo" is an error. 16518 # 16519 # This test is therefore slightly more accurate than "test -f" to check for file precense. 16520 # It is also a way to make sure we got the proper file name for the real test later on. 16521 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 16522 if test "x$test_shortpath" = x; then 16523 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&5 16524 $as_echo "$as_me: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&6;} 16525 as_fn_error $? "Cannot locate the the path of OUTPUT_ROOT" "$LINENO" 5 16526 fi 16527 16528 # Call helper function which possibly converts this using DOS-style short mode. 16529 # If so, the updated path is stored in $new_path. 16530 16531 input_path="$new_path" 16532 # Check if we need to convert this using DOS-style short mode. If the path 16533 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16534 # take no chances and rewrite it. 16535 # Note: m4 eats our [], so we need to use [ and ] instead. 16536 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 16537 if test "x$has_forbidden_chars" != x; then 16538 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16539 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 16540 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 16541 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 16542 # Going to short mode and back again did indeed matter. Since short mode is 16543 # case insensitive, let's make it lowercase to improve readability. 16544 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16545 # Now convert it back to Unix-style (cygpath) 16546 input_path=`$CYGPATH -u "$shortmode_path"` 16547 new_path="$input_path" 16548 fi 16549 fi 16550 16551 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 16552 if test "x$test_cygdrive_prefix" = x; then 16553 # As a simple fix, exclude /usr/bin since it's not a real path. 16554 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 16555 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 16556 # a path prefixed by /cygdrive for fixpath to work. 16557 new_path="$CYGWIN_ROOT_PATH$input_path" 16558 fi 16559 fi 16560 16561 16562 if test "x$path" != "x$new_path"; then 16563 OUTPUT_ROOT="$new_path" 16564 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OUTPUT_ROOT to \"$new_path\"" >&5 16565 $as_echo "$as_me: Rewriting OUTPUT_ROOT to \"$new_path\"" >&6;} 16566 fi 16567 16568 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16569 16570 path="$OUTPUT_ROOT" 16571 has_colon=`$ECHO $path | $GREP ^.:` 16572 new_path="$path" 16573 if test "x$has_colon" = x; then 16574 # Not in mixed or Windows style, start by that. 16575 new_path=`cmd //c echo $path` 16576 fi 16577 16578 16579 input_path="$new_path" 16580 # Check if we need to convert this using DOS-style short mode. If the path 16581 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16582 # take no chances and rewrite it. 16583 # Note: m4 eats our [], so we need to use [ and ] instead. 16584 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 16585 if test "x$has_forbidden_chars" != x; then 16586 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16587 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16588 fi 16589 16590 16591 windows_path="$new_path" 16592 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16593 unix_path=`$CYGPATH -u "$windows_path"` 16594 new_path="$unix_path" 16595 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16596 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16597 new_path="$unix_path" 16598 fi 16599 16600 if test "x$path" != "x$new_path"; then 16601 OUTPUT_ROOT="$new_path" 16602 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OUTPUT_ROOT to \"$new_path\"" >&5 16603 $as_echo "$as_me: Rewriting OUTPUT_ROOT to \"$new_path\"" >&6;} 16604 fi 16605 16606 # Save the first 10 bytes of this path to the storage, so fixpath can work. 16607 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 16608 16609 else 16610 # We're on a unix platform. Hooray! :) 16611 path="$OUTPUT_ROOT" 16612 has_space=`$ECHO "$path" | $GREP " "` 16613 if test "x$has_space" != x; then 16614 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&5 16615 $as_echo "$as_me: The path of OUTPUT_ROOT, which resolves as \"$path\", is invalid." >&6;} 16616 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 16617 fi 16618 16619 # Use eval to expand a potential ~ 16620 eval path="$path" 16621 if test ! -f "$path" && test ! -d "$path"; then 16622 as_fn_error $? "The path of OUTPUT_ROOT, which resolves as \"$path\", is not found." "$LINENO" 5 16623 fi 16624 16625 if test -d "$path"; then 16626 OUTPUT_ROOT="`cd "$path"; $THEPWDCMD -L`" 16627 else 16628 dir="`$DIRNAME "$path"`" 16629 base="`$BASENAME "$path"`" 16630 OUTPUT_ROOT="`cd "$dir"; $THEPWDCMD -L`/$base" 16631 fi 16632 fi 16633 fi 16634 16635 16636 CONFIGURESUPPORT_OUTPUTDIR="$OUTPUT_ROOT/configure-support" 16637 $MKDIR -p "$CONFIGURESUPPORT_OUTPUTDIR" 16638 16639 SPEC=$OUTPUT_ROOT/spec.gmk 16640 16641 CONF_NAME=$CONF_NAME 16642 16643 OUTPUT_ROOT=$OUTPUT_ROOT 16644 16645 16646 16647 # The spec.gmk file contains all variables for the make system. 16648 ac_config_files="$ac_config_files $OUTPUT_ROOT/spec.gmk:$AUTOCONF_DIR/spec.gmk.in" 16649 16650 # The hotspot-spec.gmk file contains legacy variables for the hotspot make system. 16651 ac_config_files="$ac_config_files $OUTPUT_ROOT/hotspot-spec.gmk:$AUTOCONF_DIR/hotspot-spec.gmk.in" 16652 16653 # The bootcycle-spec.gmk file contains support for boot cycle builds. 16654 ac_config_files="$ac_config_files $OUTPUT_ROOT/bootcycle-spec.gmk:$AUTOCONF_DIR/bootcycle-spec.gmk.in" 16655 16656 # The compare.sh is used to compare the build output to other builds. 16657 ac_config_files="$ac_config_files $OUTPUT_ROOT/compare.sh:$AUTOCONF_DIR/compare.sh.in" 16658 16659 # The generated Makefile knows where the spec.gmk is and where the source is. 16660 # You can run make from the OUTPUT_ROOT, or from the top-level Makefile 16661 # which will look for generated configurations 16662 ac_config_files="$ac_config_files $OUTPUT_ROOT/Makefile:$AUTOCONF_DIR/Makefile.in" 16663 16664 16665 16666 # Must be done before we can call HELP_MSG_MISSING_DEPENDENCY. 16667 16668 for ac_prog in apt-get yum port pkgutil pkgadd 16669 do 16670 # Extract the first word of "$ac_prog", so it can be a program name with args. 16671 set dummy $ac_prog; ac_word=$2 16672 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 16673 $as_echo_n "checking for $ac_word... " >&6; } 16674 if ${ac_cv_prog_PKGHANDLER+:} false; then : 16675 $as_echo_n "(cached) " >&6 16676 else 16677 if test -n "$PKGHANDLER"; then 16678 ac_cv_prog_PKGHANDLER="$PKGHANDLER" # Let the user override the test. 16679 else 16680 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 16681 for as_dir in $PATH 16682 do 16683 IFS=$as_save_IFS 16684 test -z "$as_dir" && as_dir=. 16685 for ac_exec_ext in '' $ac_executable_extensions; do 16686 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 16687 ac_cv_prog_PKGHANDLER="$ac_prog" 16688 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 16689 break 2 16690 fi 16691 done 16692 done 16693 IFS=$as_save_IFS 16694 16695 fi 16696 fi 16697 PKGHANDLER=$ac_cv_prog_PKGHANDLER 16698 if test -n "$PKGHANDLER"; then 16699 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKGHANDLER" >&5 16700 $as_echo "$PKGHANDLER" >&6; } 16701 else 16702 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 16703 $as_echo "no" >&6; } 16704 fi 16705 16706 16707 test -n "$PKGHANDLER" && break 16708 done 16709 16710 16711 16712 # Setup tools that requires more complex handling, or that is not needed by the configure script. 16713 16714 16715 16716 # Publish this variable in the help. 16717 16718 16719 if [ -z "${MAKE+x}" ]; then 16720 # The variable is not set by user, try to locate tool using the code snippet 16721 16722 # Try our hardest to locate a correct version of GNU make 16723 for ac_prog in gmake 16724 do 16725 # Extract the first word of "$ac_prog", so it can be a program name with args. 16726 set dummy $ac_prog; ac_word=$2 16727 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 16728 $as_echo_n "checking for $ac_word... " >&6; } 16729 if ${ac_cv_path_CHECK_GMAKE+:} false; then : 16730 $as_echo_n "(cached) " >&6 16731 else 16732 case $CHECK_GMAKE in 16733 [\\/]* | ?:[\\/]*) 16734 ac_cv_path_CHECK_GMAKE="$CHECK_GMAKE" # Let the user override the test with a path. 16735 ;; 16736 *) 16737 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 16738 for as_dir in $PATH 16739 do 16740 IFS=$as_save_IFS 16741 test -z "$as_dir" && as_dir=. 16742 for ac_exec_ext in '' $ac_executable_extensions; do 16743 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 16744 ac_cv_path_CHECK_GMAKE="$as_dir/$ac_word$ac_exec_ext" 16745 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 16746 break 2 16747 fi 16748 done 16749 done 16750 IFS=$as_save_IFS 16751 16752 ;; 16753 esac 16754 fi 16755 CHECK_GMAKE=$ac_cv_path_CHECK_GMAKE 16756 if test -n "$CHECK_GMAKE"; then 16757 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_GMAKE" >&5 16758 $as_echo "$CHECK_GMAKE" >&6; } 16759 else 16760 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 16761 $as_echo "no" >&6; } 16762 fi 16763 16764 16765 test -n "$CHECK_GMAKE" && break 16766 done 16767 16768 16769 MAKE_CANDIDATE=""$CHECK_GMAKE"" 16770 DESCRIPTION="gmake in PATH" 16771 16772 # On Cygwin, we require a newer version of make than on other platforms 16773 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16774 MAKE_VERSION_EXPR="-e 4\." 16775 MAKE_REQUIRED_VERSION="4.0" 16776 else 16777 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 16778 MAKE_REQUIRED_VERSION="3.81" 16779 fi 16780 16781 if test "x$MAKE_CANDIDATE" != x; then 16782 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 16783 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 16784 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 16785 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 16786 if test "x$IS_GNU_MAKE" = x; then 16787 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 16788 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 16789 else 16790 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 16791 if test "x$IS_MODERN_MAKE" = x; then 16792 { $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 16793 $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;} 16794 else 16795 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 16796 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16797 MAKE_EXPECTED_ENV='cygwin' 16798 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16799 MAKE_EXPECTED_ENV='msys' 16800 else 16801 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 16802 fi 16803 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 16804 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 16805 else 16806 # Not relevant for non-Windows 16807 IS_MAKE_CORRECT_ENV=true 16808 fi 16809 if test "x$IS_MAKE_CORRECT_ENV" = x; then 16810 { $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 16811 $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;} 16812 else 16813 FOUND_MAKE=$MAKE_CANDIDATE 16814 16815 # Only process if variable expands to non-empty 16816 16817 if test "x$FOUND_MAKE" != x; then 16818 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16819 16820 # First separate the path from the arguments. This will split at the first 16821 # space. 16822 complete="$FOUND_MAKE" 16823 path="${complete%% *}" 16824 tmp="$complete EOL" 16825 arguments="${tmp#* }" 16826 16827 # Input might be given as Windows format, start by converting to 16828 # unix format. 16829 new_path=`$CYGPATH -u "$path"` 16830 16831 # Now try to locate executable using which 16832 new_path=`$WHICH "$new_path" 2> /dev/null` 16833 # bat and cmd files are not always considered executable in cygwin causing which 16834 # to not find them 16835 if test "x$new_path" = x \ 16836 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 16837 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 16838 new_path=`$CYGPATH -u "$path"` 16839 fi 16840 if test "x$new_path" = x; then 16841 # Oops. Which didn't find the executable. 16842 # The splitting of arguments from the executable at a space might have been incorrect, 16843 # since paths with space are more likely in Windows. Give it another try with the whole 16844 # argument. 16845 path="$complete" 16846 arguments="EOL" 16847 new_path=`$CYGPATH -u "$path"` 16848 new_path=`$WHICH "$new_path" 2> /dev/null` 16849 # bat and cmd files are not always considered executable in cygwin causing which 16850 # to not find them 16851 if test "x$new_path" = x \ 16852 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 16853 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 16854 new_path=`$CYGPATH -u "$path"` 16855 fi 16856 if test "x$new_path" = x; then 16857 # It's still not found. Now this is an unrecoverable error. 16858 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 16859 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 16860 has_space=`$ECHO "$complete" | $GREP " "` 16861 if test "x$has_space" != x; then 16862 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 16863 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 16864 fi 16865 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 16866 fi 16867 fi 16868 16869 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 16870 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 16871 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 16872 # "foo.exe" is OK but "foo" is an error. 16873 # 16874 # This test is therefore slightly more accurate than "test -f" to check for file presence. 16875 # It is also a way to make sure we got the proper file name for the real test later on. 16876 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 16877 if test "x$test_shortpath" = x; then 16878 # Short path failed, file does not exist as specified. 16879 # Try adding .exe or .cmd 16880 if test -f "${new_path}.exe"; then 16881 input_to_shortpath="${new_path}.exe" 16882 elif test -f "${new_path}.cmd"; then 16883 input_to_shortpath="${new_path}.cmd" 16884 else 16885 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 16886 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 16887 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 16888 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 16889 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 16890 fi 16891 else 16892 input_to_shortpath="$new_path" 16893 fi 16894 16895 # Call helper function which possibly converts this using DOS-style short mode. 16896 # If so, the updated path is stored in $new_path. 16897 new_path="$input_to_shortpath" 16898 16899 input_path="$input_to_shortpath" 16900 # Check if we need to convert this using DOS-style short mode. If the path 16901 # contains just simple characters, use it. Otherwise (spaces, weird characters), 16902 # take no chances and rewrite it. 16903 # Note: m4 eats our [], so we need to use [ and ] instead. 16904 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 16905 if test "x$has_forbidden_chars" != x; then 16906 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 16907 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 16908 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 16909 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 16910 # Going to short mode and back again did indeed matter. Since short mode is 16911 # case insensitive, let's make it lowercase to improve readability. 16912 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 16913 # Now convert it back to Unix-style (cygpath) 16914 input_path=`$CYGPATH -u "$shortmode_path"` 16915 new_path="$input_path" 16916 fi 16917 fi 16918 16919 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 16920 if test "x$test_cygdrive_prefix" = x; then 16921 # As a simple fix, exclude /usr/bin since it's not a real path. 16922 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 16923 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 16924 # a path prefixed by /cygdrive for fixpath to work. 16925 new_path="$CYGWIN_ROOT_PATH$input_path" 16926 fi 16927 fi 16928 16929 # remove trailing .exe if any 16930 new_path="${new_path/%.exe/}" 16931 16932 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16933 16934 # First separate the path from the arguments. This will split at the first 16935 # space. 16936 complete="$FOUND_MAKE" 16937 path="${complete%% *}" 16938 tmp="$complete EOL" 16939 arguments="${tmp#* }" 16940 16941 # Input might be given as Windows format, start by converting to 16942 # unix format. 16943 new_path="$path" 16944 16945 windows_path="$new_path" 16946 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16947 unix_path=`$CYGPATH -u "$windows_path"` 16948 new_path="$unix_path" 16949 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16950 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16951 new_path="$unix_path" 16952 fi 16953 16954 16955 # Now try to locate executable using which 16956 new_path=`$WHICH "$new_path" 2> /dev/null` 16957 16958 if test "x$new_path" = x; then 16959 # Oops. Which didn't find the executable. 16960 # The splitting of arguments from the executable at a space might have been incorrect, 16961 # since paths with space are more likely in Windows. Give it another try with the whole 16962 # argument. 16963 path="$complete" 16964 arguments="EOL" 16965 new_path="$path" 16966 16967 windows_path="$new_path" 16968 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16969 unix_path=`$CYGPATH -u "$windows_path"` 16970 new_path="$unix_path" 16971 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16972 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16973 new_path="$unix_path" 16974 fi 16975 16976 16977 new_path=`$WHICH "$new_path" 2> /dev/null` 16978 # bat and cmd files are not always considered executable in MSYS causing which 16979 # to not find them 16980 if test "x$new_path" = x \ 16981 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 16982 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 16983 new_path="$path" 16984 16985 windows_path="$new_path" 16986 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 16987 unix_path=`$CYGPATH -u "$windows_path"` 16988 new_path="$unix_path" 16989 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 16990 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 16991 new_path="$unix_path" 16992 fi 16993 16994 fi 16995 16996 if test "x$new_path" = x; then 16997 # It's still not found. Now this is an unrecoverable error. 16998 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 16999 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 17000 has_space=`$ECHO "$complete" | $GREP " "` 17001 if test "x$has_space" != x; then 17002 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 17003 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 17004 fi 17005 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 17006 fi 17007 fi 17008 17009 # Now new_path has a complete unix path to the binary 17010 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 17011 # Keep paths in /bin as-is, but remove trailing .exe if any 17012 new_path="${new_path/%.exe/}" 17013 # Do not save /bin paths to all_fixpath_prefixes! 17014 else 17015 # Not in mixed or Windows style, start by that. 17016 new_path=`cmd //c echo $new_path` 17017 17018 input_path="$new_path" 17019 # Check if we need to convert this using DOS-style short mode. If the path 17020 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17021 # take no chances and rewrite it. 17022 # Note: m4 eats our [], so we need to use [ and ] instead. 17023 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 17024 if test "x$has_forbidden_chars" != x; then 17025 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17026 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17027 fi 17028 17029 # Output is in $new_path 17030 17031 windows_path="$new_path" 17032 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17033 unix_path=`$CYGPATH -u "$windows_path"` 17034 new_path="$unix_path" 17035 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17036 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17037 new_path="$unix_path" 17038 fi 17039 17040 # remove trailing .exe if any 17041 new_path="${new_path/%.exe/}" 17042 17043 # Save the first 10 bytes of this path to the storage, so fixpath can work. 17044 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 17045 fi 17046 17047 else 17048 # We're on a unix platform. Hooray! :) 17049 # First separate the path from the arguments. This will split at the first 17050 # space. 17051 complete="$FOUND_MAKE" 17052 path="${complete%% *}" 17053 tmp="$complete EOL" 17054 arguments="${tmp#* }" 17055 17056 # Cannot rely on the command "which" here since it doesn't always work. 17057 is_absolute_path=`$ECHO "$path" | $GREP ^/` 17058 if test -z "$is_absolute_path"; then 17059 # Path to executable is not absolute. Find it. 17060 IFS_save="$IFS" 17061 IFS=: 17062 for p in $PATH; do 17063 if test -f "$p/$path" && test -x "$p/$path"; then 17064 new_path="$p/$path" 17065 break 17066 fi 17067 done 17068 IFS="$IFS_save" 17069 else 17070 # This is an absolute path, we can use it without further modifications. 17071 new_path="$path" 17072 fi 17073 17074 if test "x$new_path" = x; then 17075 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 17076 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 17077 has_space=`$ECHO "$complete" | $GREP " "` 17078 if test "x$has_space" != x; then 17079 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 17080 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 17081 fi 17082 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 17083 fi 17084 fi 17085 17086 # Now join together the path and the arguments once again 17087 if test "x$arguments" != xEOL; then 17088 new_complete="$new_path ${arguments% *}" 17089 else 17090 new_complete="$new_path" 17091 fi 17092 17093 if test "x$complete" != "x$new_complete"; then 17094 FOUND_MAKE="$new_complete" 17095 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 17096 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 17097 fi 17098 fi 17099 17100 fi 17101 fi 17102 fi 17103 fi 17104 17105 17106 if test "x$FOUND_MAKE" = x; then 17107 for ac_prog in make 17108 do 17109 # Extract the first word of "$ac_prog", so it can be a program name with args. 17110 set dummy $ac_prog; ac_word=$2 17111 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 17112 $as_echo_n "checking for $ac_word... " >&6; } 17113 if ${ac_cv_path_CHECK_MAKE+:} false; then : 17114 $as_echo_n "(cached) " >&6 17115 else 17116 case $CHECK_MAKE in 17117 [\\/]* | ?:[\\/]*) 17118 ac_cv_path_CHECK_MAKE="$CHECK_MAKE" # Let the user override the test with a path. 17119 ;; 17120 *) 17121 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 17122 for as_dir in $PATH 17123 do 17124 IFS=$as_save_IFS 17125 test -z "$as_dir" && as_dir=. 17126 for ac_exec_ext in '' $ac_executable_extensions; do 17127 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 17128 ac_cv_path_CHECK_MAKE="$as_dir/$ac_word$ac_exec_ext" 17129 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 17130 break 2 17131 fi 17132 done 17133 done 17134 IFS=$as_save_IFS 17135 17136 ;; 17137 esac 17138 fi 17139 CHECK_MAKE=$ac_cv_path_CHECK_MAKE 17140 if test -n "$CHECK_MAKE"; then 17141 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_MAKE" >&5 17142 $as_echo "$CHECK_MAKE" >&6; } 17143 else 17144 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 17145 $as_echo "no" >&6; } 17146 fi 17147 17148 17149 test -n "$CHECK_MAKE" && break 17150 done 17151 17152 17153 MAKE_CANDIDATE=""$CHECK_MAKE"" 17154 DESCRIPTION="make in PATH" 17155 17156 # On Cygwin, we require a newer version of make than on other platforms 17157 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17158 MAKE_VERSION_EXPR="-e 4\." 17159 MAKE_REQUIRED_VERSION="4.0" 17160 else 17161 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 17162 MAKE_REQUIRED_VERSION="3.81" 17163 fi 17164 17165 if test "x$MAKE_CANDIDATE" != x; then 17166 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 17167 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 17168 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 17169 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 17170 if test "x$IS_GNU_MAKE" = x; then 17171 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 17172 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 17173 else 17174 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 17175 if test "x$IS_MODERN_MAKE" = x; then 17176 { $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 17177 $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;} 17178 else 17179 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 17180 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17181 MAKE_EXPECTED_ENV='cygwin' 17182 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17183 MAKE_EXPECTED_ENV='msys' 17184 else 17185 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 17186 fi 17187 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 17188 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 17189 else 17190 # Not relevant for non-Windows 17191 IS_MAKE_CORRECT_ENV=true 17192 fi 17193 if test "x$IS_MAKE_CORRECT_ENV" = x; then 17194 { $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 17195 $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;} 17196 else 17197 FOUND_MAKE=$MAKE_CANDIDATE 17198 17199 # Only process if variable expands to non-empty 17200 17201 if test "x$FOUND_MAKE" != x; then 17202 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17203 17204 # First separate the path from the arguments. This will split at the first 17205 # space. 17206 complete="$FOUND_MAKE" 17207 path="${complete%% *}" 17208 tmp="$complete EOL" 17209 arguments="${tmp#* }" 17210 17211 # Input might be given as Windows format, start by converting to 17212 # unix format. 17213 new_path=`$CYGPATH -u "$path"` 17214 17215 # Now try to locate executable using which 17216 new_path=`$WHICH "$new_path" 2> /dev/null` 17217 # bat and cmd files are not always considered executable in cygwin causing which 17218 # to not find them 17219 if test "x$new_path" = x \ 17220 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 17221 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 17222 new_path=`$CYGPATH -u "$path"` 17223 fi 17224 if test "x$new_path" = x; then 17225 # Oops. Which didn't find the executable. 17226 # The splitting of arguments from the executable at a space might have been incorrect, 17227 # since paths with space are more likely in Windows. Give it another try with the whole 17228 # argument. 17229 path="$complete" 17230 arguments="EOL" 17231 new_path=`$CYGPATH -u "$path"` 17232 new_path=`$WHICH "$new_path" 2> /dev/null` 17233 # bat and cmd files are not always considered executable in cygwin causing which 17234 # to not find them 17235 if test "x$new_path" = x \ 17236 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 17237 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 17238 new_path=`$CYGPATH -u "$path"` 17239 fi 17240 if test "x$new_path" = x; then 17241 # It's still not found. Now this is an unrecoverable error. 17242 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 17243 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 17244 has_space=`$ECHO "$complete" | $GREP " "` 17245 if test "x$has_space" != x; then 17246 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 17247 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 17248 fi 17249 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 17250 fi 17251 fi 17252 17253 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 17254 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 17255 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 17256 # "foo.exe" is OK but "foo" is an error. 17257 # 17258 # This test is therefore slightly more accurate than "test -f" to check for file presence. 17259 # It is also a way to make sure we got the proper file name for the real test later on. 17260 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 17261 if test "x$test_shortpath" = x; then 17262 # Short path failed, file does not exist as specified. 17263 # Try adding .exe or .cmd 17264 if test -f "${new_path}.exe"; then 17265 input_to_shortpath="${new_path}.exe" 17266 elif test -f "${new_path}.cmd"; then 17267 input_to_shortpath="${new_path}.cmd" 17268 else 17269 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 17270 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 17271 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 17272 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 17273 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 17274 fi 17275 else 17276 input_to_shortpath="$new_path" 17277 fi 17278 17279 # Call helper function which possibly converts this using DOS-style short mode. 17280 # If so, the updated path is stored in $new_path. 17281 new_path="$input_to_shortpath" 17282 17283 input_path="$input_to_shortpath" 17284 # Check if we need to convert this using DOS-style short mode. If the path 17285 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17286 # take no chances and rewrite it. 17287 # Note: m4 eats our [], so we need to use [ and ] instead. 17288 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 17289 if test "x$has_forbidden_chars" != x; then 17290 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17291 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 17292 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 17293 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 17294 # Going to short mode and back again did indeed matter. Since short mode is 17295 # case insensitive, let's make it lowercase to improve readability. 17296 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17297 # Now convert it back to Unix-style (cygpath) 17298 input_path=`$CYGPATH -u "$shortmode_path"` 17299 new_path="$input_path" 17300 fi 17301 fi 17302 17303 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 17304 if test "x$test_cygdrive_prefix" = x; then 17305 # As a simple fix, exclude /usr/bin since it's not a real path. 17306 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 17307 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 17308 # a path prefixed by /cygdrive for fixpath to work. 17309 new_path="$CYGWIN_ROOT_PATH$input_path" 17310 fi 17311 fi 17312 17313 # remove trailing .exe if any 17314 new_path="${new_path/%.exe/}" 17315 17316 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17317 17318 # First separate the path from the arguments. This will split at the first 17319 # space. 17320 complete="$FOUND_MAKE" 17321 path="${complete%% *}" 17322 tmp="$complete EOL" 17323 arguments="${tmp#* }" 17324 17325 # Input might be given as Windows format, start by converting to 17326 # unix format. 17327 new_path="$path" 17328 17329 windows_path="$new_path" 17330 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17331 unix_path=`$CYGPATH -u "$windows_path"` 17332 new_path="$unix_path" 17333 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17334 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17335 new_path="$unix_path" 17336 fi 17337 17338 17339 # Now try to locate executable using which 17340 new_path=`$WHICH "$new_path" 2> /dev/null` 17341 17342 if test "x$new_path" = x; then 17343 # Oops. Which didn't find the executable. 17344 # The splitting of arguments from the executable at a space might have been incorrect, 17345 # since paths with space are more likely in Windows. Give it another try with the whole 17346 # argument. 17347 path="$complete" 17348 arguments="EOL" 17349 new_path="$path" 17350 17351 windows_path="$new_path" 17352 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17353 unix_path=`$CYGPATH -u "$windows_path"` 17354 new_path="$unix_path" 17355 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17356 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17357 new_path="$unix_path" 17358 fi 17359 17360 17361 new_path=`$WHICH "$new_path" 2> /dev/null` 17362 # bat and cmd files are not always considered executable in MSYS causing which 17363 # to not find them 17364 if test "x$new_path" = x \ 17365 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 17366 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 17367 new_path="$path" 17368 17369 windows_path="$new_path" 17370 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17371 unix_path=`$CYGPATH -u "$windows_path"` 17372 new_path="$unix_path" 17373 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17374 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17375 new_path="$unix_path" 17376 fi 17377 17378 fi 17379 17380 if test "x$new_path" = x; then 17381 # It's still not found. Now this is an unrecoverable error. 17382 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 17383 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 17384 has_space=`$ECHO "$complete" | $GREP " "` 17385 if test "x$has_space" != x; then 17386 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 17387 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 17388 fi 17389 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 17390 fi 17391 fi 17392 17393 # Now new_path has a complete unix path to the binary 17394 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 17395 # Keep paths in /bin as-is, but remove trailing .exe if any 17396 new_path="${new_path/%.exe/}" 17397 # Do not save /bin paths to all_fixpath_prefixes! 17398 else 17399 # Not in mixed or Windows style, start by that. 17400 new_path=`cmd //c echo $new_path` 17401 17402 input_path="$new_path" 17403 # Check if we need to convert this using DOS-style short mode. If the path 17404 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17405 # take no chances and rewrite it. 17406 # Note: m4 eats our [], so we need to use [ and ] instead. 17407 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 17408 if test "x$has_forbidden_chars" != x; then 17409 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17410 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17411 fi 17412 17413 # Output is in $new_path 17414 17415 windows_path="$new_path" 17416 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17417 unix_path=`$CYGPATH -u "$windows_path"` 17418 new_path="$unix_path" 17419 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17420 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17421 new_path="$unix_path" 17422 fi 17423 17424 # remove trailing .exe if any 17425 new_path="${new_path/%.exe/}" 17426 17427 # Save the first 10 bytes of this path to the storage, so fixpath can work. 17428 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 17429 fi 17430 17431 else 17432 # We're on a unix platform. Hooray! :) 17433 # First separate the path from the arguments. This will split at the first 17434 # space. 17435 complete="$FOUND_MAKE" 17436 path="${complete%% *}" 17437 tmp="$complete EOL" 17438 arguments="${tmp#* }" 17439 17440 # Cannot rely on the command "which" here since it doesn't always work. 17441 is_absolute_path=`$ECHO "$path" | $GREP ^/` 17442 if test -z "$is_absolute_path"; then 17443 # Path to executable is not absolute. Find it. 17444 IFS_save="$IFS" 17445 IFS=: 17446 for p in $PATH; do 17447 if test -f "$p/$path" && test -x "$p/$path"; then 17448 new_path="$p/$path" 17449 break 17450 fi 17451 done 17452 IFS="$IFS_save" 17453 else 17454 # This is an absolute path, we can use it without further modifications. 17455 new_path="$path" 17456 fi 17457 17458 if test "x$new_path" = x; then 17459 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 17460 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 17461 has_space=`$ECHO "$complete" | $GREP " "` 17462 if test "x$has_space" != x; then 17463 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 17464 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 17465 fi 17466 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 17467 fi 17468 fi 17469 17470 # Now join together the path and the arguments once again 17471 if test "x$arguments" != xEOL; then 17472 new_complete="$new_path ${arguments% *}" 17473 else 17474 new_complete="$new_path" 17475 fi 17476 17477 if test "x$complete" != "x$new_complete"; then 17478 FOUND_MAKE="$new_complete" 17479 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 17480 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 17481 fi 17482 fi 17483 17484 fi 17485 fi 17486 fi 17487 fi 17488 17489 fi 17490 17491 if test "x$FOUND_MAKE" = x; then 17492 if test "x$TOOLCHAIN_PATH" != x; then 17493 # We have a toolchain path, check that as well before giving up. 17494 OLD_PATH=$PATH 17495 PATH=$TOOLCHAIN_PATH:$PATH 17496 for ac_prog in gmake 17497 do 17498 # Extract the first word of "$ac_prog", so it can be a program name with args. 17499 set dummy $ac_prog; ac_word=$2 17500 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 17501 $as_echo_n "checking for $ac_word... " >&6; } 17502 if ${ac_cv_path_CHECK_TOOLSDIR_GMAKE+:} false; then : 17503 $as_echo_n "(cached) " >&6 17504 else 17505 case $CHECK_TOOLSDIR_GMAKE in 17506 [\\/]* | ?:[\\/]*) 17507 ac_cv_path_CHECK_TOOLSDIR_GMAKE="$CHECK_TOOLSDIR_GMAKE" # Let the user override the test with a path. 17508 ;; 17509 *) 17510 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 17511 for as_dir in $PATH 17512 do 17513 IFS=$as_save_IFS 17514 test -z "$as_dir" && as_dir=. 17515 for ac_exec_ext in '' $ac_executable_extensions; do 17516 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 17517 ac_cv_path_CHECK_TOOLSDIR_GMAKE="$as_dir/$ac_word$ac_exec_ext" 17518 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 17519 break 2 17520 fi 17521 done 17522 done 17523 IFS=$as_save_IFS 17524 17525 ;; 17526 esac 17527 fi 17528 CHECK_TOOLSDIR_GMAKE=$ac_cv_path_CHECK_TOOLSDIR_GMAKE 17529 if test -n "$CHECK_TOOLSDIR_GMAKE"; then 17530 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_GMAKE" >&5 17531 $as_echo "$CHECK_TOOLSDIR_GMAKE" >&6; } 17532 else 17533 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 17534 $as_echo "no" >&6; } 17535 fi 17536 17537 17538 test -n "$CHECK_TOOLSDIR_GMAKE" && break 17539 done 17540 17541 17542 MAKE_CANDIDATE=""$CHECK_TOOLSDIR_GMAKE"" 17543 DESCRIPTION="gmake in tools-dir" 17544 17545 # On Cygwin, we require a newer version of make than on other platforms 17546 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17547 MAKE_VERSION_EXPR="-e 4\." 17548 MAKE_REQUIRED_VERSION="4.0" 17549 else 17550 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 17551 MAKE_REQUIRED_VERSION="3.81" 17552 fi 17553 17554 if test "x$MAKE_CANDIDATE" != x; then 17555 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 17556 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 17557 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 17558 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 17559 if test "x$IS_GNU_MAKE" = x; then 17560 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 17561 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 17562 else 17563 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 17564 if test "x$IS_MODERN_MAKE" = x; then 17565 { $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 17566 $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;} 17567 else 17568 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 17569 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17570 MAKE_EXPECTED_ENV='cygwin' 17571 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17572 MAKE_EXPECTED_ENV='msys' 17573 else 17574 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 17575 fi 17576 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 17577 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 17578 else 17579 # Not relevant for non-Windows 17580 IS_MAKE_CORRECT_ENV=true 17581 fi 17582 if test "x$IS_MAKE_CORRECT_ENV" = x; then 17583 { $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 17584 $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;} 17585 else 17586 FOUND_MAKE=$MAKE_CANDIDATE 17587 17588 # Only process if variable expands to non-empty 17589 17590 if test "x$FOUND_MAKE" != x; then 17591 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17592 17593 # First separate the path from the arguments. This will split at the first 17594 # space. 17595 complete="$FOUND_MAKE" 17596 path="${complete%% *}" 17597 tmp="$complete EOL" 17598 arguments="${tmp#* }" 17599 17600 # Input might be given as Windows format, start by converting to 17601 # unix format. 17602 new_path=`$CYGPATH -u "$path"` 17603 17604 # Now try to locate executable using which 17605 new_path=`$WHICH "$new_path" 2> /dev/null` 17606 # bat and cmd files are not always considered executable in cygwin causing which 17607 # to not find them 17608 if test "x$new_path" = x \ 17609 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 17610 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 17611 new_path=`$CYGPATH -u "$path"` 17612 fi 17613 if test "x$new_path" = x; then 17614 # Oops. Which didn't find the executable. 17615 # The splitting of arguments from the executable at a space might have been incorrect, 17616 # since paths with space are more likely in Windows. Give it another try with the whole 17617 # argument. 17618 path="$complete" 17619 arguments="EOL" 17620 new_path=`$CYGPATH -u "$path"` 17621 new_path=`$WHICH "$new_path" 2> /dev/null` 17622 # bat and cmd files are not always considered executable in cygwin causing which 17623 # to not find them 17624 if test "x$new_path" = x \ 17625 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 17626 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 17627 new_path=`$CYGPATH -u "$path"` 17628 fi 17629 if test "x$new_path" = x; then 17630 # It's still not found. Now this is an unrecoverable error. 17631 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 17632 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 17633 has_space=`$ECHO "$complete" | $GREP " "` 17634 if test "x$has_space" != x; then 17635 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 17636 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 17637 fi 17638 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 17639 fi 17640 fi 17641 17642 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 17643 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 17644 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 17645 # "foo.exe" is OK but "foo" is an error. 17646 # 17647 # This test is therefore slightly more accurate than "test -f" to check for file presence. 17648 # It is also a way to make sure we got the proper file name for the real test later on. 17649 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 17650 if test "x$test_shortpath" = x; then 17651 # Short path failed, file does not exist as specified. 17652 # Try adding .exe or .cmd 17653 if test -f "${new_path}.exe"; then 17654 input_to_shortpath="${new_path}.exe" 17655 elif test -f "${new_path}.cmd"; then 17656 input_to_shortpath="${new_path}.cmd" 17657 else 17658 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 17659 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 17660 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 17661 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 17662 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 17663 fi 17664 else 17665 input_to_shortpath="$new_path" 17666 fi 17667 17668 # Call helper function which possibly converts this using DOS-style short mode. 17669 # If so, the updated path is stored in $new_path. 17670 new_path="$input_to_shortpath" 17671 17672 input_path="$input_to_shortpath" 17673 # Check if we need to convert this using DOS-style short mode. If the path 17674 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17675 # take no chances and rewrite it. 17676 # Note: m4 eats our [], so we need to use [ and ] instead. 17677 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 17678 if test "x$has_forbidden_chars" != x; then 17679 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17680 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 17681 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 17682 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 17683 # Going to short mode and back again did indeed matter. Since short mode is 17684 # case insensitive, let's make it lowercase to improve readability. 17685 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17686 # Now convert it back to Unix-style (cygpath) 17687 input_path=`$CYGPATH -u "$shortmode_path"` 17688 new_path="$input_path" 17689 fi 17690 fi 17691 17692 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 17693 if test "x$test_cygdrive_prefix" = x; then 17694 # As a simple fix, exclude /usr/bin since it's not a real path. 17695 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 17696 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 17697 # a path prefixed by /cygdrive for fixpath to work. 17698 new_path="$CYGWIN_ROOT_PATH$input_path" 17699 fi 17700 fi 17701 17702 # remove trailing .exe if any 17703 new_path="${new_path/%.exe/}" 17704 17705 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17706 17707 # First separate the path from the arguments. This will split at the first 17708 # space. 17709 complete="$FOUND_MAKE" 17710 path="${complete%% *}" 17711 tmp="$complete EOL" 17712 arguments="${tmp#* }" 17713 17714 # Input might be given as Windows format, start by converting to 17715 # unix format. 17716 new_path="$path" 17717 17718 windows_path="$new_path" 17719 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17720 unix_path=`$CYGPATH -u "$windows_path"` 17721 new_path="$unix_path" 17722 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17723 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17724 new_path="$unix_path" 17725 fi 17726 17727 17728 # Now try to locate executable using which 17729 new_path=`$WHICH "$new_path" 2> /dev/null` 17730 17731 if test "x$new_path" = x; then 17732 # Oops. Which didn't find the executable. 17733 # The splitting of arguments from the executable at a space might have been incorrect, 17734 # since paths with space are more likely in Windows. Give it another try with the whole 17735 # argument. 17736 path="$complete" 17737 arguments="EOL" 17738 new_path="$path" 17739 17740 windows_path="$new_path" 17741 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17742 unix_path=`$CYGPATH -u "$windows_path"` 17743 new_path="$unix_path" 17744 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17745 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17746 new_path="$unix_path" 17747 fi 17748 17749 17750 new_path=`$WHICH "$new_path" 2> /dev/null` 17751 # bat and cmd files are not always considered executable in MSYS causing which 17752 # to not find them 17753 if test "x$new_path" = x \ 17754 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 17755 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 17756 new_path="$path" 17757 17758 windows_path="$new_path" 17759 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17760 unix_path=`$CYGPATH -u "$windows_path"` 17761 new_path="$unix_path" 17762 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17763 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17764 new_path="$unix_path" 17765 fi 17766 17767 fi 17768 17769 if test "x$new_path" = x; then 17770 # It's still not found. Now this is an unrecoverable error. 17771 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 17772 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 17773 has_space=`$ECHO "$complete" | $GREP " "` 17774 if test "x$has_space" != x; then 17775 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 17776 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 17777 fi 17778 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 17779 fi 17780 fi 17781 17782 # Now new_path has a complete unix path to the binary 17783 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 17784 # Keep paths in /bin as-is, but remove trailing .exe if any 17785 new_path="${new_path/%.exe/}" 17786 # Do not save /bin paths to all_fixpath_prefixes! 17787 else 17788 # Not in mixed or Windows style, start by that. 17789 new_path=`cmd //c echo $new_path` 17790 17791 input_path="$new_path" 17792 # Check if we need to convert this using DOS-style short mode. If the path 17793 # contains just simple characters, use it. Otherwise (spaces, weird characters), 17794 # take no chances and rewrite it. 17795 # Note: m4 eats our [], so we need to use [ and ] instead. 17796 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 17797 if test "x$has_forbidden_chars" != x; then 17798 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 17799 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 17800 fi 17801 17802 # Output is in $new_path 17803 17804 windows_path="$new_path" 17805 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17806 unix_path=`$CYGPATH -u "$windows_path"` 17807 new_path="$unix_path" 17808 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17809 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 17810 new_path="$unix_path" 17811 fi 17812 17813 # remove trailing .exe if any 17814 new_path="${new_path/%.exe/}" 17815 17816 # Save the first 10 bytes of this path to the storage, so fixpath can work. 17817 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 17818 fi 17819 17820 else 17821 # We're on a unix platform. Hooray! :) 17822 # First separate the path from the arguments. This will split at the first 17823 # space. 17824 complete="$FOUND_MAKE" 17825 path="${complete%% *}" 17826 tmp="$complete EOL" 17827 arguments="${tmp#* }" 17828 17829 # Cannot rely on the command "which" here since it doesn't always work. 17830 is_absolute_path=`$ECHO "$path" | $GREP ^/` 17831 if test -z "$is_absolute_path"; then 17832 # Path to executable is not absolute. Find it. 17833 IFS_save="$IFS" 17834 IFS=: 17835 for p in $PATH; do 17836 if test -f "$p/$path" && test -x "$p/$path"; then 17837 new_path="$p/$path" 17838 break 17839 fi 17840 done 17841 IFS="$IFS_save" 17842 else 17843 # This is an absolute path, we can use it without further modifications. 17844 new_path="$path" 17845 fi 17846 17847 if test "x$new_path" = x; then 17848 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 17849 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 17850 has_space=`$ECHO "$complete" | $GREP " "` 17851 if test "x$has_space" != x; then 17852 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 17853 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 17854 fi 17855 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 17856 fi 17857 fi 17858 17859 # Now join together the path and the arguments once again 17860 if test "x$arguments" != xEOL; then 17861 new_complete="$new_path ${arguments% *}" 17862 else 17863 new_complete="$new_path" 17864 fi 17865 17866 if test "x$complete" != "x$new_complete"; then 17867 FOUND_MAKE="$new_complete" 17868 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 17869 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 17870 fi 17871 fi 17872 17873 fi 17874 fi 17875 fi 17876 fi 17877 17878 if test "x$FOUND_MAKE" = x; then 17879 for ac_prog in make 17880 do 17881 # Extract the first word of "$ac_prog", so it can be a program name with args. 17882 set dummy $ac_prog; ac_word=$2 17883 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 17884 $as_echo_n "checking for $ac_word... " >&6; } 17885 if ${ac_cv_path_CHECK_TOOLSDIR_MAKE+:} false; then : 17886 $as_echo_n "(cached) " >&6 17887 else 17888 case $CHECK_TOOLSDIR_MAKE in 17889 [\\/]* | ?:[\\/]*) 17890 ac_cv_path_CHECK_TOOLSDIR_MAKE="$CHECK_TOOLSDIR_MAKE" # Let the user override the test with a path. 17891 ;; 17892 *) 17893 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 17894 for as_dir in $PATH 17895 do 17896 IFS=$as_save_IFS 17897 test -z "$as_dir" && as_dir=. 17898 for ac_exec_ext in '' $ac_executable_extensions; do 17899 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 17900 ac_cv_path_CHECK_TOOLSDIR_MAKE="$as_dir/$ac_word$ac_exec_ext" 17901 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 17902 break 2 17903 fi 17904 done 17905 done 17906 IFS=$as_save_IFS 17907 17908 ;; 17909 esac 17910 fi 17911 CHECK_TOOLSDIR_MAKE=$ac_cv_path_CHECK_TOOLSDIR_MAKE 17912 if test -n "$CHECK_TOOLSDIR_MAKE"; then 17913 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_MAKE" >&5 17914 $as_echo "$CHECK_TOOLSDIR_MAKE" >&6; } 17915 else 17916 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 17917 $as_echo "no" >&6; } 17918 fi 17919 17920 17921 test -n "$CHECK_TOOLSDIR_MAKE" && break 17922 done 17923 17924 17925 MAKE_CANDIDATE=""$CHECK_TOOLSDIR_MAKE"" 17926 DESCRIPTION="make in tools-dir" 17927 17928 # On Cygwin, we require a newer version of make than on other platforms 17929 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17930 MAKE_VERSION_EXPR="-e 4\." 17931 MAKE_REQUIRED_VERSION="4.0" 17932 else 17933 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 17934 MAKE_REQUIRED_VERSION="3.81" 17935 fi 17936 17937 if test "x$MAKE_CANDIDATE" != x; then 17938 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 17939 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 17940 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 17941 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 17942 if test "x$IS_GNU_MAKE" = x; then 17943 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 17944 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 17945 else 17946 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 17947 if test "x$IS_MODERN_MAKE" = x; then 17948 { $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 17949 $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;} 17950 else 17951 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 17952 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17953 MAKE_EXPECTED_ENV='cygwin' 17954 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 17955 MAKE_EXPECTED_ENV='msys' 17956 else 17957 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 17958 fi 17959 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 17960 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 17961 else 17962 # Not relevant for non-Windows 17963 IS_MAKE_CORRECT_ENV=true 17964 fi 17965 if test "x$IS_MAKE_CORRECT_ENV" = x; then 17966 { $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 17967 $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;} 17968 else 17969 FOUND_MAKE=$MAKE_CANDIDATE 17970 17971 # Only process if variable expands to non-empty 17972 17973 if test "x$FOUND_MAKE" != x; then 17974 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 17975 17976 # First separate the path from the arguments. This will split at the first 17977 # space. 17978 complete="$FOUND_MAKE" 17979 path="${complete%% *}" 17980 tmp="$complete EOL" 17981 arguments="${tmp#* }" 17982 17983 # Input might be given as Windows format, start by converting to 17984 # unix format. 17985 new_path=`$CYGPATH -u "$path"` 17986 17987 # Now try to locate executable using which 17988 new_path=`$WHICH "$new_path" 2> /dev/null` 17989 # bat and cmd files are not always considered executable in cygwin causing which 17990 # to not find them 17991 if test "x$new_path" = x \ 17992 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 17993 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 17994 new_path=`$CYGPATH -u "$path"` 17995 fi 17996 if test "x$new_path" = x; then 17997 # Oops. Which didn't find the executable. 17998 # The splitting of arguments from the executable at a space might have been incorrect, 17999 # since paths with space are more likely in Windows. Give it another try with the whole 18000 # argument. 18001 path="$complete" 18002 arguments="EOL" 18003 new_path=`$CYGPATH -u "$path"` 18004 new_path=`$WHICH "$new_path" 2> /dev/null` 18005 # bat and cmd files are not always considered executable in cygwin causing which 18006 # to not find them 18007 if test "x$new_path" = x \ 18008 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18009 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18010 new_path=`$CYGPATH -u "$path"` 18011 fi 18012 if test "x$new_path" = x; then 18013 # It's still not found. Now this is an unrecoverable error. 18014 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18015 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18016 has_space=`$ECHO "$complete" | $GREP " "` 18017 if test "x$has_space" != x; then 18018 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18019 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18020 fi 18021 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18022 fi 18023 fi 18024 18025 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 18026 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 18027 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 18028 # "foo.exe" is OK but "foo" is an error. 18029 # 18030 # This test is therefore slightly more accurate than "test -f" to check for file presence. 18031 # It is also a way to make sure we got the proper file name for the real test later on. 18032 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 18033 if test "x$test_shortpath" = x; then 18034 # Short path failed, file does not exist as specified. 18035 # Try adding .exe or .cmd 18036 if test -f "${new_path}.exe"; then 18037 input_to_shortpath="${new_path}.exe" 18038 elif test -f "${new_path}.cmd"; then 18039 input_to_shortpath="${new_path}.cmd" 18040 else 18041 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 18042 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 18043 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 18044 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 18045 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18046 fi 18047 else 18048 input_to_shortpath="$new_path" 18049 fi 18050 18051 # Call helper function which possibly converts this using DOS-style short mode. 18052 # If so, the updated path is stored in $new_path. 18053 new_path="$input_to_shortpath" 18054 18055 input_path="$input_to_shortpath" 18056 # Check if we need to convert this using DOS-style short mode. If the path 18057 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18058 # take no chances and rewrite it. 18059 # Note: m4 eats our [], so we need to use [ and ] instead. 18060 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 18061 if test "x$has_forbidden_chars" != x; then 18062 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18063 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 18064 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 18065 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 18066 # Going to short mode and back again did indeed matter. Since short mode is 18067 # case insensitive, let's make it lowercase to improve readability. 18068 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18069 # Now convert it back to Unix-style (cygpath) 18070 input_path=`$CYGPATH -u "$shortmode_path"` 18071 new_path="$input_path" 18072 fi 18073 fi 18074 18075 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 18076 if test "x$test_cygdrive_prefix" = x; then 18077 # As a simple fix, exclude /usr/bin since it's not a real path. 18078 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 18079 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 18080 # a path prefixed by /cygdrive for fixpath to work. 18081 new_path="$CYGWIN_ROOT_PATH$input_path" 18082 fi 18083 fi 18084 18085 # remove trailing .exe if any 18086 new_path="${new_path/%.exe/}" 18087 18088 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18089 18090 # First separate the path from the arguments. This will split at the first 18091 # space. 18092 complete="$FOUND_MAKE" 18093 path="${complete%% *}" 18094 tmp="$complete EOL" 18095 arguments="${tmp#* }" 18096 18097 # Input might be given as Windows format, start by converting to 18098 # unix format. 18099 new_path="$path" 18100 18101 windows_path="$new_path" 18102 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18103 unix_path=`$CYGPATH -u "$windows_path"` 18104 new_path="$unix_path" 18105 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18106 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18107 new_path="$unix_path" 18108 fi 18109 18110 18111 # Now try to locate executable using which 18112 new_path=`$WHICH "$new_path" 2> /dev/null` 18113 18114 if test "x$new_path" = x; then 18115 # Oops. Which didn't find the executable. 18116 # The splitting of arguments from the executable at a space might have been incorrect, 18117 # since paths with space are more likely in Windows. Give it another try with the whole 18118 # argument. 18119 path="$complete" 18120 arguments="EOL" 18121 new_path="$path" 18122 18123 windows_path="$new_path" 18124 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18125 unix_path=`$CYGPATH -u "$windows_path"` 18126 new_path="$unix_path" 18127 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18128 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18129 new_path="$unix_path" 18130 fi 18131 18132 18133 new_path=`$WHICH "$new_path" 2> /dev/null` 18134 # bat and cmd files are not always considered executable in MSYS causing which 18135 # to not find them 18136 if test "x$new_path" = x \ 18137 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18138 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18139 new_path="$path" 18140 18141 windows_path="$new_path" 18142 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18143 unix_path=`$CYGPATH -u "$windows_path"` 18144 new_path="$unix_path" 18145 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18146 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18147 new_path="$unix_path" 18148 fi 18149 18150 fi 18151 18152 if test "x$new_path" = x; then 18153 # It's still not found. Now this is an unrecoverable error. 18154 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18155 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18156 has_space=`$ECHO "$complete" | $GREP " "` 18157 if test "x$has_space" != x; then 18158 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18159 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18160 fi 18161 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18162 fi 18163 fi 18164 18165 # Now new_path has a complete unix path to the binary 18166 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 18167 # Keep paths in /bin as-is, but remove trailing .exe if any 18168 new_path="${new_path/%.exe/}" 18169 # Do not save /bin paths to all_fixpath_prefixes! 18170 else 18171 # Not in mixed or Windows style, start by that. 18172 new_path=`cmd //c echo $new_path` 18173 18174 input_path="$new_path" 18175 # Check if we need to convert this using DOS-style short mode. If the path 18176 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18177 # take no chances and rewrite it. 18178 # Note: m4 eats our [], so we need to use [ and ] instead. 18179 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 18180 if test "x$has_forbidden_chars" != x; then 18181 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18182 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18183 fi 18184 18185 # Output is in $new_path 18186 18187 windows_path="$new_path" 18188 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18189 unix_path=`$CYGPATH -u "$windows_path"` 18190 new_path="$unix_path" 18191 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18192 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18193 new_path="$unix_path" 18194 fi 18195 18196 # remove trailing .exe if any 18197 new_path="${new_path/%.exe/}" 18198 18199 # Save the first 10 bytes of this path to the storage, so fixpath can work. 18200 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 18201 fi 18202 18203 else 18204 # We're on a unix platform. Hooray! :) 18205 # First separate the path from the arguments. This will split at the first 18206 # space. 18207 complete="$FOUND_MAKE" 18208 path="${complete%% *}" 18209 tmp="$complete EOL" 18210 arguments="${tmp#* }" 18211 18212 # Cannot rely on the command "which" here since it doesn't always work. 18213 is_absolute_path=`$ECHO "$path" | $GREP ^/` 18214 if test -z "$is_absolute_path"; then 18215 # Path to executable is not absolute. Find it. 18216 IFS_save="$IFS" 18217 IFS=: 18218 for p in $PATH; do 18219 if test -f "$p/$path" && test -x "$p/$path"; then 18220 new_path="$p/$path" 18221 break 18222 fi 18223 done 18224 IFS="$IFS_save" 18225 else 18226 # This is an absolute path, we can use it without further modifications. 18227 new_path="$path" 18228 fi 18229 18230 if test "x$new_path" = x; then 18231 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18232 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18233 has_space=`$ECHO "$complete" | $GREP " "` 18234 if test "x$has_space" != x; then 18235 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 18236 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 18237 fi 18238 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18239 fi 18240 fi 18241 18242 # Now join together the path and the arguments once again 18243 if test "x$arguments" != xEOL; then 18244 new_complete="$new_path ${arguments% *}" 18245 else 18246 new_complete="$new_path" 18247 fi 18248 18249 if test "x$complete" != "x$new_complete"; then 18250 FOUND_MAKE="$new_complete" 18251 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 18252 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 18253 fi 18254 fi 18255 18256 fi 18257 fi 18258 fi 18259 fi 18260 18261 fi 18262 PATH=$OLD_PATH 18263 fi 18264 fi 18265 18266 if test "x$FOUND_MAKE" = x; then 18267 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 18268 fi 18269 18270 else 18271 # The variable is set, but is it from the command line or the environment? 18272 18273 # Try to remove the string !MAKE! from our list. 18274 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!MAKE!/} 18275 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 18276 # If it failed, the variable was not from the command line. Ignore it, 18277 # but warn the user (except for BASH, which is always set by the calling BASH). 18278 if test "xMAKE" != xBASH; then 18279 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of MAKE from the environment. Use command line variables instead." >&5 18280 $as_echo "$as_me: WARNING: Ignoring value of MAKE from the environment. Use command line variables instead." >&2;} 18281 fi 18282 # Try to locate tool using the code snippet 18283 18284 # Try our hardest to locate a correct version of GNU make 18285 for ac_prog in gmake 18286 do 18287 # Extract the first word of "$ac_prog", so it can be a program name with args. 18288 set dummy $ac_prog; ac_word=$2 18289 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 18290 $as_echo_n "checking for $ac_word... " >&6; } 18291 if ${ac_cv_path_CHECK_GMAKE+:} false; then : 18292 $as_echo_n "(cached) " >&6 18293 else 18294 case $CHECK_GMAKE in 18295 [\\/]* | ?:[\\/]*) 18296 ac_cv_path_CHECK_GMAKE="$CHECK_GMAKE" # Let the user override the test with a path. 18297 ;; 18298 *) 18299 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 18300 for as_dir in $PATH 18301 do 18302 IFS=$as_save_IFS 18303 test -z "$as_dir" && as_dir=. 18304 for ac_exec_ext in '' $ac_executable_extensions; do 18305 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 18306 ac_cv_path_CHECK_GMAKE="$as_dir/$ac_word$ac_exec_ext" 18307 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 18308 break 2 18309 fi 18310 done 18311 done 18312 IFS=$as_save_IFS 18313 18314 ;; 18315 esac 18316 fi 18317 CHECK_GMAKE=$ac_cv_path_CHECK_GMAKE 18318 if test -n "$CHECK_GMAKE"; then 18319 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_GMAKE" >&5 18320 $as_echo "$CHECK_GMAKE" >&6; } 18321 else 18322 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 18323 $as_echo "no" >&6; } 18324 fi 18325 18326 18327 test -n "$CHECK_GMAKE" && break 18328 done 18329 18330 18331 MAKE_CANDIDATE=""$CHECK_GMAKE"" 18332 DESCRIPTION="gmake in PATH" 18333 18334 # On Cygwin, we require a newer version of make than on other platforms 18335 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18336 MAKE_VERSION_EXPR="-e 4\." 18337 MAKE_REQUIRED_VERSION="4.0" 18338 else 18339 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 18340 MAKE_REQUIRED_VERSION="3.81" 18341 fi 18342 18343 if test "x$MAKE_CANDIDATE" != x; then 18344 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 18345 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 18346 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 18347 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 18348 if test "x$IS_GNU_MAKE" = x; then 18349 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 18350 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 18351 else 18352 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 18353 if test "x$IS_MODERN_MAKE" = x; then 18354 { $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 18355 $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;} 18356 else 18357 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 18358 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18359 MAKE_EXPECTED_ENV='cygwin' 18360 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18361 MAKE_EXPECTED_ENV='msys' 18362 else 18363 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 18364 fi 18365 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 18366 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 18367 else 18368 # Not relevant for non-Windows 18369 IS_MAKE_CORRECT_ENV=true 18370 fi 18371 if test "x$IS_MAKE_CORRECT_ENV" = x; then 18372 { $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 18373 $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;} 18374 else 18375 FOUND_MAKE=$MAKE_CANDIDATE 18376 18377 # Only process if variable expands to non-empty 18378 18379 if test "x$FOUND_MAKE" != x; then 18380 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18381 18382 # First separate the path from the arguments. This will split at the first 18383 # space. 18384 complete="$FOUND_MAKE" 18385 path="${complete%% *}" 18386 tmp="$complete EOL" 18387 arguments="${tmp#* }" 18388 18389 # Input might be given as Windows format, start by converting to 18390 # unix format. 18391 new_path=`$CYGPATH -u "$path"` 18392 18393 # Now try to locate executable using which 18394 new_path=`$WHICH "$new_path" 2> /dev/null` 18395 # bat and cmd files are not always considered executable in cygwin causing which 18396 # to not find them 18397 if test "x$new_path" = x \ 18398 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18399 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18400 new_path=`$CYGPATH -u "$path"` 18401 fi 18402 if test "x$new_path" = x; then 18403 # Oops. Which didn't find the executable. 18404 # The splitting of arguments from the executable at a space might have been incorrect, 18405 # since paths with space are more likely in Windows. Give it another try with the whole 18406 # argument. 18407 path="$complete" 18408 arguments="EOL" 18409 new_path=`$CYGPATH -u "$path"` 18410 new_path=`$WHICH "$new_path" 2> /dev/null` 18411 # bat and cmd files are not always considered executable in cygwin causing which 18412 # to not find them 18413 if test "x$new_path" = x \ 18414 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18415 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18416 new_path=`$CYGPATH -u "$path"` 18417 fi 18418 if test "x$new_path" = x; then 18419 # It's still not found. Now this is an unrecoverable error. 18420 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18421 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18422 has_space=`$ECHO "$complete" | $GREP " "` 18423 if test "x$has_space" != x; then 18424 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18425 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18426 fi 18427 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18428 fi 18429 fi 18430 18431 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 18432 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 18433 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 18434 # "foo.exe" is OK but "foo" is an error. 18435 # 18436 # This test is therefore slightly more accurate than "test -f" to check for file presence. 18437 # It is also a way to make sure we got the proper file name for the real test later on. 18438 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 18439 if test "x$test_shortpath" = x; then 18440 # Short path failed, file does not exist as specified. 18441 # Try adding .exe or .cmd 18442 if test -f "${new_path}.exe"; then 18443 input_to_shortpath="${new_path}.exe" 18444 elif test -f "${new_path}.cmd"; then 18445 input_to_shortpath="${new_path}.cmd" 18446 else 18447 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 18448 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 18449 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 18450 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 18451 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18452 fi 18453 else 18454 input_to_shortpath="$new_path" 18455 fi 18456 18457 # Call helper function which possibly converts this using DOS-style short mode. 18458 # If so, the updated path is stored in $new_path. 18459 new_path="$input_to_shortpath" 18460 18461 input_path="$input_to_shortpath" 18462 # Check if we need to convert this using DOS-style short mode. If the path 18463 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18464 # take no chances and rewrite it. 18465 # Note: m4 eats our [], so we need to use [ and ] instead. 18466 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 18467 if test "x$has_forbidden_chars" != x; then 18468 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18469 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 18470 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 18471 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 18472 # Going to short mode and back again did indeed matter. Since short mode is 18473 # case insensitive, let's make it lowercase to improve readability. 18474 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18475 # Now convert it back to Unix-style (cygpath) 18476 input_path=`$CYGPATH -u "$shortmode_path"` 18477 new_path="$input_path" 18478 fi 18479 fi 18480 18481 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 18482 if test "x$test_cygdrive_prefix" = x; then 18483 # As a simple fix, exclude /usr/bin since it's not a real path. 18484 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 18485 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 18486 # a path prefixed by /cygdrive for fixpath to work. 18487 new_path="$CYGWIN_ROOT_PATH$input_path" 18488 fi 18489 fi 18490 18491 # remove trailing .exe if any 18492 new_path="${new_path/%.exe/}" 18493 18494 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18495 18496 # First separate the path from the arguments. This will split at the first 18497 # space. 18498 complete="$FOUND_MAKE" 18499 path="${complete%% *}" 18500 tmp="$complete EOL" 18501 arguments="${tmp#* }" 18502 18503 # Input might be given as Windows format, start by converting to 18504 # unix format. 18505 new_path="$path" 18506 18507 windows_path="$new_path" 18508 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18509 unix_path=`$CYGPATH -u "$windows_path"` 18510 new_path="$unix_path" 18511 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18512 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18513 new_path="$unix_path" 18514 fi 18515 18516 18517 # Now try to locate executable using which 18518 new_path=`$WHICH "$new_path" 2> /dev/null` 18519 18520 if test "x$new_path" = x; then 18521 # Oops. Which didn't find the executable. 18522 # The splitting of arguments from the executable at a space might have been incorrect, 18523 # since paths with space are more likely in Windows. Give it another try with the whole 18524 # argument. 18525 path="$complete" 18526 arguments="EOL" 18527 new_path="$path" 18528 18529 windows_path="$new_path" 18530 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18531 unix_path=`$CYGPATH -u "$windows_path"` 18532 new_path="$unix_path" 18533 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18534 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18535 new_path="$unix_path" 18536 fi 18537 18538 18539 new_path=`$WHICH "$new_path" 2> /dev/null` 18540 # bat and cmd files are not always considered executable in MSYS causing which 18541 # to not find them 18542 if test "x$new_path" = x \ 18543 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18544 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18545 new_path="$path" 18546 18547 windows_path="$new_path" 18548 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18549 unix_path=`$CYGPATH -u "$windows_path"` 18550 new_path="$unix_path" 18551 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18552 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18553 new_path="$unix_path" 18554 fi 18555 18556 fi 18557 18558 if test "x$new_path" = x; then 18559 # It's still not found. Now this is an unrecoverable error. 18560 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18561 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18562 has_space=`$ECHO "$complete" | $GREP " "` 18563 if test "x$has_space" != x; then 18564 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18565 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18566 fi 18567 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18568 fi 18569 fi 18570 18571 # Now new_path has a complete unix path to the binary 18572 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 18573 # Keep paths in /bin as-is, but remove trailing .exe if any 18574 new_path="${new_path/%.exe/}" 18575 # Do not save /bin paths to all_fixpath_prefixes! 18576 else 18577 # Not in mixed or Windows style, start by that. 18578 new_path=`cmd //c echo $new_path` 18579 18580 input_path="$new_path" 18581 # Check if we need to convert this using DOS-style short mode. If the path 18582 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18583 # take no chances and rewrite it. 18584 # Note: m4 eats our [], so we need to use [ and ] instead. 18585 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 18586 if test "x$has_forbidden_chars" != x; then 18587 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18588 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18589 fi 18590 18591 # Output is in $new_path 18592 18593 windows_path="$new_path" 18594 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18595 unix_path=`$CYGPATH -u "$windows_path"` 18596 new_path="$unix_path" 18597 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18598 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18599 new_path="$unix_path" 18600 fi 18601 18602 # remove trailing .exe if any 18603 new_path="${new_path/%.exe/}" 18604 18605 # Save the first 10 bytes of this path to the storage, so fixpath can work. 18606 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 18607 fi 18608 18609 else 18610 # We're on a unix platform. Hooray! :) 18611 # First separate the path from the arguments. This will split at the first 18612 # space. 18613 complete="$FOUND_MAKE" 18614 path="${complete%% *}" 18615 tmp="$complete EOL" 18616 arguments="${tmp#* }" 18617 18618 # Cannot rely on the command "which" here since it doesn't always work. 18619 is_absolute_path=`$ECHO "$path" | $GREP ^/` 18620 if test -z "$is_absolute_path"; then 18621 # Path to executable is not absolute. Find it. 18622 IFS_save="$IFS" 18623 IFS=: 18624 for p in $PATH; do 18625 if test -f "$p/$path" && test -x "$p/$path"; then 18626 new_path="$p/$path" 18627 break 18628 fi 18629 done 18630 IFS="$IFS_save" 18631 else 18632 # This is an absolute path, we can use it without further modifications. 18633 new_path="$path" 18634 fi 18635 18636 if test "x$new_path" = x; then 18637 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18638 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18639 has_space=`$ECHO "$complete" | $GREP " "` 18640 if test "x$has_space" != x; then 18641 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 18642 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 18643 fi 18644 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18645 fi 18646 fi 18647 18648 # Now join together the path and the arguments once again 18649 if test "x$arguments" != xEOL; then 18650 new_complete="$new_path ${arguments% *}" 18651 else 18652 new_complete="$new_path" 18653 fi 18654 18655 if test "x$complete" != "x$new_complete"; then 18656 FOUND_MAKE="$new_complete" 18657 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 18658 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 18659 fi 18660 fi 18661 18662 fi 18663 fi 18664 fi 18665 fi 18666 18667 18668 if test "x$FOUND_MAKE" = x; then 18669 for ac_prog in make 18670 do 18671 # Extract the first word of "$ac_prog", so it can be a program name with args. 18672 set dummy $ac_prog; ac_word=$2 18673 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 18674 $as_echo_n "checking for $ac_word... " >&6; } 18675 if ${ac_cv_path_CHECK_MAKE+:} false; then : 18676 $as_echo_n "(cached) " >&6 18677 else 18678 case $CHECK_MAKE in 18679 [\\/]* | ?:[\\/]*) 18680 ac_cv_path_CHECK_MAKE="$CHECK_MAKE" # Let the user override the test with a path. 18681 ;; 18682 *) 18683 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 18684 for as_dir in $PATH 18685 do 18686 IFS=$as_save_IFS 18687 test -z "$as_dir" && as_dir=. 18688 for ac_exec_ext in '' $ac_executable_extensions; do 18689 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 18690 ac_cv_path_CHECK_MAKE="$as_dir/$ac_word$ac_exec_ext" 18691 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 18692 break 2 18693 fi 18694 done 18695 done 18696 IFS=$as_save_IFS 18697 18698 ;; 18699 esac 18700 fi 18701 CHECK_MAKE=$ac_cv_path_CHECK_MAKE 18702 if test -n "$CHECK_MAKE"; then 18703 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_MAKE" >&5 18704 $as_echo "$CHECK_MAKE" >&6; } 18705 else 18706 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 18707 $as_echo "no" >&6; } 18708 fi 18709 18710 18711 test -n "$CHECK_MAKE" && break 18712 done 18713 18714 18715 MAKE_CANDIDATE=""$CHECK_MAKE"" 18716 DESCRIPTION="make in PATH" 18717 18718 # On Cygwin, we require a newer version of make than on other platforms 18719 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18720 MAKE_VERSION_EXPR="-e 4\." 18721 MAKE_REQUIRED_VERSION="4.0" 18722 else 18723 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 18724 MAKE_REQUIRED_VERSION="3.81" 18725 fi 18726 18727 if test "x$MAKE_CANDIDATE" != x; then 18728 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 18729 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 18730 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 18731 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 18732 if test "x$IS_GNU_MAKE" = x; then 18733 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 18734 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 18735 else 18736 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 18737 if test "x$IS_MODERN_MAKE" = x; then 18738 { $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 18739 $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;} 18740 else 18741 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 18742 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18743 MAKE_EXPECTED_ENV='cygwin' 18744 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18745 MAKE_EXPECTED_ENV='msys' 18746 else 18747 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 18748 fi 18749 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 18750 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 18751 else 18752 # Not relevant for non-Windows 18753 IS_MAKE_CORRECT_ENV=true 18754 fi 18755 if test "x$IS_MAKE_CORRECT_ENV" = x; then 18756 { $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 18757 $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;} 18758 else 18759 FOUND_MAKE=$MAKE_CANDIDATE 18760 18761 # Only process if variable expands to non-empty 18762 18763 if test "x$FOUND_MAKE" != x; then 18764 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18765 18766 # First separate the path from the arguments. This will split at the first 18767 # space. 18768 complete="$FOUND_MAKE" 18769 path="${complete%% *}" 18770 tmp="$complete EOL" 18771 arguments="${tmp#* }" 18772 18773 # Input might be given as Windows format, start by converting to 18774 # unix format. 18775 new_path=`$CYGPATH -u "$path"` 18776 18777 # Now try to locate executable using which 18778 new_path=`$WHICH "$new_path" 2> /dev/null` 18779 # bat and cmd files are not always considered executable in cygwin causing which 18780 # to not find them 18781 if test "x$new_path" = x \ 18782 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18783 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18784 new_path=`$CYGPATH -u "$path"` 18785 fi 18786 if test "x$new_path" = x; then 18787 # Oops. Which didn't find the executable. 18788 # The splitting of arguments from the executable at a space might have been incorrect, 18789 # since paths with space are more likely in Windows. Give it another try with the whole 18790 # argument. 18791 path="$complete" 18792 arguments="EOL" 18793 new_path=`$CYGPATH -u "$path"` 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 # It's still not found. Now this is an unrecoverable error. 18804 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18805 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18806 has_space=`$ECHO "$complete" | $GREP " "` 18807 if test "x$has_space" != x; then 18808 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18809 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18810 fi 18811 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18812 fi 18813 fi 18814 18815 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 18816 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 18817 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 18818 # "foo.exe" is OK but "foo" is an error. 18819 # 18820 # This test is therefore slightly more accurate than "test -f" to check for file presence. 18821 # It is also a way to make sure we got the proper file name for the real test later on. 18822 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 18823 if test "x$test_shortpath" = x; then 18824 # Short path failed, file does not exist as specified. 18825 # Try adding .exe or .cmd 18826 if test -f "${new_path}.exe"; then 18827 input_to_shortpath="${new_path}.exe" 18828 elif test -f "${new_path}.cmd"; then 18829 input_to_shortpath="${new_path}.cmd" 18830 else 18831 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 18832 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 18833 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 18834 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 18835 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18836 fi 18837 else 18838 input_to_shortpath="$new_path" 18839 fi 18840 18841 # Call helper function which possibly converts this using DOS-style short mode. 18842 # If so, the updated path is stored in $new_path. 18843 new_path="$input_to_shortpath" 18844 18845 input_path="$input_to_shortpath" 18846 # Check if we need to convert this using DOS-style short mode. If the path 18847 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18848 # take no chances and rewrite it. 18849 # Note: m4 eats our [], so we need to use [ and ] instead. 18850 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 18851 if test "x$has_forbidden_chars" != x; then 18852 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18853 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 18854 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 18855 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 18856 # Going to short mode and back again did indeed matter. Since short mode is 18857 # case insensitive, let's make it lowercase to improve readability. 18858 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18859 # Now convert it back to Unix-style (cygpath) 18860 input_path=`$CYGPATH -u "$shortmode_path"` 18861 new_path="$input_path" 18862 fi 18863 fi 18864 18865 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 18866 if test "x$test_cygdrive_prefix" = x; then 18867 # As a simple fix, exclude /usr/bin since it's not a real path. 18868 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 18869 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 18870 # a path prefixed by /cygdrive for fixpath to work. 18871 new_path="$CYGWIN_ROOT_PATH$input_path" 18872 fi 18873 fi 18874 18875 # remove trailing .exe if any 18876 new_path="${new_path/%.exe/}" 18877 18878 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18879 18880 # First separate the path from the arguments. This will split at the first 18881 # space. 18882 complete="$FOUND_MAKE" 18883 path="${complete%% *}" 18884 tmp="$complete EOL" 18885 arguments="${tmp#* }" 18886 18887 # Input might be given as Windows format, start by converting to 18888 # unix format. 18889 new_path="$path" 18890 18891 windows_path="$new_path" 18892 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18893 unix_path=`$CYGPATH -u "$windows_path"` 18894 new_path="$unix_path" 18895 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18896 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18897 new_path="$unix_path" 18898 fi 18899 18900 18901 # Now try to locate executable using which 18902 new_path=`$WHICH "$new_path" 2> /dev/null` 18903 18904 if test "x$new_path" = x; then 18905 # Oops. Which didn't find the executable. 18906 # The splitting of arguments from the executable at a space might have been incorrect, 18907 # since paths with space are more likely in Windows. Give it another try with the whole 18908 # argument. 18909 path="$complete" 18910 arguments="EOL" 18911 new_path="$path" 18912 18913 windows_path="$new_path" 18914 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18915 unix_path=`$CYGPATH -u "$windows_path"` 18916 new_path="$unix_path" 18917 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18918 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18919 new_path="$unix_path" 18920 fi 18921 18922 18923 new_path=`$WHICH "$new_path" 2> /dev/null` 18924 # bat and cmd files are not always considered executable in MSYS causing which 18925 # to not find them 18926 if test "x$new_path" = x \ 18927 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 18928 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 18929 new_path="$path" 18930 18931 windows_path="$new_path" 18932 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18933 unix_path=`$CYGPATH -u "$windows_path"` 18934 new_path="$unix_path" 18935 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18936 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18937 new_path="$unix_path" 18938 fi 18939 18940 fi 18941 18942 if test "x$new_path" = x; then 18943 # It's still not found. Now this is an unrecoverable error. 18944 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 18945 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 18946 has_space=`$ECHO "$complete" | $GREP " "` 18947 if test "x$has_space" != x; then 18948 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 18949 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 18950 fi 18951 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 18952 fi 18953 fi 18954 18955 # Now new_path has a complete unix path to the binary 18956 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 18957 # Keep paths in /bin as-is, but remove trailing .exe if any 18958 new_path="${new_path/%.exe/}" 18959 # Do not save /bin paths to all_fixpath_prefixes! 18960 else 18961 # Not in mixed or Windows style, start by that. 18962 new_path=`cmd //c echo $new_path` 18963 18964 input_path="$new_path" 18965 # Check if we need to convert this using DOS-style short mode. If the path 18966 # contains just simple characters, use it. Otherwise (spaces, weird characters), 18967 # take no chances and rewrite it. 18968 # Note: m4 eats our [], so we need to use [ and ] instead. 18969 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 18970 if test "x$has_forbidden_chars" != x; then 18971 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 18972 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 18973 fi 18974 18975 # Output is in $new_path 18976 18977 windows_path="$new_path" 18978 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 18979 unix_path=`$CYGPATH -u "$windows_path"` 18980 new_path="$unix_path" 18981 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 18982 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 18983 new_path="$unix_path" 18984 fi 18985 18986 # remove trailing .exe if any 18987 new_path="${new_path/%.exe/}" 18988 18989 # Save the first 10 bytes of this path to the storage, so fixpath can work. 18990 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 18991 fi 18992 18993 else 18994 # We're on a unix platform. Hooray! :) 18995 # First separate the path from the arguments. This will split at the first 18996 # space. 18997 complete="$FOUND_MAKE" 18998 path="${complete%% *}" 18999 tmp="$complete EOL" 19000 arguments="${tmp#* }" 19001 19002 # Cannot rely on the command "which" here since it doesn't always work. 19003 is_absolute_path=`$ECHO "$path" | $GREP ^/` 19004 if test -z "$is_absolute_path"; then 19005 # Path to executable is not absolute. Find it. 19006 IFS_save="$IFS" 19007 IFS=: 19008 for p in $PATH; do 19009 if test -f "$p/$path" && test -x "$p/$path"; then 19010 new_path="$p/$path" 19011 break 19012 fi 19013 done 19014 IFS="$IFS_save" 19015 else 19016 # This is an absolute path, we can use it without further modifications. 19017 new_path="$path" 19018 fi 19019 19020 if test "x$new_path" = x; then 19021 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19022 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19023 has_space=`$ECHO "$complete" | $GREP " "` 19024 if test "x$has_space" != x; then 19025 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 19026 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 19027 fi 19028 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19029 fi 19030 fi 19031 19032 # Now join together the path and the arguments once again 19033 if test "x$arguments" != xEOL; then 19034 new_complete="$new_path ${arguments% *}" 19035 else 19036 new_complete="$new_path" 19037 fi 19038 19039 if test "x$complete" != "x$new_complete"; then 19040 FOUND_MAKE="$new_complete" 19041 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 19042 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 19043 fi 19044 fi 19045 19046 fi 19047 fi 19048 fi 19049 fi 19050 19051 fi 19052 19053 if test "x$FOUND_MAKE" = x; then 19054 if test "x$TOOLCHAIN_PATH" != x; then 19055 # We have a toolchain path, check that as well before giving up. 19056 OLD_PATH=$PATH 19057 PATH=$TOOLCHAIN_PATH:$PATH 19058 for ac_prog in gmake 19059 do 19060 # Extract the first word of "$ac_prog", so it can be a program name with args. 19061 set dummy $ac_prog; ac_word=$2 19062 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 19063 $as_echo_n "checking for $ac_word... " >&6; } 19064 if ${ac_cv_path_CHECK_TOOLSDIR_GMAKE+:} false; then : 19065 $as_echo_n "(cached) " >&6 19066 else 19067 case $CHECK_TOOLSDIR_GMAKE in 19068 [\\/]* | ?:[\\/]*) 19069 ac_cv_path_CHECK_TOOLSDIR_GMAKE="$CHECK_TOOLSDIR_GMAKE" # Let the user override the test with a path. 19070 ;; 19071 *) 19072 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 19073 for as_dir in $PATH 19074 do 19075 IFS=$as_save_IFS 19076 test -z "$as_dir" && as_dir=. 19077 for ac_exec_ext in '' $ac_executable_extensions; do 19078 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 19079 ac_cv_path_CHECK_TOOLSDIR_GMAKE="$as_dir/$ac_word$ac_exec_ext" 19080 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 19081 break 2 19082 fi 19083 done 19084 done 19085 IFS=$as_save_IFS 19086 19087 ;; 19088 esac 19089 fi 19090 CHECK_TOOLSDIR_GMAKE=$ac_cv_path_CHECK_TOOLSDIR_GMAKE 19091 if test -n "$CHECK_TOOLSDIR_GMAKE"; then 19092 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_GMAKE" >&5 19093 $as_echo "$CHECK_TOOLSDIR_GMAKE" >&6; } 19094 else 19095 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 19096 $as_echo "no" >&6; } 19097 fi 19098 19099 19100 test -n "$CHECK_TOOLSDIR_GMAKE" && break 19101 done 19102 19103 19104 MAKE_CANDIDATE=""$CHECK_TOOLSDIR_GMAKE"" 19105 DESCRIPTION="gmake in tools-dir" 19106 19107 # On Cygwin, we require a newer version of make than on other platforms 19108 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19109 MAKE_VERSION_EXPR="-e 4\." 19110 MAKE_REQUIRED_VERSION="4.0" 19111 else 19112 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 19113 MAKE_REQUIRED_VERSION="3.81" 19114 fi 19115 19116 if test "x$MAKE_CANDIDATE" != x; then 19117 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 19118 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 19119 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 19120 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 19121 if test "x$IS_GNU_MAKE" = x; then 19122 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 19123 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 19124 else 19125 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 19126 if test "x$IS_MODERN_MAKE" = x; then 19127 { $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 19128 $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;} 19129 else 19130 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 19131 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19132 MAKE_EXPECTED_ENV='cygwin' 19133 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19134 MAKE_EXPECTED_ENV='msys' 19135 else 19136 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 19137 fi 19138 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 19139 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 19140 else 19141 # Not relevant for non-Windows 19142 IS_MAKE_CORRECT_ENV=true 19143 fi 19144 if test "x$IS_MAKE_CORRECT_ENV" = x; then 19145 { $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 19146 $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;} 19147 else 19148 FOUND_MAKE=$MAKE_CANDIDATE 19149 19150 # Only process if variable expands to non-empty 19151 19152 if test "x$FOUND_MAKE" != x; then 19153 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19154 19155 # First separate the path from the arguments. This will split at the first 19156 # space. 19157 complete="$FOUND_MAKE" 19158 path="${complete%% *}" 19159 tmp="$complete EOL" 19160 arguments="${tmp#* }" 19161 19162 # Input might be given as Windows format, start by converting to 19163 # unix format. 19164 new_path=`$CYGPATH -u "$path"` 19165 19166 # Now try to locate executable using which 19167 new_path=`$WHICH "$new_path" 2> /dev/null` 19168 # bat and cmd files are not always considered executable in cygwin causing which 19169 # to not find them 19170 if test "x$new_path" = x \ 19171 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19172 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19173 new_path=`$CYGPATH -u "$path"` 19174 fi 19175 if test "x$new_path" = x; then 19176 # Oops. Which didn't find the executable. 19177 # The splitting of arguments from the executable at a space might have been incorrect, 19178 # since paths with space are more likely in Windows. Give it another try with the whole 19179 # argument. 19180 path="$complete" 19181 arguments="EOL" 19182 new_path=`$CYGPATH -u "$path"` 19183 new_path=`$WHICH "$new_path" 2> /dev/null` 19184 # bat and cmd files are not always considered executable in cygwin causing which 19185 # to not find them 19186 if test "x$new_path" = x \ 19187 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19188 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19189 new_path=`$CYGPATH -u "$path"` 19190 fi 19191 if test "x$new_path" = x; then 19192 # It's still not found. Now this is an unrecoverable error. 19193 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19194 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19195 has_space=`$ECHO "$complete" | $GREP " "` 19196 if test "x$has_space" != x; then 19197 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19198 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19199 fi 19200 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19201 fi 19202 fi 19203 19204 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 19205 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 19206 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 19207 # "foo.exe" is OK but "foo" is an error. 19208 # 19209 # This test is therefore slightly more accurate than "test -f" to check for file presence. 19210 # It is also a way to make sure we got the proper file name for the real test later on. 19211 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 19212 if test "x$test_shortpath" = x; then 19213 # Short path failed, file does not exist as specified. 19214 # Try adding .exe or .cmd 19215 if test -f "${new_path}.exe"; then 19216 input_to_shortpath="${new_path}.exe" 19217 elif test -f "${new_path}.cmd"; then 19218 input_to_shortpath="${new_path}.cmd" 19219 else 19220 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 19221 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 19222 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 19223 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 19224 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19225 fi 19226 else 19227 input_to_shortpath="$new_path" 19228 fi 19229 19230 # Call helper function which possibly converts this using DOS-style short mode. 19231 # If so, the updated path is stored in $new_path. 19232 new_path="$input_to_shortpath" 19233 19234 input_path="$input_to_shortpath" 19235 # Check if we need to convert this using DOS-style short mode. If the path 19236 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19237 # take no chances and rewrite it. 19238 # Note: m4 eats our [], so we need to use [ and ] instead. 19239 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 19240 if test "x$has_forbidden_chars" != x; then 19241 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19242 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 19243 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 19244 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 19245 # Going to short mode and back again did indeed matter. Since short mode is 19246 # case insensitive, let's make it lowercase to improve readability. 19247 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19248 # Now convert it back to Unix-style (cygpath) 19249 input_path=`$CYGPATH -u "$shortmode_path"` 19250 new_path="$input_path" 19251 fi 19252 fi 19253 19254 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 19255 if test "x$test_cygdrive_prefix" = x; then 19256 # As a simple fix, exclude /usr/bin since it's not a real path. 19257 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 19258 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 19259 # a path prefixed by /cygdrive for fixpath to work. 19260 new_path="$CYGWIN_ROOT_PATH$input_path" 19261 fi 19262 fi 19263 19264 # remove trailing .exe if any 19265 new_path="${new_path/%.exe/}" 19266 19267 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19268 19269 # First separate the path from the arguments. This will split at the first 19270 # space. 19271 complete="$FOUND_MAKE" 19272 path="${complete%% *}" 19273 tmp="$complete EOL" 19274 arguments="${tmp#* }" 19275 19276 # Input might be given as Windows format, start by converting to 19277 # unix format. 19278 new_path="$path" 19279 19280 windows_path="$new_path" 19281 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19282 unix_path=`$CYGPATH -u "$windows_path"` 19283 new_path="$unix_path" 19284 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19285 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19286 new_path="$unix_path" 19287 fi 19288 19289 19290 # Now try to locate executable using which 19291 new_path=`$WHICH "$new_path" 2> /dev/null` 19292 19293 if test "x$new_path" = x; then 19294 # Oops. Which didn't find the executable. 19295 # The splitting of arguments from the executable at a space might have been incorrect, 19296 # since paths with space are more likely in Windows. Give it another try with the whole 19297 # argument. 19298 path="$complete" 19299 arguments="EOL" 19300 new_path="$path" 19301 19302 windows_path="$new_path" 19303 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19304 unix_path=`$CYGPATH -u "$windows_path"` 19305 new_path="$unix_path" 19306 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19307 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19308 new_path="$unix_path" 19309 fi 19310 19311 19312 new_path=`$WHICH "$new_path" 2> /dev/null` 19313 # bat and cmd files are not always considered executable in MSYS causing which 19314 # to not find them 19315 if test "x$new_path" = x \ 19316 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19317 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19318 new_path="$path" 19319 19320 windows_path="$new_path" 19321 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19322 unix_path=`$CYGPATH -u "$windows_path"` 19323 new_path="$unix_path" 19324 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19325 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19326 new_path="$unix_path" 19327 fi 19328 19329 fi 19330 19331 if test "x$new_path" = x; then 19332 # It's still not found. Now this is an unrecoverable error. 19333 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19334 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19335 has_space=`$ECHO "$complete" | $GREP " "` 19336 if test "x$has_space" != x; then 19337 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19338 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19339 fi 19340 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19341 fi 19342 fi 19343 19344 # Now new_path has a complete unix path to the binary 19345 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 19346 # Keep paths in /bin as-is, but remove trailing .exe if any 19347 new_path="${new_path/%.exe/}" 19348 # Do not save /bin paths to all_fixpath_prefixes! 19349 else 19350 # Not in mixed or Windows style, start by that. 19351 new_path=`cmd //c echo $new_path` 19352 19353 input_path="$new_path" 19354 # Check if we need to convert this using DOS-style short mode. If the path 19355 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19356 # take no chances and rewrite it. 19357 # Note: m4 eats our [], so we need to use [ and ] instead. 19358 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 19359 if test "x$has_forbidden_chars" != x; then 19360 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19361 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19362 fi 19363 19364 # Output is in $new_path 19365 19366 windows_path="$new_path" 19367 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19368 unix_path=`$CYGPATH -u "$windows_path"` 19369 new_path="$unix_path" 19370 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19371 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19372 new_path="$unix_path" 19373 fi 19374 19375 # remove trailing .exe if any 19376 new_path="${new_path/%.exe/}" 19377 19378 # Save the first 10 bytes of this path to the storage, so fixpath can work. 19379 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 19380 fi 19381 19382 else 19383 # We're on a unix platform. Hooray! :) 19384 # First separate the path from the arguments. This will split at the first 19385 # space. 19386 complete="$FOUND_MAKE" 19387 path="${complete%% *}" 19388 tmp="$complete EOL" 19389 arguments="${tmp#* }" 19390 19391 # Cannot rely on the command "which" here since it doesn't always work. 19392 is_absolute_path=`$ECHO "$path" | $GREP ^/` 19393 if test -z "$is_absolute_path"; then 19394 # Path to executable is not absolute. Find it. 19395 IFS_save="$IFS" 19396 IFS=: 19397 for p in $PATH; do 19398 if test -f "$p/$path" && test -x "$p/$path"; then 19399 new_path="$p/$path" 19400 break 19401 fi 19402 done 19403 IFS="$IFS_save" 19404 else 19405 # This is an absolute path, we can use it without further modifications. 19406 new_path="$path" 19407 fi 19408 19409 if test "x$new_path" = x; then 19410 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19411 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19412 has_space=`$ECHO "$complete" | $GREP " "` 19413 if test "x$has_space" != x; then 19414 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 19415 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 19416 fi 19417 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19418 fi 19419 fi 19420 19421 # Now join together the path and the arguments once again 19422 if test "x$arguments" != xEOL; then 19423 new_complete="$new_path ${arguments% *}" 19424 else 19425 new_complete="$new_path" 19426 fi 19427 19428 if test "x$complete" != "x$new_complete"; then 19429 FOUND_MAKE="$new_complete" 19430 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 19431 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 19432 fi 19433 fi 19434 19435 fi 19436 fi 19437 fi 19438 fi 19439 19440 if test "x$FOUND_MAKE" = x; then 19441 for ac_prog in make 19442 do 19443 # Extract the first word of "$ac_prog", so it can be a program name with args. 19444 set dummy $ac_prog; ac_word=$2 19445 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 19446 $as_echo_n "checking for $ac_word... " >&6; } 19447 if ${ac_cv_path_CHECK_TOOLSDIR_MAKE+:} false; then : 19448 $as_echo_n "(cached) " >&6 19449 else 19450 case $CHECK_TOOLSDIR_MAKE in 19451 [\\/]* | ?:[\\/]*) 19452 ac_cv_path_CHECK_TOOLSDIR_MAKE="$CHECK_TOOLSDIR_MAKE" # Let the user override the test with a path. 19453 ;; 19454 *) 19455 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 19456 for as_dir in $PATH 19457 do 19458 IFS=$as_save_IFS 19459 test -z "$as_dir" && as_dir=. 19460 for ac_exec_ext in '' $ac_executable_extensions; do 19461 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 19462 ac_cv_path_CHECK_TOOLSDIR_MAKE="$as_dir/$ac_word$ac_exec_ext" 19463 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 19464 break 2 19465 fi 19466 done 19467 done 19468 IFS=$as_save_IFS 19469 19470 ;; 19471 esac 19472 fi 19473 CHECK_TOOLSDIR_MAKE=$ac_cv_path_CHECK_TOOLSDIR_MAKE 19474 if test -n "$CHECK_TOOLSDIR_MAKE"; then 19475 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CHECK_TOOLSDIR_MAKE" >&5 19476 $as_echo "$CHECK_TOOLSDIR_MAKE" >&6; } 19477 else 19478 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 19479 $as_echo "no" >&6; } 19480 fi 19481 19482 19483 test -n "$CHECK_TOOLSDIR_MAKE" && break 19484 done 19485 19486 19487 MAKE_CANDIDATE=""$CHECK_TOOLSDIR_MAKE"" 19488 DESCRIPTION="make in tools-dir" 19489 19490 # On Cygwin, we require a newer version of make than on other platforms 19491 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19492 MAKE_VERSION_EXPR="-e 4\." 19493 MAKE_REQUIRED_VERSION="4.0" 19494 else 19495 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 19496 MAKE_REQUIRED_VERSION="3.81" 19497 fi 19498 19499 if test "x$MAKE_CANDIDATE" != x; then 19500 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 19501 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 19502 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 19503 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 19504 if test "x$IS_GNU_MAKE" = x; then 19505 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 19506 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 19507 else 19508 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 19509 if test "x$IS_MODERN_MAKE" = x; then 19510 { $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 19511 $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;} 19512 else 19513 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 19514 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19515 MAKE_EXPECTED_ENV='cygwin' 19516 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19517 MAKE_EXPECTED_ENV='msys' 19518 else 19519 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 19520 fi 19521 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 19522 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 19523 else 19524 # Not relevant for non-Windows 19525 IS_MAKE_CORRECT_ENV=true 19526 fi 19527 if test "x$IS_MAKE_CORRECT_ENV" = x; then 19528 { $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 19529 $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;} 19530 else 19531 FOUND_MAKE=$MAKE_CANDIDATE 19532 19533 # Only process if variable expands to non-empty 19534 19535 if test "x$FOUND_MAKE" != x; then 19536 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19537 19538 # First separate the path from the arguments. This will split at the first 19539 # space. 19540 complete="$FOUND_MAKE" 19541 path="${complete%% *}" 19542 tmp="$complete EOL" 19543 arguments="${tmp#* }" 19544 19545 # Input might be given as Windows format, start by converting to 19546 # unix format. 19547 new_path=`$CYGPATH -u "$path"` 19548 19549 # Now try to locate executable using which 19550 new_path=`$WHICH "$new_path" 2> /dev/null` 19551 # bat and cmd files are not always considered executable in cygwin causing which 19552 # to not find them 19553 if test "x$new_path" = x \ 19554 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19555 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19556 new_path=`$CYGPATH -u "$path"` 19557 fi 19558 if test "x$new_path" = x; then 19559 # Oops. Which didn't find the executable. 19560 # The splitting of arguments from the executable at a space might have been incorrect, 19561 # since paths with space are more likely in Windows. Give it another try with the whole 19562 # argument. 19563 path="$complete" 19564 arguments="EOL" 19565 new_path=`$CYGPATH -u "$path"` 19566 new_path=`$WHICH "$new_path" 2> /dev/null` 19567 # bat and cmd files are not always considered executable in cygwin causing which 19568 # to not find them 19569 if test "x$new_path" = x \ 19570 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19571 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19572 new_path=`$CYGPATH -u "$path"` 19573 fi 19574 if test "x$new_path" = x; then 19575 # It's still not found. Now this is an unrecoverable error. 19576 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19577 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19578 has_space=`$ECHO "$complete" | $GREP " "` 19579 if test "x$has_space" != x; then 19580 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19581 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19582 fi 19583 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19584 fi 19585 fi 19586 19587 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 19588 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 19589 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 19590 # "foo.exe" is OK but "foo" is an error. 19591 # 19592 # This test is therefore slightly more accurate than "test -f" to check for file presence. 19593 # It is also a way to make sure we got the proper file name for the real test later on. 19594 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 19595 if test "x$test_shortpath" = x; then 19596 # Short path failed, file does not exist as specified. 19597 # Try adding .exe or .cmd 19598 if test -f "${new_path}.exe"; then 19599 input_to_shortpath="${new_path}.exe" 19600 elif test -f "${new_path}.cmd"; then 19601 input_to_shortpath="${new_path}.cmd" 19602 else 19603 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 19604 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 19605 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 19606 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 19607 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19608 fi 19609 else 19610 input_to_shortpath="$new_path" 19611 fi 19612 19613 # Call helper function which possibly converts this using DOS-style short mode. 19614 # If so, the updated path is stored in $new_path. 19615 new_path="$input_to_shortpath" 19616 19617 input_path="$input_to_shortpath" 19618 # Check if we need to convert this using DOS-style short mode. If the path 19619 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19620 # take no chances and rewrite it. 19621 # Note: m4 eats our [], so we need to use [ and ] instead. 19622 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 19623 if test "x$has_forbidden_chars" != x; then 19624 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19625 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 19626 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 19627 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 19628 # Going to short mode and back again did indeed matter. Since short mode is 19629 # case insensitive, let's make it lowercase to improve readability. 19630 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19631 # Now convert it back to Unix-style (cygpath) 19632 input_path=`$CYGPATH -u "$shortmode_path"` 19633 new_path="$input_path" 19634 fi 19635 fi 19636 19637 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 19638 if test "x$test_cygdrive_prefix" = x; then 19639 # As a simple fix, exclude /usr/bin since it's not a real path. 19640 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 19641 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 19642 # a path prefixed by /cygdrive for fixpath to work. 19643 new_path="$CYGWIN_ROOT_PATH$input_path" 19644 fi 19645 fi 19646 19647 # remove trailing .exe if any 19648 new_path="${new_path/%.exe/}" 19649 19650 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19651 19652 # First separate the path from the arguments. This will split at the first 19653 # space. 19654 complete="$FOUND_MAKE" 19655 path="${complete%% *}" 19656 tmp="$complete EOL" 19657 arguments="${tmp#* }" 19658 19659 # Input might be given as Windows format, start by converting to 19660 # unix format. 19661 new_path="$path" 19662 19663 windows_path="$new_path" 19664 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19665 unix_path=`$CYGPATH -u "$windows_path"` 19666 new_path="$unix_path" 19667 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19668 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19669 new_path="$unix_path" 19670 fi 19671 19672 19673 # Now try to locate executable using which 19674 new_path=`$WHICH "$new_path" 2> /dev/null` 19675 19676 if test "x$new_path" = x; then 19677 # Oops. Which didn't find the executable. 19678 # The splitting of arguments from the executable at a space might have been incorrect, 19679 # since paths with space are more likely in Windows. Give it another try with the whole 19680 # argument. 19681 path="$complete" 19682 arguments="EOL" 19683 new_path="$path" 19684 19685 windows_path="$new_path" 19686 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19687 unix_path=`$CYGPATH -u "$windows_path"` 19688 new_path="$unix_path" 19689 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19690 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19691 new_path="$unix_path" 19692 fi 19693 19694 19695 new_path=`$WHICH "$new_path" 2> /dev/null` 19696 # bat and cmd files are not always considered executable in MSYS causing which 19697 # to not find them 19698 if test "x$new_path" = x \ 19699 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19700 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19701 new_path="$path" 19702 19703 windows_path="$new_path" 19704 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19705 unix_path=`$CYGPATH -u "$windows_path"` 19706 new_path="$unix_path" 19707 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19708 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19709 new_path="$unix_path" 19710 fi 19711 19712 fi 19713 19714 if test "x$new_path" = x; then 19715 # It's still not found. Now this is an unrecoverable error. 19716 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19717 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19718 has_space=`$ECHO "$complete" | $GREP " "` 19719 if test "x$has_space" != x; then 19720 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 19721 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 19722 fi 19723 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19724 fi 19725 fi 19726 19727 # Now new_path has a complete unix path to the binary 19728 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 19729 # Keep paths in /bin as-is, but remove trailing .exe if any 19730 new_path="${new_path/%.exe/}" 19731 # Do not save /bin paths to all_fixpath_prefixes! 19732 else 19733 # Not in mixed or Windows style, start by that. 19734 new_path=`cmd //c echo $new_path` 19735 19736 input_path="$new_path" 19737 # Check if we need to convert this using DOS-style short mode. If the path 19738 # contains just simple characters, use it. Otherwise (spaces, weird characters), 19739 # take no chances and rewrite it. 19740 # Note: m4 eats our [], so we need to use [ and ] instead. 19741 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 19742 if test "x$has_forbidden_chars" != x; then 19743 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 19744 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 19745 fi 19746 19747 # Output is in $new_path 19748 19749 windows_path="$new_path" 19750 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19751 unix_path=`$CYGPATH -u "$windows_path"` 19752 new_path="$unix_path" 19753 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19754 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 19755 new_path="$unix_path" 19756 fi 19757 19758 # remove trailing .exe if any 19759 new_path="${new_path/%.exe/}" 19760 19761 # Save the first 10 bytes of this path to the storage, so fixpath can work. 19762 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 19763 fi 19764 19765 else 19766 # We're on a unix platform. Hooray! :) 19767 # First separate the path from the arguments. This will split at the first 19768 # space. 19769 complete="$FOUND_MAKE" 19770 path="${complete%% *}" 19771 tmp="$complete EOL" 19772 arguments="${tmp#* }" 19773 19774 # Cannot rely on the command "which" here since it doesn't always work. 19775 is_absolute_path=`$ECHO "$path" | $GREP ^/` 19776 if test -z "$is_absolute_path"; then 19777 # Path to executable is not absolute. Find it. 19778 IFS_save="$IFS" 19779 IFS=: 19780 for p in $PATH; do 19781 if test -f "$p/$path" && test -x "$p/$path"; then 19782 new_path="$p/$path" 19783 break 19784 fi 19785 done 19786 IFS="$IFS_save" 19787 else 19788 # This is an absolute path, we can use it without further modifications. 19789 new_path="$path" 19790 fi 19791 19792 if test "x$new_path" = x; then 19793 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 19794 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 19795 has_space=`$ECHO "$complete" | $GREP " "` 19796 if test "x$has_space" != x; then 19797 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 19798 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 19799 fi 19800 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 19801 fi 19802 fi 19803 19804 # Now join together the path and the arguments once again 19805 if test "x$arguments" != xEOL; then 19806 new_complete="$new_path ${arguments% *}" 19807 else 19808 new_complete="$new_path" 19809 fi 19810 19811 if test "x$complete" != "x$new_complete"; then 19812 FOUND_MAKE="$new_complete" 19813 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 19814 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 19815 fi 19816 fi 19817 19818 fi 19819 fi 19820 fi 19821 fi 19822 19823 fi 19824 PATH=$OLD_PATH 19825 fi 19826 fi 19827 19828 if test "x$FOUND_MAKE" = x; then 19829 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 19830 fi 19831 19832 else 19833 # If it succeeded, then it was overridden by the user. We will use it 19834 # for the tool. 19835 19836 # First remove it from the list of overridden variables, so we can test 19837 # for unknown variables in the end. 19838 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 19839 19840 # Check if we try to supply an empty value 19841 if test "x$MAKE" = x; then 19842 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool MAKE= (no value)" >&5 19843 $as_echo "$as_me: Setting user supplied tool MAKE= (no value)" >&6;} 19844 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MAKE" >&5 19845 $as_echo_n "checking for MAKE... " >&6; } 19846 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 19847 $as_echo "disabled" >&6; } 19848 else 19849 # Check if the provided tool contains a complete path. 19850 tool_specified="$MAKE" 19851 tool_basename="${tool_specified##*/}" 19852 if test "x$tool_basename" = "x$tool_specified"; then 19853 # A command without a complete path is provided, search $PATH. 19854 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool MAKE=$tool_basename" >&5 19855 $as_echo "$as_me: Will search for user supplied tool MAKE=$tool_basename" >&6;} 19856 # Extract the first word of "$tool_basename", so it can be a program name with args. 19857 set dummy $tool_basename; ac_word=$2 19858 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 19859 $as_echo_n "checking for $ac_word... " >&6; } 19860 if ${ac_cv_path_MAKE+:} false; then : 19861 $as_echo_n "(cached) " >&6 19862 else 19863 case $MAKE in 19864 [\\/]* | ?:[\\/]*) 19865 ac_cv_path_MAKE="$MAKE" # Let the user override the test with a path. 19866 ;; 19867 *) 19868 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 19869 for as_dir in $PATH 19870 do 19871 IFS=$as_save_IFS 19872 test -z "$as_dir" && as_dir=. 19873 for ac_exec_ext in '' $ac_executable_extensions; do 19874 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 19875 ac_cv_path_MAKE="$as_dir/$ac_word$ac_exec_ext" 19876 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 19877 break 2 19878 fi 19879 done 19880 done 19881 IFS=$as_save_IFS 19882 19883 ;; 19884 esac 19885 fi 19886 MAKE=$ac_cv_path_MAKE 19887 if test -n "$MAKE"; then 19888 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MAKE" >&5 19889 $as_echo "$MAKE" >&6; } 19890 else 19891 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 19892 $as_echo "no" >&6; } 19893 fi 19894 19895 19896 if test "x$MAKE" = x; then 19897 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 19898 fi 19899 else 19900 # Otherwise we believe it is a complete path. Use it as it is. 19901 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool MAKE=$tool_specified" >&5 19902 $as_echo "$as_me: Will use user supplied tool MAKE=$tool_specified" >&6;} 19903 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for MAKE" >&5 19904 $as_echo_n "checking for MAKE... " >&6; } 19905 if test ! -x "$tool_specified"; then 19906 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 19907 $as_echo "not found" >&6; } 19908 as_fn_error $? "User supplied tool MAKE=$tool_specified does not exist or is not executable" "$LINENO" 5 19909 fi 19910 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 19911 $as_echo "$tool_specified" >&6; } 19912 fi 19913 fi 19914 fi 19915 19916 # If MAKE was set by user, verify the version 19917 19918 MAKE_CANDIDATE=""$MAKE"" 19919 DESCRIPTION="user supplied MAKE=$MAKE" 19920 19921 # On Cygwin, we require a newer version of make than on other platforms 19922 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19923 MAKE_VERSION_EXPR="-e 4\." 19924 MAKE_REQUIRED_VERSION="4.0" 19925 else 19926 MAKE_VERSION_EXPR="-e 3\.8[12] -e 4\." 19927 MAKE_REQUIRED_VERSION="3.81" 19928 fi 19929 19930 if test "x$MAKE_CANDIDATE" != x; then 19931 { $as_echo "$as_me:${as_lineno-$LINENO}: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&5 19932 $as_echo "$as_me: Testing potential make at $MAKE_CANDIDATE, found using $DESCRIPTION" >&6;} 19933 MAKE_VERSION_STRING=`$MAKE_CANDIDATE --version | $HEAD -n 1` 19934 IS_GNU_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP 'GNU Make'` 19935 if test "x$IS_GNU_MAKE" = x; then 19936 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&5 19937 $as_echo "$as_me: Found potential make at $MAKE_CANDIDATE, however, this is not GNU Make. Ignoring." >&6;} 19938 else 19939 IS_MODERN_MAKE=`$ECHO $MAKE_VERSION_STRING | $GREP $MAKE_VERSION_EXPR` 19940 if test "x$IS_MODERN_MAKE" = x; then 19941 { $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 19942 $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;} 19943 else 19944 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 19945 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19946 MAKE_EXPECTED_ENV='cygwin' 19947 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 19948 MAKE_EXPECTED_ENV='msys' 19949 else 19950 as_fn_error $? "Unknown Windows environment" "$LINENO" 5 19951 fi 19952 MAKE_BUILT_FOR=`$MAKE_CANDIDATE --version | $GREP -i 'built for'` 19953 IS_MAKE_CORRECT_ENV=`$ECHO $MAKE_BUILT_FOR | $GREP $MAKE_EXPECTED_ENV` 19954 else 19955 # Not relevant for non-Windows 19956 IS_MAKE_CORRECT_ENV=true 19957 fi 19958 if test "x$IS_MAKE_CORRECT_ENV" = x; then 19959 { $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 19960 $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;} 19961 else 19962 FOUND_MAKE=$MAKE_CANDIDATE 19963 19964 # Only process if variable expands to non-empty 19965 19966 if test "x$FOUND_MAKE" != x; then 19967 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 19968 19969 # First separate the path from the arguments. This will split at the first 19970 # space. 19971 complete="$FOUND_MAKE" 19972 path="${complete%% *}" 19973 tmp="$complete EOL" 19974 arguments="${tmp#* }" 19975 19976 # Input might be given as Windows format, start by converting to 19977 # unix format. 19978 new_path=`$CYGPATH -u "$path"` 19979 19980 # Now try to locate executable using which 19981 new_path=`$WHICH "$new_path" 2> /dev/null` 19982 # bat and cmd files are not always considered executable in cygwin causing which 19983 # to not find them 19984 if test "x$new_path" = x \ 19985 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 19986 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 19987 new_path=`$CYGPATH -u "$path"` 19988 fi 19989 if test "x$new_path" = x; then 19990 # Oops. Which didn't find the executable. 19991 # The splitting of arguments from the executable at a space might have been incorrect, 19992 # since paths with space are more likely in Windows. Give it another try with the whole 19993 # argument. 19994 path="$complete" 19995 arguments="EOL" 19996 new_path=`$CYGPATH -u "$path"` 19997 new_path=`$WHICH "$new_path" 2> /dev/null` 19998 # bat and cmd files are not always considered executable in cygwin causing which 19999 # to not find them 20000 if test "x$new_path" = x \ 20001 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20002 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20003 new_path=`$CYGPATH -u "$path"` 20004 fi 20005 if test "x$new_path" = x; then 20006 # It's still not found. Now this is an unrecoverable error. 20007 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20008 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20009 has_space=`$ECHO "$complete" | $GREP " "` 20010 if test "x$has_space" != x; then 20011 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20012 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20013 fi 20014 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20015 fi 20016 fi 20017 20018 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 20019 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 20020 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 20021 # "foo.exe" is OK but "foo" is an error. 20022 # 20023 # This test is therefore slightly more accurate than "test -f" to check for file presence. 20024 # It is also a way to make sure we got the proper file name for the real test later on. 20025 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 20026 if test "x$test_shortpath" = x; then 20027 # Short path failed, file does not exist as specified. 20028 # Try adding .exe or .cmd 20029 if test -f "${new_path}.exe"; then 20030 input_to_shortpath="${new_path}.exe" 20031 elif test -f "${new_path}.cmd"; then 20032 input_to_shortpath="${new_path}.cmd" 20033 else 20034 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&5 20035 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$new_path\", is invalid." >&6;} 20036 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 20037 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 20038 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20039 fi 20040 else 20041 input_to_shortpath="$new_path" 20042 fi 20043 20044 # Call helper function which possibly converts this using DOS-style short mode. 20045 # If so, the updated path is stored in $new_path. 20046 new_path="$input_to_shortpath" 20047 20048 input_path="$input_to_shortpath" 20049 # Check if we need to convert this using DOS-style short mode. If the path 20050 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20051 # take no chances and rewrite it. 20052 # Note: m4 eats our [], so we need to use [ and ] instead. 20053 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 20054 if test "x$has_forbidden_chars" != x; then 20055 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20056 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 20057 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 20058 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 20059 # Going to short mode and back again did indeed matter. Since short mode is 20060 # case insensitive, let's make it lowercase to improve readability. 20061 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20062 # Now convert it back to Unix-style (cygpath) 20063 input_path=`$CYGPATH -u "$shortmode_path"` 20064 new_path="$input_path" 20065 fi 20066 fi 20067 20068 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 20069 if test "x$test_cygdrive_prefix" = x; then 20070 # As a simple fix, exclude /usr/bin since it's not a real path. 20071 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 20072 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 20073 # a path prefixed by /cygdrive for fixpath to work. 20074 new_path="$CYGWIN_ROOT_PATH$input_path" 20075 fi 20076 fi 20077 20078 # remove trailing .exe if any 20079 new_path="${new_path/%.exe/}" 20080 20081 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20082 20083 # First separate the path from the arguments. This will split at the first 20084 # space. 20085 complete="$FOUND_MAKE" 20086 path="${complete%% *}" 20087 tmp="$complete EOL" 20088 arguments="${tmp#* }" 20089 20090 # Input might be given as Windows format, start by converting to 20091 # unix format. 20092 new_path="$path" 20093 20094 windows_path="$new_path" 20095 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20096 unix_path=`$CYGPATH -u "$windows_path"` 20097 new_path="$unix_path" 20098 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20099 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20100 new_path="$unix_path" 20101 fi 20102 20103 20104 # Now try to locate executable using which 20105 new_path=`$WHICH "$new_path" 2> /dev/null` 20106 20107 if test "x$new_path" = x; then 20108 # Oops. Which didn't find the executable. 20109 # The splitting of arguments from the executable at a space might have been incorrect, 20110 # since paths with space are more likely in Windows. Give it another try with the whole 20111 # argument. 20112 path="$complete" 20113 arguments="EOL" 20114 new_path="$path" 20115 20116 windows_path="$new_path" 20117 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20118 unix_path=`$CYGPATH -u "$windows_path"` 20119 new_path="$unix_path" 20120 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20121 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20122 new_path="$unix_path" 20123 fi 20124 20125 20126 new_path=`$WHICH "$new_path" 2> /dev/null` 20127 # bat and cmd files are not always considered executable in MSYS causing which 20128 # to not find them 20129 if test "x$new_path" = x \ 20130 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 20131 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 20132 new_path="$path" 20133 20134 windows_path="$new_path" 20135 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20136 unix_path=`$CYGPATH -u "$windows_path"` 20137 new_path="$unix_path" 20138 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20139 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20140 new_path="$unix_path" 20141 fi 20142 20143 fi 20144 20145 if test "x$new_path" = x; then 20146 # It's still not found. Now this is an unrecoverable error. 20147 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20148 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20149 has_space=`$ECHO "$complete" | $GREP " "` 20150 if test "x$has_space" != x; then 20151 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 20152 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 20153 fi 20154 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20155 fi 20156 fi 20157 20158 # Now new_path has a complete unix path to the binary 20159 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 20160 # Keep paths in /bin as-is, but remove trailing .exe if any 20161 new_path="${new_path/%.exe/}" 20162 # Do not save /bin paths to all_fixpath_prefixes! 20163 else 20164 # Not in mixed or Windows style, start by that. 20165 new_path=`cmd //c echo $new_path` 20166 20167 input_path="$new_path" 20168 # Check if we need to convert this using DOS-style short mode. If the path 20169 # contains just simple characters, use it. Otherwise (spaces, weird characters), 20170 # take no chances and rewrite it. 20171 # Note: m4 eats our [], so we need to use [ and ] instead. 20172 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 20173 if test "x$has_forbidden_chars" != x; then 20174 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 20175 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 20176 fi 20177 20178 # Output is in $new_path 20179 20180 windows_path="$new_path" 20181 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 20182 unix_path=`$CYGPATH -u "$windows_path"` 20183 new_path="$unix_path" 20184 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 20185 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 20186 new_path="$unix_path" 20187 fi 20188 20189 # remove trailing .exe if any 20190 new_path="${new_path/%.exe/}" 20191 20192 # Save the first 10 bytes of this path to the storage, so fixpath can work. 20193 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 20194 fi 20195 20196 else 20197 # We're on a unix platform. Hooray! :) 20198 # First separate the path from the arguments. This will split at the first 20199 # space. 20200 complete="$FOUND_MAKE" 20201 path="${complete%% *}" 20202 tmp="$complete EOL" 20203 arguments="${tmp#* }" 20204 20205 # Cannot rely on the command "which" here since it doesn't always work. 20206 is_absolute_path=`$ECHO "$path" | $GREP ^/` 20207 if test -z "$is_absolute_path"; then 20208 # Path to executable is not absolute. Find it. 20209 IFS_save="$IFS" 20210 IFS=: 20211 for p in $PATH; do 20212 if test -f "$p/$path" && test -x "$p/$path"; then 20213 new_path="$p/$path" 20214 break 20215 fi 20216 done 20217 IFS="$IFS_save" 20218 else 20219 # This is an absolute path, we can use it without further modifications. 20220 new_path="$path" 20221 fi 20222 20223 if test "x$new_path" = x; then 20224 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&5 20225 $as_echo "$as_me: The path of FOUND_MAKE, which resolves as \"$complete\", is not found." >&6;} 20226 has_space=`$ECHO "$complete" | $GREP " "` 20227 if test "x$has_space" != x; then 20228 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 20229 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 20230 fi 20231 as_fn_error $? "Cannot locate the the path of FOUND_MAKE" "$LINENO" 5 20232 fi 20233 fi 20234 20235 # Now join together the path and the arguments once again 20236 if test "x$arguments" != xEOL; then 20237 new_complete="$new_path ${arguments% *}" 20238 else 20239 new_complete="$new_path" 20240 fi 20241 20242 if test "x$complete" != "x$new_complete"; then 20243 FOUND_MAKE="$new_complete" 20244 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5 20245 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;} 20246 fi 20247 fi 20248 20249 fi 20250 fi 20251 fi 20252 fi 20253 20254 if test "x$FOUND_MAKE" = x; then 20255 as_fn_error $? "The specified make (by MAKE=$MAKE) is not GNU make $MAKE_REQUIRED_VERSION or newer." "$LINENO" 5 20256 fi 20257 20258 fi 20259 20260 20261 MAKE=$FOUND_MAKE 20262 20263 { $as_echo "$as_me:${as_lineno-$LINENO}: Using GNU make at $FOUND_MAKE (version: $MAKE_VERSION_STRING)" >&5 20264 $as_echo "$as_me: Using GNU make at $FOUND_MAKE (version: $MAKE_VERSION_STRING)" >&6;} 20265 20266 20267 # Check if make supports the output sync option and if so, setup using it. 20268 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if make --output-sync is supported" >&5 20269 $as_echo_n "checking if make --output-sync is supported... " >&6; } 20270 if $MAKE --version -O > /dev/null 2>&1; then 20271 OUTPUT_SYNC_SUPPORTED=true 20272 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 20273 $as_echo "yes" >&6; } 20274 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for output-sync value" >&5 20275 $as_echo_n "checking for output-sync value... " >&6; } 20276 20277 # Check whether --with-output-sync was given. 20278 if test "${with_output_sync+set}" = set; then : 20279 withval=$with_output_sync; OUTPUT_SYNC=$with_output_sync 20280 fi 20281 20282 if test "x$OUTPUT_SYNC" = "x"; then 20283 OUTPUT_SYNC=none 20284 fi 20285 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OUTPUT_SYNC" >&5 20286 $as_echo "$OUTPUT_SYNC" >&6; } 20287 if ! $MAKE --version -O$OUTPUT_SYNC > /dev/null 2>&1; then 20288 as_fn_error $? "Make did not the support the value $OUTPUT_SYNC as output sync type." "$LINENO" 5 20289 fi 20290 else 20291 OUTPUT_SYNC_SUPPORTED=false 20292 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 20293 $as_echo "no" >&6; } 20294 fi 20295 20296 20297 20298 20299 20300 20301 # Test if find supports -delete 20302 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if find supports -delete" >&5 20303 $as_echo_n "checking if find supports -delete... " >&6; } 20304 FIND_DELETE="-delete" 20305 20306 DELETEDIR=`$MKTEMP -d tmp.XXXXXXXXXX` || (echo Could not create temporary directory!; exit $?) 20307 20308 echo Hejsan > $DELETEDIR/TestIfFindSupportsDelete 20309 20310 TEST_DELETE=`$FIND "$DELETEDIR" -name TestIfFindSupportsDelete $FIND_DELETE 2>&1` 20311 if test -f $DELETEDIR/TestIfFindSupportsDelete; then 20312 # No, it does not. 20313 rm $DELETEDIR/TestIfFindSupportsDelete 20314 if test "x$OPENJDK_TARGET_OS" = "xaix"; then 20315 # AIX 'find' is buggy if called with '-exec {} \+' and an empty file list 20316 FIND_DELETE="-print | xargs rm" 20317 else 20318 FIND_DELETE="-exec rm \{\} \+" 20319 fi 20320 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 20321 $as_echo "no" >&6; } 20322 else 20323 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 20324 $as_echo "yes" >&6; } 20325 fi 20326 rmdir $DELETEDIR 20327 20328 20329 20330 # These tools might not be installed by default, 20331 # need hint on how to install them. 20332 20333 20334 20335 # Publish this variable in the help. 20336 20337 20338 if [ -z "${UNZIP+x}" ]; then 20339 # The variable is not set by user, try to locate tool using the code snippet 20340 for ac_prog in unzip 20341 do 20342 # Extract the first word of "$ac_prog", so it can be a program name with args. 20343 set dummy $ac_prog; ac_word=$2 20344 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 20345 $as_echo_n "checking for $ac_word... " >&6; } 20346 if ${ac_cv_path_UNZIP+:} false; then : 20347 $as_echo_n "(cached) " >&6 20348 else 20349 case $UNZIP in 20350 [\\/]* | ?:[\\/]*) 20351 ac_cv_path_UNZIP="$UNZIP" # Let the user override the test with a path. 20352 ;; 20353 *) 20354 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 20355 for as_dir in $PATH 20356 do 20357 IFS=$as_save_IFS 20358 test -z "$as_dir" && as_dir=. 20359 for ac_exec_ext in '' $ac_executable_extensions; do 20360 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 20361 ac_cv_path_UNZIP="$as_dir/$ac_word$ac_exec_ext" 20362 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 20363 break 2 20364 fi 20365 done 20366 done 20367 IFS=$as_save_IFS 20368 20369 ;; 20370 esac 20371 fi 20372 UNZIP=$ac_cv_path_UNZIP 20373 if test -n "$UNZIP"; then 20374 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNZIP" >&5 20375 $as_echo "$UNZIP" >&6; } 20376 else 20377 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 20378 $as_echo "no" >&6; } 20379 fi 20380 20381 20382 test -n "$UNZIP" && break 20383 done 20384 20385 else 20386 # The variable is set, but is it from the command line or the environment? 20387 20388 # Try to remove the string !UNZIP! from our list. 20389 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!UNZIP!/} 20390 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 20391 # If it failed, the variable was not from the command line. Ignore it, 20392 # but warn the user (except for BASH, which is always set by the calling BASH). 20393 if test "xUNZIP" != xBASH; then 20394 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of UNZIP from the environment. Use command line variables instead." >&5 20395 $as_echo "$as_me: WARNING: Ignoring value of UNZIP from the environment. Use command line variables instead." >&2;} 20396 fi 20397 # Try to locate tool using the code snippet 20398 for ac_prog in unzip 20399 do 20400 # Extract the first word of "$ac_prog", so it can be a program name with args. 20401 set dummy $ac_prog; ac_word=$2 20402 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 20403 $as_echo_n "checking for $ac_word... " >&6; } 20404 if ${ac_cv_path_UNZIP+:} false; then : 20405 $as_echo_n "(cached) " >&6 20406 else 20407 case $UNZIP in 20408 [\\/]* | ?:[\\/]*) 20409 ac_cv_path_UNZIP="$UNZIP" # Let the user override the test with a path. 20410 ;; 20411 *) 20412 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 20413 for as_dir in $PATH 20414 do 20415 IFS=$as_save_IFS 20416 test -z "$as_dir" && as_dir=. 20417 for ac_exec_ext in '' $ac_executable_extensions; do 20418 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 20419 ac_cv_path_UNZIP="$as_dir/$ac_word$ac_exec_ext" 20420 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 20421 break 2 20422 fi 20423 done 20424 done 20425 IFS=$as_save_IFS 20426 20427 ;; 20428 esac 20429 fi 20430 UNZIP=$ac_cv_path_UNZIP 20431 if test -n "$UNZIP"; then 20432 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNZIP" >&5 20433 $as_echo "$UNZIP" >&6; } 20434 else 20435 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 20436 $as_echo "no" >&6; } 20437 fi 20438 20439 20440 test -n "$UNZIP" && break 20441 done 20442 20443 else 20444 # If it succeeded, then it was overridden by the user. We will use it 20445 # for the tool. 20446 20447 # First remove it from the list of overridden variables, so we can test 20448 # for unknown variables in the end. 20449 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 20450 20451 # Check if we try to supply an empty value 20452 if test "x$UNZIP" = x; then 20453 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool UNZIP= (no value)" >&5 20454 $as_echo "$as_me: Setting user supplied tool UNZIP= (no value)" >&6;} 20455 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNZIP" >&5 20456 $as_echo_n "checking for UNZIP... " >&6; } 20457 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 20458 $as_echo "disabled" >&6; } 20459 else 20460 # Check if the provided tool contains a complete path. 20461 tool_specified="$UNZIP" 20462 tool_basename="${tool_specified##*/}" 20463 if test "x$tool_basename" = "x$tool_specified"; then 20464 # A command without a complete path is provided, search $PATH. 20465 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool UNZIP=$tool_basename" >&5 20466 $as_echo "$as_me: Will search for user supplied tool UNZIP=$tool_basename" >&6;} 20467 # Extract the first word of "$tool_basename", so it can be a program name with args. 20468 set dummy $tool_basename; ac_word=$2 20469 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 20470 $as_echo_n "checking for $ac_word... " >&6; } 20471 if ${ac_cv_path_UNZIP+:} false; then : 20472 $as_echo_n "(cached) " >&6 20473 else 20474 case $UNZIP in 20475 [\\/]* | ?:[\\/]*) 20476 ac_cv_path_UNZIP="$UNZIP" # Let the user override the test with a path. 20477 ;; 20478 *) 20479 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 20480 for as_dir in $PATH 20481 do 20482 IFS=$as_save_IFS 20483 test -z "$as_dir" && as_dir=. 20484 for ac_exec_ext in '' $ac_executable_extensions; do 20485 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 20486 ac_cv_path_UNZIP="$as_dir/$ac_word$ac_exec_ext" 20487 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 20488 break 2 20489 fi 20490 done 20491 done 20492 IFS=$as_save_IFS 20493 20494 ;; 20495 esac 20496 fi 20497 UNZIP=$ac_cv_path_UNZIP 20498 if test -n "$UNZIP"; then 20499 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $UNZIP" >&5 20500 $as_echo "$UNZIP" >&6; } 20501 else 20502 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 20503 $as_echo "no" >&6; } 20504 fi 20505 20506 20507 if test "x$UNZIP" = x; then 20508 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 20509 fi 20510 else 20511 # Otherwise we believe it is a complete path. Use it as it is. 20512 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool UNZIP=$tool_specified" >&5 20513 $as_echo "$as_me: Will use user supplied tool UNZIP=$tool_specified" >&6;} 20514 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for UNZIP" >&5 20515 $as_echo_n "checking for UNZIP... " >&6; } 20516 if test ! -x "$tool_specified"; then 20517 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 20518 $as_echo "not found" >&6; } 20519 as_fn_error $? "User supplied tool UNZIP=$tool_specified does not exist or is not executable" "$LINENO" 5 20520 fi 20521 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 20522 $as_echo "$tool_specified" >&6; } 20523 fi 20524 fi 20525 fi 20526 20527 fi 20528 20529 20530 20531 if test "x$UNZIP" = x; then 20532 as_fn_error $? "Could not find required tool for UNZIP" "$LINENO" 5 20533 fi 20534 20535 20536 20537 20538 20539 # Publish this variable in the help. 20540 20541 20542 if [ -z "${ZIP+x}" ]; then 20543 # The variable is not set by user, try to locate tool using the code snippet 20544 for ac_prog in zip 20545 do 20546 # Extract the first word of "$ac_prog", so it can be a program name with args. 20547 set dummy $ac_prog; ac_word=$2 20548 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 20549 $as_echo_n "checking for $ac_word... " >&6; } 20550 if ${ac_cv_path_ZIP+:} false; then : 20551 $as_echo_n "(cached) " >&6 20552 else 20553 case $ZIP in 20554 [\\/]* | ?:[\\/]*) 20555 ac_cv_path_ZIP="$ZIP" # Let the user override the test with a path. 20556 ;; 20557 *) 20558 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 20559 for as_dir in $PATH 20560 do 20561 IFS=$as_save_IFS 20562 test -z "$as_dir" && as_dir=. 20563 for ac_exec_ext in '' $ac_executable_extensions; do 20564 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 20565 ac_cv_path_ZIP="$as_dir/$ac_word$ac_exec_ext" 20566 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 20567 break 2 20568 fi 20569 done 20570 done 20571 IFS=$as_save_IFS 20572 20573 ;; 20574 esac 20575 fi 20576 ZIP=$ac_cv_path_ZIP 20577 if test -n "$ZIP"; then 20578 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIP" >&5 20579 $as_echo "$ZIP" >&6; } 20580 else 20581 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 20582 $as_echo "no" >&6; } 20583 fi 20584 20585 20586 test -n "$ZIP" && break 20587 done 20588 20589 else 20590 # The variable is set, but is it from the command line or the environment? 20591 20592 # Try to remove the string !ZIP! from our list. 20593 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ZIP!/} 20594 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 20595 # If it failed, the variable was not from the command line. Ignore it, 20596 # but warn the user (except for BASH, which is always set by the calling BASH). 20597 if test "xZIP" != xBASH; then 20598 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ZIP from the environment. Use command line variables instead." >&5 20599 $as_echo "$as_me: WARNING: Ignoring value of ZIP from the environment. Use command line variables instead." >&2;} 20600 fi 20601 # Try to locate tool using the code snippet 20602 for ac_prog in zip 20603 do 20604 # Extract the first word of "$ac_prog", so it can be a program name with args. 20605 set dummy $ac_prog; ac_word=$2 20606 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 20607 $as_echo_n "checking for $ac_word... " >&6; } 20608 if ${ac_cv_path_ZIP+:} false; then : 20609 $as_echo_n "(cached) " >&6 20610 else 20611 case $ZIP in 20612 [\\/]* | ?:[\\/]*) 20613 ac_cv_path_ZIP="$ZIP" # Let the user override the test with a path. 20614 ;; 20615 *) 20616 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 20617 for as_dir in $PATH 20618 do 20619 IFS=$as_save_IFS 20620 test -z "$as_dir" && as_dir=. 20621 for ac_exec_ext in '' $ac_executable_extensions; do 20622 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 20623 ac_cv_path_ZIP="$as_dir/$ac_word$ac_exec_ext" 20624 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 20625 break 2 20626 fi 20627 done 20628 done 20629 IFS=$as_save_IFS 20630 20631 ;; 20632 esac 20633 fi 20634 ZIP=$ac_cv_path_ZIP 20635 if test -n "$ZIP"; then 20636 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIP" >&5 20637 $as_echo "$ZIP" >&6; } 20638 else 20639 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 20640 $as_echo "no" >&6; } 20641 fi 20642 20643 20644 test -n "$ZIP" && break 20645 done 20646 20647 else 20648 # If it succeeded, then it was overridden by the user. We will use it 20649 # for the tool. 20650 20651 # First remove it from the list of overridden variables, so we can test 20652 # for unknown variables in the end. 20653 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 20654 20655 # Check if we try to supply an empty value 20656 if test "x$ZIP" = x; then 20657 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ZIP= (no value)" >&5 20658 $as_echo "$as_me: Setting user supplied tool ZIP= (no value)" >&6;} 20659 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ZIP" >&5 20660 $as_echo_n "checking for ZIP... " >&6; } 20661 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 20662 $as_echo "disabled" >&6; } 20663 else 20664 # Check if the provided tool contains a complete path. 20665 tool_specified="$ZIP" 20666 tool_basename="${tool_specified##*/}" 20667 if test "x$tool_basename" = "x$tool_specified"; then 20668 # A command without a complete path is provided, search $PATH. 20669 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ZIP=$tool_basename" >&5 20670 $as_echo "$as_me: Will search for user supplied tool ZIP=$tool_basename" >&6;} 20671 # Extract the first word of "$tool_basename", so it can be a program name with args. 20672 set dummy $tool_basename; ac_word=$2 20673 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 20674 $as_echo_n "checking for $ac_word... " >&6; } 20675 if ${ac_cv_path_ZIP+:} false; then : 20676 $as_echo_n "(cached) " >&6 20677 else 20678 case $ZIP in 20679 [\\/]* | ?:[\\/]*) 20680 ac_cv_path_ZIP="$ZIP" # Let the user override the test with a path. 20681 ;; 20682 *) 20683 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 20684 for as_dir in $PATH 20685 do 20686 IFS=$as_save_IFS 20687 test -z "$as_dir" && as_dir=. 20688 for ac_exec_ext in '' $ac_executable_extensions; do 20689 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 20690 ac_cv_path_ZIP="$as_dir/$ac_word$ac_exec_ext" 20691 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 20692 break 2 20693 fi 20694 done 20695 done 20696 IFS=$as_save_IFS 20697 20698 ;; 20699 esac 20700 fi 20701 ZIP=$ac_cv_path_ZIP 20702 if test -n "$ZIP"; then 20703 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ZIP" >&5 20704 $as_echo "$ZIP" >&6; } 20705 else 20706 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 20707 $as_echo "no" >&6; } 20708 fi 20709 20710 20711 if test "x$ZIP" = x; then 20712 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 20713 fi 20714 else 20715 # Otherwise we believe it is a complete path. Use it as it is. 20716 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ZIP=$tool_specified" >&5 20717 $as_echo "$as_me: Will use user supplied tool ZIP=$tool_specified" >&6;} 20718 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ZIP" >&5 20719 $as_echo_n "checking for ZIP... " >&6; } 20720 if test ! -x "$tool_specified"; then 20721 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 20722 $as_echo "not found" >&6; } 20723 as_fn_error $? "User supplied tool ZIP=$tool_specified does not exist or is not executable" "$LINENO" 5 20724 fi 20725 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 20726 $as_echo "$tool_specified" >&6; } 20727 fi 20728 fi 20729 fi 20730 20731 fi 20732 20733 20734 20735 if test "x$ZIP" = x; then 20736 as_fn_error $? "Could not find required tool for ZIP" "$LINENO" 5 20737 fi 20738 20739 20740 20741 # Non-required basic tools 20742 20743 20744 20745 # Publish this variable in the help. 20746 20747 20748 if [ -z "${LDD+x}" ]; then 20749 # The variable is not set by user, try to locate tool using the code snippet 20750 for ac_prog in ldd 20751 do 20752 # Extract the first word of "$ac_prog", so it can be a program name with args. 20753 set dummy $ac_prog; ac_word=$2 20754 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 20755 $as_echo_n "checking for $ac_word... " >&6; } 20756 if ${ac_cv_path_LDD+:} false; then : 20757 $as_echo_n "(cached) " >&6 20758 else 20759 case $LDD in 20760 [\\/]* | ?:[\\/]*) 20761 ac_cv_path_LDD="$LDD" # Let the user override the test with a path. 20762 ;; 20763 *) 20764 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 20765 for as_dir in $PATH 20766 do 20767 IFS=$as_save_IFS 20768 test -z "$as_dir" && as_dir=. 20769 for ac_exec_ext in '' $ac_executable_extensions; do 20770 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 20771 ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext" 20772 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 20773 break 2 20774 fi 20775 done 20776 done 20777 IFS=$as_save_IFS 20778 20779 ;; 20780 esac 20781 fi 20782 LDD=$ac_cv_path_LDD 20783 if test -n "$LDD"; then 20784 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDD" >&5 20785 $as_echo "$LDD" >&6; } 20786 else 20787 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 20788 $as_echo "no" >&6; } 20789 fi 20790 20791 20792 test -n "$LDD" && break 20793 done 20794 20795 else 20796 # The variable is set, but is it from the command line or the environment? 20797 20798 # Try to remove the string !LDD! from our list. 20799 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LDD!/} 20800 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 20801 # If it failed, the variable was not from the command line. Ignore it, 20802 # but warn the user (except for BASH, which is always set by the calling BASH). 20803 if test "xLDD" != xBASH; then 20804 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LDD from the environment. Use command line variables instead." >&5 20805 $as_echo "$as_me: WARNING: Ignoring value of LDD from the environment. Use command line variables instead." >&2;} 20806 fi 20807 # Try to locate tool using the code snippet 20808 for ac_prog in ldd 20809 do 20810 # Extract the first word of "$ac_prog", so it can be a program name with args. 20811 set dummy $ac_prog; ac_word=$2 20812 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 20813 $as_echo_n "checking for $ac_word... " >&6; } 20814 if ${ac_cv_path_LDD+:} false; then : 20815 $as_echo_n "(cached) " >&6 20816 else 20817 case $LDD in 20818 [\\/]* | ?:[\\/]*) 20819 ac_cv_path_LDD="$LDD" # Let the user override the test with a path. 20820 ;; 20821 *) 20822 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 20823 for as_dir in $PATH 20824 do 20825 IFS=$as_save_IFS 20826 test -z "$as_dir" && as_dir=. 20827 for ac_exec_ext in '' $ac_executable_extensions; do 20828 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 20829 ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext" 20830 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 20831 break 2 20832 fi 20833 done 20834 done 20835 IFS=$as_save_IFS 20836 20837 ;; 20838 esac 20839 fi 20840 LDD=$ac_cv_path_LDD 20841 if test -n "$LDD"; then 20842 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDD" >&5 20843 $as_echo "$LDD" >&6; } 20844 else 20845 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 20846 $as_echo "no" >&6; } 20847 fi 20848 20849 20850 test -n "$LDD" && break 20851 done 20852 20853 else 20854 # If it succeeded, then it was overridden by the user. We will use it 20855 # for the tool. 20856 20857 # First remove it from the list of overridden variables, so we can test 20858 # for unknown variables in the end. 20859 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 20860 20861 # Check if we try to supply an empty value 20862 if test "x$LDD" = x; then 20863 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool LDD= (no value)" >&5 20864 $as_echo "$as_me: Setting user supplied tool LDD= (no value)" >&6;} 20865 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LDD" >&5 20866 $as_echo_n "checking for LDD... " >&6; } 20867 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 20868 $as_echo "disabled" >&6; } 20869 else 20870 # Check if the provided tool contains a complete path. 20871 tool_specified="$LDD" 20872 tool_basename="${tool_specified##*/}" 20873 if test "x$tool_basename" = "x$tool_specified"; then 20874 # A command without a complete path is provided, search $PATH. 20875 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LDD=$tool_basename" >&5 20876 $as_echo "$as_me: Will search for user supplied tool LDD=$tool_basename" >&6;} 20877 # Extract the first word of "$tool_basename", so it can be a program name with args. 20878 set dummy $tool_basename; ac_word=$2 20879 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 20880 $as_echo_n "checking for $ac_word... " >&6; } 20881 if ${ac_cv_path_LDD+:} false; then : 20882 $as_echo_n "(cached) " >&6 20883 else 20884 case $LDD in 20885 [\\/]* | ?:[\\/]*) 20886 ac_cv_path_LDD="$LDD" # Let the user override the test with a path. 20887 ;; 20888 *) 20889 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 20890 for as_dir in $PATH 20891 do 20892 IFS=$as_save_IFS 20893 test -z "$as_dir" && as_dir=. 20894 for ac_exec_ext in '' $ac_executable_extensions; do 20895 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 20896 ac_cv_path_LDD="$as_dir/$ac_word$ac_exec_ext" 20897 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 20898 break 2 20899 fi 20900 done 20901 done 20902 IFS=$as_save_IFS 20903 20904 ;; 20905 esac 20906 fi 20907 LDD=$ac_cv_path_LDD 20908 if test -n "$LDD"; then 20909 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LDD" >&5 20910 $as_echo "$LDD" >&6; } 20911 else 20912 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 20913 $as_echo "no" >&6; } 20914 fi 20915 20916 20917 if test "x$LDD" = x; then 20918 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 20919 fi 20920 else 20921 # Otherwise we believe it is a complete path. Use it as it is. 20922 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LDD=$tool_specified" >&5 20923 $as_echo "$as_me: Will use user supplied tool LDD=$tool_specified" >&6;} 20924 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LDD" >&5 20925 $as_echo_n "checking for LDD... " >&6; } 20926 if test ! -x "$tool_specified"; then 20927 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 20928 $as_echo "not found" >&6; } 20929 as_fn_error $? "User supplied tool LDD=$tool_specified does not exist or is not executable" "$LINENO" 5 20930 fi 20931 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 20932 $as_echo "$tool_specified" >&6; } 20933 fi 20934 fi 20935 fi 20936 20937 fi 20938 20939 20940 if test "x$LDD" = "x"; then 20941 # List shared lib dependencies is used for 20942 # debug output and checking for forbidden dependencies. 20943 # We can build without it. 20944 LDD="true" 20945 fi 20946 20947 20948 # Publish this variable in the help. 20949 20950 20951 if [ -z "${OTOOL+x}" ]; then 20952 # The variable is not set by user, try to locate tool using the code snippet 20953 for ac_prog in otool 20954 do 20955 # Extract the first word of "$ac_prog", so it can be a program name with args. 20956 set dummy $ac_prog; ac_word=$2 20957 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 20958 $as_echo_n "checking for $ac_word... " >&6; } 20959 if ${ac_cv_path_OTOOL+:} false; then : 20960 $as_echo_n "(cached) " >&6 20961 else 20962 case $OTOOL in 20963 [\\/]* | ?:[\\/]*) 20964 ac_cv_path_OTOOL="$OTOOL" # Let the user override the test with a path. 20965 ;; 20966 *) 20967 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 20968 for as_dir in $PATH 20969 do 20970 IFS=$as_save_IFS 20971 test -z "$as_dir" && as_dir=. 20972 for ac_exec_ext in '' $ac_executable_extensions; do 20973 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 20974 ac_cv_path_OTOOL="$as_dir/$ac_word$ac_exec_ext" 20975 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 20976 break 2 20977 fi 20978 done 20979 done 20980 IFS=$as_save_IFS 20981 20982 ;; 20983 esac 20984 fi 20985 OTOOL=$ac_cv_path_OTOOL 20986 if test -n "$OTOOL"; then 20987 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 20988 $as_echo "$OTOOL" >&6; } 20989 else 20990 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 20991 $as_echo "no" >&6; } 20992 fi 20993 20994 20995 test -n "$OTOOL" && break 20996 done 20997 20998 else 20999 # The variable is set, but is it from the command line or the environment? 21000 21001 # Try to remove the string !OTOOL! from our list. 21002 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!OTOOL!/} 21003 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 21004 # If it failed, the variable was not from the command line. Ignore it, 21005 # but warn the user (except for BASH, which is always set by the calling BASH). 21006 if test "xOTOOL" != xBASH; then 21007 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of OTOOL from the environment. Use command line variables instead." >&5 21008 $as_echo "$as_me: WARNING: Ignoring value of OTOOL from the environment. Use command line variables instead." >&2;} 21009 fi 21010 # Try to locate tool using the code snippet 21011 for ac_prog in otool 21012 do 21013 # Extract the first word of "$ac_prog", so it can be a program name with args. 21014 set dummy $ac_prog; ac_word=$2 21015 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21016 $as_echo_n "checking for $ac_word... " >&6; } 21017 if ${ac_cv_path_OTOOL+:} false; then : 21018 $as_echo_n "(cached) " >&6 21019 else 21020 case $OTOOL in 21021 [\\/]* | ?:[\\/]*) 21022 ac_cv_path_OTOOL="$OTOOL" # Let the user override the test with a path. 21023 ;; 21024 *) 21025 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21026 for as_dir in $PATH 21027 do 21028 IFS=$as_save_IFS 21029 test -z "$as_dir" && as_dir=. 21030 for ac_exec_ext in '' $ac_executable_extensions; do 21031 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21032 ac_cv_path_OTOOL="$as_dir/$ac_word$ac_exec_ext" 21033 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21034 break 2 21035 fi 21036 done 21037 done 21038 IFS=$as_save_IFS 21039 21040 ;; 21041 esac 21042 fi 21043 OTOOL=$ac_cv_path_OTOOL 21044 if test -n "$OTOOL"; then 21045 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 21046 $as_echo "$OTOOL" >&6; } 21047 else 21048 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21049 $as_echo "no" >&6; } 21050 fi 21051 21052 21053 test -n "$OTOOL" && break 21054 done 21055 21056 else 21057 # If it succeeded, then it was overridden by the user. We will use it 21058 # for the tool. 21059 21060 # First remove it from the list of overridden variables, so we can test 21061 # for unknown variables in the end. 21062 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 21063 21064 # Check if we try to supply an empty value 21065 if test "x$OTOOL" = x; then 21066 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool OTOOL= (no value)" >&5 21067 $as_echo "$as_me: Setting user supplied tool OTOOL= (no value)" >&6;} 21068 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTOOL" >&5 21069 $as_echo_n "checking for OTOOL... " >&6; } 21070 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 21071 $as_echo "disabled" >&6; } 21072 else 21073 # Check if the provided tool contains a complete path. 21074 tool_specified="$OTOOL" 21075 tool_basename="${tool_specified##*/}" 21076 if test "x$tool_basename" = "x$tool_specified"; then 21077 # A command without a complete path is provided, search $PATH. 21078 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool OTOOL=$tool_basename" >&5 21079 $as_echo "$as_me: Will search for user supplied tool OTOOL=$tool_basename" >&6;} 21080 # Extract the first word of "$tool_basename", so it can be a program name with args. 21081 set dummy $tool_basename; ac_word=$2 21082 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21083 $as_echo_n "checking for $ac_word... " >&6; } 21084 if ${ac_cv_path_OTOOL+:} false; then : 21085 $as_echo_n "(cached) " >&6 21086 else 21087 case $OTOOL in 21088 [\\/]* | ?:[\\/]*) 21089 ac_cv_path_OTOOL="$OTOOL" # Let the user override the test with a path. 21090 ;; 21091 *) 21092 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21093 for as_dir in $PATH 21094 do 21095 IFS=$as_save_IFS 21096 test -z "$as_dir" && as_dir=. 21097 for ac_exec_ext in '' $ac_executable_extensions; do 21098 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21099 ac_cv_path_OTOOL="$as_dir/$ac_word$ac_exec_ext" 21100 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21101 break 2 21102 fi 21103 done 21104 done 21105 IFS=$as_save_IFS 21106 21107 ;; 21108 esac 21109 fi 21110 OTOOL=$ac_cv_path_OTOOL 21111 if test -n "$OTOOL"; then 21112 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OTOOL" >&5 21113 $as_echo "$OTOOL" >&6; } 21114 else 21115 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21116 $as_echo "no" >&6; } 21117 fi 21118 21119 21120 if test "x$OTOOL" = x; then 21121 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 21122 fi 21123 else 21124 # Otherwise we believe it is a complete path. Use it as it is. 21125 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool OTOOL=$tool_specified" >&5 21126 $as_echo "$as_me: Will use user supplied tool OTOOL=$tool_specified" >&6;} 21127 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OTOOL" >&5 21128 $as_echo_n "checking for OTOOL... " >&6; } 21129 if test ! -x "$tool_specified"; then 21130 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 21131 $as_echo "not found" >&6; } 21132 as_fn_error $? "User supplied tool OTOOL=$tool_specified does not exist or is not executable" "$LINENO" 5 21133 fi 21134 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 21135 $as_echo "$tool_specified" >&6; } 21136 fi 21137 fi 21138 fi 21139 21140 fi 21141 21142 21143 if test "x$OTOOL" = "x"; then 21144 OTOOL="true" 21145 fi 21146 21147 21148 # Publish this variable in the help. 21149 21150 21151 if [ -z "${READELF+x}" ]; then 21152 # The variable is not set by user, try to locate tool using the code snippet 21153 for ac_prog in greadelf readelf 21154 do 21155 # Extract the first word of "$ac_prog", so it can be a program name with args. 21156 set dummy $ac_prog; ac_word=$2 21157 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21158 $as_echo_n "checking for $ac_word... " >&6; } 21159 if ${ac_cv_path_READELF+:} false; then : 21160 $as_echo_n "(cached) " >&6 21161 else 21162 case $READELF in 21163 [\\/]* | ?:[\\/]*) 21164 ac_cv_path_READELF="$READELF" # Let the user override the test with a path. 21165 ;; 21166 *) 21167 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21168 for as_dir in $PATH 21169 do 21170 IFS=$as_save_IFS 21171 test -z "$as_dir" && as_dir=. 21172 for ac_exec_ext in '' $ac_executable_extensions; do 21173 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21174 ac_cv_path_READELF="$as_dir/$ac_word$ac_exec_ext" 21175 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21176 break 2 21177 fi 21178 done 21179 done 21180 IFS=$as_save_IFS 21181 21182 ;; 21183 esac 21184 fi 21185 READELF=$ac_cv_path_READELF 21186 if test -n "$READELF"; then 21187 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5 21188 $as_echo "$READELF" >&6; } 21189 else 21190 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21191 $as_echo "no" >&6; } 21192 fi 21193 21194 21195 test -n "$READELF" && break 21196 done 21197 21198 else 21199 # The variable is set, but is it from the command line or the environment? 21200 21201 # Try to remove the string !READELF! from our list. 21202 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!READELF!/} 21203 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 21204 # If it failed, the variable was not from the command line. Ignore it, 21205 # but warn the user (except for BASH, which is always set by the calling BASH). 21206 if test "xREADELF" != xBASH; then 21207 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of READELF from the environment. Use command line variables instead." >&5 21208 $as_echo "$as_me: WARNING: Ignoring value of READELF from the environment. Use command line variables instead." >&2;} 21209 fi 21210 # Try to locate tool using the code snippet 21211 for ac_prog in greadelf readelf 21212 do 21213 # Extract the first word of "$ac_prog", so it can be a program name with args. 21214 set dummy $ac_prog; ac_word=$2 21215 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21216 $as_echo_n "checking for $ac_word... " >&6; } 21217 if ${ac_cv_path_READELF+:} false; then : 21218 $as_echo_n "(cached) " >&6 21219 else 21220 case $READELF in 21221 [\\/]* | ?:[\\/]*) 21222 ac_cv_path_READELF="$READELF" # Let the user override the test with a path. 21223 ;; 21224 *) 21225 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21226 for as_dir in $PATH 21227 do 21228 IFS=$as_save_IFS 21229 test -z "$as_dir" && as_dir=. 21230 for ac_exec_ext in '' $ac_executable_extensions; do 21231 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21232 ac_cv_path_READELF="$as_dir/$ac_word$ac_exec_ext" 21233 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21234 break 2 21235 fi 21236 done 21237 done 21238 IFS=$as_save_IFS 21239 21240 ;; 21241 esac 21242 fi 21243 READELF=$ac_cv_path_READELF 21244 if test -n "$READELF"; then 21245 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5 21246 $as_echo "$READELF" >&6; } 21247 else 21248 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21249 $as_echo "no" >&6; } 21250 fi 21251 21252 21253 test -n "$READELF" && break 21254 done 21255 21256 else 21257 # If it succeeded, then it was overridden by the user. We will use it 21258 # for the tool. 21259 21260 # First remove it from the list of overridden variables, so we can test 21261 # for unknown variables in the end. 21262 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 21263 21264 # Check if we try to supply an empty value 21265 if test "x$READELF" = x; then 21266 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool READELF= (no value)" >&5 21267 $as_echo "$as_me: Setting user supplied tool READELF= (no value)" >&6;} 21268 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READELF" >&5 21269 $as_echo_n "checking for READELF... " >&6; } 21270 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 21271 $as_echo "disabled" >&6; } 21272 else 21273 # Check if the provided tool contains a complete path. 21274 tool_specified="$READELF" 21275 tool_basename="${tool_specified##*/}" 21276 if test "x$tool_basename" = "x$tool_specified"; then 21277 # A command without a complete path is provided, search $PATH. 21278 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool READELF=$tool_basename" >&5 21279 $as_echo "$as_me: Will search for user supplied tool READELF=$tool_basename" >&6;} 21280 # Extract the first word of "$tool_basename", so it can be a program name with args. 21281 set dummy $tool_basename; ac_word=$2 21282 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21283 $as_echo_n "checking for $ac_word... " >&6; } 21284 if ${ac_cv_path_READELF+:} false; then : 21285 $as_echo_n "(cached) " >&6 21286 else 21287 case $READELF in 21288 [\\/]* | ?:[\\/]*) 21289 ac_cv_path_READELF="$READELF" # Let the user override the test with a path. 21290 ;; 21291 *) 21292 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21293 for as_dir in $PATH 21294 do 21295 IFS=$as_save_IFS 21296 test -z "$as_dir" && as_dir=. 21297 for ac_exec_ext in '' $ac_executable_extensions; do 21298 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21299 ac_cv_path_READELF="$as_dir/$ac_word$ac_exec_ext" 21300 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21301 break 2 21302 fi 21303 done 21304 done 21305 IFS=$as_save_IFS 21306 21307 ;; 21308 esac 21309 fi 21310 READELF=$ac_cv_path_READELF 21311 if test -n "$READELF"; then 21312 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $READELF" >&5 21313 $as_echo "$READELF" >&6; } 21314 else 21315 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21316 $as_echo "no" >&6; } 21317 fi 21318 21319 21320 if test "x$READELF" = x; then 21321 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 21322 fi 21323 else 21324 # Otherwise we believe it is a complete path. Use it as it is. 21325 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool READELF=$tool_specified" >&5 21326 $as_echo "$as_me: Will use user supplied tool READELF=$tool_specified" >&6;} 21327 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for READELF" >&5 21328 $as_echo_n "checking for READELF... " >&6; } 21329 if test ! -x "$tool_specified"; then 21330 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 21331 $as_echo "not found" >&6; } 21332 as_fn_error $? "User supplied tool READELF=$tool_specified does not exist or is not executable" "$LINENO" 5 21333 fi 21334 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 21335 $as_echo "$tool_specified" >&6; } 21336 fi 21337 fi 21338 fi 21339 21340 fi 21341 21342 21343 21344 21345 # Publish this variable in the help. 21346 21347 21348 if [ -z "${HG+x}" ]; then 21349 # The variable is not set by user, try to locate tool using the code snippet 21350 for ac_prog in hg 21351 do 21352 # Extract the first word of "$ac_prog", so it can be a program name with args. 21353 set dummy $ac_prog; ac_word=$2 21354 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21355 $as_echo_n "checking for $ac_word... " >&6; } 21356 if ${ac_cv_path_HG+:} false; then : 21357 $as_echo_n "(cached) " >&6 21358 else 21359 case $HG in 21360 [\\/]* | ?:[\\/]*) 21361 ac_cv_path_HG="$HG" # Let the user override the test with a path. 21362 ;; 21363 *) 21364 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21365 for as_dir in $PATH 21366 do 21367 IFS=$as_save_IFS 21368 test -z "$as_dir" && as_dir=. 21369 for ac_exec_ext in '' $ac_executable_extensions; do 21370 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21371 ac_cv_path_HG="$as_dir/$ac_word$ac_exec_ext" 21372 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21373 break 2 21374 fi 21375 done 21376 done 21377 IFS=$as_save_IFS 21378 21379 ;; 21380 esac 21381 fi 21382 HG=$ac_cv_path_HG 21383 if test -n "$HG"; then 21384 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HG" >&5 21385 $as_echo "$HG" >&6; } 21386 else 21387 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21388 $as_echo "no" >&6; } 21389 fi 21390 21391 21392 test -n "$HG" && break 21393 done 21394 21395 else 21396 # The variable is set, but is it from the command line or the environment? 21397 21398 # Try to remove the string !HG! from our list. 21399 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!HG!/} 21400 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 21401 # If it failed, the variable was not from the command line. Ignore it, 21402 # but warn the user (except for BASH, which is always set by the calling BASH). 21403 if test "xHG" != xBASH; then 21404 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of HG from the environment. Use command line variables instead." >&5 21405 $as_echo "$as_me: WARNING: Ignoring value of HG from the environment. Use command line variables instead." >&2;} 21406 fi 21407 # Try to locate tool using the code snippet 21408 for ac_prog in hg 21409 do 21410 # Extract the first word of "$ac_prog", so it can be a program name with args. 21411 set dummy $ac_prog; ac_word=$2 21412 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21413 $as_echo_n "checking for $ac_word... " >&6; } 21414 if ${ac_cv_path_HG+:} false; then : 21415 $as_echo_n "(cached) " >&6 21416 else 21417 case $HG in 21418 [\\/]* | ?:[\\/]*) 21419 ac_cv_path_HG="$HG" # Let the user override the test with a path. 21420 ;; 21421 *) 21422 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21423 for as_dir in $PATH 21424 do 21425 IFS=$as_save_IFS 21426 test -z "$as_dir" && as_dir=. 21427 for ac_exec_ext in '' $ac_executable_extensions; do 21428 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21429 ac_cv_path_HG="$as_dir/$ac_word$ac_exec_ext" 21430 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21431 break 2 21432 fi 21433 done 21434 done 21435 IFS=$as_save_IFS 21436 21437 ;; 21438 esac 21439 fi 21440 HG=$ac_cv_path_HG 21441 if test -n "$HG"; then 21442 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HG" >&5 21443 $as_echo "$HG" >&6; } 21444 else 21445 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21446 $as_echo "no" >&6; } 21447 fi 21448 21449 21450 test -n "$HG" && break 21451 done 21452 21453 else 21454 # If it succeeded, then it was overridden by the user. We will use it 21455 # for the tool. 21456 21457 # First remove it from the list of overridden variables, so we can test 21458 # for unknown variables in the end. 21459 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 21460 21461 # Check if we try to supply an empty value 21462 if test "x$HG" = x; then 21463 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool HG= (no value)" >&5 21464 $as_echo "$as_me: Setting user supplied tool HG= (no value)" >&6;} 21465 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HG" >&5 21466 $as_echo_n "checking for HG... " >&6; } 21467 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 21468 $as_echo "disabled" >&6; } 21469 else 21470 # Check if the provided tool contains a complete path. 21471 tool_specified="$HG" 21472 tool_basename="${tool_specified##*/}" 21473 if test "x$tool_basename" = "x$tool_specified"; then 21474 # A command without a complete path is provided, search $PATH. 21475 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool HG=$tool_basename" >&5 21476 $as_echo "$as_me: Will search for user supplied tool HG=$tool_basename" >&6;} 21477 # Extract the first word of "$tool_basename", so it can be a program name with args. 21478 set dummy $tool_basename; ac_word=$2 21479 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21480 $as_echo_n "checking for $ac_word... " >&6; } 21481 if ${ac_cv_path_HG+:} false; then : 21482 $as_echo_n "(cached) " >&6 21483 else 21484 case $HG in 21485 [\\/]* | ?:[\\/]*) 21486 ac_cv_path_HG="$HG" # Let the user override the test with a path. 21487 ;; 21488 *) 21489 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21490 for as_dir in $PATH 21491 do 21492 IFS=$as_save_IFS 21493 test -z "$as_dir" && as_dir=. 21494 for ac_exec_ext in '' $ac_executable_extensions; do 21495 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21496 ac_cv_path_HG="$as_dir/$ac_word$ac_exec_ext" 21497 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21498 break 2 21499 fi 21500 done 21501 done 21502 IFS=$as_save_IFS 21503 21504 ;; 21505 esac 21506 fi 21507 HG=$ac_cv_path_HG 21508 if test -n "$HG"; then 21509 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $HG" >&5 21510 $as_echo "$HG" >&6; } 21511 else 21512 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21513 $as_echo "no" >&6; } 21514 fi 21515 21516 21517 if test "x$HG" = x; then 21518 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 21519 fi 21520 else 21521 # Otherwise we believe it is a complete path. Use it as it is. 21522 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool HG=$tool_specified" >&5 21523 $as_echo "$as_me: Will use user supplied tool HG=$tool_specified" >&6;} 21524 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for HG" >&5 21525 $as_echo_n "checking for HG... " >&6; } 21526 if test ! -x "$tool_specified"; then 21527 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 21528 $as_echo "not found" >&6; } 21529 as_fn_error $? "User supplied tool HG=$tool_specified does not exist or is not executable" "$LINENO" 5 21530 fi 21531 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 21532 $as_echo "$tool_specified" >&6; } 21533 fi 21534 fi 21535 fi 21536 21537 fi 21538 21539 21540 21541 21542 # Publish this variable in the help. 21543 21544 21545 if [ -z "${STAT+x}" ]; then 21546 # The variable is not set by user, try to locate tool using the code snippet 21547 for ac_prog in stat 21548 do 21549 # Extract the first word of "$ac_prog", so it can be a program name with args. 21550 set dummy $ac_prog; ac_word=$2 21551 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21552 $as_echo_n "checking for $ac_word... " >&6; } 21553 if ${ac_cv_path_STAT+:} false; then : 21554 $as_echo_n "(cached) " >&6 21555 else 21556 case $STAT in 21557 [\\/]* | ?:[\\/]*) 21558 ac_cv_path_STAT="$STAT" # Let the user override the test with a path. 21559 ;; 21560 *) 21561 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21562 for as_dir in $PATH 21563 do 21564 IFS=$as_save_IFS 21565 test -z "$as_dir" && as_dir=. 21566 for ac_exec_ext in '' $ac_executable_extensions; do 21567 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21568 ac_cv_path_STAT="$as_dir/$ac_word$ac_exec_ext" 21569 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21570 break 2 21571 fi 21572 done 21573 done 21574 IFS=$as_save_IFS 21575 21576 ;; 21577 esac 21578 fi 21579 STAT=$ac_cv_path_STAT 21580 if test -n "$STAT"; then 21581 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAT" >&5 21582 $as_echo "$STAT" >&6; } 21583 else 21584 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21585 $as_echo "no" >&6; } 21586 fi 21587 21588 21589 test -n "$STAT" && break 21590 done 21591 21592 else 21593 # The variable is set, but is it from the command line or the environment? 21594 21595 # Try to remove the string !STAT! from our list. 21596 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!STAT!/} 21597 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 21598 # If it failed, the variable was not from the command line. Ignore it, 21599 # but warn the user (except for BASH, which is always set by the calling BASH). 21600 if test "xSTAT" != xBASH; then 21601 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of STAT from the environment. Use command line variables instead." >&5 21602 $as_echo "$as_me: WARNING: Ignoring value of STAT from the environment. Use command line variables instead." >&2;} 21603 fi 21604 # Try to locate tool using the code snippet 21605 for ac_prog in stat 21606 do 21607 # Extract the first word of "$ac_prog", so it can be a program name with args. 21608 set dummy $ac_prog; ac_word=$2 21609 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21610 $as_echo_n "checking for $ac_word... " >&6; } 21611 if ${ac_cv_path_STAT+:} false; then : 21612 $as_echo_n "(cached) " >&6 21613 else 21614 case $STAT in 21615 [\\/]* | ?:[\\/]*) 21616 ac_cv_path_STAT="$STAT" # Let the user override the test with a path. 21617 ;; 21618 *) 21619 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21620 for as_dir in $PATH 21621 do 21622 IFS=$as_save_IFS 21623 test -z "$as_dir" && as_dir=. 21624 for ac_exec_ext in '' $ac_executable_extensions; do 21625 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21626 ac_cv_path_STAT="$as_dir/$ac_word$ac_exec_ext" 21627 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21628 break 2 21629 fi 21630 done 21631 done 21632 IFS=$as_save_IFS 21633 21634 ;; 21635 esac 21636 fi 21637 STAT=$ac_cv_path_STAT 21638 if test -n "$STAT"; then 21639 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAT" >&5 21640 $as_echo "$STAT" >&6; } 21641 else 21642 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21643 $as_echo "no" >&6; } 21644 fi 21645 21646 21647 test -n "$STAT" && break 21648 done 21649 21650 else 21651 # If it succeeded, then it was overridden by the user. We will use it 21652 # for the tool. 21653 21654 # First remove it from the list of overridden variables, so we can test 21655 # for unknown variables in the end. 21656 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 21657 21658 # Check if we try to supply an empty value 21659 if test "x$STAT" = x; then 21660 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool STAT= (no value)" >&5 21661 $as_echo "$as_me: Setting user supplied tool STAT= (no value)" >&6;} 21662 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STAT" >&5 21663 $as_echo_n "checking for STAT... " >&6; } 21664 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 21665 $as_echo "disabled" >&6; } 21666 else 21667 # Check if the provided tool contains a complete path. 21668 tool_specified="$STAT" 21669 tool_basename="${tool_specified##*/}" 21670 if test "x$tool_basename" = "x$tool_specified"; then 21671 # A command without a complete path is provided, search $PATH. 21672 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool STAT=$tool_basename" >&5 21673 $as_echo "$as_me: Will search for user supplied tool STAT=$tool_basename" >&6;} 21674 # Extract the first word of "$tool_basename", so it can be a program name with args. 21675 set dummy $tool_basename; ac_word=$2 21676 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21677 $as_echo_n "checking for $ac_word... " >&6; } 21678 if ${ac_cv_path_STAT+:} false; then : 21679 $as_echo_n "(cached) " >&6 21680 else 21681 case $STAT in 21682 [\\/]* | ?:[\\/]*) 21683 ac_cv_path_STAT="$STAT" # Let the user override the test with a path. 21684 ;; 21685 *) 21686 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21687 for as_dir in $PATH 21688 do 21689 IFS=$as_save_IFS 21690 test -z "$as_dir" && as_dir=. 21691 for ac_exec_ext in '' $ac_executable_extensions; do 21692 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21693 ac_cv_path_STAT="$as_dir/$ac_word$ac_exec_ext" 21694 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21695 break 2 21696 fi 21697 done 21698 done 21699 IFS=$as_save_IFS 21700 21701 ;; 21702 esac 21703 fi 21704 STAT=$ac_cv_path_STAT 21705 if test -n "$STAT"; then 21706 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STAT" >&5 21707 $as_echo "$STAT" >&6; } 21708 else 21709 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21710 $as_echo "no" >&6; } 21711 fi 21712 21713 21714 if test "x$STAT" = x; then 21715 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 21716 fi 21717 else 21718 # Otherwise we believe it is a complete path. Use it as it is. 21719 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool STAT=$tool_specified" >&5 21720 $as_echo "$as_me: Will use user supplied tool STAT=$tool_specified" >&6;} 21721 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STAT" >&5 21722 $as_echo_n "checking for STAT... " >&6; } 21723 if test ! -x "$tool_specified"; then 21724 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 21725 $as_echo "not found" >&6; } 21726 as_fn_error $? "User supplied tool STAT=$tool_specified does not exist or is not executable" "$LINENO" 5 21727 fi 21728 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 21729 $as_echo "$tool_specified" >&6; } 21730 fi 21731 fi 21732 fi 21733 21734 fi 21735 21736 21737 21738 21739 # Publish this variable in the help. 21740 21741 21742 if [ -z "${TIME+x}" ]; then 21743 # The variable is not set by user, try to locate tool using the code snippet 21744 for ac_prog in time 21745 do 21746 # Extract the first word of "$ac_prog", so it can be a program name with args. 21747 set dummy $ac_prog; ac_word=$2 21748 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21749 $as_echo_n "checking for $ac_word... " >&6; } 21750 if ${ac_cv_path_TIME+:} false; then : 21751 $as_echo_n "(cached) " >&6 21752 else 21753 case $TIME in 21754 [\\/]* | ?:[\\/]*) 21755 ac_cv_path_TIME="$TIME" # Let the user override the test with a path. 21756 ;; 21757 *) 21758 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21759 for as_dir in $PATH 21760 do 21761 IFS=$as_save_IFS 21762 test -z "$as_dir" && as_dir=. 21763 for ac_exec_ext in '' $ac_executable_extensions; do 21764 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21765 ac_cv_path_TIME="$as_dir/$ac_word$ac_exec_ext" 21766 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21767 break 2 21768 fi 21769 done 21770 done 21771 IFS=$as_save_IFS 21772 21773 ;; 21774 esac 21775 fi 21776 TIME=$ac_cv_path_TIME 21777 if test -n "$TIME"; then 21778 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TIME" >&5 21779 $as_echo "$TIME" >&6; } 21780 else 21781 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21782 $as_echo "no" >&6; } 21783 fi 21784 21785 21786 test -n "$TIME" && break 21787 done 21788 21789 else 21790 # The variable is set, but is it from the command line or the environment? 21791 21792 # Try to remove the string !TIME! from our list. 21793 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!TIME!/} 21794 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 21795 # If it failed, the variable was not from the command line. Ignore it, 21796 # but warn the user (except for BASH, which is always set by the calling BASH). 21797 if test "xTIME" != xBASH; then 21798 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of TIME from the environment. Use command line variables instead." >&5 21799 $as_echo "$as_me: WARNING: Ignoring value of TIME from the environment. Use command line variables instead." >&2;} 21800 fi 21801 # Try to locate tool using the code snippet 21802 for ac_prog in time 21803 do 21804 # Extract the first word of "$ac_prog", so it can be a program name with args. 21805 set dummy $ac_prog; ac_word=$2 21806 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21807 $as_echo_n "checking for $ac_word... " >&6; } 21808 if ${ac_cv_path_TIME+:} false; then : 21809 $as_echo_n "(cached) " >&6 21810 else 21811 case $TIME in 21812 [\\/]* | ?:[\\/]*) 21813 ac_cv_path_TIME="$TIME" # Let the user override the test with a path. 21814 ;; 21815 *) 21816 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21817 for as_dir in $PATH 21818 do 21819 IFS=$as_save_IFS 21820 test -z "$as_dir" && as_dir=. 21821 for ac_exec_ext in '' $ac_executable_extensions; do 21822 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21823 ac_cv_path_TIME="$as_dir/$ac_word$ac_exec_ext" 21824 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21825 break 2 21826 fi 21827 done 21828 done 21829 IFS=$as_save_IFS 21830 21831 ;; 21832 esac 21833 fi 21834 TIME=$ac_cv_path_TIME 21835 if test -n "$TIME"; then 21836 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TIME" >&5 21837 $as_echo "$TIME" >&6; } 21838 else 21839 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21840 $as_echo "no" >&6; } 21841 fi 21842 21843 21844 test -n "$TIME" && break 21845 done 21846 21847 else 21848 # If it succeeded, then it was overridden by the user. We will use it 21849 # for the tool. 21850 21851 # First remove it from the list of overridden variables, so we can test 21852 # for unknown variables in the end. 21853 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 21854 21855 # Check if we try to supply an empty value 21856 if test "x$TIME" = x; then 21857 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool TIME= (no value)" >&5 21858 $as_echo "$as_me: Setting user supplied tool TIME= (no value)" >&6;} 21859 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIME" >&5 21860 $as_echo_n "checking for TIME... " >&6; } 21861 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 21862 $as_echo "disabled" >&6; } 21863 else 21864 # Check if the provided tool contains a complete path. 21865 tool_specified="$TIME" 21866 tool_basename="${tool_specified##*/}" 21867 if test "x$tool_basename" = "x$tool_specified"; then 21868 # A command without a complete path is provided, search $PATH. 21869 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool TIME=$tool_basename" >&5 21870 $as_echo "$as_me: Will search for user supplied tool TIME=$tool_basename" >&6;} 21871 # Extract the first word of "$tool_basename", so it can be a program name with args. 21872 set dummy $tool_basename; ac_word=$2 21873 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21874 $as_echo_n "checking for $ac_word... " >&6; } 21875 if ${ac_cv_path_TIME+:} false; then : 21876 $as_echo_n "(cached) " >&6 21877 else 21878 case $TIME in 21879 [\\/]* | ?:[\\/]*) 21880 ac_cv_path_TIME="$TIME" # Let the user override the test with a path. 21881 ;; 21882 *) 21883 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21884 for as_dir in $PATH 21885 do 21886 IFS=$as_save_IFS 21887 test -z "$as_dir" && as_dir=. 21888 for ac_exec_ext in '' $ac_executable_extensions; do 21889 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21890 ac_cv_path_TIME="$as_dir/$ac_word$ac_exec_ext" 21891 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21892 break 2 21893 fi 21894 done 21895 done 21896 IFS=$as_save_IFS 21897 21898 ;; 21899 esac 21900 fi 21901 TIME=$ac_cv_path_TIME 21902 if test -n "$TIME"; then 21903 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TIME" >&5 21904 $as_echo "$TIME" >&6; } 21905 else 21906 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21907 $as_echo "no" >&6; } 21908 fi 21909 21910 21911 if test "x$TIME" = x; then 21912 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 21913 fi 21914 else 21915 # Otherwise we believe it is a complete path. Use it as it is. 21916 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool TIME=$tool_specified" >&5 21917 $as_echo "$as_me: Will use user supplied tool TIME=$tool_specified" >&6;} 21918 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for TIME" >&5 21919 $as_echo_n "checking for TIME... " >&6; } 21920 if test ! -x "$tool_specified"; then 21921 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 21922 $as_echo "not found" >&6; } 21923 as_fn_error $? "User supplied tool TIME=$tool_specified does not exist or is not executable" "$LINENO" 5 21924 fi 21925 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 21926 $as_echo "$tool_specified" >&6; } 21927 fi 21928 fi 21929 fi 21930 21931 fi 21932 21933 21934 21935 21936 # Publish this variable in the help. 21937 21938 21939 if [ -z "${PATCH+x}" ]; then 21940 # The variable is not set by user, try to locate tool using the code snippet 21941 for ac_prog in gpatch patch 21942 do 21943 # Extract the first word of "$ac_prog", so it can be a program name with args. 21944 set dummy $ac_prog; ac_word=$2 21945 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 21946 $as_echo_n "checking for $ac_word... " >&6; } 21947 if ${ac_cv_path_PATCH+:} false; then : 21948 $as_echo_n "(cached) " >&6 21949 else 21950 case $PATCH in 21951 [\\/]* | ?:[\\/]*) 21952 ac_cv_path_PATCH="$PATCH" # Let the user override the test with a path. 21953 ;; 21954 *) 21955 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 21956 for as_dir in $PATH 21957 do 21958 IFS=$as_save_IFS 21959 test -z "$as_dir" && as_dir=. 21960 for ac_exec_ext in '' $ac_executable_extensions; do 21961 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 21962 ac_cv_path_PATCH="$as_dir/$ac_word$ac_exec_ext" 21963 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 21964 break 2 21965 fi 21966 done 21967 done 21968 IFS=$as_save_IFS 21969 21970 ;; 21971 esac 21972 fi 21973 PATCH=$ac_cv_path_PATCH 21974 if test -n "$PATCH"; then 21975 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATCH" >&5 21976 $as_echo "$PATCH" >&6; } 21977 else 21978 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 21979 $as_echo "no" >&6; } 21980 fi 21981 21982 21983 test -n "$PATCH" && break 21984 done 21985 21986 else 21987 # The variable is set, but is it from the command line or the environment? 21988 21989 # Try to remove the string !PATCH! from our list. 21990 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!PATCH!/} 21991 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 21992 # If it failed, the variable was not from the command line. Ignore it, 21993 # but warn the user (except for BASH, which is always set by the calling BASH). 21994 if test "xPATCH" != xBASH; then 21995 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of PATCH from the environment. Use command line variables instead." >&5 21996 $as_echo "$as_me: WARNING: Ignoring value of PATCH from the environment. Use command line variables instead." >&2;} 21997 fi 21998 # Try to locate tool using the code snippet 21999 for ac_prog in gpatch patch 22000 do 22001 # Extract the first word of "$ac_prog", so it can be a program name with args. 22002 set dummy $ac_prog; ac_word=$2 22003 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22004 $as_echo_n "checking for $ac_word... " >&6; } 22005 if ${ac_cv_path_PATCH+:} false; then : 22006 $as_echo_n "(cached) " >&6 22007 else 22008 case $PATCH in 22009 [\\/]* | ?:[\\/]*) 22010 ac_cv_path_PATCH="$PATCH" # Let the user override the test with a path. 22011 ;; 22012 *) 22013 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22014 for as_dir in $PATH 22015 do 22016 IFS=$as_save_IFS 22017 test -z "$as_dir" && as_dir=. 22018 for ac_exec_ext in '' $ac_executable_extensions; do 22019 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22020 ac_cv_path_PATCH="$as_dir/$ac_word$ac_exec_ext" 22021 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22022 break 2 22023 fi 22024 done 22025 done 22026 IFS=$as_save_IFS 22027 22028 ;; 22029 esac 22030 fi 22031 PATCH=$ac_cv_path_PATCH 22032 if test -n "$PATCH"; then 22033 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATCH" >&5 22034 $as_echo "$PATCH" >&6; } 22035 else 22036 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22037 $as_echo "no" >&6; } 22038 fi 22039 22040 22041 test -n "$PATCH" && break 22042 done 22043 22044 else 22045 # If it succeeded, then it was overridden by the user. We will use it 22046 # for the tool. 22047 22048 # First remove it from the list of overridden variables, so we can test 22049 # for unknown variables in the end. 22050 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 22051 22052 # Check if we try to supply an empty value 22053 if test "x$PATCH" = x; then 22054 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool PATCH= (no value)" >&5 22055 $as_echo "$as_me: Setting user supplied tool PATCH= (no value)" >&6;} 22056 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PATCH" >&5 22057 $as_echo_n "checking for PATCH... " >&6; } 22058 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 22059 $as_echo "disabled" >&6; } 22060 else 22061 # Check if the provided tool contains a complete path. 22062 tool_specified="$PATCH" 22063 tool_basename="${tool_specified##*/}" 22064 if test "x$tool_basename" = "x$tool_specified"; then 22065 # A command without a complete path is provided, search $PATH. 22066 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool PATCH=$tool_basename" >&5 22067 $as_echo "$as_me: Will search for user supplied tool PATCH=$tool_basename" >&6;} 22068 # Extract the first word of "$tool_basename", so it can be a program name with args. 22069 set dummy $tool_basename; ac_word=$2 22070 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22071 $as_echo_n "checking for $ac_word... " >&6; } 22072 if ${ac_cv_path_PATCH+:} false; then : 22073 $as_echo_n "(cached) " >&6 22074 else 22075 case $PATCH in 22076 [\\/]* | ?:[\\/]*) 22077 ac_cv_path_PATCH="$PATCH" # Let the user override the test with a path. 22078 ;; 22079 *) 22080 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22081 for as_dir in $PATH 22082 do 22083 IFS=$as_save_IFS 22084 test -z "$as_dir" && as_dir=. 22085 for ac_exec_ext in '' $ac_executable_extensions; do 22086 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22087 ac_cv_path_PATCH="$as_dir/$ac_word$ac_exec_ext" 22088 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22089 break 2 22090 fi 22091 done 22092 done 22093 IFS=$as_save_IFS 22094 22095 ;; 22096 esac 22097 fi 22098 PATCH=$ac_cv_path_PATCH 22099 if test -n "$PATCH"; then 22100 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PATCH" >&5 22101 $as_echo "$PATCH" >&6; } 22102 else 22103 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22104 $as_echo "no" >&6; } 22105 fi 22106 22107 22108 if test "x$PATCH" = x; then 22109 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 22110 fi 22111 else 22112 # Otherwise we believe it is a complete path. Use it as it is. 22113 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool PATCH=$tool_specified" >&5 22114 $as_echo "$as_me: Will use user supplied tool PATCH=$tool_specified" >&6;} 22115 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PATCH" >&5 22116 $as_echo_n "checking for PATCH... " >&6; } 22117 if test ! -x "$tool_specified"; then 22118 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 22119 $as_echo "not found" >&6; } 22120 as_fn_error $? "User supplied tool PATCH=$tool_specified does not exist or is not executable" "$LINENO" 5 22121 fi 22122 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 22123 $as_echo "$tool_specified" >&6; } 22124 fi 22125 fi 22126 fi 22127 22128 fi 22129 22130 22131 # Check if it's GNU time 22132 IS_GNU_TIME=`$TIME --version 2>&1 | $GREP 'GNU time'` 22133 if test "x$IS_GNU_TIME" != x; then 22134 IS_GNU_TIME=yes 22135 else 22136 IS_GNU_TIME=no 22137 fi 22138 22139 22140 if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then 22141 22142 22143 22144 # Publish this variable in the help. 22145 22146 22147 if [ -z "${DSYMUTIL+x}" ]; then 22148 # The variable is not set by user, try to locate tool using the code snippet 22149 for ac_prog in dsymutil 22150 do 22151 # Extract the first word of "$ac_prog", so it can be a program name with args. 22152 set dummy $ac_prog; ac_word=$2 22153 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22154 $as_echo_n "checking for $ac_word... " >&6; } 22155 if ${ac_cv_path_DSYMUTIL+:} false; then : 22156 $as_echo_n "(cached) " >&6 22157 else 22158 case $DSYMUTIL in 22159 [\\/]* | ?:[\\/]*) 22160 ac_cv_path_DSYMUTIL="$DSYMUTIL" # Let the user override the test with a path. 22161 ;; 22162 *) 22163 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22164 for as_dir in $PATH 22165 do 22166 IFS=$as_save_IFS 22167 test -z "$as_dir" && as_dir=. 22168 for ac_exec_ext in '' $ac_executable_extensions; do 22169 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22170 ac_cv_path_DSYMUTIL="$as_dir/$ac_word$ac_exec_ext" 22171 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22172 break 2 22173 fi 22174 done 22175 done 22176 IFS=$as_save_IFS 22177 22178 ;; 22179 esac 22180 fi 22181 DSYMUTIL=$ac_cv_path_DSYMUTIL 22182 if test -n "$DSYMUTIL"; then 22183 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 22184 $as_echo "$DSYMUTIL" >&6; } 22185 else 22186 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22187 $as_echo "no" >&6; } 22188 fi 22189 22190 22191 test -n "$DSYMUTIL" && break 22192 done 22193 22194 else 22195 # The variable is set, but is it from the command line or the environment? 22196 22197 # Try to remove the string !DSYMUTIL! from our list. 22198 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!DSYMUTIL!/} 22199 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 22200 # If it failed, the variable was not from the command line. Ignore it, 22201 # but warn the user (except for BASH, which is always set by the calling BASH). 22202 if test "xDSYMUTIL" != xBASH; then 22203 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of DSYMUTIL from the environment. Use command line variables instead." >&5 22204 $as_echo "$as_me: WARNING: Ignoring value of DSYMUTIL from the environment. Use command line variables instead." >&2;} 22205 fi 22206 # Try to locate tool using the code snippet 22207 for ac_prog in dsymutil 22208 do 22209 # Extract the first word of "$ac_prog", so it can be a program name with args. 22210 set dummy $ac_prog; ac_word=$2 22211 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22212 $as_echo_n "checking for $ac_word... " >&6; } 22213 if ${ac_cv_path_DSYMUTIL+:} false; then : 22214 $as_echo_n "(cached) " >&6 22215 else 22216 case $DSYMUTIL in 22217 [\\/]* | ?:[\\/]*) 22218 ac_cv_path_DSYMUTIL="$DSYMUTIL" # Let the user override the test with a path. 22219 ;; 22220 *) 22221 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22222 for as_dir in $PATH 22223 do 22224 IFS=$as_save_IFS 22225 test -z "$as_dir" && as_dir=. 22226 for ac_exec_ext in '' $ac_executable_extensions; do 22227 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22228 ac_cv_path_DSYMUTIL="$as_dir/$ac_word$ac_exec_ext" 22229 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22230 break 2 22231 fi 22232 done 22233 done 22234 IFS=$as_save_IFS 22235 22236 ;; 22237 esac 22238 fi 22239 DSYMUTIL=$ac_cv_path_DSYMUTIL 22240 if test -n "$DSYMUTIL"; then 22241 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 22242 $as_echo "$DSYMUTIL" >&6; } 22243 else 22244 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22245 $as_echo "no" >&6; } 22246 fi 22247 22248 22249 test -n "$DSYMUTIL" && break 22250 done 22251 22252 else 22253 # If it succeeded, then it was overridden by the user. We will use it 22254 # for the tool. 22255 22256 # First remove it from the list of overridden variables, so we can test 22257 # for unknown variables in the end. 22258 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 22259 22260 # Check if we try to supply an empty value 22261 if test "x$DSYMUTIL" = x; then 22262 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool DSYMUTIL= (no value)" >&5 22263 $as_echo "$as_me: Setting user supplied tool DSYMUTIL= (no value)" >&6;} 22264 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DSYMUTIL" >&5 22265 $as_echo_n "checking for DSYMUTIL... " >&6; } 22266 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 22267 $as_echo "disabled" >&6; } 22268 else 22269 # Check if the provided tool contains a complete path. 22270 tool_specified="$DSYMUTIL" 22271 tool_basename="${tool_specified##*/}" 22272 if test "x$tool_basename" = "x$tool_specified"; then 22273 # A command without a complete path is provided, search $PATH. 22274 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool DSYMUTIL=$tool_basename" >&5 22275 $as_echo "$as_me: Will search for user supplied tool DSYMUTIL=$tool_basename" >&6;} 22276 # Extract the first word of "$tool_basename", so it can be a program name with args. 22277 set dummy $tool_basename; ac_word=$2 22278 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22279 $as_echo_n "checking for $ac_word... " >&6; } 22280 if ${ac_cv_path_DSYMUTIL+:} false; then : 22281 $as_echo_n "(cached) " >&6 22282 else 22283 case $DSYMUTIL in 22284 [\\/]* | ?:[\\/]*) 22285 ac_cv_path_DSYMUTIL="$DSYMUTIL" # Let the user override the test with a path. 22286 ;; 22287 *) 22288 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22289 for as_dir in $PATH 22290 do 22291 IFS=$as_save_IFS 22292 test -z "$as_dir" && as_dir=. 22293 for ac_exec_ext in '' $ac_executable_extensions; do 22294 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22295 ac_cv_path_DSYMUTIL="$as_dir/$ac_word$ac_exec_ext" 22296 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22297 break 2 22298 fi 22299 done 22300 done 22301 IFS=$as_save_IFS 22302 22303 ;; 22304 esac 22305 fi 22306 DSYMUTIL=$ac_cv_path_DSYMUTIL 22307 if test -n "$DSYMUTIL"; then 22308 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DSYMUTIL" >&5 22309 $as_echo "$DSYMUTIL" >&6; } 22310 else 22311 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22312 $as_echo "no" >&6; } 22313 fi 22314 22315 22316 if test "x$DSYMUTIL" = x; then 22317 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 22318 fi 22319 else 22320 # Otherwise we believe it is a complete path. Use it as it is. 22321 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool DSYMUTIL=$tool_specified" >&5 22322 $as_echo "$as_me: Will use user supplied tool DSYMUTIL=$tool_specified" >&6;} 22323 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DSYMUTIL" >&5 22324 $as_echo_n "checking for DSYMUTIL... " >&6; } 22325 if test ! -x "$tool_specified"; then 22326 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 22327 $as_echo "not found" >&6; } 22328 as_fn_error $? "User supplied tool DSYMUTIL=$tool_specified does not exist or is not executable" "$LINENO" 5 22329 fi 22330 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 22331 $as_echo "$tool_specified" >&6; } 22332 fi 22333 fi 22334 fi 22335 22336 fi 22337 22338 22339 22340 if test "x$DSYMUTIL" = x; then 22341 as_fn_error $? "Could not find required tool for DSYMUTIL" "$LINENO" 5 22342 fi 22343 22344 22345 22346 22347 22348 # Publish this variable in the help. 22349 22350 22351 if [ -z "${XATTR+x}" ]; then 22352 # The variable is not set by user, try to locate tool using the code snippet 22353 for ac_prog in xattr 22354 do 22355 # Extract the first word of "$ac_prog", so it can be a program name with args. 22356 set dummy $ac_prog; ac_word=$2 22357 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22358 $as_echo_n "checking for $ac_word... " >&6; } 22359 if ${ac_cv_path_XATTR+:} false; then : 22360 $as_echo_n "(cached) " >&6 22361 else 22362 case $XATTR in 22363 [\\/]* | ?:[\\/]*) 22364 ac_cv_path_XATTR="$XATTR" # Let the user override the test with a path. 22365 ;; 22366 *) 22367 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22368 for as_dir in $PATH 22369 do 22370 IFS=$as_save_IFS 22371 test -z "$as_dir" && as_dir=. 22372 for ac_exec_ext in '' $ac_executable_extensions; do 22373 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22374 ac_cv_path_XATTR="$as_dir/$ac_word$ac_exec_ext" 22375 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22376 break 2 22377 fi 22378 done 22379 done 22380 IFS=$as_save_IFS 22381 22382 ;; 22383 esac 22384 fi 22385 XATTR=$ac_cv_path_XATTR 22386 if test -n "$XATTR"; then 22387 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XATTR" >&5 22388 $as_echo "$XATTR" >&6; } 22389 else 22390 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22391 $as_echo "no" >&6; } 22392 fi 22393 22394 22395 test -n "$XATTR" && break 22396 done 22397 22398 else 22399 # The variable is set, but is it from the command line or the environment? 22400 22401 # Try to remove the string !XATTR! from our list. 22402 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!XATTR!/} 22403 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 22404 # If it failed, the variable was not from the command line. Ignore it, 22405 # but warn the user (except for BASH, which is always set by the calling BASH). 22406 if test "xXATTR" != xBASH; then 22407 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of XATTR from the environment. Use command line variables instead." >&5 22408 $as_echo "$as_me: WARNING: Ignoring value of XATTR from the environment. Use command line variables instead." >&2;} 22409 fi 22410 # Try to locate tool using the code snippet 22411 for ac_prog in xattr 22412 do 22413 # Extract the first word of "$ac_prog", so it can be a program name with args. 22414 set dummy $ac_prog; ac_word=$2 22415 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22416 $as_echo_n "checking for $ac_word... " >&6; } 22417 if ${ac_cv_path_XATTR+:} false; then : 22418 $as_echo_n "(cached) " >&6 22419 else 22420 case $XATTR in 22421 [\\/]* | ?:[\\/]*) 22422 ac_cv_path_XATTR="$XATTR" # Let the user override the test with a path. 22423 ;; 22424 *) 22425 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22426 for as_dir in $PATH 22427 do 22428 IFS=$as_save_IFS 22429 test -z "$as_dir" && as_dir=. 22430 for ac_exec_ext in '' $ac_executable_extensions; do 22431 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22432 ac_cv_path_XATTR="$as_dir/$ac_word$ac_exec_ext" 22433 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22434 break 2 22435 fi 22436 done 22437 done 22438 IFS=$as_save_IFS 22439 22440 ;; 22441 esac 22442 fi 22443 XATTR=$ac_cv_path_XATTR 22444 if test -n "$XATTR"; then 22445 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XATTR" >&5 22446 $as_echo "$XATTR" >&6; } 22447 else 22448 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22449 $as_echo "no" >&6; } 22450 fi 22451 22452 22453 test -n "$XATTR" && break 22454 done 22455 22456 else 22457 # If it succeeded, then it was overridden by the user. We will use it 22458 # for the tool. 22459 22460 # First remove it from the list of overridden variables, so we can test 22461 # for unknown variables in the end. 22462 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 22463 22464 # Check if we try to supply an empty value 22465 if test "x$XATTR" = x; then 22466 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool XATTR= (no value)" >&5 22467 $as_echo "$as_me: Setting user supplied tool XATTR= (no value)" >&6;} 22468 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XATTR" >&5 22469 $as_echo_n "checking for XATTR... " >&6; } 22470 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 22471 $as_echo "disabled" >&6; } 22472 else 22473 # Check if the provided tool contains a complete path. 22474 tool_specified="$XATTR" 22475 tool_basename="${tool_specified##*/}" 22476 if test "x$tool_basename" = "x$tool_specified"; then 22477 # A command without a complete path is provided, search $PATH. 22478 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool XATTR=$tool_basename" >&5 22479 $as_echo "$as_me: Will search for user supplied tool XATTR=$tool_basename" >&6;} 22480 # Extract the first word of "$tool_basename", so it can be a program name with args. 22481 set dummy $tool_basename; ac_word=$2 22482 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22483 $as_echo_n "checking for $ac_word... " >&6; } 22484 if ${ac_cv_path_XATTR+:} false; then : 22485 $as_echo_n "(cached) " >&6 22486 else 22487 case $XATTR in 22488 [\\/]* | ?:[\\/]*) 22489 ac_cv_path_XATTR="$XATTR" # Let the user override the test with a path. 22490 ;; 22491 *) 22492 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22493 for as_dir in $PATH 22494 do 22495 IFS=$as_save_IFS 22496 test -z "$as_dir" && as_dir=. 22497 for ac_exec_ext in '' $ac_executable_extensions; do 22498 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22499 ac_cv_path_XATTR="$as_dir/$ac_word$ac_exec_ext" 22500 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22501 break 2 22502 fi 22503 done 22504 done 22505 IFS=$as_save_IFS 22506 22507 ;; 22508 esac 22509 fi 22510 XATTR=$ac_cv_path_XATTR 22511 if test -n "$XATTR"; then 22512 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $XATTR" >&5 22513 $as_echo "$XATTR" >&6; } 22514 else 22515 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22516 $as_echo "no" >&6; } 22517 fi 22518 22519 22520 if test "x$XATTR" = x; then 22521 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 22522 fi 22523 else 22524 # Otherwise we believe it is a complete path. Use it as it is. 22525 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool XATTR=$tool_specified" >&5 22526 $as_echo "$as_me: Will use user supplied tool XATTR=$tool_specified" >&6;} 22527 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for XATTR" >&5 22528 $as_echo_n "checking for XATTR... " >&6; } 22529 if test ! -x "$tool_specified"; then 22530 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 22531 $as_echo "not found" >&6; } 22532 as_fn_error $? "User supplied tool XATTR=$tool_specified does not exist or is not executable" "$LINENO" 5 22533 fi 22534 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 22535 $as_echo "$tool_specified" >&6; } 22536 fi 22537 fi 22538 fi 22539 22540 fi 22541 22542 22543 22544 if test "x$XATTR" = x; then 22545 as_fn_error $? "Could not find required tool for XATTR" "$LINENO" 5 22546 fi 22547 22548 22549 22550 22551 # Publish this variable in the help. 22552 22553 22554 if [ -z "${CODESIGN+x}" ]; then 22555 # The variable is not set by user, try to locate tool using the code snippet 22556 for ac_prog in codesign 22557 do 22558 # Extract the first word of "$ac_prog", so it can be a program name with args. 22559 set dummy $ac_prog; ac_word=$2 22560 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22561 $as_echo_n "checking for $ac_word... " >&6; } 22562 if ${ac_cv_path_CODESIGN+:} false; then : 22563 $as_echo_n "(cached) " >&6 22564 else 22565 case $CODESIGN in 22566 [\\/]* | ?:[\\/]*) 22567 ac_cv_path_CODESIGN="$CODESIGN" # Let the user override the test with a path. 22568 ;; 22569 *) 22570 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22571 for as_dir in $PATH 22572 do 22573 IFS=$as_save_IFS 22574 test -z "$as_dir" && as_dir=. 22575 for ac_exec_ext in '' $ac_executable_extensions; do 22576 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22577 ac_cv_path_CODESIGN="$as_dir/$ac_word$ac_exec_ext" 22578 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22579 break 2 22580 fi 22581 done 22582 done 22583 IFS=$as_save_IFS 22584 22585 ;; 22586 esac 22587 fi 22588 CODESIGN=$ac_cv_path_CODESIGN 22589 if test -n "$CODESIGN"; then 22590 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CODESIGN" >&5 22591 $as_echo "$CODESIGN" >&6; } 22592 else 22593 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22594 $as_echo "no" >&6; } 22595 fi 22596 22597 22598 test -n "$CODESIGN" && break 22599 done 22600 22601 else 22602 # The variable is set, but is it from the command line or the environment? 22603 22604 # Try to remove the string !CODESIGN! from our list. 22605 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CODESIGN!/} 22606 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 22607 # If it failed, the variable was not from the command line. Ignore it, 22608 # but warn the user (except for BASH, which is always set by the calling BASH). 22609 if test "xCODESIGN" != xBASH; then 22610 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CODESIGN from the environment. Use command line variables instead." >&5 22611 $as_echo "$as_me: WARNING: Ignoring value of CODESIGN from the environment. Use command line variables instead." >&2;} 22612 fi 22613 # Try to locate tool using the code snippet 22614 for ac_prog in codesign 22615 do 22616 # Extract the first word of "$ac_prog", so it can be a program name with args. 22617 set dummy $ac_prog; ac_word=$2 22618 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22619 $as_echo_n "checking for $ac_word... " >&6; } 22620 if ${ac_cv_path_CODESIGN+:} false; then : 22621 $as_echo_n "(cached) " >&6 22622 else 22623 case $CODESIGN in 22624 [\\/]* | ?:[\\/]*) 22625 ac_cv_path_CODESIGN="$CODESIGN" # Let the user override the test with a path. 22626 ;; 22627 *) 22628 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22629 for as_dir in $PATH 22630 do 22631 IFS=$as_save_IFS 22632 test -z "$as_dir" && as_dir=. 22633 for ac_exec_ext in '' $ac_executable_extensions; do 22634 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22635 ac_cv_path_CODESIGN="$as_dir/$ac_word$ac_exec_ext" 22636 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22637 break 2 22638 fi 22639 done 22640 done 22641 IFS=$as_save_IFS 22642 22643 ;; 22644 esac 22645 fi 22646 CODESIGN=$ac_cv_path_CODESIGN 22647 if test -n "$CODESIGN"; then 22648 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CODESIGN" >&5 22649 $as_echo "$CODESIGN" >&6; } 22650 else 22651 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22652 $as_echo "no" >&6; } 22653 fi 22654 22655 22656 test -n "$CODESIGN" && break 22657 done 22658 22659 else 22660 # If it succeeded, then it was overridden by the user. We will use it 22661 # for the tool. 22662 22663 # First remove it from the list of overridden variables, so we can test 22664 # for unknown variables in the end. 22665 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 22666 22667 # Check if we try to supply an empty value 22668 if test "x$CODESIGN" = x; then 22669 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CODESIGN= (no value)" >&5 22670 $as_echo "$as_me: Setting user supplied tool CODESIGN= (no value)" >&6;} 22671 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CODESIGN" >&5 22672 $as_echo_n "checking for CODESIGN... " >&6; } 22673 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 22674 $as_echo "disabled" >&6; } 22675 else 22676 # Check if the provided tool contains a complete path. 22677 tool_specified="$CODESIGN" 22678 tool_basename="${tool_specified##*/}" 22679 if test "x$tool_basename" = "x$tool_specified"; then 22680 # A command without a complete path is provided, search $PATH. 22681 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CODESIGN=$tool_basename" >&5 22682 $as_echo "$as_me: Will search for user supplied tool CODESIGN=$tool_basename" >&6;} 22683 # Extract the first word of "$tool_basename", so it can be a program name with args. 22684 set dummy $tool_basename; ac_word=$2 22685 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22686 $as_echo_n "checking for $ac_word... " >&6; } 22687 if ${ac_cv_path_CODESIGN+:} false; then : 22688 $as_echo_n "(cached) " >&6 22689 else 22690 case $CODESIGN in 22691 [\\/]* | ?:[\\/]*) 22692 ac_cv_path_CODESIGN="$CODESIGN" # Let the user override the test with a path. 22693 ;; 22694 *) 22695 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22696 for as_dir in $PATH 22697 do 22698 IFS=$as_save_IFS 22699 test -z "$as_dir" && as_dir=. 22700 for ac_exec_ext in '' $ac_executable_extensions; do 22701 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22702 ac_cv_path_CODESIGN="$as_dir/$ac_word$ac_exec_ext" 22703 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22704 break 2 22705 fi 22706 done 22707 done 22708 IFS=$as_save_IFS 22709 22710 ;; 22711 esac 22712 fi 22713 CODESIGN=$ac_cv_path_CODESIGN 22714 if test -n "$CODESIGN"; then 22715 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CODESIGN" >&5 22716 $as_echo "$CODESIGN" >&6; } 22717 else 22718 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22719 $as_echo "no" >&6; } 22720 fi 22721 22722 22723 if test "x$CODESIGN" = x; then 22724 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 22725 fi 22726 else 22727 # Otherwise we believe it is a complete path. Use it as it is. 22728 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CODESIGN=$tool_specified" >&5 22729 $as_echo "$as_me: Will use user supplied tool CODESIGN=$tool_specified" >&6;} 22730 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CODESIGN" >&5 22731 $as_echo_n "checking for CODESIGN... " >&6; } 22732 if test ! -x "$tool_specified"; then 22733 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 22734 $as_echo "not found" >&6; } 22735 as_fn_error $? "User supplied tool CODESIGN=$tool_specified does not exist or is not executable" "$LINENO" 5 22736 fi 22737 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 22738 $as_echo "$tool_specified" >&6; } 22739 fi 22740 fi 22741 fi 22742 22743 fi 22744 22745 22746 if test "x$CODESIGN" != "x"; then 22747 # Verify that the openjdk_codesign certificate is present 22748 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if openjdk_codesign certificate is present" >&5 22749 $as_echo_n "checking if openjdk_codesign certificate is present... " >&6; } 22750 rm -f codesign-testfile 22751 touch codesign-testfile 22752 codesign -s openjdk_codesign codesign-testfile 2>&5 >&5 || CODESIGN= 22753 rm -f codesign-testfile 22754 if test "x$CODESIGN" = x; then 22755 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22756 $as_echo "no" >&6; } 22757 else 22758 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 22759 $as_echo "yes" >&6; } 22760 fi 22761 fi 22762 22763 22764 22765 # Publish this variable in the help. 22766 22767 22768 if [ -z "${SETFILE+x}" ]; then 22769 # The variable is not set by user, try to locate tool using the code snippet 22770 for ac_prog in SetFile 22771 do 22772 # Extract the first word of "$ac_prog", so it can be a program name with args. 22773 set dummy $ac_prog; ac_word=$2 22774 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22775 $as_echo_n "checking for $ac_word... " >&6; } 22776 if ${ac_cv_path_SETFILE+:} false; then : 22777 $as_echo_n "(cached) " >&6 22778 else 22779 case $SETFILE in 22780 [\\/]* | ?:[\\/]*) 22781 ac_cv_path_SETFILE="$SETFILE" # Let the user override the test with a path. 22782 ;; 22783 *) 22784 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22785 for as_dir in $PATH 22786 do 22787 IFS=$as_save_IFS 22788 test -z "$as_dir" && as_dir=. 22789 for ac_exec_ext in '' $ac_executable_extensions; do 22790 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22791 ac_cv_path_SETFILE="$as_dir/$ac_word$ac_exec_ext" 22792 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22793 break 2 22794 fi 22795 done 22796 done 22797 IFS=$as_save_IFS 22798 22799 ;; 22800 esac 22801 fi 22802 SETFILE=$ac_cv_path_SETFILE 22803 if test -n "$SETFILE"; then 22804 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SETFILE" >&5 22805 $as_echo "$SETFILE" >&6; } 22806 else 22807 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22808 $as_echo "no" >&6; } 22809 fi 22810 22811 22812 test -n "$SETFILE" && break 22813 done 22814 22815 else 22816 # The variable is set, but is it from the command line or the environment? 22817 22818 # Try to remove the string !SETFILE! from our list. 22819 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!SETFILE!/} 22820 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 22821 # If it failed, the variable was not from the command line. Ignore it, 22822 # but warn the user (except for BASH, which is always set by the calling BASH). 22823 if test "xSETFILE" != xBASH; then 22824 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of SETFILE from the environment. Use command line variables instead." >&5 22825 $as_echo "$as_me: WARNING: Ignoring value of SETFILE from the environment. Use command line variables instead." >&2;} 22826 fi 22827 # Try to locate tool using the code snippet 22828 for ac_prog in SetFile 22829 do 22830 # Extract the first word of "$ac_prog", so it can be a program name with args. 22831 set dummy $ac_prog; ac_word=$2 22832 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22833 $as_echo_n "checking for $ac_word... " >&6; } 22834 if ${ac_cv_path_SETFILE+:} false; then : 22835 $as_echo_n "(cached) " >&6 22836 else 22837 case $SETFILE in 22838 [\\/]* | ?:[\\/]*) 22839 ac_cv_path_SETFILE="$SETFILE" # Let the user override the test with a path. 22840 ;; 22841 *) 22842 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22843 for as_dir in $PATH 22844 do 22845 IFS=$as_save_IFS 22846 test -z "$as_dir" && as_dir=. 22847 for ac_exec_ext in '' $ac_executable_extensions; do 22848 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22849 ac_cv_path_SETFILE="$as_dir/$ac_word$ac_exec_ext" 22850 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22851 break 2 22852 fi 22853 done 22854 done 22855 IFS=$as_save_IFS 22856 22857 ;; 22858 esac 22859 fi 22860 SETFILE=$ac_cv_path_SETFILE 22861 if test -n "$SETFILE"; then 22862 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SETFILE" >&5 22863 $as_echo "$SETFILE" >&6; } 22864 else 22865 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22866 $as_echo "no" >&6; } 22867 fi 22868 22869 22870 test -n "$SETFILE" && break 22871 done 22872 22873 else 22874 # If it succeeded, then it was overridden by the user. We will use it 22875 # for the tool. 22876 22877 # First remove it from the list of overridden variables, so we can test 22878 # for unknown variables in the end. 22879 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 22880 22881 # Check if we try to supply an empty value 22882 if test "x$SETFILE" = x; then 22883 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool SETFILE= (no value)" >&5 22884 $as_echo "$as_me: Setting user supplied tool SETFILE= (no value)" >&6;} 22885 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SETFILE" >&5 22886 $as_echo_n "checking for SETFILE... " >&6; } 22887 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 22888 $as_echo "disabled" >&6; } 22889 else 22890 # Check if the provided tool contains a complete path. 22891 tool_specified="$SETFILE" 22892 tool_basename="${tool_specified##*/}" 22893 if test "x$tool_basename" = "x$tool_specified"; then 22894 # A command without a complete path is provided, search $PATH. 22895 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool SETFILE=$tool_basename" >&5 22896 $as_echo "$as_me: Will search for user supplied tool SETFILE=$tool_basename" >&6;} 22897 # Extract the first word of "$tool_basename", so it can be a program name with args. 22898 set dummy $tool_basename; ac_word=$2 22899 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 22900 $as_echo_n "checking for $ac_word... " >&6; } 22901 if ${ac_cv_path_SETFILE+:} false; then : 22902 $as_echo_n "(cached) " >&6 22903 else 22904 case $SETFILE in 22905 [\\/]* | ?:[\\/]*) 22906 ac_cv_path_SETFILE="$SETFILE" # Let the user override the test with a path. 22907 ;; 22908 *) 22909 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 22910 for as_dir in $PATH 22911 do 22912 IFS=$as_save_IFS 22913 test -z "$as_dir" && as_dir=. 22914 for ac_exec_ext in '' $ac_executable_extensions; do 22915 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 22916 ac_cv_path_SETFILE="$as_dir/$ac_word$ac_exec_ext" 22917 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 22918 break 2 22919 fi 22920 done 22921 done 22922 IFS=$as_save_IFS 22923 22924 ;; 22925 esac 22926 fi 22927 SETFILE=$ac_cv_path_SETFILE 22928 if test -n "$SETFILE"; then 22929 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SETFILE" >&5 22930 $as_echo "$SETFILE" >&6; } 22931 else 22932 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22933 $as_echo "no" >&6; } 22934 fi 22935 22936 22937 if test "x$SETFILE" = x; then 22938 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 22939 fi 22940 else 22941 # Otherwise we believe it is a complete path. Use it as it is. 22942 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool SETFILE=$tool_specified" >&5 22943 $as_echo "$as_me: Will use user supplied tool SETFILE=$tool_specified" >&6;} 22944 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for SETFILE" >&5 22945 $as_echo_n "checking for SETFILE... " >&6; } 22946 if test ! -x "$tool_specified"; then 22947 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 22948 $as_echo "not found" >&6; } 22949 as_fn_error $? "User supplied tool SETFILE=$tool_specified does not exist or is not executable" "$LINENO" 5 22950 fi 22951 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 22952 $as_echo "$tool_specified" >&6; } 22953 fi 22954 fi 22955 fi 22956 22957 fi 22958 22959 22960 22961 if test "x$SETFILE" = x; then 22962 as_fn_error $? "Could not find required tool for SETFILE" "$LINENO" 5 22963 fi 22964 22965 22966 fi 22967 22968 22969 # Test if bash supports pipefail. 22970 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if bash supports pipefail" >&5 22971 $as_echo_n "checking if bash supports pipefail... " >&6; } 22972 if ${BASH} -c 'set -o pipefail'; then 22973 BASH_ARGS="$BASH_ARGS -o pipefail" 22974 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 22975 $as_echo "yes" >&6; } 22976 else 22977 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22978 $as_echo "no" >&6; } 22979 fi 22980 22981 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if bash supports errexit (-e)" >&5 22982 $as_echo_n "checking if bash supports errexit (-e)... " >&6; } 22983 if ${BASH} -e -c 'true'; then 22984 BASH_ARGS="$BASH_ARGS -e" 22985 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 22986 $as_echo "yes" >&6; } 22987 else 22988 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 22989 $as_echo "no" >&6; } 22990 fi 22991 22992 22993 22994 22995 # Check if pkg-config is available. 22996 22997 22998 if test "x$ac_cv_env_PKG_CONFIG_set" != "xset"; then 22999 if test -n "$ac_tool_prefix"; then 23000 # Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args. 23001 set dummy ${ac_tool_prefix}pkg-config; ac_word=$2 23002 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23003 $as_echo_n "checking for $ac_word... " >&6; } 23004 if ${ac_cv_path_PKG_CONFIG+:} false; then : 23005 $as_echo_n "(cached) " >&6 23006 else 23007 case $PKG_CONFIG in 23008 [\\/]* | ?:[\\/]*) 23009 ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path. 23010 ;; 23011 *) 23012 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23013 for as_dir in $PATH 23014 do 23015 IFS=$as_save_IFS 23016 test -z "$as_dir" && as_dir=. 23017 for ac_exec_ext in '' $ac_executable_extensions; do 23018 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23019 ac_cv_path_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" 23020 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23021 break 2 23022 fi 23023 done 23024 done 23025 IFS=$as_save_IFS 23026 23027 ;; 23028 esac 23029 fi 23030 PKG_CONFIG=$ac_cv_path_PKG_CONFIG 23031 if test -n "$PKG_CONFIG"; then 23032 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5 23033 $as_echo "$PKG_CONFIG" >&6; } 23034 else 23035 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23036 $as_echo "no" >&6; } 23037 fi 23038 23039 23040 fi 23041 if test -z "$ac_cv_path_PKG_CONFIG"; then 23042 ac_pt_PKG_CONFIG=$PKG_CONFIG 23043 # Extract the first word of "pkg-config", so it can be a program name with args. 23044 set dummy pkg-config; ac_word=$2 23045 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 23046 $as_echo_n "checking for $ac_word... " >&6; } 23047 if ${ac_cv_path_ac_pt_PKG_CONFIG+:} false; then : 23048 $as_echo_n "(cached) " >&6 23049 else 23050 case $ac_pt_PKG_CONFIG in 23051 [\\/]* | ?:[\\/]*) 23052 ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path. 23053 ;; 23054 *) 23055 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 23056 for as_dir in $PATH 23057 do 23058 IFS=$as_save_IFS 23059 test -z "$as_dir" && as_dir=. 23060 for ac_exec_ext in '' $ac_executable_extensions; do 23061 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 23062 ac_cv_path_ac_pt_PKG_CONFIG="$as_dir/$ac_word$ac_exec_ext" 23063 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 23064 break 2 23065 fi 23066 done 23067 done 23068 IFS=$as_save_IFS 23069 23070 ;; 23071 esac 23072 fi 23073 ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG 23074 if test -n "$ac_pt_PKG_CONFIG"; then 23075 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5 23076 $as_echo "$ac_pt_PKG_CONFIG" >&6; } 23077 else 23078 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23079 $as_echo "no" >&6; } 23080 fi 23081 23082 if test "x$ac_pt_PKG_CONFIG" = x; then 23083 PKG_CONFIG="" 23084 else 23085 case $cross_compiling:$ac_tool_warned in 23086 yes:) 23087 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 23088 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 23089 ac_tool_warned=yes ;; 23090 esac 23091 PKG_CONFIG=$ac_pt_PKG_CONFIG 23092 fi 23093 else 23094 PKG_CONFIG="$ac_cv_path_PKG_CONFIG" 23095 fi 23096 23097 fi 23098 if test -n "$PKG_CONFIG"; then 23099 _pkg_min_version=0.9.0 23100 { $as_echo "$as_me:${as_lineno-$LINENO}: checking pkg-config is at least version $_pkg_min_version" >&5 23101 $as_echo_n "checking pkg-config is at least version $_pkg_min_version... " >&6; } 23102 if $PKG_CONFIG --atleast-pkgconfig-version $_pkg_min_version; then 23103 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 23104 $as_echo "yes" >&6; } 23105 else 23106 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 23107 $as_echo "no" >&6; } 23108 PKG_CONFIG="" 23109 fi 23110 23111 fi 23112 23113 # After basic tools have been setup, we can check build os specific details. 23114 23115 ############################################################################### 23116 23117 # Note that this is the build platform OS version! 23118 23119 OS_VERSION="`uname -r | ${SED} 's!\.! !g' | ${SED} 's!-! !g'`" 23120 OS_VERSION_MAJOR="`${ECHO} ${OS_VERSION} | ${CUT} -f 1 -d ' '`" 23121 OS_VERSION_MINOR="`${ECHO} ${OS_VERSION} | ${CUT} -f 2 -d ' '`" 23122 OS_VERSION_MICRO="`${ECHO} ${OS_VERSION} | ${CUT} -f 3 -d ' '`" 23123 23124 23125 23126 23127 23128 # Misc basic settings 23129 23130 23131 # Check whether --with-default-make-target was given. 23132 if test "${with_default_make_target+set}" = set; then : 23133 withval=$with_default_make_target; 23134 fi 23135 23136 if test "x$with_default_make_target" = "x" \ 23137 || test "x$with_default_make_target" = "xyes"; then 23138 DEFAULT_MAKE_TARGET="exploded-image" 23139 elif test "x$with_default_make_target" = "xno"; then 23140 as_fn_error $? "--without-default-make-target is not a valid option" "$LINENO" 5 23141 else 23142 DEFAULT_MAKE_TARGET="$with_default_make_target" 23143 fi 23144 23145 23146 23147 23148 ############################################################################### 23149 # 23150 # Determine OpenJDK variants, options and version numbers. 23151 # 23152 ############################################################################### 23153 23154 # We need build & target for this. 23155 23156 # Should we build a JDK/JVM with headful support (ie a graphical ui)? 23157 # We always build headless support. 23158 { $as_echo "$as_me:${as_lineno-$LINENO}: checking headful support" >&5 23159 $as_echo_n "checking headful support... " >&6; } 23160 # Check whether --enable-headful was given. 23161 if test "${enable_headful+set}" = set; then : 23162 enableval=$enable_headful; SUPPORT_HEADFUL=${enable_headful} 23163 else 23164 SUPPORT_HEADFUL=yes 23165 fi 23166 23167 23168 SUPPORT_HEADLESS=yes 23169 BUILD_HEADLESS="BUILD_HEADLESS:=true" 23170 23171 if test "x$SUPPORT_HEADFUL" = xyes; then 23172 # We are building both headful and headless. 23173 headful_msg="include support for both headful and headless" 23174 fi 23175 23176 if test "x$SUPPORT_HEADFUL" = xno; then 23177 # Thus we are building headless only. 23178 BUILD_HEADLESS="BUILD_HEADLESS:=true" 23179 headful_msg="headless only" 23180 fi 23181 23182 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $headful_msg" >&5 23183 $as_echo "$headful_msg" >&6; } 23184 23185 23186 23187 23188 23189 # Choose cacerts source file 23190 23191 # Check whether --with-cacerts-file was given. 23192 if test "${with_cacerts_file+set}" = set; then : 23193 withval=$with_cacerts_file; 23194 fi 23195 23196 if test "x$with_cacerts_file" != x; then 23197 CACERTS_FILE=$with_cacerts_file 23198 fi 23199 23200 23201 # Enable or disable unlimited crypto 23202 # Check whether --enable-unlimited-crypto was given. 23203 if test "${enable_unlimited_crypto+set}" = set; then : 23204 enableval=$enable_unlimited_crypto; 23205 else 23206 enable_unlimited_crypto=no 23207 fi 23208 23209 if test "x$enable_unlimited_crypto" = "xyes"; then 23210 UNLIMITED_CRYPTO=true 23211 else 23212 UNLIMITED_CRYPTO=false 23213 fi 23214 23215 23216 # Compress jars 23217 COMPRESS_JARS=false 23218 23219 23220 23221 # Setup default copyright year. Mostly overridden when building close to a new year. 23222 23223 # Check whether --with-copyright-year was given. 23224 if test "${with_copyright_year+set}" = set; then : 23225 withval=$with_copyright_year; 23226 fi 23227 23228 if test "x$with_copyright_year" = xyes; then 23229 as_fn_error $? "Copyright year must have a value" "$LINENO" 5 23230 elif test "x$with_copyright_year" != x; then 23231 COPYRIGHT_YEAR="$with_copyright_year" 23232 else 23233 COPYRIGHT_YEAR=`date +'%Y'` 23234 fi 23235 23236 23237 23238 # Control wether Hotspot runs Queens test after build. 23239 # Check whether --enable-hotspot-test-in-build was given. 23240 if test "${enable_hotspot_test_in_build+set}" = set; then : 23241 enableval=$enable_hotspot_test_in_build; 23242 else 23243 enable_hotspot_test_in_build=no 23244 fi 23245 23246 if test "x$enable_hotspot_test_in_build" = "xyes"; then 23247 TEST_IN_BUILD=true 23248 else 23249 TEST_IN_BUILD=false 23250 fi 23251 23252 23253 23254 # Warn user that old version arguments are deprecated. 23255 23256 23257 # Check whether --with-milestone was given. 23258 if test "${with_milestone+set}" = set; then : 23259 withval=$with_milestone; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-milestone is deprecated and will be ignored." >&5 23260 $as_echo "$as_me: WARNING: Option --with-milestone is deprecated and will be ignored." >&2;} 23261 fi 23262 23263 23264 23265 23266 # Check whether --with-update-version was given. 23267 if test "${with_update_version+set}" = set; then : 23268 withval=$with_update_version; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-update-version is deprecated and will be ignored." >&5 23269 $as_echo "$as_me: WARNING: Option --with-update-version is deprecated and will be ignored." >&2;} 23270 fi 23271 23272 23273 23274 23275 # Check whether --with-user-release-suffix was given. 23276 if test "${with_user_release_suffix+set}" = set; then : 23277 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 23278 $as_echo "$as_me: WARNING: Option --with-user-release-suffix is deprecated and will be ignored." >&2;} 23279 fi 23280 23281 23282 23283 23284 # Check whether --with-build-number was given. 23285 if test "${with_build_number+set}" = set; then : 23286 withval=$with_build_number; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-build-number is deprecated and will be ignored." >&5 23287 $as_echo "$as_me: WARNING: Option --with-build-number is deprecated and will be ignored." >&2;} 23288 fi 23289 23290 23291 23292 # Source the version numbers file 23293 . $AUTOCONF_DIR/version-numbers 23294 23295 # Some non-version number information is set in that file 23296 23297 23298 23299 23300 23301 23302 23303 23304 # Override version from arguments 23305 23306 # If --with-version-string is set, process it first. It is possible to 23307 # override parts with more specific flags, since these are processed later. 23308 23309 # Check whether --with-version-string was given. 23310 if test "${with_version_string+set}" = set; then : 23311 withval=$with_version_string; 23312 fi 23313 23314 if test "x$with_version_string" = xyes; then 23315 as_fn_error $? "--with-version-string must have a value" "$LINENO" 5 23316 elif test "x$with_version_string" != x; then 23317 # Additional [] needed to keep m4 from mangling shell constructs. 23318 if [[ $with_version_string =~ ^([0-9]+)(\.([0-9]+))?(\.([0-9]+))?(\.([0-9]+))?(-([a-zA-Z]+))?((\+)([0-9]+)?(-([-a-zA-Z0-9.]+))?)?$ ]] ; then 23319 VERSION_MAJOR=${BASH_REMATCH[1]} 23320 VERSION_MINOR=${BASH_REMATCH[3]} 23321 VERSION_SECURITY=${BASH_REMATCH[5]} 23322 VERSION_PATCH=${BASH_REMATCH[7]} 23323 VERSION_PRE=${BASH_REMATCH[9]} 23324 version_plus_separator=${BASH_REMATCH[11]} 23325 VERSION_BUILD=${BASH_REMATCH[12]} 23326 VERSION_OPT=${BASH_REMATCH[14]} 23327 # Unspecified numerical fields are interpreted as 0. 23328 if test "x$VERSION_MINOR" = x; then 23329 VERSION_MINOR=0 23330 fi 23331 if test "x$VERSION_SECURITY" = x; then 23332 VERSION_SECURITY=0 23333 fi 23334 if test "x$VERSION_PATCH" = x; then 23335 VERSION_PATCH=0 23336 fi 23337 if test "x$version_plus_separator" != x \ 23338 && test "x$VERSION_BUILD$VERSION_OPT" = x; then 23339 as_fn_error $? "Version string contains + but both 'BUILD' and 'OPT' are missing" "$LINENO" 5 23340 fi 23341 # Stop the version part process from setting default values. 23342 # We still allow them to explicitely override though. 23343 NO_DEFAULT_VERSION_PARTS=true 23344 else 23345 as_fn_error $? "--with-version-string fails to parse as a valid version string: $with_version_string" "$LINENO" 5 23346 fi 23347 fi 23348 23349 23350 # Check whether --with-version-pre was given. 23351 if test "${with_version_pre+set}" = set; then : 23352 withval=$with_version_pre; with_version_pre_present=true 23353 else 23354 with_version_pre_present=false 23355 fi 23356 23357 23358 if test "x$with_version_pre_present" = xtrue; then 23359 if test "x$with_version_pre" = xyes; then 23360 as_fn_error $? "--with-version-pre must have a value" "$LINENO" 5 23361 elif test "x$with_version_pre" = xno; then 23362 # Interpret --without-* as empty string instead of the literal "no" 23363 VERSION_PRE= 23364 else 23365 # Only [a-zA-Z] is allowed in the VERSION_PRE. Outer [ ] to quote m4. 23366 VERSION_PRE=`$ECHO "$with_version_pre" | $TR -c -d '[a-z][A-Z]'` 23367 if test "x$VERSION_PRE" != "x$with_version_pre"; then 23368 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-version-pre value has been sanitized from '$with_version_pre' to '$VERSION_PRE'" >&5 23369 $as_echo "$as_me: WARNING: --with-version-pre value has been sanitized from '$with_version_pre' to '$VERSION_PRE'" >&2;} 23370 fi 23371 fi 23372 else 23373 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 23374 # Default is to use "internal" as pre 23375 VERSION_PRE="internal" 23376 fi 23377 fi 23378 23379 23380 # Check whether --with-version-opt was given. 23381 if test "${with_version_opt+set}" = set; then : 23382 withval=$with_version_opt; with_version_opt_present=true 23383 else 23384 with_version_opt_present=false 23385 fi 23386 23387 23388 if test "x$with_version_opt_present" = xtrue; then 23389 if test "x$with_version_opt" = xyes; then 23390 as_fn_error $? "--with-version-opt must have a value" "$LINENO" 5 23391 elif test "x$with_version_opt" = xno; then 23392 # Interpret --without-* as empty string instead of the literal "no" 23393 VERSION_OPT= 23394 else 23395 # Only [-.a-zA-Z0-9] is allowed in the VERSION_OPT. Outer [ ] to quote m4. 23396 VERSION_OPT=`$ECHO "$with_version_opt" | $TR -c -d '[a-z][A-Z][0-9].-'` 23397 if test "x$VERSION_OPT" != "x$with_version_opt"; then 23398 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-version-opt value has been sanitized from '$with_version_opt' to '$VERSION_OPT'" >&5 23399 $as_echo "$as_me: WARNING: --with-version-opt value has been sanitized from '$with_version_opt' to '$VERSION_OPT'" >&2;} 23400 fi 23401 fi 23402 else 23403 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 23404 # Default is to calculate a string like this <timestamp>.<username>.<base dir name> 23405 timestamp=`$DATE '+%Y-%m-%d-%H%M%S'` 23406 # Outer [ ] to quote m4. 23407 username=`$ECHO "$USER" | $TR -d -c '[a-z][A-Z][0-9]'` 23408 basedirname=`$BASENAME "$TOPDIR" | $TR -d -c '[a-z][A-Z][0-9].-'` 23409 VERSION_OPT="$timestamp.$username.$basedirname" 23410 fi 23411 fi 23412 23413 23414 # Check whether --with-version-build was given. 23415 if test "${with_version_build+set}" = set; then : 23416 withval=$with_version_build; with_version_build_present=true 23417 else 23418 with_version_build_present=false 23419 fi 23420 23421 23422 if test "x$with_version_build_present" = xtrue; then 23423 if test "x$with_version_build" = xyes; then 23424 as_fn_error $? "--with-version-build must have a value" "$LINENO" 5 23425 elif test "x$with_version_build" = xno; then 23426 # Interpret --without-* as empty string instead of the literal "no" 23427 VERSION_BUILD= 23428 elif test "x$with_version_build" = x; then 23429 VERSION_BUILD= 23430 else 23431 23432 # Additional [] needed to keep m4 from mangling shell constructs. 23433 if ! [[ "$with_version_build" =~ ^0*([1-9][0-9]*)|(0)$ ]] ; then 23434 as_fn_error $? "\"$with_version_build\" is not a valid numerical value for VERSION_BUILD" "$LINENO" 5 23435 fi 23436 # Extract the version number without leading zeros. 23437 cleaned_value=${BASH_REMATCH[1]} 23438 if test "x$cleaned_value" = x; then 23439 # Special case for zero 23440 cleaned_value=${BASH_REMATCH[2]} 23441 fi 23442 23443 if test $cleaned_value -gt 255; then 23444 as_fn_error $? "VERSION_BUILD is given as $with_version_build. This is greater than 255 which is not allowed." "$LINENO" 5 23445 fi 23446 if test "x$cleaned_value" != "x$with_version_build"; then 23447 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Value for VERSION_BUILD has been sanitized from '$with_version_build' to '$cleaned_value'" >&5 23448 $as_echo "$as_me: WARNING: Value for VERSION_BUILD has been sanitized from '$with_version_build' to '$cleaned_value'" >&2;} 23449 fi 23450 VERSION_BUILD=$cleaned_value 23451 23452 fi 23453 else 23454 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 23455 # Default is to not have a build number. 23456 VERSION_BUILD="" 23457 # FIXME: Until all code can cope with an empty VERSION_BUILD, set it to 0. 23458 VERSION_BUILD=0 23459 fi 23460 fi 23461 23462 23463 # Check whether --with-version-major was given. 23464 if test "${with_version_major+set}" = set; then : 23465 withval=$with_version_major; with_version_major_present=true 23466 else 23467 with_version_major_present=false 23468 fi 23469 23470 23471 if test "x$with_version_major_present" = xtrue; then 23472 if test "x$with_version_major" = xyes; then 23473 as_fn_error $? "--with-version-major must have a value" "$LINENO" 5 23474 else 23475 23476 # Additional [] needed to keep m4 from mangling shell constructs. 23477 if ! [[ "$with_version_major" =~ ^0*([1-9][0-9]*)|(0)$ ]] ; then 23478 as_fn_error $? "\"$with_version_major\" is not a valid numerical value for VERSION_MAJOR" "$LINENO" 5 23479 fi 23480 # Extract the version number without leading zeros. 23481 cleaned_value=${BASH_REMATCH[1]} 23482 if test "x$cleaned_value" = x; then 23483 # Special case for zero 23484 cleaned_value=${BASH_REMATCH[2]} 23485 fi 23486 23487 if test $cleaned_value -gt 255; then 23488 as_fn_error $? "VERSION_MAJOR is given as $with_version_major. This is greater than 255 which is not allowed." "$LINENO" 5 23489 fi 23490 if test "x$cleaned_value" != "x$with_version_major"; then 23491 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Value for VERSION_MAJOR has been sanitized from '$with_version_major' to '$cleaned_value'" >&5 23492 $as_echo "$as_me: WARNING: Value for VERSION_MAJOR has been sanitized from '$with_version_major' to '$cleaned_value'" >&2;} 23493 fi 23494 VERSION_MAJOR=$cleaned_value 23495 23496 fi 23497 else 23498 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 23499 # Default is to get value from version-numbers 23500 VERSION_MAJOR="$DEFAULT_VERSION_MAJOR" 23501 fi 23502 fi 23503 23504 23505 # Check whether --with-version-minor was given. 23506 if test "${with_version_minor+set}" = set; then : 23507 withval=$with_version_minor; with_version_minor_present=true 23508 else 23509 with_version_minor_present=false 23510 fi 23511 23512 23513 if test "x$with_version_minor_present" = xtrue; then 23514 if test "x$with_version_minor" = xyes; then 23515 as_fn_error $? "--with-version-minor must have a value" "$LINENO" 5 23516 elif test "x$with_version_minor" = xno; then 23517 # Interpret --without-* as empty string (i.e. 0) instead of the literal "no" 23518 VERSION_MINOR=0 23519 elif test "x$with_version_minor" = x; then 23520 VERSION_MINOR=0 23521 else 23522 23523 # Additional [] needed to keep m4 from mangling shell constructs. 23524 if ! [[ "$with_version_minor" =~ ^0*([1-9][0-9]*)|(0)$ ]] ; then 23525 as_fn_error $? "\"$with_version_minor\" is not a valid numerical value for VERSION_MINOR" "$LINENO" 5 23526 fi 23527 # Extract the version number without leading zeros. 23528 cleaned_value=${BASH_REMATCH[1]} 23529 if test "x$cleaned_value" = x; then 23530 # Special case for zero 23531 cleaned_value=${BASH_REMATCH[2]} 23532 fi 23533 23534 if test $cleaned_value -gt 255; then 23535 as_fn_error $? "VERSION_MINOR is given as $with_version_minor. This is greater than 255 which is not allowed." "$LINENO" 5 23536 fi 23537 if test "x$cleaned_value" != "x$with_version_minor"; then 23538 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Value for VERSION_MINOR has been sanitized from '$with_version_minor' to '$cleaned_value'" >&5 23539 $as_echo "$as_me: WARNING: Value for VERSION_MINOR has been sanitized from '$with_version_minor' to '$cleaned_value'" >&2;} 23540 fi 23541 VERSION_MINOR=$cleaned_value 23542 23543 fi 23544 else 23545 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 23546 # Default is 0, if unspecified 23547 VERSION_MINOR=0 23548 fi 23549 fi 23550 23551 23552 # Check whether --with-version-security was given. 23553 if test "${with_version_security+set}" = set; then : 23554 withval=$with_version_security; with_version_security_present=true 23555 else 23556 with_version_security_present=false 23557 fi 23558 23559 23560 if test "x$with_version_security_present" = xtrue; then 23561 if test "x$with_version_security" = xyes; then 23562 as_fn_error $? "--with-version-security must have a value" "$LINENO" 5 23563 elif test "x$with_version_security" = xno; then 23564 # Interpret --without-* as empty string (i.e. 0) instead of the literal "no" 23565 VERSION_SECURITY=0 23566 elif test "x$with_version_security" = x; then 23567 VERSION_SECURITY=0 23568 else 23569 23570 # Additional [] needed to keep m4 from mangling shell constructs. 23571 if ! [[ "$with_version_security" =~ ^0*([1-9][0-9]*)|(0)$ ]] ; then 23572 as_fn_error $? "\"$with_version_security\" is not a valid numerical value for VERSION_SECURITY" "$LINENO" 5 23573 fi 23574 # Extract the version number without leading zeros. 23575 cleaned_value=${BASH_REMATCH[1]} 23576 if test "x$cleaned_value" = x; then 23577 # Special case for zero 23578 cleaned_value=${BASH_REMATCH[2]} 23579 fi 23580 23581 if test $cleaned_value -gt 255; then 23582 as_fn_error $? "VERSION_SECURITY is given as $with_version_security. This is greater than 255 which is not allowed." "$LINENO" 5 23583 fi 23584 if test "x$cleaned_value" != "x$with_version_security"; then 23585 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Value for VERSION_SECURITY has been sanitized from '$with_version_security' to '$cleaned_value'" >&5 23586 $as_echo "$as_me: WARNING: Value for VERSION_SECURITY has been sanitized from '$with_version_security' to '$cleaned_value'" >&2;} 23587 fi 23588 VERSION_SECURITY=$cleaned_value 23589 23590 fi 23591 else 23592 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 23593 # Default is 0, if unspecified 23594 VERSION_SECURITY=0 23595 fi 23596 fi 23597 23598 23599 # Check whether --with-version-patch was given. 23600 if test "${with_version_patch+set}" = set; then : 23601 withval=$with_version_patch; with_version_patch_present=true 23602 else 23603 with_version_patch_present=false 23604 fi 23605 23606 23607 if test "x$with_version_patch_present" = xtrue; then 23608 if test "x$with_version_patch" = xyes; then 23609 as_fn_error $? "--with-version-patch must have a value" "$LINENO" 5 23610 elif test "x$with_version_patch" = xno; then 23611 # Interpret --without-* as empty string (i.e. 0) instead of the literal "no" 23612 VERSION_PATCH=0 23613 elif test "x$with_version_patch" = x; then 23614 VERSION_PATCH=0 23615 else 23616 23617 # Additional [] needed to keep m4 from mangling shell constructs. 23618 if ! [[ "$with_version_patch" =~ ^0*([1-9][0-9]*)|(0)$ ]] ; then 23619 as_fn_error $? "\"$with_version_patch\" is not a valid numerical value for VERSION_PATCH" "$LINENO" 5 23620 fi 23621 # Extract the version number without leading zeros. 23622 cleaned_value=${BASH_REMATCH[1]} 23623 if test "x$cleaned_value" = x; then 23624 # Special case for zero 23625 cleaned_value=${BASH_REMATCH[2]} 23626 fi 23627 23628 if test $cleaned_value -gt 255; then 23629 as_fn_error $? "VERSION_PATCH is given as $with_version_patch. This is greater than 255 which is not allowed." "$LINENO" 5 23630 fi 23631 if test "x$cleaned_value" != "x$with_version_patch"; then 23632 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Value for VERSION_PATCH has been sanitized from '$with_version_patch' to '$cleaned_value'" >&5 23633 $as_echo "$as_me: WARNING: Value for VERSION_PATCH has been sanitized from '$with_version_patch' to '$cleaned_value'" >&2;} 23634 fi 23635 VERSION_PATCH=$cleaned_value 23636 23637 fi 23638 else 23639 if test "x$NO_DEFAULT_VERSION_PARTS" != xtrue; then 23640 # Default is 0, if unspecified 23641 VERSION_PATCH=0 23642 fi 23643 fi 23644 23645 # Calculate derived version properties 23646 23647 # Set VERSION_IS_GA based on if VERSION_PRE has a value 23648 if test "x$VERSION_PRE" = x; then 23649 VERSION_IS_GA=true 23650 else 23651 VERSION_IS_GA=false 23652 fi 23653 23654 # VERSION_NUMBER but always with exactly 4 positions, with 0 for empty positions. 23655 VERSION_NUMBER_FOUR_POSITIONS=$VERSION_MAJOR.$VERSION_MINOR.$VERSION_SECURITY.$VERSION_PATCH 23656 23657 stripped_version_number=$VERSION_NUMBER_FOUR_POSITIONS 23658 # Strip trailing zeroes from stripped_version_number 23659 for i in 1 2 3 ; do stripped_version_number=${stripped_version_number%.0} ; done 23660 VERSION_NUMBER=$stripped_version_number 23661 23662 # The complete version string, with additional build information 23663 if test "x$VERSION_BUILD$VERSION_OPT" = x; then 23664 VERSION_STRING=$VERSION_NUMBER${VERSION_PRE:+-$VERSION_PRE} 23665 else 23666 # If either build or opt is set, we need a + separator 23667 VERSION_STRING=$VERSION_NUMBER${VERSION_PRE:+-$VERSION_PRE}+$VERSION_BUILD${VERSION_OPT:+-$VERSION_OPT} 23668 fi 23669 23670 # The short version string, just VERSION_NUMBER and PRE, if present. 23671 VERSION_SHORT=$VERSION_NUMBER${VERSION_PRE:+-$VERSION_PRE} 23672 23673 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for version string" >&5 23674 $as_echo_n "checking for version string... " >&6; } 23675 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $VERSION_STRING" >&5 23676 $as_echo "$VERSION_STRING" >&6; } 23677 23678 23679 23680 23681 23682 23683 23684 23685 23686 23687 23688 23689 23690 23691 23692 ############################################################################### 23693 # 23694 # Setup BootJDK, used to bootstrap the build. 23695 # 23696 ############################################################################### 23697 23698 23699 BOOT_JDK_FOUND=no 23700 23701 # Check whether --with-boot-jdk was given. 23702 if test "${with_boot_jdk+set}" = set; then : 23703 withval=$with_boot_jdk; 23704 fi 23705 23706 23707 # We look for the Boot JDK through various means, going from more certain to 23708 # more of a guess-work. After each test, BOOT_JDK_FOUND is set to "yes" if 23709 # we detected something (if so, the path to the jdk is in BOOT_JDK). But we 23710 # must check if this is indeed valid; otherwise we'll continue looking. 23711 23712 # Test: Is bootjdk explicitely set by command line arguments? 23713 23714 if test "x$BOOT_JDK_FOUND" = xno; then 23715 # Now execute the test 23716 23717 if test "x$with_boot_jdk" != x; then 23718 BOOT_JDK=$with_boot_jdk 23719 BOOT_JDK_FOUND=maybe 23720 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using configure arguments" >&5 23721 $as_echo "$as_me: Found potential Boot JDK using configure arguments" >&6;} 23722 fi 23723 23724 23725 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 23726 if test "x$BOOT_JDK_FOUND" = xmaybe; then 23727 # Do we have a bin/java? 23728 if test ! -x "$BOOT_JDK/bin/java"; then 23729 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 23730 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 23731 BOOT_JDK_FOUND=no 23732 else 23733 # Do we have a bin/javac? 23734 if test ! -x "$BOOT_JDK/bin/javac"; then 23735 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 23736 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 23737 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 23738 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 23739 BOOT_JDK_FOUND=no 23740 else 23741 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 23742 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 23743 23744 # Extra M4 quote needed to protect [] in grep expression. 23745 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 23746 if test "x$FOUND_CORRECT_VERSION" = x; then 23747 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 23748 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 23749 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 23750 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 23751 BOOT_JDK_FOUND=no 23752 else 23753 # We're done! :-) 23754 BOOT_JDK_FOUND=yes 23755 23756 # Only process if variable expands to non-empty 23757 23758 if test "x$BOOT_JDK" != x; then 23759 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 23760 23761 # Input might be given as Windows format, start by converting to 23762 # unix format. 23763 path="$BOOT_JDK" 23764 new_path=`$CYGPATH -u "$path"` 23765 23766 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 23767 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 23768 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 23769 # "foo.exe" is OK but "foo" is an error. 23770 # 23771 # This test is therefore slightly more accurate than "test -f" to check for file precense. 23772 # It is also a way to make sure we got the proper file name for the real test later on. 23773 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 23774 if test "x$test_shortpath" = x; then 23775 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 23776 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 23777 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 23778 fi 23779 23780 # Call helper function which possibly converts this using DOS-style short mode. 23781 # If so, the updated path is stored in $new_path. 23782 23783 input_path="$new_path" 23784 # Check if we need to convert this using DOS-style short mode. If the path 23785 # contains just simple characters, use it. Otherwise (spaces, weird characters), 23786 # take no chances and rewrite it. 23787 # Note: m4 eats our [], so we need to use [ and ] instead. 23788 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 23789 if test "x$has_forbidden_chars" != x; then 23790 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 23791 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 23792 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 23793 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 23794 # Going to short mode and back again did indeed matter. Since short mode is 23795 # case insensitive, let's make it lowercase to improve readability. 23796 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 23797 # Now convert it back to Unix-style (cygpath) 23798 input_path=`$CYGPATH -u "$shortmode_path"` 23799 new_path="$input_path" 23800 fi 23801 fi 23802 23803 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 23804 if test "x$test_cygdrive_prefix" = x; then 23805 # As a simple fix, exclude /usr/bin since it's not a real path. 23806 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 23807 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 23808 # a path prefixed by /cygdrive for fixpath to work. 23809 new_path="$CYGWIN_ROOT_PATH$input_path" 23810 fi 23811 fi 23812 23813 23814 if test "x$path" != "x$new_path"; then 23815 BOOT_JDK="$new_path" 23816 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 23817 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 23818 fi 23819 23820 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 23821 23822 path="$BOOT_JDK" 23823 has_colon=`$ECHO $path | $GREP ^.:` 23824 new_path="$path" 23825 if test "x$has_colon" = x; then 23826 # Not in mixed or Windows style, start by that. 23827 new_path=`cmd //c echo $path` 23828 fi 23829 23830 23831 input_path="$new_path" 23832 # Check if we need to convert this using DOS-style short mode. If the path 23833 # contains just simple characters, use it. Otherwise (spaces, weird characters), 23834 # take no chances and rewrite it. 23835 # Note: m4 eats our [], so we need to use [ and ] instead. 23836 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 23837 if test "x$has_forbidden_chars" != x; then 23838 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 23839 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 23840 fi 23841 23842 23843 windows_path="$new_path" 23844 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 23845 unix_path=`$CYGPATH -u "$windows_path"` 23846 new_path="$unix_path" 23847 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 23848 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 23849 new_path="$unix_path" 23850 fi 23851 23852 if test "x$path" != "x$new_path"; then 23853 BOOT_JDK="$new_path" 23854 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 23855 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 23856 fi 23857 23858 # Save the first 10 bytes of this path to the storage, so fixpath can work. 23859 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 23860 23861 else 23862 # We're on a unix platform. Hooray! :) 23863 path="$BOOT_JDK" 23864 has_space=`$ECHO "$path" | $GREP " "` 23865 if test "x$has_space" != x; then 23866 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 23867 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 23868 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 23869 fi 23870 23871 # Use eval to expand a potential ~ 23872 eval path="$path" 23873 if test ! -f "$path" && test ! -d "$path"; then 23874 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 23875 fi 23876 23877 if test -d "$path"; then 23878 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 23879 else 23880 dir="`$DIRNAME "$path"`" 23881 base="`$BASENAME "$path"`" 23882 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 23883 fi 23884 fi 23885 fi 23886 23887 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 23888 $as_echo_n "checking for Boot JDK... " >&6; } 23889 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 23890 $as_echo "$BOOT_JDK" >&6; } 23891 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 23892 $as_echo_n "checking Boot JDK version... " >&6; } 23893 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 23894 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 23895 $as_echo "$BOOT_JDK_VERSION" >&6; } 23896 fi # end check jdk version 23897 fi # end check javac 23898 fi # end check java 23899 fi # end check boot jdk found 23900 fi 23901 23902 if test "x$with_boot_jdk" != x && test "x$BOOT_JDK_FOUND" = xno; then 23903 # Having specified an argument which is incorrect will produce an instant failure; 23904 # we should not go on looking 23905 as_fn_error $? "The path given by --with-boot-jdk does not contain a valid Boot JDK" "$LINENO" 5 23906 fi 23907 23908 # Test: On MacOS X, can we find a boot jdk using /usr/libexec/java_home? 23909 23910 if test "x$BOOT_JDK_FOUND" = xno; then 23911 # Now execute the test 23912 23913 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 23914 # First check at user selected default 23915 23916 if test "x$BOOT_JDK_FOUND" = xno; then 23917 # Now execute the test 23918 23919 if test -x /usr/libexec/java_home; then 23920 BOOT_JDK=`/usr/libexec/java_home ` 23921 BOOT_JDK_FOUND=maybe 23922 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home " >&5 23923 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home " >&6;} 23924 fi 23925 23926 23927 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 23928 if test "x$BOOT_JDK_FOUND" = xmaybe; then 23929 # Do we have a bin/java? 23930 if test ! -x "$BOOT_JDK/bin/java"; then 23931 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 23932 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 23933 BOOT_JDK_FOUND=no 23934 else 23935 # Do we have a bin/javac? 23936 if test ! -x "$BOOT_JDK/bin/javac"; then 23937 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 23938 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 23939 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 23940 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 23941 BOOT_JDK_FOUND=no 23942 else 23943 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 23944 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 23945 23946 # Extra M4 quote needed to protect [] in grep expression. 23947 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 23948 if test "x$FOUND_CORRECT_VERSION" = x; then 23949 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 23950 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 23951 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 23952 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 23953 BOOT_JDK_FOUND=no 23954 else 23955 # We're done! :-) 23956 BOOT_JDK_FOUND=yes 23957 23958 # Only process if variable expands to non-empty 23959 23960 if test "x$BOOT_JDK" != x; then 23961 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 23962 23963 # Input might be given as Windows format, start by converting to 23964 # unix format. 23965 path="$BOOT_JDK" 23966 new_path=`$CYGPATH -u "$path"` 23967 23968 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 23969 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 23970 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 23971 # "foo.exe" is OK but "foo" is an error. 23972 # 23973 # This test is therefore slightly more accurate than "test -f" to check for file precense. 23974 # It is also a way to make sure we got the proper file name for the real test later on. 23975 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 23976 if test "x$test_shortpath" = x; then 23977 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 23978 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 23979 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 23980 fi 23981 23982 # Call helper function which possibly converts this using DOS-style short mode. 23983 # If so, the updated path is stored in $new_path. 23984 23985 input_path="$new_path" 23986 # Check if we need to convert this using DOS-style short mode. If the path 23987 # contains just simple characters, use it. Otherwise (spaces, weird characters), 23988 # take no chances and rewrite it. 23989 # Note: m4 eats our [], so we need to use [ and ] instead. 23990 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 23991 if test "x$has_forbidden_chars" != x; then 23992 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 23993 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 23994 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 23995 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 23996 # Going to short mode and back again did indeed matter. Since short mode is 23997 # case insensitive, let's make it lowercase to improve readability. 23998 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 23999 # Now convert it back to Unix-style (cygpath) 24000 input_path=`$CYGPATH -u "$shortmode_path"` 24001 new_path="$input_path" 24002 fi 24003 fi 24004 24005 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 24006 if test "x$test_cygdrive_prefix" = x; then 24007 # As a simple fix, exclude /usr/bin since it's not a real path. 24008 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 24009 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 24010 # a path prefixed by /cygdrive for fixpath to work. 24011 new_path="$CYGWIN_ROOT_PATH$input_path" 24012 fi 24013 fi 24014 24015 24016 if test "x$path" != "x$new_path"; then 24017 BOOT_JDK="$new_path" 24018 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 24019 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 24020 fi 24021 24022 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24023 24024 path="$BOOT_JDK" 24025 has_colon=`$ECHO $path | $GREP ^.:` 24026 new_path="$path" 24027 if test "x$has_colon" = x; then 24028 # Not in mixed or Windows style, start by that. 24029 new_path=`cmd //c echo $path` 24030 fi 24031 24032 24033 input_path="$new_path" 24034 # Check if we need to convert this using DOS-style short mode. If the path 24035 # contains just simple characters, use it. Otherwise (spaces, weird characters), 24036 # take no chances and rewrite it. 24037 # Note: m4 eats our [], so we need to use [ and ] instead. 24038 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 24039 if test "x$has_forbidden_chars" != x; then 24040 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 24041 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 24042 fi 24043 24044 24045 windows_path="$new_path" 24046 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24047 unix_path=`$CYGPATH -u "$windows_path"` 24048 new_path="$unix_path" 24049 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24050 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 24051 new_path="$unix_path" 24052 fi 24053 24054 if test "x$path" != "x$new_path"; then 24055 BOOT_JDK="$new_path" 24056 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 24057 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 24058 fi 24059 24060 # Save the first 10 bytes of this path to the storage, so fixpath can work. 24061 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 24062 24063 else 24064 # We're on a unix platform. Hooray! :) 24065 path="$BOOT_JDK" 24066 has_space=`$ECHO "$path" | $GREP " "` 24067 if test "x$has_space" != x; then 24068 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 24069 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 24070 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 24071 fi 24072 24073 # Use eval to expand a potential ~ 24074 eval path="$path" 24075 if test ! -f "$path" && test ! -d "$path"; then 24076 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 24077 fi 24078 24079 if test -d "$path"; then 24080 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 24081 else 24082 dir="`$DIRNAME "$path"`" 24083 base="`$BASENAME "$path"`" 24084 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 24085 fi 24086 fi 24087 fi 24088 24089 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 24090 $as_echo_n "checking for Boot JDK... " >&6; } 24091 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 24092 $as_echo "$BOOT_JDK" >&6; } 24093 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 24094 $as_echo_n "checking Boot JDK version... " >&6; } 24095 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 24096 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 24097 $as_echo "$BOOT_JDK_VERSION" >&6; } 24098 fi # end check jdk version 24099 fi # end check javac 24100 fi # end check java 24101 fi # end check boot jdk found 24102 fi 24103 24104 # If that did not work out (e.g. too old), try explicit versions instead 24105 24106 if test "x$BOOT_JDK_FOUND" = xno; then 24107 # Now execute the test 24108 24109 if test -x /usr/libexec/java_home; then 24110 BOOT_JDK=`/usr/libexec/java_home -v 1.9` 24111 BOOT_JDK_FOUND=maybe 24112 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home -v 1.9" >&5 24113 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home -v 1.9" >&6;} 24114 fi 24115 24116 24117 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 24118 if test "x$BOOT_JDK_FOUND" = xmaybe; then 24119 # Do we have a bin/java? 24120 if test ! -x "$BOOT_JDK/bin/java"; then 24121 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 24122 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 24123 BOOT_JDK_FOUND=no 24124 else 24125 # Do we have a bin/javac? 24126 if test ! -x "$BOOT_JDK/bin/javac"; then 24127 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 24128 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 24129 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 24130 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 24131 BOOT_JDK_FOUND=no 24132 else 24133 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 24134 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 24135 24136 # Extra M4 quote needed to protect [] in grep expression. 24137 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 24138 if test "x$FOUND_CORRECT_VERSION" = x; then 24139 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 24140 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 24141 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 24142 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 24143 BOOT_JDK_FOUND=no 24144 else 24145 # We're done! :-) 24146 BOOT_JDK_FOUND=yes 24147 24148 # Only process if variable expands to non-empty 24149 24150 if test "x$BOOT_JDK" != x; then 24151 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24152 24153 # Input might be given as Windows format, start by converting to 24154 # unix format. 24155 path="$BOOT_JDK" 24156 new_path=`$CYGPATH -u "$path"` 24157 24158 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 24159 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 24160 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 24161 # "foo.exe" is OK but "foo" is an error. 24162 # 24163 # This test is therefore slightly more accurate than "test -f" to check for file precense. 24164 # It is also a way to make sure we got the proper file name for the real test later on. 24165 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 24166 if test "x$test_shortpath" = x; then 24167 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 24168 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 24169 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 24170 fi 24171 24172 # Call helper function which possibly converts this using DOS-style short mode. 24173 # If so, the updated path is stored in $new_path. 24174 24175 input_path="$new_path" 24176 # Check if we need to convert this using DOS-style short mode. If the path 24177 # contains just simple characters, use it. Otherwise (spaces, weird characters), 24178 # take no chances and rewrite it. 24179 # Note: m4 eats our [], so we need to use [ and ] instead. 24180 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 24181 if test "x$has_forbidden_chars" != x; then 24182 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 24183 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 24184 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 24185 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 24186 # Going to short mode and back again did indeed matter. Since short mode is 24187 # case insensitive, let's make it lowercase to improve readability. 24188 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 24189 # Now convert it back to Unix-style (cygpath) 24190 input_path=`$CYGPATH -u "$shortmode_path"` 24191 new_path="$input_path" 24192 fi 24193 fi 24194 24195 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 24196 if test "x$test_cygdrive_prefix" = x; then 24197 # As a simple fix, exclude /usr/bin since it's not a real path. 24198 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 24199 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 24200 # a path prefixed by /cygdrive for fixpath to work. 24201 new_path="$CYGWIN_ROOT_PATH$input_path" 24202 fi 24203 fi 24204 24205 24206 if test "x$path" != "x$new_path"; then 24207 BOOT_JDK="$new_path" 24208 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 24209 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 24210 fi 24211 24212 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24213 24214 path="$BOOT_JDK" 24215 has_colon=`$ECHO $path | $GREP ^.:` 24216 new_path="$path" 24217 if test "x$has_colon" = x; then 24218 # Not in mixed or Windows style, start by that. 24219 new_path=`cmd //c echo $path` 24220 fi 24221 24222 24223 input_path="$new_path" 24224 # Check if we need to convert this using DOS-style short mode. If the path 24225 # contains just simple characters, use it. Otherwise (spaces, weird characters), 24226 # take no chances and rewrite it. 24227 # Note: m4 eats our [], so we need to use [ and ] instead. 24228 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 24229 if test "x$has_forbidden_chars" != x; then 24230 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 24231 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 24232 fi 24233 24234 24235 windows_path="$new_path" 24236 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24237 unix_path=`$CYGPATH -u "$windows_path"` 24238 new_path="$unix_path" 24239 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24240 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 24241 new_path="$unix_path" 24242 fi 24243 24244 if test "x$path" != "x$new_path"; then 24245 BOOT_JDK="$new_path" 24246 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 24247 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 24248 fi 24249 24250 # Save the first 10 bytes of this path to the storage, so fixpath can work. 24251 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 24252 24253 else 24254 # We're on a unix platform. Hooray! :) 24255 path="$BOOT_JDK" 24256 has_space=`$ECHO "$path" | $GREP " "` 24257 if test "x$has_space" != x; then 24258 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 24259 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 24260 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 24261 fi 24262 24263 # Use eval to expand a potential ~ 24264 eval path="$path" 24265 if test ! -f "$path" && test ! -d "$path"; then 24266 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 24267 fi 24268 24269 if test -d "$path"; then 24270 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 24271 else 24272 dir="`$DIRNAME "$path"`" 24273 base="`$BASENAME "$path"`" 24274 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 24275 fi 24276 fi 24277 fi 24278 24279 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 24280 $as_echo_n "checking for Boot JDK... " >&6; } 24281 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 24282 $as_echo "$BOOT_JDK" >&6; } 24283 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 24284 $as_echo_n "checking Boot JDK version... " >&6; } 24285 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 24286 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 24287 $as_echo "$BOOT_JDK_VERSION" >&6; } 24288 fi # end check jdk version 24289 fi # end check javac 24290 fi # end check java 24291 fi # end check boot jdk found 24292 fi 24293 24294 24295 if test "x$BOOT_JDK_FOUND" = xno; then 24296 # Now execute the test 24297 24298 if test -x /usr/libexec/java_home; then 24299 BOOT_JDK=`/usr/libexec/java_home -v 1.8` 24300 BOOT_JDK_FOUND=maybe 24301 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home -v 1.8" >&5 24302 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home -v 1.8" >&6;} 24303 fi 24304 24305 24306 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 24307 if test "x$BOOT_JDK_FOUND" = xmaybe; then 24308 # Do we have a bin/java? 24309 if test ! -x "$BOOT_JDK/bin/java"; then 24310 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 24311 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 24312 BOOT_JDK_FOUND=no 24313 else 24314 # Do we have a bin/javac? 24315 if test ! -x "$BOOT_JDK/bin/javac"; then 24316 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 24317 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 24318 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 24319 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 24320 BOOT_JDK_FOUND=no 24321 else 24322 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 24323 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 24324 24325 # Extra M4 quote needed to protect [] in grep expression. 24326 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 24327 if test "x$FOUND_CORRECT_VERSION" = x; then 24328 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 24329 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 24330 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 24331 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 24332 BOOT_JDK_FOUND=no 24333 else 24334 # We're done! :-) 24335 BOOT_JDK_FOUND=yes 24336 24337 # Only process if variable expands to non-empty 24338 24339 if test "x$BOOT_JDK" != x; then 24340 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24341 24342 # Input might be given as Windows format, start by converting to 24343 # unix format. 24344 path="$BOOT_JDK" 24345 new_path=`$CYGPATH -u "$path"` 24346 24347 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 24348 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 24349 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 24350 # "foo.exe" is OK but "foo" is an error. 24351 # 24352 # This test is therefore slightly more accurate than "test -f" to check for file precense. 24353 # It is also a way to make sure we got the proper file name for the real test later on. 24354 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 24355 if test "x$test_shortpath" = x; then 24356 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 24357 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 24358 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 24359 fi 24360 24361 # Call helper function which possibly converts this using DOS-style short mode. 24362 # If so, the updated path is stored in $new_path. 24363 24364 input_path="$new_path" 24365 # Check if we need to convert this using DOS-style short mode. If the path 24366 # contains just simple characters, use it. Otherwise (spaces, weird characters), 24367 # take no chances and rewrite it. 24368 # Note: m4 eats our [], so we need to use [ and ] instead. 24369 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 24370 if test "x$has_forbidden_chars" != x; then 24371 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 24372 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 24373 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 24374 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 24375 # Going to short mode and back again did indeed matter. Since short mode is 24376 # case insensitive, let's make it lowercase to improve readability. 24377 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 24378 # Now convert it back to Unix-style (cygpath) 24379 input_path=`$CYGPATH -u "$shortmode_path"` 24380 new_path="$input_path" 24381 fi 24382 fi 24383 24384 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 24385 if test "x$test_cygdrive_prefix" = x; then 24386 # As a simple fix, exclude /usr/bin since it's not a real path. 24387 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 24388 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 24389 # a path prefixed by /cygdrive for fixpath to work. 24390 new_path="$CYGWIN_ROOT_PATH$input_path" 24391 fi 24392 fi 24393 24394 24395 if test "x$path" != "x$new_path"; then 24396 BOOT_JDK="$new_path" 24397 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 24398 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 24399 fi 24400 24401 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24402 24403 path="$BOOT_JDK" 24404 has_colon=`$ECHO $path | $GREP ^.:` 24405 new_path="$path" 24406 if test "x$has_colon" = x; then 24407 # Not in mixed or Windows style, start by that. 24408 new_path=`cmd //c echo $path` 24409 fi 24410 24411 24412 input_path="$new_path" 24413 # Check if we need to convert this using DOS-style short mode. If the path 24414 # contains just simple characters, use it. Otherwise (spaces, weird characters), 24415 # take no chances and rewrite it. 24416 # Note: m4 eats our [], so we need to use [ and ] instead. 24417 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 24418 if test "x$has_forbidden_chars" != x; then 24419 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 24420 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 24421 fi 24422 24423 24424 windows_path="$new_path" 24425 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24426 unix_path=`$CYGPATH -u "$windows_path"` 24427 new_path="$unix_path" 24428 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24429 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 24430 new_path="$unix_path" 24431 fi 24432 24433 if test "x$path" != "x$new_path"; then 24434 BOOT_JDK="$new_path" 24435 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 24436 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 24437 fi 24438 24439 # Save the first 10 bytes of this path to the storage, so fixpath can work. 24440 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 24441 24442 else 24443 # We're on a unix platform. Hooray! :) 24444 path="$BOOT_JDK" 24445 has_space=`$ECHO "$path" | $GREP " "` 24446 if test "x$has_space" != x; then 24447 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 24448 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 24449 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 24450 fi 24451 24452 # Use eval to expand a potential ~ 24453 eval path="$path" 24454 if test ! -f "$path" && test ! -d "$path"; then 24455 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 24456 fi 24457 24458 if test -d "$path"; then 24459 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 24460 else 24461 dir="`$DIRNAME "$path"`" 24462 base="`$BASENAME "$path"`" 24463 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 24464 fi 24465 fi 24466 fi 24467 24468 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 24469 $as_echo_n "checking for Boot JDK... " >&6; } 24470 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 24471 $as_echo "$BOOT_JDK" >&6; } 24472 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 24473 $as_echo_n "checking Boot JDK version... " >&6; } 24474 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 24475 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 24476 $as_echo "$BOOT_JDK_VERSION" >&6; } 24477 fi # end check jdk version 24478 fi # end check javac 24479 fi # end check java 24480 fi # end check boot jdk found 24481 fi 24482 24483 24484 if test "x$BOOT_JDK_FOUND" = xno; then 24485 # Now execute the test 24486 24487 if test -x /usr/libexec/java_home; then 24488 BOOT_JDK=`/usr/libexec/java_home -v 1.7` 24489 BOOT_JDK_FOUND=maybe 24490 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using /usr/libexec/java_home -v 1.7" >&5 24491 $as_echo "$as_me: Found potential Boot JDK using /usr/libexec/java_home -v 1.7" >&6;} 24492 fi 24493 24494 24495 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 24496 if test "x$BOOT_JDK_FOUND" = xmaybe; then 24497 # Do we have a bin/java? 24498 if test ! -x "$BOOT_JDK/bin/java"; then 24499 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 24500 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 24501 BOOT_JDK_FOUND=no 24502 else 24503 # Do we have a bin/javac? 24504 if test ! -x "$BOOT_JDK/bin/javac"; then 24505 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 24506 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 24507 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 24508 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 24509 BOOT_JDK_FOUND=no 24510 else 24511 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 24512 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 24513 24514 # Extra M4 quote needed to protect [] in grep expression. 24515 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 24516 if test "x$FOUND_CORRECT_VERSION" = x; then 24517 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 24518 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 24519 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 24520 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 24521 BOOT_JDK_FOUND=no 24522 else 24523 # We're done! :-) 24524 BOOT_JDK_FOUND=yes 24525 24526 # Only process if variable expands to non-empty 24527 24528 if test "x$BOOT_JDK" != x; then 24529 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24530 24531 # Input might be given as Windows format, start by converting to 24532 # unix format. 24533 path="$BOOT_JDK" 24534 new_path=`$CYGPATH -u "$path"` 24535 24536 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 24537 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 24538 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 24539 # "foo.exe" is OK but "foo" is an error. 24540 # 24541 # This test is therefore slightly more accurate than "test -f" to check for file precense. 24542 # It is also a way to make sure we got the proper file name for the real test later on. 24543 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 24544 if test "x$test_shortpath" = x; then 24545 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 24546 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 24547 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 24548 fi 24549 24550 # Call helper function which possibly converts this using DOS-style short mode. 24551 # If so, the updated path is stored in $new_path. 24552 24553 input_path="$new_path" 24554 # Check if we need to convert this using DOS-style short mode. If the path 24555 # contains just simple characters, use it. Otherwise (spaces, weird characters), 24556 # take no chances and rewrite it. 24557 # Note: m4 eats our [], so we need to use [ and ] instead. 24558 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 24559 if test "x$has_forbidden_chars" != x; then 24560 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 24561 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 24562 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 24563 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 24564 # Going to short mode and back again did indeed matter. Since short mode is 24565 # case insensitive, let's make it lowercase to improve readability. 24566 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 24567 # Now convert it back to Unix-style (cygpath) 24568 input_path=`$CYGPATH -u "$shortmode_path"` 24569 new_path="$input_path" 24570 fi 24571 fi 24572 24573 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 24574 if test "x$test_cygdrive_prefix" = x; then 24575 # As a simple fix, exclude /usr/bin since it's not a real path. 24576 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 24577 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 24578 # a path prefixed by /cygdrive for fixpath to work. 24579 new_path="$CYGWIN_ROOT_PATH$input_path" 24580 fi 24581 fi 24582 24583 24584 if test "x$path" != "x$new_path"; then 24585 BOOT_JDK="$new_path" 24586 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 24587 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 24588 fi 24589 24590 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24591 24592 path="$BOOT_JDK" 24593 has_colon=`$ECHO $path | $GREP ^.:` 24594 new_path="$path" 24595 if test "x$has_colon" = x; then 24596 # Not in mixed or Windows style, start by that. 24597 new_path=`cmd //c echo $path` 24598 fi 24599 24600 24601 input_path="$new_path" 24602 # Check if we need to convert this using DOS-style short mode. If the path 24603 # contains just simple characters, use it. Otherwise (spaces, weird characters), 24604 # take no chances and rewrite it. 24605 # Note: m4 eats our [], so we need to use [ and ] instead. 24606 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 24607 if test "x$has_forbidden_chars" != x; then 24608 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 24609 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 24610 fi 24611 24612 24613 windows_path="$new_path" 24614 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24615 unix_path=`$CYGPATH -u "$windows_path"` 24616 new_path="$unix_path" 24617 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24618 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 24619 new_path="$unix_path" 24620 fi 24621 24622 if test "x$path" != "x$new_path"; then 24623 BOOT_JDK="$new_path" 24624 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 24625 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 24626 fi 24627 24628 # Save the first 10 bytes of this path to the storage, so fixpath can work. 24629 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 24630 24631 else 24632 # We're on a unix platform. Hooray! :) 24633 path="$BOOT_JDK" 24634 has_space=`$ECHO "$path" | $GREP " "` 24635 if test "x$has_space" != x; then 24636 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 24637 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 24638 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 24639 fi 24640 24641 # Use eval to expand a potential ~ 24642 eval path="$path" 24643 if test ! -f "$path" && test ! -d "$path"; then 24644 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 24645 fi 24646 24647 if test -d "$path"; then 24648 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 24649 else 24650 dir="`$DIRNAME "$path"`" 24651 base="`$BASENAME "$path"`" 24652 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 24653 fi 24654 fi 24655 fi 24656 24657 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 24658 $as_echo_n "checking for Boot JDK... " >&6; } 24659 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 24660 $as_echo "$BOOT_JDK" >&6; } 24661 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 24662 $as_echo_n "checking Boot JDK version... " >&6; } 24663 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 24664 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 24665 $as_echo "$BOOT_JDK_VERSION" >&6; } 24666 fi # end check jdk version 24667 fi # end check javac 24668 fi # end check java 24669 fi # end check boot jdk found 24670 fi 24671 24672 fi 24673 24674 24675 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 24676 if test "x$BOOT_JDK_FOUND" = xmaybe; then 24677 # Do we have a bin/java? 24678 if test ! -x "$BOOT_JDK/bin/java"; then 24679 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 24680 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 24681 BOOT_JDK_FOUND=no 24682 else 24683 # Do we have a bin/javac? 24684 if test ! -x "$BOOT_JDK/bin/javac"; then 24685 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 24686 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 24687 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 24688 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 24689 BOOT_JDK_FOUND=no 24690 else 24691 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 24692 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 24693 24694 # Extra M4 quote needed to protect [] in grep expression. 24695 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 24696 if test "x$FOUND_CORRECT_VERSION" = x; then 24697 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 24698 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 24699 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 24700 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 24701 BOOT_JDK_FOUND=no 24702 else 24703 # We're done! :-) 24704 BOOT_JDK_FOUND=yes 24705 24706 # Only process if variable expands to non-empty 24707 24708 if test "x$BOOT_JDK" != x; then 24709 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24710 24711 # Input might be given as Windows format, start by converting to 24712 # unix format. 24713 path="$BOOT_JDK" 24714 new_path=`$CYGPATH -u "$path"` 24715 24716 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 24717 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 24718 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 24719 # "foo.exe" is OK but "foo" is an error. 24720 # 24721 # This test is therefore slightly more accurate than "test -f" to check for file precense. 24722 # It is also a way to make sure we got the proper file name for the real test later on. 24723 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 24724 if test "x$test_shortpath" = x; then 24725 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 24726 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 24727 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 24728 fi 24729 24730 # Call helper function which possibly converts this using DOS-style short mode. 24731 # If so, the updated path is stored in $new_path. 24732 24733 input_path="$new_path" 24734 # Check if we need to convert this using DOS-style short mode. If the path 24735 # contains just simple characters, use it. Otherwise (spaces, weird characters), 24736 # take no chances and rewrite it. 24737 # Note: m4 eats our [], so we need to use [ and ] instead. 24738 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 24739 if test "x$has_forbidden_chars" != x; then 24740 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 24741 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 24742 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 24743 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 24744 # Going to short mode and back again did indeed matter. Since short mode is 24745 # case insensitive, let's make it lowercase to improve readability. 24746 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 24747 # Now convert it back to Unix-style (cygpath) 24748 input_path=`$CYGPATH -u "$shortmode_path"` 24749 new_path="$input_path" 24750 fi 24751 fi 24752 24753 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 24754 if test "x$test_cygdrive_prefix" = x; then 24755 # As a simple fix, exclude /usr/bin since it's not a real path. 24756 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 24757 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 24758 # a path prefixed by /cygdrive for fixpath to work. 24759 new_path="$CYGWIN_ROOT_PATH$input_path" 24760 fi 24761 fi 24762 24763 24764 if test "x$path" != "x$new_path"; then 24765 BOOT_JDK="$new_path" 24766 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 24767 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 24768 fi 24769 24770 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24771 24772 path="$BOOT_JDK" 24773 has_colon=`$ECHO $path | $GREP ^.:` 24774 new_path="$path" 24775 if test "x$has_colon" = x; then 24776 # Not in mixed or Windows style, start by that. 24777 new_path=`cmd //c echo $path` 24778 fi 24779 24780 24781 input_path="$new_path" 24782 # Check if we need to convert this using DOS-style short mode. If the path 24783 # contains just simple characters, use it. Otherwise (spaces, weird characters), 24784 # take no chances and rewrite it. 24785 # Note: m4 eats our [], so we need to use [ and ] instead. 24786 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 24787 if test "x$has_forbidden_chars" != x; then 24788 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 24789 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 24790 fi 24791 24792 24793 windows_path="$new_path" 24794 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24795 unix_path=`$CYGPATH -u "$windows_path"` 24796 new_path="$unix_path" 24797 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24798 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 24799 new_path="$unix_path" 24800 fi 24801 24802 if test "x$path" != "x$new_path"; then 24803 BOOT_JDK="$new_path" 24804 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 24805 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 24806 fi 24807 24808 # Save the first 10 bytes of this path to the storage, so fixpath can work. 24809 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 24810 24811 else 24812 # We're on a unix platform. Hooray! :) 24813 path="$BOOT_JDK" 24814 has_space=`$ECHO "$path" | $GREP " "` 24815 if test "x$has_space" != x; then 24816 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 24817 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 24818 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 24819 fi 24820 24821 # Use eval to expand a potential ~ 24822 eval path="$path" 24823 if test ! -f "$path" && test ! -d "$path"; then 24824 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 24825 fi 24826 24827 if test -d "$path"; then 24828 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 24829 else 24830 dir="`$DIRNAME "$path"`" 24831 base="`$BASENAME "$path"`" 24832 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 24833 fi 24834 fi 24835 fi 24836 24837 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 24838 $as_echo_n "checking for Boot JDK... " >&6; } 24839 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 24840 $as_echo "$BOOT_JDK" >&6; } 24841 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 24842 $as_echo_n "checking Boot JDK version... " >&6; } 24843 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 24844 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 24845 $as_echo "$BOOT_JDK_VERSION" >&6; } 24846 fi # end check jdk version 24847 fi # end check javac 24848 fi # end check java 24849 fi # end check boot jdk found 24850 fi 24851 24852 24853 # Test: Is $JAVA_HOME set? 24854 24855 if test "x$BOOT_JDK_FOUND" = xno; then 24856 # Now execute the test 24857 24858 if test "x$JAVA_HOME" != x; then 24859 JAVA_HOME_PROCESSED="$JAVA_HOME" 24860 24861 # Only process if variable expands to non-empty 24862 24863 if test "x$JAVA_HOME_PROCESSED" != x; then 24864 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24865 24866 # Input might be given as Windows format, start by converting to 24867 # unix format. 24868 path="$JAVA_HOME_PROCESSED" 24869 new_path=`$CYGPATH -u "$path"` 24870 24871 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 24872 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 24873 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 24874 # "foo.exe" is OK but "foo" is an error. 24875 # 24876 # This test is therefore slightly more accurate than "test -f" to check for file precense. 24877 # It is also a way to make sure we got the proper file name for the real test later on. 24878 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 24879 if test "x$test_shortpath" = x; then 24880 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&5 24881 $as_echo "$as_me: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&6;} 24882 as_fn_error $? "Cannot locate the the path of JAVA_HOME_PROCESSED" "$LINENO" 5 24883 fi 24884 24885 # Call helper function which possibly converts this using DOS-style short mode. 24886 # If so, the updated path is stored in $new_path. 24887 24888 input_path="$new_path" 24889 # Check if we need to convert this using DOS-style short mode. If the path 24890 # contains just simple characters, use it. Otherwise (spaces, weird characters), 24891 # take no chances and rewrite it. 24892 # Note: m4 eats our [], so we need to use [ and ] instead. 24893 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 24894 if test "x$has_forbidden_chars" != x; then 24895 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 24896 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 24897 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 24898 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 24899 # Going to short mode and back again did indeed matter. Since short mode is 24900 # case insensitive, let's make it lowercase to improve readability. 24901 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 24902 # Now convert it back to Unix-style (cygpath) 24903 input_path=`$CYGPATH -u "$shortmode_path"` 24904 new_path="$input_path" 24905 fi 24906 fi 24907 24908 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 24909 if test "x$test_cygdrive_prefix" = x; then 24910 # As a simple fix, exclude /usr/bin since it's not a real path. 24911 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 24912 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 24913 # a path prefixed by /cygdrive for fixpath to work. 24914 new_path="$CYGWIN_ROOT_PATH$input_path" 24915 fi 24916 fi 24917 24918 24919 if test "x$path" != "x$new_path"; then 24920 JAVA_HOME_PROCESSED="$new_path" 24921 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&5 24922 $as_echo "$as_me: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&6;} 24923 fi 24924 24925 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24926 24927 path="$JAVA_HOME_PROCESSED" 24928 has_colon=`$ECHO $path | $GREP ^.:` 24929 new_path="$path" 24930 if test "x$has_colon" = x; then 24931 # Not in mixed or Windows style, start by that. 24932 new_path=`cmd //c echo $path` 24933 fi 24934 24935 24936 input_path="$new_path" 24937 # Check if we need to convert this using DOS-style short mode. If the path 24938 # contains just simple characters, use it. Otherwise (spaces, weird characters), 24939 # take no chances and rewrite it. 24940 # Note: m4 eats our [], so we need to use [ and ] instead. 24941 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 24942 if test "x$has_forbidden_chars" != x; then 24943 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 24944 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 24945 fi 24946 24947 24948 windows_path="$new_path" 24949 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 24950 unix_path=`$CYGPATH -u "$windows_path"` 24951 new_path="$unix_path" 24952 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 24953 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 24954 new_path="$unix_path" 24955 fi 24956 24957 if test "x$path" != "x$new_path"; then 24958 JAVA_HOME_PROCESSED="$new_path" 24959 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&5 24960 $as_echo "$as_me: Rewriting JAVA_HOME_PROCESSED to \"$new_path\"" >&6;} 24961 fi 24962 24963 # Save the first 10 bytes of this path to the storage, so fixpath can work. 24964 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 24965 24966 else 24967 # We're on a unix platform. Hooray! :) 24968 path="$JAVA_HOME_PROCESSED" 24969 has_space=`$ECHO "$path" | $GREP " "` 24970 if test "x$has_space" != x; then 24971 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&5 24972 $as_echo "$as_me: The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is invalid." >&6;} 24973 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 24974 fi 24975 24976 # Use eval to expand a potential ~ 24977 eval path="$path" 24978 if test ! -f "$path" && test ! -d "$path"; then 24979 as_fn_error $? "The path of JAVA_HOME_PROCESSED, which resolves as \"$path\", is not found." "$LINENO" 5 24980 fi 24981 24982 if test -d "$path"; then 24983 JAVA_HOME_PROCESSED="`cd "$path"; $THEPWDCMD -L`" 24984 else 24985 dir="`$DIRNAME "$path"`" 24986 base="`$BASENAME "$path"`" 24987 JAVA_HOME_PROCESSED="`cd "$dir"; $THEPWDCMD -L`/$base" 24988 fi 24989 fi 24990 fi 24991 24992 if test ! -d "$JAVA_HOME_PROCESSED"; then 24993 { $as_echo "$as_me:${as_lineno-$LINENO}: Your JAVA_HOME points to a non-existing directory!" >&5 24994 $as_echo "$as_me: Your JAVA_HOME points to a non-existing directory!" >&6;} 24995 else 24996 # Aha, the user has set a JAVA_HOME 24997 # let us use that as the Boot JDK. 24998 BOOT_JDK="$JAVA_HOME_PROCESSED" 24999 BOOT_JDK_FOUND=maybe 25000 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using JAVA_HOME" >&5 25001 $as_echo "$as_me: Found potential Boot JDK using JAVA_HOME" >&6;} 25002 fi 25003 fi 25004 25005 25006 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 25007 if test "x$BOOT_JDK_FOUND" = xmaybe; then 25008 # Do we have a bin/java? 25009 if test ! -x "$BOOT_JDK/bin/java"; then 25010 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 25011 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 25012 BOOT_JDK_FOUND=no 25013 else 25014 # Do we have a bin/javac? 25015 if test ! -x "$BOOT_JDK/bin/javac"; then 25016 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 25017 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 25018 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 25019 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 25020 BOOT_JDK_FOUND=no 25021 else 25022 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 25023 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 25024 25025 # Extra M4 quote needed to protect [] in grep expression. 25026 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 25027 if test "x$FOUND_CORRECT_VERSION" = x; then 25028 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 25029 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 25030 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 25031 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 25032 BOOT_JDK_FOUND=no 25033 else 25034 # We're done! :-) 25035 BOOT_JDK_FOUND=yes 25036 25037 # Only process if variable expands to non-empty 25038 25039 if test "x$BOOT_JDK" != x; then 25040 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25041 25042 # Input might be given as Windows format, start by converting to 25043 # unix format. 25044 path="$BOOT_JDK" 25045 new_path=`$CYGPATH -u "$path"` 25046 25047 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 25048 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 25049 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 25050 # "foo.exe" is OK but "foo" is an error. 25051 # 25052 # This test is therefore slightly more accurate than "test -f" to check for file precense. 25053 # It is also a way to make sure we got the proper file name for the real test later on. 25054 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 25055 if test "x$test_shortpath" = x; then 25056 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25057 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25058 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 25059 fi 25060 25061 # Call helper function which possibly converts this using DOS-style short mode. 25062 # If so, the updated path is stored in $new_path. 25063 25064 input_path="$new_path" 25065 # Check if we need to convert this using DOS-style short mode. If the path 25066 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25067 # take no chances and rewrite it. 25068 # Note: m4 eats our [], so we need to use [ and ] instead. 25069 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 25070 if test "x$has_forbidden_chars" != x; then 25071 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25072 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 25073 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 25074 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 25075 # Going to short mode and back again did indeed matter. Since short mode is 25076 # case insensitive, let's make it lowercase to improve readability. 25077 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25078 # Now convert it back to Unix-style (cygpath) 25079 input_path=`$CYGPATH -u "$shortmode_path"` 25080 new_path="$input_path" 25081 fi 25082 fi 25083 25084 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 25085 if test "x$test_cygdrive_prefix" = x; then 25086 # As a simple fix, exclude /usr/bin since it's not a real path. 25087 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 25088 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 25089 # a path prefixed by /cygdrive for fixpath to work. 25090 new_path="$CYGWIN_ROOT_PATH$input_path" 25091 fi 25092 fi 25093 25094 25095 if test "x$path" != "x$new_path"; then 25096 BOOT_JDK="$new_path" 25097 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25098 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25099 fi 25100 25101 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25102 25103 path="$BOOT_JDK" 25104 has_colon=`$ECHO $path | $GREP ^.:` 25105 new_path="$path" 25106 if test "x$has_colon" = x; then 25107 # Not in mixed or Windows style, start by that. 25108 new_path=`cmd //c echo $path` 25109 fi 25110 25111 25112 input_path="$new_path" 25113 # Check if we need to convert this using DOS-style short mode. If the path 25114 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25115 # take no chances and rewrite it. 25116 # Note: m4 eats our [], so we need to use [ and ] instead. 25117 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 25118 if test "x$has_forbidden_chars" != x; then 25119 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25120 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25121 fi 25122 25123 25124 windows_path="$new_path" 25125 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25126 unix_path=`$CYGPATH -u "$windows_path"` 25127 new_path="$unix_path" 25128 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25129 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25130 new_path="$unix_path" 25131 fi 25132 25133 if test "x$path" != "x$new_path"; then 25134 BOOT_JDK="$new_path" 25135 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25136 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25137 fi 25138 25139 # Save the first 10 bytes of this path to the storage, so fixpath can work. 25140 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 25141 25142 else 25143 # We're on a unix platform. Hooray! :) 25144 path="$BOOT_JDK" 25145 has_space=`$ECHO "$path" | $GREP " "` 25146 if test "x$has_space" != x; then 25147 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25148 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25149 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 25150 fi 25151 25152 # Use eval to expand a potential ~ 25153 eval path="$path" 25154 if test ! -f "$path" && test ! -d "$path"; then 25155 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 25156 fi 25157 25158 if test -d "$path"; then 25159 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 25160 else 25161 dir="`$DIRNAME "$path"`" 25162 base="`$BASENAME "$path"`" 25163 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 25164 fi 25165 fi 25166 fi 25167 25168 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 25169 $as_echo_n "checking for Boot JDK... " >&6; } 25170 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 25171 $as_echo "$BOOT_JDK" >&6; } 25172 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 25173 $as_echo_n "checking Boot JDK version... " >&6; } 25174 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 25175 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 25176 $as_echo "$BOOT_JDK_VERSION" >&6; } 25177 fi # end check jdk version 25178 fi # end check javac 25179 fi # end check java 25180 fi # end check boot jdk found 25181 fi 25182 25183 25184 # Test: Is there a java or javac in the PATH, which is a symlink to the JDK? 25185 25186 if test "x$BOOT_JDK_FOUND" = xno; then 25187 # Now execute the test 25188 25189 # Extract the first word of "javac", so it can be a program name with args. 25190 set dummy javac; ac_word=$2 25191 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 25192 $as_echo_n "checking for $ac_word... " >&6; } 25193 if ${ac_cv_path_JAVAC_CHECK+:} false; then : 25194 $as_echo_n "(cached) " >&6 25195 else 25196 case $JAVAC_CHECK in 25197 [\\/]* | ?:[\\/]*) 25198 ac_cv_path_JAVAC_CHECK="$JAVAC_CHECK" # Let the user override the test with a path. 25199 ;; 25200 *) 25201 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 25202 for as_dir in $PATH 25203 do 25204 IFS=$as_save_IFS 25205 test -z "$as_dir" && as_dir=. 25206 for ac_exec_ext in '' $ac_executable_extensions; do 25207 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 25208 ac_cv_path_JAVAC_CHECK="$as_dir/$ac_word$ac_exec_ext" 25209 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 25210 break 2 25211 fi 25212 done 25213 done 25214 IFS=$as_save_IFS 25215 25216 ;; 25217 esac 25218 fi 25219 JAVAC_CHECK=$ac_cv_path_JAVAC_CHECK 25220 if test -n "$JAVAC_CHECK"; then 25221 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVAC_CHECK" >&5 25222 $as_echo "$JAVAC_CHECK" >&6; } 25223 else 25224 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 25225 $as_echo "no" >&6; } 25226 fi 25227 25228 25229 # Extract the first word of "java", so it can be a program name with args. 25230 set dummy java; ac_word=$2 25231 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 25232 $as_echo_n "checking for $ac_word... " >&6; } 25233 if ${ac_cv_path_JAVA_CHECK+:} false; then : 25234 $as_echo_n "(cached) " >&6 25235 else 25236 case $JAVA_CHECK in 25237 [\\/]* | ?:[\\/]*) 25238 ac_cv_path_JAVA_CHECK="$JAVA_CHECK" # Let the user override the test with a path. 25239 ;; 25240 *) 25241 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 25242 for as_dir in $PATH 25243 do 25244 IFS=$as_save_IFS 25245 test -z "$as_dir" && as_dir=. 25246 for ac_exec_ext in '' $ac_executable_extensions; do 25247 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 25248 ac_cv_path_JAVA_CHECK="$as_dir/$ac_word$ac_exec_ext" 25249 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 25250 break 2 25251 fi 25252 done 25253 done 25254 IFS=$as_save_IFS 25255 25256 ;; 25257 esac 25258 fi 25259 JAVA_CHECK=$ac_cv_path_JAVA_CHECK 25260 if test -n "$JAVA_CHECK"; then 25261 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVA_CHECK" >&5 25262 $as_echo "$JAVA_CHECK" >&6; } 25263 else 25264 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 25265 $as_echo "no" >&6; } 25266 fi 25267 25268 25269 BINARY="$JAVAC_CHECK" 25270 if test "x$JAVAC_CHECK" = x; then 25271 BINARY="$JAVA_CHECK" 25272 fi 25273 if test "x$BINARY" != x; then 25274 # So there is a java(c) binary, it might be part of a JDK. 25275 # Lets find the JDK/JRE directory by following symbolic links. 25276 # Linux/GNU systems often have links from /usr/bin/java to 25277 # /etc/alternatives/java to the real JDK binary. 25278 25279 if test "x$OPENJDK_BUILD_OS" != xwindows; then 25280 # Follow a chain of symbolic links. Use readlink 25281 # where it exists, else fall back to horribly 25282 # complicated shell code. 25283 if test "x$READLINK_TESTED" != yes; then 25284 # On MacOSX there is a readlink tool with a different 25285 # purpose than the GNU readlink tool. Check the found readlink. 25286 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 25287 if test "x$ISGNU" = x; then 25288 # A readlink that we do not know how to use. 25289 # Are there other non-GNU readlinks out there? 25290 READLINK_TESTED=yes 25291 READLINK= 25292 fi 25293 fi 25294 25295 if test "x$READLINK" != x; then 25296 BINARY=`$READLINK -f $BINARY` 25297 else 25298 # Save the current directory for restoring afterwards 25299 STARTDIR=$PWD 25300 COUNTER=0 25301 sym_link_dir=`$DIRNAME $BINARY` 25302 sym_link_file=`$BASENAME $BINARY` 25303 cd $sym_link_dir 25304 # Use -P flag to resolve symlinks in directories. 25305 cd `$THEPWDCMD -P` 25306 sym_link_dir=`$THEPWDCMD -P` 25307 # Resolve file symlinks 25308 while test $COUNTER -lt 20; do 25309 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 25310 if test "x$ISLINK" == x; then 25311 # This is not a symbolic link! We are done! 25312 break 25313 fi 25314 # Again resolve directory symlinks since the target of the just found 25315 # link could be in a different directory 25316 cd `$DIRNAME $ISLINK` 25317 sym_link_dir=`$THEPWDCMD -P` 25318 sym_link_file=`$BASENAME $ISLINK` 25319 let COUNTER=COUNTER+1 25320 done 25321 cd $STARTDIR 25322 BINARY=$sym_link_dir/$sym_link_file 25323 fi 25324 fi 25325 25326 BOOT_JDK=`dirname "$BINARY"` 25327 BOOT_JDK=`cd "$BOOT_JDK/.."; pwd` 25328 if test -x "$BOOT_JDK/bin/javac" && test -x "$BOOT_JDK/bin/java"; then 25329 # Looks like we found ourselves an JDK 25330 BOOT_JDK_FOUND=maybe 25331 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using java(c) in PATH" >&5 25332 $as_echo "$as_me: Found potential Boot JDK using java(c) in PATH" >&6;} 25333 fi 25334 fi 25335 25336 25337 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 25338 if test "x$BOOT_JDK_FOUND" = xmaybe; then 25339 # Do we have a bin/java? 25340 if test ! -x "$BOOT_JDK/bin/java"; then 25341 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 25342 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 25343 BOOT_JDK_FOUND=no 25344 else 25345 # Do we have a bin/javac? 25346 if test ! -x "$BOOT_JDK/bin/javac"; then 25347 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 25348 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 25349 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 25350 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 25351 BOOT_JDK_FOUND=no 25352 else 25353 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 25354 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 25355 25356 # Extra M4 quote needed to protect [] in grep expression. 25357 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 25358 if test "x$FOUND_CORRECT_VERSION" = x; then 25359 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 25360 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 25361 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 25362 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 25363 BOOT_JDK_FOUND=no 25364 else 25365 # We're done! :-) 25366 BOOT_JDK_FOUND=yes 25367 25368 # Only process if variable expands to non-empty 25369 25370 if test "x$BOOT_JDK" != x; then 25371 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25372 25373 # Input might be given as Windows format, start by converting to 25374 # unix format. 25375 path="$BOOT_JDK" 25376 new_path=`$CYGPATH -u "$path"` 25377 25378 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 25379 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 25380 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 25381 # "foo.exe" is OK but "foo" is an error. 25382 # 25383 # This test is therefore slightly more accurate than "test -f" to check for file precense. 25384 # It is also a way to make sure we got the proper file name for the real test later on. 25385 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 25386 if test "x$test_shortpath" = x; then 25387 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25388 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25389 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 25390 fi 25391 25392 # Call helper function which possibly converts this using DOS-style short mode. 25393 # If so, the updated path is stored in $new_path. 25394 25395 input_path="$new_path" 25396 # Check if we need to convert this using DOS-style short mode. If the path 25397 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25398 # take no chances and rewrite it. 25399 # Note: m4 eats our [], so we need to use [ and ] instead. 25400 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 25401 if test "x$has_forbidden_chars" != x; then 25402 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25403 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 25404 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 25405 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 25406 # Going to short mode and back again did indeed matter. Since short mode is 25407 # case insensitive, let's make it lowercase to improve readability. 25408 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25409 # Now convert it back to Unix-style (cygpath) 25410 input_path=`$CYGPATH -u "$shortmode_path"` 25411 new_path="$input_path" 25412 fi 25413 fi 25414 25415 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 25416 if test "x$test_cygdrive_prefix" = x; then 25417 # As a simple fix, exclude /usr/bin since it's not a real path. 25418 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 25419 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 25420 # a path prefixed by /cygdrive for fixpath to work. 25421 new_path="$CYGWIN_ROOT_PATH$input_path" 25422 fi 25423 fi 25424 25425 25426 if test "x$path" != "x$new_path"; then 25427 BOOT_JDK="$new_path" 25428 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25429 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25430 fi 25431 25432 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25433 25434 path="$BOOT_JDK" 25435 has_colon=`$ECHO $path | $GREP ^.:` 25436 new_path="$path" 25437 if test "x$has_colon" = x; then 25438 # Not in mixed or Windows style, start by that. 25439 new_path=`cmd //c echo $path` 25440 fi 25441 25442 25443 input_path="$new_path" 25444 # Check if we need to convert this using DOS-style short mode. If the path 25445 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25446 # take no chances and rewrite it. 25447 # Note: m4 eats our [], so we need to use [ and ] instead. 25448 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 25449 if test "x$has_forbidden_chars" != x; then 25450 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25451 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25452 fi 25453 25454 25455 windows_path="$new_path" 25456 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25457 unix_path=`$CYGPATH -u "$windows_path"` 25458 new_path="$unix_path" 25459 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25460 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25461 new_path="$unix_path" 25462 fi 25463 25464 if test "x$path" != "x$new_path"; then 25465 BOOT_JDK="$new_path" 25466 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25467 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25468 fi 25469 25470 # Save the first 10 bytes of this path to the storage, so fixpath can work. 25471 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 25472 25473 else 25474 # We're on a unix platform. Hooray! :) 25475 path="$BOOT_JDK" 25476 has_space=`$ECHO "$path" | $GREP " "` 25477 if test "x$has_space" != x; then 25478 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25479 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25480 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 25481 fi 25482 25483 # Use eval to expand a potential ~ 25484 eval path="$path" 25485 if test ! -f "$path" && test ! -d "$path"; then 25486 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 25487 fi 25488 25489 if test -d "$path"; then 25490 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 25491 else 25492 dir="`$DIRNAME "$path"`" 25493 base="`$BASENAME "$path"`" 25494 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 25495 fi 25496 fi 25497 fi 25498 25499 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 25500 $as_echo_n "checking for Boot JDK... " >&6; } 25501 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 25502 $as_echo "$BOOT_JDK" >&6; } 25503 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 25504 $as_echo_n "checking Boot JDK version... " >&6; } 25505 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 25506 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 25507 $as_echo "$BOOT_JDK_VERSION" >&6; } 25508 fi # end check jdk version 25509 fi # end check javac 25510 fi # end check java 25511 fi # end check boot jdk found 25512 fi 25513 25514 25515 # Test: Is there a JDK installed in default, well-known locations? 25516 25517 if test "x$BOOT_JDK_FOUND" = xno; then 25518 # Now execute the test 25519 25520 if test "x$OPENJDK_TARGET_OS" = xwindows; then 25521 25522 if test "x$BOOT_JDK_FOUND" = xno; then 25523 # Now execute the test 25524 25525 if test "x$ProgramW6432" != x; then 25526 VIRTUAL_DIR="$ProgramW6432/Java" 25527 25528 windows_path="$VIRTUAL_DIR" 25529 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25530 unix_path=`$CYGPATH -u "$windows_path"` 25531 VIRTUAL_DIR="$unix_path" 25532 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25533 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25534 VIRTUAL_DIR="$unix_path" 25535 fi 25536 25537 25538 BOOT_JDK_PREFIX="$VIRTUAL_DIR" 25539 BOOT_JDK_SUFFIX="" 25540 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 25541 if test "x$ALL_JDKS_FOUND" != x; then 25542 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 25543 25544 if test "x$BOOT_JDK_FOUND" = xno; then 25545 # Now execute the test 25546 25547 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 25548 if test -d "$BOOT_JDK"; then 25549 BOOT_JDK_FOUND=maybe 25550 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 25551 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 25552 fi 25553 25554 25555 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 25556 if test "x$BOOT_JDK_FOUND" = xmaybe; then 25557 # Do we have a bin/java? 25558 if test ! -x "$BOOT_JDK/bin/java"; then 25559 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 25560 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 25561 BOOT_JDK_FOUND=no 25562 else 25563 # Do we have a bin/javac? 25564 if test ! -x "$BOOT_JDK/bin/javac"; then 25565 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 25566 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 25567 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 25568 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 25569 BOOT_JDK_FOUND=no 25570 else 25571 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 25572 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 25573 25574 # Extra M4 quote needed to protect [] in grep expression. 25575 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 25576 if test "x$FOUND_CORRECT_VERSION" = x; then 25577 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 25578 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 25579 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 25580 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 25581 BOOT_JDK_FOUND=no 25582 else 25583 # We're done! :-) 25584 BOOT_JDK_FOUND=yes 25585 25586 # Only process if variable expands to non-empty 25587 25588 if test "x$BOOT_JDK" != x; then 25589 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25590 25591 # Input might be given as Windows format, start by converting to 25592 # unix format. 25593 path="$BOOT_JDK" 25594 new_path=`$CYGPATH -u "$path"` 25595 25596 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 25597 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 25598 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 25599 # "foo.exe" is OK but "foo" is an error. 25600 # 25601 # This test is therefore slightly more accurate than "test -f" to check for file precense. 25602 # It is also a way to make sure we got the proper file name for the real test later on. 25603 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 25604 if test "x$test_shortpath" = x; then 25605 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25606 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25607 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 25608 fi 25609 25610 # Call helper function which possibly converts this using DOS-style short mode. 25611 # If so, the updated path is stored in $new_path. 25612 25613 input_path="$new_path" 25614 # Check if we need to convert this using DOS-style short mode. If the path 25615 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25616 # take no chances and rewrite it. 25617 # Note: m4 eats our [], so we need to use [ and ] instead. 25618 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 25619 if test "x$has_forbidden_chars" != x; then 25620 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25621 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 25622 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 25623 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 25624 # Going to short mode and back again did indeed matter. Since short mode is 25625 # case insensitive, let's make it lowercase to improve readability. 25626 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25627 # Now convert it back to Unix-style (cygpath) 25628 input_path=`$CYGPATH -u "$shortmode_path"` 25629 new_path="$input_path" 25630 fi 25631 fi 25632 25633 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 25634 if test "x$test_cygdrive_prefix" = x; then 25635 # As a simple fix, exclude /usr/bin since it's not a real path. 25636 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 25637 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 25638 # a path prefixed by /cygdrive for fixpath to work. 25639 new_path="$CYGWIN_ROOT_PATH$input_path" 25640 fi 25641 fi 25642 25643 25644 if test "x$path" != "x$new_path"; then 25645 BOOT_JDK="$new_path" 25646 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25647 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25648 fi 25649 25650 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25651 25652 path="$BOOT_JDK" 25653 has_colon=`$ECHO $path | $GREP ^.:` 25654 new_path="$path" 25655 if test "x$has_colon" = x; then 25656 # Not in mixed or Windows style, start by that. 25657 new_path=`cmd //c echo $path` 25658 fi 25659 25660 25661 input_path="$new_path" 25662 # Check if we need to convert this using DOS-style short mode. If the path 25663 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25664 # take no chances and rewrite it. 25665 # Note: m4 eats our [], so we need to use [ and ] instead. 25666 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 25667 if test "x$has_forbidden_chars" != x; then 25668 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25669 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25670 fi 25671 25672 25673 windows_path="$new_path" 25674 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25675 unix_path=`$CYGPATH -u "$windows_path"` 25676 new_path="$unix_path" 25677 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25678 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25679 new_path="$unix_path" 25680 fi 25681 25682 if test "x$path" != "x$new_path"; then 25683 BOOT_JDK="$new_path" 25684 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25685 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25686 fi 25687 25688 # Save the first 10 bytes of this path to the storage, so fixpath can work. 25689 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 25690 25691 else 25692 # We're on a unix platform. Hooray! :) 25693 path="$BOOT_JDK" 25694 has_space=`$ECHO "$path" | $GREP " "` 25695 if test "x$has_space" != x; then 25696 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25697 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25698 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 25699 fi 25700 25701 # Use eval to expand a potential ~ 25702 eval path="$path" 25703 if test ! -f "$path" && test ! -d "$path"; then 25704 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 25705 fi 25706 25707 if test -d "$path"; then 25708 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 25709 else 25710 dir="`$DIRNAME "$path"`" 25711 base="`$BASENAME "$path"`" 25712 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 25713 fi 25714 fi 25715 fi 25716 25717 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 25718 $as_echo_n "checking for Boot JDK... " >&6; } 25719 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 25720 $as_echo "$BOOT_JDK" >&6; } 25721 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 25722 $as_echo_n "checking Boot JDK version... " >&6; } 25723 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 25724 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 25725 $as_echo "$BOOT_JDK_VERSION" >&6; } 25726 fi # end check jdk version 25727 fi # end check javac 25728 fi # end check java 25729 fi # end check boot jdk found 25730 fi 25731 25732 done 25733 fi 25734 25735 fi 25736 25737 25738 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 25739 if test "x$BOOT_JDK_FOUND" = xmaybe; then 25740 # Do we have a bin/java? 25741 if test ! -x "$BOOT_JDK/bin/java"; then 25742 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 25743 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 25744 BOOT_JDK_FOUND=no 25745 else 25746 # Do we have a bin/javac? 25747 if test ! -x "$BOOT_JDK/bin/javac"; then 25748 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 25749 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 25750 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 25751 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 25752 BOOT_JDK_FOUND=no 25753 else 25754 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 25755 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 25756 25757 # Extra M4 quote needed to protect [] in grep expression. 25758 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 25759 if test "x$FOUND_CORRECT_VERSION" = x; then 25760 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 25761 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 25762 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 25763 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 25764 BOOT_JDK_FOUND=no 25765 else 25766 # We're done! :-) 25767 BOOT_JDK_FOUND=yes 25768 25769 # Only process if variable expands to non-empty 25770 25771 if test "x$BOOT_JDK" != x; then 25772 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25773 25774 # Input might be given as Windows format, start by converting to 25775 # unix format. 25776 path="$BOOT_JDK" 25777 new_path=`$CYGPATH -u "$path"` 25778 25779 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 25780 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 25781 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 25782 # "foo.exe" is OK but "foo" is an error. 25783 # 25784 # This test is therefore slightly more accurate than "test -f" to check for file precense. 25785 # It is also a way to make sure we got the proper file name for the real test later on. 25786 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 25787 if test "x$test_shortpath" = x; then 25788 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25789 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25790 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 25791 fi 25792 25793 # Call helper function which possibly converts this using DOS-style short mode. 25794 # If so, the updated path is stored in $new_path. 25795 25796 input_path="$new_path" 25797 # Check if we need to convert this using DOS-style short mode. If the path 25798 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25799 # take no chances and rewrite it. 25800 # Note: m4 eats our [], so we need to use [ and ] instead. 25801 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 25802 if test "x$has_forbidden_chars" != x; then 25803 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25804 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 25805 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 25806 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 25807 # Going to short mode and back again did indeed matter. Since short mode is 25808 # case insensitive, let's make it lowercase to improve readability. 25809 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25810 # Now convert it back to Unix-style (cygpath) 25811 input_path=`$CYGPATH -u "$shortmode_path"` 25812 new_path="$input_path" 25813 fi 25814 fi 25815 25816 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 25817 if test "x$test_cygdrive_prefix" = x; then 25818 # As a simple fix, exclude /usr/bin since it's not a real path. 25819 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 25820 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 25821 # a path prefixed by /cygdrive for fixpath to work. 25822 new_path="$CYGWIN_ROOT_PATH$input_path" 25823 fi 25824 fi 25825 25826 25827 if test "x$path" != "x$new_path"; then 25828 BOOT_JDK="$new_path" 25829 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25830 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25831 fi 25832 25833 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25834 25835 path="$BOOT_JDK" 25836 has_colon=`$ECHO $path | $GREP ^.:` 25837 new_path="$path" 25838 if test "x$has_colon" = x; then 25839 # Not in mixed or Windows style, start by that. 25840 new_path=`cmd //c echo $path` 25841 fi 25842 25843 25844 input_path="$new_path" 25845 # Check if we need to convert this using DOS-style short mode. If the path 25846 # contains just simple characters, use it. Otherwise (spaces, weird characters), 25847 # take no chances and rewrite it. 25848 # Note: m4 eats our [], so we need to use [ and ] instead. 25849 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 25850 if test "x$has_forbidden_chars" != x; then 25851 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 25852 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 25853 fi 25854 25855 25856 windows_path="$new_path" 25857 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25858 unix_path=`$CYGPATH -u "$windows_path"` 25859 new_path="$unix_path" 25860 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25861 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25862 new_path="$unix_path" 25863 fi 25864 25865 if test "x$path" != "x$new_path"; then 25866 BOOT_JDK="$new_path" 25867 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 25868 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 25869 fi 25870 25871 # Save the first 10 bytes of this path to the storage, so fixpath can work. 25872 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 25873 25874 else 25875 # We're on a unix platform. Hooray! :) 25876 path="$BOOT_JDK" 25877 has_space=`$ECHO "$path" | $GREP " "` 25878 if test "x$has_space" != x; then 25879 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 25880 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 25881 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 25882 fi 25883 25884 # Use eval to expand a potential ~ 25885 eval path="$path" 25886 if test ! -f "$path" && test ! -d "$path"; then 25887 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 25888 fi 25889 25890 if test -d "$path"; then 25891 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 25892 else 25893 dir="`$DIRNAME "$path"`" 25894 base="`$BASENAME "$path"`" 25895 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 25896 fi 25897 fi 25898 fi 25899 25900 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 25901 $as_echo_n "checking for Boot JDK... " >&6; } 25902 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 25903 $as_echo "$BOOT_JDK" >&6; } 25904 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 25905 $as_echo_n "checking Boot JDK version... " >&6; } 25906 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 25907 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 25908 $as_echo "$BOOT_JDK_VERSION" >&6; } 25909 fi # end check jdk version 25910 fi # end check javac 25911 fi # end check java 25912 fi # end check boot jdk found 25913 fi 25914 25915 25916 if test "x$BOOT_JDK_FOUND" = xno; then 25917 # Now execute the test 25918 25919 if test "x$PROGRAMW6432" != x; then 25920 VIRTUAL_DIR="$PROGRAMW6432/Java" 25921 25922 windows_path="$VIRTUAL_DIR" 25923 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25924 unix_path=`$CYGPATH -u "$windows_path"` 25925 VIRTUAL_DIR="$unix_path" 25926 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 25927 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 25928 VIRTUAL_DIR="$unix_path" 25929 fi 25930 25931 25932 BOOT_JDK_PREFIX="$VIRTUAL_DIR" 25933 BOOT_JDK_SUFFIX="" 25934 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 25935 if test "x$ALL_JDKS_FOUND" != x; then 25936 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 25937 25938 if test "x$BOOT_JDK_FOUND" = xno; then 25939 # Now execute the test 25940 25941 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 25942 if test -d "$BOOT_JDK"; then 25943 BOOT_JDK_FOUND=maybe 25944 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 25945 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 25946 fi 25947 25948 25949 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 25950 if test "x$BOOT_JDK_FOUND" = xmaybe; then 25951 # Do we have a bin/java? 25952 if test ! -x "$BOOT_JDK/bin/java"; then 25953 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 25954 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 25955 BOOT_JDK_FOUND=no 25956 else 25957 # Do we have a bin/javac? 25958 if test ! -x "$BOOT_JDK/bin/javac"; then 25959 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 25960 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 25961 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 25962 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 25963 BOOT_JDK_FOUND=no 25964 else 25965 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 25966 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 25967 25968 # Extra M4 quote needed to protect [] in grep expression. 25969 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 25970 if test "x$FOUND_CORRECT_VERSION" = x; then 25971 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 25972 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 25973 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 25974 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 25975 BOOT_JDK_FOUND=no 25976 else 25977 # We're done! :-) 25978 BOOT_JDK_FOUND=yes 25979 25980 # Only process if variable expands to non-empty 25981 25982 if test "x$BOOT_JDK" != x; then 25983 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 25984 25985 # Input might be given as Windows format, start by converting to 25986 # unix format. 25987 path="$BOOT_JDK" 25988 new_path=`$CYGPATH -u "$path"` 25989 25990 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 25991 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 25992 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 25993 # "foo.exe" is OK but "foo" is an error. 25994 # 25995 # This test is therefore slightly more accurate than "test -f" to check for file precense. 25996 # It is also a way to make sure we got the proper file name for the real test later on. 25997 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 25998 if test "x$test_shortpath" = x; then 25999 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26000 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26001 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 26002 fi 26003 26004 # Call helper function which possibly converts this using DOS-style short mode. 26005 # If so, the updated path is stored in $new_path. 26006 26007 input_path="$new_path" 26008 # Check if we need to convert this using DOS-style short mode. If the path 26009 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26010 # take no chances and rewrite it. 26011 # Note: m4 eats our [], so we need to use [ and ] instead. 26012 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26013 if test "x$has_forbidden_chars" != x; then 26014 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26015 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26016 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26017 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26018 # Going to short mode and back again did indeed matter. Since short mode is 26019 # case insensitive, let's make it lowercase to improve readability. 26020 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26021 # Now convert it back to Unix-style (cygpath) 26022 input_path=`$CYGPATH -u "$shortmode_path"` 26023 new_path="$input_path" 26024 fi 26025 fi 26026 26027 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26028 if test "x$test_cygdrive_prefix" = x; then 26029 # As a simple fix, exclude /usr/bin since it's not a real path. 26030 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 26031 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26032 # a path prefixed by /cygdrive for fixpath to work. 26033 new_path="$CYGWIN_ROOT_PATH$input_path" 26034 fi 26035 fi 26036 26037 26038 if test "x$path" != "x$new_path"; then 26039 BOOT_JDK="$new_path" 26040 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26041 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26042 fi 26043 26044 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26045 26046 path="$BOOT_JDK" 26047 has_colon=`$ECHO $path | $GREP ^.:` 26048 new_path="$path" 26049 if test "x$has_colon" = x; then 26050 # Not in mixed or Windows style, start by that. 26051 new_path=`cmd //c echo $path` 26052 fi 26053 26054 26055 input_path="$new_path" 26056 # Check if we need to convert this using DOS-style short mode. If the path 26057 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26058 # take no chances and rewrite it. 26059 # Note: m4 eats our [], so we need to use [ and ] instead. 26060 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26061 if test "x$has_forbidden_chars" != x; then 26062 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26063 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26064 fi 26065 26066 26067 windows_path="$new_path" 26068 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26069 unix_path=`$CYGPATH -u "$windows_path"` 26070 new_path="$unix_path" 26071 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26072 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26073 new_path="$unix_path" 26074 fi 26075 26076 if test "x$path" != "x$new_path"; then 26077 BOOT_JDK="$new_path" 26078 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26079 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26080 fi 26081 26082 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26083 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26084 26085 else 26086 # We're on a unix platform. Hooray! :) 26087 path="$BOOT_JDK" 26088 has_space=`$ECHO "$path" | $GREP " "` 26089 if test "x$has_space" != x; then 26090 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26091 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26092 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 26093 fi 26094 26095 # Use eval to expand a potential ~ 26096 eval path="$path" 26097 if test ! -f "$path" && test ! -d "$path"; then 26098 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 26099 fi 26100 26101 if test -d "$path"; then 26102 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 26103 else 26104 dir="`$DIRNAME "$path"`" 26105 base="`$BASENAME "$path"`" 26106 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 26107 fi 26108 fi 26109 fi 26110 26111 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 26112 $as_echo_n "checking for Boot JDK... " >&6; } 26113 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 26114 $as_echo "$BOOT_JDK" >&6; } 26115 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 26116 $as_echo_n "checking Boot JDK version... " >&6; } 26117 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 26118 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 26119 $as_echo "$BOOT_JDK_VERSION" >&6; } 26120 fi # end check jdk version 26121 fi # end check javac 26122 fi # end check java 26123 fi # end check boot jdk found 26124 fi 26125 26126 done 26127 fi 26128 26129 fi 26130 26131 26132 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 26133 if test "x$BOOT_JDK_FOUND" = xmaybe; then 26134 # Do we have a bin/java? 26135 if test ! -x "$BOOT_JDK/bin/java"; then 26136 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 26137 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 26138 BOOT_JDK_FOUND=no 26139 else 26140 # Do we have a bin/javac? 26141 if test ! -x "$BOOT_JDK/bin/javac"; then 26142 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 26143 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 26144 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 26145 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 26146 BOOT_JDK_FOUND=no 26147 else 26148 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 26149 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 26150 26151 # Extra M4 quote needed to protect [] in grep expression. 26152 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 26153 if test "x$FOUND_CORRECT_VERSION" = x; then 26154 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 26155 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 26156 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 26157 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 26158 BOOT_JDK_FOUND=no 26159 else 26160 # We're done! :-) 26161 BOOT_JDK_FOUND=yes 26162 26163 # Only process if variable expands to non-empty 26164 26165 if test "x$BOOT_JDK" != x; then 26166 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26167 26168 # Input might be given as Windows format, start by converting to 26169 # unix format. 26170 path="$BOOT_JDK" 26171 new_path=`$CYGPATH -u "$path"` 26172 26173 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26174 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26175 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26176 # "foo.exe" is OK but "foo" is an error. 26177 # 26178 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26179 # It is also a way to make sure we got the proper file name for the real test later on. 26180 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26181 if test "x$test_shortpath" = x; then 26182 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26183 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26184 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 26185 fi 26186 26187 # Call helper function which possibly converts this using DOS-style short mode. 26188 # If so, the updated path is stored in $new_path. 26189 26190 input_path="$new_path" 26191 # Check if we need to convert this using DOS-style short mode. If the path 26192 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26193 # take no chances and rewrite it. 26194 # Note: m4 eats our [], so we need to use [ and ] instead. 26195 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26196 if test "x$has_forbidden_chars" != x; then 26197 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26198 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26199 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26200 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26201 # Going to short mode and back again did indeed matter. Since short mode is 26202 # case insensitive, let's make it lowercase to improve readability. 26203 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26204 # Now convert it back to Unix-style (cygpath) 26205 input_path=`$CYGPATH -u "$shortmode_path"` 26206 new_path="$input_path" 26207 fi 26208 fi 26209 26210 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26211 if test "x$test_cygdrive_prefix" = x; then 26212 # As a simple fix, exclude /usr/bin since it's not a real path. 26213 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 26214 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26215 # a path prefixed by /cygdrive for fixpath to work. 26216 new_path="$CYGWIN_ROOT_PATH$input_path" 26217 fi 26218 fi 26219 26220 26221 if test "x$path" != "x$new_path"; then 26222 BOOT_JDK="$new_path" 26223 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26224 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26225 fi 26226 26227 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26228 26229 path="$BOOT_JDK" 26230 has_colon=`$ECHO $path | $GREP ^.:` 26231 new_path="$path" 26232 if test "x$has_colon" = x; then 26233 # Not in mixed or Windows style, start by that. 26234 new_path=`cmd //c echo $path` 26235 fi 26236 26237 26238 input_path="$new_path" 26239 # Check if we need to convert this using DOS-style short mode. If the path 26240 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26241 # take no chances and rewrite it. 26242 # Note: m4 eats our [], so we need to use [ and ] instead. 26243 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26244 if test "x$has_forbidden_chars" != x; then 26245 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26246 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26247 fi 26248 26249 26250 windows_path="$new_path" 26251 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26252 unix_path=`$CYGPATH -u "$windows_path"` 26253 new_path="$unix_path" 26254 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26255 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26256 new_path="$unix_path" 26257 fi 26258 26259 if test "x$path" != "x$new_path"; then 26260 BOOT_JDK="$new_path" 26261 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26262 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26263 fi 26264 26265 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26266 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26267 26268 else 26269 # We're on a unix platform. Hooray! :) 26270 path="$BOOT_JDK" 26271 has_space=`$ECHO "$path" | $GREP " "` 26272 if test "x$has_space" != x; then 26273 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26274 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26275 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 26276 fi 26277 26278 # Use eval to expand a potential ~ 26279 eval path="$path" 26280 if test ! -f "$path" && test ! -d "$path"; then 26281 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 26282 fi 26283 26284 if test -d "$path"; then 26285 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 26286 else 26287 dir="`$DIRNAME "$path"`" 26288 base="`$BASENAME "$path"`" 26289 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 26290 fi 26291 fi 26292 fi 26293 26294 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 26295 $as_echo_n "checking for Boot JDK... " >&6; } 26296 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 26297 $as_echo "$BOOT_JDK" >&6; } 26298 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 26299 $as_echo_n "checking Boot JDK version... " >&6; } 26300 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 26301 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 26302 $as_echo "$BOOT_JDK_VERSION" >&6; } 26303 fi # end check jdk version 26304 fi # end check javac 26305 fi # end check java 26306 fi # end check boot jdk found 26307 fi 26308 26309 26310 if test "x$BOOT_JDK_FOUND" = xno; then 26311 # Now execute the test 26312 26313 if test "x$PROGRAMFILES" != x; then 26314 VIRTUAL_DIR="$PROGRAMFILES/Java" 26315 26316 windows_path="$VIRTUAL_DIR" 26317 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26318 unix_path=`$CYGPATH -u "$windows_path"` 26319 VIRTUAL_DIR="$unix_path" 26320 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26321 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26322 VIRTUAL_DIR="$unix_path" 26323 fi 26324 26325 26326 BOOT_JDK_PREFIX="$VIRTUAL_DIR" 26327 BOOT_JDK_SUFFIX="" 26328 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 26329 if test "x$ALL_JDKS_FOUND" != x; then 26330 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 26331 26332 if test "x$BOOT_JDK_FOUND" = xno; then 26333 # Now execute the test 26334 26335 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 26336 if test -d "$BOOT_JDK"; then 26337 BOOT_JDK_FOUND=maybe 26338 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 26339 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 26340 fi 26341 26342 26343 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 26344 if test "x$BOOT_JDK_FOUND" = xmaybe; then 26345 # Do we have a bin/java? 26346 if test ! -x "$BOOT_JDK/bin/java"; then 26347 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 26348 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 26349 BOOT_JDK_FOUND=no 26350 else 26351 # Do we have a bin/javac? 26352 if test ! -x "$BOOT_JDK/bin/javac"; then 26353 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 26354 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 26355 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 26356 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 26357 BOOT_JDK_FOUND=no 26358 else 26359 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 26360 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 26361 26362 # Extra M4 quote needed to protect [] in grep expression. 26363 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 26364 if test "x$FOUND_CORRECT_VERSION" = x; then 26365 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 26366 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 26367 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 26368 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 26369 BOOT_JDK_FOUND=no 26370 else 26371 # We're done! :-) 26372 BOOT_JDK_FOUND=yes 26373 26374 # Only process if variable expands to non-empty 26375 26376 if test "x$BOOT_JDK" != x; then 26377 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26378 26379 # Input might be given as Windows format, start by converting to 26380 # unix format. 26381 path="$BOOT_JDK" 26382 new_path=`$CYGPATH -u "$path"` 26383 26384 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26385 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26386 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26387 # "foo.exe" is OK but "foo" is an error. 26388 # 26389 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26390 # It is also a way to make sure we got the proper file name for the real test later on. 26391 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26392 if test "x$test_shortpath" = x; then 26393 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26394 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26395 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 26396 fi 26397 26398 # Call helper function which possibly converts this using DOS-style short mode. 26399 # If so, the updated path is stored in $new_path. 26400 26401 input_path="$new_path" 26402 # Check if we need to convert this using DOS-style short mode. If the path 26403 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26404 # take no chances and rewrite it. 26405 # Note: m4 eats our [], so we need to use [ and ] instead. 26406 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26407 if test "x$has_forbidden_chars" != x; then 26408 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26409 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26410 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26411 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26412 # Going to short mode and back again did indeed matter. Since short mode is 26413 # case insensitive, let's make it lowercase to improve readability. 26414 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26415 # Now convert it back to Unix-style (cygpath) 26416 input_path=`$CYGPATH -u "$shortmode_path"` 26417 new_path="$input_path" 26418 fi 26419 fi 26420 26421 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26422 if test "x$test_cygdrive_prefix" = x; then 26423 # As a simple fix, exclude /usr/bin since it's not a real path. 26424 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 26425 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26426 # a path prefixed by /cygdrive for fixpath to work. 26427 new_path="$CYGWIN_ROOT_PATH$input_path" 26428 fi 26429 fi 26430 26431 26432 if test "x$path" != "x$new_path"; then 26433 BOOT_JDK="$new_path" 26434 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26435 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26436 fi 26437 26438 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26439 26440 path="$BOOT_JDK" 26441 has_colon=`$ECHO $path | $GREP ^.:` 26442 new_path="$path" 26443 if test "x$has_colon" = x; then 26444 # Not in mixed or Windows style, start by that. 26445 new_path=`cmd //c echo $path` 26446 fi 26447 26448 26449 input_path="$new_path" 26450 # Check if we need to convert this using DOS-style short mode. If the path 26451 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26452 # take no chances and rewrite it. 26453 # Note: m4 eats our [], so we need to use [ and ] instead. 26454 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26455 if test "x$has_forbidden_chars" != x; then 26456 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26457 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26458 fi 26459 26460 26461 windows_path="$new_path" 26462 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26463 unix_path=`$CYGPATH -u "$windows_path"` 26464 new_path="$unix_path" 26465 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26466 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26467 new_path="$unix_path" 26468 fi 26469 26470 if test "x$path" != "x$new_path"; then 26471 BOOT_JDK="$new_path" 26472 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26473 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26474 fi 26475 26476 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26477 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26478 26479 else 26480 # We're on a unix platform. Hooray! :) 26481 path="$BOOT_JDK" 26482 has_space=`$ECHO "$path" | $GREP " "` 26483 if test "x$has_space" != x; then 26484 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26485 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26486 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 26487 fi 26488 26489 # Use eval to expand a potential ~ 26490 eval path="$path" 26491 if test ! -f "$path" && test ! -d "$path"; then 26492 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 26493 fi 26494 26495 if test -d "$path"; then 26496 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 26497 else 26498 dir="`$DIRNAME "$path"`" 26499 base="`$BASENAME "$path"`" 26500 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 26501 fi 26502 fi 26503 fi 26504 26505 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 26506 $as_echo_n "checking for Boot JDK... " >&6; } 26507 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 26508 $as_echo "$BOOT_JDK" >&6; } 26509 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 26510 $as_echo_n "checking Boot JDK version... " >&6; } 26511 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 26512 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 26513 $as_echo "$BOOT_JDK_VERSION" >&6; } 26514 fi # end check jdk version 26515 fi # end check javac 26516 fi # end check java 26517 fi # end check boot jdk found 26518 fi 26519 26520 done 26521 fi 26522 26523 fi 26524 26525 26526 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 26527 if test "x$BOOT_JDK_FOUND" = xmaybe; then 26528 # Do we have a bin/java? 26529 if test ! -x "$BOOT_JDK/bin/java"; then 26530 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 26531 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 26532 BOOT_JDK_FOUND=no 26533 else 26534 # Do we have a bin/javac? 26535 if test ! -x "$BOOT_JDK/bin/javac"; then 26536 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 26537 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 26538 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 26539 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 26540 BOOT_JDK_FOUND=no 26541 else 26542 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 26543 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 26544 26545 # Extra M4 quote needed to protect [] in grep expression. 26546 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 26547 if test "x$FOUND_CORRECT_VERSION" = x; then 26548 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 26549 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 26550 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 26551 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 26552 BOOT_JDK_FOUND=no 26553 else 26554 # We're done! :-) 26555 BOOT_JDK_FOUND=yes 26556 26557 # Only process if variable expands to non-empty 26558 26559 if test "x$BOOT_JDK" != x; then 26560 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26561 26562 # Input might be given as Windows format, start by converting to 26563 # unix format. 26564 path="$BOOT_JDK" 26565 new_path=`$CYGPATH -u "$path"` 26566 26567 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26568 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26569 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26570 # "foo.exe" is OK but "foo" is an error. 26571 # 26572 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26573 # It is also a way to make sure we got the proper file name for the real test later on. 26574 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26575 if test "x$test_shortpath" = x; then 26576 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26577 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26578 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 26579 fi 26580 26581 # Call helper function which possibly converts this using DOS-style short mode. 26582 # If so, the updated path is stored in $new_path. 26583 26584 input_path="$new_path" 26585 # Check if we need to convert this using DOS-style short mode. If the path 26586 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26587 # take no chances and rewrite it. 26588 # Note: m4 eats our [], so we need to use [ and ] instead. 26589 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26590 if test "x$has_forbidden_chars" != x; then 26591 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26592 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26593 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26594 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26595 # Going to short mode and back again did indeed matter. Since short mode is 26596 # case insensitive, let's make it lowercase to improve readability. 26597 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26598 # Now convert it back to Unix-style (cygpath) 26599 input_path=`$CYGPATH -u "$shortmode_path"` 26600 new_path="$input_path" 26601 fi 26602 fi 26603 26604 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26605 if test "x$test_cygdrive_prefix" = x; then 26606 # As a simple fix, exclude /usr/bin since it's not a real path. 26607 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 26608 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26609 # a path prefixed by /cygdrive for fixpath to work. 26610 new_path="$CYGWIN_ROOT_PATH$input_path" 26611 fi 26612 fi 26613 26614 26615 if test "x$path" != "x$new_path"; then 26616 BOOT_JDK="$new_path" 26617 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26618 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26619 fi 26620 26621 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26622 26623 path="$BOOT_JDK" 26624 has_colon=`$ECHO $path | $GREP ^.:` 26625 new_path="$path" 26626 if test "x$has_colon" = x; then 26627 # Not in mixed or Windows style, start by that. 26628 new_path=`cmd //c echo $path` 26629 fi 26630 26631 26632 input_path="$new_path" 26633 # Check if we need to convert this using DOS-style short mode. If the path 26634 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26635 # take no chances and rewrite it. 26636 # Note: m4 eats our [], so we need to use [ and ] instead. 26637 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26638 if test "x$has_forbidden_chars" != x; then 26639 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26640 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26641 fi 26642 26643 26644 windows_path="$new_path" 26645 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26646 unix_path=`$CYGPATH -u "$windows_path"` 26647 new_path="$unix_path" 26648 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26649 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26650 new_path="$unix_path" 26651 fi 26652 26653 if test "x$path" != "x$new_path"; then 26654 BOOT_JDK="$new_path" 26655 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26656 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26657 fi 26658 26659 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26660 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26661 26662 else 26663 # We're on a unix platform. Hooray! :) 26664 path="$BOOT_JDK" 26665 has_space=`$ECHO "$path" | $GREP " "` 26666 if test "x$has_space" != x; then 26667 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26668 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26669 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 26670 fi 26671 26672 # Use eval to expand a potential ~ 26673 eval path="$path" 26674 if test ! -f "$path" && test ! -d "$path"; then 26675 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 26676 fi 26677 26678 if test -d "$path"; then 26679 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 26680 else 26681 dir="`$DIRNAME "$path"`" 26682 base="`$BASENAME "$path"`" 26683 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 26684 fi 26685 fi 26686 fi 26687 26688 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 26689 $as_echo_n "checking for Boot JDK... " >&6; } 26690 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 26691 $as_echo "$BOOT_JDK" >&6; } 26692 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 26693 $as_echo_n "checking Boot JDK version... " >&6; } 26694 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 26695 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 26696 $as_echo "$BOOT_JDK_VERSION" >&6; } 26697 fi # end check jdk version 26698 fi # end check javac 26699 fi # end check java 26700 fi # end check boot jdk found 26701 fi 26702 26703 26704 if test "x$BOOT_JDK_FOUND" = xno; then 26705 # Now execute the test 26706 26707 if test "x$ProgramFiles" != x; then 26708 VIRTUAL_DIR="$ProgramFiles/Java" 26709 26710 windows_path="$VIRTUAL_DIR" 26711 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26712 unix_path=`$CYGPATH -u "$windows_path"` 26713 VIRTUAL_DIR="$unix_path" 26714 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26715 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26716 VIRTUAL_DIR="$unix_path" 26717 fi 26718 26719 26720 BOOT_JDK_PREFIX="$VIRTUAL_DIR" 26721 BOOT_JDK_SUFFIX="" 26722 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 26723 if test "x$ALL_JDKS_FOUND" != x; then 26724 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 26725 26726 if test "x$BOOT_JDK_FOUND" = xno; then 26727 # Now execute the test 26728 26729 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 26730 if test -d "$BOOT_JDK"; then 26731 BOOT_JDK_FOUND=maybe 26732 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 26733 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 26734 fi 26735 26736 26737 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 26738 if test "x$BOOT_JDK_FOUND" = xmaybe; then 26739 # Do we have a bin/java? 26740 if test ! -x "$BOOT_JDK/bin/java"; then 26741 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 26742 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 26743 BOOT_JDK_FOUND=no 26744 else 26745 # Do we have a bin/javac? 26746 if test ! -x "$BOOT_JDK/bin/javac"; then 26747 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 26748 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 26749 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 26750 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 26751 BOOT_JDK_FOUND=no 26752 else 26753 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 26754 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 26755 26756 # Extra M4 quote needed to protect [] in grep expression. 26757 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 26758 if test "x$FOUND_CORRECT_VERSION" = x; then 26759 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 26760 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 26761 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 26762 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 26763 BOOT_JDK_FOUND=no 26764 else 26765 # We're done! :-) 26766 BOOT_JDK_FOUND=yes 26767 26768 # Only process if variable expands to non-empty 26769 26770 if test "x$BOOT_JDK" != x; then 26771 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26772 26773 # Input might be given as Windows format, start by converting to 26774 # unix format. 26775 path="$BOOT_JDK" 26776 new_path=`$CYGPATH -u "$path"` 26777 26778 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26779 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26780 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26781 # "foo.exe" is OK but "foo" is an error. 26782 # 26783 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26784 # It is also a way to make sure we got the proper file name for the real test later on. 26785 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26786 if test "x$test_shortpath" = x; then 26787 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26788 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26789 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 26790 fi 26791 26792 # Call helper function which possibly converts this using DOS-style short mode. 26793 # If so, the updated path is stored in $new_path. 26794 26795 input_path="$new_path" 26796 # Check if we need to convert this using DOS-style short mode. If the path 26797 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26798 # take no chances and rewrite it. 26799 # Note: m4 eats our [], so we need to use [ and ] instead. 26800 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26801 if test "x$has_forbidden_chars" != x; then 26802 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26803 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26804 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26805 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26806 # Going to short mode and back again did indeed matter. Since short mode is 26807 # case insensitive, let's make it lowercase to improve readability. 26808 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26809 # Now convert it back to Unix-style (cygpath) 26810 input_path=`$CYGPATH -u "$shortmode_path"` 26811 new_path="$input_path" 26812 fi 26813 fi 26814 26815 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26816 if test "x$test_cygdrive_prefix" = x; then 26817 # As a simple fix, exclude /usr/bin since it's not a real path. 26818 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 26819 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 26820 # a path prefixed by /cygdrive for fixpath to work. 26821 new_path="$CYGWIN_ROOT_PATH$input_path" 26822 fi 26823 fi 26824 26825 26826 if test "x$path" != "x$new_path"; then 26827 BOOT_JDK="$new_path" 26828 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26829 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26830 fi 26831 26832 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26833 26834 path="$BOOT_JDK" 26835 has_colon=`$ECHO $path | $GREP ^.:` 26836 new_path="$path" 26837 if test "x$has_colon" = x; then 26838 # Not in mixed or Windows style, start by that. 26839 new_path=`cmd //c echo $path` 26840 fi 26841 26842 26843 input_path="$new_path" 26844 # Check if we need to convert this using DOS-style short mode. If the path 26845 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26846 # take no chances and rewrite it. 26847 # Note: m4 eats our [], so we need to use [ and ] instead. 26848 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 26849 if test "x$has_forbidden_chars" != x; then 26850 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26851 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26852 fi 26853 26854 26855 windows_path="$new_path" 26856 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26857 unix_path=`$CYGPATH -u "$windows_path"` 26858 new_path="$unix_path" 26859 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 26860 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 26861 new_path="$unix_path" 26862 fi 26863 26864 if test "x$path" != "x$new_path"; then 26865 BOOT_JDK="$new_path" 26866 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 26867 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 26868 fi 26869 26870 # Save the first 10 bytes of this path to the storage, so fixpath can work. 26871 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 26872 26873 else 26874 # We're on a unix platform. Hooray! :) 26875 path="$BOOT_JDK" 26876 has_space=`$ECHO "$path" | $GREP " "` 26877 if test "x$has_space" != x; then 26878 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26879 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26880 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 26881 fi 26882 26883 # Use eval to expand a potential ~ 26884 eval path="$path" 26885 if test ! -f "$path" && test ! -d "$path"; then 26886 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 26887 fi 26888 26889 if test -d "$path"; then 26890 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 26891 else 26892 dir="`$DIRNAME "$path"`" 26893 base="`$BASENAME "$path"`" 26894 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 26895 fi 26896 fi 26897 fi 26898 26899 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 26900 $as_echo_n "checking for Boot JDK... " >&6; } 26901 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 26902 $as_echo "$BOOT_JDK" >&6; } 26903 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 26904 $as_echo_n "checking Boot JDK version... " >&6; } 26905 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 26906 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 26907 $as_echo "$BOOT_JDK_VERSION" >&6; } 26908 fi # end check jdk version 26909 fi # end check javac 26910 fi # end check java 26911 fi # end check boot jdk found 26912 fi 26913 26914 done 26915 fi 26916 26917 fi 26918 26919 26920 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 26921 if test "x$BOOT_JDK_FOUND" = xmaybe; then 26922 # Do we have a bin/java? 26923 if test ! -x "$BOOT_JDK/bin/java"; then 26924 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 26925 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 26926 BOOT_JDK_FOUND=no 26927 else 26928 # Do we have a bin/javac? 26929 if test ! -x "$BOOT_JDK/bin/javac"; then 26930 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 26931 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 26932 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 26933 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 26934 BOOT_JDK_FOUND=no 26935 else 26936 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 26937 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 26938 26939 # Extra M4 quote needed to protect [] in grep expression. 26940 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 26941 if test "x$FOUND_CORRECT_VERSION" = x; then 26942 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 26943 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 26944 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 26945 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 26946 BOOT_JDK_FOUND=no 26947 else 26948 # We're done! :-) 26949 BOOT_JDK_FOUND=yes 26950 26951 # Only process if variable expands to non-empty 26952 26953 if test "x$BOOT_JDK" != x; then 26954 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 26955 26956 # Input might be given as Windows format, start by converting to 26957 # unix format. 26958 path="$BOOT_JDK" 26959 new_path=`$CYGPATH -u "$path"` 26960 26961 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 26962 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 26963 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 26964 # "foo.exe" is OK but "foo" is an error. 26965 # 26966 # This test is therefore slightly more accurate than "test -f" to check for file precense. 26967 # It is also a way to make sure we got the proper file name for the real test later on. 26968 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 26969 if test "x$test_shortpath" = x; then 26970 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 26971 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 26972 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 26973 fi 26974 26975 # Call helper function which possibly converts this using DOS-style short mode. 26976 # If so, the updated path is stored in $new_path. 26977 26978 input_path="$new_path" 26979 # Check if we need to convert this using DOS-style short mode. If the path 26980 # contains just simple characters, use it. Otherwise (spaces, weird characters), 26981 # take no chances and rewrite it. 26982 # Note: m4 eats our [], so we need to use [ and ] instead. 26983 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 26984 if test "x$has_forbidden_chars" != x; then 26985 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 26986 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 26987 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 26988 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 26989 # Going to short mode and back again did indeed matter. Since short mode is 26990 # case insensitive, let's make it lowercase to improve readability. 26991 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 26992 # Now convert it back to Unix-style (cygpath) 26993 input_path=`$CYGPATH -u "$shortmode_path"` 26994 new_path="$input_path" 26995 fi 26996 fi 26997 26998 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 26999 if test "x$test_cygdrive_prefix" = x; then 27000 # As a simple fix, exclude /usr/bin since it's not a real path. 27001 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 27002 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27003 # a path prefixed by /cygdrive for fixpath to work. 27004 new_path="$CYGWIN_ROOT_PATH$input_path" 27005 fi 27006 fi 27007 27008 27009 if test "x$path" != "x$new_path"; then 27010 BOOT_JDK="$new_path" 27011 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27012 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27013 fi 27014 27015 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27016 27017 path="$BOOT_JDK" 27018 has_colon=`$ECHO $path | $GREP ^.:` 27019 new_path="$path" 27020 if test "x$has_colon" = x; then 27021 # Not in mixed or Windows style, start by that. 27022 new_path=`cmd //c echo $path` 27023 fi 27024 27025 27026 input_path="$new_path" 27027 # Check if we need to convert this using DOS-style short mode. If the path 27028 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27029 # take no chances and rewrite it. 27030 # Note: m4 eats our [], so we need to use [ and ] instead. 27031 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27032 if test "x$has_forbidden_chars" != x; then 27033 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27034 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27035 fi 27036 27037 27038 windows_path="$new_path" 27039 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27040 unix_path=`$CYGPATH -u "$windows_path"` 27041 new_path="$unix_path" 27042 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27043 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27044 new_path="$unix_path" 27045 fi 27046 27047 if test "x$path" != "x$new_path"; then 27048 BOOT_JDK="$new_path" 27049 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27050 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27051 fi 27052 27053 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27054 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27055 27056 else 27057 # We're on a unix platform. Hooray! :) 27058 path="$BOOT_JDK" 27059 has_space=`$ECHO "$path" | $GREP " "` 27060 if test "x$has_space" != x; then 27061 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27062 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27063 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 27064 fi 27065 27066 # Use eval to expand a potential ~ 27067 eval path="$path" 27068 if test ! -f "$path" && test ! -d "$path"; then 27069 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 27070 fi 27071 27072 if test -d "$path"; then 27073 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 27074 else 27075 dir="`$DIRNAME "$path"`" 27076 base="`$BASENAME "$path"`" 27077 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 27078 fi 27079 fi 27080 fi 27081 27082 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 27083 $as_echo_n "checking for Boot JDK... " >&6; } 27084 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 27085 $as_echo "$BOOT_JDK" >&6; } 27086 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 27087 $as_echo_n "checking Boot JDK version... " >&6; } 27088 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 27089 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 27090 $as_echo "$BOOT_JDK_VERSION" >&6; } 27091 fi # end check jdk version 27092 fi # end check javac 27093 fi # end check java 27094 fi # end check boot jdk found 27095 fi 27096 27097 27098 if test "x$BOOT_JDK_FOUND" = xno; then 27099 # Now execute the test 27100 27101 BOOT_JDK_PREFIX="/cygdrive/c/Program Files/Java" 27102 BOOT_JDK_SUFFIX="" 27103 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 27104 if test "x$ALL_JDKS_FOUND" != x; then 27105 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 27106 27107 if test "x$BOOT_JDK_FOUND" = xno; then 27108 # Now execute the test 27109 27110 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 27111 if test -d "$BOOT_JDK"; then 27112 BOOT_JDK_FOUND=maybe 27113 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 27114 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 27115 fi 27116 27117 27118 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 27119 if test "x$BOOT_JDK_FOUND" = xmaybe; then 27120 # Do we have a bin/java? 27121 if test ! -x "$BOOT_JDK/bin/java"; then 27122 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 27123 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 27124 BOOT_JDK_FOUND=no 27125 else 27126 # Do we have a bin/javac? 27127 if test ! -x "$BOOT_JDK/bin/javac"; then 27128 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 27129 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 27130 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 27131 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 27132 BOOT_JDK_FOUND=no 27133 else 27134 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 27135 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 27136 27137 # Extra M4 quote needed to protect [] in grep expression. 27138 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 27139 if test "x$FOUND_CORRECT_VERSION" = x; then 27140 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 27141 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 27142 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 27143 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 27144 BOOT_JDK_FOUND=no 27145 else 27146 # We're done! :-) 27147 BOOT_JDK_FOUND=yes 27148 27149 # Only process if variable expands to non-empty 27150 27151 if test "x$BOOT_JDK" != x; then 27152 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27153 27154 # Input might be given as Windows format, start by converting to 27155 # unix format. 27156 path="$BOOT_JDK" 27157 new_path=`$CYGPATH -u "$path"` 27158 27159 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27160 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27161 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27162 # "foo.exe" is OK but "foo" is an error. 27163 # 27164 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27165 # It is also a way to make sure we got the proper file name for the real test later on. 27166 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27167 if test "x$test_shortpath" = x; then 27168 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27169 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27170 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 27171 fi 27172 27173 # Call helper function which possibly converts this using DOS-style short mode. 27174 # If so, the updated path is stored in $new_path. 27175 27176 input_path="$new_path" 27177 # Check if we need to convert this using DOS-style short mode. If the path 27178 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27179 # take no chances and rewrite it. 27180 # Note: m4 eats our [], so we need to use [ and ] instead. 27181 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27182 if test "x$has_forbidden_chars" != x; then 27183 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27184 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27185 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27186 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27187 # Going to short mode and back again did indeed matter. Since short mode is 27188 # case insensitive, let's make it lowercase to improve readability. 27189 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27190 # Now convert it back to Unix-style (cygpath) 27191 input_path=`$CYGPATH -u "$shortmode_path"` 27192 new_path="$input_path" 27193 fi 27194 fi 27195 27196 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27197 if test "x$test_cygdrive_prefix" = x; then 27198 # As a simple fix, exclude /usr/bin since it's not a real path. 27199 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 27200 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27201 # a path prefixed by /cygdrive for fixpath to work. 27202 new_path="$CYGWIN_ROOT_PATH$input_path" 27203 fi 27204 fi 27205 27206 27207 if test "x$path" != "x$new_path"; then 27208 BOOT_JDK="$new_path" 27209 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27210 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27211 fi 27212 27213 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27214 27215 path="$BOOT_JDK" 27216 has_colon=`$ECHO $path | $GREP ^.:` 27217 new_path="$path" 27218 if test "x$has_colon" = x; then 27219 # Not in mixed or Windows style, start by that. 27220 new_path=`cmd //c echo $path` 27221 fi 27222 27223 27224 input_path="$new_path" 27225 # Check if we need to convert this using DOS-style short mode. If the path 27226 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27227 # take no chances and rewrite it. 27228 # Note: m4 eats our [], so we need to use [ and ] instead. 27229 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27230 if test "x$has_forbidden_chars" != x; then 27231 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27232 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27233 fi 27234 27235 27236 windows_path="$new_path" 27237 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27238 unix_path=`$CYGPATH -u "$windows_path"` 27239 new_path="$unix_path" 27240 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27241 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27242 new_path="$unix_path" 27243 fi 27244 27245 if test "x$path" != "x$new_path"; then 27246 BOOT_JDK="$new_path" 27247 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27248 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27249 fi 27250 27251 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27252 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27253 27254 else 27255 # We're on a unix platform. Hooray! :) 27256 path="$BOOT_JDK" 27257 has_space=`$ECHO "$path" | $GREP " "` 27258 if test "x$has_space" != x; then 27259 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27260 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27261 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 27262 fi 27263 27264 # Use eval to expand a potential ~ 27265 eval path="$path" 27266 if test ! -f "$path" && test ! -d "$path"; then 27267 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 27268 fi 27269 27270 if test -d "$path"; then 27271 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 27272 else 27273 dir="`$DIRNAME "$path"`" 27274 base="`$BASENAME "$path"`" 27275 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 27276 fi 27277 fi 27278 fi 27279 27280 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 27281 $as_echo_n "checking for Boot JDK... " >&6; } 27282 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 27283 $as_echo "$BOOT_JDK" >&6; } 27284 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 27285 $as_echo_n "checking Boot JDK version... " >&6; } 27286 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 27287 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 27288 $as_echo "$BOOT_JDK_VERSION" >&6; } 27289 fi # end check jdk version 27290 fi # end check javac 27291 fi # end check java 27292 fi # end check boot jdk found 27293 fi 27294 27295 done 27296 fi 27297 27298 27299 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 27300 if test "x$BOOT_JDK_FOUND" = xmaybe; then 27301 # Do we have a bin/java? 27302 if test ! -x "$BOOT_JDK/bin/java"; then 27303 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 27304 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 27305 BOOT_JDK_FOUND=no 27306 else 27307 # Do we have a bin/javac? 27308 if test ! -x "$BOOT_JDK/bin/javac"; then 27309 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 27310 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 27311 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 27312 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 27313 BOOT_JDK_FOUND=no 27314 else 27315 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 27316 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 27317 27318 # Extra M4 quote needed to protect [] in grep expression. 27319 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 27320 if test "x$FOUND_CORRECT_VERSION" = x; then 27321 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 27322 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 27323 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 27324 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 27325 BOOT_JDK_FOUND=no 27326 else 27327 # We're done! :-) 27328 BOOT_JDK_FOUND=yes 27329 27330 # Only process if variable expands to non-empty 27331 27332 if test "x$BOOT_JDK" != x; then 27333 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27334 27335 # Input might be given as Windows format, start by converting to 27336 # unix format. 27337 path="$BOOT_JDK" 27338 new_path=`$CYGPATH -u "$path"` 27339 27340 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27341 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27342 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27343 # "foo.exe" is OK but "foo" is an error. 27344 # 27345 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27346 # It is also a way to make sure we got the proper file name for the real test later on. 27347 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27348 if test "x$test_shortpath" = x; then 27349 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27350 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27351 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 27352 fi 27353 27354 # Call helper function which possibly converts this using DOS-style short mode. 27355 # If so, the updated path is stored in $new_path. 27356 27357 input_path="$new_path" 27358 # Check if we need to convert this using DOS-style short mode. If the path 27359 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27360 # take no chances and rewrite it. 27361 # Note: m4 eats our [], so we need to use [ and ] instead. 27362 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27363 if test "x$has_forbidden_chars" != x; then 27364 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27365 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27366 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27367 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27368 # Going to short mode and back again did indeed matter. Since short mode is 27369 # case insensitive, let's make it lowercase to improve readability. 27370 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27371 # Now convert it back to Unix-style (cygpath) 27372 input_path=`$CYGPATH -u "$shortmode_path"` 27373 new_path="$input_path" 27374 fi 27375 fi 27376 27377 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27378 if test "x$test_cygdrive_prefix" = x; then 27379 # As a simple fix, exclude /usr/bin since it's not a real path. 27380 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 27381 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27382 # a path prefixed by /cygdrive for fixpath to work. 27383 new_path="$CYGWIN_ROOT_PATH$input_path" 27384 fi 27385 fi 27386 27387 27388 if test "x$path" != "x$new_path"; then 27389 BOOT_JDK="$new_path" 27390 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27391 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27392 fi 27393 27394 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27395 27396 path="$BOOT_JDK" 27397 has_colon=`$ECHO $path | $GREP ^.:` 27398 new_path="$path" 27399 if test "x$has_colon" = x; then 27400 # Not in mixed or Windows style, start by that. 27401 new_path=`cmd //c echo $path` 27402 fi 27403 27404 27405 input_path="$new_path" 27406 # Check if we need to convert this using DOS-style short mode. If the path 27407 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27408 # take no chances and rewrite it. 27409 # Note: m4 eats our [], so we need to use [ and ] instead. 27410 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27411 if test "x$has_forbidden_chars" != x; then 27412 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27413 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27414 fi 27415 27416 27417 windows_path="$new_path" 27418 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27419 unix_path=`$CYGPATH -u "$windows_path"` 27420 new_path="$unix_path" 27421 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27422 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27423 new_path="$unix_path" 27424 fi 27425 27426 if test "x$path" != "x$new_path"; then 27427 BOOT_JDK="$new_path" 27428 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27429 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27430 fi 27431 27432 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27433 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27434 27435 else 27436 # We're on a unix platform. Hooray! :) 27437 path="$BOOT_JDK" 27438 has_space=`$ECHO "$path" | $GREP " "` 27439 if test "x$has_space" != x; then 27440 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27441 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27442 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 27443 fi 27444 27445 # Use eval to expand a potential ~ 27446 eval path="$path" 27447 if test ! -f "$path" && test ! -d "$path"; then 27448 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 27449 fi 27450 27451 if test -d "$path"; then 27452 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 27453 else 27454 dir="`$DIRNAME "$path"`" 27455 base="`$BASENAME "$path"`" 27456 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 27457 fi 27458 fi 27459 fi 27460 27461 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 27462 $as_echo_n "checking for Boot JDK... " >&6; } 27463 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 27464 $as_echo "$BOOT_JDK" >&6; } 27465 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 27466 $as_echo_n "checking Boot JDK version... " >&6; } 27467 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 27468 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 27469 $as_echo "$BOOT_JDK_VERSION" >&6; } 27470 fi # end check jdk version 27471 fi # end check javac 27472 fi # end check java 27473 fi # end check boot jdk found 27474 fi 27475 27476 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 27477 27478 if test "x$BOOT_JDK_FOUND" = xno; then 27479 # Now execute the test 27480 27481 BOOT_JDK_PREFIX="/Library/Java/JavaVirtualMachines" 27482 BOOT_JDK_SUFFIX="/Contents/Home" 27483 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 27484 if test "x$ALL_JDKS_FOUND" != x; then 27485 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 27486 27487 if test "x$BOOT_JDK_FOUND" = xno; then 27488 # Now execute the test 27489 27490 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 27491 if test -d "$BOOT_JDK"; then 27492 BOOT_JDK_FOUND=maybe 27493 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 27494 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 27495 fi 27496 27497 27498 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 27499 if test "x$BOOT_JDK_FOUND" = xmaybe; then 27500 # Do we have a bin/java? 27501 if test ! -x "$BOOT_JDK/bin/java"; then 27502 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 27503 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 27504 BOOT_JDK_FOUND=no 27505 else 27506 # Do we have a bin/javac? 27507 if test ! -x "$BOOT_JDK/bin/javac"; then 27508 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 27509 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 27510 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 27511 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 27512 BOOT_JDK_FOUND=no 27513 else 27514 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 27515 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 27516 27517 # Extra M4 quote needed to protect [] in grep expression. 27518 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 27519 if test "x$FOUND_CORRECT_VERSION" = x; then 27520 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 27521 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 27522 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 27523 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 27524 BOOT_JDK_FOUND=no 27525 else 27526 # We're done! :-) 27527 BOOT_JDK_FOUND=yes 27528 27529 # Only process if variable expands to non-empty 27530 27531 if test "x$BOOT_JDK" != x; then 27532 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27533 27534 # Input might be given as Windows format, start by converting to 27535 # unix format. 27536 path="$BOOT_JDK" 27537 new_path=`$CYGPATH -u "$path"` 27538 27539 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27540 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27541 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27542 # "foo.exe" is OK but "foo" is an error. 27543 # 27544 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27545 # It is also a way to make sure we got the proper file name for the real test later on. 27546 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27547 if test "x$test_shortpath" = x; then 27548 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27549 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27550 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 27551 fi 27552 27553 # Call helper function which possibly converts this using DOS-style short mode. 27554 # If so, the updated path is stored in $new_path. 27555 27556 input_path="$new_path" 27557 # Check if we need to convert this using DOS-style short mode. If the path 27558 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27559 # take no chances and rewrite it. 27560 # Note: m4 eats our [], so we need to use [ and ] instead. 27561 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27562 if test "x$has_forbidden_chars" != x; then 27563 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27564 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27565 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27566 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27567 # Going to short mode and back again did indeed matter. Since short mode is 27568 # case insensitive, let's make it lowercase to improve readability. 27569 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27570 # Now convert it back to Unix-style (cygpath) 27571 input_path=`$CYGPATH -u "$shortmode_path"` 27572 new_path="$input_path" 27573 fi 27574 fi 27575 27576 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27577 if test "x$test_cygdrive_prefix" = x; then 27578 # As a simple fix, exclude /usr/bin since it's not a real path. 27579 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 27580 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27581 # a path prefixed by /cygdrive for fixpath to work. 27582 new_path="$CYGWIN_ROOT_PATH$input_path" 27583 fi 27584 fi 27585 27586 27587 if test "x$path" != "x$new_path"; then 27588 BOOT_JDK="$new_path" 27589 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27590 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27591 fi 27592 27593 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27594 27595 path="$BOOT_JDK" 27596 has_colon=`$ECHO $path | $GREP ^.:` 27597 new_path="$path" 27598 if test "x$has_colon" = x; then 27599 # Not in mixed or Windows style, start by that. 27600 new_path=`cmd //c echo $path` 27601 fi 27602 27603 27604 input_path="$new_path" 27605 # Check if we need to convert this using DOS-style short mode. If the path 27606 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27607 # take no chances and rewrite it. 27608 # Note: m4 eats our [], so we need to use [ and ] instead. 27609 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27610 if test "x$has_forbidden_chars" != x; then 27611 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27612 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27613 fi 27614 27615 27616 windows_path="$new_path" 27617 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27618 unix_path=`$CYGPATH -u "$windows_path"` 27619 new_path="$unix_path" 27620 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27621 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27622 new_path="$unix_path" 27623 fi 27624 27625 if test "x$path" != "x$new_path"; then 27626 BOOT_JDK="$new_path" 27627 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27628 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27629 fi 27630 27631 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27632 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27633 27634 else 27635 # We're on a unix platform. Hooray! :) 27636 path="$BOOT_JDK" 27637 has_space=`$ECHO "$path" | $GREP " "` 27638 if test "x$has_space" != x; then 27639 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27640 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27641 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 27642 fi 27643 27644 # Use eval to expand a potential ~ 27645 eval path="$path" 27646 if test ! -f "$path" && test ! -d "$path"; then 27647 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 27648 fi 27649 27650 if test -d "$path"; then 27651 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 27652 else 27653 dir="`$DIRNAME "$path"`" 27654 base="`$BASENAME "$path"`" 27655 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 27656 fi 27657 fi 27658 fi 27659 27660 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 27661 $as_echo_n "checking for Boot JDK... " >&6; } 27662 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 27663 $as_echo "$BOOT_JDK" >&6; } 27664 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 27665 $as_echo_n "checking Boot JDK version... " >&6; } 27666 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 27667 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 27668 $as_echo "$BOOT_JDK_VERSION" >&6; } 27669 fi # end check jdk version 27670 fi # end check javac 27671 fi # end check java 27672 fi # end check boot jdk found 27673 fi 27674 27675 done 27676 fi 27677 27678 27679 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 27680 if test "x$BOOT_JDK_FOUND" = xmaybe; then 27681 # Do we have a bin/java? 27682 if test ! -x "$BOOT_JDK/bin/java"; then 27683 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 27684 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 27685 BOOT_JDK_FOUND=no 27686 else 27687 # Do we have a bin/javac? 27688 if test ! -x "$BOOT_JDK/bin/javac"; then 27689 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 27690 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 27691 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 27692 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 27693 BOOT_JDK_FOUND=no 27694 else 27695 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 27696 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 27697 27698 # Extra M4 quote needed to protect [] in grep expression. 27699 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 27700 if test "x$FOUND_CORRECT_VERSION" = x; then 27701 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 27702 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 27703 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 27704 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 27705 BOOT_JDK_FOUND=no 27706 else 27707 # We're done! :-) 27708 BOOT_JDK_FOUND=yes 27709 27710 # Only process if variable expands to non-empty 27711 27712 if test "x$BOOT_JDK" != x; then 27713 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27714 27715 # Input might be given as Windows format, start by converting to 27716 # unix format. 27717 path="$BOOT_JDK" 27718 new_path=`$CYGPATH -u "$path"` 27719 27720 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27721 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27722 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27723 # "foo.exe" is OK but "foo" is an error. 27724 # 27725 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27726 # It is also a way to make sure we got the proper file name for the real test later on. 27727 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27728 if test "x$test_shortpath" = x; then 27729 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27730 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27731 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 27732 fi 27733 27734 # Call helper function which possibly converts this using DOS-style short mode. 27735 # If so, the updated path is stored in $new_path. 27736 27737 input_path="$new_path" 27738 # Check if we need to convert this using DOS-style short mode. If the path 27739 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27740 # take no chances and rewrite it. 27741 # Note: m4 eats our [], so we need to use [ and ] instead. 27742 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27743 if test "x$has_forbidden_chars" != x; then 27744 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27745 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27746 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27747 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27748 # Going to short mode and back again did indeed matter. Since short mode is 27749 # case insensitive, let's make it lowercase to improve readability. 27750 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27751 # Now convert it back to Unix-style (cygpath) 27752 input_path=`$CYGPATH -u "$shortmode_path"` 27753 new_path="$input_path" 27754 fi 27755 fi 27756 27757 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27758 if test "x$test_cygdrive_prefix" = x; then 27759 # As a simple fix, exclude /usr/bin since it's not a real path. 27760 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 27761 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27762 # a path prefixed by /cygdrive for fixpath to work. 27763 new_path="$CYGWIN_ROOT_PATH$input_path" 27764 fi 27765 fi 27766 27767 27768 if test "x$path" != "x$new_path"; then 27769 BOOT_JDK="$new_path" 27770 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27771 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27772 fi 27773 27774 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27775 27776 path="$BOOT_JDK" 27777 has_colon=`$ECHO $path | $GREP ^.:` 27778 new_path="$path" 27779 if test "x$has_colon" = x; then 27780 # Not in mixed or Windows style, start by that. 27781 new_path=`cmd //c echo $path` 27782 fi 27783 27784 27785 input_path="$new_path" 27786 # Check if we need to convert this using DOS-style short mode. If the path 27787 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27788 # take no chances and rewrite it. 27789 # Note: m4 eats our [], so we need to use [ and ] instead. 27790 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27791 if test "x$has_forbidden_chars" != x; then 27792 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27793 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27794 fi 27795 27796 27797 windows_path="$new_path" 27798 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27799 unix_path=`$CYGPATH -u "$windows_path"` 27800 new_path="$unix_path" 27801 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27802 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 27803 new_path="$unix_path" 27804 fi 27805 27806 if test "x$path" != "x$new_path"; then 27807 BOOT_JDK="$new_path" 27808 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27809 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27810 fi 27811 27812 # Save the first 10 bytes of this path to the storage, so fixpath can work. 27813 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 27814 27815 else 27816 # We're on a unix platform. Hooray! :) 27817 path="$BOOT_JDK" 27818 has_space=`$ECHO "$path" | $GREP " "` 27819 if test "x$has_space" != x; then 27820 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27821 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27822 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 27823 fi 27824 27825 # Use eval to expand a potential ~ 27826 eval path="$path" 27827 if test ! -f "$path" && test ! -d "$path"; then 27828 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 27829 fi 27830 27831 if test -d "$path"; then 27832 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 27833 else 27834 dir="`$DIRNAME "$path"`" 27835 base="`$BASENAME "$path"`" 27836 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 27837 fi 27838 fi 27839 fi 27840 27841 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 27842 $as_echo_n "checking for Boot JDK... " >&6; } 27843 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 27844 $as_echo "$BOOT_JDK" >&6; } 27845 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 27846 $as_echo_n "checking Boot JDK version... " >&6; } 27847 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 27848 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 27849 $as_echo "$BOOT_JDK_VERSION" >&6; } 27850 fi # end check jdk version 27851 fi # end check javac 27852 fi # end check java 27853 fi # end check boot jdk found 27854 fi 27855 27856 27857 if test "x$BOOT_JDK_FOUND" = xno; then 27858 # Now execute the test 27859 27860 BOOT_JDK_PREFIX="/System/Library/Java/JavaVirtualMachines" 27861 BOOT_JDK_SUFFIX="/Contents/Home" 27862 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 27863 if test "x$ALL_JDKS_FOUND" != x; then 27864 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 27865 27866 if test "x$BOOT_JDK_FOUND" = xno; then 27867 # Now execute the test 27868 27869 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 27870 if test -d "$BOOT_JDK"; then 27871 BOOT_JDK_FOUND=maybe 27872 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 27873 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 27874 fi 27875 27876 27877 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 27878 if test "x$BOOT_JDK_FOUND" = xmaybe; then 27879 # Do we have a bin/java? 27880 if test ! -x "$BOOT_JDK/bin/java"; then 27881 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 27882 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 27883 BOOT_JDK_FOUND=no 27884 else 27885 # Do we have a bin/javac? 27886 if test ! -x "$BOOT_JDK/bin/javac"; then 27887 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 27888 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 27889 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 27890 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 27891 BOOT_JDK_FOUND=no 27892 else 27893 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 27894 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 27895 27896 # Extra M4 quote needed to protect [] in grep expression. 27897 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 27898 if test "x$FOUND_CORRECT_VERSION" = x; then 27899 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 27900 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 27901 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 27902 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 27903 BOOT_JDK_FOUND=no 27904 else 27905 # We're done! :-) 27906 BOOT_JDK_FOUND=yes 27907 27908 # Only process if variable expands to non-empty 27909 27910 if test "x$BOOT_JDK" != x; then 27911 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27912 27913 # Input might be given as Windows format, start by converting to 27914 # unix format. 27915 path="$BOOT_JDK" 27916 new_path=`$CYGPATH -u "$path"` 27917 27918 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 27919 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 27920 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 27921 # "foo.exe" is OK but "foo" is an error. 27922 # 27923 # This test is therefore slightly more accurate than "test -f" to check for file precense. 27924 # It is also a way to make sure we got the proper file name for the real test later on. 27925 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 27926 if test "x$test_shortpath" = x; then 27927 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 27928 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 27929 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 27930 fi 27931 27932 # Call helper function which possibly converts this using DOS-style short mode. 27933 # If so, the updated path is stored in $new_path. 27934 27935 input_path="$new_path" 27936 # Check if we need to convert this using DOS-style short mode. If the path 27937 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27938 # take no chances and rewrite it. 27939 # Note: m4 eats our [], so we need to use [ and ] instead. 27940 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 27941 if test "x$has_forbidden_chars" != x; then 27942 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27943 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 27944 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 27945 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 27946 # Going to short mode and back again did indeed matter. Since short mode is 27947 # case insensitive, let's make it lowercase to improve readability. 27948 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27949 # Now convert it back to Unix-style (cygpath) 27950 input_path=`$CYGPATH -u "$shortmode_path"` 27951 new_path="$input_path" 27952 fi 27953 fi 27954 27955 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 27956 if test "x$test_cygdrive_prefix" = x; then 27957 # As a simple fix, exclude /usr/bin since it's not a real path. 27958 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 27959 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 27960 # a path prefixed by /cygdrive for fixpath to work. 27961 new_path="$CYGWIN_ROOT_PATH$input_path" 27962 fi 27963 fi 27964 27965 27966 if test "x$path" != "x$new_path"; then 27967 BOOT_JDK="$new_path" 27968 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 27969 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 27970 fi 27971 27972 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 27973 27974 path="$BOOT_JDK" 27975 has_colon=`$ECHO $path | $GREP ^.:` 27976 new_path="$path" 27977 if test "x$has_colon" = x; then 27978 # Not in mixed or Windows style, start by that. 27979 new_path=`cmd //c echo $path` 27980 fi 27981 27982 27983 input_path="$new_path" 27984 # Check if we need to convert this using DOS-style short mode. If the path 27985 # contains just simple characters, use it. Otherwise (spaces, weird characters), 27986 # take no chances and rewrite it. 27987 # Note: m4 eats our [], so we need to use [ and ] instead. 27988 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 27989 if test "x$has_forbidden_chars" != x; then 27990 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 27991 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 27992 fi 27993 27994 27995 windows_path="$new_path" 27996 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 27997 unix_path=`$CYGPATH -u "$windows_path"` 27998 new_path="$unix_path" 27999 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28000 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28001 new_path="$unix_path" 28002 fi 28003 28004 if test "x$path" != "x$new_path"; then 28005 BOOT_JDK="$new_path" 28006 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28007 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28008 fi 28009 28010 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28011 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28012 28013 else 28014 # We're on a unix platform. Hooray! :) 28015 path="$BOOT_JDK" 28016 has_space=`$ECHO "$path" | $GREP " "` 28017 if test "x$has_space" != x; then 28018 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28019 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28020 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28021 fi 28022 28023 # Use eval to expand a potential ~ 28024 eval path="$path" 28025 if test ! -f "$path" && test ! -d "$path"; then 28026 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28027 fi 28028 28029 if test -d "$path"; then 28030 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28031 else 28032 dir="`$DIRNAME "$path"`" 28033 base="`$BASENAME "$path"`" 28034 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28035 fi 28036 fi 28037 fi 28038 28039 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 28040 $as_echo_n "checking for Boot JDK... " >&6; } 28041 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 28042 $as_echo "$BOOT_JDK" >&6; } 28043 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 28044 $as_echo_n "checking Boot JDK version... " >&6; } 28045 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 28046 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 28047 $as_echo "$BOOT_JDK_VERSION" >&6; } 28048 fi # end check jdk version 28049 fi # end check javac 28050 fi # end check java 28051 fi # end check boot jdk found 28052 fi 28053 28054 done 28055 fi 28056 28057 28058 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 28059 if test "x$BOOT_JDK_FOUND" = xmaybe; then 28060 # Do we have a bin/java? 28061 if test ! -x "$BOOT_JDK/bin/java"; then 28062 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 28063 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 28064 BOOT_JDK_FOUND=no 28065 else 28066 # Do we have a bin/javac? 28067 if test ! -x "$BOOT_JDK/bin/javac"; then 28068 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 28069 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 28070 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 28071 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 28072 BOOT_JDK_FOUND=no 28073 else 28074 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 28075 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 28076 28077 # Extra M4 quote needed to protect [] in grep expression. 28078 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 28079 if test "x$FOUND_CORRECT_VERSION" = x; then 28080 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 28081 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 28082 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 28083 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 28084 BOOT_JDK_FOUND=no 28085 else 28086 # We're done! :-) 28087 BOOT_JDK_FOUND=yes 28088 28089 # Only process if variable expands to non-empty 28090 28091 if test "x$BOOT_JDK" != x; then 28092 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28093 28094 # Input might be given as Windows format, start by converting to 28095 # unix format. 28096 path="$BOOT_JDK" 28097 new_path=`$CYGPATH -u "$path"` 28098 28099 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28100 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28101 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28102 # "foo.exe" is OK but "foo" is an error. 28103 # 28104 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28105 # It is also a way to make sure we got the proper file name for the real test later on. 28106 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28107 if test "x$test_shortpath" = x; then 28108 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28109 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28110 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28111 fi 28112 28113 # Call helper function which possibly converts this using DOS-style short mode. 28114 # If so, the updated path is stored in $new_path. 28115 28116 input_path="$new_path" 28117 # Check if we need to convert this using DOS-style short mode. If the path 28118 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28119 # take no chances and rewrite it. 28120 # Note: m4 eats our [], so we need to use [ and ] instead. 28121 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28122 if test "x$has_forbidden_chars" != x; then 28123 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28124 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28125 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28126 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28127 # Going to short mode and back again did indeed matter. Since short mode is 28128 # case insensitive, let's make it lowercase to improve readability. 28129 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28130 # Now convert it back to Unix-style (cygpath) 28131 input_path=`$CYGPATH -u "$shortmode_path"` 28132 new_path="$input_path" 28133 fi 28134 fi 28135 28136 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28137 if test "x$test_cygdrive_prefix" = x; then 28138 # As a simple fix, exclude /usr/bin since it's not a real path. 28139 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 28140 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28141 # a path prefixed by /cygdrive for fixpath to work. 28142 new_path="$CYGWIN_ROOT_PATH$input_path" 28143 fi 28144 fi 28145 28146 28147 if test "x$path" != "x$new_path"; then 28148 BOOT_JDK="$new_path" 28149 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28150 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28151 fi 28152 28153 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28154 28155 path="$BOOT_JDK" 28156 has_colon=`$ECHO $path | $GREP ^.:` 28157 new_path="$path" 28158 if test "x$has_colon" = x; then 28159 # Not in mixed or Windows style, start by that. 28160 new_path=`cmd //c echo $path` 28161 fi 28162 28163 28164 input_path="$new_path" 28165 # Check if we need to convert this using DOS-style short mode. If the path 28166 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28167 # take no chances and rewrite it. 28168 # Note: m4 eats our [], so we need to use [ and ] instead. 28169 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28170 if test "x$has_forbidden_chars" != x; then 28171 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28172 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28173 fi 28174 28175 28176 windows_path="$new_path" 28177 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28178 unix_path=`$CYGPATH -u "$windows_path"` 28179 new_path="$unix_path" 28180 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28181 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28182 new_path="$unix_path" 28183 fi 28184 28185 if test "x$path" != "x$new_path"; then 28186 BOOT_JDK="$new_path" 28187 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28188 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28189 fi 28190 28191 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28192 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28193 28194 else 28195 # We're on a unix platform. Hooray! :) 28196 path="$BOOT_JDK" 28197 has_space=`$ECHO "$path" | $GREP " "` 28198 if test "x$has_space" != x; then 28199 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28200 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28201 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28202 fi 28203 28204 # Use eval to expand a potential ~ 28205 eval path="$path" 28206 if test ! -f "$path" && test ! -d "$path"; then 28207 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28208 fi 28209 28210 if test -d "$path"; then 28211 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28212 else 28213 dir="`$DIRNAME "$path"`" 28214 base="`$BASENAME "$path"`" 28215 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28216 fi 28217 fi 28218 fi 28219 28220 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 28221 $as_echo_n "checking for Boot JDK... " >&6; } 28222 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 28223 $as_echo "$BOOT_JDK" >&6; } 28224 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 28225 $as_echo_n "checking Boot JDK version... " >&6; } 28226 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 28227 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 28228 $as_echo "$BOOT_JDK_VERSION" >&6; } 28229 fi # end check jdk version 28230 fi # end check javac 28231 fi # end check java 28232 fi # end check boot jdk found 28233 fi 28234 28235 elif test "x$OPENJDK_TARGET_OS" = xlinux; then 28236 28237 if test "x$BOOT_JDK_FOUND" = xno; then 28238 # Now execute the test 28239 28240 BOOT_JDK_PREFIX="/usr/lib/jvm" 28241 BOOT_JDK_SUFFIX="" 28242 ALL_JDKS_FOUND=`$LS "$BOOT_JDK_PREFIX" 2> /dev/null | $SORT -r` 28243 if test "x$ALL_JDKS_FOUND" != x; then 28244 for JDK_TO_TRY in $ALL_JDKS_FOUND ; do 28245 28246 if test "x$BOOT_JDK_FOUND" = xno; then 28247 # Now execute the test 28248 28249 BOOT_JDK="${BOOT_JDK_PREFIX}/${JDK_TO_TRY}${BOOT_JDK_SUFFIX}" 28250 if test -d "$BOOT_JDK"; then 28251 BOOT_JDK_FOUND=maybe 28252 { $as_echo "$as_me:${as_lineno-$LINENO}: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&5 28253 $as_echo "$as_me: Found potential Boot JDK using well-known locations (in $BOOT_JDK_PREFIX/$JDK_TO_TRY)" >&6;} 28254 fi 28255 28256 28257 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 28258 if test "x$BOOT_JDK_FOUND" = xmaybe; then 28259 # Do we have a bin/java? 28260 if test ! -x "$BOOT_JDK/bin/java"; then 28261 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 28262 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 28263 BOOT_JDK_FOUND=no 28264 else 28265 # Do we have a bin/javac? 28266 if test ! -x "$BOOT_JDK/bin/javac"; then 28267 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 28268 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 28269 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 28270 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 28271 BOOT_JDK_FOUND=no 28272 else 28273 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 28274 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 28275 28276 # Extra M4 quote needed to protect [] in grep expression. 28277 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 28278 if test "x$FOUND_CORRECT_VERSION" = x; then 28279 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 28280 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 28281 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 28282 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 28283 BOOT_JDK_FOUND=no 28284 else 28285 # We're done! :-) 28286 BOOT_JDK_FOUND=yes 28287 28288 # Only process if variable expands to non-empty 28289 28290 if test "x$BOOT_JDK" != x; then 28291 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28292 28293 # Input might be given as Windows format, start by converting to 28294 # unix format. 28295 path="$BOOT_JDK" 28296 new_path=`$CYGPATH -u "$path"` 28297 28298 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28299 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28300 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28301 # "foo.exe" is OK but "foo" is an error. 28302 # 28303 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28304 # It is also a way to make sure we got the proper file name for the real test later on. 28305 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28306 if test "x$test_shortpath" = x; then 28307 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28308 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28309 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28310 fi 28311 28312 # Call helper function which possibly converts this using DOS-style short mode. 28313 # If so, the updated path is stored in $new_path. 28314 28315 input_path="$new_path" 28316 # Check if we need to convert this using DOS-style short mode. If the path 28317 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28318 # take no chances and rewrite it. 28319 # Note: m4 eats our [], so we need to use [ and ] instead. 28320 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28321 if test "x$has_forbidden_chars" != x; then 28322 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28323 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28324 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28325 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28326 # Going to short mode and back again did indeed matter. Since short mode is 28327 # case insensitive, let's make it lowercase to improve readability. 28328 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28329 # Now convert it back to Unix-style (cygpath) 28330 input_path=`$CYGPATH -u "$shortmode_path"` 28331 new_path="$input_path" 28332 fi 28333 fi 28334 28335 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28336 if test "x$test_cygdrive_prefix" = x; then 28337 # As a simple fix, exclude /usr/bin since it's not a real path. 28338 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 28339 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28340 # a path prefixed by /cygdrive for fixpath to work. 28341 new_path="$CYGWIN_ROOT_PATH$input_path" 28342 fi 28343 fi 28344 28345 28346 if test "x$path" != "x$new_path"; then 28347 BOOT_JDK="$new_path" 28348 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28349 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28350 fi 28351 28352 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28353 28354 path="$BOOT_JDK" 28355 has_colon=`$ECHO $path | $GREP ^.:` 28356 new_path="$path" 28357 if test "x$has_colon" = x; then 28358 # Not in mixed or Windows style, start by that. 28359 new_path=`cmd //c echo $path` 28360 fi 28361 28362 28363 input_path="$new_path" 28364 # Check if we need to convert this using DOS-style short mode. If the path 28365 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28366 # take no chances and rewrite it. 28367 # Note: m4 eats our [], so we need to use [ and ] instead. 28368 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28369 if test "x$has_forbidden_chars" != x; then 28370 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28371 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28372 fi 28373 28374 28375 windows_path="$new_path" 28376 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28377 unix_path=`$CYGPATH -u "$windows_path"` 28378 new_path="$unix_path" 28379 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28380 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28381 new_path="$unix_path" 28382 fi 28383 28384 if test "x$path" != "x$new_path"; then 28385 BOOT_JDK="$new_path" 28386 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28387 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28388 fi 28389 28390 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28391 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28392 28393 else 28394 # We're on a unix platform. Hooray! :) 28395 path="$BOOT_JDK" 28396 has_space=`$ECHO "$path" | $GREP " "` 28397 if test "x$has_space" != x; then 28398 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28399 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28400 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28401 fi 28402 28403 # Use eval to expand a potential ~ 28404 eval path="$path" 28405 if test ! -f "$path" && test ! -d "$path"; then 28406 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28407 fi 28408 28409 if test -d "$path"; then 28410 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28411 else 28412 dir="`$DIRNAME "$path"`" 28413 base="`$BASENAME "$path"`" 28414 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28415 fi 28416 fi 28417 fi 28418 28419 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 28420 $as_echo_n "checking for Boot JDK... " >&6; } 28421 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 28422 $as_echo "$BOOT_JDK" >&6; } 28423 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 28424 $as_echo_n "checking Boot JDK version... " >&6; } 28425 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 28426 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 28427 $as_echo "$BOOT_JDK_VERSION" >&6; } 28428 fi # end check jdk version 28429 fi # end check javac 28430 fi # end check java 28431 fi # end check boot jdk found 28432 fi 28433 28434 done 28435 fi 28436 28437 28438 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 28439 if test "x$BOOT_JDK_FOUND" = xmaybe; then 28440 # Do we have a bin/java? 28441 if test ! -x "$BOOT_JDK/bin/java"; then 28442 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 28443 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 28444 BOOT_JDK_FOUND=no 28445 else 28446 # Do we have a bin/javac? 28447 if test ! -x "$BOOT_JDK/bin/javac"; then 28448 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 28449 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 28450 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 28451 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 28452 BOOT_JDK_FOUND=no 28453 else 28454 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 28455 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 28456 28457 # Extra M4 quote needed to protect [] in grep expression. 28458 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 28459 if test "x$FOUND_CORRECT_VERSION" = x; then 28460 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 28461 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 28462 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 28463 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 28464 BOOT_JDK_FOUND=no 28465 else 28466 # We're done! :-) 28467 BOOT_JDK_FOUND=yes 28468 28469 # Only process if variable expands to non-empty 28470 28471 if test "x$BOOT_JDK" != x; then 28472 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28473 28474 # Input might be given as Windows format, start by converting to 28475 # unix format. 28476 path="$BOOT_JDK" 28477 new_path=`$CYGPATH -u "$path"` 28478 28479 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28480 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28481 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28482 # "foo.exe" is OK but "foo" is an error. 28483 # 28484 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28485 # It is also a way to make sure we got the proper file name for the real test later on. 28486 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28487 if test "x$test_shortpath" = x; then 28488 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28489 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28490 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28491 fi 28492 28493 # Call helper function which possibly converts this using DOS-style short mode. 28494 # If so, the updated path is stored in $new_path. 28495 28496 input_path="$new_path" 28497 # Check if we need to convert this using DOS-style short mode. If the path 28498 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28499 # take no chances and rewrite it. 28500 # Note: m4 eats our [], so we need to use [ and ] instead. 28501 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28502 if test "x$has_forbidden_chars" != x; then 28503 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28504 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28505 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28506 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28507 # Going to short mode and back again did indeed matter. Since short mode is 28508 # case insensitive, let's make it lowercase to improve readability. 28509 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28510 # Now convert it back to Unix-style (cygpath) 28511 input_path=`$CYGPATH -u "$shortmode_path"` 28512 new_path="$input_path" 28513 fi 28514 fi 28515 28516 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28517 if test "x$test_cygdrive_prefix" = x; then 28518 # As a simple fix, exclude /usr/bin since it's not a real path. 28519 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 28520 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28521 # a path prefixed by /cygdrive for fixpath to work. 28522 new_path="$CYGWIN_ROOT_PATH$input_path" 28523 fi 28524 fi 28525 28526 28527 if test "x$path" != "x$new_path"; then 28528 BOOT_JDK="$new_path" 28529 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28530 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28531 fi 28532 28533 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28534 28535 path="$BOOT_JDK" 28536 has_colon=`$ECHO $path | $GREP ^.:` 28537 new_path="$path" 28538 if test "x$has_colon" = x; then 28539 # Not in mixed or Windows style, start by that. 28540 new_path=`cmd //c echo $path` 28541 fi 28542 28543 28544 input_path="$new_path" 28545 # Check if we need to convert this using DOS-style short mode. If the path 28546 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28547 # take no chances and rewrite it. 28548 # Note: m4 eats our [], so we need to use [ and ] instead. 28549 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28550 if test "x$has_forbidden_chars" != x; then 28551 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28552 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28553 fi 28554 28555 28556 windows_path="$new_path" 28557 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28558 unix_path=`$CYGPATH -u "$windows_path"` 28559 new_path="$unix_path" 28560 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28561 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28562 new_path="$unix_path" 28563 fi 28564 28565 if test "x$path" != "x$new_path"; then 28566 BOOT_JDK="$new_path" 28567 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28568 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28569 fi 28570 28571 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28572 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28573 28574 else 28575 # We're on a unix platform. Hooray! :) 28576 path="$BOOT_JDK" 28577 has_space=`$ECHO "$path" | $GREP " "` 28578 if test "x$has_space" != x; then 28579 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28580 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28581 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28582 fi 28583 28584 # Use eval to expand a potential ~ 28585 eval path="$path" 28586 if test ! -f "$path" && test ! -d "$path"; then 28587 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28588 fi 28589 28590 if test -d "$path"; then 28591 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28592 else 28593 dir="`$DIRNAME "$path"`" 28594 base="`$BASENAME "$path"`" 28595 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28596 fi 28597 fi 28598 fi 28599 28600 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 28601 $as_echo_n "checking for Boot JDK... " >&6; } 28602 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 28603 $as_echo "$BOOT_JDK" >&6; } 28604 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 28605 $as_echo_n "checking Boot JDK version... " >&6; } 28606 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 28607 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 28608 $as_echo "$BOOT_JDK_VERSION" >&6; } 28609 fi # end check jdk version 28610 fi # end check javac 28611 fi # end check java 28612 fi # end check boot jdk found 28613 fi 28614 28615 fi 28616 28617 28618 # If previous step claimed to have found a JDK, check it to see if it seems to be valid. 28619 if test "x$BOOT_JDK_FOUND" = xmaybe; then 28620 # Do we have a bin/java? 28621 if test ! -x "$BOOT_JDK/bin/java"; then 28622 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&5 28623 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/java; ignoring" >&6;} 28624 BOOT_JDK_FOUND=no 28625 else 28626 # Do we have a bin/javac? 28627 if test ! -x "$BOOT_JDK/bin/javac"; then 28628 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&5 28629 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK did not contain bin/javac; ignoring" >&6;} 28630 { $as_echo "$as_me:${as_lineno-$LINENO}: (This might be an JRE instead of an JDK)" >&5 28631 $as_echo "$as_me: (This might be an JRE instead of an JDK)" >&6;} 28632 BOOT_JDK_FOUND=no 28633 else 28634 # Oh, this is looking good! We probably have found a proper JDK. Is it the correct version? 28635 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | head -n 1` 28636 28637 # Extra M4 quote needed to protect [] in grep expression. 28638 FOUND_CORRECT_VERSION=`$ECHO $BOOT_JDK_VERSION | $EGREP '\"9([\.+-].*)?\"|(1\.[89]\.)'` 28639 if test "x$FOUND_CORRECT_VERSION" = x; then 28640 { $as_echo "$as_me:${as_lineno-$LINENO}: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&5 28641 $as_echo "$as_me: Potential Boot JDK found at $BOOT_JDK is incorrect JDK version ($BOOT_JDK_VERSION); ignoring" >&6;} 28642 { $as_echo "$as_me:${as_lineno-$LINENO}: (Your Boot JDK must be version 8 or 9)" >&5 28643 $as_echo "$as_me: (Your Boot JDK must be version 8 or 9)" >&6;} 28644 BOOT_JDK_FOUND=no 28645 else 28646 # We're done! :-) 28647 BOOT_JDK_FOUND=yes 28648 28649 # Only process if variable expands to non-empty 28650 28651 if test "x$BOOT_JDK" != x; then 28652 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28653 28654 # Input might be given as Windows format, start by converting to 28655 # unix format. 28656 path="$BOOT_JDK" 28657 new_path=`$CYGPATH -u "$path"` 28658 28659 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 28660 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 28661 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 28662 # "foo.exe" is OK but "foo" is an error. 28663 # 28664 # This test is therefore slightly more accurate than "test -f" to check for file precense. 28665 # It is also a way to make sure we got the proper file name for the real test later on. 28666 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 28667 if test "x$test_shortpath" = x; then 28668 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28669 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28670 as_fn_error $? "Cannot locate the the path of BOOT_JDK" "$LINENO" 5 28671 fi 28672 28673 # Call helper function which possibly converts this using DOS-style short mode. 28674 # If so, the updated path is stored in $new_path. 28675 28676 input_path="$new_path" 28677 # Check if we need to convert this using DOS-style short mode. If the path 28678 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28679 # take no chances and rewrite it. 28680 # Note: m4 eats our [], so we need to use [ and ] instead. 28681 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 28682 if test "x$has_forbidden_chars" != x; then 28683 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28684 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 28685 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 28686 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 28687 # Going to short mode and back again did indeed matter. Since short mode is 28688 # case insensitive, let's make it lowercase to improve readability. 28689 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28690 # Now convert it back to Unix-style (cygpath) 28691 input_path=`$CYGPATH -u "$shortmode_path"` 28692 new_path="$input_path" 28693 fi 28694 fi 28695 28696 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 28697 if test "x$test_cygdrive_prefix" = x; then 28698 # As a simple fix, exclude /usr/bin since it's not a real path. 28699 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 28700 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 28701 # a path prefixed by /cygdrive for fixpath to work. 28702 new_path="$CYGWIN_ROOT_PATH$input_path" 28703 fi 28704 fi 28705 28706 28707 if test "x$path" != "x$new_path"; then 28708 BOOT_JDK="$new_path" 28709 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28710 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28711 fi 28712 28713 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28714 28715 path="$BOOT_JDK" 28716 has_colon=`$ECHO $path | $GREP ^.:` 28717 new_path="$path" 28718 if test "x$has_colon" = x; then 28719 # Not in mixed or Windows style, start by that. 28720 new_path=`cmd //c echo $path` 28721 fi 28722 28723 28724 input_path="$new_path" 28725 # Check if we need to convert this using DOS-style short mode. If the path 28726 # contains just simple characters, use it. Otherwise (spaces, weird characters), 28727 # take no chances and rewrite it. 28728 # Note: m4 eats our [], so we need to use [ and ] instead. 28729 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 28730 if test "x$has_forbidden_chars" != x; then 28731 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 28732 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 28733 fi 28734 28735 28736 windows_path="$new_path" 28737 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28738 unix_path=`$CYGPATH -u "$windows_path"` 28739 new_path="$unix_path" 28740 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28741 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 28742 new_path="$unix_path" 28743 fi 28744 28745 if test "x$path" != "x$new_path"; then 28746 BOOT_JDK="$new_path" 28747 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BOOT_JDK to \"$new_path\"" >&5 28748 $as_echo "$as_me: Rewriting BOOT_JDK to \"$new_path\"" >&6;} 28749 fi 28750 28751 # Save the first 10 bytes of this path to the storage, so fixpath can work. 28752 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 28753 28754 else 28755 # We're on a unix platform. Hooray! :) 28756 path="$BOOT_JDK" 28757 has_space=`$ECHO "$path" | $GREP " "` 28758 if test "x$has_space" != x; then 28759 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&5 28760 $as_echo "$as_me: The path of BOOT_JDK, which resolves as \"$path\", is invalid." >&6;} 28761 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 28762 fi 28763 28764 # Use eval to expand a potential ~ 28765 eval path="$path" 28766 if test ! -f "$path" && test ! -d "$path"; then 28767 as_fn_error $? "The path of BOOT_JDK, which resolves as \"$path\", is not found." "$LINENO" 5 28768 fi 28769 28770 if test -d "$path"; then 28771 BOOT_JDK="`cd "$path"; $THEPWDCMD -L`" 28772 else 28773 dir="`$DIRNAME "$path"`" 28774 base="`$BASENAME "$path"`" 28775 BOOT_JDK="`cd "$dir"; $THEPWDCMD -L`/$base" 28776 fi 28777 fi 28778 fi 28779 28780 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Boot JDK" >&5 28781 $as_echo_n "checking for Boot JDK... " >&6; } 28782 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK" >&5 28783 $as_echo "$BOOT_JDK" >&6; } 28784 { $as_echo "$as_me:${as_lineno-$LINENO}: checking Boot JDK version" >&5 28785 $as_echo_n "checking Boot JDK version... " >&6; } 28786 BOOT_JDK_VERSION=`"$BOOT_JDK/bin/java" -version 2>&1 | $TR '\n\r' ' '` 28787 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_VERSION" >&5 28788 $as_echo "$BOOT_JDK_VERSION" >&6; } 28789 fi # end check jdk version 28790 fi # end check javac 28791 fi # end check java 28792 fi # end check boot jdk found 28793 fi 28794 28795 28796 # If we haven't found anything yet, we've truly lost. Give up. 28797 if test "x$BOOT_JDK_FOUND" = xno; then 28798 28799 # Print a helpful message on how to acquire the necessary build dependency. 28800 # openjdk is the help tag: freetype, cups, alsa etc 28801 MISSING_DEPENDENCY=openjdk 28802 28803 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 28804 cygwin_help $MISSING_DEPENDENCY 28805 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 28806 msys_help $MISSING_DEPENDENCY 28807 else 28808 PKGHANDLER_COMMAND= 28809 28810 case $PKGHANDLER in 28811 apt-get) 28812 apt_help $MISSING_DEPENDENCY ;; 28813 yum) 28814 yum_help $MISSING_DEPENDENCY ;; 28815 port) 28816 port_help $MISSING_DEPENDENCY ;; 28817 pkgutil) 28818 pkgutil_help $MISSING_DEPENDENCY ;; 28819 pkgadd) 28820 pkgadd_help $MISSING_DEPENDENCY ;; 28821 esac 28822 28823 if test "x$PKGHANDLER_COMMAND" != x; then 28824 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 28825 fi 28826 fi 28827 28828 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find a valid Boot JDK. $HELP_MSG" >&5 28829 $as_echo "$as_me: Could not find a valid Boot JDK. $HELP_MSG" >&6;} 28830 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be fixed by explicitely setting --with-boot-jdk" >&5 28831 $as_echo "$as_me: This might be fixed by explicitely setting --with-boot-jdk" >&6;} 28832 as_fn_error $? "Cannot continue" "$LINENO" 5 28833 fi 28834 28835 28836 28837 # Setup tools from the Boot JDK. 28838 28839 # Use user overridden value if available, otherwise locate tool in the Boot JDK. 28840 28841 # Publish this variable in the help. 28842 28843 28844 if [ -z "${JAVA+x}" ]; then 28845 # The variable is not set by user, try to locate tool using the code snippet 28846 28847 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for java in Boot JDK" >&5 28848 $as_echo_n "checking for java in Boot JDK... " >&6; } 28849 JAVA=$BOOT_JDK/bin/java 28850 if test ! -x $JAVA; then 28851 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 28852 $as_echo "not found" >&6; } 28853 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 28854 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 28855 as_fn_error $? "Could not find java in the Boot JDK" "$LINENO" 5 28856 fi 28857 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 28858 $as_echo "ok" >&6; } 28859 28860 28861 else 28862 # The variable is set, but is it from the command line or the environment? 28863 28864 # Try to remove the string !JAVA! from our list. 28865 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAVA!/} 28866 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 28867 # If it failed, the variable was not from the command line. Ignore it, 28868 # but warn the user (except for BASH, which is always set by the calling BASH). 28869 if test "xJAVA" != xBASH; then 28870 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAVA from the environment. Use command line variables instead." >&5 28871 $as_echo "$as_me: WARNING: Ignoring value of JAVA from the environment. Use command line variables instead." >&2;} 28872 fi 28873 # Try to locate tool using the code snippet 28874 28875 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for java in Boot JDK" >&5 28876 $as_echo_n "checking for java in Boot JDK... " >&6; } 28877 JAVA=$BOOT_JDK/bin/java 28878 if test ! -x $JAVA; then 28879 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 28880 $as_echo "not found" >&6; } 28881 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 28882 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 28883 as_fn_error $? "Could not find java in the Boot JDK" "$LINENO" 5 28884 fi 28885 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 28886 $as_echo "ok" >&6; } 28887 28888 28889 else 28890 # If it succeeded, then it was overridden by the user. We will use it 28891 # for the tool. 28892 28893 # First remove it from the list of overridden variables, so we can test 28894 # for unknown variables in the end. 28895 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 28896 28897 # Check if we try to supply an empty value 28898 if test "x$JAVA" = x; then 28899 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JAVA= (no value)" >&5 28900 $as_echo "$as_me: Setting user supplied tool JAVA= (no value)" >&6;} 28901 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVA" >&5 28902 $as_echo_n "checking for JAVA... " >&6; } 28903 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 28904 $as_echo "disabled" >&6; } 28905 else 28906 # Check if the provided tool contains a complete path. 28907 tool_specified="$JAVA" 28908 tool_basename="${tool_specified##*/}" 28909 if test "x$tool_basename" = "x$tool_specified"; then 28910 # A command without a complete path is provided, search $PATH. 28911 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAVA=$tool_basename" >&5 28912 $as_echo "$as_me: Will search for user supplied tool JAVA=$tool_basename" >&6;} 28913 # Extract the first word of "$tool_basename", so it can be a program name with args. 28914 set dummy $tool_basename; ac_word=$2 28915 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 28916 $as_echo_n "checking for $ac_word... " >&6; } 28917 if ${ac_cv_path_JAVA+:} false; then : 28918 $as_echo_n "(cached) " >&6 28919 else 28920 case $JAVA in 28921 [\\/]* | ?:[\\/]*) 28922 ac_cv_path_JAVA="$JAVA" # Let the user override the test with a path. 28923 ;; 28924 *) 28925 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 28926 for as_dir in $PATH 28927 do 28928 IFS=$as_save_IFS 28929 test -z "$as_dir" && as_dir=. 28930 for ac_exec_ext in '' $ac_executable_extensions; do 28931 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 28932 ac_cv_path_JAVA="$as_dir/$ac_word$ac_exec_ext" 28933 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 28934 break 2 28935 fi 28936 done 28937 done 28938 IFS=$as_save_IFS 28939 28940 ;; 28941 esac 28942 fi 28943 JAVA=$ac_cv_path_JAVA 28944 if test -n "$JAVA"; then 28945 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVA" >&5 28946 $as_echo "$JAVA" >&6; } 28947 else 28948 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 28949 $as_echo "no" >&6; } 28950 fi 28951 28952 28953 if test "x$JAVA" = x; then 28954 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 28955 fi 28956 else 28957 # Otherwise we believe it is a complete path. Use it as it is. 28958 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAVA=$tool_specified" >&5 28959 $as_echo "$as_me: Will use user supplied tool JAVA=$tool_specified" >&6;} 28960 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVA" >&5 28961 $as_echo_n "checking for JAVA... " >&6; } 28962 if test ! -x "$tool_specified"; then 28963 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 28964 $as_echo "not found" >&6; } 28965 as_fn_error $? "User supplied tool JAVA=$tool_specified does not exist or is not executable" "$LINENO" 5 28966 fi 28967 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 28968 $as_echo "$tool_specified" >&6; } 28969 fi 28970 fi 28971 fi 28972 28973 fi 28974 28975 28976 28977 # Use user overridden value if available, otherwise locate tool in the Boot JDK. 28978 28979 # Publish this variable in the help. 28980 28981 28982 if [ -z "${JAVAC+x}" ]; then 28983 # The variable is not set by user, try to locate tool using the code snippet 28984 28985 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javac in Boot JDK" >&5 28986 $as_echo_n "checking for javac in Boot JDK... " >&6; } 28987 JAVAC=$BOOT_JDK/bin/javac 28988 if test ! -x $JAVAC; then 28989 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 28990 $as_echo "not found" >&6; } 28991 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 28992 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 28993 as_fn_error $? "Could not find javac in the Boot JDK" "$LINENO" 5 28994 fi 28995 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 28996 $as_echo "ok" >&6; } 28997 28998 28999 else 29000 # The variable is set, but is it from the command line or the environment? 29001 29002 # Try to remove the string !JAVAC! from our list. 29003 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAVAC!/} 29004 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 29005 # If it failed, the variable was not from the command line. Ignore it, 29006 # but warn the user (except for BASH, which is always set by the calling BASH). 29007 if test "xJAVAC" != xBASH; then 29008 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAVAC from the environment. Use command line variables instead." >&5 29009 $as_echo "$as_me: WARNING: Ignoring value of JAVAC from the environment. Use command line variables instead." >&2;} 29010 fi 29011 # Try to locate tool using the code snippet 29012 29013 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javac in Boot JDK" >&5 29014 $as_echo_n "checking for javac in Boot JDK... " >&6; } 29015 JAVAC=$BOOT_JDK/bin/javac 29016 if test ! -x $JAVAC; then 29017 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 29018 $as_echo "not found" >&6; } 29019 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 29020 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 29021 as_fn_error $? "Could not find javac in the Boot JDK" "$LINENO" 5 29022 fi 29023 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 29024 $as_echo "ok" >&6; } 29025 29026 29027 else 29028 # If it succeeded, then it was overridden by the user. We will use it 29029 # for the tool. 29030 29031 # First remove it from the list of overridden variables, so we can test 29032 # for unknown variables in the end. 29033 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 29034 29035 # Check if we try to supply an empty value 29036 if test "x$JAVAC" = x; then 29037 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JAVAC= (no value)" >&5 29038 $as_echo "$as_me: Setting user supplied tool JAVAC= (no value)" >&6;} 29039 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAC" >&5 29040 $as_echo_n "checking for JAVAC... " >&6; } 29041 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 29042 $as_echo "disabled" >&6; } 29043 else 29044 # Check if the provided tool contains a complete path. 29045 tool_specified="$JAVAC" 29046 tool_basename="${tool_specified##*/}" 29047 if test "x$tool_basename" = "x$tool_specified"; then 29048 # A command without a complete path is provided, search $PATH. 29049 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAVAC=$tool_basename" >&5 29050 $as_echo "$as_me: Will search for user supplied tool JAVAC=$tool_basename" >&6;} 29051 # Extract the first word of "$tool_basename", so it can be a program name with args. 29052 set dummy $tool_basename; ac_word=$2 29053 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 29054 $as_echo_n "checking for $ac_word... " >&6; } 29055 if ${ac_cv_path_JAVAC+:} false; then : 29056 $as_echo_n "(cached) " >&6 29057 else 29058 case $JAVAC in 29059 [\\/]* | ?:[\\/]*) 29060 ac_cv_path_JAVAC="$JAVAC" # Let the user override the test with a path. 29061 ;; 29062 *) 29063 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 29064 for as_dir in $PATH 29065 do 29066 IFS=$as_save_IFS 29067 test -z "$as_dir" && as_dir=. 29068 for ac_exec_ext in '' $ac_executable_extensions; do 29069 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 29070 ac_cv_path_JAVAC="$as_dir/$ac_word$ac_exec_ext" 29071 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 29072 break 2 29073 fi 29074 done 29075 done 29076 IFS=$as_save_IFS 29077 29078 ;; 29079 esac 29080 fi 29081 JAVAC=$ac_cv_path_JAVAC 29082 if test -n "$JAVAC"; then 29083 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVAC" >&5 29084 $as_echo "$JAVAC" >&6; } 29085 else 29086 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 29087 $as_echo "no" >&6; } 29088 fi 29089 29090 29091 if test "x$JAVAC" = x; then 29092 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 29093 fi 29094 else 29095 # Otherwise we believe it is a complete path. Use it as it is. 29096 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAVAC=$tool_specified" >&5 29097 $as_echo "$as_me: Will use user supplied tool JAVAC=$tool_specified" >&6;} 29098 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAC" >&5 29099 $as_echo_n "checking for JAVAC... " >&6; } 29100 if test ! -x "$tool_specified"; then 29101 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 29102 $as_echo "not found" >&6; } 29103 as_fn_error $? "User supplied tool JAVAC=$tool_specified does not exist or is not executable" "$LINENO" 5 29104 fi 29105 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 29106 $as_echo "$tool_specified" >&6; } 29107 fi 29108 fi 29109 fi 29110 29111 fi 29112 29113 29114 29115 # Use user overridden value if available, otherwise locate tool in the Boot JDK. 29116 29117 # Publish this variable in the help. 29118 29119 29120 if [ -z "${JAVAH+x}" ]; then 29121 # The variable is not set by user, try to locate tool using the code snippet 29122 29123 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javah in Boot JDK" >&5 29124 $as_echo_n "checking for javah in Boot JDK... " >&6; } 29125 JAVAH=$BOOT_JDK/bin/javah 29126 if test ! -x $JAVAH; then 29127 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 29128 $as_echo "not found" >&6; } 29129 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 29130 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 29131 as_fn_error $? "Could not find javah in the Boot JDK" "$LINENO" 5 29132 fi 29133 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 29134 $as_echo "ok" >&6; } 29135 29136 29137 else 29138 # The variable is set, but is it from the command line or the environment? 29139 29140 # Try to remove the string !JAVAH! from our list. 29141 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAVAH!/} 29142 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 29143 # If it failed, the variable was not from the command line. Ignore it, 29144 # but warn the user (except for BASH, which is always set by the calling BASH). 29145 if test "xJAVAH" != xBASH; then 29146 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAVAH from the environment. Use command line variables instead." >&5 29147 $as_echo "$as_me: WARNING: Ignoring value of JAVAH from the environment. Use command line variables instead." >&2;} 29148 fi 29149 # Try to locate tool using the code snippet 29150 29151 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for javah in Boot JDK" >&5 29152 $as_echo_n "checking for javah in Boot JDK... " >&6; } 29153 JAVAH=$BOOT_JDK/bin/javah 29154 if test ! -x $JAVAH; then 29155 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 29156 $as_echo "not found" >&6; } 29157 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 29158 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 29159 as_fn_error $? "Could not find javah in the Boot JDK" "$LINENO" 5 29160 fi 29161 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 29162 $as_echo "ok" >&6; } 29163 29164 29165 else 29166 # If it succeeded, then it was overridden by the user. We will use it 29167 # for the tool. 29168 29169 # First remove it from the list of overridden variables, so we can test 29170 # for unknown variables in the end. 29171 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 29172 29173 # Check if we try to supply an empty value 29174 if test "x$JAVAH" = x; then 29175 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JAVAH= (no value)" >&5 29176 $as_echo "$as_me: Setting user supplied tool JAVAH= (no value)" >&6;} 29177 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAH" >&5 29178 $as_echo_n "checking for JAVAH... " >&6; } 29179 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 29180 $as_echo "disabled" >&6; } 29181 else 29182 # Check if the provided tool contains a complete path. 29183 tool_specified="$JAVAH" 29184 tool_basename="${tool_specified##*/}" 29185 if test "x$tool_basename" = "x$tool_specified"; then 29186 # A command without a complete path is provided, search $PATH. 29187 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAVAH=$tool_basename" >&5 29188 $as_echo "$as_me: Will search for user supplied tool JAVAH=$tool_basename" >&6;} 29189 # Extract the first word of "$tool_basename", so it can be a program name with args. 29190 set dummy $tool_basename; ac_word=$2 29191 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 29192 $as_echo_n "checking for $ac_word... " >&6; } 29193 if ${ac_cv_path_JAVAH+:} false; then : 29194 $as_echo_n "(cached) " >&6 29195 else 29196 case $JAVAH in 29197 [\\/]* | ?:[\\/]*) 29198 ac_cv_path_JAVAH="$JAVAH" # Let the user override the test with a path. 29199 ;; 29200 *) 29201 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 29202 for as_dir in $PATH 29203 do 29204 IFS=$as_save_IFS 29205 test -z "$as_dir" && as_dir=. 29206 for ac_exec_ext in '' $ac_executable_extensions; do 29207 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 29208 ac_cv_path_JAVAH="$as_dir/$ac_word$ac_exec_ext" 29209 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 29210 break 2 29211 fi 29212 done 29213 done 29214 IFS=$as_save_IFS 29215 29216 ;; 29217 esac 29218 fi 29219 JAVAH=$ac_cv_path_JAVAH 29220 if test -n "$JAVAH"; then 29221 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAVAH" >&5 29222 $as_echo "$JAVAH" >&6; } 29223 else 29224 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 29225 $as_echo "no" >&6; } 29226 fi 29227 29228 29229 if test "x$JAVAH" = x; then 29230 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 29231 fi 29232 else 29233 # Otherwise we believe it is a complete path. Use it as it is. 29234 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAVAH=$tool_specified" >&5 29235 $as_echo "$as_me: Will use user supplied tool JAVAH=$tool_specified" >&6;} 29236 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAVAH" >&5 29237 $as_echo_n "checking for JAVAH... " >&6; } 29238 if test ! -x "$tool_specified"; then 29239 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 29240 $as_echo "not found" >&6; } 29241 as_fn_error $? "User supplied tool JAVAH=$tool_specified does not exist or is not executable" "$LINENO" 5 29242 fi 29243 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 29244 $as_echo "$tool_specified" >&6; } 29245 fi 29246 fi 29247 fi 29248 29249 fi 29250 29251 29252 29253 # Use user overridden value if available, otherwise locate tool in the Boot JDK. 29254 29255 # Publish this variable in the help. 29256 29257 29258 if [ -z "${JAR+x}" ]; then 29259 # The variable is not set by user, try to locate tool using the code snippet 29260 29261 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jar in Boot JDK" >&5 29262 $as_echo_n "checking for jar in Boot JDK... " >&6; } 29263 JAR=$BOOT_JDK/bin/jar 29264 if test ! -x $JAR; then 29265 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 29266 $as_echo "not found" >&6; } 29267 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 29268 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 29269 as_fn_error $? "Could not find jar in the Boot JDK" "$LINENO" 5 29270 fi 29271 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 29272 $as_echo "ok" >&6; } 29273 29274 29275 else 29276 # The variable is set, but is it from the command line or the environment? 29277 29278 # Try to remove the string !JAR! from our list. 29279 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JAR!/} 29280 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 29281 # If it failed, the variable was not from the command line. Ignore it, 29282 # but warn the user (except for BASH, which is always set by the calling BASH). 29283 if test "xJAR" != xBASH; then 29284 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JAR from the environment. Use command line variables instead." >&5 29285 $as_echo "$as_me: WARNING: Ignoring value of JAR from the environment. Use command line variables instead." >&2;} 29286 fi 29287 # Try to locate tool using the code snippet 29288 29289 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jar in Boot JDK" >&5 29290 $as_echo_n "checking for jar in Boot JDK... " >&6; } 29291 JAR=$BOOT_JDK/bin/jar 29292 if test ! -x $JAR; then 29293 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 29294 $as_echo "not found" >&6; } 29295 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 29296 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 29297 as_fn_error $? "Could not find jar in the Boot JDK" "$LINENO" 5 29298 fi 29299 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 29300 $as_echo "ok" >&6; } 29301 29302 29303 else 29304 # If it succeeded, then it was overridden by the user. We will use it 29305 # for the tool. 29306 29307 # First remove it from the list of overridden variables, so we can test 29308 # for unknown variables in the end. 29309 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 29310 29311 # Check if we try to supply an empty value 29312 if test "x$JAR" = x; then 29313 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JAR= (no value)" >&5 29314 $as_echo "$as_me: Setting user supplied tool JAR= (no value)" >&6;} 29315 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAR" >&5 29316 $as_echo_n "checking for JAR... " >&6; } 29317 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 29318 $as_echo "disabled" >&6; } 29319 else 29320 # Check if the provided tool contains a complete path. 29321 tool_specified="$JAR" 29322 tool_basename="${tool_specified##*/}" 29323 if test "x$tool_basename" = "x$tool_specified"; then 29324 # A command without a complete path is provided, search $PATH. 29325 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JAR=$tool_basename" >&5 29326 $as_echo "$as_me: Will search for user supplied tool JAR=$tool_basename" >&6;} 29327 # Extract the first word of "$tool_basename", so it can be a program name with args. 29328 set dummy $tool_basename; ac_word=$2 29329 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 29330 $as_echo_n "checking for $ac_word... " >&6; } 29331 if ${ac_cv_path_JAR+:} false; then : 29332 $as_echo_n "(cached) " >&6 29333 else 29334 case $JAR in 29335 [\\/]* | ?:[\\/]*) 29336 ac_cv_path_JAR="$JAR" # Let the user override the test with a path. 29337 ;; 29338 *) 29339 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 29340 for as_dir in $PATH 29341 do 29342 IFS=$as_save_IFS 29343 test -z "$as_dir" && as_dir=. 29344 for ac_exec_ext in '' $ac_executable_extensions; do 29345 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 29346 ac_cv_path_JAR="$as_dir/$ac_word$ac_exec_ext" 29347 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 29348 break 2 29349 fi 29350 done 29351 done 29352 IFS=$as_save_IFS 29353 29354 ;; 29355 esac 29356 fi 29357 JAR=$ac_cv_path_JAR 29358 if test -n "$JAR"; then 29359 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JAR" >&5 29360 $as_echo "$JAR" >&6; } 29361 else 29362 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 29363 $as_echo "no" >&6; } 29364 fi 29365 29366 29367 if test "x$JAR" = x; then 29368 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 29369 fi 29370 else 29371 # Otherwise we believe it is a complete path. Use it as it is. 29372 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JAR=$tool_specified" >&5 29373 $as_echo "$as_me: Will use user supplied tool JAR=$tool_specified" >&6;} 29374 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JAR" >&5 29375 $as_echo_n "checking for JAR... " >&6; } 29376 if test ! -x "$tool_specified"; then 29377 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 29378 $as_echo "not found" >&6; } 29379 as_fn_error $? "User supplied tool JAR=$tool_specified does not exist or is not executable" "$LINENO" 5 29380 fi 29381 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 29382 $as_echo "$tool_specified" >&6; } 29383 fi 29384 fi 29385 fi 29386 29387 fi 29388 29389 29390 29391 # Use user overridden value if available, otherwise locate tool in the Boot JDK. 29392 29393 # Publish this variable in the help. 29394 29395 29396 if [ -z "${JARSIGNER+x}" ]; then 29397 # The variable is not set by user, try to locate tool using the code snippet 29398 29399 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jarsigner in Boot JDK" >&5 29400 $as_echo_n "checking for jarsigner in Boot JDK... " >&6; } 29401 JARSIGNER=$BOOT_JDK/bin/jarsigner 29402 if test ! -x $JARSIGNER; then 29403 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 29404 $as_echo "not found" >&6; } 29405 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 29406 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 29407 as_fn_error $? "Could not find jarsigner in the Boot JDK" "$LINENO" 5 29408 fi 29409 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 29410 $as_echo "ok" >&6; } 29411 29412 29413 else 29414 # The variable is set, but is it from the command line or the environment? 29415 29416 # Try to remove the string !JARSIGNER! from our list. 29417 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JARSIGNER!/} 29418 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 29419 # If it failed, the variable was not from the command line. Ignore it, 29420 # but warn the user (except for BASH, which is always set by the calling BASH). 29421 if test "xJARSIGNER" != xBASH; then 29422 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JARSIGNER from the environment. Use command line variables instead." >&5 29423 $as_echo "$as_me: WARNING: Ignoring value of JARSIGNER from the environment. Use command line variables instead." >&2;} 29424 fi 29425 # Try to locate tool using the code snippet 29426 29427 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jarsigner in Boot JDK" >&5 29428 $as_echo_n "checking for jarsigner in Boot JDK... " >&6; } 29429 JARSIGNER=$BOOT_JDK/bin/jarsigner 29430 if test ! -x $JARSIGNER; then 29431 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 29432 $as_echo "not found" >&6; } 29433 { $as_echo "$as_me:${as_lineno-$LINENO}: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&5 29434 $as_echo "$as_me: Your Boot JDK seems broken. This might be fixed by explicitely setting --with-boot-jdk" >&6;} 29435 as_fn_error $? "Could not find jarsigner in the Boot JDK" "$LINENO" 5 29436 fi 29437 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 29438 $as_echo "ok" >&6; } 29439 29440 29441 else 29442 # If it succeeded, then it was overridden by the user. We will use it 29443 # for the tool. 29444 29445 # First remove it from the list of overridden variables, so we can test 29446 # for unknown variables in the end. 29447 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 29448 29449 # Check if we try to supply an empty value 29450 if test "x$JARSIGNER" = x; then 29451 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JARSIGNER= (no value)" >&5 29452 $as_echo "$as_me: Setting user supplied tool JARSIGNER= (no value)" >&6;} 29453 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JARSIGNER" >&5 29454 $as_echo_n "checking for JARSIGNER... " >&6; } 29455 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 29456 $as_echo "disabled" >&6; } 29457 else 29458 # Check if the provided tool contains a complete path. 29459 tool_specified="$JARSIGNER" 29460 tool_basename="${tool_specified##*/}" 29461 if test "x$tool_basename" = "x$tool_specified"; then 29462 # A command without a complete path is provided, search $PATH. 29463 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JARSIGNER=$tool_basename" >&5 29464 $as_echo "$as_me: Will search for user supplied tool JARSIGNER=$tool_basename" >&6;} 29465 # Extract the first word of "$tool_basename", so it can be a program name with args. 29466 set dummy $tool_basename; ac_word=$2 29467 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 29468 $as_echo_n "checking for $ac_word... " >&6; } 29469 if ${ac_cv_path_JARSIGNER+:} false; then : 29470 $as_echo_n "(cached) " >&6 29471 else 29472 case $JARSIGNER in 29473 [\\/]* | ?:[\\/]*) 29474 ac_cv_path_JARSIGNER="$JARSIGNER" # Let the user override the test with a path. 29475 ;; 29476 *) 29477 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 29478 for as_dir in $PATH 29479 do 29480 IFS=$as_save_IFS 29481 test -z "$as_dir" && as_dir=. 29482 for ac_exec_ext in '' $ac_executable_extensions; do 29483 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 29484 ac_cv_path_JARSIGNER="$as_dir/$ac_word$ac_exec_ext" 29485 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 29486 break 2 29487 fi 29488 done 29489 done 29490 IFS=$as_save_IFS 29491 29492 ;; 29493 esac 29494 fi 29495 JARSIGNER=$ac_cv_path_JARSIGNER 29496 if test -n "$JARSIGNER"; then 29497 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JARSIGNER" >&5 29498 $as_echo "$JARSIGNER" >&6; } 29499 else 29500 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 29501 $as_echo "no" >&6; } 29502 fi 29503 29504 29505 if test "x$JARSIGNER" = x; then 29506 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 29507 fi 29508 else 29509 # Otherwise we believe it is a complete path. Use it as it is. 29510 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JARSIGNER=$tool_specified" >&5 29511 $as_echo "$as_me: Will use user supplied tool JARSIGNER=$tool_specified" >&6;} 29512 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JARSIGNER" >&5 29513 $as_echo_n "checking for JARSIGNER... " >&6; } 29514 if test ! -x "$tool_specified"; then 29515 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 29516 $as_echo "not found" >&6; } 29517 as_fn_error $? "User supplied tool JARSIGNER=$tool_specified does not exist or is not executable" "$LINENO" 5 29518 fi 29519 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 29520 $as_echo "$tool_specified" >&6; } 29521 fi 29522 fi 29523 fi 29524 29525 fi 29526 29527 29528 29529 # Finally, set some other options... 29530 29531 # When compiling code to be executed by the Boot JDK, force jdk8 compatibility. 29532 BOOT_JDK_SOURCETARGET="-source 8 -target 8" 29533 29534 29535 29536 # Check if the boot jdk is 32 or 64 bit 29537 if "$JAVA" -d64 -version > /dev/null 2>&1; then 29538 BOOT_JDK_BITS="64" 29539 else 29540 BOOT_JDK_BITS="32" 29541 fi 29542 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if Boot JDK is 32 or 64 bits" >&5 29543 $as_echo_n "checking if Boot JDK is 32 or 64 bits... " >&6; } 29544 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BOOT_JDK_BITS" >&5 29545 $as_echo "$BOOT_JDK_BITS" >&6; } 29546 29547 29548 29549 ############################################################################### 29550 # 29551 # Configure the sources to use. We can add or override individual directories. 29552 # 29553 ############################################################################### 29554 29555 29556 # Where are the sources. 29557 LANGTOOLS_TOPDIR="$SRC_ROOT/langtools" 29558 CORBA_TOPDIR="$SRC_ROOT/corba" 29559 JAXP_TOPDIR="$SRC_ROOT/jaxp" 29560 JAXWS_TOPDIR="$SRC_ROOT/jaxws" 29561 HOTSPOT_TOPDIR="$SRC_ROOT/hotspot" 29562 NASHORN_TOPDIR="$SRC_ROOT/nashorn" 29563 JDK_TOPDIR="$SRC_ROOT/jdk" 29564 29565 29566 29567 29568 29569 29570 29571 29572 29573 # This feature is no longer supported. 29574 29575 29576 29577 # Check whether --with-add-source-root was given. 29578 if test "${with_add_source_root+set}" = set; then : 29579 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 29580 $as_echo "$as_me: WARNING: Option --with-add-source-root is deprecated and will be ignored." >&2;} 29581 fi 29582 29583 29584 29585 29586 # Check whether --with-override-source-root was given. 29587 if test "${with_override_source_root+set}" = set; then : 29588 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 29589 $as_echo "$as_me: WARNING: Option --with-override-source-root is deprecated and will be ignored." >&2;} 29590 fi 29591 29592 29593 29594 29595 # Check whether --with-adds-and-overrides was given. 29596 if test "${with_adds_and_overrides+set}" = set; then : 29597 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 29598 $as_echo "$as_me: WARNING: Option --with-adds-and-overrides is deprecated and will be ignored." >&2;} 29599 fi 29600 29601 29602 29603 29604 # Check whether --with-override-langtools was given. 29605 if test "${with_override_langtools+set}" = set; then : 29606 withval=$with_override_langtools; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-override-langtools is deprecated and will be ignored." >&5 29607 $as_echo "$as_me: WARNING: Option --with-override-langtools is deprecated and will be ignored." >&2;} 29608 fi 29609 29610 29611 29612 29613 # Check whether --with-override-corba was given. 29614 if test "${with_override_corba+set}" = set; then : 29615 withval=$with_override_corba; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-override-corba is deprecated and will be ignored." >&5 29616 $as_echo "$as_me: WARNING: Option --with-override-corba is deprecated and will be ignored." >&2;} 29617 fi 29618 29619 29620 29621 29622 # Check whether --with-override-jaxp was given. 29623 if test "${with_override_jaxp+set}" = set; then : 29624 withval=$with_override_jaxp; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-override-jaxp is deprecated and will be ignored." >&5 29625 $as_echo "$as_me: WARNING: Option --with-override-jaxp is deprecated and will be ignored." >&2;} 29626 fi 29627 29628 29629 29630 29631 # Check whether --with-override-jaxws was given. 29632 if test "${with_override_jaxws+set}" = set; then : 29633 withval=$with_override_jaxws; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-override-jaxws is deprecated and will be ignored." >&5 29634 $as_echo "$as_me: WARNING: Option --with-override-jaxws is deprecated and will be ignored." >&2;} 29635 fi 29636 29637 29638 29639 29640 # Check whether --with-override-hotspot was given. 29641 if test "${with_override_hotspot+set}" = set; then : 29642 withval=$with_override_hotspot; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-override-hotspot is deprecated and will be ignored." >&5 29643 $as_echo "$as_me: WARNING: Option --with-override-hotspot is deprecated and will be ignored." >&2;} 29644 fi 29645 29646 29647 29648 29649 # Check whether --with-override-nashorn was given. 29650 if test "${with_override_nashorn+set}" = set; then : 29651 withval=$with_override_nashorn; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-override-nashorn is deprecated and will be ignored." >&5 29652 $as_echo "$as_me: WARNING: Option --with-override-nashorn is deprecated and will be ignored." >&2;} 29653 fi 29654 29655 29656 29657 29658 # Check whether --with-override-jdk was given. 29659 if test "${with_override_jdk+set}" = set; then : 29660 withval=$with_override_jdk; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-override-jdk is deprecated and will be ignored." >&5 29661 $as_echo "$as_me: WARNING: Option --with-override-jdk is deprecated and will be ignored." >&2;} 29662 fi 29663 29664 29665 29666 29667 BUILD_OUTPUT="$OUTPUT_ROOT" 29668 29669 29670 HOTSPOT_DIST="$OUTPUT_ROOT/hotspot/dist" 29671 BUILD_HOTSPOT=true 29672 29673 29674 29675 # Check whether --with-import-hotspot was given. 29676 if test "${with_import_hotspot+set}" = set; then : 29677 withval=$with_import_hotspot; 29678 fi 29679 29680 if test "x$with_import_hotspot" != x; then 29681 CURDIR="$PWD" 29682 cd "$with_import_hotspot" 29683 HOTSPOT_DIST="`pwd`" 29684 cd "$CURDIR" 29685 if ! (test -d $HOTSPOT_DIST/lib && test -d $HOTSPOT_DIST/jre/lib); then 29686 as_fn_error $? "You have to import hotspot from a full jdk image or hotspot build dist dir!" "$LINENO" 5 29687 fi 29688 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if hotspot should be imported" >&5 29689 $as_echo_n "checking if hotspot should be imported... " >&6; } 29690 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes from $HOTSPOT_DIST" >&5 29691 $as_echo "yes from $HOTSPOT_DIST" >&6; } 29692 BUILD_HOTSPOT=false 29693 fi 29694 29695 JDK_OUTPUTDIR="$OUTPUT_ROOT/jdk" 29696 29697 29698 ############################################################################### 29699 # 29700 # Setup the toolchain (compilers etc), i.e. tools used to compile and process 29701 # native code. 29702 # 29703 ############################################################################### 29704 29705 # See if we are doing a complete static build or not 29706 29707 # Check whether --enable-static-build was given. 29708 if test "${enable_static_build+set}" = set; then : 29709 enableval=$enable_static_build; 29710 fi 29711 29712 STATIC_BUILD=false 29713 if test "x$enable_static_build" = "xyes"; then 29714 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if static build is enabled" >&5 29715 $as_echo_n "checking if static build is enabled... " >&6; } 29716 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 29717 $as_echo "yes" >&6; } 29718 if test "x$OPENJDK_TARGET_OS" != "xmacosx"; then 29719 as_fn_error $? "--enable-static-build is only supported for macosx builds" "$LINENO" 5 29720 fi 29721 STATIC_BUILD_CFLAGS="-DSTATIC_BUILD=1" 29722 LEGACY_EXTRA_CFLAGS="$LEGACY_EXTRA_CFLAGS $STATIC_BUILD_CFLAGS" 29723 LEGACY_EXTRA_CXXFLAGS="$LEGACY_EXTRA_CXXFLAGS $STATIC_BUILD_CFLAGS" 29724 CFLAGS_JDKLIB_EXTRA="$CFLAGS_JDKLIB_EXTRA $STATIC_BUILD_CFLAGS" 29725 CXXFLAGS_JDKLIB_EXTRA="$CXXFLAGS_JDKLIB_EXTRA $STATIC_BUILD_CFLAGS" 29726 STATIC_BUILD=true 29727 elif test "x$enable_static_build" = "xno"; then 29728 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if static build is enabled" >&5 29729 $as_echo_n "checking if static build is enabled... " >&6; } 29730 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 29731 $as_echo "no" >&6; } 29732 elif test "x$enable_static_build" != "x"; then 29733 as_fn_error $? "--enable-static-build can only be assigned \"yes\" or \"no\"" "$LINENO" 5 29734 fi 29735 29736 29737 29738 29739 # First determine the toolchain type (compiler family) 29740 29741 29742 # Check whether --with-toolchain-type was given. 29743 if test "${with_toolchain_type+set}" = set; then : 29744 withval=$with_toolchain_type; 29745 fi 29746 29747 29748 # Use indirect variable referencing 29749 toolchain_var_name=VALID_TOOLCHAINS_$OPENJDK_BUILD_OS 29750 VALID_TOOLCHAINS=${!toolchain_var_name} 29751 29752 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 29753 if test -n "$XCODEBUILD"; then 29754 # On Mac OS X, default toolchain to clang after Xcode 5 29755 XCODE_VERSION_OUTPUT=`"$XCODEBUILD" -version 2>&1 | $HEAD -n 1` 29756 $ECHO "$XCODE_VERSION_OUTPUT" | $GREP "Xcode " > /dev/null 29757 if test $? -ne 0; then 29758 as_fn_error $? "Failed to determine Xcode version." "$LINENO" 5 29759 fi 29760 XCODE_MAJOR_VERSION=`$ECHO $XCODE_VERSION_OUTPUT | \ 29761 $SED -e 's/^Xcode \([1-9][0-9.]*\)/\1/' | \ 29762 $CUT -f 1 -d .` 29763 { $as_echo "$as_me:${as_lineno-$LINENO}: Xcode major version: $XCODE_MAJOR_VERSION" >&5 29764 $as_echo "$as_me: Xcode major version: $XCODE_MAJOR_VERSION" >&6;} 29765 if test $XCODE_MAJOR_VERSION -ge 5; then 29766 DEFAULT_TOOLCHAIN="clang" 29767 else 29768 DEFAULT_TOOLCHAIN="gcc" 29769 fi 29770 else 29771 # If Xcode is not installed, but the command line tools are 29772 # then we can't run xcodebuild. On these systems we should 29773 # default to clang 29774 DEFAULT_TOOLCHAIN="clang" 29775 fi 29776 else 29777 # First toolchain type in the list is the default 29778 DEFAULT_TOOLCHAIN=${VALID_TOOLCHAINS%% *} 29779 fi 29780 29781 if test "x$with_toolchain_type" = xlist; then 29782 # List all toolchains 29783 { $as_echo "$as_me:${as_lineno-$LINENO}: The following toolchains are valid on this platform:" >&5 29784 $as_echo "$as_me: The following toolchains are valid on this platform:" >&6;} 29785 for toolchain in $VALID_TOOLCHAINS; do 29786 toolchain_var_name=TOOLCHAIN_DESCRIPTION_$toolchain 29787 TOOLCHAIN_DESCRIPTION=${!toolchain_var_name} 29788 $PRINTF " %-10s %s\n" $toolchain "$TOOLCHAIN_DESCRIPTION" 29789 done 29790 29791 exit 0 29792 elif test "x$with_toolchain_type" != x; then 29793 # User override; check that it is valid 29794 if test "x${VALID_TOOLCHAINS/$with_toolchain_type/}" = "x${VALID_TOOLCHAINS}"; then 29795 { $as_echo "$as_me:${as_lineno-$LINENO}: Toolchain type $with_toolchain_type is not valid on this platform." >&5 29796 $as_echo "$as_me: Toolchain type $with_toolchain_type is not valid on this platform." >&6;} 29797 { $as_echo "$as_me:${as_lineno-$LINENO}: Valid toolchains: $VALID_TOOLCHAINS." >&5 29798 $as_echo "$as_me: Valid toolchains: $VALID_TOOLCHAINS." >&6;} 29799 as_fn_error $? "Cannot continue." "$LINENO" 5 29800 fi 29801 TOOLCHAIN_TYPE=$with_toolchain_type 29802 else 29803 # No flag given, use default 29804 TOOLCHAIN_TYPE=$DEFAULT_TOOLCHAIN 29805 fi 29806 29807 29808 TOOLCHAIN_CC_BINARY_clang="clang" 29809 TOOLCHAIN_CC_BINARY_gcc="gcc" 29810 TOOLCHAIN_CC_BINARY_microsoft="cl" 29811 TOOLCHAIN_CC_BINARY_solstudio="cc" 29812 TOOLCHAIN_CC_BINARY_xlc="xlc_r" 29813 29814 TOOLCHAIN_CXX_BINARY_clang="clang++" 29815 TOOLCHAIN_CXX_BINARY_gcc="g++" 29816 TOOLCHAIN_CXX_BINARY_microsoft="cl" 29817 TOOLCHAIN_CXX_BINARY_solstudio="CC" 29818 TOOLCHAIN_CXX_BINARY_xlc="xlC_r" 29819 29820 # Use indirect variable referencing 29821 toolchain_var_name=TOOLCHAIN_DESCRIPTION_$TOOLCHAIN_TYPE 29822 TOOLCHAIN_DESCRIPTION=${!toolchain_var_name} 29823 toolchain_var_name=TOOLCHAIN_CC_BINARY_$TOOLCHAIN_TYPE 29824 TOOLCHAIN_CC_BINARY=${!toolchain_var_name} 29825 toolchain_var_name=TOOLCHAIN_CXX_BINARY_$TOOLCHAIN_TYPE 29826 TOOLCHAIN_CXX_BINARY=${!toolchain_var_name} 29827 29828 29829 # Define filename patterns 29830 if test "x$OPENJDK_TARGET_OS" = xwindows; then 29831 LIBRARY_PREFIX= 29832 SHARED_LIBRARY_SUFFIX='.dll' 29833 STATIC_LIBRARY_SUFFIX='.lib' 29834 SHARED_LIBRARY='$1.dll' 29835 STATIC_LIBRARY='$1.lib' 29836 OBJ_SUFFIX='.obj' 29837 EXE_SUFFIX='.exe' 29838 else 29839 LIBRARY_PREFIX=lib 29840 SHARED_LIBRARY_SUFFIX='.so' 29841 STATIC_LIBRARY_SUFFIX='.a' 29842 SHARED_LIBRARY='lib$1.so' 29843 STATIC_LIBRARY='lib$1.a' 29844 OBJ_SUFFIX='.o' 29845 EXE_SUFFIX='' 29846 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 29847 # For full static builds, we're overloading the SHARED_LIBRARY 29848 # variables in order to limit the amount of changes required. 29849 # It would be better to remove SHARED and just use LIBRARY and 29850 # LIBRARY_SUFFIX for libraries that can be built either 29851 # shared or static and use STATIC_* for libraries that are 29852 # always built statically. 29853 if test "x$STATIC_BUILD" = xtrue; then 29854 SHARED_LIBRARY='lib$1.a' 29855 SHARED_LIBRARY_SUFFIX='.a' 29856 else 29857 SHARED_LIBRARY='lib$1.dylib' 29858 SHARED_LIBRARY_SUFFIX='.dylib' 29859 fi 29860 fi 29861 fi 29862 29863 29864 29865 29866 29867 29868 29869 29870 29871 29872 if test "x$TOOLCHAIN_TYPE" = "x$DEFAULT_TOOLCHAIN"; then 29873 { $as_echo "$as_me:${as_lineno-$LINENO}: Using default toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION)" >&5 29874 $as_echo "$as_me: Using default toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION)" >&6;} 29875 else 29876 { $as_echo "$as_me:${as_lineno-$LINENO}: Using user selected toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION). Default toolchain is $DEFAULT_TOOLCHAIN." >&5 29877 $as_echo "$as_me: Using user selected toolchain $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION). Default toolchain is $DEFAULT_TOOLCHAIN." >&6;} 29878 fi 29879 29880 29881 # User supplied flags should be used when configure detects compilers 29882 29883 if test "x$CFLAGS" != "x${ADDED_CFLAGS}"; then 29884 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring CFLAGS($CFLAGS) found in environment. Use --with-extra-cflags" >&5 29885 $as_echo "$as_me: WARNING: Ignoring CFLAGS($CFLAGS) found in environment. Use --with-extra-cflags" >&2;} 29886 fi 29887 29888 if test "x$CXXFLAGS" != "x${ADDED_CXXFLAGS}"; then 29889 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring CXXFLAGS($CXXFLAGS) found in environment. Use --with-extra-cxxflags" >&5 29890 $as_echo "$as_me: WARNING: Ignoring CXXFLAGS($CXXFLAGS) found in environment. Use --with-extra-cxxflags" >&2;} 29891 fi 29892 29893 if test "x$LDFLAGS" != "x${ADDED_LDFLAGS}"; then 29894 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring LDFLAGS($LDFLAGS) found in environment. Use --with-extra-ldflags" >&5 29895 $as_echo "$as_me: WARNING: Ignoring LDFLAGS($LDFLAGS) found in environment. Use --with-extra-ldflags" >&2;} 29896 fi 29897 29898 29899 # Check whether --with-extra-cflags was given. 29900 if test "${with_extra_cflags+set}" = set; then : 29901 withval=$with_extra_cflags; 29902 fi 29903 29904 29905 29906 # Check whether --with-extra-cxxflags was given. 29907 if test "${with_extra_cxxflags+set}" = set; then : 29908 withval=$with_extra_cxxflags; 29909 fi 29910 29911 29912 29913 # Check whether --with-extra-ldflags was given. 29914 if test "${with_extra_ldflags+set}" = set; then : 29915 withval=$with_extra_ldflags; 29916 fi 29917 29918 29919 EXTRA_CFLAGS="$with_extra_cflags" 29920 EXTRA_CXXFLAGS="$with_extra_cxxflags" 29921 EXTRA_LDFLAGS="$with_extra_ldflags" 29922 29923 # Hotspot needs these set in their legacy form 29924 LEGACY_EXTRA_CFLAGS="$LEGACY_EXTRA_CFLAGS $EXTRA_CFLAGS" 29925 LEGACY_EXTRA_CXXFLAGS="$LEGACY_EXTRA_CXXFLAGS $EXTRA_CXXFLAGS" 29926 LEGACY_EXTRA_LDFLAGS="$LEGACY_EXTRA_LDFLAGS $EXTRA_LDFLAGS" 29927 29928 29929 29930 29931 29932 # The global CFLAGS and LDLAGS variables are used by configure tests and 29933 # should include the extra parameters 29934 CFLAGS="$EXTRA_CFLAGS" 29935 CXXFLAGS="$EXTRA_CXXFLAGS" 29936 LDFLAGS="$EXTRA_LDFLAGS" 29937 CPPFLAGS="" 29938 29939 # The sysroot cflags are needed for configure to be able to run the compilers 29940 29941 if test "x$SYSROOT" != "x"; then 29942 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 29943 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 29944 # Solaris Studio does not have a concept of sysroot. Instead we must 29945 # make sure the default include and lib dirs are appended to each 29946 # compile and link command line. 29947 SYSROOT_CFLAGS="-I$SYSROOT/usr/include" 29948 SYSROOT_LDFLAGS="-L$SYSROOT/usr/lib$OPENJDK_TARGET_CPU_ISADIR \ 29949 -L$SYSROOT/lib$OPENJDK_TARGET_CPU_ISADIR \ 29950 -L$SYSROOT/usr/ccs/lib$OPENJDK_TARGET_CPU_ISADIR" 29951 fi 29952 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 29953 SYSROOT_CFLAGS="--sysroot=$SYSROOT" 29954 SYSROOT_LDFLAGS="--sysroot=$SYSROOT" 29955 elif test "x$TOOLCHAIN_TYPE" = xclang; then 29956 SYSROOT_CFLAGS="-isysroot $SYSROOT" 29957 SYSROOT_LDFLAGS="-isysroot $SYSROOT" 29958 fi 29959 # Propagate the sysroot args to hotspot 29960 LEGACY_EXTRA_CFLAGS="$LEGACY_EXTRA_CFLAGS $SYSROOT_CFLAGS" 29961 LEGACY_EXTRA_CXXFLAGS="$LEGACY_EXTRA_CXXFLAGS $SYSROOT_CFLAGS" 29962 LEGACY_EXTRA_LDFLAGS="$LEGACY_EXTRA_LDFLAGS $SYSROOT_LDFLAGS" 29963 # The global CFLAGS and LDFLAGS variables need these for configure to function 29964 CFLAGS="$CFLAGS $SYSROOT_CFLAGS" 29965 CPPFLAGS="$CPPFLAGS $SYSROOT_CFLAGS" 29966 CXXFLAGS="$CXXFLAGS $SYSROOT_CFLAGS" 29967 LDFLAGS="$LDFLAGS $SYSROOT_LDFLAGS" 29968 fi 29969 29970 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 29971 # We also need -iframework<path>/System/Library/Frameworks 29972 SYSROOT_CFLAGS="$SYSROOT_CFLAGS -iframework $SYSROOT/System/Library/Frameworks" 29973 SYSROOT_LDFLAGS="$SYSROOT_LDFLAGS -iframework $SYSROOT/System/Library/Frameworks" 29974 # These always need to be set, or we can't find the frameworks embedded in JavaVM.framework 29975 # set this here so it doesn't have to be peppered throughout the forest 29976 SYSROOT_CFLAGS="$SYSROOT_CFLAGS -F $SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks" 29977 SYSROOT_LDFLAGS="$SYSROOT_LDFLAGS -F $SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks" 29978 fi 29979 29980 29981 29982 29983 29984 # Then detect the actual binaries needed 29985 29986 # FIXME: Is this needed? 29987 ac_ext=cpp 29988 ac_cpp='$CXXCPP $CPPFLAGS' 29989 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 29990 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 29991 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 29992 29993 29994 # Store the CFLAGS etc passed to the configure script. 29995 ORG_CFLAGS="$CFLAGS" 29996 ORG_CXXFLAGS="$CXXFLAGS" 29997 29998 # autoconf magic only relies on PATH, so update it if tools dir is specified 29999 OLD_PATH="$PATH" 30000 30001 # On Windows, we need to detect the visual studio installation first. 30002 # This will change the PATH, but we need to keep that new PATH even 30003 # after toolchain detection is done, since the compiler (on x86) uses 30004 # it for DLL resolution in runtime. 30005 if test "x$OPENJDK_BUILD_OS" = "xwindows" \ 30006 && test "x$TOOLCHAIN_TYPE" = "xmicrosoft"; then 30007 30008 # Store path to cygwin link.exe to help excluding it when searching for 30009 # VS linker. This must be done before changing the PATH when looking for VS. 30010 # Extract the first word of "link", so it can be a program name with args. 30011 set dummy link; ac_word=$2 30012 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 30013 $as_echo_n "checking for $ac_word... " >&6; } 30014 if ${ac_cv_path_CYGWIN_LINK+:} false; then : 30015 $as_echo_n "(cached) " >&6 30016 else 30017 case $CYGWIN_LINK in 30018 [\\/]* | ?:[\\/]*) 30019 ac_cv_path_CYGWIN_LINK="$CYGWIN_LINK" # Let the user override the test with a path. 30020 ;; 30021 *) 30022 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 30023 for as_dir in $PATH 30024 do 30025 IFS=$as_save_IFS 30026 test -z "$as_dir" && as_dir=. 30027 for ac_exec_ext in '' $ac_executable_extensions; do 30028 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 30029 ac_cv_path_CYGWIN_LINK="$as_dir/$ac_word$ac_exec_ext" 30030 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 30031 break 2 30032 fi 30033 done 30034 done 30035 IFS=$as_save_IFS 30036 30037 ;; 30038 esac 30039 fi 30040 CYGWIN_LINK=$ac_cv_path_CYGWIN_LINK 30041 if test -n "$CYGWIN_LINK"; then 30042 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CYGWIN_LINK" >&5 30043 $as_echo "$CYGWIN_LINK" >&6; } 30044 else 30045 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 30046 $as_echo "no" >&6; } 30047 fi 30048 30049 30050 if test "x$CYGWIN_LINK" != x; then 30051 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the first found link.exe is actually the Cygwin link tool" >&5 30052 $as_echo_n "checking if the first found link.exe is actually the Cygwin link tool... " >&6; } 30053 "$CYGWIN_LINK" --version > /dev/null 30054 if test $? -eq 0 ; then 30055 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 30056 $as_echo "yes" >&6; } 30057 else 30058 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 30059 $as_echo "no" >&6; } 30060 # This might be the VS linker. Don't exclude it later on. 30061 CYGWIN_LINK="" 30062 fi 30063 fi 30064 30065 # First-hand choice is to locate and run the vsvars bat file. 30066 30067 30068 # Check whether --with-toolchain-version was given. 30069 if test "${with_toolchain_version+set}" = set; then : 30070 withval=$with_toolchain_version; 30071 fi 30072 30073 30074 if test "x$with_toolchain_version" = xlist; then 30075 # List all toolchains 30076 { $as_echo "$as_me:${as_lineno-$LINENO}: The following toolchain versions are valid on this platform:" >&5 30077 $as_echo "$as_me: The following toolchain versions are valid on this platform:" >&6;} 30078 for version in $VALID_VS_VERSIONS; do 30079 eval VS_DESCRIPTION=\${VS_DESCRIPTION_$version} 30080 $PRINTF " %-10s %s\n" $version "$VS_DESCRIPTION" 30081 done 30082 30083 exit 0 30084 elif test "x$DEVKIT_VS_VERSION" != x; then 30085 VS_VERSION=$DEVKIT_VS_VERSION 30086 TOOLCHAIN_VERSION=$VS_VERSION 30087 eval VS_DESCRIPTION="\${VS_DESCRIPTION_${VS_VERSION}}" 30088 eval VS_VERSION_INTERNAL="\${VS_VERSION_INTERNAL_${VS_VERSION}}" 30089 eval MSVCR_NAME="\${VS_MSVCR_${VS_VERSION}}" 30090 eval MSVCP_NAME="\${VS_MSVCP_${VS_VERSION}}" 30091 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 30092 VS_PATH="$TOOLCHAIN_PATH:$PATH" 30093 30094 # Convert DEVKIT_VS_INCLUDE into windows style VS_INCLUDE so that it 30095 # can still be exported as INCLUDE for compiler invocations without 30096 # SYSROOT_CFLAGS 30097 OLDIFS="$IFS" 30098 IFS=";" 30099 for i in $DEVKIT_VS_INCLUDE; do 30100 ipath=$i 30101 30102 unix_path="$ipath" 30103 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30104 windows_path=`$CYGPATH -m "$unix_path"` 30105 ipath="$windows_path" 30106 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30107 windows_path=`cmd //c echo $unix_path` 30108 ipath="$windows_path" 30109 fi 30110 30111 VS_INCLUDE="$VS_INCLUDE;$ipath" 30112 done 30113 # Convert DEVKIT_VS_LIB into VS_LIB so that it can still be exported 30114 # as LIB for compiler invocations without SYSROOT_LDFLAGS 30115 for i in $DEVKIT_VS_LIB; do 30116 libpath=$i 30117 30118 unix_path="$libpath" 30119 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30120 windows_path=`$CYGPATH -m "$unix_path"` 30121 libpath="$windows_path" 30122 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30123 windows_path=`cmd //c echo $unix_path` 30124 libpath="$windows_path" 30125 fi 30126 30127 VS_LIB="$VS_LIB;$libpath" 30128 done 30129 IFS="$OLDIFS" 30130 30131 { $as_echo "$as_me:${as_lineno-$LINENO}: Found devkit $VS_DESCRIPTION" >&5 30132 $as_echo "$as_me: Found devkit $VS_DESCRIPTION" >&6;} 30133 30134 elif test "x$with_toolchain_version" != x; then 30135 # User override; check that it is valid 30136 if test "x${VALID_VS_VERSIONS/$with_toolchain_version/}" = "x${VALID_VS_VERSIONS}"; then 30137 { $as_echo "$as_me:${as_lineno-$LINENO}: Visual Studio version $with_toolchain_version is not valid." >&5 30138 $as_echo "$as_me: Visual Studio version $with_toolchain_version is not valid." >&6;} 30139 { $as_echo "$as_me:${as_lineno-$LINENO}: Valid Visual Studio versions: $VALID_VS_VERSIONS." >&5 30140 $as_echo "$as_me: Valid Visual Studio versions: $VALID_VS_VERSIONS." >&6;} 30141 as_fn_error $? "Cannot continue." "$LINENO" 5 30142 fi 30143 VS_VERSIONS_PROBE_LIST="$with_toolchain_version" 30144 else 30145 # No flag given, use default 30146 VS_VERSIONS_PROBE_LIST="$VALID_VS_VERSIONS" 30147 fi 30148 30149 for VS_VERSION in $VS_VERSIONS_PROBE_LIST; do 30150 30151 VS_VERSION="$VS_VERSION" 30152 eval VS_COMNTOOLS_VAR="\${VS_ENVVAR_${VS_VERSION}}" 30153 eval VS_COMNTOOLS="\$${VS_COMNTOOLS_VAR}" 30154 eval VS_INSTALL_DIR="\${VS_VS_INSTALLDIR_${VS_VERSION}}" 30155 eval SDK_INSTALL_DIR="\${VS_SDK_INSTALLDIR_${VS_VERSION}}" 30156 30157 # When using --with-tools-dir, assume it points to the correct and default 30158 # version of Visual Studio or that --with-toolchain-version was also set. 30159 if test "x$with_tools_dir" != x; then 30160 30161 if test "x$VS_ENV_CMD" = x; then 30162 VS_VERSION="${VS_VERSION}" 30163 VS_BASE="$with_tools_dir/../.." 30164 METHOD="--with-tools-dir" 30165 30166 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 30167 VCVARSFILE="vc/bin/vcvars32.bat" 30168 else 30169 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 30170 fi 30171 30172 30173 windows_path="$VS_BASE" 30174 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30175 unix_path=`$CYGPATH -u "$windows_path"` 30176 VS_BASE="$unix_path" 30177 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30178 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 30179 VS_BASE="$unix_path" 30180 fi 30181 30182 if test -d "$VS_BASE"; then 30183 if test -f "$VS_BASE/$VCVARSFILE"; then 30184 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 30185 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 30186 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 30187 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 30188 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 30189 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 30190 else 30191 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 30192 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 30193 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 30194 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 30195 fi 30196 fi 30197 fi 30198 30199 30200 if test "x$VS_ENV_CMD" = x; then 30201 VS_VERSION="${VS_VERSION}" 30202 VS_BASE="$with_tools_dir/../../.." 30203 METHOD="--with-tools-dir" 30204 30205 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 30206 VCVARSFILE="vc/bin/vcvars32.bat" 30207 else 30208 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 30209 fi 30210 30211 30212 windows_path="$VS_BASE" 30213 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30214 unix_path=`$CYGPATH -u "$windows_path"` 30215 VS_BASE="$unix_path" 30216 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30217 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 30218 VS_BASE="$unix_path" 30219 fi 30220 30221 if test -d "$VS_BASE"; then 30222 if test -f "$VS_BASE/$VCVARSFILE"; then 30223 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 30224 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 30225 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 30226 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 30227 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 30228 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 30229 else 30230 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 30231 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 30232 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 30233 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 30234 fi 30235 fi 30236 fi 30237 30238 if test "x$VS_ENV_CMD" = x; then 30239 # Having specified an argument which is incorrect will produce an instant failure; 30240 # we should not go on looking 30241 { $as_echo "$as_me:${as_lineno-$LINENO}: The path given by --with-tools-dir does not contain a valid" >&5 30242 $as_echo "$as_me: The path given by --with-tools-dir does not contain a valid" >&6;} 30243 { $as_echo "$as_me:${as_lineno-$LINENO}: Visual Studio installation. Please point to the VC/bin or VC/bin/amd64" >&5 30244 $as_echo "$as_me: Visual Studio installation. Please point to the VC/bin or VC/bin/amd64" >&6;} 30245 { $as_echo "$as_me:${as_lineno-$LINENO}: directory within the Visual Studio installation" >&5 30246 $as_echo "$as_me: directory within the Visual Studio installation" >&6;} 30247 as_fn_error $? "Cannot locate a valid Visual Studio installation" "$LINENO" 5 30248 fi 30249 fi 30250 30251 VS_ENV_CMD="" 30252 VS_ENV_ARGS="" 30253 30254 if test "x$VS_COMNTOOLS" != x; then 30255 30256 if test "x$VS_ENV_CMD" = x; then 30257 VS_VERSION="${VS_VERSION}" 30258 VS_BASE="$VS_COMNTOOLS/../.." 30259 METHOD="$VS_COMNTOOLS_VAR variable" 30260 30261 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 30262 VCVARSFILE="vc/bin/vcvars32.bat" 30263 else 30264 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 30265 fi 30266 30267 30268 windows_path="$VS_BASE" 30269 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30270 unix_path=`$CYGPATH -u "$windows_path"` 30271 VS_BASE="$unix_path" 30272 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30273 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 30274 VS_BASE="$unix_path" 30275 fi 30276 30277 if test -d "$VS_BASE"; then 30278 if test -f "$VS_BASE/$VCVARSFILE"; then 30279 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 30280 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 30281 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 30282 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 30283 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 30284 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 30285 else 30286 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 30287 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 30288 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 30289 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 30290 fi 30291 fi 30292 fi 30293 30294 fi 30295 if test "x$PROGRAMFILES" != x; then 30296 30297 if test "x$VS_ENV_CMD" = x; then 30298 VS_VERSION="${VS_VERSION}" 30299 VS_BASE="$PROGRAMFILES/$VS_INSTALL_DIR" 30300 METHOD="well-known name" 30301 30302 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 30303 VCVARSFILE="vc/bin/vcvars32.bat" 30304 else 30305 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 30306 fi 30307 30308 30309 windows_path="$VS_BASE" 30310 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30311 unix_path=`$CYGPATH -u "$windows_path"` 30312 VS_BASE="$unix_path" 30313 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30314 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 30315 VS_BASE="$unix_path" 30316 fi 30317 30318 if test -d "$VS_BASE"; then 30319 if test -f "$VS_BASE/$VCVARSFILE"; then 30320 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 30321 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 30322 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 30323 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 30324 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 30325 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 30326 else 30327 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 30328 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 30329 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 30330 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 30331 fi 30332 fi 30333 fi 30334 30335 fi 30336 # Work around the insanely named ProgramFiles(x86) env variable 30337 PROGRAMFILES_X86="`env | $SED -n 's/^ProgramFiles(x86)=//p'`" 30338 if test "x$PROGRAMFILES_X86" != x; then 30339 30340 if test "x$VS_ENV_CMD" = x; then 30341 VS_VERSION="${VS_VERSION}" 30342 VS_BASE="$PROGRAMFILES_X86/$VS_INSTALL_DIR" 30343 METHOD="well-known name" 30344 30345 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 30346 VCVARSFILE="vc/bin/vcvars32.bat" 30347 else 30348 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 30349 fi 30350 30351 30352 windows_path="$VS_BASE" 30353 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30354 unix_path=`$CYGPATH -u "$windows_path"` 30355 VS_BASE="$unix_path" 30356 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30357 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 30358 VS_BASE="$unix_path" 30359 fi 30360 30361 if test -d "$VS_BASE"; then 30362 if test -f "$VS_BASE/$VCVARSFILE"; then 30363 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 30364 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 30365 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 30366 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 30367 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 30368 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 30369 else 30370 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 30371 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 30372 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 30373 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 30374 fi 30375 fi 30376 fi 30377 30378 fi 30379 30380 if test "x$VS_ENV_CMD" = x; then 30381 VS_VERSION="${VS_VERSION}" 30382 VS_BASE="C:/Program Files/$VS_INSTALL_DIR" 30383 METHOD="well-known name" 30384 30385 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 30386 VCVARSFILE="vc/bin/vcvars32.bat" 30387 else 30388 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 30389 fi 30390 30391 30392 windows_path="$VS_BASE" 30393 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30394 unix_path=`$CYGPATH -u "$windows_path"` 30395 VS_BASE="$unix_path" 30396 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30397 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 30398 VS_BASE="$unix_path" 30399 fi 30400 30401 if test -d "$VS_BASE"; then 30402 if test -f "$VS_BASE/$VCVARSFILE"; then 30403 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 30404 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 30405 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 30406 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 30407 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 30408 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 30409 else 30410 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 30411 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 30412 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 30413 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 30414 fi 30415 fi 30416 fi 30417 30418 30419 if test "x$VS_ENV_CMD" = x; then 30420 VS_VERSION="${VS_VERSION}" 30421 VS_BASE="C:/Program Files (x86)/$VS_INSTALL_DIR" 30422 METHOD="well-known name" 30423 30424 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 30425 VCVARSFILE="vc/bin/vcvars32.bat" 30426 else 30427 VCVARSFILE="vc/bin/amd64/vcvars64.bat" 30428 fi 30429 30430 30431 windows_path="$VS_BASE" 30432 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30433 unix_path=`$CYGPATH -u "$windows_path"` 30434 VS_BASE="$unix_path" 30435 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30436 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 30437 VS_BASE="$unix_path" 30438 fi 30439 30440 if test -d "$VS_BASE"; then 30441 if test -f "$VS_BASE/$VCVARSFILE"; then 30442 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 30443 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 30444 VS_ENV_CMD="$VS_BASE/$VCVARSFILE" 30445 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 30446 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be one of 'v100', 'v110' or 'v120' for VS 2010, 2012 or VS2013 30447 eval PLATFORM_TOOLSET="\${VS_VS_PLATFORM_NAME_${VS_VERSION}}" 30448 else 30449 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Visual Studio installation at $VS_BASE using $METHOD" >&5 30450 $as_echo "$as_me: Found Visual Studio installation at $VS_BASE using $METHOD" >&6;} 30451 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&5 30452 $as_echo "$as_me: Warning: $VCVARSFILE is missing, this is probably Visual Studio Express. Ignoring" >&6;} 30453 fi 30454 fi 30455 fi 30456 30457 30458 if test "x$SDK_INSTALL_DIR" != x; then 30459 if test "x$ProgramW6432" != x; then 30460 30461 if test "x$VS_ENV_CMD" = x; then 30462 VS_VERSION="${VS_VERSION}" 30463 WIN_SDK_BASE="$ProgramW6432/$SDK_INSTALL_DIR" 30464 METHOD="well-known name" 30465 30466 windows_path="$WIN_SDK_BASE" 30467 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30468 unix_path=`$CYGPATH -u "$windows_path"` 30469 WIN_SDK_BASE="$unix_path" 30470 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30471 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 30472 WIN_SDK_BASE="$unix_path" 30473 fi 30474 30475 if test -d "$WIN_SDK_BASE"; then 30476 # There have been cases of partial or broken SDK installations. A missing 30477 # lib dir is not going to work. 30478 if test ! -d "$WIN_SDK_BASE/lib"; then 30479 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 30480 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 30481 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 30482 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 30483 elif test -f "$WIN_SDK_BASE/Bin/SetEnv.Cmd"; then 30484 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 30485 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 30486 VS_ENV_CMD="$WIN_SDK_BASE/Bin/SetEnv.Cmd" 30487 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 30488 VS_ENV_ARGS="/x86" 30489 else 30490 VS_ENV_ARGS="/x64" 30491 fi 30492 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 30493 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK 30494 # TODO: improve detection for other versions of SDK 30495 eval PLATFORM_TOOLSET="\${VS_SDK_PLATFORM_NAME_${VS_VERSION}}" 30496 else 30497 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 30498 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 30499 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 30500 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 30501 fi 30502 fi 30503 fi 30504 30505 fi 30506 if test "x$PROGRAMW6432" != x; then 30507 30508 if test "x$VS_ENV_CMD" = x; then 30509 VS_VERSION="${VS_VERSION}" 30510 WIN_SDK_BASE="$PROGRAMW6432/$SDK_INSTALL_DIR" 30511 METHOD="well-known name" 30512 30513 windows_path="$WIN_SDK_BASE" 30514 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30515 unix_path=`$CYGPATH -u "$windows_path"` 30516 WIN_SDK_BASE="$unix_path" 30517 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30518 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 30519 WIN_SDK_BASE="$unix_path" 30520 fi 30521 30522 if test -d "$WIN_SDK_BASE"; then 30523 # There have been cases of partial or broken SDK installations. A missing 30524 # lib dir is not going to work. 30525 if test ! -d "$WIN_SDK_BASE/lib"; then 30526 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 30527 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 30528 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 30529 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 30530 elif test -f "$WIN_SDK_BASE/Bin/SetEnv.Cmd"; then 30531 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 30532 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 30533 VS_ENV_CMD="$WIN_SDK_BASE/Bin/SetEnv.Cmd" 30534 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 30535 VS_ENV_ARGS="/x86" 30536 else 30537 VS_ENV_ARGS="/x64" 30538 fi 30539 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 30540 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK 30541 # TODO: improve detection for other versions of SDK 30542 eval PLATFORM_TOOLSET="\${VS_SDK_PLATFORM_NAME_${VS_VERSION}}" 30543 else 30544 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 30545 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 30546 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 30547 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 30548 fi 30549 fi 30550 fi 30551 30552 fi 30553 if test "x$PROGRAMFILES" != x; then 30554 30555 if test "x$VS_ENV_CMD" = x; then 30556 VS_VERSION="${VS_VERSION}" 30557 WIN_SDK_BASE="$PROGRAMFILES/$SDK_INSTALL_DIR" 30558 METHOD="well-known name" 30559 30560 windows_path="$WIN_SDK_BASE" 30561 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30562 unix_path=`$CYGPATH -u "$windows_path"` 30563 WIN_SDK_BASE="$unix_path" 30564 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30565 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 30566 WIN_SDK_BASE="$unix_path" 30567 fi 30568 30569 if test -d "$WIN_SDK_BASE"; then 30570 # There have been cases of partial or broken SDK installations. A missing 30571 # lib dir is not going to work. 30572 if test ! -d "$WIN_SDK_BASE/lib"; then 30573 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 30574 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 30575 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 30576 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 30577 elif test -f "$WIN_SDK_BASE/Bin/SetEnv.Cmd"; then 30578 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 30579 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 30580 VS_ENV_CMD="$WIN_SDK_BASE/Bin/SetEnv.Cmd" 30581 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 30582 VS_ENV_ARGS="/x86" 30583 else 30584 VS_ENV_ARGS="/x64" 30585 fi 30586 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 30587 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK 30588 # TODO: improve detection for other versions of SDK 30589 eval PLATFORM_TOOLSET="\${VS_SDK_PLATFORM_NAME_${VS_VERSION}}" 30590 else 30591 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 30592 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 30593 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 30594 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 30595 fi 30596 fi 30597 fi 30598 30599 fi 30600 30601 if test "x$VS_ENV_CMD" = x; then 30602 VS_VERSION="${VS_VERSION}" 30603 WIN_SDK_BASE="C:/Program Files/$SDK_INSTALL_DIR" 30604 METHOD="well-known name" 30605 30606 windows_path="$WIN_SDK_BASE" 30607 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30608 unix_path=`$CYGPATH -u "$windows_path"` 30609 WIN_SDK_BASE="$unix_path" 30610 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30611 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 30612 WIN_SDK_BASE="$unix_path" 30613 fi 30614 30615 if test -d "$WIN_SDK_BASE"; then 30616 # There have been cases of partial or broken SDK installations. A missing 30617 # lib dir is not going to work. 30618 if test ! -d "$WIN_SDK_BASE/lib"; then 30619 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 30620 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 30621 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 30622 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 30623 elif test -f "$WIN_SDK_BASE/Bin/SetEnv.Cmd"; then 30624 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 30625 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 30626 VS_ENV_CMD="$WIN_SDK_BASE/Bin/SetEnv.Cmd" 30627 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 30628 VS_ENV_ARGS="/x86" 30629 else 30630 VS_ENV_ARGS="/x64" 30631 fi 30632 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 30633 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK 30634 # TODO: improve detection for other versions of SDK 30635 eval PLATFORM_TOOLSET="\${VS_SDK_PLATFORM_NAME_${VS_VERSION}}" 30636 else 30637 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 30638 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 30639 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 30640 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 30641 fi 30642 fi 30643 fi 30644 30645 30646 if test "x$VS_ENV_CMD" = x; then 30647 VS_VERSION="${VS_VERSION}" 30648 WIN_SDK_BASE="C:/Program Files (x86)/$SDK_INSTALL_DIR" 30649 METHOD="well-known name" 30650 30651 windows_path="$WIN_SDK_BASE" 30652 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30653 unix_path=`$CYGPATH -u "$windows_path"` 30654 WIN_SDK_BASE="$unix_path" 30655 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30656 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 30657 WIN_SDK_BASE="$unix_path" 30658 fi 30659 30660 if test -d "$WIN_SDK_BASE"; then 30661 # There have been cases of partial or broken SDK installations. A missing 30662 # lib dir is not going to work. 30663 if test ! -d "$WIN_SDK_BASE/lib"; then 30664 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 30665 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 30666 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, lib dir is missing. Ignoring" >&5 30667 $as_echo "$as_me: Warning: Installation is broken, lib dir is missing. Ignoring" >&6;} 30668 elif test -f "$WIN_SDK_BASE/Bin/SetEnv.Cmd"; then 30669 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 30670 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 30671 VS_ENV_CMD="$WIN_SDK_BASE/Bin/SetEnv.Cmd" 30672 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 30673 VS_ENV_ARGS="/x86" 30674 else 30675 VS_ENV_ARGS="/x64" 30676 fi 30677 # PLATFORM_TOOLSET is used during the compilation of the freetype sources (see 30678 # 'LIB_BUILD_FREETYPE' in libraries.m4) and must be 'Windows7.1SDK' for Windows7.1SDK 30679 # TODO: improve detection for other versions of SDK 30680 eval PLATFORM_TOOLSET="\${VS_SDK_PLATFORM_NAME_${VS_VERSION}}" 30681 else 30682 { $as_echo "$as_me:${as_lineno-$LINENO}: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&5 30683 $as_echo "$as_me: Found Windows SDK installation at $WIN_SDK_BASE using $METHOD" >&6;} 30684 { $as_echo "$as_me:${as_lineno-$LINENO}: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&5 30685 $as_echo "$as_me: Warning: Installation is broken, SetEnv.Cmd is missing. Ignoring" >&6;} 30686 fi 30687 fi 30688 fi 30689 30690 fi 30691 30692 if test "x$VS_ENV_CMD" != x; then 30693 TOOLCHAIN_VERSION=$VS_VERSION 30694 eval VS_DESCRIPTION="\${VS_DESCRIPTION_${VS_VERSION}}" 30695 eval VS_VERSION_INTERNAL="\${VS_VERSION_INTERNAL_${VS_VERSION}}" 30696 eval MSVCR_NAME="\${VS_MSVCR_${VS_VERSION}}" 30697 eval MSVCP_NAME="\${VS_MSVCP_${VS_VERSION}}" 30698 # The rest of the variables are already evaled while probing 30699 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $VS_DESCRIPTION" >&5 30700 $as_echo "$as_me: Found $VS_DESCRIPTION" >&6;} 30701 break 30702 fi 30703 done 30704 30705 30706 # If we have a devkit, skip all of the below. 30707 if test "x$DEVKIT_VS_VERSION" = x; then 30708 if test "x$VS_ENV_CMD" != x; then 30709 # We have found a Visual Studio environment on disk, let's extract variables from the vsvars bat file. 30710 30711 # Only process if variable expands to non-empty 30712 30713 if test "x$VS_ENV_CMD" != x; then 30714 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30715 30716 # First separate the path from the arguments. This will split at the first 30717 # space. 30718 complete="$VS_ENV_CMD" 30719 path="${complete%% *}" 30720 tmp="$complete EOL" 30721 arguments="${tmp#* }" 30722 30723 # Input might be given as Windows format, start by converting to 30724 # unix format. 30725 new_path=`$CYGPATH -u "$path"` 30726 30727 # Now try to locate executable using which 30728 new_path=`$WHICH "$new_path" 2> /dev/null` 30729 # bat and cmd files are not always considered executable in cygwin causing which 30730 # to not find them 30731 if test "x$new_path" = x \ 30732 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 30733 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 30734 new_path=`$CYGPATH -u "$path"` 30735 fi 30736 if test "x$new_path" = x; then 30737 # Oops. Which didn't find the executable. 30738 # The splitting of arguments from the executable at a space might have been incorrect, 30739 # since paths with space are more likely in Windows. Give it another try with the whole 30740 # argument. 30741 path="$complete" 30742 arguments="EOL" 30743 new_path=`$CYGPATH -u "$path"` 30744 new_path=`$WHICH "$new_path" 2> /dev/null` 30745 # bat and cmd files are not always considered executable in cygwin causing which 30746 # to not find them 30747 if test "x$new_path" = x \ 30748 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 30749 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 30750 new_path=`$CYGPATH -u "$path"` 30751 fi 30752 if test "x$new_path" = x; then 30753 # It's still not found. Now this is an unrecoverable error. 30754 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5 30755 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;} 30756 has_space=`$ECHO "$complete" | $GREP " "` 30757 if test "x$has_space" != x; then 30758 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 30759 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 30760 fi 30761 as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5 30762 fi 30763 fi 30764 30765 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 30766 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 30767 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 30768 # "foo.exe" is OK but "foo" is an error. 30769 # 30770 # This test is therefore slightly more accurate than "test -f" to check for file presence. 30771 # It is also a way to make sure we got the proper file name for the real test later on. 30772 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 30773 if test "x$test_shortpath" = x; then 30774 # Short path failed, file does not exist as specified. 30775 # Try adding .exe or .cmd 30776 if test -f "${new_path}.exe"; then 30777 input_to_shortpath="${new_path}.exe" 30778 elif test -f "${new_path}.cmd"; then 30779 input_to_shortpath="${new_path}.cmd" 30780 else 30781 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$new_path\", is invalid." >&5 30782 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$new_path\", is invalid." >&6;} 30783 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 30784 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 30785 as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5 30786 fi 30787 else 30788 input_to_shortpath="$new_path" 30789 fi 30790 30791 # Call helper function which possibly converts this using DOS-style short mode. 30792 # If so, the updated path is stored in $new_path. 30793 new_path="$input_to_shortpath" 30794 30795 input_path="$input_to_shortpath" 30796 # Check if we need to convert this using DOS-style short mode. If the path 30797 # contains just simple characters, use it. Otherwise (spaces, weird characters), 30798 # take no chances and rewrite it. 30799 # Note: m4 eats our [], so we need to use [ and ] instead. 30800 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 30801 if test "x$has_forbidden_chars" != x; then 30802 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 30803 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 30804 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 30805 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 30806 # Going to short mode and back again did indeed matter. Since short mode is 30807 # case insensitive, let's make it lowercase to improve readability. 30808 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 30809 # Now convert it back to Unix-style (cygpath) 30810 input_path=`$CYGPATH -u "$shortmode_path"` 30811 new_path="$input_path" 30812 fi 30813 fi 30814 30815 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 30816 if test "x$test_cygdrive_prefix" = x; then 30817 # As a simple fix, exclude /usr/bin since it's not a real path. 30818 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 30819 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 30820 # a path prefixed by /cygdrive for fixpath to work. 30821 new_path="$CYGWIN_ROOT_PATH$input_path" 30822 fi 30823 fi 30824 30825 # remove trailing .exe if any 30826 new_path="${new_path/%.exe/}" 30827 30828 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30829 30830 # First separate the path from the arguments. This will split at the first 30831 # space. 30832 complete="$VS_ENV_CMD" 30833 path="${complete%% *}" 30834 tmp="$complete EOL" 30835 arguments="${tmp#* }" 30836 30837 # Input might be given as Windows format, start by converting to 30838 # unix format. 30839 new_path="$path" 30840 30841 windows_path="$new_path" 30842 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30843 unix_path=`$CYGPATH -u "$windows_path"` 30844 new_path="$unix_path" 30845 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30846 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 30847 new_path="$unix_path" 30848 fi 30849 30850 30851 # Now try to locate executable using which 30852 new_path=`$WHICH "$new_path" 2> /dev/null` 30853 30854 if test "x$new_path" = x; then 30855 # Oops. Which didn't find the executable. 30856 # The splitting of arguments from the executable at a space might have been incorrect, 30857 # since paths with space are more likely in Windows. Give it another try with the whole 30858 # argument. 30859 path="$complete" 30860 arguments="EOL" 30861 new_path="$path" 30862 30863 windows_path="$new_path" 30864 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30865 unix_path=`$CYGPATH -u "$windows_path"` 30866 new_path="$unix_path" 30867 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30868 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 30869 new_path="$unix_path" 30870 fi 30871 30872 30873 new_path=`$WHICH "$new_path" 2> /dev/null` 30874 # bat and cmd files are not always considered executable in MSYS causing which 30875 # to not find them 30876 if test "x$new_path" = x \ 30877 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 30878 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 30879 new_path="$path" 30880 30881 windows_path="$new_path" 30882 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30883 unix_path=`$CYGPATH -u "$windows_path"` 30884 new_path="$unix_path" 30885 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30886 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 30887 new_path="$unix_path" 30888 fi 30889 30890 fi 30891 30892 if test "x$new_path" = x; then 30893 # It's still not found. Now this is an unrecoverable error. 30894 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5 30895 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;} 30896 has_space=`$ECHO "$complete" | $GREP " "` 30897 if test "x$has_space" != x; then 30898 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 30899 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 30900 fi 30901 as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5 30902 fi 30903 fi 30904 30905 # Now new_path has a complete unix path to the binary 30906 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 30907 # Keep paths in /bin as-is, but remove trailing .exe if any 30908 new_path="${new_path/%.exe/}" 30909 # Do not save /bin paths to all_fixpath_prefixes! 30910 else 30911 # Not in mixed or Windows style, start by that. 30912 new_path=`cmd //c echo $new_path` 30913 30914 input_path="$new_path" 30915 # Check if we need to convert this using DOS-style short mode. If the path 30916 # contains just simple characters, use it. Otherwise (spaces, weird characters), 30917 # take no chances and rewrite it. 30918 # Note: m4 eats our [], so we need to use [ and ] instead. 30919 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 30920 if test "x$has_forbidden_chars" != x; then 30921 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 30922 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 30923 fi 30924 30925 # Output is in $new_path 30926 30927 windows_path="$new_path" 30928 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 30929 unix_path=`$CYGPATH -u "$windows_path"` 30930 new_path="$unix_path" 30931 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 30932 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 30933 new_path="$unix_path" 30934 fi 30935 30936 # remove trailing .exe if any 30937 new_path="${new_path/%.exe/}" 30938 30939 # Save the first 10 bytes of this path to the storage, so fixpath can work. 30940 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 30941 fi 30942 30943 else 30944 # We're on a unix platform. Hooray! :) 30945 # First separate the path from the arguments. This will split at the first 30946 # space. 30947 complete="$VS_ENV_CMD" 30948 path="${complete%% *}" 30949 tmp="$complete EOL" 30950 arguments="${tmp#* }" 30951 30952 # Cannot rely on the command "which" here since it doesn't always work. 30953 is_absolute_path=`$ECHO "$path" | $GREP ^/` 30954 if test -z "$is_absolute_path"; then 30955 # Path to executable is not absolute. Find it. 30956 IFS_save="$IFS" 30957 IFS=: 30958 for p in $PATH; do 30959 if test -f "$p/$path" && test -x "$p/$path"; then 30960 new_path="$p/$path" 30961 break 30962 fi 30963 done 30964 IFS="$IFS_save" 30965 else 30966 # This is an absolute path, we can use it without further modifications. 30967 new_path="$path" 30968 fi 30969 30970 if test "x$new_path" = x; then 30971 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&5 30972 $as_echo "$as_me: The path of VS_ENV_CMD, which resolves as \"$complete\", is not found." >&6;} 30973 has_space=`$ECHO "$complete" | $GREP " "` 30974 if test "x$has_space" != x; then 30975 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 30976 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 30977 fi 30978 as_fn_error $? "Cannot locate the the path of VS_ENV_CMD" "$LINENO" 5 30979 fi 30980 fi 30981 30982 # Now join together the path and the arguments once again 30983 if test "x$arguments" != xEOL; then 30984 new_complete="$new_path ${arguments% *}" 30985 else 30986 new_complete="$new_path" 30987 fi 30988 30989 if test "x$complete" != "x$new_complete"; then 30990 VS_ENV_CMD="$new_complete" 30991 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting VS_ENV_CMD to \"$new_complete\"" >&5 30992 $as_echo "$as_me: Rewriting VS_ENV_CMD to \"$new_complete\"" >&6;} 30993 fi 30994 fi 30995 30996 30997 # Lets extract the variables that are set by vcvarsall.bat/vsvars32.bat/vsvars64.bat 30998 { $as_echo "$as_me:${as_lineno-$LINENO}: Trying to extract Visual Studio environment variables" >&5 30999 $as_echo "$as_me: Trying to extract Visual Studio environment variables" >&6;} 31000 31001 # We need to create a couple of temporary files. 31002 VS_ENV_TMP_DIR="$CONFIGURESUPPORT_OUTPUTDIR/vs-env" 31003 $MKDIR -p $VS_ENV_TMP_DIR 31004 31005 # Cannot use the VS10 setup script directly (since it only updates the DOS subshell environment). 31006 # Instead create a shell script which will set the relevant variables when run. 31007 WINPATH_VS_ENV_CMD="$VS_ENV_CMD" 31008 31009 unix_path="$WINPATH_VS_ENV_CMD" 31010 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31011 windows_path=`$CYGPATH -m "$unix_path"` 31012 WINPATH_VS_ENV_CMD="$windows_path" 31013 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31014 windows_path=`cmd //c echo $unix_path` 31015 WINPATH_VS_ENV_CMD="$windows_path" 31016 fi 31017 31018 WINPATH_BASH="$BASH" 31019 31020 unix_path="$WINPATH_BASH" 31021 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31022 windows_path=`$CYGPATH -m "$unix_path"` 31023 WINPATH_BASH="$windows_path" 31024 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31025 windows_path=`cmd //c echo $unix_path` 31026 WINPATH_BASH="$windows_path" 31027 fi 31028 31029 31030 # Generate a DOS batch file which runs $VS_ENV_CMD, and then creates a shell 31031 # script (executable by bash) that will setup the important variables. 31032 EXTRACT_VC_ENV_BAT_FILE="$VS_ENV_TMP_DIR/extract-vs-env.bat" 31033 $ECHO "@echo off" > $EXTRACT_VC_ENV_BAT_FILE 31034 # This will end up something like: 31035 # call C:/progra~2/micros~2.0/vc/bin/amd64/vcvars64.bat 31036 $ECHO "call $WINPATH_VS_ENV_CMD $VS_ENV_ARGS" >> $EXTRACT_VC_ENV_BAT_FILE 31037 # These will end up something like: 31038 # C:/CygWin/bin/bash -c 'echo VS_PATH=\"$PATH\" > localdevenv.sh 31039 # The trailing space for everyone except PATH is no typo, but is needed due 31040 # to trailing \ in the Windows paths. These will be stripped later. 31041 $ECHO "$WINPATH_BASH -c 'echo VS_PATH="'\"$PATH\" > set-vs-env.sh' \ 31042 >> $EXTRACT_VC_ENV_BAT_FILE 31043 $ECHO "$WINPATH_BASH -c 'echo VS_INCLUDE="'\"$INCLUDE\;$include \" >> set-vs-env.sh' \ 31044 >> $EXTRACT_VC_ENV_BAT_FILE 31045 $ECHO "$WINPATH_BASH -c 'echo VS_LIB="'\"$LIB\;$lib \" >> set-vs-env.sh' \ 31046 >> $EXTRACT_VC_ENV_BAT_FILE 31047 $ECHO "$WINPATH_BASH -c 'echo VCINSTALLDIR="'\"$VCINSTALLDIR \" >> set-vs-env.sh' \ 31048 >> $EXTRACT_VC_ENV_BAT_FILE 31049 $ECHO "$WINPATH_BASH -c 'echo WindowsSdkDir="'\"$WindowsSdkDir \" >> set-vs-env.sh' \ 31050 >> $EXTRACT_VC_ENV_BAT_FILE 31051 $ECHO "$WINPATH_BASH -c 'echo WINDOWSSDKDIR="'\"$WINDOWSSDKDIR \" >> set-vs-env.sh' \ 31052 >> $EXTRACT_VC_ENV_BAT_FILE 31053 31054 # Now execute the newly created bat file. 31055 # The | cat is to stop SetEnv.Cmd to mess with system colors on msys. 31056 # Change directory so we don't need to mess with Windows paths in redirects. 31057 cd $VS_ENV_TMP_DIR 31058 cmd /c extract-vs-env.bat | $CAT 31059 cd $CURDIR 31060 31061 if test ! -s $VS_ENV_TMP_DIR/set-vs-env.sh; then 31062 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not succesfully extract the envionment variables needed for the VS setup." >&5 31063 $as_echo "$as_me: Could not succesfully extract the envionment variables needed for the VS setup." >&6;} 31064 { $as_echo "$as_me:${as_lineno-$LINENO}: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&5 31065 $as_echo "$as_me: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&6;} 31066 { $as_echo "$as_me:${as_lineno-$LINENO}: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&5 31067 $as_echo "$as_me: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&6;} 31068 as_fn_error $? "Cannot continue" "$LINENO" 5 31069 fi 31070 31071 # Now set all paths and other env variables. This will allow the rest of 31072 # the configure script to find and run the compiler in the proper way. 31073 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting extracted environment variables" >&5 31074 $as_echo "$as_me: Setting extracted environment variables" >&6;} 31075 . $VS_ENV_TMP_DIR/set-vs-env.sh 31076 # Now we have VS_PATH, VS_INCLUDE, VS_LIB. For further checking, we 31077 # also define VCINSTALLDIR, WindowsSdkDir and WINDOWSSDKDIR. 31078 else 31079 # We did not find a vsvars bat file, let's hope we are run from a VS command prompt. 31080 { $as_echo "$as_me:${as_lineno-$LINENO}: Cannot locate a valid Visual Studio installation, checking current environment" >&5 31081 $as_echo "$as_me: Cannot locate a valid Visual Studio installation, checking current environment" >&6;} 31082 fi 31083 fi 31084 31085 # At this point, we should have correct variables in the environment, or we can't continue. 31086 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Visual Studio variables" >&5 31087 $as_echo_n "checking for Visual Studio variables... " >&6; } 31088 31089 if test "x$VCINSTALLDIR" != x || test "x$WindowsSDKDir" != x \ 31090 || test "x$WINDOWSSDKDIR" != x || test "x$DEVKIT_NAME" != x; then 31091 if test "x$VS_INCLUDE" = x || test "x$VS_LIB" = x; then 31092 { $as_echo "$as_me:${as_lineno-$LINENO}: result: present but broken" >&5 31093 $as_echo "present but broken" >&6; } 31094 as_fn_error $? "Your VC command prompt seems broken, INCLUDE and/or LIB is missing." "$LINENO" 5 31095 else 31096 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 31097 $as_echo "ok" >&6; } 31098 # Remove any trailing "\" ";" and " " from the variables. 31099 VS_INCLUDE=`$ECHO "$VS_INCLUDE" | $SED -e 's/\\\\*;* *$//'` 31100 VS_LIB=`$ECHO "$VS_LIB" | $SED 's/\\\\*;* *$//'` 31101 VCINSTALLDIR=`$ECHO "$VCINSTALLDIR" | $SED 's/\\\\* *$//'` 31102 WindowsSDKDir=`$ECHO "$WindowsSDKDir" | $SED 's/\\\\* *$//'` 31103 WINDOWSSDKDIR=`$ECHO "$WINDOWSSDKDIR" | $SED 's/\\\\* *$//'` 31104 # Remove any paths containing # (typically F#) as that messes up make. This 31105 # is needed if visual studio was installed with F# support. 31106 VS_PATH=`$ECHO "$VS_PATH" | $SED 's/[^:#]*#[^:]*://g'` 31107 31108 31109 31110 31111 31112 # Convert VS_INCLUDE into SYSROOT_CFLAGS 31113 OLDIFS="$IFS" 31114 IFS=";" 31115 for i in $VS_INCLUDE; do 31116 ipath=$i 31117 # Only process non-empty elements 31118 if test "x$ipath" != x; then 31119 IFS="$OLDIFS" 31120 # Check that directory exists before calling fixup_path 31121 testpath=$ipath 31122 31123 windows_path="$testpath" 31124 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31125 unix_path=`$CYGPATH -u "$windows_path"` 31126 testpath="$unix_path" 31127 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31128 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31129 testpath="$unix_path" 31130 fi 31131 31132 if test -d "$testpath"; then 31133 31134 # Only process if variable expands to non-empty 31135 31136 if test "x$ipath" != x; then 31137 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31138 31139 # Input might be given as Windows format, start by converting to 31140 # unix format. 31141 path="$ipath" 31142 new_path=`$CYGPATH -u "$path"` 31143 31144 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 31145 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 31146 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 31147 # "foo.exe" is OK but "foo" is an error. 31148 # 31149 # This test is therefore slightly more accurate than "test -f" to check for file precense. 31150 # It is also a way to make sure we got the proper file name for the real test later on. 31151 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 31152 if test "x$test_shortpath" = x; then 31153 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of ipath, which resolves as \"$path\", is invalid." >&5 31154 $as_echo "$as_me: The path of ipath, which resolves as \"$path\", is invalid." >&6;} 31155 as_fn_error $? "Cannot locate the the path of ipath" "$LINENO" 5 31156 fi 31157 31158 # Call helper function which possibly converts this using DOS-style short mode. 31159 # If so, the updated path is stored in $new_path. 31160 31161 input_path="$new_path" 31162 # Check if we need to convert this using DOS-style short mode. If the path 31163 # contains just simple characters, use it. Otherwise (spaces, weird characters), 31164 # take no chances and rewrite it. 31165 # Note: m4 eats our [], so we need to use [ and ] instead. 31166 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 31167 if test "x$has_forbidden_chars" != x; then 31168 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 31169 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 31170 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 31171 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 31172 # Going to short mode and back again did indeed matter. Since short mode is 31173 # case insensitive, let's make it lowercase to improve readability. 31174 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 31175 # Now convert it back to Unix-style (cygpath) 31176 input_path=`$CYGPATH -u "$shortmode_path"` 31177 new_path="$input_path" 31178 fi 31179 fi 31180 31181 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 31182 if test "x$test_cygdrive_prefix" = x; then 31183 # As a simple fix, exclude /usr/bin since it's not a real path. 31184 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 31185 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 31186 # a path prefixed by /cygdrive for fixpath to work. 31187 new_path="$CYGWIN_ROOT_PATH$input_path" 31188 fi 31189 fi 31190 31191 31192 if test "x$path" != "x$new_path"; then 31193 ipath="$new_path" 31194 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting ipath to \"$new_path\"" >&5 31195 $as_echo "$as_me: Rewriting ipath to \"$new_path\"" >&6;} 31196 fi 31197 31198 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31199 31200 path="$ipath" 31201 has_colon=`$ECHO $path | $GREP ^.:` 31202 new_path="$path" 31203 if test "x$has_colon" = x; then 31204 # Not in mixed or Windows style, start by that. 31205 new_path=`cmd //c echo $path` 31206 fi 31207 31208 31209 input_path="$new_path" 31210 # Check if we need to convert this using DOS-style short mode. If the path 31211 # contains just simple characters, use it. Otherwise (spaces, weird characters), 31212 # take no chances and rewrite it. 31213 # Note: m4 eats our [], so we need to use [ and ] instead. 31214 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 31215 if test "x$has_forbidden_chars" != x; then 31216 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 31217 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 31218 fi 31219 31220 31221 windows_path="$new_path" 31222 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31223 unix_path=`$CYGPATH -u "$windows_path"` 31224 new_path="$unix_path" 31225 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31226 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31227 new_path="$unix_path" 31228 fi 31229 31230 if test "x$path" != "x$new_path"; then 31231 ipath="$new_path" 31232 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting ipath to \"$new_path\"" >&5 31233 $as_echo "$as_me: Rewriting ipath to \"$new_path\"" >&6;} 31234 fi 31235 31236 # Save the first 10 bytes of this path to the storage, so fixpath can work. 31237 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 31238 31239 else 31240 # We're on a unix platform. Hooray! :) 31241 path="$ipath" 31242 has_space=`$ECHO "$path" | $GREP " "` 31243 if test "x$has_space" != x; then 31244 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of ipath, which resolves as \"$path\", is invalid." >&5 31245 $as_echo "$as_me: The path of ipath, which resolves as \"$path\", is invalid." >&6;} 31246 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 31247 fi 31248 31249 # Use eval to expand a potential ~ 31250 eval path="$path" 31251 if test ! -f "$path" && test ! -d "$path"; then 31252 as_fn_error $? "The path of ipath, which resolves as \"$path\", is not found." "$LINENO" 5 31253 fi 31254 31255 if test -d "$path"; then 31256 ipath="`cd "$path"; $THEPWDCMD -L`" 31257 else 31258 dir="`$DIRNAME "$path"`" 31259 base="`$BASENAME "$path"`" 31260 ipath="`cd "$dir"; $THEPWDCMD -L`/$base" 31261 fi 31262 fi 31263 fi 31264 31265 SYSROOT_CFLAGS="$SYSROOT_CFLAGS -I$ipath" 31266 fi 31267 IFS=";" 31268 fi 31269 done 31270 # Convert VS_LIB into SYSROOT_LDFLAGS 31271 for i in $VS_LIB; do 31272 libpath=$i 31273 # Only process non-empty elements 31274 if test "x$libpath" != x; then 31275 IFS="$OLDIFS" 31276 # Check that directory exists before calling fixup_path 31277 testpath=$libpath 31278 31279 windows_path="$testpath" 31280 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31281 unix_path=`$CYGPATH -u "$windows_path"` 31282 testpath="$unix_path" 31283 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31284 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31285 testpath="$unix_path" 31286 fi 31287 31288 if test -d "$testpath"; then 31289 31290 # Only process if variable expands to non-empty 31291 31292 if test "x$libpath" != x; then 31293 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31294 31295 # Input might be given as Windows format, start by converting to 31296 # unix format. 31297 path="$libpath" 31298 new_path=`$CYGPATH -u "$path"` 31299 31300 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 31301 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 31302 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 31303 # "foo.exe" is OK but "foo" is an error. 31304 # 31305 # This test is therefore slightly more accurate than "test -f" to check for file precense. 31306 # It is also a way to make sure we got the proper file name for the real test later on. 31307 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 31308 if test "x$test_shortpath" = x; then 31309 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of libpath, which resolves as \"$path\", is invalid." >&5 31310 $as_echo "$as_me: The path of libpath, which resolves as \"$path\", is invalid." >&6;} 31311 as_fn_error $? "Cannot locate the the path of libpath" "$LINENO" 5 31312 fi 31313 31314 # Call helper function which possibly converts this using DOS-style short mode. 31315 # If so, the updated path is stored in $new_path. 31316 31317 input_path="$new_path" 31318 # Check if we need to convert this using DOS-style short mode. If the path 31319 # contains just simple characters, use it. Otherwise (spaces, weird characters), 31320 # take no chances and rewrite it. 31321 # Note: m4 eats our [], so we need to use [ and ] instead. 31322 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 31323 if test "x$has_forbidden_chars" != x; then 31324 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 31325 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 31326 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 31327 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 31328 # Going to short mode and back again did indeed matter. Since short mode is 31329 # case insensitive, let's make it lowercase to improve readability. 31330 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 31331 # Now convert it back to Unix-style (cygpath) 31332 input_path=`$CYGPATH -u "$shortmode_path"` 31333 new_path="$input_path" 31334 fi 31335 fi 31336 31337 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 31338 if test "x$test_cygdrive_prefix" = x; then 31339 # As a simple fix, exclude /usr/bin since it's not a real path. 31340 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 31341 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 31342 # a path prefixed by /cygdrive for fixpath to work. 31343 new_path="$CYGWIN_ROOT_PATH$input_path" 31344 fi 31345 fi 31346 31347 31348 if test "x$path" != "x$new_path"; then 31349 libpath="$new_path" 31350 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting libpath to \"$new_path\"" >&5 31351 $as_echo "$as_me: Rewriting libpath to \"$new_path\"" >&6;} 31352 fi 31353 31354 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31355 31356 path="$libpath" 31357 has_colon=`$ECHO $path | $GREP ^.:` 31358 new_path="$path" 31359 if test "x$has_colon" = x; then 31360 # Not in mixed or Windows style, start by that. 31361 new_path=`cmd //c echo $path` 31362 fi 31363 31364 31365 input_path="$new_path" 31366 # Check if we need to convert this using DOS-style short mode. If the path 31367 # contains just simple characters, use it. Otherwise (spaces, weird characters), 31368 # take no chances and rewrite it. 31369 # Note: m4 eats our [], so we need to use [ and ] instead. 31370 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 31371 if test "x$has_forbidden_chars" != x; then 31372 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 31373 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 31374 fi 31375 31376 31377 windows_path="$new_path" 31378 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31379 unix_path=`$CYGPATH -u "$windows_path"` 31380 new_path="$unix_path" 31381 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31382 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31383 new_path="$unix_path" 31384 fi 31385 31386 if test "x$path" != "x$new_path"; then 31387 libpath="$new_path" 31388 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting libpath to \"$new_path\"" >&5 31389 $as_echo "$as_me: Rewriting libpath to \"$new_path\"" >&6;} 31390 fi 31391 31392 # Save the first 10 bytes of this path to the storage, so fixpath can work. 31393 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 31394 31395 else 31396 # We're on a unix platform. Hooray! :) 31397 path="$libpath" 31398 has_space=`$ECHO "$path" | $GREP " "` 31399 if test "x$has_space" != x; then 31400 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of libpath, which resolves as \"$path\", is invalid." >&5 31401 $as_echo "$as_me: The path of libpath, which resolves as \"$path\", is invalid." >&6;} 31402 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 31403 fi 31404 31405 # Use eval to expand a potential ~ 31406 eval path="$path" 31407 if test ! -f "$path" && test ! -d "$path"; then 31408 as_fn_error $? "The path of libpath, which resolves as \"$path\", is not found." "$LINENO" 5 31409 fi 31410 31411 if test -d "$path"; then 31412 libpath="`cd "$path"; $THEPWDCMD -L`" 31413 else 31414 dir="`$DIRNAME "$path"`" 31415 base="`$BASENAME "$path"`" 31416 libpath="`cd "$dir"; $THEPWDCMD -L`/$base" 31417 fi 31418 fi 31419 fi 31420 31421 SYSROOT_LDFLAGS="$SYSROOT_LDFLAGS -libpath:$libpath" 31422 fi 31423 IFS=";" 31424 fi 31425 done 31426 IFS="$OLDIFS" 31427 fi 31428 else 31429 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 31430 $as_echo "not found" >&6; } 31431 31432 if test "x$VS_ENV_CMD" = x; then 31433 { $as_echo "$as_me:${as_lineno-$LINENO}: Cannot locate a valid Visual Studio or Windows SDK installation on disk," >&5 31434 $as_echo "$as_me: Cannot locate a valid Visual Studio or Windows SDK installation on disk," >&6;} 31435 { $as_echo "$as_me:${as_lineno-$LINENO}: nor is this script run from a Visual Studio command prompt." >&5 31436 $as_echo "$as_me: nor is this script run from a Visual Studio command prompt." >&6;} 31437 else 31438 { $as_echo "$as_me:${as_lineno-$LINENO}: Running the extraction script failed." >&5 31439 $as_echo "$as_me: Running the extraction script failed." >&6;} 31440 fi 31441 { $as_echo "$as_me:${as_lineno-$LINENO}: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&5 31442 $as_echo "$as_me: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&6;} 31443 { $as_echo "$as_me:${as_lineno-$LINENO}: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&5 31444 $as_echo "$as_me: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&6;} 31445 as_fn_error $? "Cannot continue" "$LINENO" 5 31446 fi 31447 31448 # Reset path to VS_PATH. It will include everything that was on PATH at the time we 31449 # ran TOOLCHAIN_SETUP_VISUAL_STUDIO_ENV. 31450 PATH="$VS_PATH" 31451 # The microsoft toolchain also requires INCLUDE and LIB to be set. 31452 export INCLUDE="$VS_INCLUDE" 31453 export LIB="$VS_LIB" 31454 else 31455 # Currently we do not define this for other toolchains. This might change as the need arise. 31456 TOOLCHAIN_VERSION= 31457 fi 31458 31459 31460 # For solaris we really need solaris tools, and not the GNU equivalent. 31461 # The build tools on Solaris reside in /usr/ccs (C Compilation System), 31462 # so add that to path before starting to probe. 31463 # FIXME: This was originally only done for AS,NM,GNM,STRIP,OBJCOPY,OBJDUMP. 31464 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 31465 PATH="/usr/ccs/bin:$PATH" 31466 fi 31467 31468 # Finally add TOOLCHAIN_PATH at the beginning, to allow --with-tools-dir to 31469 # override all other locations. 31470 if test "x$TOOLCHAIN_PATH" != x; then 31471 PATH=$TOOLCHAIN_PATH:$PATH 31472 fi 31473 31474 31475 # 31476 # Setup the compilers (CC and CXX) 31477 # 31478 31479 COMPILER_NAME=C 31480 SEARCH_LIST="$TOOLCHAIN_CC_BINARY" 31481 31482 if test "x$CC" != x; then 31483 # User has supplied compiler name already, always let that override. 31484 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied compiler CC=$CC" >&5 31485 $as_echo "$as_me: Will use user supplied compiler CC=$CC" >&6;} 31486 if test "x`basename $CC`" = "x$CC"; then 31487 # A command without a complete path is provided, search $PATH. 31488 31489 for ac_prog in $CC 31490 do 31491 # Extract the first word of "$ac_prog", so it can be a program name with args. 31492 set dummy $ac_prog; ac_word=$2 31493 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 31494 $as_echo_n "checking for $ac_word... " >&6; } 31495 if ${ac_cv_path_POTENTIAL_CC+:} false; then : 31496 $as_echo_n "(cached) " >&6 31497 else 31498 case $POTENTIAL_CC in 31499 [\\/]* | ?:[\\/]*) 31500 ac_cv_path_POTENTIAL_CC="$POTENTIAL_CC" # Let the user override the test with a path. 31501 ;; 31502 *) 31503 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 31504 for as_dir in $PATH 31505 do 31506 IFS=$as_save_IFS 31507 test -z "$as_dir" && as_dir=. 31508 for ac_exec_ext in '' $ac_executable_extensions; do 31509 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 31510 ac_cv_path_POTENTIAL_CC="$as_dir/$ac_word$ac_exec_ext" 31511 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 31512 break 2 31513 fi 31514 done 31515 done 31516 IFS=$as_save_IFS 31517 31518 ;; 31519 esac 31520 fi 31521 POTENTIAL_CC=$ac_cv_path_POTENTIAL_CC 31522 if test -n "$POTENTIAL_CC"; then 31523 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CC" >&5 31524 $as_echo "$POTENTIAL_CC" >&6; } 31525 else 31526 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 31527 $as_echo "no" >&6; } 31528 fi 31529 31530 31531 test -n "$POTENTIAL_CC" && break 31532 done 31533 31534 if test "x$POTENTIAL_CC" != x; then 31535 CC=$POTENTIAL_CC 31536 else 31537 as_fn_error $? "User supplied compiler CC=$CC could not be found" "$LINENO" 5 31538 fi 31539 else 31540 # Otherwise it might already be a complete path 31541 if test ! -x "$CC"; then 31542 as_fn_error $? "User supplied compiler CC=$CC does not exist" "$LINENO" 5 31543 fi 31544 fi 31545 else 31546 # No user supplied value. Locate compiler ourselves. 31547 31548 # If we are cross compiling, assume cross compilation tools follows the 31549 # cross compilation standard where they are prefixed with the autoconf 31550 # standard name for the target. For example the binary 31551 # i686-sun-solaris2.10-gcc will cross compile for i686-sun-solaris2.10. 31552 # If we are not cross compiling, then the default compiler name will be 31553 # used. 31554 31555 CC= 31556 # If TOOLCHAIN_PATH is set, check for all compiler names in there first 31557 # before checking the rest of the PATH. 31558 # FIXME: Now that we prefix the TOOLS_DIR to the PATH in the PRE_DETECTION 31559 # step, this should not be necessary. 31560 if test -n "$TOOLCHAIN_PATH"; then 31561 PATH_save="$PATH" 31562 PATH="$TOOLCHAIN_PATH" 31563 for ac_prog in $SEARCH_LIST 31564 do 31565 # Extract the first word of "$ac_prog", so it can be a program name with args. 31566 set dummy $ac_prog; ac_word=$2 31567 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 31568 $as_echo_n "checking for $ac_word... " >&6; } 31569 if ${ac_cv_path_TOOLCHAIN_PATH_CC+:} false; then : 31570 $as_echo_n "(cached) " >&6 31571 else 31572 case $TOOLCHAIN_PATH_CC in 31573 [\\/]* | ?:[\\/]*) 31574 ac_cv_path_TOOLCHAIN_PATH_CC="$TOOLCHAIN_PATH_CC" # Let the user override the test with a path. 31575 ;; 31576 *) 31577 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 31578 for as_dir in $PATH 31579 do 31580 IFS=$as_save_IFS 31581 test -z "$as_dir" && as_dir=. 31582 for ac_exec_ext in '' $ac_executable_extensions; do 31583 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 31584 ac_cv_path_TOOLCHAIN_PATH_CC="$as_dir/$ac_word$ac_exec_ext" 31585 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 31586 break 2 31587 fi 31588 done 31589 done 31590 IFS=$as_save_IFS 31591 31592 ;; 31593 esac 31594 fi 31595 TOOLCHAIN_PATH_CC=$ac_cv_path_TOOLCHAIN_PATH_CC 31596 if test -n "$TOOLCHAIN_PATH_CC"; then 31597 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLCHAIN_PATH_CC" >&5 31598 $as_echo "$TOOLCHAIN_PATH_CC" >&6; } 31599 else 31600 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 31601 $as_echo "no" >&6; } 31602 fi 31603 31604 31605 test -n "$TOOLCHAIN_PATH_CC" && break 31606 done 31607 31608 CC=$TOOLCHAIN_PATH_CC 31609 PATH="$PATH_save" 31610 fi 31611 31612 # AC_PATH_PROGS can't be run multiple times with the same variable, 31613 # so create a new name for this run. 31614 if test "x$CC" = x; then 31615 for ac_prog in $SEARCH_LIST 31616 do 31617 # Extract the first word of "$ac_prog", so it can be a program name with args. 31618 set dummy $ac_prog; ac_word=$2 31619 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 31620 $as_echo_n "checking for $ac_word... " >&6; } 31621 if ${ac_cv_path_POTENTIAL_CC+:} false; then : 31622 $as_echo_n "(cached) " >&6 31623 else 31624 case $POTENTIAL_CC in 31625 [\\/]* | ?:[\\/]*) 31626 ac_cv_path_POTENTIAL_CC="$POTENTIAL_CC" # Let the user override the test with a path. 31627 ;; 31628 *) 31629 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 31630 for as_dir in $PATH 31631 do 31632 IFS=$as_save_IFS 31633 test -z "$as_dir" && as_dir=. 31634 for ac_exec_ext in '' $ac_executable_extensions; do 31635 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 31636 ac_cv_path_POTENTIAL_CC="$as_dir/$ac_word$ac_exec_ext" 31637 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 31638 break 2 31639 fi 31640 done 31641 done 31642 IFS=$as_save_IFS 31643 31644 ;; 31645 esac 31646 fi 31647 POTENTIAL_CC=$ac_cv_path_POTENTIAL_CC 31648 if test -n "$POTENTIAL_CC"; then 31649 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CC" >&5 31650 $as_echo "$POTENTIAL_CC" >&6; } 31651 else 31652 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 31653 $as_echo "no" >&6; } 31654 fi 31655 31656 31657 test -n "$POTENTIAL_CC" && break 31658 done 31659 31660 CC=$POTENTIAL_CC 31661 fi 31662 31663 if test "x$CC" = x; then 31664 31665 # Print a helpful message on how to acquire the necessary build dependency. 31666 # devkit is the help tag: freetype, cups, alsa etc 31667 MISSING_DEPENDENCY=devkit 31668 31669 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31670 cygwin_help $MISSING_DEPENDENCY 31671 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31672 msys_help $MISSING_DEPENDENCY 31673 else 31674 PKGHANDLER_COMMAND= 31675 31676 case $PKGHANDLER in 31677 apt-get) 31678 apt_help $MISSING_DEPENDENCY ;; 31679 yum) 31680 yum_help $MISSING_DEPENDENCY ;; 31681 port) 31682 port_help $MISSING_DEPENDENCY ;; 31683 pkgutil) 31684 pkgutil_help $MISSING_DEPENDENCY ;; 31685 pkgadd) 31686 pkgadd_help $MISSING_DEPENDENCY ;; 31687 esac 31688 31689 if test "x$PKGHANDLER_COMMAND" != x; then 31690 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 31691 fi 31692 fi 31693 31694 as_fn_error $? "Could not find a $COMPILER_NAME compiler. $HELP_MSG" "$LINENO" 5 31695 fi 31696 fi 31697 31698 # Now we have a compiler binary in CC. Make sure it's okay. 31699 31700 # Only process if variable expands to non-empty 31701 31702 if test "x$CC" != x; then 31703 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31704 31705 # First separate the path from the arguments. This will split at the first 31706 # space. 31707 complete="$CC" 31708 path="${complete%% *}" 31709 tmp="$complete EOL" 31710 arguments="${tmp#* }" 31711 31712 # Input might be given as Windows format, start by converting to 31713 # unix format. 31714 new_path=`$CYGPATH -u "$path"` 31715 31716 # Now try to locate executable using which 31717 new_path=`$WHICH "$new_path" 2> /dev/null` 31718 # bat and cmd files are not always considered executable in cygwin causing which 31719 # to not find them 31720 if test "x$new_path" = x \ 31721 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 31722 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 31723 new_path=`$CYGPATH -u "$path"` 31724 fi 31725 if test "x$new_path" = x; then 31726 # Oops. Which didn't find the executable. 31727 # The splitting of arguments from the executable at a space might have been incorrect, 31728 # since paths with space are more likely in Windows. Give it another try with the whole 31729 # argument. 31730 path="$complete" 31731 arguments="EOL" 31732 new_path=`$CYGPATH -u "$path"` 31733 new_path=`$WHICH "$new_path" 2> /dev/null` 31734 # bat and cmd files are not always considered executable in cygwin causing which 31735 # to not find them 31736 if test "x$new_path" = x \ 31737 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 31738 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 31739 new_path=`$CYGPATH -u "$path"` 31740 fi 31741 if test "x$new_path" = x; then 31742 # It's still not found. Now this is an unrecoverable error. 31743 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5 31744 $as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;} 31745 has_space=`$ECHO "$complete" | $GREP " "` 31746 if test "x$has_space" != x; then 31747 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 31748 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 31749 fi 31750 as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5 31751 fi 31752 fi 31753 31754 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 31755 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 31756 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 31757 # "foo.exe" is OK but "foo" is an error. 31758 # 31759 # This test is therefore slightly more accurate than "test -f" to check for file presence. 31760 # It is also a way to make sure we got the proper file name for the real test later on. 31761 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 31762 if test "x$test_shortpath" = x; then 31763 # Short path failed, file does not exist as specified. 31764 # Try adding .exe or .cmd 31765 if test -f "${new_path}.exe"; then 31766 input_to_shortpath="${new_path}.exe" 31767 elif test -f "${new_path}.cmd"; then 31768 input_to_shortpath="${new_path}.cmd" 31769 else 31770 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$new_path\", is invalid." >&5 31771 $as_echo "$as_me: The path of CC, which resolves as \"$new_path\", is invalid." >&6;} 31772 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 31773 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 31774 as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5 31775 fi 31776 else 31777 input_to_shortpath="$new_path" 31778 fi 31779 31780 # Call helper function which possibly converts this using DOS-style short mode. 31781 # If so, the updated path is stored in $new_path. 31782 new_path="$input_to_shortpath" 31783 31784 input_path="$input_to_shortpath" 31785 # Check if we need to convert this using DOS-style short mode. If the path 31786 # contains just simple characters, use it. Otherwise (spaces, weird characters), 31787 # take no chances and rewrite it. 31788 # Note: m4 eats our [], so we need to use [ and ] instead. 31789 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 31790 if test "x$has_forbidden_chars" != x; then 31791 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 31792 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 31793 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 31794 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 31795 # Going to short mode and back again did indeed matter. Since short mode is 31796 # case insensitive, let's make it lowercase to improve readability. 31797 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 31798 # Now convert it back to Unix-style (cygpath) 31799 input_path=`$CYGPATH -u "$shortmode_path"` 31800 new_path="$input_path" 31801 fi 31802 fi 31803 31804 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 31805 if test "x$test_cygdrive_prefix" = x; then 31806 # As a simple fix, exclude /usr/bin since it's not a real path. 31807 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 31808 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 31809 # a path prefixed by /cygdrive for fixpath to work. 31810 new_path="$CYGWIN_ROOT_PATH$input_path" 31811 fi 31812 fi 31813 31814 # remove trailing .exe if any 31815 new_path="${new_path/%.exe/}" 31816 31817 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31818 31819 # First separate the path from the arguments. This will split at the first 31820 # space. 31821 complete="$CC" 31822 path="${complete%% *}" 31823 tmp="$complete EOL" 31824 arguments="${tmp#* }" 31825 31826 # Input might be given as Windows format, start by converting to 31827 # unix format. 31828 new_path="$path" 31829 31830 windows_path="$new_path" 31831 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31832 unix_path=`$CYGPATH -u "$windows_path"` 31833 new_path="$unix_path" 31834 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31835 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31836 new_path="$unix_path" 31837 fi 31838 31839 31840 # Now try to locate executable using which 31841 new_path=`$WHICH "$new_path" 2> /dev/null` 31842 31843 if test "x$new_path" = x; then 31844 # Oops. Which didn't find the executable. 31845 # The splitting of arguments from the executable at a space might have been incorrect, 31846 # since paths with space are more likely in Windows. Give it another try with the whole 31847 # argument. 31848 path="$complete" 31849 arguments="EOL" 31850 new_path="$path" 31851 31852 windows_path="$new_path" 31853 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31854 unix_path=`$CYGPATH -u "$windows_path"` 31855 new_path="$unix_path" 31856 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31857 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31858 new_path="$unix_path" 31859 fi 31860 31861 31862 new_path=`$WHICH "$new_path" 2> /dev/null` 31863 # bat and cmd files are not always considered executable in MSYS causing which 31864 # to not find them 31865 if test "x$new_path" = x \ 31866 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 31867 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 31868 new_path="$path" 31869 31870 windows_path="$new_path" 31871 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31872 unix_path=`$CYGPATH -u "$windows_path"` 31873 new_path="$unix_path" 31874 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31875 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31876 new_path="$unix_path" 31877 fi 31878 31879 fi 31880 31881 if test "x$new_path" = x; then 31882 # It's still not found. Now this is an unrecoverable error. 31883 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5 31884 $as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;} 31885 has_space=`$ECHO "$complete" | $GREP " "` 31886 if test "x$has_space" != x; then 31887 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 31888 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 31889 fi 31890 as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5 31891 fi 31892 fi 31893 31894 # Now new_path has a complete unix path to the binary 31895 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 31896 # Keep paths in /bin as-is, but remove trailing .exe if any 31897 new_path="${new_path/%.exe/}" 31898 # Do not save /bin paths to all_fixpath_prefixes! 31899 else 31900 # Not in mixed or Windows style, start by that. 31901 new_path=`cmd //c echo $new_path` 31902 31903 input_path="$new_path" 31904 # Check if we need to convert this using DOS-style short mode. If the path 31905 # contains just simple characters, use it. Otherwise (spaces, weird characters), 31906 # take no chances and rewrite it. 31907 # Note: m4 eats our [], so we need to use [ and ] instead. 31908 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 31909 if test "x$has_forbidden_chars" != x; then 31910 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 31911 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 31912 fi 31913 31914 # Output is in $new_path 31915 31916 windows_path="$new_path" 31917 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 31918 unix_path=`$CYGPATH -u "$windows_path"` 31919 new_path="$unix_path" 31920 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 31921 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 31922 new_path="$unix_path" 31923 fi 31924 31925 # remove trailing .exe if any 31926 new_path="${new_path/%.exe/}" 31927 31928 # Save the first 10 bytes of this path to the storage, so fixpath can work. 31929 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 31930 fi 31931 31932 else 31933 # We're on a unix platform. Hooray! :) 31934 # First separate the path from the arguments. This will split at the first 31935 # space. 31936 complete="$CC" 31937 path="${complete%% *}" 31938 tmp="$complete EOL" 31939 arguments="${tmp#* }" 31940 31941 # Cannot rely on the command "which" here since it doesn't always work. 31942 is_absolute_path=`$ECHO "$path" | $GREP ^/` 31943 if test -z "$is_absolute_path"; then 31944 # Path to executable is not absolute. Find it. 31945 IFS_save="$IFS" 31946 IFS=: 31947 for p in $PATH; do 31948 if test -f "$p/$path" && test -x "$p/$path"; then 31949 new_path="$p/$path" 31950 break 31951 fi 31952 done 31953 IFS="$IFS_save" 31954 else 31955 # This is an absolute path, we can use it without further modifications. 31956 new_path="$path" 31957 fi 31958 31959 if test "x$new_path" = x; then 31960 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CC, which resolves as \"$complete\", is not found." >&5 31961 $as_echo "$as_me: The path of CC, which resolves as \"$complete\", is not found." >&6;} 31962 has_space=`$ECHO "$complete" | $GREP " "` 31963 if test "x$has_space" != x; then 31964 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 31965 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 31966 fi 31967 as_fn_error $? "Cannot locate the the path of CC" "$LINENO" 5 31968 fi 31969 fi 31970 31971 # Now join together the path and the arguments once again 31972 if test "x$arguments" != xEOL; then 31973 new_complete="$new_path ${arguments% *}" 31974 else 31975 new_complete="$new_path" 31976 fi 31977 31978 if test "x$complete" != "x$new_complete"; then 31979 CC="$new_complete" 31980 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CC to \"$new_complete\"" >&5 31981 $as_echo "$as_me: Rewriting CC to \"$new_complete\"" >&6;} 31982 fi 31983 fi 31984 31985 TEST_COMPILER="$CC" 31986 # Don't remove symbolic links on AIX because 'xlc_r' and 'xlC_r' may all be links 31987 # to 'xlc' but it is crucial that we invoke the compiler with the right name! 31988 if test "x$OPENJDK_BUILD_OS" != xaix; then 31989 # FIXME: This test should not be needed anymore; we don't do that for any platform. 31990 { $as_echo "$as_me:${as_lineno-$LINENO}: checking resolved symbolic links for CC" >&5 31991 $as_echo_n "checking resolved symbolic links for CC... " >&6; } 31992 31993 if test "x$OPENJDK_BUILD_OS" != xwindows; then 31994 # Follow a chain of symbolic links. Use readlink 31995 # where it exists, else fall back to horribly 31996 # complicated shell code. 31997 if test "x$READLINK_TESTED" != yes; then 31998 # On MacOSX there is a readlink tool with a different 31999 # purpose than the GNU readlink tool. Check the found readlink. 32000 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 32001 if test "x$ISGNU" = x; then 32002 # A readlink that we do not know how to use. 32003 # Are there other non-GNU readlinks out there? 32004 READLINK_TESTED=yes 32005 READLINK= 32006 fi 32007 fi 32008 32009 if test "x$READLINK" != x; then 32010 TEST_COMPILER=`$READLINK -f $TEST_COMPILER` 32011 else 32012 # Save the current directory for restoring afterwards 32013 STARTDIR=$PWD 32014 COUNTER=0 32015 sym_link_dir=`$DIRNAME $TEST_COMPILER` 32016 sym_link_file=`$BASENAME $TEST_COMPILER` 32017 cd $sym_link_dir 32018 # Use -P flag to resolve symlinks in directories. 32019 cd `$THEPWDCMD -P` 32020 sym_link_dir=`$THEPWDCMD -P` 32021 # Resolve file symlinks 32022 while test $COUNTER -lt 20; do 32023 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 32024 if test "x$ISLINK" == x; then 32025 # This is not a symbolic link! We are done! 32026 break 32027 fi 32028 # Again resolve directory symlinks since the target of the just found 32029 # link could be in a different directory 32030 cd `$DIRNAME $ISLINK` 32031 sym_link_dir=`$THEPWDCMD -P` 32032 sym_link_file=`$BASENAME $ISLINK` 32033 let COUNTER=COUNTER+1 32034 done 32035 cd $STARTDIR 32036 TEST_COMPILER=$sym_link_dir/$sym_link_file 32037 fi 32038 fi 32039 32040 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEST_COMPILER" >&5 32041 $as_echo "$TEST_COMPILER" >&6; } 32042 fi 32043 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if CC is disguised ccache" >&5 32044 $as_echo_n "checking if CC is disguised ccache... " >&6; } 32045 32046 COMPILER_BASENAME=`$BASENAME "$TEST_COMPILER"` 32047 if test "x$COMPILER_BASENAME" = "xccache"; then 32048 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, trying to find proper $COMPILER_NAME compiler" >&5 32049 $as_echo "yes, trying to find proper $COMPILER_NAME compiler" >&6; } 32050 # We /usr/lib/ccache in the path, so cc is a symlink to /usr/bin/ccache. 32051 # We want to control ccache invocation ourselves, so ignore this cc and try 32052 # searching again. 32053 32054 # Remove the path to the fake ccache cc from the PATH 32055 RETRY_COMPILER_SAVED_PATH="$PATH" 32056 COMPILER_DIRNAME=`$DIRNAME $CC` 32057 PATH="`$ECHO $PATH | $SED -e "s,$COMPILER_DIRNAME,,g" -e "s,::,:,g" -e "s,^:,,g"`" 32058 32059 # Try again looking for our compiler 32060 if test -n "$ac_tool_prefix"; then 32061 for ac_prog in $TOOLCHAIN_CC_BINARY 32062 do 32063 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 32064 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 32065 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 32066 $as_echo_n "checking for $ac_word... " >&6; } 32067 if ${ac_cv_prog_PROPER_COMPILER_CC+:} false; then : 32068 $as_echo_n "(cached) " >&6 32069 else 32070 if test -n "$PROPER_COMPILER_CC"; then 32071 ac_cv_prog_PROPER_COMPILER_CC="$PROPER_COMPILER_CC" # Let the user override the test. 32072 else 32073 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 32074 for as_dir in $PATH 32075 do 32076 IFS=$as_save_IFS 32077 test -z "$as_dir" && as_dir=. 32078 for ac_exec_ext in '' $ac_executable_extensions; do 32079 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 32080 ac_cv_prog_PROPER_COMPILER_CC="$ac_tool_prefix$ac_prog" 32081 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 32082 break 2 32083 fi 32084 done 32085 done 32086 IFS=$as_save_IFS 32087 32088 fi 32089 fi 32090 PROPER_COMPILER_CC=$ac_cv_prog_PROPER_COMPILER_CC 32091 if test -n "$PROPER_COMPILER_CC"; then 32092 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROPER_COMPILER_CC" >&5 32093 $as_echo "$PROPER_COMPILER_CC" >&6; } 32094 else 32095 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 32096 $as_echo "no" >&6; } 32097 fi 32098 32099 32100 test -n "$PROPER_COMPILER_CC" && break 32101 done 32102 fi 32103 if test -z "$PROPER_COMPILER_CC"; then 32104 ac_ct_PROPER_COMPILER_CC=$PROPER_COMPILER_CC 32105 for ac_prog in $TOOLCHAIN_CC_BINARY 32106 do 32107 # Extract the first word of "$ac_prog", so it can be a program name with args. 32108 set dummy $ac_prog; ac_word=$2 32109 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 32110 $as_echo_n "checking for $ac_word... " >&6; } 32111 if ${ac_cv_prog_ac_ct_PROPER_COMPILER_CC+:} false; then : 32112 $as_echo_n "(cached) " >&6 32113 else 32114 if test -n "$ac_ct_PROPER_COMPILER_CC"; then 32115 ac_cv_prog_ac_ct_PROPER_COMPILER_CC="$ac_ct_PROPER_COMPILER_CC" # Let the user override the test. 32116 else 32117 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 32118 for as_dir in $PATH 32119 do 32120 IFS=$as_save_IFS 32121 test -z "$as_dir" && as_dir=. 32122 for ac_exec_ext in '' $ac_executable_extensions; do 32123 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 32124 ac_cv_prog_ac_ct_PROPER_COMPILER_CC="$ac_prog" 32125 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 32126 break 2 32127 fi 32128 done 32129 done 32130 IFS=$as_save_IFS 32131 32132 fi 32133 fi 32134 ac_ct_PROPER_COMPILER_CC=$ac_cv_prog_ac_ct_PROPER_COMPILER_CC 32135 if test -n "$ac_ct_PROPER_COMPILER_CC"; then 32136 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_PROPER_COMPILER_CC" >&5 32137 $as_echo "$ac_ct_PROPER_COMPILER_CC" >&6; } 32138 else 32139 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 32140 $as_echo "no" >&6; } 32141 fi 32142 32143 32144 test -n "$ac_ct_PROPER_COMPILER_CC" && break 32145 done 32146 32147 if test "x$ac_ct_PROPER_COMPILER_CC" = x; then 32148 PROPER_COMPILER_CC="" 32149 else 32150 case $cross_compiling:$ac_tool_warned in 32151 yes:) 32152 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 32153 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 32154 ac_tool_warned=yes ;; 32155 esac 32156 PROPER_COMPILER_CC=$ac_ct_PROPER_COMPILER_CC 32157 fi 32158 fi 32159 32160 32161 # Only process if variable expands to non-empty 32162 32163 if test "x$PROPER_COMPILER_CC" != x; then 32164 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32165 32166 # First separate the path from the arguments. This will split at the first 32167 # space. 32168 complete="$PROPER_COMPILER_CC" 32169 path="${complete%% *}" 32170 tmp="$complete EOL" 32171 arguments="${tmp#* }" 32172 32173 # Input might be given as Windows format, start by converting to 32174 # unix format. 32175 new_path=`$CYGPATH -u "$path"` 32176 32177 # Now try to locate executable using which 32178 new_path=`$WHICH "$new_path" 2> /dev/null` 32179 # bat and cmd files are not always considered executable in cygwin causing which 32180 # to not find them 32181 if test "x$new_path" = x \ 32182 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 32183 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 32184 new_path=`$CYGPATH -u "$path"` 32185 fi 32186 if test "x$new_path" = x; then 32187 # Oops. Which didn't find the executable. 32188 # The splitting of arguments from the executable at a space might have been incorrect, 32189 # since paths with space are more likely in Windows. Give it another try with the whole 32190 # argument. 32191 path="$complete" 32192 arguments="EOL" 32193 new_path=`$CYGPATH -u "$path"` 32194 new_path=`$WHICH "$new_path" 2> /dev/null` 32195 # bat and cmd files are not always considered executable in cygwin causing which 32196 # to not find them 32197 if test "x$new_path" = x \ 32198 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 32199 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 32200 new_path=`$CYGPATH -u "$path"` 32201 fi 32202 if test "x$new_path" = x; then 32203 # It's still not found. Now this is an unrecoverable error. 32204 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&5 32205 $as_echo "$as_me: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&6;} 32206 has_space=`$ECHO "$complete" | $GREP " "` 32207 if test "x$has_space" != x; then 32208 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 32209 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 32210 fi 32211 as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CC" "$LINENO" 5 32212 fi 32213 fi 32214 32215 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 32216 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 32217 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 32218 # "foo.exe" is OK but "foo" is an error. 32219 # 32220 # This test is therefore slightly more accurate than "test -f" to check for file presence. 32221 # It is also a way to make sure we got the proper file name for the real test later on. 32222 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 32223 if test "x$test_shortpath" = x; then 32224 # Short path failed, file does not exist as specified. 32225 # Try adding .exe or .cmd 32226 if test -f "${new_path}.exe"; then 32227 input_to_shortpath="${new_path}.exe" 32228 elif test -f "${new_path}.cmd"; then 32229 input_to_shortpath="${new_path}.cmd" 32230 else 32231 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CC, which resolves as \"$new_path\", is invalid." >&5 32232 $as_echo "$as_me: The path of PROPER_COMPILER_CC, which resolves as \"$new_path\", is invalid." >&6;} 32233 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 32234 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 32235 as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CC" "$LINENO" 5 32236 fi 32237 else 32238 input_to_shortpath="$new_path" 32239 fi 32240 32241 # Call helper function which possibly converts this using DOS-style short mode. 32242 # If so, the updated path is stored in $new_path. 32243 new_path="$input_to_shortpath" 32244 32245 input_path="$input_to_shortpath" 32246 # Check if we need to convert this using DOS-style short mode. If the path 32247 # contains just simple characters, use it. Otherwise (spaces, weird characters), 32248 # take no chances and rewrite it. 32249 # Note: m4 eats our [], so we need to use [ and ] instead. 32250 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 32251 if test "x$has_forbidden_chars" != x; then 32252 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 32253 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 32254 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 32255 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 32256 # Going to short mode and back again did indeed matter. Since short mode is 32257 # case insensitive, let's make it lowercase to improve readability. 32258 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 32259 # Now convert it back to Unix-style (cygpath) 32260 input_path=`$CYGPATH -u "$shortmode_path"` 32261 new_path="$input_path" 32262 fi 32263 fi 32264 32265 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 32266 if test "x$test_cygdrive_prefix" = x; then 32267 # As a simple fix, exclude /usr/bin since it's not a real path. 32268 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 32269 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 32270 # a path prefixed by /cygdrive for fixpath to work. 32271 new_path="$CYGWIN_ROOT_PATH$input_path" 32272 fi 32273 fi 32274 32275 # remove trailing .exe if any 32276 new_path="${new_path/%.exe/}" 32277 32278 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32279 32280 # First separate the path from the arguments. This will split at the first 32281 # space. 32282 complete="$PROPER_COMPILER_CC" 32283 path="${complete%% *}" 32284 tmp="$complete EOL" 32285 arguments="${tmp#* }" 32286 32287 # Input might be given as Windows format, start by converting to 32288 # unix format. 32289 new_path="$path" 32290 32291 windows_path="$new_path" 32292 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32293 unix_path=`$CYGPATH -u "$windows_path"` 32294 new_path="$unix_path" 32295 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32296 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32297 new_path="$unix_path" 32298 fi 32299 32300 32301 # Now try to locate executable using which 32302 new_path=`$WHICH "$new_path" 2> /dev/null` 32303 32304 if test "x$new_path" = x; then 32305 # Oops. Which didn't find the executable. 32306 # The splitting of arguments from the executable at a space might have been incorrect, 32307 # since paths with space are more likely in Windows. Give it another try with the whole 32308 # argument. 32309 path="$complete" 32310 arguments="EOL" 32311 new_path="$path" 32312 32313 windows_path="$new_path" 32314 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32315 unix_path=`$CYGPATH -u "$windows_path"` 32316 new_path="$unix_path" 32317 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32318 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32319 new_path="$unix_path" 32320 fi 32321 32322 32323 new_path=`$WHICH "$new_path" 2> /dev/null` 32324 # bat and cmd files are not always considered executable in MSYS causing which 32325 # to not find them 32326 if test "x$new_path" = x \ 32327 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 32328 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 32329 new_path="$path" 32330 32331 windows_path="$new_path" 32332 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32333 unix_path=`$CYGPATH -u "$windows_path"` 32334 new_path="$unix_path" 32335 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32336 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32337 new_path="$unix_path" 32338 fi 32339 32340 fi 32341 32342 if test "x$new_path" = x; then 32343 # It's still not found. Now this is an unrecoverable error. 32344 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&5 32345 $as_echo "$as_me: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&6;} 32346 has_space=`$ECHO "$complete" | $GREP " "` 32347 if test "x$has_space" != x; then 32348 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 32349 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 32350 fi 32351 as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CC" "$LINENO" 5 32352 fi 32353 fi 32354 32355 # Now new_path has a complete unix path to the binary 32356 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 32357 # Keep paths in /bin as-is, but remove trailing .exe if any 32358 new_path="${new_path/%.exe/}" 32359 # Do not save /bin paths to all_fixpath_prefixes! 32360 else 32361 # Not in mixed or Windows style, start by that. 32362 new_path=`cmd //c echo $new_path` 32363 32364 input_path="$new_path" 32365 # Check if we need to convert this using DOS-style short mode. If the path 32366 # contains just simple characters, use it. Otherwise (spaces, weird characters), 32367 # take no chances and rewrite it. 32368 # Note: m4 eats our [], so we need to use [ and ] instead. 32369 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 32370 if test "x$has_forbidden_chars" != x; then 32371 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 32372 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 32373 fi 32374 32375 # Output is in $new_path 32376 32377 windows_path="$new_path" 32378 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 32379 unix_path=`$CYGPATH -u "$windows_path"` 32380 new_path="$unix_path" 32381 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 32382 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 32383 new_path="$unix_path" 32384 fi 32385 32386 # remove trailing .exe if any 32387 new_path="${new_path/%.exe/}" 32388 32389 # Save the first 10 bytes of this path to the storage, so fixpath can work. 32390 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 32391 fi 32392 32393 else 32394 # We're on a unix platform. Hooray! :) 32395 # First separate the path from the arguments. This will split at the first 32396 # space. 32397 complete="$PROPER_COMPILER_CC" 32398 path="${complete%% *}" 32399 tmp="$complete EOL" 32400 arguments="${tmp#* }" 32401 32402 # Cannot rely on the command "which" here since it doesn't always work. 32403 is_absolute_path=`$ECHO "$path" | $GREP ^/` 32404 if test -z "$is_absolute_path"; then 32405 # Path to executable is not absolute. Find it. 32406 IFS_save="$IFS" 32407 IFS=: 32408 for p in $PATH; do 32409 if test -f "$p/$path" && test -x "$p/$path"; then 32410 new_path="$p/$path" 32411 break 32412 fi 32413 done 32414 IFS="$IFS_save" 32415 else 32416 # This is an absolute path, we can use it without further modifications. 32417 new_path="$path" 32418 fi 32419 32420 if test "x$new_path" = x; then 32421 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&5 32422 $as_echo "$as_me: The path of PROPER_COMPILER_CC, which resolves as \"$complete\", is not found." >&6;} 32423 has_space=`$ECHO "$complete" | $GREP " "` 32424 if test "x$has_space" != x; then 32425 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 32426 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 32427 fi 32428 as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CC" "$LINENO" 5 32429 fi 32430 fi 32431 32432 # Now join together the path and the arguments once again 32433 if test "x$arguments" != xEOL; then 32434 new_complete="$new_path ${arguments% *}" 32435 else 32436 new_complete="$new_path" 32437 fi 32438 32439 if test "x$complete" != "x$new_complete"; then 32440 PROPER_COMPILER_CC="$new_complete" 32441 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting PROPER_COMPILER_CC to \"$new_complete\"" >&5 32442 $as_echo "$as_me: Rewriting PROPER_COMPILER_CC to \"$new_complete\"" >&6;} 32443 fi 32444 fi 32445 32446 PATH="$RETRY_COMPILER_SAVED_PATH" 32447 32448 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for resolved symbolic links for CC" >&5 32449 $as_echo_n "checking for resolved symbolic links for CC... " >&6; } 32450 32451 if test "x$OPENJDK_BUILD_OS" != xwindows; then 32452 # Follow a chain of symbolic links. Use readlink 32453 # where it exists, else fall back to horribly 32454 # complicated shell code. 32455 if test "x$READLINK_TESTED" != yes; then 32456 # On MacOSX there is a readlink tool with a different 32457 # purpose than the GNU readlink tool. Check the found readlink. 32458 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 32459 if test "x$ISGNU" = x; then 32460 # A readlink that we do not know how to use. 32461 # Are there other non-GNU readlinks out there? 32462 READLINK_TESTED=yes 32463 READLINK= 32464 fi 32465 fi 32466 32467 if test "x$READLINK" != x; then 32468 PROPER_COMPILER_CC=`$READLINK -f $PROPER_COMPILER_CC` 32469 else 32470 # Save the current directory for restoring afterwards 32471 STARTDIR=$PWD 32472 COUNTER=0 32473 sym_link_dir=`$DIRNAME $PROPER_COMPILER_CC` 32474 sym_link_file=`$BASENAME $PROPER_COMPILER_CC` 32475 cd $sym_link_dir 32476 # Use -P flag to resolve symlinks in directories. 32477 cd `$THEPWDCMD -P` 32478 sym_link_dir=`$THEPWDCMD -P` 32479 # Resolve file symlinks 32480 while test $COUNTER -lt 20; do 32481 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 32482 if test "x$ISLINK" == x; then 32483 # This is not a symbolic link! We are done! 32484 break 32485 fi 32486 # Again resolve directory symlinks since the target of the just found 32487 # link could be in a different directory 32488 cd `$DIRNAME $ISLINK` 32489 sym_link_dir=`$THEPWDCMD -P` 32490 sym_link_file=`$BASENAME $ISLINK` 32491 let COUNTER=COUNTER+1 32492 done 32493 cd $STARTDIR 32494 PROPER_COMPILER_CC=$sym_link_dir/$sym_link_file 32495 fi 32496 fi 32497 32498 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROPER_COMPILER_CC" >&5 32499 $as_echo "$PROPER_COMPILER_CC" >&6; } 32500 CC="$PROPER_COMPILER_CC" 32501 else 32502 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, keeping CC" >&5 32503 $as_echo "no, keeping CC" >&6; } 32504 fi 32505 32506 32507 COMPILER=$CC 32508 COMPILER_NAME=$COMPILER_NAME 32509 32510 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 32511 # cc -V output typically looks like 32512 # cc: Sun C 5.12 Linux_i386 2011/11/16 32513 COMPILER_VERSION_OUTPUT=`$COMPILER -V 2>&1` 32514 # Check that this is likely to be the Solaris Studio cc. 32515 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "^.*: Sun $COMPILER_NAME" > /dev/null 32516 if test $? -ne 0; then 32517 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 32518 { $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 32519 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 32520 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&5 32521 $as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 32522 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 32523 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 32524 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 32525 fi 32526 # Remove usage instructions (if present), and 32527 # collapse compiler output into a single line 32528 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 32529 $SED -e 's/ *[Uu]sage:.*//'` 32530 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 32531 $SED -e "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/"` 32532 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 32533 # xlc -qversion output typically looks like 32534 # IBM XL C/C++ for AIX, V11.1 (5724-X13) 32535 # Version: 11.01.0000.0015 32536 COMPILER_VERSION_OUTPUT=`$COMPILER -qversion 2>&1` 32537 # Check that this is likely to be the IBM XL C compiler. 32538 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "IBM XL C" > /dev/null 32539 if test $? -ne 0; then 32540 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 32541 { $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 32542 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 32543 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&5 32544 $as_echo "$as_me: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 32545 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 32546 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 32547 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 32548 fi 32549 # Collapse compiler output into a single line 32550 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 32551 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 32552 $SED -e 's/^.*, V\([1-9][0-9.]*\).*$/\1/'` 32553 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 32554 # There is no specific version flag, but all output starts with a version string. 32555 # First line typically looks something like: 32556 # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86 32557 COMPILER_VERSION_OUTPUT=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'` 32558 # Check that this is likely to be Microsoft CL.EXE. 32559 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Microsoft.*Compiler" > /dev/null 32560 if test $? -ne 0; then 32561 { $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 32562 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 32563 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&5 32564 $as_echo "$as_me: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 32565 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 32566 fi 32567 # Collapse compiler output into a single line 32568 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 32569 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 32570 $SED -e 's/^.*ersion.\([1-9][0-9.]*\) .*$/\1/'` 32571 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 32572 # gcc --version output typically looks like 32573 # gcc (Ubuntu/Linaro 4.8.1-10ubuntu9) 4.8.1 32574 # Copyright (C) 2013 Free Software Foundation, Inc. 32575 # This is free software; see the source for copying conditions. There is NO 32576 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 32577 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 32578 # Check that this is likely to be GCC. 32579 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Free Software Foundation" > /dev/null 32580 if test $? -ne 0; then 32581 { $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 32582 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 32583 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION\"" >&5 32584 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION\"" >&6;} 32585 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 32586 fi 32587 # Remove Copyright and legalese from version string, and 32588 # collapse into a single line 32589 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 32590 $SED -e 's/ *Copyright .*//'` 32591 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 32592 $SED -e 's/^.* \([1-9]\.[0-9.]*\) .*$/\1/'` 32593 elif test "x$TOOLCHAIN_TYPE" = xclang; then 32594 # clang --version output typically looks like 32595 # Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn) 32596 # clang version 3.3 (tags/RELEASE_33/final) 32597 # or 32598 # Debian clang version 3.2-7ubuntu1 (tags/RELEASE_32/final) (based on LLVM 3.2) 32599 # Target: x86_64-pc-linux-gnu 32600 # Thread model: posix 32601 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 32602 # Check that this is likely to be clang 32603 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "clang" > /dev/null 32604 if test $? -ne 0; then 32605 { $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 32606 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 32607 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&5 32608 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 32609 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 32610 fi 32611 # Collapse compiler output into a single line 32612 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 32613 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 32614 $SED -e 's/^.*clang version \([1-9][0-9.]*\).*$/\1/'` 32615 else 32616 as_fn_error $? "Unknown toolchain type $TOOLCHAIN_TYPE." "$LINENO" 5 32617 fi 32618 # This sets CC_VERSION_NUMBER or CXX_VERSION_NUMBER. (This comment is a grep marker) 32619 CC_VERSION_NUMBER="$COMPILER_VERSION_NUMBER" 32620 # This sets CC_VERSION_STRING or CXX_VERSION_STRING. (This comment is a grep marker) 32621 CC_VERSION_STRING="$COMPILER_VERSION_STRING" 32622 32623 { $as_echo "$as_me:${as_lineno-$LINENO}: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&5 32624 $as_echo "$as_me: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&6;} 32625 32626 32627 # Now that we have resolved CC ourself, let autoconf have its go at it 32628 ac_ext=c 32629 ac_cpp='$CPP $CPPFLAGS' 32630 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 32631 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 32632 ac_compiler_gnu=$ac_cv_c_compiler_gnu 32633 if test -n "$ac_tool_prefix"; then 32634 for ac_prog in $CC 32635 do 32636 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 32637 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 32638 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 32639 $as_echo_n "checking for $ac_word... " >&6; } 32640 if ${ac_cv_prog_CC+:} false; then : 32641 $as_echo_n "(cached) " >&6 32642 else 32643 if test -n "$CC"; then 32644 ac_cv_prog_CC="$CC" # Let the user override the test. 32645 else 32646 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 32647 for as_dir in $PATH 32648 do 32649 IFS=$as_save_IFS 32650 test -z "$as_dir" && as_dir=. 32651 for ac_exec_ext in '' $ac_executable_extensions; do 32652 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 32653 ac_cv_prog_CC="$ac_tool_prefix$ac_prog" 32654 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 32655 break 2 32656 fi 32657 done 32658 done 32659 IFS=$as_save_IFS 32660 32661 fi 32662 fi 32663 CC=$ac_cv_prog_CC 32664 if test -n "$CC"; then 32665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CC" >&5 32666 $as_echo "$CC" >&6; } 32667 else 32668 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 32669 $as_echo "no" >&6; } 32670 fi 32671 32672 32673 test -n "$CC" && break 32674 done 32675 fi 32676 if test -z "$CC"; then 32677 ac_ct_CC=$CC 32678 for ac_prog in $CC 32679 do 32680 # Extract the first word of "$ac_prog", so it can be a program name with args. 32681 set dummy $ac_prog; ac_word=$2 32682 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 32683 $as_echo_n "checking for $ac_word... " >&6; } 32684 if ${ac_cv_prog_ac_ct_CC+:} false; then : 32685 $as_echo_n "(cached) " >&6 32686 else 32687 if test -n "$ac_ct_CC"; then 32688 ac_cv_prog_ac_ct_CC="$ac_ct_CC" # Let the user override the test. 32689 else 32690 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 32691 for as_dir in $PATH 32692 do 32693 IFS=$as_save_IFS 32694 test -z "$as_dir" && as_dir=. 32695 for ac_exec_ext in '' $ac_executable_extensions; do 32696 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 32697 ac_cv_prog_ac_ct_CC="$ac_prog" 32698 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 32699 break 2 32700 fi 32701 done 32702 done 32703 IFS=$as_save_IFS 32704 32705 fi 32706 fi 32707 ac_ct_CC=$ac_cv_prog_ac_ct_CC 32708 if test -n "$ac_ct_CC"; then 32709 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CC" >&5 32710 $as_echo "$ac_ct_CC" >&6; } 32711 else 32712 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 32713 $as_echo "no" >&6; } 32714 fi 32715 32716 32717 test -n "$ac_ct_CC" && break 32718 done 32719 32720 if test "x$ac_ct_CC" = x; then 32721 CC="" 32722 else 32723 case $cross_compiling:$ac_tool_warned in 32724 yes:) 32725 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 32726 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 32727 ac_tool_warned=yes ;; 32728 esac 32729 CC=$ac_ct_CC 32730 fi 32731 fi 32732 32733 32734 test -z "$CC" && { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 32735 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 32736 as_fn_error $? "no acceptable C compiler found in \$PATH 32737 See \`config.log' for more details" "$LINENO" 5; } 32738 32739 # Provide some information about the compiler. 32740 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler version" >&5 32741 set X $ac_compile 32742 ac_compiler=$2 32743 for ac_option in --version -v -V -qversion; do 32744 { { ac_try="$ac_compiler $ac_option >&5" 32745 case "(($ac_try" in 32746 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 32747 *) ac_try_echo=$ac_try;; 32748 esac 32749 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 32750 $as_echo "$ac_try_echo"; } >&5 32751 (eval "$ac_compiler $ac_option >&5") 2>conftest.err 32752 ac_status=$? 32753 if test -s conftest.err; then 32754 sed '10a\ 32755 ... rest of stderr output deleted ... 32756 10q' conftest.err >conftest.er1 32757 cat conftest.er1 >&5 32758 fi 32759 rm -f conftest.er1 conftest.err 32760 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 32761 test $ac_status = 0; } 32762 done 32763 32764 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 32765 /* end confdefs.h. */ 32766 32767 int 32768 main () 32769 { 32770 32771 ; 32772 return 0; 32773 } 32774 _ACEOF 32775 ac_clean_files_save=$ac_clean_files 32776 ac_clean_files="$ac_clean_files a.out a.out.dSYM a.exe b.out" 32777 # Try to create an executable without -o first, disregard a.out. 32778 # It will help us diagnose broken compilers, and finding out an intuition 32779 # of exeext. 32780 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether the C compiler works" >&5 32781 $as_echo_n "checking whether the C compiler works... " >&6; } 32782 ac_link_default=`$as_echo "$ac_link" | sed 's/ -o *conftest[^ ]*//'` 32783 32784 # The possible output files: 32785 ac_files="a.out conftest.exe conftest a.exe a_out.exe b.out conftest.*" 32786 32787 ac_rmfiles= 32788 for ac_file in $ac_files 32789 do 32790 case $ac_file in 32791 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; 32792 * ) ac_rmfiles="$ac_rmfiles $ac_file";; 32793 esac 32794 done 32795 rm -f $ac_rmfiles 32796 32797 if { { ac_try="$ac_link_default" 32798 case "(($ac_try" in 32799 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 32800 *) ac_try_echo=$ac_try;; 32801 esac 32802 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 32803 $as_echo "$ac_try_echo"; } >&5 32804 (eval "$ac_link_default") 2>&5 32805 ac_status=$? 32806 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 32807 test $ac_status = 0; }; then : 32808 # Autoconf-2.13 could set the ac_cv_exeext variable to `no'. 32809 # So ignore a value of `no', otherwise this would lead to `EXEEXT = no' 32810 # in a Makefile. We should not override ac_cv_exeext if it was cached, 32811 # so that the user can short-circuit this test for compilers unknown to 32812 # Autoconf. 32813 for ac_file in $ac_files '' 32814 do 32815 test -f "$ac_file" || continue 32816 case $ac_file in 32817 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) 32818 ;; 32819 [ab].out ) 32820 # We found the default executable, but exeext='' is most 32821 # certainly right. 32822 break;; 32823 *.* ) 32824 if test "${ac_cv_exeext+set}" = set && test "$ac_cv_exeext" != no; 32825 then :; else 32826 ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` 32827 fi 32828 # We set ac_cv_exeext here because the later test for it is not 32829 # safe: cross compilers may not add the suffix if given an `-o' 32830 # argument, so we may need to know it at that point already. 32831 # Even if this section looks crufty: it has the advantage of 32832 # actually working. 32833 break;; 32834 * ) 32835 break;; 32836 esac 32837 done 32838 test "$ac_cv_exeext" = no && ac_cv_exeext= 32839 32840 else 32841 ac_file='' 32842 fi 32843 if test -z "$ac_file"; then : 32844 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 32845 $as_echo "no" >&6; } 32846 $as_echo "$as_me: failed program was:" >&5 32847 sed 's/^/| /' conftest.$ac_ext >&5 32848 32849 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 32850 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 32851 as_fn_error 77 "C compiler cannot create executables 32852 See \`config.log' for more details" "$LINENO" 5; } 32853 else 32854 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 32855 $as_echo "yes" >&6; } 32856 fi 32857 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for C compiler default output file name" >&5 32858 $as_echo_n "checking for C compiler default output file name... " >&6; } 32859 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_file" >&5 32860 $as_echo "$ac_file" >&6; } 32861 ac_exeext=$ac_cv_exeext 32862 32863 rm -f -r a.out a.out.dSYM a.exe conftest$ac_cv_exeext b.out 32864 ac_clean_files=$ac_clean_files_save 32865 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of executables" >&5 32866 $as_echo_n "checking for suffix of executables... " >&6; } 32867 if { { ac_try="$ac_link" 32868 case "(($ac_try" in 32869 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 32870 *) ac_try_echo=$ac_try;; 32871 esac 32872 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 32873 $as_echo "$ac_try_echo"; } >&5 32874 (eval "$ac_link") 2>&5 32875 ac_status=$? 32876 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 32877 test $ac_status = 0; }; then : 32878 # If both `conftest.exe' and `conftest' are `present' (well, observable) 32879 # catch `conftest.exe'. For instance with Cygwin, `ls conftest' will 32880 # work properly (i.e., refer to `conftest.exe'), while it won't with 32881 # `rm'. 32882 for ac_file in conftest.exe conftest conftest.*; do 32883 test -f "$ac_file" || continue 32884 case $ac_file in 32885 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM | *.o | *.obj ) ;; 32886 *.* ) ac_cv_exeext=`expr "$ac_file" : '[^.]*\(\..*\)'` 32887 break;; 32888 * ) break;; 32889 esac 32890 done 32891 else 32892 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 32893 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 32894 as_fn_error $? "cannot compute suffix of executables: cannot compile and link 32895 See \`config.log' for more details" "$LINENO" 5; } 32896 fi 32897 rm -f conftest conftest$ac_cv_exeext 32898 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_exeext" >&5 32899 $as_echo "$ac_cv_exeext" >&6; } 32900 32901 rm -f conftest.$ac_ext 32902 EXEEXT=$ac_cv_exeext 32903 ac_exeext=$EXEEXT 32904 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 32905 /* end confdefs.h. */ 32906 #include <stdio.h> 32907 int 32908 main () 32909 { 32910 FILE *f = fopen ("conftest.out", "w"); 32911 return ferror (f) || fclose (f) != 0; 32912 32913 ; 32914 return 0; 32915 } 32916 _ACEOF 32917 ac_clean_files="$ac_clean_files conftest.out" 32918 # Check that the compiler produces executables we can run. If not, either 32919 # the compiler is broken, or we cross compile. 32920 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are cross compiling" >&5 32921 $as_echo_n "checking whether we are cross compiling... " >&6; } 32922 if test "$cross_compiling" != yes; then 32923 { { ac_try="$ac_link" 32924 case "(($ac_try" in 32925 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 32926 *) ac_try_echo=$ac_try;; 32927 esac 32928 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 32929 $as_echo "$ac_try_echo"; } >&5 32930 (eval "$ac_link") 2>&5 32931 ac_status=$? 32932 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 32933 test $ac_status = 0; } 32934 if { ac_try='./conftest$ac_cv_exeext' 32935 { { case "(($ac_try" in 32936 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 32937 *) ac_try_echo=$ac_try;; 32938 esac 32939 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 32940 $as_echo "$ac_try_echo"; } >&5 32941 (eval "$ac_try") 2>&5 32942 ac_status=$? 32943 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 32944 test $ac_status = 0; }; }; then 32945 cross_compiling=no 32946 else 32947 if test "$cross_compiling" = maybe; then 32948 cross_compiling=yes 32949 else 32950 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 32951 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 32952 as_fn_error $? "cannot run C compiled programs. 32953 If you meant to cross compile, use \`--host'. 32954 See \`config.log' for more details" "$LINENO" 5; } 32955 fi 32956 fi 32957 fi 32958 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $cross_compiling" >&5 32959 $as_echo "$cross_compiling" >&6; } 32960 32961 rm -f conftest.$ac_ext conftest$ac_cv_exeext conftest.out 32962 ac_clean_files=$ac_clean_files_save 32963 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for suffix of object files" >&5 32964 $as_echo_n "checking for suffix of object files... " >&6; } 32965 if ${ac_cv_objext+:} false; then : 32966 $as_echo_n "(cached) " >&6 32967 else 32968 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 32969 /* end confdefs.h. */ 32970 32971 int 32972 main () 32973 { 32974 32975 ; 32976 return 0; 32977 } 32978 _ACEOF 32979 rm -f conftest.o conftest.obj 32980 if { { ac_try="$ac_compile" 32981 case "(($ac_try" in 32982 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 32983 *) ac_try_echo=$ac_try;; 32984 esac 32985 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 32986 $as_echo "$ac_try_echo"; } >&5 32987 (eval "$ac_compile") 2>&5 32988 ac_status=$? 32989 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 32990 test $ac_status = 0; }; then : 32991 for ac_file in conftest.o conftest.obj conftest.*; do 32992 test -f "$ac_file" || continue; 32993 case $ac_file in 32994 *.$ac_ext | *.xcoff | *.tds | *.d | *.pdb | *.xSYM | *.bb | *.bbg | *.map | *.inf | *.dSYM ) ;; 32995 *) ac_cv_objext=`expr "$ac_file" : '.*\.\(.*\)'` 32996 break;; 32997 esac 32998 done 32999 else 33000 $as_echo "$as_me: failed program was:" >&5 33001 sed 's/^/| /' conftest.$ac_ext >&5 33002 33003 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 33004 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 33005 as_fn_error $? "cannot compute suffix of object files: cannot compile 33006 See \`config.log' for more details" "$LINENO" 5; } 33007 fi 33008 rm -f conftest.$ac_cv_objext conftest.$ac_ext 33009 fi 33010 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_objext" >&5 33011 $as_echo "$ac_cv_objext" >&6; } 33012 OBJEXT=$ac_cv_objext 33013 ac_objext=$OBJEXT 33014 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C compiler" >&5 33015 $as_echo_n "checking whether we are using the GNU C compiler... " >&6; } 33016 if ${ac_cv_c_compiler_gnu+:} false; then : 33017 $as_echo_n "(cached) " >&6 33018 else 33019 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 33020 /* end confdefs.h. */ 33021 33022 int 33023 main () 33024 { 33025 #ifndef __GNUC__ 33026 choke me 33027 #endif 33028 33029 ; 33030 return 0; 33031 } 33032 _ACEOF 33033 if ac_fn_c_try_compile "$LINENO"; then : 33034 ac_compiler_gnu=yes 33035 else 33036 ac_compiler_gnu=no 33037 fi 33038 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 33039 ac_cv_c_compiler_gnu=$ac_compiler_gnu 33040 33041 fi 33042 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_compiler_gnu" >&5 33043 $as_echo "$ac_cv_c_compiler_gnu" >&6; } 33044 if test $ac_compiler_gnu = yes; then 33045 GCC=yes 33046 else 33047 GCC= 33048 fi 33049 ac_test_CFLAGS=${CFLAGS+set} 33050 ac_save_CFLAGS=$CFLAGS 33051 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CC accepts -g" >&5 33052 $as_echo_n "checking whether $CC accepts -g... " >&6; } 33053 if ${ac_cv_prog_cc_g+:} false; then : 33054 $as_echo_n "(cached) " >&6 33055 else 33056 ac_save_c_werror_flag=$ac_c_werror_flag 33057 ac_c_werror_flag=yes 33058 ac_cv_prog_cc_g=no 33059 CFLAGS="-g" 33060 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 33061 /* end confdefs.h. */ 33062 33063 int 33064 main () 33065 { 33066 33067 ; 33068 return 0; 33069 } 33070 _ACEOF 33071 if ac_fn_c_try_compile "$LINENO"; then : 33072 ac_cv_prog_cc_g=yes 33073 else 33074 CFLAGS="" 33075 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 33076 /* end confdefs.h. */ 33077 33078 int 33079 main () 33080 { 33081 33082 ; 33083 return 0; 33084 } 33085 _ACEOF 33086 if ac_fn_c_try_compile "$LINENO"; then : 33087 33088 else 33089 ac_c_werror_flag=$ac_save_c_werror_flag 33090 CFLAGS="-g" 33091 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 33092 /* end confdefs.h. */ 33093 33094 int 33095 main () 33096 { 33097 33098 ; 33099 return 0; 33100 } 33101 _ACEOF 33102 if ac_fn_c_try_compile "$LINENO"; then : 33103 ac_cv_prog_cc_g=yes 33104 fi 33105 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 33106 fi 33107 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 33108 fi 33109 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 33110 ac_c_werror_flag=$ac_save_c_werror_flag 33111 fi 33112 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_g" >&5 33113 $as_echo "$ac_cv_prog_cc_g" >&6; } 33114 if test "$ac_test_CFLAGS" = set; then 33115 CFLAGS=$ac_save_CFLAGS 33116 elif test $ac_cv_prog_cc_g = yes; then 33117 if test "$GCC" = yes; then 33118 CFLAGS="-g -O2" 33119 else 33120 CFLAGS="-g" 33121 fi 33122 else 33123 if test "$GCC" = yes; then 33124 CFLAGS="-O2" 33125 else 33126 CFLAGS= 33127 fi 33128 fi 33129 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $CC option to accept ISO C89" >&5 33130 $as_echo_n "checking for $CC option to accept ISO C89... " >&6; } 33131 if ${ac_cv_prog_cc_c89+:} false; then : 33132 $as_echo_n "(cached) " >&6 33133 else 33134 ac_cv_prog_cc_c89=no 33135 ac_save_CC=$CC 33136 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 33137 /* end confdefs.h. */ 33138 #include <stdarg.h> 33139 #include <stdio.h> 33140 struct stat; 33141 /* Most of the following tests are stolen from RCS 5.7's src/conf.sh. */ 33142 struct buf { int x; }; 33143 FILE * (*rcsopen) (struct buf *, struct stat *, int); 33144 static char *e (p, i) 33145 char **p; 33146 int i; 33147 { 33148 return p[i]; 33149 } 33150 static char *f (char * (*g) (char **, int), char **p, ...) 33151 { 33152 char *s; 33153 va_list v; 33154 va_start (v,p); 33155 s = g (p, va_arg (v,int)); 33156 va_end (v); 33157 return s; 33158 } 33159 33160 /* OSF 4.0 Compaq cc is some sort of almost-ANSI by default. It has 33161 function prototypes and stuff, but not '\xHH' hex character constants. 33162 These don't provoke an error unfortunately, instead are silently treated 33163 as 'x'. The following induces an error, until -std is added to get 33164 proper ANSI mode. Curiously '\x00'!='x' always comes out true, for an 33165 array size at least. It's necessary to write '\x00'==0 to get something 33166 that's true only with -std. */ 33167 int osf4_cc_array ['\x00' == 0 ? 1 : -1]; 33168 33169 /* IBM C 6 for AIX is almost-ANSI by default, but it replaces macro parameters 33170 inside strings and character constants. */ 33171 #define FOO(x) 'x' 33172 int xlc6_cc_array[FOO(a) == 'x' ? 1 : -1]; 33173 33174 int test (int i, double x); 33175 struct s1 {int (*f) (int a);}; 33176 struct s2 {int (*f) (double a);}; 33177 int pairnames (int, char **, FILE *(*)(struct buf *, struct stat *, int), int, int); 33178 int argc; 33179 char **argv; 33180 int 33181 main () 33182 { 33183 return f (e, argv, 0) != argv[0] || f (e, argv, 1) != argv[1]; 33184 ; 33185 return 0; 33186 } 33187 _ACEOF 33188 for ac_arg in '' -qlanglvl=extc89 -qlanglvl=ansi -std \ 33189 -Ae "-Aa -D_HPUX_SOURCE" "-Xc -D__EXTENSIONS__" 33190 do 33191 CC="$ac_save_CC $ac_arg" 33192 if ac_fn_c_try_compile "$LINENO"; then : 33193 ac_cv_prog_cc_c89=$ac_arg 33194 fi 33195 rm -f core conftest.err conftest.$ac_objext 33196 test "x$ac_cv_prog_cc_c89" != "xno" && break 33197 done 33198 rm -f conftest.$ac_ext 33199 CC=$ac_save_CC 33200 33201 fi 33202 # AC_CACHE_VAL 33203 case "x$ac_cv_prog_cc_c89" in 33204 x) 33205 { $as_echo "$as_me:${as_lineno-$LINENO}: result: none needed" >&5 33206 $as_echo "none needed" >&6; } ;; 33207 xno) 33208 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unsupported" >&5 33209 $as_echo "unsupported" >&6; } ;; 33210 *) 33211 CC="$CC $ac_cv_prog_cc_c89" 33212 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cc_c89" >&5 33213 $as_echo "$ac_cv_prog_cc_c89" >&6; } ;; 33214 esac 33215 if test "x$ac_cv_prog_cc_c89" != xno; then : 33216 33217 fi 33218 33219 ac_ext=cpp 33220 ac_cpp='$CXXCPP $CPPFLAGS' 33221 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 33222 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 33223 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 33224 33225 33226 33227 COMPILER_NAME=C++ 33228 SEARCH_LIST="$TOOLCHAIN_CXX_BINARY" 33229 33230 if test "x$CXX" != x; then 33231 # User has supplied compiler name already, always let that override. 33232 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied compiler CXX=$CXX" >&5 33233 $as_echo "$as_me: Will use user supplied compiler CXX=$CXX" >&6;} 33234 if test "x`basename $CXX`" = "x$CXX"; then 33235 # A command without a complete path is provided, search $PATH. 33236 33237 for ac_prog in $CXX 33238 do 33239 # Extract the first word of "$ac_prog", so it can be a program name with args. 33240 set dummy $ac_prog; ac_word=$2 33241 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33242 $as_echo_n "checking for $ac_word... " >&6; } 33243 if ${ac_cv_path_POTENTIAL_CXX+:} false; then : 33244 $as_echo_n "(cached) " >&6 33245 else 33246 case $POTENTIAL_CXX in 33247 [\\/]* | ?:[\\/]*) 33248 ac_cv_path_POTENTIAL_CXX="$POTENTIAL_CXX" # Let the user override the test with a path. 33249 ;; 33250 *) 33251 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33252 for as_dir in $PATH 33253 do 33254 IFS=$as_save_IFS 33255 test -z "$as_dir" && as_dir=. 33256 for ac_exec_ext in '' $ac_executable_extensions; do 33257 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 33258 ac_cv_path_POTENTIAL_CXX="$as_dir/$ac_word$ac_exec_ext" 33259 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 33260 break 2 33261 fi 33262 done 33263 done 33264 IFS=$as_save_IFS 33265 33266 ;; 33267 esac 33268 fi 33269 POTENTIAL_CXX=$ac_cv_path_POTENTIAL_CXX 33270 if test -n "$POTENTIAL_CXX"; then 33271 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CXX" >&5 33272 $as_echo "$POTENTIAL_CXX" >&6; } 33273 else 33274 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33275 $as_echo "no" >&6; } 33276 fi 33277 33278 33279 test -n "$POTENTIAL_CXX" && break 33280 done 33281 33282 if test "x$POTENTIAL_CXX" != x; then 33283 CXX=$POTENTIAL_CXX 33284 else 33285 as_fn_error $? "User supplied compiler CXX=$CXX could not be found" "$LINENO" 5 33286 fi 33287 else 33288 # Otherwise it might already be a complete path 33289 if test ! -x "$CXX"; then 33290 as_fn_error $? "User supplied compiler CXX=$CXX does not exist" "$LINENO" 5 33291 fi 33292 fi 33293 else 33294 # No user supplied value. Locate compiler ourselves. 33295 33296 # If we are cross compiling, assume cross compilation tools follows the 33297 # cross compilation standard where they are prefixed with the autoconf 33298 # standard name for the target. For example the binary 33299 # i686-sun-solaris2.10-gcc will cross compile for i686-sun-solaris2.10. 33300 # If we are not cross compiling, then the default compiler name will be 33301 # used. 33302 33303 CXX= 33304 # If TOOLCHAIN_PATH is set, check for all compiler names in there first 33305 # before checking the rest of the PATH. 33306 # FIXME: Now that we prefix the TOOLS_DIR to the PATH in the PRE_DETECTION 33307 # step, this should not be necessary. 33308 if test -n "$TOOLCHAIN_PATH"; then 33309 PATH_save="$PATH" 33310 PATH="$TOOLCHAIN_PATH" 33311 for ac_prog in $SEARCH_LIST 33312 do 33313 # Extract the first word of "$ac_prog", so it can be a program name with args. 33314 set dummy $ac_prog; ac_word=$2 33315 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33316 $as_echo_n "checking for $ac_word... " >&6; } 33317 if ${ac_cv_path_TOOLCHAIN_PATH_CXX+:} false; then : 33318 $as_echo_n "(cached) " >&6 33319 else 33320 case $TOOLCHAIN_PATH_CXX in 33321 [\\/]* | ?:[\\/]*) 33322 ac_cv_path_TOOLCHAIN_PATH_CXX="$TOOLCHAIN_PATH_CXX" # Let the user override the test with a path. 33323 ;; 33324 *) 33325 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33326 for as_dir in $PATH 33327 do 33328 IFS=$as_save_IFS 33329 test -z "$as_dir" && as_dir=. 33330 for ac_exec_ext in '' $ac_executable_extensions; do 33331 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 33332 ac_cv_path_TOOLCHAIN_PATH_CXX="$as_dir/$ac_word$ac_exec_ext" 33333 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 33334 break 2 33335 fi 33336 done 33337 done 33338 IFS=$as_save_IFS 33339 33340 ;; 33341 esac 33342 fi 33343 TOOLCHAIN_PATH_CXX=$ac_cv_path_TOOLCHAIN_PATH_CXX 33344 if test -n "$TOOLCHAIN_PATH_CXX"; then 33345 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLCHAIN_PATH_CXX" >&5 33346 $as_echo "$TOOLCHAIN_PATH_CXX" >&6; } 33347 else 33348 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33349 $as_echo "no" >&6; } 33350 fi 33351 33352 33353 test -n "$TOOLCHAIN_PATH_CXX" && break 33354 done 33355 33356 CXX=$TOOLCHAIN_PATH_CXX 33357 PATH="$PATH_save" 33358 fi 33359 33360 # AC_PATH_PROGS can't be run multiple times with the same variable, 33361 # so create a new name for this run. 33362 if test "x$CXX" = x; then 33363 for ac_prog in $SEARCH_LIST 33364 do 33365 # Extract the first word of "$ac_prog", so it can be a program name with args. 33366 set dummy $ac_prog; ac_word=$2 33367 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33368 $as_echo_n "checking for $ac_word... " >&6; } 33369 if ${ac_cv_path_POTENTIAL_CXX+:} false; then : 33370 $as_echo_n "(cached) " >&6 33371 else 33372 case $POTENTIAL_CXX in 33373 [\\/]* | ?:[\\/]*) 33374 ac_cv_path_POTENTIAL_CXX="$POTENTIAL_CXX" # Let the user override the test with a path. 33375 ;; 33376 *) 33377 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33378 for as_dir in $PATH 33379 do 33380 IFS=$as_save_IFS 33381 test -z "$as_dir" && as_dir=. 33382 for ac_exec_ext in '' $ac_executable_extensions; do 33383 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 33384 ac_cv_path_POTENTIAL_CXX="$as_dir/$ac_word$ac_exec_ext" 33385 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 33386 break 2 33387 fi 33388 done 33389 done 33390 IFS=$as_save_IFS 33391 33392 ;; 33393 esac 33394 fi 33395 POTENTIAL_CXX=$ac_cv_path_POTENTIAL_CXX 33396 if test -n "$POTENTIAL_CXX"; then 33397 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $POTENTIAL_CXX" >&5 33398 $as_echo "$POTENTIAL_CXX" >&6; } 33399 else 33400 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33401 $as_echo "no" >&6; } 33402 fi 33403 33404 33405 test -n "$POTENTIAL_CXX" && break 33406 done 33407 33408 CXX=$POTENTIAL_CXX 33409 fi 33410 33411 if test "x$CXX" = x; then 33412 33413 # Print a helpful message on how to acquire the necessary build dependency. 33414 # devkit is the help tag: freetype, cups, alsa etc 33415 MISSING_DEPENDENCY=devkit 33416 33417 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33418 cygwin_help $MISSING_DEPENDENCY 33419 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33420 msys_help $MISSING_DEPENDENCY 33421 else 33422 PKGHANDLER_COMMAND= 33423 33424 case $PKGHANDLER in 33425 apt-get) 33426 apt_help $MISSING_DEPENDENCY ;; 33427 yum) 33428 yum_help $MISSING_DEPENDENCY ;; 33429 port) 33430 port_help $MISSING_DEPENDENCY ;; 33431 pkgutil) 33432 pkgutil_help $MISSING_DEPENDENCY ;; 33433 pkgadd) 33434 pkgadd_help $MISSING_DEPENDENCY ;; 33435 esac 33436 33437 if test "x$PKGHANDLER_COMMAND" != x; then 33438 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 33439 fi 33440 fi 33441 33442 as_fn_error $? "Could not find a $COMPILER_NAME compiler. $HELP_MSG" "$LINENO" 5 33443 fi 33444 fi 33445 33446 # Now we have a compiler binary in CXX. Make sure it's okay. 33447 33448 # Only process if variable expands to non-empty 33449 33450 if test "x$CXX" != x; then 33451 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33452 33453 # First separate the path from the arguments. This will split at the first 33454 # space. 33455 complete="$CXX" 33456 path="${complete%% *}" 33457 tmp="$complete EOL" 33458 arguments="${tmp#* }" 33459 33460 # Input might be given as Windows format, start by converting to 33461 # unix format. 33462 new_path=`$CYGPATH -u "$path"` 33463 33464 # Now try to locate executable using which 33465 new_path=`$WHICH "$new_path" 2> /dev/null` 33466 # bat and cmd files are not always considered executable in cygwin causing which 33467 # to not find them 33468 if test "x$new_path" = x \ 33469 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 33470 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 33471 new_path=`$CYGPATH -u "$path"` 33472 fi 33473 if test "x$new_path" = x; then 33474 # Oops. Which didn't find the executable. 33475 # The splitting of arguments from the executable at a space might have been incorrect, 33476 # since paths with space are more likely in Windows. Give it another try with the whole 33477 # argument. 33478 path="$complete" 33479 arguments="EOL" 33480 new_path=`$CYGPATH -u "$path"` 33481 new_path=`$WHICH "$new_path" 2> /dev/null` 33482 # bat and cmd files are not always considered executable in cygwin causing which 33483 # to not find them 33484 if test "x$new_path" = x \ 33485 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 33486 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 33487 new_path=`$CYGPATH -u "$path"` 33488 fi 33489 if test "x$new_path" = x; then 33490 # It's still not found. Now this is an unrecoverable error. 33491 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5 33492 $as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;} 33493 has_space=`$ECHO "$complete" | $GREP " "` 33494 if test "x$has_space" != x; then 33495 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 33496 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 33497 fi 33498 as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5 33499 fi 33500 fi 33501 33502 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 33503 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 33504 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 33505 # "foo.exe" is OK but "foo" is an error. 33506 # 33507 # This test is therefore slightly more accurate than "test -f" to check for file presence. 33508 # It is also a way to make sure we got the proper file name for the real test later on. 33509 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 33510 if test "x$test_shortpath" = x; then 33511 # Short path failed, file does not exist as specified. 33512 # Try adding .exe or .cmd 33513 if test -f "${new_path}.exe"; then 33514 input_to_shortpath="${new_path}.exe" 33515 elif test -f "${new_path}.cmd"; then 33516 input_to_shortpath="${new_path}.cmd" 33517 else 33518 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$new_path\", is invalid." >&5 33519 $as_echo "$as_me: The path of CXX, which resolves as \"$new_path\", is invalid." >&6;} 33520 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 33521 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 33522 as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5 33523 fi 33524 else 33525 input_to_shortpath="$new_path" 33526 fi 33527 33528 # Call helper function which possibly converts this using DOS-style short mode. 33529 # If so, the updated path is stored in $new_path. 33530 new_path="$input_to_shortpath" 33531 33532 input_path="$input_to_shortpath" 33533 # Check if we need to convert this using DOS-style short mode. If the path 33534 # contains just simple characters, use it. Otherwise (spaces, weird characters), 33535 # take no chances and rewrite it. 33536 # Note: m4 eats our [], so we need to use [ and ] instead. 33537 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 33538 if test "x$has_forbidden_chars" != x; then 33539 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 33540 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 33541 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 33542 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 33543 # Going to short mode and back again did indeed matter. Since short mode is 33544 # case insensitive, let's make it lowercase to improve readability. 33545 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 33546 # Now convert it back to Unix-style (cygpath) 33547 input_path=`$CYGPATH -u "$shortmode_path"` 33548 new_path="$input_path" 33549 fi 33550 fi 33551 33552 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 33553 if test "x$test_cygdrive_prefix" = x; then 33554 # As a simple fix, exclude /usr/bin since it's not a real path. 33555 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 33556 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 33557 # a path prefixed by /cygdrive for fixpath to work. 33558 new_path="$CYGWIN_ROOT_PATH$input_path" 33559 fi 33560 fi 33561 33562 # remove trailing .exe if any 33563 new_path="${new_path/%.exe/}" 33564 33565 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33566 33567 # First separate the path from the arguments. This will split at the first 33568 # space. 33569 complete="$CXX" 33570 path="${complete%% *}" 33571 tmp="$complete EOL" 33572 arguments="${tmp#* }" 33573 33574 # Input might be given as Windows format, start by converting to 33575 # unix format. 33576 new_path="$path" 33577 33578 windows_path="$new_path" 33579 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33580 unix_path=`$CYGPATH -u "$windows_path"` 33581 new_path="$unix_path" 33582 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33583 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33584 new_path="$unix_path" 33585 fi 33586 33587 33588 # Now try to locate executable using which 33589 new_path=`$WHICH "$new_path" 2> /dev/null` 33590 33591 if test "x$new_path" = x; then 33592 # Oops. Which didn't find the executable. 33593 # The splitting of arguments from the executable at a space might have been incorrect, 33594 # since paths with space are more likely in Windows. Give it another try with the whole 33595 # argument. 33596 path="$complete" 33597 arguments="EOL" 33598 new_path="$path" 33599 33600 windows_path="$new_path" 33601 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33602 unix_path=`$CYGPATH -u "$windows_path"` 33603 new_path="$unix_path" 33604 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33605 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33606 new_path="$unix_path" 33607 fi 33608 33609 33610 new_path=`$WHICH "$new_path" 2> /dev/null` 33611 # bat and cmd files are not always considered executable in MSYS causing which 33612 # to not find them 33613 if test "x$new_path" = x \ 33614 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 33615 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 33616 new_path="$path" 33617 33618 windows_path="$new_path" 33619 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33620 unix_path=`$CYGPATH -u "$windows_path"` 33621 new_path="$unix_path" 33622 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33623 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33624 new_path="$unix_path" 33625 fi 33626 33627 fi 33628 33629 if test "x$new_path" = x; then 33630 # It's still not found. Now this is an unrecoverable error. 33631 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5 33632 $as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;} 33633 has_space=`$ECHO "$complete" | $GREP " "` 33634 if test "x$has_space" != x; then 33635 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 33636 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 33637 fi 33638 as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5 33639 fi 33640 fi 33641 33642 # Now new_path has a complete unix path to the binary 33643 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 33644 # Keep paths in /bin as-is, but remove trailing .exe if any 33645 new_path="${new_path/%.exe/}" 33646 # Do not save /bin paths to all_fixpath_prefixes! 33647 else 33648 # Not in mixed or Windows style, start by that. 33649 new_path=`cmd //c echo $new_path` 33650 33651 input_path="$new_path" 33652 # Check if we need to convert this using DOS-style short mode. If the path 33653 # contains just simple characters, use it. Otherwise (spaces, weird characters), 33654 # take no chances and rewrite it. 33655 # Note: m4 eats our [], so we need to use [ and ] instead. 33656 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 33657 if test "x$has_forbidden_chars" != x; then 33658 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 33659 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 33660 fi 33661 33662 # Output is in $new_path 33663 33664 windows_path="$new_path" 33665 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33666 unix_path=`$CYGPATH -u "$windows_path"` 33667 new_path="$unix_path" 33668 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 33669 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 33670 new_path="$unix_path" 33671 fi 33672 33673 # remove trailing .exe if any 33674 new_path="${new_path/%.exe/}" 33675 33676 # Save the first 10 bytes of this path to the storage, so fixpath can work. 33677 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 33678 fi 33679 33680 else 33681 # We're on a unix platform. Hooray! :) 33682 # First separate the path from the arguments. This will split at the first 33683 # space. 33684 complete="$CXX" 33685 path="${complete%% *}" 33686 tmp="$complete EOL" 33687 arguments="${tmp#* }" 33688 33689 # Cannot rely on the command "which" here since it doesn't always work. 33690 is_absolute_path=`$ECHO "$path" | $GREP ^/` 33691 if test -z "$is_absolute_path"; then 33692 # Path to executable is not absolute. Find it. 33693 IFS_save="$IFS" 33694 IFS=: 33695 for p in $PATH; do 33696 if test -f "$p/$path" && test -x "$p/$path"; then 33697 new_path="$p/$path" 33698 break 33699 fi 33700 done 33701 IFS="$IFS_save" 33702 else 33703 # This is an absolute path, we can use it without further modifications. 33704 new_path="$path" 33705 fi 33706 33707 if test "x$new_path" = x; then 33708 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXX, which resolves as \"$complete\", is not found." >&5 33709 $as_echo "$as_me: The path of CXX, which resolves as \"$complete\", is not found." >&6;} 33710 has_space=`$ECHO "$complete" | $GREP " "` 33711 if test "x$has_space" != x; then 33712 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 33713 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 33714 fi 33715 as_fn_error $? "Cannot locate the the path of CXX" "$LINENO" 5 33716 fi 33717 fi 33718 33719 # Now join together the path and the arguments once again 33720 if test "x$arguments" != xEOL; then 33721 new_complete="$new_path ${arguments% *}" 33722 else 33723 new_complete="$new_path" 33724 fi 33725 33726 if test "x$complete" != "x$new_complete"; then 33727 CXX="$new_complete" 33728 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CXX to \"$new_complete\"" >&5 33729 $as_echo "$as_me: Rewriting CXX to \"$new_complete\"" >&6;} 33730 fi 33731 fi 33732 33733 TEST_COMPILER="$CXX" 33734 # Don't remove symbolic links on AIX because 'xlc_r' and 'xlC_r' may all be links 33735 # to 'xlc' but it is crucial that we invoke the compiler with the right name! 33736 if test "x$OPENJDK_BUILD_OS" != xaix; then 33737 # FIXME: This test should not be needed anymore; we don't do that for any platform. 33738 { $as_echo "$as_me:${as_lineno-$LINENO}: checking resolved symbolic links for CXX" >&5 33739 $as_echo_n "checking resolved symbolic links for CXX... " >&6; } 33740 33741 if test "x$OPENJDK_BUILD_OS" != xwindows; then 33742 # Follow a chain of symbolic links. Use readlink 33743 # where it exists, else fall back to horribly 33744 # complicated shell code. 33745 if test "x$READLINK_TESTED" != yes; then 33746 # On MacOSX there is a readlink tool with a different 33747 # purpose than the GNU readlink tool. Check the found readlink. 33748 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 33749 if test "x$ISGNU" = x; then 33750 # A readlink that we do not know how to use. 33751 # Are there other non-GNU readlinks out there? 33752 READLINK_TESTED=yes 33753 READLINK= 33754 fi 33755 fi 33756 33757 if test "x$READLINK" != x; then 33758 TEST_COMPILER=`$READLINK -f $TEST_COMPILER` 33759 else 33760 # Save the current directory for restoring afterwards 33761 STARTDIR=$PWD 33762 COUNTER=0 33763 sym_link_dir=`$DIRNAME $TEST_COMPILER` 33764 sym_link_file=`$BASENAME $TEST_COMPILER` 33765 cd $sym_link_dir 33766 # Use -P flag to resolve symlinks in directories. 33767 cd `$THEPWDCMD -P` 33768 sym_link_dir=`$THEPWDCMD -P` 33769 # Resolve file symlinks 33770 while test $COUNTER -lt 20; do 33771 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 33772 if test "x$ISLINK" == x; then 33773 # This is not a symbolic link! We are done! 33774 break 33775 fi 33776 # Again resolve directory symlinks since the target of the just found 33777 # link could be in a different directory 33778 cd `$DIRNAME $ISLINK` 33779 sym_link_dir=`$THEPWDCMD -P` 33780 sym_link_file=`$BASENAME $ISLINK` 33781 let COUNTER=COUNTER+1 33782 done 33783 cd $STARTDIR 33784 TEST_COMPILER=$sym_link_dir/$sym_link_file 33785 fi 33786 fi 33787 33788 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TEST_COMPILER" >&5 33789 $as_echo "$TEST_COMPILER" >&6; } 33790 fi 33791 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if CXX is disguised ccache" >&5 33792 $as_echo_n "checking if CXX is disguised ccache... " >&6; } 33793 33794 COMPILER_BASENAME=`$BASENAME "$TEST_COMPILER"` 33795 if test "x$COMPILER_BASENAME" = "xccache"; then 33796 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes, trying to find proper $COMPILER_NAME compiler" >&5 33797 $as_echo "yes, trying to find proper $COMPILER_NAME compiler" >&6; } 33798 # We /usr/lib/ccache in the path, so cc is a symlink to /usr/bin/ccache. 33799 # We want to control ccache invocation ourselves, so ignore this cc and try 33800 # searching again. 33801 33802 # Remove the path to the fake ccache cc from the PATH 33803 RETRY_COMPILER_SAVED_PATH="$PATH" 33804 COMPILER_DIRNAME=`$DIRNAME $CXX` 33805 PATH="`$ECHO $PATH | $SED -e "s,$COMPILER_DIRNAME,,g" -e "s,::,:,g" -e "s,^:,,g"`" 33806 33807 # Try again looking for our compiler 33808 if test -n "$ac_tool_prefix"; then 33809 for ac_prog in $TOOLCHAIN_CXX_BINARY 33810 do 33811 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 33812 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 33813 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33814 $as_echo_n "checking for $ac_word... " >&6; } 33815 if ${ac_cv_prog_PROPER_COMPILER_CXX+:} false; then : 33816 $as_echo_n "(cached) " >&6 33817 else 33818 if test -n "$PROPER_COMPILER_CXX"; then 33819 ac_cv_prog_PROPER_COMPILER_CXX="$PROPER_COMPILER_CXX" # Let the user override the test. 33820 else 33821 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33822 for as_dir in $PATH 33823 do 33824 IFS=$as_save_IFS 33825 test -z "$as_dir" && as_dir=. 33826 for ac_exec_ext in '' $ac_executable_extensions; do 33827 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 33828 ac_cv_prog_PROPER_COMPILER_CXX="$ac_tool_prefix$ac_prog" 33829 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 33830 break 2 33831 fi 33832 done 33833 done 33834 IFS=$as_save_IFS 33835 33836 fi 33837 fi 33838 PROPER_COMPILER_CXX=$ac_cv_prog_PROPER_COMPILER_CXX 33839 if test -n "$PROPER_COMPILER_CXX"; then 33840 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROPER_COMPILER_CXX" >&5 33841 $as_echo "$PROPER_COMPILER_CXX" >&6; } 33842 else 33843 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33844 $as_echo "no" >&6; } 33845 fi 33846 33847 33848 test -n "$PROPER_COMPILER_CXX" && break 33849 done 33850 fi 33851 if test -z "$PROPER_COMPILER_CXX"; then 33852 ac_ct_PROPER_COMPILER_CXX=$PROPER_COMPILER_CXX 33853 for ac_prog in $TOOLCHAIN_CXX_BINARY 33854 do 33855 # Extract the first word of "$ac_prog", so it can be a program name with args. 33856 set dummy $ac_prog; ac_word=$2 33857 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 33858 $as_echo_n "checking for $ac_word... " >&6; } 33859 if ${ac_cv_prog_ac_ct_PROPER_COMPILER_CXX+:} false; then : 33860 $as_echo_n "(cached) " >&6 33861 else 33862 if test -n "$ac_ct_PROPER_COMPILER_CXX"; then 33863 ac_cv_prog_ac_ct_PROPER_COMPILER_CXX="$ac_ct_PROPER_COMPILER_CXX" # Let the user override the test. 33864 else 33865 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 33866 for as_dir in $PATH 33867 do 33868 IFS=$as_save_IFS 33869 test -z "$as_dir" && as_dir=. 33870 for ac_exec_ext in '' $ac_executable_extensions; do 33871 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 33872 ac_cv_prog_ac_ct_PROPER_COMPILER_CXX="$ac_prog" 33873 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 33874 break 2 33875 fi 33876 done 33877 done 33878 IFS=$as_save_IFS 33879 33880 fi 33881 fi 33882 ac_ct_PROPER_COMPILER_CXX=$ac_cv_prog_ac_ct_PROPER_COMPILER_CXX 33883 if test -n "$ac_ct_PROPER_COMPILER_CXX"; then 33884 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_PROPER_COMPILER_CXX" >&5 33885 $as_echo "$ac_ct_PROPER_COMPILER_CXX" >&6; } 33886 else 33887 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 33888 $as_echo "no" >&6; } 33889 fi 33890 33891 33892 test -n "$ac_ct_PROPER_COMPILER_CXX" && break 33893 done 33894 33895 if test "x$ac_ct_PROPER_COMPILER_CXX" = x; then 33896 PROPER_COMPILER_CXX="" 33897 else 33898 case $cross_compiling:$ac_tool_warned in 33899 yes:) 33900 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 33901 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 33902 ac_tool_warned=yes ;; 33903 esac 33904 PROPER_COMPILER_CXX=$ac_ct_PROPER_COMPILER_CXX 33905 fi 33906 fi 33907 33908 33909 # Only process if variable expands to non-empty 33910 33911 if test "x$PROPER_COMPILER_CXX" != x; then 33912 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 33913 33914 # First separate the path from the arguments. This will split at the first 33915 # space. 33916 complete="$PROPER_COMPILER_CXX" 33917 path="${complete%% *}" 33918 tmp="$complete EOL" 33919 arguments="${tmp#* }" 33920 33921 # Input might be given as Windows format, start by converting to 33922 # unix format. 33923 new_path=`$CYGPATH -u "$path"` 33924 33925 # Now try to locate executable using which 33926 new_path=`$WHICH "$new_path" 2> /dev/null` 33927 # bat and cmd files are not always considered executable in cygwin causing which 33928 # to not find them 33929 if test "x$new_path" = x \ 33930 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 33931 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 33932 new_path=`$CYGPATH -u "$path"` 33933 fi 33934 if test "x$new_path" = x; then 33935 # Oops. Which didn't find the executable. 33936 # The splitting of arguments from the executable at a space might have been incorrect, 33937 # since paths with space are more likely in Windows. Give it another try with the whole 33938 # argument. 33939 path="$complete" 33940 arguments="EOL" 33941 new_path=`$CYGPATH -u "$path"` 33942 new_path=`$WHICH "$new_path" 2> /dev/null` 33943 # bat and cmd files are not always considered executable in cygwin causing which 33944 # to not find them 33945 if test "x$new_path" = x \ 33946 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 33947 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 33948 new_path=`$CYGPATH -u "$path"` 33949 fi 33950 if test "x$new_path" = x; then 33951 # It's still not found. Now this is an unrecoverable error. 33952 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&5 33953 $as_echo "$as_me: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&6;} 33954 has_space=`$ECHO "$complete" | $GREP " "` 33955 if test "x$has_space" != x; then 33956 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 33957 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 33958 fi 33959 as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CXX" "$LINENO" 5 33960 fi 33961 fi 33962 33963 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 33964 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 33965 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 33966 # "foo.exe" is OK but "foo" is an error. 33967 # 33968 # This test is therefore slightly more accurate than "test -f" to check for file presence. 33969 # It is also a way to make sure we got the proper file name for the real test later on. 33970 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 33971 if test "x$test_shortpath" = x; then 33972 # Short path failed, file does not exist as specified. 33973 # Try adding .exe or .cmd 33974 if test -f "${new_path}.exe"; then 33975 input_to_shortpath="${new_path}.exe" 33976 elif test -f "${new_path}.cmd"; then 33977 input_to_shortpath="${new_path}.cmd" 33978 else 33979 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CXX, which resolves as \"$new_path\", is invalid." >&5 33980 $as_echo "$as_me: The path of PROPER_COMPILER_CXX, which resolves as \"$new_path\", is invalid." >&6;} 33981 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 33982 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 33983 as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CXX" "$LINENO" 5 33984 fi 33985 else 33986 input_to_shortpath="$new_path" 33987 fi 33988 33989 # Call helper function which possibly converts this using DOS-style short mode. 33990 # If so, the updated path is stored in $new_path. 33991 new_path="$input_to_shortpath" 33992 33993 input_path="$input_to_shortpath" 33994 # Check if we need to convert this using DOS-style short mode. If the path 33995 # contains just simple characters, use it. Otherwise (spaces, weird characters), 33996 # take no chances and rewrite it. 33997 # Note: m4 eats our [], so we need to use [ and ] instead. 33998 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 33999 if test "x$has_forbidden_chars" != x; then 34000 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 34001 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 34002 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 34003 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 34004 # Going to short mode and back again did indeed matter. Since short mode is 34005 # case insensitive, let's make it lowercase to improve readability. 34006 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 34007 # Now convert it back to Unix-style (cygpath) 34008 input_path=`$CYGPATH -u "$shortmode_path"` 34009 new_path="$input_path" 34010 fi 34011 fi 34012 34013 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 34014 if test "x$test_cygdrive_prefix" = x; then 34015 # As a simple fix, exclude /usr/bin since it's not a real path. 34016 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 34017 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 34018 # a path prefixed by /cygdrive for fixpath to work. 34019 new_path="$CYGWIN_ROOT_PATH$input_path" 34020 fi 34021 fi 34022 34023 # remove trailing .exe if any 34024 new_path="${new_path/%.exe/}" 34025 34026 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34027 34028 # First separate the path from the arguments. This will split at the first 34029 # space. 34030 complete="$PROPER_COMPILER_CXX" 34031 path="${complete%% *}" 34032 tmp="$complete EOL" 34033 arguments="${tmp#* }" 34034 34035 # Input might be given as Windows format, start by converting to 34036 # unix format. 34037 new_path="$path" 34038 34039 windows_path="$new_path" 34040 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34041 unix_path=`$CYGPATH -u "$windows_path"` 34042 new_path="$unix_path" 34043 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34044 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 34045 new_path="$unix_path" 34046 fi 34047 34048 34049 # Now try to locate executable using which 34050 new_path=`$WHICH "$new_path" 2> /dev/null` 34051 34052 if test "x$new_path" = x; then 34053 # Oops. Which didn't find the executable. 34054 # The splitting of arguments from the executable at a space might have been incorrect, 34055 # since paths with space are more likely in Windows. Give it another try with the whole 34056 # argument. 34057 path="$complete" 34058 arguments="EOL" 34059 new_path="$path" 34060 34061 windows_path="$new_path" 34062 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34063 unix_path=`$CYGPATH -u "$windows_path"` 34064 new_path="$unix_path" 34065 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34066 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 34067 new_path="$unix_path" 34068 fi 34069 34070 34071 new_path=`$WHICH "$new_path" 2> /dev/null` 34072 # bat and cmd files are not always considered executable in MSYS causing which 34073 # to not find them 34074 if test "x$new_path" = x \ 34075 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 34076 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 34077 new_path="$path" 34078 34079 windows_path="$new_path" 34080 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34081 unix_path=`$CYGPATH -u "$windows_path"` 34082 new_path="$unix_path" 34083 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34084 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 34085 new_path="$unix_path" 34086 fi 34087 34088 fi 34089 34090 if test "x$new_path" = x; then 34091 # It's still not found. Now this is an unrecoverable error. 34092 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&5 34093 $as_echo "$as_me: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&6;} 34094 has_space=`$ECHO "$complete" | $GREP " "` 34095 if test "x$has_space" != x; then 34096 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 34097 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 34098 fi 34099 as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CXX" "$LINENO" 5 34100 fi 34101 fi 34102 34103 # Now new_path has a complete unix path to the binary 34104 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 34105 # Keep paths in /bin as-is, but remove trailing .exe if any 34106 new_path="${new_path/%.exe/}" 34107 # Do not save /bin paths to all_fixpath_prefixes! 34108 else 34109 # Not in mixed or Windows style, start by that. 34110 new_path=`cmd //c echo $new_path` 34111 34112 input_path="$new_path" 34113 # Check if we need to convert this using DOS-style short mode. If the path 34114 # contains just simple characters, use it. Otherwise (spaces, weird characters), 34115 # take no chances and rewrite it. 34116 # Note: m4 eats our [], so we need to use [ and ] instead. 34117 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 34118 if test "x$has_forbidden_chars" != x; then 34119 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 34120 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 34121 fi 34122 34123 # Output is in $new_path 34124 34125 windows_path="$new_path" 34126 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34127 unix_path=`$CYGPATH -u "$windows_path"` 34128 new_path="$unix_path" 34129 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34130 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 34131 new_path="$unix_path" 34132 fi 34133 34134 # remove trailing .exe if any 34135 new_path="${new_path/%.exe/}" 34136 34137 # Save the first 10 bytes of this path to the storage, so fixpath can work. 34138 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 34139 fi 34140 34141 else 34142 # We're on a unix platform. Hooray! :) 34143 # First separate the path from the arguments. This will split at the first 34144 # space. 34145 complete="$PROPER_COMPILER_CXX" 34146 path="${complete%% *}" 34147 tmp="$complete EOL" 34148 arguments="${tmp#* }" 34149 34150 # Cannot rely on the command "which" here since it doesn't always work. 34151 is_absolute_path=`$ECHO "$path" | $GREP ^/` 34152 if test -z "$is_absolute_path"; then 34153 # Path to executable is not absolute. Find it. 34154 IFS_save="$IFS" 34155 IFS=: 34156 for p in $PATH; do 34157 if test -f "$p/$path" && test -x "$p/$path"; then 34158 new_path="$p/$path" 34159 break 34160 fi 34161 done 34162 IFS="$IFS_save" 34163 else 34164 # This is an absolute path, we can use it without further modifications. 34165 new_path="$path" 34166 fi 34167 34168 if test "x$new_path" = x; then 34169 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&5 34170 $as_echo "$as_me: The path of PROPER_COMPILER_CXX, which resolves as \"$complete\", is not found." >&6;} 34171 has_space=`$ECHO "$complete" | $GREP " "` 34172 if test "x$has_space" != x; then 34173 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 34174 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 34175 fi 34176 as_fn_error $? "Cannot locate the the path of PROPER_COMPILER_CXX" "$LINENO" 5 34177 fi 34178 fi 34179 34180 # Now join together the path and the arguments once again 34181 if test "x$arguments" != xEOL; then 34182 new_complete="$new_path ${arguments% *}" 34183 else 34184 new_complete="$new_path" 34185 fi 34186 34187 if test "x$complete" != "x$new_complete"; then 34188 PROPER_COMPILER_CXX="$new_complete" 34189 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting PROPER_COMPILER_CXX to \"$new_complete\"" >&5 34190 $as_echo "$as_me: Rewriting PROPER_COMPILER_CXX to \"$new_complete\"" >&6;} 34191 fi 34192 fi 34193 34194 PATH="$RETRY_COMPILER_SAVED_PATH" 34195 34196 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for resolved symbolic links for CXX" >&5 34197 $as_echo_n "checking for resolved symbolic links for CXX... " >&6; } 34198 34199 if test "x$OPENJDK_BUILD_OS" != xwindows; then 34200 # Follow a chain of symbolic links. Use readlink 34201 # where it exists, else fall back to horribly 34202 # complicated shell code. 34203 if test "x$READLINK_TESTED" != yes; then 34204 # On MacOSX there is a readlink tool with a different 34205 # purpose than the GNU readlink tool. Check the found readlink. 34206 ISGNU=`$READLINK --version 2>&1 | $GREP GNU` 34207 if test "x$ISGNU" = x; then 34208 # A readlink that we do not know how to use. 34209 # Are there other non-GNU readlinks out there? 34210 READLINK_TESTED=yes 34211 READLINK= 34212 fi 34213 fi 34214 34215 if test "x$READLINK" != x; then 34216 PROPER_COMPILER_CXX=`$READLINK -f $PROPER_COMPILER_CXX` 34217 else 34218 # Save the current directory for restoring afterwards 34219 STARTDIR=$PWD 34220 COUNTER=0 34221 sym_link_dir=`$DIRNAME $PROPER_COMPILER_CXX` 34222 sym_link_file=`$BASENAME $PROPER_COMPILER_CXX` 34223 cd $sym_link_dir 34224 # Use -P flag to resolve symlinks in directories. 34225 cd `$THEPWDCMD -P` 34226 sym_link_dir=`$THEPWDCMD -P` 34227 # Resolve file symlinks 34228 while test $COUNTER -lt 20; do 34229 ISLINK=`$LS -l $sym_link_dir/$sym_link_file | $GREP '\->' | $SED -e 's/.*-> \(.*\)/\1/'` 34230 if test "x$ISLINK" == x; then 34231 # This is not a symbolic link! We are done! 34232 break 34233 fi 34234 # Again resolve directory symlinks since the target of the just found 34235 # link could be in a different directory 34236 cd `$DIRNAME $ISLINK` 34237 sym_link_dir=`$THEPWDCMD -P` 34238 sym_link_file=`$BASENAME $ISLINK` 34239 let COUNTER=COUNTER+1 34240 done 34241 cd $STARTDIR 34242 PROPER_COMPILER_CXX=$sym_link_dir/$sym_link_file 34243 fi 34244 fi 34245 34246 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $PROPER_COMPILER_CXX" >&5 34247 $as_echo "$PROPER_COMPILER_CXX" >&6; } 34248 CXX="$PROPER_COMPILER_CXX" 34249 else 34250 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, keeping CXX" >&5 34251 $as_echo "no, keeping CXX" >&6; } 34252 fi 34253 34254 34255 COMPILER=$CXX 34256 COMPILER_NAME=$COMPILER_NAME 34257 34258 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 34259 # cc -V output typically looks like 34260 # cc: Sun C 5.12 Linux_i386 2011/11/16 34261 COMPILER_VERSION_OUTPUT=`$COMPILER -V 2>&1` 34262 # Check that this is likely to be the Solaris Studio cc. 34263 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "^.*: Sun $COMPILER_NAME" > /dev/null 34264 if test $? -ne 0; then 34265 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 34266 { $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 34267 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 34268 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&5 34269 $as_echo "$as_me: The result from running with -V was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 34270 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 34271 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 34272 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 34273 fi 34274 # Remove usage instructions (if present), and 34275 # collapse compiler output into a single line 34276 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34277 $SED -e 's/ *[Uu]sage:.*//'` 34278 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34279 $SED -e "s/^.*[ ,\t]$COMPILER_NAME[ ,\t]\([1-9]\.[0-9][0-9]*\).*/\1/"` 34280 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 34281 # xlc -qversion output typically looks like 34282 # IBM XL C/C++ for AIX, V11.1 (5724-X13) 34283 # Version: 11.01.0000.0015 34284 COMPILER_VERSION_OUTPUT=`$COMPILER -qversion 2>&1` 34285 # Check that this is likely to be the IBM XL C compiler. 34286 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "IBM XL C" > /dev/null 34287 if test $? -ne 0; then 34288 ALT_VERSION_OUTPUT=`$COMPILER --version 2>&1` 34289 { $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 34290 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 34291 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&5 34292 $as_echo "$as_me: The result from running with -qversion was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 34293 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&5 34294 $as_echo "$as_me: The result from running with --version was: \"$ALT_VERSION_OUTPUT\"" >&6;} 34295 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 34296 fi 34297 # Collapse compiler output into a single line 34298 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 34299 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34300 $SED -e 's/^.*, V\([1-9][0-9.]*\).*$/\1/'` 34301 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 34302 # There is no specific version flag, but all output starts with a version string. 34303 # First line typically looks something like: 34304 # Microsoft (R) 32-bit C/C++ Optimizing Compiler Version 16.00.40219.01 for 80x86 34305 COMPILER_VERSION_OUTPUT=`$COMPILER 2>&1 | $HEAD -n 1 | $TR -d '\r'` 34306 # Check that this is likely to be Microsoft CL.EXE. 34307 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Microsoft.*Compiler" > /dev/null 34308 if test $? -ne 0; then 34309 { $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 34310 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 34311 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&5 34312 $as_echo "$as_me: The result from running it was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 34313 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 34314 fi 34315 # Collapse compiler output into a single line 34316 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 34317 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34318 $SED -e 's/^.*ersion.\([1-9][0-9.]*\) .*$/\1/'` 34319 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 34320 # gcc --version output typically looks like 34321 # gcc (Ubuntu/Linaro 4.8.1-10ubuntu9) 4.8.1 34322 # Copyright (C) 2013 Free Software Foundation, Inc. 34323 # This is free software; see the source for copying conditions. There is NO 34324 # warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 34325 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 34326 # Check that this is likely to be GCC. 34327 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "Free Software Foundation" > /dev/null 34328 if test $? -ne 0; then 34329 { $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 34330 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 34331 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION\"" >&5 34332 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION\"" >&6;} 34333 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 34334 fi 34335 # Remove Copyright and legalese from version string, and 34336 # collapse into a single line 34337 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34338 $SED -e 's/ *Copyright .*//'` 34339 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34340 $SED -e 's/^.* \([1-9]\.[0-9.]*\) .*$/\1/'` 34341 elif test "x$TOOLCHAIN_TYPE" = xclang; then 34342 # clang --version output typically looks like 34343 # Apple LLVM version 5.0 (clang-500.2.79) (based on LLVM 3.3svn) 34344 # clang version 3.3 (tags/RELEASE_33/final) 34345 # or 34346 # Debian clang version 3.2-7ubuntu1 (tags/RELEASE_32/final) (based on LLVM 3.2) 34347 # Target: x86_64-pc-linux-gnu 34348 # Thread model: posix 34349 COMPILER_VERSION_OUTPUT=`$COMPILER --version 2>&1` 34350 # Check that this is likely to be clang 34351 $ECHO "$COMPILER_VERSION_OUTPUT" | $GREP "clang" > /dev/null 34352 if test $? -ne 0; then 34353 { $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 34354 $as_echo "$as_me: The $COMPILER_NAME compiler (located as $COMPILER) does not seem to be the required $TOOLCHAIN_TYPE compiler." >&6;} 34355 { $as_echo "$as_me:${as_lineno-$LINENO}: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&5 34356 $as_echo "$as_me: The result from running with --version was: \"$COMPILER_VERSION_OUTPUT\"" >&6;} 34357 as_fn_error $? "A $TOOLCHAIN_TYPE compiler is required. Try setting --with-tools-dir." "$LINENO" 5 34358 fi 34359 # Collapse compiler output into a single line 34360 COMPILER_VERSION_STRING=`$ECHO $COMPILER_VERSION_OUTPUT` 34361 COMPILER_VERSION_NUMBER=`$ECHO $COMPILER_VERSION_OUTPUT | \ 34362 $SED -e 's/^.*clang version \([1-9][0-9.]*\).*$/\1/'` 34363 else 34364 as_fn_error $? "Unknown toolchain type $TOOLCHAIN_TYPE." "$LINENO" 5 34365 fi 34366 # This sets CC_VERSION_NUMBER or CXX_VERSION_NUMBER. (This comment is a grep marker) 34367 CXX_VERSION_NUMBER="$COMPILER_VERSION_NUMBER" 34368 # This sets CC_VERSION_STRING or CXX_VERSION_STRING. (This comment is a grep marker) 34369 CXX_VERSION_STRING="$COMPILER_VERSION_STRING" 34370 34371 { $as_echo "$as_me:${as_lineno-$LINENO}: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&5 34372 $as_echo "$as_me: Using $TOOLCHAIN_TYPE $COMPILER_NAME compiler version $COMPILER_VERSION_NUMBER [$COMPILER_VERSION_STRING]" >&6;} 34373 34374 34375 # Now that we have resolved CXX ourself, let autoconf have its go at it 34376 ac_ext=cpp 34377 ac_cpp='$CXXCPP $CPPFLAGS' 34378 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 34379 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 34380 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 34381 if test -z "$CXX"; then 34382 if test -n "$CCC"; then 34383 CXX=$CCC 34384 else 34385 if test -n "$ac_tool_prefix"; then 34386 for ac_prog in $CXX 34387 do 34388 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 34389 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 34390 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 34391 $as_echo_n "checking for $ac_word... " >&6; } 34392 if ${ac_cv_prog_CXX+:} false; then : 34393 $as_echo_n "(cached) " >&6 34394 else 34395 if test -n "$CXX"; then 34396 ac_cv_prog_CXX="$CXX" # Let the user override the test. 34397 else 34398 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 34399 for as_dir in $PATH 34400 do 34401 IFS=$as_save_IFS 34402 test -z "$as_dir" && as_dir=. 34403 for ac_exec_ext in '' $ac_executable_extensions; do 34404 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 34405 ac_cv_prog_CXX="$ac_tool_prefix$ac_prog" 34406 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 34407 break 2 34408 fi 34409 done 34410 done 34411 IFS=$as_save_IFS 34412 34413 fi 34414 fi 34415 CXX=$ac_cv_prog_CXX 34416 if test -n "$CXX"; then 34417 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXX" >&5 34418 $as_echo "$CXX" >&6; } 34419 else 34420 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 34421 $as_echo "no" >&6; } 34422 fi 34423 34424 34425 test -n "$CXX" && break 34426 done 34427 fi 34428 if test -z "$CXX"; then 34429 ac_ct_CXX=$CXX 34430 for ac_prog in $CXX 34431 do 34432 # Extract the first word of "$ac_prog", so it can be a program name with args. 34433 set dummy $ac_prog; ac_word=$2 34434 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 34435 $as_echo_n "checking for $ac_word... " >&6; } 34436 if ${ac_cv_prog_ac_ct_CXX+:} false; then : 34437 $as_echo_n "(cached) " >&6 34438 else 34439 if test -n "$ac_ct_CXX"; then 34440 ac_cv_prog_ac_ct_CXX="$ac_ct_CXX" # Let the user override the test. 34441 else 34442 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 34443 for as_dir in $PATH 34444 do 34445 IFS=$as_save_IFS 34446 test -z "$as_dir" && as_dir=. 34447 for ac_exec_ext in '' $ac_executable_extensions; do 34448 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 34449 ac_cv_prog_ac_ct_CXX="$ac_prog" 34450 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 34451 break 2 34452 fi 34453 done 34454 done 34455 IFS=$as_save_IFS 34456 34457 fi 34458 fi 34459 ac_ct_CXX=$ac_cv_prog_ac_ct_CXX 34460 if test -n "$ac_ct_CXX"; then 34461 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_CXX" >&5 34462 $as_echo "$ac_ct_CXX" >&6; } 34463 else 34464 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 34465 $as_echo "no" >&6; } 34466 fi 34467 34468 34469 test -n "$ac_ct_CXX" && break 34470 done 34471 34472 if test "x$ac_ct_CXX" = x; then 34473 CXX="g++" 34474 else 34475 case $cross_compiling:$ac_tool_warned in 34476 yes:) 34477 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 34478 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 34479 ac_tool_warned=yes ;; 34480 esac 34481 CXX=$ac_ct_CXX 34482 fi 34483 fi 34484 34485 fi 34486 fi 34487 # Provide some information about the compiler. 34488 $as_echo "$as_me:${as_lineno-$LINENO}: checking for C++ compiler version" >&5 34489 set X $ac_compile 34490 ac_compiler=$2 34491 for ac_option in --version -v -V -qversion; do 34492 { { ac_try="$ac_compiler $ac_option >&5" 34493 case "(($ac_try" in 34494 *\"* | *\`* | *\\*) ac_try_echo=\$ac_try;; 34495 *) ac_try_echo=$ac_try;; 34496 esac 34497 eval ac_try_echo="\"\$as_me:${as_lineno-$LINENO}: $ac_try_echo\"" 34498 $as_echo "$ac_try_echo"; } >&5 34499 (eval "$ac_compiler $ac_option >&5") 2>conftest.err 34500 ac_status=$? 34501 if test -s conftest.err; then 34502 sed '10a\ 34503 ... rest of stderr output deleted ... 34504 10q' conftest.err >conftest.er1 34505 cat conftest.er1 >&5 34506 fi 34507 rm -f conftest.er1 conftest.err 34508 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 34509 test $ac_status = 0; } 34510 done 34511 34512 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether we are using the GNU C++ compiler" >&5 34513 $as_echo_n "checking whether we are using the GNU C++ compiler... " >&6; } 34514 if ${ac_cv_cxx_compiler_gnu+:} false; then : 34515 $as_echo_n "(cached) " >&6 34516 else 34517 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34518 /* end confdefs.h. */ 34519 34520 int 34521 main () 34522 { 34523 #ifndef __GNUC__ 34524 choke me 34525 #endif 34526 34527 ; 34528 return 0; 34529 } 34530 _ACEOF 34531 if ac_fn_cxx_try_compile "$LINENO"; then : 34532 ac_compiler_gnu=yes 34533 else 34534 ac_compiler_gnu=no 34535 fi 34536 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 34537 ac_cv_cxx_compiler_gnu=$ac_compiler_gnu 34538 34539 fi 34540 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_cxx_compiler_gnu" >&5 34541 $as_echo "$ac_cv_cxx_compiler_gnu" >&6; } 34542 if test $ac_compiler_gnu = yes; then 34543 GXX=yes 34544 else 34545 GXX= 34546 fi 34547 ac_test_CXXFLAGS=${CXXFLAGS+set} 34548 ac_save_CXXFLAGS=$CXXFLAGS 34549 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether $CXX accepts -g" >&5 34550 $as_echo_n "checking whether $CXX accepts -g... " >&6; } 34551 if ${ac_cv_prog_cxx_g+:} false; then : 34552 $as_echo_n "(cached) " >&6 34553 else 34554 ac_save_cxx_werror_flag=$ac_cxx_werror_flag 34555 ac_cxx_werror_flag=yes 34556 ac_cv_prog_cxx_g=no 34557 CXXFLAGS="-g" 34558 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34559 /* end confdefs.h. */ 34560 34561 int 34562 main () 34563 { 34564 34565 ; 34566 return 0; 34567 } 34568 _ACEOF 34569 if ac_fn_cxx_try_compile "$LINENO"; then : 34570 ac_cv_prog_cxx_g=yes 34571 else 34572 CXXFLAGS="" 34573 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34574 /* end confdefs.h. */ 34575 34576 int 34577 main () 34578 { 34579 34580 ; 34581 return 0; 34582 } 34583 _ACEOF 34584 if ac_fn_cxx_try_compile "$LINENO"; then : 34585 34586 else 34587 ac_cxx_werror_flag=$ac_save_cxx_werror_flag 34588 CXXFLAGS="-g" 34589 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34590 /* end confdefs.h. */ 34591 34592 int 34593 main () 34594 { 34595 34596 ; 34597 return 0; 34598 } 34599 _ACEOF 34600 if ac_fn_cxx_try_compile "$LINENO"; then : 34601 ac_cv_prog_cxx_g=yes 34602 fi 34603 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 34604 fi 34605 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 34606 fi 34607 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 34608 ac_cxx_werror_flag=$ac_save_cxx_werror_flag 34609 fi 34610 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_prog_cxx_g" >&5 34611 $as_echo "$ac_cv_prog_cxx_g" >&6; } 34612 if test "$ac_test_CXXFLAGS" = set; then 34613 CXXFLAGS=$ac_save_CXXFLAGS 34614 elif test $ac_cv_prog_cxx_g = yes; then 34615 if test "$GXX" = yes; then 34616 CXXFLAGS="-g -O2" 34617 else 34618 CXXFLAGS="-g" 34619 fi 34620 else 34621 if test "$GXX" = yes; then 34622 CXXFLAGS="-O2" 34623 else 34624 CXXFLAGS= 34625 fi 34626 fi 34627 ac_ext=cpp 34628 ac_cpp='$CXXCPP $CPPFLAGS' 34629 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 34630 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 34631 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 34632 34633 34634 # 34635 # Setup the preprocessor (CPP and CXXCPP) 34636 # 34637 ac_ext=c 34638 ac_cpp='$CPP $CPPFLAGS' 34639 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 34640 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 34641 ac_compiler_gnu=$ac_cv_c_compiler_gnu 34642 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C preprocessor" >&5 34643 $as_echo_n "checking how to run the C preprocessor... " >&6; } 34644 # On Suns, sometimes $CPP names a directory. 34645 if test -n "$CPP" && test -d "$CPP"; then 34646 CPP= 34647 fi 34648 if test -z "$CPP"; then 34649 if ${ac_cv_prog_CPP+:} false; then : 34650 $as_echo_n "(cached) " >&6 34651 else 34652 # Double quotes because CPP needs to be expanded 34653 for CPP in "$CC -E" "$CC -E -traditional-cpp" "/lib/cpp" 34654 do 34655 ac_preproc_ok=false 34656 for ac_c_preproc_warn_flag in '' yes 34657 do 34658 # Use a header file that comes with gcc, so configuring glibc 34659 # with a fresh cross-compiler works. 34660 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 34661 # <limits.h> exists even on freestanding compilers. 34662 # On the NeXT, cc -E runs the code through the compiler's parser, 34663 # not just through cpp. "Syntax error" is here to catch this case. 34664 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34665 /* end confdefs.h. */ 34666 #ifdef __STDC__ 34667 # include <limits.h> 34668 #else 34669 # include <assert.h> 34670 #endif 34671 Syntax error 34672 _ACEOF 34673 if ac_fn_c_try_cpp "$LINENO"; then : 34674 34675 else 34676 # Broken: fails on valid input. 34677 continue 34678 fi 34679 rm -f conftest.err conftest.i conftest.$ac_ext 34680 34681 # OK, works on sane cases. Now check whether nonexistent headers 34682 # can be detected and how. 34683 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34684 /* end confdefs.h. */ 34685 #include <ac_nonexistent.h> 34686 _ACEOF 34687 if ac_fn_c_try_cpp "$LINENO"; then : 34688 # Broken: success on invalid input. 34689 continue 34690 else 34691 # Passes both tests. 34692 ac_preproc_ok=: 34693 break 34694 fi 34695 rm -f conftest.err conftest.i conftest.$ac_ext 34696 34697 done 34698 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 34699 rm -f conftest.i conftest.err conftest.$ac_ext 34700 if $ac_preproc_ok; then : 34701 break 34702 fi 34703 34704 done 34705 ac_cv_prog_CPP=$CPP 34706 34707 fi 34708 CPP=$ac_cv_prog_CPP 34709 else 34710 ac_cv_prog_CPP=$CPP 34711 fi 34712 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CPP" >&5 34713 $as_echo "$CPP" >&6; } 34714 ac_preproc_ok=false 34715 for ac_c_preproc_warn_flag in '' yes 34716 do 34717 # Use a header file that comes with gcc, so configuring glibc 34718 # with a fresh cross-compiler works. 34719 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 34720 # <limits.h> exists even on freestanding compilers. 34721 # On the NeXT, cc -E runs the code through the compiler's parser, 34722 # not just through cpp. "Syntax error" is here to catch this case. 34723 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34724 /* end confdefs.h. */ 34725 #ifdef __STDC__ 34726 # include <limits.h> 34727 #else 34728 # include <assert.h> 34729 #endif 34730 Syntax error 34731 _ACEOF 34732 if ac_fn_c_try_cpp "$LINENO"; then : 34733 34734 else 34735 # Broken: fails on valid input. 34736 continue 34737 fi 34738 rm -f conftest.err conftest.i conftest.$ac_ext 34739 34740 # OK, works on sane cases. Now check whether nonexistent headers 34741 # can be detected and how. 34742 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 34743 /* end confdefs.h. */ 34744 #include <ac_nonexistent.h> 34745 _ACEOF 34746 if ac_fn_c_try_cpp "$LINENO"; then : 34747 # Broken: success on invalid input. 34748 continue 34749 else 34750 # Passes both tests. 34751 ac_preproc_ok=: 34752 break 34753 fi 34754 rm -f conftest.err conftest.i conftest.$ac_ext 34755 34756 done 34757 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 34758 rm -f conftest.i conftest.err conftest.$ac_ext 34759 if $ac_preproc_ok; then : 34760 34761 else 34762 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 34763 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 34764 as_fn_error $? "C preprocessor \"$CPP\" fails sanity check 34765 See \`config.log' for more details" "$LINENO" 5; } 34766 fi 34767 34768 ac_ext=cpp 34769 ac_cpp='$CXXCPP $CPPFLAGS' 34770 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 34771 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 34772 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 34773 34774 34775 # Only process if variable expands to non-empty 34776 34777 if test "x$CPP" != x; then 34778 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34779 34780 # First separate the path from the arguments. This will split at the first 34781 # space. 34782 complete="$CPP" 34783 path="${complete%% *}" 34784 tmp="$complete EOL" 34785 arguments="${tmp#* }" 34786 34787 # Input might be given as Windows format, start by converting to 34788 # unix format. 34789 new_path=`$CYGPATH -u "$path"` 34790 34791 # Now try to locate executable using which 34792 new_path=`$WHICH "$new_path" 2> /dev/null` 34793 # bat and cmd files are not always considered executable in cygwin causing which 34794 # to not find them 34795 if test "x$new_path" = x \ 34796 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 34797 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 34798 new_path=`$CYGPATH -u "$path"` 34799 fi 34800 if test "x$new_path" = x; then 34801 # Oops. Which didn't find the executable. 34802 # The splitting of arguments from the executable at a space might have been incorrect, 34803 # since paths with space are more likely in Windows. Give it another try with the whole 34804 # argument. 34805 path="$complete" 34806 arguments="EOL" 34807 new_path=`$CYGPATH -u "$path"` 34808 new_path=`$WHICH "$new_path" 2> /dev/null` 34809 # bat and cmd files are not always considered executable in cygwin causing which 34810 # to not find them 34811 if test "x$new_path" = x \ 34812 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 34813 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 34814 new_path=`$CYGPATH -u "$path"` 34815 fi 34816 if test "x$new_path" = x; then 34817 # It's still not found. Now this is an unrecoverable error. 34818 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5 34819 $as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;} 34820 has_space=`$ECHO "$complete" | $GREP " "` 34821 if test "x$has_space" != x; then 34822 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 34823 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 34824 fi 34825 as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5 34826 fi 34827 fi 34828 34829 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 34830 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 34831 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 34832 # "foo.exe" is OK but "foo" is an error. 34833 # 34834 # This test is therefore slightly more accurate than "test -f" to check for file presence. 34835 # It is also a way to make sure we got the proper file name for the real test later on. 34836 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 34837 if test "x$test_shortpath" = x; then 34838 # Short path failed, file does not exist as specified. 34839 # Try adding .exe or .cmd 34840 if test -f "${new_path}.exe"; then 34841 input_to_shortpath="${new_path}.exe" 34842 elif test -f "${new_path}.cmd"; then 34843 input_to_shortpath="${new_path}.cmd" 34844 else 34845 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$new_path\", is invalid." >&5 34846 $as_echo "$as_me: The path of CPP, which resolves as \"$new_path\", is invalid." >&6;} 34847 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 34848 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 34849 as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5 34850 fi 34851 else 34852 input_to_shortpath="$new_path" 34853 fi 34854 34855 # Call helper function which possibly converts this using DOS-style short mode. 34856 # If so, the updated path is stored in $new_path. 34857 new_path="$input_to_shortpath" 34858 34859 input_path="$input_to_shortpath" 34860 # Check if we need to convert this using DOS-style short mode. If the path 34861 # contains just simple characters, use it. Otherwise (spaces, weird characters), 34862 # take no chances and rewrite it. 34863 # Note: m4 eats our [], so we need to use [ and ] instead. 34864 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 34865 if test "x$has_forbidden_chars" != x; then 34866 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 34867 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 34868 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 34869 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 34870 # Going to short mode and back again did indeed matter. Since short mode is 34871 # case insensitive, let's make it lowercase to improve readability. 34872 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 34873 # Now convert it back to Unix-style (cygpath) 34874 input_path=`$CYGPATH -u "$shortmode_path"` 34875 new_path="$input_path" 34876 fi 34877 fi 34878 34879 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 34880 if test "x$test_cygdrive_prefix" = x; then 34881 # As a simple fix, exclude /usr/bin since it's not a real path. 34882 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 34883 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 34884 # a path prefixed by /cygdrive for fixpath to work. 34885 new_path="$CYGWIN_ROOT_PATH$input_path" 34886 fi 34887 fi 34888 34889 # remove trailing .exe if any 34890 new_path="${new_path/%.exe/}" 34891 34892 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34893 34894 # First separate the path from the arguments. This will split at the first 34895 # space. 34896 complete="$CPP" 34897 path="${complete%% *}" 34898 tmp="$complete EOL" 34899 arguments="${tmp#* }" 34900 34901 # Input might be given as Windows format, start by converting to 34902 # unix format. 34903 new_path="$path" 34904 34905 windows_path="$new_path" 34906 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34907 unix_path=`$CYGPATH -u "$windows_path"` 34908 new_path="$unix_path" 34909 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34910 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 34911 new_path="$unix_path" 34912 fi 34913 34914 34915 # Now try to locate executable using which 34916 new_path=`$WHICH "$new_path" 2> /dev/null` 34917 34918 if test "x$new_path" = x; then 34919 # Oops. Which didn't find the executable. 34920 # The splitting of arguments from the executable at a space might have been incorrect, 34921 # since paths with space are more likely in Windows. Give it another try with the whole 34922 # argument. 34923 path="$complete" 34924 arguments="EOL" 34925 new_path="$path" 34926 34927 windows_path="$new_path" 34928 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34929 unix_path=`$CYGPATH -u "$windows_path"` 34930 new_path="$unix_path" 34931 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34932 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 34933 new_path="$unix_path" 34934 fi 34935 34936 34937 new_path=`$WHICH "$new_path" 2> /dev/null` 34938 # bat and cmd files are not always considered executable in MSYS causing which 34939 # to not find them 34940 if test "x$new_path" = x \ 34941 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 34942 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 34943 new_path="$path" 34944 34945 windows_path="$new_path" 34946 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34947 unix_path=`$CYGPATH -u "$windows_path"` 34948 new_path="$unix_path" 34949 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34950 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 34951 new_path="$unix_path" 34952 fi 34953 34954 fi 34955 34956 if test "x$new_path" = x; then 34957 # It's still not found. Now this is an unrecoverable error. 34958 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5 34959 $as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;} 34960 has_space=`$ECHO "$complete" | $GREP " "` 34961 if test "x$has_space" != x; then 34962 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 34963 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 34964 fi 34965 as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5 34966 fi 34967 fi 34968 34969 # Now new_path has a complete unix path to the binary 34970 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 34971 # Keep paths in /bin as-is, but remove trailing .exe if any 34972 new_path="${new_path/%.exe/}" 34973 # Do not save /bin paths to all_fixpath_prefixes! 34974 else 34975 # Not in mixed or Windows style, start by that. 34976 new_path=`cmd //c echo $new_path` 34977 34978 input_path="$new_path" 34979 # Check if we need to convert this using DOS-style short mode. If the path 34980 # contains just simple characters, use it. Otherwise (spaces, weird characters), 34981 # take no chances and rewrite it. 34982 # Note: m4 eats our [], so we need to use [ and ] instead. 34983 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 34984 if test "x$has_forbidden_chars" != x; then 34985 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 34986 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 34987 fi 34988 34989 # Output is in $new_path 34990 34991 windows_path="$new_path" 34992 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 34993 unix_path=`$CYGPATH -u "$windows_path"` 34994 new_path="$unix_path" 34995 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 34996 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 34997 new_path="$unix_path" 34998 fi 34999 35000 # remove trailing .exe if any 35001 new_path="${new_path/%.exe/}" 35002 35003 # Save the first 10 bytes of this path to the storage, so fixpath can work. 35004 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 35005 fi 35006 35007 else 35008 # We're on a unix platform. Hooray! :) 35009 # First separate the path from the arguments. This will split at the first 35010 # space. 35011 complete="$CPP" 35012 path="${complete%% *}" 35013 tmp="$complete EOL" 35014 arguments="${tmp#* }" 35015 35016 # Cannot rely on the command "which" here since it doesn't always work. 35017 is_absolute_path=`$ECHO "$path" | $GREP ^/` 35018 if test -z "$is_absolute_path"; then 35019 # Path to executable is not absolute. Find it. 35020 IFS_save="$IFS" 35021 IFS=: 35022 for p in $PATH; do 35023 if test -f "$p/$path" && test -x "$p/$path"; then 35024 new_path="$p/$path" 35025 break 35026 fi 35027 done 35028 IFS="$IFS_save" 35029 else 35030 # This is an absolute path, we can use it without further modifications. 35031 new_path="$path" 35032 fi 35033 35034 if test "x$new_path" = x; then 35035 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CPP, which resolves as \"$complete\", is not found." >&5 35036 $as_echo "$as_me: The path of CPP, which resolves as \"$complete\", is not found." >&6;} 35037 has_space=`$ECHO "$complete" | $GREP " "` 35038 if test "x$has_space" != x; then 35039 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 35040 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 35041 fi 35042 as_fn_error $? "Cannot locate the the path of CPP" "$LINENO" 5 35043 fi 35044 fi 35045 35046 # Now join together the path and the arguments once again 35047 if test "x$arguments" != xEOL; then 35048 new_complete="$new_path ${arguments% *}" 35049 else 35050 new_complete="$new_path" 35051 fi 35052 35053 if test "x$complete" != "x$new_complete"; then 35054 CPP="$new_complete" 35055 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CPP to \"$new_complete\"" >&5 35056 $as_echo "$as_me: Rewriting CPP to \"$new_complete\"" >&6;} 35057 fi 35058 fi 35059 35060 ac_ext=cpp 35061 ac_cpp='$CXXCPP $CPPFLAGS' 35062 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 35063 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 35064 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 35065 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to run the C++ preprocessor" >&5 35066 $as_echo_n "checking how to run the C++ preprocessor... " >&6; } 35067 if test -z "$CXXCPP"; then 35068 if ${ac_cv_prog_CXXCPP+:} false; then : 35069 $as_echo_n "(cached) " >&6 35070 else 35071 # Double quotes because CXXCPP needs to be expanded 35072 for CXXCPP in "$CXX -E" "/lib/cpp" 35073 do 35074 ac_preproc_ok=false 35075 for ac_cxx_preproc_warn_flag in '' yes 35076 do 35077 # Use a header file that comes with gcc, so configuring glibc 35078 # with a fresh cross-compiler works. 35079 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 35080 # <limits.h> exists even on freestanding compilers. 35081 # On the NeXT, cc -E runs the code through the compiler's parser, 35082 # not just through cpp. "Syntax error" is here to catch this case. 35083 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35084 /* end confdefs.h. */ 35085 #ifdef __STDC__ 35086 # include <limits.h> 35087 #else 35088 # include <assert.h> 35089 #endif 35090 Syntax error 35091 _ACEOF 35092 if ac_fn_cxx_try_cpp "$LINENO"; then : 35093 35094 else 35095 # Broken: fails on valid input. 35096 continue 35097 fi 35098 rm -f conftest.err conftest.i conftest.$ac_ext 35099 35100 # OK, works on sane cases. Now check whether nonexistent headers 35101 # can be detected and how. 35102 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35103 /* end confdefs.h. */ 35104 #include <ac_nonexistent.h> 35105 _ACEOF 35106 if ac_fn_cxx_try_cpp "$LINENO"; then : 35107 # Broken: success on invalid input. 35108 continue 35109 else 35110 # Passes both tests. 35111 ac_preproc_ok=: 35112 break 35113 fi 35114 rm -f conftest.err conftest.i conftest.$ac_ext 35115 35116 done 35117 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 35118 rm -f conftest.i conftest.err conftest.$ac_ext 35119 if $ac_preproc_ok; then : 35120 break 35121 fi 35122 35123 done 35124 ac_cv_prog_CXXCPP=$CXXCPP 35125 35126 fi 35127 CXXCPP=$ac_cv_prog_CXXCPP 35128 else 35129 ac_cv_prog_CXXCPP=$CXXCPP 35130 fi 35131 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CXXCPP" >&5 35132 $as_echo "$CXXCPP" >&6; } 35133 ac_preproc_ok=false 35134 for ac_cxx_preproc_warn_flag in '' yes 35135 do 35136 # Use a header file that comes with gcc, so configuring glibc 35137 # with a fresh cross-compiler works. 35138 # Prefer <limits.h> to <assert.h> if __STDC__ is defined, since 35139 # <limits.h> exists even on freestanding compilers. 35140 # On the NeXT, cc -E runs the code through the compiler's parser, 35141 # not just through cpp. "Syntax error" is here to catch this case. 35142 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35143 /* end confdefs.h. */ 35144 #ifdef __STDC__ 35145 # include <limits.h> 35146 #else 35147 # include <assert.h> 35148 #endif 35149 Syntax error 35150 _ACEOF 35151 if ac_fn_cxx_try_cpp "$LINENO"; then : 35152 35153 else 35154 # Broken: fails on valid input. 35155 continue 35156 fi 35157 rm -f conftest.err conftest.i conftest.$ac_ext 35158 35159 # OK, works on sane cases. Now check whether nonexistent headers 35160 # can be detected and how. 35161 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 35162 /* end confdefs.h. */ 35163 #include <ac_nonexistent.h> 35164 _ACEOF 35165 if ac_fn_cxx_try_cpp "$LINENO"; then : 35166 # Broken: success on invalid input. 35167 continue 35168 else 35169 # Passes both tests. 35170 ac_preproc_ok=: 35171 break 35172 fi 35173 rm -f conftest.err conftest.i conftest.$ac_ext 35174 35175 done 35176 # Because of `break', _AC_PREPROC_IFELSE's cleaning code was skipped. 35177 rm -f conftest.i conftest.err conftest.$ac_ext 35178 if $ac_preproc_ok; then : 35179 35180 else 35181 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 35182 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 35183 as_fn_error $? "C++ preprocessor \"$CXXCPP\" fails sanity check 35184 See \`config.log' for more details" "$LINENO" 5; } 35185 fi 35186 35187 ac_ext=cpp 35188 ac_cpp='$CXXCPP $CPPFLAGS' 35189 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 35190 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 35191 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 35192 35193 35194 # Only process if variable expands to non-empty 35195 35196 if test "x$CXXCPP" != x; then 35197 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35198 35199 # First separate the path from the arguments. This will split at the first 35200 # space. 35201 complete="$CXXCPP" 35202 path="${complete%% *}" 35203 tmp="$complete EOL" 35204 arguments="${tmp#* }" 35205 35206 # Input might be given as Windows format, start by converting to 35207 # unix format. 35208 new_path=`$CYGPATH -u "$path"` 35209 35210 # Now try to locate executable using which 35211 new_path=`$WHICH "$new_path" 2> /dev/null` 35212 # bat and cmd files are not always considered executable in cygwin causing which 35213 # to not find them 35214 if test "x$new_path" = x \ 35215 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 35216 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 35217 new_path=`$CYGPATH -u "$path"` 35218 fi 35219 if test "x$new_path" = x; then 35220 # Oops. Which didn't find the executable. 35221 # The splitting of arguments from the executable at a space might have been incorrect, 35222 # since paths with space are more likely in Windows. Give it another try with the whole 35223 # argument. 35224 path="$complete" 35225 arguments="EOL" 35226 new_path=`$CYGPATH -u "$path"` 35227 new_path=`$WHICH "$new_path" 2> /dev/null` 35228 # bat and cmd files are not always considered executable in cygwin causing which 35229 # to not find them 35230 if test "x$new_path" = x \ 35231 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 35232 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 35233 new_path=`$CYGPATH -u "$path"` 35234 fi 35235 if test "x$new_path" = x; then 35236 # It's still not found. Now this is an unrecoverable error. 35237 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5 35238 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;} 35239 has_space=`$ECHO "$complete" | $GREP " "` 35240 if test "x$has_space" != x; then 35241 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 35242 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 35243 fi 35244 as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5 35245 fi 35246 fi 35247 35248 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 35249 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 35250 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 35251 # "foo.exe" is OK but "foo" is an error. 35252 # 35253 # This test is therefore slightly more accurate than "test -f" to check for file presence. 35254 # It is also a way to make sure we got the proper file name for the real test later on. 35255 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 35256 if test "x$test_shortpath" = x; then 35257 # Short path failed, file does not exist as specified. 35258 # Try adding .exe or .cmd 35259 if test -f "${new_path}.exe"; then 35260 input_to_shortpath="${new_path}.exe" 35261 elif test -f "${new_path}.cmd"; then 35262 input_to_shortpath="${new_path}.cmd" 35263 else 35264 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$new_path\", is invalid." >&5 35265 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$new_path\", is invalid." >&6;} 35266 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 35267 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 35268 as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5 35269 fi 35270 else 35271 input_to_shortpath="$new_path" 35272 fi 35273 35274 # Call helper function which possibly converts this using DOS-style short mode. 35275 # If so, the updated path is stored in $new_path. 35276 new_path="$input_to_shortpath" 35277 35278 input_path="$input_to_shortpath" 35279 # Check if we need to convert this using DOS-style short mode. If the path 35280 # contains just simple characters, use it. Otherwise (spaces, weird characters), 35281 # take no chances and rewrite it. 35282 # Note: m4 eats our [], so we need to use [ and ] instead. 35283 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 35284 if test "x$has_forbidden_chars" != x; then 35285 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 35286 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 35287 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 35288 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 35289 # Going to short mode and back again did indeed matter. Since short mode is 35290 # case insensitive, let's make it lowercase to improve readability. 35291 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 35292 # Now convert it back to Unix-style (cygpath) 35293 input_path=`$CYGPATH -u "$shortmode_path"` 35294 new_path="$input_path" 35295 fi 35296 fi 35297 35298 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 35299 if test "x$test_cygdrive_prefix" = x; then 35300 # As a simple fix, exclude /usr/bin since it's not a real path. 35301 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 35302 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 35303 # a path prefixed by /cygdrive for fixpath to work. 35304 new_path="$CYGWIN_ROOT_PATH$input_path" 35305 fi 35306 fi 35307 35308 # remove trailing .exe if any 35309 new_path="${new_path/%.exe/}" 35310 35311 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35312 35313 # First separate the path from the arguments. This will split at the first 35314 # space. 35315 complete="$CXXCPP" 35316 path="${complete%% *}" 35317 tmp="$complete EOL" 35318 arguments="${tmp#* }" 35319 35320 # Input might be given as Windows format, start by converting to 35321 # unix format. 35322 new_path="$path" 35323 35324 windows_path="$new_path" 35325 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35326 unix_path=`$CYGPATH -u "$windows_path"` 35327 new_path="$unix_path" 35328 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35329 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 35330 new_path="$unix_path" 35331 fi 35332 35333 35334 # Now try to locate executable using which 35335 new_path=`$WHICH "$new_path" 2> /dev/null` 35336 35337 if test "x$new_path" = x; then 35338 # Oops. Which didn't find the executable. 35339 # The splitting of arguments from the executable at a space might have been incorrect, 35340 # since paths with space are more likely in Windows. Give it another try with the whole 35341 # argument. 35342 path="$complete" 35343 arguments="EOL" 35344 new_path="$path" 35345 35346 windows_path="$new_path" 35347 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35348 unix_path=`$CYGPATH -u "$windows_path"` 35349 new_path="$unix_path" 35350 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35351 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 35352 new_path="$unix_path" 35353 fi 35354 35355 35356 new_path=`$WHICH "$new_path" 2> /dev/null` 35357 # bat and cmd files are not always considered executable in MSYS causing which 35358 # to not find them 35359 if test "x$new_path" = x \ 35360 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 35361 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 35362 new_path="$path" 35363 35364 windows_path="$new_path" 35365 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35366 unix_path=`$CYGPATH -u "$windows_path"` 35367 new_path="$unix_path" 35368 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35369 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 35370 new_path="$unix_path" 35371 fi 35372 35373 fi 35374 35375 if test "x$new_path" = x; then 35376 # It's still not found. Now this is an unrecoverable error. 35377 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5 35378 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;} 35379 has_space=`$ECHO "$complete" | $GREP " "` 35380 if test "x$has_space" != x; then 35381 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 35382 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 35383 fi 35384 as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5 35385 fi 35386 fi 35387 35388 # Now new_path has a complete unix path to the binary 35389 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 35390 # Keep paths in /bin as-is, but remove trailing .exe if any 35391 new_path="${new_path/%.exe/}" 35392 # Do not save /bin paths to all_fixpath_prefixes! 35393 else 35394 # Not in mixed or Windows style, start by that. 35395 new_path=`cmd //c echo $new_path` 35396 35397 input_path="$new_path" 35398 # Check if we need to convert this using DOS-style short mode. If the path 35399 # contains just simple characters, use it. Otherwise (spaces, weird characters), 35400 # take no chances and rewrite it. 35401 # Note: m4 eats our [], so we need to use [ and ] instead. 35402 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 35403 if test "x$has_forbidden_chars" != x; then 35404 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 35405 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 35406 fi 35407 35408 # Output is in $new_path 35409 35410 windows_path="$new_path" 35411 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35412 unix_path=`$CYGPATH -u "$windows_path"` 35413 new_path="$unix_path" 35414 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35415 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 35416 new_path="$unix_path" 35417 fi 35418 35419 # remove trailing .exe if any 35420 new_path="${new_path/%.exe/}" 35421 35422 # Save the first 10 bytes of this path to the storage, so fixpath can work. 35423 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 35424 fi 35425 35426 else 35427 # We're on a unix platform. Hooray! :) 35428 # First separate the path from the arguments. This will split at the first 35429 # space. 35430 complete="$CXXCPP" 35431 path="${complete%% *}" 35432 tmp="$complete EOL" 35433 arguments="${tmp#* }" 35434 35435 # Cannot rely on the command "which" here since it doesn't always work. 35436 is_absolute_path=`$ECHO "$path" | $GREP ^/` 35437 if test -z "$is_absolute_path"; then 35438 # Path to executable is not absolute. Find it. 35439 IFS_save="$IFS" 35440 IFS=: 35441 for p in $PATH; do 35442 if test -f "$p/$path" && test -x "$p/$path"; then 35443 new_path="$p/$path" 35444 break 35445 fi 35446 done 35447 IFS="$IFS_save" 35448 else 35449 # This is an absolute path, we can use it without further modifications. 35450 new_path="$path" 35451 fi 35452 35453 if test "x$new_path" = x; then 35454 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of CXXCPP, which resolves as \"$complete\", is not found." >&5 35455 $as_echo "$as_me: The path of CXXCPP, which resolves as \"$complete\", is not found." >&6;} 35456 has_space=`$ECHO "$complete" | $GREP " "` 35457 if test "x$has_space" != x; then 35458 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 35459 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 35460 fi 35461 as_fn_error $? "Cannot locate the the path of CXXCPP" "$LINENO" 5 35462 fi 35463 fi 35464 35465 # Now join together the path and the arguments once again 35466 if test "x$arguments" != xEOL; then 35467 new_complete="$new_path ${arguments% *}" 35468 else 35469 new_complete="$new_path" 35470 fi 35471 35472 if test "x$complete" != "x$new_complete"; then 35473 CXXCPP="$new_complete" 35474 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting CXXCPP to \"$new_complete\"" >&5 35475 $as_echo "$as_me: Rewriting CXXCPP to \"$new_complete\"" >&6;} 35476 fi 35477 fi 35478 35479 35480 # 35481 # Setup the linker (LD) 35482 # 35483 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 35484 # In the Microsoft toolchain we have a separate LD command "link". 35485 # Make sure we reject /usr/bin/link (as determined in CYGWIN_LINK), which is 35486 # a cygwin program for something completely different. 35487 # Extract the first word of "link", so it can be a program name with args. 35488 set dummy link; ac_word=$2 35489 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 35490 $as_echo_n "checking for $ac_word... " >&6; } 35491 if ${ac_cv_prog_LD+:} false; then : 35492 $as_echo_n "(cached) " >&6 35493 else 35494 if test -n "$LD"; then 35495 ac_cv_prog_LD="$LD" # Let the user override the test. 35496 else 35497 ac_prog_rejected=no 35498 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 35499 for as_dir in $PATH 35500 do 35501 IFS=$as_save_IFS 35502 test -z "$as_dir" && as_dir=. 35503 for ac_exec_ext in '' $ac_executable_extensions; do 35504 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 35505 if test "$as_dir/$ac_word$ac_exec_ext" = "$CYGWIN_LINK"; then 35506 ac_prog_rejected=yes 35507 continue 35508 fi 35509 ac_cv_prog_LD="link" 35510 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 35511 break 2 35512 fi 35513 done 35514 done 35515 IFS=$as_save_IFS 35516 35517 if test $ac_prog_rejected = yes; then 35518 # We found a bogon in the path, so make sure we never use it. 35519 set dummy $ac_cv_prog_LD 35520 shift 35521 if test $# != 0; then 35522 # We chose a different compiler from the bogus one. 35523 # However, it has the same basename, so the bogon will be chosen 35524 # first if we set LD to just the basename; use the full file name. 35525 shift 35526 ac_cv_prog_LD="$as_dir/$ac_word${1+' '}$@" 35527 fi 35528 fi 35529 fi 35530 fi 35531 LD=$ac_cv_prog_LD 35532 if test -n "$LD"; then 35533 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LD" >&5 35534 $as_echo "$LD" >&6; } 35535 else 35536 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 35537 $as_echo "no" >&6; } 35538 fi 35539 35540 35541 35542 # Only process if variable expands to non-empty 35543 35544 if test "x$LD" != x; then 35545 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35546 35547 # First separate the path from the arguments. This will split at the first 35548 # space. 35549 complete="$LD" 35550 path="${complete%% *}" 35551 tmp="$complete EOL" 35552 arguments="${tmp#* }" 35553 35554 # Input might be given as Windows format, start by converting to 35555 # unix format. 35556 new_path=`$CYGPATH -u "$path"` 35557 35558 # Now try to locate executable using which 35559 new_path=`$WHICH "$new_path" 2> /dev/null` 35560 # bat and cmd files are not always considered executable in cygwin causing which 35561 # to not find them 35562 if test "x$new_path" = x \ 35563 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 35564 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 35565 new_path=`$CYGPATH -u "$path"` 35566 fi 35567 if test "x$new_path" = x; then 35568 # Oops. Which didn't find the executable. 35569 # The splitting of arguments from the executable at a space might have been incorrect, 35570 # since paths with space are more likely in Windows. Give it another try with the whole 35571 # argument. 35572 path="$complete" 35573 arguments="EOL" 35574 new_path=`$CYGPATH -u "$path"` 35575 new_path=`$WHICH "$new_path" 2> /dev/null` 35576 # bat and cmd files are not always considered executable in cygwin causing which 35577 # to not find them 35578 if test "x$new_path" = x \ 35579 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 35580 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 35581 new_path=`$CYGPATH -u "$path"` 35582 fi 35583 if test "x$new_path" = x; then 35584 # It's still not found. Now this is an unrecoverable error. 35585 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$complete\", is not found." >&5 35586 $as_echo "$as_me: The path of LD, which resolves as \"$complete\", is not found." >&6;} 35587 has_space=`$ECHO "$complete" | $GREP " "` 35588 if test "x$has_space" != x; then 35589 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 35590 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 35591 fi 35592 as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5 35593 fi 35594 fi 35595 35596 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 35597 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 35598 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 35599 # "foo.exe" is OK but "foo" is an error. 35600 # 35601 # This test is therefore slightly more accurate than "test -f" to check for file presence. 35602 # It is also a way to make sure we got the proper file name for the real test later on. 35603 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 35604 if test "x$test_shortpath" = x; then 35605 # Short path failed, file does not exist as specified. 35606 # Try adding .exe or .cmd 35607 if test -f "${new_path}.exe"; then 35608 input_to_shortpath="${new_path}.exe" 35609 elif test -f "${new_path}.cmd"; then 35610 input_to_shortpath="${new_path}.cmd" 35611 else 35612 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$new_path\", is invalid." >&5 35613 $as_echo "$as_me: The path of LD, which resolves as \"$new_path\", is invalid." >&6;} 35614 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 35615 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 35616 as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5 35617 fi 35618 else 35619 input_to_shortpath="$new_path" 35620 fi 35621 35622 # Call helper function which possibly converts this using DOS-style short mode. 35623 # If so, the updated path is stored in $new_path. 35624 new_path="$input_to_shortpath" 35625 35626 input_path="$input_to_shortpath" 35627 # Check if we need to convert this using DOS-style short mode. If the path 35628 # contains just simple characters, use it. Otherwise (spaces, weird characters), 35629 # take no chances and rewrite it. 35630 # Note: m4 eats our [], so we need to use [ and ] instead. 35631 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 35632 if test "x$has_forbidden_chars" != x; then 35633 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 35634 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 35635 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 35636 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 35637 # Going to short mode and back again did indeed matter. Since short mode is 35638 # case insensitive, let's make it lowercase to improve readability. 35639 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 35640 # Now convert it back to Unix-style (cygpath) 35641 input_path=`$CYGPATH -u "$shortmode_path"` 35642 new_path="$input_path" 35643 fi 35644 fi 35645 35646 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 35647 if test "x$test_cygdrive_prefix" = x; then 35648 # As a simple fix, exclude /usr/bin since it's not a real path. 35649 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 35650 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 35651 # a path prefixed by /cygdrive for fixpath to work. 35652 new_path="$CYGWIN_ROOT_PATH$input_path" 35653 fi 35654 fi 35655 35656 # remove trailing .exe if any 35657 new_path="${new_path/%.exe/}" 35658 35659 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35660 35661 # First separate the path from the arguments. This will split at the first 35662 # space. 35663 complete="$LD" 35664 path="${complete%% *}" 35665 tmp="$complete EOL" 35666 arguments="${tmp#* }" 35667 35668 # Input might be given as Windows format, start by converting to 35669 # unix format. 35670 new_path="$path" 35671 35672 windows_path="$new_path" 35673 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35674 unix_path=`$CYGPATH -u "$windows_path"` 35675 new_path="$unix_path" 35676 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35677 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 35678 new_path="$unix_path" 35679 fi 35680 35681 35682 # Now try to locate executable using which 35683 new_path=`$WHICH "$new_path" 2> /dev/null` 35684 35685 if test "x$new_path" = x; then 35686 # Oops. Which didn't find the executable. 35687 # The splitting of arguments from the executable at a space might have been incorrect, 35688 # since paths with space are more likely in Windows. Give it another try with the whole 35689 # argument. 35690 path="$complete" 35691 arguments="EOL" 35692 new_path="$path" 35693 35694 windows_path="$new_path" 35695 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35696 unix_path=`$CYGPATH -u "$windows_path"` 35697 new_path="$unix_path" 35698 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35699 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 35700 new_path="$unix_path" 35701 fi 35702 35703 35704 new_path=`$WHICH "$new_path" 2> /dev/null` 35705 # bat and cmd files are not always considered executable in MSYS causing which 35706 # to not find them 35707 if test "x$new_path" = x \ 35708 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 35709 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 35710 new_path="$path" 35711 35712 windows_path="$new_path" 35713 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35714 unix_path=`$CYGPATH -u "$windows_path"` 35715 new_path="$unix_path" 35716 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35717 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 35718 new_path="$unix_path" 35719 fi 35720 35721 fi 35722 35723 if test "x$new_path" = x; then 35724 # It's still not found. Now this is an unrecoverable error. 35725 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$complete\", is not found." >&5 35726 $as_echo "$as_me: The path of LD, which resolves as \"$complete\", is not found." >&6;} 35727 has_space=`$ECHO "$complete" | $GREP " "` 35728 if test "x$has_space" != x; then 35729 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 35730 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 35731 fi 35732 as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5 35733 fi 35734 fi 35735 35736 # Now new_path has a complete unix path to the binary 35737 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 35738 # Keep paths in /bin as-is, but remove trailing .exe if any 35739 new_path="${new_path/%.exe/}" 35740 # Do not save /bin paths to all_fixpath_prefixes! 35741 else 35742 # Not in mixed or Windows style, start by that. 35743 new_path=`cmd //c echo $new_path` 35744 35745 input_path="$new_path" 35746 # Check if we need to convert this using DOS-style short mode. If the path 35747 # contains just simple characters, use it. Otherwise (spaces, weird characters), 35748 # take no chances and rewrite it. 35749 # Note: m4 eats our [], so we need to use [ and ] instead. 35750 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 35751 if test "x$has_forbidden_chars" != x; then 35752 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 35753 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 35754 fi 35755 35756 # Output is in $new_path 35757 35758 windows_path="$new_path" 35759 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 35760 unix_path=`$CYGPATH -u "$windows_path"` 35761 new_path="$unix_path" 35762 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 35763 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 35764 new_path="$unix_path" 35765 fi 35766 35767 # remove trailing .exe if any 35768 new_path="${new_path/%.exe/}" 35769 35770 # Save the first 10 bytes of this path to the storage, so fixpath can work. 35771 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 35772 fi 35773 35774 else 35775 # We're on a unix platform. Hooray! :) 35776 # First separate the path from the arguments. This will split at the first 35777 # space. 35778 complete="$LD" 35779 path="${complete%% *}" 35780 tmp="$complete EOL" 35781 arguments="${tmp#* }" 35782 35783 # Cannot rely on the command "which" here since it doesn't always work. 35784 is_absolute_path=`$ECHO "$path" | $GREP ^/` 35785 if test -z "$is_absolute_path"; then 35786 # Path to executable is not absolute. Find it. 35787 IFS_save="$IFS" 35788 IFS=: 35789 for p in $PATH; do 35790 if test -f "$p/$path" && test -x "$p/$path"; then 35791 new_path="$p/$path" 35792 break 35793 fi 35794 done 35795 IFS="$IFS_save" 35796 else 35797 # This is an absolute path, we can use it without further modifications. 35798 new_path="$path" 35799 fi 35800 35801 if test "x$new_path" = x; then 35802 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LD, which resolves as \"$complete\", is not found." >&5 35803 $as_echo "$as_me: The path of LD, which resolves as \"$complete\", is not found." >&6;} 35804 has_space=`$ECHO "$complete" | $GREP " "` 35805 if test "x$has_space" != x; then 35806 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 35807 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 35808 fi 35809 as_fn_error $? "Cannot locate the the path of LD" "$LINENO" 5 35810 fi 35811 fi 35812 35813 # Now join together the path and the arguments once again 35814 if test "x$arguments" != xEOL; then 35815 new_complete="$new_path ${arguments% *}" 35816 else 35817 new_complete="$new_path" 35818 fi 35819 35820 if test "x$complete" != "x$new_complete"; then 35821 LD="$new_complete" 35822 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting LD to \"$new_complete\"" >&5 35823 $as_echo "$as_me: Rewriting LD to \"$new_complete\"" >&6;} 35824 fi 35825 fi 35826 35827 # Verify that we indeed succeeded with this trick. 35828 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if the found link.exe is actually the Visual Studio linker" >&5 35829 $as_echo_n "checking if the found link.exe is actually the Visual Studio linker... " >&6; } 35830 "$LD" --version > /dev/null 35831 if test $? -eq 0 ; then 35832 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 35833 $as_echo "no" >&6; } 35834 as_fn_error $? "This is the Cygwin link tool. Please check your PATH and rerun configure." "$LINENO" 5 35835 else 35836 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 35837 $as_echo "yes" >&6; } 35838 fi 35839 LDCXX="$LD" 35840 else 35841 # All other toolchains use the compiler to link. 35842 LD="$CC" 35843 LDCXX="$CXX" 35844 fi 35845 35846 # FIXME: it should be CXXLD, according to standard (cf CXXCPP) 35847 35848 35849 # 35850 # Setup the assembler (AS) 35851 # 35852 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 35853 # FIXME: should this really be solaris, or solstudio? 35854 35855 35856 # Publish this variable in the help. 35857 35858 35859 if [ -z "${AS+x}" ]; then 35860 # The variable is not set by user, try to locate tool using the code snippet 35861 for ac_prog in as 35862 do 35863 # Extract the first word of "$ac_prog", so it can be a program name with args. 35864 set dummy $ac_prog; ac_word=$2 35865 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 35866 $as_echo_n "checking for $ac_word... " >&6; } 35867 if ${ac_cv_path_AS+:} false; then : 35868 $as_echo_n "(cached) " >&6 35869 else 35870 case $AS in 35871 [\\/]* | ?:[\\/]*) 35872 ac_cv_path_AS="$AS" # Let the user override the test with a path. 35873 ;; 35874 *) 35875 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 35876 for as_dir in $PATH 35877 do 35878 IFS=$as_save_IFS 35879 test -z "$as_dir" && as_dir=. 35880 for ac_exec_ext in '' $ac_executable_extensions; do 35881 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 35882 ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext" 35883 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 35884 break 2 35885 fi 35886 done 35887 done 35888 IFS=$as_save_IFS 35889 35890 ;; 35891 esac 35892 fi 35893 AS=$ac_cv_path_AS 35894 if test -n "$AS"; then 35895 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5 35896 $as_echo "$AS" >&6; } 35897 else 35898 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 35899 $as_echo "no" >&6; } 35900 fi 35901 35902 35903 test -n "$AS" && break 35904 done 35905 35906 else 35907 # The variable is set, but is it from the command line or the environment? 35908 35909 # Try to remove the string !AS! from our list. 35910 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AS!/} 35911 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 35912 # If it failed, the variable was not from the command line. Ignore it, 35913 # but warn the user (except for BASH, which is always set by the calling BASH). 35914 if test "xAS" != xBASH; then 35915 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AS from the environment. Use command line variables instead." >&5 35916 $as_echo "$as_me: WARNING: Ignoring value of AS from the environment. Use command line variables instead." >&2;} 35917 fi 35918 # Try to locate tool using the code snippet 35919 for ac_prog in as 35920 do 35921 # Extract the first word of "$ac_prog", so it can be a program name with args. 35922 set dummy $ac_prog; ac_word=$2 35923 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 35924 $as_echo_n "checking for $ac_word... " >&6; } 35925 if ${ac_cv_path_AS+:} false; then : 35926 $as_echo_n "(cached) " >&6 35927 else 35928 case $AS in 35929 [\\/]* | ?:[\\/]*) 35930 ac_cv_path_AS="$AS" # Let the user override the test with a path. 35931 ;; 35932 *) 35933 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 35934 for as_dir in $PATH 35935 do 35936 IFS=$as_save_IFS 35937 test -z "$as_dir" && as_dir=. 35938 for ac_exec_ext in '' $ac_executable_extensions; do 35939 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 35940 ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext" 35941 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 35942 break 2 35943 fi 35944 done 35945 done 35946 IFS=$as_save_IFS 35947 35948 ;; 35949 esac 35950 fi 35951 AS=$ac_cv_path_AS 35952 if test -n "$AS"; then 35953 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5 35954 $as_echo "$AS" >&6; } 35955 else 35956 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 35957 $as_echo "no" >&6; } 35958 fi 35959 35960 35961 test -n "$AS" && break 35962 done 35963 35964 else 35965 # If it succeeded, then it was overridden by the user. We will use it 35966 # for the tool. 35967 35968 # First remove it from the list of overridden variables, so we can test 35969 # for unknown variables in the end. 35970 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 35971 35972 # Check if we try to supply an empty value 35973 if test "x$AS" = x; then 35974 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool AS= (no value)" >&5 35975 $as_echo "$as_me: Setting user supplied tool AS= (no value)" >&6;} 35976 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AS" >&5 35977 $as_echo_n "checking for AS... " >&6; } 35978 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 35979 $as_echo "disabled" >&6; } 35980 else 35981 # Check if the provided tool contains a complete path. 35982 tool_specified="$AS" 35983 tool_basename="${tool_specified##*/}" 35984 if test "x$tool_basename" = "x$tool_specified"; then 35985 # A command without a complete path is provided, search $PATH. 35986 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AS=$tool_basename" >&5 35987 $as_echo "$as_me: Will search for user supplied tool AS=$tool_basename" >&6;} 35988 # Extract the first word of "$tool_basename", so it can be a program name with args. 35989 set dummy $tool_basename; ac_word=$2 35990 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 35991 $as_echo_n "checking for $ac_word... " >&6; } 35992 if ${ac_cv_path_AS+:} false; then : 35993 $as_echo_n "(cached) " >&6 35994 else 35995 case $AS in 35996 [\\/]* | ?:[\\/]*) 35997 ac_cv_path_AS="$AS" # Let the user override the test with a path. 35998 ;; 35999 *) 36000 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 36001 for as_dir in $PATH 36002 do 36003 IFS=$as_save_IFS 36004 test -z "$as_dir" && as_dir=. 36005 for ac_exec_ext in '' $ac_executable_extensions; do 36006 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 36007 ac_cv_path_AS="$as_dir/$ac_word$ac_exec_ext" 36008 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 36009 break 2 36010 fi 36011 done 36012 done 36013 IFS=$as_save_IFS 36014 36015 ;; 36016 esac 36017 fi 36018 AS=$ac_cv_path_AS 36019 if test -n "$AS"; then 36020 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AS" >&5 36021 $as_echo "$AS" >&6; } 36022 else 36023 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 36024 $as_echo "no" >&6; } 36025 fi 36026 36027 36028 if test "x$AS" = x; then 36029 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 36030 fi 36031 else 36032 # Otherwise we believe it is a complete path. Use it as it is. 36033 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AS=$tool_specified" >&5 36034 $as_echo "$as_me: Will use user supplied tool AS=$tool_specified" >&6;} 36035 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AS" >&5 36036 $as_echo_n "checking for AS... " >&6; } 36037 if test ! -x "$tool_specified"; then 36038 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 36039 $as_echo "not found" >&6; } 36040 as_fn_error $? "User supplied tool AS=$tool_specified does not exist or is not executable" "$LINENO" 5 36041 fi 36042 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 36043 $as_echo "$tool_specified" >&6; } 36044 fi 36045 fi 36046 fi 36047 36048 fi 36049 36050 36051 36052 # Only process if variable expands to non-empty 36053 36054 if test "x$AS" != x; then 36055 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36056 36057 # First separate the path from the arguments. This will split at the first 36058 # space. 36059 complete="$AS" 36060 path="${complete%% *}" 36061 tmp="$complete EOL" 36062 arguments="${tmp#* }" 36063 36064 # Input might be given as Windows format, start by converting to 36065 # unix format. 36066 new_path=`$CYGPATH -u "$path"` 36067 36068 # Now try to locate executable using which 36069 new_path=`$WHICH "$new_path" 2> /dev/null` 36070 # bat and cmd files are not always considered executable in cygwin causing which 36071 # to not find them 36072 if test "x$new_path" = x \ 36073 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36074 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36075 new_path=`$CYGPATH -u "$path"` 36076 fi 36077 if test "x$new_path" = x; then 36078 # Oops. Which didn't find the executable. 36079 # The splitting of arguments from the executable at a space might have been incorrect, 36080 # since paths with space are more likely in Windows. Give it another try with the whole 36081 # argument. 36082 path="$complete" 36083 arguments="EOL" 36084 new_path=`$CYGPATH -u "$path"` 36085 new_path=`$WHICH "$new_path" 2> /dev/null` 36086 # bat and cmd files are not always considered executable in cygwin causing which 36087 # to not find them 36088 if test "x$new_path" = x \ 36089 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36090 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36091 new_path=`$CYGPATH -u "$path"` 36092 fi 36093 if test "x$new_path" = x; then 36094 # It's still not found. Now this is an unrecoverable error. 36095 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5 36096 $as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;} 36097 has_space=`$ECHO "$complete" | $GREP " "` 36098 if test "x$has_space" != x; then 36099 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 36100 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 36101 fi 36102 as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5 36103 fi 36104 fi 36105 36106 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 36107 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 36108 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 36109 # "foo.exe" is OK but "foo" is an error. 36110 # 36111 # This test is therefore slightly more accurate than "test -f" to check for file presence. 36112 # It is also a way to make sure we got the proper file name for the real test later on. 36113 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 36114 if test "x$test_shortpath" = x; then 36115 # Short path failed, file does not exist as specified. 36116 # Try adding .exe or .cmd 36117 if test -f "${new_path}.exe"; then 36118 input_to_shortpath="${new_path}.exe" 36119 elif test -f "${new_path}.cmd"; then 36120 input_to_shortpath="${new_path}.cmd" 36121 else 36122 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$new_path\", is invalid." >&5 36123 $as_echo "$as_me: The path of AS, which resolves as \"$new_path\", is invalid." >&6;} 36124 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 36125 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 36126 as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5 36127 fi 36128 else 36129 input_to_shortpath="$new_path" 36130 fi 36131 36132 # Call helper function which possibly converts this using DOS-style short mode. 36133 # If so, the updated path is stored in $new_path. 36134 new_path="$input_to_shortpath" 36135 36136 input_path="$input_to_shortpath" 36137 # Check if we need to convert this using DOS-style short mode. If the path 36138 # contains just simple characters, use it. Otherwise (spaces, weird characters), 36139 # take no chances and rewrite it. 36140 # Note: m4 eats our [], so we need to use [ and ] instead. 36141 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 36142 if test "x$has_forbidden_chars" != x; then 36143 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 36144 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 36145 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 36146 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 36147 # Going to short mode and back again did indeed matter. Since short mode is 36148 # case insensitive, let's make it lowercase to improve readability. 36149 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 36150 # Now convert it back to Unix-style (cygpath) 36151 input_path=`$CYGPATH -u "$shortmode_path"` 36152 new_path="$input_path" 36153 fi 36154 fi 36155 36156 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 36157 if test "x$test_cygdrive_prefix" = x; then 36158 # As a simple fix, exclude /usr/bin since it's not a real path. 36159 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 36160 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 36161 # a path prefixed by /cygdrive for fixpath to work. 36162 new_path="$CYGWIN_ROOT_PATH$input_path" 36163 fi 36164 fi 36165 36166 # remove trailing .exe if any 36167 new_path="${new_path/%.exe/}" 36168 36169 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36170 36171 # First separate the path from the arguments. This will split at the first 36172 # space. 36173 complete="$AS" 36174 path="${complete%% *}" 36175 tmp="$complete EOL" 36176 arguments="${tmp#* }" 36177 36178 # Input might be given as Windows format, start by converting to 36179 # unix format. 36180 new_path="$path" 36181 36182 windows_path="$new_path" 36183 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36184 unix_path=`$CYGPATH -u "$windows_path"` 36185 new_path="$unix_path" 36186 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36187 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36188 new_path="$unix_path" 36189 fi 36190 36191 36192 # Now try to locate executable using which 36193 new_path=`$WHICH "$new_path" 2> /dev/null` 36194 36195 if test "x$new_path" = x; then 36196 # Oops. Which didn't find the executable. 36197 # The splitting of arguments from the executable at a space might have been incorrect, 36198 # since paths with space are more likely in Windows. Give it another try with the whole 36199 # argument. 36200 path="$complete" 36201 arguments="EOL" 36202 new_path="$path" 36203 36204 windows_path="$new_path" 36205 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36206 unix_path=`$CYGPATH -u "$windows_path"` 36207 new_path="$unix_path" 36208 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36209 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36210 new_path="$unix_path" 36211 fi 36212 36213 36214 new_path=`$WHICH "$new_path" 2> /dev/null` 36215 # bat and cmd files are not always considered executable in MSYS causing which 36216 # to not find them 36217 if test "x$new_path" = x \ 36218 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 36219 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 36220 new_path="$path" 36221 36222 windows_path="$new_path" 36223 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36224 unix_path=`$CYGPATH -u "$windows_path"` 36225 new_path="$unix_path" 36226 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36227 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36228 new_path="$unix_path" 36229 fi 36230 36231 fi 36232 36233 if test "x$new_path" = x; then 36234 # It's still not found. Now this is an unrecoverable error. 36235 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5 36236 $as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;} 36237 has_space=`$ECHO "$complete" | $GREP " "` 36238 if test "x$has_space" != x; then 36239 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 36240 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 36241 fi 36242 as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5 36243 fi 36244 fi 36245 36246 # Now new_path has a complete unix path to the binary 36247 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 36248 # Keep paths in /bin as-is, but remove trailing .exe if any 36249 new_path="${new_path/%.exe/}" 36250 # Do not save /bin paths to all_fixpath_prefixes! 36251 else 36252 # Not in mixed or Windows style, start by that. 36253 new_path=`cmd //c echo $new_path` 36254 36255 input_path="$new_path" 36256 # Check if we need to convert this using DOS-style short mode. If the path 36257 # contains just simple characters, use it. Otherwise (spaces, weird characters), 36258 # take no chances and rewrite it. 36259 # Note: m4 eats our [], so we need to use [ and ] instead. 36260 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 36261 if test "x$has_forbidden_chars" != x; then 36262 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 36263 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 36264 fi 36265 36266 # Output is in $new_path 36267 36268 windows_path="$new_path" 36269 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 36270 unix_path=`$CYGPATH -u "$windows_path"` 36271 new_path="$unix_path" 36272 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 36273 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 36274 new_path="$unix_path" 36275 fi 36276 36277 # remove trailing .exe if any 36278 new_path="${new_path/%.exe/}" 36279 36280 # Save the first 10 bytes of this path to the storage, so fixpath can work. 36281 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 36282 fi 36283 36284 else 36285 # We're on a unix platform. Hooray! :) 36286 # First separate the path from the arguments. This will split at the first 36287 # space. 36288 complete="$AS" 36289 path="${complete%% *}" 36290 tmp="$complete EOL" 36291 arguments="${tmp#* }" 36292 36293 # Cannot rely on the command "which" here since it doesn't always work. 36294 is_absolute_path=`$ECHO "$path" | $GREP ^/` 36295 if test -z "$is_absolute_path"; then 36296 # Path to executable is not absolute. Find it. 36297 IFS_save="$IFS" 36298 IFS=: 36299 for p in $PATH; do 36300 if test -f "$p/$path" && test -x "$p/$path"; then 36301 new_path="$p/$path" 36302 break 36303 fi 36304 done 36305 IFS="$IFS_save" 36306 else 36307 # This is an absolute path, we can use it without further modifications. 36308 new_path="$path" 36309 fi 36310 36311 if test "x$new_path" = x; then 36312 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AS, which resolves as \"$complete\", is not found." >&5 36313 $as_echo "$as_me: The path of AS, which resolves as \"$complete\", is not found." >&6;} 36314 has_space=`$ECHO "$complete" | $GREP " "` 36315 if test "x$has_space" != x; then 36316 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 36317 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 36318 fi 36319 as_fn_error $? "Cannot locate the the path of AS" "$LINENO" 5 36320 fi 36321 fi 36322 36323 # Now join together the path and the arguments once again 36324 if test "x$arguments" != xEOL; then 36325 new_complete="$new_path ${arguments% *}" 36326 else 36327 new_complete="$new_path" 36328 fi 36329 36330 if test "x$complete" != "x$new_complete"; then 36331 AS="$new_complete" 36332 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting AS to \"$new_complete\"" >&5 36333 $as_echo "$as_me: Rewriting AS to \"$new_complete\"" >&6;} 36334 fi 36335 fi 36336 36337 else 36338 # FIXME: is this correct for microsoft? 36339 AS="$CC -c" 36340 fi 36341 36342 36343 # 36344 # Setup the archiver (AR) 36345 # 36346 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 36347 # The corresponding ar tool is lib.exe (used to create static libraries) 36348 # Extract the first word of "lib", so it can be a program name with args. 36349 set dummy lib; ac_word=$2 36350 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 36351 $as_echo_n "checking for $ac_word... " >&6; } 36352 if ${ac_cv_prog_AR+:} false; then : 36353 $as_echo_n "(cached) " >&6 36354 else 36355 if test -n "$AR"; then 36356 ac_cv_prog_AR="$AR" # Let the user override the test. 36357 else 36358 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 36359 for as_dir in $PATH 36360 do 36361 IFS=$as_save_IFS 36362 test -z "$as_dir" && as_dir=. 36363 for ac_exec_ext in '' $ac_executable_extensions; do 36364 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 36365 ac_cv_prog_AR="lib" 36366 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 36367 break 2 36368 fi 36369 done 36370 done 36371 IFS=$as_save_IFS 36372 36373 fi 36374 fi 36375 AR=$ac_cv_prog_AR 36376 if test -n "$AR"; then 36377 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 36378 $as_echo "$AR" >&6; } 36379 else 36380 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 36381 $as_echo "no" >&6; } 36382 fi 36383 36384 36385 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 36386 36387 36388 # Publish this variable in the help. 36389 36390 36391 if [ -z "${AR+x}" ]; then 36392 # The variable is not set by user, try to locate tool using the code snippet 36393 if test -n "$ac_tool_prefix"; then 36394 for ac_prog in ar gcc-ar 36395 do 36396 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 36397 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 36398 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 36399 $as_echo_n "checking for $ac_word... " >&6; } 36400 if ${ac_cv_prog_AR+:} false; then : 36401 $as_echo_n "(cached) " >&6 36402 else 36403 if test -n "$AR"; then 36404 ac_cv_prog_AR="$AR" # Let the user override the test. 36405 else 36406 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 36407 for as_dir in $PATH 36408 do 36409 IFS=$as_save_IFS 36410 test -z "$as_dir" && as_dir=. 36411 for ac_exec_ext in '' $ac_executable_extensions; do 36412 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 36413 ac_cv_prog_AR="$ac_tool_prefix$ac_prog" 36414 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 36415 break 2 36416 fi 36417 done 36418 done 36419 IFS=$as_save_IFS 36420 36421 fi 36422 fi 36423 AR=$ac_cv_prog_AR 36424 if test -n "$AR"; then 36425 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 36426 $as_echo "$AR" >&6; } 36427 else 36428 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 36429 $as_echo "no" >&6; } 36430 fi 36431 36432 36433 test -n "$AR" && break 36434 done 36435 fi 36436 if test -z "$AR"; then 36437 ac_ct_AR=$AR 36438 for ac_prog in ar gcc-ar 36439 do 36440 # Extract the first word of "$ac_prog", so it can be a program name with args. 36441 set dummy $ac_prog; ac_word=$2 36442 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 36443 $as_echo_n "checking for $ac_word... " >&6; } 36444 if ${ac_cv_prog_ac_ct_AR+:} false; then : 36445 $as_echo_n "(cached) " >&6 36446 else 36447 if test -n "$ac_ct_AR"; then 36448 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. 36449 else 36450 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 36451 for as_dir in $PATH 36452 do 36453 IFS=$as_save_IFS 36454 test -z "$as_dir" && as_dir=. 36455 for ac_exec_ext in '' $ac_executable_extensions; do 36456 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 36457 ac_cv_prog_ac_ct_AR="$ac_prog" 36458 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 36459 break 2 36460 fi 36461 done 36462 done 36463 IFS=$as_save_IFS 36464 36465 fi 36466 fi 36467 ac_ct_AR=$ac_cv_prog_ac_ct_AR 36468 if test -n "$ac_ct_AR"; then 36469 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 36470 $as_echo "$ac_ct_AR" >&6; } 36471 else 36472 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 36473 $as_echo "no" >&6; } 36474 fi 36475 36476 36477 test -n "$ac_ct_AR" && break 36478 done 36479 36480 if test "x$ac_ct_AR" = x; then 36481 AR="" 36482 else 36483 case $cross_compiling:$ac_tool_warned in 36484 yes:) 36485 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 36486 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 36487 ac_tool_warned=yes ;; 36488 esac 36489 AR=$ac_ct_AR 36490 fi 36491 fi 36492 36493 else 36494 # The variable is set, but is it from the command line or the environment? 36495 36496 # Try to remove the string !AR! from our list. 36497 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AR!/} 36498 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 36499 # If it failed, the variable was not from the command line. Ignore it, 36500 # but warn the user (except for BASH, which is always set by the calling BASH). 36501 if test "xAR" != xBASH; then 36502 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&5 36503 $as_echo "$as_me: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&2;} 36504 fi 36505 # Try to locate tool using the code snippet 36506 if test -n "$ac_tool_prefix"; then 36507 for ac_prog in ar gcc-ar 36508 do 36509 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 36510 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 36511 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 36512 $as_echo_n "checking for $ac_word... " >&6; } 36513 if ${ac_cv_prog_AR+:} false; then : 36514 $as_echo_n "(cached) " >&6 36515 else 36516 if test -n "$AR"; then 36517 ac_cv_prog_AR="$AR" # Let the user override the test. 36518 else 36519 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 36520 for as_dir in $PATH 36521 do 36522 IFS=$as_save_IFS 36523 test -z "$as_dir" && as_dir=. 36524 for ac_exec_ext in '' $ac_executable_extensions; do 36525 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 36526 ac_cv_prog_AR="$ac_tool_prefix$ac_prog" 36527 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 36528 break 2 36529 fi 36530 done 36531 done 36532 IFS=$as_save_IFS 36533 36534 fi 36535 fi 36536 AR=$ac_cv_prog_AR 36537 if test -n "$AR"; then 36538 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 36539 $as_echo "$AR" >&6; } 36540 else 36541 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 36542 $as_echo "no" >&6; } 36543 fi 36544 36545 36546 test -n "$AR" && break 36547 done 36548 fi 36549 if test -z "$AR"; then 36550 ac_ct_AR=$AR 36551 for ac_prog in ar gcc-ar 36552 do 36553 # Extract the first word of "$ac_prog", so it can be a program name with args. 36554 set dummy $ac_prog; ac_word=$2 36555 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 36556 $as_echo_n "checking for $ac_word... " >&6; } 36557 if ${ac_cv_prog_ac_ct_AR+:} false; then : 36558 $as_echo_n "(cached) " >&6 36559 else 36560 if test -n "$ac_ct_AR"; then 36561 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. 36562 else 36563 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 36564 for as_dir in $PATH 36565 do 36566 IFS=$as_save_IFS 36567 test -z "$as_dir" && as_dir=. 36568 for ac_exec_ext in '' $ac_executable_extensions; do 36569 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 36570 ac_cv_prog_ac_ct_AR="$ac_prog" 36571 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 36572 break 2 36573 fi 36574 done 36575 done 36576 IFS=$as_save_IFS 36577 36578 fi 36579 fi 36580 ac_ct_AR=$ac_cv_prog_ac_ct_AR 36581 if test -n "$ac_ct_AR"; then 36582 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 36583 $as_echo "$ac_ct_AR" >&6; } 36584 else 36585 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 36586 $as_echo "no" >&6; } 36587 fi 36588 36589 36590 test -n "$ac_ct_AR" && break 36591 done 36592 36593 if test "x$ac_ct_AR" = x; then 36594 AR="" 36595 else 36596 case $cross_compiling:$ac_tool_warned in 36597 yes:) 36598 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 36599 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 36600 ac_tool_warned=yes ;; 36601 esac 36602 AR=$ac_ct_AR 36603 fi 36604 fi 36605 36606 else 36607 # If it succeeded, then it was overridden by the user. We will use it 36608 # for the tool. 36609 36610 # First remove it from the list of overridden variables, so we can test 36611 # for unknown variables in the end. 36612 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 36613 36614 # Check if we try to supply an empty value 36615 if test "x$AR" = x; then 36616 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool AR= (no value)" >&5 36617 $as_echo "$as_me: Setting user supplied tool AR= (no value)" >&6;} 36618 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AR" >&5 36619 $as_echo_n "checking for AR... " >&6; } 36620 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 36621 $as_echo "disabled" >&6; } 36622 else 36623 # Check if the provided tool contains a complete path. 36624 tool_specified="$AR" 36625 tool_basename="${tool_specified##*/}" 36626 if test "x$tool_basename" = "x$tool_specified"; then 36627 # A command without a complete path is provided, search $PATH. 36628 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AR=$tool_basename" >&5 36629 $as_echo "$as_me: Will search for user supplied tool AR=$tool_basename" >&6;} 36630 # Extract the first word of "$tool_basename", so it can be a program name with args. 36631 set dummy $tool_basename; ac_word=$2 36632 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 36633 $as_echo_n "checking for $ac_word... " >&6; } 36634 if ${ac_cv_path_AR+:} false; then : 36635 $as_echo_n "(cached) " >&6 36636 else 36637 case $AR in 36638 [\\/]* | ?:[\\/]*) 36639 ac_cv_path_AR="$AR" # Let the user override the test with a path. 36640 ;; 36641 *) 36642 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 36643 for as_dir in $PATH 36644 do 36645 IFS=$as_save_IFS 36646 test -z "$as_dir" && as_dir=. 36647 for ac_exec_ext in '' $ac_executable_extensions; do 36648 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 36649 ac_cv_path_AR="$as_dir/$ac_word$ac_exec_ext" 36650 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 36651 break 2 36652 fi 36653 done 36654 done 36655 IFS=$as_save_IFS 36656 36657 ;; 36658 esac 36659 fi 36660 AR=$ac_cv_path_AR 36661 if test -n "$AR"; then 36662 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 36663 $as_echo "$AR" >&6; } 36664 else 36665 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 36666 $as_echo "no" >&6; } 36667 fi 36668 36669 36670 if test "x$AR" = x; then 36671 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 36672 fi 36673 else 36674 # Otherwise we believe it is a complete path. Use it as it is. 36675 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AR=$tool_specified" >&5 36676 $as_echo "$as_me: Will use user supplied tool AR=$tool_specified" >&6;} 36677 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AR" >&5 36678 $as_echo_n "checking for AR... " >&6; } 36679 if test ! -x "$tool_specified"; then 36680 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 36681 $as_echo "not found" >&6; } 36682 as_fn_error $? "User supplied tool AR=$tool_specified does not exist or is not executable" "$LINENO" 5 36683 fi 36684 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 36685 $as_echo "$tool_specified" >&6; } 36686 fi 36687 fi 36688 fi 36689 36690 fi 36691 36692 36693 else 36694 36695 36696 # Publish this variable in the help. 36697 36698 36699 if [ -z "${AR+x}" ]; then 36700 # The variable is not set by user, try to locate tool using the code snippet 36701 if test -n "$ac_tool_prefix"; then 36702 for ac_prog in ar 36703 do 36704 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 36705 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 36706 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 36707 $as_echo_n "checking for $ac_word... " >&6; } 36708 if ${ac_cv_prog_AR+:} false; then : 36709 $as_echo_n "(cached) " >&6 36710 else 36711 if test -n "$AR"; then 36712 ac_cv_prog_AR="$AR" # Let the user override the test. 36713 else 36714 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 36715 for as_dir in $PATH 36716 do 36717 IFS=$as_save_IFS 36718 test -z "$as_dir" && as_dir=. 36719 for ac_exec_ext in '' $ac_executable_extensions; do 36720 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 36721 ac_cv_prog_AR="$ac_tool_prefix$ac_prog" 36722 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 36723 break 2 36724 fi 36725 done 36726 done 36727 IFS=$as_save_IFS 36728 36729 fi 36730 fi 36731 AR=$ac_cv_prog_AR 36732 if test -n "$AR"; then 36733 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 36734 $as_echo "$AR" >&6; } 36735 else 36736 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 36737 $as_echo "no" >&6; } 36738 fi 36739 36740 36741 test -n "$AR" && break 36742 done 36743 fi 36744 if test -z "$AR"; then 36745 ac_ct_AR=$AR 36746 for ac_prog in ar 36747 do 36748 # Extract the first word of "$ac_prog", so it can be a program name with args. 36749 set dummy $ac_prog; ac_word=$2 36750 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 36751 $as_echo_n "checking for $ac_word... " >&6; } 36752 if ${ac_cv_prog_ac_ct_AR+:} false; then : 36753 $as_echo_n "(cached) " >&6 36754 else 36755 if test -n "$ac_ct_AR"; then 36756 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. 36757 else 36758 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 36759 for as_dir in $PATH 36760 do 36761 IFS=$as_save_IFS 36762 test -z "$as_dir" && as_dir=. 36763 for ac_exec_ext in '' $ac_executable_extensions; do 36764 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 36765 ac_cv_prog_ac_ct_AR="$ac_prog" 36766 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 36767 break 2 36768 fi 36769 done 36770 done 36771 IFS=$as_save_IFS 36772 36773 fi 36774 fi 36775 ac_ct_AR=$ac_cv_prog_ac_ct_AR 36776 if test -n "$ac_ct_AR"; then 36777 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 36778 $as_echo "$ac_ct_AR" >&6; } 36779 else 36780 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 36781 $as_echo "no" >&6; } 36782 fi 36783 36784 36785 test -n "$ac_ct_AR" && break 36786 done 36787 36788 if test "x$ac_ct_AR" = x; then 36789 AR="" 36790 else 36791 case $cross_compiling:$ac_tool_warned in 36792 yes:) 36793 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 36794 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 36795 ac_tool_warned=yes ;; 36796 esac 36797 AR=$ac_ct_AR 36798 fi 36799 fi 36800 36801 else 36802 # The variable is set, but is it from the command line or the environment? 36803 36804 # Try to remove the string !AR! from our list. 36805 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!AR!/} 36806 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 36807 # If it failed, the variable was not from the command line. Ignore it, 36808 # but warn the user (except for BASH, which is always set by the calling BASH). 36809 if test "xAR" != xBASH; then 36810 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&5 36811 $as_echo "$as_me: WARNING: Ignoring value of AR from the environment. Use command line variables instead." >&2;} 36812 fi 36813 # Try to locate tool using the code snippet 36814 if test -n "$ac_tool_prefix"; then 36815 for ac_prog in ar 36816 do 36817 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 36818 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 36819 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 36820 $as_echo_n "checking for $ac_word... " >&6; } 36821 if ${ac_cv_prog_AR+:} false; then : 36822 $as_echo_n "(cached) " >&6 36823 else 36824 if test -n "$AR"; then 36825 ac_cv_prog_AR="$AR" # Let the user override the test. 36826 else 36827 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 36828 for as_dir in $PATH 36829 do 36830 IFS=$as_save_IFS 36831 test -z "$as_dir" && as_dir=. 36832 for ac_exec_ext in '' $ac_executable_extensions; do 36833 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 36834 ac_cv_prog_AR="$ac_tool_prefix$ac_prog" 36835 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 36836 break 2 36837 fi 36838 done 36839 done 36840 IFS=$as_save_IFS 36841 36842 fi 36843 fi 36844 AR=$ac_cv_prog_AR 36845 if test -n "$AR"; then 36846 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 36847 $as_echo "$AR" >&6; } 36848 else 36849 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 36850 $as_echo "no" >&6; } 36851 fi 36852 36853 36854 test -n "$AR" && break 36855 done 36856 fi 36857 if test -z "$AR"; then 36858 ac_ct_AR=$AR 36859 for ac_prog in ar 36860 do 36861 # Extract the first word of "$ac_prog", so it can be a program name with args. 36862 set dummy $ac_prog; ac_word=$2 36863 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 36864 $as_echo_n "checking for $ac_word... " >&6; } 36865 if ${ac_cv_prog_ac_ct_AR+:} false; then : 36866 $as_echo_n "(cached) " >&6 36867 else 36868 if test -n "$ac_ct_AR"; then 36869 ac_cv_prog_ac_ct_AR="$ac_ct_AR" # Let the user override the test. 36870 else 36871 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 36872 for as_dir in $PATH 36873 do 36874 IFS=$as_save_IFS 36875 test -z "$as_dir" && as_dir=. 36876 for ac_exec_ext in '' $ac_executable_extensions; do 36877 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 36878 ac_cv_prog_ac_ct_AR="$ac_prog" 36879 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 36880 break 2 36881 fi 36882 done 36883 done 36884 IFS=$as_save_IFS 36885 36886 fi 36887 fi 36888 ac_ct_AR=$ac_cv_prog_ac_ct_AR 36889 if test -n "$ac_ct_AR"; then 36890 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_AR" >&5 36891 $as_echo "$ac_ct_AR" >&6; } 36892 else 36893 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 36894 $as_echo "no" >&6; } 36895 fi 36896 36897 36898 test -n "$ac_ct_AR" && break 36899 done 36900 36901 if test "x$ac_ct_AR" = x; then 36902 AR="" 36903 else 36904 case $cross_compiling:$ac_tool_warned in 36905 yes:) 36906 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 36907 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 36908 ac_tool_warned=yes ;; 36909 esac 36910 AR=$ac_ct_AR 36911 fi 36912 fi 36913 36914 else 36915 # If it succeeded, then it was overridden by the user. We will use it 36916 # for the tool. 36917 36918 # First remove it from the list of overridden variables, so we can test 36919 # for unknown variables in the end. 36920 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 36921 36922 # Check if we try to supply an empty value 36923 if test "x$AR" = x; then 36924 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool AR= (no value)" >&5 36925 $as_echo "$as_me: Setting user supplied tool AR= (no value)" >&6;} 36926 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AR" >&5 36927 $as_echo_n "checking for AR... " >&6; } 36928 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 36929 $as_echo "disabled" >&6; } 36930 else 36931 # Check if the provided tool contains a complete path. 36932 tool_specified="$AR" 36933 tool_basename="${tool_specified##*/}" 36934 if test "x$tool_basename" = "x$tool_specified"; then 36935 # A command without a complete path is provided, search $PATH. 36936 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool AR=$tool_basename" >&5 36937 $as_echo "$as_me: Will search for user supplied tool AR=$tool_basename" >&6;} 36938 # Extract the first word of "$tool_basename", so it can be a program name with args. 36939 set dummy $tool_basename; ac_word=$2 36940 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 36941 $as_echo_n "checking for $ac_word... " >&6; } 36942 if ${ac_cv_path_AR+:} false; then : 36943 $as_echo_n "(cached) " >&6 36944 else 36945 case $AR in 36946 [\\/]* | ?:[\\/]*) 36947 ac_cv_path_AR="$AR" # Let the user override the test with a path. 36948 ;; 36949 *) 36950 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 36951 for as_dir in $PATH 36952 do 36953 IFS=$as_save_IFS 36954 test -z "$as_dir" && as_dir=. 36955 for ac_exec_ext in '' $ac_executable_extensions; do 36956 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 36957 ac_cv_path_AR="$as_dir/$ac_word$ac_exec_ext" 36958 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 36959 break 2 36960 fi 36961 done 36962 done 36963 IFS=$as_save_IFS 36964 36965 ;; 36966 esac 36967 fi 36968 AR=$ac_cv_path_AR 36969 if test -n "$AR"; then 36970 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $AR" >&5 36971 $as_echo "$AR" >&6; } 36972 else 36973 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 36974 $as_echo "no" >&6; } 36975 fi 36976 36977 36978 if test "x$AR" = x; then 36979 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 36980 fi 36981 else 36982 # Otherwise we believe it is a complete path. Use it as it is. 36983 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool AR=$tool_specified" >&5 36984 $as_echo "$as_me: Will use user supplied tool AR=$tool_specified" >&6;} 36985 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for AR" >&5 36986 $as_echo_n "checking for AR... " >&6; } 36987 if test ! -x "$tool_specified"; then 36988 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 36989 $as_echo "not found" >&6; } 36990 as_fn_error $? "User supplied tool AR=$tool_specified does not exist or is not executable" "$LINENO" 5 36991 fi 36992 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 36993 $as_echo "$tool_specified" >&6; } 36994 fi 36995 fi 36996 fi 36997 36998 fi 36999 37000 37001 fi 37002 37003 # Only process if variable expands to non-empty 37004 37005 if test "x$AR" != x; then 37006 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37007 37008 # First separate the path from the arguments. This will split at the first 37009 # space. 37010 complete="$AR" 37011 path="${complete%% *}" 37012 tmp="$complete EOL" 37013 arguments="${tmp#* }" 37014 37015 # Input might be given as Windows format, start by converting to 37016 # unix format. 37017 new_path=`$CYGPATH -u "$path"` 37018 37019 # Now try to locate executable using which 37020 new_path=`$WHICH "$new_path" 2> /dev/null` 37021 # bat and cmd files are not always considered executable in cygwin causing which 37022 # to not find them 37023 if test "x$new_path" = x \ 37024 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37025 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 37026 new_path=`$CYGPATH -u "$path"` 37027 fi 37028 if test "x$new_path" = x; then 37029 # Oops. Which didn't find the executable. 37030 # The splitting of arguments from the executable at a space might have been incorrect, 37031 # since paths with space are more likely in Windows. Give it another try with the whole 37032 # argument. 37033 path="$complete" 37034 arguments="EOL" 37035 new_path=`$CYGPATH -u "$path"` 37036 new_path=`$WHICH "$new_path" 2> /dev/null` 37037 # bat and cmd files are not always considered executable in cygwin causing which 37038 # to not find them 37039 if test "x$new_path" = x \ 37040 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37041 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 37042 new_path=`$CYGPATH -u "$path"` 37043 fi 37044 if test "x$new_path" = x; then 37045 # It's still not found. Now this is an unrecoverable error. 37046 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5 37047 $as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;} 37048 has_space=`$ECHO "$complete" | $GREP " "` 37049 if test "x$has_space" != x; then 37050 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 37051 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 37052 fi 37053 as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5 37054 fi 37055 fi 37056 37057 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 37058 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 37059 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 37060 # "foo.exe" is OK but "foo" is an error. 37061 # 37062 # This test is therefore slightly more accurate than "test -f" to check for file presence. 37063 # It is also a way to make sure we got the proper file name for the real test later on. 37064 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 37065 if test "x$test_shortpath" = x; then 37066 # Short path failed, file does not exist as specified. 37067 # Try adding .exe or .cmd 37068 if test -f "${new_path}.exe"; then 37069 input_to_shortpath="${new_path}.exe" 37070 elif test -f "${new_path}.cmd"; then 37071 input_to_shortpath="${new_path}.cmd" 37072 else 37073 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$new_path\", is invalid." >&5 37074 $as_echo "$as_me: The path of AR, which resolves as \"$new_path\", is invalid." >&6;} 37075 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 37076 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 37077 as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5 37078 fi 37079 else 37080 input_to_shortpath="$new_path" 37081 fi 37082 37083 # Call helper function which possibly converts this using DOS-style short mode. 37084 # If so, the updated path is stored in $new_path. 37085 new_path="$input_to_shortpath" 37086 37087 input_path="$input_to_shortpath" 37088 # Check if we need to convert this using DOS-style short mode. If the path 37089 # contains just simple characters, use it. Otherwise (spaces, weird characters), 37090 # take no chances and rewrite it. 37091 # Note: m4 eats our [], so we need to use [ and ] instead. 37092 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 37093 if test "x$has_forbidden_chars" != x; then 37094 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 37095 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 37096 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 37097 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 37098 # Going to short mode and back again did indeed matter. Since short mode is 37099 # case insensitive, let's make it lowercase to improve readability. 37100 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 37101 # Now convert it back to Unix-style (cygpath) 37102 input_path=`$CYGPATH -u "$shortmode_path"` 37103 new_path="$input_path" 37104 fi 37105 fi 37106 37107 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 37108 if test "x$test_cygdrive_prefix" = x; then 37109 # As a simple fix, exclude /usr/bin since it's not a real path. 37110 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 37111 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 37112 # a path prefixed by /cygdrive for fixpath to work. 37113 new_path="$CYGWIN_ROOT_PATH$input_path" 37114 fi 37115 fi 37116 37117 # remove trailing .exe if any 37118 new_path="${new_path/%.exe/}" 37119 37120 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37121 37122 # First separate the path from the arguments. This will split at the first 37123 # space. 37124 complete="$AR" 37125 path="${complete%% *}" 37126 tmp="$complete EOL" 37127 arguments="${tmp#* }" 37128 37129 # Input might be given as Windows format, start by converting to 37130 # unix format. 37131 new_path="$path" 37132 37133 windows_path="$new_path" 37134 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37135 unix_path=`$CYGPATH -u "$windows_path"` 37136 new_path="$unix_path" 37137 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37138 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37139 new_path="$unix_path" 37140 fi 37141 37142 37143 # Now try to locate executable using which 37144 new_path=`$WHICH "$new_path" 2> /dev/null` 37145 37146 if test "x$new_path" = x; then 37147 # Oops. Which didn't find the executable. 37148 # The splitting of arguments from the executable at a space might have been incorrect, 37149 # since paths with space are more likely in Windows. Give it another try with the whole 37150 # argument. 37151 path="$complete" 37152 arguments="EOL" 37153 new_path="$path" 37154 37155 windows_path="$new_path" 37156 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37157 unix_path=`$CYGPATH -u "$windows_path"` 37158 new_path="$unix_path" 37159 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37160 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37161 new_path="$unix_path" 37162 fi 37163 37164 37165 new_path=`$WHICH "$new_path" 2> /dev/null` 37166 # bat and cmd files are not always considered executable in MSYS causing which 37167 # to not find them 37168 if test "x$new_path" = x \ 37169 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37170 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 37171 new_path="$path" 37172 37173 windows_path="$new_path" 37174 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37175 unix_path=`$CYGPATH -u "$windows_path"` 37176 new_path="$unix_path" 37177 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37178 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37179 new_path="$unix_path" 37180 fi 37181 37182 fi 37183 37184 if test "x$new_path" = x; then 37185 # It's still not found. Now this is an unrecoverable error. 37186 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5 37187 $as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;} 37188 has_space=`$ECHO "$complete" | $GREP " "` 37189 if test "x$has_space" != x; then 37190 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 37191 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 37192 fi 37193 as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5 37194 fi 37195 fi 37196 37197 # Now new_path has a complete unix path to the binary 37198 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 37199 # Keep paths in /bin as-is, but remove trailing .exe if any 37200 new_path="${new_path/%.exe/}" 37201 # Do not save /bin paths to all_fixpath_prefixes! 37202 else 37203 # Not in mixed or Windows style, start by that. 37204 new_path=`cmd //c echo $new_path` 37205 37206 input_path="$new_path" 37207 # Check if we need to convert this using DOS-style short mode. If the path 37208 # contains just simple characters, use it. Otherwise (spaces, weird characters), 37209 # take no chances and rewrite it. 37210 # Note: m4 eats our [], so we need to use [ and ] instead. 37211 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 37212 if test "x$has_forbidden_chars" != x; then 37213 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 37214 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 37215 fi 37216 37217 # Output is in $new_path 37218 37219 windows_path="$new_path" 37220 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37221 unix_path=`$CYGPATH -u "$windows_path"` 37222 new_path="$unix_path" 37223 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37224 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37225 new_path="$unix_path" 37226 fi 37227 37228 # remove trailing .exe if any 37229 new_path="${new_path/%.exe/}" 37230 37231 # Save the first 10 bytes of this path to the storage, so fixpath can work. 37232 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 37233 fi 37234 37235 else 37236 # We're on a unix platform. Hooray! :) 37237 # First separate the path from the arguments. This will split at the first 37238 # space. 37239 complete="$AR" 37240 path="${complete%% *}" 37241 tmp="$complete EOL" 37242 arguments="${tmp#* }" 37243 37244 # Cannot rely on the command "which" here since it doesn't always work. 37245 is_absolute_path=`$ECHO "$path" | $GREP ^/` 37246 if test -z "$is_absolute_path"; then 37247 # Path to executable is not absolute. Find it. 37248 IFS_save="$IFS" 37249 IFS=: 37250 for p in $PATH; do 37251 if test -f "$p/$path" && test -x "$p/$path"; then 37252 new_path="$p/$path" 37253 break 37254 fi 37255 done 37256 IFS="$IFS_save" 37257 else 37258 # This is an absolute path, we can use it without further modifications. 37259 new_path="$path" 37260 fi 37261 37262 if test "x$new_path" = x; then 37263 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of AR, which resolves as \"$complete\", is not found." >&5 37264 $as_echo "$as_me: The path of AR, which resolves as \"$complete\", is not found." >&6;} 37265 has_space=`$ECHO "$complete" | $GREP " "` 37266 if test "x$has_space" != x; then 37267 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 37268 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 37269 fi 37270 as_fn_error $? "Cannot locate the the path of AR" "$LINENO" 5 37271 fi 37272 fi 37273 37274 # Now join together the path and the arguments once again 37275 if test "x$arguments" != xEOL; then 37276 new_complete="$new_path ${arguments% *}" 37277 else 37278 new_complete="$new_path" 37279 fi 37280 37281 if test "x$complete" != "x$new_complete"; then 37282 AR="$new_complete" 37283 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting AR to \"$new_complete\"" >&5 37284 $as_echo "$as_me: Rewriting AR to \"$new_complete\"" >&6;} 37285 fi 37286 fi 37287 37288 37289 37290 if test "x$OPENJDK_TARGET_OS" = "xmacosx"; then 37291 37292 37293 # Publish this variable in the help. 37294 37295 37296 if [ -z "${LIPO+x}" ]; then 37297 # The variable is not set by user, try to locate tool using the code snippet 37298 for ac_prog in lipo 37299 do 37300 # Extract the first word of "$ac_prog", so it can be a program name with args. 37301 set dummy $ac_prog; ac_word=$2 37302 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37303 $as_echo_n "checking for $ac_word... " >&6; } 37304 if ${ac_cv_path_LIPO+:} false; then : 37305 $as_echo_n "(cached) " >&6 37306 else 37307 case $LIPO in 37308 [\\/]* | ?:[\\/]*) 37309 ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path. 37310 ;; 37311 *) 37312 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37313 for as_dir in $PATH 37314 do 37315 IFS=$as_save_IFS 37316 test -z "$as_dir" && as_dir=. 37317 for ac_exec_ext in '' $ac_executable_extensions; do 37318 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37319 ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext" 37320 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37321 break 2 37322 fi 37323 done 37324 done 37325 IFS=$as_save_IFS 37326 37327 ;; 37328 esac 37329 fi 37330 LIPO=$ac_cv_path_LIPO 37331 if test -n "$LIPO"; then 37332 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 37333 $as_echo "$LIPO" >&6; } 37334 else 37335 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37336 $as_echo "no" >&6; } 37337 fi 37338 37339 37340 test -n "$LIPO" && break 37341 done 37342 37343 else 37344 # The variable is set, but is it from the command line or the environment? 37345 37346 # Try to remove the string !LIPO! from our list. 37347 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!LIPO!/} 37348 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 37349 # If it failed, the variable was not from the command line. Ignore it, 37350 # but warn the user (except for BASH, which is always set by the calling BASH). 37351 if test "xLIPO" != xBASH; then 37352 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of LIPO from the environment. Use command line variables instead." >&5 37353 $as_echo "$as_me: WARNING: Ignoring value of LIPO from the environment. Use command line variables instead." >&2;} 37354 fi 37355 # Try to locate tool using the code snippet 37356 for ac_prog in lipo 37357 do 37358 # Extract the first word of "$ac_prog", so it can be a program name with args. 37359 set dummy $ac_prog; ac_word=$2 37360 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37361 $as_echo_n "checking for $ac_word... " >&6; } 37362 if ${ac_cv_path_LIPO+:} false; then : 37363 $as_echo_n "(cached) " >&6 37364 else 37365 case $LIPO in 37366 [\\/]* | ?:[\\/]*) 37367 ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path. 37368 ;; 37369 *) 37370 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37371 for as_dir in $PATH 37372 do 37373 IFS=$as_save_IFS 37374 test -z "$as_dir" && as_dir=. 37375 for ac_exec_ext in '' $ac_executable_extensions; do 37376 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37377 ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext" 37378 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37379 break 2 37380 fi 37381 done 37382 done 37383 IFS=$as_save_IFS 37384 37385 ;; 37386 esac 37387 fi 37388 LIPO=$ac_cv_path_LIPO 37389 if test -n "$LIPO"; then 37390 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 37391 $as_echo "$LIPO" >&6; } 37392 else 37393 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37394 $as_echo "no" >&6; } 37395 fi 37396 37397 37398 test -n "$LIPO" && break 37399 done 37400 37401 else 37402 # If it succeeded, then it was overridden by the user. We will use it 37403 # for the tool. 37404 37405 # First remove it from the list of overridden variables, so we can test 37406 # for unknown variables in the end. 37407 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 37408 37409 # Check if we try to supply an empty value 37410 if test "x$LIPO" = x; then 37411 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool LIPO= (no value)" >&5 37412 $as_echo "$as_me: Setting user supplied tool LIPO= (no value)" >&6;} 37413 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIPO" >&5 37414 $as_echo_n "checking for LIPO... " >&6; } 37415 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 37416 $as_echo "disabled" >&6; } 37417 else 37418 # Check if the provided tool contains a complete path. 37419 tool_specified="$LIPO" 37420 tool_basename="${tool_specified##*/}" 37421 if test "x$tool_basename" = "x$tool_specified"; then 37422 # A command without a complete path is provided, search $PATH. 37423 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool LIPO=$tool_basename" >&5 37424 $as_echo "$as_me: Will search for user supplied tool LIPO=$tool_basename" >&6;} 37425 # Extract the first word of "$tool_basename", so it can be a program name with args. 37426 set dummy $tool_basename; ac_word=$2 37427 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37428 $as_echo_n "checking for $ac_word... " >&6; } 37429 if ${ac_cv_path_LIPO+:} false; then : 37430 $as_echo_n "(cached) " >&6 37431 else 37432 case $LIPO in 37433 [\\/]* | ?:[\\/]*) 37434 ac_cv_path_LIPO="$LIPO" # Let the user override the test with a path. 37435 ;; 37436 *) 37437 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37438 for as_dir in $PATH 37439 do 37440 IFS=$as_save_IFS 37441 test -z "$as_dir" && as_dir=. 37442 for ac_exec_ext in '' $ac_executable_extensions; do 37443 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37444 ac_cv_path_LIPO="$as_dir/$ac_word$ac_exec_ext" 37445 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37446 break 2 37447 fi 37448 done 37449 done 37450 IFS=$as_save_IFS 37451 37452 ;; 37453 esac 37454 fi 37455 LIPO=$ac_cv_path_LIPO 37456 if test -n "$LIPO"; then 37457 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIPO" >&5 37458 $as_echo "$LIPO" >&6; } 37459 else 37460 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37461 $as_echo "no" >&6; } 37462 fi 37463 37464 37465 if test "x$LIPO" = x; then 37466 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 37467 fi 37468 else 37469 # Otherwise we believe it is a complete path. Use it as it is. 37470 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool LIPO=$tool_specified" >&5 37471 $as_echo "$as_me: Will use user supplied tool LIPO=$tool_specified" >&6;} 37472 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIPO" >&5 37473 $as_echo_n "checking for LIPO... " >&6; } 37474 if test ! -x "$tool_specified"; then 37475 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 37476 $as_echo "not found" >&6; } 37477 as_fn_error $? "User supplied tool LIPO=$tool_specified does not exist or is not executable" "$LINENO" 5 37478 fi 37479 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 37480 $as_echo "$tool_specified" >&6; } 37481 fi 37482 fi 37483 fi 37484 37485 fi 37486 37487 37488 37489 # Only process if variable expands to non-empty 37490 37491 if test "x$LIPO" != x; then 37492 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37493 37494 # First separate the path from the arguments. This will split at the first 37495 # space. 37496 complete="$LIPO" 37497 path="${complete%% *}" 37498 tmp="$complete EOL" 37499 arguments="${tmp#* }" 37500 37501 # Input might be given as Windows format, start by converting to 37502 # unix format. 37503 new_path=`$CYGPATH -u "$path"` 37504 37505 # Now try to locate executable using which 37506 new_path=`$WHICH "$new_path" 2> /dev/null` 37507 # bat and cmd files are not always considered executable in cygwin causing which 37508 # to not find them 37509 if test "x$new_path" = x \ 37510 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37511 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 37512 new_path=`$CYGPATH -u "$path"` 37513 fi 37514 if test "x$new_path" = x; then 37515 # Oops. Which didn't find the executable. 37516 # The splitting of arguments from the executable at a space might have been incorrect, 37517 # since paths with space are more likely in Windows. Give it another try with the whole 37518 # argument. 37519 path="$complete" 37520 arguments="EOL" 37521 new_path=`$CYGPATH -u "$path"` 37522 new_path=`$WHICH "$new_path" 2> /dev/null` 37523 # bat and cmd files are not always considered executable in cygwin causing which 37524 # to not find them 37525 if test "x$new_path" = x \ 37526 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37527 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 37528 new_path=`$CYGPATH -u "$path"` 37529 fi 37530 if test "x$new_path" = x; then 37531 # It's still not found. Now this is an unrecoverable error. 37532 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5 37533 $as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;} 37534 has_space=`$ECHO "$complete" | $GREP " "` 37535 if test "x$has_space" != x; then 37536 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 37537 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 37538 fi 37539 as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5 37540 fi 37541 fi 37542 37543 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 37544 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 37545 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 37546 # "foo.exe" is OK but "foo" is an error. 37547 # 37548 # This test is therefore slightly more accurate than "test -f" to check for file presence. 37549 # It is also a way to make sure we got the proper file name for the real test later on. 37550 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 37551 if test "x$test_shortpath" = x; then 37552 # Short path failed, file does not exist as specified. 37553 # Try adding .exe or .cmd 37554 if test -f "${new_path}.exe"; then 37555 input_to_shortpath="${new_path}.exe" 37556 elif test -f "${new_path}.cmd"; then 37557 input_to_shortpath="${new_path}.cmd" 37558 else 37559 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$new_path\", is invalid." >&5 37560 $as_echo "$as_me: The path of LIPO, which resolves as \"$new_path\", is invalid." >&6;} 37561 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 37562 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 37563 as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5 37564 fi 37565 else 37566 input_to_shortpath="$new_path" 37567 fi 37568 37569 # Call helper function which possibly converts this using DOS-style short mode. 37570 # If so, the updated path is stored in $new_path. 37571 new_path="$input_to_shortpath" 37572 37573 input_path="$input_to_shortpath" 37574 # Check if we need to convert this using DOS-style short mode. If the path 37575 # contains just simple characters, use it. Otherwise (spaces, weird characters), 37576 # take no chances and rewrite it. 37577 # Note: m4 eats our [], so we need to use [ and ] instead. 37578 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 37579 if test "x$has_forbidden_chars" != x; then 37580 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 37581 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 37582 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 37583 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 37584 # Going to short mode and back again did indeed matter. Since short mode is 37585 # case insensitive, let's make it lowercase to improve readability. 37586 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 37587 # Now convert it back to Unix-style (cygpath) 37588 input_path=`$CYGPATH -u "$shortmode_path"` 37589 new_path="$input_path" 37590 fi 37591 fi 37592 37593 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 37594 if test "x$test_cygdrive_prefix" = x; then 37595 # As a simple fix, exclude /usr/bin since it's not a real path. 37596 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 37597 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 37598 # a path prefixed by /cygdrive for fixpath to work. 37599 new_path="$CYGWIN_ROOT_PATH$input_path" 37600 fi 37601 fi 37602 37603 # remove trailing .exe if any 37604 new_path="${new_path/%.exe/}" 37605 37606 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37607 37608 # First separate the path from the arguments. This will split at the first 37609 # space. 37610 complete="$LIPO" 37611 path="${complete%% *}" 37612 tmp="$complete EOL" 37613 arguments="${tmp#* }" 37614 37615 # Input might be given as Windows format, start by converting to 37616 # unix format. 37617 new_path="$path" 37618 37619 windows_path="$new_path" 37620 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37621 unix_path=`$CYGPATH -u "$windows_path"` 37622 new_path="$unix_path" 37623 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37624 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37625 new_path="$unix_path" 37626 fi 37627 37628 37629 # Now try to locate executable using which 37630 new_path=`$WHICH "$new_path" 2> /dev/null` 37631 37632 if test "x$new_path" = x; then 37633 # Oops. Which didn't find the executable. 37634 # The splitting of arguments from the executable at a space might have been incorrect, 37635 # since paths with space are more likely in Windows. Give it another try with the whole 37636 # argument. 37637 path="$complete" 37638 arguments="EOL" 37639 new_path="$path" 37640 37641 windows_path="$new_path" 37642 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37643 unix_path=`$CYGPATH -u "$windows_path"` 37644 new_path="$unix_path" 37645 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37646 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37647 new_path="$unix_path" 37648 fi 37649 37650 37651 new_path=`$WHICH "$new_path" 2> /dev/null` 37652 # bat and cmd files are not always considered executable in MSYS causing which 37653 # to not find them 37654 if test "x$new_path" = x \ 37655 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37656 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 37657 new_path="$path" 37658 37659 windows_path="$new_path" 37660 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37661 unix_path=`$CYGPATH -u "$windows_path"` 37662 new_path="$unix_path" 37663 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37664 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37665 new_path="$unix_path" 37666 fi 37667 37668 fi 37669 37670 if test "x$new_path" = x; then 37671 # It's still not found. Now this is an unrecoverable error. 37672 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5 37673 $as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;} 37674 has_space=`$ECHO "$complete" | $GREP " "` 37675 if test "x$has_space" != x; then 37676 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 37677 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 37678 fi 37679 as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5 37680 fi 37681 fi 37682 37683 # Now new_path has a complete unix path to the binary 37684 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 37685 # Keep paths in /bin as-is, but remove trailing .exe if any 37686 new_path="${new_path/%.exe/}" 37687 # Do not save /bin paths to all_fixpath_prefixes! 37688 else 37689 # Not in mixed or Windows style, start by that. 37690 new_path=`cmd //c echo $new_path` 37691 37692 input_path="$new_path" 37693 # Check if we need to convert this using DOS-style short mode. If the path 37694 # contains just simple characters, use it. Otherwise (spaces, weird characters), 37695 # take no chances and rewrite it. 37696 # Note: m4 eats our [], so we need to use [ and ] instead. 37697 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 37698 if test "x$has_forbidden_chars" != x; then 37699 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 37700 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 37701 fi 37702 37703 # Output is in $new_path 37704 37705 windows_path="$new_path" 37706 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37707 unix_path=`$CYGPATH -u "$windows_path"` 37708 new_path="$unix_path" 37709 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37710 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37711 new_path="$unix_path" 37712 fi 37713 37714 # remove trailing .exe if any 37715 new_path="${new_path/%.exe/}" 37716 37717 # Save the first 10 bytes of this path to the storage, so fixpath can work. 37718 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 37719 fi 37720 37721 else 37722 # We're on a unix platform. Hooray! :) 37723 # First separate the path from the arguments. This will split at the first 37724 # space. 37725 complete="$LIPO" 37726 path="${complete%% *}" 37727 tmp="$complete EOL" 37728 arguments="${tmp#* }" 37729 37730 # Cannot rely on the command "which" here since it doesn't always work. 37731 is_absolute_path=`$ECHO "$path" | $GREP ^/` 37732 if test -z "$is_absolute_path"; then 37733 # Path to executable is not absolute. Find it. 37734 IFS_save="$IFS" 37735 IFS=: 37736 for p in $PATH; do 37737 if test -f "$p/$path" && test -x "$p/$path"; then 37738 new_path="$p/$path" 37739 break 37740 fi 37741 done 37742 IFS="$IFS_save" 37743 else 37744 # This is an absolute path, we can use it without further modifications. 37745 new_path="$path" 37746 fi 37747 37748 if test "x$new_path" = x; then 37749 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of LIPO, which resolves as \"$complete\", is not found." >&5 37750 $as_echo "$as_me: The path of LIPO, which resolves as \"$complete\", is not found." >&6;} 37751 has_space=`$ECHO "$complete" | $GREP " "` 37752 if test "x$has_space" != x; then 37753 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 37754 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 37755 fi 37756 as_fn_error $? "Cannot locate the the path of LIPO" "$LINENO" 5 37757 fi 37758 fi 37759 37760 # Now join together the path and the arguments once again 37761 if test "x$arguments" != xEOL; then 37762 new_complete="$new_path ${arguments% *}" 37763 else 37764 new_complete="$new_path" 37765 fi 37766 37767 if test "x$complete" != "x$new_complete"; then 37768 LIPO="$new_complete" 37769 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting LIPO to \"$new_complete\"" >&5 37770 $as_echo "$as_me: Rewriting LIPO to \"$new_complete\"" >&6;} 37771 fi 37772 fi 37773 37774 fi 37775 37776 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 37777 # Extract the first word of "mt", so it can be a program name with args. 37778 set dummy mt; ac_word=$2 37779 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 37780 $as_echo_n "checking for $ac_word... " >&6; } 37781 if ${ac_cv_prog_MT+:} false; then : 37782 $as_echo_n "(cached) " >&6 37783 else 37784 if test -n "$MT"; then 37785 ac_cv_prog_MT="$MT" # Let the user override the test. 37786 else 37787 ac_prog_rejected=no 37788 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 37789 for as_dir in $PATH 37790 do 37791 IFS=$as_save_IFS 37792 test -z "$as_dir" && as_dir=. 37793 for ac_exec_ext in '' $ac_executable_extensions; do 37794 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 37795 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/bin/mt"; then 37796 ac_prog_rejected=yes 37797 continue 37798 fi 37799 ac_cv_prog_MT="mt" 37800 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 37801 break 2 37802 fi 37803 done 37804 done 37805 IFS=$as_save_IFS 37806 37807 if test $ac_prog_rejected = yes; then 37808 # We found a bogon in the path, so make sure we never use it. 37809 set dummy $ac_cv_prog_MT 37810 shift 37811 if test $# != 0; then 37812 # We chose a different compiler from the bogus one. 37813 # However, it has the same basename, so the bogon will be chosen 37814 # first if we set MT to just the basename; use the full file name. 37815 shift 37816 ac_cv_prog_MT="$as_dir/$ac_word${1+' '}$@" 37817 fi 37818 fi 37819 fi 37820 fi 37821 MT=$ac_cv_prog_MT 37822 if test -n "$MT"; then 37823 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MT" >&5 37824 $as_echo "$MT" >&6; } 37825 else 37826 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 37827 $as_echo "no" >&6; } 37828 fi 37829 37830 37831 37832 # Only process if variable expands to non-empty 37833 37834 if test "x$MT" != x; then 37835 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37836 37837 # First separate the path from the arguments. This will split at the first 37838 # space. 37839 complete="$MT" 37840 path="${complete%% *}" 37841 tmp="$complete EOL" 37842 arguments="${tmp#* }" 37843 37844 # Input might be given as Windows format, start by converting to 37845 # unix format. 37846 new_path=`$CYGPATH -u "$path"` 37847 37848 # Now try to locate executable using which 37849 new_path=`$WHICH "$new_path" 2> /dev/null` 37850 # bat and cmd files are not always considered executable in cygwin causing which 37851 # to not find them 37852 if test "x$new_path" = x \ 37853 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37854 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 37855 new_path=`$CYGPATH -u "$path"` 37856 fi 37857 if test "x$new_path" = x; then 37858 # Oops. Which didn't find the executable. 37859 # The splitting of arguments from the executable at a space might have been incorrect, 37860 # since paths with space are more likely in Windows. Give it another try with the whole 37861 # argument. 37862 path="$complete" 37863 arguments="EOL" 37864 new_path=`$CYGPATH -u "$path"` 37865 new_path=`$WHICH "$new_path" 2> /dev/null` 37866 # bat and cmd files are not always considered executable in cygwin causing which 37867 # to not find them 37868 if test "x$new_path" = x \ 37869 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37870 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 37871 new_path=`$CYGPATH -u "$path"` 37872 fi 37873 if test "x$new_path" = x; then 37874 # It's still not found. Now this is an unrecoverable error. 37875 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5 37876 $as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;} 37877 has_space=`$ECHO "$complete" | $GREP " "` 37878 if test "x$has_space" != x; then 37879 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 37880 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 37881 fi 37882 as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5 37883 fi 37884 fi 37885 37886 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 37887 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 37888 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 37889 # "foo.exe" is OK but "foo" is an error. 37890 # 37891 # This test is therefore slightly more accurate than "test -f" to check for file presence. 37892 # It is also a way to make sure we got the proper file name for the real test later on. 37893 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 37894 if test "x$test_shortpath" = x; then 37895 # Short path failed, file does not exist as specified. 37896 # Try adding .exe or .cmd 37897 if test -f "${new_path}.exe"; then 37898 input_to_shortpath="${new_path}.exe" 37899 elif test -f "${new_path}.cmd"; then 37900 input_to_shortpath="${new_path}.cmd" 37901 else 37902 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$new_path\", is invalid." >&5 37903 $as_echo "$as_me: The path of MT, which resolves as \"$new_path\", is invalid." >&6;} 37904 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 37905 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 37906 as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5 37907 fi 37908 else 37909 input_to_shortpath="$new_path" 37910 fi 37911 37912 # Call helper function which possibly converts this using DOS-style short mode. 37913 # If so, the updated path is stored in $new_path. 37914 new_path="$input_to_shortpath" 37915 37916 input_path="$input_to_shortpath" 37917 # Check if we need to convert this using DOS-style short mode. If the path 37918 # contains just simple characters, use it. Otherwise (spaces, weird characters), 37919 # take no chances and rewrite it. 37920 # Note: m4 eats our [], so we need to use [ and ] instead. 37921 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 37922 if test "x$has_forbidden_chars" != x; then 37923 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 37924 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 37925 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 37926 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 37927 # Going to short mode and back again did indeed matter. Since short mode is 37928 # case insensitive, let's make it lowercase to improve readability. 37929 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 37930 # Now convert it back to Unix-style (cygpath) 37931 input_path=`$CYGPATH -u "$shortmode_path"` 37932 new_path="$input_path" 37933 fi 37934 fi 37935 37936 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 37937 if test "x$test_cygdrive_prefix" = x; then 37938 # As a simple fix, exclude /usr/bin since it's not a real path. 37939 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 37940 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 37941 # a path prefixed by /cygdrive for fixpath to work. 37942 new_path="$CYGWIN_ROOT_PATH$input_path" 37943 fi 37944 fi 37945 37946 # remove trailing .exe if any 37947 new_path="${new_path/%.exe/}" 37948 37949 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37950 37951 # First separate the path from the arguments. This will split at the first 37952 # space. 37953 complete="$MT" 37954 path="${complete%% *}" 37955 tmp="$complete EOL" 37956 arguments="${tmp#* }" 37957 37958 # Input might be given as Windows format, start by converting to 37959 # unix format. 37960 new_path="$path" 37961 37962 windows_path="$new_path" 37963 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37964 unix_path=`$CYGPATH -u "$windows_path"` 37965 new_path="$unix_path" 37966 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37967 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37968 new_path="$unix_path" 37969 fi 37970 37971 37972 # Now try to locate executable using which 37973 new_path=`$WHICH "$new_path" 2> /dev/null` 37974 37975 if test "x$new_path" = x; then 37976 # Oops. Which didn't find the executable. 37977 # The splitting of arguments from the executable at a space might have been incorrect, 37978 # since paths with space are more likely in Windows. Give it another try with the whole 37979 # argument. 37980 path="$complete" 37981 arguments="EOL" 37982 new_path="$path" 37983 37984 windows_path="$new_path" 37985 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 37986 unix_path=`$CYGPATH -u "$windows_path"` 37987 new_path="$unix_path" 37988 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 37989 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 37990 new_path="$unix_path" 37991 fi 37992 37993 37994 new_path=`$WHICH "$new_path" 2> /dev/null` 37995 # bat and cmd files are not always considered executable in MSYS causing which 37996 # to not find them 37997 if test "x$new_path" = x \ 37998 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 37999 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38000 new_path="$path" 38001 38002 windows_path="$new_path" 38003 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38004 unix_path=`$CYGPATH -u "$windows_path"` 38005 new_path="$unix_path" 38006 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38007 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38008 new_path="$unix_path" 38009 fi 38010 38011 fi 38012 38013 if test "x$new_path" = x; then 38014 # It's still not found. Now this is an unrecoverable error. 38015 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5 38016 $as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;} 38017 has_space=`$ECHO "$complete" | $GREP " "` 38018 if test "x$has_space" != x; then 38019 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 38020 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 38021 fi 38022 as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5 38023 fi 38024 fi 38025 38026 # Now new_path has a complete unix path to the binary 38027 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 38028 # Keep paths in /bin as-is, but remove trailing .exe if any 38029 new_path="${new_path/%.exe/}" 38030 # Do not save /bin paths to all_fixpath_prefixes! 38031 else 38032 # Not in mixed or Windows style, start by that. 38033 new_path=`cmd //c echo $new_path` 38034 38035 input_path="$new_path" 38036 # Check if we need to convert this using DOS-style short mode. If the path 38037 # contains just simple characters, use it. Otherwise (spaces, weird characters), 38038 # take no chances and rewrite it. 38039 # Note: m4 eats our [], so we need to use [ and ] instead. 38040 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 38041 if test "x$has_forbidden_chars" != x; then 38042 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 38043 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 38044 fi 38045 38046 # Output is in $new_path 38047 38048 windows_path="$new_path" 38049 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38050 unix_path=`$CYGPATH -u "$windows_path"` 38051 new_path="$unix_path" 38052 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38053 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38054 new_path="$unix_path" 38055 fi 38056 38057 # remove trailing .exe if any 38058 new_path="${new_path/%.exe/}" 38059 38060 # Save the first 10 bytes of this path to the storage, so fixpath can work. 38061 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 38062 fi 38063 38064 else 38065 # We're on a unix platform. Hooray! :) 38066 # First separate the path from the arguments. This will split at the first 38067 # space. 38068 complete="$MT" 38069 path="${complete%% *}" 38070 tmp="$complete EOL" 38071 arguments="${tmp#* }" 38072 38073 # Cannot rely on the command "which" here since it doesn't always work. 38074 is_absolute_path=`$ECHO "$path" | $GREP ^/` 38075 if test -z "$is_absolute_path"; then 38076 # Path to executable is not absolute. Find it. 38077 IFS_save="$IFS" 38078 IFS=: 38079 for p in $PATH; do 38080 if test -f "$p/$path" && test -x "$p/$path"; then 38081 new_path="$p/$path" 38082 break 38083 fi 38084 done 38085 IFS="$IFS_save" 38086 else 38087 # This is an absolute path, we can use it without further modifications. 38088 new_path="$path" 38089 fi 38090 38091 if test "x$new_path" = x; then 38092 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MT, which resolves as \"$complete\", is not found." >&5 38093 $as_echo "$as_me: The path of MT, which resolves as \"$complete\", is not found." >&6;} 38094 has_space=`$ECHO "$complete" | $GREP " "` 38095 if test "x$has_space" != x; then 38096 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 38097 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 38098 fi 38099 as_fn_error $? "Cannot locate the the path of MT" "$LINENO" 5 38100 fi 38101 fi 38102 38103 # Now join together the path and the arguments once again 38104 if test "x$arguments" != xEOL; then 38105 new_complete="$new_path ${arguments% *}" 38106 else 38107 new_complete="$new_path" 38108 fi 38109 38110 if test "x$complete" != "x$new_complete"; then 38111 MT="$new_complete" 38112 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MT to \"$new_complete\"" >&5 38113 $as_echo "$as_me: Rewriting MT to \"$new_complete\"" >&6;} 38114 fi 38115 fi 38116 38117 # Setup the resource compiler (RC) 38118 # Extract the first word of "rc", so it can be a program name with args. 38119 set dummy rc; ac_word=$2 38120 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38121 $as_echo_n "checking for $ac_word... " >&6; } 38122 if ${ac_cv_prog_RC+:} false; then : 38123 $as_echo_n "(cached) " >&6 38124 else 38125 if test -n "$RC"; then 38126 ac_cv_prog_RC="$RC" # Let the user override the test. 38127 else 38128 ac_prog_rejected=no 38129 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38130 for as_dir in $PATH 38131 do 38132 IFS=$as_save_IFS 38133 test -z "$as_dir" && as_dir=. 38134 for ac_exec_ext in '' $ac_executable_extensions; do 38135 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38136 if test "$as_dir/$ac_word$ac_exec_ext" = "/usr/bin/rc"; then 38137 ac_prog_rejected=yes 38138 continue 38139 fi 38140 ac_cv_prog_RC="rc" 38141 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38142 break 2 38143 fi 38144 done 38145 done 38146 IFS=$as_save_IFS 38147 38148 if test $ac_prog_rejected = yes; then 38149 # We found a bogon in the path, so make sure we never use it. 38150 set dummy $ac_cv_prog_RC 38151 shift 38152 if test $# != 0; then 38153 # We chose a different compiler from the bogus one. 38154 # However, it has the same basename, so the bogon will be chosen 38155 # first if we set RC to just the basename; use the full file name. 38156 shift 38157 ac_cv_prog_RC="$as_dir/$ac_word${1+' '}$@" 38158 fi 38159 fi 38160 fi 38161 fi 38162 RC=$ac_cv_prog_RC 38163 if test -n "$RC"; then 38164 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RC" >&5 38165 $as_echo "$RC" >&6; } 38166 else 38167 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38168 $as_echo "no" >&6; } 38169 fi 38170 38171 38172 38173 # Only process if variable expands to non-empty 38174 38175 if test "x$RC" != x; then 38176 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38177 38178 # First separate the path from the arguments. This will split at the first 38179 # space. 38180 complete="$RC" 38181 path="${complete%% *}" 38182 tmp="$complete EOL" 38183 arguments="${tmp#* }" 38184 38185 # Input might be given as Windows format, start by converting to 38186 # unix format. 38187 new_path=`$CYGPATH -u "$path"` 38188 38189 # Now try to locate executable using which 38190 new_path=`$WHICH "$new_path" 2> /dev/null` 38191 # bat and cmd files are not always considered executable in cygwin causing which 38192 # to not find them 38193 if test "x$new_path" = x \ 38194 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38195 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38196 new_path=`$CYGPATH -u "$path"` 38197 fi 38198 if test "x$new_path" = x; then 38199 # Oops. Which didn't find the executable. 38200 # The splitting of arguments from the executable at a space might have been incorrect, 38201 # since paths with space are more likely in Windows. Give it another try with the whole 38202 # argument. 38203 path="$complete" 38204 arguments="EOL" 38205 new_path=`$CYGPATH -u "$path"` 38206 new_path=`$WHICH "$new_path" 2> /dev/null` 38207 # bat and cmd files are not always considered executable in cygwin causing which 38208 # to not find them 38209 if test "x$new_path" = x \ 38210 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38211 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38212 new_path=`$CYGPATH -u "$path"` 38213 fi 38214 if test "x$new_path" = x; then 38215 # It's still not found. Now this is an unrecoverable error. 38216 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5 38217 $as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;} 38218 has_space=`$ECHO "$complete" | $GREP " "` 38219 if test "x$has_space" != x; then 38220 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 38221 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 38222 fi 38223 as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5 38224 fi 38225 fi 38226 38227 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 38228 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 38229 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 38230 # "foo.exe" is OK but "foo" is an error. 38231 # 38232 # This test is therefore slightly more accurate than "test -f" to check for file presence. 38233 # It is also a way to make sure we got the proper file name for the real test later on. 38234 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 38235 if test "x$test_shortpath" = x; then 38236 # Short path failed, file does not exist as specified. 38237 # Try adding .exe or .cmd 38238 if test -f "${new_path}.exe"; then 38239 input_to_shortpath="${new_path}.exe" 38240 elif test -f "${new_path}.cmd"; then 38241 input_to_shortpath="${new_path}.cmd" 38242 else 38243 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$new_path\", is invalid." >&5 38244 $as_echo "$as_me: The path of RC, which resolves as \"$new_path\", is invalid." >&6;} 38245 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 38246 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 38247 as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5 38248 fi 38249 else 38250 input_to_shortpath="$new_path" 38251 fi 38252 38253 # Call helper function which possibly converts this using DOS-style short mode. 38254 # If so, the updated path is stored in $new_path. 38255 new_path="$input_to_shortpath" 38256 38257 input_path="$input_to_shortpath" 38258 # Check if we need to convert this using DOS-style short mode. If the path 38259 # contains just simple characters, use it. Otherwise (spaces, weird characters), 38260 # take no chances and rewrite it. 38261 # Note: m4 eats our [], so we need to use [ and ] instead. 38262 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 38263 if test "x$has_forbidden_chars" != x; then 38264 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 38265 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 38266 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 38267 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 38268 # Going to short mode and back again did indeed matter. Since short mode is 38269 # case insensitive, let's make it lowercase to improve readability. 38270 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 38271 # Now convert it back to Unix-style (cygpath) 38272 input_path=`$CYGPATH -u "$shortmode_path"` 38273 new_path="$input_path" 38274 fi 38275 fi 38276 38277 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 38278 if test "x$test_cygdrive_prefix" = x; then 38279 # As a simple fix, exclude /usr/bin since it's not a real path. 38280 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 38281 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 38282 # a path prefixed by /cygdrive for fixpath to work. 38283 new_path="$CYGWIN_ROOT_PATH$input_path" 38284 fi 38285 fi 38286 38287 # remove trailing .exe if any 38288 new_path="${new_path/%.exe/}" 38289 38290 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38291 38292 # First separate the path from the arguments. This will split at the first 38293 # space. 38294 complete="$RC" 38295 path="${complete%% *}" 38296 tmp="$complete EOL" 38297 arguments="${tmp#* }" 38298 38299 # Input might be given as Windows format, start by converting to 38300 # unix format. 38301 new_path="$path" 38302 38303 windows_path="$new_path" 38304 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38305 unix_path=`$CYGPATH -u "$windows_path"` 38306 new_path="$unix_path" 38307 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38308 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38309 new_path="$unix_path" 38310 fi 38311 38312 38313 # Now try to locate executable using which 38314 new_path=`$WHICH "$new_path" 2> /dev/null` 38315 38316 if test "x$new_path" = x; then 38317 # Oops. Which didn't find the executable. 38318 # The splitting of arguments from the executable at a space might have been incorrect, 38319 # since paths with space are more likely in Windows. Give it another try with the whole 38320 # argument. 38321 path="$complete" 38322 arguments="EOL" 38323 new_path="$path" 38324 38325 windows_path="$new_path" 38326 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38327 unix_path=`$CYGPATH -u "$windows_path"` 38328 new_path="$unix_path" 38329 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38330 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38331 new_path="$unix_path" 38332 fi 38333 38334 38335 new_path=`$WHICH "$new_path" 2> /dev/null` 38336 # bat and cmd files are not always considered executable in MSYS causing which 38337 # to not find them 38338 if test "x$new_path" = x \ 38339 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38340 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38341 new_path="$path" 38342 38343 windows_path="$new_path" 38344 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38345 unix_path=`$CYGPATH -u "$windows_path"` 38346 new_path="$unix_path" 38347 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38348 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38349 new_path="$unix_path" 38350 fi 38351 38352 fi 38353 38354 if test "x$new_path" = x; then 38355 # It's still not found. Now this is an unrecoverable error. 38356 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5 38357 $as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;} 38358 has_space=`$ECHO "$complete" | $GREP " "` 38359 if test "x$has_space" != x; then 38360 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 38361 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 38362 fi 38363 as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5 38364 fi 38365 fi 38366 38367 # Now new_path has a complete unix path to the binary 38368 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 38369 # Keep paths in /bin as-is, but remove trailing .exe if any 38370 new_path="${new_path/%.exe/}" 38371 # Do not save /bin paths to all_fixpath_prefixes! 38372 else 38373 # Not in mixed or Windows style, start by that. 38374 new_path=`cmd //c echo $new_path` 38375 38376 input_path="$new_path" 38377 # Check if we need to convert this using DOS-style short mode. If the path 38378 # contains just simple characters, use it. Otherwise (spaces, weird characters), 38379 # take no chances and rewrite it. 38380 # Note: m4 eats our [], so we need to use [ and ] instead. 38381 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 38382 if test "x$has_forbidden_chars" != x; then 38383 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 38384 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 38385 fi 38386 38387 # Output is in $new_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 # remove trailing .exe if any 38399 new_path="${new_path/%.exe/}" 38400 38401 # Save the first 10 bytes of this path to the storage, so fixpath can work. 38402 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 38403 fi 38404 38405 else 38406 # We're on a unix platform. Hooray! :) 38407 # First separate the path from the arguments. This will split at the first 38408 # space. 38409 complete="$RC" 38410 path="${complete%% *}" 38411 tmp="$complete EOL" 38412 arguments="${tmp#* }" 38413 38414 # Cannot rely on the command "which" here since it doesn't always work. 38415 is_absolute_path=`$ECHO "$path" | $GREP ^/` 38416 if test -z "$is_absolute_path"; then 38417 # Path to executable is not absolute. Find it. 38418 IFS_save="$IFS" 38419 IFS=: 38420 for p in $PATH; do 38421 if test -f "$p/$path" && test -x "$p/$path"; then 38422 new_path="$p/$path" 38423 break 38424 fi 38425 done 38426 IFS="$IFS_save" 38427 else 38428 # This is an absolute path, we can use it without further modifications. 38429 new_path="$path" 38430 fi 38431 38432 if test "x$new_path" = x; then 38433 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of RC, which resolves as \"$complete\", is not found." >&5 38434 $as_echo "$as_me: The path of RC, which resolves as \"$complete\", is not found." >&6;} 38435 has_space=`$ECHO "$complete" | $GREP " "` 38436 if test "x$has_space" != x; then 38437 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 38438 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 38439 fi 38440 as_fn_error $? "Cannot locate the the path of RC" "$LINENO" 5 38441 fi 38442 fi 38443 38444 # Now join together the path and the arguments once again 38445 if test "x$arguments" != xEOL; then 38446 new_complete="$new_path ${arguments% *}" 38447 else 38448 new_complete="$new_path" 38449 fi 38450 38451 if test "x$complete" != "x$new_complete"; then 38452 RC="$new_complete" 38453 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting RC to \"$new_complete\"" >&5 38454 $as_echo "$as_me: Rewriting RC to \"$new_complete\"" >&6;} 38455 fi 38456 fi 38457 38458 # Extract the first word of "dumpbin", so it can be a program name with args. 38459 set dummy dumpbin; ac_word=$2 38460 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38461 $as_echo_n "checking for $ac_word... " >&6; } 38462 if ${ac_cv_prog_DUMPBIN+:} false; then : 38463 $as_echo_n "(cached) " >&6 38464 else 38465 if test -n "$DUMPBIN"; then 38466 ac_cv_prog_DUMPBIN="$DUMPBIN" # Let the user override the test. 38467 else 38468 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38469 for as_dir in $PATH 38470 do 38471 IFS=$as_save_IFS 38472 test -z "$as_dir" && as_dir=. 38473 for ac_exec_ext in '' $ac_executable_extensions; do 38474 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38475 ac_cv_prog_DUMPBIN="dumpbin" 38476 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38477 break 2 38478 fi 38479 done 38480 done 38481 IFS=$as_save_IFS 38482 38483 fi 38484 fi 38485 DUMPBIN=$ac_cv_prog_DUMPBIN 38486 if test -n "$DUMPBIN"; then 38487 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DUMPBIN" >&5 38488 $as_echo "$DUMPBIN" >&6; } 38489 else 38490 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38491 $as_echo "no" >&6; } 38492 fi 38493 38494 38495 38496 # Only process if variable expands to non-empty 38497 38498 if test "x$DUMPBIN" != x; then 38499 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38500 38501 # First separate the path from the arguments. This will split at the first 38502 # space. 38503 complete="$DUMPBIN" 38504 path="${complete%% *}" 38505 tmp="$complete EOL" 38506 arguments="${tmp#* }" 38507 38508 # Input might be given as Windows format, start by converting to 38509 # unix format. 38510 new_path=`$CYGPATH -u "$path"` 38511 38512 # Now try to locate executable using which 38513 new_path=`$WHICH "$new_path" 2> /dev/null` 38514 # bat and cmd files are not always considered executable in cygwin causing which 38515 # to not find them 38516 if test "x$new_path" = x \ 38517 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38518 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38519 new_path=`$CYGPATH -u "$path"` 38520 fi 38521 if test "x$new_path" = x; then 38522 # Oops. Which didn't find the executable. 38523 # The splitting of arguments from the executable at a space might have been incorrect, 38524 # since paths with space are more likely in Windows. Give it another try with the whole 38525 # argument. 38526 path="$complete" 38527 arguments="EOL" 38528 new_path=`$CYGPATH -u "$path"` 38529 new_path=`$WHICH "$new_path" 2> /dev/null` 38530 # bat and cmd files are not always considered executable in cygwin causing which 38531 # to not find them 38532 if test "x$new_path" = x \ 38533 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38534 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38535 new_path=`$CYGPATH -u "$path"` 38536 fi 38537 if test "x$new_path" = x; then 38538 # It's still not found. Now this is an unrecoverable error. 38539 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5 38540 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;} 38541 has_space=`$ECHO "$complete" | $GREP " "` 38542 if test "x$has_space" != x; then 38543 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 38544 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 38545 fi 38546 as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5 38547 fi 38548 fi 38549 38550 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 38551 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 38552 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 38553 # "foo.exe" is OK but "foo" is an error. 38554 # 38555 # This test is therefore slightly more accurate than "test -f" to check for file presence. 38556 # It is also a way to make sure we got the proper file name for the real test later on. 38557 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 38558 if test "x$test_shortpath" = x; then 38559 # Short path failed, file does not exist as specified. 38560 # Try adding .exe or .cmd 38561 if test -f "${new_path}.exe"; then 38562 input_to_shortpath="${new_path}.exe" 38563 elif test -f "${new_path}.cmd"; then 38564 input_to_shortpath="${new_path}.cmd" 38565 else 38566 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$new_path\", is invalid." >&5 38567 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$new_path\", is invalid." >&6;} 38568 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 38569 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 38570 as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5 38571 fi 38572 else 38573 input_to_shortpath="$new_path" 38574 fi 38575 38576 # Call helper function which possibly converts this using DOS-style short mode. 38577 # If so, the updated path is stored in $new_path. 38578 new_path="$input_to_shortpath" 38579 38580 input_path="$input_to_shortpath" 38581 # Check if we need to convert this using DOS-style short mode. If the path 38582 # contains just simple characters, use it. Otherwise (spaces, weird characters), 38583 # take no chances and rewrite it. 38584 # Note: m4 eats our [], so we need to use [ and ] instead. 38585 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 38586 if test "x$has_forbidden_chars" != x; then 38587 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 38588 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 38589 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 38590 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 38591 # Going to short mode and back again did indeed matter. Since short mode is 38592 # case insensitive, let's make it lowercase to improve readability. 38593 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 38594 # Now convert it back to Unix-style (cygpath) 38595 input_path=`$CYGPATH -u "$shortmode_path"` 38596 new_path="$input_path" 38597 fi 38598 fi 38599 38600 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 38601 if test "x$test_cygdrive_prefix" = x; then 38602 # As a simple fix, exclude /usr/bin since it's not a real path. 38603 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 38604 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 38605 # a path prefixed by /cygdrive for fixpath to work. 38606 new_path="$CYGWIN_ROOT_PATH$input_path" 38607 fi 38608 fi 38609 38610 # remove trailing .exe if any 38611 new_path="${new_path/%.exe/}" 38612 38613 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38614 38615 # First separate the path from the arguments. This will split at the first 38616 # space. 38617 complete="$DUMPBIN" 38618 path="${complete%% *}" 38619 tmp="$complete EOL" 38620 arguments="${tmp#* }" 38621 38622 # Input might be given as Windows format, start by converting to 38623 # unix format. 38624 new_path="$path" 38625 38626 windows_path="$new_path" 38627 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38628 unix_path=`$CYGPATH -u "$windows_path"` 38629 new_path="$unix_path" 38630 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38631 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38632 new_path="$unix_path" 38633 fi 38634 38635 38636 # Now try to locate executable using which 38637 new_path=`$WHICH "$new_path" 2> /dev/null` 38638 38639 if test "x$new_path" = x; then 38640 # Oops. Which didn't find the executable. 38641 # The splitting of arguments from the executable at a space might have been incorrect, 38642 # since paths with space are more likely in Windows. Give it another try with the whole 38643 # argument. 38644 path="$complete" 38645 arguments="EOL" 38646 new_path="$path" 38647 38648 windows_path="$new_path" 38649 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38650 unix_path=`$CYGPATH -u "$windows_path"` 38651 new_path="$unix_path" 38652 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38653 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38654 new_path="$unix_path" 38655 fi 38656 38657 38658 new_path=`$WHICH "$new_path" 2> /dev/null` 38659 # bat and cmd files are not always considered executable in MSYS causing which 38660 # to not find them 38661 if test "x$new_path" = x \ 38662 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 38663 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 38664 new_path="$path" 38665 38666 windows_path="$new_path" 38667 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38668 unix_path=`$CYGPATH -u "$windows_path"` 38669 new_path="$unix_path" 38670 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38671 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38672 new_path="$unix_path" 38673 fi 38674 38675 fi 38676 38677 if test "x$new_path" = x; then 38678 # It's still not found. Now this is an unrecoverable error. 38679 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5 38680 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;} 38681 has_space=`$ECHO "$complete" | $GREP " "` 38682 if test "x$has_space" != x; then 38683 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 38684 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 38685 fi 38686 as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5 38687 fi 38688 fi 38689 38690 # Now new_path has a complete unix path to the binary 38691 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 38692 # Keep paths in /bin as-is, but remove trailing .exe if any 38693 new_path="${new_path/%.exe/}" 38694 # Do not save /bin paths to all_fixpath_prefixes! 38695 else 38696 # Not in mixed or Windows style, start by that. 38697 new_path=`cmd //c echo $new_path` 38698 38699 input_path="$new_path" 38700 # Check if we need to convert this using DOS-style short mode. If the path 38701 # contains just simple characters, use it. Otherwise (spaces, weird characters), 38702 # take no chances and rewrite it. 38703 # Note: m4 eats our [], so we need to use [ and ] instead. 38704 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 38705 if test "x$has_forbidden_chars" != x; then 38706 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 38707 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 38708 fi 38709 38710 # Output is in $new_path 38711 38712 windows_path="$new_path" 38713 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 38714 unix_path=`$CYGPATH -u "$windows_path"` 38715 new_path="$unix_path" 38716 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 38717 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 38718 new_path="$unix_path" 38719 fi 38720 38721 # remove trailing .exe if any 38722 new_path="${new_path/%.exe/}" 38723 38724 # Save the first 10 bytes of this path to the storage, so fixpath can work. 38725 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 38726 fi 38727 38728 else 38729 # We're on a unix platform. Hooray! :) 38730 # First separate the path from the arguments. This will split at the first 38731 # space. 38732 complete="$DUMPBIN" 38733 path="${complete%% *}" 38734 tmp="$complete EOL" 38735 arguments="${tmp#* }" 38736 38737 # Cannot rely on the command "which" here since it doesn't always work. 38738 is_absolute_path=`$ECHO "$path" | $GREP ^/` 38739 if test -z "$is_absolute_path"; then 38740 # Path to executable is not absolute. Find it. 38741 IFS_save="$IFS" 38742 IFS=: 38743 for p in $PATH; do 38744 if test -f "$p/$path" && test -x "$p/$path"; then 38745 new_path="$p/$path" 38746 break 38747 fi 38748 done 38749 IFS="$IFS_save" 38750 else 38751 # This is an absolute path, we can use it without further modifications. 38752 new_path="$path" 38753 fi 38754 38755 if test "x$new_path" = x; then 38756 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&5 38757 $as_echo "$as_me: The path of DUMPBIN, which resolves as \"$complete\", is not found." >&6;} 38758 has_space=`$ECHO "$complete" | $GREP " "` 38759 if test "x$has_space" != x; then 38760 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 38761 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 38762 fi 38763 as_fn_error $? "Cannot locate the the path of DUMPBIN" "$LINENO" 5 38764 fi 38765 fi 38766 38767 # Now join together the path and the arguments once again 38768 if test "x$arguments" != xEOL; then 38769 new_complete="$new_path ${arguments% *}" 38770 else 38771 new_complete="$new_path" 38772 fi 38773 38774 if test "x$complete" != "x$new_complete"; then 38775 DUMPBIN="$new_complete" 38776 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting DUMPBIN to \"$new_complete\"" >&5 38777 $as_echo "$as_me: Rewriting DUMPBIN to \"$new_complete\"" >&6;} 38778 fi 38779 fi 38780 38781 # We need to check for 'msbuild.exe' because at the place where we expect to 38782 # find 'msbuild.exe' there's also a directory called 'msbuild' and configure 38783 # won't find the 'msbuild.exe' executable in that case (and the 38784 # 'ac_executable_extensions' is unusable due to performance reasons). 38785 # Notice that we intentionally don't fix up the path to MSBUILD because we 38786 # will call it in a DOS shell during freetype detection on Windows (see 38787 # 'LIB_SETUP_FREETYPE' in "libraries.m4" 38788 # Extract the first word of "msbuild.exe", so it can be a program name with args. 38789 set dummy msbuild.exe; ac_word=$2 38790 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38791 $as_echo_n "checking for $ac_word... " >&6; } 38792 if ${ac_cv_prog_MSBUILD+:} false; then : 38793 $as_echo_n "(cached) " >&6 38794 else 38795 if test -n "$MSBUILD"; then 38796 ac_cv_prog_MSBUILD="$MSBUILD" # Let the user override the test. 38797 else 38798 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38799 for as_dir in $PATH 38800 do 38801 IFS=$as_save_IFS 38802 test -z "$as_dir" && as_dir=. 38803 for ac_exec_ext in '' $ac_executable_extensions; do 38804 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38805 ac_cv_prog_MSBUILD="msbuild.exe" 38806 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38807 break 2 38808 fi 38809 done 38810 done 38811 IFS=$as_save_IFS 38812 38813 fi 38814 fi 38815 MSBUILD=$ac_cv_prog_MSBUILD 38816 if test -n "$MSBUILD"; then 38817 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSBUILD" >&5 38818 $as_echo "$MSBUILD" >&6; } 38819 else 38820 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38821 $as_echo "no" >&6; } 38822 fi 38823 38824 38825 fi 38826 38827 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 38828 38829 38830 # Publish this variable in the help. 38831 38832 38833 if [ -z "${STRIP+x}" ]; then 38834 # The variable is not set by user, try to locate tool using the code snippet 38835 for ac_prog in strip 38836 do 38837 # Extract the first word of "$ac_prog", so it can be a program name with args. 38838 set dummy $ac_prog; ac_word=$2 38839 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38840 $as_echo_n "checking for $ac_word... " >&6; } 38841 if ${ac_cv_path_STRIP+:} false; then : 38842 $as_echo_n "(cached) " >&6 38843 else 38844 case $STRIP in 38845 [\\/]* | ?:[\\/]*) 38846 ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path. 38847 ;; 38848 *) 38849 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38850 for as_dir in $PATH 38851 do 38852 IFS=$as_save_IFS 38853 test -z "$as_dir" && as_dir=. 38854 for ac_exec_ext in '' $ac_executable_extensions; do 38855 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38856 ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext" 38857 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38858 break 2 38859 fi 38860 done 38861 done 38862 IFS=$as_save_IFS 38863 38864 ;; 38865 esac 38866 fi 38867 STRIP=$ac_cv_path_STRIP 38868 if test -n "$STRIP"; then 38869 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 38870 $as_echo "$STRIP" >&6; } 38871 else 38872 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38873 $as_echo "no" >&6; } 38874 fi 38875 38876 38877 test -n "$STRIP" && break 38878 done 38879 38880 else 38881 # The variable is set, but is it from the command line or the environment? 38882 38883 # Try to remove the string !STRIP! from our list. 38884 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!STRIP!/} 38885 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 38886 # If it failed, the variable was not from the command line. Ignore it, 38887 # but warn the user (except for BASH, which is always set by the calling BASH). 38888 if test "xSTRIP" != xBASH; then 38889 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&5 38890 $as_echo "$as_me: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&2;} 38891 fi 38892 # Try to locate tool using the code snippet 38893 for ac_prog in strip 38894 do 38895 # Extract the first word of "$ac_prog", so it can be a program name with args. 38896 set dummy $ac_prog; ac_word=$2 38897 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38898 $as_echo_n "checking for $ac_word... " >&6; } 38899 if ${ac_cv_path_STRIP+:} false; then : 38900 $as_echo_n "(cached) " >&6 38901 else 38902 case $STRIP in 38903 [\\/]* | ?:[\\/]*) 38904 ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path. 38905 ;; 38906 *) 38907 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38908 for as_dir in $PATH 38909 do 38910 IFS=$as_save_IFS 38911 test -z "$as_dir" && as_dir=. 38912 for ac_exec_ext in '' $ac_executable_extensions; do 38913 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38914 ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext" 38915 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38916 break 2 38917 fi 38918 done 38919 done 38920 IFS=$as_save_IFS 38921 38922 ;; 38923 esac 38924 fi 38925 STRIP=$ac_cv_path_STRIP 38926 if test -n "$STRIP"; then 38927 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 38928 $as_echo "$STRIP" >&6; } 38929 else 38930 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38931 $as_echo "no" >&6; } 38932 fi 38933 38934 38935 test -n "$STRIP" && break 38936 done 38937 38938 else 38939 # If it succeeded, then it was overridden by the user. We will use it 38940 # for the tool. 38941 38942 # First remove it from the list of overridden variables, so we can test 38943 # for unknown variables in the end. 38944 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 38945 38946 # Check if we try to supply an empty value 38947 if test "x$STRIP" = x; then 38948 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool STRIP= (no value)" >&5 38949 $as_echo "$as_me: Setting user supplied tool STRIP= (no value)" >&6;} 38950 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5 38951 $as_echo_n "checking for STRIP... " >&6; } 38952 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 38953 $as_echo "disabled" >&6; } 38954 else 38955 # Check if the provided tool contains a complete path. 38956 tool_specified="$STRIP" 38957 tool_basename="${tool_specified##*/}" 38958 if test "x$tool_basename" = "x$tool_specified"; then 38959 # A command without a complete path is provided, search $PATH. 38960 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool STRIP=$tool_basename" >&5 38961 $as_echo "$as_me: Will search for user supplied tool STRIP=$tool_basename" >&6;} 38962 # Extract the first word of "$tool_basename", so it can be a program name with args. 38963 set dummy $tool_basename; ac_word=$2 38964 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 38965 $as_echo_n "checking for $ac_word... " >&6; } 38966 if ${ac_cv_path_STRIP+:} false; then : 38967 $as_echo_n "(cached) " >&6 38968 else 38969 case $STRIP in 38970 [\\/]* | ?:[\\/]*) 38971 ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path. 38972 ;; 38973 *) 38974 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 38975 for as_dir in $PATH 38976 do 38977 IFS=$as_save_IFS 38978 test -z "$as_dir" && as_dir=. 38979 for ac_exec_ext in '' $ac_executable_extensions; do 38980 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 38981 ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext" 38982 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 38983 break 2 38984 fi 38985 done 38986 done 38987 IFS=$as_save_IFS 38988 38989 ;; 38990 esac 38991 fi 38992 STRIP=$ac_cv_path_STRIP 38993 if test -n "$STRIP"; then 38994 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 38995 $as_echo "$STRIP" >&6; } 38996 else 38997 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 38998 $as_echo "no" >&6; } 38999 fi 39000 39001 39002 if test "x$STRIP" = x; then 39003 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 39004 fi 39005 else 39006 # Otherwise we believe it is a complete path. Use it as it is. 39007 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool STRIP=$tool_specified" >&5 39008 $as_echo "$as_me: Will use user supplied tool STRIP=$tool_specified" >&6;} 39009 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5 39010 $as_echo_n "checking for STRIP... " >&6; } 39011 if test ! -x "$tool_specified"; then 39012 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 39013 $as_echo "not found" >&6; } 39014 as_fn_error $? "User supplied tool STRIP=$tool_specified does not exist or is not executable" "$LINENO" 5 39015 fi 39016 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 39017 $as_echo "$tool_specified" >&6; } 39018 fi 39019 fi 39020 fi 39021 39022 fi 39023 39024 39025 39026 # Only process if variable expands to non-empty 39027 39028 if test "x$STRIP" != x; then 39029 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39030 39031 # First separate the path from the arguments. This will split at the first 39032 # space. 39033 complete="$STRIP" 39034 path="${complete%% *}" 39035 tmp="$complete EOL" 39036 arguments="${tmp#* }" 39037 39038 # Input might be given as Windows format, start by converting to 39039 # unix format. 39040 new_path=`$CYGPATH -u "$path"` 39041 39042 # Now try to locate executable using which 39043 new_path=`$WHICH "$new_path" 2> /dev/null` 39044 # bat and cmd files are not always considered executable in cygwin causing which 39045 # to not find them 39046 if test "x$new_path" = x \ 39047 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39048 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39049 new_path=`$CYGPATH -u "$path"` 39050 fi 39051 if test "x$new_path" = x; then 39052 # Oops. Which didn't find the executable. 39053 # The splitting of arguments from the executable at a space might have been incorrect, 39054 # since paths with space are more likely in Windows. Give it another try with the whole 39055 # argument. 39056 path="$complete" 39057 arguments="EOL" 39058 new_path=`$CYGPATH -u "$path"` 39059 new_path=`$WHICH "$new_path" 2> /dev/null` 39060 # bat and cmd files are not always considered executable in cygwin causing which 39061 # to not find them 39062 if test "x$new_path" = x \ 39063 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39064 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39065 new_path=`$CYGPATH -u "$path"` 39066 fi 39067 if test "x$new_path" = x; then 39068 # It's still not found. Now this is an unrecoverable error. 39069 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 39070 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 39071 has_space=`$ECHO "$complete" | $GREP " "` 39072 if test "x$has_space" != x; then 39073 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 39074 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 39075 fi 39076 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 39077 fi 39078 fi 39079 39080 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 39081 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 39082 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 39083 # "foo.exe" is OK but "foo" is an error. 39084 # 39085 # This test is therefore slightly more accurate than "test -f" to check for file presence. 39086 # It is also a way to make sure we got the proper file name for the real test later on. 39087 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 39088 if test "x$test_shortpath" = x; then 39089 # Short path failed, file does not exist as specified. 39090 # Try adding .exe or .cmd 39091 if test -f "${new_path}.exe"; then 39092 input_to_shortpath="${new_path}.exe" 39093 elif test -f "${new_path}.cmd"; then 39094 input_to_shortpath="${new_path}.cmd" 39095 else 39096 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$new_path\", is invalid." >&5 39097 $as_echo "$as_me: The path of STRIP, which resolves as \"$new_path\", is invalid." >&6;} 39098 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 39099 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 39100 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 39101 fi 39102 else 39103 input_to_shortpath="$new_path" 39104 fi 39105 39106 # Call helper function which possibly converts this using DOS-style short mode. 39107 # If so, the updated path is stored in $new_path. 39108 new_path="$input_to_shortpath" 39109 39110 input_path="$input_to_shortpath" 39111 # Check if we need to convert this using DOS-style short mode. If the path 39112 # contains just simple characters, use it. Otherwise (spaces, weird characters), 39113 # take no chances and rewrite it. 39114 # Note: m4 eats our [], so we need to use [ and ] instead. 39115 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 39116 if test "x$has_forbidden_chars" != x; then 39117 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 39118 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 39119 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 39120 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 39121 # Going to short mode and back again did indeed matter. Since short mode is 39122 # case insensitive, let's make it lowercase to improve readability. 39123 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39124 # Now convert it back to Unix-style (cygpath) 39125 input_path=`$CYGPATH -u "$shortmode_path"` 39126 new_path="$input_path" 39127 fi 39128 fi 39129 39130 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 39131 if test "x$test_cygdrive_prefix" = x; then 39132 # As a simple fix, exclude /usr/bin since it's not a real path. 39133 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 39134 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 39135 # a path prefixed by /cygdrive for fixpath to work. 39136 new_path="$CYGWIN_ROOT_PATH$input_path" 39137 fi 39138 fi 39139 39140 # remove trailing .exe if any 39141 new_path="${new_path/%.exe/}" 39142 39143 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39144 39145 # First separate the path from the arguments. This will split at the first 39146 # space. 39147 complete="$STRIP" 39148 path="${complete%% *}" 39149 tmp="$complete EOL" 39150 arguments="${tmp#* }" 39151 39152 # Input might be given as Windows format, start by converting to 39153 # unix format. 39154 new_path="$path" 39155 39156 windows_path="$new_path" 39157 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39158 unix_path=`$CYGPATH -u "$windows_path"` 39159 new_path="$unix_path" 39160 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39161 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39162 new_path="$unix_path" 39163 fi 39164 39165 39166 # Now try to locate executable using which 39167 new_path=`$WHICH "$new_path" 2> /dev/null` 39168 39169 if test "x$new_path" = x; then 39170 # Oops. Which didn't find the executable. 39171 # The splitting of arguments from the executable at a space might have been incorrect, 39172 # since paths with space are more likely in Windows. Give it another try with the whole 39173 # argument. 39174 path="$complete" 39175 arguments="EOL" 39176 new_path="$path" 39177 39178 windows_path="$new_path" 39179 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39180 unix_path=`$CYGPATH -u "$windows_path"` 39181 new_path="$unix_path" 39182 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39183 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39184 new_path="$unix_path" 39185 fi 39186 39187 39188 new_path=`$WHICH "$new_path" 2> /dev/null` 39189 # bat and cmd files are not always considered executable in MSYS causing which 39190 # to not find them 39191 if test "x$new_path" = x \ 39192 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39193 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39194 new_path="$path" 39195 39196 windows_path="$new_path" 39197 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39198 unix_path=`$CYGPATH -u "$windows_path"` 39199 new_path="$unix_path" 39200 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39201 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39202 new_path="$unix_path" 39203 fi 39204 39205 fi 39206 39207 if test "x$new_path" = x; then 39208 # It's still not found. Now this is an unrecoverable error. 39209 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 39210 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 39211 has_space=`$ECHO "$complete" | $GREP " "` 39212 if test "x$has_space" != x; then 39213 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 39214 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 39215 fi 39216 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 39217 fi 39218 fi 39219 39220 # Now new_path has a complete unix path to the binary 39221 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 39222 # Keep paths in /bin as-is, but remove trailing .exe if any 39223 new_path="${new_path/%.exe/}" 39224 # Do not save /bin paths to all_fixpath_prefixes! 39225 else 39226 # Not in mixed or Windows style, start by that. 39227 new_path=`cmd //c echo $new_path` 39228 39229 input_path="$new_path" 39230 # Check if we need to convert this using DOS-style short mode. If the path 39231 # contains just simple characters, use it. Otherwise (spaces, weird characters), 39232 # take no chances and rewrite it. 39233 # Note: m4 eats our [], so we need to use [ and ] instead. 39234 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 39235 if test "x$has_forbidden_chars" != x; then 39236 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 39237 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39238 fi 39239 39240 # Output is in $new_path 39241 39242 windows_path="$new_path" 39243 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39244 unix_path=`$CYGPATH -u "$windows_path"` 39245 new_path="$unix_path" 39246 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39247 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39248 new_path="$unix_path" 39249 fi 39250 39251 # remove trailing .exe if any 39252 new_path="${new_path/%.exe/}" 39253 39254 # Save the first 10 bytes of this path to the storage, so fixpath can work. 39255 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 39256 fi 39257 39258 else 39259 # We're on a unix platform. Hooray! :) 39260 # First separate the path from the arguments. This will split at the first 39261 # space. 39262 complete="$STRIP" 39263 path="${complete%% *}" 39264 tmp="$complete EOL" 39265 arguments="${tmp#* }" 39266 39267 # Cannot rely on the command "which" here since it doesn't always work. 39268 is_absolute_path=`$ECHO "$path" | $GREP ^/` 39269 if test -z "$is_absolute_path"; then 39270 # Path to executable is not absolute. Find it. 39271 IFS_save="$IFS" 39272 IFS=: 39273 for p in $PATH; do 39274 if test -f "$p/$path" && test -x "$p/$path"; then 39275 new_path="$p/$path" 39276 break 39277 fi 39278 done 39279 IFS="$IFS_save" 39280 else 39281 # This is an absolute path, we can use it without further modifications. 39282 new_path="$path" 39283 fi 39284 39285 if test "x$new_path" = x; then 39286 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 39287 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 39288 has_space=`$ECHO "$complete" | $GREP " "` 39289 if test "x$has_space" != x; then 39290 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 39291 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 39292 fi 39293 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 39294 fi 39295 fi 39296 39297 # Now join together the path and the arguments once again 39298 if test "x$arguments" != xEOL; then 39299 new_complete="$new_path ${arguments% *}" 39300 else 39301 new_complete="$new_path" 39302 fi 39303 39304 if test "x$complete" != "x$new_complete"; then 39305 STRIP="$new_complete" 39306 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STRIP to \"$new_complete\"" >&5 39307 $as_echo "$as_me: Rewriting STRIP to \"$new_complete\"" >&6;} 39308 fi 39309 fi 39310 39311 39312 39313 # Publish this variable in the help. 39314 39315 39316 if [ -z "${NM+x}" ]; then 39317 # The variable is not set by user, try to locate tool using the code snippet 39318 for ac_prog in nm 39319 do 39320 # Extract the first word of "$ac_prog", so it can be a program name with args. 39321 set dummy $ac_prog; ac_word=$2 39322 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 39323 $as_echo_n "checking for $ac_word... " >&6; } 39324 if ${ac_cv_path_NM+:} false; then : 39325 $as_echo_n "(cached) " >&6 39326 else 39327 case $NM in 39328 [\\/]* | ?:[\\/]*) 39329 ac_cv_path_NM="$NM" # Let the user override the test with a path. 39330 ;; 39331 *) 39332 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 39333 for as_dir in $PATH 39334 do 39335 IFS=$as_save_IFS 39336 test -z "$as_dir" && as_dir=. 39337 for ac_exec_ext in '' $ac_executable_extensions; do 39338 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 39339 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 39340 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 39341 break 2 39342 fi 39343 done 39344 done 39345 IFS=$as_save_IFS 39346 39347 ;; 39348 esac 39349 fi 39350 NM=$ac_cv_path_NM 39351 if test -n "$NM"; then 39352 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 39353 $as_echo "$NM" >&6; } 39354 else 39355 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 39356 $as_echo "no" >&6; } 39357 fi 39358 39359 39360 test -n "$NM" && break 39361 done 39362 39363 else 39364 # The variable is set, but is it from the command line or the environment? 39365 39366 # Try to remove the string !NM! from our list. 39367 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NM!/} 39368 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 39369 # If it failed, the variable was not from the command line. Ignore it, 39370 # but warn the user (except for BASH, which is always set by the calling BASH). 39371 if test "xNM" != xBASH; then 39372 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&5 39373 $as_echo "$as_me: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&2;} 39374 fi 39375 # Try to locate tool using the code snippet 39376 for ac_prog in nm 39377 do 39378 # Extract the first word of "$ac_prog", so it can be a program name with args. 39379 set dummy $ac_prog; ac_word=$2 39380 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 39381 $as_echo_n "checking for $ac_word... " >&6; } 39382 if ${ac_cv_path_NM+:} false; then : 39383 $as_echo_n "(cached) " >&6 39384 else 39385 case $NM in 39386 [\\/]* | ?:[\\/]*) 39387 ac_cv_path_NM="$NM" # Let the user override the test with a path. 39388 ;; 39389 *) 39390 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 39391 for as_dir in $PATH 39392 do 39393 IFS=$as_save_IFS 39394 test -z "$as_dir" && as_dir=. 39395 for ac_exec_ext in '' $ac_executable_extensions; do 39396 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 39397 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 39398 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 39399 break 2 39400 fi 39401 done 39402 done 39403 IFS=$as_save_IFS 39404 39405 ;; 39406 esac 39407 fi 39408 NM=$ac_cv_path_NM 39409 if test -n "$NM"; then 39410 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 39411 $as_echo "$NM" >&6; } 39412 else 39413 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 39414 $as_echo "no" >&6; } 39415 fi 39416 39417 39418 test -n "$NM" && break 39419 done 39420 39421 else 39422 # If it succeeded, then it was overridden by the user. We will use it 39423 # for the tool. 39424 39425 # First remove it from the list of overridden variables, so we can test 39426 # for unknown variables in the end. 39427 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 39428 39429 # Check if we try to supply an empty value 39430 if test "x$NM" = x; then 39431 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool NM= (no value)" >&5 39432 $as_echo "$as_me: Setting user supplied tool NM= (no value)" >&6;} 39433 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 39434 $as_echo_n "checking for NM... " >&6; } 39435 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 39436 $as_echo "disabled" >&6; } 39437 else 39438 # Check if the provided tool contains a complete path. 39439 tool_specified="$NM" 39440 tool_basename="${tool_specified##*/}" 39441 if test "x$tool_basename" = "x$tool_specified"; then 39442 # A command without a complete path is provided, search $PATH. 39443 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NM=$tool_basename" >&5 39444 $as_echo "$as_me: Will search for user supplied tool NM=$tool_basename" >&6;} 39445 # Extract the first word of "$tool_basename", so it can be a program name with args. 39446 set dummy $tool_basename; ac_word=$2 39447 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 39448 $as_echo_n "checking for $ac_word... " >&6; } 39449 if ${ac_cv_path_NM+:} false; then : 39450 $as_echo_n "(cached) " >&6 39451 else 39452 case $NM in 39453 [\\/]* | ?:[\\/]*) 39454 ac_cv_path_NM="$NM" # Let the user override the test with a path. 39455 ;; 39456 *) 39457 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 39458 for as_dir in $PATH 39459 do 39460 IFS=$as_save_IFS 39461 test -z "$as_dir" && as_dir=. 39462 for ac_exec_ext in '' $ac_executable_extensions; do 39463 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 39464 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 39465 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 39466 break 2 39467 fi 39468 done 39469 done 39470 IFS=$as_save_IFS 39471 39472 ;; 39473 esac 39474 fi 39475 NM=$ac_cv_path_NM 39476 if test -n "$NM"; then 39477 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 39478 $as_echo "$NM" >&6; } 39479 else 39480 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 39481 $as_echo "no" >&6; } 39482 fi 39483 39484 39485 if test "x$NM" = x; then 39486 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 39487 fi 39488 else 39489 # Otherwise we believe it is a complete path. Use it as it is. 39490 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NM=$tool_specified" >&5 39491 $as_echo "$as_me: Will use user supplied tool NM=$tool_specified" >&6;} 39492 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 39493 $as_echo_n "checking for NM... " >&6; } 39494 if test ! -x "$tool_specified"; then 39495 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 39496 $as_echo "not found" >&6; } 39497 as_fn_error $? "User supplied tool NM=$tool_specified does not exist or is not executable" "$LINENO" 5 39498 fi 39499 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 39500 $as_echo "$tool_specified" >&6; } 39501 fi 39502 fi 39503 fi 39504 39505 fi 39506 39507 39508 39509 # Only process if variable expands to non-empty 39510 39511 if test "x$NM" != x; then 39512 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39513 39514 # First separate the path from the arguments. This will split at the first 39515 # space. 39516 complete="$NM" 39517 path="${complete%% *}" 39518 tmp="$complete EOL" 39519 arguments="${tmp#* }" 39520 39521 # Input might be given as Windows format, start by converting to 39522 # unix format. 39523 new_path=`$CYGPATH -u "$path"` 39524 39525 # Now try to locate executable using which 39526 new_path=`$WHICH "$new_path" 2> /dev/null` 39527 # bat and cmd files are not always considered executable in cygwin causing which 39528 # to not find them 39529 if test "x$new_path" = x \ 39530 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39531 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39532 new_path=`$CYGPATH -u "$path"` 39533 fi 39534 if test "x$new_path" = x; then 39535 # Oops. Which didn't find the executable. 39536 # The splitting of arguments from the executable at a space might have been incorrect, 39537 # since paths with space are more likely in Windows. Give it another try with the whole 39538 # argument. 39539 path="$complete" 39540 arguments="EOL" 39541 new_path=`$CYGPATH -u "$path"` 39542 new_path=`$WHICH "$new_path" 2> /dev/null` 39543 # bat and cmd files are not always considered executable in cygwin causing which 39544 # to not find them 39545 if test "x$new_path" = x \ 39546 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39547 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39548 new_path=`$CYGPATH -u "$path"` 39549 fi 39550 if test "x$new_path" = x; then 39551 # It's still not found. Now this is an unrecoverable error. 39552 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 39553 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 39554 has_space=`$ECHO "$complete" | $GREP " "` 39555 if test "x$has_space" != x; then 39556 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 39557 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 39558 fi 39559 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 39560 fi 39561 fi 39562 39563 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 39564 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 39565 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 39566 # "foo.exe" is OK but "foo" is an error. 39567 # 39568 # This test is therefore slightly more accurate than "test -f" to check for file presence. 39569 # It is also a way to make sure we got the proper file name for the real test later on. 39570 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 39571 if test "x$test_shortpath" = x; then 39572 # Short path failed, file does not exist as specified. 39573 # Try adding .exe or .cmd 39574 if test -f "${new_path}.exe"; then 39575 input_to_shortpath="${new_path}.exe" 39576 elif test -f "${new_path}.cmd"; then 39577 input_to_shortpath="${new_path}.cmd" 39578 else 39579 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$new_path\", is invalid." >&5 39580 $as_echo "$as_me: The path of NM, which resolves as \"$new_path\", is invalid." >&6;} 39581 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 39582 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 39583 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 39584 fi 39585 else 39586 input_to_shortpath="$new_path" 39587 fi 39588 39589 # Call helper function which possibly converts this using DOS-style short mode. 39590 # If so, the updated path is stored in $new_path. 39591 new_path="$input_to_shortpath" 39592 39593 input_path="$input_to_shortpath" 39594 # Check if we need to convert this using DOS-style short mode. If the path 39595 # contains just simple characters, use it. Otherwise (spaces, weird characters), 39596 # take no chances and rewrite it. 39597 # Note: m4 eats our [], so we need to use [ and ] instead. 39598 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 39599 if test "x$has_forbidden_chars" != x; then 39600 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 39601 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 39602 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 39603 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 39604 # Going to short mode and back again did indeed matter. Since short mode is 39605 # case insensitive, let's make it lowercase to improve readability. 39606 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39607 # Now convert it back to Unix-style (cygpath) 39608 input_path=`$CYGPATH -u "$shortmode_path"` 39609 new_path="$input_path" 39610 fi 39611 fi 39612 39613 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 39614 if test "x$test_cygdrive_prefix" = x; then 39615 # As a simple fix, exclude /usr/bin since it's not a real path. 39616 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 39617 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 39618 # a path prefixed by /cygdrive for fixpath to work. 39619 new_path="$CYGWIN_ROOT_PATH$input_path" 39620 fi 39621 fi 39622 39623 # remove trailing .exe if any 39624 new_path="${new_path/%.exe/}" 39625 39626 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39627 39628 # First separate the path from the arguments. This will split at the first 39629 # space. 39630 complete="$NM" 39631 path="${complete%% *}" 39632 tmp="$complete EOL" 39633 arguments="${tmp#* }" 39634 39635 # Input might be given as Windows format, start by converting to 39636 # unix format. 39637 new_path="$path" 39638 39639 windows_path="$new_path" 39640 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39641 unix_path=`$CYGPATH -u "$windows_path"` 39642 new_path="$unix_path" 39643 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39644 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39645 new_path="$unix_path" 39646 fi 39647 39648 39649 # Now try to locate executable using which 39650 new_path=`$WHICH "$new_path" 2> /dev/null` 39651 39652 if test "x$new_path" = x; then 39653 # Oops. Which didn't find the executable. 39654 # The splitting of arguments from the executable at a space might have been incorrect, 39655 # since paths with space are more likely in Windows. Give it another try with the whole 39656 # argument. 39657 path="$complete" 39658 arguments="EOL" 39659 new_path="$path" 39660 39661 windows_path="$new_path" 39662 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39663 unix_path=`$CYGPATH -u "$windows_path"` 39664 new_path="$unix_path" 39665 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39666 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39667 new_path="$unix_path" 39668 fi 39669 39670 39671 new_path=`$WHICH "$new_path" 2> /dev/null` 39672 # bat and cmd files are not always considered executable in MSYS causing which 39673 # to not find them 39674 if test "x$new_path" = x \ 39675 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 39676 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 39677 new_path="$path" 39678 39679 windows_path="$new_path" 39680 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39681 unix_path=`$CYGPATH -u "$windows_path"` 39682 new_path="$unix_path" 39683 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39684 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39685 new_path="$unix_path" 39686 fi 39687 39688 fi 39689 39690 if test "x$new_path" = x; then 39691 # It's still not found. Now this is an unrecoverable error. 39692 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 39693 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 39694 has_space=`$ECHO "$complete" | $GREP " "` 39695 if test "x$has_space" != x; then 39696 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 39697 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 39698 fi 39699 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 39700 fi 39701 fi 39702 39703 # Now new_path has a complete unix path to the binary 39704 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 39705 # Keep paths in /bin as-is, but remove trailing .exe if any 39706 new_path="${new_path/%.exe/}" 39707 # Do not save /bin paths to all_fixpath_prefixes! 39708 else 39709 # Not in mixed or Windows style, start by that. 39710 new_path=`cmd //c echo $new_path` 39711 39712 input_path="$new_path" 39713 # Check if we need to convert this using DOS-style short mode. If the path 39714 # contains just simple characters, use it. Otherwise (spaces, weird characters), 39715 # take no chances and rewrite it. 39716 # Note: m4 eats our [], so we need to use [ and ] instead. 39717 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 39718 if test "x$has_forbidden_chars" != x; then 39719 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 39720 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 39721 fi 39722 39723 # Output is in $new_path 39724 39725 windows_path="$new_path" 39726 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39727 unix_path=`$CYGPATH -u "$windows_path"` 39728 new_path="$unix_path" 39729 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 39730 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 39731 new_path="$unix_path" 39732 fi 39733 39734 # remove trailing .exe if any 39735 new_path="${new_path/%.exe/}" 39736 39737 # Save the first 10 bytes of this path to the storage, so fixpath can work. 39738 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 39739 fi 39740 39741 else 39742 # We're on a unix platform. Hooray! :) 39743 # First separate the path from the arguments. This will split at the first 39744 # space. 39745 complete="$NM" 39746 path="${complete%% *}" 39747 tmp="$complete EOL" 39748 arguments="${tmp#* }" 39749 39750 # Cannot rely on the command "which" here since it doesn't always work. 39751 is_absolute_path=`$ECHO "$path" | $GREP ^/` 39752 if test -z "$is_absolute_path"; then 39753 # Path to executable is not absolute. Find it. 39754 IFS_save="$IFS" 39755 IFS=: 39756 for p in $PATH; do 39757 if test -f "$p/$path" && test -x "$p/$path"; then 39758 new_path="$p/$path" 39759 break 39760 fi 39761 done 39762 IFS="$IFS_save" 39763 else 39764 # This is an absolute path, we can use it without further modifications. 39765 new_path="$path" 39766 fi 39767 39768 if test "x$new_path" = x; then 39769 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 39770 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 39771 has_space=`$ECHO "$complete" | $GREP " "` 39772 if test "x$has_space" != x; then 39773 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 39774 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 39775 fi 39776 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 39777 fi 39778 fi 39779 39780 # Now join together the path and the arguments once again 39781 if test "x$arguments" != xEOL; then 39782 new_complete="$new_path ${arguments% *}" 39783 else 39784 new_complete="$new_path" 39785 fi 39786 39787 if test "x$complete" != "x$new_complete"; then 39788 NM="$new_complete" 39789 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting NM to \"$new_complete\"" >&5 39790 $as_echo "$as_me: Rewriting NM to \"$new_complete\"" >&6;} 39791 fi 39792 fi 39793 39794 39795 39796 # Publish this variable in the help. 39797 39798 39799 if [ -z "${GNM+x}" ]; then 39800 # The variable is not set by user, try to locate tool using the code snippet 39801 for ac_prog in gnm 39802 do 39803 # Extract the first word of "$ac_prog", so it can be a program name with args. 39804 set dummy $ac_prog; ac_word=$2 39805 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 39806 $as_echo_n "checking for $ac_word... " >&6; } 39807 if ${ac_cv_path_GNM+:} false; then : 39808 $as_echo_n "(cached) " >&6 39809 else 39810 case $GNM in 39811 [\\/]* | ?:[\\/]*) 39812 ac_cv_path_GNM="$GNM" # Let the user override the test with a path. 39813 ;; 39814 *) 39815 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 39816 for as_dir in $PATH 39817 do 39818 IFS=$as_save_IFS 39819 test -z "$as_dir" && as_dir=. 39820 for ac_exec_ext in '' $ac_executable_extensions; do 39821 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 39822 ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext" 39823 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 39824 break 2 39825 fi 39826 done 39827 done 39828 IFS=$as_save_IFS 39829 39830 ;; 39831 esac 39832 fi 39833 GNM=$ac_cv_path_GNM 39834 if test -n "$GNM"; then 39835 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5 39836 $as_echo "$GNM" >&6; } 39837 else 39838 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 39839 $as_echo "no" >&6; } 39840 fi 39841 39842 39843 test -n "$GNM" && break 39844 done 39845 39846 else 39847 # The variable is set, but is it from the command line or the environment? 39848 39849 # Try to remove the string !GNM! from our list. 39850 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!GNM!/} 39851 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 39852 # If it failed, the variable was not from the command line. Ignore it, 39853 # but warn the user (except for BASH, which is always set by the calling BASH). 39854 if test "xGNM" != xBASH; then 39855 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of GNM from the environment. Use command line variables instead." >&5 39856 $as_echo "$as_me: WARNING: Ignoring value of GNM from the environment. Use command line variables instead." >&2;} 39857 fi 39858 # Try to locate tool using the code snippet 39859 for ac_prog in gnm 39860 do 39861 # Extract the first word of "$ac_prog", so it can be a program name with args. 39862 set dummy $ac_prog; ac_word=$2 39863 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 39864 $as_echo_n "checking for $ac_word... " >&6; } 39865 if ${ac_cv_path_GNM+:} false; then : 39866 $as_echo_n "(cached) " >&6 39867 else 39868 case $GNM in 39869 [\\/]* | ?:[\\/]*) 39870 ac_cv_path_GNM="$GNM" # Let the user override the test with a path. 39871 ;; 39872 *) 39873 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 39874 for as_dir in $PATH 39875 do 39876 IFS=$as_save_IFS 39877 test -z "$as_dir" && as_dir=. 39878 for ac_exec_ext in '' $ac_executable_extensions; do 39879 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 39880 ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext" 39881 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 39882 break 2 39883 fi 39884 done 39885 done 39886 IFS=$as_save_IFS 39887 39888 ;; 39889 esac 39890 fi 39891 GNM=$ac_cv_path_GNM 39892 if test -n "$GNM"; then 39893 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5 39894 $as_echo "$GNM" >&6; } 39895 else 39896 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 39897 $as_echo "no" >&6; } 39898 fi 39899 39900 39901 test -n "$GNM" && break 39902 done 39903 39904 else 39905 # If it succeeded, then it was overridden by the user. We will use it 39906 # for the tool. 39907 39908 # First remove it from the list of overridden variables, so we can test 39909 # for unknown variables in the end. 39910 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 39911 39912 # Check if we try to supply an empty value 39913 if test "x$GNM" = x; then 39914 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool GNM= (no value)" >&5 39915 $as_echo "$as_me: Setting user supplied tool GNM= (no value)" >&6;} 39916 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNM" >&5 39917 $as_echo_n "checking for GNM... " >&6; } 39918 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 39919 $as_echo "disabled" >&6; } 39920 else 39921 # Check if the provided tool contains a complete path. 39922 tool_specified="$GNM" 39923 tool_basename="${tool_specified##*/}" 39924 if test "x$tool_basename" = "x$tool_specified"; then 39925 # A command without a complete path is provided, search $PATH. 39926 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool GNM=$tool_basename" >&5 39927 $as_echo "$as_me: Will search for user supplied tool GNM=$tool_basename" >&6;} 39928 # Extract the first word of "$tool_basename", so it can be a program name with args. 39929 set dummy $tool_basename; ac_word=$2 39930 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 39931 $as_echo_n "checking for $ac_word... " >&6; } 39932 if ${ac_cv_path_GNM+:} false; then : 39933 $as_echo_n "(cached) " >&6 39934 else 39935 case $GNM in 39936 [\\/]* | ?:[\\/]*) 39937 ac_cv_path_GNM="$GNM" # Let the user override the test with a path. 39938 ;; 39939 *) 39940 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 39941 for as_dir in $PATH 39942 do 39943 IFS=$as_save_IFS 39944 test -z "$as_dir" && as_dir=. 39945 for ac_exec_ext in '' $ac_executable_extensions; do 39946 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 39947 ac_cv_path_GNM="$as_dir/$ac_word$ac_exec_ext" 39948 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 39949 break 2 39950 fi 39951 done 39952 done 39953 IFS=$as_save_IFS 39954 39955 ;; 39956 esac 39957 fi 39958 GNM=$ac_cv_path_GNM 39959 if test -n "$GNM"; then 39960 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $GNM" >&5 39961 $as_echo "$GNM" >&6; } 39962 else 39963 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 39964 $as_echo "no" >&6; } 39965 fi 39966 39967 39968 if test "x$GNM" = x; then 39969 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 39970 fi 39971 else 39972 # Otherwise we believe it is a complete path. Use it as it is. 39973 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool GNM=$tool_specified" >&5 39974 $as_echo "$as_me: Will use user supplied tool GNM=$tool_specified" >&6;} 39975 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for GNM" >&5 39976 $as_echo_n "checking for GNM... " >&6; } 39977 if test ! -x "$tool_specified"; then 39978 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 39979 $as_echo "not found" >&6; } 39980 as_fn_error $? "User supplied tool GNM=$tool_specified does not exist or is not executable" "$LINENO" 5 39981 fi 39982 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 39983 $as_echo "$tool_specified" >&6; } 39984 fi 39985 fi 39986 fi 39987 39988 fi 39989 39990 39991 39992 # Only process if variable expands to non-empty 39993 39994 if test "x$GNM" != x; then 39995 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 39996 39997 # First separate the path from the arguments. This will split at the first 39998 # space. 39999 complete="$GNM" 40000 path="${complete%% *}" 40001 tmp="$complete EOL" 40002 arguments="${tmp#* }" 40003 40004 # Input might be given as Windows format, start by converting to 40005 # unix format. 40006 new_path=`$CYGPATH -u "$path"` 40007 40008 # Now try to locate executable using which 40009 new_path=`$WHICH "$new_path" 2> /dev/null` 40010 # bat and cmd files are not always considered executable in cygwin causing which 40011 # to not find them 40012 if test "x$new_path" = x \ 40013 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40014 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40015 new_path=`$CYGPATH -u "$path"` 40016 fi 40017 if test "x$new_path" = x; then 40018 # Oops. Which didn't find the executable. 40019 # The splitting of arguments from the executable at a space might have been incorrect, 40020 # since paths with space are more likely in Windows. Give it another try with the whole 40021 # argument. 40022 path="$complete" 40023 arguments="EOL" 40024 new_path=`$CYGPATH -u "$path"` 40025 new_path=`$WHICH "$new_path" 2> /dev/null` 40026 # bat and cmd files are not always considered executable in cygwin causing which 40027 # to not find them 40028 if test "x$new_path" = x \ 40029 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40030 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40031 new_path=`$CYGPATH -u "$path"` 40032 fi 40033 if test "x$new_path" = x; then 40034 # It's still not found. Now this is an unrecoverable error. 40035 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5 40036 $as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;} 40037 has_space=`$ECHO "$complete" | $GREP " "` 40038 if test "x$has_space" != x; then 40039 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 40040 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 40041 fi 40042 as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5 40043 fi 40044 fi 40045 40046 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 40047 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 40048 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 40049 # "foo.exe" is OK but "foo" is an error. 40050 # 40051 # This test is therefore slightly more accurate than "test -f" to check for file presence. 40052 # It is also a way to make sure we got the proper file name for the real test later on. 40053 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 40054 if test "x$test_shortpath" = x; then 40055 # Short path failed, file does not exist as specified. 40056 # Try adding .exe or .cmd 40057 if test -f "${new_path}.exe"; then 40058 input_to_shortpath="${new_path}.exe" 40059 elif test -f "${new_path}.cmd"; then 40060 input_to_shortpath="${new_path}.cmd" 40061 else 40062 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$new_path\", is invalid." >&5 40063 $as_echo "$as_me: The path of GNM, which resolves as \"$new_path\", is invalid." >&6;} 40064 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 40065 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 40066 as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5 40067 fi 40068 else 40069 input_to_shortpath="$new_path" 40070 fi 40071 40072 # Call helper function which possibly converts this using DOS-style short mode. 40073 # If so, the updated path is stored in $new_path. 40074 new_path="$input_to_shortpath" 40075 40076 input_path="$input_to_shortpath" 40077 # Check if we need to convert this using DOS-style short mode. If the path 40078 # contains just simple characters, use it. Otherwise (spaces, weird characters), 40079 # take no chances and rewrite it. 40080 # Note: m4 eats our [], so we need to use [ and ] instead. 40081 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 40082 if test "x$has_forbidden_chars" != x; then 40083 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 40084 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 40085 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 40086 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 40087 # Going to short mode and back again did indeed matter. Since short mode is 40088 # case insensitive, let's make it lowercase to improve readability. 40089 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 40090 # Now convert it back to Unix-style (cygpath) 40091 input_path=`$CYGPATH -u "$shortmode_path"` 40092 new_path="$input_path" 40093 fi 40094 fi 40095 40096 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 40097 if test "x$test_cygdrive_prefix" = x; then 40098 # As a simple fix, exclude /usr/bin since it's not a real path. 40099 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 40100 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 40101 # a path prefixed by /cygdrive for fixpath to work. 40102 new_path="$CYGWIN_ROOT_PATH$input_path" 40103 fi 40104 fi 40105 40106 # remove trailing .exe if any 40107 new_path="${new_path/%.exe/}" 40108 40109 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40110 40111 # First separate the path from the arguments. This will split at the first 40112 # space. 40113 complete="$GNM" 40114 path="${complete%% *}" 40115 tmp="$complete EOL" 40116 arguments="${tmp#* }" 40117 40118 # Input might be given as Windows format, start by converting to 40119 # unix format. 40120 new_path="$path" 40121 40122 windows_path="$new_path" 40123 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40124 unix_path=`$CYGPATH -u "$windows_path"` 40125 new_path="$unix_path" 40126 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40127 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40128 new_path="$unix_path" 40129 fi 40130 40131 40132 # Now try to locate executable using which 40133 new_path=`$WHICH "$new_path" 2> /dev/null` 40134 40135 if test "x$new_path" = x; then 40136 # Oops. Which didn't find the executable. 40137 # The splitting of arguments from the executable at a space might have been incorrect, 40138 # since paths with space are more likely in Windows. Give it another try with the whole 40139 # argument. 40140 path="$complete" 40141 arguments="EOL" 40142 new_path="$path" 40143 40144 windows_path="$new_path" 40145 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40146 unix_path=`$CYGPATH -u "$windows_path"` 40147 new_path="$unix_path" 40148 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40149 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40150 new_path="$unix_path" 40151 fi 40152 40153 40154 new_path=`$WHICH "$new_path" 2> /dev/null` 40155 # bat and cmd files are not always considered executable in MSYS causing which 40156 # to not find them 40157 if test "x$new_path" = x \ 40158 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40159 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40160 new_path="$path" 40161 40162 windows_path="$new_path" 40163 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40164 unix_path=`$CYGPATH -u "$windows_path"` 40165 new_path="$unix_path" 40166 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40167 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40168 new_path="$unix_path" 40169 fi 40170 40171 fi 40172 40173 if test "x$new_path" = x; then 40174 # It's still not found. Now this is an unrecoverable error. 40175 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5 40176 $as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;} 40177 has_space=`$ECHO "$complete" | $GREP " "` 40178 if test "x$has_space" != x; then 40179 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 40180 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 40181 fi 40182 as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5 40183 fi 40184 fi 40185 40186 # Now new_path has a complete unix path to the binary 40187 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 40188 # Keep paths in /bin as-is, but remove trailing .exe if any 40189 new_path="${new_path/%.exe/}" 40190 # Do not save /bin paths to all_fixpath_prefixes! 40191 else 40192 # Not in mixed or Windows style, start by that. 40193 new_path=`cmd //c echo $new_path` 40194 40195 input_path="$new_path" 40196 # Check if we need to convert this using DOS-style short mode. If the path 40197 # contains just simple characters, use it. Otherwise (spaces, weird characters), 40198 # take no chances and rewrite it. 40199 # Note: m4 eats our [], so we need to use [ and ] instead. 40200 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 40201 if test "x$has_forbidden_chars" != x; then 40202 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 40203 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 40204 fi 40205 40206 # Output is in $new_path 40207 40208 windows_path="$new_path" 40209 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40210 unix_path=`$CYGPATH -u "$windows_path"` 40211 new_path="$unix_path" 40212 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40213 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40214 new_path="$unix_path" 40215 fi 40216 40217 # remove trailing .exe if any 40218 new_path="${new_path/%.exe/}" 40219 40220 # Save the first 10 bytes of this path to the storage, so fixpath can work. 40221 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 40222 fi 40223 40224 else 40225 # We're on a unix platform. Hooray! :) 40226 # First separate the path from the arguments. This will split at the first 40227 # space. 40228 complete="$GNM" 40229 path="${complete%% *}" 40230 tmp="$complete EOL" 40231 arguments="${tmp#* }" 40232 40233 # Cannot rely on the command "which" here since it doesn't always work. 40234 is_absolute_path=`$ECHO "$path" | $GREP ^/` 40235 if test -z "$is_absolute_path"; then 40236 # Path to executable is not absolute. Find it. 40237 IFS_save="$IFS" 40238 IFS=: 40239 for p in $PATH; do 40240 if test -f "$p/$path" && test -x "$p/$path"; then 40241 new_path="$p/$path" 40242 break 40243 fi 40244 done 40245 IFS="$IFS_save" 40246 else 40247 # This is an absolute path, we can use it without further modifications. 40248 new_path="$path" 40249 fi 40250 40251 if test "x$new_path" = x; then 40252 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of GNM, which resolves as \"$complete\", is not found." >&5 40253 $as_echo "$as_me: The path of GNM, which resolves as \"$complete\", is not found." >&6;} 40254 has_space=`$ECHO "$complete" | $GREP " "` 40255 if test "x$has_space" != x; then 40256 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 40257 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 40258 fi 40259 as_fn_error $? "Cannot locate the the path of GNM" "$LINENO" 5 40260 fi 40261 fi 40262 40263 # Now join together the path and the arguments once again 40264 if test "x$arguments" != xEOL; then 40265 new_complete="$new_path ${arguments% *}" 40266 else 40267 new_complete="$new_path" 40268 fi 40269 40270 if test "x$complete" != "x$new_complete"; then 40271 GNM="$new_complete" 40272 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting GNM to \"$new_complete\"" >&5 40273 $as_echo "$as_me: Rewriting GNM to \"$new_complete\"" >&6;} 40274 fi 40275 fi 40276 40277 elif test "x$OPENJDK_TARGET_OS" != xwindows; then 40278 # FIXME: we should unify this with the solaris case above. 40279 40280 40281 # Publish this variable in the help. 40282 40283 40284 if [ -z "${STRIP+x}" ]; then 40285 # The variable is not set by user, try to locate tool using the code snippet 40286 if test -n "$ac_tool_prefix"; then 40287 for ac_prog in strip 40288 do 40289 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 40290 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 40291 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40292 $as_echo_n "checking for $ac_word... " >&6; } 40293 if ${ac_cv_prog_STRIP+:} false; then : 40294 $as_echo_n "(cached) " >&6 40295 else 40296 if test -n "$STRIP"; then 40297 ac_cv_prog_STRIP="$STRIP" # Let the user override the test. 40298 else 40299 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40300 for as_dir in $PATH 40301 do 40302 IFS=$as_save_IFS 40303 test -z "$as_dir" && as_dir=. 40304 for ac_exec_ext in '' $ac_executable_extensions; do 40305 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40306 ac_cv_prog_STRIP="$ac_tool_prefix$ac_prog" 40307 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40308 break 2 40309 fi 40310 done 40311 done 40312 IFS=$as_save_IFS 40313 40314 fi 40315 fi 40316 STRIP=$ac_cv_prog_STRIP 40317 if test -n "$STRIP"; then 40318 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 40319 $as_echo "$STRIP" >&6; } 40320 else 40321 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40322 $as_echo "no" >&6; } 40323 fi 40324 40325 40326 test -n "$STRIP" && break 40327 done 40328 fi 40329 if test -z "$STRIP"; then 40330 ac_ct_STRIP=$STRIP 40331 for ac_prog in strip 40332 do 40333 # Extract the first word of "$ac_prog", so it can be a program name with args. 40334 set dummy $ac_prog; ac_word=$2 40335 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40336 $as_echo_n "checking for $ac_word... " >&6; } 40337 if ${ac_cv_prog_ac_ct_STRIP+:} false; then : 40338 $as_echo_n "(cached) " >&6 40339 else 40340 if test -n "$ac_ct_STRIP"; then 40341 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. 40342 else 40343 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40344 for as_dir in $PATH 40345 do 40346 IFS=$as_save_IFS 40347 test -z "$as_dir" && as_dir=. 40348 for ac_exec_ext in '' $ac_executable_extensions; do 40349 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40350 ac_cv_prog_ac_ct_STRIP="$ac_prog" 40351 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40352 break 2 40353 fi 40354 done 40355 done 40356 IFS=$as_save_IFS 40357 40358 fi 40359 fi 40360 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP 40361 if test -n "$ac_ct_STRIP"; then 40362 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 40363 $as_echo "$ac_ct_STRIP" >&6; } 40364 else 40365 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40366 $as_echo "no" >&6; } 40367 fi 40368 40369 40370 test -n "$ac_ct_STRIP" && break 40371 done 40372 40373 if test "x$ac_ct_STRIP" = x; then 40374 STRIP="" 40375 else 40376 case $cross_compiling:$ac_tool_warned in 40377 yes:) 40378 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 40379 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 40380 ac_tool_warned=yes ;; 40381 esac 40382 STRIP=$ac_ct_STRIP 40383 fi 40384 fi 40385 40386 else 40387 # The variable is set, but is it from the command line or the environment? 40388 40389 # Try to remove the string !STRIP! from our list. 40390 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!STRIP!/} 40391 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 40392 # If it failed, the variable was not from the command line. Ignore it, 40393 # but warn the user (except for BASH, which is always set by the calling BASH). 40394 if test "xSTRIP" != xBASH; then 40395 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&5 40396 $as_echo "$as_me: WARNING: Ignoring value of STRIP from the environment. Use command line variables instead." >&2;} 40397 fi 40398 # Try to locate tool using the code snippet 40399 if test -n "$ac_tool_prefix"; then 40400 for ac_prog in strip 40401 do 40402 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 40403 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 40404 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40405 $as_echo_n "checking for $ac_word... " >&6; } 40406 if ${ac_cv_prog_STRIP+:} false; then : 40407 $as_echo_n "(cached) " >&6 40408 else 40409 if test -n "$STRIP"; then 40410 ac_cv_prog_STRIP="$STRIP" # Let the user override the test. 40411 else 40412 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40413 for as_dir in $PATH 40414 do 40415 IFS=$as_save_IFS 40416 test -z "$as_dir" && as_dir=. 40417 for ac_exec_ext in '' $ac_executable_extensions; do 40418 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40419 ac_cv_prog_STRIP="$ac_tool_prefix$ac_prog" 40420 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40421 break 2 40422 fi 40423 done 40424 done 40425 IFS=$as_save_IFS 40426 40427 fi 40428 fi 40429 STRIP=$ac_cv_prog_STRIP 40430 if test -n "$STRIP"; then 40431 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 40432 $as_echo "$STRIP" >&6; } 40433 else 40434 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40435 $as_echo "no" >&6; } 40436 fi 40437 40438 40439 test -n "$STRIP" && break 40440 done 40441 fi 40442 if test -z "$STRIP"; then 40443 ac_ct_STRIP=$STRIP 40444 for ac_prog in strip 40445 do 40446 # Extract the first word of "$ac_prog", so it can be a program name with args. 40447 set dummy $ac_prog; ac_word=$2 40448 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40449 $as_echo_n "checking for $ac_word... " >&6; } 40450 if ${ac_cv_prog_ac_ct_STRIP+:} false; then : 40451 $as_echo_n "(cached) " >&6 40452 else 40453 if test -n "$ac_ct_STRIP"; then 40454 ac_cv_prog_ac_ct_STRIP="$ac_ct_STRIP" # Let the user override the test. 40455 else 40456 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40457 for as_dir in $PATH 40458 do 40459 IFS=$as_save_IFS 40460 test -z "$as_dir" && as_dir=. 40461 for ac_exec_ext in '' $ac_executable_extensions; do 40462 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40463 ac_cv_prog_ac_ct_STRIP="$ac_prog" 40464 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40465 break 2 40466 fi 40467 done 40468 done 40469 IFS=$as_save_IFS 40470 40471 fi 40472 fi 40473 ac_ct_STRIP=$ac_cv_prog_ac_ct_STRIP 40474 if test -n "$ac_ct_STRIP"; then 40475 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_STRIP" >&5 40476 $as_echo "$ac_ct_STRIP" >&6; } 40477 else 40478 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40479 $as_echo "no" >&6; } 40480 fi 40481 40482 40483 test -n "$ac_ct_STRIP" && break 40484 done 40485 40486 if test "x$ac_ct_STRIP" = x; then 40487 STRIP="" 40488 else 40489 case $cross_compiling:$ac_tool_warned in 40490 yes:) 40491 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 40492 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 40493 ac_tool_warned=yes ;; 40494 esac 40495 STRIP=$ac_ct_STRIP 40496 fi 40497 fi 40498 40499 else 40500 # If it succeeded, then it was overridden by the user. We will use it 40501 # for the tool. 40502 40503 # First remove it from the list of overridden variables, so we can test 40504 # for unknown variables in the end. 40505 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 40506 40507 # Check if we try to supply an empty value 40508 if test "x$STRIP" = x; then 40509 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool STRIP= (no value)" >&5 40510 $as_echo "$as_me: Setting user supplied tool STRIP= (no value)" >&6;} 40511 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5 40512 $as_echo_n "checking for STRIP... " >&6; } 40513 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 40514 $as_echo "disabled" >&6; } 40515 else 40516 # Check if the provided tool contains a complete path. 40517 tool_specified="$STRIP" 40518 tool_basename="${tool_specified##*/}" 40519 if test "x$tool_basename" = "x$tool_specified"; then 40520 # A command without a complete path is provided, search $PATH. 40521 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool STRIP=$tool_basename" >&5 40522 $as_echo "$as_me: Will search for user supplied tool STRIP=$tool_basename" >&6;} 40523 # Extract the first word of "$tool_basename", so it can be a program name with args. 40524 set dummy $tool_basename; ac_word=$2 40525 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40526 $as_echo_n "checking for $ac_word... " >&6; } 40527 if ${ac_cv_path_STRIP+:} false; then : 40528 $as_echo_n "(cached) " >&6 40529 else 40530 case $STRIP in 40531 [\\/]* | ?:[\\/]*) 40532 ac_cv_path_STRIP="$STRIP" # Let the user override the test with a path. 40533 ;; 40534 *) 40535 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40536 for as_dir in $PATH 40537 do 40538 IFS=$as_save_IFS 40539 test -z "$as_dir" && as_dir=. 40540 for ac_exec_ext in '' $ac_executable_extensions; do 40541 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40542 ac_cv_path_STRIP="$as_dir/$ac_word$ac_exec_ext" 40543 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40544 break 2 40545 fi 40546 done 40547 done 40548 IFS=$as_save_IFS 40549 40550 ;; 40551 esac 40552 fi 40553 STRIP=$ac_cv_path_STRIP 40554 if test -n "$STRIP"; then 40555 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $STRIP" >&5 40556 $as_echo "$STRIP" >&6; } 40557 else 40558 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40559 $as_echo "no" >&6; } 40560 fi 40561 40562 40563 if test "x$STRIP" = x; then 40564 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 40565 fi 40566 else 40567 # Otherwise we believe it is a complete path. Use it as it is. 40568 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool STRIP=$tool_specified" >&5 40569 $as_echo "$as_me: Will use user supplied tool STRIP=$tool_specified" >&6;} 40570 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for STRIP" >&5 40571 $as_echo_n "checking for STRIP... " >&6; } 40572 if test ! -x "$tool_specified"; then 40573 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 40574 $as_echo "not found" >&6; } 40575 as_fn_error $? "User supplied tool STRIP=$tool_specified does not exist or is not executable" "$LINENO" 5 40576 fi 40577 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 40578 $as_echo "$tool_specified" >&6; } 40579 fi 40580 fi 40581 fi 40582 40583 fi 40584 40585 40586 40587 # Only process if variable expands to non-empty 40588 40589 if test "x$STRIP" != x; then 40590 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40591 40592 # First separate the path from the arguments. This will split at the first 40593 # space. 40594 complete="$STRIP" 40595 path="${complete%% *}" 40596 tmp="$complete EOL" 40597 arguments="${tmp#* }" 40598 40599 # Input might be given as Windows format, start by converting to 40600 # unix format. 40601 new_path=`$CYGPATH -u "$path"` 40602 40603 # Now try to locate executable using which 40604 new_path=`$WHICH "$new_path" 2> /dev/null` 40605 # bat and cmd files are not always considered executable in cygwin causing which 40606 # to not find them 40607 if test "x$new_path" = x \ 40608 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40609 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40610 new_path=`$CYGPATH -u "$path"` 40611 fi 40612 if test "x$new_path" = x; then 40613 # Oops. Which didn't find the executable. 40614 # The splitting of arguments from the executable at a space might have been incorrect, 40615 # since paths with space are more likely in Windows. Give it another try with the whole 40616 # argument. 40617 path="$complete" 40618 arguments="EOL" 40619 new_path=`$CYGPATH -u "$path"` 40620 new_path=`$WHICH "$new_path" 2> /dev/null` 40621 # bat and cmd files are not always considered executable in cygwin causing which 40622 # to not find them 40623 if test "x$new_path" = x \ 40624 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40625 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40626 new_path=`$CYGPATH -u "$path"` 40627 fi 40628 if test "x$new_path" = x; then 40629 # It's still not found. Now this is an unrecoverable error. 40630 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 40631 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 40632 has_space=`$ECHO "$complete" | $GREP " "` 40633 if test "x$has_space" != x; then 40634 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 40635 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 40636 fi 40637 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 40638 fi 40639 fi 40640 40641 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 40642 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 40643 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 40644 # "foo.exe" is OK but "foo" is an error. 40645 # 40646 # This test is therefore slightly more accurate than "test -f" to check for file presence. 40647 # It is also a way to make sure we got the proper file name for the real test later on. 40648 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 40649 if test "x$test_shortpath" = x; then 40650 # Short path failed, file does not exist as specified. 40651 # Try adding .exe or .cmd 40652 if test -f "${new_path}.exe"; then 40653 input_to_shortpath="${new_path}.exe" 40654 elif test -f "${new_path}.cmd"; then 40655 input_to_shortpath="${new_path}.cmd" 40656 else 40657 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$new_path\", is invalid." >&5 40658 $as_echo "$as_me: The path of STRIP, which resolves as \"$new_path\", is invalid." >&6;} 40659 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 40660 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 40661 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 40662 fi 40663 else 40664 input_to_shortpath="$new_path" 40665 fi 40666 40667 # Call helper function which possibly converts this using DOS-style short mode. 40668 # If so, the updated path is stored in $new_path. 40669 new_path="$input_to_shortpath" 40670 40671 input_path="$input_to_shortpath" 40672 # Check if we need to convert this using DOS-style short mode. If the path 40673 # contains just simple characters, use it. Otherwise (spaces, weird characters), 40674 # take no chances and rewrite it. 40675 # Note: m4 eats our [], so we need to use [ and ] instead. 40676 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 40677 if test "x$has_forbidden_chars" != x; then 40678 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 40679 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 40680 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 40681 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 40682 # Going to short mode and back again did indeed matter. Since short mode is 40683 # case insensitive, let's make it lowercase to improve readability. 40684 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 40685 # Now convert it back to Unix-style (cygpath) 40686 input_path=`$CYGPATH -u "$shortmode_path"` 40687 new_path="$input_path" 40688 fi 40689 fi 40690 40691 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 40692 if test "x$test_cygdrive_prefix" = x; then 40693 # As a simple fix, exclude /usr/bin since it's not a real path. 40694 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 40695 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 40696 # a path prefixed by /cygdrive for fixpath to work. 40697 new_path="$CYGWIN_ROOT_PATH$input_path" 40698 fi 40699 fi 40700 40701 # remove trailing .exe if any 40702 new_path="${new_path/%.exe/}" 40703 40704 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40705 40706 # First separate the path from the arguments. This will split at the first 40707 # space. 40708 complete="$STRIP" 40709 path="${complete%% *}" 40710 tmp="$complete EOL" 40711 arguments="${tmp#* }" 40712 40713 # Input might be given as Windows format, start by converting to 40714 # unix format. 40715 new_path="$path" 40716 40717 windows_path="$new_path" 40718 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40719 unix_path=`$CYGPATH -u "$windows_path"` 40720 new_path="$unix_path" 40721 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40722 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40723 new_path="$unix_path" 40724 fi 40725 40726 40727 # Now try to locate executable using which 40728 new_path=`$WHICH "$new_path" 2> /dev/null` 40729 40730 if test "x$new_path" = x; then 40731 # Oops. Which didn't find the executable. 40732 # The splitting of arguments from the executable at a space might have been incorrect, 40733 # since paths with space are more likely in Windows. Give it another try with the whole 40734 # argument. 40735 path="$complete" 40736 arguments="EOL" 40737 new_path="$path" 40738 40739 windows_path="$new_path" 40740 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40741 unix_path=`$CYGPATH -u "$windows_path"` 40742 new_path="$unix_path" 40743 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40744 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40745 new_path="$unix_path" 40746 fi 40747 40748 40749 new_path=`$WHICH "$new_path" 2> /dev/null` 40750 # bat and cmd files are not always considered executable in MSYS causing which 40751 # to not find them 40752 if test "x$new_path" = x \ 40753 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 40754 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 40755 new_path="$path" 40756 40757 windows_path="$new_path" 40758 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40759 unix_path=`$CYGPATH -u "$windows_path"` 40760 new_path="$unix_path" 40761 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40762 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40763 new_path="$unix_path" 40764 fi 40765 40766 fi 40767 40768 if test "x$new_path" = x; then 40769 # It's still not found. Now this is an unrecoverable error. 40770 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 40771 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 40772 has_space=`$ECHO "$complete" | $GREP " "` 40773 if test "x$has_space" != x; then 40774 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 40775 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 40776 fi 40777 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 40778 fi 40779 fi 40780 40781 # Now new_path has a complete unix path to the binary 40782 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 40783 # Keep paths in /bin as-is, but remove trailing .exe if any 40784 new_path="${new_path/%.exe/}" 40785 # Do not save /bin paths to all_fixpath_prefixes! 40786 else 40787 # Not in mixed or Windows style, start by that. 40788 new_path=`cmd //c echo $new_path` 40789 40790 input_path="$new_path" 40791 # Check if we need to convert this using DOS-style short mode. If the path 40792 # contains just simple characters, use it. Otherwise (spaces, weird characters), 40793 # take no chances and rewrite it. 40794 # Note: m4 eats our [], so we need to use [ and ] instead. 40795 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 40796 if test "x$has_forbidden_chars" != x; then 40797 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 40798 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 40799 fi 40800 40801 # Output is in $new_path 40802 40803 windows_path="$new_path" 40804 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 40805 unix_path=`$CYGPATH -u "$windows_path"` 40806 new_path="$unix_path" 40807 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 40808 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 40809 new_path="$unix_path" 40810 fi 40811 40812 # remove trailing .exe if any 40813 new_path="${new_path/%.exe/}" 40814 40815 # Save the first 10 bytes of this path to the storage, so fixpath can work. 40816 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 40817 fi 40818 40819 else 40820 # We're on a unix platform. Hooray! :) 40821 # First separate the path from the arguments. This will split at the first 40822 # space. 40823 complete="$STRIP" 40824 path="${complete%% *}" 40825 tmp="$complete EOL" 40826 arguments="${tmp#* }" 40827 40828 # Cannot rely on the command "which" here since it doesn't always work. 40829 is_absolute_path=`$ECHO "$path" | $GREP ^/` 40830 if test -z "$is_absolute_path"; then 40831 # Path to executable is not absolute. Find it. 40832 IFS_save="$IFS" 40833 IFS=: 40834 for p in $PATH; do 40835 if test -f "$p/$path" && test -x "$p/$path"; then 40836 new_path="$p/$path" 40837 break 40838 fi 40839 done 40840 IFS="$IFS_save" 40841 else 40842 # This is an absolute path, we can use it without further modifications. 40843 new_path="$path" 40844 fi 40845 40846 if test "x$new_path" = x; then 40847 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of STRIP, which resolves as \"$complete\", is not found." >&5 40848 $as_echo "$as_me: The path of STRIP, which resolves as \"$complete\", is not found." >&6;} 40849 has_space=`$ECHO "$complete" | $GREP " "` 40850 if test "x$has_space" != x; then 40851 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 40852 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 40853 fi 40854 as_fn_error $? "Cannot locate the the path of STRIP" "$LINENO" 5 40855 fi 40856 fi 40857 40858 # Now join together the path and the arguments once again 40859 if test "x$arguments" != xEOL; then 40860 new_complete="$new_path ${arguments% *}" 40861 else 40862 new_complete="$new_path" 40863 fi 40864 40865 if test "x$complete" != "x$new_complete"; then 40866 STRIP="$new_complete" 40867 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting STRIP to \"$new_complete\"" >&5 40868 $as_echo "$as_me: Rewriting STRIP to \"$new_complete\"" >&6;} 40869 fi 40870 fi 40871 40872 if test "x$TOOLCHAIN_TYPE" = xgcc; then 40873 40874 40875 # Publish this variable in the help. 40876 40877 40878 if [ -z "${NM+x}" ]; then 40879 # The variable is not set by user, try to locate tool using the code snippet 40880 if test -n "$ac_tool_prefix"; then 40881 for ac_prog in nm gcc-nm 40882 do 40883 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 40884 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 40885 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40886 $as_echo_n "checking for $ac_word... " >&6; } 40887 if ${ac_cv_prog_NM+:} false; then : 40888 $as_echo_n "(cached) " >&6 40889 else 40890 if test -n "$NM"; then 40891 ac_cv_prog_NM="$NM" # Let the user override the test. 40892 else 40893 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40894 for as_dir in $PATH 40895 do 40896 IFS=$as_save_IFS 40897 test -z "$as_dir" && as_dir=. 40898 for ac_exec_ext in '' $ac_executable_extensions; do 40899 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40900 ac_cv_prog_NM="$ac_tool_prefix$ac_prog" 40901 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40902 break 2 40903 fi 40904 done 40905 done 40906 IFS=$as_save_IFS 40907 40908 fi 40909 fi 40910 NM=$ac_cv_prog_NM 40911 if test -n "$NM"; then 40912 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 40913 $as_echo "$NM" >&6; } 40914 else 40915 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40916 $as_echo "no" >&6; } 40917 fi 40918 40919 40920 test -n "$NM" && break 40921 done 40922 fi 40923 if test -z "$NM"; then 40924 ac_ct_NM=$NM 40925 for ac_prog in nm gcc-nm 40926 do 40927 # Extract the first word of "$ac_prog", so it can be a program name with args. 40928 set dummy $ac_prog; ac_word=$2 40929 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40930 $as_echo_n "checking for $ac_word... " >&6; } 40931 if ${ac_cv_prog_ac_ct_NM+:} false; then : 40932 $as_echo_n "(cached) " >&6 40933 else 40934 if test -n "$ac_ct_NM"; then 40935 ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test. 40936 else 40937 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 40938 for as_dir in $PATH 40939 do 40940 IFS=$as_save_IFS 40941 test -z "$as_dir" && as_dir=. 40942 for ac_exec_ext in '' $ac_executable_extensions; do 40943 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 40944 ac_cv_prog_ac_ct_NM="$ac_prog" 40945 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 40946 break 2 40947 fi 40948 done 40949 done 40950 IFS=$as_save_IFS 40951 40952 fi 40953 fi 40954 ac_ct_NM=$ac_cv_prog_ac_ct_NM 40955 if test -n "$ac_ct_NM"; then 40956 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5 40957 $as_echo "$ac_ct_NM" >&6; } 40958 else 40959 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 40960 $as_echo "no" >&6; } 40961 fi 40962 40963 40964 test -n "$ac_ct_NM" && break 40965 done 40966 40967 if test "x$ac_ct_NM" = x; then 40968 NM="" 40969 else 40970 case $cross_compiling:$ac_tool_warned in 40971 yes:) 40972 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 40973 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 40974 ac_tool_warned=yes ;; 40975 esac 40976 NM=$ac_ct_NM 40977 fi 40978 fi 40979 40980 else 40981 # The variable is set, but is it from the command line or the environment? 40982 40983 # Try to remove the string !NM! from our list. 40984 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NM!/} 40985 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 40986 # If it failed, the variable was not from the command line. Ignore it, 40987 # but warn the user (except for BASH, which is always set by the calling BASH). 40988 if test "xNM" != xBASH; then 40989 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&5 40990 $as_echo "$as_me: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&2;} 40991 fi 40992 # Try to locate tool using the code snippet 40993 if test -n "$ac_tool_prefix"; then 40994 for ac_prog in nm gcc-nm 40995 do 40996 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 40997 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 40998 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 40999 $as_echo_n "checking for $ac_word... " >&6; } 41000 if ${ac_cv_prog_NM+:} false; then : 41001 $as_echo_n "(cached) " >&6 41002 else 41003 if test -n "$NM"; then 41004 ac_cv_prog_NM="$NM" # Let the user override the test. 41005 else 41006 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41007 for as_dir in $PATH 41008 do 41009 IFS=$as_save_IFS 41010 test -z "$as_dir" && as_dir=. 41011 for ac_exec_ext in '' $ac_executable_extensions; do 41012 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41013 ac_cv_prog_NM="$ac_tool_prefix$ac_prog" 41014 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41015 break 2 41016 fi 41017 done 41018 done 41019 IFS=$as_save_IFS 41020 41021 fi 41022 fi 41023 NM=$ac_cv_prog_NM 41024 if test -n "$NM"; then 41025 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 41026 $as_echo "$NM" >&6; } 41027 else 41028 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41029 $as_echo "no" >&6; } 41030 fi 41031 41032 41033 test -n "$NM" && break 41034 done 41035 fi 41036 if test -z "$NM"; then 41037 ac_ct_NM=$NM 41038 for ac_prog in nm gcc-nm 41039 do 41040 # Extract the first word of "$ac_prog", so it can be a program name with args. 41041 set dummy $ac_prog; ac_word=$2 41042 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41043 $as_echo_n "checking for $ac_word... " >&6; } 41044 if ${ac_cv_prog_ac_ct_NM+:} false; then : 41045 $as_echo_n "(cached) " >&6 41046 else 41047 if test -n "$ac_ct_NM"; then 41048 ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test. 41049 else 41050 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41051 for as_dir in $PATH 41052 do 41053 IFS=$as_save_IFS 41054 test -z "$as_dir" && as_dir=. 41055 for ac_exec_ext in '' $ac_executable_extensions; do 41056 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41057 ac_cv_prog_ac_ct_NM="$ac_prog" 41058 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41059 break 2 41060 fi 41061 done 41062 done 41063 IFS=$as_save_IFS 41064 41065 fi 41066 fi 41067 ac_ct_NM=$ac_cv_prog_ac_ct_NM 41068 if test -n "$ac_ct_NM"; then 41069 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5 41070 $as_echo "$ac_ct_NM" >&6; } 41071 else 41072 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41073 $as_echo "no" >&6; } 41074 fi 41075 41076 41077 test -n "$ac_ct_NM" && break 41078 done 41079 41080 if test "x$ac_ct_NM" = x; then 41081 NM="" 41082 else 41083 case $cross_compiling:$ac_tool_warned in 41084 yes:) 41085 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 41086 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 41087 ac_tool_warned=yes ;; 41088 esac 41089 NM=$ac_ct_NM 41090 fi 41091 fi 41092 41093 else 41094 # If it succeeded, then it was overridden by the user. We will use it 41095 # for the tool. 41096 41097 # First remove it from the list of overridden variables, so we can test 41098 # for unknown variables in the end. 41099 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 41100 41101 # Check if we try to supply an empty value 41102 if test "x$NM" = x; then 41103 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool NM= (no value)" >&5 41104 $as_echo "$as_me: Setting user supplied tool NM= (no value)" >&6;} 41105 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 41106 $as_echo_n "checking for NM... " >&6; } 41107 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 41108 $as_echo "disabled" >&6; } 41109 else 41110 # Check if the provided tool contains a complete path. 41111 tool_specified="$NM" 41112 tool_basename="${tool_specified##*/}" 41113 if test "x$tool_basename" = "x$tool_specified"; then 41114 # A command without a complete path is provided, search $PATH. 41115 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NM=$tool_basename" >&5 41116 $as_echo "$as_me: Will search for user supplied tool NM=$tool_basename" >&6;} 41117 # Extract the first word of "$tool_basename", so it can be a program name with args. 41118 set dummy $tool_basename; ac_word=$2 41119 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41120 $as_echo_n "checking for $ac_word... " >&6; } 41121 if ${ac_cv_path_NM+:} false; then : 41122 $as_echo_n "(cached) " >&6 41123 else 41124 case $NM in 41125 [\\/]* | ?:[\\/]*) 41126 ac_cv_path_NM="$NM" # Let the user override the test with a path. 41127 ;; 41128 *) 41129 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41130 for as_dir in $PATH 41131 do 41132 IFS=$as_save_IFS 41133 test -z "$as_dir" && as_dir=. 41134 for ac_exec_ext in '' $ac_executable_extensions; do 41135 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41136 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 41137 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41138 break 2 41139 fi 41140 done 41141 done 41142 IFS=$as_save_IFS 41143 41144 ;; 41145 esac 41146 fi 41147 NM=$ac_cv_path_NM 41148 if test -n "$NM"; then 41149 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 41150 $as_echo "$NM" >&6; } 41151 else 41152 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41153 $as_echo "no" >&6; } 41154 fi 41155 41156 41157 if test "x$NM" = x; then 41158 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 41159 fi 41160 else 41161 # Otherwise we believe it is a complete path. Use it as it is. 41162 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NM=$tool_specified" >&5 41163 $as_echo "$as_me: Will use user supplied tool NM=$tool_specified" >&6;} 41164 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 41165 $as_echo_n "checking for NM... " >&6; } 41166 if test ! -x "$tool_specified"; then 41167 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 41168 $as_echo "not found" >&6; } 41169 as_fn_error $? "User supplied tool NM=$tool_specified does not exist or is not executable" "$LINENO" 5 41170 fi 41171 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 41172 $as_echo "$tool_specified" >&6; } 41173 fi 41174 fi 41175 fi 41176 41177 fi 41178 41179 41180 else 41181 41182 41183 # Publish this variable in the help. 41184 41185 41186 if [ -z "${NM+x}" ]; then 41187 # The variable is not set by user, try to locate tool using the code snippet 41188 if test -n "$ac_tool_prefix"; then 41189 for ac_prog in nm 41190 do 41191 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 41192 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 41193 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41194 $as_echo_n "checking for $ac_word... " >&6; } 41195 if ${ac_cv_prog_NM+:} false; then : 41196 $as_echo_n "(cached) " >&6 41197 else 41198 if test -n "$NM"; then 41199 ac_cv_prog_NM="$NM" # Let the user override the test. 41200 else 41201 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41202 for as_dir in $PATH 41203 do 41204 IFS=$as_save_IFS 41205 test -z "$as_dir" && as_dir=. 41206 for ac_exec_ext in '' $ac_executable_extensions; do 41207 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41208 ac_cv_prog_NM="$ac_tool_prefix$ac_prog" 41209 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41210 break 2 41211 fi 41212 done 41213 done 41214 IFS=$as_save_IFS 41215 41216 fi 41217 fi 41218 NM=$ac_cv_prog_NM 41219 if test -n "$NM"; then 41220 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 41221 $as_echo "$NM" >&6; } 41222 else 41223 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41224 $as_echo "no" >&6; } 41225 fi 41226 41227 41228 test -n "$NM" && break 41229 done 41230 fi 41231 if test -z "$NM"; then 41232 ac_ct_NM=$NM 41233 for ac_prog in nm 41234 do 41235 # Extract the first word of "$ac_prog", so it can be a program name with args. 41236 set dummy $ac_prog; ac_word=$2 41237 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41238 $as_echo_n "checking for $ac_word... " >&6; } 41239 if ${ac_cv_prog_ac_ct_NM+:} false; then : 41240 $as_echo_n "(cached) " >&6 41241 else 41242 if test -n "$ac_ct_NM"; then 41243 ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test. 41244 else 41245 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41246 for as_dir in $PATH 41247 do 41248 IFS=$as_save_IFS 41249 test -z "$as_dir" && as_dir=. 41250 for ac_exec_ext in '' $ac_executable_extensions; do 41251 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41252 ac_cv_prog_ac_ct_NM="$ac_prog" 41253 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41254 break 2 41255 fi 41256 done 41257 done 41258 IFS=$as_save_IFS 41259 41260 fi 41261 fi 41262 ac_ct_NM=$ac_cv_prog_ac_ct_NM 41263 if test -n "$ac_ct_NM"; then 41264 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5 41265 $as_echo "$ac_ct_NM" >&6; } 41266 else 41267 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41268 $as_echo "no" >&6; } 41269 fi 41270 41271 41272 test -n "$ac_ct_NM" && break 41273 done 41274 41275 if test "x$ac_ct_NM" = x; then 41276 NM="" 41277 else 41278 case $cross_compiling:$ac_tool_warned in 41279 yes:) 41280 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 41281 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 41282 ac_tool_warned=yes ;; 41283 esac 41284 NM=$ac_ct_NM 41285 fi 41286 fi 41287 41288 else 41289 # The variable is set, but is it from the command line or the environment? 41290 41291 # Try to remove the string !NM! from our list. 41292 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!NM!/} 41293 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 41294 # If it failed, the variable was not from the command line. Ignore it, 41295 # but warn the user (except for BASH, which is always set by the calling BASH). 41296 if test "xNM" != xBASH; then 41297 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&5 41298 $as_echo "$as_me: WARNING: Ignoring value of NM from the environment. Use command line variables instead." >&2;} 41299 fi 41300 # Try to locate tool using the code snippet 41301 if test -n "$ac_tool_prefix"; then 41302 for ac_prog in nm 41303 do 41304 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 41305 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 41306 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41307 $as_echo_n "checking for $ac_word... " >&6; } 41308 if ${ac_cv_prog_NM+:} false; then : 41309 $as_echo_n "(cached) " >&6 41310 else 41311 if test -n "$NM"; then 41312 ac_cv_prog_NM="$NM" # Let the user override the test. 41313 else 41314 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41315 for as_dir in $PATH 41316 do 41317 IFS=$as_save_IFS 41318 test -z "$as_dir" && as_dir=. 41319 for ac_exec_ext in '' $ac_executable_extensions; do 41320 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41321 ac_cv_prog_NM="$ac_tool_prefix$ac_prog" 41322 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41323 break 2 41324 fi 41325 done 41326 done 41327 IFS=$as_save_IFS 41328 41329 fi 41330 fi 41331 NM=$ac_cv_prog_NM 41332 if test -n "$NM"; then 41333 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 41334 $as_echo "$NM" >&6; } 41335 else 41336 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41337 $as_echo "no" >&6; } 41338 fi 41339 41340 41341 test -n "$NM" && break 41342 done 41343 fi 41344 if test -z "$NM"; then 41345 ac_ct_NM=$NM 41346 for ac_prog in nm 41347 do 41348 # Extract the first word of "$ac_prog", so it can be a program name with args. 41349 set dummy $ac_prog; ac_word=$2 41350 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41351 $as_echo_n "checking for $ac_word... " >&6; } 41352 if ${ac_cv_prog_ac_ct_NM+:} false; then : 41353 $as_echo_n "(cached) " >&6 41354 else 41355 if test -n "$ac_ct_NM"; then 41356 ac_cv_prog_ac_ct_NM="$ac_ct_NM" # Let the user override the test. 41357 else 41358 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41359 for as_dir in $PATH 41360 do 41361 IFS=$as_save_IFS 41362 test -z "$as_dir" && as_dir=. 41363 for ac_exec_ext in '' $ac_executable_extensions; do 41364 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41365 ac_cv_prog_ac_ct_NM="$ac_prog" 41366 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41367 break 2 41368 fi 41369 done 41370 done 41371 IFS=$as_save_IFS 41372 41373 fi 41374 fi 41375 ac_ct_NM=$ac_cv_prog_ac_ct_NM 41376 if test -n "$ac_ct_NM"; then 41377 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_NM" >&5 41378 $as_echo "$ac_ct_NM" >&6; } 41379 else 41380 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41381 $as_echo "no" >&6; } 41382 fi 41383 41384 41385 test -n "$ac_ct_NM" && break 41386 done 41387 41388 if test "x$ac_ct_NM" = x; then 41389 NM="" 41390 else 41391 case $cross_compiling:$ac_tool_warned in 41392 yes:) 41393 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 41394 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 41395 ac_tool_warned=yes ;; 41396 esac 41397 NM=$ac_ct_NM 41398 fi 41399 fi 41400 41401 else 41402 # If it succeeded, then it was overridden by the user. We will use it 41403 # for the tool. 41404 41405 # First remove it from the list of overridden variables, so we can test 41406 # for unknown variables in the end. 41407 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 41408 41409 # Check if we try to supply an empty value 41410 if test "x$NM" = x; then 41411 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool NM= (no value)" >&5 41412 $as_echo "$as_me: Setting user supplied tool NM= (no value)" >&6;} 41413 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 41414 $as_echo_n "checking for NM... " >&6; } 41415 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 41416 $as_echo "disabled" >&6; } 41417 else 41418 # Check if the provided tool contains a complete path. 41419 tool_specified="$NM" 41420 tool_basename="${tool_specified##*/}" 41421 if test "x$tool_basename" = "x$tool_specified"; then 41422 # A command without a complete path is provided, search $PATH. 41423 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool NM=$tool_basename" >&5 41424 $as_echo "$as_me: Will search for user supplied tool NM=$tool_basename" >&6;} 41425 # Extract the first word of "$tool_basename", so it can be a program name with args. 41426 set dummy $tool_basename; ac_word=$2 41427 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41428 $as_echo_n "checking for $ac_word... " >&6; } 41429 if ${ac_cv_path_NM+:} false; then : 41430 $as_echo_n "(cached) " >&6 41431 else 41432 case $NM in 41433 [\\/]* | ?:[\\/]*) 41434 ac_cv_path_NM="$NM" # Let the user override the test with a path. 41435 ;; 41436 *) 41437 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41438 for as_dir in $PATH 41439 do 41440 IFS=$as_save_IFS 41441 test -z "$as_dir" && as_dir=. 41442 for ac_exec_ext in '' $ac_executable_extensions; do 41443 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41444 ac_cv_path_NM="$as_dir/$ac_word$ac_exec_ext" 41445 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41446 break 2 41447 fi 41448 done 41449 done 41450 IFS=$as_save_IFS 41451 41452 ;; 41453 esac 41454 fi 41455 NM=$ac_cv_path_NM 41456 if test -n "$NM"; then 41457 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NM" >&5 41458 $as_echo "$NM" >&6; } 41459 else 41460 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41461 $as_echo "no" >&6; } 41462 fi 41463 41464 41465 if test "x$NM" = x; then 41466 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 41467 fi 41468 else 41469 # Otherwise we believe it is a complete path. Use it as it is. 41470 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool NM=$tool_specified" >&5 41471 $as_echo "$as_me: Will use user supplied tool NM=$tool_specified" >&6;} 41472 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for NM" >&5 41473 $as_echo_n "checking for NM... " >&6; } 41474 if test ! -x "$tool_specified"; then 41475 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 41476 $as_echo "not found" >&6; } 41477 as_fn_error $? "User supplied tool NM=$tool_specified does not exist or is not executable" "$LINENO" 5 41478 fi 41479 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 41480 $as_echo "$tool_specified" >&6; } 41481 fi 41482 fi 41483 fi 41484 41485 fi 41486 41487 41488 fi 41489 41490 # Only process if variable expands to non-empty 41491 41492 if test "x$NM" != x; then 41493 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41494 41495 # First separate the path from the arguments. This will split at the first 41496 # space. 41497 complete="$NM" 41498 path="${complete%% *}" 41499 tmp="$complete EOL" 41500 arguments="${tmp#* }" 41501 41502 # Input might be given as Windows format, start by converting to 41503 # unix format. 41504 new_path=`$CYGPATH -u "$path"` 41505 41506 # Now try to locate executable using which 41507 new_path=`$WHICH "$new_path" 2> /dev/null` 41508 # bat and cmd files are not always considered executable in cygwin causing which 41509 # to not find them 41510 if test "x$new_path" = x \ 41511 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 41512 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 41513 new_path=`$CYGPATH -u "$path"` 41514 fi 41515 if test "x$new_path" = x; then 41516 # Oops. Which didn't find the executable. 41517 # The splitting of arguments from the executable at a space might have been incorrect, 41518 # since paths with space are more likely in Windows. Give it another try with the whole 41519 # argument. 41520 path="$complete" 41521 arguments="EOL" 41522 new_path=`$CYGPATH -u "$path"` 41523 new_path=`$WHICH "$new_path" 2> /dev/null` 41524 # bat and cmd files are not always considered executable in cygwin causing which 41525 # to not find them 41526 if test "x$new_path" = x \ 41527 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 41528 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 41529 new_path=`$CYGPATH -u "$path"` 41530 fi 41531 if test "x$new_path" = x; then 41532 # It's still not found. Now this is an unrecoverable error. 41533 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 41534 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 41535 has_space=`$ECHO "$complete" | $GREP " "` 41536 if test "x$has_space" != x; then 41537 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 41538 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 41539 fi 41540 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 41541 fi 41542 fi 41543 41544 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 41545 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 41546 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 41547 # "foo.exe" is OK but "foo" is an error. 41548 # 41549 # This test is therefore slightly more accurate than "test -f" to check for file presence. 41550 # It is also a way to make sure we got the proper file name for the real test later on. 41551 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 41552 if test "x$test_shortpath" = x; then 41553 # Short path failed, file does not exist as specified. 41554 # Try adding .exe or .cmd 41555 if test -f "${new_path}.exe"; then 41556 input_to_shortpath="${new_path}.exe" 41557 elif test -f "${new_path}.cmd"; then 41558 input_to_shortpath="${new_path}.cmd" 41559 else 41560 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$new_path\", is invalid." >&5 41561 $as_echo "$as_me: The path of NM, which resolves as \"$new_path\", is invalid." >&6;} 41562 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 41563 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 41564 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 41565 fi 41566 else 41567 input_to_shortpath="$new_path" 41568 fi 41569 41570 # Call helper function which possibly converts this using DOS-style short mode. 41571 # If so, the updated path is stored in $new_path. 41572 new_path="$input_to_shortpath" 41573 41574 input_path="$input_to_shortpath" 41575 # Check if we need to convert this using DOS-style short mode. If the path 41576 # contains just simple characters, use it. Otherwise (spaces, weird characters), 41577 # take no chances and rewrite it. 41578 # Note: m4 eats our [], so we need to use [ and ] instead. 41579 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 41580 if test "x$has_forbidden_chars" != x; then 41581 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 41582 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 41583 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 41584 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 41585 # Going to short mode and back again did indeed matter. Since short mode is 41586 # case insensitive, let's make it lowercase to improve readability. 41587 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 41588 # Now convert it back to Unix-style (cygpath) 41589 input_path=`$CYGPATH -u "$shortmode_path"` 41590 new_path="$input_path" 41591 fi 41592 fi 41593 41594 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 41595 if test "x$test_cygdrive_prefix" = x; then 41596 # As a simple fix, exclude /usr/bin since it's not a real path. 41597 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 41598 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 41599 # a path prefixed by /cygdrive for fixpath to work. 41600 new_path="$CYGWIN_ROOT_PATH$input_path" 41601 fi 41602 fi 41603 41604 # remove trailing .exe if any 41605 new_path="${new_path/%.exe/}" 41606 41607 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41608 41609 # First separate the path from the arguments. This will split at the first 41610 # space. 41611 complete="$NM" 41612 path="${complete%% *}" 41613 tmp="$complete EOL" 41614 arguments="${tmp#* }" 41615 41616 # Input might be given as Windows format, start by converting to 41617 # unix format. 41618 new_path="$path" 41619 41620 windows_path="$new_path" 41621 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41622 unix_path=`$CYGPATH -u "$windows_path"` 41623 new_path="$unix_path" 41624 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41625 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41626 new_path="$unix_path" 41627 fi 41628 41629 41630 # Now try to locate executable using which 41631 new_path=`$WHICH "$new_path" 2> /dev/null` 41632 41633 if test "x$new_path" = x; then 41634 # Oops. Which didn't find the executable. 41635 # The splitting of arguments from the executable at a space might have been incorrect, 41636 # since paths with space are more likely in Windows. Give it another try with the whole 41637 # argument. 41638 path="$complete" 41639 arguments="EOL" 41640 new_path="$path" 41641 41642 windows_path="$new_path" 41643 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41644 unix_path=`$CYGPATH -u "$windows_path"` 41645 new_path="$unix_path" 41646 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41647 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41648 new_path="$unix_path" 41649 fi 41650 41651 41652 new_path=`$WHICH "$new_path" 2> /dev/null` 41653 # bat and cmd files are not always considered executable in MSYS causing which 41654 # to not find them 41655 if test "x$new_path" = x \ 41656 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 41657 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 41658 new_path="$path" 41659 41660 windows_path="$new_path" 41661 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41662 unix_path=`$CYGPATH -u "$windows_path"` 41663 new_path="$unix_path" 41664 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41665 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41666 new_path="$unix_path" 41667 fi 41668 41669 fi 41670 41671 if test "x$new_path" = x; then 41672 # It's still not found. Now this is an unrecoverable error. 41673 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 41674 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 41675 has_space=`$ECHO "$complete" | $GREP " "` 41676 if test "x$has_space" != x; then 41677 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 41678 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 41679 fi 41680 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 41681 fi 41682 fi 41683 41684 # Now new_path has a complete unix path to the binary 41685 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 41686 # Keep paths in /bin as-is, but remove trailing .exe if any 41687 new_path="${new_path/%.exe/}" 41688 # Do not save /bin paths to all_fixpath_prefixes! 41689 else 41690 # Not in mixed or Windows style, start by that. 41691 new_path=`cmd //c echo $new_path` 41692 41693 input_path="$new_path" 41694 # Check if we need to convert this using DOS-style short mode. If the path 41695 # contains just simple characters, use it. Otherwise (spaces, weird characters), 41696 # take no chances and rewrite it. 41697 # Note: m4 eats our [], so we need to use [ and ] instead. 41698 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 41699 if test "x$has_forbidden_chars" != x; then 41700 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 41701 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 41702 fi 41703 41704 # Output is in $new_path 41705 41706 windows_path="$new_path" 41707 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 41708 unix_path=`$CYGPATH -u "$windows_path"` 41709 new_path="$unix_path" 41710 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 41711 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 41712 new_path="$unix_path" 41713 fi 41714 41715 # remove trailing .exe if any 41716 new_path="${new_path/%.exe/}" 41717 41718 # Save the first 10 bytes of this path to the storage, so fixpath can work. 41719 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 41720 fi 41721 41722 else 41723 # We're on a unix platform. Hooray! :) 41724 # First separate the path from the arguments. This will split at the first 41725 # space. 41726 complete="$NM" 41727 path="${complete%% *}" 41728 tmp="$complete EOL" 41729 arguments="${tmp#* }" 41730 41731 # Cannot rely on the command "which" here since it doesn't always work. 41732 is_absolute_path=`$ECHO "$path" | $GREP ^/` 41733 if test -z "$is_absolute_path"; then 41734 # Path to executable is not absolute. Find it. 41735 IFS_save="$IFS" 41736 IFS=: 41737 for p in $PATH; do 41738 if test -f "$p/$path" && test -x "$p/$path"; then 41739 new_path="$p/$path" 41740 break 41741 fi 41742 done 41743 IFS="$IFS_save" 41744 else 41745 # This is an absolute path, we can use it without further modifications. 41746 new_path="$path" 41747 fi 41748 41749 if test "x$new_path" = x; then 41750 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of NM, which resolves as \"$complete\", is not found." >&5 41751 $as_echo "$as_me: The path of NM, which resolves as \"$complete\", is not found." >&6;} 41752 has_space=`$ECHO "$complete" | $GREP " "` 41753 if test "x$has_space" != x; then 41754 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 41755 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 41756 fi 41757 as_fn_error $? "Cannot locate the the path of NM" "$LINENO" 5 41758 fi 41759 fi 41760 41761 # Now join together the path and the arguments once again 41762 if test "x$arguments" != xEOL; then 41763 new_complete="$new_path ${arguments% *}" 41764 else 41765 new_complete="$new_path" 41766 fi 41767 41768 if test "x$complete" != "x$new_complete"; then 41769 NM="$new_complete" 41770 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting NM to \"$new_complete\"" >&5 41771 $as_echo "$as_me: Rewriting NM to \"$new_complete\"" >&6;} 41772 fi 41773 fi 41774 41775 GNM="$NM" 41776 41777 fi 41778 41779 # objcopy is used for moving debug symbols to separate files when 41780 # full debug symbols are enabled. 41781 if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xlinux; then 41782 41783 41784 # Publish this variable in the help. 41785 41786 41787 if [ -z "${OBJCOPY+x}" ]; then 41788 # The variable is not set by user, try to locate tool using the code snippet 41789 if test -n "$ac_tool_prefix"; then 41790 for ac_prog in gobjcopy objcopy 41791 do 41792 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 41793 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 41794 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41795 $as_echo_n "checking for $ac_word... " >&6; } 41796 if ${ac_cv_prog_OBJCOPY+:} false; then : 41797 $as_echo_n "(cached) " >&6 41798 else 41799 if test -n "$OBJCOPY"; then 41800 ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test. 41801 else 41802 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41803 for as_dir in $PATH 41804 do 41805 IFS=$as_save_IFS 41806 test -z "$as_dir" && as_dir=. 41807 for ac_exec_ext in '' $ac_executable_extensions; do 41808 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41809 ac_cv_prog_OBJCOPY="$ac_tool_prefix$ac_prog" 41810 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41811 break 2 41812 fi 41813 done 41814 done 41815 IFS=$as_save_IFS 41816 41817 fi 41818 fi 41819 OBJCOPY=$ac_cv_prog_OBJCOPY 41820 if test -n "$OBJCOPY"; then 41821 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5 41822 $as_echo "$OBJCOPY" >&6; } 41823 else 41824 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41825 $as_echo "no" >&6; } 41826 fi 41827 41828 41829 test -n "$OBJCOPY" && break 41830 done 41831 fi 41832 if test -z "$OBJCOPY"; then 41833 ac_ct_OBJCOPY=$OBJCOPY 41834 for ac_prog in gobjcopy objcopy 41835 do 41836 # Extract the first word of "$ac_prog", so it can be a program name with args. 41837 set dummy $ac_prog; ac_word=$2 41838 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41839 $as_echo_n "checking for $ac_word... " >&6; } 41840 if ${ac_cv_prog_ac_ct_OBJCOPY+:} false; then : 41841 $as_echo_n "(cached) " >&6 41842 else 41843 if test -n "$ac_ct_OBJCOPY"; then 41844 ac_cv_prog_ac_ct_OBJCOPY="$ac_ct_OBJCOPY" # Let the user override the test. 41845 else 41846 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41847 for as_dir in $PATH 41848 do 41849 IFS=$as_save_IFS 41850 test -z "$as_dir" && as_dir=. 41851 for ac_exec_ext in '' $ac_executable_extensions; do 41852 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41853 ac_cv_prog_ac_ct_OBJCOPY="$ac_prog" 41854 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41855 break 2 41856 fi 41857 done 41858 done 41859 IFS=$as_save_IFS 41860 41861 fi 41862 fi 41863 ac_ct_OBJCOPY=$ac_cv_prog_ac_ct_OBJCOPY 41864 if test -n "$ac_ct_OBJCOPY"; then 41865 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJCOPY" >&5 41866 $as_echo "$ac_ct_OBJCOPY" >&6; } 41867 else 41868 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41869 $as_echo "no" >&6; } 41870 fi 41871 41872 41873 test -n "$ac_ct_OBJCOPY" && break 41874 done 41875 41876 if test "x$ac_ct_OBJCOPY" = x; then 41877 OBJCOPY="" 41878 else 41879 case $cross_compiling:$ac_tool_warned in 41880 yes:) 41881 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 41882 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 41883 ac_tool_warned=yes ;; 41884 esac 41885 OBJCOPY=$ac_ct_OBJCOPY 41886 fi 41887 fi 41888 41889 else 41890 # The variable is set, but is it from the command line or the environment? 41891 41892 # Try to remove the string !OBJCOPY! from our list. 41893 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!OBJCOPY!/} 41894 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 41895 # If it failed, the variable was not from the command line. Ignore it, 41896 # but warn the user (except for BASH, which is always set by the calling BASH). 41897 if test "xOBJCOPY" != xBASH; then 41898 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of OBJCOPY from the environment. Use command line variables instead." >&5 41899 $as_echo "$as_me: WARNING: Ignoring value of OBJCOPY from the environment. Use command line variables instead." >&2;} 41900 fi 41901 # Try to locate tool using the code snippet 41902 if test -n "$ac_tool_prefix"; then 41903 for ac_prog in gobjcopy objcopy 41904 do 41905 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 41906 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 41907 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41908 $as_echo_n "checking for $ac_word... " >&6; } 41909 if ${ac_cv_prog_OBJCOPY+:} false; then : 41910 $as_echo_n "(cached) " >&6 41911 else 41912 if test -n "$OBJCOPY"; then 41913 ac_cv_prog_OBJCOPY="$OBJCOPY" # Let the user override the test. 41914 else 41915 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41916 for as_dir in $PATH 41917 do 41918 IFS=$as_save_IFS 41919 test -z "$as_dir" && as_dir=. 41920 for ac_exec_ext in '' $ac_executable_extensions; do 41921 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41922 ac_cv_prog_OBJCOPY="$ac_tool_prefix$ac_prog" 41923 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41924 break 2 41925 fi 41926 done 41927 done 41928 IFS=$as_save_IFS 41929 41930 fi 41931 fi 41932 OBJCOPY=$ac_cv_prog_OBJCOPY 41933 if test -n "$OBJCOPY"; then 41934 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5 41935 $as_echo "$OBJCOPY" >&6; } 41936 else 41937 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41938 $as_echo "no" >&6; } 41939 fi 41940 41941 41942 test -n "$OBJCOPY" && break 41943 done 41944 fi 41945 if test -z "$OBJCOPY"; then 41946 ac_ct_OBJCOPY=$OBJCOPY 41947 for ac_prog in gobjcopy objcopy 41948 do 41949 # Extract the first word of "$ac_prog", so it can be a program name with args. 41950 set dummy $ac_prog; ac_word=$2 41951 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 41952 $as_echo_n "checking for $ac_word... " >&6; } 41953 if ${ac_cv_prog_ac_ct_OBJCOPY+:} false; then : 41954 $as_echo_n "(cached) " >&6 41955 else 41956 if test -n "$ac_ct_OBJCOPY"; then 41957 ac_cv_prog_ac_ct_OBJCOPY="$ac_ct_OBJCOPY" # Let the user override the test. 41958 else 41959 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 41960 for as_dir in $PATH 41961 do 41962 IFS=$as_save_IFS 41963 test -z "$as_dir" && as_dir=. 41964 for ac_exec_ext in '' $ac_executable_extensions; do 41965 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 41966 ac_cv_prog_ac_ct_OBJCOPY="$ac_prog" 41967 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 41968 break 2 41969 fi 41970 done 41971 done 41972 IFS=$as_save_IFS 41973 41974 fi 41975 fi 41976 ac_ct_OBJCOPY=$ac_cv_prog_ac_ct_OBJCOPY 41977 if test -n "$ac_ct_OBJCOPY"; then 41978 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJCOPY" >&5 41979 $as_echo "$ac_ct_OBJCOPY" >&6; } 41980 else 41981 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 41982 $as_echo "no" >&6; } 41983 fi 41984 41985 41986 test -n "$ac_ct_OBJCOPY" && break 41987 done 41988 41989 if test "x$ac_ct_OBJCOPY" = x; then 41990 OBJCOPY="" 41991 else 41992 case $cross_compiling:$ac_tool_warned in 41993 yes:) 41994 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 41995 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 41996 ac_tool_warned=yes ;; 41997 esac 41998 OBJCOPY=$ac_ct_OBJCOPY 41999 fi 42000 fi 42001 42002 else 42003 # If it succeeded, then it was overridden by the user. We will use it 42004 # for the tool. 42005 42006 # First remove it from the list of overridden variables, so we can test 42007 # for unknown variables in the end. 42008 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 42009 42010 # Check if we try to supply an empty value 42011 if test "x$OBJCOPY" = x; then 42012 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool OBJCOPY= (no value)" >&5 42013 $as_echo "$as_me: Setting user supplied tool OBJCOPY= (no value)" >&6;} 42014 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJCOPY" >&5 42015 $as_echo_n "checking for OBJCOPY... " >&6; } 42016 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 42017 $as_echo "disabled" >&6; } 42018 else 42019 # Check if the provided tool contains a complete path. 42020 tool_specified="$OBJCOPY" 42021 tool_basename="${tool_specified##*/}" 42022 if test "x$tool_basename" = "x$tool_specified"; then 42023 # A command without a complete path is provided, search $PATH. 42024 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool OBJCOPY=$tool_basename" >&5 42025 $as_echo "$as_me: Will search for user supplied tool OBJCOPY=$tool_basename" >&6;} 42026 # Extract the first word of "$tool_basename", so it can be a program name with args. 42027 set dummy $tool_basename; ac_word=$2 42028 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42029 $as_echo_n "checking for $ac_word... " >&6; } 42030 if ${ac_cv_path_OBJCOPY+:} false; then : 42031 $as_echo_n "(cached) " >&6 42032 else 42033 case $OBJCOPY in 42034 [\\/]* | ?:[\\/]*) 42035 ac_cv_path_OBJCOPY="$OBJCOPY" # Let the user override the test with a path. 42036 ;; 42037 *) 42038 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42039 for as_dir in $PATH 42040 do 42041 IFS=$as_save_IFS 42042 test -z "$as_dir" && as_dir=. 42043 for ac_exec_ext in '' $ac_executable_extensions; do 42044 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42045 ac_cv_path_OBJCOPY="$as_dir/$ac_word$ac_exec_ext" 42046 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42047 break 2 42048 fi 42049 done 42050 done 42051 IFS=$as_save_IFS 42052 42053 ;; 42054 esac 42055 fi 42056 OBJCOPY=$ac_cv_path_OBJCOPY 42057 if test -n "$OBJCOPY"; then 42058 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJCOPY" >&5 42059 $as_echo "$OBJCOPY" >&6; } 42060 else 42061 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42062 $as_echo "no" >&6; } 42063 fi 42064 42065 42066 if test "x$OBJCOPY" = x; then 42067 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 42068 fi 42069 else 42070 # Otherwise we believe it is a complete path. Use it as it is. 42071 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool OBJCOPY=$tool_specified" >&5 42072 $as_echo "$as_me: Will use user supplied tool OBJCOPY=$tool_specified" >&6;} 42073 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJCOPY" >&5 42074 $as_echo_n "checking for OBJCOPY... " >&6; } 42075 if test ! -x "$tool_specified"; then 42076 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 42077 $as_echo "not found" >&6; } 42078 as_fn_error $? "User supplied tool OBJCOPY=$tool_specified does not exist or is not executable" "$LINENO" 5 42079 fi 42080 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 42081 $as_echo "$tool_specified" >&6; } 42082 fi 42083 fi 42084 fi 42085 42086 fi 42087 42088 42089 # Only call fixup if objcopy was found. 42090 if test -n "$OBJCOPY"; then 42091 42092 # Only process if variable expands to non-empty 42093 42094 if test "x$OBJCOPY" != x; then 42095 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42096 42097 # First separate the path from the arguments. This will split at the first 42098 # space. 42099 complete="$OBJCOPY" 42100 path="${complete%% *}" 42101 tmp="$complete EOL" 42102 arguments="${tmp#* }" 42103 42104 # Input might be given as Windows format, start by converting to 42105 # unix format. 42106 new_path=`$CYGPATH -u "$path"` 42107 42108 # Now try to locate executable using which 42109 new_path=`$WHICH "$new_path" 2> /dev/null` 42110 # bat and cmd files are not always considered executable in cygwin causing which 42111 # to not find them 42112 if test "x$new_path" = x \ 42113 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 42114 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 42115 new_path=`$CYGPATH -u "$path"` 42116 fi 42117 if test "x$new_path" = x; then 42118 # Oops. Which didn't find the executable. 42119 # The splitting of arguments from the executable at a space might have been incorrect, 42120 # since paths with space are more likely in Windows. Give it another try with the whole 42121 # argument. 42122 path="$complete" 42123 arguments="EOL" 42124 new_path=`$CYGPATH -u "$path"` 42125 new_path=`$WHICH "$new_path" 2> /dev/null` 42126 # bat and cmd files are not always considered executable in cygwin causing which 42127 # to not find them 42128 if test "x$new_path" = x \ 42129 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 42130 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 42131 new_path=`$CYGPATH -u "$path"` 42132 fi 42133 if test "x$new_path" = x; then 42134 # It's still not found. Now this is an unrecoverable error. 42135 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5 42136 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 42137 has_space=`$ECHO "$complete" | $GREP " "` 42138 if test "x$has_space" != x; then 42139 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 42140 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 42141 fi 42142 as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5 42143 fi 42144 fi 42145 42146 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 42147 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 42148 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 42149 # "foo.exe" is OK but "foo" is an error. 42150 # 42151 # This test is therefore slightly more accurate than "test -f" to check for file presence. 42152 # It is also a way to make sure we got the proper file name for the real test later on. 42153 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 42154 if test "x$test_shortpath" = x; then 42155 # Short path failed, file does not exist as specified. 42156 # Try adding .exe or .cmd 42157 if test -f "${new_path}.exe"; then 42158 input_to_shortpath="${new_path}.exe" 42159 elif test -f "${new_path}.cmd"; then 42160 input_to_shortpath="${new_path}.cmd" 42161 else 42162 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$new_path\", is invalid." >&5 42163 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$new_path\", is invalid." >&6;} 42164 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 42165 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 42166 as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5 42167 fi 42168 else 42169 input_to_shortpath="$new_path" 42170 fi 42171 42172 # Call helper function which possibly converts this using DOS-style short mode. 42173 # If so, the updated path is stored in $new_path. 42174 new_path="$input_to_shortpath" 42175 42176 input_path="$input_to_shortpath" 42177 # Check if we need to convert this using DOS-style short mode. If the path 42178 # contains just simple characters, use it. Otherwise (spaces, weird characters), 42179 # take no chances and rewrite it. 42180 # Note: m4 eats our [], so we need to use [ and ] instead. 42181 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 42182 if test "x$has_forbidden_chars" != x; then 42183 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 42184 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 42185 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 42186 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 42187 # Going to short mode and back again did indeed matter. Since short mode is 42188 # case insensitive, let's make it lowercase to improve readability. 42189 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 42190 # Now convert it back to Unix-style (cygpath) 42191 input_path=`$CYGPATH -u "$shortmode_path"` 42192 new_path="$input_path" 42193 fi 42194 fi 42195 42196 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 42197 if test "x$test_cygdrive_prefix" = x; then 42198 # As a simple fix, exclude /usr/bin since it's not a real path. 42199 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 42200 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 42201 # a path prefixed by /cygdrive for fixpath to work. 42202 new_path="$CYGWIN_ROOT_PATH$input_path" 42203 fi 42204 fi 42205 42206 # remove trailing .exe if any 42207 new_path="${new_path/%.exe/}" 42208 42209 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42210 42211 # First separate the path from the arguments. This will split at the first 42212 # space. 42213 complete="$OBJCOPY" 42214 path="${complete%% *}" 42215 tmp="$complete EOL" 42216 arguments="${tmp#* }" 42217 42218 # Input might be given as Windows format, start by converting to 42219 # unix format. 42220 new_path="$path" 42221 42222 windows_path="$new_path" 42223 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42224 unix_path=`$CYGPATH -u "$windows_path"` 42225 new_path="$unix_path" 42226 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42227 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42228 new_path="$unix_path" 42229 fi 42230 42231 42232 # Now try to locate executable using which 42233 new_path=`$WHICH "$new_path" 2> /dev/null` 42234 42235 if test "x$new_path" = x; then 42236 # Oops. Which didn't find the executable. 42237 # The splitting of arguments from the executable at a space might have been incorrect, 42238 # since paths with space are more likely in Windows. Give it another try with the whole 42239 # argument. 42240 path="$complete" 42241 arguments="EOL" 42242 new_path="$path" 42243 42244 windows_path="$new_path" 42245 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42246 unix_path=`$CYGPATH -u "$windows_path"` 42247 new_path="$unix_path" 42248 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42249 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42250 new_path="$unix_path" 42251 fi 42252 42253 42254 new_path=`$WHICH "$new_path" 2> /dev/null` 42255 # bat and cmd files are not always considered executable in MSYS causing which 42256 # to not find them 42257 if test "x$new_path" = x \ 42258 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 42259 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 42260 new_path="$path" 42261 42262 windows_path="$new_path" 42263 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42264 unix_path=`$CYGPATH -u "$windows_path"` 42265 new_path="$unix_path" 42266 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42267 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42268 new_path="$unix_path" 42269 fi 42270 42271 fi 42272 42273 if test "x$new_path" = x; then 42274 # It's still not found. Now this is an unrecoverable error. 42275 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5 42276 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 42277 has_space=`$ECHO "$complete" | $GREP " "` 42278 if test "x$has_space" != x; then 42279 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 42280 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 42281 fi 42282 as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5 42283 fi 42284 fi 42285 42286 # Now new_path has a complete unix path to the binary 42287 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 42288 # Keep paths in /bin as-is, but remove trailing .exe if any 42289 new_path="${new_path/%.exe/}" 42290 # Do not save /bin paths to all_fixpath_prefixes! 42291 else 42292 # Not in mixed or Windows style, start by that. 42293 new_path=`cmd //c echo $new_path` 42294 42295 input_path="$new_path" 42296 # Check if we need to convert this using DOS-style short mode. If the path 42297 # contains just simple characters, use it. Otherwise (spaces, weird characters), 42298 # take no chances and rewrite it. 42299 # Note: m4 eats our [], so we need to use [ and ] instead. 42300 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 42301 if test "x$has_forbidden_chars" != x; then 42302 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 42303 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 42304 fi 42305 42306 # Output is in $new_path 42307 42308 windows_path="$new_path" 42309 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42310 unix_path=`$CYGPATH -u "$windows_path"` 42311 new_path="$unix_path" 42312 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42313 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42314 new_path="$unix_path" 42315 fi 42316 42317 # remove trailing .exe if any 42318 new_path="${new_path/%.exe/}" 42319 42320 # Save the first 10 bytes of this path to the storage, so fixpath can work. 42321 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 42322 fi 42323 42324 else 42325 # We're on a unix platform. Hooray! :) 42326 # First separate the path from the arguments. This will split at the first 42327 # space. 42328 complete="$OBJCOPY" 42329 path="${complete%% *}" 42330 tmp="$complete EOL" 42331 arguments="${tmp#* }" 42332 42333 # Cannot rely on the command "which" here since it doesn't always work. 42334 is_absolute_path=`$ECHO "$path" | $GREP ^/` 42335 if test -z "$is_absolute_path"; then 42336 # Path to executable is not absolute. Find it. 42337 IFS_save="$IFS" 42338 IFS=: 42339 for p in $PATH; do 42340 if test -f "$p/$path" && test -x "$p/$path"; then 42341 new_path="$p/$path" 42342 break 42343 fi 42344 done 42345 IFS="$IFS_save" 42346 else 42347 # This is an absolute path, we can use it without further modifications. 42348 new_path="$path" 42349 fi 42350 42351 if test "x$new_path" = x; then 42352 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&5 42353 $as_echo "$as_me: The path of OBJCOPY, which resolves as \"$complete\", is not found." >&6;} 42354 has_space=`$ECHO "$complete" | $GREP " "` 42355 if test "x$has_space" != x; then 42356 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 42357 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 42358 fi 42359 as_fn_error $? "Cannot locate the the path of OBJCOPY" "$LINENO" 5 42360 fi 42361 fi 42362 42363 # Now join together the path and the arguments once again 42364 if test "x$arguments" != xEOL; then 42365 new_complete="$new_path ${arguments% *}" 42366 else 42367 new_complete="$new_path" 42368 fi 42369 42370 if test "x$complete" != "x$new_complete"; then 42371 OBJCOPY="$new_complete" 42372 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OBJCOPY to \"$new_complete\"" >&5 42373 $as_echo "$as_me: Rewriting OBJCOPY to \"$new_complete\"" >&6;} 42374 fi 42375 fi 42376 42377 if test "x$OPENJDK_BUILD_OS" = xsolaris; then 42378 # objcopy prior to 2.21.1 on solaris is broken and is not usable. 42379 # Rewrite objcopy version output to VALID_VERSION or BAD_VERSION. 42380 # - version number is last blank separate word on first line 42381 # - version number formats that have been seen: 42382 # - <major>.<minor> 42383 # - <major>.<minor>.<micro> 42384 OBJCOPY_VERSION=`$OBJCOPY --version | $HEAD -n 1` 42385 # The outer [ ] is to prevent m4 from eating the [] in the sed expression. 42386 OBJCOPY_VERSION_CHECK=`$ECHO $OBJCOPY_VERSION | $SED -n \ 42387 -e 's/.* //' \ 42388 -e '/^[01]\./b bad' \ 42389 -e '/^2\./{' \ 42390 -e ' s/^2\.//' \ 42391 -e ' /^[0-9]$/b bad' \ 42392 -e ' /^[0-9]\./b bad' \ 42393 -e ' /^1[0-9]$/b bad' \ 42394 -e ' /^1[0-9]\./b bad' \ 42395 -e ' /^20\./b bad' \ 42396 -e ' /^21\.0$/b bad' \ 42397 -e ' /^21\.0\./b bad' \ 42398 -e '}' \ 42399 -e ':good' \ 42400 -e 's/.*/VALID_VERSION/p' \ 42401 -e 'q' \ 42402 -e ':bad' \ 42403 -e 's/.*/BAD_VERSION/p' \ 42404 -e 'q'` 42405 if test "x$OBJCOPY_VERSION_CHECK" = xBAD_VERSION; then 42406 OBJCOPY= 42407 { $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 42408 $as_echo "$as_me: WARNING: Ignoring found objcopy since it is broken (prior to 2.21.1). No debug symbols will be generated." >&2;} 42409 { $as_echo "$as_me:${as_lineno-$LINENO}: objcopy reports version $OBJCOPY_VERSION" >&5 42410 $as_echo "$as_me: objcopy reports version $OBJCOPY_VERSION" >&6;} 42411 { $as_echo "$as_me:${as_lineno-$LINENO}: Note: patch 149063-01 or newer contains the correct Solaris 10 SPARC version" >&5 42412 $as_echo "$as_me: Note: patch 149063-01 or newer contains the correct Solaris 10 SPARC version" >&6;} 42413 { $as_echo "$as_me:${as_lineno-$LINENO}: Note: patch 149064-01 or newer contains the correct Solaris 10 X86 version" >&5 42414 $as_echo "$as_me: Note: patch 149064-01 or newer contains the correct Solaris 10 X86 version" >&6;} 42415 { $as_echo "$as_me:${as_lineno-$LINENO}: Note: Solaris 11 Update 1 contains the correct version" >&5 42416 $as_echo "$as_me: Note: Solaris 11 Update 1 contains the correct version" >&6;} 42417 fi 42418 fi 42419 fi 42420 fi 42421 42422 42423 42424 # Publish this variable in the help. 42425 42426 42427 if [ -z "${OBJDUMP+x}" ]; then 42428 # The variable is not set by user, try to locate tool using the code snippet 42429 if test -n "$ac_tool_prefix"; then 42430 for ac_prog in gobjdump objdump 42431 do 42432 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 42433 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 42434 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42435 $as_echo_n "checking for $ac_word... " >&6; } 42436 if ${ac_cv_prog_OBJDUMP+:} false; then : 42437 $as_echo_n "(cached) " >&6 42438 else 42439 if test -n "$OBJDUMP"; then 42440 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. 42441 else 42442 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42443 for as_dir in $PATH 42444 do 42445 IFS=$as_save_IFS 42446 test -z "$as_dir" && as_dir=. 42447 for ac_exec_ext in '' $ac_executable_extensions; do 42448 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42449 ac_cv_prog_OBJDUMP="$ac_tool_prefix$ac_prog" 42450 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42451 break 2 42452 fi 42453 done 42454 done 42455 IFS=$as_save_IFS 42456 42457 fi 42458 fi 42459 OBJDUMP=$ac_cv_prog_OBJDUMP 42460 if test -n "$OBJDUMP"; then 42461 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 42462 $as_echo "$OBJDUMP" >&6; } 42463 else 42464 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42465 $as_echo "no" >&6; } 42466 fi 42467 42468 42469 test -n "$OBJDUMP" && break 42470 done 42471 fi 42472 if test -z "$OBJDUMP"; then 42473 ac_ct_OBJDUMP=$OBJDUMP 42474 for ac_prog in gobjdump objdump 42475 do 42476 # Extract the first word of "$ac_prog", so it can be a program name with args. 42477 set dummy $ac_prog; ac_word=$2 42478 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42479 $as_echo_n "checking for $ac_word... " >&6; } 42480 if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then : 42481 $as_echo_n "(cached) " >&6 42482 else 42483 if test -n "$ac_ct_OBJDUMP"; then 42484 ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. 42485 else 42486 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42487 for as_dir in $PATH 42488 do 42489 IFS=$as_save_IFS 42490 test -z "$as_dir" && as_dir=. 42491 for ac_exec_ext in '' $ac_executable_extensions; do 42492 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42493 ac_cv_prog_ac_ct_OBJDUMP="$ac_prog" 42494 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42495 break 2 42496 fi 42497 done 42498 done 42499 IFS=$as_save_IFS 42500 42501 fi 42502 fi 42503 ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP 42504 if test -n "$ac_ct_OBJDUMP"; then 42505 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 42506 $as_echo "$ac_ct_OBJDUMP" >&6; } 42507 else 42508 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42509 $as_echo "no" >&6; } 42510 fi 42511 42512 42513 test -n "$ac_ct_OBJDUMP" && break 42514 done 42515 42516 if test "x$ac_ct_OBJDUMP" = x; then 42517 OBJDUMP="" 42518 else 42519 case $cross_compiling:$ac_tool_warned in 42520 yes:) 42521 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 42522 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 42523 ac_tool_warned=yes ;; 42524 esac 42525 OBJDUMP=$ac_ct_OBJDUMP 42526 fi 42527 fi 42528 42529 else 42530 # The variable is set, but is it from the command line or the environment? 42531 42532 # Try to remove the string !OBJDUMP! from our list. 42533 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!OBJDUMP!/} 42534 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 42535 # If it failed, the variable was not from the command line. Ignore it, 42536 # but warn the user (except for BASH, which is always set by the calling BASH). 42537 if test "xOBJDUMP" != xBASH; then 42538 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of OBJDUMP from the environment. Use command line variables instead." >&5 42539 $as_echo "$as_me: WARNING: Ignoring value of OBJDUMP from the environment. Use command line variables instead." >&2;} 42540 fi 42541 # Try to locate tool using the code snippet 42542 if test -n "$ac_tool_prefix"; then 42543 for ac_prog in gobjdump objdump 42544 do 42545 # Extract the first word of "$ac_tool_prefix$ac_prog", so it can be a program name with args. 42546 set dummy $ac_tool_prefix$ac_prog; ac_word=$2 42547 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42548 $as_echo_n "checking for $ac_word... " >&6; } 42549 if ${ac_cv_prog_OBJDUMP+:} false; then : 42550 $as_echo_n "(cached) " >&6 42551 else 42552 if test -n "$OBJDUMP"; then 42553 ac_cv_prog_OBJDUMP="$OBJDUMP" # Let the user override the test. 42554 else 42555 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42556 for as_dir in $PATH 42557 do 42558 IFS=$as_save_IFS 42559 test -z "$as_dir" && as_dir=. 42560 for ac_exec_ext in '' $ac_executable_extensions; do 42561 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42562 ac_cv_prog_OBJDUMP="$ac_tool_prefix$ac_prog" 42563 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42564 break 2 42565 fi 42566 done 42567 done 42568 IFS=$as_save_IFS 42569 42570 fi 42571 fi 42572 OBJDUMP=$ac_cv_prog_OBJDUMP 42573 if test -n "$OBJDUMP"; then 42574 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 42575 $as_echo "$OBJDUMP" >&6; } 42576 else 42577 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42578 $as_echo "no" >&6; } 42579 fi 42580 42581 42582 test -n "$OBJDUMP" && break 42583 done 42584 fi 42585 if test -z "$OBJDUMP"; then 42586 ac_ct_OBJDUMP=$OBJDUMP 42587 for ac_prog in gobjdump objdump 42588 do 42589 # Extract the first word of "$ac_prog", so it can be a program name with args. 42590 set dummy $ac_prog; ac_word=$2 42591 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42592 $as_echo_n "checking for $ac_word... " >&6; } 42593 if ${ac_cv_prog_ac_ct_OBJDUMP+:} false; then : 42594 $as_echo_n "(cached) " >&6 42595 else 42596 if test -n "$ac_ct_OBJDUMP"; then 42597 ac_cv_prog_ac_ct_OBJDUMP="$ac_ct_OBJDUMP" # Let the user override the test. 42598 else 42599 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42600 for as_dir in $PATH 42601 do 42602 IFS=$as_save_IFS 42603 test -z "$as_dir" && as_dir=. 42604 for ac_exec_ext in '' $ac_executable_extensions; do 42605 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42606 ac_cv_prog_ac_ct_OBJDUMP="$ac_prog" 42607 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42608 break 2 42609 fi 42610 done 42611 done 42612 IFS=$as_save_IFS 42613 42614 fi 42615 fi 42616 ac_ct_OBJDUMP=$ac_cv_prog_ac_ct_OBJDUMP 42617 if test -n "$ac_ct_OBJDUMP"; then 42618 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_OBJDUMP" >&5 42619 $as_echo "$ac_ct_OBJDUMP" >&6; } 42620 else 42621 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42622 $as_echo "no" >&6; } 42623 fi 42624 42625 42626 test -n "$ac_ct_OBJDUMP" && break 42627 done 42628 42629 if test "x$ac_ct_OBJDUMP" = x; then 42630 OBJDUMP="" 42631 else 42632 case $cross_compiling:$ac_tool_warned in 42633 yes:) 42634 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 42635 $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} 42636 ac_tool_warned=yes ;; 42637 esac 42638 OBJDUMP=$ac_ct_OBJDUMP 42639 fi 42640 fi 42641 42642 else 42643 # If it succeeded, then it was overridden by the user. We will use it 42644 # for the tool. 42645 42646 # First remove it from the list of overridden variables, so we can test 42647 # for unknown variables in the end. 42648 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 42649 42650 # Check if we try to supply an empty value 42651 if test "x$OBJDUMP" = x; then 42652 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool OBJDUMP= (no value)" >&5 42653 $as_echo "$as_me: Setting user supplied tool OBJDUMP= (no value)" >&6;} 42654 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJDUMP" >&5 42655 $as_echo_n "checking for OBJDUMP... " >&6; } 42656 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 42657 $as_echo "disabled" >&6; } 42658 else 42659 # Check if the provided tool contains a complete path. 42660 tool_specified="$OBJDUMP" 42661 tool_basename="${tool_specified##*/}" 42662 if test "x$tool_basename" = "x$tool_specified"; then 42663 # A command without a complete path is provided, search $PATH. 42664 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool OBJDUMP=$tool_basename" >&5 42665 $as_echo "$as_me: Will search for user supplied tool OBJDUMP=$tool_basename" >&6;} 42666 # Extract the first word of "$tool_basename", so it can be a program name with args. 42667 set dummy $tool_basename; ac_word=$2 42668 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 42669 $as_echo_n "checking for $ac_word... " >&6; } 42670 if ${ac_cv_path_OBJDUMP+:} false; then : 42671 $as_echo_n "(cached) " >&6 42672 else 42673 case $OBJDUMP in 42674 [\\/]* | ?:[\\/]*) 42675 ac_cv_path_OBJDUMP="$OBJDUMP" # Let the user override the test with a path. 42676 ;; 42677 *) 42678 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 42679 for as_dir in $PATH 42680 do 42681 IFS=$as_save_IFS 42682 test -z "$as_dir" && as_dir=. 42683 for ac_exec_ext in '' $ac_executable_extensions; do 42684 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 42685 ac_cv_path_OBJDUMP="$as_dir/$ac_word$ac_exec_ext" 42686 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 42687 break 2 42688 fi 42689 done 42690 done 42691 IFS=$as_save_IFS 42692 42693 ;; 42694 esac 42695 fi 42696 OBJDUMP=$ac_cv_path_OBJDUMP 42697 if test -n "$OBJDUMP"; then 42698 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OBJDUMP" >&5 42699 $as_echo "$OBJDUMP" >&6; } 42700 else 42701 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 42702 $as_echo "no" >&6; } 42703 fi 42704 42705 42706 if test "x$OBJDUMP" = x; then 42707 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 42708 fi 42709 else 42710 # Otherwise we believe it is a complete path. Use it as it is. 42711 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool OBJDUMP=$tool_specified" >&5 42712 $as_echo "$as_me: Will use user supplied tool OBJDUMP=$tool_specified" >&6;} 42713 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for OBJDUMP" >&5 42714 $as_echo_n "checking for OBJDUMP... " >&6; } 42715 if test ! -x "$tool_specified"; then 42716 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 42717 $as_echo "not found" >&6; } 42718 as_fn_error $? "User supplied tool OBJDUMP=$tool_specified does not exist or is not executable" "$LINENO" 5 42719 fi 42720 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 42721 $as_echo "$tool_specified" >&6; } 42722 fi 42723 fi 42724 fi 42725 42726 fi 42727 42728 42729 if test "x$OBJDUMP" != x; then 42730 # Only used for compare.sh; we can live without it. BASIC_FIXUP_EXECUTABLE 42731 # bails if argument is missing. 42732 42733 # Only process if variable expands to non-empty 42734 42735 if test "x$OBJDUMP" != x; then 42736 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42737 42738 # First separate the path from the arguments. This will split at the first 42739 # space. 42740 complete="$OBJDUMP" 42741 path="${complete%% *}" 42742 tmp="$complete EOL" 42743 arguments="${tmp#* }" 42744 42745 # Input might be given as Windows format, start by converting to 42746 # unix format. 42747 new_path=`$CYGPATH -u "$path"` 42748 42749 # Now try to locate executable using which 42750 new_path=`$WHICH "$new_path" 2> /dev/null` 42751 # bat and cmd files are not always considered executable in cygwin causing which 42752 # to not find them 42753 if test "x$new_path" = x \ 42754 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 42755 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 42756 new_path=`$CYGPATH -u "$path"` 42757 fi 42758 if test "x$new_path" = x; then 42759 # Oops. Which didn't find the executable. 42760 # The splitting of arguments from the executable at a space might have been incorrect, 42761 # since paths with space are more likely in Windows. Give it another try with the whole 42762 # argument. 42763 path="$complete" 42764 arguments="EOL" 42765 new_path=`$CYGPATH -u "$path"` 42766 new_path=`$WHICH "$new_path" 2> /dev/null` 42767 # bat and cmd files are not always considered executable in cygwin causing which 42768 # to not find them 42769 if test "x$new_path" = x \ 42770 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 42771 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 42772 new_path=`$CYGPATH -u "$path"` 42773 fi 42774 if test "x$new_path" = x; then 42775 # It's still not found. Now this is an unrecoverable error. 42776 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5 42777 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;} 42778 has_space=`$ECHO "$complete" | $GREP " "` 42779 if test "x$has_space" != x; then 42780 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 42781 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 42782 fi 42783 as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5 42784 fi 42785 fi 42786 42787 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 42788 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 42789 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 42790 # "foo.exe" is OK but "foo" is an error. 42791 # 42792 # This test is therefore slightly more accurate than "test -f" to check for file presence. 42793 # It is also a way to make sure we got the proper file name for the real test later on. 42794 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 42795 if test "x$test_shortpath" = x; then 42796 # Short path failed, file does not exist as specified. 42797 # Try adding .exe or .cmd 42798 if test -f "${new_path}.exe"; then 42799 input_to_shortpath="${new_path}.exe" 42800 elif test -f "${new_path}.cmd"; then 42801 input_to_shortpath="${new_path}.cmd" 42802 else 42803 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$new_path\", is invalid." >&5 42804 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$new_path\", is invalid." >&6;} 42805 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 42806 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 42807 as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5 42808 fi 42809 else 42810 input_to_shortpath="$new_path" 42811 fi 42812 42813 # Call helper function which possibly converts this using DOS-style short mode. 42814 # If so, the updated path is stored in $new_path. 42815 new_path="$input_to_shortpath" 42816 42817 input_path="$input_to_shortpath" 42818 # Check if we need to convert this using DOS-style short mode. If the path 42819 # contains just simple characters, use it. Otherwise (spaces, weird characters), 42820 # take no chances and rewrite it. 42821 # Note: m4 eats our [], so we need to use [ and ] instead. 42822 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 42823 if test "x$has_forbidden_chars" != x; then 42824 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 42825 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 42826 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 42827 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 42828 # Going to short mode and back again did indeed matter. Since short mode is 42829 # case insensitive, let's make it lowercase to improve readability. 42830 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 42831 # Now convert it back to Unix-style (cygpath) 42832 input_path=`$CYGPATH -u "$shortmode_path"` 42833 new_path="$input_path" 42834 fi 42835 fi 42836 42837 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 42838 if test "x$test_cygdrive_prefix" = x; then 42839 # As a simple fix, exclude /usr/bin since it's not a real path. 42840 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 42841 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 42842 # a path prefixed by /cygdrive for fixpath to work. 42843 new_path="$CYGWIN_ROOT_PATH$input_path" 42844 fi 42845 fi 42846 42847 # remove trailing .exe if any 42848 new_path="${new_path/%.exe/}" 42849 42850 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42851 42852 # First separate the path from the arguments. This will split at the first 42853 # space. 42854 complete="$OBJDUMP" 42855 path="${complete%% *}" 42856 tmp="$complete EOL" 42857 arguments="${tmp#* }" 42858 42859 # Input might be given as Windows format, start by converting to 42860 # unix format. 42861 new_path="$path" 42862 42863 windows_path="$new_path" 42864 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42865 unix_path=`$CYGPATH -u "$windows_path"` 42866 new_path="$unix_path" 42867 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42868 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42869 new_path="$unix_path" 42870 fi 42871 42872 42873 # Now try to locate executable using which 42874 new_path=`$WHICH "$new_path" 2> /dev/null` 42875 42876 if test "x$new_path" = x; then 42877 # Oops. Which didn't find the executable. 42878 # The splitting of arguments from the executable at a space might have been incorrect, 42879 # since paths with space are more likely in Windows. Give it another try with the whole 42880 # argument. 42881 path="$complete" 42882 arguments="EOL" 42883 new_path="$path" 42884 42885 windows_path="$new_path" 42886 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42887 unix_path=`$CYGPATH -u "$windows_path"` 42888 new_path="$unix_path" 42889 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42890 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42891 new_path="$unix_path" 42892 fi 42893 42894 42895 new_path=`$WHICH "$new_path" 2> /dev/null` 42896 # bat and cmd files are not always considered executable in MSYS causing which 42897 # to not find them 42898 if test "x$new_path" = x \ 42899 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 42900 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 42901 new_path="$path" 42902 42903 windows_path="$new_path" 42904 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42905 unix_path=`$CYGPATH -u "$windows_path"` 42906 new_path="$unix_path" 42907 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42908 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42909 new_path="$unix_path" 42910 fi 42911 42912 fi 42913 42914 if test "x$new_path" = x; then 42915 # It's still not found. Now this is an unrecoverable error. 42916 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5 42917 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;} 42918 has_space=`$ECHO "$complete" | $GREP " "` 42919 if test "x$has_space" != x; then 42920 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 42921 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 42922 fi 42923 as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5 42924 fi 42925 fi 42926 42927 # Now new_path has a complete unix path to the binary 42928 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 42929 # Keep paths in /bin as-is, but remove trailing .exe if any 42930 new_path="${new_path/%.exe/}" 42931 # Do not save /bin paths to all_fixpath_prefixes! 42932 else 42933 # Not in mixed or Windows style, start by that. 42934 new_path=`cmd //c echo $new_path` 42935 42936 input_path="$new_path" 42937 # Check if we need to convert this using DOS-style short mode. If the path 42938 # contains just simple characters, use it. Otherwise (spaces, weird characters), 42939 # take no chances and rewrite it. 42940 # Note: m4 eats our [], so we need to use [ and ] instead. 42941 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 42942 if test "x$has_forbidden_chars" != x; then 42943 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 42944 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 42945 fi 42946 42947 # Output is in $new_path 42948 42949 windows_path="$new_path" 42950 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 42951 unix_path=`$CYGPATH -u "$windows_path"` 42952 new_path="$unix_path" 42953 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 42954 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 42955 new_path="$unix_path" 42956 fi 42957 42958 # remove trailing .exe if any 42959 new_path="${new_path/%.exe/}" 42960 42961 # Save the first 10 bytes of this path to the storage, so fixpath can work. 42962 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 42963 fi 42964 42965 else 42966 # We're on a unix platform. Hooray! :) 42967 # First separate the path from the arguments. This will split at the first 42968 # space. 42969 complete="$OBJDUMP" 42970 path="${complete%% *}" 42971 tmp="$complete EOL" 42972 arguments="${tmp#* }" 42973 42974 # Cannot rely on the command "which" here since it doesn't always work. 42975 is_absolute_path=`$ECHO "$path" | $GREP ^/` 42976 if test -z "$is_absolute_path"; then 42977 # Path to executable is not absolute. Find it. 42978 IFS_save="$IFS" 42979 IFS=: 42980 for p in $PATH; do 42981 if test -f "$p/$path" && test -x "$p/$path"; then 42982 new_path="$p/$path" 42983 break 42984 fi 42985 done 42986 IFS="$IFS_save" 42987 else 42988 # This is an absolute path, we can use it without further modifications. 42989 new_path="$path" 42990 fi 42991 42992 if test "x$new_path" = x; then 42993 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&5 42994 $as_echo "$as_me: The path of OBJDUMP, which resolves as \"$complete\", is not found." >&6;} 42995 has_space=`$ECHO "$complete" | $GREP " "` 42996 if test "x$has_space" != x; then 42997 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 42998 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 42999 fi 43000 as_fn_error $? "Cannot locate the the path of OBJDUMP" "$LINENO" 5 43001 fi 43002 fi 43003 43004 # Now join together the path and the arguments once again 43005 if test "x$arguments" != xEOL; then 43006 new_complete="$new_path ${arguments% *}" 43007 else 43008 new_complete="$new_path" 43009 fi 43010 43011 if test "x$complete" != "x$new_complete"; then 43012 OBJDUMP="$new_complete" 43013 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting OBJDUMP to \"$new_complete\"" >&5 43014 $as_echo "$as_me: Rewriting OBJDUMP to \"$new_complete\"" >&6;} 43015 fi 43016 fi 43017 43018 fi 43019 43020 43021 # Restore old path. 43022 PATH="$OLD_PATH" 43023 43024 # Restore the flags to the user specified values. 43025 # This is necessary since AC_PROG_CC defaults CFLAGS to "-g -O2" 43026 CFLAGS="$ORG_CFLAGS" 43027 CXXFLAGS="$ORG_CXXFLAGS" 43028 43029 43030 # Finally do some processing after the detection phase 43031 43032 if test "x$COMPILE_TYPE" = "xcross"; then 43033 # Now we need to find a C/C++ compiler that can build executables for the 43034 # build platform. We can't use the AC_PROG_CC macro, since it can only be 43035 # used once. Also, we need to do this without adding a tools dir to the 43036 # path, otherwise we might pick up cross-compilers which don't use standard 43037 # naming. 43038 43039 OLDPATH="$PATH" 43040 43041 43042 # Check whether --with-build-devkit was given. 43043 if test "${with_build_devkit+set}" = set; then : 43044 withval=$with_build_devkit; 43045 fi 43046 43047 if test "x$with_build_devkit" = "xyes"; then 43048 as_fn_error $? "--with-build-devkit must have a value" "$LINENO" 5 43049 elif test -n "$with_build_devkit"; then 43050 if test ! -d "$with_build_devkit"; then 43051 as_fn_error $? "--with-build-devkit points to non existing dir: $with_build_devkit" "$LINENO" 5 43052 else 43053 43054 # Only process if variable expands to non-empty 43055 43056 if test "x$with_build_devkit" != x; then 43057 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43058 43059 # Input might be given as Windows format, start by converting to 43060 # unix format. 43061 path="$with_build_devkit" 43062 new_path=`$CYGPATH -u "$path"` 43063 43064 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 43065 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 43066 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 43067 # "foo.exe" is OK but "foo" is an error. 43068 # 43069 # This test is therefore slightly more accurate than "test -f" to check for file precense. 43070 # It is also a way to make sure we got the proper file name for the real test later on. 43071 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 43072 if test "x$test_shortpath" = x; then 43073 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_build_devkit, which resolves as \"$path\", is invalid." >&5 43074 $as_echo "$as_me: The path of with_build_devkit, which resolves as \"$path\", is invalid." >&6;} 43075 as_fn_error $? "Cannot locate the the path of with_build_devkit" "$LINENO" 5 43076 fi 43077 43078 # Call helper function which possibly converts this using DOS-style short mode. 43079 # If so, the updated path is stored in $new_path. 43080 43081 input_path="$new_path" 43082 # Check if we need to convert this using DOS-style short mode. If the path 43083 # contains just simple characters, use it. Otherwise (spaces, weird characters), 43084 # take no chances and rewrite it. 43085 # Note: m4 eats our [], so we need to use [ and ] instead. 43086 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 43087 if test "x$has_forbidden_chars" != x; then 43088 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 43089 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 43090 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 43091 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 43092 # Going to short mode and back again did indeed matter. Since short mode is 43093 # case insensitive, let's make it lowercase to improve readability. 43094 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 43095 # Now convert it back to Unix-style (cygpath) 43096 input_path=`$CYGPATH -u "$shortmode_path"` 43097 new_path="$input_path" 43098 fi 43099 fi 43100 43101 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 43102 if test "x$test_cygdrive_prefix" = x; then 43103 # As a simple fix, exclude /usr/bin since it's not a real path. 43104 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 43105 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 43106 # a path prefixed by /cygdrive for fixpath to work. 43107 new_path="$CYGWIN_ROOT_PATH$input_path" 43108 fi 43109 fi 43110 43111 43112 if test "x$path" != "x$new_path"; then 43113 with_build_devkit="$new_path" 43114 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_build_devkit to \"$new_path\"" >&5 43115 $as_echo "$as_me: Rewriting with_build_devkit to \"$new_path\"" >&6;} 43116 fi 43117 43118 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43119 43120 path="$with_build_devkit" 43121 has_colon=`$ECHO $path | $GREP ^.:` 43122 new_path="$path" 43123 if test "x$has_colon" = x; then 43124 # Not in mixed or Windows style, start by that. 43125 new_path=`cmd //c echo $path` 43126 fi 43127 43128 43129 input_path="$new_path" 43130 # Check if we need to convert this using DOS-style short mode. If the path 43131 # contains just simple characters, use it. Otherwise (spaces, weird characters), 43132 # take no chances and rewrite it. 43133 # Note: m4 eats our [], so we need to use [ and ] instead. 43134 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 43135 if test "x$has_forbidden_chars" != x; then 43136 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 43137 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 43138 fi 43139 43140 43141 windows_path="$new_path" 43142 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43143 unix_path=`$CYGPATH -u "$windows_path"` 43144 new_path="$unix_path" 43145 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43146 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43147 new_path="$unix_path" 43148 fi 43149 43150 if test "x$path" != "x$new_path"; then 43151 with_build_devkit="$new_path" 43152 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting with_build_devkit to \"$new_path\"" >&5 43153 $as_echo "$as_me: Rewriting with_build_devkit to \"$new_path\"" >&6;} 43154 fi 43155 43156 # Save the first 10 bytes of this path to the storage, so fixpath can work. 43157 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 43158 43159 else 43160 # We're on a unix platform. Hooray! :) 43161 path="$with_build_devkit" 43162 has_space=`$ECHO "$path" | $GREP " "` 43163 if test "x$has_space" != x; then 43164 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_build_devkit, which resolves as \"$path\", is invalid." >&5 43165 $as_echo "$as_me: The path of with_build_devkit, which resolves as \"$path\", is invalid." >&6;} 43166 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 43167 fi 43168 43169 # Use eval to expand a potential ~ 43170 eval path="$path" 43171 if test ! -f "$path" && test ! -d "$path"; then 43172 as_fn_error $? "The path of with_build_devkit, which resolves as \"$path\", is not found." "$LINENO" 5 43173 fi 43174 43175 if test -d "$path"; then 43176 with_build_devkit="`cd "$path"; $THEPWDCMD -L`" 43177 else 43178 dir="`$DIRNAME "$path"`" 43179 base="`$BASENAME "$path"`" 43180 with_build_devkit="`cd "$dir"; $THEPWDCMD -L`/$base" 43181 fi 43182 fi 43183 fi 43184 43185 BUILD_DEVKIT_ROOT="$with_build_devkit" 43186 # Check for a meta data info file in the root of the devkit 43187 if test -f "$BUILD_DEVKIT_ROOT/devkit.info"; then 43188 # Process devkit.info so that existing devkit variables are not 43189 # modified by this 43190 $SED -e "s/^DEVKIT_/BUILD_DEVKIT_/g" \ 43191 -e "s/\$DEVKIT_ROOT/\$BUILD_DEVKIT_ROOT/g" \ 43192 -e "s/\$host/\$build/g" \ 43193 $BUILD_DEVKIT_ROOT/devkit.info \ 43194 > $CONFIGURESUPPORT_OUTPUTDIR/build-devkit.info 43195 . $CONFIGURESUPPORT_OUTPUTDIR/build-devkit.info 43196 # This potentially sets the following: 43197 # A descriptive name of the devkit 43198 43199 if test "x$BUILD_DEVKIT_NAME" = x; then 43200 eval BUILD_DEVKIT_NAME="\${BUILD_DEVKIT_NAME_${OPENJDK_TARGET_CPU}}" 43201 fi 43202 43203 # Corresponds to --with-extra-path 43204 43205 if test "x$BUILD_DEVKIT_EXTRA_PATH" = x; then 43206 eval BUILD_DEVKIT_EXTRA_PATH="\${BUILD_DEVKIT_EXTRA_PATH_${OPENJDK_TARGET_CPU}}" 43207 fi 43208 43209 # Corresponds to --with-toolchain-path 43210 43211 if test "x$BUILD_DEVKIT_TOOLCHAIN_PATH" = x; then 43212 eval BUILD_DEVKIT_TOOLCHAIN_PATH="\${BUILD_DEVKIT_TOOLCHAIN_PATH_${OPENJDK_TARGET_CPU}}" 43213 fi 43214 43215 # Corresponds to --with-sysroot 43216 43217 if test "x$BUILD_DEVKIT_SYSROOT" = x; then 43218 eval BUILD_DEVKIT_SYSROOT="\${BUILD_DEVKIT_SYSROOT_${OPENJDK_TARGET_CPU}}" 43219 fi 43220 43221 # Skip the Window specific parts 43222 fi 43223 43224 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for build platform devkit" >&5 43225 $as_echo_n "checking for build platform devkit... " >&6; } 43226 if test "x$BUILD_DEVKIT_NAME" != x; then 43227 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_DEVKIT_NAME in $BUILD_DEVKIT_ROOT" >&5 43228 $as_echo "$BUILD_DEVKIT_NAME in $BUILD_DEVKIT_ROOT" >&6; } 43229 else 43230 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_DEVKIT_ROOT" >&5 43231 $as_echo "$BUILD_DEVKIT_ROOT" >&6; } 43232 fi 43233 43234 BUILD_SYSROOT="$BUILD_DEVKIT_SYSROOT" 43235 43236 if test "x$BUILD_SYSROOT" != "x"; then 43237 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 43238 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 43239 # Solaris Studio does not have a concept of sysroot. Instead we must 43240 # make sure the default include and lib dirs are appended to each 43241 # compile and link command line. 43242 BUILD_SYSROOT_CFLAGS="-I$BUILD_SYSROOT/usr/include" 43243 BUILD_SYSROOT_LDFLAGS="-L$BUILD_SYSROOT/usr/lib$OPENJDK_TARGET_CPU_ISADIR \ 43244 -L$BUILD_SYSROOT/lib$OPENJDK_TARGET_CPU_ISADIR \ 43245 -L$BUILD_SYSROOT/usr/ccs/lib$OPENJDK_TARGET_CPU_ISADIR" 43246 fi 43247 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 43248 BUILD_SYSROOT_CFLAGS="--sysroot=$BUILD_SYSROOT" 43249 BUILD_SYSROOT_LDFLAGS="--sysroot=$BUILD_SYSROOT" 43250 elif test "x$TOOLCHAIN_TYPE" = xclang; then 43251 BUILD_SYSROOT_CFLAGS="-isysroot $BUILD_SYSROOT" 43252 BUILD_SYSROOT_LDFLAGS="-isysroot $BUILD_SYSROOT" 43253 fi 43254 # Propagate the sysroot args to hotspot 43255 BUILD_LEGACY_EXTRA_CFLAGS="$BUILD_LEGACY_EXTRA_CFLAGS $BUILD_SYSROOT_CFLAGS" 43256 BUILD_LEGACY_EXTRA_CXXFLAGS="$BUILD_LEGACY_EXTRA_CXXFLAGS $BUILD_SYSROOT_CFLAGS" 43257 BUILD_LEGACY_EXTRA_LDFLAGS="$BUILD_LEGACY_EXTRA_LDFLAGS $BUILD_SYSROOT_LDFLAGS" 43258 # The global CFLAGS and LDFLAGS variables need these for configure to function 43259 BUILD_CFLAGS="$BUILD_CFLAGS $BUILD_SYSROOT_CFLAGS" 43260 BUILD_CPPFLAGS="$BUILD_CPPFLAGS $BUILD_SYSROOT_CFLAGS" 43261 BUILD_CXXFLAGS="$BUILD_CXXFLAGS $BUILD_SYSROOT_CFLAGS" 43262 BUILD_LDFLAGS="$BUILD_LDFLAGS $BUILD_SYSROOT_LDFLAGS" 43263 fi 43264 43265 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 43266 # We also need -iframework<path>/System/Library/Frameworks 43267 BUILD_SYSROOT_CFLAGS="$BUILD_SYSROOT_CFLAGS -iframework $BUILD_SYSROOT/System/Library/Frameworks" 43268 BUILD_SYSROOT_LDFLAGS="$BUILD_SYSROOT_LDFLAGS -iframework $BUILD_SYSROOT/System/Library/Frameworks" 43269 # These always need to be set, or we can't find the frameworks embedded in JavaVM.framework 43270 # set this here so it doesn't have to be peppered throughout the forest 43271 BUILD_SYSROOT_CFLAGS="$BUILD_SYSROOT_CFLAGS -F $BUILD_SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks" 43272 BUILD_SYSROOT_LDFLAGS="$BUILD_SYSROOT_LDFLAGS -F $BUILD_SYSROOT/System/Library/Frameworks/JavaVM.framework/Frameworks" 43273 fi 43274 43275 43276 43277 43278 43279 # Fallback default of just /bin if DEVKIT_PATH is not defined 43280 if test "x$BUILD_DEVKIT_TOOLCHAIN_PATH" = x; then 43281 BUILD_DEVKIT_TOOLCHAIN_PATH="$BUILD_DEVKIT_ROOT/bin" 43282 fi 43283 PATH="$BUILD_DEVKIT_TOOLCHAIN_PATH:$BUILD_DEVKIT_EXTRA_PATH" 43284 fi 43285 fi 43286 43287 # FIXME: we should list the discovered compilers as an exclude pattern! 43288 # If we do that, we can do this detection before POST_DETECTION, and still 43289 # find the build compilers in the tools dir, if needed. 43290 43291 43292 43293 # Publish this variable in the help. 43294 43295 43296 if [ -z "${BUILD_CC+x}" ]; then 43297 # The variable is not set by user, try to locate tool using the code snippet 43298 for ac_prog in cl cc gcc 43299 do 43300 # Extract the first word of "$ac_prog", so it can be a program name with args. 43301 set dummy $ac_prog; ac_word=$2 43302 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43303 $as_echo_n "checking for $ac_word... " >&6; } 43304 if ${ac_cv_path_BUILD_CC+:} false; then : 43305 $as_echo_n "(cached) " >&6 43306 else 43307 case $BUILD_CC in 43308 [\\/]* | ?:[\\/]*) 43309 ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path. 43310 ;; 43311 *) 43312 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43313 for as_dir in $PATH 43314 do 43315 IFS=$as_save_IFS 43316 test -z "$as_dir" && as_dir=. 43317 for ac_exec_ext in '' $ac_executable_extensions; do 43318 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43319 ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext" 43320 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43321 break 2 43322 fi 43323 done 43324 done 43325 IFS=$as_save_IFS 43326 43327 ;; 43328 esac 43329 fi 43330 BUILD_CC=$ac_cv_path_BUILD_CC 43331 if test -n "$BUILD_CC"; then 43332 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5 43333 $as_echo "$BUILD_CC" >&6; } 43334 else 43335 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43336 $as_echo "no" >&6; } 43337 fi 43338 43339 43340 test -n "$BUILD_CC" && break 43341 done 43342 43343 else 43344 # The variable is set, but is it from the command line or the environment? 43345 43346 # Try to remove the string !BUILD_CC! from our list. 43347 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_CC!/} 43348 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 43349 # If it failed, the variable was not from the command line. Ignore it, 43350 # but warn the user (except for BASH, which is always set by the calling BASH). 43351 if test "xBUILD_CC" != xBASH; then 43352 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_CC from the environment. Use command line variables instead." >&5 43353 $as_echo "$as_me: WARNING: Ignoring value of BUILD_CC from the environment. Use command line variables instead." >&2;} 43354 fi 43355 # Try to locate tool using the code snippet 43356 for ac_prog in cl cc gcc 43357 do 43358 # Extract the first word of "$ac_prog", so it can be a program name with args. 43359 set dummy $ac_prog; ac_word=$2 43360 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43361 $as_echo_n "checking for $ac_word... " >&6; } 43362 if ${ac_cv_path_BUILD_CC+:} false; then : 43363 $as_echo_n "(cached) " >&6 43364 else 43365 case $BUILD_CC in 43366 [\\/]* | ?:[\\/]*) 43367 ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path. 43368 ;; 43369 *) 43370 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43371 for as_dir in $PATH 43372 do 43373 IFS=$as_save_IFS 43374 test -z "$as_dir" && as_dir=. 43375 for ac_exec_ext in '' $ac_executable_extensions; do 43376 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43377 ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext" 43378 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43379 break 2 43380 fi 43381 done 43382 done 43383 IFS=$as_save_IFS 43384 43385 ;; 43386 esac 43387 fi 43388 BUILD_CC=$ac_cv_path_BUILD_CC 43389 if test -n "$BUILD_CC"; then 43390 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5 43391 $as_echo "$BUILD_CC" >&6; } 43392 else 43393 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43394 $as_echo "no" >&6; } 43395 fi 43396 43397 43398 test -n "$BUILD_CC" && break 43399 done 43400 43401 else 43402 # If it succeeded, then it was overridden by the user. We will use it 43403 # for the tool. 43404 43405 # First remove it from the list of overridden variables, so we can test 43406 # for unknown variables in the end. 43407 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 43408 43409 # Check if we try to supply an empty value 43410 if test "x$BUILD_CC" = x; then 43411 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_CC= (no value)" >&5 43412 $as_echo "$as_me: Setting user supplied tool BUILD_CC= (no value)" >&6;} 43413 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CC" >&5 43414 $as_echo_n "checking for BUILD_CC... " >&6; } 43415 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 43416 $as_echo "disabled" >&6; } 43417 else 43418 # Check if the provided tool contains a complete path. 43419 tool_specified="$BUILD_CC" 43420 tool_basename="${tool_specified##*/}" 43421 if test "x$tool_basename" = "x$tool_specified"; then 43422 # A command without a complete path is provided, search $PATH. 43423 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_CC=$tool_basename" >&5 43424 $as_echo "$as_me: Will search for user supplied tool BUILD_CC=$tool_basename" >&6;} 43425 # Extract the first word of "$tool_basename", so it can be a program name with args. 43426 set dummy $tool_basename; ac_word=$2 43427 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43428 $as_echo_n "checking for $ac_word... " >&6; } 43429 if ${ac_cv_path_BUILD_CC+:} false; then : 43430 $as_echo_n "(cached) " >&6 43431 else 43432 case $BUILD_CC in 43433 [\\/]* | ?:[\\/]*) 43434 ac_cv_path_BUILD_CC="$BUILD_CC" # Let the user override the test with a path. 43435 ;; 43436 *) 43437 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43438 for as_dir in $PATH 43439 do 43440 IFS=$as_save_IFS 43441 test -z "$as_dir" && as_dir=. 43442 for ac_exec_ext in '' $ac_executable_extensions; do 43443 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43444 ac_cv_path_BUILD_CC="$as_dir/$ac_word$ac_exec_ext" 43445 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43446 break 2 43447 fi 43448 done 43449 done 43450 IFS=$as_save_IFS 43451 43452 ;; 43453 esac 43454 fi 43455 BUILD_CC=$ac_cv_path_BUILD_CC 43456 if test -n "$BUILD_CC"; then 43457 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CC" >&5 43458 $as_echo "$BUILD_CC" >&6; } 43459 else 43460 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43461 $as_echo "no" >&6; } 43462 fi 43463 43464 43465 if test "x$BUILD_CC" = x; then 43466 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 43467 fi 43468 else 43469 # Otherwise we believe it is a complete path. Use it as it is. 43470 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_CC=$tool_specified" >&5 43471 $as_echo "$as_me: Will use user supplied tool BUILD_CC=$tool_specified" >&6;} 43472 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CC" >&5 43473 $as_echo_n "checking for BUILD_CC... " >&6; } 43474 if test ! -x "$tool_specified"; then 43475 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 43476 $as_echo "not found" >&6; } 43477 as_fn_error $? "User supplied tool BUILD_CC=$tool_specified does not exist or is not executable" "$LINENO" 5 43478 fi 43479 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 43480 $as_echo "$tool_specified" >&6; } 43481 fi 43482 fi 43483 fi 43484 43485 fi 43486 43487 43488 43489 if test "x$BUILD_CC" = x; then 43490 as_fn_error $? "Could not find required tool for BUILD_CC" "$LINENO" 5 43491 fi 43492 43493 43494 43495 # Only process if variable expands to non-empty 43496 43497 if test "x$BUILD_CC" != x; then 43498 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43499 43500 # First separate the path from the arguments. This will split at the first 43501 # space. 43502 complete="$BUILD_CC" 43503 path="${complete%% *}" 43504 tmp="$complete EOL" 43505 arguments="${tmp#* }" 43506 43507 # Input might be given as Windows format, start by converting to 43508 # unix format. 43509 new_path=`$CYGPATH -u "$path"` 43510 43511 # Now try to locate executable using which 43512 new_path=`$WHICH "$new_path" 2> /dev/null` 43513 # bat and cmd files are not always considered executable in cygwin causing which 43514 # to not find them 43515 if test "x$new_path" = x \ 43516 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 43517 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 43518 new_path=`$CYGPATH -u "$path"` 43519 fi 43520 if test "x$new_path" = x; then 43521 # Oops. Which didn't find the executable. 43522 # The splitting of arguments from the executable at a space might have been incorrect, 43523 # since paths with space are more likely in Windows. Give it another try with the whole 43524 # argument. 43525 path="$complete" 43526 arguments="EOL" 43527 new_path=`$CYGPATH -u "$path"` 43528 new_path=`$WHICH "$new_path" 2> /dev/null` 43529 # bat and cmd files are not always considered executable in cygwin causing which 43530 # to not find them 43531 if test "x$new_path" = x \ 43532 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 43533 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 43534 new_path=`$CYGPATH -u "$path"` 43535 fi 43536 if test "x$new_path" = x; then 43537 # It's still not found. Now this is an unrecoverable error. 43538 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5 43539 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;} 43540 has_space=`$ECHO "$complete" | $GREP " "` 43541 if test "x$has_space" != x; then 43542 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 43543 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 43544 fi 43545 as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5 43546 fi 43547 fi 43548 43549 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 43550 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 43551 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 43552 # "foo.exe" is OK but "foo" is an error. 43553 # 43554 # This test is therefore slightly more accurate than "test -f" to check for file presence. 43555 # It is also a way to make sure we got the proper file name for the real test later on. 43556 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 43557 if test "x$test_shortpath" = x; then 43558 # Short path failed, file does not exist as specified. 43559 # Try adding .exe or .cmd 43560 if test -f "${new_path}.exe"; then 43561 input_to_shortpath="${new_path}.exe" 43562 elif test -f "${new_path}.cmd"; then 43563 input_to_shortpath="${new_path}.cmd" 43564 else 43565 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$new_path\", is invalid." >&5 43566 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$new_path\", is invalid." >&6;} 43567 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 43568 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 43569 as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5 43570 fi 43571 else 43572 input_to_shortpath="$new_path" 43573 fi 43574 43575 # Call helper function which possibly converts this using DOS-style short mode. 43576 # If so, the updated path is stored in $new_path. 43577 new_path="$input_to_shortpath" 43578 43579 input_path="$input_to_shortpath" 43580 # Check if we need to convert this using DOS-style short mode. If the path 43581 # contains just simple characters, use it. Otherwise (spaces, weird characters), 43582 # take no chances and rewrite it. 43583 # Note: m4 eats our [], so we need to use [ and ] instead. 43584 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 43585 if test "x$has_forbidden_chars" != x; then 43586 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 43587 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 43588 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 43589 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 43590 # Going to short mode and back again did indeed matter. Since short mode is 43591 # case insensitive, let's make it lowercase to improve readability. 43592 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 43593 # Now convert it back to Unix-style (cygpath) 43594 input_path=`$CYGPATH -u "$shortmode_path"` 43595 new_path="$input_path" 43596 fi 43597 fi 43598 43599 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 43600 if test "x$test_cygdrive_prefix" = x; then 43601 # As a simple fix, exclude /usr/bin since it's not a real path. 43602 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 43603 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 43604 # a path prefixed by /cygdrive for fixpath to work. 43605 new_path="$CYGWIN_ROOT_PATH$input_path" 43606 fi 43607 fi 43608 43609 # remove trailing .exe if any 43610 new_path="${new_path/%.exe/}" 43611 43612 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43613 43614 # First separate the path from the arguments. This will split at the first 43615 # space. 43616 complete="$BUILD_CC" 43617 path="${complete%% *}" 43618 tmp="$complete EOL" 43619 arguments="${tmp#* }" 43620 43621 # Input might be given as Windows format, start by converting to 43622 # unix format. 43623 new_path="$path" 43624 43625 windows_path="$new_path" 43626 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43627 unix_path=`$CYGPATH -u "$windows_path"` 43628 new_path="$unix_path" 43629 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43630 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43631 new_path="$unix_path" 43632 fi 43633 43634 43635 # Now try to locate executable using which 43636 new_path=`$WHICH "$new_path" 2> /dev/null` 43637 43638 if test "x$new_path" = x; then 43639 # Oops. Which didn't find the executable. 43640 # The splitting of arguments from the executable at a space might have been incorrect, 43641 # since paths with space are more likely in Windows. Give it another try with the whole 43642 # argument. 43643 path="$complete" 43644 arguments="EOL" 43645 new_path="$path" 43646 43647 windows_path="$new_path" 43648 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43649 unix_path=`$CYGPATH -u "$windows_path"` 43650 new_path="$unix_path" 43651 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43652 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43653 new_path="$unix_path" 43654 fi 43655 43656 43657 new_path=`$WHICH "$new_path" 2> /dev/null` 43658 # bat and cmd files are not always considered executable in MSYS causing which 43659 # to not find them 43660 if test "x$new_path" = x \ 43661 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 43662 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 43663 new_path="$path" 43664 43665 windows_path="$new_path" 43666 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43667 unix_path=`$CYGPATH -u "$windows_path"` 43668 new_path="$unix_path" 43669 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43670 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43671 new_path="$unix_path" 43672 fi 43673 43674 fi 43675 43676 if test "x$new_path" = x; then 43677 # It's still not found. Now this is an unrecoverable error. 43678 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5 43679 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;} 43680 has_space=`$ECHO "$complete" | $GREP " "` 43681 if test "x$has_space" != x; then 43682 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 43683 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 43684 fi 43685 as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5 43686 fi 43687 fi 43688 43689 # Now new_path has a complete unix path to the binary 43690 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 43691 # Keep paths in /bin as-is, but remove trailing .exe if any 43692 new_path="${new_path/%.exe/}" 43693 # Do not save /bin paths to all_fixpath_prefixes! 43694 else 43695 # Not in mixed or Windows style, start by that. 43696 new_path=`cmd //c echo $new_path` 43697 43698 input_path="$new_path" 43699 # Check if we need to convert this using DOS-style short mode. If the path 43700 # contains just simple characters, use it. Otherwise (spaces, weird characters), 43701 # take no chances and rewrite it. 43702 # Note: m4 eats our [], so we need to use [ and ] instead. 43703 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 43704 if test "x$has_forbidden_chars" != x; then 43705 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 43706 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 43707 fi 43708 43709 # Output is in $new_path 43710 43711 windows_path="$new_path" 43712 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43713 unix_path=`$CYGPATH -u "$windows_path"` 43714 new_path="$unix_path" 43715 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 43716 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 43717 new_path="$unix_path" 43718 fi 43719 43720 # remove trailing .exe if any 43721 new_path="${new_path/%.exe/}" 43722 43723 # Save the first 10 bytes of this path to the storage, so fixpath can work. 43724 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 43725 fi 43726 43727 else 43728 # We're on a unix platform. Hooray! :) 43729 # First separate the path from the arguments. This will split at the first 43730 # space. 43731 complete="$BUILD_CC" 43732 path="${complete%% *}" 43733 tmp="$complete EOL" 43734 arguments="${tmp#* }" 43735 43736 # Cannot rely on the command "which" here since it doesn't always work. 43737 is_absolute_path=`$ECHO "$path" | $GREP ^/` 43738 if test -z "$is_absolute_path"; then 43739 # Path to executable is not absolute. Find it. 43740 IFS_save="$IFS" 43741 IFS=: 43742 for p in $PATH; do 43743 if test -f "$p/$path" && test -x "$p/$path"; then 43744 new_path="$p/$path" 43745 break 43746 fi 43747 done 43748 IFS="$IFS_save" 43749 else 43750 # This is an absolute path, we can use it without further modifications. 43751 new_path="$path" 43752 fi 43753 43754 if test "x$new_path" = x; then 43755 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&5 43756 $as_echo "$as_me: The path of BUILD_CC, which resolves as \"$complete\", is not found." >&6;} 43757 has_space=`$ECHO "$complete" | $GREP " "` 43758 if test "x$has_space" != x; then 43759 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 43760 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 43761 fi 43762 as_fn_error $? "Cannot locate the the path of BUILD_CC" "$LINENO" 5 43763 fi 43764 fi 43765 43766 # Now join together the path and the arguments once again 43767 if test "x$arguments" != xEOL; then 43768 new_complete="$new_path ${arguments% *}" 43769 else 43770 new_complete="$new_path" 43771 fi 43772 43773 if test "x$complete" != "x$new_complete"; then 43774 BUILD_CC="$new_complete" 43775 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_CC to \"$new_complete\"" >&5 43776 $as_echo "$as_me: Rewriting BUILD_CC to \"$new_complete\"" >&6;} 43777 fi 43778 fi 43779 43780 43781 43782 43783 # Publish this variable in the help. 43784 43785 43786 if [ -z "${BUILD_CXX+x}" ]; then 43787 # The variable is not set by user, try to locate tool using the code snippet 43788 for ac_prog in cl CC g++ 43789 do 43790 # Extract the first word of "$ac_prog", so it can be a program name with args. 43791 set dummy $ac_prog; ac_word=$2 43792 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43793 $as_echo_n "checking for $ac_word... " >&6; } 43794 if ${ac_cv_path_BUILD_CXX+:} false; then : 43795 $as_echo_n "(cached) " >&6 43796 else 43797 case $BUILD_CXX in 43798 [\\/]* | ?:[\\/]*) 43799 ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path. 43800 ;; 43801 *) 43802 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43803 for as_dir in $PATH 43804 do 43805 IFS=$as_save_IFS 43806 test -z "$as_dir" && as_dir=. 43807 for ac_exec_ext in '' $ac_executable_extensions; do 43808 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43809 ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext" 43810 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43811 break 2 43812 fi 43813 done 43814 done 43815 IFS=$as_save_IFS 43816 43817 ;; 43818 esac 43819 fi 43820 BUILD_CXX=$ac_cv_path_BUILD_CXX 43821 if test -n "$BUILD_CXX"; then 43822 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5 43823 $as_echo "$BUILD_CXX" >&6; } 43824 else 43825 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43826 $as_echo "no" >&6; } 43827 fi 43828 43829 43830 test -n "$BUILD_CXX" && break 43831 done 43832 43833 else 43834 # The variable is set, but is it from the command line or the environment? 43835 43836 # Try to remove the string !BUILD_CXX! from our list. 43837 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_CXX!/} 43838 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 43839 # If it failed, the variable was not from the command line. Ignore it, 43840 # but warn the user (except for BASH, which is always set by the calling BASH). 43841 if test "xBUILD_CXX" != xBASH; then 43842 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_CXX from the environment. Use command line variables instead." >&5 43843 $as_echo "$as_me: WARNING: Ignoring value of BUILD_CXX from the environment. Use command line variables instead." >&2;} 43844 fi 43845 # Try to locate tool using the code snippet 43846 for ac_prog in cl CC g++ 43847 do 43848 # Extract the first word of "$ac_prog", so it can be a program name with args. 43849 set dummy $ac_prog; ac_word=$2 43850 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43851 $as_echo_n "checking for $ac_word... " >&6; } 43852 if ${ac_cv_path_BUILD_CXX+:} false; then : 43853 $as_echo_n "(cached) " >&6 43854 else 43855 case $BUILD_CXX in 43856 [\\/]* | ?:[\\/]*) 43857 ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path. 43858 ;; 43859 *) 43860 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43861 for as_dir in $PATH 43862 do 43863 IFS=$as_save_IFS 43864 test -z "$as_dir" && as_dir=. 43865 for ac_exec_ext in '' $ac_executable_extensions; do 43866 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43867 ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext" 43868 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43869 break 2 43870 fi 43871 done 43872 done 43873 IFS=$as_save_IFS 43874 43875 ;; 43876 esac 43877 fi 43878 BUILD_CXX=$ac_cv_path_BUILD_CXX 43879 if test -n "$BUILD_CXX"; then 43880 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5 43881 $as_echo "$BUILD_CXX" >&6; } 43882 else 43883 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43884 $as_echo "no" >&6; } 43885 fi 43886 43887 43888 test -n "$BUILD_CXX" && break 43889 done 43890 43891 else 43892 # If it succeeded, then it was overridden by the user. We will use it 43893 # for the tool. 43894 43895 # First remove it from the list of overridden variables, so we can test 43896 # for unknown variables in the end. 43897 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 43898 43899 # Check if we try to supply an empty value 43900 if test "x$BUILD_CXX" = x; then 43901 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_CXX= (no value)" >&5 43902 $as_echo "$as_me: Setting user supplied tool BUILD_CXX= (no value)" >&6;} 43903 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CXX" >&5 43904 $as_echo_n "checking for BUILD_CXX... " >&6; } 43905 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 43906 $as_echo "disabled" >&6; } 43907 else 43908 # Check if the provided tool contains a complete path. 43909 tool_specified="$BUILD_CXX" 43910 tool_basename="${tool_specified##*/}" 43911 if test "x$tool_basename" = "x$tool_specified"; then 43912 # A command without a complete path is provided, search $PATH. 43913 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_CXX=$tool_basename" >&5 43914 $as_echo "$as_me: Will search for user supplied tool BUILD_CXX=$tool_basename" >&6;} 43915 # Extract the first word of "$tool_basename", so it can be a program name with args. 43916 set dummy $tool_basename; ac_word=$2 43917 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 43918 $as_echo_n "checking for $ac_word... " >&6; } 43919 if ${ac_cv_path_BUILD_CXX+:} false; then : 43920 $as_echo_n "(cached) " >&6 43921 else 43922 case $BUILD_CXX in 43923 [\\/]* | ?:[\\/]*) 43924 ac_cv_path_BUILD_CXX="$BUILD_CXX" # Let the user override the test with a path. 43925 ;; 43926 *) 43927 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 43928 for as_dir in $PATH 43929 do 43930 IFS=$as_save_IFS 43931 test -z "$as_dir" && as_dir=. 43932 for ac_exec_ext in '' $ac_executable_extensions; do 43933 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 43934 ac_cv_path_BUILD_CXX="$as_dir/$ac_word$ac_exec_ext" 43935 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 43936 break 2 43937 fi 43938 done 43939 done 43940 IFS=$as_save_IFS 43941 43942 ;; 43943 esac 43944 fi 43945 BUILD_CXX=$ac_cv_path_BUILD_CXX 43946 if test -n "$BUILD_CXX"; then 43947 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_CXX" >&5 43948 $as_echo "$BUILD_CXX" >&6; } 43949 else 43950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 43951 $as_echo "no" >&6; } 43952 fi 43953 43954 43955 if test "x$BUILD_CXX" = x; then 43956 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 43957 fi 43958 else 43959 # Otherwise we believe it is a complete path. Use it as it is. 43960 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_CXX=$tool_specified" >&5 43961 $as_echo "$as_me: Will use user supplied tool BUILD_CXX=$tool_specified" >&6;} 43962 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_CXX" >&5 43963 $as_echo_n "checking for BUILD_CXX... " >&6; } 43964 if test ! -x "$tool_specified"; then 43965 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 43966 $as_echo "not found" >&6; } 43967 as_fn_error $? "User supplied tool BUILD_CXX=$tool_specified does not exist or is not executable" "$LINENO" 5 43968 fi 43969 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 43970 $as_echo "$tool_specified" >&6; } 43971 fi 43972 fi 43973 fi 43974 43975 fi 43976 43977 43978 43979 if test "x$BUILD_CXX" = x; then 43980 as_fn_error $? "Could not find required tool for BUILD_CXX" "$LINENO" 5 43981 fi 43982 43983 43984 43985 # Only process if variable expands to non-empty 43986 43987 if test "x$BUILD_CXX" != x; then 43988 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 43989 43990 # First separate the path from the arguments. This will split at the first 43991 # space. 43992 complete="$BUILD_CXX" 43993 path="${complete%% *}" 43994 tmp="$complete EOL" 43995 arguments="${tmp#* }" 43996 43997 # Input might be given as Windows format, start by converting to 43998 # unix format. 43999 new_path=`$CYGPATH -u "$path"` 44000 44001 # Now try to locate executable using which 44002 new_path=`$WHICH "$new_path" 2> /dev/null` 44003 # bat and cmd files are not always considered executable in cygwin causing which 44004 # to not find them 44005 if test "x$new_path" = x \ 44006 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44007 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44008 new_path=`$CYGPATH -u "$path"` 44009 fi 44010 if test "x$new_path" = x; then 44011 # Oops. Which didn't find the executable. 44012 # The splitting of arguments from the executable at a space might have been incorrect, 44013 # since paths with space are more likely in Windows. Give it another try with the whole 44014 # argument. 44015 path="$complete" 44016 arguments="EOL" 44017 new_path=`$CYGPATH -u "$path"` 44018 new_path=`$WHICH "$new_path" 2> /dev/null` 44019 # bat and cmd files are not always considered executable in cygwin causing which 44020 # to not find them 44021 if test "x$new_path" = x \ 44022 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44023 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44024 new_path=`$CYGPATH -u "$path"` 44025 fi 44026 if test "x$new_path" = x; then 44027 # It's still not found. Now this is an unrecoverable error. 44028 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5 44029 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;} 44030 has_space=`$ECHO "$complete" | $GREP " "` 44031 if test "x$has_space" != x; then 44032 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 44033 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 44034 fi 44035 as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5 44036 fi 44037 fi 44038 44039 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 44040 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 44041 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 44042 # "foo.exe" is OK but "foo" is an error. 44043 # 44044 # This test is therefore slightly more accurate than "test -f" to check for file presence. 44045 # It is also a way to make sure we got the proper file name for the real test later on. 44046 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 44047 if test "x$test_shortpath" = x; then 44048 # Short path failed, file does not exist as specified. 44049 # Try adding .exe or .cmd 44050 if test -f "${new_path}.exe"; then 44051 input_to_shortpath="${new_path}.exe" 44052 elif test -f "${new_path}.cmd"; then 44053 input_to_shortpath="${new_path}.cmd" 44054 else 44055 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$new_path\", is invalid." >&5 44056 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$new_path\", is invalid." >&6;} 44057 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 44058 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 44059 as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5 44060 fi 44061 else 44062 input_to_shortpath="$new_path" 44063 fi 44064 44065 # Call helper function which possibly converts this using DOS-style short mode. 44066 # If so, the updated path is stored in $new_path. 44067 new_path="$input_to_shortpath" 44068 44069 input_path="$input_to_shortpath" 44070 # Check if we need to convert this using DOS-style short mode. If the path 44071 # contains just simple characters, use it. Otherwise (spaces, weird characters), 44072 # take no chances and rewrite it. 44073 # Note: m4 eats our [], so we need to use [ and ] instead. 44074 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 44075 if test "x$has_forbidden_chars" != x; then 44076 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 44077 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 44078 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 44079 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 44080 # Going to short mode and back again did indeed matter. Since short mode is 44081 # case insensitive, let's make it lowercase to improve readability. 44082 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 44083 # Now convert it back to Unix-style (cygpath) 44084 input_path=`$CYGPATH -u "$shortmode_path"` 44085 new_path="$input_path" 44086 fi 44087 fi 44088 44089 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 44090 if test "x$test_cygdrive_prefix" = x; then 44091 # As a simple fix, exclude /usr/bin since it's not a real path. 44092 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 44093 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 44094 # a path prefixed by /cygdrive for fixpath to work. 44095 new_path="$CYGWIN_ROOT_PATH$input_path" 44096 fi 44097 fi 44098 44099 # remove trailing .exe if any 44100 new_path="${new_path/%.exe/}" 44101 44102 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44103 44104 # First separate the path from the arguments. This will split at the first 44105 # space. 44106 complete="$BUILD_CXX" 44107 path="${complete%% *}" 44108 tmp="$complete EOL" 44109 arguments="${tmp#* }" 44110 44111 # Input might be given as Windows format, start by converting to 44112 # unix format. 44113 new_path="$path" 44114 44115 windows_path="$new_path" 44116 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44117 unix_path=`$CYGPATH -u "$windows_path"` 44118 new_path="$unix_path" 44119 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44120 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44121 new_path="$unix_path" 44122 fi 44123 44124 44125 # Now try to locate executable using which 44126 new_path=`$WHICH "$new_path" 2> /dev/null` 44127 44128 if test "x$new_path" = x; then 44129 # Oops. Which didn't find the executable. 44130 # The splitting of arguments from the executable at a space might have been incorrect, 44131 # since paths with space are more likely in Windows. Give it another try with the whole 44132 # argument. 44133 path="$complete" 44134 arguments="EOL" 44135 new_path="$path" 44136 44137 windows_path="$new_path" 44138 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44139 unix_path=`$CYGPATH -u "$windows_path"` 44140 new_path="$unix_path" 44141 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44142 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44143 new_path="$unix_path" 44144 fi 44145 44146 44147 new_path=`$WHICH "$new_path" 2> /dev/null` 44148 # bat and cmd files are not always considered executable in MSYS causing which 44149 # to not find them 44150 if test "x$new_path" = x \ 44151 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44152 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44153 new_path="$path" 44154 44155 windows_path="$new_path" 44156 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44157 unix_path=`$CYGPATH -u "$windows_path"` 44158 new_path="$unix_path" 44159 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44160 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44161 new_path="$unix_path" 44162 fi 44163 44164 fi 44165 44166 if test "x$new_path" = x; then 44167 # It's still not found. Now this is an unrecoverable error. 44168 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5 44169 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;} 44170 has_space=`$ECHO "$complete" | $GREP " "` 44171 if test "x$has_space" != x; then 44172 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 44173 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 44174 fi 44175 as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5 44176 fi 44177 fi 44178 44179 # Now new_path has a complete unix path to the binary 44180 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 44181 # Keep paths in /bin as-is, but remove trailing .exe if any 44182 new_path="${new_path/%.exe/}" 44183 # Do not save /bin paths to all_fixpath_prefixes! 44184 else 44185 # Not in mixed or Windows style, start by that. 44186 new_path=`cmd //c echo $new_path` 44187 44188 input_path="$new_path" 44189 # Check if we need to convert this using DOS-style short mode. If the path 44190 # contains just simple characters, use it. Otherwise (spaces, weird characters), 44191 # take no chances and rewrite it. 44192 # Note: m4 eats our [], so we need to use [ and ] instead. 44193 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 44194 if test "x$has_forbidden_chars" != x; then 44195 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 44196 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 44197 fi 44198 44199 # Output is in $new_path 44200 44201 windows_path="$new_path" 44202 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44203 unix_path=`$CYGPATH -u "$windows_path"` 44204 new_path="$unix_path" 44205 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44206 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44207 new_path="$unix_path" 44208 fi 44209 44210 # remove trailing .exe if any 44211 new_path="${new_path/%.exe/}" 44212 44213 # Save the first 10 bytes of this path to the storage, so fixpath can work. 44214 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 44215 fi 44216 44217 else 44218 # We're on a unix platform. Hooray! :) 44219 # First separate the path from the arguments. This will split at the first 44220 # space. 44221 complete="$BUILD_CXX" 44222 path="${complete%% *}" 44223 tmp="$complete EOL" 44224 arguments="${tmp#* }" 44225 44226 # Cannot rely on the command "which" here since it doesn't always work. 44227 is_absolute_path=`$ECHO "$path" | $GREP ^/` 44228 if test -z "$is_absolute_path"; then 44229 # Path to executable is not absolute. Find it. 44230 IFS_save="$IFS" 44231 IFS=: 44232 for p in $PATH; do 44233 if test -f "$p/$path" && test -x "$p/$path"; then 44234 new_path="$p/$path" 44235 break 44236 fi 44237 done 44238 IFS="$IFS_save" 44239 else 44240 # This is an absolute path, we can use it without further modifications. 44241 new_path="$path" 44242 fi 44243 44244 if test "x$new_path" = x; then 44245 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&5 44246 $as_echo "$as_me: The path of BUILD_CXX, which resolves as \"$complete\", is not found." >&6;} 44247 has_space=`$ECHO "$complete" | $GREP " "` 44248 if test "x$has_space" != x; then 44249 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 44250 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 44251 fi 44252 as_fn_error $? "Cannot locate the the path of BUILD_CXX" "$LINENO" 5 44253 fi 44254 fi 44255 44256 # Now join together the path and the arguments once again 44257 if test "x$arguments" != xEOL; then 44258 new_complete="$new_path ${arguments% *}" 44259 else 44260 new_complete="$new_path" 44261 fi 44262 44263 if test "x$complete" != "x$new_complete"; then 44264 BUILD_CXX="$new_complete" 44265 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_CXX to \"$new_complete\"" >&5 44266 $as_echo "$as_me: Rewriting BUILD_CXX to \"$new_complete\"" >&6;} 44267 fi 44268 fi 44269 44270 44271 44272 # Publish this variable in the help. 44273 44274 44275 if [ -z "${BUILD_NM+x}" ]; then 44276 # The variable is not set by user, try to locate tool using the code snippet 44277 for ac_prog in nm gcc-nm 44278 do 44279 # Extract the first word of "$ac_prog", so it can be a program name with args. 44280 set dummy $ac_prog; ac_word=$2 44281 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44282 $as_echo_n "checking for $ac_word... " >&6; } 44283 if ${ac_cv_path_BUILD_NM+:} false; then : 44284 $as_echo_n "(cached) " >&6 44285 else 44286 case $BUILD_NM in 44287 [\\/]* | ?:[\\/]*) 44288 ac_cv_path_BUILD_NM="$BUILD_NM" # Let the user override the test with a path. 44289 ;; 44290 *) 44291 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44292 for as_dir in $PATH 44293 do 44294 IFS=$as_save_IFS 44295 test -z "$as_dir" && as_dir=. 44296 for ac_exec_ext in '' $ac_executable_extensions; do 44297 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44298 ac_cv_path_BUILD_NM="$as_dir/$ac_word$ac_exec_ext" 44299 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44300 break 2 44301 fi 44302 done 44303 done 44304 IFS=$as_save_IFS 44305 44306 ;; 44307 esac 44308 fi 44309 BUILD_NM=$ac_cv_path_BUILD_NM 44310 if test -n "$BUILD_NM"; then 44311 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_NM" >&5 44312 $as_echo "$BUILD_NM" >&6; } 44313 else 44314 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44315 $as_echo "no" >&6; } 44316 fi 44317 44318 44319 test -n "$BUILD_NM" && break 44320 done 44321 44322 else 44323 # The variable is set, but is it from the command line or the environment? 44324 44325 # Try to remove the string !BUILD_NM! from our list. 44326 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_NM!/} 44327 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 44328 # If it failed, the variable was not from the command line. Ignore it, 44329 # but warn the user (except for BASH, which is always set by the calling BASH). 44330 if test "xBUILD_NM" != xBASH; then 44331 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_NM from the environment. Use command line variables instead." >&5 44332 $as_echo "$as_me: WARNING: Ignoring value of BUILD_NM from the environment. Use command line variables instead." >&2;} 44333 fi 44334 # Try to locate tool using the code snippet 44335 for ac_prog in nm gcc-nm 44336 do 44337 # Extract the first word of "$ac_prog", so it can be a program name with args. 44338 set dummy $ac_prog; ac_word=$2 44339 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44340 $as_echo_n "checking for $ac_word... " >&6; } 44341 if ${ac_cv_path_BUILD_NM+:} false; then : 44342 $as_echo_n "(cached) " >&6 44343 else 44344 case $BUILD_NM in 44345 [\\/]* | ?:[\\/]*) 44346 ac_cv_path_BUILD_NM="$BUILD_NM" # Let the user override the test with a path. 44347 ;; 44348 *) 44349 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44350 for as_dir in $PATH 44351 do 44352 IFS=$as_save_IFS 44353 test -z "$as_dir" && as_dir=. 44354 for ac_exec_ext in '' $ac_executable_extensions; do 44355 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44356 ac_cv_path_BUILD_NM="$as_dir/$ac_word$ac_exec_ext" 44357 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44358 break 2 44359 fi 44360 done 44361 done 44362 IFS=$as_save_IFS 44363 44364 ;; 44365 esac 44366 fi 44367 BUILD_NM=$ac_cv_path_BUILD_NM 44368 if test -n "$BUILD_NM"; then 44369 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_NM" >&5 44370 $as_echo "$BUILD_NM" >&6; } 44371 else 44372 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44373 $as_echo "no" >&6; } 44374 fi 44375 44376 44377 test -n "$BUILD_NM" && break 44378 done 44379 44380 else 44381 # If it succeeded, then it was overridden by the user. We will use it 44382 # for the tool. 44383 44384 # First remove it from the list of overridden variables, so we can test 44385 # for unknown variables in the end. 44386 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 44387 44388 # Check if we try to supply an empty value 44389 if test "x$BUILD_NM" = x; then 44390 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_NM= (no value)" >&5 44391 $as_echo "$as_me: Setting user supplied tool BUILD_NM= (no value)" >&6;} 44392 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_NM" >&5 44393 $as_echo_n "checking for BUILD_NM... " >&6; } 44394 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 44395 $as_echo "disabled" >&6; } 44396 else 44397 # Check if the provided tool contains a complete path. 44398 tool_specified="$BUILD_NM" 44399 tool_basename="${tool_specified##*/}" 44400 if test "x$tool_basename" = "x$tool_specified"; then 44401 # A command without a complete path is provided, search $PATH. 44402 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_NM=$tool_basename" >&5 44403 $as_echo "$as_me: Will search for user supplied tool BUILD_NM=$tool_basename" >&6;} 44404 # Extract the first word of "$tool_basename", so it can be a program name with args. 44405 set dummy $tool_basename; ac_word=$2 44406 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44407 $as_echo_n "checking for $ac_word... " >&6; } 44408 if ${ac_cv_path_BUILD_NM+:} false; then : 44409 $as_echo_n "(cached) " >&6 44410 else 44411 case $BUILD_NM in 44412 [\\/]* | ?:[\\/]*) 44413 ac_cv_path_BUILD_NM="$BUILD_NM" # Let the user override the test with a path. 44414 ;; 44415 *) 44416 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44417 for as_dir in $PATH 44418 do 44419 IFS=$as_save_IFS 44420 test -z "$as_dir" && as_dir=. 44421 for ac_exec_ext in '' $ac_executable_extensions; do 44422 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44423 ac_cv_path_BUILD_NM="$as_dir/$ac_word$ac_exec_ext" 44424 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44425 break 2 44426 fi 44427 done 44428 done 44429 IFS=$as_save_IFS 44430 44431 ;; 44432 esac 44433 fi 44434 BUILD_NM=$ac_cv_path_BUILD_NM 44435 if test -n "$BUILD_NM"; then 44436 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_NM" >&5 44437 $as_echo "$BUILD_NM" >&6; } 44438 else 44439 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44440 $as_echo "no" >&6; } 44441 fi 44442 44443 44444 if test "x$BUILD_NM" = x; then 44445 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 44446 fi 44447 else 44448 # Otherwise we believe it is a complete path. Use it as it is. 44449 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_NM=$tool_specified" >&5 44450 $as_echo "$as_me: Will use user supplied tool BUILD_NM=$tool_specified" >&6;} 44451 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_NM" >&5 44452 $as_echo_n "checking for BUILD_NM... " >&6; } 44453 if test ! -x "$tool_specified"; then 44454 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 44455 $as_echo "not found" >&6; } 44456 as_fn_error $? "User supplied tool BUILD_NM=$tool_specified does not exist or is not executable" "$LINENO" 5 44457 fi 44458 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 44459 $as_echo "$tool_specified" >&6; } 44460 fi 44461 fi 44462 fi 44463 44464 fi 44465 44466 44467 44468 # Only process if variable expands to non-empty 44469 44470 if test "x$BUILD_NM" != x; then 44471 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44472 44473 # First separate the path from the arguments. This will split at the first 44474 # space. 44475 complete="$BUILD_NM" 44476 path="${complete%% *}" 44477 tmp="$complete EOL" 44478 arguments="${tmp#* }" 44479 44480 # Input might be given as Windows format, start by converting to 44481 # unix format. 44482 new_path=`$CYGPATH -u "$path"` 44483 44484 # Now try to locate executable using which 44485 new_path=`$WHICH "$new_path" 2> /dev/null` 44486 # bat and cmd files are not always considered executable in cygwin causing which 44487 # to not find them 44488 if test "x$new_path" = x \ 44489 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44490 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44491 new_path=`$CYGPATH -u "$path"` 44492 fi 44493 if test "x$new_path" = x; then 44494 # Oops. Which didn't find the executable. 44495 # The splitting of arguments from the executable at a space might have been incorrect, 44496 # since paths with space are more likely in Windows. Give it another try with the whole 44497 # argument. 44498 path="$complete" 44499 arguments="EOL" 44500 new_path=`$CYGPATH -u "$path"` 44501 new_path=`$WHICH "$new_path" 2> /dev/null` 44502 # bat and cmd files are not always considered executable in cygwin causing which 44503 # to not find them 44504 if test "x$new_path" = x \ 44505 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44506 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44507 new_path=`$CYGPATH -u "$path"` 44508 fi 44509 if test "x$new_path" = x; then 44510 # It's still not found. Now this is an unrecoverable error. 44511 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&5 44512 $as_echo "$as_me: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&6;} 44513 has_space=`$ECHO "$complete" | $GREP " "` 44514 if test "x$has_space" != x; then 44515 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 44516 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 44517 fi 44518 as_fn_error $? "Cannot locate the the path of BUILD_NM" "$LINENO" 5 44519 fi 44520 fi 44521 44522 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 44523 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 44524 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 44525 # "foo.exe" is OK but "foo" is an error. 44526 # 44527 # This test is therefore slightly more accurate than "test -f" to check for file presence. 44528 # It is also a way to make sure we got the proper file name for the real test later on. 44529 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 44530 if test "x$test_shortpath" = x; then 44531 # Short path failed, file does not exist as specified. 44532 # Try adding .exe or .cmd 44533 if test -f "${new_path}.exe"; then 44534 input_to_shortpath="${new_path}.exe" 44535 elif test -f "${new_path}.cmd"; then 44536 input_to_shortpath="${new_path}.cmd" 44537 else 44538 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_NM, which resolves as \"$new_path\", is invalid." >&5 44539 $as_echo "$as_me: The path of BUILD_NM, which resolves as \"$new_path\", is invalid." >&6;} 44540 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 44541 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 44542 as_fn_error $? "Cannot locate the the path of BUILD_NM" "$LINENO" 5 44543 fi 44544 else 44545 input_to_shortpath="$new_path" 44546 fi 44547 44548 # Call helper function which possibly converts this using DOS-style short mode. 44549 # If so, the updated path is stored in $new_path. 44550 new_path="$input_to_shortpath" 44551 44552 input_path="$input_to_shortpath" 44553 # Check if we need to convert this using DOS-style short mode. If the path 44554 # contains just simple characters, use it. Otherwise (spaces, weird characters), 44555 # take no chances and rewrite it. 44556 # Note: m4 eats our [], so we need to use [ and ] instead. 44557 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 44558 if test "x$has_forbidden_chars" != x; then 44559 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 44560 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 44561 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 44562 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 44563 # Going to short mode and back again did indeed matter. Since short mode is 44564 # case insensitive, let's make it lowercase to improve readability. 44565 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 44566 # Now convert it back to Unix-style (cygpath) 44567 input_path=`$CYGPATH -u "$shortmode_path"` 44568 new_path="$input_path" 44569 fi 44570 fi 44571 44572 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 44573 if test "x$test_cygdrive_prefix" = x; then 44574 # As a simple fix, exclude /usr/bin since it's not a real path. 44575 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 44576 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 44577 # a path prefixed by /cygdrive for fixpath to work. 44578 new_path="$CYGWIN_ROOT_PATH$input_path" 44579 fi 44580 fi 44581 44582 # remove trailing .exe if any 44583 new_path="${new_path/%.exe/}" 44584 44585 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44586 44587 # First separate the path from the arguments. This will split at the first 44588 # space. 44589 complete="$BUILD_NM" 44590 path="${complete%% *}" 44591 tmp="$complete EOL" 44592 arguments="${tmp#* }" 44593 44594 # Input might be given as Windows format, start by converting to 44595 # unix format. 44596 new_path="$path" 44597 44598 windows_path="$new_path" 44599 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44600 unix_path=`$CYGPATH -u "$windows_path"` 44601 new_path="$unix_path" 44602 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44603 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44604 new_path="$unix_path" 44605 fi 44606 44607 44608 # Now try to locate executable using which 44609 new_path=`$WHICH "$new_path" 2> /dev/null` 44610 44611 if test "x$new_path" = x; then 44612 # Oops. Which didn't find the executable. 44613 # The splitting of arguments from the executable at a space might have been incorrect, 44614 # since paths with space are more likely in Windows. Give it another try with the whole 44615 # argument. 44616 path="$complete" 44617 arguments="EOL" 44618 new_path="$path" 44619 44620 windows_path="$new_path" 44621 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44622 unix_path=`$CYGPATH -u "$windows_path"` 44623 new_path="$unix_path" 44624 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44625 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44626 new_path="$unix_path" 44627 fi 44628 44629 44630 new_path=`$WHICH "$new_path" 2> /dev/null` 44631 # bat and cmd files are not always considered executable in MSYS causing which 44632 # to not find them 44633 if test "x$new_path" = x \ 44634 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44635 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44636 new_path="$path" 44637 44638 windows_path="$new_path" 44639 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44640 unix_path=`$CYGPATH -u "$windows_path"` 44641 new_path="$unix_path" 44642 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44643 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44644 new_path="$unix_path" 44645 fi 44646 44647 fi 44648 44649 if test "x$new_path" = x; then 44650 # It's still not found. Now this is an unrecoverable error. 44651 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&5 44652 $as_echo "$as_me: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&6;} 44653 has_space=`$ECHO "$complete" | $GREP " "` 44654 if test "x$has_space" != x; then 44655 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 44656 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 44657 fi 44658 as_fn_error $? "Cannot locate the the path of BUILD_NM" "$LINENO" 5 44659 fi 44660 fi 44661 44662 # Now new_path has a complete unix path to the binary 44663 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 44664 # Keep paths in /bin as-is, but remove trailing .exe if any 44665 new_path="${new_path/%.exe/}" 44666 # Do not save /bin paths to all_fixpath_prefixes! 44667 else 44668 # Not in mixed or Windows style, start by that. 44669 new_path=`cmd //c echo $new_path` 44670 44671 input_path="$new_path" 44672 # Check if we need to convert this using DOS-style short mode. If the path 44673 # contains just simple characters, use it. Otherwise (spaces, weird characters), 44674 # take no chances and rewrite it. 44675 # Note: m4 eats our [], so we need to use [ and ] instead. 44676 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 44677 if test "x$has_forbidden_chars" != x; then 44678 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 44679 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 44680 fi 44681 44682 # Output is in $new_path 44683 44684 windows_path="$new_path" 44685 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44686 unix_path=`$CYGPATH -u "$windows_path"` 44687 new_path="$unix_path" 44688 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 44689 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 44690 new_path="$unix_path" 44691 fi 44692 44693 # remove trailing .exe if any 44694 new_path="${new_path/%.exe/}" 44695 44696 # Save the first 10 bytes of this path to the storage, so fixpath can work. 44697 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 44698 fi 44699 44700 else 44701 # We're on a unix platform. Hooray! :) 44702 # First separate the path from the arguments. This will split at the first 44703 # space. 44704 complete="$BUILD_NM" 44705 path="${complete%% *}" 44706 tmp="$complete EOL" 44707 arguments="${tmp#* }" 44708 44709 # Cannot rely on the command "which" here since it doesn't always work. 44710 is_absolute_path=`$ECHO "$path" | $GREP ^/` 44711 if test -z "$is_absolute_path"; then 44712 # Path to executable is not absolute. Find it. 44713 IFS_save="$IFS" 44714 IFS=: 44715 for p in $PATH; do 44716 if test -f "$p/$path" && test -x "$p/$path"; then 44717 new_path="$p/$path" 44718 break 44719 fi 44720 done 44721 IFS="$IFS_save" 44722 else 44723 # This is an absolute path, we can use it without further modifications. 44724 new_path="$path" 44725 fi 44726 44727 if test "x$new_path" = x; then 44728 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&5 44729 $as_echo "$as_me: The path of BUILD_NM, which resolves as \"$complete\", is not found." >&6;} 44730 has_space=`$ECHO "$complete" | $GREP " "` 44731 if test "x$has_space" != x; then 44732 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 44733 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 44734 fi 44735 as_fn_error $? "Cannot locate the the path of BUILD_NM" "$LINENO" 5 44736 fi 44737 fi 44738 44739 # Now join together the path and the arguments once again 44740 if test "x$arguments" != xEOL; then 44741 new_complete="$new_path ${arguments% *}" 44742 else 44743 new_complete="$new_path" 44744 fi 44745 44746 if test "x$complete" != "x$new_complete"; then 44747 BUILD_NM="$new_complete" 44748 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_NM to \"$new_complete\"" >&5 44749 $as_echo "$as_me: Rewriting BUILD_NM to \"$new_complete\"" >&6;} 44750 fi 44751 fi 44752 44753 44754 44755 # Publish this variable in the help. 44756 44757 44758 if [ -z "${BUILD_AR+x}" ]; then 44759 # The variable is not set by user, try to locate tool using the code snippet 44760 for ac_prog in ar gcc-ar 44761 do 44762 # Extract the first word of "$ac_prog", so it can be a program name with args. 44763 set dummy $ac_prog; ac_word=$2 44764 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44765 $as_echo_n "checking for $ac_word... " >&6; } 44766 if ${ac_cv_path_BUILD_AR+:} false; then : 44767 $as_echo_n "(cached) " >&6 44768 else 44769 case $BUILD_AR in 44770 [\\/]* | ?:[\\/]*) 44771 ac_cv_path_BUILD_AR="$BUILD_AR" # Let the user override the test with a path. 44772 ;; 44773 *) 44774 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44775 for as_dir in $PATH 44776 do 44777 IFS=$as_save_IFS 44778 test -z "$as_dir" && as_dir=. 44779 for ac_exec_ext in '' $ac_executable_extensions; do 44780 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44781 ac_cv_path_BUILD_AR="$as_dir/$ac_word$ac_exec_ext" 44782 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44783 break 2 44784 fi 44785 done 44786 done 44787 IFS=$as_save_IFS 44788 44789 ;; 44790 esac 44791 fi 44792 BUILD_AR=$ac_cv_path_BUILD_AR 44793 if test -n "$BUILD_AR"; then 44794 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_AR" >&5 44795 $as_echo "$BUILD_AR" >&6; } 44796 else 44797 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44798 $as_echo "no" >&6; } 44799 fi 44800 44801 44802 test -n "$BUILD_AR" && break 44803 done 44804 44805 else 44806 # The variable is set, but is it from the command line or the environment? 44807 44808 # Try to remove the string !BUILD_AR! from our list. 44809 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!BUILD_AR!/} 44810 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 44811 # If it failed, the variable was not from the command line. Ignore it, 44812 # but warn the user (except for BASH, which is always set by the calling BASH). 44813 if test "xBUILD_AR" != xBASH; then 44814 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of BUILD_AR from the environment. Use command line variables instead." >&5 44815 $as_echo "$as_me: WARNING: Ignoring value of BUILD_AR from the environment. Use command line variables instead." >&2;} 44816 fi 44817 # Try to locate tool using the code snippet 44818 for ac_prog in ar gcc-ar 44819 do 44820 # Extract the first word of "$ac_prog", so it can be a program name with args. 44821 set dummy $ac_prog; ac_word=$2 44822 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44823 $as_echo_n "checking for $ac_word... " >&6; } 44824 if ${ac_cv_path_BUILD_AR+:} false; then : 44825 $as_echo_n "(cached) " >&6 44826 else 44827 case $BUILD_AR in 44828 [\\/]* | ?:[\\/]*) 44829 ac_cv_path_BUILD_AR="$BUILD_AR" # Let the user override the test with a path. 44830 ;; 44831 *) 44832 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44833 for as_dir in $PATH 44834 do 44835 IFS=$as_save_IFS 44836 test -z "$as_dir" && as_dir=. 44837 for ac_exec_ext in '' $ac_executable_extensions; do 44838 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44839 ac_cv_path_BUILD_AR="$as_dir/$ac_word$ac_exec_ext" 44840 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44841 break 2 44842 fi 44843 done 44844 done 44845 IFS=$as_save_IFS 44846 44847 ;; 44848 esac 44849 fi 44850 BUILD_AR=$ac_cv_path_BUILD_AR 44851 if test -n "$BUILD_AR"; then 44852 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_AR" >&5 44853 $as_echo "$BUILD_AR" >&6; } 44854 else 44855 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44856 $as_echo "no" >&6; } 44857 fi 44858 44859 44860 test -n "$BUILD_AR" && break 44861 done 44862 44863 else 44864 # If it succeeded, then it was overridden by the user. We will use it 44865 # for the tool. 44866 44867 # First remove it from the list of overridden variables, so we can test 44868 # for unknown variables in the end. 44869 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 44870 44871 # Check if we try to supply an empty value 44872 if test "x$BUILD_AR" = x; then 44873 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool BUILD_AR= (no value)" >&5 44874 $as_echo "$as_me: Setting user supplied tool BUILD_AR= (no value)" >&6;} 44875 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_AR" >&5 44876 $as_echo_n "checking for BUILD_AR... " >&6; } 44877 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 44878 $as_echo "disabled" >&6; } 44879 else 44880 # Check if the provided tool contains a complete path. 44881 tool_specified="$BUILD_AR" 44882 tool_basename="${tool_specified##*/}" 44883 if test "x$tool_basename" = "x$tool_specified"; then 44884 # A command without a complete path is provided, search $PATH. 44885 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool BUILD_AR=$tool_basename" >&5 44886 $as_echo "$as_me: Will search for user supplied tool BUILD_AR=$tool_basename" >&6;} 44887 # Extract the first word of "$tool_basename", so it can be a program name with args. 44888 set dummy $tool_basename; ac_word=$2 44889 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 44890 $as_echo_n "checking for $ac_word... " >&6; } 44891 if ${ac_cv_path_BUILD_AR+:} false; then : 44892 $as_echo_n "(cached) " >&6 44893 else 44894 case $BUILD_AR in 44895 [\\/]* | ?:[\\/]*) 44896 ac_cv_path_BUILD_AR="$BUILD_AR" # Let the user override the test with a path. 44897 ;; 44898 *) 44899 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 44900 for as_dir in $PATH 44901 do 44902 IFS=$as_save_IFS 44903 test -z "$as_dir" && as_dir=. 44904 for ac_exec_ext in '' $ac_executable_extensions; do 44905 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 44906 ac_cv_path_BUILD_AR="$as_dir/$ac_word$ac_exec_ext" 44907 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 44908 break 2 44909 fi 44910 done 44911 done 44912 IFS=$as_save_IFS 44913 44914 ;; 44915 esac 44916 fi 44917 BUILD_AR=$ac_cv_path_BUILD_AR 44918 if test -n "$BUILD_AR"; then 44919 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUILD_AR" >&5 44920 $as_echo "$BUILD_AR" >&6; } 44921 else 44922 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 44923 $as_echo "no" >&6; } 44924 fi 44925 44926 44927 if test "x$BUILD_AR" = x; then 44928 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 44929 fi 44930 else 44931 # Otherwise we believe it is a complete path. Use it as it is. 44932 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool BUILD_AR=$tool_specified" >&5 44933 $as_echo "$as_me: Will use user supplied tool BUILD_AR=$tool_specified" >&6;} 44934 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for BUILD_AR" >&5 44935 $as_echo_n "checking for BUILD_AR... " >&6; } 44936 if test ! -x "$tool_specified"; then 44937 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 44938 $as_echo "not found" >&6; } 44939 as_fn_error $? "User supplied tool BUILD_AR=$tool_specified does not exist or is not executable" "$LINENO" 5 44940 fi 44941 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 44942 $as_echo "$tool_specified" >&6; } 44943 fi 44944 fi 44945 fi 44946 44947 fi 44948 44949 44950 44951 # Only process if variable expands to non-empty 44952 44953 if test "x$BUILD_AR" != x; then 44954 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 44955 44956 # First separate the path from the arguments. This will split at the first 44957 # space. 44958 complete="$BUILD_AR" 44959 path="${complete%% *}" 44960 tmp="$complete EOL" 44961 arguments="${tmp#* }" 44962 44963 # Input might be given as Windows format, start by converting to 44964 # unix format. 44965 new_path=`$CYGPATH -u "$path"` 44966 44967 # Now try to locate executable using which 44968 new_path=`$WHICH "$new_path" 2> /dev/null` 44969 # bat and cmd files are not always considered executable in cygwin causing which 44970 # to not find them 44971 if test "x$new_path" = x \ 44972 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44973 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44974 new_path=`$CYGPATH -u "$path"` 44975 fi 44976 if test "x$new_path" = x; then 44977 # Oops. Which didn't find the executable. 44978 # The splitting of arguments from the executable at a space might have been incorrect, 44979 # since paths with space are more likely in Windows. Give it another try with the whole 44980 # argument. 44981 path="$complete" 44982 arguments="EOL" 44983 new_path=`$CYGPATH -u "$path"` 44984 new_path=`$WHICH "$new_path" 2> /dev/null` 44985 # bat and cmd files are not always considered executable in cygwin causing which 44986 # to not find them 44987 if test "x$new_path" = x \ 44988 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 44989 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 44990 new_path=`$CYGPATH -u "$path"` 44991 fi 44992 if test "x$new_path" = x; then 44993 # It's still not found. Now this is an unrecoverable error. 44994 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&5 44995 $as_echo "$as_me: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&6;} 44996 has_space=`$ECHO "$complete" | $GREP " "` 44997 if test "x$has_space" != x; then 44998 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 44999 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 45000 fi 45001 as_fn_error $? "Cannot locate the the path of BUILD_AR" "$LINENO" 5 45002 fi 45003 fi 45004 45005 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 45006 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 45007 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 45008 # "foo.exe" is OK but "foo" is an error. 45009 # 45010 # This test is therefore slightly more accurate than "test -f" to check for file presence. 45011 # It is also a way to make sure we got the proper file name for the real test later on. 45012 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 45013 if test "x$test_shortpath" = x; then 45014 # Short path failed, file does not exist as specified. 45015 # Try adding .exe or .cmd 45016 if test -f "${new_path}.exe"; then 45017 input_to_shortpath="${new_path}.exe" 45018 elif test -f "${new_path}.cmd"; then 45019 input_to_shortpath="${new_path}.cmd" 45020 else 45021 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_AR, which resolves as \"$new_path\", is invalid." >&5 45022 $as_echo "$as_me: The path of BUILD_AR, which resolves as \"$new_path\", is invalid." >&6;} 45023 { $as_echo "$as_me:${as_lineno-$LINENO}: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&5 45024 $as_echo "$as_me: Neither \"$new_path\" nor \"$new_path.exe/cmd\" can be found" >&6;} 45025 as_fn_error $? "Cannot locate the the path of BUILD_AR" "$LINENO" 5 45026 fi 45027 else 45028 input_to_shortpath="$new_path" 45029 fi 45030 45031 # Call helper function which possibly converts this using DOS-style short mode. 45032 # If so, the updated path is stored in $new_path. 45033 new_path="$input_to_shortpath" 45034 45035 input_path="$input_to_shortpath" 45036 # Check if we need to convert this using DOS-style short mode. If the path 45037 # contains just simple characters, use it. Otherwise (spaces, weird characters), 45038 # take no chances and rewrite it. 45039 # Note: m4 eats our [], so we need to use [ and ] instead. 45040 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 45041 if test "x$has_forbidden_chars" != x; then 45042 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 45043 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 45044 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 45045 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 45046 # Going to short mode and back again did indeed matter. Since short mode is 45047 # case insensitive, let's make it lowercase to improve readability. 45048 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 45049 # Now convert it back to Unix-style (cygpath) 45050 input_path=`$CYGPATH -u "$shortmode_path"` 45051 new_path="$input_path" 45052 fi 45053 fi 45054 45055 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 45056 if test "x$test_cygdrive_prefix" = x; then 45057 # As a simple fix, exclude /usr/bin since it's not a real path. 45058 if test "x`$ECHO $input_to_shortpath | $GREP ^/usr/bin/`" = x; then 45059 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 45060 # a path prefixed by /cygdrive for fixpath to work. 45061 new_path="$CYGWIN_ROOT_PATH$input_path" 45062 fi 45063 fi 45064 45065 # remove trailing .exe if any 45066 new_path="${new_path/%.exe/}" 45067 45068 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45069 45070 # First separate the path from the arguments. This will split at the first 45071 # space. 45072 complete="$BUILD_AR" 45073 path="${complete%% *}" 45074 tmp="$complete EOL" 45075 arguments="${tmp#* }" 45076 45077 # Input might be given as Windows format, start by converting to 45078 # unix format. 45079 new_path="$path" 45080 45081 windows_path="$new_path" 45082 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45083 unix_path=`$CYGPATH -u "$windows_path"` 45084 new_path="$unix_path" 45085 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45086 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45087 new_path="$unix_path" 45088 fi 45089 45090 45091 # Now try to locate executable using which 45092 new_path=`$WHICH "$new_path" 2> /dev/null` 45093 45094 if test "x$new_path" = x; then 45095 # Oops. Which didn't find the executable. 45096 # The splitting of arguments from the executable at a space might have been incorrect, 45097 # since paths with space are more likely in Windows. Give it another try with the whole 45098 # argument. 45099 path="$complete" 45100 arguments="EOL" 45101 new_path="$path" 45102 45103 windows_path="$new_path" 45104 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45105 unix_path=`$CYGPATH -u "$windows_path"` 45106 new_path="$unix_path" 45107 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45108 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45109 new_path="$unix_path" 45110 fi 45111 45112 45113 new_path=`$WHICH "$new_path" 2> /dev/null` 45114 # bat and cmd files are not always considered executable in MSYS causing which 45115 # to not find them 45116 if test "x$new_path" = x \ 45117 && test "x`$ECHO \"$path\" | $GREP -i -e \"\\.bat$\" -e \"\\.cmd$\"`" != x \ 45118 && test "x`$LS \"$path\" 2>/dev/null`" != x; then 45119 new_path="$path" 45120 45121 windows_path="$new_path" 45122 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45123 unix_path=`$CYGPATH -u "$windows_path"` 45124 new_path="$unix_path" 45125 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45126 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45127 new_path="$unix_path" 45128 fi 45129 45130 fi 45131 45132 if test "x$new_path" = x; then 45133 # It's still not found. Now this is an unrecoverable error. 45134 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&5 45135 $as_echo "$as_me: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&6;} 45136 has_space=`$ECHO "$complete" | $GREP " "` 45137 if test "x$has_space" != x; then 45138 { $as_echo "$as_me:${as_lineno-$LINENO}: You might be mixing spaces in the path and extra arguments, which is not allowed." >&5 45139 $as_echo "$as_me: You might be mixing spaces in the path and extra arguments, which is not allowed." >&6;} 45140 fi 45141 as_fn_error $? "Cannot locate the the path of BUILD_AR" "$LINENO" 5 45142 fi 45143 fi 45144 45145 # Now new_path has a complete unix path to the binary 45146 if test "x`$ECHO $new_path | $GREP ^/bin/`" != x; then 45147 # Keep paths in /bin as-is, but remove trailing .exe if any 45148 new_path="${new_path/%.exe/}" 45149 # Do not save /bin paths to all_fixpath_prefixes! 45150 else 45151 # Not in mixed or Windows style, start by that. 45152 new_path=`cmd //c echo $new_path` 45153 45154 input_path="$new_path" 45155 # Check if we need to convert this using DOS-style short mode. If the path 45156 # contains just simple characters, use it. Otherwise (spaces, weird characters), 45157 # take no chances and rewrite it. 45158 # Note: m4 eats our [], so we need to use [ and ] instead. 45159 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 45160 if test "x$has_forbidden_chars" != x; then 45161 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 45162 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 45163 fi 45164 45165 # Output is in $new_path 45166 45167 windows_path="$new_path" 45168 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45169 unix_path=`$CYGPATH -u "$windows_path"` 45170 new_path="$unix_path" 45171 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45172 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45173 new_path="$unix_path" 45174 fi 45175 45176 # remove trailing .exe if any 45177 new_path="${new_path/%.exe/}" 45178 45179 # Save the first 10 bytes of this path to the storage, so fixpath can work. 45180 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 45181 fi 45182 45183 else 45184 # We're on a unix platform. Hooray! :) 45185 # First separate the path from the arguments. This will split at the first 45186 # space. 45187 complete="$BUILD_AR" 45188 path="${complete%% *}" 45189 tmp="$complete EOL" 45190 arguments="${tmp#* }" 45191 45192 # Cannot rely on the command "which" here since it doesn't always work. 45193 is_absolute_path=`$ECHO "$path" | $GREP ^/` 45194 if test -z "$is_absolute_path"; then 45195 # Path to executable is not absolute. Find it. 45196 IFS_save="$IFS" 45197 IFS=: 45198 for p in $PATH; do 45199 if test -f "$p/$path" && test -x "$p/$path"; then 45200 new_path="$p/$path" 45201 break 45202 fi 45203 done 45204 IFS="$IFS_save" 45205 else 45206 # This is an absolute path, we can use it without further modifications. 45207 new_path="$path" 45208 fi 45209 45210 if test "x$new_path" = x; then 45211 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&5 45212 $as_echo "$as_me: The path of BUILD_AR, which resolves as \"$complete\", is not found." >&6;} 45213 has_space=`$ECHO "$complete" | $GREP " "` 45214 if test "x$has_space" != x; then 45215 { $as_echo "$as_me:${as_lineno-$LINENO}: This might be caused by spaces in the path, which is not allowed." >&5 45216 $as_echo "$as_me: This might be caused by spaces in the path, which is not allowed." >&6;} 45217 fi 45218 as_fn_error $? "Cannot locate the the path of BUILD_AR" "$LINENO" 5 45219 fi 45220 fi 45221 45222 # Now join together the path and the arguments once again 45223 if test "x$arguments" != xEOL; then 45224 new_complete="$new_path ${arguments% *}" 45225 else 45226 new_complete="$new_path" 45227 fi 45228 45229 if test "x$complete" != "x$new_complete"; then 45230 BUILD_AR="$new_complete" 45231 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting BUILD_AR to \"$new_complete\"" >&5 45232 $as_echo "$as_me: Rewriting BUILD_AR to \"$new_complete\"" >&6;} 45233 fi 45234 fi 45235 45236 # Assume the C compiler is the assembler 45237 BUILD_AS="$BUILD_CC -c" 45238 # Just like for the target compiler, use the compiler as linker 45239 BUILD_LD="$BUILD_CC" 45240 BUILD_LDCXX="$BUILD_CXX" 45241 45242 PATH="$OLDPATH" 45243 else 45244 # If we are not cross compiling, use the normal target compilers for 45245 # building the build platform executables. 45246 BUILD_CC="$CC" 45247 BUILD_CXX="$CXX" 45248 BUILD_LD="$LD" 45249 BUILD_LDCXX="$LDCXX" 45250 BUILD_NM="$NM" 45251 BUILD_AS="$AS" 45252 BUILD_SYSROOT_CFLAGS="$SYSROOT_CFLAGS" 45253 BUILD_SYSROOT_LDFLAGS="$SYSROOT_LDFLAGS" 45254 BUILD_AR="$AR" 45255 fi 45256 45257 45258 45259 45260 45261 45262 45263 45264 45265 45266 45267 45268 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 45269 # For hotspot, we need these in Windows mixed path, 45270 # so rewrite them all. Need added .exe suffix. 45271 HOTSPOT_CXX="$CXX.exe" 45272 HOTSPOT_LD="$LD.exe" 45273 HOTSPOT_MT="$MT.exe" 45274 HOTSPOT_RC="$RC.exe" 45275 45276 unix_path="$HOTSPOT_CXX" 45277 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45278 windows_path=`$CYGPATH -m "$unix_path"` 45279 HOTSPOT_CXX="$windows_path" 45280 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45281 windows_path=`cmd //c echo $unix_path` 45282 HOTSPOT_CXX="$windows_path" 45283 fi 45284 45285 45286 unix_path="$HOTSPOT_LD" 45287 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45288 windows_path=`$CYGPATH -m "$unix_path"` 45289 HOTSPOT_LD="$windows_path" 45290 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45291 windows_path=`cmd //c echo $unix_path` 45292 HOTSPOT_LD="$windows_path" 45293 fi 45294 45295 45296 unix_path="$HOTSPOT_MT" 45297 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45298 windows_path=`$CYGPATH -m "$unix_path"` 45299 HOTSPOT_MT="$windows_path" 45300 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45301 windows_path=`cmd //c echo $unix_path` 45302 HOTSPOT_MT="$windows_path" 45303 fi 45304 45305 45306 unix_path="$HOTSPOT_RC" 45307 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45308 windows_path=`$CYGPATH -m "$unix_path"` 45309 HOTSPOT_RC="$windows_path" 45310 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45311 windows_path=`cmd //c echo $unix_path` 45312 HOTSPOT_RC="$windows_path" 45313 fi 45314 45315 45316 45317 else 45318 HOTSPOT_CXX="$CXX" 45319 HOTSPOT_LD="$LD" 45320 fi 45321 45322 45323 45324 if test "x$TOOLCHAIN_TYPE" = xclang; then 45325 USE_CLANG=true 45326 fi 45327 45328 45329 45330 45331 45332 # The package path is used only on macosx? 45333 # FIXME: clean this up, and/or move it elsewhere. 45334 PACKAGE_PATH=/opt/local 45335 45336 45337 # Check for extra potential brokenness. 45338 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 45339 # On Windows, double-check that we got the right compiler. 45340 CC_VERSION_OUTPUT=`$CC 2>&1 | $HEAD -n 1 | $TR -d '\r'` 45341 COMPILER_CPU_TEST=`$ECHO $CC_VERSION_OUTPUT | $SED -n "s/^.* \(.*\)$/\1/p"` 45342 if test "x$OPENJDK_TARGET_CPU" = "xx86"; then 45343 if test "x$COMPILER_CPU_TEST" != "x80x86" -a "x$COMPILER_CPU_TEST" != "xx86"; then 45344 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 45345 fi 45346 elif test "x$OPENJDK_TARGET_CPU" = "xx86_64"; then 45347 if test "x$COMPILER_CPU_TEST" != "xx64"; then 45348 as_fn_error $? "Target CPU mismatch. We are building for $OPENJDK_TARGET_CPU but CL is for \"$COMPILER_CPU_TEST\"; expected \"x64\"." "$LINENO" 5 45349 fi 45350 fi 45351 fi 45352 45353 if test "x$TOOLCHAIN_TYPE" = xgcc; then 45354 # If this is a --hash-style=gnu system, use --hash-style=both, why? 45355 HAS_GNU_HASH=`$CC -dumpspecs 2>/dev/null | $GREP 'hash-style=gnu'` 45356 # This is later checked when setting flags. 45357 45358 # "-Og" suppported for GCC 4.8 and later 45359 CFLAG_OPTIMIZE_DEBUG_FLAG="-Og" 45360 45361 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler supports \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"" >&5 45362 $as_echo_n "checking if compiler supports \"$CFLAG_OPTIMIZE_DEBUG_FLAG\"... " >&6; } 45363 supports=yes 45364 45365 saved_cflags="$CFLAGS" 45366 CFLAGS="$CFLAGS $CFLAG_OPTIMIZE_DEBUG_FLAG" 45367 ac_ext=c 45368 ac_cpp='$CPP $CPPFLAGS' 45369 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 45370 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 45371 ac_compiler_gnu=$ac_cv_c_compiler_gnu 45372 45373 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 45374 /* end confdefs.h. */ 45375 int i; 45376 _ACEOF 45377 if ac_fn_c_try_compile "$LINENO"; then : 45378 45379 else 45380 supports=no 45381 fi 45382 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 45383 ac_ext=cpp 45384 ac_cpp='$CXXCPP $CPPFLAGS' 45385 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 45386 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 45387 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 45388 45389 CFLAGS="$saved_cflags" 45390 45391 saved_cxxflags="$CXXFLAGS" 45392 CXXFLAGS="$CXXFLAG $CFLAG_OPTIMIZE_DEBUG_FLAG" 45393 ac_ext=cpp 45394 ac_cpp='$CXXCPP $CPPFLAGS' 45395 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 45396 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 45397 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 45398 45399 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 45400 /* end confdefs.h. */ 45401 int i; 45402 _ACEOF 45403 if ac_fn_cxx_try_compile "$LINENO"; then : 45404 45405 else 45406 supports=no 45407 fi 45408 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 45409 ac_ext=cpp 45410 ac_cpp='$CXXCPP $CPPFLAGS' 45411 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 45412 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 45413 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 45414 45415 CXXFLAGS="$saved_cxxflags" 45416 45417 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 45418 $as_echo "$supports" >&6; } 45419 if test "x$supports" = "xyes" ; then 45420 HAS_CFLAG_OPTIMIZE_DEBUG=true 45421 else 45422 HAS_CFLAG_OPTIMIZE_DEBUG=false 45423 fi 45424 45425 45426 # "-z relro" supported in GNU binutils 2.17 and later 45427 LINKER_RELRO_FLAG="-Wl,-z,relro" 45428 45429 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if linker supports \"$LINKER_RELRO_FLAG\"" >&5 45430 $as_echo_n "checking if linker supports \"$LINKER_RELRO_FLAG\"... " >&6; } 45431 supports=yes 45432 45433 saved_ldflags="$LDFLAGS" 45434 LDFLAGS="$LDFLAGS $LINKER_RELRO_FLAG" 45435 ac_ext=c 45436 ac_cpp='$CPP $CPPFLAGS' 45437 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 45438 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 45439 ac_compiler_gnu=$ac_cv_c_compiler_gnu 45440 45441 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 45442 /* end confdefs.h. */ 45443 45444 int 45445 main () 45446 { 45447 45448 ; 45449 return 0; 45450 } 45451 _ACEOF 45452 if ac_fn_c_try_link "$LINENO"; then : 45453 45454 else 45455 supports=no 45456 fi 45457 rm -f core conftest.err conftest.$ac_objext \ 45458 conftest$ac_exeext conftest.$ac_ext 45459 ac_ext=cpp 45460 ac_cpp='$CXXCPP $CPPFLAGS' 45461 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 45462 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 45463 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 45464 45465 LDFLAGS="$saved_ldflags" 45466 45467 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 45468 $as_echo "$supports" >&6; } 45469 if test "x$supports" = "xyes" ; then 45470 HAS_LINKER_RELRO=true 45471 else 45472 HAS_LINKER_RELRO=false 45473 fi 45474 45475 45476 # "-z now" supported in GNU binutils 2.11 and later 45477 LINKER_NOW_FLAG="-Wl,-z,now" 45478 45479 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if linker supports \"$LINKER_NOW_FLAG\"" >&5 45480 $as_echo_n "checking if linker supports \"$LINKER_NOW_FLAG\"... " >&6; } 45481 supports=yes 45482 45483 saved_ldflags="$LDFLAGS" 45484 LDFLAGS="$LDFLAGS $LINKER_NOW_FLAG" 45485 ac_ext=c 45486 ac_cpp='$CPP $CPPFLAGS' 45487 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 45488 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 45489 ac_compiler_gnu=$ac_cv_c_compiler_gnu 45490 45491 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 45492 /* end confdefs.h. */ 45493 45494 int 45495 main () 45496 { 45497 45498 ; 45499 return 0; 45500 } 45501 _ACEOF 45502 if ac_fn_c_try_link "$LINENO"; then : 45503 45504 else 45505 supports=no 45506 fi 45507 rm -f core conftest.err conftest.$ac_objext \ 45508 conftest$ac_exeext conftest.$ac_ext 45509 ac_ext=cpp 45510 ac_cpp='$CXXCPP $CPPFLAGS' 45511 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 45512 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 45513 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 45514 45515 LDFLAGS="$saved_ldflags" 45516 45517 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 45518 $as_echo "$supports" >&6; } 45519 if test "x$supports" = "xyes" ; then 45520 HAS_LINKER_NOW=true 45521 else 45522 HAS_LINKER_NOW=false 45523 fi 45524 45525 fi 45526 45527 # Check for broken SuSE 'ld' for which 'Only anonymous version tag is allowed 45528 # in executable.' 45529 USING_BROKEN_SUSE_LD=no 45530 if test "x$OPENJDK_TARGET_OS" = xlinux && test "x$TOOLCHAIN_TYPE" = xgcc; then 45531 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for broken SuSE 'ld' which only understands anonymous version tags in executables" >&5 45532 $as_echo_n "checking for broken SuSE 'ld' which only understands anonymous version tags in executables... " >&6; } 45533 $ECHO "SUNWprivate_1.1 { local: *; };" > version-script.map 45534 $ECHO "int main() { }" > main.c 45535 if $CXX -Wl,-version-script=version-script.map main.c 2>&5 >&5; then 45536 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45537 $as_echo "no" >&6; } 45538 USING_BROKEN_SUSE_LD=no 45539 else 45540 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 45541 $as_echo "yes" >&6; } 45542 USING_BROKEN_SUSE_LD=yes 45543 fi 45544 rm -rf version-script.map main.c a.out 45545 fi 45546 45547 45548 45549 # Setup the JTReg Regression Test Harness. 45550 45551 45552 # Check whether --with-jtreg was given. 45553 if test "${with_jtreg+set}" = set; then : 45554 withval=$with_jtreg; 45555 else 45556 with_jtreg=no 45557 fi 45558 45559 45560 if test "x$with_jtreg" = xno; then 45561 # jtreg disabled 45562 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jtreg" >&5 45563 $as_echo_n "checking for jtreg... " >&6; } 45564 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45565 $as_echo "no" >&6; } 45566 else 45567 if test "x$with_jtreg" != xyes; then 45568 # with path specified. 45569 JT_HOME="$with_jtreg" 45570 fi 45571 45572 if test "x$JT_HOME" != x; then 45573 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jtreg" >&5 45574 $as_echo_n "checking for jtreg... " >&6; } 45575 45576 # use JT_HOME enviroment var. 45577 45578 # Only process if variable expands to non-empty 45579 45580 if test "x$JT_HOME" != x; then 45581 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45582 45583 # Input might be given as Windows format, start by converting to 45584 # unix format. 45585 path="$JT_HOME" 45586 new_path=`$CYGPATH -u "$path"` 45587 45588 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 45589 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 45590 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 45591 # "foo.exe" is OK but "foo" is an error. 45592 # 45593 # This test is therefore slightly more accurate than "test -f" to check for file precense. 45594 # It is also a way to make sure we got the proper file name for the real test later on. 45595 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 45596 if test "x$test_shortpath" = x; then 45597 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JT_HOME, which resolves as \"$path\", is invalid." >&5 45598 $as_echo "$as_me: The path of JT_HOME, which resolves as \"$path\", is invalid." >&6;} 45599 as_fn_error $? "Cannot locate the the path of JT_HOME" "$LINENO" 5 45600 fi 45601 45602 # Call helper function which possibly converts this using DOS-style short mode. 45603 # If so, the updated path is stored in $new_path. 45604 45605 input_path="$new_path" 45606 # Check if we need to convert this using DOS-style short mode. If the path 45607 # contains just simple characters, use it. Otherwise (spaces, weird characters), 45608 # take no chances and rewrite it. 45609 # Note: m4 eats our [], so we need to use [ and ] instead. 45610 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 45611 if test "x$has_forbidden_chars" != x; then 45612 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 45613 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 45614 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 45615 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 45616 # Going to short mode and back again did indeed matter. Since short mode is 45617 # case insensitive, let's make it lowercase to improve readability. 45618 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 45619 # Now convert it back to Unix-style (cygpath) 45620 input_path=`$CYGPATH -u "$shortmode_path"` 45621 new_path="$input_path" 45622 fi 45623 fi 45624 45625 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 45626 if test "x$test_cygdrive_prefix" = x; then 45627 # As a simple fix, exclude /usr/bin since it's not a real path. 45628 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 45629 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 45630 # a path prefixed by /cygdrive for fixpath to work. 45631 new_path="$CYGWIN_ROOT_PATH$input_path" 45632 fi 45633 fi 45634 45635 45636 if test "x$path" != "x$new_path"; then 45637 JT_HOME="$new_path" 45638 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JT_HOME to \"$new_path\"" >&5 45639 $as_echo "$as_me: Rewriting JT_HOME to \"$new_path\"" >&6;} 45640 fi 45641 45642 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45643 45644 path="$JT_HOME" 45645 has_colon=`$ECHO $path | $GREP ^.:` 45646 new_path="$path" 45647 if test "x$has_colon" = x; then 45648 # Not in mixed or Windows style, start by that. 45649 new_path=`cmd //c echo $path` 45650 fi 45651 45652 45653 input_path="$new_path" 45654 # Check if we need to convert this using DOS-style short mode. If the path 45655 # contains just simple characters, use it. Otherwise (spaces, weird characters), 45656 # take no chances and rewrite it. 45657 # Note: m4 eats our [], so we need to use [ and ] instead. 45658 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 45659 if test "x$has_forbidden_chars" != x; then 45660 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 45661 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 45662 fi 45663 45664 45665 windows_path="$new_path" 45666 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 45667 unix_path=`$CYGPATH -u "$windows_path"` 45668 new_path="$unix_path" 45669 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 45670 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 45671 new_path="$unix_path" 45672 fi 45673 45674 if test "x$path" != "x$new_path"; then 45675 JT_HOME="$new_path" 45676 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting JT_HOME to \"$new_path\"" >&5 45677 $as_echo "$as_me: Rewriting JT_HOME to \"$new_path\"" >&6;} 45678 fi 45679 45680 # Save the first 10 bytes of this path to the storage, so fixpath can work. 45681 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 45682 45683 else 45684 # We're on a unix platform. Hooray! :) 45685 path="$JT_HOME" 45686 has_space=`$ECHO "$path" | $GREP " "` 45687 if test "x$has_space" != x; then 45688 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of JT_HOME, which resolves as \"$path\", is invalid." >&5 45689 $as_echo "$as_me: The path of JT_HOME, which resolves as \"$path\", is invalid." >&6;} 45690 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 45691 fi 45692 45693 # Use eval to expand a potential ~ 45694 eval path="$path" 45695 if test ! -f "$path" && test ! -d "$path"; then 45696 as_fn_error $? "The path of JT_HOME, which resolves as \"$path\", is not found." "$LINENO" 5 45697 fi 45698 45699 if test -d "$path"; then 45700 JT_HOME="`cd "$path"; $THEPWDCMD -L`" 45701 else 45702 dir="`$DIRNAME "$path"`" 45703 base="`$BASENAME "$path"`" 45704 JT_HOME="`cd "$dir"; $THEPWDCMD -L`/$base" 45705 fi 45706 fi 45707 fi 45708 45709 45710 # jtreg win32 script works for everybody 45711 JTREGEXE="$JT_HOME/bin/jtreg" 45712 45713 if test ! -f "$JTREGEXE"; then 45714 as_fn_error $? "JTReg executable does not exist: $JTREGEXE" "$LINENO" 5 45715 fi 45716 45717 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5 45718 $as_echo "$JTREGEXE" >&6; } 45719 else 45720 # try to find jtreg on path 45721 45722 45723 45724 # Publish this variable in the help. 45725 45726 45727 if [ -z "${JTREGEXE+x}" ]; then 45728 # The variable is not set by user, try to locate tool using the code snippet 45729 for ac_prog in jtreg 45730 do 45731 # Extract the first word of "$ac_prog", so it can be a program name with args. 45732 set dummy $ac_prog; ac_word=$2 45733 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45734 $as_echo_n "checking for $ac_word... " >&6; } 45735 if ${ac_cv_path_JTREGEXE+:} false; then : 45736 $as_echo_n "(cached) " >&6 45737 else 45738 case $JTREGEXE in 45739 [\\/]* | ?:[\\/]*) 45740 ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path. 45741 ;; 45742 *) 45743 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45744 for as_dir in $PATH 45745 do 45746 IFS=$as_save_IFS 45747 test -z "$as_dir" && as_dir=. 45748 for ac_exec_ext in '' $ac_executable_extensions; do 45749 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45750 ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext" 45751 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45752 break 2 45753 fi 45754 done 45755 done 45756 IFS=$as_save_IFS 45757 45758 ;; 45759 esac 45760 fi 45761 JTREGEXE=$ac_cv_path_JTREGEXE 45762 if test -n "$JTREGEXE"; then 45763 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5 45764 $as_echo "$JTREGEXE" >&6; } 45765 else 45766 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45767 $as_echo "no" >&6; } 45768 fi 45769 45770 45771 test -n "$JTREGEXE" && break 45772 done 45773 45774 else 45775 # The variable is set, but is it from the command line or the environment? 45776 45777 # Try to remove the string !JTREGEXE! from our list. 45778 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!JTREGEXE!/} 45779 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 45780 # If it failed, the variable was not from the command line. Ignore it, 45781 # but warn the user (except for BASH, which is always set by the calling BASH). 45782 if test "xJTREGEXE" != xBASH; then 45783 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of JTREGEXE from the environment. Use command line variables instead." >&5 45784 $as_echo "$as_me: WARNING: Ignoring value of JTREGEXE from the environment. Use command line variables instead." >&2;} 45785 fi 45786 # Try to locate tool using the code snippet 45787 for ac_prog in jtreg 45788 do 45789 # Extract the first word of "$ac_prog", so it can be a program name with args. 45790 set dummy $ac_prog; ac_word=$2 45791 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45792 $as_echo_n "checking for $ac_word... " >&6; } 45793 if ${ac_cv_path_JTREGEXE+:} false; then : 45794 $as_echo_n "(cached) " >&6 45795 else 45796 case $JTREGEXE in 45797 [\\/]* | ?:[\\/]*) 45798 ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path. 45799 ;; 45800 *) 45801 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45802 for as_dir in $PATH 45803 do 45804 IFS=$as_save_IFS 45805 test -z "$as_dir" && as_dir=. 45806 for ac_exec_ext in '' $ac_executable_extensions; do 45807 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45808 ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext" 45809 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45810 break 2 45811 fi 45812 done 45813 done 45814 IFS=$as_save_IFS 45815 45816 ;; 45817 esac 45818 fi 45819 JTREGEXE=$ac_cv_path_JTREGEXE 45820 if test -n "$JTREGEXE"; then 45821 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5 45822 $as_echo "$JTREGEXE" >&6; } 45823 else 45824 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45825 $as_echo "no" >&6; } 45826 fi 45827 45828 45829 test -n "$JTREGEXE" && break 45830 done 45831 45832 else 45833 # If it succeeded, then it was overridden by the user. We will use it 45834 # for the tool. 45835 45836 # First remove it from the list of overridden variables, so we can test 45837 # for unknown variables in the end. 45838 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 45839 45840 # Check if we try to supply an empty value 45841 if test "x$JTREGEXE" = x; then 45842 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool JTREGEXE= (no value)" >&5 45843 $as_echo "$as_me: Setting user supplied tool JTREGEXE= (no value)" >&6;} 45844 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JTREGEXE" >&5 45845 $as_echo_n "checking for JTREGEXE... " >&6; } 45846 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 45847 $as_echo "disabled" >&6; } 45848 else 45849 # Check if the provided tool contains a complete path. 45850 tool_specified="$JTREGEXE" 45851 tool_basename="${tool_specified##*/}" 45852 if test "x$tool_basename" = "x$tool_specified"; then 45853 # A command without a complete path is provided, search $PATH. 45854 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool JTREGEXE=$tool_basename" >&5 45855 $as_echo "$as_me: Will search for user supplied tool JTREGEXE=$tool_basename" >&6;} 45856 # Extract the first word of "$tool_basename", so it can be a program name with args. 45857 set dummy $tool_basename; ac_word=$2 45858 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 45859 $as_echo_n "checking for $ac_word... " >&6; } 45860 if ${ac_cv_path_JTREGEXE+:} false; then : 45861 $as_echo_n "(cached) " >&6 45862 else 45863 case $JTREGEXE in 45864 [\\/]* | ?:[\\/]*) 45865 ac_cv_path_JTREGEXE="$JTREGEXE" # Let the user override the test with a path. 45866 ;; 45867 *) 45868 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 45869 for as_dir in $PATH 45870 do 45871 IFS=$as_save_IFS 45872 test -z "$as_dir" && as_dir=. 45873 for ac_exec_ext in '' $ac_executable_extensions; do 45874 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 45875 ac_cv_path_JTREGEXE="$as_dir/$ac_word$ac_exec_ext" 45876 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 45877 break 2 45878 fi 45879 done 45880 done 45881 IFS=$as_save_IFS 45882 45883 ;; 45884 esac 45885 fi 45886 JTREGEXE=$ac_cv_path_JTREGEXE 45887 if test -n "$JTREGEXE"; then 45888 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JTREGEXE" >&5 45889 $as_echo "$JTREGEXE" >&6; } 45890 else 45891 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45892 $as_echo "no" >&6; } 45893 fi 45894 45895 45896 if test "x$JTREGEXE" = x; then 45897 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 45898 fi 45899 else 45900 # Otherwise we believe it is a complete path. Use it as it is. 45901 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool JTREGEXE=$tool_specified" >&5 45902 $as_echo "$as_me: Will use user supplied tool JTREGEXE=$tool_specified" >&6;} 45903 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for JTREGEXE" >&5 45904 $as_echo_n "checking for JTREGEXE... " >&6; } 45905 if test ! -x "$tool_specified"; then 45906 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 45907 $as_echo "not found" >&6; } 45908 as_fn_error $? "User supplied tool JTREGEXE=$tool_specified does not exist or is not executable" "$LINENO" 5 45909 fi 45910 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 45911 $as_echo "$tool_specified" >&6; } 45912 fi 45913 fi 45914 fi 45915 45916 fi 45917 45918 45919 45920 if test "x$JTREGEXE" = x; then 45921 as_fn_error $? "Could not find required tool for JTREGEXE" "$LINENO" 5 45922 fi 45923 45924 45925 JT_HOME="`$DIRNAME $JTREGEXE`" 45926 fi 45927 fi 45928 45929 45930 45931 45932 45933 45934 # COMPILER_TARGET_BITS_FLAG : option for selecting 32- or 64-bit output 45935 # COMPILER_COMMAND_FILE_FLAG : option for passing a command file to the compiler 45936 if test "x$TOOLCHAIN_TYPE" = xxlc; then 45937 COMPILER_TARGET_BITS_FLAG="-q" 45938 COMPILER_COMMAND_FILE_FLAG="-f" 45939 else 45940 COMPILER_TARGET_BITS_FLAG="-m" 45941 COMPILER_COMMAND_FILE_FLAG="@" 45942 45943 # The solstudio linker does not support @-files. 45944 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 45945 COMPILER_COMMAND_FILE_FLAG= 45946 fi 45947 45948 # Check if @file is supported by gcc 45949 if test "x$TOOLCHAIN_TYPE" = xgcc; then 45950 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if @file is supported by gcc" >&5 45951 $as_echo_n "checking if @file is supported by gcc... " >&6; } 45952 # Extra emtpy "" to prevent ECHO from interpreting '--version' as argument 45953 $ECHO "" "--version" > command.file 45954 if $CXX @command.file 2>&5 >&5; then 45955 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 45956 $as_echo "yes" >&6; } 45957 COMPILER_COMMAND_FILE_FLAG="@" 45958 else 45959 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 45960 $as_echo "no" >&6; } 45961 COMPILER_COMMAND_FILE_FLAG= 45962 fi 45963 rm -rf command.file 45964 fi 45965 fi 45966 45967 45968 45969 # FIXME: figure out if we should select AR flags depending on OS or toolchain. 45970 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 45971 ARFLAGS="-r" 45972 elif test "x$OPENJDK_TARGET_OS" = xaix; then 45973 ARFLAGS="-X64" 45974 elif test "x$OPENJDK_TARGET_OS" = xwindows; then 45975 # lib.exe is used as AR to create static libraries. 45976 ARFLAGS="-nologo -NODEFAULTLIB:MSVCRT" 45977 else 45978 ARFLAGS="" 45979 fi 45980 45981 45982 ## Setup strip. 45983 # FIXME: should this really be per platform, or should it be per toolchain type? 45984 # strip is not provided by clang or solstudio; so guessing platform makes most sense. 45985 # FIXME: we should really only export STRIPFLAGS from here, not POST_STRIP_CMD. 45986 if test "x$OPENJDK_TARGET_OS" = xlinux; then 45987 STRIPFLAGS="-g" 45988 elif test "x$OPENJDK_TARGET_OS" = xsolaris; then 45989 STRIPFLAGS="-x" 45990 elif test "x$OPENJDK_TARGET_OS" = xmacosx; then 45991 STRIPFLAGS="-S" 45992 elif test "x$OPENJDK_TARGET_OS" = xaix; then 45993 STRIPFLAGS="-X32_64" 45994 fi 45995 45996 45997 45998 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 45999 CC_OUT_OPTION=-Fo 46000 EXE_OUT_OPTION=-out: 46001 LD_OUT_OPTION=-out: 46002 AR_OUT_OPTION=-out: 46003 else 46004 # The option used to specify the target .o,.a or .so file. 46005 # When compiling, how to specify the to be created object file. 46006 CC_OUT_OPTION='-o$(SPACE)' 46007 # When linking, how to specify the to be created executable. 46008 EXE_OUT_OPTION='-o$(SPACE)' 46009 # When linking, how to specify the to be created dynamically linkable library. 46010 LD_OUT_OPTION='-o$(SPACE)' 46011 # When archiving, how to specify the to be create static archive for object files. 46012 AR_OUT_OPTION='rcs$(SPACE)' 46013 fi 46014 46015 46016 46017 46018 46019 # On Windows, we need to set RC flags. 46020 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 46021 RC_FLAGS="-nologo -l0x409" 46022 if test "x$VARIANT" = xOPT; then 46023 RC_FLAGS="$RC_FLAGS -DNDEBUG" 46024 fi 46025 46026 # The version variables used to create RC_FLAGS may be overridden 46027 # in a custom configure script, or possibly the command line. 46028 # Let those variables be expanded at make time in spec.gmk. 46029 # The \$ are escaped to the shell, and the $(...) variables 46030 # are evaluated by make. 46031 RC_FLAGS="$RC_FLAGS \ 46032 -D\"JDK_VERSION_STRING=\$(VERSION_STRING)\" \ 46033 -D\"JDK_COMPANY=\$(COMPANY_NAME)\" \ 46034 -D\"JDK_COMPONENT=\$(PRODUCT_NAME) \$(JDK_RC_PLATFORM_NAME) binary\" \ 46035 -D\"JDK_VER=\$(VERSION_NUMBER)\" \ 46036 -D\"JDK_COPYRIGHT=Copyright \xA9 $COPYRIGHT_YEAR\" \ 46037 -D\"JDK_NAME=\$(PRODUCT_NAME) \$(JDK_RC_PLATFORM_NAME) \$(VERSION_MAJOR)\" \ 46038 -D\"JDK_FVER=\$(subst .,\$(COMMA),\$(VERSION_NUMBER_FOUR_POSITIONS))\"" 46039 fi 46040 46041 46042 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 46043 # silence copyright notice and other headers. 46044 COMMON_CCXXFLAGS="$COMMON_CCXXFLAGS -nologo" 46045 fi 46046 46047 46048 # FIXME: Currently we must test this after toolchain but before flags. Fix! 46049 46050 # Now we can test some aspects on the target using configure macros. 46051 46052 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5 46053 $as_echo_n "checking for ANSI C header files... " >&6; } 46054 if ${ac_cv_header_stdc+:} false; then : 46055 $as_echo_n "(cached) " >&6 46056 else 46057 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 46058 /* end confdefs.h. */ 46059 #include <stdlib.h> 46060 #include <stdarg.h> 46061 #include <string.h> 46062 #include <float.h> 46063 46064 int 46065 main () 46066 { 46067 46068 ; 46069 return 0; 46070 } 46071 _ACEOF 46072 if ac_fn_cxx_try_compile "$LINENO"; then : 46073 ac_cv_header_stdc=yes 46074 else 46075 ac_cv_header_stdc=no 46076 fi 46077 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 46078 46079 if test $ac_cv_header_stdc = yes; then 46080 # SunOS 4.x string.h does not declare mem*, contrary to ANSI. 46081 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 46082 /* end confdefs.h. */ 46083 #include <string.h> 46084 46085 _ACEOF 46086 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 46087 $EGREP "memchr" >/dev/null 2>&1; then : 46088 46089 else 46090 ac_cv_header_stdc=no 46091 fi 46092 rm -f conftest* 46093 46094 fi 46095 46096 if test $ac_cv_header_stdc = yes; then 46097 # ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI. 46098 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 46099 /* end confdefs.h. */ 46100 #include <stdlib.h> 46101 46102 _ACEOF 46103 if (eval "$ac_cpp conftest.$ac_ext") 2>&5 | 46104 $EGREP "free" >/dev/null 2>&1; then : 46105 46106 else 46107 ac_cv_header_stdc=no 46108 fi 46109 rm -f conftest* 46110 46111 fi 46112 46113 if test $ac_cv_header_stdc = yes; then 46114 # /bin/cc in Irix-4.0.5 gets non-ANSI ctype macros unless using -ansi. 46115 if test "$cross_compiling" = yes; then : 46116 : 46117 else 46118 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 46119 /* end confdefs.h. */ 46120 #include <ctype.h> 46121 #include <stdlib.h> 46122 #if ((' ' & 0x0FF) == 0x020) 46123 # define ISLOWER(c) ('a' <= (c) && (c) <= 'z') 46124 # define TOUPPER(c) (ISLOWER(c) ? 'A' + ((c) - 'a') : (c)) 46125 #else 46126 # define ISLOWER(c) \ 46127 (('a' <= (c) && (c) <= 'i') \ 46128 || ('j' <= (c) && (c) <= 'r') \ 46129 || ('s' <= (c) && (c) <= 'z')) 46130 # define TOUPPER(c) (ISLOWER(c) ? ((c) | 0x40) : (c)) 46131 #endif 46132 46133 #define XOR(e, f) (((e) && !(f)) || (!(e) && (f))) 46134 int 46135 main () 46136 { 46137 int i; 46138 for (i = 0; i < 256; i++) 46139 if (XOR (islower (i), ISLOWER (i)) 46140 || toupper (i) != TOUPPER (i)) 46141 return 2; 46142 return 0; 46143 } 46144 _ACEOF 46145 if ac_fn_cxx_try_run "$LINENO"; then : 46146 46147 else 46148 ac_cv_header_stdc=no 46149 fi 46150 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 46151 conftest.$ac_objext conftest.beam conftest.$ac_ext 46152 fi 46153 46154 fi 46155 fi 46156 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_header_stdc" >&5 46157 $as_echo "$ac_cv_header_stdc" >&6; } 46158 if test $ac_cv_header_stdc = yes; then 46159 46160 $as_echo "#define STDC_HEADERS 1" >>confdefs.h 46161 46162 fi 46163 46164 # On IRIX 5.3, sys/types and inttypes.h are conflicting. 46165 for ac_header in sys/types.h sys/stat.h stdlib.h string.h memory.h strings.h \ 46166 inttypes.h stdint.h unistd.h 46167 do : 46168 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` 46169 ac_fn_cxx_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default 46170 " 46171 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : 46172 cat >>confdefs.h <<_ACEOF 46173 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 46174 _ACEOF 46175 46176 fi 46177 46178 done 46179 46180 46181 46182 ############################################################################### 46183 # 46184 # Now we check if libjvm.so will use 32 or 64 bit pointers for the C/C++ code. 46185 # (The JVM can use 32 or 64 bit Java pointers but that decision 46186 # is made at runtime.) 46187 # 46188 46189 if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xaix; then 46190 # Always specify -m flag on Solaris 46191 # And -q on AIX because otherwise the compiler produces 32-bit objects by default 46192 46193 # When we add flags to the "official" CFLAGS etc, we need to 46194 # keep track of these additions in ADDED_CFLAGS etc. These 46195 # will later be checked to make sure only controlled additions 46196 # have been made to CFLAGS etc. 46197 ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 46198 ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 46199 ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 46200 46201 CFLAGS="${CFLAGS}${ADDED_CFLAGS}" 46202 CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}" 46203 LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}" 46204 46205 CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}" 46206 CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}" 46207 LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}" 46208 46209 elif test "x$COMPILE_TYPE" = xreduced; then 46210 if test "x$OPENJDK_TARGET_OS_TYPE" = xunix; then 46211 # Specify -m if running reduced on unix platforms 46212 46213 # When we add flags to the "official" CFLAGS etc, we need to 46214 # keep track of these additions in ADDED_CFLAGS etc. These 46215 # will later be checked to make sure only controlled additions 46216 # have been made to CFLAGS etc. 46217 ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 46218 ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 46219 ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 46220 46221 CFLAGS="${CFLAGS}${ADDED_CFLAGS}" 46222 CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}" 46223 LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}" 46224 46225 CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}" 46226 CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}" 46227 LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}" 46228 46229 fi 46230 fi 46231 46232 # Make compilation sanity check 46233 for ac_header in stdio.h 46234 do : 46235 ac_fn_cxx_check_header_mongrel "$LINENO" "stdio.h" "ac_cv_header_stdio_h" "$ac_includes_default" 46236 if test "x$ac_cv_header_stdio_h" = xyes; then : 46237 cat >>confdefs.h <<_ACEOF 46238 #define HAVE_STDIO_H 1 46239 _ACEOF 46240 46241 else 46242 46243 { $as_echo "$as_me:${as_lineno-$LINENO}: Failed to compile stdio.h. This likely implies missing compile dependencies." >&5 46244 $as_echo "$as_me: Failed to compile stdio.h. This likely implies missing compile dependencies." >&6;} 46245 if test "x$COMPILE_TYPE" = xreduced; then 46246 46247 # Print a helpful message on how to acquire the necessary build dependency. 46248 # reduced is the help tag: freetype, cups, alsa etc 46249 MISSING_DEPENDENCY=reduced 46250 46251 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46252 cygwin_help $MISSING_DEPENDENCY 46253 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46254 msys_help $MISSING_DEPENDENCY 46255 else 46256 PKGHANDLER_COMMAND= 46257 46258 case $PKGHANDLER in 46259 apt-get) 46260 apt_help $MISSING_DEPENDENCY ;; 46261 yum) 46262 yum_help $MISSING_DEPENDENCY ;; 46263 port) 46264 port_help $MISSING_DEPENDENCY ;; 46265 pkgutil) 46266 pkgutil_help $MISSING_DEPENDENCY ;; 46267 pkgadd) 46268 pkgadd_help $MISSING_DEPENDENCY ;; 46269 esac 46270 46271 if test "x$PKGHANDLER_COMMAND" != x; then 46272 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 46273 fi 46274 fi 46275 46276 { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a reduced build. Check that you have 32-bit libraries installed. $HELP_MSG" >&5 46277 $as_echo "$as_me: You are doing a reduced build. Check that you have 32-bit libraries installed. $HELP_MSG" >&6;} 46278 elif test "x$COMPILE_TYPE" = xcross; then 46279 { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&5 46280 $as_echo "$as_me: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&6;} 46281 fi 46282 as_fn_error $? "Cannot continue." "$LINENO" 5 46283 46284 fi 46285 46286 done 46287 46288 46289 # The cast to long int works around a bug in the HP C Compiler 46290 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects 46291 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. 46292 # This bug is HP SR number 8606223364. 46293 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int *" >&5 46294 $as_echo_n "checking size of int *... " >&6; } 46295 if ${ac_cv_sizeof_int_p+:} false; then : 46296 $as_echo_n "(cached) " >&6 46297 else 46298 if ac_fn_cxx_compute_int "$LINENO" "(long int) (sizeof (int *))" "ac_cv_sizeof_int_p" "$ac_includes_default"; then : 46299 46300 else 46301 if test "$ac_cv_type_int_p" = yes; then 46302 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 46303 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 46304 as_fn_error 77 "cannot compute sizeof (int *) 46305 See \`config.log' for more details" "$LINENO" 5; } 46306 else 46307 ac_cv_sizeof_int_p=0 46308 fi 46309 fi 46310 46311 fi 46312 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int_p" >&5 46313 $as_echo "$ac_cv_sizeof_int_p" >&6; } 46314 46315 46316 46317 cat >>confdefs.h <<_ACEOF 46318 #define SIZEOF_INT_P $ac_cv_sizeof_int_p 46319 _ACEOF 46320 46321 46322 46323 # AC_CHECK_SIZEOF defines 'ac_cv_sizeof_int_p' to hold the number of bytes used by an 'int*' 46324 if test "x$ac_cv_sizeof_int_p" = x; then 46325 # The test failed, lets stick to the assumed value. 46326 { $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 46327 $as_echo "$as_me: WARNING: The number of bits in the target could not be determined, using $OPENJDK_TARGET_CPU_BITS." >&2;} 46328 else 46329 TESTED_TARGET_CPU_BITS=`expr 8 \* $ac_cv_sizeof_int_p` 46330 46331 if test "x$TESTED_TARGET_CPU_BITS" != "x$OPENJDK_TARGET_CPU_BITS"; then 46332 # This situation may happen on 64-bit platforms where the compiler by default only generates 32-bit objects 46333 # Let's try to implicitely set the compilers target architecture and retry the test 46334 { $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 46335 $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;} 46336 { $as_echo "$as_me:${as_lineno-$LINENO}: Retrying with platforms compiler target bits flag to ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" >&5 46337 $as_echo "$as_me: Retrying with platforms compiler target bits flag to ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" >&6;} 46338 46339 # When we add flags to the "official" CFLAGS etc, we need to 46340 # keep track of these additions in ADDED_CFLAGS etc. These 46341 # will later be checked to make sure only controlled additions 46342 # have been made to CFLAGS etc. 46343 ADDED_CFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 46344 ADDED_CXXFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 46345 ADDED_LDFLAGS=" ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 46346 46347 CFLAGS="${CFLAGS}${ADDED_CFLAGS}" 46348 CXXFLAGS="${CXXFLAGS}${ADDED_CXXFLAGS}" 46349 LDFLAGS="${LDFLAGS}${ADDED_LDFLAGS}" 46350 46351 CFLAGS_JDK="${CFLAGS_JDK}${ADDED_CFLAGS}" 46352 CXXFLAGS_JDK="${CXXFLAGS_JDK}${ADDED_CXXFLAGS}" 46353 LDFLAGS_JDK="${LDFLAGS_JDK}${ADDED_LDFLAGS}" 46354 46355 46356 # We have to unset 'ac_cv_sizeof_int_p' first, otherwise AC_CHECK_SIZEOF will use the previously cached value! 46357 unset ac_cv_sizeof_int_p 46358 # And we have to undef the definition of SIZEOF_INT_P in confdefs.h by the previous invocation of AC_CHECK_SIZEOF 46359 cat >>confdefs.h <<_ACEOF 46360 #undef SIZEOF_INT_P 46361 _ACEOF 46362 46363 # The cast to long int works around a bug in the HP C Compiler 46364 # version HP92453-01 B.11.11.23709.GP, which incorrectly rejects 46365 # declarations like `int a3[[(sizeof (unsigned char)) >= 0]];'. 46366 # This bug is HP SR number 8606223364. 46367 { $as_echo "$as_me:${as_lineno-$LINENO}: checking size of int *" >&5 46368 $as_echo_n "checking size of int *... " >&6; } 46369 if ${ac_cv_sizeof_int_p+:} false; then : 46370 $as_echo_n "(cached) " >&6 46371 else 46372 if ac_fn_cxx_compute_int "$LINENO" "(long int) (sizeof (int *))" "ac_cv_sizeof_int_p" "$ac_includes_default"; then : 46373 46374 else 46375 if test "$ac_cv_type_int_p" = yes; then 46376 { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5 46377 $as_echo "$as_me: error: in \`$ac_pwd':" >&2;} 46378 as_fn_error 77 "cannot compute sizeof (int *) 46379 See \`config.log' for more details" "$LINENO" 5; } 46380 else 46381 ac_cv_sizeof_int_p=0 46382 fi 46383 fi 46384 46385 fi 46386 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_sizeof_int_p" >&5 46387 $as_echo "$ac_cv_sizeof_int_p" >&6; } 46388 46389 46390 46391 cat >>confdefs.h <<_ACEOF 46392 #define SIZEOF_INT_P $ac_cv_sizeof_int_p 46393 _ACEOF 46394 46395 46396 46397 TESTED_TARGET_CPU_BITS=`expr 8 \* $ac_cv_sizeof_int_p` 46398 46399 if test "x$TESTED_TARGET_CPU_BITS" != "x$OPENJDK_TARGET_CPU_BITS"; then 46400 { $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 46401 $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;} 46402 if test "x$COMPILE_TYPE" = xreduced; then 46403 46404 # Print a helpful message on how to acquire the necessary build dependency. 46405 # reduced is the help tag: freetype, cups, alsa etc 46406 MISSING_DEPENDENCY=reduced 46407 46408 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 46409 cygwin_help $MISSING_DEPENDENCY 46410 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 46411 msys_help $MISSING_DEPENDENCY 46412 else 46413 PKGHANDLER_COMMAND= 46414 46415 case $PKGHANDLER in 46416 apt-get) 46417 apt_help $MISSING_DEPENDENCY ;; 46418 yum) 46419 yum_help $MISSING_DEPENDENCY ;; 46420 port) 46421 port_help $MISSING_DEPENDENCY ;; 46422 pkgutil) 46423 pkgutil_help $MISSING_DEPENDENCY ;; 46424 pkgadd) 46425 pkgadd_help $MISSING_DEPENDENCY ;; 46426 esac 46427 46428 if test "x$PKGHANDLER_COMMAND" != x; then 46429 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 46430 fi 46431 fi 46432 46433 { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a reduced build. Check that you have 32-bit libraries installed. $HELP_MSG" >&5 46434 $as_echo "$as_me: You are doing a reduced build. Check that you have 32-bit libraries installed. $HELP_MSG" >&6;} 46435 elif test "x$COMPILE_TYPE" = xcross; then 46436 { $as_echo "$as_me:${as_lineno-$LINENO}: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&5 46437 $as_echo "$as_me: You are doing a cross-compilation. Check that you have all target platform libraries installed." >&6;} 46438 fi 46439 as_fn_error $? "Cannot continue." "$LINENO" 5 46440 fi 46441 fi 46442 fi 46443 46444 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for target address size" >&5 46445 $as_echo_n "checking for target address size... " >&6; } 46446 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OPENJDK_TARGET_CPU_BITS bits" >&5 46447 $as_echo "$OPENJDK_TARGET_CPU_BITS bits" >&6; } 46448 46449 46450 ############################################################################### 46451 # 46452 # Is the target little of big endian? 46453 # 46454 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether byte ordering is bigendian" >&5 46455 $as_echo_n "checking whether byte ordering is bigendian... " >&6; } 46456 if ${ac_cv_c_bigendian+:} false; then : 46457 $as_echo_n "(cached) " >&6 46458 else 46459 ac_cv_c_bigendian=unknown 46460 # See if we're dealing with a universal compiler. 46461 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 46462 /* end confdefs.h. */ 46463 #ifndef __APPLE_CC__ 46464 not a universal capable compiler 46465 #endif 46466 typedef int dummy; 46467 46468 _ACEOF 46469 if ac_fn_cxx_try_compile "$LINENO"; then : 46470 46471 # Check for potential -arch flags. It is not universal unless 46472 # there are at least two -arch flags with different values. 46473 ac_arch= 46474 ac_prev= 46475 for ac_word in $CC $CFLAGS $CPPFLAGS $LDFLAGS; do 46476 if test -n "$ac_prev"; then 46477 case $ac_word in 46478 i?86 | x86_64 | ppc | ppc64) 46479 if test -z "$ac_arch" || test "$ac_arch" = "$ac_word"; then 46480 ac_arch=$ac_word 46481 else 46482 ac_cv_c_bigendian=universal 46483 break 46484 fi 46485 ;; 46486 esac 46487 ac_prev= 46488 elif test "x$ac_word" = "x-arch"; then 46489 ac_prev=arch 46490 fi 46491 done 46492 fi 46493 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 46494 if test $ac_cv_c_bigendian = unknown; then 46495 # See if sys/param.h defines the BYTE_ORDER macro. 46496 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 46497 /* end confdefs.h. */ 46498 #include <sys/types.h> 46499 #include <sys/param.h> 46500 46501 int 46502 main () 46503 { 46504 #if ! (defined BYTE_ORDER && defined BIG_ENDIAN \ 46505 && defined LITTLE_ENDIAN && BYTE_ORDER && BIG_ENDIAN \ 46506 && LITTLE_ENDIAN) 46507 bogus endian macros 46508 #endif 46509 46510 ; 46511 return 0; 46512 } 46513 _ACEOF 46514 if ac_fn_cxx_try_compile "$LINENO"; then : 46515 # It does; now see whether it defined to BIG_ENDIAN or not. 46516 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 46517 /* end confdefs.h. */ 46518 #include <sys/types.h> 46519 #include <sys/param.h> 46520 46521 int 46522 main () 46523 { 46524 #if BYTE_ORDER != BIG_ENDIAN 46525 not big endian 46526 #endif 46527 46528 ; 46529 return 0; 46530 } 46531 _ACEOF 46532 if ac_fn_cxx_try_compile "$LINENO"; then : 46533 ac_cv_c_bigendian=yes 46534 else 46535 ac_cv_c_bigendian=no 46536 fi 46537 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 46538 fi 46539 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 46540 fi 46541 if test $ac_cv_c_bigendian = unknown; then 46542 # See if <limits.h> defines _LITTLE_ENDIAN or _BIG_ENDIAN (e.g., Solaris). 46543 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 46544 /* end confdefs.h. */ 46545 #include <limits.h> 46546 46547 int 46548 main () 46549 { 46550 #if ! (defined _LITTLE_ENDIAN || defined _BIG_ENDIAN) 46551 bogus endian macros 46552 #endif 46553 46554 ; 46555 return 0; 46556 } 46557 _ACEOF 46558 if ac_fn_cxx_try_compile "$LINENO"; then : 46559 # It does; now see whether it defined to _BIG_ENDIAN or not. 46560 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 46561 /* end confdefs.h. */ 46562 #include <limits.h> 46563 46564 int 46565 main () 46566 { 46567 #ifndef _BIG_ENDIAN 46568 not big endian 46569 #endif 46570 46571 ; 46572 return 0; 46573 } 46574 _ACEOF 46575 if ac_fn_cxx_try_compile "$LINENO"; then : 46576 ac_cv_c_bigendian=yes 46577 else 46578 ac_cv_c_bigendian=no 46579 fi 46580 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 46581 fi 46582 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 46583 fi 46584 if test $ac_cv_c_bigendian = unknown; then 46585 # Compile a test program. 46586 if test "$cross_compiling" = yes; then : 46587 # Try to guess by grepping values from an object file. 46588 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 46589 /* end confdefs.h. */ 46590 short int ascii_mm[] = 46591 { 0x4249, 0x4765, 0x6E44, 0x6961, 0x6E53, 0x7953, 0 }; 46592 short int ascii_ii[] = 46593 { 0x694C, 0x5454, 0x656C, 0x6E45, 0x6944, 0x6E61, 0 }; 46594 int use_ascii (int i) { 46595 return ascii_mm[i] + ascii_ii[i]; 46596 } 46597 short int ebcdic_ii[] = 46598 { 0x89D3, 0xE3E3, 0x8593, 0x95C5, 0x89C4, 0x9581, 0 }; 46599 short int ebcdic_mm[] = 46600 { 0xC2C9, 0xC785, 0x95C4, 0x8981, 0x95E2, 0xA8E2, 0 }; 46601 int use_ebcdic (int i) { 46602 return ebcdic_mm[i] + ebcdic_ii[i]; 46603 } 46604 extern int foo; 46605 46606 int 46607 main () 46608 { 46609 return use_ascii (foo) == use_ebcdic (foo); 46610 ; 46611 return 0; 46612 } 46613 _ACEOF 46614 if ac_fn_cxx_try_compile "$LINENO"; then : 46615 if grep BIGenDianSyS conftest.$ac_objext >/dev/null; then 46616 ac_cv_c_bigendian=yes 46617 fi 46618 if grep LiTTleEnDian conftest.$ac_objext >/dev/null ; then 46619 if test "$ac_cv_c_bigendian" = unknown; then 46620 ac_cv_c_bigendian=no 46621 else 46622 # finding both strings is unlikely to happen, but who knows? 46623 ac_cv_c_bigendian=unknown 46624 fi 46625 fi 46626 fi 46627 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 46628 else 46629 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 46630 /* end confdefs.h. */ 46631 $ac_includes_default 46632 int 46633 main () 46634 { 46635 46636 /* Are we little or big endian? From Harbison&Steele. */ 46637 union 46638 { 46639 long int l; 46640 char c[sizeof (long int)]; 46641 } u; 46642 u.l = 1; 46643 return u.c[sizeof (long int) - 1] == 1; 46644 46645 ; 46646 return 0; 46647 } 46648 _ACEOF 46649 if ac_fn_cxx_try_run "$LINENO"; then : 46650 ac_cv_c_bigendian=no 46651 else 46652 ac_cv_c_bigendian=yes 46653 fi 46654 rm -f core *.core core.conftest.* gmon.out bb.out conftest$ac_exeext \ 46655 conftest.$ac_objext conftest.beam conftest.$ac_ext 46656 fi 46657 46658 fi 46659 fi 46660 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_c_bigendian" >&5 46661 $as_echo "$ac_cv_c_bigendian" >&6; } 46662 case $ac_cv_c_bigendian in #( 46663 yes) 46664 ENDIAN="big";; #( 46665 no) 46666 ENDIAN="little" ;; #( 46667 universal) 46668 ENDIAN="universal_endianness" 46669 ;; #( 46670 *) 46671 ENDIAN="unknown" ;; 46672 esac 46673 46674 46675 if test "x$ENDIAN" = xuniversal_endianness; then 46676 as_fn_error $? "Building with both big and little endianness is not supported" "$LINENO" 5 46677 fi 46678 if test "x$ENDIAN" != "x$OPENJDK_TARGET_CPU_ENDIAN"; then 46679 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 46680 fi 46681 46682 46683 # Configure flags for the tools 46684 46685 ############################################################################### 46686 # 46687 # How to compile shared libraries. 46688 # 46689 46690 if test "x$TOOLCHAIN_TYPE" = xgcc; then 46691 PICFLAG="-fPIC" 46692 C_FLAG_REORDER='' 46693 CXX_FLAG_REORDER='' 46694 46695 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 46696 # Linking is different on MacOSX 46697 if test "x$STATIC_BUILD" = xtrue; then 46698 SHARED_LIBRARY_FLAGS ='-undefined dynamic_lookup' 46699 else 46700 SHARED_LIBRARY_FLAGS="-dynamiclib -compatibility_version 1.0.0 -current_version 1.0.0 $PICFLAG" 46701 fi 46702 SET_EXECUTABLE_ORIGIN='-Wl,-rpath,@loader_path/.' 46703 SET_SHARED_LIBRARY_ORIGIN="$SET_EXECUTABLE_ORIGIN" 46704 SET_SHARED_LIBRARY_NAME='-Wl,-install_name,@rpath/$1' 46705 SET_SHARED_LIBRARY_MAPFILE='' 46706 else 46707 # Default works for linux, might work on other platforms as well. 46708 SHARED_LIBRARY_FLAGS='-shared' 46709 SET_EXECUTABLE_ORIGIN='-Wl,-rpath,\$$$$ORIGIN$1' 46710 SET_SHARED_LIBRARY_ORIGIN="-Wl,-z,origin $SET_EXECUTABLE_ORIGIN" 46711 SET_SHARED_LIBRARY_NAME='-Wl,-soname=$1' 46712 SET_SHARED_LIBRARY_MAPFILE='-Wl,-version-script=$1' 46713 fi 46714 elif test "x$TOOLCHAIN_TYPE" = xclang; then 46715 C_FLAG_REORDER='' 46716 CXX_FLAG_REORDER='' 46717 46718 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 46719 # Linking is different on MacOSX 46720 PICFLAG='' 46721 SHARED_LIBRARY_FLAGS="-dynamiclib -compatibility_version 1.0.0 -current_version 1.0.0 $PICFLAG" 46722 SET_EXECUTABLE_ORIGIN='-Wl,-rpath,@loader_path/.' 46723 SET_SHARED_LIBRARY_ORIGIN="$SET_EXECUTABLE_ORIGIN" 46724 SET_SHARED_LIBRARY_NAME='-Wl,-install_name,@rpath/$1' 46725 SET_SHARED_LIBRARY_MAPFILE='' 46726 else 46727 # Default works for linux, might work on other platforms as well. 46728 PICFLAG='-fPIC' 46729 SHARED_LIBRARY_FLAGS='-shared' 46730 SET_EXECUTABLE_ORIGIN='-Wl,-rpath,\$$$$ORIGIN$1' 46731 SET_SHARED_LIBRARY_ORIGIN="-Wl,-z,origin $SET_EXECUTABLE_ORIGIN" 46732 SET_SHARED_LIBRARY_NAME='-Wl,-soname=$1' 46733 SET_SHARED_LIBRARY_MAPFILE='-Wl,-version-script=$1' 46734 fi 46735 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 46736 PICFLAG="-KPIC" 46737 C_FLAG_REORDER='-xF' 46738 CXX_FLAG_REORDER='-xF' 46739 SHARED_LIBRARY_FLAGS="-G" 46740 SET_EXECUTABLE_ORIGIN='-R\$$$$ORIGIN$1' 46741 SET_SHARED_LIBRARY_ORIGIN="$SET_EXECUTABLE_ORIGIN" 46742 SET_SHARED_LIBRARY_NAME='-h $1' 46743 SET_SHARED_LIBRARY_MAPFILE='-M$1' 46744 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 46745 PICFLAG="-qpic=large" 46746 C_FLAG_REORDER='' 46747 CXX_FLAG_REORDER='' 46748 SHARED_LIBRARY_FLAGS="-qmkshrobj" 46749 SET_EXECUTABLE_ORIGIN="" 46750 SET_SHARED_LIBRARY_ORIGIN='' 46751 SET_SHARED_LIBRARY_NAME='' 46752 SET_SHARED_LIBRARY_MAPFILE='' 46753 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 46754 PICFLAG="" 46755 C_FLAG_REORDER='' 46756 CXX_FLAG_REORDER='' 46757 SHARED_LIBRARY_FLAGS="-dll" 46758 SET_EXECUTABLE_ORIGIN='' 46759 SET_SHARED_LIBRARY_ORIGIN='' 46760 SET_SHARED_LIBRARY_NAME='' 46761 SET_SHARED_LIBRARY_MAPFILE='' 46762 fi 46763 46764 46765 46766 46767 46768 46769 46770 46771 46772 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 46773 CFLAGS_JDK="${CFLAGS_JDK} -D__solaris__" 46774 CXXFLAGS_JDK="${CXXFLAGS_JDK} -D__solaris__" 46775 CFLAGS_JDKLIB_EXTRA='-xstrconst' 46776 fi 46777 # The (cross) compiler is now configured, we can now test capabilities 46778 # of the target platform. 46779 46780 46781 46782 ############################################################################### 46783 # 46784 # Setup the opt flags for different compilers 46785 # and different operating systems. 46786 # 46787 46788 # FIXME: this was indirectly the old default, but just inherited. 46789 # if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 46790 # C_FLAG_DEPS="-MMD -MF" 46791 # fi 46792 46793 # Generate make dependency files 46794 if test "x$TOOLCHAIN_TYPE" = xgcc; then 46795 C_FLAG_DEPS="-MMD -MF" 46796 elif test "x$TOOLCHAIN_TYPE" = xclang; then 46797 C_FLAG_DEPS="-MMD -MF" 46798 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 46799 C_FLAG_DEPS="-xMMD -xMF" 46800 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 46801 C_FLAG_DEPS="-qmakedep=gcc -MF" 46802 fi 46803 CXX_FLAG_DEPS="$C_FLAG_DEPS" 46804 46805 46806 46807 # Debug symbols 46808 if test "x$TOOLCHAIN_TYPE" = xgcc; then 46809 if test "x$OPENJDK_TARGET_CPU_BITS" = "x64" && test "x$DEBUG_LEVEL" = "xfastdebug"; then 46810 # reduce from default "-g2" option to save space 46811 CFLAGS_DEBUG_SYMBOLS="-g1" 46812 CXXFLAGS_DEBUG_SYMBOLS="-g1" 46813 else 46814 CFLAGS_DEBUG_SYMBOLS="-g" 46815 CXXFLAGS_DEBUG_SYMBOLS="-g" 46816 fi 46817 elif test "x$TOOLCHAIN_TYPE" = xclang; then 46818 CFLAGS_DEBUG_SYMBOLS="-g" 46819 CXXFLAGS_DEBUG_SYMBOLS="-g" 46820 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 46821 CFLAGS_DEBUG_SYMBOLS="-g -xs" 46822 # FIXME: likely a bug, this disables debug symbols rather than enables them 46823 CXXFLAGS_DEBUG_SYMBOLS="-g0 -xs" 46824 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 46825 CFLAGS_DEBUG_SYMBOLS="-g" 46826 CXXFLAGS_DEBUG_SYMBOLS="-g" 46827 fi 46828 46829 46830 46831 # bounds, memory and behavior checking options 46832 if test "x$TOOLCHAIN_TYPE" = xgcc; then 46833 case $DEBUG_LEVEL in 46834 release ) 46835 # no adjustment 46836 ;; 46837 fastdebug ) 46838 # no adjustment 46839 ;; 46840 slowdebug ) 46841 # Add runtime stack smashing and undefined behavior checks. 46842 # Not all versions of gcc support -fstack-protector 46843 STACK_PROTECTOR_CFLAG="-fstack-protector-all" 46844 46845 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler supports \"$STACK_PROTECTOR_CFLAG\"" >&5 46846 $as_echo_n "checking if compiler supports \"$STACK_PROTECTOR_CFLAG\"... " >&6; } 46847 supports=yes 46848 46849 saved_cflags="$CFLAGS" 46850 CFLAGS="$CFLAGS $STACK_PROTECTOR_CFLAG" 46851 ac_ext=c 46852 ac_cpp='$CPP $CPPFLAGS' 46853 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 46854 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 46855 ac_compiler_gnu=$ac_cv_c_compiler_gnu 46856 46857 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 46858 /* end confdefs.h. */ 46859 int i; 46860 _ACEOF 46861 if ac_fn_c_try_compile "$LINENO"; then : 46862 46863 else 46864 supports=no 46865 fi 46866 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 46867 ac_ext=cpp 46868 ac_cpp='$CXXCPP $CPPFLAGS' 46869 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 46870 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 46871 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 46872 46873 CFLAGS="$saved_cflags" 46874 46875 saved_cxxflags="$CXXFLAGS" 46876 CXXFLAGS="$CXXFLAG $STACK_PROTECTOR_CFLAG" 46877 ac_ext=cpp 46878 ac_cpp='$CXXCPP $CPPFLAGS' 46879 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 46880 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 46881 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 46882 46883 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 46884 /* end confdefs.h. */ 46885 int i; 46886 _ACEOF 46887 if ac_fn_cxx_try_compile "$LINENO"; then : 46888 46889 else 46890 supports=no 46891 fi 46892 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 46893 ac_ext=cpp 46894 ac_cpp='$CXXCPP $CPPFLAGS' 46895 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 46896 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 46897 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 46898 46899 CXXFLAGS="$saved_cxxflags" 46900 46901 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 46902 $as_echo "$supports" >&6; } 46903 if test "x$supports" = "xyes" ; then 46904 : 46905 else 46906 STACK_PROTECTOR_CFLAG="" 46907 fi 46908 46909 46910 CFLAGS_DEBUG_OPTIONS="$STACK_PROTECTOR_CFLAG --param ssp-buffer-size=1" 46911 CXXFLAGS_DEBUG_OPTIONS="$STACK_PROTECTOR_CFLAG --param ssp-buffer-size=1" 46912 ;; 46913 esac 46914 fi 46915 46916 # Optimization levels 46917 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 46918 CC_HIGHEST="$CC_HIGHEST -fns -fsimple -fsingle -xbuiltin=%all -xdepend -xrestrict -xlibmil" 46919 46920 if test "x$OPENJDK_TARGET_CPU_ARCH" = "xx86"; then 46921 # FIXME: seems we always set -xregs=no%frameptr; put it elsewhere more global? 46922 C_O_FLAG_HIGHEST="-xO4 -Wu,-O4~yz $CC_HIGHEST -xalias_level=basic -xregs=no%frameptr" 46923 C_O_FLAG_HI="-xO4 -Wu,-O4~yz -xregs=no%frameptr" 46924 C_O_FLAG_NORM="-xO2 -Wu,-O2~yz -xregs=no%frameptr" 46925 C_O_FLAG_DEBUG="-xregs=no%frameptr" 46926 C_O_FLAG_NONE="-xregs=no%frameptr" 46927 CXX_O_FLAG_HIGHEST="-xO4 -Qoption ube -O4~yz $CC_HIGHEST -xregs=no%frameptr" 46928 CXX_O_FLAG_HI="-xO4 -Qoption ube -O4~yz -xregs=no%frameptr" 46929 CXX_O_FLAG_NORM="-xO2 -Qoption ube -O2~yz -xregs=no%frameptr" 46930 CXX_O_FLAG_DEBUG="-xregs=no%frameptr" 46931 CXX_O_FLAG_NONE="-xregs=no%frameptr" 46932 if test "x$OPENJDK_TARGET_CPU_BITS" = "x32"; then 46933 C_O_FLAG_HIGHEST="$C_O_FLAG_HIGHEST -xchip=pentium" 46934 CXX_O_FLAG_HIGHEST="$CXX_O_FLAG_HIGHEST -xchip=pentium" 46935 fi 46936 elif test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then 46937 C_O_FLAG_HIGHEST="-xO4 -Wc,-Qrm-s -Wc,-Qiselect-T0 $CC_HIGHEST -xalias_level=basic -xprefetch=auto,explicit -xchip=ultra" 46938 C_O_FLAG_HI="-xO4 -Wc,-Qrm-s -Wc,-Qiselect-T0" 46939 C_O_FLAG_NORM="-xO2 -Wc,-Qrm-s -Wc,-Qiselect-T0" 46940 C_O_FLAG_DEBUG="" 46941 C_O_FLAG_NONE="" 46942 CXX_O_FLAG_HIGHEST="-xO4 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0 $CC_HIGHEST -xprefetch=auto,explicit -xchip=ultra" 46943 CXX_O_FLAG_HI="-xO4 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0" 46944 CXX_O_FLAG_NORM="-xO2 -Qoption cg -Qrm-s -Qoption cg -Qiselect-T0" 46945 C_O_FLAG_DEBUG="" 46946 CXX_O_FLAG_NONE="" 46947 fi 46948 else 46949 # The remaining toolchains share opt flags between CC and CXX; 46950 # setup for C and duplicate afterwards. 46951 if test "x$TOOLCHAIN_TYPE" = xgcc; then 46952 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 46953 # On MacOSX we optimize for size, something 46954 # we should do for all platforms? 46955 C_O_FLAG_HIGHEST="-Os" 46956 C_O_FLAG_HI="-Os" 46957 C_O_FLAG_NORM="-Os" 46958 else 46959 C_O_FLAG_HIGHEST="-O3" 46960 C_O_FLAG_HI="-O3" 46961 C_O_FLAG_NORM="-O2" 46962 fi 46963 C_O_FLAG_DEBUG="-O0" 46964 C_O_FLAG_NONE="-O0" 46965 elif test "x$TOOLCHAIN_TYPE" = xclang; then 46966 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 46967 # On MacOSX we optimize for size, something 46968 # we should do for all platforms? 46969 C_O_FLAG_HIGHEST="-Os" 46970 C_O_FLAG_HI="-Os" 46971 C_O_FLAG_NORM="-Os" 46972 else 46973 C_O_FLAG_HIGHEST="-O3" 46974 C_O_FLAG_HI="-O3" 46975 C_O_FLAG_NORM="-O2" 46976 fi 46977 C_O_FLAG_DEBUG="-O0" 46978 C_O_FLAG_NONE="-O0" 46979 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 46980 C_O_FLAG_HIGHEST="-O3" 46981 C_O_FLAG_HI="-O3 -qstrict" 46982 C_O_FLAG_NORM="-O2" 46983 C_O_FLAG_DEBUG="-qnoopt" 46984 C_O_FLAG_NONE="-qnoop" 46985 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 46986 C_O_FLAG_HIGHEST="-O2" 46987 C_O_FLAG_HI="-O1" 46988 C_O_FLAG_NORM="-O1" 46989 C_O_FLAG_DEBUG="-Od" 46990 C_O_FLAG_NONE="-Od" 46991 fi 46992 CXX_O_FLAG_HIGHEST="$C_O_FLAG_HIGHEST" 46993 CXX_O_FLAG_HI="$C_O_FLAG_HI" 46994 CXX_O_FLAG_NORM="$C_O_FLAG_NORM" 46995 CXX_O_FLAG_DEBUG="$C_O_FLAG_DEBUG" 46996 CXX_O_FLAG_NONE="$C_O_FLAG_NONE" 46997 fi 46998 46999 # Adjust optimization flags according to debug level. 47000 case $DEBUG_LEVEL in 47001 release ) 47002 # no adjustment 47003 ;; 47004 fastdebug ) 47005 # Not quite so much optimization 47006 C_O_FLAG_HI="$C_O_FLAG_NORM" 47007 CXX_O_FLAG_HI="$CXX_O_FLAG_NORM" 47008 ;; 47009 slowdebug ) 47010 # Disable optimization 47011 C_O_FLAG_HIGHEST="$C_O_FLAG_DEBUG" 47012 C_O_FLAG_HI="$C_O_FLAG_DEBUG" 47013 C_O_FLAG_NORM="$C_O_FLAG_DEBUG" 47014 CXX_O_FLAG_HIGHEST="$CXX_O_FLAG_DEBUG" 47015 CXX_O_FLAG_HI="$CXX_O_FLAG_DEBUG" 47016 CXX_O_FLAG_NORM="$CXX_O_FLAG_DEBUG" 47017 ;; 47018 esac 47019 47020 47021 47022 47023 47024 47025 47026 47027 47028 47029 47030 47031 47032 # Special extras... 47033 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 47034 if test "x$OPENJDK_TARGET_CPU_ARCH" = "xsparc"; then 47035 CFLAGS_JDKLIB_EXTRA="${CFLAGS_JDKLIB_EXTRA} -xregs=no%appl" 47036 CXXFLAGS_JDKLIB_EXTRA="${CXXFLAGS_JDKLIB_EXTRA} -xregs=no%appl" 47037 fi 47038 CFLAGS_JDKLIB_EXTRA="${CFLAGS_JDKLIB_EXTRA} -errtags=yes -errfmt" 47039 CXXFLAGS_JDKLIB_EXTRA="${CXXFLAGS_JDKLIB_EXTRA} -errtags=yes -errfmt" 47040 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 47041 CFLAGS_JDK="${CFLAGS_JDK} -qchars=signed -qfullpath -qsaveopt" 47042 CXXFLAGS_JDK="${CXXFLAGS_JDK} -qchars=signed -qfullpath -qsaveopt" 47043 fi 47044 47045 CFLAGS_JDK="${CFLAGS_JDK} $EXTRA_CFLAGS" 47046 CXXFLAGS_JDK="${CXXFLAGS_JDK} $EXTRA_CXXFLAGS" 47047 LDFLAGS_JDK="${LDFLAGS_JDK} $EXTRA_LDFLAGS" 47048 47049 ############################################################################### 47050 # 47051 # Now setup the CFLAGS and LDFLAGS for the JDK build. 47052 # Later we will also have CFLAGS and LDFLAGS for the hotspot subrepo build. 47053 # 47054 47055 # Setup compiler/platform specific flags into 47056 # CFLAGS_JDK - C Compiler flags 47057 # CXXFLAGS_JDK - C++ Compiler flags 47058 # COMMON_CCXXFLAGS_JDK - common to C and C++ 47059 if test "x$TOOLCHAIN_TYPE" = xgcc; then 47060 if test "x$OPENJDK_TARGET_CPU" = xx86; then 47061 # Force compatibility with i586 on 32 bit intel platforms. 47062 COMMON_CCXXFLAGS="${COMMON_CCXXFLAGS} -march=i586" 47063 fi 47064 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS $COMMON_CCXXFLAGS_JDK -Wall -Wextra -Wno-unused -Wno-unused-parameter -Wformat=2 \ 47065 -pipe -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE" 47066 case $OPENJDK_TARGET_CPU_ARCH in 47067 arm ) 47068 # on arm we don't prevent gcc to omit frame pointer but do prevent strict aliasing 47069 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 47070 ;; 47071 ppc ) 47072 # on ppc we don't prevent gcc to omit frame pointer but do prevent strict aliasing 47073 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 47074 ;; 47075 * ) 47076 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer" 47077 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 47078 ;; 47079 esac 47080 elif test "x$TOOLCHAIN_TYPE" = xclang; then 47081 if test "x$OPENJDK_TARGET_OS" = xlinux; then 47082 if test "x$OPENJDK_TARGET_CPU" = xx86; then 47083 # Force compatibility with i586 on 32 bit intel platforms. 47084 COMMON_CCXXFLAGS="${COMMON_CCXXFLAGS} -march=i586" 47085 fi 47086 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS $COMMON_CCXXFLAGS_JDK -Wall -Wextra -Wno-unused -Wno-unused-parameter -Wformat=2 \ 47087 -pipe -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE" 47088 case $OPENJDK_TARGET_CPU_ARCH in 47089 ppc ) 47090 # on ppc we don't prevent gcc to omit frame pointer but do prevent strict aliasing 47091 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 47092 ;; 47093 * ) 47094 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -fno-omit-frame-pointer" 47095 CFLAGS_JDK="${CFLAGS_JDK} -fno-strict-aliasing" 47096 ;; 47097 esac 47098 fi 47099 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 47100 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS $COMMON_CCXXFLAGS_JDK -DTRACING -DMACRO_MEMSYS_OPS -DBREAKPTS" 47101 if test "x$OPENJDK_TARGET_CPU_ARCH" = xx86; then 47102 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DcpuIntel -Di586 -D$OPENJDK_TARGET_CPU_LEGACY_LIB" 47103 fi 47104 47105 CFLAGS_JDK="$CFLAGS_JDK -xc99=%none -xCC -errshort=tags -Xa -v -mt -W0,-noglobal" 47106 CXXFLAGS_JDK="$CXXFLAGS_JDK -errtags=yes +w -mt -features=no%except -DCC_NOEX -norunpath -xnolib" 47107 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 47108 CFLAGS_JDK="$CFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC" 47109 CXXFLAGS_JDK="$CXXFLAGS_JDK -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE -DSTDC" 47110 elif test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 47111 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS $COMMON_CCXXFLAGS_JDK \ 47112 -Zi -MD -Zc:wchar_t- -W3 -wd4800 \ 47113 -DWIN32_LEAN_AND_MEAN \ 47114 -D_CRT_SECURE_NO_DEPRECATE -D_CRT_NONSTDC_NO_DEPRECATE \ 47115 -D_WINSOCK_DEPRECATED_NO_WARNINGS \ 47116 -DWIN32 -DIAL" 47117 if test "x$OPENJDK_TARGET_CPU" = xx86_64; then 47118 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_AMD64_ -Damd64" 47119 else 47120 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_X86_ -Dx86" 47121 fi 47122 # If building with Visual Studio 2010, we can still use _STATIC_CPPLIB to 47123 # avoid bundling msvcpNNN.dll. Doesn't work with newer versions of visual 47124 # studio. 47125 if test "x$TOOLCHAIN_VERSION" = "x2010"; then 47126 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK \ 47127 -D_STATIC_CPPLIB -D_DISABLE_DEPRECATE_STATIC_CPPLIB" 47128 fi 47129 fi 47130 47131 ############################################################################### 47132 47133 # Adjust flags according to debug level. 47134 case $DEBUG_LEVEL in 47135 fastdebug | slowdebug ) 47136 CFLAGS_JDK="$CFLAGS_JDK $CFLAGS_DEBUG_SYMBOLS $CFLAGS_DEBUG_OPTIONS" 47137 CXXFLAGS_JDK="$CXXFLAGS_JDK $CXXFLAGS_DEBUG_SYMBOLS $CXXFLAGS_DEBUG_OPTIONS" 47138 JAVAC_FLAGS="$JAVAC_FLAGS -g" 47139 ;; 47140 release ) 47141 ;; 47142 * ) 47143 as_fn_error $? "Unrecognized \$DEBUG_LEVEL: $DEBUG_LEVEL" "$LINENO" 5 47144 ;; 47145 esac 47146 47147 # Setup LP64 47148 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK $ADD_LP64" 47149 47150 # Set some common defines. These works for all compilers, but assume 47151 # -D is universally accepted. 47152 47153 # Setup endianness 47154 if test "x$OPENJDK_TARGET_CPU_ENDIAN" = xlittle; then 47155 # The macro _LITTLE_ENDIAN needs to be defined the same to avoid the 47156 # Sun C compiler warning message: warning: macro redefined: _LITTLE_ENDIAN 47157 # (The Solaris X86 system defines this in file /usr/include/sys/isa_defs.h). 47158 # Note: -Dmacro is the same as #define macro 1 47159 # -Dmacro= is the same as #define macro 47160 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 47161 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_LITTLE_ENDIAN=" 47162 else 47163 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_LITTLE_ENDIAN" 47164 fi 47165 else 47166 # Same goes for _BIG_ENDIAN. Do we really need to set *ENDIAN on Solaris if they 47167 # are defined in the system? 47168 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 47169 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_BIG_ENDIAN=" 47170 else 47171 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_BIG_ENDIAN" 47172 fi 47173 fi 47174 47175 # Setup target OS define. Use OS target name but in upper case. 47176 OPENJDK_TARGET_OS_UPPERCASE=`$ECHO $OPENJDK_TARGET_OS | $TR 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'` 47177 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D$OPENJDK_TARGET_OS_UPPERCASE" 47178 47179 # Setup target CPU 47180 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DARCH='\"$OPENJDK_TARGET_CPU_LEGACY\"' -D$OPENJDK_TARGET_CPU_LEGACY" 47181 47182 # Setup debug/release defines 47183 if test "x$DEBUG_LEVEL" = xrelease; then 47184 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DNDEBUG" 47185 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 47186 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DTRIMMED" 47187 fi 47188 else 47189 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DDEBUG" 47190 fi 47191 47192 # Set some additional per-OS defines. 47193 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 47194 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE -D_DARWIN_UNLIMITED_SELECT" 47195 elif test "x$OPENJDK_TARGET_OS" = xaix; then 47196 # FIXME: PPC64 should not be here. 47197 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DPPC64" 47198 elif test "x$OPENJDK_TARGET_OS" = xbsd; then 47199 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -D_ALLBSD_SOURCE" 47200 fi 47201 47202 # Additional macosx handling 47203 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 47204 # Setting these parameters makes it an error to link to macosx APIs that are 47205 # newer than the given OS version and makes the linked binaries compatible 47206 # even if built on a newer version of the OS. 47207 # The expected format is X.Y.Z 47208 MACOSX_VERSION_MIN=10.7.0 47209 47210 47211 # The macro takes the version with no dots, ex: 1070 47212 # Let the flags variables get resolved in make for easier override on make 47213 # command line. 47214 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK -DMAC_OS_X_VERSION_MAX_ALLOWED=\$(subst .,,\$(MACOSX_VERSION_MIN)) -mmacosx-version-min=\$(MACOSX_VERSION_MIN)" 47215 LDFLAGS_JDK="$LDFLAGS_JDK -mmacosx-version-min=\$(MACOSX_VERSION_MIN)" 47216 fi 47217 47218 # Setup some hard coded includes 47219 COMMON_CCXXFLAGS_JDK="$COMMON_CCXXFLAGS_JDK \ 47220 -I${JDK_TOPDIR}/src/java.base/share/native/include \ 47221 -I${JDK_TOPDIR}/src/java.base/$OPENJDK_TARGET_OS/native/include \ 47222 -I${JDK_TOPDIR}/src/java.base/$OPENJDK_TARGET_OS_TYPE/native/include \ 47223 -I${JDK_TOPDIR}/src/java.base/share/native/libjava \ 47224 -I${JDK_TOPDIR}/src/java.base/$OPENJDK_TARGET_OS_TYPE/native/libjava" 47225 47226 # The shared libraries are compiled using the picflag. 47227 CFLAGS_JDKLIB="$COMMON_CCXXFLAGS_JDK $CFLAGS_JDK $PICFLAG $CFLAGS_JDKLIB_EXTRA" 47228 CXXFLAGS_JDKLIB="$COMMON_CCXXFLAGS_JDK $CXXFLAGS_JDK $PICFLAG $CXXFLAGS_JDKLIB_EXTRA" 47229 47230 # Executable flags 47231 CFLAGS_JDKEXE="$COMMON_CCXXFLAGS_JDK $CFLAGS_JDK" 47232 CXXFLAGS_JDKEXE="$COMMON_CCXXFLAGS_JDK $CXXFLAGS_JDK" 47233 47234 47235 47236 47237 47238 47239 # Flags for compiling test libraries 47240 CFLAGS_TESTLIB="$COMMON_CCXXFLAGS_JDK $CFLAGS_JDK $PICFLAG $CFLAGS_JDKLIB_EXTRA" 47241 CXXFLAGS_TESTLIB="$COMMON_CCXXFLAGS_JDK $CXXFLAGS_JDK $PICFLAG $CXXFLAGS_JDKLIB_EXTRA" 47242 47243 # Flags for compiling test executables 47244 CFLAGS_TESTEXE="$COMMON_CCXXFLAGS_JDK $CFLAGS_JDK" 47245 CXXFLAGS_TESTEXE="$COMMON_CCXXFLAGS_JDK $CXXFLAGS_JDK" 47246 47247 47248 47249 47250 47251 47252 # Setup LDFLAGS et al. 47253 # 47254 47255 # Now this is odd. The JDK native libraries have to link against libjvm.so 47256 # On 32-bit machines there is normally two distinct libjvm.so:s, client and server. 47257 # Which should we link to? Are we lucky enough that the binary api to the libjvm.so library 47258 # is identical for client and server? Yes. Which is picked at runtime (client or server)? 47259 # Neither, since the chosen libjvm.so has already been loaded by the launcher, all the following 47260 # libraries will link to whatever is in memory. Yuck. 47261 # 47262 # Thus we offer the compiler to find libjvm.so first in server then in client. It works. Ugh. 47263 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 47264 LDFLAGS_JDK="$LDFLAGS_JDK -nologo -opt:ref -incremental:no" 47265 if test "x$OPENJDK_TARGET_CPU_BITS" = "x32"; then 47266 LDFLAGS_JDK="$LDFLAGS_JDK -safeseh" 47267 fi 47268 # TODO: make -debug optional "--disable-full-debug-symbols" 47269 LDFLAGS_JDK="$LDFLAGS_JDK -debug" 47270 elif test "x$TOOLCHAIN_TYPE" = xgcc; then 47271 # If this is a --hash-style=gnu system, use --hash-style=both, why? 47272 # We have previously set HAS_GNU_HASH if this is the case 47273 if test -n "$HAS_GNU_HASH"; then 47274 LDFLAGS_JDK="${LDFLAGS_JDK} -Wl,--hash-style=both" 47275 fi 47276 if test "x$OPENJDK_TARGET_OS" = xlinux; then 47277 # And since we now know that the linker is gnu, then add -z defs, to forbid 47278 # undefined symbols in object files. 47279 LDFLAGS_JDK="${LDFLAGS_JDK} -Wl,-z,defs" 47280 case $DEBUG_LEVEL in 47281 release ) 47282 # tell linker to optimize libraries. 47283 # Should this be supplied to the OSS linker as well? 47284 LDFLAGS_JDK="${LDFLAGS_JDK} -Wl,-O1" 47285 ;; 47286 slowdebug ) 47287 if test "x$HAS_LINKER_NOW" = "xtrue"; then 47288 # do relocations at load 47289 LDFLAGS_JDK="$LDFLAGS_JDK $LINKER_NOW_FLAG" 47290 LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK $LINKER_NOW_FLAG" 47291 fi 47292 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 47293 # mark relocations read only 47294 LDFLAGS_JDK="$LDFLAGS_JDK $LINKER_RELRO_FLAG" 47295 LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK $LINKER_RELRO_FLAG" 47296 fi 47297 ;; 47298 fastdebug ) 47299 if test "x$HAS_LINKER_RELRO" = "xtrue"; then 47300 # mark relocations read only 47301 LDFLAGS_JDK="$LDFLAGS_JDK $LINKER_RELRO_FLAG" 47302 LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK $LINKER_RELRO_FLAG" 47303 fi 47304 ;; 47305 * ) 47306 as_fn_error $? "Unrecognized \$DEBUG_LEVEL: $DEBUG_LEVEL" "$LINENO" 5 47307 ;; 47308 esac 47309 fi 47310 elif test "x$TOOLCHAIN_TYPE" = xsolstudio; then 47311 LDFLAGS_JDK="$LDFLAGS_JDK -Wl,-z,defs -xildoff -ztext" 47312 LDFLAGS_CXX_JDK="$LDFLAGS_CXX_JDK -norunpath -xnolib" 47313 elif test "x$TOOLCHAIN_TYPE" = xxlc; then 47314 LDFLAGS_JDK="${LDFLAGS_JDK} -brtl -bnolibpath -bexpall -bernotok" 47315 fi 47316 47317 # Customize LDFLAGS for executables 47318 47319 LDFLAGS_JDKEXE="${LDFLAGS_JDK}" 47320 47321 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 47322 if test "x$OPENJDK_TARGET_CPU_BITS" = "x64"; then 47323 LDFLAGS_STACK_SIZE=1048576 47324 else 47325 LDFLAGS_STACK_SIZE=327680 47326 fi 47327 LDFLAGS_JDKEXE="${LDFLAGS_JDKEXE} /STACK:$LDFLAGS_STACK_SIZE" 47328 elif test "x$OPENJDK_TARGET_OS" = xlinux; then 47329 LDFLAGS_JDKEXE="$LDFLAGS_JDKEXE -Wl,--allow-shlib-undefined" 47330 fi 47331 47332 # Customize LDFLAGS for libs 47333 LDFLAGS_JDKLIB="${LDFLAGS_JDK}" 47334 47335 LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} ${SHARED_LIBRARY_FLAGS}" 47336 if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then 47337 LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} \ 47338 -libpath:${OUTPUT_ROOT}/support/modules_libs/java.base" 47339 JDKLIB_LIBS="" 47340 else 47341 LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} \ 47342 -L${OUTPUT_ROOT}/support/modules_libs/java.base${OPENJDK_TARGET_CPU_LIBDIR}" 47343 47344 # On some platforms (mac) the linker warns about non existing -L dirs. 47345 # Add server first if available. Linking aginst client does not always produce the same results. 47346 # Only add client dir if client is being built. Add minimal (note not minimal1) if only building minimal1. 47347 # Default to server for other variants. 47348 if test "x$JVM_VARIANT_SERVER" = xtrue; then 47349 LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} -L${OUTPUT_ROOT}/support/modules_libs/java.base${OPENJDK_TARGET_CPU_LIBDIR}/server" 47350 elif test "x$JVM_VARIANT_CLIENT" = xtrue; then 47351 LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} -L${OUTPUT_ROOT}/support/modules_libs/java.base${OPENJDK_TARGET_CPU_LIBDIR}/client" 47352 elif test "x$JVM_VARIANT_MINIMAL1" = xtrue; then 47353 LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} -L${OUTPUT_ROOT}/support/modules_libs/java.base${OPENJDK_TARGET_CPU_LIBDIR}/minimal" 47354 else 47355 LDFLAGS_JDKLIB="${LDFLAGS_JDKLIB} -L${OUTPUT_ROOT}/support/modules_libs/java.base${OPENJDK_TARGET_CPU_LIBDIR}/server" 47356 fi 47357 47358 JDKLIB_LIBS="-ljava -ljvm" 47359 if test "x$TOOLCHAIN_TYPE" = xsolstudio; then 47360 JDKLIB_LIBS="$JDKLIB_LIBS -lc" 47361 fi 47362 fi 47363 47364 47365 47366 47367 47368 47369 47370 LDFLAGS_TESTLIB="$LDFLAGS_JDKLIB" 47371 LDFLAGS_TESTEXE="$LDFLAGS_JDKEXE" 47372 47373 47374 47375 47376 47377 # Some Zero and Shark settings. 47378 # ZERO_ARCHFLAG tells the compiler which mode to build for 47379 case "${OPENJDK_TARGET_CPU}" in 47380 s390) 47381 ZERO_ARCHFLAG="${COMPILER_TARGET_BITS_FLAG}31" 47382 ;; 47383 *) 47384 ZERO_ARCHFLAG="${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 47385 esac 47386 47387 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler supports \"$ZERO_ARCHFLAG\"" >&5 47388 $as_echo_n "checking if compiler supports \"$ZERO_ARCHFLAG\"... " >&6; } 47389 supports=yes 47390 47391 saved_cflags="$CFLAGS" 47392 CFLAGS="$CFLAGS $ZERO_ARCHFLAG" 47393 ac_ext=c 47394 ac_cpp='$CPP $CPPFLAGS' 47395 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47396 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47397 ac_compiler_gnu=$ac_cv_c_compiler_gnu 47398 47399 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 47400 /* end confdefs.h. */ 47401 int i; 47402 _ACEOF 47403 if ac_fn_c_try_compile "$LINENO"; then : 47404 47405 else 47406 supports=no 47407 fi 47408 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 47409 ac_ext=cpp 47410 ac_cpp='$CXXCPP $CPPFLAGS' 47411 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47412 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47413 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 47414 47415 CFLAGS="$saved_cflags" 47416 47417 saved_cxxflags="$CXXFLAGS" 47418 CXXFLAGS="$CXXFLAG $ZERO_ARCHFLAG" 47419 ac_ext=cpp 47420 ac_cpp='$CXXCPP $CPPFLAGS' 47421 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47422 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47423 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 47424 47425 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 47426 /* end confdefs.h. */ 47427 int i; 47428 _ACEOF 47429 if ac_fn_cxx_try_compile "$LINENO"; then : 47430 47431 else 47432 supports=no 47433 fi 47434 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 47435 ac_ext=cpp 47436 ac_cpp='$CXXCPP $CPPFLAGS' 47437 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47438 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47439 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 47440 47441 CXXFLAGS="$saved_cxxflags" 47442 47443 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 47444 $as_echo "$supports" >&6; } 47445 if test "x$supports" = "xyes" ; then 47446 : 47447 else 47448 ZERO_ARCHFLAG="" 47449 fi 47450 47451 47452 47453 # Check that the compiler supports -mX (or -qX on AIX) flags 47454 # Set COMPILER_SUPPORTS_TARGET_BITS_FLAG to 'true' if it does 47455 47456 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"" >&5 47457 $as_echo_n "checking if compiler supports \"${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}\"... " >&6; } 47458 supports=yes 47459 47460 saved_cflags="$CFLAGS" 47461 CFLAGS="$CFLAGS ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 47462 ac_ext=c 47463 ac_cpp='$CPP $CPPFLAGS' 47464 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47465 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47466 ac_compiler_gnu=$ac_cv_c_compiler_gnu 47467 47468 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 47469 /* end confdefs.h. */ 47470 int i; 47471 _ACEOF 47472 if ac_fn_c_try_compile "$LINENO"; then : 47473 47474 else 47475 supports=no 47476 fi 47477 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 47478 ac_ext=cpp 47479 ac_cpp='$CXXCPP $CPPFLAGS' 47480 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47481 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47482 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 47483 47484 CFLAGS="$saved_cflags" 47485 47486 saved_cxxflags="$CXXFLAGS" 47487 CXXFLAGS="$CXXFLAG ${COMPILER_TARGET_BITS_FLAG}${OPENJDK_TARGET_CPU_BITS}" 47488 ac_ext=cpp 47489 ac_cpp='$CXXCPP $CPPFLAGS' 47490 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47491 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47492 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 47493 47494 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 47495 /* end confdefs.h. */ 47496 int i; 47497 _ACEOF 47498 if ac_fn_cxx_try_compile "$LINENO"; then : 47499 47500 else 47501 supports=no 47502 fi 47503 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 47504 ac_ext=cpp 47505 ac_cpp='$CXXCPP $CPPFLAGS' 47506 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47507 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47508 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 47509 47510 CXXFLAGS="$saved_cxxflags" 47511 47512 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 47513 $as_echo "$supports" >&6; } 47514 if test "x$supports" = "xyes" ; then 47515 COMPILER_SUPPORTS_TARGET_BITS_FLAG=true 47516 else 47517 COMPILER_SUPPORTS_TARGET_BITS_FLAG=false 47518 fi 47519 47520 47521 47522 # Check whether --enable-warnings-as-errors was given. 47523 if test "${enable_warnings_as_errors+set}" = set; then : 47524 enableval=$enable_warnings_as_errors; 47525 fi 47526 47527 47528 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if native warnings are errors" >&5 47529 $as_echo_n "checking if native warnings are errors... " >&6; } 47530 if test "x$enable_warnings_as_errors" = "xyes"; then 47531 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (explicitely set)" >&5 47532 $as_echo "yes (explicitely set)" >&6; } 47533 WARNINGS_AS_ERRORS=true 47534 elif test "x$enable_warnings_as_errors" = "xno"; then 47535 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 47536 $as_echo "no" >&6; } 47537 WARNINGS_AS_ERRORS=false 47538 elif test "x$enable_warnings_as_errors" = "x"; then 47539 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (default)" >&5 47540 $as_echo "yes (default)" >&6; } 47541 WARNINGS_AS_ERRORS=true 47542 else 47543 as_fn_error $? "--enable-warnings-as-errors accepts no argument" "$LINENO" 5 47544 fi 47545 47546 if test "x$WARNINGS_AS_ERRORS" = "xfalse"; then 47547 # Set legacy hotspot variable 47548 HOTSPOT_SET_WARNINGS_AS_ERRORS="WARNINGS_ARE_ERRORS=" 47549 else 47550 HOTSPOT_SET_WARNINGS_AS_ERRORS="" 47551 fi 47552 47553 47554 47555 47556 case "${TOOLCHAIN_TYPE}" in 47557 microsoft) 47558 DISABLE_WARNING_PREFIX="-wd" 47559 CFLAGS_WARNINGS_ARE_ERRORS="-WX" 47560 ;; 47561 solstudio) 47562 DISABLE_WARNING_PREFIX="-erroff=" 47563 CFLAGS_WARNINGS_ARE_ERRORS="-errtags -errwarn=%all" 47564 ;; 47565 gcc) 47566 # Prior to gcc 4.4, a -Wno-X where X is unknown for that version of gcc will cause an error 47567 47568 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 47569 $as_echo_n "checking if compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 47570 supports=yes 47571 47572 saved_cflags="$CFLAGS" 47573 CFLAGS="$CFLAGS -Wno-this-is-a-warning-that-do-not-exist" 47574 ac_ext=c 47575 ac_cpp='$CPP $CPPFLAGS' 47576 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47577 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47578 ac_compiler_gnu=$ac_cv_c_compiler_gnu 47579 47580 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 47581 /* end confdefs.h. */ 47582 int i; 47583 _ACEOF 47584 if ac_fn_c_try_compile "$LINENO"; then : 47585 47586 else 47587 supports=no 47588 fi 47589 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 47590 ac_ext=cpp 47591 ac_cpp='$CXXCPP $CPPFLAGS' 47592 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47593 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47594 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 47595 47596 CFLAGS="$saved_cflags" 47597 47598 saved_cxxflags="$CXXFLAGS" 47599 CXXFLAGS="$CXXFLAG -Wno-this-is-a-warning-that-do-not-exist" 47600 ac_ext=cpp 47601 ac_cpp='$CXXCPP $CPPFLAGS' 47602 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47603 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47604 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 47605 47606 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 47607 /* end confdefs.h. */ 47608 int i; 47609 _ACEOF 47610 if ac_fn_cxx_try_compile "$LINENO"; then : 47611 47612 else 47613 supports=no 47614 fi 47615 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 47616 ac_ext=cpp 47617 ac_cpp='$CXXCPP $CPPFLAGS' 47618 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47619 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47620 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 47621 47622 CXXFLAGS="$saved_cxxflags" 47623 47624 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 47625 $as_echo "$supports" >&6; } 47626 if test "x$supports" = "xyes" ; then 47627 GCC_CAN_DISABLE_WARNINGS=true 47628 else 47629 GCC_CAN_DISABLE_WARNINGS=false 47630 47631 fi 47632 47633 if test "x$GCC_CAN_DISABLE_WARNINGS" = "xtrue"; then 47634 DISABLE_WARNING_PREFIX="-Wno-" 47635 else 47636 DISABLE_WARNING_PREFIX= 47637 fi 47638 CFLAGS_WARNINGS_ARE_ERRORS="-Werror" 47639 # Repeate the check for the BUILD_CC 47640 CC_OLD="$CC" 47641 CC="$BUILD_CC" 47642 47643 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"" >&5 47644 $as_echo_n "checking if compiler supports \"-Wno-this-is-a-warning-that-do-not-exist\"... " >&6; } 47645 supports=yes 47646 47647 saved_cflags="$CFLAGS" 47648 CFLAGS="$CFLAGS -Wno-this-is-a-warning-that-do-not-exist" 47649 ac_ext=c 47650 ac_cpp='$CPP $CPPFLAGS' 47651 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47652 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47653 ac_compiler_gnu=$ac_cv_c_compiler_gnu 47654 47655 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 47656 /* end confdefs.h. */ 47657 int i; 47658 _ACEOF 47659 if ac_fn_c_try_compile "$LINENO"; then : 47660 47661 else 47662 supports=no 47663 fi 47664 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 47665 ac_ext=cpp 47666 ac_cpp='$CXXCPP $CPPFLAGS' 47667 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47668 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47669 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 47670 47671 CFLAGS="$saved_cflags" 47672 47673 saved_cxxflags="$CXXFLAGS" 47674 CXXFLAGS="$CXXFLAG -Wno-this-is-a-warning-that-do-not-exist" 47675 ac_ext=cpp 47676 ac_cpp='$CXXCPP $CPPFLAGS' 47677 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47678 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47679 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 47680 47681 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 47682 /* end confdefs.h. */ 47683 int i; 47684 _ACEOF 47685 if ac_fn_cxx_try_compile "$LINENO"; then : 47686 47687 else 47688 supports=no 47689 fi 47690 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 47691 ac_ext=cpp 47692 ac_cpp='$CXXCPP $CPPFLAGS' 47693 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 47694 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 47695 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 47696 47697 CXXFLAGS="$saved_cxxflags" 47698 47699 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $supports" >&5 47700 $as_echo "$supports" >&6; } 47701 if test "x$supports" = "xyes" ; then 47702 BUILD_CC_CAN_DISABLE_WARNINGS=true 47703 else 47704 BUILD_CC_CAN_DISABLE_WARNINGS=false 47705 47706 fi 47707 47708 if test "x$BUILD_CC_CAN_DISABLE_WARNINGS" = "xtrue"; then 47709 BUILD_CC_DISABLE_WARNING_PREFIX="-Wno-" 47710 else 47711 BUILD_CC_DISABLE_WARNING_PREFIX= 47712 fi 47713 CC="$CC_OLD" 47714 ;; 47715 clang) 47716 DISABLE_WARNING_PREFIX="-Wno-" 47717 CFLAGS_WARNINGS_ARE_ERRORS="-Werror" 47718 ;; 47719 esac 47720 47721 47722 47723 47724 # Setup debug symbols (need objcopy from the toolchain for that) 47725 47726 # 47727 # NATIVE_DEBUG_SYMBOLS 47728 # This must be done after the toolchain is setup, since we're looking at objcopy. 47729 # 47730 { $as_echo "$as_me:${as_lineno-$LINENO}: checking what type of native debug symbols to use" >&5 47731 $as_echo_n "checking what type of native debug symbols to use... " >&6; } 47732 47733 # Check whether --with-native-debug-symbols was given. 47734 if test "${with_native_debug_symbols+set}" = set; then : 47735 withval=$with_native_debug_symbols; 47736 if test "x$OPENJDK_TARGET_OS" = xaix; then 47737 if test "x$withval" = xexternal || test "x$withval" = xzipped; then 47738 as_fn_error $? "AIX only supports the parameters 'none' and 'internal' for --with-native-debug-symbols" "$LINENO" 5 47739 fi 47740 fi 47741 47742 else 47743 47744 if test "x$OPENJDK_TARGET_OS" = xaix; then 47745 # AIX doesn't support 'zipped' so use 'internal' as default 47746 with_native_debug_symbols="internal" 47747 else 47748 with_native_debug_symbols="zipped" 47749 fi 47750 47751 fi 47752 47753 NATIVE_DEBUG_SYMBOLS=$with_native_debug_symbols 47754 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NATIVE_DEBUG_SYMBOLS" >&5 47755 $as_echo "$NATIVE_DEBUG_SYMBOLS" >&6; } 47756 47757 if test "x$NATIVE_DEBUG_SYMBOLS" = xzipped; then 47758 47759 if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xlinux; then 47760 if test "x$OBJCOPY" = x; then 47761 # enabling of enable-debug-symbols and can't find objcopy 47762 # this is an error 47763 as_fn_error $? "Unable to find objcopy, cannot enable native debug symbols" "$LINENO" 5 47764 fi 47765 fi 47766 47767 ENABLE_DEBUG_SYMBOLS=true 47768 ZIP_DEBUGINFO_FILES=true 47769 DEBUG_BINARIES=true 47770 STRIP_POLICY=min_strip 47771 elif test "x$NATIVE_DEBUG_SYMBOLS" = xnone; then 47772 ENABLE_DEBUG_SYMBOLS=false 47773 ZIP_DEBUGINFO_FILES=false 47774 DEBUG_BINARIES=false 47775 STRIP_POLICY=no_strip 47776 elif test "x$NATIVE_DEBUG_SYMBOLS" = xinternal; then 47777 ENABLE_DEBUG_SYMBOLS=false # -g option only 47778 ZIP_DEBUGINFO_FILES=false 47779 DEBUG_BINARIES=true 47780 STRIP_POLICY=no_strip 47781 STRIP="" 47782 elif test "x$NATIVE_DEBUG_SYMBOLS" = xexternal; then 47783 47784 if test "x$OPENJDK_TARGET_OS" = xsolaris || test "x$OPENJDK_TARGET_OS" = xlinux; then 47785 if test "x$OBJCOPY" = x; then 47786 # enabling of enable-debug-symbols and can't find objcopy 47787 # this is an error 47788 as_fn_error $? "Unable to find objcopy, cannot enable native debug symbols" "$LINENO" 5 47789 fi 47790 fi 47791 47792 ENABLE_DEBUG_SYMBOLS=true 47793 ZIP_DEBUGINFO_FILES=false 47794 DEBUG_BINARIES=true 47795 STRIP_POLICY=min_strip 47796 else 47797 as_fn_error $? "Allowed native debug symbols are: none, internal, external, zipped" "$LINENO" 5 47798 fi 47799 47800 # --enable-debug-symbols is deprecated. 47801 # Please use --with-native-debug-symbols=[internal,external,zipped] . 47802 47803 # Check whether --enable-debug-symbols was given. 47804 if test "${enable_debug_symbols+set}" = set; then : 47805 enableval=$enable_debug_symbols; 47806 fi 47807 47808 if test "x$enable_debug_symbols" != x; then 47809 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --enable-debug-symbols is deprecated and will be ignored." >&5 47810 $as_echo "$as_me: WARNING: Option --enable-debug-symbols is deprecated and will be ignored." >&2;} 47811 47812 if test "xPlease use --with-native-debug-symbols=[internal,external,zipped] ." != x; then 47813 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Please use --with-native-debug-symbols=[internal,external,zipped] ." >&5 47814 $as_echo "$as_me: WARNING: Please use --with-native-debug-symbols=[internal,external,zipped] ." >&2;} 47815 fi 47816 47817 fi 47818 47819 47820 # --enable-zip-debug-info is deprecated. 47821 # Please use --with-native-debug-symbols=zipped . 47822 47823 # Check whether --enable-zip-debug-info was given. 47824 if test "${enable_zip_debug_info+set}" = set; then : 47825 enableval=$enable_zip_debug_info; 47826 fi 47827 47828 if test "x$enable_zip_debug_info" != x; then 47829 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --enable-zip-debug-info is deprecated and will be ignored." >&5 47830 $as_echo "$as_me: WARNING: Option --enable-zip-debug-info is deprecated and will be ignored." >&2;} 47831 47832 if test "xPlease use --with-native-debug-symbols=zipped ." != x; then 47833 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Please use --with-native-debug-symbols=zipped ." >&5 47834 $as_echo "$as_me: WARNING: Please use --with-native-debug-symbols=zipped ." >&2;} 47835 fi 47836 47837 fi 47838 47839 47840 47841 47842 47843 47844 47845 47846 47847 # Check whether --enable-native-coverage was given. 47848 if test "${enable_native_coverage+set}" = set; then : 47849 enableval=$enable_native_coverage; 47850 fi 47851 47852 GCOV_ENABLED="false" 47853 if test "x$enable_native_coverage" = "xyes"; then 47854 if test "x$TOOLCHAIN_TYPE" = "xgcc"; then 47855 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if native coverage is enabled" >&5 47856 $as_echo_n "checking if native coverage is enabled... " >&6; } 47857 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 47858 $as_echo "yes" >&6; } 47859 GCOV_CFLAGS="-fprofile-arcs -ftest-coverage -fno-inline" 47860 GCOV_LDFLAGS="-fprofile-arcs" 47861 LEGACY_EXTRA_CFLAGS="$LEGACY_EXTRA_CFLAGS $GCOV_CFLAGS" 47862 LEGACY_EXTRA_CXXFLAGS="$LEGACY_EXTRA_CXXFLAGS $GCOV_CFLAGS" 47863 LEGACY_EXTRA_LDFLAGS="$LEGACY_EXTRA_LDFLAGS $GCOV_LDFLAGS" 47864 CFLAGS_JDKLIB="$CFLAGS_JDKLIB $GCOV_CFLAGS" 47865 CFLAGS_JDKEXE="$CFLAGS_JDKEXE $GCOV_CFLAGS" 47866 CXXFLAGS_JDKLIB="$CXXFLAGS_JDKLIB $GCOV_CFLAGS" 47867 CXXFLAGS_JDKEXE="$CXXFLAGS_JDKEXE $GCOV_CFLAGS" 47868 LDFLAGS_JDKLIB="$LDFLAGS_JDKLIB $GCOV_LDFLAGS" 47869 LDFLAGS_JDKEXE="$LDFLAGS_JDKEXE $GCOV_LDFLAGS" 47870 GCOV_ENABLED="true" 47871 else 47872 as_fn_error $? "--enable-native-coverage only works with toolchain type gcc" "$LINENO" 5 47873 fi 47874 elif test "x$enable_native_coverage" = "xno"; then 47875 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if native coverage is enabled" >&5 47876 $as_echo_n "checking if native coverage is enabled... " >&6; } 47877 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 47878 $as_echo "no" >&6; } 47879 elif test "x$enable_native_coverage" != "x"; then 47880 as_fn_error $? "--enable-native-coverage can only be assigned \"yes\" or \"no\"" "$LINENO" 5 47881 fi 47882 47883 47884 47885 47886 ############################################################################### 47887 # 47888 # Check dependencies for external and internal libraries. 47889 # 47890 ############################################################################### 47891 47892 # After we have toolchain, we can compile fixpath. It's needed by the lib checks. 47893 47894 # When using cygwin or msys, we need a wrapper binary that renames 47895 # /cygdrive/c/ arguments into c:/ arguments and peeks into 47896 # @files and rewrites these too! This wrapper binary is 47897 # called fixpath. 47898 FIXPATH= 47899 if test "x$OPENJDK_BUILD_OS" = xwindows; then 47900 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fixpath can be created" >&5 47901 $as_echo_n "checking if fixpath can be created... " >&6; } 47902 FIXPATH_SRC="$SRC_ROOT/common/src/fixpath.c" 47903 FIXPATH_BIN="$CONFIGURESUPPORT_OUTPUTDIR/bin/fixpath.exe" 47904 FIXPATH_DIR="$CONFIGURESUPPORT_OUTPUTDIR/fixpath" 47905 if test "x$OPENJDK_BUILD_OS_ENV" = xwindows.cygwin; then 47906 # Important to keep the .exe suffix on Cygwin for Hotspot makefiles 47907 FIXPATH="$FIXPATH_BIN -c" 47908 elif test "x$OPENJDK_BUILD_OS_ENV" = xwindows.msys; then 47909 # Take all collected prefixes and turn them into a -m/c/foo@/c/bar@... command line 47910 # @ was chosen as separator to minimize risk of other tools messing around with it 47911 all_unique_prefixes=`echo "${all_fixpath_prefixes[@]}" \ 47912 | tr ' ' '\n' | grep '^/./' | sort | uniq` 47913 fixpath_argument_list=`echo $all_unique_prefixes | tr ' ' '@'` 47914 FIXPATH="$FIXPATH_BIN -m$fixpath_argument_list" 47915 fi 47916 FIXPATH_SRC_W="$FIXPATH_SRC" 47917 FIXPATH_BIN_W="$FIXPATH_BIN" 47918 47919 unix_path="$FIXPATH_SRC_W" 47920 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47921 windows_path=`$CYGPATH -m "$unix_path"` 47922 FIXPATH_SRC_W="$windows_path" 47923 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47924 windows_path=`cmd //c echo $unix_path` 47925 FIXPATH_SRC_W="$windows_path" 47926 fi 47927 47928 47929 unix_path="$FIXPATH_BIN_W" 47930 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 47931 windows_path=`$CYGPATH -m "$unix_path"` 47932 FIXPATH_BIN_W="$windows_path" 47933 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 47934 windows_path=`cmd //c echo $unix_path` 47935 FIXPATH_BIN_W="$windows_path" 47936 fi 47937 47938 $RM -rf $FIXPATH_BIN $FIXPATH_DIR 47939 $MKDIR -p $FIXPATH_DIR $CONFIGURESUPPORT_OUTPUTDIR/bin 47940 cd $FIXPATH_DIR 47941 $CC $FIXPATH_SRC_W -Fe$FIXPATH_BIN_W > $FIXPATH_DIR/fixpath1.log 2>&1 47942 cd $CURDIR 47943 47944 if test ! -x $FIXPATH_BIN; then 47945 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 47946 $as_echo "no" >&6; } 47947 cat $FIXPATH_DIR/fixpath1.log 47948 as_fn_error $? "Could not create $FIXPATH_BIN" "$LINENO" 5 47949 fi 47950 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 47951 $as_echo "yes" >&6; } 47952 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if fixpath.exe works" >&5 47953 $as_echo_n "checking if fixpath.exe works... " >&6; } 47954 cd $FIXPATH_DIR 47955 $FIXPATH $CC $FIXPATH_SRC -Fe$FIXPATH_DIR/fixpath2.exe \ 47956 > $FIXPATH_DIR/fixpath2.log 2>&1 47957 cd $CURDIR 47958 if test ! -x $FIXPATH_DIR/fixpath2.exe; then 47959 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 47960 $as_echo "no" >&6; } 47961 cat $FIXPATH_DIR/fixpath2.log 47962 as_fn_error $? "fixpath did not work!" "$LINENO" 5 47963 fi 47964 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 47965 $as_echo "yes" >&6; } 47966 47967 FIXPATH_DETACH_FLAG="--detach" 47968 fi 47969 47970 47971 47972 47973 47974 47975 # Check if X11 is needed 47976 if test "x$OPENJDK_TARGET_OS" = xwindows || test "x$OPENJDK_TARGET_OS" = xmacosx; then 47977 # No X11 support on windows or macosx 47978 NEEDS_LIB_X11=false 47979 else 47980 if test "x$SUPPORT_HEADFUL" = xno; then 47981 # No X11 support if building headless-only 47982 NEEDS_LIB_X11=false 47983 else 47984 # All other instances need X11 47985 NEEDS_LIB_X11=true 47986 fi 47987 fi 47988 47989 # Check if cups is needed 47990 if test "x$OPENJDK_TARGET_OS" = xwindows; then 47991 # Windows have a separate print system 47992 NEEDS_LIB_CUPS=false 47993 else 47994 NEEDS_LIB_CUPS=true 47995 fi 47996 47997 # Check if freetype is needed 47998 if test "x$OPENJDK" = "xtrue"; then 47999 NEEDS_LIB_FREETYPE=true 48000 else 48001 NEEDS_LIB_FREETYPE=false 48002 fi 48003 48004 # Check if alsa is needed 48005 if test "x$OPENJDK_TARGET_OS" = xlinux; then 48006 NEEDS_LIB_ALSA=true 48007 else 48008 NEEDS_LIB_ALSA=false 48009 fi 48010 48011 # Check if ffi is needed 48012 if test "x$JVM_VARIANT_ZERO" = xtrue || test "x$JVM_VARIANT_ZEROSHARK" = xtrue; then 48013 NEEDS_LIB_FFI=true 48014 else 48015 NEEDS_LIB_FFI=false 48016 fi 48017 48018 48019 # statically link libstdc++ before C++ ABI is stablized on Linux unless 48020 # dynamic build is configured on command line. 48021 48022 # Check whether --with-stdc++lib was given. 48023 if test "${with_stdc__lib+set}" = set; then : 48024 withval=$with_stdc__lib; 48025 if test "x$with_stdc__lib" != xdynamic && test "x$with_stdc__lib" != xstatic \ 48026 && test "x$with_stdc__lib" != xdefault; then 48027 as_fn_error $? "Bad parameter value --with-stdc++lib=$with_stdc__lib!" "$LINENO" 5 48028 fi 48029 48030 else 48031 with_stdc__lib=default 48032 48033 fi 48034 48035 48036 if test "x$OPENJDK_TARGET_OS" = xlinux; then 48037 # Test if -lstdc++ works. 48038 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if dynamic link of stdc++ is possible" >&5 48039 $as_echo_n "checking if dynamic link of stdc++ is possible... " >&6; } 48040 ac_ext=cpp 48041 ac_cpp='$CXXCPP $CPPFLAGS' 48042 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 48043 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 48044 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 48045 48046 OLD_CXXFLAGS="$CXXFLAGS" 48047 CXXFLAGS="$CXXFLAGS -lstdc++" 48048 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48049 /* end confdefs.h. */ 48050 48051 int 48052 main () 48053 { 48054 return 0; 48055 ; 48056 return 0; 48057 } 48058 _ACEOF 48059 if ac_fn_cxx_try_link "$LINENO"; then : 48060 has_dynamic_libstdcxx=yes 48061 else 48062 has_dynamic_libstdcxx=no 48063 fi 48064 rm -f core conftest.err conftest.$ac_objext \ 48065 conftest$ac_exeext conftest.$ac_ext 48066 CXXFLAGS="$OLD_CXXFLAGS" 48067 ac_ext=cpp 48068 ac_cpp='$CXXCPP $CPPFLAGS' 48069 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 48070 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 48071 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 48072 48073 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_dynamic_libstdcxx" >&5 48074 $as_echo "$has_dynamic_libstdcxx" >&6; } 48075 48076 # Test if stdc++ can be linked statically. 48077 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if static link of stdc++ is possible" >&5 48078 $as_echo_n "checking if static link of stdc++ is possible... " >&6; } 48079 STATIC_STDCXX_FLAGS="-Wl,-Bstatic -lstdc++ -lgcc -Wl,-Bdynamic" 48080 ac_ext=cpp 48081 ac_cpp='$CXXCPP $CPPFLAGS' 48082 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 48083 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 48084 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 48085 48086 OLD_LIBS="$LIBS" 48087 OLD_CXX="$CXX" 48088 LIBS="$STATIC_STDCXX_FLAGS" 48089 CXX="$CC" 48090 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 48091 /* end confdefs.h. */ 48092 48093 int 48094 main () 48095 { 48096 return 0; 48097 ; 48098 return 0; 48099 } 48100 _ACEOF 48101 if ac_fn_cxx_try_link "$LINENO"; then : 48102 has_static_libstdcxx=yes 48103 else 48104 has_static_libstdcxx=no 48105 fi 48106 rm -f core conftest.err conftest.$ac_objext \ 48107 conftest$ac_exeext conftest.$ac_ext 48108 LIBS="$OLD_LIBS" 48109 CXX="$OLD_CXX" 48110 ac_ext=cpp 48111 ac_cpp='$CXXCPP $CPPFLAGS' 48112 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 48113 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 48114 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 48115 48116 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $has_static_libstdcxx" >&5 48117 $as_echo "$has_static_libstdcxx" >&6; } 48118 48119 if test "x$has_static_libstdcxx" = xno && test "x$has_dynamic_libstdcxx" = xno; then 48120 as_fn_error $? "Cannot link to stdc++, neither dynamically nor statically!" "$LINENO" 5 48121 fi 48122 48123 if test "x$with_stdc__lib" = xstatic && test "x$has_static_libstdcxx" = xno; then 48124 as_fn_error $? "Static linking of libstdc++ was not possible!" "$LINENO" 5 48125 fi 48126 48127 if test "x$with_stdc__lib" = xdynamic && test "x$has_dynamic_libstdcxx" = xno; then 48128 as_fn_error $? "Dynamic linking of libstdc++ was not possible!" "$LINENO" 5 48129 fi 48130 48131 # If dynamic was requested, it's available since it would fail above otherwise. 48132 # If dynamic wasn't requested, go with static unless it isn't available. 48133 { $as_echo "$as_me:${as_lineno-$LINENO}: checking how to link with libstdc++" >&5 48134 $as_echo_n "checking how to link with libstdc++... " >&6; } 48135 if test "x$with_stdc__lib" = xdynamic || test "x$has_static_libstdcxx" = xno || test "x$JVM_VARIANT_ZEROSHARK" = xtrue; then 48136 LIBCXX="$LIBCXX -lstdc++" 48137 LDCXX="$CXX" 48138 STATIC_CXX_SETTING="STATIC_CXX=false" 48139 { $as_echo "$as_me:${as_lineno-$LINENO}: result: dynamic" >&5 48140 $as_echo "dynamic" >&6; } 48141 else 48142 LIBCXX="$LIBCXX $STATIC_STDCXX_FLAGS" 48143 LDCXX="$CC" 48144 STATIC_CXX_SETTING="STATIC_CXX=true" 48145 { $as_echo "$as_me:${as_lineno-$LINENO}: result: static" >&5 48146 $as_echo "static" >&6; } 48147 fi 48148 fi 48149 48150 48151 # libCrun is the c++ runtime-library with SunStudio (roughly the equivalent of gcc's libstdc++.so) 48152 if test "x$TOOLCHAIN_TYPE" = xsolstudio && test "x$LIBCXX" = x; then 48153 LIBCXX="${SYSROOT}/usr/lib${OPENJDK_TARGET_CPU_ISADIR}/libCrun.so.1" 48154 fi 48155 48156 # TODO better (platform agnostic) test 48157 if test "x$OPENJDK_TARGET_OS" = xmacosx && test "x$LIBCXX" = x && test "x$TOOLCHAIN_TYPE" = xgcc; then 48158 LIBCXX="-lstdc++" 48159 fi 48160 48161 48162 # Setup Windows runtime dlls 48163 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 48164 48165 48166 # Check whether --with-msvcr-dll was given. 48167 if test "${with_msvcr_dll+set}" = set; then : 48168 withval=$with_msvcr_dll; 48169 fi 48170 48171 48172 if test "x$with_msvcr_dll" != x; then 48173 # If given explicitely by user, do not probe. If not present, fail directly. 48174 48175 DLL_NAME="$MSVCR_NAME" 48176 POSSIBLE_MSVC_DLL="$with_msvcr_dll" 48177 METHOD="--with-msvcr-dll" 48178 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 48179 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 48180 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 48181 48182 # Need to check if the found msvcr is correct architecture 48183 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 48184 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 48185 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 48186 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 48187 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 48188 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 48189 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 48190 CORRECT_MSVCR_ARCH="PE32 executable" 48191 else 48192 CORRECT_MSVCR_ARCH="PE32+ executable" 48193 fi 48194 else 48195 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 48196 CORRECT_MSVCR_ARCH=386 48197 else 48198 CORRECT_MSVCR_ARCH=x86-64 48199 fi 48200 fi 48201 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 48202 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 48203 $as_echo "ok" >&6; } 48204 MSVC_DLL="$POSSIBLE_MSVC_DLL" 48205 48206 # Only process if variable expands to non-empty 48207 48208 if test "x$MSVC_DLL" != x; then 48209 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 48210 48211 # Input might be given as Windows format, start by converting to 48212 # unix format. 48213 path="$MSVC_DLL" 48214 new_path=`$CYGPATH -u "$path"` 48215 48216 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 48217 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 48218 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 48219 # "foo.exe" is OK but "foo" is an error. 48220 # 48221 # This test is therefore slightly more accurate than "test -f" to check for file precense. 48222 # It is also a way to make sure we got the proper file name for the real test later on. 48223 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 48224 if test "x$test_shortpath" = x; then 48225 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 48226 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 48227 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 48228 fi 48229 48230 # Call helper function which possibly converts this using DOS-style short mode. 48231 # If so, the updated path is stored in $new_path. 48232 48233 input_path="$new_path" 48234 # Check if we need to convert this using DOS-style short mode. If the path 48235 # contains just simple characters, use it. Otherwise (spaces, weird characters), 48236 # take no chances and rewrite it. 48237 # Note: m4 eats our [], so we need to use [ and ] instead. 48238 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 48239 if test "x$has_forbidden_chars" != x; then 48240 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 48241 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 48242 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 48243 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 48244 # Going to short mode and back again did indeed matter. Since short mode is 48245 # case insensitive, let's make it lowercase to improve readability. 48246 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 48247 # Now convert it back to Unix-style (cygpath) 48248 input_path=`$CYGPATH -u "$shortmode_path"` 48249 new_path="$input_path" 48250 fi 48251 fi 48252 48253 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 48254 if test "x$test_cygdrive_prefix" = x; then 48255 # As a simple fix, exclude /usr/bin since it's not a real path. 48256 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 48257 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 48258 # a path prefixed by /cygdrive for fixpath to work. 48259 new_path="$CYGWIN_ROOT_PATH$input_path" 48260 fi 48261 fi 48262 48263 48264 if test "x$path" != "x$new_path"; then 48265 MSVC_DLL="$new_path" 48266 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 48267 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 48268 fi 48269 48270 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 48271 48272 path="$MSVC_DLL" 48273 has_colon=`$ECHO $path | $GREP ^.:` 48274 new_path="$path" 48275 if test "x$has_colon" = x; then 48276 # Not in mixed or Windows style, start by that. 48277 new_path=`cmd //c echo $path` 48278 fi 48279 48280 48281 input_path="$new_path" 48282 # Check if we need to convert this using DOS-style short mode. If the path 48283 # contains just simple characters, use it. Otherwise (spaces, weird characters), 48284 # take no chances and rewrite it. 48285 # Note: m4 eats our [], so we need to use [ and ] instead. 48286 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 48287 if test "x$has_forbidden_chars" != x; then 48288 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 48289 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 48290 fi 48291 48292 48293 windows_path="$new_path" 48294 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 48295 unix_path=`$CYGPATH -u "$windows_path"` 48296 new_path="$unix_path" 48297 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 48298 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 48299 new_path="$unix_path" 48300 fi 48301 48302 if test "x$path" != "x$new_path"; then 48303 MSVC_DLL="$new_path" 48304 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 48305 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 48306 fi 48307 48308 # Save the first 10 bytes of this path to the storage, so fixpath can work. 48309 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 48310 48311 else 48312 # We're on a unix platform. Hooray! :) 48313 path="$MSVC_DLL" 48314 has_space=`$ECHO "$path" | $GREP " "` 48315 if test "x$has_space" != x; then 48316 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 48317 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 48318 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 48319 fi 48320 48321 # Use eval to expand a potential ~ 48322 eval path="$path" 48323 if test ! -f "$path" && test ! -d "$path"; then 48324 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 48325 fi 48326 48327 if test -d "$path"; then 48328 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 48329 else 48330 dir="`$DIRNAME "$path"`" 48331 base="`$BASENAME "$path"`" 48332 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 48333 fi 48334 fi 48335 fi 48336 48337 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 48338 $as_echo_n "checking for $DLL_NAME... " >&6; } 48339 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 48340 $as_echo "$MSVC_DLL" >&6; } 48341 else 48342 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 48343 $as_echo "incorrect, ignoring" >&6; } 48344 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 48345 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 48346 fi 48347 fi 48348 48349 if test "x$MSVC_DLL" = x; then 48350 as_fn_error $? "Could not find a proper $MSVCR_NAME as specified by --with-msvcr-dll" "$LINENO" 5 48351 fi 48352 MSVCR_DLL="$MSVC_DLL" 48353 elif test "x$DEVKIT_MSVCR_DLL" != x; then 48354 48355 DLL_NAME="$MSVCR_NAME" 48356 POSSIBLE_MSVC_DLL="$DEVKIT_MSVCR_DLL" 48357 METHOD="devkit" 48358 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 48359 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 48360 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 48361 48362 # Need to check if the found msvcr is correct architecture 48363 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 48364 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 48365 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 48366 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 48367 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 48368 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 48369 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 48370 CORRECT_MSVCR_ARCH="PE32 executable" 48371 else 48372 CORRECT_MSVCR_ARCH="PE32+ executable" 48373 fi 48374 else 48375 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 48376 CORRECT_MSVCR_ARCH=386 48377 else 48378 CORRECT_MSVCR_ARCH=x86-64 48379 fi 48380 fi 48381 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 48382 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 48383 $as_echo "ok" >&6; } 48384 MSVC_DLL="$POSSIBLE_MSVC_DLL" 48385 48386 # Only process if variable expands to non-empty 48387 48388 if test "x$MSVC_DLL" != x; then 48389 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 48390 48391 # Input might be given as Windows format, start by converting to 48392 # unix format. 48393 path="$MSVC_DLL" 48394 new_path=`$CYGPATH -u "$path"` 48395 48396 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 48397 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 48398 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 48399 # "foo.exe" is OK but "foo" is an error. 48400 # 48401 # This test is therefore slightly more accurate than "test -f" to check for file precense. 48402 # It is also a way to make sure we got the proper file name for the real test later on. 48403 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 48404 if test "x$test_shortpath" = x; then 48405 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 48406 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 48407 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 48408 fi 48409 48410 # Call helper function which possibly converts this using DOS-style short mode. 48411 # If so, the updated path is stored in $new_path. 48412 48413 input_path="$new_path" 48414 # Check if we need to convert this using DOS-style short mode. If the path 48415 # contains just simple characters, use it. Otherwise (spaces, weird characters), 48416 # take no chances and rewrite it. 48417 # Note: m4 eats our [], so we need to use [ and ] instead. 48418 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 48419 if test "x$has_forbidden_chars" != x; then 48420 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 48421 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 48422 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 48423 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 48424 # Going to short mode and back again did indeed matter. Since short mode is 48425 # case insensitive, let's make it lowercase to improve readability. 48426 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 48427 # Now convert it back to Unix-style (cygpath) 48428 input_path=`$CYGPATH -u "$shortmode_path"` 48429 new_path="$input_path" 48430 fi 48431 fi 48432 48433 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 48434 if test "x$test_cygdrive_prefix" = x; then 48435 # As a simple fix, exclude /usr/bin since it's not a real path. 48436 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 48437 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 48438 # a path prefixed by /cygdrive for fixpath to work. 48439 new_path="$CYGWIN_ROOT_PATH$input_path" 48440 fi 48441 fi 48442 48443 48444 if test "x$path" != "x$new_path"; then 48445 MSVC_DLL="$new_path" 48446 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 48447 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 48448 fi 48449 48450 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 48451 48452 path="$MSVC_DLL" 48453 has_colon=`$ECHO $path | $GREP ^.:` 48454 new_path="$path" 48455 if test "x$has_colon" = x; then 48456 # Not in mixed or Windows style, start by that. 48457 new_path=`cmd //c echo $path` 48458 fi 48459 48460 48461 input_path="$new_path" 48462 # Check if we need to convert this using DOS-style short mode. If the path 48463 # contains just simple characters, use it. Otherwise (spaces, weird characters), 48464 # take no chances and rewrite it. 48465 # Note: m4 eats our [], so we need to use [ and ] instead. 48466 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 48467 if test "x$has_forbidden_chars" != x; then 48468 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 48469 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 48470 fi 48471 48472 48473 windows_path="$new_path" 48474 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 48475 unix_path=`$CYGPATH -u "$windows_path"` 48476 new_path="$unix_path" 48477 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 48478 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 48479 new_path="$unix_path" 48480 fi 48481 48482 if test "x$path" != "x$new_path"; then 48483 MSVC_DLL="$new_path" 48484 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 48485 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 48486 fi 48487 48488 # Save the first 10 bytes of this path to the storage, so fixpath can work. 48489 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 48490 48491 else 48492 # We're on a unix platform. Hooray! :) 48493 path="$MSVC_DLL" 48494 has_space=`$ECHO "$path" | $GREP " "` 48495 if test "x$has_space" != x; then 48496 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 48497 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 48498 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 48499 fi 48500 48501 # Use eval to expand a potential ~ 48502 eval path="$path" 48503 if test ! -f "$path" && test ! -d "$path"; then 48504 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 48505 fi 48506 48507 if test -d "$path"; then 48508 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 48509 else 48510 dir="`$DIRNAME "$path"`" 48511 base="`$BASENAME "$path"`" 48512 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 48513 fi 48514 fi 48515 fi 48516 48517 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 48518 $as_echo_n "checking for $DLL_NAME... " >&6; } 48519 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 48520 $as_echo "$MSVC_DLL" >&6; } 48521 else 48522 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 48523 $as_echo "incorrect, ignoring" >&6; } 48524 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 48525 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 48526 fi 48527 fi 48528 48529 if test "x$MSVC_DLL" = x; then 48530 as_fn_error $? "Could not find a proper $MSVCR_NAME as specified by devkit" "$LINENO" 5 48531 fi 48532 MSVCR_DLL="$MSVC_DLL" 48533 else 48534 48535 DLL_NAME="${MSVCR_NAME}" 48536 MSVC_DLL= 48537 48538 if test "x$MSVC_DLL" = x; then 48539 # Probe: Using well-known location from Visual Studio 10.0 48540 if test "x$VCINSTALLDIR" != x; then 48541 CYGWIN_VC_INSTALL_DIR="$VCINSTALLDIR" 48542 48543 windows_path="$CYGWIN_VC_INSTALL_DIR" 48544 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 48545 unix_path=`$CYGPATH -u "$windows_path"` 48546 CYGWIN_VC_INSTALL_DIR="$unix_path" 48547 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 48548 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 48549 CYGWIN_VC_INSTALL_DIR="$unix_path" 48550 fi 48551 48552 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 48553 POSSIBLE_MSVC_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x64/Microsoft.VC${VS_VERSION_INTERNAL}.CRT/$DLL_NAME" 48554 else 48555 POSSIBLE_MSVC_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x86/Microsoft.VC${VS_VERSION_INTERNAL}.CRT/$DLL_NAME" 48556 fi 48557 $ECHO "POSSIBLE_MSVC_DLL $POSSIBLEMSVC_DLL" 48558 48559 DLL_NAME="$DLL_NAME" 48560 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 48561 METHOD="well-known location in VCINSTALLDIR" 48562 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 48563 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 48564 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 48565 48566 # Need to check if the found msvcr is correct architecture 48567 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 48568 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 48569 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 48570 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 48571 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 48572 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 48573 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 48574 CORRECT_MSVCR_ARCH="PE32 executable" 48575 else 48576 CORRECT_MSVCR_ARCH="PE32+ executable" 48577 fi 48578 else 48579 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 48580 CORRECT_MSVCR_ARCH=386 48581 else 48582 CORRECT_MSVCR_ARCH=x86-64 48583 fi 48584 fi 48585 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 48586 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 48587 $as_echo "ok" >&6; } 48588 MSVC_DLL="$POSSIBLE_MSVC_DLL" 48589 48590 # Only process if variable expands to non-empty 48591 48592 if test "x$MSVC_DLL" != x; then 48593 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 48594 48595 # Input might be given as Windows format, start by converting to 48596 # unix format. 48597 path="$MSVC_DLL" 48598 new_path=`$CYGPATH -u "$path"` 48599 48600 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 48601 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 48602 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 48603 # "foo.exe" is OK but "foo" is an error. 48604 # 48605 # This test is therefore slightly more accurate than "test -f" to check for file precense. 48606 # It is also a way to make sure we got the proper file name for the real test later on. 48607 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 48608 if test "x$test_shortpath" = x; then 48609 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 48610 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 48611 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 48612 fi 48613 48614 # Call helper function which possibly converts this using DOS-style short mode. 48615 # If so, the updated path is stored in $new_path. 48616 48617 input_path="$new_path" 48618 # Check if we need to convert this using DOS-style short mode. If the path 48619 # contains just simple characters, use it. Otherwise (spaces, weird characters), 48620 # take no chances and rewrite it. 48621 # Note: m4 eats our [], so we need to use [ and ] instead. 48622 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 48623 if test "x$has_forbidden_chars" != x; then 48624 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 48625 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 48626 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 48627 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 48628 # Going to short mode and back again did indeed matter. Since short mode is 48629 # case insensitive, let's make it lowercase to improve readability. 48630 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 48631 # Now convert it back to Unix-style (cygpath) 48632 input_path=`$CYGPATH -u "$shortmode_path"` 48633 new_path="$input_path" 48634 fi 48635 fi 48636 48637 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 48638 if test "x$test_cygdrive_prefix" = x; then 48639 # As a simple fix, exclude /usr/bin since it's not a real path. 48640 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 48641 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 48642 # a path prefixed by /cygdrive for fixpath to work. 48643 new_path="$CYGWIN_ROOT_PATH$input_path" 48644 fi 48645 fi 48646 48647 48648 if test "x$path" != "x$new_path"; then 48649 MSVC_DLL="$new_path" 48650 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 48651 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 48652 fi 48653 48654 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 48655 48656 path="$MSVC_DLL" 48657 has_colon=`$ECHO $path | $GREP ^.:` 48658 new_path="$path" 48659 if test "x$has_colon" = x; then 48660 # Not in mixed or Windows style, start by that. 48661 new_path=`cmd //c echo $path` 48662 fi 48663 48664 48665 input_path="$new_path" 48666 # Check if we need to convert this using DOS-style short mode. If the path 48667 # contains just simple characters, use it. Otherwise (spaces, weird characters), 48668 # take no chances and rewrite it. 48669 # Note: m4 eats our [], so we need to use [ and ] instead. 48670 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 48671 if test "x$has_forbidden_chars" != x; then 48672 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 48673 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 48674 fi 48675 48676 48677 windows_path="$new_path" 48678 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 48679 unix_path=`$CYGPATH -u "$windows_path"` 48680 new_path="$unix_path" 48681 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 48682 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 48683 new_path="$unix_path" 48684 fi 48685 48686 if test "x$path" != "x$new_path"; then 48687 MSVC_DLL="$new_path" 48688 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 48689 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 48690 fi 48691 48692 # Save the first 10 bytes of this path to the storage, so fixpath can work. 48693 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 48694 48695 else 48696 # We're on a unix platform. Hooray! :) 48697 path="$MSVC_DLL" 48698 has_space=`$ECHO "$path" | $GREP " "` 48699 if test "x$has_space" != x; then 48700 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 48701 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 48702 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 48703 fi 48704 48705 # Use eval to expand a potential ~ 48706 eval path="$path" 48707 if test ! -f "$path" && test ! -d "$path"; then 48708 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 48709 fi 48710 48711 if test -d "$path"; then 48712 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 48713 else 48714 dir="`$DIRNAME "$path"`" 48715 base="`$BASENAME "$path"`" 48716 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 48717 fi 48718 fi 48719 fi 48720 48721 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 48722 $as_echo_n "checking for $DLL_NAME... " >&6; } 48723 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 48724 $as_echo "$MSVC_DLL" >&6; } 48725 else 48726 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 48727 $as_echo "incorrect, ignoring" >&6; } 48728 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 48729 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 48730 fi 48731 fi 48732 48733 fi 48734 fi 48735 48736 if test "x$MSVC_DLL" = x; then 48737 # Probe: Check in the Boot JDK directory. 48738 POSSIBLE_MSVC_DLL="$BOOT_JDK/bin/$DLL_NAME" 48739 48740 DLL_NAME="$DLL_NAME" 48741 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 48742 METHOD="well-known location in Boot JDK" 48743 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 48744 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 48745 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 48746 48747 # Need to check if the found msvcr is correct architecture 48748 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 48749 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 48750 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 48751 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 48752 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 48753 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 48754 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 48755 CORRECT_MSVCR_ARCH="PE32 executable" 48756 else 48757 CORRECT_MSVCR_ARCH="PE32+ executable" 48758 fi 48759 else 48760 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 48761 CORRECT_MSVCR_ARCH=386 48762 else 48763 CORRECT_MSVCR_ARCH=x86-64 48764 fi 48765 fi 48766 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 48767 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 48768 $as_echo "ok" >&6; } 48769 MSVC_DLL="$POSSIBLE_MSVC_DLL" 48770 48771 # Only process if variable expands to non-empty 48772 48773 if test "x$MSVC_DLL" != x; then 48774 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 48775 48776 # Input might be given as Windows format, start by converting to 48777 # unix format. 48778 path="$MSVC_DLL" 48779 new_path=`$CYGPATH -u "$path"` 48780 48781 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 48782 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 48783 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 48784 # "foo.exe" is OK but "foo" is an error. 48785 # 48786 # This test is therefore slightly more accurate than "test -f" to check for file precense. 48787 # It is also a way to make sure we got the proper file name for the real test later on. 48788 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 48789 if test "x$test_shortpath" = x; then 48790 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 48791 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 48792 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 48793 fi 48794 48795 # Call helper function which possibly converts this using DOS-style short mode. 48796 # If so, the updated path is stored in $new_path. 48797 48798 input_path="$new_path" 48799 # Check if we need to convert this using DOS-style short mode. If the path 48800 # contains just simple characters, use it. Otherwise (spaces, weird characters), 48801 # take no chances and rewrite it. 48802 # Note: m4 eats our [], so we need to use [ and ] instead. 48803 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 48804 if test "x$has_forbidden_chars" != x; then 48805 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 48806 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 48807 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 48808 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 48809 # Going to short mode and back again did indeed matter. Since short mode is 48810 # case insensitive, let's make it lowercase to improve readability. 48811 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 48812 # Now convert it back to Unix-style (cygpath) 48813 input_path=`$CYGPATH -u "$shortmode_path"` 48814 new_path="$input_path" 48815 fi 48816 fi 48817 48818 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 48819 if test "x$test_cygdrive_prefix" = x; then 48820 # As a simple fix, exclude /usr/bin since it's not a real path. 48821 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 48822 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 48823 # a path prefixed by /cygdrive for fixpath to work. 48824 new_path="$CYGWIN_ROOT_PATH$input_path" 48825 fi 48826 fi 48827 48828 48829 if test "x$path" != "x$new_path"; then 48830 MSVC_DLL="$new_path" 48831 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 48832 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 48833 fi 48834 48835 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 48836 48837 path="$MSVC_DLL" 48838 has_colon=`$ECHO $path | $GREP ^.:` 48839 new_path="$path" 48840 if test "x$has_colon" = x; then 48841 # Not in mixed or Windows style, start by that. 48842 new_path=`cmd //c echo $path` 48843 fi 48844 48845 48846 input_path="$new_path" 48847 # Check if we need to convert this using DOS-style short mode. If the path 48848 # contains just simple characters, use it. Otherwise (spaces, weird characters), 48849 # take no chances and rewrite it. 48850 # Note: m4 eats our [], so we need to use [ and ] instead. 48851 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 48852 if test "x$has_forbidden_chars" != x; then 48853 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 48854 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 48855 fi 48856 48857 48858 windows_path="$new_path" 48859 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 48860 unix_path=`$CYGPATH -u "$windows_path"` 48861 new_path="$unix_path" 48862 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 48863 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 48864 new_path="$unix_path" 48865 fi 48866 48867 if test "x$path" != "x$new_path"; then 48868 MSVC_DLL="$new_path" 48869 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 48870 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 48871 fi 48872 48873 # Save the first 10 bytes of this path to the storage, so fixpath can work. 48874 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 48875 48876 else 48877 # We're on a unix platform. Hooray! :) 48878 path="$MSVC_DLL" 48879 has_space=`$ECHO "$path" | $GREP " "` 48880 if test "x$has_space" != x; then 48881 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 48882 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 48883 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 48884 fi 48885 48886 # Use eval to expand a potential ~ 48887 eval path="$path" 48888 if test ! -f "$path" && test ! -d "$path"; then 48889 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 48890 fi 48891 48892 if test -d "$path"; then 48893 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 48894 else 48895 dir="`$DIRNAME "$path"`" 48896 base="`$BASENAME "$path"`" 48897 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 48898 fi 48899 fi 48900 fi 48901 48902 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 48903 $as_echo_n "checking for $DLL_NAME... " >&6; } 48904 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 48905 $as_echo "$MSVC_DLL" >&6; } 48906 else 48907 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 48908 $as_echo "incorrect, ignoring" >&6; } 48909 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 48910 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 48911 fi 48912 fi 48913 48914 fi 48915 48916 if test "x$MSVC_DLL" = x; then 48917 # Probe: Look in the Windows system32 directory 48918 CYGWIN_SYSTEMROOT="$SYSTEMROOT" 48919 48920 windows_path="$CYGWIN_SYSTEMROOT" 48921 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 48922 unix_path=`$CYGPATH -u "$windows_path"` 48923 CYGWIN_SYSTEMROOT="$unix_path" 48924 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 48925 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 48926 CYGWIN_SYSTEMROOT="$unix_path" 48927 fi 48928 48929 POSSIBLE_MSVC_DLL="$CYGWIN_SYSTEMROOT/system32/$DLL_NAME" 48930 48931 DLL_NAME="$DLL_NAME" 48932 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 48933 METHOD="well-known location in SYSTEMROOT" 48934 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 48935 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 48936 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 48937 48938 # Need to check if the found msvcr is correct architecture 48939 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 48940 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 48941 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 48942 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 48943 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 48944 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 48945 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 48946 CORRECT_MSVCR_ARCH="PE32 executable" 48947 else 48948 CORRECT_MSVCR_ARCH="PE32+ executable" 48949 fi 48950 else 48951 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 48952 CORRECT_MSVCR_ARCH=386 48953 else 48954 CORRECT_MSVCR_ARCH=x86-64 48955 fi 48956 fi 48957 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 48958 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 48959 $as_echo "ok" >&6; } 48960 MSVC_DLL="$POSSIBLE_MSVC_DLL" 48961 48962 # Only process if variable expands to non-empty 48963 48964 if test "x$MSVC_DLL" != x; then 48965 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 48966 48967 # Input might be given as Windows format, start by converting to 48968 # unix format. 48969 path="$MSVC_DLL" 48970 new_path=`$CYGPATH -u "$path"` 48971 48972 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 48973 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 48974 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 48975 # "foo.exe" is OK but "foo" is an error. 48976 # 48977 # This test is therefore slightly more accurate than "test -f" to check for file precense. 48978 # It is also a way to make sure we got the proper file name for the real test later on. 48979 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 48980 if test "x$test_shortpath" = x; then 48981 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 48982 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 48983 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 48984 fi 48985 48986 # Call helper function which possibly converts this using DOS-style short mode. 48987 # If so, the updated path is stored in $new_path. 48988 48989 input_path="$new_path" 48990 # Check if we need to convert this using DOS-style short mode. If the path 48991 # contains just simple characters, use it. Otherwise (spaces, weird characters), 48992 # take no chances and rewrite it. 48993 # Note: m4 eats our [], so we need to use [ and ] instead. 48994 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 48995 if test "x$has_forbidden_chars" != x; then 48996 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 48997 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 48998 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 48999 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 49000 # Going to short mode and back again did indeed matter. Since short mode is 49001 # case insensitive, let's make it lowercase to improve readability. 49002 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 49003 # Now convert it back to Unix-style (cygpath) 49004 input_path=`$CYGPATH -u "$shortmode_path"` 49005 new_path="$input_path" 49006 fi 49007 fi 49008 49009 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 49010 if test "x$test_cygdrive_prefix" = x; then 49011 # As a simple fix, exclude /usr/bin since it's not a real path. 49012 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 49013 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 49014 # a path prefixed by /cygdrive for fixpath to work. 49015 new_path="$CYGWIN_ROOT_PATH$input_path" 49016 fi 49017 fi 49018 49019 49020 if test "x$path" != "x$new_path"; then 49021 MSVC_DLL="$new_path" 49022 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 49023 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 49024 fi 49025 49026 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 49027 49028 path="$MSVC_DLL" 49029 has_colon=`$ECHO $path | $GREP ^.:` 49030 new_path="$path" 49031 if test "x$has_colon" = x; then 49032 # Not in mixed or Windows style, start by that. 49033 new_path=`cmd //c echo $path` 49034 fi 49035 49036 49037 input_path="$new_path" 49038 # Check if we need to convert this using DOS-style short mode. If the path 49039 # contains just simple characters, use it. Otherwise (spaces, weird characters), 49040 # take no chances and rewrite it. 49041 # Note: m4 eats our [], so we need to use [ and ] instead. 49042 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 49043 if test "x$has_forbidden_chars" != x; then 49044 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 49045 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 49046 fi 49047 49048 49049 windows_path="$new_path" 49050 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 49051 unix_path=`$CYGPATH -u "$windows_path"` 49052 new_path="$unix_path" 49053 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 49054 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 49055 new_path="$unix_path" 49056 fi 49057 49058 if test "x$path" != "x$new_path"; then 49059 MSVC_DLL="$new_path" 49060 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 49061 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 49062 fi 49063 49064 # Save the first 10 bytes of this path to the storage, so fixpath can work. 49065 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 49066 49067 else 49068 # We're on a unix platform. Hooray! :) 49069 path="$MSVC_DLL" 49070 has_space=`$ECHO "$path" | $GREP " "` 49071 if test "x$has_space" != x; then 49072 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 49073 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 49074 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 49075 fi 49076 49077 # Use eval to expand a potential ~ 49078 eval path="$path" 49079 if test ! -f "$path" && test ! -d "$path"; then 49080 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 49081 fi 49082 49083 if test -d "$path"; then 49084 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 49085 else 49086 dir="`$DIRNAME "$path"`" 49087 base="`$BASENAME "$path"`" 49088 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 49089 fi 49090 fi 49091 fi 49092 49093 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 49094 $as_echo_n "checking for $DLL_NAME... " >&6; } 49095 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 49096 $as_echo "$MSVC_DLL" >&6; } 49097 else 49098 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 49099 $as_echo "incorrect, ignoring" >&6; } 49100 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 49101 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 49102 fi 49103 fi 49104 49105 fi 49106 49107 if test "x$MSVC_DLL" = x; then 49108 # Probe: If Visual Studio Express is installed, there is usually one with the debugger 49109 if test "x$VS100COMNTOOLS" != x; then 49110 CYGWIN_VS_TOOLS_DIR="$VS100COMNTOOLS/.." 49111 49112 windows_path="$CYGWIN_VS_TOOLS_DIR" 49113 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 49114 unix_path=`$CYGPATH -u "$windows_path"` 49115 CYGWIN_VS_TOOLS_DIR="$unix_path" 49116 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 49117 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 49118 CYGWIN_VS_TOOLS_DIR="$unix_path" 49119 fi 49120 49121 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 49122 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name $DLL_NAME \ 49123 | $GREP -i /x64/ | $HEAD --lines 1` 49124 else 49125 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name $DLL_NAME \ 49126 | $GREP -i /x86/ | $HEAD --lines 1` 49127 fi 49128 49129 DLL_NAME="$DLL_NAME" 49130 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 49131 METHOD="search of VS100COMNTOOLS" 49132 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 49133 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 49134 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 49135 49136 # Need to check if the found msvcr is correct architecture 49137 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 49138 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 49139 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 49140 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 49141 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 49142 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 49143 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 49144 CORRECT_MSVCR_ARCH="PE32 executable" 49145 else 49146 CORRECT_MSVCR_ARCH="PE32+ executable" 49147 fi 49148 else 49149 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 49150 CORRECT_MSVCR_ARCH=386 49151 else 49152 CORRECT_MSVCR_ARCH=x86-64 49153 fi 49154 fi 49155 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 49156 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 49157 $as_echo "ok" >&6; } 49158 MSVC_DLL="$POSSIBLE_MSVC_DLL" 49159 49160 # Only process if variable expands to non-empty 49161 49162 if test "x$MSVC_DLL" != x; then 49163 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 49164 49165 # Input might be given as Windows format, start by converting to 49166 # unix format. 49167 path="$MSVC_DLL" 49168 new_path=`$CYGPATH -u "$path"` 49169 49170 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 49171 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 49172 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 49173 # "foo.exe" is OK but "foo" is an error. 49174 # 49175 # This test is therefore slightly more accurate than "test -f" to check for file precense. 49176 # It is also a way to make sure we got the proper file name for the real test later on. 49177 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 49178 if test "x$test_shortpath" = x; then 49179 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 49180 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 49181 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 49182 fi 49183 49184 # Call helper function which possibly converts this using DOS-style short mode. 49185 # If so, the updated path is stored in $new_path. 49186 49187 input_path="$new_path" 49188 # Check if we need to convert this using DOS-style short mode. If the path 49189 # contains just simple characters, use it. Otherwise (spaces, weird characters), 49190 # take no chances and rewrite it. 49191 # Note: m4 eats our [], so we need to use [ and ] instead. 49192 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 49193 if test "x$has_forbidden_chars" != x; then 49194 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 49195 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 49196 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 49197 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 49198 # Going to short mode and back again did indeed matter. Since short mode is 49199 # case insensitive, let's make it lowercase to improve readability. 49200 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 49201 # Now convert it back to Unix-style (cygpath) 49202 input_path=`$CYGPATH -u "$shortmode_path"` 49203 new_path="$input_path" 49204 fi 49205 fi 49206 49207 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 49208 if test "x$test_cygdrive_prefix" = x; then 49209 # As a simple fix, exclude /usr/bin since it's not a real path. 49210 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 49211 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 49212 # a path prefixed by /cygdrive for fixpath to work. 49213 new_path="$CYGWIN_ROOT_PATH$input_path" 49214 fi 49215 fi 49216 49217 49218 if test "x$path" != "x$new_path"; then 49219 MSVC_DLL="$new_path" 49220 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 49221 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 49222 fi 49223 49224 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 49225 49226 path="$MSVC_DLL" 49227 has_colon=`$ECHO $path | $GREP ^.:` 49228 new_path="$path" 49229 if test "x$has_colon" = x; then 49230 # Not in mixed or Windows style, start by that. 49231 new_path=`cmd //c echo $path` 49232 fi 49233 49234 49235 input_path="$new_path" 49236 # Check if we need to convert this using DOS-style short mode. If the path 49237 # contains just simple characters, use it. Otherwise (spaces, weird characters), 49238 # take no chances and rewrite it. 49239 # Note: m4 eats our [], so we need to use [ and ] instead. 49240 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 49241 if test "x$has_forbidden_chars" != x; then 49242 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 49243 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 49244 fi 49245 49246 49247 windows_path="$new_path" 49248 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 49249 unix_path=`$CYGPATH -u "$windows_path"` 49250 new_path="$unix_path" 49251 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 49252 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 49253 new_path="$unix_path" 49254 fi 49255 49256 if test "x$path" != "x$new_path"; then 49257 MSVC_DLL="$new_path" 49258 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 49259 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 49260 fi 49261 49262 # Save the first 10 bytes of this path to the storage, so fixpath can work. 49263 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 49264 49265 else 49266 # We're on a unix platform. Hooray! :) 49267 path="$MSVC_DLL" 49268 has_space=`$ECHO "$path" | $GREP " "` 49269 if test "x$has_space" != x; then 49270 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 49271 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 49272 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 49273 fi 49274 49275 # Use eval to expand a potential ~ 49276 eval path="$path" 49277 if test ! -f "$path" && test ! -d "$path"; then 49278 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 49279 fi 49280 49281 if test -d "$path"; then 49282 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 49283 else 49284 dir="`$DIRNAME "$path"`" 49285 base="`$BASENAME "$path"`" 49286 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 49287 fi 49288 fi 49289 fi 49290 49291 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 49292 $as_echo_n "checking for $DLL_NAME... " >&6; } 49293 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 49294 $as_echo "$MSVC_DLL" >&6; } 49295 else 49296 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 49297 $as_echo "incorrect, ignoring" >&6; } 49298 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 49299 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 49300 fi 49301 fi 49302 49303 fi 49304 fi 49305 49306 if test "x$MSVC_DLL" = x; then 49307 # Probe: Search wildly in the VCINSTALLDIR. We've probably lost by now. 49308 # (This was the original behaviour; kept since it might turn something up) 49309 if test "x$CYGWIN_VC_INSTALL_DIR" != x; then 49310 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 49311 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 49312 | $GREP x64 | $HEAD --lines 1` 49313 else 49314 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 49315 | $GREP x86 | $GREP -v ia64 | $GREP -v x64 | $HEAD --lines 1` 49316 if test "x$POSSIBLE_MSVC_DLL" = x; then 49317 # We're grasping at straws now... 49318 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 49319 | $HEAD --lines 1` 49320 fi 49321 fi 49322 49323 49324 DLL_NAME="$DLL_NAME" 49325 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 49326 METHOD="search of VCINSTALLDIR" 49327 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 49328 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 49329 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 49330 49331 # Need to check if the found msvcr is correct architecture 49332 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 49333 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 49334 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 49335 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 49336 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 49337 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 49338 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 49339 CORRECT_MSVCR_ARCH="PE32 executable" 49340 else 49341 CORRECT_MSVCR_ARCH="PE32+ executable" 49342 fi 49343 else 49344 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 49345 CORRECT_MSVCR_ARCH=386 49346 else 49347 CORRECT_MSVCR_ARCH=x86-64 49348 fi 49349 fi 49350 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 49351 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 49352 $as_echo "ok" >&6; } 49353 MSVC_DLL="$POSSIBLE_MSVC_DLL" 49354 49355 # Only process if variable expands to non-empty 49356 49357 if test "x$MSVC_DLL" != x; then 49358 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 49359 49360 # Input might be given as Windows format, start by converting to 49361 # unix format. 49362 path="$MSVC_DLL" 49363 new_path=`$CYGPATH -u "$path"` 49364 49365 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 49366 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 49367 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 49368 # "foo.exe" is OK but "foo" is an error. 49369 # 49370 # This test is therefore slightly more accurate than "test -f" to check for file precense. 49371 # It is also a way to make sure we got the proper file name for the real test later on. 49372 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 49373 if test "x$test_shortpath" = x; then 49374 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 49375 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 49376 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 49377 fi 49378 49379 # Call helper function which possibly converts this using DOS-style short mode. 49380 # If so, the updated path is stored in $new_path. 49381 49382 input_path="$new_path" 49383 # Check if we need to convert this using DOS-style short mode. If the path 49384 # contains just simple characters, use it. Otherwise (spaces, weird characters), 49385 # take no chances and rewrite it. 49386 # Note: m4 eats our [], so we need to use [ and ] instead. 49387 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 49388 if test "x$has_forbidden_chars" != x; then 49389 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 49390 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 49391 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 49392 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 49393 # Going to short mode and back again did indeed matter. Since short mode is 49394 # case insensitive, let's make it lowercase to improve readability. 49395 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 49396 # Now convert it back to Unix-style (cygpath) 49397 input_path=`$CYGPATH -u "$shortmode_path"` 49398 new_path="$input_path" 49399 fi 49400 fi 49401 49402 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 49403 if test "x$test_cygdrive_prefix" = x; then 49404 # As a simple fix, exclude /usr/bin since it's not a real path. 49405 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 49406 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 49407 # a path prefixed by /cygdrive for fixpath to work. 49408 new_path="$CYGWIN_ROOT_PATH$input_path" 49409 fi 49410 fi 49411 49412 49413 if test "x$path" != "x$new_path"; then 49414 MSVC_DLL="$new_path" 49415 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 49416 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 49417 fi 49418 49419 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 49420 49421 path="$MSVC_DLL" 49422 has_colon=`$ECHO $path | $GREP ^.:` 49423 new_path="$path" 49424 if test "x$has_colon" = x; then 49425 # Not in mixed or Windows style, start by that. 49426 new_path=`cmd //c echo $path` 49427 fi 49428 49429 49430 input_path="$new_path" 49431 # Check if we need to convert this using DOS-style short mode. If the path 49432 # contains just simple characters, use it. Otherwise (spaces, weird characters), 49433 # take no chances and rewrite it. 49434 # Note: m4 eats our [], so we need to use [ and ] instead. 49435 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 49436 if test "x$has_forbidden_chars" != x; then 49437 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 49438 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 49439 fi 49440 49441 49442 windows_path="$new_path" 49443 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 49444 unix_path=`$CYGPATH -u "$windows_path"` 49445 new_path="$unix_path" 49446 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 49447 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 49448 new_path="$unix_path" 49449 fi 49450 49451 if test "x$path" != "x$new_path"; then 49452 MSVC_DLL="$new_path" 49453 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 49454 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 49455 fi 49456 49457 # Save the first 10 bytes of this path to the storage, so fixpath can work. 49458 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 49459 49460 else 49461 # We're on a unix platform. Hooray! :) 49462 path="$MSVC_DLL" 49463 has_space=`$ECHO "$path" | $GREP " "` 49464 if test "x$has_space" != x; then 49465 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 49466 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 49467 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 49468 fi 49469 49470 # Use eval to expand a potential ~ 49471 eval path="$path" 49472 if test ! -f "$path" && test ! -d "$path"; then 49473 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 49474 fi 49475 49476 if test -d "$path"; then 49477 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 49478 else 49479 dir="`$DIRNAME "$path"`" 49480 base="`$BASENAME "$path"`" 49481 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 49482 fi 49483 fi 49484 fi 49485 49486 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 49487 $as_echo_n "checking for $DLL_NAME... " >&6; } 49488 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 49489 $as_echo "$MSVC_DLL" >&6; } 49490 else 49491 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 49492 $as_echo "incorrect, ignoring" >&6; } 49493 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 49494 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 49495 fi 49496 fi 49497 49498 fi 49499 fi 49500 49501 if test "x$MSVC_DLL" = x; then 49502 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 49503 $as_echo_n "checking for $DLL_NAME... " >&6; } 49504 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 49505 $as_echo "no" >&6; } 49506 as_fn_error $? "Could not find $DLL_NAME. Please specify using --with-msvcr-dll." "$LINENO" 5 49507 fi 49508 49509 MSVCR_DLL="$MSVC_DLL" 49510 fi 49511 49512 49513 49514 # Check whether --with-msvcp-dll was given. 49515 if test "${with_msvcp_dll+set}" = set; then : 49516 withval=$with_msvcp_dll; 49517 fi 49518 49519 49520 if test "x$MSVCP_NAME" != "x"; then 49521 if test "x$with_msvcp_dll" != x; then 49522 # If given explicitely by user, do not probe. If not present, fail directly. 49523 49524 DLL_NAME="$MSVCP_NAME" 49525 POSSIBLE_MSVC_DLL="$with_msvcp_dll" 49526 METHOD="--with-msvcp-dll" 49527 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 49528 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 49529 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 49530 49531 # Need to check if the found msvcr is correct architecture 49532 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 49533 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 49534 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 49535 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 49536 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 49537 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 49538 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 49539 CORRECT_MSVCR_ARCH="PE32 executable" 49540 else 49541 CORRECT_MSVCR_ARCH="PE32+ executable" 49542 fi 49543 else 49544 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 49545 CORRECT_MSVCR_ARCH=386 49546 else 49547 CORRECT_MSVCR_ARCH=x86-64 49548 fi 49549 fi 49550 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 49551 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 49552 $as_echo "ok" >&6; } 49553 MSVC_DLL="$POSSIBLE_MSVC_DLL" 49554 49555 # Only process if variable expands to non-empty 49556 49557 if test "x$MSVC_DLL" != x; then 49558 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 49559 49560 # Input might be given as Windows format, start by converting to 49561 # unix format. 49562 path="$MSVC_DLL" 49563 new_path=`$CYGPATH -u "$path"` 49564 49565 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 49566 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 49567 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 49568 # "foo.exe" is OK but "foo" is an error. 49569 # 49570 # This test is therefore slightly more accurate than "test -f" to check for file precense. 49571 # It is also a way to make sure we got the proper file name for the real test later on. 49572 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 49573 if test "x$test_shortpath" = x; then 49574 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 49575 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 49576 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 49577 fi 49578 49579 # Call helper function which possibly converts this using DOS-style short mode. 49580 # If so, the updated path is stored in $new_path. 49581 49582 input_path="$new_path" 49583 # Check if we need to convert this using DOS-style short mode. If the path 49584 # contains just simple characters, use it. Otherwise (spaces, weird characters), 49585 # take no chances and rewrite it. 49586 # Note: m4 eats our [], so we need to use [ and ] instead. 49587 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 49588 if test "x$has_forbidden_chars" != x; then 49589 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 49590 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 49591 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 49592 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 49593 # Going to short mode and back again did indeed matter. Since short mode is 49594 # case insensitive, let's make it lowercase to improve readability. 49595 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 49596 # Now convert it back to Unix-style (cygpath) 49597 input_path=`$CYGPATH -u "$shortmode_path"` 49598 new_path="$input_path" 49599 fi 49600 fi 49601 49602 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 49603 if test "x$test_cygdrive_prefix" = x; then 49604 # As a simple fix, exclude /usr/bin since it's not a real path. 49605 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 49606 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 49607 # a path prefixed by /cygdrive for fixpath to work. 49608 new_path="$CYGWIN_ROOT_PATH$input_path" 49609 fi 49610 fi 49611 49612 49613 if test "x$path" != "x$new_path"; then 49614 MSVC_DLL="$new_path" 49615 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 49616 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 49617 fi 49618 49619 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 49620 49621 path="$MSVC_DLL" 49622 has_colon=`$ECHO $path | $GREP ^.:` 49623 new_path="$path" 49624 if test "x$has_colon" = x; then 49625 # Not in mixed or Windows style, start by that. 49626 new_path=`cmd //c echo $path` 49627 fi 49628 49629 49630 input_path="$new_path" 49631 # Check if we need to convert this using DOS-style short mode. If the path 49632 # contains just simple characters, use it. Otherwise (spaces, weird characters), 49633 # take no chances and rewrite it. 49634 # Note: m4 eats our [], so we need to use [ and ] instead. 49635 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 49636 if test "x$has_forbidden_chars" != x; then 49637 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 49638 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 49639 fi 49640 49641 49642 windows_path="$new_path" 49643 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 49644 unix_path=`$CYGPATH -u "$windows_path"` 49645 new_path="$unix_path" 49646 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 49647 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 49648 new_path="$unix_path" 49649 fi 49650 49651 if test "x$path" != "x$new_path"; then 49652 MSVC_DLL="$new_path" 49653 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 49654 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 49655 fi 49656 49657 # Save the first 10 bytes of this path to the storage, so fixpath can work. 49658 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 49659 49660 else 49661 # We're on a unix platform. Hooray! :) 49662 path="$MSVC_DLL" 49663 has_space=`$ECHO "$path" | $GREP " "` 49664 if test "x$has_space" != x; then 49665 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 49666 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 49667 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 49668 fi 49669 49670 # Use eval to expand a potential ~ 49671 eval path="$path" 49672 if test ! -f "$path" && test ! -d "$path"; then 49673 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 49674 fi 49675 49676 if test -d "$path"; then 49677 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 49678 else 49679 dir="`$DIRNAME "$path"`" 49680 base="`$BASENAME "$path"`" 49681 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 49682 fi 49683 fi 49684 fi 49685 49686 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 49687 $as_echo_n "checking for $DLL_NAME... " >&6; } 49688 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 49689 $as_echo "$MSVC_DLL" >&6; } 49690 else 49691 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 49692 $as_echo "incorrect, ignoring" >&6; } 49693 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 49694 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 49695 fi 49696 fi 49697 49698 if test "x$MSVC_DLL" = x; then 49699 as_fn_error $? "Could not find a proper $MSVCP_NAME as specified by --with-msvcp-dll" "$LINENO" 5 49700 fi 49701 MSVCP_DLL="$MSVC_DLL" 49702 elif test "x$DEVKIT_MSVCP_DLL" != x; then 49703 49704 DLL_NAME="$MSVCP_NAME" 49705 POSSIBLE_MSVC_DLL="$DEVKIT_MSVCP_DLL" 49706 METHOD="devkit" 49707 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 49708 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 49709 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 49710 49711 # Need to check if the found msvcr is correct architecture 49712 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 49713 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 49714 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 49715 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 49716 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 49717 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 49718 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 49719 CORRECT_MSVCR_ARCH="PE32 executable" 49720 else 49721 CORRECT_MSVCR_ARCH="PE32+ executable" 49722 fi 49723 else 49724 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 49725 CORRECT_MSVCR_ARCH=386 49726 else 49727 CORRECT_MSVCR_ARCH=x86-64 49728 fi 49729 fi 49730 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 49731 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 49732 $as_echo "ok" >&6; } 49733 MSVC_DLL="$POSSIBLE_MSVC_DLL" 49734 49735 # Only process if variable expands to non-empty 49736 49737 if test "x$MSVC_DLL" != x; then 49738 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 49739 49740 # Input might be given as Windows format, start by converting to 49741 # unix format. 49742 path="$MSVC_DLL" 49743 new_path=`$CYGPATH -u "$path"` 49744 49745 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 49746 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 49747 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 49748 # "foo.exe" is OK but "foo" is an error. 49749 # 49750 # This test is therefore slightly more accurate than "test -f" to check for file precense. 49751 # It is also a way to make sure we got the proper file name for the real test later on. 49752 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 49753 if test "x$test_shortpath" = x; then 49754 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 49755 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 49756 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 49757 fi 49758 49759 # Call helper function which possibly converts this using DOS-style short mode. 49760 # If so, the updated path is stored in $new_path. 49761 49762 input_path="$new_path" 49763 # Check if we need to convert this using DOS-style short mode. If the path 49764 # contains just simple characters, use it. Otherwise (spaces, weird characters), 49765 # take no chances and rewrite it. 49766 # Note: m4 eats our [], so we need to use [ and ] instead. 49767 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 49768 if test "x$has_forbidden_chars" != x; then 49769 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 49770 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 49771 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 49772 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 49773 # Going to short mode and back again did indeed matter. Since short mode is 49774 # case insensitive, let's make it lowercase to improve readability. 49775 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 49776 # Now convert it back to Unix-style (cygpath) 49777 input_path=`$CYGPATH -u "$shortmode_path"` 49778 new_path="$input_path" 49779 fi 49780 fi 49781 49782 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 49783 if test "x$test_cygdrive_prefix" = x; then 49784 # As a simple fix, exclude /usr/bin since it's not a real path. 49785 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 49786 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 49787 # a path prefixed by /cygdrive for fixpath to work. 49788 new_path="$CYGWIN_ROOT_PATH$input_path" 49789 fi 49790 fi 49791 49792 49793 if test "x$path" != "x$new_path"; then 49794 MSVC_DLL="$new_path" 49795 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 49796 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 49797 fi 49798 49799 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 49800 49801 path="$MSVC_DLL" 49802 has_colon=`$ECHO $path | $GREP ^.:` 49803 new_path="$path" 49804 if test "x$has_colon" = x; then 49805 # Not in mixed or Windows style, start by that. 49806 new_path=`cmd //c echo $path` 49807 fi 49808 49809 49810 input_path="$new_path" 49811 # Check if we need to convert this using DOS-style short mode. If the path 49812 # contains just simple characters, use it. Otherwise (spaces, weird characters), 49813 # take no chances and rewrite it. 49814 # Note: m4 eats our [], so we need to use [ and ] instead. 49815 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 49816 if test "x$has_forbidden_chars" != x; then 49817 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 49818 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 49819 fi 49820 49821 49822 windows_path="$new_path" 49823 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 49824 unix_path=`$CYGPATH -u "$windows_path"` 49825 new_path="$unix_path" 49826 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 49827 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 49828 new_path="$unix_path" 49829 fi 49830 49831 if test "x$path" != "x$new_path"; then 49832 MSVC_DLL="$new_path" 49833 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 49834 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 49835 fi 49836 49837 # Save the first 10 bytes of this path to the storage, so fixpath can work. 49838 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 49839 49840 else 49841 # We're on a unix platform. Hooray! :) 49842 path="$MSVC_DLL" 49843 has_space=`$ECHO "$path" | $GREP " "` 49844 if test "x$has_space" != x; then 49845 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 49846 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 49847 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 49848 fi 49849 49850 # Use eval to expand a potential ~ 49851 eval path="$path" 49852 if test ! -f "$path" && test ! -d "$path"; then 49853 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 49854 fi 49855 49856 if test -d "$path"; then 49857 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 49858 else 49859 dir="`$DIRNAME "$path"`" 49860 base="`$BASENAME "$path"`" 49861 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 49862 fi 49863 fi 49864 fi 49865 49866 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 49867 $as_echo_n "checking for $DLL_NAME... " >&6; } 49868 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 49869 $as_echo "$MSVC_DLL" >&6; } 49870 else 49871 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 49872 $as_echo "incorrect, ignoring" >&6; } 49873 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 49874 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 49875 fi 49876 fi 49877 49878 if test "x$MSVC_DLL" = x; then 49879 as_fn_error $? "Could not find a proper $MSVCP_NAME as specified by devkit" "$LINENO" 5 49880 fi 49881 MSVCP_DLL="$MSVC_DLL" 49882 else 49883 49884 DLL_NAME="${MSVCP_NAME}" 49885 MSVC_DLL= 49886 49887 if test "x$MSVC_DLL" = x; then 49888 # Probe: Using well-known location from Visual Studio 10.0 49889 if test "x$VCINSTALLDIR" != x; then 49890 CYGWIN_VC_INSTALL_DIR="$VCINSTALLDIR" 49891 49892 windows_path="$CYGWIN_VC_INSTALL_DIR" 49893 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 49894 unix_path=`$CYGPATH -u "$windows_path"` 49895 CYGWIN_VC_INSTALL_DIR="$unix_path" 49896 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 49897 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 49898 CYGWIN_VC_INSTALL_DIR="$unix_path" 49899 fi 49900 49901 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 49902 POSSIBLE_MSVC_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x64/Microsoft.VC${VS_VERSION_INTERNAL}.CRT/$DLL_NAME" 49903 else 49904 POSSIBLE_MSVC_DLL="$CYGWIN_VC_INSTALL_DIR/redist/x86/Microsoft.VC${VS_VERSION_INTERNAL}.CRT/$DLL_NAME" 49905 fi 49906 $ECHO "POSSIBLE_MSVC_DLL $POSSIBLEMSVC_DLL" 49907 49908 DLL_NAME="$DLL_NAME" 49909 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 49910 METHOD="well-known location in VCINSTALLDIR" 49911 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 49912 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 49913 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 49914 49915 # Need to check if the found msvcr is correct architecture 49916 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 49917 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 49918 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 49919 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 49920 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 49921 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 49922 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 49923 CORRECT_MSVCR_ARCH="PE32 executable" 49924 else 49925 CORRECT_MSVCR_ARCH="PE32+ executable" 49926 fi 49927 else 49928 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 49929 CORRECT_MSVCR_ARCH=386 49930 else 49931 CORRECT_MSVCR_ARCH=x86-64 49932 fi 49933 fi 49934 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 49935 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 49936 $as_echo "ok" >&6; } 49937 MSVC_DLL="$POSSIBLE_MSVC_DLL" 49938 49939 # Only process if variable expands to non-empty 49940 49941 if test "x$MSVC_DLL" != x; then 49942 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 49943 49944 # Input might be given as Windows format, start by converting to 49945 # unix format. 49946 path="$MSVC_DLL" 49947 new_path=`$CYGPATH -u "$path"` 49948 49949 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 49950 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 49951 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 49952 # "foo.exe" is OK but "foo" is an error. 49953 # 49954 # This test is therefore slightly more accurate than "test -f" to check for file precense. 49955 # It is also a way to make sure we got the proper file name for the real test later on. 49956 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 49957 if test "x$test_shortpath" = x; then 49958 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 49959 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 49960 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 49961 fi 49962 49963 # Call helper function which possibly converts this using DOS-style short mode. 49964 # If so, the updated path is stored in $new_path. 49965 49966 input_path="$new_path" 49967 # Check if we need to convert this using DOS-style short mode. If the path 49968 # contains just simple characters, use it. Otherwise (spaces, weird characters), 49969 # take no chances and rewrite it. 49970 # Note: m4 eats our [], so we need to use [ and ] instead. 49971 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 49972 if test "x$has_forbidden_chars" != x; then 49973 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 49974 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 49975 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 49976 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 49977 # Going to short mode and back again did indeed matter. Since short mode is 49978 # case insensitive, let's make it lowercase to improve readability. 49979 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 49980 # Now convert it back to Unix-style (cygpath) 49981 input_path=`$CYGPATH -u "$shortmode_path"` 49982 new_path="$input_path" 49983 fi 49984 fi 49985 49986 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 49987 if test "x$test_cygdrive_prefix" = x; then 49988 # As a simple fix, exclude /usr/bin since it's not a real path. 49989 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 49990 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 49991 # a path prefixed by /cygdrive for fixpath to work. 49992 new_path="$CYGWIN_ROOT_PATH$input_path" 49993 fi 49994 fi 49995 49996 49997 if test "x$path" != "x$new_path"; then 49998 MSVC_DLL="$new_path" 49999 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 50000 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 50001 fi 50002 50003 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 50004 50005 path="$MSVC_DLL" 50006 has_colon=`$ECHO $path | $GREP ^.:` 50007 new_path="$path" 50008 if test "x$has_colon" = x; then 50009 # Not in mixed or Windows style, start by that. 50010 new_path=`cmd //c echo $path` 50011 fi 50012 50013 50014 input_path="$new_path" 50015 # Check if we need to convert this using DOS-style short mode. If the path 50016 # contains just simple characters, use it. Otherwise (spaces, weird characters), 50017 # take no chances and rewrite it. 50018 # Note: m4 eats our [], so we need to use [ and ] instead. 50019 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 50020 if test "x$has_forbidden_chars" != x; then 50021 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 50022 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 50023 fi 50024 50025 50026 windows_path="$new_path" 50027 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 50028 unix_path=`$CYGPATH -u "$windows_path"` 50029 new_path="$unix_path" 50030 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 50031 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 50032 new_path="$unix_path" 50033 fi 50034 50035 if test "x$path" != "x$new_path"; then 50036 MSVC_DLL="$new_path" 50037 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 50038 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 50039 fi 50040 50041 # Save the first 10 bytes of this path to the storage, so fixpath can work. 50042 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 50043 50044 else 50045 # We're on a unix platform. Hooray! :) 50046 path="$MSVC_DLL" 50047 has_space=`$ECHO "$path" | $GREP " "` 50048 if test "x$has_space" != x; then 50049 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 50050 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 50051 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 50052 fi 50053 50054 # Use eval to expand a potential ~ 50055 eval path="$path" 50056 if test ! -f "$path" && test ! -d "$path"; then 50057 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 50058 fi 50059 50060 if test -d "$path"; then 50061 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 50062 else 50063 dir="`$DIRNAME "$path"`" 50064 base="`$BASENAME "$path"`" 50065 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 50066 fi 50067 fi 50068 fi 50069 50070 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 50071 $as_echo_n "checking for $DLL_NAME... " >&6; } 50072 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 50073 $as_echo "$MSVC_DLL" >&6; } 50074 else 50075 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 50076 $as_echo "incorrect, ignoring" >&6; } 50077 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 50078 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 50079 fi 50080 fi 50081 50082 fi 50083 fi 50084 50085 if test "x$MSVC_DLL" = x; then 50086 # Probe: Check in the Boot JDK directory. 50087 POSSIBLE_MSVC_DLL="$BOOT_JDK/bin/$DLL_NAME" 50088 50089 DLL_NAME="$DLL_NAME" 50090 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 50091 METHOD="well-known location in Boot JDK" 50092 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 50093 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 50094 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 50095 50096 # Need to check if the found msvcr is correct architecture 50097 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 50098 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 50099 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 50100 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 50101 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 50102 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 50103 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 50104 CORRECT_MSVCR_ARCH="PE32 executable" 50105 else 50106 CORRECT_MSVCR_ARCH="PE32+ executable" 50107 fi 50108 else 50109 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 50110 CORRECT_MSVCR_ARCH=386 50111 else 50112 CORRECT_MSVCR_ARCH=x86-64 50113 fi 50114 fi 50115 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 50116 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 50117 $as_echo "ok" >&6; } 50118 MSVC_DLL="$POSSIBLE_MSVC_DLL" 50119 50120 # Only process if variable expands to non-empty 50121 50122 if test "x$MSVC_DLL" != x; then 50123 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 50124 50125 # Input might be given as Windows format, start by converting to 50126 # unix format. 50127 path="$MSVC_DLL" 50128 new_path=`$CYGPATH -u "$path"` 50129 50130 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 50131 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 50132 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 50133 # "foo.exe" is OK but "foo" is an error. 50134 # 50135 # This test is therefore slightly more accurate than "test -f" to check for file precense. 50136 # It is also a way to make sure we got the proper file name for the real test later on. 50137 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 50138 if test "x$test_shortpath" = x; then 50139 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 50140 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 50141 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 50142 fi 50143 50144 # Call helper function which possibly converts this using DOS-style short mode. 50145 # If so, the updated path is stored in $new_path. 50146 50147 input_path="$new_path" 50148 # Check if we need to convert this using DOS-style short mode. If the path 50149 # contains just simple characters, use it. Otherwise (spaces, weird characters), 50150 # take no chances and rewrite it. 50151 # Note: m4 eats our [], so we need to use [ and ] instead. 50152 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 50153 if test "x$has_forbidden_chars" != x; then 50154 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 50155 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 50156 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 50157 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 50158 # Going to short mode and back again did indeed matter. Since short mode is 50159 # case insensitive, let's make it lowercase to improve readability. 50160 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 50161 # Now convert it back to Unix-style (cygpath) 50162 input_path=`$CYGPATH -u "$shortmode_path"` 50163 new_path="$input_path" 50164 fi 50165 fi 50166 50167 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 50168 if test "x$test_cygdrive_prefix" = x; then 50169 # As a simple fix, exclude /usr/bin since it's not a real path. 50170 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 50171 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 50172 # a path prefixed by /cygdrive for fixpath to work. 50173 new_path="$CYGWIN_ROOT_PATH$input_path" 50174 fi 50175 fi 50176 50177 50178 if test "x$path" != "x$new_path"; then 50179 MSVC_DLL="$new_path" 50180 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 50181 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 50182 fi 50183 50184 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 50185 50186 path="$MSVC_DLL" 50187 has_colon=`$ECHO $path | $GREP ^.:` 50188 new_path="$path" 50189 if test "x$has_colon" = x; then 50190 # Not in mixed or Windows style, start by that. 50191 new_path=`cmd //c echo $path` 50192 fi 50193 50194 50195 input_path="$new_path" 50196 # Check if we need to convert this using DOS-style short mode. If the path 50197 # contains just simple characters, use it. Otherwise (spaces, weird characters), 50198 # take no chances and rewrite it. 50199 # Note: m4 eats our [], so we need to use [ and ] instead. 50200 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 50201 if test "x$has_forbidden_chars" != x; then 50202 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 50203 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 50204 fi 50205 50206 50207 windows_path="$new_path" 50208 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 50209 unix_path=`$CYGPATH -u "$windows_path"` 50210 new_path="$unix_path" 50211 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 50212 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 50213 new_path="$unix_path" 50214 fi 50215 50216 if test "x$path" != "x$new_path"; then 50217 MSVC_DLL="$new_path" 50218 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 50219 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 50220 fi 50221 50222 # Save the first 10 bytes of this path to the storage, so fixpath can work. 50223 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 50224 50225 else 50226 # We're on a unix platform. Hooray! :) 50227 path="$MSVC_DLL" 50228 has_space=`$ECHO "$path" | $GREP " "` 50229 if test "x$has_space" != x; then 50230 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 50231 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 50232 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 50233 fi 50234 50235 # Use eval to expand a potential ~ 50236 eval path="$path" 50237 if test ! -f "$path" && test ! -d "$path"; then 50238 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 50239 fi 50240 50241 if test -d "$path"; then 50242 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 50243 else 50244 dir="`$DIRNAME "$path"`" 50245 base="`$BASENAME "$path"`" 50246 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 50247 fi 50248 fi 50249 fi 50250 50251 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 50252 $as_echo_n "checking for $DLL_NAME... " >&6; } 50253 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 50254 $as_echo "$MSVC_DLL" >&6; } 50255 else 50256 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 50257 $as_echo "incorrect, ignoring" >&6; } 50258 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 50259 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 50260 fi 50261 fi 50262 50263 fi 50264 50265 if test "x$MSVC_DLL" = x; then 50266 # Probe: Look in the Windows system32 directory 50267 CYGWIN_SYSTEMROOT="$SYSTEMROOT" 50268 50269 windows_path="$CYGWIN_SYSTEMROOT" 50270 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 50271 unix_path=`$CYGPATH -u "$windows_path"` 50272 CYGWIN_SYSTEMROOT="$unix_path" 50273 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 50274 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 50275 CYGWIN_SYSTEMROOT="$unix_path" 50276 fi 50277 50278 POSSIBLE_MSVC_DLL="$CYGWIN_SYSTEMROOT/system32/$DLL_NAME" 50279 50280 DLL_NAME="$DLL_NAME" 50281 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 50282 METHOD="well-known location in SYSTEMROOT" 50283 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 50284 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 50285 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 50286 50287 # Need to check if the found msvcr is correct architecture 50288 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 50289 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 50290 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 50291 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 50292 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 50293 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 50294 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 50295 CORRECT_MSVCR_ARCH="PE32 executable" 50296 else 50297 CORRECT_MSVCR_ARCH="PE32+ executable" 50298 fi 50299 else 50300 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 50301 CORRECT_MSVCR_ARCH=386 50302 else 50303 CORRECT_MSVCR_ARCH=x86-64 50304 fi 50305 fi 50306 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 50307 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 50308 $as_echo "ok" >&6; } 50309 MSVC_DLL="$POSSIBLE_MSVC_DLL" 50310 50311 # Only process if variable expands to non-empty 50312 50313 if test "x$MSVC_DLL" != x; then 50314 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 50315 50316 # Input might be given as Windows format, start by converting to 50317 # unix format. 50318 path="$MSVC_DLL" 50319 new_path=`$CYGPATH -u "$path"` 50320 50321 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 50322 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 50323 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 50324 # "foo.exe" is OK but "foo" is an error. 50325 # 50326 # This test is therefore slightly more accurate than "test -f" to check for file precense. 50327 # It is also a way to make sure we got the proper file name for the real test later on. 50328 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 50329 if test "x$test_shortpath" = x; then 50330 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 50331 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 50332 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 50333 fi 50334 50335 # Call helper function which possibly converts this using DOS-style short mode. 50336 # If so, the updated path is stored in $new_path. 50337 50338 input_path="$new_path" 50339 # Check if we need to convert this using DOS-style short mode. If the path 50340 # contains just simple characters, use it. Otherwise (spaces, weird characters), 50341 # take no chances and rewrite it. 50342 # Note: m4 eats our [], so we need to use [ and ] instead. 50343 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 50344 if test "x$has_forbidden_chars" != x; then 50345 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 50346 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 50347 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 50348 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 50349 # Going to short mode and back again did indeed matter. Since short mode is 50350 # case insensitive, let's make it lowercase to improve readability. 50351 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 50352 # Now convert it back to Unix-style (cygpath) 50353 input_path=`$CYGPATH -u "$shortmode_path"` 50354 new_path="$input_path" 50355 fi 50356 fi 50357 50358 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 50359 if test "x$test_cygdrive_prefix" = x; then 50360 # As a simple fix, exclude /usr/bin since it's not a real path. 50361 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 50362 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 50363 # a path prefixed by /cygdrive for fixpath to work. 50364 new_path="$CYGWIN_ROOT_PATH$input_path" 50365 fi 50366 fi 50367 50368 50369 if test "x$path" != "x$new_path"; then 50370 MSVC_DLL="$new_path" 50371 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 50372 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 50373 fi 50374 50375 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 50376 50377 path="$MSVC_DLL" 50378 has_colon=`$ECHO $path | $GREP ^.:` 50379 new_path="$path" 50380 if test "x$has_colon" = x; then 50381 # Not in mixed or Windows style, start by that. 50382 new_path=`cmd //c echo $path` 50383 fi 50384 50385 50386 input_path="$new_path" 50387 # Check if we need to convert this using DOS-style short mode. If the path 50388 # contains just simple characters, use it. Otherwise (spaces, weird characters), 50389 # take no chances and rewrite it. 50390 # Note: m4 eats our [], so we need to use [ and ] instead. 50391 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 50392 if test "x$has_forbidden_chars" != x; then 50393 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 50394 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 50395 fi 50396 50397 50398 windows_path="$new_path" 50399 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 50400 unix_path=`$CYGPATH -u "$windows_path"` 50401 new_path="$unix_path" 50402 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 50403 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 50404 new_path="$unix_path" 50405 fi 50406 50407 if test "x$path" != "x$new_path"; then 50408 MSVC_DLL="$new_path" 50409 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 50410 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 50411 fi 50412 50413 # Save the first 10 bytes of this path to the storage, so fixpath can work. 50414 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 50415 50416 else 50417 # We're on a unix platform. Hooray! :) 50418 path="$MSVC_DLL" 50419 has_space=`$ECHO "$path" | $GREP " "` 50420 if test "x$has_space" != x; then 50421 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 50422 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 50423 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 50424 fi 50425 50426 # Use eval to expand a potential ~ 50427 eval path="$path" 50428 if test ! -f "$path" && test ! -d "$path"; then 50429 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 50430 fi 50431 50432 if test -d "$path"; then 50433 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 50434 else 50435 dir="`$DIRNAME "$path"`" 50436 base="`$BASENAME "$path"`" 50437 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 50438 fi 50439 fi 50440 fi 50441 50442 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 50443 $as_echo_n "checking for $DLL_NAME... " >&6; } 50444 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 50445 $as_echo "$MSVC_DLL" >&6; } 50446 else 50447 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 50448 $as_echo "incorrect, ignoring" >&6; } 50449 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 50450 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 50451 fi 50452 fi 50453 50454 fi 50455 50456 if test "x$MSVC_DLL" = x; then 50457 # Probe: If Visual Studio Express is installed, there is usually one with the debugger 50458 if test "x$VS100COMNTOOLS" != x; then 50459 CYGWIN_VS_TOOLS_DIR="$VS100COMNTOOLS/.." 50460 50461 windows_path="$CYGWIN_VS_TOOLS_DIR" 50462 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 50463 unix_path=`$CYGPATH -u "$windows_path"` 50464 CYGWIN_VS_TOOLS_DIR="$unix_path" 50465 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 50466 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 50467 CYGWIN_VS_TOOLS_DIR="$unix_path" 50468 fi 50469 50470 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 50471 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name $DLL_NAME \ 50472 | $GREP -i /x64/ | $HEAD --lines 1` 50473 else 50474 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VS_TOOLS_DIR" -name $DLL_NAME \ 50475 | $GREP -i /x86/ | $HEAD --lines 1` 50476 fi 50477 50478 DLL_NAME="$DLL_NAME" 50479 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 50480 METHOD="search of VS100COMNTOOLS" 50481 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 50482 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 50483 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 50484 50485 # Need to check if the found msvcr is correct architecture 50486 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 50487 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 50488 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 50489 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 50490 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 50491 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 50492 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 50493 CORRECT_MSVCR_ARCH="PE32 executable" 50494 else 50495 CORRECT_MSVCR_ARCH="PE32+ executable" 50496 fi 50497 else 50498 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 50499 CORRECT_MSVCR_ARCH=386 50500 else 50501 CORRECT_MSVCR_ARCH=x86-64 50502 fi 50503 fi 50504 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 50505 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 50506 $as_echo "ok" >&6; } 50507 MSVC_DLL="$POSSIBLE_MSVC_DLL" 50508 50509 # Only process if variable expands to non-empty 50510 50511 if test "x$MSVC_DLL" != x; then 50512 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 50513 50514 # Input might be given as Windows format, start by converting to 50515 # unix format. 50516 path="$MSVC_DLL" 50517 new_path=`$CYGPATH -u "$path"` 50518 50519 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 50520 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 50521 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 50522 # "foo.exe" is OK but "foo" is an error. 50523 # 50524 # This test is therefore slightly more accurate than "test -f" to check for file precense. 50525 # It is also a way to make sure we got the proper file name for the real test later on. 50526 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 50527 if test "x$test_shortpath" = x; then 50528 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 50529 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 50530 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 50531 fi 50532 50533 # Call helper function which possibly converts this using DOS-style short mode. 50534 # If so, the updated path is stored in $new_path. 50535 50536 input_path="$new_path" 50537 # Check if we need to convert this using DOS-style short mode. If the path 50538 # contains just simple characters, use it. Otherwise (spaces, weird characters), 50539 # take no chances and rewrite it. 50540 # Note: m4 eats our [], so we need to use [ and ] instead. 50541 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 50542 if test "x$has_forbidden_chars" != x; then 50543 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 50544 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 50545 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 50546 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 50547 # Going to short mode and back again did indeed matter. Since short mode is 50548 # case insensitive, let's make it lowercase to improve readability. 50549 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 50550 # Now convert it back to Unix-style (cygpath) 50551 input_path=`$CYGPATH -u "$shortmode_path"` 50552 new_path="$input_path" 50553 fi 50554 fi 50555 50556 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 50557 if test "x$test_cygdrive_prefix" = x; then 50558 # As a simple fix, exclude /usr/bin since it's not a real path. 50559 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 50560 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 50561 # a path prefixed by /cygdrive for fixpath to work. 50562 new_path="$CYGWIN_ROOT_PATH$input_path" 50563 fi 50564 fi 50565 50566 50567 if test "x$path" != "x$new_path"; then 50568 MSVC_DLL="$new_path" 50569 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 50570 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 50571 fi 50572 50573 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 50574 50575 path="$MSVC_DLL" 50576 has_colon=`$ECHO $path | $GREP ^.:` 50577 new_path="$path" 50578 if test "x$has_colon" = x; then 50579 # Not in mixed or Windows style, start by that. 50580 new_path=`cmd //c echo $path` 50581 fi 50582 50583 50584 input_path="$new_path" 50585 # Check if we need to convert this using DOS-style short mode. If the path 50586 # contains just simple characters, use it. Otherwise (spaces, weird characters), 50587 # take no chances and rewrite it. 50588 # Note: m4 eats our [], so we need to use [ and ] instead. 50589 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 50590 if test "x$has_forbidden_chars" != x; then 50591 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 50592 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 50593 fi 50594 50595 50596 windows_path="$new_path" 50597 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 50598 unix_path=`$CYGPATH -u "$windows_path"` 50599 new_path="$unix_path" 50600 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 50601 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 50602 new_path="$unix_path" 50603 fi 50604 50605 if test "x$path" != "x$new_path"; then 50606 MSVC_DLL="$new_path" 50607 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 50608 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 50609 fi 50610 50611 # Save the first 10 bytes of this path to the storage, so fixpath can work. 50612 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 50613 50614 else 50615 # We're on a unix platform. Hooray! :) 50616 path="$MSVC_DLL" 50617 has_space=`$ECHO "$path" | $GREP " "` 50618 if test "x$has_space" != x; then 50619 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 50620 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 50621 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 50622 fi 50623 50624 # Use eval to expand a potential ~ 50625 eval path="$path" 50626 if test ! -f "$path" && test ! -d "$path"; then 50627 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 50628 fi 50629 50630 if test -d "$path"; then 50631 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 50632 else 50633 dir="`$DIRNAME "$path"`" 50634 base="`$BASENAME "$path"`" 50635 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 50636 fi 50637 fi 50638 fi 50639 50640 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 50641 $as_echo_n "checking for $DLL_NAME... " >&6; } 50642 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 50643 $as_echo "$MSVC_DLL" >&6; } 50644 else 50645 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 50646 $as_echo "incorrect, ignoring" >&6; } 50647 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 50648 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 50649 fi 50650 fi 50651 50652 fi 50653 fi 50654 50655 if test "x$MSVC_DLL" = x; then 50656 # Probe: Search wildly in the VCINSTALLDIR. We've probably lost by now. 50657 # (This was the original behaviour; kept since it might turn something up) 50658 if test "x$CYGWIN_VC_INSTALL_DIR" != x; then 50659 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 50660 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 50661 | $GREP x64 | $HEAD --lines 1` 50662 else 50663 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 50664 | $GREP x86 | $GREP -v ia64 | $GREP -v x64 | $HEAD --lines 1` 50665 if test "x$POSSIBLE_MSVC_DLL" = x; then 50666 # We're grasping at straws now... 50667 POSSIBLE_MSVC_DLL=`$FIND "$CYGWIN_VC_INSTALL_DIR" -name $DLL_NAME \ 50668 | $HEAD --lines 1` 50669 fi 50670 fi 50671 50672 50673 DLL_NAME="$DLL_NAME" 50674 POSSIBLE_MSVC_DLL="$POSSIBLE_MSVC_DLL" 50675 METHOD="search of VCINSTALLDIR" 50676 if test -n "$POSSIBLE_MSVC_DLL" -a -e "$POSSIBLE_MSVC_DLL"; then 50677 { $as_echo "$as_me:${as_lineno-$LINENO}: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&5 50678 $as_echo "$as_me: Found $DLL_NAME at $POSSIBLE_MSVC_DLL using $METHOD" >&6;} 50679 50680 # Need to check if the found msvcr is correct architecture 50681 { $as_echo "$as_me:${as_lineno-$LINENO}: checking found $DLL_NAME architecture" >&5 50682 $as_echo_n "checking found $DLL_NAME architecture... " >&6; } 50683 MSVC_DLL_FILETYPE=`$FILE -b "$POSSIBLE_MSVC_DLL"` 50684 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 50685 # The MSYS 'file' command returns "PE32 executable for MS Windows (DLL) (GUI) Intel 80386 32-bit" 50686 # on x32 and "PE32+ executable for MS Windows (DLL) (GUI) Mono/.Net assembly" on x64 systems. 50687 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 50688 CORRECT_MSVCR_ARCH="PE32 executable" 50689 else 50690 CORRECT_MSVCR_ARCH="PE32+ executable" 50691 fi 50692 else 50693 if test "x$OPENJDK_TARGET_CPU_BITS" = x32; then 50694 CORRECT_MSVCR_ARCH=386 50695 else 50696 CORRECT_MSVCR_ARCH=x86-64 50697 fi 50698 fi 50699 if $ECHO "$MSVC_DLL_FILETYPE" | $GREP "$CORRECT_MSVCR_ARCH" 2>&1 > /dev/null; then 50700 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ok" >&5 50701 $as_echo "ok" >&6; } 50702 MSVC_DLL="$POSSIBLE_MSVC_DLL" 50703 50704 # Only process if variable expands to non-empty 50705 50706 if test "x$MSVC_DLL" != x; then 50707 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 50708 50709 # Input might be given as Windows format, start by converting to 50710 # unix format. 50711 path="$MSVC_DLL" 50712 new_path=`$CYGPATH -u "$path"` 50713 50714 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 50715 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 50716 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 50717 # "foo.exe" is OK but "foo" is an error. 50718 # 50719 # This test is therefore slightly more accurate than "test -f" to check for file precense. 50720 # It is also a way to make sure we got the proper file name for the real test later on. 50721 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 50722 if test "x$test_shortpath" = x; then 50723 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 50724 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 50725 as_fn_error $? "Cannot locate the the path of MSVC_DLL" "$LINENO" 5 50726 fi 50727 50728 # Call helper function which possibly converts this using DOS-style short mode. 50729 # If so, the updated path is stored in $new_path. 50730 50731 input_path="$new_path" 50732 # Check if we need to convert this using DOS-style short mode. If the path 50733 # contains just simple characters, use it. Otherwise (spaces, weird characters), 50734 # take no chances and rewrite it. 50735 # Note: m4 eats our [], so we need to use [ and ] instead. 50736 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 50737 if test "x$has_forbidden_chars" != x; then 50738 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 50739 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 50740 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 50741 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 50742 # Going to short mode and back again did indeed matter. Since short mode is 50743 # case insensitive, let's make it lowercase to improve readability. 50744 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 50745 # Now convert it back to Unix-style (cygpath) 50746 input_path=`$CYGPATH -u "$shortmode_path"` 50747 new_path="$input_path" 50748 fi 50749 fi 50750 50751 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 50752 if test "x$test_cygdrive_prefix" = x; then 50753 # As a simple fix, exclude /usr/bin since it's not a real path. 50754 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 50755 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 50756 # a path prefixed by /cygdrive for fixpath to work. 50757 new_path="$CYGWIN_ROOT_PATH$input_path" 50758 fi 50759 fi 50760 50761 50762 if test "x$path" != "x$new_path"; then 50763 MSVC_DLL="$new_path" 50764 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 50765 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 50766 fi 50767 50768 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 50769 50770 path="$MSVC_DLL" 50771 has_colon=`$ECHO $path | $GREP ^.:` 50772 new_path="$path" 50773 if test "x$has_colon" = x; then 50774 # Not in mixed or Windows style, start by that. 50775 new_path=`cmd //c echo $path` 50776 fi 50777 50778 50779 input_path="$new_path" 50780 # Check if we need to convert this using DOS-style short mode. If the path 50781 # contains just simple characters, use it. Otherwise (spaces, weird characters), 50782 # take no chances and rewrite it. 50783 # Note: m4 eats our [], so we need to use [ and ] instead. 50784 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 50785 if test "x$has_forbidden_chars" != x; then 50786 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 50787 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 50788 fi 50789 50790 50791 windows_path="$new_path" 50792 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 50793 unix_path=`$CYGPATH -u "$windows_path"` 50794 new_path="$unix_path" 50795 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 50796 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 50797 new_path="$unix_path" 50798 fi 50799 50800 if test "x$path" != "x$new_path"; then 50801 MSVC_DLL="$new_path" 50802 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting MSVC_DLL to \"$new_path\"" >&5 50803 $as_echo "$as_me: Rewriting MSVC_DLL to \"$new_path\"" >&6;} 50804 fi 50805 50806 # Save the first 10 bytes of this path to the storage, so fixpath can work. 50807 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 50808 50809 else 50810 # We're on a unix platform. Hooray! :) 50811 path="$MSVC_DLL" 50812 has_space=`$ECHO "$path" | $GREP " "` 50813 if test "x$has_space" != x; then 50814 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&5 50815 $as_echo "$as_me: The path of MSVC_DLL, which resolves as \"$path\", is invalid." >&6;} 50816 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 50817 fi 50818 50819 # Use eval to expand a potential ~ 50820 eval path="$path" 50821 if test ! -f "$path" && test ! -d "$path"; then 50822 as_fn_error $? "The path of MSVC_DLL, which resolves as \"$path\", is not found." "$LINENO" 5 50823 fi 50824 50825 if test -d "$path"; then 50826 MSVC_DLL="`cd "$path"; $THEPWDCMD -L`" 50827 else 50828 dir="`$DIRNAME "$path"`" 50829 base="`$BASENAME "$path"`" 50830 MSVC_DLL="`cd "$dir"; $THEPWDCMD -L`/$base" 50831 fi 50832 fi 50833 fi 50834 50835 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 50836 $as_echo_n "checking for $DLL_NAME... " >&6; } 50837 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MSVC_DLL" >&5 50838 $as_echo "$MSVC_DLL" >&6; } 50839 else 50840 { $as_echo "$as_me:${as_lineno-$LINENO}: result: incorrect, ignoring" >&5 50841 $as_echo "incorrect, ignoring" >&6; } 50842 { $as_echo "$as_me:${as_lineno-$LINENO}: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&5 50843 $as_echo "$as_me: The file type of the located $DLL_NAME is $MSVC_DLL_FILETYPE" >&6;} 50844 fi 50845 fi 50846 50847 fi 50848 fi 50849 50850 if test "x$MSVC_DLL" = x; then 50851 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $DLL_NAME" >&5 50852 $as_echo_n "checking for $DLL_NAME... " >&6; } 50853 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 50854 $as_echo "no" >&6; } 50855 as_fn_error $? "Could not find $DLL_NAME. Please specify using --with-msvcr-dll." "$LINENO" 5 50856 fi 50857 50858 MSVCP_DLL="$MSVC_DLL" 50859 fi 50860 50861 fi 50862 50863 fi 50864 50865 50866 if test "x$NEEDS_LIB_X11" = xfalse; then 50867 if (test "x${with_x}" != x && test "x${with_x}" != xno); then 50868 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: X11 is not used, so --with-x is ignored" >&5 50869 $as_echo "$as_me: WARNING: X11 is not used, so --with-x is ignored" >&2;} 50870 fi 50871 X_CFLAGS= 50872 X_LIBS= 50873 else 50874 50875 if test "x${with_x}" = xno; then 50876 as_fn_error $? "It is not possible to disable the use of X11. Remove the --without-x option." "$LINENO" 5 50877 fi 50878 50879 if test "x${with_x}" != x && test "x${with_x}" != xyes; then 50880 # The user has specified a X11 base directory. Use it for includes and 50881 # libraries, unless explicitely overridden. 50882 if test "x$x_includes" = xNONE; then 50883 x_includes="${with_x}/include" 50884 fi 50885 if test "x$x_libraries" = xNONE; then 50886 x_libraries="${with_x}/lib" 50887 fi 50888 else 50889 # Check if the user has specified sysroot, but not --with-x, --x-includes or --x-libraries. 50890 # Make a simple check for the libraries at the sysroot, and setup --x-includes and 50891 # --x-libraries for the sysroot, if that seems to be correct. 50892 if test "x$SYSROOT" != "x"; then 50893 if test "x$x_includes" = xNONE; then 50894 if test -f "$SYSROOT/usr/X11R6/include/X11/Xlib.h"; then 50895 x_includes="$SYSROOT/usr/X11R6/include" 50896 elif test -f "$SYSROOT/usr/include/X11/Xlib.h"; then 50897 x_includes="$SYSROOT/usr/include" 50898 fi 50899 fi 50900 if test "x$x_libraries" = xNONE; then 50901 if test -f "$SYSROOT/usr/X11R6/lib/libX11.so"; then 50902 x_libraries="$SYSROOT/usr/X11R6/lib" 50903 elif test -f "$SYSROOT/usr/lib64/libX11.so" && test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 50904 x_libraries="$SYSROOT/usr/lib64" 50905 elif test -f "$SYSROOT/usr/lib/libX11.so"; then 50906 x_libraries="$SYSROOT/usr/lib" 50907 fi 50908 fi 50909 fi 50910 fi 50911 50912 # Now let autoconf do it's magic 50913 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5 50914 $as_echo_n "checking for X... " >&6; } 50915 50916 50917 # Check whether --with-x was given. 50918 if test "${with_x+set}" = set; then : 50919 withval=$with_x; 50920 fi 50921 50922 # $have_x is `yes', `no', `disabled', or empty when we do not yet know. 50923 if test "x$with_x" = xno; then 50924 # The user explicitly disabled X. 50925 have_x=disabled 50926 else 50927 case $x_includes,$x_libraries in #( 50928 *\'*) as_fn_error $? "cannot use X directory names containing '" "$LINENO" 5;; #( 50929 *,NONE | NONE,*) if ${ac_cv_have_x+:} false; then : 50930 $as_echo_n "(cached) " >&6 50931 else 50932 # One or both of the vars are not set, and there is no cached value. 50933 ac_x_includes=no ac_x_libraries=no 50934 rm -f -r conftest.dir 50935 if mkdir conftest.dir; then 50936 cd conftest.dir 50937 cat >Imakefile <<'_ACEOF' 50938 incroot: 50939 @echo incroot='${INCROOT}' 50940 usrlibdir: 50941 @echo usrlibdir='${USRLIBDIR}' 50942 libdir: 50943 @echo libdir='${LIBDIR}' 50944 _ACEOF 50945 if (export CC; ${XMKMF-xmkmf}) >/dev/null 2>/dev/null && test -f Makefile; then 50946 # GNU make sometimes prints "make[1]: Entering ...", which would confuse us. 50947 for ac_var in incroot usrlibdir libdir; do 50948 eval "ac_im_$ac_var=\`\${MAKE-make} $ac_var 2>/dev/null | sed -n 's/^$ac_var=//p'\`" 50949 done 50950 # Open Windows xmkmf reportedly sets LIBDIR instead of USRLIBDIR. 50951 for ac_extension in a so sl dylib la dll; do 50952 if test ! -f "$ac_im_usrlibdir/libX11.$ac_extension" && 50953 test -f "$ac_im_libdir/libX11.$ac_extension"; then 50954 ac_im_usrlibdir=$ac_im_libdir; break 50955 fi 50956 done 50957 # Screen out bogus values from the imake configuration. They are 50958 # bogus both because they are the default anyway, and because 50959 # using them would break gcc on systems where it needs fixed includes. 50960 case $ac_im_incroot in 50961 /usr/include) ac_x_includes= ;; 50962 *) test -f "$ac_im_incroot/X11/Xos.h" && ac_x_includes=$ac_im_incroot;; 50963 esac 50964 case $ac_im_usrlibdir in 50965 /usr/lib | /usr/lib64 | /lib | /lib64) ;; 50966 *) test -d "$ac_im_usrlibdir" && ac_x_libraries=$ac_im_usrlibdir ;; 50967 esac 50968 fi 50969 cd .. 50970 rm -f -r conftest.dir 50971 fi 50972 50973 # Standard set of common directories for X headers. 50974 # Check X11 before X11Rn because it is often a symlink to the current release. 50975 ac_x_header_dirs=' 50976 /usr/X11/include 50977 /usr/X11R7/include 50978 /usr/X11R6/include 50979 /usr/X11R5/include 50980 /usr/X11R4/include 50981 50982 /usr/include/X11 50983 /usr/include/X11R7 50984 /usr/include/X11R6 50985 /usr/include/X11R5 50986 /usr/include/X11R4 50987 50988 /usr/local/X11/include 50989 /usr/local/X11R7/include 50990 /usr/local/X11R6/include 50991 /usr/local/X11R5/include 50992 /usr/local/X11R4/include 50993 50994 /usr/local/include/X11 50995 /usr/local/include/X11R7 50996 /usr/local/include/X11R6 50997 /usr/local/include/X11R5 50998 /usr/local/include/X11R4 50999 51000 /usr/X386/include 51001 /usr/x386/include 51002 /usr/XFree86/include/X11 51003 51004 /usr/include 51005 /usr/local/include 51006 /usr/unsupported/include 51007 /usr/athena/include 51008 /usr/local/x11r5/include 51009 /usr/lpp/Xamples/include 51010 51011 /usr/openwin/include 51012 /usr/openwin/share/include' 51013 51014 if test "$ac_x_includes" = no; then 51015 # Guess where to find include files, by looking for Xlib.h. 51016 # First, try using that file with no special directory specified. 51017 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51018 /* end confdefs.h. */ 51019 #include <X11/Xlib.h> 51020 _ACEOF 51021 if ac_fn_cxx_try_cpp "$LINENO"; then : 51022 # We can compile using X headers with no special include directory. 51023 ac_x_includes= 51024 else 51025 for ac_dir in $ac_x_header_dirs; do 51026 if test -r "$ac_dir/X11/Xlib.h"; then 51027 ac_x_includes=$ac_dir 51028 break 51029 fi 51030 done 51031 fi 51032 rm -f conftest.err conftest.i conftest.$ac_ext 51033 fi # $ac_x_includes = no 51034 51035 if test "$ac_x_libraries" = no; then 51036 # Check for the libraries. 51037 # See if we find them without any special options. 51038 # Don't add to $LIBS permanently. 51039 ac_save_LIBS=$LIBS 51040 LIBS="-lX11 $LIBS" 51041 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51042 /* end confdefs.h. */ 51043 #include <X11/Xlib.h> 51044 int 51045 main () 51046 { 51047 XrmInitialize () 51048 ; 51049 return 0; 51050 } 51051 _ACEOF 51052 if ac_fn_cxx_try_link "$LINENO"; then : 51053 LIBS=$ac_save_LIBS 51054 # We can link X programs with no special library path. 51055 ac_x_libraries= 51056 else 51057 LIBS=$ac_save_LIBS 51058 for ac_dir in `$as_echo "$ac_x_includes $ac_x_header_dirs" | sed s/include/lib/g` 51059 do 51060 # Don't even attempt the hair of trying to link an X program! 51061 for ac_extension in a so sl dylib la dll; do 51062 if test -r "$ac_dir/libX11.$ac_extension"; then 51063 ac_x_libraries=$ac_dir 51064 break 2 51065 fi 51066 done 51067 done 51068 fi 51069 rm -f core conftest.err conftest.$ac_objext \ 51070 conftest$ac_exeext conftest.$ac_ext 51071 fi # $ac_x_libraries = no 51072 51073 case $ac_x_includes,$ac_x_libraries in #( 51074 no,* | *,no | *\'*) 51075 # Didn't find X, or a directory has "'" in its name. 51076 ac_cv_have_x="have_x=no";; #( 51077 *) 51078 # Record where we found X for the cache. 51079 ac_cv_have_x="have_x=yes\ 51080 ac_x_includes='$ac_x_includes'\ 51081 ac_x_libraries='$ac_x_libraries'" 51082 esac 51083 fi 51084 ;; #( 51085 *) have_x=yes;; 51086 esac 51087 eval "$ac_cv_have_x" 51088 fi # $with_x != no 51089 51090 if test "$have_x" != yes; then 51091 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $have_x" >&5 51092 $as_echo "$have_x" >&6; } 51093 no_x=yes 51094 else 51095 # If each of the values was on the command line, it overrides each guess. 51096 test "x$x_includes" = xNONE && x_includes=$ac_x_includes 51097 test "x$x_libraries" = xNONE && x_libraries=$ac_x_libraries 51098 # Update the cache value to reflect the command line values. 51099 ac_cv_have_x="have_x=yes\ 51100 ac_x_includes='$x_includes'\ 51101 ac_x_libraries='$x_libraries'" 51102 { $as_echo "$as_me:${as_lineno-$LINENO}: result: libraries $x_libraries, headers $x_includes" >&5 51103 $as_echo "libraries $x_libraries, headers $x_includes" >&6; } 51104 fi 51105 51106 if test "$no_x" = yes; then 51107 # Not all programs may use this symbol, but it does not hurt to define it. 51108 51109 $as_echo "#define X_DISPLAY_MISSING 1" >>confdefs.h 51110 51111 X_CFLAGS= X_PRE_LIBS= X_LIBS= X_EXTRA_LIBS= 51112 else 51113 if test -n "$x_includes"; then 51114 X_CFLAGS="$X_CFLAGS -I$x_includes" 51115 fi 51116 51117 # It would also be nice to do this for all -L options, not just this one. 51118 if test -n "$x_libraries"; then 51119 X_LIBS="$X_LIBS -L$x_libraries" 51120 # For Solaris; some versions of Sun CC require a space after -R and 51121 # others require no space. Words are not sufficient . . . . 51122 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether -R must be followed by a space" >&5 51123 $as_echo_n "checking whether -R must be followed by a space... " >&6; } 51124 ac_xsave_LIBS=$LIBS; LIBS="$LIBS -R$x_libraries" 51125 ac_xsave_cxx_werror_flag=$ac_cxx_werror_flag 51126 ac_cxx_werror_flag=yes 51127 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51128 /* end confdefs.h. */ 51129 51130 int 51131 main () 51132 { 51133 51134 ; 51135 return 0; 51136 } 51137 _ACEOF 51138 if ac_fn_cxx_try_link "$LINENO"; then : 51139 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 51140 $as_echo "no" >&6; } 51141 X_LIBS="$X_LIBS -R$x_libraries" 51142 else 51143 LIBS="$ac_xsave_LIBS -R $x_libraries" 51144 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51145 /* end confdefs.h. */ 51146 51147 int 51148 main () 51149 { 51150 51151 ; 51152 return 0; 51153 } 51154 _ACEOF 51155 if ac_fn_cxx_try_link "$LINENO"; then : 51156 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 51157 $as_echo "yes" >&6; } 51158 X_LIBS="$X_LIBS -R $x_libraries" 51159 else 51160 { $as_echo "$as_me:${as_lineno-$LINENO}: result: neither works" >&5 51161 $as_echo "neither works" >&6; } 51162 fi 51163 rm -f core conftest.err conftest.$ac_objext \ 51164 conftest$ac_exeext conftest.$ac_ext 51165 fi 51166 rm -f core conftest.err conftest.$ac_objext \ 51167 conftest$ac_exeext conftest.$ac_ext 51168 ac_cxx_werror_flag=$ac_xsave_cxx_werror_flag 51169 LIBS=$ac_xsave_LIBS 51170 fi 51171 51172 # Check for system-dependent libraries X programs must link with. 51173 # Do this before checking for the system-independent R6 libraries 51174 # (-lICE), since we may need -lsocket or whatever for X linking. 51175 51176 if test "$ISC" = yes; then 51177 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl_s -linet" 51178 else 51179 # Martyn Johnson says this is needed for Ultrix, if the X 51180 # libraries were built with DECnet support. And Karl Berry says 51181 # the Alpha needs dnet_stub (dnet does not exist). 51182 ac_xsave_LIBS="$LIBS"; LIBS="$LIBS $X_LIBS -lX11" 51183 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51184 /* end confdefs.h. */ 51185 51186 /* Override any GCC internal prototype to avoid an error. 51187 Use char because int might match the return type of a GCC 51188 builtin and then its argument prototype would still apply. */ 51189 #ifdef __cplusplus 51190 extern "C" 51191 #endif 51192 char XOpenDisplay (); 51193 int 51194 main () 51195 { 51196 return XOpenDisplay (); 51197 ; 51198 return 0; 51199 } 51200 _ACEOF 51201 if ac_fn_cxx_try_link "$LINENO"; then : 51202 51203 else 51204 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet" >&5 51205 $as_echo_n "checking for dnet_ntoa in -ldnet... " >&6; } 51206 if ${ac_cv_lib_dnet_dnet_ntoa+:} false; then : 51207 $as_echo_n "(cached) " >&6 51208 else 51209 ac_check_lib_save_LIBS=$LIBS 51210 LIBS="-ldnet $LIBS" 51211 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51212 /* end confdefs.h. */ 51213 51214 /* Override any GCC internal prototype to avoid an error. 51215 Use char because int might match the return type of a GCC 51216 builtin and then its argument prototype would still apply. */ 51217 #ifdef __cplusplus 51218 extern "C" 51219 #endif 51220 char dnet_ntoa (); 51221 int 51222 main () 51223 { 51224 return dnet_ntoa (); 51225 ; 51226 return 0; 51227 } 51228 _ACEOF 51229 if ac_fn_cxx_try_link "$LINENO"; then : 51230 ac_cv_lib_dnet_dnet_ntoa=yes 51231 else 51232 ac_cv_lib_dnet_dnet_ntoa=no 51233 fi 51234 rm -f core conftest.err conftest.$ac_objext \ 51235 conftest$ac_exeext conftest.$ac_ext 51236 LIBS=$ac_check_lib_save_LIBS 51237 fi 51238 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_dnet_ntoa" >&5 51239 $as_echo "$ac_cv_lib_dnet_dnet_ntoa" >&6; } 51240 if test "x$ac_cv_lib_dnet_dnet_ntoa" = xyes; then : 51241 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet" 51242 fi 51243 51244 if test $ac_cv_lib_dnet_dnet_ntoa = no; then 51245 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dnet_ntoa in -ldnet_stub" >&5 51246 $as_echo_n "checking for dnet_ntoa in -ldnet_stub... " >&6; } 51247 if ${ac_cv_lib_dnet_stub_dnet_ntoa+:} false; then : 51248 $as_echo_n "(cached) " >&6 51249 else 51250 ac_check_lib_save_LIBS=$LIBS 51251 LIBS="-ldnet_stub $LIBS" 51252 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51253 /* end confdefs.h. */ 51254 51255 /* Override any GCC internal prototype to avoid an error. 51256 Use char because int might match the return type of a GCC 51257 builtin and then its argument prototype would still apply. */ 51258 #ifdef __cplusplus 51259 extern "C" 51260 #endif 51261 char dnet_ntoa (); 51262 int 51263 main () 51264 { 51265 return dnet_ntoa (); 51266 ; 51267 return 0; 51268 } 51269 _ACEOF 51270 if ac_fn_cxx_try_link "$LINENO"; then : 51271 ac_cv_lib_dnet_stub_dnet_ntoa=yes 51272 else 51273 ac_cv_lib_dnet_stub_dnet_ntoa=no 51274 fi 51275 rm -f core conftest.err conftest.$ac_objext \ 51276 conftest$ac_exeext conftest.$ac_ext 51277 LIBS=$ac_check_lib_save_LIBS 51278 fi 51279 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dnet_stub_dnet_ntoa" >&5 51280 $as_echo "$ac_cv_lib_dnet_stub_dnet_ntoa" >&6; } 51281 if test "x$ac_cv_lib_dnet_stub_dnet_ntoa" = xyes; then : 51282 X_EXTRA_LIBS="$X_EXTRA_LIBS -ldnet_stub" 51283 fi 51284 51285 fi 51286 fi 51287 rm -f core conftest.err conftest.$ac_objext \ 51288 conftest$ac_exeext conftest.$ac_ext 51289 LIBS="$ac_xsave_LIBS" 51290 51291 # msh@cis.ufl.edu says -lnsl (and -lsocket) are needed for his 386/AT, 51292 # to get the SysV transport functions. 51293 # Chad R. Larson says the Pyramis MIS-ES running DC/OSx (SVR4) 51294 # needs -lnsl. 51295 # The nsl library prevents programs from opening the X display 51296 # on Irix 5.2, according to T.E. Dickey. 51297 # The functions gethostbyname, getservbyname, and inet_addr are 51298 # in -lbsd on LynxOS 3.0.1/i386, according to Lars Hecking. 51299 ac_fn_cxx_check_func "$LINENO" "gethostbyname" "ac_cv_func_gethostbyname" 51300 if test "x$ac_cv_func_gethostbyname" = xyes; then : 51301 51302 fi 51303 51304 if test $ac_cv_func_gethostbyname = no; then 51305 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lnsl" >&5 51306 $as_echo_n "checking for gethostbyname in -lnsl... " >&6; } 51307 if ${ac_cv_lib_nsl_gethostbyname+:} false; then : 51308 $as_echo_n "(cached) " >&6 51309 else 51310 ac_check_lib_save_LIBS=$LIBS 51311 LIBS="-lnsl $LIBS" 51312 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51313 /* end confdefs.h. */ 51314 51315 /* Override any GCC internal prototype to avoid an error. 51316 Use char because int might match the return type of a GCC 51317 builtin and then its argument prototype would still apply. */ 51318 #ifdef __cplusplus 51319 extern "C" 51320 #endif 51321 char gethostbyname (); 51322 int 51323 main () 51324 { 51325 return gethostbyname (); 51326 ; 51327 return 0; 51328 } 51329 _ACEOF 51330 if ac_fn_cxx_try_link "$LINENO"; then : 51331 ac_cv_lib_nsl_gethostbyname=yes 51332 else 51333 ac_cv_lib_nsl_gethostbyname=no 51334 fi 51335 rm -f core conftest.err conftest.$ac_objext \ 51336 conftest$ac_exeext conftest.$ac_ext 51337 LIBS=$ac_check_lib_save_LIBS 51338 fi 51339 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_nsl_gethostbyname" >&5 51340 $as_echo "$ac_cv_lib_nsl_gethostbyname" >&6; } 51341 if test "x$ac_cv_lib_nsl_gethostbyname" = xyes; then : 51342 X_EXTRA_LIBS="$X_EXTRA_LIBS -lnsl" 51343 fi 51344 51345 if test $ac_cv_lib_nsl_gethostbyname = no; then 51346 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for gethostbyname in -lbsd" >&5 51347 $as_echo_n "checking for gethostbyname in -lbsd... " >&6; } 51348 if ${ac_cv_lib_bsd_gethostbyname+:} false; then : 51349 $as_echo_n "(cached) " >&6 51350 else 51351 ac_check_lib_save_LIBS=$LIBS 51352 LIBS="-lbsd $LIBS" 51353 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51354 /* end confdefs.h. */ 51355 51356 /* Override any GCC internal prototype to avoid an error. 51357 Use char because int might match the return type of a GCC 51358 builtin and then its argument prototype would still apply. */ 51359 #ifdef __cplusplus 51360 extern "C" 51361 #endif 51362 char gethostbyname (); 51363 int 51364 main () 51365 { 51366 return gethostbyname (); 51367 ; 51368 return 0; 51369 } 51370 _ACEOF 51371 if ac_fn_cxx_try_link "$LINENO"; then : 51372 ac_cv_lib_bsd_gethostbyname=yes 51373 else 51374 ac_cv_lib_bsd_gethostbyname=no 51375 fi 51376 rm -f core conftest.err conftest.$ac_objext \ 51377 conftest$ac_exeext conftest.$ac_ext 51378 LIBS=$ac_check_lib_save_LIBS 51379 fi 51380 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_bsd_gethostbyname" >&5 51381 $as_echo "$ac_cv_lib_bsd_gethostbyname" >&6; } 51382 if test "x$ac_cv_lib_bsd_gethostbyname" = xyes; then : 51383 X_EXTRA_LIBS="$X_EXTRA_LIBS -lbsd" 51384 fi 51385 51386 fi 51387 fi 51388 51389 # lieder@skyler.mavd.honeywell.com says without -lsocket, 51390 # socket/setsockopt and other routines are undefined under SCO ODT 51391 # 2.0. But -lsocket is broken on IRIX 5.2 (and is not necessary 51392 # on later versions), says Simon Leinen: it contains gethostby* 51393 # variants that don't use the name server (or something). -lsocket 51394 # must be given before -lnsl if both are needed. We assume that 51395 # if connect needs -lnsl, so does gethostbyname. 51396 ac_fn_cxx_check_func "$LINENO" "connect" "ac_cv_func_connect" 51397 if test "x$ac_cv_func_connect" = xyes; then : 51398 51399 fi 51400 51401 if test $ac_cv_func_connect = no; then 51402 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for connect in -lsocket" >&5 51403 $as_echo_n "checking for connect in -lsocket... " >&6; } 51404 if ${ac_cv_lib_socket_connect+:} false; then : 51405 $as_echo_n "(cached) " >&6 51406 else 51407 ac_check_lib_save_LIBS=$LIBS 51408 LIBS="-lsocket $X_EXTRA_LIBS $LIBS" 51409 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51410 /* end confdefs.h. */ 51411 51412 /* Override any GCC internal prototype to avoid an error. 51413 Use char because int might match the return type of a GCC 51414 builtin and then its argument prototype would still apply. */ 51415 #ifdef __cplusplus 51416 extern "C" 51417 #endif 51418 char connect (); 51419 int 51420 main () 51421 { 51422 return connect (); 51423 ; 51424 return 0; 51425 } 51426 _ACEOF 51427 if ac_fn_cxx_try_link "$LINENO"; then : 51428 ac_cv_lib_socket_connect=yes 51429 else 51430 ac_cv_lib_socket_connect=no 51431 fi 51432 rm -f core conftest.err conftest.$ac_objext \ 51433 conftest$ac_exeext conftest.$ac_ext 51434 LIBS=$ac_check_lib_save_LIBS 51435 fi 51436 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_socket_connect" >&5 51437 $as_echo "$ac_cv_lib_socket_connect" >&6; } 51438 if test "x$ac_cv_lib_socket_connect" = xyes; then : 51439 X_EXTRA_LIBS="-lsocket $X_EXTRA_LIBS" 51440 fi 51441 51442 fi 51443 51444 # Guillermo Gomez says -lposix is necessary on A/UX. 51445 ac_fn_cxx_check_func "$LINENO" "remove" "ac_cv_func_remove" 51446 if test "x$ac_cv_func_remove" = xyes; then : 51447 51448 fi 51449 51450 if test $ac_cv_func_remove = no; then 51451 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for remove in -lposix" >&5 51452 $as_echo_n "checking for remove in -lposix... " >&6; } 51453 if ${ac_cv_lib_posix_remove+:} false; then : 51454 $as_echo_n "(cached) " >&6 51455 else 51456 ac_check_lib_save_LIBS=$LIBS 51457 LIBS="-lposix $LIBS" 51458 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51459 /* end confdefs.h. */ 51460 51461 /* Override any GCC internal prototype to avoid an error. 51462 Use char because int might match the return type of a GCC 51463 builtin and then its argument prototype would still apply. */ 51464 #ifdef __cplusplus 51465 extern "C" 51466 #endif 51467 char remove (); 51468 int 51469 main () 51470 { 51471 return remove (); 51472 ; 51473 return 0; 51474 } 51475 _ACEOF 51476 if ac_fn_cxx_try_link "$LINENO"; then : 51477 ac_cv_lib_posix_remove=yes 51478 else 51479 ac_cv_lib_posix_remove=no 51480 fi 51481 rm -f core conftest.err conftest.$ac_objext \ 51482 conftest$ac_exeext conftest.$ac_ext 51483 LIBS=$ac_check_lib_save_LIBS 51484 fi 51485 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_posix_remove" >&5 51486 $as_echo "$ac_cv_lib_posix_remove" >&6; } 51487 if test "x$ac_cv_lib_posix_remove" = xyes; then : 51488 X_EXTRA_LIBS="$X_EXTRA_LIBS -lposix" 51489 fi 51490 51491 fi 51492 51493 # BSDI BSD/OS 2.1 needs -lipc for XOpenDisplay. 51494 ac_fn_cxx_check_func "$LINENO" "shmat" "ac_cv_func_shmat" 51495 if test "x$ac_cv_func_shmat" = xyes; then : 51496 51497 fi 51498 51499 if test $ac_cv_func_shmat = no; then 51500 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for shmat in -lipc" >&5 51501 $as_echo_n "checking for shmat in -lipc... " >&6; } 51502 if ${ac_cv_lib_ipc_shmat+:} false; then : 51503 $as_echo_n "(cached) " >&6 51504 else 51505 ac_check_lib_save_LIBS=$LIBS 51506 LIBS="-lipc $LIBS" 51507 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51508 /* end confdefs.h. */ 51509 51510 /* Override any GCC internal prototype to avoid an error. 51511 Use char because int might match the return type of a GCC 51512 builtin and then its argument prototype would still apply. */ 51513 #ifdef __cplusplus 51514 extern "C" 51515 #endif 51516 char shmat (); 51517 int 51518 main () 51519 { 51520 return shmat (); 51521 ; 51522 return 0; 51523 } 51524 _ACEOF 51525 if ac_fn_cxx_try_link "$LINENO"; then : 51526 ac_cv_lib_ipc_shmat=yes 51527 else 51528 ac_cv_lib_ipc_shmat=no 51529 fi 51530 rm -f core conftest.err conftest.$ac_objext \ 51531 conftest$ac_exeext conftest.$ac_ext 51532 LIBS=$ac_check_lib_save_LIBS 51533 fi 51534 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ipc_shmat" >&5 51535 $as_echo "$ac_cv_lib_ipc_shmat" >&6; } 51536 if test "x$ac_cv_lib_ipc_shmat" = xyes; then : 51537 X_EXTRA_LIBS="$X_EXTRA_LIBS -lipc" 51538 fi 51539 51540 fi 51541 fi 51542 51543 # Check for libraries that X11R6 Xt/Xaw programs need. 51544 ac_save_LDFLAGS=$LDFLAGS 51545 test -n "$x_libraries" && LDFLAGS="$LDFLAGS -L$x_libraries" 51546 # SM needs ICE to (dynamically) link under SunOS 4.x (so we have to 51547 # check for ICE first), but we must link in the order -lSM -lICE or 51548 # we get undefined symbols. So assume we have SM if we have ICE. 51549 # These have to be linked with before -lX11, unlike the other 51550 # libraries we check for below, so use a different variable. 51551 # John Interrante, Karl Berry 51552 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for IceConnectionNumber in -lICE" >&5 51553 $as_echo_n "checking for IceConnectionNumber in -lICE... " >&6; } 51554 if ${ac_cv_lib_ICE_IceConnectionNumber+:} false; then : 51555 $as_echo_n "(cached) " >&6 51556 else 51557 ac_check_lib_save_LIBS=$LIBS 51558 LIBS="-lICE $X_EXTRA_LIBS $LIBS" 51559 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51560 /* end confdefs.h. */ 51561 51562 /* Override any GCC internal prototype to avoid an error. 51563 Use char because int might match the return type of a GCC 51564 builtin and then its argument prototype would still apply. */ 51565 #ifdef __cplusplus 51566 extern "C" 51567 #endif 51568 char IceConnectionNumber (); 51569 int 51570 main () 51571 { 51572 return IceConnectionNumber (); 51573 ; 51574 return 0; 51575 } 51576 _ACEOF 51577 if ac_fn_cxx_try_link "$LINENO"; then : 51578 ac_cv_lib_ICE_IceConnectionNumber=yes 51579 else 51580 ac_cv_lib_ICE_IceConnectionNumber=no 51581 fi 51582 rm -f core conftest.err conftest.$ac_objext \ 51583 conftest$ac_exeext conftest.$ac_ext 51584 LIBS=$ac_check_lib_save_LIBS 51585 fi 51586 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_ICE_IceConnectionNumber" >&5 51587 $as_echo "$ac_cv_lib_ICE_IceConnectionNumber" >&6; } 51588 if test "x$ac_cv_lib_ICE_IceConnectionNumber" = xyes; then : 51589 X_PRE_LIBS="$X_PRE_LIBS -lSM -lICE" 51590 fi 51591 51592 LDFLAGS=$ac_save_LDFLAGS 51593 51594 fi 51595 51596 51597 # AC_PATH_XTRA creates X_LIBS and sometimes adds -R flags. When cross compiling 51598 # this doesn't make sense so we remove it. 51599 if test "x$COMPILE_TYPE" = xcross; then 51600 X_LIBS=`$ECHO $X_LIBS | $SED 's/-R \{0,1\}[^ ]*//g'` 51601 fi 51602 51603 if test "x$no_x" = xyes; then 51604 51605 # Print a helpful message on how to acquire the necessary build dependency. 51606 # x11 is the help tag: freetype, cups, alsa etc 51607 MISSING_DEPENDENCY=x11 51608 51609 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 51610 cygwin_help $MISSING_DEPENDENCY 51611 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 51612 msys_help $MISSING_DEPENDENCY 51613 else 51614 PKGHANDLER_COMMAND= 51615 51616 case $PKGHANDLER in 51617 apt-get) 51618 apt_help $MISSING_DEPENDENCY ;; 51619 yum) 51620 yum_help $MISSING_DEPENDENCY ;; 51621 port) 51622 port_help $MISSING_DEPENDENCY ;; 51623 pkgutil) 51624 pkgutil_help $MISSING_DEPENDENCY ;; 51625 pkgadd) 51626 pkgadd_help $MISSING_DEPENDENCY ;; 51627 esac 51628 51629 if test "x$PKGHANDLER_COMMAND" != x; then 51630 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 51631 fi 51632 fi 51633 51634 as_fn_error $? "Could not find X11 libraries. $HELP_MSG" "$LINENO" 5 51635 fi 51636 51637 if test "x$OPENJDK_TARGET_OS" = xsolaris; then 51638 OPENWIN_HOME="/usr/openwin" 51639 X_CFLAGS="-I$SYSROOT$OPENWIN_HOME/include -I$SYSROOT$OPENWIN_HOME/include/X11/extensions" 51640 X_LIBS="-L$SYSROOT$OPENWIN_HOME/sfw/lib$OPENJDK_TARGET_CPU_ISADIR \ 51641 -L$SYSROOT$OPENWIN_HOME/lib$OPENJDK_TARGET_CPU_ISADIR \ 51642 -R$OPENWIN_HOME/sfw/lib$OPENJDK_TARGET_CPU_ISADIR \ 51643 -R$OPENWIN_HOME/lib$OPENJDK_TARGET_CPU_ISADIR" 51644 fi 51645 51646 ac_ext=c 51647 ac_cpp='$CPP $CPPFLAGS' 51648 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51649 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51650 ac_compiler_gnu=$ac_cv_c_compiler_gnu 51651 51652 OLD_CFLAGS="$CFLAGS" 51653 CFLAGS="$CFLAGS $SYSROOT_CFLAGS $X_CFLAGS" 51654 51655 # Need to include Xlib.h and Xutil.h to avoid "present but cannot be compiled" warnings on Solaris 10 51656 for ac_header in X11/extensions/shape.h X11/extensions/Xrender.h X11/extensions/XTest.h X11/Intrinsic.h 51657 do : 51658 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` 51659 ac_fn_c_check_header_compile "$LINENO" "$ac_header" "$as_ac_Header" " 51660 # include <X11/Xlib.h> 51661 # include <X11/Xutil.h> 51662 51663 51664 " 51665 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : 51666 cat >>confdefs.h <<_ACEOF 51667 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 51668 _ACEOF 51669 X11_HEADERS_OK=yes 51670 else 51671 X11_HEADERS_OK=no; break 51672 fi 51673 51674 done 51675 51676 51677 if test "x$X11_HEADERS_OK" = xno; then 51678 51679 # Print a helpful message on how to acquire the necessary build dependency. 51680 # x11 is the help tag: freetype, cups, alsa etc 51681 MISSING_DEPENDENCY=x11 51682 51683 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 51684 cygwin_help $MISSING_DEPENDENCY 51685 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 51686 msys_help $MISSING_DEPENDENCY 51687 else 51688 PKGHANDLER_COMMAND= 51689 51690 case $PKGHANDLER in 51691 apt-get) 51692 apt_help $MISSING_DEPENDENCY ;; 51693 yum) 51694 yum_help $MISSING_DEPENDENCY ;; 51695 port) 51696 port_help $MISSING_DEPENDENCY ;; 51697 pkgutil) 51698 pkgutil_help $MISSING_DEPENDENCY ;; 51699 pkgadd) 51700 pkgadd_help $MISSING_DEPENDENCY ;; 51701 esac 51702 51703 if test "x$PKGHANDLER_COMMAND" != x; then 51704 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 51705 fi 51706 fi 51707 51708 as_fn_error $? "Could not find all X11 headers (shape.h Xrender.h XTest.h Intrinsic.h). $HELP_MSG" "$LINENO" 5 51709 fi 51710 51711 # If XLinearGradient isn't available in Xrender.h, signal that it needs to be 51712 # defined in libawt_xawt. 51713 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if XlinearGradient is defined in Xrender.h" >&5 51714 $as_echo_n "checking if XlinearGradient is defined in Xrender.h... " >&6; } 51715 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 51716 /* end confdefs.h. */ 51717 #include <X11/extensions/Xrender.h> 51718 int 51719 main () 51720 { 51721 XLinearGradient x; 51722 ; 51723 return 0; 51724 } 51725 _ACEOF 51726 if ac_fn_c_try_compile "$LINENO"; then : 51727 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 51728 $as_echo "yes" >&6; } 51729 else 51730 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 51731 $as_echo "no" >&6; } 51732 X_CFLAGS="$X_CFLAGS -DSOLARIS10_NO_XRENDER_STRUCTS" 51733 fi 51734 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 51735 51736 CFLAGS="$OLD_CFLAGS" 51737 ac_ext=cpp 51738 ac_cpp='$CXXCPP $CPPFLAGS' 51739 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 51740 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 51741 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 51742 51743 fi # NEEDS_LIB_X11 51744 51745 51746 51747 51748 51749 51750 # Check whether --with-cups was given. 51751 if test "${with_cups+set}" = set; then : 51752 withval=$with_cups; 51753 fi 51754 51755 51756 # Check whether --with-cups-include was given. 51757 if test "${with_cups_include+set}" = set; then : 51758 withval=$with_cups_include; 51759 fi 51760 51761 51762 if test "x$NEEDS_LIB_CUPS" = xfalse; then 51763 if (test "x${with_cups}" != x && test "x${with_cups}" != xno) || \ 51764 (test "x${with_cups_include}" != x && test "x${with_cups_include}" != xno); then 51765 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cups not used, so --with-cups[-*] is ignored" >&5 51766 $as_echo "$as_me: WARNING: cups not used, so --with-cups[-*] is ignored" >&2;} 51767 fi 51768 CUPS_CFLAGS= 51769 else 51770 CUPS_FOUND=no 51771 51772 if test "x${with_cups}" = xno || test "x${with_cups_include}" = xno; then 51773 as_fn_error $? "It is not possible to disable the use of cups. Remove the --without-cups option." "$LINENO" 5 51774 fi 51775 51776 if test "x${with_cups}" != x; then 51777 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cups headers" >&5 51778 $as_echo_n "checking for cups headers... " >&6; } 51779 if test -s "${with_cups}/include/cups/cups.h"; then 51780 CUPS_CFLAGS="-I${with_cups}/include" 51781 CUPS_FOUND=yes 51782 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUPS_FOUND" >&5 51783 $as_echo "$CUPS_FOUND" >&6; } 51784 else 51785 as_fn_error $? "Can't find 'include/cups/cups.h' under ${with_cups} given with the --with-cups option." "$LINENO" 5 51786 fi 51787 fi 51788 if test "x${with_cups_include}" != x; then 51789 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cups headers" >&5 51790 $as_echo_n "checking for cups headers... " >&6; } 51791 if test -s "${with_cups_include}/cups/cups.h"; then 51792 CUPS_CFLAGS="-I${with_cups_include}" 51793 CUPS_FOUND=yes 51794 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUPS_FOUND" >&5 51795 $as_echo "$CUPS_FOUND" >&6; } 51796 else 51797 as_fn_error $? "Can't find 'cups/cups.h' under ${with_cups_include} given with the --with-cups-include option." "$LINENO" 5 51798 fi 51799 fi 51800 if test "x$CUPS_FOUND" = xno; then 51801 # Are the cups headers installed in the default /usr/include location? 51802 for ac_header in cups/cups.h cups/ppd.h 51803 do : 51804 as_ac_Header=`$as_echo "ac_cv_header_$ac_header" | $as_tr_sh` 51805 ac_fn_cxx_check_header_mongrel "$LINENO" "$ac_header" "$as_ac_Header" "$ac_includes_default" 51806 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then : 51807 cat >>confdefs.h <<_ACEOF 51808 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1 51809 _ACEOF 51810 51811 CUPS_FOUND=yes 51812 CUPS_CFLAGS= 51813 DEFAULT_CUPS=yes 51814 51815 fi 51816 51817 done 51818 51819 fi 51820 if test "x$CUPS_FOUND" = xno; then 51821 # Getting nervous now? Lets poke around for standard Solaris third-party 51822 # package installation locations. 51823 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cups headers" >&5 51824 $as_echo_n "checking for cups headers... " >&6; } 51825 if test -s $SYSROOT/opt/sfw/cups/include/cups/cups.h; then 51826 # An SFW package seems to be installed! 51827 CUPS_FOUND=yes 51828 CUPS_CFLAGS="-I$SYSROOT/opt/sfw/cups/include" 51829 elif test -s $SYSROOT/opt/csw/include/cups/cups.h; then 51830 # A CSW package seems to be installed! 51831 CUPS_FOUND=yes 51832 CUPS_CFLAGS="-I$SYSROOT/opt/csw/include" 51833 fi 51834 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUPS_FOUND" >&5 51835 $as_echo "$CUPS_FOUND" >&6; } 51836 fi 51837 if test "x$CUPS_FOUND" = xno; then 51838 51839 # Print a helpful message on how to acquire the necessary build dependency. 51840 # cups is the help tag: freetype, cups, alsa etc 51841 MISSING_DEPENDENCY=cups 51842 51843 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 51844 cygwin_help $MISSING_DEPENDENCY 51845 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 51846 msys_help $MISSING_DEPENDENCY 51847 else 51848 PKGHANDLER_COMMAND= 51849 51850 case $PKGHANDLER in 51851 apt-get) 51852 apt_help $MISSING_DEPENDENCY ;; 51853 yum) 51854 yum_help $MISSING_DEPENDENCY ;; 51855 port) 51856 port_help $MISSING_DEPENDENCY ;; 51857 pkgutil) 51858 pkgutil_help $MISSING_DEPENDENCY ;; 51859 pkgadd) 51860 pkgadd_help $MISSING_DEPENDENCY ;; 51861 esac 51862 51863 if test "x$PKGHANDLER_COMMAND" != x; then 51864 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 51865 fi 51866 fi 51867 51868 as_fn_error $? "Could not find cups! $HELP_MSG " "$LINENO" 5 51869 fi 51870 fi 51871 51872 51873 51874 51875 51876 # Check whether --with-freetype was given. 51877 if test "${with_freetype+set}" = set; then : 51878 withval=$with_freetype; 51879 fi 51880 51881 51882 # Check whether --with-freetype-include was given. 51883 if test "${with_freetype_include+set}" = set; then : 51884 withval=$with_freetype_include; 51885 fi 51886 51887 51888 # Check whether --with-freetype-lib was given. 51889 if test "${with_freetype_lib+set}" = set; then : 51890 withval=$with_freetype_lib; 51891 fi 51892 51893 51894 # Check whether --with-freetype-src was given. 51895 if test "${with_freetype_src+set}" = set; then : 51896 withval=$with_freetype_src; 51897 fi 51898 51899 # Check whether --enable-freetype-bundling was given. 51900 if test "${enable_freetype_bundling+set}" = set; then : 51901 enableval=$enable_freetype_bundling; 51902 fi 51903 51904 51905 # Need to specify explicitly since it needs to be overridden on some versions of macosx 51906 FREETYPE_BASE_NAME=freetype 51907 FREETYPE_CFLAGS= 51908 FREETYPE_LIBS= 51909 FREETYPE_BUNDLE_LIB_PATH= 51910 51911 if test "x$NEEDS_LIB_FREETYPE" = xfalse; then 51912 if (test "x$with_freetype" != x && test "x$with_freetype" != xno) || \ 51913 (test "x$with_freetype_include" != x && test "x$with_freetype_include" != xno) || \ 51914 (test "x$with_freetype_lib" != x && test "x$with_freetype_lib" != xno) || \ 51915 (test "x$with_freetype_src" != x && test "x$with_freetype_src" != xno); then 51916 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: freetype not used, so --with-freetype[-*] is ignored" >&5 51917 $as_echo "$as_me: WARNING: freetype not used, so --with-freetype[-*] is ignored" >&2;} 51918 fi 51919 if (test "x$enable_freetype_bundling" != x && test "x$enable_freetype_bundling" != xno); then 51920 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: freetype not used, so --enable-freetype-bundling is ignored" >&5 51921 $as_echo "$as_me: WARNING: freetype not used, so --enable-freetype-bundling is ignored" >&2;} 51922 fi 51923 else 51924 # freetype is needed to build; go get it! 51925 51926 BUNDLE_FREETYPE="$enable_freetype_bundling" 51927 51928 if test "x$with_freetype_src" != x; then 51929 if test "x$OPENJDK_TARGET_OS" = xwindows; then 51930 # Try to build freetype if --with-freetype-src was given on Windows 51931 51932 FREETYPE_SRC_PATH="$with_freetype_src" 51933 BUILD_FREETYPE=yes 51934 51935 # Check if the freetype sources are acessible.. 51936 if ! test -d $FREETYPE_SRC_PATH; then 51937 { $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 51938 $as_echo "$as_me: WARNING: --with-freetype-src specified, but can not find path \"$FREETYPE_SRC_PATH\" - ignoring --with-freetype-src" >&2;} 51939 BUILD_FREETYPE=no 51940 fi 51941 # ..and contain a vc2010 project file 51942 vcxproj_path="$FREETYPE_SRC_PATH/builds/windows/vc2010/freetype.vcxproj" 51943 if test "x$BUILD_FREETYPE" = xyes && ! test -s $vcxproj_path; then 51944 { $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 51945 $as_echo "$as_me: WARNING: Can not find project file $vcxproj_path (you may try a newer freetype version) - ignoring --with-freetype-src" >&2;} 51946 BUILD_FREETYPE=no 51947 fi 51948 # Now check if configure found a version of 'msbuild.exe' 51949 if test "x$BUILD_FREETYPE" = xyes && test "x$MSBUILD" == x ; then 51950 { $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 51951 $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;} 51952 BUILD_FREETYPE=no 51953 fi 51954 51955 # Ready to go.. 51956 if test "x$BUILD_FREETYPE" = xyes; then 51957 # msbuild requires trailing slashes for output directories 51958 freetype_lib_path="$FREETYPE_SRC_PATH/lib$OPENJDK_TARGET_CPU_BITS/" 51959 freetype_lib_path_unix="$freetype_lib_path" 51960 freetype_obj_path="$FREETYPE_SRC_PATH/obj$OPENJDK_TARGET_CPU_BITS/" 51961 51962 unix_path="$vcxproj_path" 51963 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 51964 windows_path=`$CYGPATH -m "$unix_path"` 51965 vcxproj_path="$windows_path" 51966 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 51967 windows_path=`cmd //c echo $unix_path` 51968 vcxproj_path="$windows_path" 51969 fi 51970 51971 51972 unix_path="$freetype_lib_path" 51973 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 51974 windows_path=`$CYGPATH -m "$unix_path"` 51975 freetype_lib_path="$windows_path" 51976 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 51977 windows_path=`cmd //c echo $unix_path` 51978 freetype_lib_path="$windows_path" 51979 fi 51980 51981 51982 unix_path="$freetype_obj_path" 51983 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 51984 windows_path=`$CYGPATH -m "$unix_path"` 51985 freetype_obj_path="$windows_path" 51986 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 51987 windows_path=`cmd //c echo $unix_path` 51988 freetype_obj_path="$windows_path" 51989 fi 51990 51991 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 51992 freetype_platform=x64 51993 else 51994 freetype_platform=win32 51995 fi 51996 51997 # The original freetype project file is for VS 2010 (i.e. 'v100'), 51998 # so we have to adapt the toolset if building with any other toolsed (i.e. SDK). 51999 # Currently 'PLATFORM_TOOLSET' is set in 'TOOLCHAIN_CHECK_POSSIBLE_VISUAL_STUDIO_ROOT'/ 52000 # 'TOOLCHAIN_CHECK_POSSIBLE_WIN_SDK_ROOT' in toolchain_windows.m4 52001 { $as_echo "$as_me:${as_lineno-$LINENO}: Trying to compile freetype sources with PlatformToolset=$PLATFORM_TOOLSET to $freetype_lib_path_unix ..." >&5 52002 $as_echo "$as_me: Trying to compile freetype sources with PlatformToolset=$PLATFORM_TOOLSET to $freetype_lib_path_unix ..." >&6;} 52003 52004 # First we try to build the freetype.dll 52005 $ECHO -e "@echo off\n"\ 52006 "$MSBUILD $vcxproj_path "\ 52007 "/p:PlatformToolset=$PLATFORM_TOOLSET "\ 52008 "/p:Configuration=\"Release Multithreaded\" "\ 52009 "/p:Platform=$freetype_platform "\ 52010 "/p:ConfigurationType=DynamicLibrary "\ 52011 "/p:TargetName=freetype "\ 52012 "/p:OutDir=\"$freetype_lib_path\" "\ 52013 "/p:IntDir=\"$freetype_obj_path\" > freetype.log" > freetype.bat 52014 cmd /c freetype.bat 52015 52016 if test -s "$freetype_lib_path_unix/freetype.dll"; then 52017 # If that succeeds we also build freetype.lib 52018 $ECHO -e "@echo off\n"\ 52019 "$MSBUILD $vcxproj_path "\ 52020 "/p:PlatformToolset=$PLATFORM_TOOLSET "\ 52021 "/p:Configuration=\"Release Multithreaded\" "\ 52022 "/p:Platform=$freetype_platform "\ 52023 "/p:ConfigurationType=StaticLibrary "\ 52024 "/p:TargetName=freetype "\ 52025 "/p:OutDir=\"$freetype_lib_path\" "\ 52026 "/p:IntDir=\"$freetype_obj_path\" >> freetype.log" > freetype.bat 52027 cmd /c freetype.bat 52028 52029 if test -s "$freetype_lib_path_unix/freetype.lib"; then 52030 # Once we build both, lib and dll, set freetype lib and include path appropriately 52031 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_SRC_PATH/include" 52032 POTENTIAL_FREETYPE_LIB_PATH="$freetype_lib_path_unix" 52033 { $as_echo "$as_me:${as_lineno-$LINENO}: Compiling freetype sources succeeded! (see freetype.log for build results)" >&5 52034 $as_echo "$as_me: Compiling freetype sources succeeded! (see freetype.log for build results)" >&6;} 52035 else 52036 BUILD_FREETYPE=no 52037 fi 52038 else 52039 BUILD_FREETYPE=no 52040 fi 52041 fi 52042 52043 if test "x$BUILD_FREETYPE" = xyes; then 52044 # Okay, we built it. Check that it works. 52045 52046 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 52047 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 52048 METHOD="--with-freetype-src" 52049 52050 # Let's start with an optimistic view of the world :-) 52051 FOUND_FREETYPE=yes 52052 52053 # First look for the canonical freetype main include file ft2build.h. 52054 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 52055 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 52056 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 52057 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 52058 # Fail. 52059 FOUND_FREETYPE=no 52060 fi 52061 fi 52062 52063 if test "x$FOUND_FREETYPE" = xyes; then 52064 # Include file found, let's continue the sanity check. 52065 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 52066 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 52067 52068 # Reset to default value 52069 FREETYPE_BASE_NAME=freetype 52070 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 52071 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 52072 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 52073 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 52074 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 52075 # for the .6 version explicitly. 52076 FREETYPE_BASE_NAME=freetype.6 52077 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 52078 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 52079 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 52080 else 52081 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 52082 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 52083 FOUND_FREETYPE=no 52084 fi 52085 else 52086 if test "x$OPENJDK_TARGET_OS" = xwindows; then 52087 # On Windows, we will need both .lib and .dll file. 52088 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 52089 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 52090 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 52091 FOUND_FREETYPE=no 52092 fi 52093 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 52094 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 52095 # Found lib in isa dir, use that instead. 52096 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 52097 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 52098 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 52099 fi 52100 fi 52101 fi 52102 52103 if test "x$FOUND_FREETYPE" = xyes; then 52104 52105 # Only process if variable expands to non-empty 52106 52107 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 52108 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 52109 52110 # Input might be given as Windows format, start by converting to 52111 # unix format. 52112 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 52113 new_path=`$CYGPATH -u "$path"` 52114 52115 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 52116 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 52117 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 52118 # "foo.exe" is OK but "foo" is an error. 52119 # 52120 # This test is therefore slightly more accurate than "test -f" to check for file precense. 52121 # It is also a way to make sure we got the proper file name for the real test later on. 52122 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 52123 if test "x$test_shortpath" = x; then 52124 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 52125 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 52126 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 52127 fi 52128 52129 # Call helper function which possibly converts this using DOS-style short mode. 52130 # If so, the updated path is stored in $new_path. 52131 52132 input_path="$new_path" 52133 # Check if we need to convert this using DOS-style short mode. If the path 52134 # contains just simple characters, use it. Otherwise (spaces, weird characters), 52135 # take no chances and rewrite it. 52136 # Note: m4 eats our [], so we need to use [ and ] instead. 52137 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 52138 if test "x$has_forbidden_chars" != x; then 52139 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 52140 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 52141 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 52142 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 52143 # Going to short mode and back again did indeed matter. Since short mode is 52144 # case insensitive, let's make it lowercase to improve readability. 52145 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 52146 # Now convert it back to Unix-style (cygpath) 52147 input_path=`$CYGPATH -u "$shortmode_path"` 52148 new_path="$input_path" 52149 fi 52150 fi 52151 52152 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 52153 if test "x$test_cygdrive_prefix" = x; then 52154 # As a simple fix, exclude /usr/bin since it's not a real path. 52155 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 52156 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 52157 # a path prefixed by /cygdrive for fixpath to work. 52158 new_path="$CYGWIN_ROOT_PATH$input_path" 52159 fi 52160 fi 52161 52162 52163 if test "x$path" != "x$new_path"; then 52164 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 52165 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 52166 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 52167 fi 52168 52169 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 52170 52171 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 52172 has_colon=`$ECHO $path | $GREP ^.:` 52173 new_path="$path" 52174 if test "x$has_colon" = x; then 52175 # Not in mixed or Windows style, start by that. 52176 new_path=`cmd //c echo $path` 52177 fi 52178 52179 52180 input_path="$new_path" 52181 # Check if we need to convert this using DOS-style short mode. If the path 52182 # contains just simple characters, use it. Otherwise (spaces, weird characters), 52183 # take no chances and rewrite it. 52184 # Note: m4 eats our [], so we need to use [ and ] instead. 52185 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 52186 if test "x$has_forbidden_chars" != x; then 52187 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 52188 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 52189 fi 52190 52191 52192 windows_path="$new_path" 52193 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 52194 unix_path=`$CYGPATH -u "$windows_path"` 52195 new_path="$unix_path" 52196 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 52197 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 52198 new_path="$unix_path" 52199 fi 52200 52201 if test "x$path" != "x$new_path"; then 52202 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 52203 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 52204 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 52205 fi 52206 52207 # Save the first 10 bytes of this path to the storage, so fixpath can work. 52208 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 52209 52210 else 52211 # We're on a unix platform. Hooray! :) 52212 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 52213 has_space=`$ECHO "$path" | $GREP " "` 52214 if test "x$has_space" != x; then 52215 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 52216 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 52217 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 52218 fi 52219 52220 # Use eval to expand a potential ~ 52221 eval path="$path" 52222 if test ! -f "$path" && test ! -d "$path"; then 52223 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 52224 fi 52225 52226 if test -d "$path"; then 52227 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 52228 else 52229 dir="`$DIRNAME "$path"`" 52230 base="`$BASENAME "$path"`" 52231 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 52232 fi 52233 fi 52234 fi 52235 52236 52237 # Only process if variable expands to non-empty 52238 52239 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 52240 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 52241 52242 # Input might be given as Windows format, start by converting to 52243 # unix format. 52244 path="$POTENTIAL_FREETYPE_LIB_PATH" 52245 new_path=`$CYGPATH -u "$path"` 52246 52247 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 52248 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 52249 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 52250 # "foo.exe" is OK but "foo" is an error. 52251 # 52252 # This test is therefore slightly more accurate than "test -f" to check for file precense. 52253 # It is also a way to make sure we got the proper file name for the real test later on. 52254 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 52255 if test "x$test_shortpath" = x; then 52256 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 52257 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 52258 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 52259 fi 52260 52261 # Call helper function which possibly converts this using DOS-style short mode. 52262 # If so, the updated path is stored in $new_path. 52263 52264 input_path="$new_path" 52265 # Check if we need to convert this using DOS-style short mode. If the path 52266 # contains just simple characters, use it. Otherwise (spaces, weird characters), 52267 # take no chances and rewrite it. 52268 # Note: m4 eats our [], so we need to use [ and ] instead. 52269 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 52270 if test "x$has_forbidden_chars" != x; then 52271 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 52272 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 52273 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 52274 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 52275 # Going to short mode and back again did indeed matter. Since short mode is 52276 # case insensitive, let's make it lowercase to improve readability. 52277 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 52278 # Now convert it back to Unix-style (cygpath) 52279 input_path=`$CYGPATH -u "$shortmode_path"` 52280 new_path="$input_path" 52281 fi 52282 fi 52283 52284 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 52285 if test "x$test_cygdrive_prefix" = x; then 52286 # As a simple fix, exclude /usr/bin since it's not a real path. 52287 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 52288 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 52289 # a path prefixed by /cygdrive for fixpath to work. 52290 new_path="$CYGWIN_ROOT_PATH$input_path" 52291 fi 52292 fi 52293 52294 52295 if test "x$path" != "x$new_path"; then 52296 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 52297 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 52298 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 52299 fi 52300 52301 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 52302 52303 path="$POTENTIAL_FREETYPE_LIB_PATH" 52304 has_colon=`$ECHO $path | $GREP ^.:` 52305 new_path="$path" 52306 if test "x$has_colon" = x; then 52307 # Not in mixed or Windows style, start by that. 52308 new_path=`cmd //c echo $path` 52309 fi 52310 52311 52312 input_path="$new_path" 52313 # Check if we need to convert this using DOS-style short mode. If the path 52314 # contains just simple characters, use it. Otherwise (spaces, weird characters), 52315 # take no chances and rewrite it. 52316 # Note: m4 eats our [], so we need to use [ and ] instead. 52317 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 52318 if test "x$has_forbidden_chars" != x; then 52319 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 52320 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 52321 fi 52322 52323 52324 windows_path="$new_path" 52325 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 52326 unix_path=`$CYGPATH -u "$windows_path"` 52327 new_path="$unix_path" 52328 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 52329 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 52330 new_path="$unix_path" 52331 fi 52332 52333 if test "x$path" != "x$new_path"; then 52334 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 52335 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 52336 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 52337 fi 52338 52339 # Save the first 10 bytes of this path to the storage, so fixpath can work. 52340 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 52341 52342 else 52343 # We're on a unix platform. Hooray! :) 52344 path="$POTENTIAL_FREETYPE_LIB_PATH" 52345 has_space=`$ECHO "$path" | $GREP " "` 52346 if test "x$has_space" != x; then 52347 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 52348 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 52349 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 52350 fi 52351 52352 # Use eval to expand a potential ~ 52353 eval path="$path" 52354 if test ! -f "$path" && test ! -d "$path"; then 52355 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 52356 fi 52357 52358 if test -d "$path"; then 52359 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 52360 else 52361 dir="`$DIRNAME "$path"`" 52362 base="`$BASENAME "$path"`" 52363 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 52364 fi 52365 fi 52366 fi 52367 52368 52369 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 52370 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 52371 $as_echo_n "checking for freetype includes... " >&6; } 52372 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 52373 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 52374 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 52375 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 52376 $as_echo_n "checking for freetype libraries... " >&6; } 52377 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 52378 $as_echo "$FREETYPE_LIB_PATH" >&6; } 52379 fi 52380 52381 if test "x$FOUND_FREETYPE" != xyes; then 52382 as_fn_error $? "Can not use the built freetype at location given by --with-freetype-src" "$LINENO" 5 52383 fi 52384 else 52385 { $as_echo "$as_me:${as_lineno-$LINENO}: User specified --with-freetype-src but building freetype failed. (see freetype.log for build results)" >&5 52386 $as_echo "$as_me: User specified --with-freetype-src but building freetype failed. (see freetype.log for build results)" >&6;} 52387 as_fn_error $? "Consider building freetype manually and using --with-freetype instead." "$LINENO" 5 52388 fi 52389 else 52390 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-freetype-src is currently only supported on Windows - ignoring" >&5 52391 $as_echo "$as_me: WARNING: --with-freetype-src is currently only supported on Windows - ignoring" >&2;} 52392 fi 52393 fi 52394 52395 if test "x$with_freetype" != x || test "x$with_freetype_include" != x || test "x$with_freetype_lib" != x; then 52396 # User has specified settings 52397 52398 if test "x$BUNDLE_FREETYPE" = x; then 52399 # If not specified, default is to bundle freetype 52400 BUNDLE_FREETYPE=yes 52401 fi 52402 52403 if test "x$with_freetype" != x; then 52404 POTENTIAL_FREETYPE_INCLUDE_PATH="$with_freetype/include" 52405 POTENTIAL_FREETYPE_LIB_PATH="$with_freetype/lib" 52406 fi 52407 52408 # Allow --with-freetype-lib and --with-freetype-include to override 52409 if test "x$with_freetype_include" != x; then 52410 POTENTIAL_FREETYPE_INCLUDE_PATH="$with_freetype_include" 52411 fi 52412 if test "x$with_freetype_lib" != x; then 52413 POTENTIAL_FREETYPE_LIB_PATH="$with_freetype_lib" 52414 fi 52415 52416 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x && test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 52417 # Okay, we got it. Check that it works. 52418 52419 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 52420 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 52421 METHOD="--with-freetype" 52422 52423 # Let's start with an optimistic view of the world :-) 52424 FOUND_FREETYPE=yes 52425 52426 # First look for the canonical freetype main include file ft2build.h. 52427 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 52428 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 52429 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 52430 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 52431 # Fail. 52432 FOUND_FREETYPE=no 52433 fi 52434 fi 52435 52436 if test "x$FOUND_FREETYPE" = xyes; then 52437 # Include file found, let's continue the sanity check. 52438 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 52439 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 52440 52441 # Reset to default value 52442 FREETYPE_BASE_NAME=freetype 52443 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 52444 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 52445 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 52446 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 52447 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 52448 # for the .6 version explicitly. 52449 FREETYPE_BASE_NAME=freetype.6 52450 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 52451 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 52452 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 52453 else 52454 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 52455 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 52456 FOUND_FREETYPE=no 52457 fi 52458 else 52459 if test "x$OPENJDK_TARGET_OS" = xwindows; then 52460 # On Windows, we will need both .lib and .dll file. 52461 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 52462 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 52463 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 52464 FOUND_FREETYPE=no 52465 fi 52466 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 52467 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 52468 # Found lib in isa dir, use that instead. 52469 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 52470 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 52471 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 52472 fi 52473 fi 52474 fi 52475 52476 if test "x$FOUND_FREETYPE" = xyes; then 52477 52478 # Only process if variable expands to non-empty 52479 52480 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 52481 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 52482 52483 # Input might be given as Windows format, start by converting to 52484 # unix format. 52485 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 52486 new_path=`$CYGPATH -u "$path"` 52487 52488 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 52489 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 52490 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 52491 # "foo.exe" is OK but "foo" is an error. 52492 # 52493 # This test is therefore slightly more accurate than "test -f" to check for file precense. 52494 # It is also a way to make sure we got the proper file name for the real test later on. 52495 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 52496 if test "x$test_shortpath" = x; then 52497 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 52498 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 52499 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 52500 fi 52501 52502 # Call helper function which possibly converts this using DOS-style short mode. 52503 # If so, the updated path is stored in $new_path. 52504 52505 input_path="$new_path" 52506 # Check if we need to convert this using DOS-style short mode. If the path 52507 # contains just simple characters, use it. Otherwise (spaces, weird characters), 52508 # take no chances and rewrite it. 52509 # Note: m4 eats our [], so we need to use [ and ] instead. 52510 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 52511 if test "x$has_forbidden_chars" != x; then 52512 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 52513 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 52514 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 52515 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 52516 # Going to short mode and back again did indeed matter. Since short mode is 52517 # case insensitive, let's make it lowercase to improve readability. 52518 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 52519 # Now convert it back to Unix-style (cygpath) 52520 input_path=`$CYGPATH -u "$shortmode_path"` 52521 new_path="$input_path" 52522 fi 52523 fi 52524 52525 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 52526 if test "x$test_cygdrive_prefix" = x; then 52527 # As a simple fix, exclude /usr/bin since it's not a real path. 52528 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 52529 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 52530 # a path prefixed by /cygdrive for fixpath to work. 52531 new_path="$CYGWIN_ROOT_PATH$input_path" 52532 fi 52533 fi 52534 52535 52536 if test "x$path" != "x$new_path"; then 52537 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 52538 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 52539 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 52540 fi 52541 52542 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 52543 52544 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 52545 has_colon=`$ECHO $path | $GREP ^.:` 52546 new_path="$path" 52547 if test "x$has_colon" = x; then 52548 # Not in mixed or Windows style, start by that. 52549 new_path=`cmd //c echo $path` 52550 fi 52551 52552 52553 input_path="$new_path" 52554 # Check if we need to convert this using DOS-style short mode. If the path 52555 # contains just simple characters, use it. Otherwise (spaces, weird characters), 52556 # take no chances and rewrite it. 52557 # Note: m4 eats our [], so we need to use [ and ] instead. 52558 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 52559 if test "x$has_forbidden_chars" != x; then 52560 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 52561 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 52562 fi 52563 52564 52565 windows_path="$new_path" 52566 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 52567 unix_path=`$CYGPATH -u "$windows_path"` 52568 new_path="$unix_path" 52569 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 52570 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 52571 new_path="$unix_path" 52572 fi 52573 52574 if test "x$path" != "x$new_path"; then 52575 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 52576 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 52577 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 52578 fi 52579 52580 # Save the first 10 bytes of this path to the storage, so fixpath can work. 52581 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 52582 52583 else 52584 # We're on a unix platform. Hooray! :) 52585 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 52586 has_space=`$ECHO "$path" | $GREP " "` 52587 if test "x$has_space" != x; then 52588 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 52589 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 52590 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 52591 fi 52592 52593 # Use eval to expand a potential ~ 52594 eval path="$path" 52595 if test ! -f "$path" && test ! -d "$path"; then 52596 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 52597 fi 52598 52599 if test -d "$path"; then 52600 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 52601 else 52602 dir="`$DIRNAME "$path"`" 52603 base="`$BASENAME "$path"`" 52604 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 52605 fi 52606 fi 52607 fi 52608 52609 52610 # Only process if variable expands to non-empty 52611 52612 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 52613 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 52614 52615 # Input might be given as Windows format, start by converting to 52616 # unix format. 52617 path="$POTENTIAL_FREETYPE_LIB_PATH" 52618 new_path=`$CYGPATH -u "$path"` 52619 52620 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 52621 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 52622 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 52623 # "foo.exe" is OK but "foo" is an error. 52624 # 52625 # This test is therefore slightly more accurate than "test -f" to check for file precense. 52626 # It is also a way to make sure we got the proper file name for the real test later on. 52627 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 52628 if test "x$test_shortpath" = x; then 52629 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 52630 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 52631 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 52632 fi 52633 52634 # Call helper function which possibly converts this using DOS-style short mode. 52635 # If so, the updated path is stored in $new_path. 52636 52637 input_path="$new_path" 52638 # Check if we need to convert this using DOS-style short mode. If the path 52639 # contains just simple characters, use it. Otherwise (spaces, weird characters), 52640 # take no chances and rewrite it. 52641 # Note: m4 eats our [], so we need to use [ and ] instead. 52642 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 52643 if test "x$has_forbidden_chars" != x; then 52644 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 52645 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 52646 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 52647 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 52648 # Going to short mode and back again did indeed matter. Since short mode is 52649 # case insensitive, let's make it lowercase to improve readability. 52650 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 52651 # Now convert it back to Unix-style (cygpath) 52652 input_path=`$CYGPATH -u "$shortmode_path"` 52653 new_path="$input_path" 52654 fi 52655 fi 52656 52657 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 52658 if test "x$test_cygdrive_prefix" = x; then 52659 # As a simple fix, exclude /usr/bin since it's not a real path. 52660 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 52661 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 52662 # a path prefixed by /cygdrive for fixpath to work. 52663 new_path="$CYGWIN_ROOT_PATH$input_path" 52664 fi 52665 fi 52666 52667 52668 if test "x$path" != "x$new_path"; then 52669 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 52670 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 52671 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 52672 fi 52673 52674 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 52675 52676 path="$POTENTIAL_FREETYPE_LIB_PATH" 52677 has_colon=`$ECHO $path | $GREP ^.:` 52678 new_path="$path" 52679 if test "x$has_colon" = x; then 52680 # Not in mixed or Windows style, start by that. 52681 new_path=`cmd //c echo $path` 52682 fi 52683 52684 52685 input_path="$new_path" 52686 # Check if we need to convert this using DOS-style short mode. If the path 52687 # contains just simple characters, use it. Otherwise (spaces, weird characters), 52688 # take no chances and rewrite it. 52689 # Note: m4 eats our [], so we need to use [ and ] instead. 52690 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 52691 if test "x$has_forbidden_chars" != x; then 52692 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 52693 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 52694 fi 52695 52696 52697 windows_path="$new_path" 52698 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 52699 unix_path=`$CYGPATH -u "$windows_path"` 52700 new_path="$unix_path" 52701 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 52702 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 52703 new_path="$unix_path" 52704 fi 52705 52706 if test "x$path" != "x$new_path"; then 52707 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 52708 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 52709 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 52710 fi 52711 52712 # Save the first 10 bytes of this path to the storage, so fixpath can work. 52713 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 52714 52715 else 52716 # We're on a unix platform. Hooray! :) 52717 path="$POTENTIAL_FREETYPE_LIB_PATH" 52718 has_space=`$ECHO "$path" | $GREP " "` 52719 if test "x$has_space" != x; then 52720 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 52721 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 52722 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 52723 fi 52724 52725 # Use eval to expand a potential ~ 52726 eval path="$path" 52727 if test ! -f "$path" && test ! -d "$path"; then 52728 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 52729 fi 52730 52731 if test -d "$path"; then 52732 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 52733 else 52734 dir="`$DIRNAME "$path"`" 52735 base="`$BASENAME "$path"`" 52736 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 52737 fi 52738 fi 52739 fi 52740 52741 52742 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 52743 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 52744 $as_echo_n "checking for freetype includes... " >&6; } 52745 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 52746 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 52747 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 52748 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 52749 $as_echo_n "checking for freetype libraries... " >&6; } 52750 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 52751 $as_echo "$FREETYPE_LIB_PATH" >&6; } 52752 fi 52753 52754 if test "x$FOUND_FREETYPE" != xyes; then 52755 as_fn_error $? "Can not find or use freetype at location given by --with-freetype" "$LINENO" 5 52756 fi 52757 else 52758 # User specified only one of lib or include. This is an error. 52759 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" = x ; then 52760 { $as_echo "$as_me:${as_lineno-$LINENO}: User specified --with-freetype-lib but not --with-freetype-include" >&5 52761 $as_echo "$as_me: User specified --with-freetype-lib but not --with-freetype-include" >&6;} 52762 as_fn_error $? "Need both freetype lib and include paths. Consider using --with-freetype instead." "$LINENO" 5 52763 else 52764 { $as_echo "$as_me:${as_lineno-$LINENO}: User specified --with-freetype-include but not --with-freetype-lib" >&5 52765 $as_echo "$as_me: User specified --with-freetype-include but not --with-freetype-lib" >&6;} 52766 as_fn_error $? "Need both freetype lib and include paths. Consider using --with-freetype instead." "$LINENO" 5 52767 fi 52768 fi 52769 else 52770 # User did not specify settings, but we need freetype. Try to locate it. 52771 52772 if test "x$BUNDLE_FREETYPE" = x; then 52773 # If not specified, default is to bundle freetype only on windows 52774 if test "x$OPENJDK_TARGET_OS" = xwindows; then 52775 BUNDLE_FREETYPE=yes 52776 else 52777 BUNDLE_FREETYPE=no 52778 fi 52779 fi 52780 52781 # If we have a sysroot, assume that's where we are supposed to look and skip pkg-config. 52782 if test "x$SYSROOT" = x; then 52783 if test "x$FOUND_FREETYPE" != xyes; then 52784 # Check modules using pkg-config, but only if we have it (ugly output results otherwise) 52785 if test "x$PKG_CONFIG" != x; then 52786 52787 pkg_failed=no 52788 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FREETYPE" >&5 52789 $as_echo_n "checking for FREETYPE... " >&6; } 52790 52791 if test -n "$FREETYPE_CFLAGS"; then 52792 pkg_cv_FREETYPE_CFLAGS="$FREETYPE_CFLAGS" 52793 elif test -n "$PKG_CONFIG"; then 52794 if test -n "$PKG_CONFIG" && \ 52795 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"freetype2\""; } >&5 52796 ($PKG_CONFIG --exists --print-errors "freetype2") 2>&5 52797 ac_status=$? 52798 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 52799 test $ac_status = 0; }; then 52800 pkg_cv_FREETYPE_CFLAGS=`$PKG_CONFIG --cflags "freetype2" 2>/dev/null` 52801 else 52802 pkg_failed=yes 52803 fi 52804 else 52805 pkg_failed=untried 52806 fi 52807 if test -n "$FREETYPE_LIBS"; then 52808 pkg_cv_FREETYPE_LIBS="$FREETYPE_LIBS" 52809 elif test -n "$PKG_CONFIG"; then 52810 if test -n "$PKG_CONFIG" && \ 52811 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"freetype2\""; } >&5 52812 ($PKG_CONFIG --exists --print-errors "freetype2") 2>&5 52813 ac_status=$? 52814 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 52815 test $ac_status = 0; }; then 52816 pkg_cv_FREETYPE_LIBS=`$PKG_CONFIG --libs "freetype2" 2>/dev/null` 52817 else 52818 pkg_failed=yes 52819 fi 52820 else 52821 pkg_failed=untried 52822 fi 52823 52824 52825 52826 if test $pkg_failed = yes; then 52827 52828 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 52829 _pkg_short_errors_supported=yes 52830 else 52831 _pkg_short_errors_supported=no 52832 fi 52833 if test $_pkg_short_errors_supported = yes; then 52834 FREETYPE_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "freetype2" 2>&1` 52835 else 52836 FREETYPE_PKG_ERRORS=`$PKG_CONFIG --print-errors "freetype2" 2>&1` 52837 fi 52838 # Put the nasty error message in config.log where it belongs 52839 echo "$FREETYPE_PKG_ERRORS" >&5 52840 52841 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 52842 $as_echo "no" >&6; } 52843 FOUND_FREETYPE=no 52844 elif test $pkg_failed = untried; then 52845 FOUND_FREETYPE=no 52846 else 52847 FREETYPE_CFLAGS=$pkg_cv_FREETYPE_CFLAGS 52848 FREETYPE_LIBS=$pkg_cv_FREETYPE_LIBS 52849 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 52850 $as_echo "yes" >&6; } 52851 FOUND_FREETYPE=yes 52852 fi 52853 if test "x$FOUND_FREETYPE" = xyes; then 52854 # On solaris, pkg_check adds -lz to freetype libs, which isn't necessary for us. 52855 FREETYPE_LIBS=`$ECHO $FREETYPE_LIBS | $SED 's/-lz//g'` 52856 # 64-bit libs for Solaris x86 are installed in the amd64 subdirectory, change lib to lib/amd64 52857 if test "x$OPENJDK_TARGET_OS" = xsolaris && test "x$OPENJDK_TARGET_CPU" = xx86_64; then 52858 FREETYPE_LIBS=`$ECHO $FREETYPE_LIBS | $SED 's?/lib?/lib/amd64?g'` 52859 fi 52860 # PKG_CHECK_MODULES will set FREETYPE_CFLAGS and _LIBS, but we don't get a lib path for bundling. 52861 if test "x$BUNDLE_FREETYPE" = xyes; then 52862 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype using pkg-config, but ignoring since we can not bundle that" >&5 52863 $as_echo "$as_me: Found freetype using pkg-config, but ignoring since we can not bundle that" >&6;} 52864 FOUND_FREETYPE=no 52865 else 52866 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype" >&5 52867 $as_echo_n "checking for freetype... " >&6; } 52868 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (using pkg-config)" >&5 52869 $as_echo "yes (using pkg-config)" >&6; } 52870 fi 52871 fi 52872 fi 52873 fi 52874 fi 52875 52876 if test "x$FOUND_FREETYPE" != xyes; then 52877 # Check in well-known locations 52878 if test "x$OPENJDK_TARGET_OS" = xwindows; then 52879 FREETYPE_BASE_DIR="$PROGRAMFILES/GnuWin32" 52880 52881 windows_path="$FREETYPE_BASE_DIR" 52882 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 52883 unix_path=`$CYGPATH -u "$windows_path"` 52884 FREETYPE_BASE_DIR="$unix_path" 52885 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 52886 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 52887 FREETYPE_BASE_DIR="$unix_path" 52888 fi 52889 52890 52891 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 52892 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 52893 METHOD="well-known location" 52894 52895 # Let's start with an optimistic view of the world :-) 52896 FOUND_FREETYPE=yes 52897 52898 # First look for the canonical freetype main include file ft2build.h. 52899 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 52900 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 52901 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 52902 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 52903 # Fail. 52904 FOUND_FREETYPE=no 52905 fi 52906 fi 52907 52908 if test "x$FOUND_FREETYPE" = xyes; then 52909 # Include file found, let's continue the sanity check. 52910 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 52911 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 52912 52913 # Reset to default value 52914 FREETYPE_BASE_NAME=freetype 52915 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 52916 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 52917 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 52918 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 52919 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 52920 # for the .6 version explicitly. 52921 FREETYPE_BASE_NAME=freetype.6 52922 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 52923 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 52924 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 52925 else 52926 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 52927 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 52928 FOUND_FREETYPE=no 52929 fi 52930 else 52931 if test "x$OPENJDK_TARGET_OS" = xwindows; then 52932 # On Windows, we will need both .lib and .dll file. 52933 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 52934 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 52935 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 52936 FOUND_FREETYPE=no 52937 fi 52938 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 52939 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 52940 # Found lib in isa dir, use that instead. 52941 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 52942 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 52943 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 52944 fi 52945 fi 52946 fi 52947 52948 if test "x$FOUND_FREETYPE" = xyes; then 52949 52950 # Only process if variable expands to non-empty 52951 52952 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 52953 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 52954 52955 # Input might be given as Windows format, start by converting to 52956 # unix format. 52957 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 52958 new_path=`$CYGPATH -u "$path"` 52959 52960 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 52961 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 52962 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 52963 # "foo.exe" is OK but "foo" is an error. 52964 # 52965 # This test is therefore slightly more accurate than "test -f" to check for file precense. 52966 # It is also a way to make sure we got the proper file name for the real test later on. 52967 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 52968 if test "x$test_shortpath" = x; then 52969 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 52970 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 52971 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 52972 fi 52973 52974 # Call helper function which possibly converts this using DOS-style short mode. 52975 # If so, the updated path is stored in $new_path. 52976 52977 input_path="$new_path" 52978 # Check if we need to convert this using DOS-style short mode. If the path 52979 # contains just simple characters, use it. Otherwise (spaces, weird characters), 52980 # take no chances and rewrite it. 52981 # Note: m4 eats our [], so we need to use [ and ] instead. 52982 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 52983 if test "x$has_forbidden_chars" != x; then 52984 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 52985 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 52986 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 52987 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 52988 # Going to short mode and back again did indeed matter. Since short mode is 52989 # case insensitive, let's make it lowercase to improve readability. 52990 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 52991 # Now convert it back to Unix-style (cygpath) 52992 input_path=`$CYGPATH -u "$shortmode_path"` 52993 new_path="$input_path" 52994 fi 52995 fi 52996 52997 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 52998 if test "x$test_cygdrive_prefix" = x; then 52999 # As a simple fix, exclude /usr/bin since it's not a real path. 53000 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 53001 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 53002 # a path prefixed by /cygdrive for fixpath to work. 53003 new_path="$CYGWIN_ROOT_PATH$input_path" 53004 fi 53005 fi 53006 53007 53008 if test "x$path" != "x$new_path"; then 53009 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 53010 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 53011 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 53012 fi 53013 53014 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53015 53016 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 53017 has_colon=`$ECHO $path | $GREP ^.:` 53018 new_path="$path" 53019 if test "x$has_colon" = x; then 53020 # Not in mixed or Windows style, start by that. 53021 new_path=`cmd //c echo $path` 53022 fi 53023 53024 53025 input_path="$new_path" 53026 # Check if we need to convert this using DOS-style short mode. If the path 53027 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53028 # take no chances and rewrite it. 53029 # Note: m4 eats our [], so we need to use [ and ] instead. 53030 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 53031 if test "x$has_forbidden_chars" != x; then 53032 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53033 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53034 fi 53035 53036 53037 windows_path="$new_path" 53038 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53039 unix_path=`$CYGPATH -u "$windows_path"` 53040 new_path="$unix_path" 53041 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53042 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 53043 new_path="$unix_path" 53044 fi 53045 53046 if test "x$path" != "x$new_path"; then 53047 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 53048 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 53049 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 53050 fi 53051 53052 # Save the first 10 bytes of this path to the storage, so fixpath can work. 53053 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 53054 53055 else 53056 # We're on a unix platform. Hooray! :) 53057 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 53058 has_space=`$ECHO "$path" | $GREP " "` 53059 if test "x$has_space" != x; then 53060 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 53061 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 53062 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 53063 fi 53064 53065 # Use eval to expand a potential ~ 53066 eval path="$path" 53067 if test ! -f "$path" && test ! -d "$path"; then 53068 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 53069 fi 53070 53071 if test -d "$path"; then 53072 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 53073 else 53074 dir="`$DIRNAME "$path"`" 53075 base="`$BASENAME "$path"`" 53076 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 53077 fi 53078 fi 53079 fi 53080 53081 53082 # Only process if variable expands to non-empty 53083 53084 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 53085 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53086 53087 # Input might be given as Windows format, start by converting to 53088 # unix format. 53089 path="$POTENTIAL_FREETYPE_LIB_PATH" 53090 new_path=`$CYGPATH -u "$path"` 53091 53092 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 53093 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 53094 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 53095 # "foo.exe" is OK but "foo" is an error. 53096 # 53097 # This test is therefore slightly more accurate than "test -f" to check for file precense. 53098 # It is also a way to make sure we got the proper file name for the real test later on. 53099 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 53100 if test "x$test_shortpath" = x; then 53101 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 53102 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 53103 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 53104 fi 53105 53106 # Call helper function which possibly converts this using DOS-style short mode. 53107 # If so, the updated path is stored in $new_path. 53108 53109 input_path="$new_path" 53110 # Check if we need to convert this using DOS-style short mode. If the path 53111 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53112 # take no chances and rewrite it. 53113 # Note: m4 eats our [], so we need to use [ and ] instead. 53114 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 53115 if test "x$has_forbidden_chars" != x; then 53116 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53117 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 53118 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 53119 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 53120 # Going to short mode and back again did indeed matter. Since short mode is 53121 # case insensitive, let's make it lowercase to improve readability. 53122 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53123 # Now convert it back to Unix-style (cygpath) 53124 input_path=`$CYGPATH -u "$shortmode_path"` 53125 new_path="$input_path" 53126 fi 53127 fi 53128 53129 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 53130 if test "x$test_cygdrive_prefix" = x; then 53131 # As a simple fix, exclude /usr/bin since it's not a real path. 53132 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 53133 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 53134 # a path prefixed by /cygdrive for fixpath to work. 53135 new_path="$CYGWIN_ROOT_PATH$input_path" 53136 fi 53137 fi 53138 53139 53140 if test "x$path" != "x$new_path"; then 53141 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 53142 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 53143 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 53144 fi 53145 53146 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53147 53148 path="$POTENTIAL_FREETYPE_LIB_PATH" 53149 has_colon=`$ECHO $path | $GREP ^.:` 53150 new_path="$path" 53151 if test "x$has_colon" = x; then 53152 # Not in mixed or Windows style, start by that. 53153 new_path=`cmd //c echo $path` 53154 fi 53155 53156 53157 input_path="$new_path" 53158 # Check if we need to convert this using DOS-style short mode. If the path 53159 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53160 # take no chances and rewrite it. 53161 # Note: m4 eats our [], so we need to use [ and ] instead. 53162 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 53163 if test "x$has_forbidden_chars" != x; then 53164 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53165 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53166 fi 53167 53168 53169 windows_path="$new_path" 53170 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53171 unix_path=`$CYGPATH -u "$windows_path"` 53172 new_path="$unix_path" 53173 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53174 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 53175 new_path="$unix_path" 53176 fi 53177 53178 if test "x$path" != "x$new_path"; then 53179 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 53180 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 53181 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 53182 fi 53183 53184 # Save the first 10 bytes of this path to the storage, so fixpath can work. 53185 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 53186 53187 else 53188 # We're on a unix platform. Hooray! :) 53189 path="$POTENTIAL_FREETYPE_LIB_PATH" 53190 has_space=`$ECHO "$path" | $GREP " "` 53191 if test "x$has_space" != x; then 53192 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 53193 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 53194 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 53195 fi 53196 53197 # Use eval to expand a potential ~ 53198 eval path="$path" 53199 if test ! -f "$path" && test ! -d "$path"; then 53200 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 53201 fi 53202 53203 if test -d "$path"; then 53204 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 53205 else 53206 dir="`$DIRNAME "$path"`" 53207 base="`$BASENAME "$path"`" 53208 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 53209 fi 53210 fi 53211 fi 53212 53213 53214 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 53215 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 53216 $as_echo_n "checking for freetype includes... " >&6; } 53217 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 53218 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 53219 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 53220 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 53221 $as_echo_n "checking for freetype libraries... " >&6; } 53222 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 53223 $as_echo "$FREETYPE_LIB_PATH" >&6; } 53224 fi 53225 53226 if test "x$FOUND_FREETYPE" != xyes; then 53227 FREETYPE_BASE_DIR="$ProgramW6432/GnuWin32" 53228 53229 windows_path="$FREETYPE_BASE_DIR" 53230 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53231 unix_path=`$CYGPATH -u "$windows_path"` 53232 FREETYPE_BASE_DIR="$unix_path" 53233 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53234 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 53235 FREETYPE_BASE_DIR="$unix_path" 53236 fi 53237 53238 53239 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 53240 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 53241 METHOD="well-known location" 53242 53243 # Let's start with an optimistic view of the world :-) 53244 FOUND_FREETYPE=yes 53245 53246 # First look for the canonical freetype main include file ft2build.h. 53247 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 53248 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 53249 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 53250 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 53251 # Fail. 53252 FOUND_FREETYPE=no 53253 fi 53254 fi 53255 53256 if test "x$FOUND_FREETYPE" = xyes; then 53257 # Include file found, let's continue the sanity check. 53258 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 53259 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 53260 53261 # Reset to default value 53262 FREETYPE_BASE_NAME=freetype 53263 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 53264 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 53265 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 53266 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 53267 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 53268 # for the .6 version explicitly. 53269 FREETYPE_BASE_NAME=freetype.6 53270 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 53271 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 53272 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 53273 else 53274 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 53275 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 53276 FOUND_FREETYPE=no 53277 fi 53278 else 53279 if test "x$OPENJDK_TARGET_OS" = xwindows; then 53280 # On Windows, we will need both .lib and .dll file. 53281 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 53282 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 53283 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 53284 FOUND_FREETYPE=no 53285 fi 53286 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 53287 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 53288 # Found lib in isa dir, use that instead. 53289 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 53290 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 53291 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 53292 fi 53293 fi 53294 fi 53295 53296 if test "x$FOUND_FREETYPE" = xyes; then 53297 53298 # Only process if variable expands to non-empty 53299 53300 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 53301 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53302 53303 # Input might be given as Windows format, start by converting to 53304 # unix format. 53305 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 53306 new_path=`$CYGPATH -u "$path"` 53307 53308 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 53309 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 53310 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 53311 # "foo.exe" is OK but "foo" is an error. 53312 # 53313 # This test is therefore slightly more accurate than "test -f" to check for file precense. 53314 # It is also a way to make sure we got the proper file name for the real test later on. 53315 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 53316 if test "x$test_shortpath" = x; then 53317 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 53318 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 53319 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 53320 fi 53321 53322 # Call helper function which possibly converts this using DOS-style short mode. 53323 # If so, the updated path is stored in $new_path. 53324 53325 input_path="$new_path" 53326 # Check if we need to convert this using DOS-style short mode. If the path 53327 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53328 # take no chances and rewrite it. 53329 # Note: m4 eats our [], so we need to use [ and ] instead. 53330 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 53331 if test "x$has_forbidden_chars" != x; then 53332 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53333 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 53334 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 53335 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 53336 # Going to short mode and back again did indeed matter. Since short mode is 53337 # case insensitive, let's make it lowercase to improve readability. 53338 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53339 # Now convert it back to Unix-style (cygpath) 53340 input_path=`$CYGPATH -u "$shortmode_path"` 53341 new_path="$input_path" 53342 fi 53343 fi 53344 53345 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 53346 if test "x$test_cygdrive_prefix" = x; then 53347 # As a simple fix, exclude /usr/bin since it's not a real path. 53348 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 53349 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 53350 # a path prefixed by /cygdrive for fixpath to work. 53351 new_path="$CYGWIN_ROOT_PATH$input_path" 53352 fi 53353 fi 53354 53355 53356 if test "x$path" != "x$new_path"; then 53357 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 53358 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 53359 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 53360 fi 53361 53362 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53363 53364 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 53365 has_colon=`$ECHO $path | $GREP ^.:` 53366 new_path="$path" 53367 if test "x$has_colon" = x; then 53368 # Not in mixed or Windows style, start by that. 53369 new_path=`cmd //c echo $path` 53370 fi 53371 53372 53373 input_path="$new_path" 53374 # Check if we need to convert this using DOS-style short mode. If the path 53375 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53376 # take no chances and rewrite it. 53377 # Note: m4 eats our [], so we need to use [ and ] instead. 53378 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 53379 if test "x$has_forbidden_chars" != x; then 53380 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53381 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53382 fi 53383 53384 53385 windows_path="$new_path" 53386 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53387 unix_path=`$CYGPATH -u "$windows_path"` 53388 new_path="$unix_path" 53389 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53390 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 53391 new_path="$unix_path" 53392 fi 53393 53394 if test "x$path" != "x$new_path"; then 53395 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 53396 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 53397 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 53398 fi 53399 53400 # Save the first 10 bytes of this path to the storage, so fixpath can work. 53401 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 53402 53403 else 53404 # We're on a unix platform. Hooray! :) 53405 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 53406 has_space=`$ECHO "$path" | $GREP " "` 53407 if test "x$has_space" != x; then 53408 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 53409 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 53410 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 53411 fi 53412 53413 # Use eval to expand a potential ~ 53414 eval path="$path" 53415 if test ! -f "$path" && test ! -d "$path"; then 53416 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 53417 fi 53418 53419 if test -d "$path"; then 53420 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 53421 else 53422 dir="`$DIRNAME "$path"`" 53423 base="`$BASENAME "$path"`" 53424 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 53425 fi 53426 fi 53427 fi 53428 53429 53430 # Only process if variable expands to non-empty 53431 53432 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 53433 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53434 53435 # Input might be given as Windows format, start by converting to 53436 # unix format. 53437 path="$POTENTIAL_FREETYPE_LIB_PATH" 53438 new_path=`$CYGPATH -u "$path"` 53439 53440 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 53441 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 53442 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 53443 # "foo.exe" is OK but "foo" is an error. 53444 # 53445 # This test is therefore slightly more accurate than "test -f" to check for file precense. 53446 # It is also a way to make sure we got the proper file name for the real test later on. 53447 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 53448 if test "x$test_shortpath" = x; then 53449 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 53450 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 53451 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 53452 fi 53453 53454 # Call helper function which possibly converts this using DOS-style short mode. 53455 # If so, the updated path is stored in $new_path. 53456 53457 input_path="$new_path" 53458 # Check if we need to convert this using DOS-style short mode. If the path 53459 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53460 # take no chances and rewrite it. 53461 # Note: m4 eats our [], so we need to use [ and ] instead. 53462 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 53463 if test "x$has_forbidden_chars" != x; then 53464 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53465 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 53466 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 53467 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 53468 # Going to short mode and back again did indeed matter. Since short mode is 53469 # case insensitive, let's make it lowercase to improve readability. 53470 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53471 # Now convert it back to Unix-style (cygpath) 53472 input_path=`$CYGPATH -u "$shortmode_path"` 53473 new_path="$input_path" 53474 fi 53475 fi 53476 53477 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 53478 if test "x$test_cygdrive_prefix" = x; then 53479 # As a simple fix, exclude /usr/bin since it's not a real path. 53480 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 53481 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 53482 # a path prefixed by /cygdrive for fixpath to work. 53483 new_path="$CYGWIN_ROOT_PATH$input_path" 53484 fi 53485 fi 53486 53487 53488 if test "x$path" != "x$new_path"; then 53489 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 53490 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 53491 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 53492 fi 53493 53494 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53495 53496 path="$POTENTIAL_FREETYPE_LIB_PATH" 53497 has_colon=`$ECHO $path | $GREP ^.:` 53498 new_path="$path" 53499 if test "x$has_colon" = x; then 53500 # Not in mixed or Windows style, start by that. 53501 new_path=`cmd //c echo $path` 53502 fi 53503 53504 53505 input_path="$new_path" 53506 # Check if we need to convert this using DOS-style short mode. If the path 53507 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53508 # take no chances and rewrite it. 53509 # Note: m4 eats our [], so we need to use [ and ] instead. 53510 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 53511 if test "x$has_forbidden_chars" != x; then 53512 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53513 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53514 fi 53515 53516 53517 windows_path="$new_path" 53518 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53519 unix_path=`$CYGPATH -u "$windows_path"` 53520 new_path="$unix_path" 53521 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53522 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 53523 new_path="$unix_path" 53524 fi 53525 53526 if test "x$path" != "x$new_path"; then 53527 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 53528 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 53529 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 53530 fi 53531 53532 # Save the first 10 bytes of this path to the storage, so fixpath can work. 53533 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 53534 53535 else 53536 # We're on a unix platform. Hooray! :) 53537 path="$POTENTIAL_FREETYPE_LIB_PATH" 53538 has_space=`$ECHO "$path" | $GREP " "` 53539 if test "x$has_space" != x; then 53540 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 53541 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 53542 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 53543 fi 53544 53545 # Use eval to expand a potential ~ 53546 eval path="$path" 53547 if test ! -f "$path" && test ! -d "$path"; then 53548 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 53549 fi 53550 53551 if test -d "$path"; then 53552 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 53553 else 53554 dir="`$DIRNAME "$path"`" 53555 base="`$BASENAME "$path"`" 53556 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 53557 fi 53558 fi 53559 fi 53560 53561 53562 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 53563 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 53564 $as_echo_n "checking for freetype includes... " >&6; } 53565 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 53566 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 53567 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 53568 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 53569 $as_echo_n "checking for freetype libraries... " >&6; } 53570 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 53571 $as_echo "$FREETYPE_LIB_PATH" >&6; } 53572 fi 53573 53574 fi 53575 if test "x$FOUND_FREETYPE" != xyes; then 53576 FREETYPE_BASE_DIR="$HOME/freetype" 53577 53578 windows_path="$FREETYPE_BASE_DIR" 53579 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53580 unix_path=`$CYGPATH -u "$windows_path"` 53581 FREETYPE_BASE_DIR="$unix_path" 53582 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53583 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 53584 FREETYPE_BASE_DIR="$unix_path" 53585 fi 53586 53587 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 53588 53589 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 53590 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib64" 53591 METHOD="well-known location" 53592 53593 # Let's start with an optimistic view of the world :-) 53594 FOUND_FREETYPE=yes 53595 53596 # First look for the canonical freetype main include file ft2build.h. 53597 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 53598 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 53599 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 53600 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 53601 # Fail. 53602 FOUND_FREETYPE=no 53603 fi 53604 fi 53605 53606 if test "x$FOUND_FREETYPE" = xyes; then 53607 # Include file found, let's continue the sanity check. 53608 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 53609 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 53610 53611 # Reset to default value 53612 FREETYPE_BASE_NAME=freetype 53613 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 53614 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 53615 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 53616 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 53617 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 53618 # for the .6 version explicitly. 53619 FREETYPE_BASE_NAME=freetype.6 53620 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 53621 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 53622 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 53623 else 53624 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 53625 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 53626 FOUND_FREETYPE=no 53627 fi 53628 else 53629 if test "x$OPENJDK_TARGET_OS" = xwindows; then 53630 # On Windows, we will need both .lib and .dll file. 53631 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 53632 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 53633 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 53634 FOUND_FREETYPE=no 53635 fi 53636 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 53637 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 53638 # Found lib in isa dir, use that instead. 53639 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 53640 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 53641 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 53642 fi 53643 fi 53644 fi 53645 53646 if test "x$FOUND_FREETYPE" = xyes; then 53647 53648 # Only process if variable expands to non-empty 53649 53650 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 53651 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53652 53653 # Input might be given as Windows format, start by converting to 53654 # unix format. 53655 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 53656 new_path=`$CYGPATH -u "$path"` 53657 53658 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 53659 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 53660 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 53661 # "foo.exe" is OK but "foo" is an error. 53662 # 53663 # This test is therefore slightly more accurate than "test -f" to check for file precense. 53664 # It is also a way to make sure we got the proper file name for the real test later on. 53665 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 53666 if test "x$test_shortpath" = x; then 53667 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 53668 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 53669 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 53670 fi 53671 53672 # Call helper function which possibly converts this using DOS-style short mode. 53673 # If so, the updated path is stored in $new_path. 53674 53675 input_path="$new_path" 53676 # Check if we need to convert this using DOS-style short mode. If the path 53677 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53678 # take no chances and rewrite it. 53679 # Note: m4 eats our [], so we need to use [ and ] instead. 53680 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 53681 if test "x$has_forbidden_chars" != x; then 53682 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53683 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 53684 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 53685 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 53686 # Going to short mode and back again did indeed matter. Since short mode is 53687 # case insensitive, let's make it lowercase to improve readability. 53688 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53689 # Now convert it back to Unix-style (cygpath) 53690 input_path=`$CYGPATH -u "$shortmode_path"` 53691 new_path="$input_path" 53692 fi 53693 fi 53694 53695 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 53696 if test "x$test_cygdrive_prefix" = x; then 53697 # As a simple fix, exclude /usr/bin since it's not a real path. 53698 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 53699 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 53700 # a path prefixed by /cygdrive for fixpath to work. 53701 new_path="$CYGWIN_ROOT_PATH$input_path" 53702 fi 53703 fi 53704 53705 53706 if test "x$path" != "x$new_path"; then 53707 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 53708 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 53709 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 53710 fi 53711 53712 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53713 53714 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 53715 has_colon=`$ECHO $path | $GREP ^.:` 53716 new_path="$path" 53717 if test "x$has_colon" = x; then 53718 # Not in mixed or Windows style, start by that. 53719 new_path=`cmd //c echo $path` 53720 fi 53721 53722 53723 input_path="$new_path" 53724 # Check if we need to convert this using DOS-style short mode. If the path 53725 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53726 # take no chances and rewrite it. 53727 # Note: m4 eats our [], so we need to use [ and ] instead. 53728 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 53729 if test "x$has_forbidden_chars" != x; then 53730 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53731 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53732 fi 53733 53734 53735 windows_path="$new_path" 53736 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53737 unix_path=`$CYGPATH -u "$windows_path"` 53738 new_path="$unix_path" 53739 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53740 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 53741 new_path="$unix_path" 53742 fi 53743 53744 if test "x$path" != "x$new_path"; then 53745 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 53746 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 53747 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 53748 fi 53749 53750 # Save the first 10 bytes of this path to the storage, so fixpath can work. 53751 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 53752 53753 else 53754 # We're on a unix platform. Hooray! :) 53755 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 53756 has_space=`$ECHO "$path" | $GREP " "` 53757 if test "x$has_space" != x; then 53758 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 53759 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 53760 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 53761 fi 53762 53763 # Use eval to expand a potential ~ 53764 eval path="$path" 53765 if test ! -f "$path" && test ! -d "$path"; then 53766 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 53767 fi 53768 53769 if test -d "$path"; then 53770 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 53771 else 53772 dir="`$DIRNAME "$path"`" 53773 base="`$BASENAME "$path"`" 53774 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 53775 fi 53776 fi 53777 fi 53778 53779 53780 # Only process if variable expands to non-empty 53781 53782 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 53783 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53784 53785 # Input might be given as Windows format, start by converting to 53786 # unix format. 53787 path="$POTENTIAL_FREETYPE_LIB_PATH" 53788 new_path=`$CYGPATH -u "$path"` 53789 53790 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 53791 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 53792 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 53793 # "foo.exe" is OK but "foo" is an error. 53794 # 53795 # This test is therefore slightly more accurate than "test -f" to check for file precense. 53796 # It is also a way to make sure we got the proper file name for the real test later on. 53797 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 53798 if test "x$test_shortpath" = x; then 53799 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 53800 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 53801 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 53802 fi 53803 53804 # Call helper function which possibly converts this using DOS-style short mode. 53805 # If so, the updated path is stored in $new_path. 53806 53807 input_path="$new_path" 53808 # Check if we need to convert this using DOS-style short mode. If the path 53809 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53810 # take no chances and rewrite it. 53811 # Note: m4 eats our [], so we need to use [ and ] instead. 53812 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 53813 if test "x$has_forbidden_chars" != x; then 53814 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53815 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 53816 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 53817 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 53818 # Going to short mode and back again did indeed matter. Since short mode is 53819 # case insensitive, let's make it lowercase to improve readability. 53820 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53821 # Now convert it back to Unix-style (cygpath) 53822 input_path=`$CYGPATH -u "$shortmode_path"` 53823 new_path="$input_path" 53824 fi 53825 fi 53826 53827 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 53828 if test "x$test_cygdrive_prefix" = x; then 53829 # As a simple fix, exclude /usr/bin since it's not a real path. 53830 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 53831 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 53832 # a path prefixed by /cygdrive for fixpath to work. 53833 new_path="$CYGWIN_ROOT_PATH$input_path" 53834 fi 53835 fi 53836 53837 53838 if test "x$path" != "x$new_path"; then 53839 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 53840 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 53841 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 53842 fi 53843 53844 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53845 53846 path="$POTENTIAL_FREETYPE_LIB_PATH" 53847 has_colon=`$ECHO $path | $GREP ^.:` 53848 new_path="$path" 53849 if test "x$has_colon" = x; then 53850 # Not in mixed or Windows style, start by that. 53851 new_path=`cmd //c echo $path` 53852 fi 53853 53854 53855 input_path="$new_path" 53856 # Check if we need to convert this using DOS-style short mode. If the path 53857 # contains just simple characters, use it. Otherwise (spaces, weird characters), 53858 # take no chances and rewrite it. 53859 # Note: m4 eats our [], so we need to use [ and ] instead. 53860 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 53861 if test "x$has_forbidden_chars" != x; then 53862 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 53863 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 53864 fi 53865 53866 53867 windows_path="$new_path" 53868 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53869 unix_path=`$CYGPATH -u "$windows_path"` 53870 new_path="$unix_path" 53871 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 53872 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 53873 new_path="$unix_path" 53874 fi 53875 53876 if test "x$path" != "x$new_path"; then 53877 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 53878 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 53879 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 53880 fi 53881 53882 # Save the first 10 bytes of this path to the storage, so fixpath can work. 53883 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 53884 53885 else 53886 # We're on a unix platform. Hooray! :) 53887 path="$POTENTIAL_FREETYPE_LIB_PATH" 53888 has_space=`$ECHO "$path" | $GREP " "` 53889 if test "x$has_space" != x; then 53890 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 53891 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 53892 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 53893 fi 53894 53895 # Use eval to expand a potential ~ 53896 eval path="$path" 53897 if test ! -f "$path" && test ! -d "$path"; then 53898 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 53899 fi 53900 53901 if test -d "$path"; then 53902 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 53903 else 53904 dir="`$DIRNAME "$path"`" 53905 base="`$BASENAME "$path"`" 53906 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 53907 fi 53908 fi 53909 fi 53910 53911 53912 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 53913 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 53914 $as_echo_n "checking for freetype includes... " >&6; } 53915 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 53916 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 53917 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 53918 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 53919 $as_echo_n "checking for freetype libraries... " >&6; } 53920 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 53921 $as_echo "$FREETYPE_LIB_PATH" >&6; } 53922 fi 53923 53924 else 53925 53926 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 53927 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib32" 53928 METHOD="well-known location" 53929 53930 # Let's start with an optimistic view of the world :-) 53931 FOUND_FREETYPE=yes 53932 53933 # First look for the canonical freetype main include file ft2build.h. 53934 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 53935 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 53936 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 53937 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 53938 # Fail. 53939 FOUND_FREETYPE=no 53940 fi 53941 fi 53942 53943 if test "x$FOUND_FREETYPE" = xyes; then 53944 # Include file found, let's continue the sanity check. 53945 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 53946 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 53947 53948 # Reset to default value 53949 FREETYPE_BASE_NAME=freetype 53950 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 53951 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 53952 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 53953 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 53954 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 53955 # for the .6 version explicitly. 53956 FREETYPE_BASE_NAME=freetype.6 53957 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 53958 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 53959 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 53960 else 53961 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 53962 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 53963 FOUND_FREETYPE=no 53964 fi 53965 else 53966 if test "x$OPENJDK_TARGET_OS" = xwindows; then 53967 # On Windows, we will need both .lib and .dll file. 53968 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 53969 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 53970 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 53971 FOUND_FREETYPE=no 53972 fi 53973 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 53974 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 53975 # Found lib in isa dir, use that instead. 53976 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 53977 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 53978 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 53979 fi 53980 fi 53981 fi 53982 53983 if test "x$FOUND_FREETYPE" = xyes; then 53984 53985 # Only process if variable expands to non-empty 53986 53987 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 53988 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 53989 53990 # Input might be given as Windows format, start by converting to 53991 # unix format. 53992 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 53993 new_path=`$CYGPATH -u "$path"` 53994 53995 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 53996 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 53997 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 53998 # "foo.exe" is OK but "foo" is an error. 53999 # 54000 # This test is therefore slightly more accurate than "test -f" to check for file precense. 54001 # It is also a way to make sure we got the proper file name for the real test later on. 54002 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 54003 if test "x$test_shortpath" = x; then 54004 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 54005 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 54006 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 54007 fi 54008 54009 # Call helper function which possibly converts this using DOS-style short mode. 54010 # If so, the updated path is stored in $new_path. 54011 54012 input_path="$new_path" 54013 # Check if we need to convert this using DOS-style short mode. If the path 54014 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54015 # take no chances and rewrite it. 54016 # Note: m4 eats our [], so we need to use [ and ] instead. 54017 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 54018 if test "x$has_forbidden_chars" != x; then 54019 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54020 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 54021 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 54022 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 54023 # Going to short mode and back again did indeed matter. Since short mode is 54024 # case insensitive, let's make it lowercase to improve readability. 54025 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54026 # Now convert it back to Unix-style (cygpath) 54027 input_path=`$CYGPATH -u "$shortmode_path"` 54028 new_path="$input_path" 54029 fi 54030 fi 54031 54032 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 54033 if test "x$test_cygdrive_prefix" = x; then 54034 # As a simple fix, exclude /usr/bin since it's not a real path. 54035 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 54036 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 54037 # a path prefixed by /cygdrive for fixpath to work. 54038 new_path="$CYGWIN_ROOT_PATH$input_path" 54039 fi 54040 fi 54041 54042 54043 if test "x$path" != "x$new_path"; then 54044 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 54045 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 54046 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 54047 fi 54048 54049 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54050 54051 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 54052 has_colon=`$ECHO $path | $GREP ^.:` 54053 new_path="$path" 54054 if test "x$has_colon" = x; then 54055 # Not in mixed or Windows style, start by that. 54056 new_path=`cmd //c echo $path` 54057 fi 54058 54059 54060 input_path="$new_path" 54061 # Check if we need to convert this using DOS-style short mode. If the path 54062 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54063 # take no chances and rewrite it. 54064 # Note: m4 eats our [], so we need to use [ and ] instead. 54065 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 54066 if test "x$has_forbidden_chars" != x; then 54067 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54068 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54069 fi 54070 54071 54072 windows_path="$new_path" 54073 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54074 unix_path=`$CYGPATH -u "$windows_path"` 54075 new_path="$unix_path" 54076 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54077 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54078 new_path="$unix_path" 54079 fi 54080 54081 if test "x$path" != "x$new_path"; then 54082 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 54083 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 54084 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 54085 fi 54086 54087 # Save the first 10 bytes of this path to the storage, so fixpath can work. 54088 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 54089 54090 else 54091 # We're on a unix platform. Hooray! :) 54092 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 54093 has_space=`$ECHO "$path" | $GREP " "` 54094 if test "x$has_space" != x; then 54095 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 54096 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 54097 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 54098 fi 54099 54100 # Use eval to expand a potential ~ 54101 eval path="$path" 54102 if test ! -f "$path" && test ! -d "$path"; then 54103 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 54104 fi 54105 54106 if test -d "$path"; then 54107 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 54108 else 54109 dir="`$DIRNAME "$path"`" 54110 base="`$BASENAME "$path"`" 54111 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 54112 fi 54113 fi 54114 fi 54115 54116 54117 # Only process if variable expands to non-empty 54118 54119 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 54120 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54121 54122 # Input might be given as Windows format, start by converting to 54123 # unix format. 54124 path="$POTENTIAL_FREETYPE_LIB_PATH" 54125 new_path=`$CYGPATH -u "$path"` 54126 54127 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 54128 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 54129 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 54130 # "foo.exe" is OK but "foo" is an error. 54131 # 54132 # This test is therefore slightly more accurate than "test -f" to check for file precense. 54133 # It is also a way to make sure we got the proper file name for the real test later on. 54134 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 54135 if test "x$test_shortpath" = x; then 54136 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 54137 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 54138 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 54139 fi 54140 54141 # Call helper function which possibly converts this using DOS-style short mode. 54142 # If so, the updated path is stored in $new_path. 54143 54144 input_path="$new_path" 54145 # Check if we need to convert this using DOS-style short mode. If the path 54146 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54147 # take no chances and rewrite it. 54148 # Note: m4 eats our [], so we need to use [ and ] instead. 54149 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 54150 if test "x$has_forbidden_chars" != x; then 54151 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54152 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 54153 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 54154 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 54155 # Going to short mode and back again did indeed matter. Since short mode is 54156 # case insensitive, let's make it lowercase to improve readability. 54157 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54158 # Now convert it back to Unix-style (cygpath) 54159 input_path=`$CYGPATH -u "$shortmode_path"` 54160 new_path="$input_path" 54161 fi 54162 fi 54163 54164 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 54165 if test "x$test_cygdrive_prefix" = x; then 54166 # As a simple fix, exclude /usr/bin since it's not a real path. 54167 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 54168 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 54169 # a path prefixed by /cygdrive for fixpath to work. 54170 new_path="$CYGWIN_ROOT_PATH$input_path" 54171 fi 54172 fi 54173 54174 54175 if test "x$path" != "x$new_path"; then 54176 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 54177 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 54178 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 54179 fi 54180 54181 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54182 54183 path="$POTENTIAL_FREETYPE_LIB_PATH" 54184 has_colon=`$ECHO $path | $GREP ^.:` 54185 new_path="$path" 54186 if test "x$has_colon" = x; then 54187 # Not in mixed or Windows style, start by that. 54188 new_path=`cmd //c echo $path` 54189 fi 54190 54191 54192 input_path="$new_path" 54193 # Check if we need to convert this using DOS-style short mode. If the path 54194 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54195 # take no chances and rewrite it. 54196 # Note: m4 eats our [], so we need to use [ and ] instead. 54197 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 54198 if test "x$has_forbidden_chars" != x; then 54199 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54200 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54201 fi 54202 54203 54204 windows_path="$new_path" 54205 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54206 unix_path=`$CYGPATH -u "$windows_path"` 54207 new_path="$unix_path" 54208 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54209 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54210 new_path="$unix_path" 54211 fi 54212 54213 if test "x$path" != "x$new_path"; then 54214 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 54215 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 54216 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 54217 fi 54218 54219 # Save the first 10 bytes of this path to the storage, so fixpath can work. 54220 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 54221 54222 else 54223 # We're on a unix platform. Hooray! :) 54224 path="$POTENTIAL_FREETYPE_LIB_PATH" 54225 has_space=`$ECHO "$path" | $GREP " "` 54226 if test "x$has_space" != x; then 54227 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 54228 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 54229 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 54230 fi 54231 54232 # Use eval to expand a potential ~ 54233 eval path="$path" 54234 if test ! -f "$path" && test ! -d "$path"; then 54235 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 54236 fi 54237 54238 if test -d "$path"; then 54239 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 54240 else 54241 dir="`$DIRNAME "$path"`" 54242 base="`$BASENAME "$path"`" 54243 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 54244 fi 54245 fi 54246 fi 54247 54248 54249 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 54250 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 54251 $as_echo_n "checking for freetype includes... " >&6; } 54252 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 54253 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 54254 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 54255 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 54256 $as_echo_n "checking for freetype libraries... " >&6; } 54257 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 54258 $as_echo "$FREETYPE_LIB_PATH" >&6; } 54259 fi 54260 54261 fi 54262 if test "x$FOUND_FREETYPE" != xyes && test -d $FREETYPE_BASE_DIR \ 54263 && test -s "$FREETYPE_BASE_DIR/builds/windows/vc2010/freetype.vcxproj" && test "x$MSBUILD" != x; then 54264 # Source is available, as a last resort try to build freetype in default location 54265 54266 FREETYPE_SRC_PATH="$FREETYPE_BASE_DIR" 54267 BUILD_FREETYPE=yes 54268 54269 # Check if the freetype sources are acessible.. 54270 if ! test -d $FREETYPE_SRC_PATH; then 54271 { $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 54272 $as_echo "$as_me: WARNING: --with-freetype-src specified, but can not find path \"$FREETYPE_SRC_PATH\" - ignoring --with-freetype-src" >&2;} 54273 BUILD_FREETYPE=no 54274 fi 54275 # ..and contain a vc2010 project file 54276 vcxproj_path="$FREETYPE_SRC_PATH/builds/windows/vc2010/freetype.vcxproj" 54277 if test "x$BUILD_FREETYPE" = xyes && ! test -s $vcxproj_path; then 54278 { $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 54279 $as_echo "$as_me: WARNING: Can not find project file $vcxproj_path (you may try a newer freetype version) - ignoring --with-freetype-src" >&2;} 54280 BUILD_FREETYPE=no 54281 fi 54282 # Now check if configure found a version of 'msbuild.exe' 54283 if test "x$BUILD_FREETYPE" = xyes && test "x$MSBUILD" == x ; then 54284 { $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 54285 $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;} 54286 BUILD_FREETYPE=no 54287 fi 54288 54289 # Ready to go.. 54290 if test "x$BUILD_FREETYPE" = xyes; then 54291 # msbuild requires trailing slashes for output directories 54292 freetype_lib_path="$FREETYPE_SRC_PATH/lib$OPENJDK_TARGET_CPU_BITS/" 54293 freetype_lib_path_unix="$freetype_lib_path" 54294 freetype_obj_path="$FREETYPE_SRC_PATH/obj$OPENJDK_TARGET_CPU_BITS/" 54295 54296 unix_path="$vcxproj_path" 54297 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54298 windows_path=`$CYGPATH -m "$unix_path"` 54299 vcxproj_path="$windows_path" 54300 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54301 windows_path=`cmd //c echo $unix_path` 54302 vcxproj_path="$windows_path" 54303 fi 54304 54305 54306 unix_path="$freetype_lib_path" 54307 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54308 windows_path=`$CYGPATH -m "$unix_path"` 54309 freetype_lib_path="$windows_path" 54310 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54311 windows_path=`cmd //c echo $unix_path` 54312 freetype_lib_path="$windows_path" 54313 fi 54314 54315 54316 unix_path="$freetype_obj_path" 54317 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54318 windows_path=`$CYGPATH -m "$unix_path"` 54319 freetype_obj_path="$windows_path" 54320 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54321 windows_path=`cmd //c echo $unix_path` 54322 freetype_obj_path="$windows_path" 54323 fi 54324 54325 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 54326 freetype_platform=x64 54327 else 54328 freetype_platform=win32 54329 fi 54330 54331 # The original freetype project file is for VS 2010 (i.e. 'v100'), 54332 # so we have to adapt the toolset if building with any other toolsed (i.e. SDK). 54333 # Currently 'PLATFORM_TOOLSET' is set in 'TOOLCHAIN_CHECK_POSSIBLE_VISUAL_STUDIO_ROOT'/ 54334 # 'TOOLCHAIN_CHECK_POSSIBLE_WIN_SDK_ROOT' in toolchain_windows.m4 54335 { $as_echo "$as_me:${as_lineno-$LINENO}: Trying to compile freetype sources with PlatformToolset=$PLATFORM_TOOLSET to $freetype_lib_path_unix ..." >&5 54336 $as_echo "$as_me: Trying to compile freetype sources with PlatformToolset=$PLATFORM_TOOLSET to $freetype_lib_path_unix ..." >&6;} 54337 54338 # First we try to build the freetype.dll 54339 $ECHO -e "@echo off\n"\ 54340 "$MSBUILD $vcxproj_path "\ 54341 "/p:PlatformToolset=$PLATFORM_TOOLSET "\ 54342 "/p:Configuration=\"Release Multithreaded\" "\ 54343 "/p:Platform=$freetype_platform "\ 54344 "/p:ConfigurationType=DynamicLibrary "\ 54345 "/p:TargetName=freetype "\ 54346 "/p:OutDir=\"$freetype_lib_path\" "\ 54347 "/p:IntDir=\"$freetype_obj_path\" > freetype.log" > freetype.bat 54348 cmd /c freetype.bat 54349 54350 if test -s "$freetype_lib_path_unix/freetype.dll"; then 54351 # If that succeeds we also build freetype.lib 54352 $ECHO -e "@echo off\n"\ 54353 "$MSBUILD $vcxproj_path "\ 54354 "/p:PlatformToolset=$PLATFORM_TOOLSET "\ 54355 "/p:Configuration=\"Release Multithreaded\" "\ 54356 "/p:Platform=$freetype_platform "\ 54357 "/p:ConfigurationType=StaticLibrary "\ 54358 "/p:TargetName=freetype "\ 54359 "/p:OutDir=\"$freetype_lib_path\" "\ 54360 "/p:IntDir=\"$freetype_obj_path\" >> freetype.log" > freetype.bat 54361 cmd /c freetype.bat 54362 54363 if test -s "$freetype_lib_path_unix/freetype.lib"; then 54364 # Once we build both, lib and dll, set freetype lib and include path appropriately 54365 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_SRC_PATH/include" 54366 POTENTIAL_FREETYPE_LIB_PATH="$freetype_lib_path_unix" 54367 { $as_echo "$as_me:${as_lineno-$LINENO}: Compiling freetype sources succeeded! (see freetype.log for build results)" >&5 54368 $as_echo "$as_me: Compiling freetype sources succeeded! (see freetype.log for build results)" >&6;} 54369 else 54370 BUILD_FREETYPE=no 54371 fi 54372 else 54373 BUILD_FREETYPE=no 54374 fi 54375 fi 54376 54377 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 54378 54379 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 54380 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib64" 54381 METHOD="well-known location" 54382 54383 # Let's start with an optimistic view of the world :-) 54384 FOUND_FREETYPE=yes 54385 54386 # First look for the canonical freetype main include file ft2build.h. 54387 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 54388 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 54389 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 54390 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 54391 # Fail. 54392 FOUND_FREETYPE=no 54393 fi 54394 fi 54395 54396 if test "x$FOUND_FREETYPE" = xyes; then 54397 # Include file found, let's continue the sanity check. 54398 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 54399 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 54400 54401 # Reset to default value 54402 FREETYPE_BASE_NAME=freetype 54403 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 54404 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 54405 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 54406 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 54407 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 54408 # for the .6 version explicitly. 54409 FREETYPE_BASE_NAME=freetype.6 54410 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 54411 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 54412 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 54413 else 54414 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 54415 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 54416 FOUND_FREETYPE=no 54417 fi 54418 else 54419 if test "x$OPENJDK_TARGET_OS" = xwindows; then 54420 # On Windows, we will need both .lib and .dll file. 54421 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 54422 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 54423 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 54424 FOUND_FREETYPE=no 54425 fi 54426 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 54427 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 54428 # Found lib in isa dir, use that instead. 54429 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 54430 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 54431 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 54432 fi 54433 fi 54434 fi 54435 54436 if test "x$FOUND_FREETYPE" = xyes; then 54437 54438 # Only process if variable expands to non-empty 54439 54440 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 54441 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54442 54443 # Input might be given as Windows format, start by converting to 54444 # unix format. 54445 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 54446 new_path=`$CYGPATH -u "$path"` 54447 54448 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 54449 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 54450 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 54451 # "foo.exe" is OK but "foo" is an error. 54452 # 54453 # This test is therefore slightly more accurate than "test -f" to check for file precense. 54454 # It is also a way to make sure we got the proper file name for the real test later on. 54455 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 54456 if test "x$test_shortpath" = x; then 54457 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 54458 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 54459 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 54460 fi 54461 54462 # Call helper function which possibly converts this using DOS-style short mode. 54463 # If so, the updated path is stored in $new_path. 54464 54465 input_path="$new_path" 54466 # Check if we need to convert this using DOS-style short mode. If the path 54467 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54468 # take no chances and rewrite it. 54469 # Note: m4 eats our [], so we need to use [ and ] instead. 54470 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 54471 if test "x$has_forbidden_chars" != x; then 54472 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54473 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 54474 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 54475 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 54476 # Going to short mode and back again did indeed matter. Since short mode is 54477 # case insensitive, let's make it lowercase to improve readability. 54478 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54479 # Now convert it back to Unix-style (cygpath) 54480 input_path=`$CYGPATH -u "$shortmode_path"` 54481 new_path="$input_path" 54482 fi 54483 fi 54484 54485 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 54486 if test "x$test_cygdrive_prefix" = x; then 54487 # As a simple fix, exclude /usr/bin since it's not a real path. 54488 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 54489 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 54490 # a path prefixed by /cygdrive for fixpath to work. 54491 new_path="$CYGWIN_ROOT_PATH$input_path" 54492 fi 54493 fi 54494 54495 54496 if test "x$path" != "x$new_path"; then 54497 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 54498 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 54499 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 54500 fi 54501 54502 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54503 54504 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 54505 has_colon=`$ECHO $path | $GREP ^.:` 54506 new_path="$path" 54507 if test "x$has_colon" = x; then 54508 # Not in mixed or Windows style, start by that. 54509 new_path=`cmd //c echo $path` 54510 fi 54511 54512 54513 input_path="$new_path" 54514 # Check if we need to convert this using DOS-style short mode. If the path 54515 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54516 # take no chances and rewrite it. 54517 # Note: m4 eats our [], so we need to use [ and ] instead. 54518 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 54519 if test "x$has_forbidden_chars" != x; then 54520 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54521 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54522 fi 54523 54524 54525 windows_path="$new_path" 54526 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54527 unix_path=`$CYGPATH -u "$windows_path"` 54528 new_path="$unix_path" 54529 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54530 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54531 new_path="$unix_path" 54532 fi 54533 54534 if test "x$path" != "x$new_path"; then 54535 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 54536 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 54537 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 54538 fi 54539 54540 # Save the first 10 bytes of this path to the storage, so fixpath can work. 54541 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 54542 54543 else 54544 # We're on a unix platform. Hooray! :) 54545 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 54546 has_space=`$ECHO "$path" | $GREP " "` 54547 if test "x$has_space" != x; then 54548 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 54549 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 54550 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 54551 fi 54552 54553 # Use eval to expand a potential ~ 54554 eval path="$path" 54555 if test ! -f "$path" && test ! -d "$path"; then 54556 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 54557 fi 54558 54559 if test -d "$path"; then 54560 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 54561 else 54562 dir="`$DIRNAME "$path"`" 54563 base="`$BASENAME "$path"`" 54564 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 54565 fi 54566 fi 54567 fi 54568 54569 54570 # Only process if variable expands to non-empty 54571 54572 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 54573 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54574 54575 # Input might be given as Windows format, start by converting to 54576 # unix format. 54577 path="$POTENTIAL_FREETYPE_LIB_PATH" 54578 new_path=`$CYGPATH -u "$path"` 54579 54580 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 54581 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 54582 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 54583 # "foo.exe" is OK but "foo" is an error. 54584 # 54585 # This test is therefore slightly more accurate than "test -f" to check for file precense. 54586 # It is also a way to make sure we got the proper file name for the real test later on. 54587 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 54588 if test "x$test_shortpath" = x; then 54589 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 54590 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 54591 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 54592 fi 54593 54594 # Call helper function which possibly converts this using DOS-style short mode. 54595 # If so, the updated path is stored in $new_path. 54596 54597 input_path="$new_path" 54598 # Check if we need to convert this using DOS-style short mode. If the path 54599 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54600 # take no chances and rewrite it. 54601 # Note: m4 eats our [], so we need to use [ and ] instead. 54602 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 54603 if test "x$has_forbidden_chars" != x; then 54604 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54605 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 54606 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 54607 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 54608 # Going to short mode and back again did indeed matter. Since short mode is 54609 # case insensitive, let's make it lowercase to improve readability. 54610 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54611 # Now convert it back to Unix-style (cygpath) 54612 input_path=`$CYGPATH -u "$shortmode_path"` 54613 new_path="$input_path" 54614 fi 54615 fi 54616 54617 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 54618 if test "x$test_cygdrive_prefix" = x; then 54619 # As a simple fix, exclude /usr/bin since it's not a real path. 54620 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 54621 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 54622 # a path prefixed by /cygdrive for fixpath to work. 54623 new_path="$CYGWIN_ROOT_PATH$input_path" 54624 fi 54625 fi 54626 54627 54628 if test "x$path" != "x$new_path"; then 54629 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 54630 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 54631 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 54632 fi 54633 54634 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54635 54636 path="$POTENTIAL_FREETYPE_LIB_PATH" 54637 has_colon=`$ECHO $path | $GREP ^.:` 54638 new_path="$path" 54639 if test "x$has_colon" = x; then 54640 # Not in mixed or Windows style, start by that. 54641 new_path=`cmd //c echo $path` 54642 fi 54643 54644 54645 input_path="$new_path" 54646 # Check if we need to convert this using DOS-style short mode. If the path 54647 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54648 # take no chances and rewrite it. 54649 # Note: m4 eats our [], so we need to use [ and ] instead. 54650 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 54651 if test "x$has_forbidden_chars" != x; then 54652 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54653 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54654 fi 54655 54656 54657 windows_path="$new_path" 54658 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54659 unix_path=`$CYGPATH -u "$windows_path"` 54660 new_path="$unix_path" 54661 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54662 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54663 new_path="$unix_path" 54664 fi 54665 54666 if test "x$path" != "x$new_path"; then 54667 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 54668 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 54669 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 54670 fi 54671 54672 # Save the first 10 bytes of this path to the storage, so fixpath can work. 54673 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 54674 54675 else 54676 # We're on a unix platform. Hooray! :) 54677 path="$POTENTIAL_FREETYPE_LIB_PATH" 54678 has_space=`$ECHO "$path" | $GREP " "` 54679 if test "x$has_space" != x; then 54680 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 54681 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 54682 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 54683 fi 54684 54685 # Use eval to expand a potential ~ 54686 eval path="$path" 54687 if test ! -f "$path" && test ! -d "$path"; then 54688 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 54689 fi 54690 54691 if test -d "$path"; then 54692 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 54693 else 54694 dir="`$DIRNAME "$path"`" 54695 base="`$BASENAME "$path"`" 54696 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 54697 fi 54698 fi 54699 fi 54700 54701 54702 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 54703 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 54704 $as_echo_n "checking for freetype includes... " >&6; } 54705 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 54706 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 54707 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 54708 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 54709 $as_echo_n "checking for freetype libraries... " >&6; } 54710 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 54711 $as_echo "$FREETYPE_LIB_PATH" >&6; } 54712 fi 54713 54714 else 54715 54716 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 54717 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib32" 54718 METHOD="well-known location" 54719 54720 # Let's start with an optimistic view of the world :-) 54721 FOUND_FREETYPE=yes 54722 54723 # First look for the canonical freetype main include file ft2build.h. 54724 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 54725 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 54726 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 54727 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 54728 # Fail. 54729 FOUND_FREETYPE=no 54730 fi 54731 fi 54732 54733 if test "x$FOUND_FREETYPE" = xyes; then 54734 # Include file found, let's continue the sanity check. 54735 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 54736 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 54737 54738 # Reset to default value 54739 FREETYPE_BASE_NAME=freetype 54740 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 54741 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 54742 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 54743 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 54744 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 54745 # for the .6 version explicitly. 54746 FREETYPE_BASE_NAME=freetype.6 54747 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 54748 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 54749 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 54750 else 54751 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 54752 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 54753 FOUND_FREETYPE=no 54754 fi 54755 else 54756 if test "x$OPENJDK_TARGET_OS" = xwindows; then 54757 # On Windows, we will need both .lib and .dll file. 54758 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 54759 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 54760 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 54761 FOUND_FREETYPE=no 54762 fi 54763 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 54764 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 54765 # Found lib in isa dir, use that instead. 54766 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 54767 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 54768 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 54769 fi 54770 fi 54771 fi 54772 54773 if test "x$FOUND_FREETYPE" = xyes; then 54774 54775 # Only process if variable expands to non-empty 54776 54777 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 54778 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54779 54780 # Input might be given as Windows format, start by converting to 54781 # unix format. 54782 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 54783 new_path=`$CYGPATH -u "$path"` 54784 54785 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 54786 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 54787 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 54788 # "foo.exe" is OK but "foo" is an error. 54789 # 54790 # This test is therefore slightly more accurate than "test -f" to check for file precense. 54791 # It is also a way to make sure we got the proper file name for the real test later on. 54792 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 54793 if test "x$test_shortpath" = x; then 54794 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 54795 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 54796 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 54797 fi 54798 54799 # Call helper function which possibly converts this using DOS-style short mode. 54800 # If so, the updated path is stored in $new_path. 54801 54802 input_path="$new_path" 54803 # Check if we need to convert this using DOS-style short mode. If the path 54804 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54805 # take no chances and rewrite it. 54806 # Note: m4 eats our [], so we need to use [ and ] instead. 54807 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 54808 if test "x$has_forbidden_chars" != x; then 54809 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54810 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 54811 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 54812 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 54813 # Going to short mode and back again did indeed matter. Since short mode is 54814 # case insensitive, let's make it lowercase to improve readability. 54815 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54816 # Now convert it back to Unix-style (cygpath) 54817 input_path=`$CYGPATH -u "$shortmode_path"` 54818 new_path="$input_path" 54819 fi 54820 fi 54821 54822 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 54823 if test "x$test_cygdrive_prefix" = x; then 54824 # As a simple fix, exclude /usr/bin since it's not a real path. 54825 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 54826 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 54827 # a path prefixed by /cygdrive for fixpath to work. 54828 new_path="$CYGWIN_ROOT_PATH$input_path" 54829 fi 54830 fi 54831 54832 54833 if test "x$path" != "x$new_path"; then 54834 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 54835 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 54836 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 54837 fi 54838 54839 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54840 54841 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 54842 has_colon=`$ECHO $path | $GREP ^.:` 54843 new_path="$path" 54844 if test "x$has_colon" = x; then 54845 # Not in mixed or Windows style, start by that. 54846 new_path=`cmd //c echo $path` 54847 fi 54848 54849 54850 input_path="$new_path" 54851 # Check if we need to convert this using DOS-style short mode. If the path 54852 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54853 # take no chances and rewrite it. 54854 # Note: m4 eats our [], so we need to use [ and ] instead. 54855 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 54856 if test "x$has_forbidden_chars" != x; then 54857 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54858 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54859 fi 54860 54861 54862 windows_path="$new_path" 54863 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54864 unix_path=`$CYGPATH -u "$windows_path"` 54865 new_path="$unix_path" 54866 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54867 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 54868 new_path="$unix_path" 54869 fi 54870 54871 if test "x$path" != "x$new_path"; then 54872 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 54873 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 54874 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 54875 fi 54876 54877 # Save the first 10 bytes of this path to the storage, so fixpath can work. 54878 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 54879 54880 else 54881 # We're on a unix platform. Hooray! :) 54882 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 54883 has_space=`$ECHO "$path" | $GREP " "` 54884 if test "x$has_space" != x; then 54885 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 54886 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 54887 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 54888 fi 54889 54890 # Use eval to expand a potential ~ 54891 eval path="$path" 54892 if test ! -f "$path" && test ! -d "$path"; then 54893 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 54894 fi 54895 54896 if test -d "$path"; then 54897 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 54898 else 54899 dir="`$DIRNAME "$path"`" 54900 base="`$BASENAME "$path"`" 54901 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 54902 fi 54903 fi 54904 fi 54905 54906 54907 # Only process if variable expands to non-empty 54908 54909 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 54910 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54911 54912 # Input might be given as Windows format, start by converting to 54913 # unix format. 54914 path="$POTENTIAL_FREETYPE_LIB_PATH" 54915 new_path=`$CYGPATH -u "$path"` 54916 54917 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 54918 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 54919 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 54920 # "foo.exe" is OK but "foo" is an error. 54921 # 54922 # This test is therefore slightly more accurate than "test -f" to check for file precense. 54923 # It is also a way to make sure we got the proper file name for the real test later on. 54924 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 54925 if test "x$test_shortpath" = x; then 54926 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 54927 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 54928 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 54929 fi 54930 54931 # Call helper function which possibly converts this using DOS-style short mode. 54932 # If so, the updated path is stored in $new_path. 54933 54934 input_path="$new_path" 54935 # Check if we need to convert this using DOS-style short mode. If the path 54936 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54937 # take no chances and rewrite it. 54938 # Note: m4 eats our [], so we need to use [ and ] instead. 54939 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 54940 if test "x$has_forbidden_chars" != x; then 54941 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54942 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 54943 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 54944 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 54945 # Going to short mode and back again did indeed matter. Since short mode is 54946 # case insensitive, let's make it lowercase to improve readability. 54947 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54948 # Now convert it back to Unix-style (cygpath) 54949 input_path=`$CYGPATH -u "$shortmode_path"` 54950 new_path="$input_path" 54951 fi 54952 fi 54953 54954 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 54955 if test "x$test_cygdrive_prefix" = x; then 54956 # As a simple fix, exclude /usr/bin since it's not a real path. 54957 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 54958 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 54959 # a path prefixed by /cygdrive for fixpath to work. 54960 new_path="$CYGWIN_ROOT_PATH$input_path" 54961 fi 54962 fi 54963 54964 54965 if test "x$path" != "x$new_path"; then 54966 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 54967 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 54968 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 54969 fi 54970 54971 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54972 54973 path="$POTENTIAL_FREETYPE_LIB_PATH" 54974 has_colon=`$ECHO $path | $GREP ^.:` 54975 new_path="$path" 54976 if test "x$has_colon" = x; then 54977 # Not in mixed or Windows style, start by that. 54978 new_path=`cmd //c echo $path` 54979 fi 54980 54981 54982 input_path="$new_path" 54983 # Check if we need to convert this using DOS-style short mode. If the path 54984 # contains just simple characters, use it. Otherwise (spaces, weird characters), 54985 # take no chances and rewrite it. 54986 # Note: m4 eats our [], so we need to use [ and ] instead. 54987 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 54988 if test "x$has_forbidden_chars" != x; then 54989 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 54990 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 54991 fi 54992 54993 54994 windows_path="$new_path" 54995 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 54996 unix_path=`$CYGPATH -u "$windows_path"` 54997 new_path="$unix_path" 54998 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 54999 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55000 new_path="$unix_path" 55001 fi 55002 55003 if test "x$path" != "x$new_path"; then 55004 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 55005 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 55006 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 55007 fi 55008 55009 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55010 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55011 55012 else 55013 # We're on a unix platform. Hooray! :) 55014 path="$POTENTIAL_FREETYPE_LIB_PATH" 55015 has_space=`$ECHO "$path" | $GREP " "` 55016 if test "x$has_space" != x; then 55017 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 55018 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 55019 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55020 fi 55021 55022 # Use eval to expand a potential ~ 55023 eval path="$path" 55024 if test ! -f "$path" && test ! -d "$path"; then 55025 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 55026 fi 55027 55028 if test -d "$path"; then 55029 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 55030 else 55031 dir="`$DIRNAME "$path"`" 55032 base="`$BASENAME "$path"`" 55033 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 55034 fi 55035 fi 55036 fi 55037 55038 55039 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 55040 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 55041 $as_echo_n "checking for freetype includes... " >&6; } 55042 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 55043 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 55044 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 55045 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 55046 $as_echo_n "checking for freetype libraries... " >&6; } 55047 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 55048 $as_echo "$FREETYPE_LIB_PATH" >&6; } 55049 fi 55050 55051 fi 55052 fi 55053 fi 55054 else 55055 FREETYPE_BASE_DIR="$SYSROOT/usr" 55056 55057 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 55058 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 55059 METHOD="well-known location" 55060 55061 # Let's start with an optimistic view of the world :-) 55062 FOUND_FREETYPE=yes 55063 55064 # First look for the canonical freetype main include file ft2build.h. 55065 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 55066 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 55067 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 55068 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 55069 # Fail. 55070 FOUND_FREETYPE=no 55071 fi 55072 fi 55073 55074 if test "x$FOUND_FREETYPE" = xyes; then 55075 # Include file found, let's continue the sanity check. 55076 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 55077 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 55078 55079 # Reset to default value 55080 FREETYPE_BASE_NAME=freetype 55081 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 55082 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 55083 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 55084 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 55085 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 55086 # for the .6 version explicitly. 55087 FREETYPE_BASE_NAME=freetype.6 55088 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 55089 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 55090 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 55091 else 55092 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 55093 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 55094 FOUND_FREETYPE=no 55095 fi 55096 else 55097 if test "x$OPENJDK_TARGET_OS" = xwindows; then 55098 # On Windows, we will need both .lib and .dll file. 55099 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 55100 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 55101 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 55102 FOUND_FREETYPE=no 55103 fi 55104 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 55105 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 55106 # Found lib in isa dir, use that instead. 55107 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 55108 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 55109 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 55110 fi 55111 fi 55112 fi 55113 55114 if test "x$FOUND_FREETYPE" = xyes; then 55115 55116 # Only process if variable expands to non-empty 55117 55118 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 55119 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55120 55121 # Input might be given as Windows format, start by converting to 55122 # unix format. 55123 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 55124 new_path=`$CYGPATH -u "$path"` 55125 55126 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55127 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55128 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55129 # "foo.exe" is OK but "foo" is an error. 55130 # 55131 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55132 # It is also a way to make sure we got the proper file name for the real test later on. 55133 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55134 if test "x$test_shortpath" = x; then 55135 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 55136 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 55137 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 55138 fi 55139 55140 # Call helper function which possibly converts this using DOS-style short mode. 55141 # If so, the updated path is stored in $new_path. 55142 55143 input_path="$new_path" 55144 # Check if we need to convert this using DOS-style short mode. If the path 55145 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55146 # take no chances and rewrite it. 55147 # Note: m4 eats our [], so we need to use [ and ] instead. 55148 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55149 if test "x$has_forbidden_chars" != x; then 55150 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55151 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55152 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55153 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55154 # Going to short mode and back again did indeed matter. Since short mode is 55155 # case insensitive, let's make it lowercase to improve readability. 55156 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55157 # Now convert it back to Unix-style (cygpath) 55158 input_path=`$CYGPATH -u "$shortmode_path"` 55159 new_path="$input_path" 55160 fi 55161 fi 55162 55163 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55164 if test "x$test_cygdrive_prefix" = x; then 55165 # As a simple fix, exclude /usr/bin since it's not a real path. 55166 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55167 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55168 # a path prefixed by /cygdrive for fixpath to work. 55169 new_path="$CYGWIN_ROOT_PATH$input_path" 55170 fi 55171 fi 55172 55173 55174 if test "x$path" != "x$new_path"; then 55175 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 55176 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 55177 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 55178 fi 55179 55180 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55181 55182 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 55183 has_colon=`$ECHO $path | $GREP ^.:` 55184 new_path="$path" 55185 if test "x$has_colon" = x; then 55186 # Not in mixed or Windows style, start by that. 55187 new_path=`cmd //c echo $path` 55188 fi 55189 55190 55191 input_path="$new_path" 55192 # Check if we need to convert this using DOS-style short mode. If the path 55193 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55194 # take no chances and rewrite it. 55195 # Note: m4 eats our [], so we need to use [ and ] instead. 55196 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55197 if test "x$has_forbidden_chars" != x; then 55198 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55199 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55200 fi 55201 55202 55203 windows_path="$new_path" 55204 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55205 unix_path=`$CYGPATH -u "$windows_path"` 55206 new_path="$unix_path" 55207 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55208 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55209 new_path="$unix_path" 55210 fi 55211 55212 if test "x$path" != "x$new_path"; then 55213 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 55214 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 55215 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 55216 fi 55217 55218 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55219 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55220 55221 else 55222 # We're on a unix platform. Hooray! :) 55223 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 55224 has_space=`$ECHO "$path" | $GREP " "` 55225 if test "x$has_space" != x; then 55226 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 55227 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 55228 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55229 fi 55230 55231 # Use eval to expand a potential ~ 55232 eval path="$path" 55233 if test ! -f "$path" && test ! -d "$path"; then 55234 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 55235 fi 55236 55237 if test -d "$path"; then 55238 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 55239 else 55240 dir="`$DIRNAME "$path"`" 55241 base="`$BASENAME "$path"`" 55242 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 55243 fi 55244 fi 55245 fi 55246 55247 55248 # Only process if variable expands to non-empty 55249 55250 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 55251 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55252 55253 # Input might be given as Windows format, start by converting to 55254 # unix format. 55255 path="$POTENTIAL_FREETYPE_LIB_PATH" 55256 new_path=`$CYGPATH -u "$path"` 55257 55258 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55259 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55260 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55261 # "foo.exe" is OK but "foo" is an error. 55262 # 55263 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55264 # It is also a way to make sure we got the proper file name for the real test later on. 55265 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55266 if test "x$test_shortpath" = x; then 55267 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 55268 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 55269 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 55270 fi 55271 55272 # Call helper function which possibly converts this using DOS-style short mode. 55273 # If so, the updated path is stored in $new_path. 55274 55275 input_path="$new_path" 55276 # Check if we need to convert this using DOS-style short mode. If the path 55277 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55278 # take no chances and rewrite it. 55279 # Note: m4 eats our [], so we need to use [ and ] instead. 55280 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55281 if test "x$has_forbidden_chars" != x; then 55282 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55283 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55284 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55285 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55286 # Going to short mode and back again did indeed matter. Since short mode is 55287 # case insensitive, let's make it lowercase to improve readability. 55288 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55289 # Now convert it back to Unix-style (cygpath) 55290 input_path=`$CYGPATH -u "$shortmode_path"` 55291 new_path="$input_path" 55292 fi 55293 fi 55294 55295 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55296 if test "x$test_cygdrive_prefix" = x; then 55297 # As a simple fix, exclude /usr/bin since it's not a real path. 55298 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55299 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55300 # a path prefixed by /cygdrive for fixpath to work. 55301 new_path="$CYGWIN_ROOT_PATH$input_path" 55302 fi 55303 fi 55304 55305 55306 if test "x$path" != "x$new_path"; then 55307 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 55308 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 55309 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 55310 fi 55311 55312 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55313 55314 path="$POTENTIAL_FREETYPE_LIB_PATH" 55315 has_colon=`$ECHO $path | $GREP ^.:` 55316 new_path="$path" 55317 if test "x$has_colon" = x; then 55318 # Not in mixed or Windows style, start by that. 55319 new_path=`cmd //c echo $path` 55320 fi 55321 55322 55323 input_path="$new_path" 55324 # Check if we need to convert this using DOS-style short mode. If the path 55325 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55326 # take no chances and rewrite it. 55327 # Note: m4 eats our [], so we need to use [ and ] instead. 55328 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55329 if test "x$has_forbidden_chars" != x; then 55330 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55331 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55332 fi 55333 55334 55335 windows_path="$new_path" 55336 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55337 unix_path=`$CYGPATH -u "$windows_path"` 55338 new_path="$unix_path" 55339 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55340 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55341 new_path="$unix_path" 55342 fi 55343 55344 if test "x$path" != "x$new_path"; then 55345 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 55346 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 55347 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 55348 fi 55349 55350 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55351 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55352 55353 else 55354 # We're on a unix platform. Hooray! :) 55355 path="$POTENTIAL_FREETYPE_LIB_PATH" 55356 has_space=`$ECHO "$path" | $GREP " "` 55357 if test "x$has_space" != x; then 55358 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 55359 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 55360 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55361 fi 55362 55363 # Use eval to expand a potential ~ 55364 eval path="$path" 55365 if test ! -f "$path" && test ! -d "$path"; then 55366 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 55367 fi 55368 55369 if test -d "$path"; then 55370 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 55371 else 55372 dir="`$DIRNAME "$path"`" 55373 base="`$BASENAME "$path"`" 55374 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 55375 fi 55376 fi 55377 fi 55378 55379 55380 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 55381 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 55382 $as_echo_n "checking for freetype includes... " >&6; } 55383 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 55384 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 55385 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 55386 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 55387 $as_echo_n "checking for freetype libraries... " >&6; } 55388 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 55389 $as_echo "$FREETYPE_LIB_PATH" >&6; } 55390 fi 55391 55392 55393 if test "x$FOUND_FREETYPE" != xyes; then 55394 FREETYPE_BASE_DIR="$SYSROOT/usr/X11" 55395 55396 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 55397 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 55398 METHOD="well-known location" 55399 55400 # Let's start with an optimistic view of the world :-) 55401 FOUND_FREETYPE=yes 55402 55403 # First look for the canonical freetype main include file ft2build.h. 55404 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 55405 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 55406 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 55407 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 55408 # Fail. 55409 FOUND_FREETYPE=no 55410 fi 55411 fi 55412 55413 if test "x$FOUND_FREETYPE" = xyes; then 55414 # Include file found, let's continue the sanity check. 55415 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 55416 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 55417 55418 # Reset to default value 55419 FREETYPE_BASE_NAME=freetype 55420 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 55421 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 55422 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 55423 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 55424 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 55425 # for the .6 version explicitly. 55426 FREETYPE_BASE_NAME=freetype.6 55427 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 55428 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 55429 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 55430 else 55431 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 55432 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 55433 FOUND_FREETYPE=no 55434 fi 55435 else 55436 if test "x$OPENJDK_TARGET_OS" = xwindows; then 55437 # On Windows, we will need both .lib and .dll file. 55438 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 55439 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 55440 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 55441 FOUND_FREETYPE=no 55442 fi 55443 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 55444 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 55445 # Found lib in isa dir, use that instead. 55446 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 55447 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 55448 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 55449 fi 55450 fi 55451 fi 55452 55453 if test "x$FOUND_FREETYPE" = xyes; then 55454 55455 # Only process if variable expands to non-empty 55456 55457 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 55458 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55459 55460 # Input might be given as Windows format, start by converting to 55461 # unix format. 55462 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 55463 new_path=`$CYGPATH -u "$path"` 55464 55465 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55466 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55467 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55468 # "foo.exe" is OK but "foo" is an error. 55469 # 55470 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55471 # It is also a way to make sure we got the proper file name for the real test later on. 55472 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55473 if test "x$test_shortpath" = x; then 55474 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 55475 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 55476 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 55477 fi 55478 55479 # Call helper function which possibly converts this using DOS-style short mode. 55480 # If so, the updated path is stored in $new_path. 55481 55482 input_path="$new_path" 55483 # Check if we need to convert this using DOS-style short mode. If the path 55484 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55485 # take no chances and rewrite it. 55486 # Note: m4 eats our [], so we need to use [ and ] instead. 55487 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55488 if test "x$has_forbidden_chars" != x; then 55489 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55490 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55491 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55492 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55493 # Going to short mode and back again did indeed matter. Since short mode is 55494 # case insensitive, let's make it lowercase to improve readability. 55495 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55496 # Now convert it back to Unix-style (cygpath) 55497 input_path=`$CYGPATH -u "$shortmode_path"` 55498 new_path="$input_path" 55499 fi 55500 fi 55501 55502 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55503 if test "x$test_cygdrive_prefix" = x; then 55504 # As a simple fix, exclude /usr/bin since it's not a real path. 55505 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55506 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55507 # a path prefixed by /cygdrive for fixpath to work. 55508 new_path="$CYGWIN_ROOT_PATH$input_path" 55509 fi 55510 fi 55511 55512 55513 if test "x$path" != "x$new_path"; then 55514 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 55515 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 55516 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 55517 fi 55518 55519 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55520 55521 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 55522 has_colon=`$ECHO $path | $GREP ^.:` 55523 new_path="$path" 55524 if test "x$has_colon" = x; then 55525 # Not in mixed or Windows style, start by that. 55526 new_path=`cmd //c echo $path` 55527 fi 55528 55529 55530 input_path="$new_path" 55531 # Check if we need to convert this using DOS-style short mode. If the path 55532 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55533 # take no chances and rewrite it. 55534 # Note: m4 eats our [], so we need to use [ and ] instead. 55535 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55536 if test "x$has_forbidden_chars" != x; then 55537 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55538 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55539 fi 55540 55541 55542 windows_path="$new_path" 55543 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55544 unix_path=`$CYGPATH -u "$windows_path"` 55545 new_path="$unix_path" 55546 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55547 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55548 new_path="$unix_path" 55549 fi 55550 55551 if test "x$path" != "x$new_path"; then 55552 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 55553 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 55554 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 55555 fi 55556 55557 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55558 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55559 55560 else 55561 # We're on a unix platform. Hooray! :) 55562 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 55563 has_space=`$ECHO "$path" | $GREP " "` 55564 if test "x$has_space" != x; then 55565 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 55566 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 55567 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55568 fi 55569 55570 # Use eval to expand a potential ~ 55571 eval path="$path" 55572 if test ! -f "$path" && test ! -d "$path"; then 55573 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 55574 fi 55575 55576 if test -d "$path"; then 55577 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 55578 else 55579 dir="`$DIRNAME "$path"`" 55580 base="`$BASENAME "$path"`" 55581 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 55582 fi 55583 fi 55584 fi 55585 55586 55587 # Only process if variable expands to non-empty 55588 55589 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 55590 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55591 55592 # Input might be given as Windows format, start by converting to 55593 # unix format. 55594 path="$POTENTIAL_FREETYPE_LIB_PATH" 55595 new_path=`$CYGPATH -u "$path"` 55596 55597 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55598 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55599 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55600 # "foo.exe" is OK but "foo" is an error. 55601 # 55602 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55603 # It is also a way to make sure we got the proper file name for the real test later on. 55604 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55605 if test "x$test_shortpath" = x; then 55606 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 55607 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 55608 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 55609 fi 55610 55611 # Call helper function which possibly converts this using DOS-style short mode. 55612 # If so, the updated path is stored in $new_path. 55613 55614 input_path="$new_path" 55615 # Check if we need to convert this using DOS-style short mode. If the path 55616 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55617 # take no chances and rewrite it. 55618 # Note: m4 eats our [], so we need to use [ and ] instead. 55619 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55620 if test "x$has_forbidden_chars" != x; then 55621 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55622 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55623 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55624 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55625 # Going to short mode and back again did indeed matter. Since short mode is 55626 # case insensitive, let's make it lowercase to improve readability. 55627 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55628 # Now convert it back to Unix-style (cygpath) 55629 input_path=`$CYGPATH -u "$shortmode_path"` 55630 new_path="$input_path" 55631 fi 55632 fi 55633 55634 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55635 if test "x$test_cygdrive_prefix" = x; then 55636 # As a simple fix, exclude /usr/bin since it's not a real path. 55637 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55638 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55639 # a path prefixed by /cygdrive for fixpath to work. 55640 new_path="$CYGWIN_ROOT_PATH$input_path" 55641 fi 55642 fi 55643 55644 55645 if test "x$path" != "x$new_path"; then 55646 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 55647 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 55648 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 55649 fi 55650 55651 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55652 55653 path="$POTENTIAL_FREETYPE_LIB_PATH" 55654 has_colon=`$ECHO $path | $GREP ^.:` 55655 new_path="$path" 55656 if test "x$has_colon" = x; then 55657 # Not in mixed or Windows style, start by that. 55658 new_path=`cmd //c echo $path` 55659 fi 55660 55661 55662 input_path="$new_path" 55663 # Check if we need to convert this using DOS-style short mode. If the path 55664 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55665 # take no chances and rewrite it. 55666 # Note: m4 eats our [], so we need to use [ and ] instead. 55667 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55668 if test "x$has_forbidden_chars" != x; then 55669 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55670 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55671 fi 55672 55673 55674 windows_path="$new_path" 55675 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55676 unix_path=`$CYGPATH -u "$windows_path"` 55677 new_path="$unix_path" 55678 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55679 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55680 new_path="$unix_path" 55681 fi 55682 55683 if test "x$path" != "x$new_path"; then 55684 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 55685 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 55686 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 55687 fi 55688 55689 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55690 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55691 55692 else 55693 # We're on a unix platform. Hooray! :) 55694 path="$POTENTIAL_FREETYPE_LIB_PATH" 55695 has_space=`$ECHO "$path" | $GREP " "` 55696 if test "x$has_space" != x; then 55697 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 55698 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 55699 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55700 fi 55701 55702 # Use eval to expand a potential ~ 55703 eval path="$path" 55704 if test ! -f "$path" && test ! -d "$path"; then 55705 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 55706 fi 55707 55708 if test -d "$path"; then 55709 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 55710 else 55711 dir="`$DIRNAME "$path"`" 55712 base="`$BASENAME "$path"`" 55713 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 55714 fi 55715 fi 55716 fi 55717 55718 55719 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 55720 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 55721 $as_echo_n "checking for freetype includes... " >&6; } 55722 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 55723 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 55724 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 55725 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 55726 $as_echo_n "checking for freetype libraries... " >&6; } 55727 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 55728 $as_echo "$FREETYPE_LIB_PATH" >&6; } 55729 fi 55730 55731 fi 55732 55733 if test "x$FOUND_FREETYPE" != xyes; then 55734 FREETYPE_BASE_DIR="$SYSROOT/usr/sfw" 55735 55736 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 55737 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib" 55738 METHOD="well-known location" 55739 55740 # Let's start with an optimistic view of the world :-) 55741 FOUND_FREETYPE=yes 55742 55743 # First look for the canonical freetype main include file ft2build.h. 55744 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 55745 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 55746 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 55747 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 55748 # Fail. 55749 FOUND_FREETYPE=no 55750 fi 55751 fi 55752 55753 if test "x$FOUND_FREETYPE" = xyes; then 55754 # Include file found, let's continue the sanity check. 55755 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 55756 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 55757 55758 # Reset to default value 55759 FREETYPE_BASE_NAME=freetype 55760 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 55761 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 55762 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 55763 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 55764 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 55765 # for the .6 version explicitly. 55766 FREETYPE_BASE_NAME=freetype.6 55767 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 55768 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 55769 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 55770 else 55771 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 55772 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 55773 FOUND_FREETYPE=no 55774 fi 55775 else 55776 if test "x$OPENJDK_TARGET_OS" = xwindows; then 55777 # On Windows, we will need both .lib and .dll file. 55778 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 55779 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 55780 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 55781 FOUND_FREETYPE=no 55782 fi 55783 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 55784 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 55785 # Found lib in isa dir, use that instead. 55786 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 55787 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 55788 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 55789 fi 55790 fi 55791 fi 55792 55793 if test "x$FOUND_FREETYPE" = xyes; then 55794 55795 # Only process if variable expands to non-empty 55796 55797 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 55798 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55799 55800 # Input might be given as Windows format, start by converting to 55801 # unix format. 55802 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 55803 new_path=`$CYGPATH -u "$path"` 55804 55805 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55806 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55807 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55808 # "foo.exe" is OK but "foo" is an error. 55809 # 55810 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55811 # It is also a way to make sure we got the proper file name for the real test later on. 55812 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55813 if test "x$test_shortpath" = x; then 55814 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 55815 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 55816 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 55817 fi 55818 55819 # Call helper function which possibly converts this using DOS-style short mode. 55820 # If so, the updated path is stored in $new_path. 55821 55822 input_path="$new_path" 55823 # Check if we need to convert this using DOS-style short mode. If the path 55824 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55825 # take no chances and rewrite it. 55826 # Note: m4 eats our [], so we need to use [ and ] instead. 55827 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55828 if test "x$has_forbidden_chars" != x; then 55829 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55830 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55831 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55832 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55833 # Going to short mode and back again did indeed matter. Since short mode is 55834 # case insensitive, let's make it lowercase to improve readability. 55835 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55836 # Now convert it back to Unix-style (cygpath) 55837 input_path=`$CYGPATH -u "$shortmode_path"` 55838 new_path="$input_path" 55839 fi 55840 fi 55841 55842 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55843 if test "x$test_cygdrive_prefix" = x; then 55844 # As a simple fix, exclude /usr/bin since it's not a real path. 55845 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55846 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55847 # a path prefixed by /cygdrive for fixpath to work. 55848 new_path="$CYGWIN_ROOT_PATH$input_path" 55849 fi 55850 fi 55851 55852 55853 if test "x$path" != "x$new_path"; then 55854 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 55855 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 55856 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 55857 fi 55858 55859 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55860 55861 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 55862 has_colon=`$ECHO $path | $GREP ^.:` 55863 new_path="$path" 55864 if test "x$has_colon" = x; then 55865 # Not in mixed or Windows style, start by that. 55866 new_path=`cmd //c echo $path` 55867 fi 55868 55869 55870 input_path="$new_path" 55871 # Check if we need to convert this using DOS-style short mode. If the path 55872 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55873 # take no chances and rewrite it. 55874 # Note: m4 eats our [], so we need to use [ and ] instead. 55875 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 55876 if test "x$has_forbidden_chars" != x; then 55877 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55878 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55879 fi 55880 55881 55882 windows_path="$new_path" 55883 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55884 unix_path=`$CYGPATH -u "$windows_path"` 55885 new_path="$unix_path" 55886 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55887 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 55888 new_path="$unix_path" 55889 fi 55890 55891 if test "x$path" != "x$new_path"; then 55892 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 55893 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 55894 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 55895 fi 55896 55897 # Save the first 10 bytes of this path to the storage, so fixpath can work. 55898 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 55899 55900 else 55901 # We're on a unix platform. Hooray! :) 55902 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 55903 has_space=`$ECHO "$path" | $GREP " "` 55904 if test "x$has_space" != x; then 55905 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 55906 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 55907 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 55908 fi 55909 55910 # Use eval to expand a potential ~ 55911 eval path="$path" 55912 if test ! -f "$path" && test ! -d "$path"; then 55913 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 55914 fi 55915 55916 if test -d "$path"; then 55917 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 55918 else 55919 dir="`$DIRNAME "$path"`" 55920 base="`$BASENAME "$path"`" 55921 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 55922 fi 55923 fi 55924 fi 55925 55926 55927 # Only process if variable expands to non-empty 55928 55929 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 55930 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 55931 55932 # Input might be given as Windows format, start by converting to 55933 # unix format. 55934 path="$POTENTIAL_FREETYPE_LIB_PATH" 55935 new_path=`$CYGPATH -u "$path"` 55936 55937 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 55938 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 55939 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 55940 # "foo.exe" is OK but "foo" is an error. 55941 # 55942 # This test is therefore slightly more accurate than "test -f" to check for file precense. 55943 # It is also a way to make sure we got the proper file name for the real test later on. 55944 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 55945 if test "x$test_shortpath" = x; then 55946 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 55947 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 55948 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 55949 fi 55950 55951 # Call helper function which possibly converts this using DOS-style short mode. 55952 # If so, the updated path is stored in $new_path. 55953 55954 input_path="$new_path" 55955 # Check if we need to convert this using DOS-style short mode. If the path 55956 # contains just simple characters, use it. Otherwise (spaces, weird characters), 55957 # take no chances and rewrite it. 55958 # Note: m4 eats our [], so we need to use [ and ] instead. 55959 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 55960 if test "x$has_forbidden_chars" != x; then 55961 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 55962 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 55963 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 55964 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 55965 # Going to short mode and back again did indeed matter. Since short mode is 55966 # case insensitive, let's make it lowercase to improve readability. 55967 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 55968 # Now convert it back to Unix-style (cygpath) 55969 input_path=`$CYGPATH -u "$shortmode_path"` 55970 new_path="$input_path" 55971 fi 55972 fi 55973 55974 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 55975 if test "x$test_cygdrive_prefix" = x; then 55976 # As a simple fix, exclude /usr/bin since it's not a real path. 55977 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 55978 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 55979 # a path prefixed by /cygdrive for fixpath to work. 55980 new_path="$CYGWIN_ROOT_PATH$input_path" 55981 fi 55982 fi 55983 55984 55985 if test "x$path" != "x$new_path"; then 55986 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 55987 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 55988 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 55989 fi 55990 55991 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 55992 55993 path="$POTENTIAL_FREETYPE_LIB_PATH" 55994 has_colon=`$ECHO $path | $GREP ^.:` 55995 new_path="$path" 55996 if test "x$has_colon" = x; then 55997 # Not in mixed or Windows style, start by that. 55998 new_path=`cmd //c echo $path` 55999 fi 56000 56001 56002 input_path="$new_path" 56003 # Check if we need to convert this using DOS-style short mode. If the path 56004 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56005 # take no chances and rewrite it. 56006 # Note: m4 eats our [], so we need to use [ and ] instead. 56007 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 56008 if test "x$has_forbidden_chars" != x; then 56009 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56010 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56011 fi 56012 56013 56014 windows_path="$new_path" 56015 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56016 unix_path=`$CYGPATH -u "$windows_path"` 56017 new_path="$unix_path" 56018 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56019 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 56020 new_path="$unix_path" 56021 fi 56022 56023 if test "x$path" != "x$new_path"; then 56024 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 56025 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 56026 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 56027 fi 56028 56029 # Save the first 10 bytes of this path to the storage, so fixpath can work. 56030 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 56031 56032 else 56033 # We're on a unix platform. Hooray! :) 56034 path="$POTENTIAL_FREETYPE_LIB_PATH" 56035 has_space=`$ECHO "$path" | $GREP " "` 56036 if test "x$has_space" != x; then 56037 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 56038 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 56039 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 56040 fi 56041 56042 # Use eval to expand a potential ~ 56043 eval path="$path" 56044 if test ! -f "$path" && test ! -d "$path"; then 56045 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 56046 fi 56047 56048 if test -d "$path"; then 56049 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 56050 else 56051 dir="`$DIRNAME "$path"`" 56052 base="`$BASENAME "$path"`" 56053 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 56054 fi 56055 fi 56056 fi 56057 56058 56059 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 56060 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 56061 $as_echo_n "checking for freetype includes... " >&6; } 56062 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 56063 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 56064 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 56065 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 56066 $as_echo_n "checking for freetype libraries... " >&6; } 56067 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 56068 $as_echo "$FREETYPE_LIB_PATH" >&6; } 56069 fi 56070 56071 fi 56072 56073 if test "x$FOUND_FREETYPE" != xyes; then 56074 FREETYPE_BASE_DIR="$SYSROOT/usr" 56075 if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then 56076 56077 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 56078 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib/x86_64-linux-gnu" 56079 METHOD="well-known location" 56080 56081 # Let's start with an optimistic view of the world :-) 56082 FOUND_FREETYPE=yes 56083 56084 # First look for the canonical freetype main include file ft2build.h. 56085 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 56086 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 56087 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 56088 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 56089 # Fail. 56090 FOUND_FREETYPE=no 56091 fi 56092 fi 56093 56094 if test "x$FOUND_FREETYPE" = xyes; then 56095 # Include file found, let's continue the sanity check. 56096 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 56097 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 56098 56099 # Reset to default value 56100 FREETYPE_BASE_NAME=freetype 56101 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 56102 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 56103 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 56104 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 56105 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 56106 # for the .6 version explicitly. 56107 FREETYPE_BASE_NAME=freetype.6 56108 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 56109 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 56110 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 56111 else 56112 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 56113 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 56114 FOUND_FREETYPE=no 56115 fi 56116 else 56117 if test "x$OPENJDK_TARGET_OS" = xwindows; then 56118 # On Windows, we will need both .lib and .dll file. 56119 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 56120 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 56121 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 56122 FOUND_FREETYPE=no 56123 fi 56124 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 56125 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 56126 # Found lib in isa dir, use that instead. 56127 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 56128 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 56129 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 56130 fi 56131 fi 56132 fi 56133 56134 if test "x$FOUND_FREETYPE" = xyes; then 56135 56136 # Only process if variable expands to non-empty 56137 56138 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 56139 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56140 56141 # Input might be given as Windows format, start by converting to 56142 # unix format. 56143 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 56144 new_path=`$CYGPATH -u "$path"` 56145 56146 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 56147 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 56148 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 56149 # "foo.exe" is OK but "foo" is an error. 56150 # 56151 # This test is therefore slightly more accurate than "test -f" to check for file precense. 56152 # It is also a way to make sure we got the proper file name for the real test later on. 56153 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 56154 if test "x$test_shortpath" = x; then 56155 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 56156 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 56157 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 56158 fi 56159 56160 # Call helper function which possibly converts this using DOS-style short mode. 56161 # If so, the updated path is stored in $new_path. 56162 56163 input_path="$new_path" 56164 # Check if we need to convert this using DOS-style short mode. If the path 56165 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56166 # take no chances and rewrite it. 56167 # Note: m4 eats our [], so we need to use [ and ] instead. 56168 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 56169 if test "x$has_forbidden_chars" != x; then 56170 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56171 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 56172 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 56173 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 56174 # Going to short mode and back again did indeed matter. Since short mode is 56175 # case insensitive, let's make it lowercase to improve readability. 56176 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56177 # Now convert it back to Unix-style (cygpath) 56178 input_path=`$CYGPATH -u "$shortmode_path"` 56179 new_path="$input_path" 56180 fi 56181 fi 56182 56183 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 56184 if test "x$test_cygdrive_prefix" = x; then 56185 # As a simple fix, exclude /usr/bin since it's not a real path. 56186 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 56187 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 56188 # a path prefixed by /cygdrive for fixpath to work. 56189 new_path="$CYGWIN_ROOT_PATH$input_path" 56190 fi 56191 fi 56192 56193 56194 if test "x$path" != "x$new_path"; then 56195 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 56196 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 56197 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 56198 fi 56199 56200 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56201 56202 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 56203 has_colon=`$ECHO $path | $GREP ^.:` 56204 new_path="$path" 56205 if test "x$has_colon" = x; then 56206 # Not in mixed or Windows style, start by that. 56207 new_path=`cmd //c echo $path` 56208 fi 56209 56210 56211 input_path="$new_path" 56212 # Check if we need to convert this using DOS-style short mode. If the path 56213 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56214 # take no chances and rewrite it. 56215 # Note: m4 eats our [], so we need to use [ and ] instead. 56216 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 56217 if test "x$has_forbidden_chars" != x; then 56218 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56219 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56220 fi 56221 56222 56223 windows_path="$new_path" 56224 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56225 unix_path=`$CYGPATH -u "$windows_path"` 56226 new_path="$unix_path" 56227 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56228 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 56229 new_path="$unix_path" 56230 fi 56231 56232 if test "x$path" != "x$new_path"; then 56233 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 56234 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 56235 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 56236 fi 56237 56238 # Save the first 10 bytes of this path to the storage, so fixpath can work. 56239 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 56240 56241 else 56242 # We're on a unix platform. Hooray! :) 56243 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 56244 has_space=`$ECHO "$path" | $GREP " "` 56245 if test "x$has_space" != x; then 56246 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 56247 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 56248 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 56249 fi 56250 56251 # Use eval to expand a potential ~ 56252 eval path="$path" 56253 if test ! -f "$path" && test ! -d "$path"; then 56254 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 56255 fi 56256 56257 if test -d "$path"; then 56258 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 56259 else 56260 dir="`$DIRNAME "$path"`" 56261 base="`$BASENAME "$path"`" 56262 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 56263 fi 56264 fi 56265 fi 56266 56267 56268 # Only process if variable expands to non-empty 56269 56270 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 56271 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56272 56273 # Input might be given as Windows format, start by converting to 56274 # unix format. 56275 path="$POTENTIAL_FREETYPE_LIB_PATH" 56276 new_path=`$CYGPATH -u "$path"` 56277 56278 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 56279 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 56280 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 56281 # "foo.exe" is OK but "foo" is an error. 56282 # 56283 # This test is therefore slightly more accurate than "test -f" to check for file precense. 56284 # It is also a way to make sure we got the proper file name for the real test later on. 56285 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 56286 if test "x$test_shortpath" = x; then 56287 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 56288 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 56289 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 56290 fi 56291 56292 # Call helper function which possibly converts this using DOS-style short mode. 56293 # If so, the updated path is stored in $new_path. 56294 56295 input_path="$new_path" 56296 # Check if we need to convert this using DOS-style short mode. If the path 56297 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56298 # take no chances and rewrite it. 56299 # Note: m4 eats our [], so we need to use [ and ] instead. 56300 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 56301 if test "x$has_forbidden_chars" != x; then 56302 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56303 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 56304 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 56305 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 56306 # Going to short mode and back again did indeed matter. Since short mode is 56307 # case insensitive, let's make it lowercase to improve readability. 56308 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56309 # Now convert it back to Unix-style (cygpath) 56310 input_path=`$CYGPATH -u "$shortmode_path"` 56311 new_path="$input_path" 56312 fi 56313 fi 56314 56315 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 56316 if test "x$test_cygdrive_prefix" = x; then 56317 # As a simple fix, exclude /usr/bin since it's not a real path. 56318 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 56319 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 56320 # a path prefixed by /cygdrive for fixpath to work. 56321 new_path="$CYGWIN_ROOT_PATH$input_path" 56322 fi 56323 fi 56324 56325 56326 if test "x$path" != "x$new_path"; then 56327 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 56328 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 56329 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 56330 fi 56331 56332 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56333 56334 path="$POTENTIAL_FREETYPE_LIB_PATH" 56335 has_colon=`$ECHO $path | $GREP ^.:` 56336 new_path="$path" 56337 if test "x$has_colon" = x; then 56338 # Not in mixed or Windows style, start by that. 56339 new_path=`cmd //c echo $path` 56340 fi 56341 56342 56343 input_path="$new_path" 56344 # Check if we need to convert this using DOS-style short mode. If the path 56345 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56346 # take no chances and rewrite it. 56347 # Note: m4 eats our [], so we need to use [ and ] instead. 56348 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 56349 if test "x$has_forbidden_chars" != x; then 56350 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56351 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56352 fi 56353 56354 56355 windows_path="$new_path" 56356 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56357 unix_path=`$CYGPATH -u "$windows_path"` 56358 new_path="$unix_path" 56359 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56360 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 56361 new_path="$unix_path" 56362 fi 56363 56364 if test "x$path" != "x$new_path"; then 56365 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 56366 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 56367 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 56368 fi 56369 56370 # Save the first 10 bytes of this path to the storage, so fixpath can work. 56371 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 56372 56373 else 56374 # We're on a unix platform. Hooray! :) 56375 path="$POTENTIAL_FREETYPE_LIB_PATH" 56376 has_space=`$ECHO "$path" | $GREP " "` 56377 if test "x$has_space" != x; then 56378 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 56379 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 56380 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 56381 fi 56382 56383 # Use eval to expand a potential ~ 56384 eval path="$path" 56385 if test ! -f "$path" && test ! -d "$path"; then 56386 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 56387 fi 56388 56389 if test -d "$path"; then 56390 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 56391 else 56392 dir="`$DIRNAME "$path"`" 56393 base="`$BASENAME "$path"`" 56394 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 56395 fi 56396 fi 56397 fi 56398 56399 56400 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 56401 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 56402 $as_echo_n "checking for freetype includes... " >&6; } 56403 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 56404 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 56405 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 56406 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 56407 $as_echo_n "checking for freetype libraries... " >&6; } 56408 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 56409 $as_echo "$FREETYPE_LIB_PATH" >&6; } 56410 fi 56411 56412 else 56413 56414 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 56415 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib/i386-linux-gnu" 56416 METHOD="well-known location" 56417 56418 # Let's start with an optimistic view of the world :-) 56419 FOUND_FREETYPE=yes 56420 56421 # First look for the canonical freetype main include file ft2build.h. 56422 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 56423 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 56424 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 56425 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 56426 # Fail. 56427 FOUND_FREETYPE=no 56428 fi 56429 fi 56430 56431 if test "x$FOUND_FREETYPE" = xyes; then 56432 # Include file found, let's continue the sanity check. 56433 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 56434 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 56435 56436 # Reset to default value 56437 FREETYPE_BASE_NAME=freetype 56438 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 56439 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 56440 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 56441 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 56442 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 56443 # for the .6 version explicitly. 56444 FREETYPE_BASE_NAME=freetype.6 56445 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 56446 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 56447 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 56448 else 56449 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 56450 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 56451 FOUND_FREETYPE=no 56452 fi 56453 else 56454 if test "x$OPENJDK_TARGET_OS" = xwindows; then 56455 # On Windows, we will need both .lib and .dll file. 56456 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 56457 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 56458 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 56459 FOUND_FREETYPE=no 56460 fi 56461 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 56462 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 56463 # Found lib in isa dir, use that instead. 56464 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 56465 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 56466 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 56467 fi 56468 fi 56469 fi 56470 56471 if test "x$FOUND_FREETYPE" = xyes; then 56472 56473 # Only process if variable expands to non-empty 56474 56475 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 56476 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56477 56478 # Input might be given as Windows format, start by converting to 56479 # unix format. 56480 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 56481 new_path=`$CYGPATH -u "$path"` 56482 56483 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 56484 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 56485 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 56486 # "foo.exe" is OK but "foo" is an error. 56487 # 56488 # This test is therefore slightly more accurate than "test -f" to check for file precense. 56489 # It is also a way to make sure we got the proper file name for the real test later on. 56490 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 56491 if test "x$test_shortpath" = x; then 56492 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 56493 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 56494 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 56495 fi 56496 56497 # Call helper function which possibly converts this using DOS-style short mode. 56498 # If so, the updated path is stored in $new_path. 56499 56500 input_path="$new_path" 56501 # Check if we need to convert this using DOS-style short mode. If the path 56502 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56503 # take no chances and rewrite it. 56504 # Note: m4 eats our [], so we need to use [ and ] instead. 56505 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 56506 if test "x$has_forbidden_chars" != x; then 56507 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56508 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 56509 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 56510 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 56511 # Going to short mode and back again did indeed matter. Since short mode is 56512 # case insensitive, let's make it lowercase to improve readability. 56513 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56514 # Now convert it back to Unix-style (cygpath) 56515 input_path=`$CYGPATH -u "$shortmode_path"` 56516 new_path="$input_path" 56517 fi 56518 fi 56519 56520 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 56521 if test "x$test_cygdrive_prefix" = x; then 56522 # As a simple fix, exclude /usr/bin since it's not a real path. 56523 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 56524 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 56525 # a path prefixed by /cygdrive for fixpath to work. 56526 new_path="$CYGWIN_ROOT_PATH$input_path" 56527 fi 56528 fi 56529 56530 56531 if test "x$path" != "x$new_path"; then 56532 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 56533 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 56534 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 56535 fi 56536 56537 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56538 56539 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 56540 has_colon=`$ECHO $path | $GREP ^.:` 56541 new_path="$path" 56542 if test "x$has_colon" = x; then 56543 # Not in mixed or Windows style, start by that. 56544 new_path=`cmd //c echo $path` 56545 fi 56546 56547 56548 input_path="$new_path" 56549 # Check if we need to convert this using DOS-style short mode. If the path 56550 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56551 # take no chances and rewrite it. 56552 # Note: m4 eats our [], so we need to use [ and ] instead. 56553 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 56554 if test "x$has_forbidden_chars" != x; then 56555 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56556 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56557 fi 56558 56559 56560 windows_path="$new_path" 56561 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56562 unix_path=`$CYGPATH -u "$windows_path"` 56563 new_path="$unix_path" 56564 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56565 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 56566 new_path="$unix_path" 56567 fi 56568 56569 if test "x$path" != "x$new_path"; then 56570 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 56571 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 56572 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 56573 fi 56574 56575 # Save the first 10 bytes of this path to the storage, so fixpath can work. 56576 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 56577 56578 else 56579 # We're on a unix platform. Hooray! :) 56580 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 56581 has_space=`$ECHO "$path" | $GREP " "` 56582 if test "x$has_space" != x; then 56583 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 56584 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 56585 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 56586 fi 56587 56588 # Use eval to expand a potential ~ 56589 eval path="$path" 56590 if test ! -f "$path" && test ! -d "$path"; then 56591 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 56592 fi 56593 56594 if test -d "$path"; then 56595 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 56596 else 56597 dir="`$DIRNAME "$path"`" 56598 base="`$BASENAME "$path"`" 56599 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 56600 fi 56601 fi 56602 fi 56603 56604 56605 # Only process if variable expands to non-empty 56606 56607 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 56608 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56609 56610 # Input might be given as Windows format, start by converting to 56611 # unix format. 56612 path="$POTENTIAL_FREETYPE_LIB_PATH" 56613 new_path=`$CYGPATH -u "$path"` 56614 56615 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 56616 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 56617 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 56618 # "foo.exe" is OK but "foo" is an error. 56619 # 56620 # This test is therefore slightly more accurate than "test -f" to check for file precense. 56621 # It is also a way to make sure we got the proper file name for the real test later on. 56622 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 56623 if test "x$test_shortpath" = x; then 56624 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 56625 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 56626 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 56627 fi 56628 56629 # Call helper function which possibly converts this using DOS-style short mode. 56630 # If so, the updated path is stored in $new_path. 56631 56632 input_path="$new_path" 56633 # Check if we need to convert this using DOS-style short mode. If the path 56634 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56635 # take no chances and rewrite it. 56636 # Note: m4 eats our [], so we need to use [ and ] instead. 56637 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 56638 if test "x$has_forbidden_chars" != x; then 56639 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56640 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 56641 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 56642 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 56643 # Going to short mode and back again did indeed matter. Since short mode is 56644 # case insensitive, let's make it lowercase to improve readability. 56645 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56646 # Now convert it back to Unix-style (cygpath) 56647 input_path=`$CYGPATH -u "$shortmode_path"` 56648 new_path="$input_path" 56649 fi 56650 fi 56651 56652 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 56653 if test "x$test_cygdrive_prefix" = x; then 56654 # As a simple fix, exclude /usr/bin since it's not a real path. 56655 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 56656 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 56657 # a path prefixed by /cygdrive for fixpath to work. 56658 new_path="$CYGWIN_ROOT_PATH$input_path" 56659 fi 56660 fi 56661 56662 56663 if test "x$path" != "x$new_path"; then 56664 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 56665 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 56666 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 56667 fi 56668 56669 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56670 56671 path="$POTENTIAL_FREETYPE_LIB_PATH" 56672 has_colon=`$ECHO $path | $GREP ^.:` 56673 new_path="$path" 56674 if test "x$has_colon" = x; then 56675 # Not in mixed or Windows style, start by that. 56676 new_path=`cmd //c echo $path` 56677 fi 56678 56679 56680 input_path="$new_path" 56681 # Check if we need to convert this using DOS-style short mode. If the path 56682 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56683 # take no chances and rewrite it. 56684 # Note: m4 eats our [], so we need to use [ and ] instead. 56685 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 56686 if test "x$has_forbidden_chars" != x; then 56687 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56688 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56689 fi 56690 56691 56692 windows_path="$new_path" 56693 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56694 unix_path=`$CYGPATH -u "$windows_path"` 56695 new_path="$unix_path" 56696 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56697 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 56698 new_path="$unix_path" 56699 fi 56700 56701 if test "x$path" != "x$new_path"; then 56702 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 56703 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 56704 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 56705 fi 56706 56707 # Save the first 10 bytes of this path to the storage, so fixpath can work. 56708 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 56709 56710 else 56711 # We're on a unix platform. Hooray! :) 56712 path="$POTENTIAL_FREETYPE_LIB_PATH" 56713 has_space=`$ECHO "$path" | $GREP " "` 56714 if test "x$has_space" != x; then 56715 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 56716 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 56717 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 56718 fi 56719 56720 # Use eval to expand a potential ~ 56721 eval path="$path" 56722 if test ! -f "$path" && test ! -d "$path"; then 56723 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 56724 fi 56725 56726 if test -d "$path"; then 56727 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 56728 else 56729 dir="`$DIRNAME "$path"`" 56730 base="`$BASENAME "$path"`" 56731 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 56732 fi 56733 fi 56734 fi 56735 56736 56737 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 56738 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 56739 $as_echo_n "checking for freetype includes... " >&6; } 56740 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 56741 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 56742 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 56743 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 56744 $as_echo_n "checking for freetype libraries... " >&6; } 56745 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 56746 $as_echo "$FREETYPE_LIB_PATH" >&6; } 56747 fi 56748 56749 if test "x$FOUND_FREETYPE" != xyes; then 56750 56751 POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include" 56752 POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib32" 56753 METHOD="well-known location" 56754 56755 # Let's start with an optimistic view of the world :-) 56756 FOUND_FREETYPE=yes 56757 56758 # First look for the canonical freetype main include file ft2build.h. 56759 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 56760 # Oh no! Let's try in the freetype2 directory. This is needed at least at Mac OS X Yosemite. 56761 POTENTIAL_FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH/freetype2" 56762 if ! test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then 56763 # Fail. 56764 FOUND_FREETYPE=no 56765 fi 56766 fi 56767 56768 if test "x$FOUND_FREETYPE" = xyes; then 56769 # Include file found, let's continue the sanity check. 56770 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5 56771 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;} 56772 56773 # Reset to default value 56774 FREETYPE_BASE_NAME=freetype 56775 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 56776 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then 56777 if test "x$OPENJDK_TARGET_OS" = xmacosx \ 56778 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/${LIBRARY_PREFIX}freetype.6${SHARED_LIBRARY_SUFFIX}"; then 56779 # On Mac OS X Yosemite, the symlink from libfreetype.dylib to libfreetype.6.dylib disappeared. Check 56780 # for the .6 version explicitly. 56781 FREETYPE_BASE_NAME=freetype.6 56782 FREETYPE_LIB_NAME="${LIBRARY_PREFIX}${FREETYPE_BASE_NAME}${SHARED_LIBRARY_SUFFIX}" 56783 { $as_echo "$as_me:${as_lineno-$LINENO}: Compensating for missing symlink by using version 6 explicitly" >&5 56784 $as_echo "$as_me: Compensating for missing symlink by using version 6 explicitly" >&6;} 56785 else 56786 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5 56787 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;} 56788 FOUND_FREETYPE=no 56789 fi 56790 else 56791 if test "x$OPENJDK_TARGET_OS" = xwindows; then 56792 # On Windows, we will need both .lib and .dll file. 56793 if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib"; then 56794 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&5 56795 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/${FREETYPE_BASE_NAME}.lib. Ignoring location." >&6;} 56796 FOUND_FREETYPE=no 56797 fi 56798 elif test "x$OPENJDK_TARGET_OS" = xsolaris \ 56799 && test -s "$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR/$FREETYPE_LIB_NAME"; then 56800 # Found lib in isa dir, use that instead. 56801 POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH$OPENJDK_TARGET_CPU_ISADIR" 56802 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&5 56803 $as_echo "$as_me: Rewriting to use $POTENTIAL_FREETYPE_LIB_PATH instead" >&6;} 56804 fi 56805 fi 56806 fi 56807 56808 if test "x$FOUND_FREETYPE" = xyes; then 56809 56810 # Only process if variable expands to non-empty 56811 56812 if test "x$POTENTIAL_FREETYPE_INCLUDE_PATH" != x; then 56813 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56814 56815 # Input might be given as Windows format, start by converting to 56816 # unix format. 56817 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 56818 new_path=`$CYGPATH -u "$path"` 56819 56820 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 56821 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 56822 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 56823 # "foo.exe" is OK but "foo" is an error. 56824 # 56825 # This test is therefore slightly more accurate than "test -f" to check for file precense. 56826 # It is also a way to make sure we got the proper file name for the real test later on. 56827 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 56828 if test "x$test_shortpath" = x; then 56829 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 56830 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 56831 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5 56832 fi 56833 56834 # Call helper function which possibly converts this using DOS-style short mode. 56835 # If so, the updated path is stored in $new_path. 56836 56837 input_path="$new_path" 56838 # Check if we need to convert this using DOS-style short mode. If the path 56839 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56840 # take no chances and rewrite it. 56841 # Note: m4 eats our [], so we need to use [ and ] instead. 56842 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 56843 if test "x$has_forbidden_chars" != x; then 56844 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56845 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 56846 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 56847 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 56848 # Going to short mode and back again did indeed matter. Since short mode is 56849 # case insensitive, let's make it lowercase to improve readability. 56850 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56851 # Now convert it back to Unix-style (cygpath) 56852 input_path=`$CYGPATH -u "$shortmode_path"` 56853 new_path="$input_path" 56854 fi 56855 fi 56856 56857 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 56858 if test "x$test_cygdrive_prefix" = x; then 56859 # As a simple fix, exclude /usr/bin since it's not a real path. 56860 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 56861 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 56862 # a path prefixed by /cygdrive for fixpath to work. 56863 new_path="$CYGWIN_ROOT_PATH$input_path" 56864 fi 56865 fi 56866 56867 56868 if test "x$path" != "x$new_path"; then 56869 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 56870 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 56871 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 56872 fi 56873 56874 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56875 56876 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 56877 has_colon=`$ECHO $path | $GREP ^.:` 56878 new_path="$path" 56879 if test "x$has_colon" = x; then 56880 # Not in mixed or Windows style, start by that. 56881 new_path=`cmd //c echo $path` 56882 fi 56883 56884 56885 input_path="$new_path" 56886 # Check if we need to convert this using DOS-style short mode. If the path 56887 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56888 # take no chances and rewrite it. 56889 # Note: m4 eats our [], so we need to use [ and ] instead. 56890 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 56891 if test "x$has_forbidden_chars" != x; then 56892 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56893 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56894 fi 56895 56896 56897 windows_path="$new_path" 56898 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56899 unix_path=`$CYGPATH -u "$windows_path"` 56900 new_path="$unix_path" 56901 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 56902 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 56903 new_path="$unix_path" 56904 fi 56905 56906 if test "x$path" != "x$new_path"; then 56907 POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path" 56908 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 56909 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 56910 fi 56911 56912 # Save the first 10 bytes of this path to the storage, so fixpath can work. 56913 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 56914 56915 else 56916 # We're on a unix platform. Hooray! :) 56917 path="$POTENTIAL_FREETYPE_INCLUDE_PATH" 56918 has_space=`$ECHO "$path" | $GREP " "` 56919 if test "x$has_space" != x; then 56920 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 56921 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 56922 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 56923 fi 56924 56925 # Use eval to expand a potential ~ 56926 eval path="$path" 56927 if test ! -f "$path" && test ! -d "$path"; then 56928 as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 56929 fi 56930 56931 if test -d "$path"; then 56932 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 56933 else 56934 dir="`$DIRNAME "$path"`" 56935 base="`$BASENAME "$path"`" 56936 POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 56937 fi 56938 fi 56939 fi 56940 56941 56942 # Only process if variable expands to non-empty 56943 56944 if test "x$POTENTIAL_FREETYPE_LIB_PATH" != x; then 56945 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 56946 56947 # Input might be given as Windows format, start by converting to 56948 # unix format. 56949 path="$POTENTIAL_FREETYPE_LIB_PATH" 56950 new_path=`$CYGPATH -u "$path"` 56951 56952 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 56953 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 56954 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 56955 # "foo.exe" is OK but "foo" is an error. 56956 # 56957 # This test is therefore slightly more accurate than "test -f" to check for file precense. 56958 # It is also a way to make sure we got the proper file name for the real test later on. 56959 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 56960 if test "x$test_shortpath" = x; then 56961 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 56962 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 56963 as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5 56964 fi 56965 56966 # Call helper function which possibly converts this using DOS-style short mode. 56967 # If so, the updated path is stored in $new_path. 56968 56969 input_path="$new_path" 56970 # Check if we need to convert this using DOS-style short mode. If the path 56971 # contains just simple characters, use it. Otherwise (spaces, weird characters), 56972 # take no chances and rewrite it. 56973 # Note: m4 eats our [], so we need to use [ and ] instead. 56974 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 56975 if test "x$has_forbidden_chars" != x; then 56976 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 56977 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 56978 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 56979 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 56980 # Going to short mode and back again did indeed matter. Since short mode is 56981 # case insensitive, let's make it lowercase to improve readability. 56982 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 56983 # Now convert it back to Unix-style (cygpath) 56984 input_path=`$CYGPATH -u "$shortmode_path"` 56985 new_path="$input_path" 56986 fi 56987 fi 56988 56989 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 56990 if test "x$test_cygdrive_prefix" = x; then 56991 # As a simple fix, exclude /usr/bin since it's not a real path. 56992 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 56993 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 56994 # a path prefixed by /cygdrive for fixpath to work. 56995 new_path="$CYGWIN_ROOT_PATH$input_path" 56996 fi 56997 fi 56998 56999 57000 if test "x$path" != "x$new_path"; then 57001 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 57002 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 57003 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 57004 fi 57005 57006 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57007 57008 path="$POTENTIAL_FREETYPE_LIB_PATH" 57009 has_colon=`$ECHO $path | $GREP ^.:` 57010 new_path="$path" 57011 if test "x$has_colon" = x; then 57012 # Not in mixed or Windows style, start by that. 57013 new_path=`cmd //c echo $path` 57014 fi 57015 57016 57017 input_path="$new_path" 57018 # Check if we need to convert this using DOS-style short mode. If the path 57019 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57020 # take no chances and rewrite it. 57021 # Note: m4 eats our [], so we need to use [ and ] instead. 57022 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 57023 if test "x$has_forbidden_chars" != x; then 57024 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57025 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57026 fi 57027 57028 57029 windows_path="$new_path" 57030 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57031 unix_path=`$CYGPATH -u "$windows_path"` 57032 new_path="$unix_path" 57033 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57034 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 57035 new_path="$unix_path" 57036 fi 57037 57038 if test "x$path" != "x$new_path"; then 57039 POTENTIAL_FREETYPE_LIB_PATH="$new_path" 57040 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5 57041 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 57042 fi 57043 57044 # Save the first 10 bytes of this path to the storage, so fixpath can work. 57045 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 57046 57047 else 57048 # We're on a unix platform. Hooray! :) 57049 path="$POTENTIAL_FREETYPE_LIB_PATH" 57050 has_space=`$ECHO "$path" | $GREP " "` 57051 if test "x$has_space" != x; then 57052 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 57053 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 57054 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 57055 fi 57056 57057 # Use eval to expand a potential ~ 57058 eval path="$path" 57059 if test ! -f "$path" && test ! -d "$path"; then 57060 as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 57061 fi 57062 57063 if test -d "$path"; then 57064 POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 57065 else 57066 dir="`$DIRNAME "$path"`" 57067 base="`$BASENAME "$path"`" 57068 POTENTIAL_FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 57069 fi 57070 fi 57071 fi 57072 57073 57074 FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH" 57075 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5 57076 $as_echo_n "checking for freetype includes... " >&6; } 57077 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5 57078 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; } 57079 FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH" 57080 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5 57081 $as_echo_n "checking for freetype libraries... " >&6; } 57082 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5 57083 $as_echo "$FREETYPE_LIB_PATH" >&6; } 57084 fi 57085 57086 fi 57087 fi 57088 fi 57089 fi 57090 fi # end check in well-known locations 57091 57092 if test "x$FOUND_FREETYPE" != xyes; then 57093 57094 # Print a helpful message on how to acquire the necessary build dependency. 57095 # freetype is the help tag: freetype, cups, alsa etc 57096 MISSING_DEPENDENCY=freetype 57097 57098 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57099 cygwin_help $MISSING_DEPENDENCY 57100 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57101 msys_help $MISSING_DEPENDENCY 57102 else 57103 PKGHANDLER_COMMAND= 57104 57105 case $PKGHANDLER in 57106 apt-get) 57107 apt_help $MISSING_DEPENDENCY ;; 57108 yum) 57109 yum_help $MISSING_DEPENDENCY ;; 57110 port) 57111 port_help $MISSING_DEPENDENCY ;; 57112 pkgutil) 57113 pkgutil_help $MISSING_DEPENDENCY ;; 57114 pkgadd) 57115 pkgadd_help $MISSING_DEPENDENCY ;; 57116 esac 57117 57118 if test "x$PKGHANDLER_COMMAND" != x; then 57119 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 57120 fi 57121 fi 57122 57123 as_fn_error $? "Could not find freetype! $HELP_MSG " "$LINENO" 5 57124 fi 57125 fi # end user specified settings 57126 57127 # Set FREETYPE_CFLAGS, _LIBS and _LIB_PATH from include and lib dir. 57128 if test "x$FREETYPE_CFLAGS" = x; then 57129 57130 # Only process if variable expands to non-empty 57131 57132 if test "x$FREETYPE_INCLUDE_PATH" != x; then 57133 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57134 57135 # Input might be given as Windows format, start by converting to 57136 # unix format. 57137 path="$FREETYPE_INCLUDE_PATH" 57138 new_path=`$CYGPATH -u "$path"` 57139 57140 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 57141 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 57142 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 57143 # "foo.exe" is OK but "foo" is an error. 57144 # 57145 # This test is therefore slightly more accurate than "test -f" to check for file precense. 57146 # It is also a way to make sure we got the proper file name for the real test later on. 57147 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 57148 if test "x$test_shortpath" = x; then 57149 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 57150 $as_echo "$as_me: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 57151 as_fn_error $? "Cannot locate the the path of FREETYPE_INCLUDE_PATH" "$LINENO" 5 57152 fi 57153 57154 # Call helper function which possibly converts this using DOS-style short mode. 57155 # If so, the updated path is stored in $new_path. 57156 57157 input_path="$new_path" 57158 # Check if we need to convert this using DOS-style short mode. If the path 57159 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57160 # take no chances and rewrite it. 57161 # Note: m4 eats our [], so we need to use [ and ] instead. 57162 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 57163 if test "x$has_forbidden_chars" != x; then 57164 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57165 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 57166 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 57167 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 57168 # Going to short mode and back again did indeed matter. Since short mode is 57169 # case insensitive, let's make it lowercase to improve readability. 57170 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57171 # Now convert it back to Unix-style (cygpath) 57172 input_path=`$CYGPATH -u "$shortmode_path"` 57173 new_path="$input_path" 57174 fi 57175 fi 57176 57177 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 57178 if test "x$test_cygdrive_prefix" = x; then 57179 # As a simple fix, exclude /usr/bin since it's not a real path. 57180 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 57181 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 57182 # a path prefixed by /cygdrive for fixpath to work. 57183 new_path="$CYGWIN_ROOT_PATH$input_path" 57184 fi 57185 fi 57186 57187 57188 if test "x$path" != "x$new_path"; then 57189 FREETYPE_INCLUDE_PATH="$new_path" 57190 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 57191 $as_echo "$as_me: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 57192 fi 57193 57194 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57195 57196 path="$FREETYPE_INCLUDE_PATH" 57197 has_colon=`$ECHO $path | $GREP ^.:` 57198 new_path="$path" 57199 if test "x$has_colon" = x; then 57200 # Not in mixed or Windows style, start by that. 57201 new_path=`cmd //c echo $path` 57202 fi 57203 57204 57205 input_path="$new_path" 57206 # Check if we need to convert this using DOS-style short mode. If the path 57207 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57208 # take no chances and rewrite it. 57209 # Note: m4 eats our [], so we need to use [ and ] instead. 57210 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 57211 if test "x$has_forbidden_chars" != x; then 57212 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57213 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57214 fi 57215 57216 57217 windows_path="$new_path" 57218 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57219 unix_path=`$CYGPATH -u "$windows_path"` 57220 new_path="$unix_path" 57221 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57222 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 57223 new_path="$unix_path" 57224 fi 57225 57226 if test "x$path" != "x$new_path"; then 57227 FREETYPE_INCLUDE_PATH="$new_path" 57228 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5 57229 $as_echo "$as_me: Rewriting FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;} 57230 fi 57231 57232 # Save the first 10 bytes of this path to the storage, so fixpath can work. 57233 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 57234 57235 else 57236 # We're on a unix platform. Hooray! :) 57237 path="$FREETYPE_INCLUDE_PATH" 57238 has_space=`$ECHO "$path" | $GREP " "` 57239 if test "x$has_space" != x; then 57240 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5 57241 $as_echo "$as_me: The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;} 57242 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 57243 fi 57244 57245 # Use eval to expand a potential ~ 57246 eval path="$path" 57247 if test ! -f "$path" && test ! -d "$path"; then 57248 as_fn_error $? "The path of FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 57249 fi 57250 57251 if test -d "$path"; then 57252 FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`" 57253 else 57254 dir="`$DIRNAME "$path"`" 57255 base="`$BASENAME "$path"`" 57256 FREETYPE_INCLUDE_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 57257 fi 57258 fi 57259 fi 57260 57261 if test -d $FREETYPE_INCLUDE_PATH/freetype2/freetype; then 57262 FREETYPE_CFLAGS="-I$FREETYPE_INCLUDE_PATH/freetype2 -I$FREETYPE_INCLUDE_PATH" 57263 else 57264 FREETYPE_CFLAGS="-I$FREETYPE_INCLUDE_PATH" 57265 fi 57266 fi 57267 57268 if test "x$FREETYPE_LIBS" = x; then 57269 57270 # Only process if variable expands to non-empty 57271 57272 if test "x$FREETYPE_LIB_PATH" != x; then 57273 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57274 57275 # Input might be given as Windows format, start by converting to 57276 # unix format. 57277 path="$FREETYPE_LIB_PATH" 57278 new_path=`$CYGPATH -u "$path"` 57279 57280 # Cygwin tries to hide some aspects of the Windows file system, such that binaries are 57281 # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered 57282 # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then 57283 # "foo.exe" is OK but "foo" is an error. 57284 # 57285 # This test is therefore slightly more accurate than "test -f" to check for file precense. 57286 # It is also a way to make sure we got the proper file name for the real test later on. 57287 test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null` 57288 if test "x$test_shortpath" = x; then 57289 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 57290 $as_echo "$as_me: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 57291 as_fn_error $? "Cannot locate the the path of FREETYPE_LIB_PATH" "$LINENO" 5 57292 fi 57293 57294 # Call helper function which possibly converts this using DOS-style short mode. 57295 # If so, the updated path is stored in $new_path. 57296 57297 input_path="$new_path" 57298 # Check if we need to convert this using DOS-style short mode. If the path 57299 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57300 # take no chances and rewrite it. 57301 # Note: m4 eats our [], so we need to use [ and ] instead. 57302 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]` 57303 if test "x$has_forbidden_chars" != x; then 57304 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57305 shortmode_path=`$CYGPATH -s -m -a "$input_path"` 57306 path_after_shortmode=`$CYGPATH -u "$shortmode_path"` 57307 if test "x$path_after_shortmode" != "x$input_to_shortpath"; then 57308 # Going to short mode and back again did indeed matter. Since short mode is 57309 # case insensitive, let's make it lowercase to improve readability. 57310 shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57311 # Now convert it back to Unix-style (cygpath) 57312 input_path=`$CYGPATH -u "$shortmode_path"` 57313 new_path="$input_path" 57314 fi 57315 fi 57316 57317 test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/` 57318 if test "x$test_cygdrive_prefix" = x; then 57319 # As a simple fix, exclude /usr/bin since it's not a real path. 57320 if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then 57321 # The path is in a Cygwin special directory (e.g. /home). We need this converted to 57322 # a path prefixed by /cygdrive for fixpath to work. 57323 new_path="$CYGWIN_ROOT_PATH$input_path" 57324 fi 57325 fi 57326 57327 57328 if test "x$path" != "x$new_path"; then 57329 FREETYPE_LIB_PATH="$new_path" 57330 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&5 57331 $as_echo "$as_me: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 57332 fi 57333 57334 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57335 57336 path="$FREETYPE_LIB_PATH" 57337 has_colon=`$ECHO $path | $GREP ^.:` 57338 new_path="$path" 57339 if test "x$has_colon" = x; then 57340 # Not in mixed or Windows style, start by that. 57341 new_path=`cmd //c echo $path` 57342 fi 57343 57344 57345 input_path="$new_path" 57346 # Check if we need to convert this using DOS-style short mode. If the path 57347 # contains just simple characters, use it. Otherwise (spaces, weird characters), 57348 # take no chances and rewrite it. 57349 # Note: m4 eats our [], so we need to use [ and ] instead. 57350 has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]` 57351 if test "x$has_forbidden_chars" != x; then 57352 # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \) 57353 new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'` 57354 fi 57355 57356 57357 windows_path="$new_path" 57358 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57359 unix_path=`$CYGPATH -u "$windows_path"` 57360 new_path="$unix_path" 57361 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57362 unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'` 57363 new_path="$unix_path" 57364 fi 57365 57366 if test "x$path" != "x$new_path"; then 57367 FREETYPE_LIB_PATH="$new_path" 57368 { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&5 57369 $as_echo "$as_me: Rewriting FREETYPE_LIB_PATH to \"$new_path\"" >&6;} 57370 fi 57371 57372 # Save the first 10 bytes of this path to the storage, so fixpath can work. 57373 all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}") 57374 57375 else 57376 # We're on a unix platform. Hooray! :) 57377 path="$FREETYPE_LIB_PATH" 57378 has_space=`$ECHO "$path" | $GREP " "` 57379 if test "x$has_space" != x; then 57380 { $as_echo "$as_me:${as_lineno-$LINENO}: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5 57381 $as_echo "$as_me: The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;} 57382 as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5 57383 fi 57384 57385 # Use eval to expand a potential ~ 57386 eval path="$path" 57387 if test ! -f "$path" && test ! -d "$path"; then 57388 as_fn_error $? "The path of FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5 57389 fi 57390 57391 if test -d "$path"; then 57392 FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`" 57393 else 57394 dir="`$DIRNAME "$path"`" 57395 base="`$BASENAME "$path"`" 57396 FREETYPE_LIB_PATH="`cd "$dir"; $THEPWDCMD -L`/$base" 57397 fi 57398 fi 57399 fi 57400 57401 if test "x$OPENJDK_TARGET_OS" = xwindows; then 57402 FREETYPE_LIBS="$FREETYPE_LIB_PATH/$FREETYPE_BASE_NAME.lib" 57403 else 57404 FREETYPE_LIBS="-L$FREETYPE_LIB_PATH -l$FREETYPE_BASE_NAME" 57405 fi 57406 fi 57407 57408 # Try to compile it 57409 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we can compile and link with freetype" >&5 57410 $as_echo_n "checking if we can compile and link with freetype... " >&6; } 57411 ac_ext=cpp 57412 ac_cpp='$CXXCPP $CPPFLAGS' 57413 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 57414 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 57415 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 57416 57417 PREV_CXXCFLAGS="$CXXFLAGS" 57418 PREV_LIBS="$LIBS" 57419 PREV_CXX="$CXX" 57420 CXXFLAGS="$CXXFLAGS $FREETYPE_CFLAGS" 57421 LIBS="$LIBS $FREETYPE_LIBS" 57422 CXX="$FIXPATH $CXX" 57423 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 57424 /* end confdefs.h. */ 57425 57426 #include<ft2build.h> 57427 #include FT_FREETYPE_H 57428 int main () { 57429 FT_Init_FreeType(NULL); 57430 return 0; 57431 } 57432 57433 _ACEOF 57434 if ac_fn_cxx_try_link "$LINENO"; then : 57435 57436 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 57437 $as_echo "yes" >&6; } 57438 57439 else 57440 57441 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 57442 $as_echo "no" >&6; } 57443 { $as_echo "$as_me:${as_lineno-$LINENO}: Could not compile and link with freetype. This might be a 32/64-bit mismatch." >&5 57444 $as_echo "$as_me: Could not compile and link with freetype. This might be a 32/64-bit mismatch." >&6;} 57445 { $as_echo "$as_me:${as_lineno-$LINENO}: Using FREETYPE_CFLAGS=$FREETYPE_CFLAGS and FREETYPE_LIBS=$FREETYPE_LIBS" >&5 57446 $as_echo "$as_me: Using FREETYPE_CFLAGS=$FREETYPE_CFLAGS and FREETYPE_LIBS=$FREETYPE_LIBS" >&6;} 57447 57448 57449 # Print a helpful message on how to acquire the necessary build dependency. 57450 # freetype is the help tag: freetype, cups, alsa etc 57451 MISSING_DEPENDENCY=freetype 57452 57453 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57454 cygwin_help $MISSING_DEPENDENCY 57455 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57456 msys_help $MISSING_DEPENDENCY 57457 else 57458 PKGHANDLER_COMMAND= 57459 57460 case $PKGHANDLER in 57461 apt-get) 57462 apt_help $MISSING_DEPENDENCY ;; 57463 yum) 57464 yum_help $MISSING_DEPENDENCY ;; 57465 port) 57466 port_help $MISSING_DEPENDENCY ;; 57467 pkgutil) 57468 pkgutil_help $MISSING_DEPENDENCY ;; 57469 pkgadd) 57470 pkgadd_help $MISSING_DEPENDENCY ;; 57471 esac 57472 57473 if test "x$PKGHANDLER_COMMAND" != x; then 57474 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 57475 fi 57476 fi 57477 57478 57479 as_fn_error $? "Can not continue without freetype. $HELP_MSG" "$LINENO" 5 57480 57481 57482 fi 57483 rm -f core conftest.err conftest.$ac_objext \ 57484 conftest$ac_exeext conftest.$ac_ext 57485 CXXCFLAGS="$PREV_CXXFLAGS" 57486 LIBS="$PREV_LIBS" 57487 CXX="$PREV_CXX" 57488 ac_ext=cpp 57489 ac_cpp='$CXXCPP $CPPFLAGS' 57490 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 57491 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 57492 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 57493 57494 57495 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if we should bundle freetype" >&5 57496 $as_echo_n "checking if we should bundle freetype... " >&6; } 57497 if test "x$BUNDLE_FREETYPE" = xyes; then 57498 FREETYPE_BUNDLE_LIB_PATH="$FREETYPE_LIB_PATH" 57499 fi 57500 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $BUNDLE_FREETYPE" >&5 57501 $as_echo "$BUNDLE_FREETYPE" >&6; } 57502 57503 fi # end freetype needed 57504 57505 57506 57507 57508 57509 57510 57511 # Check whether --with-alsa was given. 57512 if test "${with_alsa+set}" = set; then : 57513 withval=$with_alsa; 57514 fi 57515 57516 57517 # Check whether --with-alsa-include was given. 57518 if test "${with_alsa_include+set}" = set; then : 57519 withval=$with_alsa_include; 57520 fi 57521 57522 57523 # Check whether --with-alsa-lib was given. 57524 if test "${with_alsa_lib+set}" = set; then : 57525 withval=$with_alsa_lib; 57526 fi 57527 57528 57529 if test "x$NEEDS_LIB_ALSA" = xfalse; then 57530 if (test "x${with_alsa}" != x && test "x${with_alsa}" != xno) || \ 57531 (test "x${with_alsa_include}" != x && test "x${with_alsa_include}" != xno) || \ 57532 (test "x${with_alsa_lib}" != x && test "x${with_alsa_lib}" != xno); then 57533 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: alsa not used, so --with-alsa[-*] is ignored" >&5 57534 $as_echo "$as_me: WARNING: alsa not used, so --with-alsa[-*] is ignored" >&2;} 57535 fi 57536 ALSA_CFLAGS= 57537 ALSA_LIBS= 57538 else 57539 ALSA_FOUND=no 57540 57541 if test "x${with_alsa}" = xno || test "x${with_alsa_include}" = xno || test "x${with_alsa_lib}" = xno; then 57542 as_fn_error $? "It is not possible to disable the use of alsa. Remove the --without-alsa option." "$LINENO" 5 57543 fi 57544 57545 if test "x${with_alsa}" != x; then 57546 ALSA_LIBS="-L${with_alsa}/lib -lasound" 57547 ALSA_CFLAGS="-I${with_alsa}/include" 57548 ALSA_FOUND=yes 57549 fi 57550 if test "x${with_alsa_include}" != x; then 57551 ALSA_CFLAGS="-I${with_alsa_include}" 57552 ALSA_FOUND=yes 57553 fi 57554 if test "x${with_alsa_lib}" != x; then 57555 ALSA_LIBS="-L${with_alsa_lib} -lasound" 57556 ALSA_FOUND=yes 57557 fi 57558 # Do not try pkg-config if we have a sysroot set. 57559 if test "x$SYSROOT" = x; then 57560 if test "x$ALSA_FOUND" = xno; then 57561 57562 pkg_failed=no 57563 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ALSA" >&5 57564 $as_echo_n "checking for ALSA... " >&6; } 57565 57566 if test -n "$ALSA_CFLAGS"; then 57567 pkg_cv_ALSA_CFLAGS="$ALSA_CFLAGS" 57568 elif test -n "$PKG_CONFIG"; then 57569 if test -n "$PKG_CONFIG" && \ 57570 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"alsa\""; } >&5 57571 ($PKG_CONFIG --exists --print-errors "alsa") 2>&5 57572 ac_status=$? 57573 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 57574 test $ac_status = 0; }; then 57575 pkg_cv_ALSA_CFLAGS=`$PKG_CONFIG --cflags "alsa" 2>/dev/null` 57576 else 57577 pkg_failed=yes 57578 fi 57579 else 57580 pkg_failed=untried 57581 fi 57582 if test -n "$ALSA_LIBS"; then 57583 pkg_cv_ALSA_LIBS="$ALSA_LIBS" 57584 elif test -n "$PKG_CONFIG"; then 57585 if test -n "$PKG_CONFIG" && \ 57586 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"alsa\""; } >&5 57587 ($PKG_CONFIG --exists --print-errors "alsa") 2>&5 57588 ac_status=$? 57589 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 57590 test $ac_status = 0; }; then 57591 pkg_cv_ALSA_LIBS=`$PKG_CONFIG --libs "alsa" 2>/dev/null` 57592 else 57593 pkg_failed=yes 57594 fi 57595 else 57596 pkg_failed=untried 57597 fi 57598 57599 57600 57601 if test $pkg_failed = yes; then 57602 57603 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 57604 _pkg_short_errors_supported=yes 57605 else 57606 _pkg_short_errors_supported=no 57607 fi 57608 if test $_pkg_short_errors_supported = yes; then 57609 ALSA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "alsa" 2>&1` 57610 else 57611 ALSA_PKG_ERRORS=`$PKG_CONFIG --print-errors "alsa" 2>&1` 57612 fi 57613 # Put the nasty error message in config.log where it belongs 57614 echo "$ALSA_PKG_ERRORS" >&5 57615 57616 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 57617 $as_echo "no" >&6; } 57618 ALSA_FOUND=no 57619 elif test $pkg_failed = untried; then 57620 ALSA_FOUND=no 57621 else 57622 ALSA_CFLAGS=$pkg_cv_ALSA_CFLAGS 57623 ALSA_LIBS=$pkg_cv_ALSA_LIBS 57624 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 57625 $as_echo "yes" >&6; } 57626 ALSA_FOUND=yes 57627 fi 57628 fi 57629 fi 57630 if test "x$ALSA_FOUND" = xno; then 57631 for ac_header in alsa/asoundlib.h 57632 do : 57633 ac_fn_cxx_check_header_mongrel "$LINENO" "alsa/asoundlib.h" "ac_cv_header_alsa_asoundlib_h" "$ac_includes_default" 57634 if test "x$ac_cv_header_alsa_asoundlib_h" = xyes; then : 57635 cat >>confdefs.h <<_ACEOF 57636 #define HAVE_ALSA_ASOUNDLIB_H 1 57637 _ACEOF 57638 57639 ALSA_FOUND=yes 57640 ALSA_CFLAGS=-Iignoreme 57641 ALSA_LIBS=-lasound 57642 DEFAULT_ALSA=yes 57643 57644 else 57645 ALSA_FOUND=no 57646 57647 fi 57648 57649 done 57650 57651 fi 57652 if test "x$ALSA_FOUND" = xno; then 57653 57654 # Print a helpful message on how to acquire the necessary build dependency. 57655 # alsa is the help tag: freetype, cups, alsa etc 57656 MISSING_DEPENDENCY=alsa 57657 57658 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57659 cygwin_help $MISSING_DEPENDENCY 57660 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57661 msys_help $MISSING_DEPENDENCY 57662 else 57663 PKGHANDLER_COMMAND= 57664 57665 case $PKGHANDLER in 57666 apt-get) 57667 apt_help $MISSING_DEPENDENCY ;; 57668 yum) 57669 yum_help $MISSING_DEPENDENCY ;; 57670 port) 57671 port_help $MISSING_DEPENDENCY ;; 57672 pkgutil) 57673 pkgutil_help $MISSING_DEPENDENCY ;; 57674 pkgadd) 57675 pkgadd_help $MISSING_DEPENDENCY ;; 57676 esac 57677 57678 if test "x$PKGHANDLER_COMMAND" != x; then 57679 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 57680 fi 57681 fi 57682 57683 as_fn_error $? "Could not find alsa! $HELP_MSG" "$LINENO" 5 57684 fi 57685 fi 57686 57687 57688 57689 57690 57691 57692 # Check whether --with-libffi was given. 57693 if test "${with_libffi+set}" = set; then : 57694 withval=$with_libffi; 57695 fi 57696 57697 57698 # Check whether --with-libffi-include was given. 57699 if test "${with_libffi_include+set}" = set; then : 57700 withval=$with_libffi_include; 57701 fi 57702 57703 57704 # Check whether --with-libffi-lib was given. 57705 if test "${with_libffi_lib+set}" = set; then : 57706 withval=$with_libffi_lib; 57707 fi 57708 57709 57710 if test "x$NEEDS_LIB_FFI" = xfalse; then 57711 if (test "x${with_libffi}" != x && test "x${with_libffi}" != xno) || \ 57712 (test "x${with_libffi_include}" != x && test "x${with_libffi_include}" != xno) || \ 57713 (test "x${with_libffi_lib}" != x && test "x${with_libffi_lib}" != xno); then 57714 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: libffi not used, so --with-libffi[-*] is ignored" >&5 57715 $as_echo "$as_me: WARNING: libffi not used, so --with-libffi[-*] is ignored" >&2;} 57716 fi 57717 LIBFFI_CFLAGS= 57718 LIBFFI_LIBS= 57719 else 57720 LIBFFI_FOUND=no 57721 57722 if test "x${with_libffi}" = xno || test "x${with_libffi_include}" = xno || test "x${with_libffi_lib}" = xno; then 57723 as_fn_error $? "It is not possible to disable the use of libffi. Remove the --without-libffi option." "$LINENO" 5 57724 fi 57725 57726 if test "x${with_libffi}" != x; then 57727 LIBFFI_LIBS="-L${with_libffi}/lib -lffi" 57728 LIBFFI_CFLAGS="-I${with_libffi}/include" 57729 LIBFFI_FOUND=yes 57730 fi 57731 if test "x${with_libffi_include}" != x; then 57732 LIBFFI_CFLAGS="-I${with_libffi_include}" 57733 LIBFFI_FOUND=yes 57734 fi 57735 if test "x${with_libffi_lib}" != x; then 57736 LIBFFI_LIBS="-L${with_libffi_lib} -lffi" 57737 LIBFFI_FOUND=yes 57738 fi 57739 # Do not try pkg-config if we have a sysroot set. 57740 if test "x$SYSROOT" = x; then 57741 if test "x$LIBFFI_FOUND" = xno; then 57742 # Figure out LIBFFI_CFLAGS and LIBFFI_LIBS 57743 57744 pkg_failed=no 57745 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LIBFFI" >&5 57746 $as_echo_n "checking for LIBFFI... " >&6; } 57747 57748 if test -n "$LIBFFI_CFLAGS"; then 57749 pkg_cv_LIBFFI_CFLAGS="$LIBFFI_CFLAGS" 57750 elif test -n "$PKG_CONFIG"; then 57751 if test -n "$PKG_CONFIG" && \ 57752 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libffi\""; } >&5 57753 ($PKG_CONFIG --exists --print-errors "libffi") 2>&5 57754 ac_status=$? 57755 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 57756 test $ac_status = 0; }; then 57757 pkg_cv_LIBFFI_CFLAGS=`$PKG_CONFIG --cflags "libffi" 2>/dev/null` 57758 else 57759 pkg_failed=yes 57760 fi 57761 else 57762 pkg_failed=untried 57763 fi 57764 if test -n "$LIBFFI_LIBS"; then 57765 pkg_cv_LIBFFI_LIBS="$LIBFFI_LIBS" 57766 elif test -n "$PKG_CONFIG"; then 57767 if test -n "$PKG_CONFIG" && \ 57768 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libffi\""; } >&5 57769 ($PKG_CONFIG --exists --print-errors "libffi") 2>&5 57770 ac_status=$? 57771 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 57772 test $ac_status = 0; }; then 57773 pkg_cv_LIBFFI_LIBS=`$PKG_CONFIG --libs "libffi" 2>/dev/null` 57774 else 57775 pkg_failed=yes 57776 fi 57777 else 57778 pkg_failed=untried 57779 fi 57780 57781 57782 57783 if test $pkg_failed = yes; then 57784 57785 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 57786 _pkg_short_errors_supported=yes 57787 else 57788 _pkg_short_errors_supported=no 57789 fi 57790 if test $_pkg_short_errors_supported = yes; then 57791 LIBFFI_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "libffi" 2>&1` 57792 else 57793 LIBFFI_PKG_ERRORS=`$PKG_CONFIG --print-errors "libffi" 2>&1` 57794 fi 57795 # Put the nasty error message in config.log where it belongs 57796 echo "$LIBFFI_PKG_ERRORS" >&5 57797 57798 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 57799 $as_echo "no" >&6; } 57800 LIBFFI_FOUND=no 57801 elif test $pkg_failed = untried; then 57802 LIBFFI_FOUND=no 57803 else 57804 LIBFFI_CFLAGS=$pkg_cv_LIBFFI_CFLAGS 57805 LIBFFI_LIBS=$pkg_cv_LIBFFI_LIBS 57806 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 57807 $as_echo "yes" >&6; } 57808 LIBFFI_FOUND=yes 57809 fi 57810 fi 57811 fi 57812 if test "x$LIBFFI_FOUND" = xno; then 57813 for ac_header in ffi.h 57814 do : 57815 ac_fn_cxx_check_header_mongrel "$LINENO" "ffi.h" "ac_cv_header_ffi_h" "$ac_includes_default" 57816 if test "x$ac_cv_header_ffi_h" = xyes; then : 57817 cat >>confdefs.h <<_ACEOF 57818 #define HAVE_FFI_H 1 57819 _ACEOF 57820 57821 LIBFFI_FOUND=yes 57822 LIBFFI_CFLAGS= 57823 LIBFFI_LIBS=-lffi 57824 57825 else 57826 LIBFFI_FOUND=no 57827 57828 fi 57829 57830 done 57831 57832 fi 57833 if test "x$LIBFFI_FOUND" = xno; then 57834 57835 # Print a helpful message on how to acquire the necessary build dependency. 57836 # ffi is the help tag: freetype, cups, alsa etc 57837 MISSING_DEPENDENCY=ffi 57838 57839 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57840 cygwin_help $MISSING_DEPENDENCY 57841 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57842 msys_help $MISSING_DEPENDENCY 57843 else 57844 PKGHANDLER_COMMAND= 57845 57846 case $PKGHANDLER in 57847 apt-get) 57848 apt_help $MISSING_DEPENDENCY ;; 57849 yum) 57850 yum_help $MISSING_DEPENDENCY ;; 57851 port) 57852 port_help $MISSING_DEPENDENCY ;; 57853 pkgutil) 57854 pkgutil_help $MISSING_DEPENDENCY ;; 57855 pkgadd) 57856 pkgadd_help $MISSING_DEPENDENCY ;; 57857 esac 57858 57859 if test "x$PKGHANDLER_COMMAND" != x; then 57860 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 57861 fi 57862 fi 57863 57864 as_fn_error $? "Could not find libffi! $HELP_MSG" "$LINENO" 5 57865 fi 57866 57867 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if libffi works" >&5 57868 $as_echo_n "checking if libffi works... " >&6; } 57869 ac_ext=c 57870 ac_cpp='$CPP $CPPFLAGS' 57871 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' 57872 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 57873 ac_compiler_gnu=$ac_cv_c_compiler_gnu 57874 57875 OLD_CFLAGS="$CFLAGS" 57876 CFLAGS="$CFLAGS $LIBFFI_CFLAGS" 57877 OLD_LIBS="$LIBS" 57878 LIBS="$LIBS $LIBFFI_LIBS" 57879 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 57880 /* end confdefs.h. */ 57881 #include <ffi.h> 57882 int 57883 main () 57884 { 57885 57886 ffi_call(NULL, NULL, NULL, NULL); 57887 return 0; 57888 57889 ; 57890 return 0; 57891 } 57892 _ACEOF 57893 if ac_fn_c_try_link "$LINENO"; then : 57894 LIBFFI_WORKS=yes 57895 else 57896 LIBFFI_WORKS=no 57897 57898 fi 57899 rm -f core conftest.err conftest.$ac_objext \ 57900 conftest$ac_exeext conftest.$ac_ext 57901 CFLAGS="$OLD_CFLAGS" 57902 LIBS="$OLD_LIBS" 57903 ac_ext=cpp 57904 ac_cpp='$CXXCPP $CPPFLAGS' 57905 ac_compile='$CXX -c $CXXFLAGS $CPPFLAGS conftest.$ac_ext >&5' 57906 ac_link='$CXX -o conftest$ac_exeext $CXXFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' 57907 ac_compiler_gnu=$ac_cv_cxx_compiler_gnu 57908 57909 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LIBFFI_WORKS" >&5 57910 $as_echo "$LIBFFI_WORKS" >&6; } 57911 57912 if test "x$LIBFFI_WORKS" = xno; then 57913 57914 # Print a helpful message on how to acquire the necessary build dependency. 57915 # ffi is the help tag: freetype, cups, alsa etc 57916 MISSING_DEPENDENCY=ffi 57917 57918 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 57919 cygwin_help $MISSING_DEPENDENCY 57920 elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 57921 msys_help $MISSING_DEPENDENCY 57922 else 57923 PKGHANDLER_COMMAND= 57924 57925 case $PKGHANDLER in 57926 apt-get) 57927 apt_help $MISSING_DEPENDENCY ;; 57928 yum) 57929 yum_help $MISSING_DEPENDENCY ;; 57930 port) 57931 port_help $MISSING_DEPENDENCY ;; 57932 pkgutil) 57933 pkgutil_help $MISSING_DEPENDENCY ;; 57934 pkgadd) 57935 pkgadd_help $MISSING_DEPENDENCY ;; 57936 esac 57937 57938 if test "x$PKGHANDLER_COMMAND" != x; then 57939 HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'." 57940 fi 57941 fi 57942 57943 as_fn_error $? "Found libffi but could not link and compile with it. $HELP_MSG" "$LINENO" 5 57944 fi 57945 fi 57946 57947 57948 57949 57950 57951 if test "x$JVM_VARIANT_ZEROSHARK" = xtrue; then 57952 # Extract the first word of "llvm-config", so it can be a program name with args. 57953 set dummy llvm-config; ac_word=$2 57954 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 57955 $as_echo_n "checking for $ac_word... " >&6; } 57956 if ${ac_cv_prog_LLVM_CONFIG+:} false; then : 57957 $as_echo_n "(cached) " >&6 57958 else 57959 if test -n "$LLVM_CONFIG"; then 57960 ac_cv_prog_LLVM_CONFIG="$LLVM_CONFIG" # Let the user override the test. 57961 else 57962 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 57963 for as_dir in $PATH 57964 do 57965 IFS=$as_save_IFS 57966 test -z "$as_dir" && as_dir=. 57967 for ac_exec_ext in '' $ac_executable_extensions; do 57968 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 57969 ac_cv_prog_LLVM_CONFIG="llvm-config" 57970 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 57971 break 2 57972 fi 57973 done 57974 done 57975 IFS=$as_save_IFS 57976 57977 fi 57978 fi 57979 LLVM_CONFIG=$ac_cv_prog_LLVM_CONFIG 57980 if test -n "$LLVM_CONFIG"; then 57981 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $LLVM_CONFIG" >&5 57982 $as_echo "$LLVM_CONFIG" >&6; } 57983 else 57984 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 57985 $as_echo "no" >&6; } 57986 fi 57987 57988 57989 57990 if test "x$LLVM_CONFIG" != xllvm-config; then 57991 as_fn_error $? "llvm-config not found in $PATH." "$LINENO" 5 57992 fi 57993 57994 llvm_components="jit mcjit engine nativecodegen native" 57995 unset LLVM_CFLAGS 57996 for flag in $("$LLVM_CONFIG" --cxxflags); do 57997 if echo "${flag}" | grep -q '^-[ID]'; then 57998 if test "${flag}" != "-D_DEBUG" ; then 57999 if test "${LLVM_CFLAGS}" != "" ; then 58000 LLVM_CFLAGS="${LLVM_CFLAGS} " 58001 fi 58002 LLVM_CFLAGS="${LLVM_CFLAGS}${flag}" 58003 fi 58004 fi 58005 done 58006 llvm_version=$("${LLVM_CONFIG}" --version | sed 's/\.//; s/svn.*//') 58007 LLVM_CFLAGS="${LLVM_CFLAGS} -DSHARK_LLVM_VERSION=${llvm_version}" 58008 58009 unset LLVM_LDFLAGS 58010 for flag in $("${LLVM_CONFIG}" --ldflags); do 58011 if echo "${flag}" | grep -q '^-L'; then 58012 if test "${LLVM_LDFLAGS}" != ""; then 58013 LLVM_LDFLAGS="${LLVM_LDFLAGS} " 58014 fi 58015 LLVM_LDFLAGS="${LLVM_LDFLAGS}${flag}" 58016 fi 58017 done 58018 58019 unset LLVM_LIBS 58020 for flag in $("${LLVM_CONFIG}" --libs ${llvm_components}); do 58021 if echo "${flag}" | grep -q '^-l'; then 58022 if test "${LLVM_LIBS}" != ""; then 58023 LLVM_LIBS="${LLVM_LIBS} " 58024 fi 58025 LLVM_LIBS="${LLVM_LIBS}${flag}" 58026 fi 58027 done 58028 58029 58030 58031 58032 fi 58033 58034 58035 58036 # Check whether --with-libjpeg was given. 58037 if test "${with_libjpeg+set}" = set; then : 58038 withval=$with_libjpeg; 58039 fi 58040 58041 58042 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which libjpeg to use" >&5 58043 $as_echo_n "checking for which libjpeg to use... " >&6; } 58044 # default is bundled 58045 DEFAULT_LIBJPEG=bundled 58046 # if user didn't specify, use DEFAULT_LIBJPEG 58047 if test "x${with_libjpeg}" = "x"; then 58048 with_libjpeg=${DEFAULT_LIBJPEG} 58049 fi 58050 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_libjpeg}" >&5 58051 $as_echo "${with_libjpeg}" >&6; } 58052 58053 if test "x${with_libjpeg}" = "xbundled"; then 58054 USE_EXTERNAL_LIBJPEG=false 58055 elif test "x${with_libjpeg}" = "xsystem"; then 58056 ac_fn_cxx_check_header_mongrel "$LINENO" "jpeglib.h" "ac_cv_header_jpeglib_h" "$ac_includes_default" 58057 if test "x$ac_cv_header_jpeglib_h" = xyes; then : 58058 58059 else 58060 as_fn_error $? "--with-libjpeg=system specified, but jpeglib.h not found!" "$LINENO" 5 58061 fi 58062 58063 58064 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for jpeg_CreateDecompress in -ljpeg" >&5 58065 $as_echo_n "checking for jpeg_CreateDecompress in -ljpeg... " >&6; } 58066 if ${ac_cv_lib_jpeg_jpeg_CreateDecompress+:} false; then : 58067 $as_echo_n "(cached) " >&6 58068 else 58069 ac_check_lib_save_LIBS=$LIBS 58070 LIBS="-ljpeg $LIBS" 58071 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 58072 /* end confdefs.h. */ 58073 58074 /* Override any GCC internal prototype to avoid an error. 58075 Use char because int might match the return type of a GCC 58076 builtin and then its argument prototype would still apply. */ 58077 #ifdef __cplusplus 58078 extern "C" 58079 #endif 58080 char jpeg_CreateDecompress (); 58081 int 58082 main () 58083 { 58084 return jpeg_CreateDecompress (); 58085 ; 58086 return 0; 58087 } 58088 _ACEOF 58089 if ac_fn_cxx_try_link "$LINENO"; then : 58090 ac_cv_lib_jpeg_jpeg_CreateDecompress=yes 58091 else 58092 ac_cv_lib_jpeg_jpeg_CreateDecompress=no 58093 fi 58094 rm -f core conftest.err conftest.$ac_objext \ 58095 conftest$ac_exeext conftest.$ac_ext 58096 LIBS=$ac_check_lib_save_LIBS 58097 fi 58098 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_jpeg_jpeg_CreateDecompress" >&5 58099 $as_echo "$ac_cv_lib_jpeg_jpeg_CreateDecompress" >&6; } 58100 if test "x$ac_cv_lib_jpeg_jpeg_CreateDecompress" = xyes; then : 58101 cat >>confdefs.h <<_ACEOF 58102 #define HAVE_LIBJPEG 1 58103 _ACEOF 58104 58105 LIBS="-ljpeg $LIBS" 58106 58107 else 58108 as_fn_error $? "--with-libjpeg=system specified, but no libjpeg found" "$LINENO" 5 58109 fi 58110 58111 58112 USE_EXTERNAL_LIBJPEG=true 58113 else 58114 as_fn_error $? "Invalid use of --with-libjpeg: ${with_libjpeg}, use 'system' or 'bundled'" "$LINENO" 5 58115 fi 58116 58117 58118 58119 58120 58121 # Check whether --with-giflib was given. 58122 if test "${with_giflib+set}" = set; then : 58123 withval=$with_giflib; 58124 fi 58125 58126 58127 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which giflib to use" >&5 58128 $as_echo_n "checking for which giflib to use... " >&6; } 58129 # default is bundled 58130 DEFAULT_GIFLIB=bundled 58131 # if user didn't specify, use DEFAULT_GIFLIB 58132 if test "x${with_giflib}" = "x"; then 58133 with_giflib=${DEFAULT_GIFLIB} 58134 fi 58135 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${with_giflib}" >&5 58136 $as_echo "${with_giflib}" >&6; } 58137 58138 if test "x${with_giflib}" = "xbundled"; then 58139 USE_EXTERNAL_LIBGIF=false 58140 elif test "x${with_giflib}" = "xsystem"; then 58141 ac_fn_cxx_check_header_mongrel "$LINENO" "gif_lib.h" "ac_cv_header_gif_lib_h" "$ac_includes_default" 58142 if test "x$ac_cv_header_gif_lib_h" = xyes; then : 58143 58144 else 58145 as_fn_error $? "--with-giflib=system specified, but gif_lib.h not found!" "$LINENO" 5 58146 fi 58147 58148 58149 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for DGifGetCode in -lgif" >&5 58150 $as_echo_n "checking for DGifGetCode in -lgif... " >&6; } 58151 if ${ac_cv_lib_gif_DGifGetCode+:} false; then : 58152 $as_echo_n "(cached) " >&6 58153 else 58154 ac_check_lib_save_LIBS=$LIBS 58155 LIBS="-lgif $LIBS" 58156 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 58157 /* end confdefs.h. */ 58158 58159 /* Override any GCC internal prototype to avoid an error. 58160 Use char because int might match the return type of a GCC 58161 builtin and then its argument prototype would still apply. */ 58162 #ifdef __cplusplus 58163 extern "C" 58164 #endif 58165 char DGifGetCode (); 58166 int 58167 main () 58168 { 58169 return DGifGetCode (); 58170 ; 58171 return 0; 58172 } 58173 _ACEOF 58174 if ac_fn_cxx_try_link "$LINENO"; then : 58175 ac_cv_lib_gif_DGifGetCode=yes 58176 else 58177 ac_cv_lib_gif_DGifGetCode=no 58178 fi 58179 rm -f core conftest.err conftest.$ac_objext \ 58180 conftest$ac_exeext conftest.$ac_ext 58181 LIBS=$ac_check_lib_save_LIBS 58182 fi 58183 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_gif_DGifGetCode" >&5 58184 $as_echo "$ac_cv_lib_gif_DGifGetCode" >&6; } 58185 if test "x$ac_cv_lib_gif_DGifGetCode" = xyes; then : 58186 cat >>confdefs.h <<_ACEOF 58187 #define HAVE_LIBGIF 1 58188 _ACEOF 58189 58190 LIBS="-lgif $LIBS" 58191 58192 else 58193 as_fn_error $? "--with-giflib=system specified, but no giflib found!" "$LINENO" 5 58194 fi 58195 58196 58197 USE_EXTERNAL_LIBGIF=true 58198 else 58199 as_fn_error $? "Invalid value of --with-giflib: ${with_giflib}, use 'system' or 'bundled'" "$LINENO" 5 58200 fi 58201 58202 58203 58204 58205 58206 # Check whether --with-libpng was given. 58207 if test "${with_libpng+set}" = set; then : 58208 withval=$with_libpng; 58209 fi 58210 58211 58212 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which libpng to use" >&5 58213 $as_echo_n "checking for which libpng to use... " >&6; } 58214 58215 # default is bundled 58216 DEFAULT_LIBPNG=bundled 58217 # if user didn't specify, use DEFAULT_LIBPNG 58218 if test "x${with_libpng}" = "x"; then 58219 with_libpng=${DEFAULT_LIBPNG} 58220 fi 58221 58222 if test "x${with_libpng}" = "xbundled"; then 58223 USE_EXTERNAL_LIBPNG=false 58224 { $as_echo "$as_me:${as_lineno-$LINENO}: result: bundled" >&5 58225 $as_echo "bundled" >&6; } 58226 elif test "x${with_libpng}" = "xsystem"; then 58227 58228 pkg_failed=no 58229 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for PNG" >&5 58230 $as_echo_n "checking for PNG... " >&6; } 58231 58232 if test -n "$PNG_CFLAGS"; then 58233 pkg_cv_PNG_CFLAGS="$PNG_CFLAGS" 58234 elif test -n "$PKG_CONFIG"; then 58235 if test -n "$PKG_CONFIG" && \ 58236 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libpng\""; } >&5 58237 ($PKG_CONFIG --exists --print-errors "libpng") 2>&5 58238 ac_status=$? 58239 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 58240 test $ac_status = 0; }; then 58241 pkg_cv_PNG_CFLAGS=`$PKG_CONFIG --cflags "libpng" 2>/dev/null` 58242 else 58243 pkg_failed=yes 58244 fi 58245 else 58246 pkg_failed=untried 58247 fi 58248 if test -n "$PNG_LIBS"; then 58249 pkg_cv_PNG_LIBS="$PNG_LIBS" 58250 elif test -n "$PKG_CONFIG"; then 58251 if test -n "$PKG_CONFIG" && \ 58252 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"libpng\""; } >&5 58253 ($PKG_CONFIG --exists --print-errors "libpng") 2>&5 58254 ac_status=$? 58255 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 58256 test $ac_status = 0; }; then 58257 pkg_cv_PNG_LIBS=`$PKG_CONFIG --libs "libpng" 2>/dev/null` 58258 else 58259 pkg_failed=yes 58260 fi 58261 else 58262 pkg_failed=untried 58263 fi 58264 58265 58266 58267 if test $pkg_failed = yes; then 58268 58269 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 58270 _pkg_short_errors_supported=yes 58271 else 58272 _pkg_short_errors_supported=no 58273 fi 58274 if test $_pkg_short_errors_supported = yes; then 58275 PNG_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "libpng" 2>&1` 58276 else 58277 PNG_PKG_ERRORS=`$PKG_CONFIG --print-errors "libpng" 2>&1` 58278 fi 58279 # Put the nasty error message in config.log where it belongs 58280 echo "$PNG_PKG_ERRORS" >&5 58281 58282 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 58283 $as_echo "no" >&6; } 58284 LIBPNG_FOUND=no 58285 elif test $pkg_failed = untried; then 58286 LIBPNG_FOUND=no 58287 else 58288 PNG_CFLAGS=$pkg_cv_PNG_CFLAGS 58289 PNG_LIBS=$pkg_cv_PNG_LIBS 58290 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 58291 $as_echo "yes" >&6; } 58292 LIBPNG_FOUND=yes 58293 fi 58294 if test "x${LIBPNG_FOUND}" = "xyes"; then 58295 USE_EXTERNAL_LIBPNG=true 58296 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system" >&5 58297 $as_echo "system" >&6; } 58298 else 58299 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system not found" >&5 58300 $as_echo "system not found" >&6; } 58301 as_fn_error $? "--with-libpng=system specified, but no libpng found!" "$LINENO" 5 58302 fi 58303 else 58304 as_fn_error $? "Invalid value of --with-libpng: ${with_libpng}, use 'system' or 'bundled'" "$LINENO" 5 58305 fi 58306 58307 58308 58309 58310 58311 # Check whether --with-zlib was given. 58312 if test "${with_zlib+set}" = set; then : 58313 withval=$with_zlib; 58314 fi 58315 58316 58317 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for compress in -lz" >&5 58318 $as_echo_n "checking for compress in -lz... " >&6; } 58319 if ${ac_cv_lib_z_compress+:} false; then : 58320 $as_echo_n "(cached) " >&6 58321 else 58322 ac_check_lib_save_LIBS=$LIBS 58323 LIBS="-lz $LIBS" 58324 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 58325 /* end confdefs.h. */ 58326 58327 /* Override any GCC internal prototype to avoid an error. 58328 Use char because int might match the return type of a GCC 58329 builtin and then its argument prototype would still apply. */ 58330 #ifdef __cplusplus 58331 extern "C" 58332 #endif 58333 char compress (); 58334 int 58335 main () 58336 { 58337 return compress (); 58338 ; 58339 return 0; 58340 } 58341 _ACEOF 58342 if ac_fn_cxx_try_link "$LINENO"; then : 58343 ac_cv_lib_z_compress=yes 58344 else 58345 ac_cv_lib_z_compress=no 58346 fi 58347 rm -f core conftest.err conftest.$ac_objext \ 58348 conftest$ac_exeext conftest.$ac_ext 58349 LIBS=$ac_check_lib_save_LIBS 58350 fi 58351 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_z_compress" >&5 58352 $as_echo "$ac_cv_lib_z_compress" >&6; } 58353 if test "x$ac_cv_lib_z_compress" = xyes; then : 58354 ZLIB_FOUND=yes 58355 else 58356 ZLIB_FOUND=no 58357 fi 58358 58359 58360 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which zlib to use" >&5 58361 $as_echo_n "checking for which zlib to use... " >&6; } 58362 58363 DEFAULT_ZLIB=bundled 58364 if test "x$OPENJDK_TARGET_OS" = xmacosx; then 58365 # On macosx default is system...on others default is bundled 58366 DEFAULT_ZLIB=system 58367 fi 58368 58369 if test "x${ZLIB_FOUND}" != "xyes"; then 58370 # If we don't find any system...set default to bundled 58371 DEFAULT_ZLIB=bundled 58372 fi 58373 58374 # If user didn't specify, use DEFAULT_ZLIB 58375 if test "x${with_zlib}" = "x"; then 58376 with_zlib=${DEFAULT_ZLIB} 58377 fi 58378 58379 if test "x${with_zlib}" = "xbundled"; then 58380 USE_EXTERNAL_LIBZ=false 58381 { $as_echo "$as_me:${as_lineno-$LINENO}: result: bundled" >&5 58382 $as_echo "bundled" >&6; } 58383 elif test "x${with_zlib}" = "xsystem"; then 58384 if test "x${ZLIB_FOUND}" = "xyes"; then 58385 USE_EXTERNAL_LIBZ=true 58386 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system" >&5 58387 $as_echo "system" >&6; } 58388 else 58389 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system not found" >&5 58390 $as_echo "system not found" >&6; } 58391 as_fn_error $? "--with-zlib=system specified, but no zlib found!" "$LINENO" 5 58392 fi 58393 else 58394 as_fn_error $? "Invalid value for --with-zlib: ${with_zlib}, use 'system' or 'bundled'" "$LINENO" 5 58395 fi 58396 58397 58398 58399 58400 58401 # Check whether --with-lcms was given. 58402 if test "${with_lcms+set}" = set; then : 58403 withval=$with_lcms; 58404 fi 58405 58406 58407 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for which lcms to use" >&5 58408 $as_echo_n "checking for which lcms to use... " >&6; } 58409 58410 DEFAULT_LCMS=bundled 58411 # If user didn't specify, use DEFAULT_LCMS 58412 if test "x${with_lcms}" = "x"; then 58413 with_lcms=${DEFAULT_LCMS} 58414 fi 58415 58416 if test "x${with_lcms}" = "xbundled"; then 58417 USE_EXTERNAL_LCMS=false 58418 { $as_echo "$as_me:${as_lineno-$LINENO}: result: bundled" >&5 58419 $as_echo "bundled" >&6; } 58420 elif test "x${with_lcms}" = "xsystem"; then 58421 { $as_echo "$as_me:${as_lineno-$LINENO}: result: system" >&5 58422 $as_echo "system" >&6; } 58423 58424 pkg_failed=no 58425 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for LCMS" >&5 58426 $as_echo_n "checking for LCMS... " >&6; } 58427 58428 if test -n "$LCMS_CFLAGS"; then 58429 pkg_cv_LCMS_CFLAGS="$LCMS_CFLAGS" 58430 elif test -n "$PKG_CONFIG"; then 58431 if test -n "$PKG_CONFIG" && \ 58432 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lcms2\""; } >&5 58433 ($PKG_CONFIG --exists --print-errors "lcms2") 2>&5 58434 ac_status=$? 58435 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 58436 test $ac_status = 0; }; then 58437 pkg_cv_LCMS_CFLAGS=`$PKG_CONFIG --cflags "lcms2" 2>/dev/null` 58438 else 58439 pkg_failed=yes 58440 fi 58441 else 58442 pkg_failed=untried 58443 fi 58444 if test -n "$LCMS_LIBS"; then 58445 pkg_cv_LCMS_LIBS="$LCMS_LIBS" 58446 elif test -n "$PKG_CONFIG"; then 58447 if test -n "$PKG_CONFIG" && \ 58448 { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"lcms2\""; } >&5 58449 ($PKG_CONFIG --exists --print-errors "lcms2") 2>&5 58450 ac_status=$? 58451 $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5 58452 test $ac_status = 0; }; then 58453 pkg_cv_LCMS_LIBS=`$PKG_CONFIG --libs "lcms2" 2>/dev/null` 58454 else 58455 pkg_failed=yes 58456 fi 58457 else 58458 pkg_failed=untried 58459 fi 58460 58461 58462 58463 if test $pkg_failed = yes; then 58464 58465 if $PKG_CONFIG --atleast-pkgconfig-version 0.20; then 58466 _pkg_short_errors_supported=yes 58467 else 58468 _pkg_short_errors_supported=no 58469 fi 58470 if test $_pkg_short_errors_supported = yes; then 58471 LCMS_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "lcms2" 2>&1` 58472 else 58473 LCMS_PKG_ERRORS=`$PKG_CONFIG --print-errors "lcms2" 2>&1` 58474 fi 58475 # Put the nasty error message in config.log where it belongs 58476 echo "$LCMS_PKG_ERRORS" >&5 58477 58478 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 58479 $as_echo "no" >&6; } 58480 LCMS_FOUND=no 58481 elif test $pkg_failed = untried; then 58482 LCMS_FOUND=no 58483 else 58484 LCMS_CFLAGS=$pkg_cv_LCMS_CFLAGS 58485 LCMS_LIBS=$pkg_cv_LCMS_LIBS 58486 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 58487 $as_echo "yes" >&6; } 58488 LCMS_FOUND=yes 58489 fi 58490 if test "x${LCMS_FOUND}" = "xyes"; then 58491 USE_EXTERNAL_LCMS=true 58492 else 58493 as_fn_error $? "--with-lcms=system specified, but no lcms found!" "$LINENO" 5 58494 fi 58495 else 58496 as_fn_error $? "Invalid value for --with-lcms: ${with_lcms}, use 'system' or 'bundled'" "$LINENO" 5 58497 fi 58498 58499 58500 58501 58502 58503 58504 58505 58506 58507 58508 58509 # Setup libm (the maths library) 58510 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cos in -lm" >&5 58511 $as_echo_n "checking for cos in -lm... " >&6; } 58512 if ${ac_cv_lib_m_cos+:} false; then : 58513 $as_echo_n "(cached) " >&6 58514 else 58515 ac_check_lib_save_LIBS=$LIBS 58516 LIBS="-lm $LIBS" 58517 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 58518 /* end confdefs.h. */ 58519 58520 /* Override any GCC internal prototype to avoid an error. 58521 Use char because int might match the return type of a GCC 58522 builtin and then its argument prototype would still apply. */ 58523 #ifdef __cplusplus 58524 extern "C" 58525 #endif 58526 char cos (); 58527 int 58528 main () 58529 { 58530 return cos (); 58531 ; 58532 return 0; 58533 } 58534 _ACEOF 58535 if ac_fn_cxx_try_link "$LINENO"; then : 58536 ac_cv_lib_m_cos=yes 58537 else 58538 ac_cv_lib_m_cos=no 58539 fi 58540 rm -f core conftest.err conftest.$ac_objext \ 58541 conftest$ac_exeext conftest.$ac_ext 58542 LIBS=$ac_check_lib_save_LIBS 58543 fi 58544 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_m_cos" >&5 58545 $as_echo "$ac_cv_lib_m_cos" >&6; } 58546 if test "x$ac_cv_lib_m_cos" = xyes; then : 58547 cat >>confdefs.h <<_ACEOF 58548 #define HAVE_LIBM 1 58549 _ACEOF 58550 58551 LIBS="-lm $LIBS" 58552 58553 else 58554 58555 { $as_echo "$as_me:${as_lineno-$LINENO}: Maths library was not found" >&5 58556 $as_echo "$as_me: Maths library was not found" >&6;} 58557 58558 fi 58559 58560 LIBM=-lm 58561 58562 58563 # Setup libdl (for dynamic library loading) 58564 save_LIBS="$LIBS" 58565 LIBS="" 58566 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for dlopen in -ldl" >&5 58567 $as_echo_n "checking for dlopen in -ldl... " >&6; } 58568 if ${ac_cv_lib_dl_dlopen+:} false; then : 58569 $as_echo_n "(cached) " >&6 58570 else 58571 ac_check_lib_save_LIBS=$LIBS 58572 LIBS="-ldl $LIBS" 58573 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 58574 /* end confdefs.h. */ 58575 58576 /* Override any GCC internal prototype to avoid an error. 58577 Use char because int might match the return type of a GCC 58578 builtin and then its argument prototype would still apply. */ 58579 #ifdef __cplusplus 58580 extern "C" 58581 #endif 58582 char dlopen (); 58583 int 58584 main () 58585 { 58586 return dlopen (); 58587 ; 58588 return 0; 58589 } 58590 _ACEOF 58591 if ac_fn_cxx_try_link "$LINENO"; then : 58592 ac_cv_lib_dl_dlopen=yes 58593 else 58594 ac_cv_lib_dl_dlopen=no 58595 fi 58596 rm -f core conftest.err conftest.$ac_objext \ 58597 conftest$ac_exeext conftest.$ac_ext 58598 LIBS=$ac_check_lib_save_LIBS 58599 fi 58600 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_cv_lib_dl_dlopen" >&5 58601 $as_echo "$ac_cv_lib_dl_dlopen" >&6; } 58602 if test "x$ac_cv_lib_dl_dlopen" = xyes; then : 58603 cat >>confdefs.h <<_ACEOF 58604 #define HAVE_LIBDL 1 58605 _ACEOF 58606 58607 LIBS="-ldl $LIBS" 58608 58609 fi 58610 58611 LIBDL="$LIBS" 58612 58613 LIBS="$save_LIBS" 58614 58615 # Deprecated libraries, keep the flags for backwards compatibility 58616 if test "x$OPENJDK_TARGET_OS" = "xwindows"; then 58617 58618 58619 # Check whether --with-dxsdk was given. 58620 if test "${with_dxsdk+set}" = set; then : 58621 withval=$with_dxsdk; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk is deprecated and will be ignored." >&5 58622 $as_echo "$as_me: WARNING: Option --with-dxsdk is deprecated and will be ignored." >&2;} 58623 fi 58624 58625 58626 58627 58628 # Check whether --with-dxsdk-lib was given. 58629 if test "${with_dxsdk_lib+set}" = set; then : 58630 withval=$with_dxsdk_lib; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk-lib is deprecated and will be ignored." >&5 58631 $as_echo "$as_me: WARNING: Option --with-dxsdk-lib is deprecated and will be ignored." >&2;} 58632 fi 58633 58634 58635 58636 58637 # Check whether --with-dxsdk-include was given. 58638 if test "${with_dxsdk_include+set}" = set; then : 58639 withval=$with_dxsdk_include; { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Option --with-dxsdk-include is deprecated and will be ignored." >&5 58640 $as_echo "$as_me: WARNING: Option --with-dxsdk-include is deprecated and will be ignored." >&2;} 58641 fi 58642 58643 58644 fi 58645 58646 # Control if libzip can use mmap. Available for purposes of overriding. 58647 LIBZIP_CAN_USE_MMAP=true 58648 58649 58650 58651 58652 58653 58654 58655 58656 58657 58658 58659 58660 58661 58662 ############################################################################### 58663 # 58664 # We need to do some final tweaking, when everything else is done. 58665 # 58666 ############################################################################### 58667 58668 58669 HOTSPOT_MAKE_ARGS="$HOTSPOT_TARGET" 58670 58671 58672 58673 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if elliptic curve crypto implementation is present" >&5 58674 $as_echo_n "checking if elliptic curve crypto implementation is present... " >&6; } 58675 58676 if test -d "${SRC_ROOT}/jdk/src/jdk.crypto.ec/share/native/libsunec/impl"; then 58677 ENABLE_INTREE_EC=yes 58678 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 58679 $as_echo "yes" >&6; } 58680 else 58681 ENABLE_INTREE_EC=no 58682 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 58683 $as_echo "no" >&6; } 58684 fi 58685 58686 58687 58688 58689 ############################################################################### 58690 # 58691 # Configure parts of the build that only affect the build performance, 58692 # not the result. 58693 # 58694 ############################################################################### 58695 58696 58697 # How many cores do we have on this build system? 58698 58699 # Check whether --with-num-cores was given. 58700 if test "${with_num_cores+set}" = set; then : 58701 withval=$with_num_cores; 58702 fi 58703 58704 if test "x$with_num_cores" = x; then 58705 # The number of cores were not specified, try to probe them. 58706 58707 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for number of cores" >&5 58708 $as_echo_n "checking for number of cores... " >&6; } 58709 NUM_CORES=1 58710 FOUND_CORES=no 58711 58712 if test -f /proc/cpuinfo; then 58713 # Looks like a Linux (or cygwin) system 58714 NUM_CORES=`cat /proc/cpuinfo | grep -c processor` 58715 FOUND_CORES=yes 58716 elif test -x /usr/sbin/psrinfo; then 58717 # Looks like a Solaris system 58718 NUM_CORES=`LC_MESSAGES=C /usr/sbin/psrinfo -v | grep -c on-line` 58719 FOUND_CORES=yes 58720 elif test -x /usr/sbin/system_profiler; then 58721 # Looks like a MacOSX system 58722 NUM_CORES=`/usr/sbin/system_profiler -detailLevel full SPHardwareDataType | grep 'Cores' | awk '{print $5}'` 58723 FOUND_CORES=yes 58724 elif test "x$OPENJDK_BUILD_OS" = xaix ; then 58725 NUM_CORES=`/usr/sbin/prtconf | grep "^Number Of Processors" | awk '{ print $4 }'` 58726 FOUND_CORES=yes 58727 elif test -n "$NUMBER_OF_PROCESSORS"; then 58728 # On windows, look in the env 58729 NUM_CORES=$NUMBER_OF_PROCESSORS 58730 FOUND_CORES=yes 58731 fi 58732 58733 if test "x$FOUND_CORES" = xyes; then 58734 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $NUM_CORES" >&5 58735 $as_echo "$NUM_CORES" >&6; } 58736 else 58737 { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not detect number of cores, defaulting to 1" >&5 58738 $as_echo "could not detect number of cores, defaulting to 1" >&6; } 58739 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This will disable all parallelism from build!" >&5 58740 $as_echo "$as_me: WARNING: This will disable all parallelism from build!" >&2;} 58741 fi 58742 58743 else 58744 NUM_CORES=$with_num_cores 58745 fi 58746 58747 58748 58749 # How much memory do we have on this build system? 58750 58751 # Check whether --with-memory-size was given. 58752 if test "${with_memory_size+set}" = set; then : 58753 withval=$with_memory_size; 58754 fi 58755 58756 if test "x$with_memory_size" = x; then 58757 # The memory size was not specified, try to probe it. 58758 58759 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for memory size" >&5 58760 $as_echo_n "checking for memory size... " >&6; } 58761 # Default to 1024 MB 58762 MEMORY_SIZE=1024 58763 FOUND_MEM=no 58764 58765 if test -f /proc/meminfo; then 58766 # Looks like a Linux (or cygwin) system 58767 MEMORY_SIZE=`cat /proc/meminfo | grep MemTotal | awk '{print $2}'` 58768 MEMORY_SIZE=`expr $MEMORY_SIZE / 1024` 58769 FOUND_MEM=yes 58770 elif test -x /usr/sbin/prtconf; then 58771 # Looks like a Solaris or AIX system 58772 MEMORY_SIZE=`/usr/sbin/prtconf | grep "^Memory [Ss]ize" | awk '{ print $3 }'` 58773 FOUND_MEM=yes 58774 elif test -x /usr/sbin/system_profiler; then 58775 # Looks like a MacOSX system 58776 MEMORY_SIZE=`/usr/sbin/system_profiler -detailLevel full SPHardwareDataType | grep 'Memory' | awk '{print $2}'` 58777 MEMORY_SIZE=`expr $MEMORY_SIZE \* 1024` 58778 FOUND_MEM=yes 58779 elif test "x$OPENJDK_BUILD_OS" = xwindows; then 58780 # Windows, but without cygwin 58781 MEMORY_SIZE=`wmic computersystem get totalphysicalmemory -value | grep = | cut -d "=" -f 2-` 58782 MEMORY_SIZE=`expr $MEMORY_SIZE / 1024 / 1024` 58783 FOUND_MEM=yes 58784 fi 58785 58786 if test "x$FOUND_MEM" = xyes; then 58787 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $MEMORY_SIZE MB" >&5 58788 $as_echo "$MEMORY_SIZE MB" >&6; } 58789 else 58790 { $as_echo "$as_me:${as_lineno-$LINENO}: result: could not detect memory size, defaulting to $MEMORY_SIZE MB" >&5 58791 $as_echo "could not detect memory size, defaulting to $MEMORY_SIZE MB" >&6; } 58792 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: This might seriously impact build performance!" >&5 58793 $as_echo "$as_me: WARNING: This might seriously impact build performance!" >&2;} 58794 fi 58795 58796 else 58797 MEMORY_SIZE=$with_memory_size 58798 fi 58799 58800 58801 58802 # Provide a decent default number of parallel jobs for make depending on 58803 # number of cores, amount of memory and machine architecture. 58804 58805 # Check whether --with-jobs was given. 58806 if test "${with_jobs+set}" = set; then : 58807 withval=$with_jobs; 58808 fi 58809 58810 if test "x$with_jobs" = x; then 58811 # Number of jobs was not specified, calculate. 58812 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for appropriate number of jobs to run in parallel" >&5 58813 $as_echo_n "checking for appropriate number of jobs to run in parallel... " >&6; } 58814 # Approximate memory in GB. 58815 memory_gb=`expr $MEMORY_SIZE / 1024` 58816 # Pick the lowest of memory in gb and number of cores. 58817 if test "$memory_gb" -lt "$NUM_CORES"; then 58818 JOBS="$memory_gb" 58819 else 58820 JOBS="$NUM_CORES" 58821 fi 58822 if test "$JOBS" -eq "0"; then 58823 JOBS=1 58824 fi 58825 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $JOBS" >&5 58826 $as_echo "$JOBS" >&6; } 58827 else 58828 JOBS=$with_jobs 58829 fi 58830 58831 58832 58833 # The number of test jobs will be chosen automatically if TEST_JOBS is 0 58834 58835 # Check whether --with-test-jobs was given. 58836 if test "${with_test_jobs+set}" = set; then : 58837 withval=$with_test_jobs; 58838 fi 58839 58840 if test "x$with_test_jobs" = x; then 58841 TEST_JOBS=0 58842 else 58843 TEST_JOBS=$with_test_jobs 58844 fi 58845 58846 58847 58848 # Setup arguments for the boot jdk (after cores and memory have been setup) 58849 58850 ############################################################################## 58851 # 58852 # Specify jvm options for anything that is run with the Boot JDK. 58853 # Not all JVM:s accept the same arguments on the command line. 58854 # 58855 58856 # Check whether --with-boot-jdk-jvmargs was given. 58857 if test "${with_boot_jdk_jvmargs+set}" = set; then : 58858 withval=$with_boot_jdk_jvmargs; 58859 fi 58860 58861 58862 { $as_echo "$as_me:${as_lineno-$LINENO}: checking flags for boot jdk java command " >&5 58863 $as_echo_n "checking flags for boot jdk java command ... " >&6; } 58864 58865 # Disable special log output when a debug build is used as Boot JDK... 58866 58867 $ECHO "Check if jvm arg is ok: -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput" >&5 58868 $ECHO "Command: $JAVA -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput -version" >&5 58869 OUTPUT=`$JAVA -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput -version 2>&1` 58870 FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn` 58871 FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""` 58872 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 58873 boot_jdk_jvmargs="$boot_jdk_jvmargs -XX:-PrintVMOptions -XX:-UnlockDiagnosticVMOptions -XX:-LogVMOutput" 58874 JVM_ARG_OK=true 58875 else 58876 $ECHO "Arg failed:" >&5 58877 $ECHO "$OUTPUT" >&5 58878 JVM_ARG_OK=false 58879 fi 58880 58881 58882 # Apply user provided options. 58883 58884 $ECHO "Check if jvm arg is ok: $with_boot_jdk_jvmargs" >&5 58885 $ECHO "Command: $JAVA $with_boot_jdk_jvmargs -version" >&5 58886 OUTPUT=`$JAVA $with_boot_jdk_jvmargs -version 2>&1` 58887 FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn` 58888 FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""` 58889 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 58890 boot_jdk_jvmargs="$boot_jdk_jvmargs $with_boot_jdk_jvmargs" 58891 JVM_ARG_OK=true 58892 else 58893 $ECHO "Arg failed:" >&5 58894 $ECHO "$OUTPUT" >&5 58895 JVM_ARG_OK=false 58896 fi 58897 58898 58899 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $boot_jdk_jvmargs" >&5 58900 $as_echo "$boot_jdk_jvmargs" >&6; } 58901 58902 # For now, general JAVA_FLAGS are the same as the boot jdk jvmargs 58903 JAVA_FLAGS=$boot_jdk_jvmargs 58904 58905 58906 58907 { $as_echo "$as_me:${as_lineno-$LINENO}: checking flags for boot jdk java command for big workloads" >&5 58908 $as_echo_n "checking flags for boot jdk java command for big workloads... " >&6; } 58909 58910 # Starting amount of heap memory. 58911 58912 $ECHO "Check if jvm arg is ok: -Xms64M" >&5 58913 $ECHO "Command: $JAVA -Xms64M -version" >&5 58914 OUTPUT=`$JAVA -Xms64M -version 2>&1` 58915 FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn` 58916 FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""` 58917 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 58918 boot_jdk_jvmargs_big="$boot_jdk_jvmargs_big -Xms64M" 58919 JVM_ARG_OK=true 58920 else 58921 $ECHO "Arg failed:" >&5 58922 $ECHO "$OUTPUT" >&5 58923 JVM_ARG_OK=false 58924 fi 58925 58926 58927 # Maximum amount of heap memory. 58928 # Maximum stack size. 58929 JVM_MAX_HEAP=`expr $MEMORY_SIZE / 2` 58930 if test "x$BOOT_JDK_BITS" = "x32"; then 58931 if test "$JVM_MAX_HEAP" -gt "1100"; then 58932 JVM_MAX_HEAP=1100 58933 elif test "$JVM_MAX_HEAP" -lt "512"; then 58934 JVM_MAX_HEAP=512 58935 fi 58936 STACK_SIZE=768 58937 else 58938 # Running a 64 bit JVM allows for and requires a bigger heap 58939 if test "$JVM_MAX_HEAP" -gt "1600"; then 58940 JVM_MAX_HEAP=1600 58941 elif test "$JVM_MAX_HEAP" -lt "512"; then 58942 JVM_MAX_HEAP=512 58943 fi 58944 STACK_SIZE=1536 58945 fi 58946 58947 $ECHO "Check if jvm arg is ok: -Xmx${JVM_MAX_HEAP}M" >&5 58948 $ECHO "Command: $JAVA -Xmx${JVM_MAX_HEAP}M -version" >&5 58949 OUTPUT=`$JAVA -Xmx${JVM_MAX_HEAP}M -version 2>&1` 58950 FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn` 58951 FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""` 58952 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 58953 boot_jdk_jvmargs_big="$boot_jdk_jvmargs_big -Xmx${JVM_MAX_HEAP}M" 58954 JVM_ARG_OK=true 58955 else 58956 $ECHO "Arg failed:" >&5 58957 $ECHO "$OUTPUT" >&5 58958 JVM_ARG_OK=false 58959 fi 58960 58961 58962 $ECHO "Check if jvm arg is ok: -XX:ThreadStackSize=$STACK_SIZE" >&5 58963 $ECHO "Command: $JAVA -XX:ThreadStackSize=$STACK_SIZE -version" >&5 58964 OUTPUT=`$JAVA -XX:ThreadStackSize=$STACK_SIZE -version 2>&1` 58965 FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn` 58966 FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""` 58967 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 58968 boot_jdk_jvmargs_big="$boot_jdk_jvmargs_big -XX:ThreadStackSize=$STACK_SIZE" 58969 JVM_ARG_OK=true 58970 else 58971 $ECHO "Arg failed:" >&5 58972 $ECHO "$OUTPUT" >&5 58973 JVM_ARG_OK=false 58974 fi 58975 58976 58977 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $boot_jdk_jvmargs_big" >&5 58978 $as_echo "$boot_jdk_jvmargs_big" >&6; } 58979 58980 JAVA_FLAGS_BIG=$boot_jdk_jvmargs_big 58981 58982 58983 # By default, the main javac compilations use big 58984 JAVA_FLAGS_JAVAC="$JAVA_FLAGS_BIG" 58985 58986 58987 { $as_echo "$as_me:${as_lineno-$LINENO}: checking flags for boot jdk java command for small workloads" >&5 58988 $as_echo_n "checking flags for boot jdk java command for small workloads... " >&6; } 58989 58990 # Use serial gc for small short lived tools if possible 58991 58992 $ECHO "Check if jvm arg is ok: -XX:+UseSerialGC" >&5 58993 $ECHO "Command: $JAVA -XX:+UseSerialGC -version" >&5 58994 OUTPUT=`$JAVA -XX:+UseSerialGC -version 2>&1` 58995 FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn` 58996 FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""` 58997 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 58998 boot_jdk_jvmargs_small="$boot_jdk_jvmargs_small -XX:+UseSerialGC" 58999 JVM_ARG_OK=true 59000 else 59001 $ECHO "Arg failed:" >&5 59002 $ECHO "$OUTPUT" >&5 59003 JVM_ARG_OK=false 59004 fi 59005 59006 59007 $ECHO "Check if jvm arg is ok: -Xms32M" >&5 59008 $ECHO "Command: $JAVA -Xms32M -version" >&5 59009 OUTPUT=`$JAVA -Xms32M -version 2>&1` 59010 FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn` 59011 FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""` 59012 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 59013 boot_jdk_jvmargs_small="$boot_jdk_jvmargs_small -Xms32M" 59014 JVM_ARG_OK=true 59015 else 59016 $ECHO "Arg failed:" >&5 59017 $ECHO "$OUTPUT" >&5 59018 JVM_ARG_OK=false 59019 fi 59020 59021 59022 $ECHO "Check if jvm arg is ok: -Xmx512M" >&5 59023 $ECHO "Command: $JAVA -Xmx512M -version" >&5 59024 OUTPUT=`$JAVA -Xmx512M -version 2>&1` 59025 FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn` 59026 FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""` 59027 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 59028 boot_jdk_jvmargs_small="$boot_jdk_jvmargs_small -Xmx512M" 59029 JVM_ARG_OK=true 59030 else 59031 $ECHO "Arg failed:" >&5 59032 $ECHO "$OUTPUT" >&5 59033 JVM_ARG_OK=false 59034 fi 59035 59036 59037 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $boot_jdk_jvmargs_small" >&5 59038 $as_echo "$boot_jdk_jvmargs_small" >&6; } 59039 59040 JAVA_FLAGS_SMALL=$boot_jdk_jvmargs_small 59041 59042 59043 JAVA_TOOL_FLAGS_SMALL="" 59044 for f in $JAVA_FLAGS_SMALL; do 59045 JAVA_TOOL_FLAGS_SMALL="$JAVA_TOOL_FLAGS_SMALL -J$f" 59046 done 59047 59048 59049 59050 # Setup smart javac (after cores and memory have been setup) 59051 59052 59053 # Check whether --with-sjavac-server-java was given. 59054 if test "${with_sjavac_server_java+set}" = set; then : 59055 withval=$with_sjavac_server_java; 59056 fi 59057 59058 59059 if test "x$with_sjavac_server_java" != x; then 59060 SJAVAC_SERVER_JAVA="$with_sjavac_server_java" 59061 FOUND_VERSION=`$SJAVAC_SERVER_JAVA -version 2>&1 | grep " version \""` 59062 if test "x$FOUND_VERSION" = x; then 59063 as_fn_error $? "Could not execute server java: $SJAVAC_SERVER_JAVA" "$LINENO" 5 59064 fi 59065 else 59066 SJAVAC_SERVER_JAVA="$JAVA" 59067 fi 59068 59069 59070 if test "$MEMORY_SIZE" -gt "3000"; then 59071 59072 $ECHO "Check if jvm arg is ok: -d64" >&5 59073 $ECHO "Command: $SJAVAC_SERVER_JAVA -d64 -version" >&5 59074 OUTPUT=`$SJAVAC_SERVER_JAVA -d64 -version 2>&1` 59075 FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn` 59076 FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""` 59077 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 59078 SJAVAC_SERVER_JAVA_FLAGS="$SJAVAC_SERVER_JAVA_FLAGS -d64" 59079 JVM_ARG_OK=true 59080 else 59081 $ECHO "Arg failed:" >&5 59082 $ECHO "$OUTPUT" >&5 59083 JVM_ARG_OK=false 59084 fi 59085 59086 if test "$JVM_ARG_OK" = true; then 59087 JVM_64BIT=true 59088 JVM_ARG_OK=false 59089 fi 59090 fi 59091 59092 MX_VALUE=`expr $MEMORY_SIZE / 2` 59093 if test "$JVM_64BIT" = true; then 59094 # Set ms lower than mx since more than one instance of the server might 59095 # get launched at the same time before they figure out which instance won. 59096 MS_VALUE=512 59097 if test "$MX_VALUE" -gt "2048"; then 59098 MX_VALUE=2048 59099 fi 59100 else 59101 MS_VALUE=256 59102 if test "$MX_VALUE" -gt "1500"; then 59103 MX_VALUE=1500 59104 fi 59105 fi 59106 if test "$MX_VALUE" -lt "512"; then 59107 MX_VALUE=512 59108 fi 59109 59110 $ECHO "Check if jvm arg is ok: -Xms${MS_VALUE}M -Xmx${MX_VALUE}M" >&5 59111 $ECHO "Command: $SJAVAC_SERVER_JAVA -Xms${MS_VALUE}M -Xmx${MX_VALUE}M -version" >&5 59112 OUTPUT=`$SJAVAC_SERVER_JAVA -Xms${MS_VALUE}M -Xmx${MX_VALUE}M -version 2>&1` 59113 FOUND_WARN=`$ECHO "$OUTPUT" | grep -i warn` 59114 FOUND_VERSION=`$ECHO $OUTPUT | grep " version \""` 59115 if test "x$FOUND_VERSION" != x && test "x$FOUND_WARN" = x; then 59116 SJAVAC_SERVER_JAVA_FLAGS="$SJAVAC_SERVER_JAVA_FLAGS -Xms${MS_VALUE}M -Xmx${MX_VALUE}M" 59117 JVM_ARG_OK=true 59118 else 59119 $ECHO "Arg failed:" >&5 59120 $ECHO "$OUTPUT" >&5 59121 JVM_ARG_OK=false 59122 fi 59123 59124 59125 59126 # Check whether --enable-sjavac was given. 59127 if test "${enable_sjavac+set}" = set; then : 59128 enableval=$enable_sjavac; ENABLE_SJAVAC="${enableval}" 59129 else 59130 ENABLE_SJAVAC="no" 59131 fi 59132 59133 if test "x$JVM_ARG_OK" = "xfalse"; then 59134 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Could not set -Xms${MS_VALUE}M -Xmx${MX_VALUE}M, disabling sjavac" >&5 59135 $as_echo "$as_me: WARNING: Could not set -Xms${MS_VALUE}M -Xmx${MX_VALUE}M, disabling sjavac" >&2;} 59136 ENABLE_SJAVAC="no" 59137 fi 59138 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use sjavac" >&5 59139 $as_echo_n "checking whether to use sjavac... " >&6; } 59140 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ENABLE_SJAVAC" >&5 59141 $as_echo "$ENABLE_SJAVAC" >&6; } 59142 59143 59144 # Check whether --enable-javac-server was given. 59145 if test "${enable_javac_server+set}" = set; then : 59146 enableval=$enable_javac_server; ENABLE_JAVAC_SERVER="${enableval}" 59147 else 59148 ENABLE_JAVAC_SERVER="yes" 59149 fi 59150 59151 if test "x$JVM_ARG_OK" = "xfalse"; then 59152 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Could not set -Xms${MS_VALUE}M -Xmx${MX_VALUE}M, disabling javac server" >&5 59153 $as_echo "$as_me: WARNING: Could not set -Xms${MS_VALUE}M -Xmx${MX_VALUE}M, disabling javac server" >&2;} 59154 ENABLE_JAVAC_SERVER="no" 59155 fi 59156 { $as_echo "$as_me:${as_lineno-$LINENO}: checking whether to use javac server" >&5 59157 $as_echo_n "checking whether to use javac server... " >&6; } 59158 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ENABLE_JAVAC_SERVER" >&5 59159 $as_echo "$ENABLE_JAVAC_SERVER" >&6; } 59160 59161 59162 if test "x$ENABLE_JAVAC_SERVER" = "xyes" || "x$ENABLE_SJAVAC" = "xyes"; then 59163 # When using a server javac, the small client instances do not need much 59164 # resources. 59165 JAVA_FLAGS_JAVAC="$JAVA_FLAGS_SMALL" 59166 fi 59167 59168 59169 # Setup use of icecc if requested 59170 59171 # Check whether --enable-icecc was given. 59172 if test "${enable_icecc+set}" = set; then : 59173 enableval=$enable_icecc; 59174 fi 59175 59176 59177 if test "x${enable_icecc}" = "xyes"; then 59178 59179 59180 59181 # Publish this variable in the help. 59182 59183 59184 if [ -z "${ICECC_CMD+x}" ]; then 59185 # The variable is not set by user, try to locate tool using the code snippet 59186 for ac_prog in icecc 59187 do 59188 # Extract the first word of "$ac_prog", so it can be a program name with args. 59189 set dummy $ac_prog; ac_word=$2 59190 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 59191 $as_echo_n "checking for $ac_word... " >&6; } 59192 if ${ac_cv_path_ICECC_CMD+:} false; then : 59193 $as_echo_n "(cached) " >&6 59194 else 59195 case $ICECC_CMD in 59196 [\\/]* | ?:[\\/]*) 59197 ac_cv_path_ICECC_CMD="$ICECC_CMD" # Let the user override the test with a path. 59198 ;; 59199 *) 59200 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 59201 for as_dir in $PATH 59202 do 59203 IFS=$as_save_IFS 59204 test -z "$as_dir" && as_dir=. 59205 for ac_exec_ext in '' $ac_executable_extensions; do 59206 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 59207 ac_cv_path_ICECC_CMD="$as_dir/$ac_word$ac_exec_ext" 59208 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 59209 break 2 59210 fi 59211 done 59212 done 59213 IFS=$as_save_IFS 59214 59215 ;; 59216 esac 59217 fi 59218 ICECC_CMD=$ac_cv_path_ICECC_CMD 59219 if test -n "$ICECC_CMD"; then 59220 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CMD" >&5 59221 $as_echo "$ICECC_CMD" >&6; } 59222 else 59223 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 59224 $as_echo "no" >&6; } 59225 fi 59226 59227 59228 test -n "$ICECC_CMD" && break 59229 done 59230 59231 else 59232 # The variable is set, but is it from the command line or the environment? 59233 59234 # Try to remove the string !ICECC_CMD! from our list. 59235 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ICECC_CMD!/} 59236 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 59237 # If it failed, the variable was not from the command line. Ignore it, 59238 # but warn the user (except for BASH, which is always set by the calling BASH). 59239 if test "xICECC_CMD" != xBASH; then 59240 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ICECC_CMD from the environment. Use command line variables instead." >&5 59241 $as_echo "$as_me: WARNING: Ignoring value of ICECC_CMD from the environment. Use command line variables instead." >&2;} 59242 fi 59243 # Try to locate tool using the code snippet 59244 for ac_prog in icecc 59245 do 59246 # Extract the first word of "$ac_prog", so it can be a program name with args. 59247 set dummy $ac_prog; ac_word=$2 59248 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 59249 $as_echo_n "checking for $ac_word... " >&6; } 59250 if ${ac_cv_path_ICECC_CMD+:} false; then : 59251 $as_echo_n "(cached) " >&6 59252 else 59253 case $ICECC_CMD in 59254 [\\/]* | ?:[\\/]*) 59255 ac_cv_path_ICECC_CMD="$ICECC_CMD" # Let the user override the test with a path. 59256 ;; 59257 *) 59258 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 59259 for as_dir in $PATH 59260 do 59261 IFS=$as_save_IFS 59262 test -z "$as_dir" && as_dir=. 59263 for ac_exec_ext in '' $ac_executable_extensions; do 59264 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 59265 ac_cv_path_ICECC_CMD="$as_dir/$ac_word$ac_exec_ext" 59266 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 59267 break 2 59268 fi 59269 done 59270 done 59271 IFS=$as_save_IFS 59272 59273 ;; 59274 esac 59275 fi 59276 ICECC_CMD=$ac_cv_path_ICECC_CMD 59277 if test -n "$ICECC_CMD"; then 59278 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CMD" >&5 59279 $as_echo "$ICECC_CMD" >&6; } 59280 else 59281 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 59282 $as_echo "no" >&6; } 59283 fi 59284 59285 59286 test -n "$ICECC_CMD" && break 59287 done 59288 59289 else 59290 # If it succeeded, then it was overridden by the user. We will use it 59291 # for the tool. 59292 59293 # First remove it from the list of overridden variables, so we can test 59294 # for unknown variables in the end. 59295 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 59296 59297 # Check if we try to supply an empty value 59298 if test "x$ICECC_CMD" = x; then 59299 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ICECC_CMD= (no value)" >&5 59300 $as_echo "$as_me: Setting user supplied tool ICECC_CMD= (no value)" >&6;} 59301 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_CMD" >&5 59302 $as_echo_n "checking for ICECC_CMD... " >&6; } 59303 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 59304 $as_echo "disabled" >&6; } 59305 else 59306 # Check if the provided tool contains a complete path. 59307 tool_specified="$ICECC_CMD" 59308 tool_basename="${tool_specified##*/}" 59309 if test "x$tool_basename" = "x$tool_specified"; then 59310 # A command without a complete path is provided, search $PATH. 59311 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ICECC_CMD=$tool_basename" >&5 59312 $as_echo "$as_me: Will search for user supplied tool ICECC_CMD=$tool_basename" >&6;} 59313 # Extract the first word of "$tool_basename", so it can be a program name with args. 59314 set dummy $tool_basename; ac_word=$2 59315 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 59316 $as_echo_n "checking for $ac_word... " >&6; } 59317 if ${ac_cv_path_ICECC_CMD+:} false; then : 59318 $as_echo_n "(cached) " >&6 59319 else 59320 case $ICECC_CMD in 59321 [\\/]* | ?:[\\/]*) 59322 ac_cv_path_ICECC_CMD="$ICECC_CMD" # Let the user override the test with a path. 59323 ;; 59324 *) 59325 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 59326 for as_dir in $PATH 59327 do 59328 IFS=$as_save_IFS 59329 test -z "$as_dir" && as_dir=. 59330 for ac_exec_ext in '' $ac_executable_extensions; do 59331 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 59332 ac_cv_path_ICECC_CMD="$as_dir/$ac_word$ac_exec_ext" 59333 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 59334 break 2 59335 fi 59336 done 59337 done 59338 IFS=$as_save_IFS 59339 59340 ;; 59341 esac 59342 fi 59343 ICECC_CMD=$ac_cv_path_ICECC_CMD 59344 if test -n "$ICECC_CMD"; then 59345 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CMD" >&5 59346 $as_echo "$ICECC_CMD" >&6; } 59347 else 59348 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 59349 $as_echo "no" >&6; } 59350 fi 59351 59352 59353 if test "x$ICECC_CMD" = x; then 59354 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 59355 fi 59356 else 59357 # Otherwise we believe it is a complete path. Use it as it is. 59358 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ICECC_CMD=$tool_specified" >&5 59359 $as_echo "$as_me: Will use user supplied tool ICECC_CMD=$tool_specified" >&6;} 59360 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_CMD" >&5 59361 $as_echo_n "checking for ICECC_CMD... " >&6; } 59362 if test ! -x "$tool_specified"; then 59363 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 59364 $as_echo "not found" >&6; } 59365 as_fn_error $? "User supplied tool ICECC_CMD=$tool_specified does not exist or is not executable" "$LINENO" 5 59366 fi 59367 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 59368 $as_echo "$tool_specified" >&6; } 59369 fi 59370 fi 59371 fi 59372 59373 fi 59374 59375 59376 59377 if test "x$ICECC_CMD" = x; then 59378 as_fn_error $? "Could not find required tool for ICECC_CMD" "$LINENO" 5 59379 fi 59380 59381 59382 old_path="$PATH" 59383 59384 # Look for icecc-create-env in some known places 59385 PATH="$PATH:/usr/lib/icecc:/usr/lib64/icecc" 59386 59387 59388 59389 # Publish this variable in the help. 59390 59391 59392 if [ -z "${ICECC_CREATE_ENV+x}" ]; then 59393 # The variable is not set by user, try to locate tool using the code snippet 59394 for ac_prog in icecc-create-env 59395 do 59396 # Extract the first word of "$ac_prog", so it can be a program name with args. 59397 set dummy $ac_prog; ac_word=$2 59398 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 59399 $as_echo_n "checking for $ac_word... " >&6; } 59400 if ${ac_cv_path_ICECC_CREATE_ENV+:} false; then : 59401 $as_echo_n "(cached) " >&6 59402 else 59403 case $ICECC_CREATE_ENV in 59404 [\\/]* | ?:[\\/]*) 59405 ac_cv_path_ICECC_CREATE_ENV="$ICECC_CREATE_ENV" # Let the user override the test with a path. 59406 ;; 59407 *) 59408 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 59409 for as_dir in $PATH 59410 do 59411 IFS=$as_save_IFS 59412 test -z "$as_dir" && as_dir=. 59413 for ac_exec_ext in '' $ac_executable_extensions; do 59414 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 59415 ac_cv_path_ICECC_CREATE_ENV="$as_dir/$ac_word$ac_exec_ext" 59416 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 59417 break 2 59418 fi 59419 done 59420 done 59421 IFS=$as_save_IFS 59422 59423 ;; 59424 esac 59425 fi 59426 ICECC_CREATE_ENV=$ac_cv_path_ICECC_CREATE_ENV 59427 if test -n "$ICECC_CREATE_ENV"; then 59428 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CREATE_ENV" >&5 59429 $as_echo "$ICECC_CREATE_ENV" >&6; } 59430 else 59431 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 59432 $as_echo "no" >&6; } 59433 fi 59434 59435 59436 test -n "$ICECC_CREATE_ENV" && break 59437 done 59438 59439 else 59440 # The variable is set, but is it from the command line or the environment? 59441 59442 # Try to remove the string !ICECC_CREATE_ENV! from our list. 59443 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ICECC_CREATE_ENV!/} 59444 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 59445 # If it failed, the variable was not from the command line. Ignore it, 59446 # but warn the user (except for BASH, which is always set by the calling BASH). 59447 if test "xICECC_CREATE_ENV" != xBASH; then 59448 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ICECC_CREATE_ENV from the environment. Use command line variables instead." >&5 59449 $as_echo "$as_me: WARNING: Ignoring value of ICECC_CREATE_ENV from the environment. Use command line variables instead." >&2;} 59450 fi 59451 # Try to locate tool using the code snippet 59452 for ac_prog in icecc-create-env 59453 do 59454 # Extract the first word of "$ac_prog", so it can be a program name with args. 59455 set dummy $ac_prog; ac_word=$2 59456 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 59457 $as_echo_n "checking for $ac_word... " >&6; } 59458 if ${ac_cv_path_ICECC_CREATE_ENV+:} false; then : 59459 $as_echo_n "(cached) " >&6 59460 else 59461 case $ICECC_CREATE_ENV in 59462 [\\/]* | ?:[\\/]*) 59463 ac_cv_path_ICECC_CREATE_ENV="$ICECC_CREATE_ENV" # Let the user override the test with a path. 59464 ;; 59465 *) 59466 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 59467 for as_dir in $PATH 59468 do 59469 IFS=$as_save_IFS 59470 test -z "$as_dir" && as_dir=. 59471 for ac_exec_ext in '' $ac_executable_extensions; do 59472 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 59473 ac_cv_path_ICECC_CREATE_ENV="$as_dir/$ac_word$ac_exec_ext" 59474 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 59475 break 2 59476 fi 59477 done 59478 done 59479 IFS=$as_save_IFS 59480 59481 ;; 59482 esac 59483 fi 59484 ICECC_CREATE_ENV=$ac_cv_path_ICECC_CREATE_ENV 59485 if test -n "$ICECC_CREATE_ENV"; then 59486 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CREATE_ENV" >&5 59487 $as_echo "$ICECC_CREATE_ENV" >&6; } 59488 else 59489 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 59490 $as_echo "no" >&6; } 59491 fi 59492 59493 59494 test -n "$ICECC_CREATE_ENV" && break 59495 done 59496 59497 else 59498 # If it succeeded, then it was overridden by the user. We will use it 59499 # for the tool. 59500 59501 # First remove it from the list of overridden variables, so we can test 59502 # for unknown variables in the end. 59503 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 59504 59505 # Check if we try to supply an empty value 59506 if test "x$ICECC_CREATE_ENV" = x; then 59507 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ICECC_CREATE_ENV= (no value)" >&5 59508 $as_echo "$as_me: Setting user supplied tool ICECC_CREATE_ENV= (no value)" >&6;} 59509 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_CREATE_ENV" >&5 59510 $as_echo_n "checking for ICECC_CREATE_ENV... " >&6; } 59511 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 59512 $as_echo "disabled" >&6; } 59513 else 59514 # Check if the provided tool contains a complete path. 59515 tool_specified="$ICECC_CREATE_ENV" 59516 tool_basename="${tool_specified##*/}" 59517 if test "x$tool_basename" = "x$tool_specified"; then 59518 # A command without a complete path is provided, search $PATH. 59519 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ICECC_CREATE_ENV=$tool_basename" >&5 59520 $as_echo "$as_me: Will search for user supplied tool ICECC_CREATE_ENV=$tool_basename" >&6;} 59521 # Extract the first word of "$tool_basename", so it can be a program name with args. 59522 set dummy $tool_basename; ac_word=$2 59523 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 59524 $as_echo_n "checking for $ac_word... " >&6; } 59525 if ${ac_cv_path_ICECC_CREATE_ENV+:} false; then : 59526 $as_echo_n "(cached) " >&6 59527 else 59528 case $ICECC_CREATE_ENV in 59529 [\\/]* | ?:[\\/]*) 59530 ac_cv_path_ICECC_CREATE_ENV="$ICECC_CREATE_ENV" # Let the user override the test with a path. 59531 ;; 59532 *) 59533 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 59534 for as_dir in $PATH 59535 do 59536 IFS=$as_save_IFS 59537 test -z "$as_dir" && as_dir=. 59538 for ac_exec_ext in '' $ac_executable_extensions; do 59539 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 59540 ac_cv_path_ICECC_CREATE_ENV="$as_dir/$ac_word$ac_exec_ext" 59541 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 59542 break 2 59543 fi 59544 done 59545 done 59546 IFS=$as_save_IFS 59547 59548 ;; 59549 esac 59550 fi 59551 ICECC_CREATE_ENV=$ac_cv_path_ICECC_CREATE_ENV 59552 if test -n "$ICECC_CREATE_ENV"; then 59553 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_CREATE_ENV" >&5 59554 $as_echo "$ICECC_CREATE_ENV" >&6; } 59555 else 59556 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 59557 $as_echo "no" >&6; } 59558 fi 59559 59560 59561 if test "x$ICECC_CREATE_ENV" = x; then 59562 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 59563 fi 59564 else 59565 # Otherwise we believe it is a complete path. Use it as it is. 59566 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ICECC_CREATE_ENV=$tool_specified" >&5 59567 $as_echo "$as_me: Will use user supplied tool ICECC_CREATE_ENV=$tool_specified" >&6;} 59568 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_CREATE_ENV" >&5 59569 $as_echo_n "checking for ICECC_CREATE_ENV... " >&6; } 59570 if test ! -x "$tool_specified"; then 59571 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 59572 $as_echo "not found" >&6; } 59573 as_fn_error $? "User supplied tool ICECC_CREATE_ENV=$tool_specified does not exist or is not executable" "$LINENO" 5 59574 fi 59575 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 59576 $as_echo "$tool_specified" >&6; } 59577 fi 59578 fi 59579 fi 59580 59581 fi 59582 59583 59584 59585 if test "x$ICECC_CREATE_ENV" = x; then 59586 as_fn_error $? "Could not find required tool for ICECC_CREATE_ENV" "$LINENO" 5 59587 fi 59588 59589 59590 # Use icecc-create-env to create a minimal compilation environment that can 59591 # be sent to the other hosts in the icecream cluster. 59592 icecc_create_env_log="${CONFIGURESUPPORT_OUTPUTDIR}/icecc/icecc_create_env.log" 59593 ${MKDIR} -p ${CONFIGURESUPPORT_OUTPUTDIR}/icecc 59594 # Older versions of icecc does not have the --gcc parameter 59595 if ${ICECC_CREATE_ENV} | $GREP -q -e --gcc; then 59596 icecc_gcc_arg="--gcc" 59597 fi 59598 if test "x${TOOLCHAIN_TYPE}" = "xgcc"; then 59599 59600 cd ${CONFIGURESUPPORT_OUTPUTDIR}/icecc \ 59601 && ${ICECC_CREATE_ENV} ${icecc_gcc_arg} ${CC} ${CXX} > \ 59602 ${icecc_create_env_log} 2>&1 59603 if test "$?" != "0"; then 59604 { $as_echo "$as_me:${as_lineno-$LINENO}: icecc-create-env output:" >&5 59605 $as_echo "$as_me: icecc-create-env output:" >&6;} 59606 cat \ 59607 ${icecc_create_env_log} 59608 as_fn_error $? "Failed to create icecc compiler environment" "$LINENO" 5 59609 fi 59610 59611 elif test "x$TOOLCHAIN_TYPE" = "xclang"; then 59612 # For clang, the icecc compilerwrapper is needed. It usually resides next 59613 # to icecc-create-env. 59614 59615 59616 59617 # Publish this variable in the help. 59618 59619 59620 if [ -z "${ICECC_WRAPPER+x}" ]; then 59621 # The variable is not set by user, try to locate tool using the code snippet 59622 for ac_prog in compilerwrapper 59623 do 59624 # Extract the first word of "$ac_prog", so it can be a program name with args. 59625 set dummy $ac_prog; ac_word=$2 59626 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 59627 $as_echo_n "checking for $ac_word... " >&6; } 59628 if ${ac_cv_path_ICECC_WRAPPER+:} false; then : 59629 $as_echo_n "(cached) " >&6 59630 else 59631 case $ICECC_WRAPPER in 59632 [\\/]* | ?:[\\/]*) 59633 ac_cv_path_ICECC_WRAPPER="$ICECC_WRAPPER" # Let the user override the test with a path. 59634 ;; 59635 *) 59636 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 59637 for as_dir in $PATH 59638 do 59639 IFS=$as_save_IFS 59640 test -z "$as_dir" && as_dir=. 59641 for ac_exec_ext in '' $ac_executable_extensions; do 59642 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 59643 ac_cv_path_ICECC_WRAPPER="$as_dir/$ac_word$ac_exec_ext" 59644 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 59645 break 2 59646 fi 59647 done 59648 done 59649 IFS=$as_save_IFS 59650 59651 ;; 59652 esac 59653 fi 59654 ICECC_WRAPPER=$ac_cv_path_ICECC_WRAPPER 59655 if test -n "$ICECC_WRAPPER"; then 59656 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_WRAPPER" >&5 59657 $as_echo "$ICECC_WRAPPER" >&6; } 59658 else 59659 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 59660 $as_echo "no" >&6; } 59661 fi 59662 59663 59664 test -n "$ICECC_WRAPPER" && break 59665 done 59666 59667 else 59668 # The variable is set, but is it from the command line or the environment? 59669 59670 # Try to remove the string !ICECC_WRAPPER! from our list. 59671 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!ICECC_WRAPPER!/} 59672 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 59673 # If it failed, the variable was not from the command line. Ignore it, 59674 # but warn the user (except for BASH, which is always set by the calling BASH). 59675 if test "xICECC_WRAPPER" != xBASH; then 59676 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of ICECC_WRAPPER from the environment. Use command line variables instead." >&5 59677 $as_echo "$as_me: WARNING: Ignoring value of ICECC_WRAPPER from the environment. Use command line variables instead." >&2;} 59678 fi 59679 # Try to locate tool using the code snippet 59680 for ac_prog in compilerwrapper 59681 do 59682 # Extract the first word of "$ac_prog", so it can be a program name with args. 59683 set dummy $ac_prog; ac_word=$2 59684 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 59685 $as_echo_n "checking for $ac_word... " >&6; } 59686 if ${ac_cv_path_ICECC_WRAPPER+:} false; then : 59687 $as_echo_n "(cached) " >&6 59688 else 59689 case $ICECC_WRAPPER in 59690 [\\/]* | ?:[\\/]*) 59691 ac_cv_path_ICECC_WRAPPER="$ICECC_WRAPPER" # Let the user override the test with a path. 59692 ;; 59693 *) 59694 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 59695 for as_dir in $PATH 59696 do 59697 IFS=$as_save_IFS 59698 test -z "$as_dir" && as_dir=. 59699 for ac_exec_ext in '' $ac_executable_extensions; do 59700 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 59701 ac_cv_path_ICECC_WRAPPER="$as_dir/$ac_word$ac_exec_ext" 59702 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 59703 break 2 59704 fi 59705 done 59706 done 59707 IFS=$as_save_IFS 59708 59709 ;; 59710 esac 59711 fi 59712 ICECC_WRAPPER=$ac_cv_path_ICECC_WRAPPER 59713 if test -n "$ICECC_WRAPPER"; then 59714 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_WRAPPER" >&5 59715 $as_echo "$ICECC_WRAPPER" >&6; } 59716 else 59717 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 59718 $as_echo "no" >&6; } 59719 fi 59720 59721 59722 test -n "$ICECC_WRAPPER" && break 59723 done 59724 59725 else 59726 # If it succeeded, then it was overridden by the user. We will use it 59727 # for the tool. 59728 59729 # First remove it from the list of overridden variables, so we can test 59730 # for unknown variables in the end. 59731 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 59732 59733 # Check if we try to supply an empty value 59734 if test "x$ICECC_WRAPPER" = x; then 59735 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool ICECC_WRAPPER= (no value)" >&5 59736 $as_echo "$as_me: Setting user supplied tool ICECC_WRAPPER= (no value)" >&6;} 59737 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_WRAPPER" >&5 59738 $as_echo_n "checking for ICECC_WRAPPER... " >&6; } 59739 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 59740 $as_echo "disabled" >&6; } 59741 else 59742 # Check if the provided tool contains a complete path. 59743 tool_specified="$ICECC_WRAPPER" 59744 tool_basename="${tool_specified##*/}" 59745 if test "x$tool_basename" = "x$tool_specified"; then 59746 # A command without a complete path is provided, search $PATH. 59747 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool ICECC_WRAPPER=$tool_basename" >&5 59748 $as_echo "$as_me: Will search for user supplied tool ICECC_WRAPPER=$tool_basename" >&6;} 59749 # Extract the first word of "$tool_basename", so it can be a program name with args. 59750 set dummy $tool_basename; ac_word=$2 59751 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 59752 $as_echo_n "checking for $ac_word... " >&6; } 59753 if ${ac_cv_path_ICECC_WRAPPER+:} false; then : 59754 $as_echo_n "(cached) " >&6 59755 else 59756 case $ICECC_WRAPPER in 59757 [\\/]* | ?:[\\/]*) 59758 ac_cv_path_ICECC_WRAPPER="$ICECC_WRAPPER" # Let the user override the test with a path. 59759 ;; 59760 *) 59761 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 59762 for as_dir in $PATH 59763 do 59764 IFS=$as_save_IFS 59765 test -z "$as_dir" && as_dir=. 59766 for ac_exec_ext in '' $ac_executable_extensions; do 59767 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 59768 ac_cv_path_ICECC_WRAPPER="$as_dir/$ac_word$ac_exec_ext" 59769 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 59770 break 2 59771 fi 59772 done 59773 done 59774 IFS=$as_save_IFS 59775 59776 ;; 59777 esac 59778 fi 59779 ICECC_WRAPPER=$ac_cv_path_ICECC_WRAPPER 59780 if test -n "$ICECC_WRAPPER"; then 59781 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ICECC_WRAPPER" >&5 59782 $as_echo "$ICECC_WRAPPER" >&6; } 59783 else 59784 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 59785 $as_echo "no" >&6; } 59786 fi 59787 59788 59789 if test "x$ICECC_WRAPPER" = x; then 59790 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 59791 fi 59792 else 59793 # Otherwise we believe it is a complete path. Use it as it is. 59794 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool ICECC_WRAPPER=$tool_specified" >&5 59795 $as_echo "$as_me: Will use user supplied tool ICECC_WRAPPER=$tool_specified" >&6;} 59796 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ICECC_WRAPPER" >&5 59797 $as_echo_n "checking for ICECC_WRAPPER... " >&6; } 59798 if test ! -x "$tool_specified"; then 59799 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 59800 $as_echo "not found" >&6; } 59801 as_fn_error $? "User supplied tool ICECC_WRAPPER=$tool_specified does not exist or is not executable" "$LINENO" 5 59802 fi 59803 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 59804 $as_echo "$tool_specified" >&6; } 59805 fi 59806 fi 59807 fi 59808 59809 fi 59810 59811 59812 59813 if test "x$ICECC_WRAPPER" = x; then 59814 as_fn_error $? "Could not find required tool for ICECC_WRAPPER" "$LINENO" 5 59815 fi 59816 59817 59818 59819 cd ${CONFIGURESUPPORT_OUTPUTDIR}/icecc \ 59820 && ${ICECC_CREATE_ENV} --clang ${CC} ${ICECC_WRAPPER} > ${icecc_create_env_log} 2>&1 59821 if test "$?" != "0"; then 59822 { $as_echo "$as_me:${as_lineno-$LINENO}: icecc-create-env output:" >&5 59823 $as_echo "$as_me: icecc-create-env output:" >&6;} 59824 cat ${icecc_create_env_log} 59825 as_fn_error $? "Failed to create icecc compiler environment" "$LINENO" 5 59826 fi 59827 59828 else 59829 as_fn_error $? "Can only create icecc compiler packages for toolchain types gcc and clang" "$LINENO" 5 59830 fi 59831 PATH="$old_path" 59832 # The bundle with the compiler gets a name based on checksums. Parse log file 59833 # to find it. 59834 ICECC_ENV_BUNDLE_BASENAME="`${SED} -n '/^creating/s/creating //p' ${icecc_create_env_log}`" 59835 ICECC_ENV_BUNDLE="${CONFIGURESUPPORT_OUTPUTDIR}/icecc/${ICECC_ENV_BUNDLE_BASENAME}" 59836 if test ! -f ${ICECC_ENV_BUNDLE}; then 59837 as_fn_error $? "icecc-create-env did not produce an environment ${ICECC_ENV_BUNDLE}" "$LINENO" 5 59838 fi 59839 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for icecc build environment for target compiler" >&5 59840 $as_echo_n "checking for icecc build environment for target compiler... " >&6; } 59841 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${ICECC_ENV_BUNDLE}" >&5 59842 $as_echo "${ICECC_ENV_BUNDLE}" >&6; } 59843 ICECC="ICECC_VERSION=${ICECC_ENV_BUNDLE} ICECC_CC=${CC} ICECC_CXX=${CXX} ${ICECC_CMD}" 59844 59845 if test "x${COMPILE_TYPE}" = "xcross"; then 59846 # If cross compiling, create a separate env package for the build compiler 59847 # Assume "gcc" or "cc" is gcc and "clang" is clang. Otherwise bail. 59848 icecc_create_env_log_build="${CONFIGURESUPPORT_OUTPUTDIR}/icecc/icecc_create_env_build.log" 59849 if test "x${BUILD_CC##*/}" = "xgcc" || test "x${BUILD_CC##*/}" = "xcc"; then 59850 59851 cd ${CONFIGURESUPPORT_OUTPUTDIR}/icecc \ 59852 && ${ICECC_CREATE_ENV} ${icecc_gcc_arg} ${BUILD_CC} ${BUILD_CXX} > \ 59853 ${icecc_create_env_log_build} 2>&1 59854 if test "$?" != "0"; then 59855 { $as_echo "$as_me:${as_lineno-$LINENO}: icecc-create-env output:" >&5 59856 $as_echo "$as_me: icecc-create-env output:" >&6;} 59857 cat \ 59858 ${icecc_create_env_log_build} 59859 as_fn_error $? "Failed to create icecc compiler environment" "$LINENO" 5 59860 fi 59861 59862 elif test "x${BUILD_CC##*/}" = "xclang"; then 59863 59864 cd ${CONFIGURESUPPORT_OUTPUTDIR}/icecc \ 59865 && ${ICECC_CREATE_ENV} --clang ${BUILD_CC} ${ICECC_WRAPPER} > ${icecc_create_env_log_build} 2>&1 59866 if test "$?" != "0"; then 59867 { $as_echo "$as_me:${as_lineno-$LINENO}: icecc-create-env output:" >&5 59868 $as_echo "$as_me: icecc-create-env output:" >&6;} 59869 cat ${icecc_create_env_log_build} 59870 as_fn_error $? "Failed to create icecc compiler environment" "$LINENO" 5 59871 fi 59872 59873 else 59874 as_fn_error $? "Cannot create icecc compiler package for ${BUILD_CC}" "$LINENO" 5 59875 fi 59876 ICECC_ENV_BUNDLE_BASENAME="`${SED} -n '/^creating/s/creating //p' ${icecc_create_env_log_build}`" 59877 ICECC_ENV_BUNDLE="${CONFIGURESUPPORT_OUTPUTDIR}/icecc/${ICECC_ENV_BUNDLE_BASENAME}" 59878 if test ! -f ${ICECC_ENV_BUNDLE}; then 59879 as_fn_error $? "icecc-create-env did not produce an environment ${ICECC_ENV_BUNDLE}" "$LINENO" 5 59880 fi 59881 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for icecc build environment for build compiler" >&5 59882 $as_echo_n "checking for icecc build environment for build compiler... " >&6; } 59883 { $as_echo "$as_me:${as_lineno-$LINENO}: result: ${ICECC_ENV_BUNDLE}" >&5 59884 $as_echo "${ICECC_ENV_BUNDLE}" >&6; } 59885 BUILD_ICECC="ICECC_VERSION=${ICECC_ENV_BUNDLE} ICECC_CC=${BUILD_CC} \ 59886 ICECC_CXX=${BUILD_CXX} ${ICECC_CMD}" 59887 else 59888 BUILD_ICECC="${ICECC}" 59889 fi 59890 59891 59892 fi 59893 59894 59895 # Can the C/C++ compiler use precompiled headers? 59896 59897 59898 ############################################################################### 59899 # 59900 # Can the C/C++ compiler use precompiled headers? 59901 # 59902 # Check whether --enable-precompiled-headers was given. 59903 if test "${enable_precompiled_headers+set}" = set; then : 59904 enableval=$enable_precompiled_headers; ENABLE_PRECOMPH=${enable_precompiled_headers} 59905 else 59906 ENABLE_PRECOMPH=yes 59907 fi 59908 59909 59910 USE_PRECOMPILED_HEADER=1 59911 { $as_echo "$as_me:${as_lineno-$LINENO}: checking If precompiled header is enabled" >&5 59912 $as_echo_n "checking If precompiled header is enabled... " >&6; } 59913 if test "x$ENABLE_PRECOMPH" = xno; then 59914 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, forced" >&5 59915 $as_echo "no, forced" >&6; } 59916 USE_PRECOMPILED_HEADER=0 59917 elif test "x$ICECC" != "x"; then 59918 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, does not work effectively with icecc" >&5 59919 $as_echo "no, does not work effectively with icecc" >&6; } 59920 USE_PRECOMPILED_HEADER=0 59921 else 59922 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 59923 $as_echo "yes" >&6; } 59924 fi 59925 59926 if test "x$ENABLE_PRECOMPH" = xyes; then 59927 # Check that the compiler actually supports precomp headers. 59928 if test "x$TOOLCHAIN_TYPE" = xgcc; then 59929 { $as_echo "$as_me:${as_lineno-$LINENO}: checking that precompiled headers work" >&5 59930 $as_echo_n "checking that precompiled headers work... " >&6; } 59931 echo "int alfa();" > conftest.h 59932 $CXX -x c++-header conftest.h -o conftest.hpp.gch 2>&5 >&5 59933 if test ! -f conftest.hpp.gch; then 59934 USE_PRECOMPILED_HEADER=0 59935 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 59936 $as_echo "no" >&6; } 59937 else 59938 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 59939 $as_echo "yes" >&6; } 59940 fi 59941 rm -f conftest.h conftest.hpp.gch 59942 fi 59943 fi 59944 59945 59946 59947 59948 # Setup use of ccache, if available 59949 59950 # Check whether --enable-ccache was given. 59951 if test "${enable_ccache+set}" = set; then : 59952 enableval=$enable_ccache; 59953 fi 59954 59955 59956 CCACHE= 59957 CCACHE_STATUS= 59958 { $as_echo "$as_me:${as_lineno-$LINENO}: checking is ccache enabled" >&5 59959 $as_echo_n "checking is ccache enabled... " >&6; } 59960 if test "x$enable_ccache" = xyes; then 59961 if test "x$TOOLCHAIN_TYPE" = "xgcc" -o "x$TOOLCHAIN_TYPE" = "xclang"; then 59962 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 59963 $as_echo "yes" >&6; } 59964 OLD_PATH="$PATH" 59965 if test "x$TOOLCHAIN_PATH" != x; then 59966 PATH=$TOOLCHAIN_PATH:$PATH 59967 fi 59968 59969 59970 59971 # Publish this variable in the help. 59972 59973 59974 if [ -z "${CCACHE+x}" ]; then 59975 # The variable is not set by user, try to locate tool using the code snippet 59976 for ac_prog in ccache 59977 do 59978 # Extract the first word of "$ac_prog", so it can be a program name with args. 59979 set dummy $ac_prog; ac_word=$2 59980 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 59981 $as_echo_n "checking for $ac_word... " >&6; } 59982 if ${ac_cv_path_CCACHE+:} false; then : 59983 $as_echo_n "(cached) " >&6 59984 else 59985 case $CCACHE in 59986 [\\/]* | ?:[\\/]*) 59987 ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path. 59988 ;; 59989 *) 59990 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 59991 for as_dir in $PATH 59992 do 59993 IFS=$as_save_IFS 59994 test -z "$as_dir" && as_dir=. 59995 for ac_exec_ext in '' $ac_executable_extensions; do 59996 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 59997 ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext" 59998 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 59999 break 2 60000 fi 60001 done 60002 done 60003 IFS=$as_save_IFS 60004 60005 ;; 60006 esac 60007 fi 60008 CCACHE=$ac_cv_path_CCACHE 60009 if test -n "$CCACHE"; then 60010 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5 60011 $as_echo "$CCACHE" >&6; } 60012 else 60013 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 60014 $as_echo "no" >&6; } 60015 fi 60016 60017 60018 test -n "$CCACHE" && break 60019 done 60020 60021 else 60022 # The variable is set, but is it from the command line or the environment? 60023 60024 # Try to remove the string !CCACHE! from our list. 60025 try_remove_var=${CONFIGURE_OVERRIDDEN_VARIABLES//!CCACHE!/} 60026 if test "x$try_remove_var" = "x$CONFIGURE_OVERRIDDEN_VARIABLES"; then 60027 # If it failed, the variable was not from the command line. Ignore it, 60028 # but warn the user (except for BASH, which is always set by the calling BASH). 60029 if test "xCCACHE" != xBASH; then 60030 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: Ignoring value of CCACHE from the environment. Use command line variables instead." >&5 60031 $as_echo "$as_me: WARNING: Ignoring value of CCACHE from the environment. Use command line variables instead." >&2;} 60032 fi 60033 # Try to locate tool using the code snippet 60034 for ac_prog in ccache 60035 do 60036 # Extract the first word of "$ac_prog", so it can be a program name with args. 60037 set dummy $ac_prog; ac_word=$2 60038 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 60039 $as_echo_n "checking for $ac_word... " >&6; } 60040 if ${ac_cv_path_CCACHE+:} false; then : 60041 $as_echo_n "(cached) " >&6 60042 else 60043 case $CCACHE in 60044 [\\/]* | ?:[\\/]*) 60045 ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path. 60046 ;; 60047 *) 60048 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 60049 for as_dir in $PATH 60050 do 60051 IFS=$as_save_IFS 60052 test -z "$as_dir" && as_dir=. 60053 for ac_exec_ext in '' $ac_executable_extensions; do 60054 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 60055 ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext" 60056 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 60057 break 2 60058 fi 60059 done 60060 done 60061 IFS=$as_save_IFS 60062 60063 ;; 60064 esac 60065 fi 60066 CCACHE=$ac_cv_path_CCACHE 60067 if test -n "$CCACHE"; then 60068 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5 60069 $as_echo "$CCACHE" >&6; } 60070 else 60071 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 60072 $as_echo "no" >&6; } 60073 fi 60074 60075 60076 test -n "$CCACHE" && break 60077 done 60078 60079 else 60080 # If it succeeded, then it was overridden by the user. We will use it 60081 # for the tool. 60082 60083 # First remove it from the list of overridden variables, so we can test 60084 # for unknown variables in the end. 60085 CONFIGURE_OVERRIDDEN_VARIABLES="$try_remove_var" 60086 60087 # Check if we try to supply an empty value 60088 if test "x$CCACHE" = x; then 60089 { $as_echo "$as_me:${as_lineno-$LINENO}: Setting user supplied tool CCACHE= (no value)" >&5 60090 $as_echo "$as_me: Setting user supplied tool CCACHE= (no value)" >&6;} 60091 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CCACHE" >&5 60092 $as_echo_n "checking for CCACHE... " >&6; } 60093 { $as_echo "$as_me:${as_lineno-$LINENO}: result: disabled" >&5 60094 $as_echo "disabled" >&6; } 60095 else 60096 # Check if the provided tool contains a complete path. 60097 tool_specified="$CCACHE" 60098 tool_basename="${tool_specified##*/}" 60099 if test "x$tool_basename" = "x$tool_specified"; then 60100 # A command without a complete path is provided, search $PATH. 60101 { $as_echo "$as_me:${as_lineno-$LINENO}: Will search for user supplied tool CCACHE=$tool_basename" >&5 60102 $as_echo "$as_me: Will search for user supplied tool CCACHE=$tool_basename" >&6;} 60103 # Extract the first word of "$tool_basename", so it can be a program name with args. 60104 set dummy $tool_basename; ac_word=$2 60105 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 60106 $as_echo_n "checking for $ac_word... " >&6; } 60107 if ${ac_cv_path_CCACHE+:} false; then : 60108 $as_echo_n "(cached) " >&6 60109 else 60110 case $CCACHE in 60111 [\\/]* | ?:[\\/]*) 60112 ac_cv_path_CCACHE="$CCACHE" # Let the user override the test with a path. 60113 ;; 60114 *) 60115 as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 60116 for as_dir in $PATH 60117 do 60118 IFS=$as_save_IFS 60119 test -z "$as_dir" && as_dir=. 60120 for ac_exec_ext in '' $ac_executable_extensions; do 60121 if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then 60122 ac_cv_path_CCACHE="$as_dir/$ac_word$ac_exec_ext" 60123 $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 60124 break 2 60125 fi 60126 done 60127 done 60128 IFS=$as_save_IFS 60129 60130 ;; 60131 esac 60132 fi 60133 CCACHE=$ac_cv_path_CCACHE 60134 if test -n "$CCACHE"; then 60135 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CCACHE" >&5 60136 $as_echo "$CCACHE" >&6; } 60137 else 60138 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 60139 $as_echo "no" >&6; } 60140 fi 60141 60142 60143 if test "x$CCACHE" = x; then 60144 as_fn_error $? "User supplied tool $tool_basename could not be found" "$LINENO" 5 60145 fi 60146 else 60147 # Otherwise we believe it is a complete path. Use it as it is. 60148 { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied tool CCACHE=$tool_specified" >&5 60149 $as_echo "$as_me: Will use user supplied tool CCACHE=$tool_specified" >&6;} 60150 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for CCACHE" >&5 60151 $as_echo_n "checking for CCACHE... " >&6; } 60152 if test ! -x "$tool_specified"; then 60153 { $as_echo "$as_me:${as_lineno-$LINENO}: result: not found" >&5 60154 $as_echo "not found" >&6; } 60155 as_fn_error $? "User supplied tool CCACHE=$tool_specified does not exist or is not executable" "$LINENO" 5 60156 fi 60157 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $tool_specified" >&5 60158 $as_echo "$tool_specified" >&6; } 60159 fi 60160 fi 60161 fi 60162 60163 fi 60164 60165 60166 60167 if test "x$CCACHE" = x; then 60168 as_fn_error $? "Could not find required tool for CCACHE" "$LINENO" 5 60169 fi 60170 60171 60172 PATH="$OLD_PATH" 60173 CCACHE_VERSION=`$CCACHE --version | head -n1 | $SED 's/[A-Za-z ]*//'` 60174 CCACHE_STATUS="Active ($CCACHE_VERSION)" 60175 else 60176 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 60177 $as_echo "no" >&6; } 60178 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: ccache is not supported with toolchain type $TOOLCHAIN_TYPE" >&5 60179 $as_echo "$as_me: WARNING: ccache is not supported with toolchain type $TOOLCHAIN_TYPE" >&2;} 60180 fi 60181 elif test "x$enable_ccache" = xno; then 60182 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no, explicitly disabled" >&5 60183 $as_echo "no, explicitly disabled" >&6; } 60184 CCACHE_STATUS="Disabled" 60185 elif test "x$enable_ccache" = x; then 60186 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 60187 $as_echo "no" >&6; } 60188 else 60189 { $as_echo "$as_me:${as_lineno-$LINENO}: result: unknown" >&5 60190 $as_echo "unknown" >&6; } 60191 as_fn_error $? "--enable-ccache does not accept any parameters" "$LINENO" 5 60192 fi 60193 60194 60195 60196 # Check whether --with-ccache-dir was given. 60197 if test "${with_ccache_dir+set}" = set; then : 60198 withval=$with_ccache_dir; 60199 fi 60200 60201 60202 if test "x$with_ccache_dir" != x; then 60203 # When using a non home ccache directory, assume the use is to share ccache files 60204 # with other users. Thus change the umask. 60205 SET_CCACHE_DIR="CCACHE_DIR=$with_ccache_dir CCACHE_UMASK=002" 60206 if test "x$CCACHE" = x; then 60207 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: --with-ccache-dir has no meaning when ccache is not enabled" >&5 60208 $as_echo "$as_me: WARNING: --with-ccache-dir has no meaning when ccache is not enabled" >&2;} 60209 fi 60210 fi 60211 60212 if test "x$CCACHE" != x; then 60213 60214 if test "x$CCACHE" != x; then 60215 if test "x$USE_PRECOMPILED_HEADER" = "x1"; then 60216 HAS_BAD_CCACHE=`$ECHO $CCACHE_VERSION | \ 60217 $GREP -e '^1.*' -e '^2.*' -e '^3\.0.*' -e '^3\.1\.[0123]$'` 60218 if test "x$HAS_BAD_CCACHE" != "x"; then 60219 as_fn_error $? "Precompiled headers requires ccache 3.1.4 or later, found $CCACHE_VERSION" "$LINENO" 5 60220 fi 60221 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if C-compiler supports ccache precompiled headers" >&5 60222 $as_echo_n "checking if C-compiler supports ccache precompiled headers... " >&6; } 60223 CCACHE_PRECOMP_FLAG="-fpch-preprocess" 60224 PUSHED_FLAGS="$CXXFLAGS" 60225 CXXFLAGS="$CCACHE_PRECOMP_FLAG $CXXFLAGS" 60226 cat confdefs.h - <<_ACEOF >conftest.$ac_ext 60227 /* end confdefs.h. */ 60228 60229 int 60230 main () 60231 { 60232 60233 ; 60234 return 0; 60235 } 60236 _ACEOF 60237 if ac_fn_cxx_try_compile "$LINENO"; then : 60238 CC_KNOWS_CCACHE_TRICK=yes 60239 else 60240 CC_KNOWS_CCACHE_TRICK=no 60241 fi 60242 rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext 60243 CXXFLAGS="$PUSHED_FLAGS" 60244 if test "x$CC_KNOWS_CCACHE_TRICK" = xyes; then 60245 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5 60246 $as_echo "yes" >&6; } 60247 CFLAGS_CCACHE="$CCACHE_PRECOMP_FLAG" 60248 60249 CCACHE_SLOPPINESS=pch_defines,time_macros 60250 else 60251 { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 60252 $as_echo "no" >&6; } 60253 as_fn_error $? "Cannot use ccache with precompiled headers without compiler support for $CCACHE_PRECOMP_FLAG" "$LINENO" 5 60254 fi 60255 fi 60256 60257 CCACHE="CCACHE_COMPRESS=1 $SET_CCACHE_DIR \ 60258 CCACHE_SLOPPINESS=$CCACHE_SLOPPINESS CCACHE_BASEDIR=$TOPDIR $CCACHE" 60259 60260 if test "x$SET_CCACHE_DIR" != x; then 60261 mkdir -p $CCACHE_DIR > /dev/null 2>&1 60262 chmod a+rwxs $CCACHE_DIR > /dev/null 2>&1 60263 fi 60264 fi 60265 60266 fi 60267 60268 60269 ############################################################################### 60270 # 60271 # And now the finish... 60272 # 60273 ############################################################################### 60274 60275 # Check for some common pitfalls 60276 60277 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then 60278 file_to_test="$SRC_ROOT/LICENSE" 60279 if test `$STAT -c '%a' "$file_to_test"` -lt 400; then 60280 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 60281 fi 60282 fi 60283 60284 60285 # Did user specify any unknown variables? 60286 60287 if test "x$CONFIGURE_OVERRIDDEN_VARIABLES" != x; then 60288 # Replace the separating ! with spaces before presenting for end user. 60289 unknown_variables=${CONFIGURE_OVERRIDDEN_VARIABLES//!/ } 60290 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: The following variables might be unknown to configure: $unknown_variables" >&5 60291 $as_echo "$as_me: WARNING: The following variables might be unknown to configure: $unknown_variables" >&2;} 60292 fi 60293 60294 60295 { $as_echo "$as_me:${as_lineno-$LINENO}: checking if build directory is on local disk" >&5 60296 $as_echo_n "checking if build directory is on local disk... " >&6; } 60297 60298 # df -l lists only local disks; if the given directory is not found then 60299 # a non-zero exit code is given 60300 if test "x$DF" = x; then 60301 if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then 60302 # msys does not have df; use Windows "net use" instead. 60303 IS_NETWORK_DISK=`net use | grep \`pwd -W | cut -d ":" -f 1 | tr a-z A-Z\`:` 60304 if test "x$IS_NETWORK_DISK" = x; then 60305 OUTPUT_DIR_IS_LOCAL="yes" 60306 else 60307 OUTPUT_DIR_IS_LOCAL="no" 60308 fi 60309 else 60310 # No df here, say it's local 60311 OUTPUT_DIR_IS_LOCAL="yes" 60312 fi 60313 else 60314 if $DF -l $OUTPUT_ROOT > /dev/null 2>&1; then 60315 OUTPUT_DIR_IS_LOCAL="yes" 60316 else 60317 OUTPUT_DIR_IS_LOCAL="no" 60318 fi 60319 fi 60320 60321 { $as_echo "$as_me:${as_lineno-$LINENO}: result: $OUTPUT_DIR_IS_LOCAL" >&5 60322 $as_echo "$OUTPUT_DIR_IS_LOCAL" >&6; } 60323 60324 60325 60326 # Check if the user has any old-style ALT_ variables set. 60327 FOUND_ALT_VARIABLES=`env | grep ^ALT_` 60328 60329 # Before generating output files, test if they exist. If they do, this is a reconfigure. 60330 # Since we can't properly handle the dependencies for this, warn the user about the situation 60331 if test -e $OUTPUT_ROOT/spec.gmk; then 60332 IS_RECONFIGURE=yes 60333 else 60334 IS_RECONFIGURE=no 60335 fi 60336 60337 60338 # At the end, call the custom hook. (Dummy macro if no custom sources available) 60339 60340 60341 # We're messing a bit with internal autoconf variables to put the config.status 60342 # in the output directory instead of the current directory. 60343 CONFIG_STATUS="$CONFIGURESUPPORT_OUTPUTDIR/config.status" 60344 60345 # Create the actual output files. Now the main work of configure is done. 60346 cat >confcache <<\_ACEOF 60347 # This file is a shell script that caches the results of configure 60348 # tests run on this system so they can be shared between configure 60349 # scripts and configure runs, see configure's option --config-cache. 60350 # It is not useful on other systems. If it contains results you don't 60351 # want to keep, you may remove or edit it. 60352 # 60353 # config.status only pays attention to the cache file if you give it 60354 # the --recheck option to rerun configure. 60355 # 60356 # `ac_cv_env_foo' variables (set or unset) will be overridden when 60357 # loading this file, other *unset* `ac_cv_foo' will be assigned the 60358 # following values. 60359 60360 _ACEOF 60361 60362 # The following way of writing the cache mishandles newlines in values, 60363 # but we know of no workaround that is simple, portable, and efficient. 60364 # So, we kill variables containing newlines. 60365 # Ultrix sh set writes to stderr and can't be redirected directly, 60366 # and sets the high bit in the cache file unless we assign to the vars. 60367 ( 60368 for ac_var in `(set) 2>&1 | sed -n 's/^\([a-zA-Z_][a-zA-Z0-9_]*\)=.*/\1/p'`; do 60369 eval ac_val=\$$ac_var 60370 case $ac_val in #( 60371 *${as_nl}*) 60372 case $ac_var in #( 60373 *_cv_*) { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: cache variable $ac_var contains a newline" >&5 60374 $as_echo "$as_me: WARNING: cache variable $ac_var contains a newline" >&2;} ;; 60375 esac 60376 case $ac_var in #( 60377 _ | IFS | as_nl) ;; #( 60378 BASH_ARGV | BASH_SOURCE) eval $ac_var= ;; #( 60379 *) { eval $ac_var=; unset $ac_var;} ;; 60380 esac ;; 60381 esac 60382 done 60383 60384 (set) 2>&1 | 60385 case $as_nl`(ac_space=' '; set) 2>&1` in #( 60386 *${as_nl}ac_space=\ *) 60387 # `set' does not quote correctly, so add quotes: double-quote 60388 # substitution turns \\\\ into \\, and sed turns \\ into \. 60389 sed -n \ 60390 "s/'/'\\\\''/g; 60391 s/^\\([_$as_cr_alnum]*_cv_[_$as_cr_alnum]*\\)=\\(.*\\)/\\1='\\2'/p" 60392 ;; #( 60393 *) 60394 # `set' quotes correctly as required by POSIX, so do not add quotes. 60395 sed -n "/^[_$as_cr_alnum]*_cv_[_$as_cr_alnum]*=/p" 60396 ;; 60397 esac | 60398 sort 60399 ) | 60400 sed ' 60401 /^ac_cv_env_/b end 60402 t clear 60403 :clear 60404 s/^\([^=]*\)=\(.*[{}].*\)$/test "${\1+set}" = set || &/ 60405 t end 60406 s/^\([^=]*\)=\(.*\)$/\1=${\1=\2}/ 60407 :end' >>confcache 60408 if diff "$cache_file" confcache >/dev/null 2>&1; then :; else 60409 if test -w "$cache_file"; then 60410 if test "x$cache_file" != "x/dev/null"; then 60411 { $as_echo "$as_me:${as_lineno-$LINENO}: updating cache $cache_file" >&5 60412 $as_echo "$as_me: updating cache $cache_file" >&6;} 60413 if test ! -f "$cache_file" || test -h "$cache_file"; then 60414 cat confcache >"$cache_file" 60415 else 60416 case $cache_file in #( 60417 */* | ?:*) 60418 mv -f confcache "$cache_file"$$ && 60419 mv -f "$cache_file"$$ "$cache_file" ;; #( 60420 *) 60421 mv -f confcache "$cache_file" ;; 60422 esac 60423 fi 60424 fi 60425 else 60426 { $as_echo "$as_me:${as_lineno-$LINENO}: not updating unwritable cache $cache_file" >&5 60427 $as_echo "$as_me: not updating unwritable cache $cache_file" >&6;} 60428 fi 60429 fi 60430 rm -f confcache 60431 60432 test "x$prefix" = xNONE && prefix=$ac_default_prefix 60433 # Let make expand exec_prefix. 60434 test "x$exec_prefix" = xNONE && exec_prefix='${prefix}' 60435 60436 # Transform confdefs.h into DEFS. 60437 # Protect against shell expansion while executing Makefile rules. 60438 # Protect against Makefile macro expansion. 60439 # 60440 # If the first sed substitution is executed (which looks for macros that 60441 # take arguments), then branch to the quote section. Otherwise, 60442 # look for a macro that doesn't take arguments. 60443 ac_script=' 60444 :mline 60445 /\\$/{ 60446 N 60447 s,\\\n,, 60448 b mline 60449 } 60450 t clear 60451 :clear 60452 s/^[ ]*#[ ]*define[ ][ ]*\([^ (][^ (]*([^)]*)\)[ ]*\(.*\)/-D\1=\2/g 60453 t quote 60454 s/^[ ]*#[ ]*define[ ][ ]*\([^ ][^ ]*\)[ ]*\(.*\)/-D\1=\2/g 60455 t quote 60456 b any 60457 :quote 60458 s/[ `~#$^&*(){}\\|;'\''"<>?]/\\&/g 60459 s/\[/\\&/g 60460 s/\]/\\&/g 60461 s/\$/$$/g 60462 H 60463 :any 60464 ${ 60465 g 60466 s/^\n// 60467 s/\n/ /g 60468 p 60469 } 60470 ' 60471 DEFS=`sed -n "$ac_script" confdefs.h` 60472 60473 60474 ac_libobjs= 60475 ac_ltlibobjs= 60476 U= 60477 for ac_i in : $LIBOBJS; do test "x$ac_i" = x: && continue 60478 # 1. Remove the extension, and $U if already installed. 60479 ac_script='s/\$U\././;s/\.o$//;s/\.obj$//' 60480 ac_i=`$as_echo "$ac_i" | sed "$ac_script"` 60481 # 2. Prepend LIBOBJDIR. When used with automake>=1.10 LIBOBJDIR 60482 # will be set to the directory where LIBOBJS objects are built. 60483 as_fn_append ac_libobjs " \${LIBOBJDIR}$ac_i\$U.$ac_objext" 60484 as_fn_append ac_ltlibobjs " \${LIBOBJDIR}$ac_i"'$U.lo' 60485 done 60486 LIBOBJS=$ac_libobjs 60487 60488 LTLIBOBJS=$ac_ltlibobjs 60489 60490 60491 60492 : "${CONFIG_STATUS=./config.status}" 60493 ac_write_fail=0 60494 ac_clean_files_save=$ac_clean_files 60495 ac_clean_files="$ac_clean_files $CONFIG_STATUS" 60496 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $CONFIG_STATUS" >&5 60497 $as_echo "$as_me: creating $CONFIG_STATUS" >&6;} 60498 as_write_fail=0 60499 cat >$CONFIG_STATUS <<_ASEOF || as_write_fail=1 60500 #! $SHELL 60501 # Generated by $as_me. 60502 # Run this file to recreate the current configuration. 60503 # Compiler output produced by configure, useful for debugging 60504 # configure, is in config.log if it exists. 60505 60506 debug=false 60507 ac_cs_recheck=false 60508 ac_cs_silent=false 60509 60510 SHELL=\${CONFIG_SHELL-$SHELL} 60511 export SHELL 60512 _ASEOF 60513 cat >>$CONFIG_STATUS <<\_ASEOF || as_write_fail=1 60514 ## -------------------- ## 60515 ## M4sh Initialization. ## 60516 ## -------------------- ## 60517 60518 # Be more Bourne compatible 60519 DUALCASE=1; export DUALCASE # for MKS sh 60520 if test -n "${ZSH_VERSION+set}" && (emulate sh) >/dev/null 2>&1; then : 60521 emulate sh 60522 NULLCMD=: 60523 # Pre-4.2 versions of Zsh do word splitting on ${1+"$@"}, which 60524 # is contrary to our usage. Disable this feature. 60525 alias -g '${1+"$@"}'='"$@"' 60526 setopt NO_GLOB_SUBST 60527 else 60528 case `(set -o) 2>/dev/null` in #( 60529 *posix*) : 60530 set -o posix ;; #( 60531 *) : 60532 ;; 60533 esac 60534 fi 60535 60536 60537 as_nl=' 60538 ' 60539 export as_nl 60540 # Printing a long string crashes Solaris 7 /usr/bin/printf. 60541 as_echo='\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\' 60542 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo 60543 as_echo=$as_echo$as_echo$as_echo$as_echo$as_echo$as_echo 60544 # Prefer a ksh shell builtin over an external printf program on Solaris, 60545 # but without wasting forks for bash or zsh. 60546 if test -z "$BASH_VERSION$ZSH_VERSION" \ 60547 && (test "X`print -r -- $as_echo`" = "X$as_echo") 2>/dev/null; then 60548 as_echo='print -r --' 60549 as_echo_n='print -rn --' 60550 elif (test "X`printf %s $as_echo`" = "X$as_echo") 2>/dev/null; then 60551 as_echo='printf %s\n' 60552 as_echo_n='printf %s' 60553 else 60554 if test "X`(/usr/ucb/echo -n -n $as_echo) 2>/dev/null`" = "X-n $as_echo"; then 60555 as_echo_body='eval /usr/ucb/echo -n "$1$as_nl"' 60556 as_echo_n='/usr/ucb/echo -n' 60557 else 60558 as_echo_body='eval expr "X$1" : "X\\(.*\\)"' 60559 as_echo_n_body='eval 60560 arg=$1; 60561 case $arg in #( 60562 *"$as_nl"*) 60563 expr "X$arg" : "X\\(.*\\)$as_nl"; 60564 arg=`expr "X$arg" : ".*$as_nl\\(.*\\)"`;; 60565 esac; 60566 expr "X$arg" : "X\\(.*\\)" | tr -d "$as_nl" 60567 ' 60568 export as_echo_n_body 60569 as_echo_n='sh -c $as_echo_n_body as_echo' 60570 fi 60571 export as_echo_body 60572 as_echo='sh -c $as_echo_body as_echo' 60573 fi 60574 60575 # The user is always right. 60576 if test "${PATH_SEPARATOR+set}" != set; then 60577 PATH_SEPARATOR=: 60578 (PATH='/bin;/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 && { 60579 (PATH='/bin:/bin'; FPATH=$PATH; sh -c :) >/dev/null 2>&1 || 60580 PATH_SEPARATOR=';' 60581 } 60582 fi 60583 60584 60585 # IFS 60586 # We need space, tab and new line, in precisely that order. Quoting is 60587 # there to prevent editors from complaining about space-tab. 60588 # (If _AS_PATH_WALK were called with IFS unset, it would disable word 60589 # splitting by setting IFS to empty value.) 60590 IFS=" "" $as_nl" 60591 60592 # Find who we are. Look in the path if we contain no directory separator. 60593 as_myself= 60594 case $0 in #(( 60595 *[\\/]* ) as_myself=$0 ;; 60596 *) as_save_IFS=$IFS; IFS=$PATH_SEPARATOR 60597 for as_dir in $PATH 60598 do 60599 IFS=$as_save_IFS 60600 test -z "$as_dir" && as_dir=. 60601 test -r "$as_dir/$0" && as_myself=$as_dir/$0 && break 60602 done 60603 IFS=$as_save_IFS 60604 60605 ;; 60606 esac 60607 # We did not find ourselves, most probably we were run as `sh COMMAND' 60608 # in which case we are not to be found in the path. 60609 if test "x$as_myself" = x; then 60610 as_myself=$0 60611 fi 60612 if test ! -f "$as_myself"; then 60613 $as_echo "$as_myself: error: cannot find myself; rerun with an absolute file name" >&2 60614 exit 1 60615 fi 60616 60617 # Unset variables that we do not need and which cause bugs (e.g. in 60618 # pre-3.0 UWIN ksh). But do not cause bugs in bash 2.01; the "|| exit 1" 60619 # suppresses any "Segmentation fault" message there. '((' could 60620 # trigger a bug in pdksh 5.2.14. 60621 for as_var in BASH_ENV ENV MAIL MAILPATH 60622 do eval test x\${$as_var+set} = xset \ 60623 && ( (unset $as_var) || exit 1) >/dev/null 2>&1 && unset $as_var || : 60624 done 60625 PS1='$ ' 60626 PS2='> ' 60627 PS4='+ ' 60628 60629 # NLS nuisances. 60630 LC_ALL=C 60631 export LC_ALL 60632 LANGUAGE=C 60633 export LANGUAGE 60634 60635 # CDPATH. 60636 (unset CDPATH) >/dev/null 2>&1 && unset CDPATH 60637 60638 60639 # as_fn_error STATUS ERROR [LINENO LOG_FD] 60640 # ---------------------------------------- 60641 # Output "`basename $0`: error: ERROR" to stderr. If LINENO and LOG_FD are 60642 # provided, also output the error to LOG_FD, referencing LINENO. Then exit the 60643 # script with STATUS, using 1 if that was 0. 60644 as_fn_error () 60645 { 60646 as_status=$1; test $as_status -eq 0 && as_status=1 60647 if test "$4"; then 60648 as_lineno=${as_lineno-"$3"} as_lineno_stack=as_lineno_stack=$as_lineno_stack 60649 $as_echo "$as_me:${as_lineno-$LINENO}: error: $2" >&$4 60650 fi 60651 $as_echo "$as_me: error: $2" >&2 60652 as_fn_exit $as_status 60653 } # as_fn_error 60654 60655 60656 # as_fn_set_status STATUS 60657 # ----------------------- 60658 # Set $? to STATUS, without forking. 60659 as_fn_set_status () 60660 { 60661 return $1 60662 } # as_fn_set_status 60663 60664 # as_fn_exit STATUS 60665 # ----------------- 60666 # Exit the shell with STATUS, even in a "trap 0" or "set -e" context. 60667 as_fn_exit () 60668 { 60669 set +e 60670 as_fn_set_status $1 60671 exit $1 60672 } # as_fn_exit 60673 60674 # as_fn_unset VAR 60675 # --------------- 60676 # Portably unset VAR. 60677 as_fn_unset () 60678 { 60679 { eval $1=; unset $1;} 60680 } 60681 as_unset=as_fn_unset 60682 # as_fn_append VAR VALUE 60683 # ---------------------- 60684 # Append the text in VALUE to the end of the definition contained in VAR. Take 60685 # advantage of any shell optimizations that allow amortized linear growth over 60686 # repeated appends, instead of the typical quadratic growth present in naive 60687 # implementations. 60688 if (eval "as_var=1; as_var+=2; test x\$as_var = x12") 2>/dev/null; then : 60689 eval 'as_fn_append () 60690 { 60691 eval $1+=\$2 60692 }' 60693 else 60694 as_fn_append () 60695 { 60696 eval $1=\$$1\$2 60697 } 60698 fi # as_fn_append 60699 60700 # as_fn_arith ARG... 60701 # ------------------ 60702 # Perform arithmetic evaluation on the ARGs, and store the result in the 60703 # global $as_val. Take advantage of shells that can avoid forks. The arguments 60704 # must be portable across $(()) and expr. 60705 if (eval "test \$(( 1 + 1 )) = 2") 2>/dev/null; then : 60706 eval 'as_fn_arith () 60707 { 60708 as_val=$(( $* )) 60709 }' 60710 else 60711 as_fn_arith () 60712 { 60713 as_val=`expr "$@" || test $? -eq 1` 60714 } 60715 fi # as_fn_arith 60716 60717 60718 if expr a : '\(a\)' >/dev/null 2>&1 && 60719 test "X`expr 00001 : '.*\(...\)'`" = X001; then 60720 as_expr=expr 60721 else 60722 as_expr=false 60723 fi 60724 60725 if (basename -- /) >/dev/null 2>&1 && test "X`basename -- / 2>&1`" = "X/"; then 60726 as_basename=basename 60727 else 60728 as_basename=false 60729 fi 60730 60731 if (as_dir=`dirname -- /` && test "X$as_dir" = X/) >/dev/null 2>&1; then 60732 as_dirname=dirname 60733 else 60734 as_dirname=false 60735 fi 60736 60737 as_me=`$as_basename -- "$0" || 60738 $as_expr X/"$0" : '.*/\([^/][^/]*\)/*$' \| \ 60739 X"$0" : 'X\(//\)$' \| \ 60740 X"$0" : 'X\(/\)' \| . 2>/dev/null || 60741 $as_echo X/"$0" | 60742 sed '/^.*\/\([^/][^/]*\)\/*$/{ 60743 s//\1/ 60744 q 60745 } 60746 /^X\/\(\/\/\)$/{ 60747 s//\1/ 60748 q 60749 } 60750 /^X\/\(\/\).*/{ 60751 s//\1/ 60752 q 60753 } 60754 s/.*/./; q'` 60755 60756 # Avoid depending upon Character Ranges. 60757 as_cr_letters='abcdefghijklmnopqrstuvwxyz' 60758 as_cr_LETTERS='ABCDEFGHIJKLMNOPQRSTUVWXYZ' 60759 as_cr_Letters=$as_cr_letters$as_cr_LETTERS 60760 as_cr_digits='0123456789' 60761 as_cr_alnum=$as_cr_Letters$as_cr_digits 60762 60763 ECHO_C= ECHO_N= ECHO_T= 60764 case `echo -n x` in #((((( 60765 -n*) 60766 case `echo 'xy\c'` in 60767 *c*) ECHO_T=' ';; # ECHO_T is single tab character. 60768 xy) ECHO_C='\c';; 60769 *) echo `echo ksh88 bug on AIX 6.1` > /dev/null 60770 ECHO_T=' ';; 60771 esac;; 60772 *) 60773 ECHO_N='-n';; 60774 esac 60775 60776 rm -f conf$$ conf$$.exe conf$$.file 60777 if test -d conf$$.dir; then 60778 rm -f conf$$.dir/conf$$.file 60779 else 60780 rm -f conf$$.dir 60781 mkdir conf$$.dir 2>/dev/null 60782 fi 60783 if (echo >conf$$.file) 2>/dev/null; then 60784 if ln -s conf$$.file conf$$ 2>/dev/null; then 60785 as_ln_s='ln -s' 60786 # ... but there are two gotchas: 60787 # 1) On MSYS, both `ln -s file dir' and `ln file dir' fail. 60788 # 2) DJGPP < 2.04 has no symlinks; `ln -s' creates a wrapper executable. 60789 # In both cases, we have to default to `cp -pR'. 60790 ln -s conf$$.file conf$$.dir 2>/dev/null && test ! -f conf$$.exe || 60791 as_ln_s='cp -pR' 60792 elif ln conf$$.file conf$$ 2>/dev/null; then 60793 as_ln_s=ln 60794 else 60795 as_ln_s='cp -pR' 60796 fi 60797 else 60798 as_ln_s='cp -pR' 60799 fi 60800 rm -f conf$$ conf$$.exe conf$$.dir/conf$$.file conf$$.file 60801 rmdir conf$$.dir 2>/dev/null 60802 60803 60804 # as_fn_mkdir_p 60805 # ------------- 60806 # Create "$as_dir" as a directory, including parents if necessary. 60807 as_fn_mkdir_p () 60808 { 60809 60810 case $as_dir in #( 60811 -*) as_dir=./$as_dir;; 60812 esac 60813 test -d "$as_dir" || eval $as_mkdir_p || { 60814 as_dirs= 60815 while :; do 60816 case $as_dir in #( 60817 *\'*) as_qdir=`$as_echo "$as_dir" | sed "s/'/'\\\\\\\\''/g"`;; #'( 60818 *) as_qdir=$as_dir;; 60819 esac 60820 as_dirs="'$as_qdir' $as_dirs" 60821 as_dir=`$as_dirname -- "$as_dir" || 60822 $as_expr X"$as_dir" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 60823 X"$as_dir" : 'X\(//\)[^/]' \| \ 60824 X"$as_dir" : 'X\(//\)$' \| \ 60825 X"$as_dir" : 'X\(/\)' \| . 2>/dev/null || 60826 $as_echo X"$as_dir" | 60827 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 60828 s//\1/ 60829 q 60830 } 60831 /^X\(\/\/\)[^/].*/{ 60832 s//\1/ 60833 q 60834 } 60835 /^X\(\/\/\)$/{ 60836 s//\1/ 60837 q 60838 } 60839 /^X\(\/\).*/{ 60840 s//\1/ 60841 q 60842 } 60843 s/.*/./; q'` 60844 test -d "$as_dir" && break 60845 done 60846 test -z "$as_dirs" || eval "mkdir $as_dirs" 60847 } || test -d "$as_dir" || as_fn_error $? "cannot create directory $as_dir" 60848 60849 60850 } # as_fn_mkdir_p 60851 if mkdir -p . 2>/dev/null; then 60852 as_mkdir_p='mkdir -p "$as_dir"' 60853 else 60854 test -d ./-p && rmdir ./-p 60855 as_mkdir_p=false 60856 fi 60857 60858 60859 # as_fn_executable_p FILE 60860 # ----------------------- 60861 # Test if FILE is an executable regular file. 60862 as_fn_executable_p () 60863 { 60864 test -f "$1" && test -x "$1" 60865 } # as_fn_executable_p 60866 as_test_x='test -x' 60867 as_executable_p=as_fn_executable_p 60868 60869 # Sed expression to map a string onto a valid CPP name. 60870 as_tr_cpp="eval sed 'y%*$as_cr_letters%P$as_cr_LETTERS%;s%[^_$as_cr_alnum]%_%g'" 60871 60872 # Sed expression to map a string onto a valid variable name. 60873 as_tr_sh="eval sed 'y%*+%pp%;s%[^_$as_cr_alnum]%_%g'" 60874 60875 60876 exec 6>&1 60877 ## ----------------------------------- ## 60878 ## Main body of $CONFIG_STATUS script. ## 60879 ## ----------------------------------- ## 60880 _ASEOF 60881 test $as_write_fail = 0 && chmod +x $CONFIG_STATUS || ac_write_fail=1 60882 60883 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 60884 # Save the log message, to keep $0 and so on meaningful, and to 60885 # report actual input values of CONFIG_FILES etc. instead of their 60886 # values after options handling. 60887 ac_log=" 60888 This file was extended by OpenJDK $as_me jdk9, which was 60889 generated by GNU Autoconf 2.69. Invocation command line was 60890 60891 CONFIG_FILES = $CONFIG_FILES 60892 CONFIG_HEADERS = $CONFIG_HEADERS 60893 CONFIG_LINKS = $CONFIG_LINKS 60894 CONFIG_COMMANDS = $CONFIG_COMMANDS 60895 $ $0 $@ 60896 60897 on `(hostname || uname -n) 2>/dev/null | sed 1q` 60898 " 60899 60900 _ACEOF 60901 60902 case $ac_config_files in *" 60903 "*) set x $ac_config_files; shift; ac_config_files=$*;; 60904 esac 60905 60906 60907 60908 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 60909 # Files that config.status was made for. 60910 config_files="$ac_config_files" 60911 60912 _ACEOF 60913 60914 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 60915 ac_cs_usage="\ 60916 \`$as_me' instantiates files and other configuration actions 60917 from templates according to the current configuration. Unless the files 60918 and actions are specified as TAGs, all are instantiated by default. 60919 60920 Usage: $0 [OPTION]... [TAG]... 60921 60922 -h, --help print this help, then exit 60923 -V, --version print version number and configuration settings, then exit 60924 --config print configuration, then exit 60925 -q, --quiet, --silent 60926 do not print progress messages 60927 -d, --debug don't remove temporary files 60928 --recheck update $as_me by reconfiguring in the same conditions 60929 --file=FILE[:TEMPLATE] 60930 instantiate the configuration file FILE 60931 60932 Configuration files: 60933 $config_files 60934 60935 Report bugs to <build-dev@openjdk.java.net>. 60936 OpenJDK home page: <http://openjdk.java.net>." 60937 60938 _ACEOF 60939 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 60940 ac_cs_config="`$as_echo "$ac_configure_args" | sed 's/^ //; s/[\\""\`\$]/\\\\&/g'`" 60941 ac_cs_version="\\ 60942 OpenJDK config.status jdk9 60943 configured by $0, generated by GNU Autoconf 2.69, 60944 with options \\"\$ac_cs_config\\" 60945 60946 Copyright (C) 2012 Free Software Foundation, Inc. 60947 This config.status script is free software; the Free Software Foundation 60948 gives unlimited permission to copy, distribute and modify it." 60949 60950 ac_pwd='$ac_pwd' 60951 srcdir='$srcdir' 60952 AWK='$AWK' 60953 test -n "\$AWK" || AWK=awk 60954 _ACEOF 60955 60956 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 60957 # The default lists apply if the user does not specify any file. 60958 ac_need_defaults=: 60959 while test $# != 0 60960 do 60961 case $1 in 60962 --*=?*) 60963 ac_option=`expr "X$1" : 'X\([^=]*\)='` 60964 ac_optarg=`expr "X$1" : 'X[^=]*=\(.*\)'` 60965 ac_shift=: 60966 ;; 60967 --*=) 60968 ac_option=`expr "X$1" : 'X\([^=]*\)='` 60969 ac_optarg= 60970 ac_shift=: 60971 ;; 60972 *) 60973 ac_option=$1 60974 ac_optarg=$2 60975 ac_shift=shift 60976 ;; 60977 esac 60978 60979 case $ac_option in 60980 # Handling of the options. 60981 -recheck | --recheck | --rechec | --reche | --rech | --rec | --re | --r) 60982 ac_cs_recheck=: ;; 60983 --version | --versio | --versi | --vers | --ver | --ve | --v | -V ) 60984 $as_echo "$ac_cs_version"; exit ;; 60985 --config | --confi | --conf | --con | --co | --c ) 60986 $as_echo "$ac_cs_config"; exit ;; 60987 --debug | --debu | --deb | --de | --d | -d ) 60988 debug=: ;; 60989 --file | --fil | --fi | --f ) 60990 $ac_shift 60991 case $ac_optarg in 60992 *\'*) ac_optarg=`$as_echo "$ac_optarg" | sed "s/'/'\\\\\\\\''/g"` ;; 60993 '') as_fn_error $? "missing file argument" ;; 60994 esac 60995 as_fn_append CONFIG_FILES " '$ac_optarg'" 60996 ac_need_defaults=false;; 60997 --he | --h | --help | --hel | -h ) 60998 $as_echo "$ac_cs_usage"; exit ;; 60999 -q | -quiet | --quiet | --quie | --qui | --qu | --q \ 61000 | -silent | --silent | --silen | --sile | --sil | --si | --s) 61001 ac_cs_silent=: ;; 61002 61003 # This is an error. 61004 -*) as_fn_error $? "unrecognized option: \`$1' 61005 Try \`$0 --help' for more information." ;; 61006 61007 *) as_fn_append ac_config_targets " $1" 61008 ac_need_defaults=false ;; 61009 61010 esac 61011 shift 61012 done 61013 61014 ac_configure_extra_args= 61015 61016 if $ac_cs_silent; then 61017 exec 6>/dev/null 61018 ac_configure_extra_args="$ac_configure_extra_args --silent" 61019 fi 61020 61021 _ACEOF 61022 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 61023 if \$ac_cs_recheck; then 61024 set X $SHELL '$0' $ac_configure_args \$ac_configure_extra_args --no-create --no-recursion 61025 shift 61026 \$as_echo "running CONFIG_SHELL=$SHELL \$*" >&6 61027 CONFIG_SHELL='$SHELL' 61028 export CONFIG_SHELL 61029 exec "\$@" 61030 fi 61031 61032 _ACEOF 61033 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 61034 exec 5>>config.log 61035 { 61036 echo 61037 sed 'h;s/./-/g;s/^.../## /;s/...$/ ##/;p;x;p;x' <<_ASBOX 61038 ## Running $as_me. ## 61039 _ASBOX 61040 $as_echo "$ac_log" 61041 } >&5 61042 61043 _ACEOF 61044 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 61045 _ACEOF 61046 61047 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 61048 61049 # Handling of arguments. 61050 for ac_config_target in $ac_config_targets 61051 do 61052 case $ac_config_target in 61053 "$OUTPUT_ROOT/spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/spec.gmk:$AUTOCONF_DIR/spec.gmk.in" ;; 61054 "$OUTPUT_ROOT/hotspot-spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/hotspot-spec.gmk:$AUTOCONF_DIR/hotspot-spec.gmk.in" ;; 61055 "$OUTPUT_ROOT/bootcycle-spec.gmk") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/bootcycle-spec.gmk:$AUTOCONF_DIR/bootcycle-spec.gmk.in" ;; 61056 "$OUTPUT_ROOT/compare.sh") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/compare.sh:$AUTOCONF_DIR/compare.sh.in" ;; 61057 "$OUTPUT_ROOT/Makefile") CONFIG_FILES="$CONFIG_FILES $OUTPUT_ROOT/Makefile:$AUTOCONF_DIR/Makefile.in" ;; 61058 61059 *) as_fn_error $? "invalid argument: \`$ac_config_target'" "$LINENO" 5;; 61060 esac 61061 done 61062 61063 61064 # If the user did not use the arguments to specify the items to instantiate, 61065 # then the envvar interface is used. Set only those that are not. 61066 # We use the long form for the default assignment because of an extremely 61067 # bizarre bug on SunOS 4.1.3. 61068 if $ac_need_defaults; then 61069 test "${CONFIG_FILES+set}" = set || CONFIG_FILES=$config_files 61070 fi 61071 61072 # Have a temporary directory for convenience. Make it in the build tree 61073 # simply because there is no reason against having it here, and in addition, 61074 # creating and moving files from /tmp can sometimes cause problems. 61075 # Hook for its removal unless debugging. 61076 # Note that there is a small window in which the directory will not be cleaned: 61077 # after its creation but before its name has been assigned to `$tmp'. 61078 $debug || 61079 { 61080 tmp= ac_tmp= 61081 trap 'exit_status=$? 61082 : "${ac_tmp:=$tmp}" 61083 { test ! -d "$ac_tmp" || rm -fr "$ac_tmp"; } && exit $exit_status 61084 ' 0 61085 trap 'as_fn_exit 1' 1 2 13 15 61086 } 61087 # Create a (secure) tmp directory for tmp files. 61088 61089 { 61090 tmp=`(umask 077 && mktemp -d "./confXXXXXX") 2>/dev/null` && 61091 test -d "$tmp" 61092 } || 61093 { 61094 tmp=./conf$$-$RANDOM 61095 (umask 077 && mkdir "$tmp") 61096 } || as_fn_error $? "cannot create a temporary directory in ." "$LINENO" 5 61097 ac_tmp=$tmp 61098 61099 # Set up the scripts for CONFIG_FILES section. 61100 # No need to generate them if there are no CONFIG_FILES. 61101 # This happens for instance with `./config.status config.h'. 61102 if test -n "$CONFIG_FILES"; then 61103 61104 61105 ac_cr=`echo X | tr X '\015'` 61106 # On cygwin, bash can eat \r inside `` if the user requested igncr. 61107 # But we know of no other shell where ac_cr would be empty at this 61108 # point, so we can use a bashism as a fallback. 61109 if test "x$ac_cr" = x; then 61110 eval ac_cr=\$\'\\r\' 61111 fi 61112 ac_cs_awk_cr=`$AWK 'BEGIN { print "a\rb" }' </dev/null 2>/dev/null` 61113 if test "$ac_cs_awk_cr" = "a${ac_cr}b"; then 61114 ac_cs_awk_cr='\\r' 61115 else 61116 ac_cs_awk_cr=$ac_cr 61117 fi 61118 61119 echo 'BEGIN {' >"$ac_tmp/subs1.awk" && 61120 _ACEOF 61121 61122 61123 { 61124 echo "cat >conf$$subs.awk <<_ACEOF" && 61125 echo "$ac_subst_vars" | sed 's/.*/&!$&$ac_delim/' && 61126 echo "_ACEOF" 61127 } >conf$$subs.sh || 61128 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 61129 ac_delim_num=`echo "$ac_subst_vars" | grep -c '^'` 61130 ac_delim='%!_!# ' 61131 for ac_last_try in false false false false false :; do 61132 . ./conf$$subs.sh || 61133 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 61134 61135 ac_delim_n=`sed -n "s/.*$ac_delim\$/X/p" conf$$subs.awk | grep -c X` 61136 if test $ac_delim_n = $ac_delim_num; then 61137 break 61138 elif $ac_last_try; then 61139 as_fn_error $? "could not make $CONFIG_STATUS" "$LINENO" 5 61140 else 61141 ac_delim="$ac_delim!$ac_delim _$ac_delim!! " 61142 fi 61143 done 61144 rm -f conf$$subs.sh 61145 61146 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 61147 cat >>"\$ac_tmp/subs1.awk" <<\\_ACAWK && 61148 _ACEOF 61149 sed -n ' 61150 h 61151 s/^/S["/; s/!.*/"]=/ 61152 p 61153 g 61154 s/^[^!]*!// 61155 :repl 61156 t repl 61157 s/'"$ac_delim"'$// 61158 t delim 61159 :nl 61160 h 61161 s/\(.\{148\}\)..*/\1/ 61162 t more1 61163 s/["\\]/\\&/g; s/^/"/; s/$/\\n"\\/ 61164 p 61165 n 61166 b repl 61167 :more1 61168 s/["\\]/\\&/g; s/^/"/; s/$/"\\/ 61169 p 61170 g 61171 s/.\{148\}// 61172 t nl 61173 :delim 61174 h 61175 s/\(.\{148\}\)..*/\1/ 61176 t more2 61177 s/["\\]/\\&/g; s/^/"/; s/$/"/ 61178 p 61179 b 61180 :more2 61181 s/["\\]/\\&/g; s/^/"/; s/$/"\\/ 61182 p 61183 g 61184 s/.\{148\}// 61185 t delim 61186 ' <conf$$subs.awk | sed ' 61187 /^[^""]/{ 61188 N 61189 s/\n// 61190 } 61191 ' >>$CONFIG_STATUS || ac_write_fail=1 61192 rm -f conf$$subs.awk 61193 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 61194 _ACAWK 61195 cat >>"\$ac_tmp/subs1.awk" <<_ACAWK && 61196 for (key in S) S_is_set[key] = 1 61197 FS = "" 61198 61199 } 61200 { 61201 line = $ 0 61202 nfields = split(line, field, "@") 61203 substed = 0 61204 len = length(field[1]) 61205 for (i = 2; i < nfields; i++) { 61206 key = field[i] 61207 keylen = length(key) 61208 if (S_is_set[key]) { 61209 value = S[key] 61210 line = substr(line, 1, len) "" value "" substr(line, len + keylen + 3) 61211 len += length(value) + length(field[++i]) 61212 substed = 1 61213 } else 61214 len += 1 + keylen 61215 } 61216 61217 print line 61218 } 61219 61220 _ACAWK 61221 _ACEOF 61222 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 61223 if sed "s/$ac_cr//" < /dev/null > /dev/null 2>&1; then 61224 sed "s/$ac_cr\$//; s/$ac_cr/$ac_cs_awk_cr/g" 61225 else 61226 cat 61227 fi < "$ac_tmp/subs1.awk" > "$ac_tmp/subs.awk" \ 61228 || as_fn_error $? "could not setup config files machinery" "$LINENO" 5 61229 _ACEOF 61230 61231 # VPATH may cause trouble with some makes, so we remove sole $(srcdir), 61232 # ${srcdir} and @srcdir@ entries from VPATH if srcdir is ".", strip leading and 61233 # trailing colons and then remove the whole line if VPATH becomes empty 61234 # (actually we leave an empty line to preserve line numbers). 61235 if test "x$srcdir" = x.; then 61236 ac_vpsub='/^[ ]*VPATH[ ]*=[ ]*/{ 61237 h 61238 s/// 61239 s/^/:/ 61240 s/[ ]*$/:/ 61241 s/:\$(srcdir):/:/g 61242 s/:\${srcdir}:/:/g 61243 s/:@srcdir@:/:/g 61244 s/^:*// 61245 s/:*$// 61246 x 61247 s/\(=[ ]*\).*/\1/ 61248 G 61249 s/\n// 61250 s/^[^=]*=[ ]*$// 61251 }' 61252 fi 61253 61254 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 61255 fi # test -n "$CONFIG_FILES" 61256 61257 61258 eval set X " :F $CONFIG_FILES " 61259 shift 61260 for ac_tag 61261 do 61262 case $ac_tag in 61263 :[FHLC]) ac_mode=$ac_tag; continue;; 61264 esac 61265 case $ac_mode$ac_tag in 61266 :[FHL]*:*);; 61267 :L* | :C*:*) as_fn_error $? "invalid tag \`$ac_tag'" "$LINENO" 5;; 61268 :[FH]-) ac_tag=-:-;; 61269 :[FH]*) ac_tag=$ac_tag:$ac_tag.in;; 61270 esac 61271 ac_save_IFS=$IFS 61272 IFS=: 61273 set x $ac_tag 61274 IFS=$ac_save_IFS 61275 shift 61276 ac_file=$1 61277 shift 61278 61279 case $ac_mode in 61280 :L) ac_source=$1;; 61281 :[FH]) 61282 ac_file_inputs= 61283 for ac_f 61284 do 61285 case $ac_f in 61286 -) ac_f="$ac_tmp/stdin";; 61287 *) # Look for the file first in the build tree, then in the source tree 61288 # (if the path is not absolute). The absolute path cannot be DOS-style, 61289 # because $ac_f cannot contain `:'. 61290 test -f "$ac_f" || 61291 case $ac_f in 61292 [\\/$]*) false;; 61293 *) test -f "$srcdir/$ac_f" && ac_f="$srcdir/$ac_f";; 61294 esac || 61295 as_fn_error 1 "cannot find input file: \`$ac_f'" "$LINENO" 5;; 61296 esac 61297 case $ac_f in *\'*) ac_f=`$as_echo "$ac_f" | sed "s/'/'\\\\\\\\''/g"`;; esac 61298 as_fn_append ac_file_inputs " '$ac_f'" 61299 done 61300 61301 # Let's still pretend it is `configure' which instantiates (i.e., don't 61302 # use $as_me), people would be surprised to read: 61303 # /* config.h. Generated by config.status. */ 61304 configure_input='Generated from '` 61305 $as_echo "$*" | sed 's|^[^:]*/||;s|:[^:]*/|, |g' 61306 `' by configure.' 61307 if test x"$ac_file" != x-; then 61308 configure_input="$ac_file. $configure_input" 61309 { $as_echo "$as_me:${as_lineno-$LINENO}: creating $ac_file" >&5 61310 $as_echo "$as_me: creating $ac_file" >&6;} 61311 fi 61312 # Neutralize special characters interpreted by sed in replacement strings. 61313 case $configure_input in #( 61314 *\&* | *\|* | *\\* ) 61315 ac_sed_conf_input=`$as_echo "$configure_input" | 61316 sed 's/[\\\\&|]/\\\\&/g'`;; #( 61317 *) ac_sed_conf_input=$configure_input;; 61318 esac 61319 61320 case $ac_tag in 61321 *:-:* | *:-) cat >"$ac_tmp/stdin" \ 61322 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 ;; 61323 esac 61324 ;; 61325 esac 61326 61327 ac_dir=`$as_dirname -- "$ac_file" || 61328 $as_expr X"$ac_file" : 'X\(.*[^/]\)//*[^/][^/]*/*$' \| \ 61329 X"$ac_file" : 'X\(//\)[^/]' \| \ 61330 X"$ac_file" : 'X\(//\)$' \| \ 61331 X"$ac_file" : 'X\(/\)' \| . 2>/dev/null || 61332 $as_echo X"$ac_file" | 61333 sed '/^X\(.*[^/]\)\/\/*[^/][^/]*\/*$/{ 61334 s//\1/ 61335 q 61336 } 61337 /^X\(\/\/\)[^/].*/{ 61338 s//\1/ 61339 q 61340 } 61341 /^X\(\/\/\)$/{ 61342 s//\1/ 61343 q 61344 } 61345 /^X\(\/\).*/{ 61346 s//\1/ 61347 q 61348 } 61349 s/.*/./; q'` 61350 as_dir="$ac_dir"; as_fn_mkdir_p 61351 ac_builddir=. 61352 61353 case "$ac_dir" in 61354 .) ac_dir_suffix= ac_top_builddir_sub=. ac_top_build_prefix= ;; 61355 *) 61356 ac_dir_suffix=/`$as_echo "$ac_dir" | sed 's|^\.[\\/]||'` 61357 # A ".." for each directory in $ac_dir_suffix. 61358 ac_top_builddir_sub=`$as_echo "$ac_dir_suffix" | sed 's|/[^\\/]*|/..|g;s|/||'` 61359 case $ac_top_builddir_sub in 61360 "") ac_top_builddir_sub=. ac_top_build_prefix= ;; 61361 *) ac_top_build_prefix=$ac_top_builddir_sub/ ;; 61362 esac ;; 61363 esac 61364 ac_abs_top_builddir=$ac_pwd 61365 ac_abs_builddir=$ac_pwd$ac_dir_suffix 61366 # for backward compatibility: 61367 ac_top_builddir=$ac_top_build_prefix 61368 61369 case $srcdir in 61370 .) # We are building in place. 61371 ac_srcdir=. 61372 ac_top_srcdir=$ac_top_builddir_sub 61373 ac_abs_top_srcdir=$ac_pwd ;; 61374 [\\/]* | ?:[\\/]* ) # Absolute name. 61375 ac_srcdir=$srcdir$ac_dir_suffix; 61376 ac_top_srcdir=$srcdir 61377 ac_abs_top_srcdir=$srcdir ;; 61378 *) # Relative name. 61379 ac_srcdir=$ac_top_build_prefix$srcdir$ac_dir_suffix 61380 ac_top_srcdir=$ac_top_build_prefix$srcdir 61381 ac_abs_top_srcdir=$ac_pwd/$srcdir ;; 61382 esac 61383 ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix 61384 61385 61386 case $ac_mode in 61387 :F) 61388 # 61389 # CONFIG_FILE 61390 # 61391 61392 _ACEOF 61393 61394 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 61395 # If the template does not know about datarootdir, expand it. 61396 # FIXME: This hack should be removed a few years after 2.60. 61397 ac_datarootdir_hack=; ac_datarootdir_seen= 61398 ac_sed_dataroot=' 61399 /datarootdir/ { 61400 p 61401 q 61402 } 61403 /@datadir@/p 61404 /@docdir@/p 61405 /@infodir@/p 61406 /@localedir@/p 61407 /@mandir@/p' 61408 case `eval "sed -n \"\$ac_sed_dataroot\" $ac_file_inputs"` in 61409 *datarootdir*) ac_datarootdir_seen=yes;; 61410 *@datadir@*|*@docdir@*|*@infodir@*|*@localedir@*|*@mandir@*) 61411 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&5 61412 $as_echo "$as_me: WARNING: $ac_file_inputs seems to ignore the --datarootdir setting" >&2;} 61413 _ACEOF 61414 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 61415 ac_datarootdir_hack=' 61416 s&@datadir@&$datadir&g 61417 s&@docdir@&$docdir&g 61418 s&@infodir@&$infodir&g 61419 s&@localedir@&$localedir&g 61420 s&@mandir@&$mandir&g 61421 s&\\\${datarootdir}&$datarootdir&g' ;; 61422 esac 61423 _ACEOF 61424 61425 # Neutralize VPATH when `$srcdir' = `.'. 61426 # Shell code in configure.ac might set extrasub. 61427 # FIXME: do we really want to maintain this feature? 61428 cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1 61429 ac_sed_extra="$ac_vpsub 61430 $extrasub 61431 _ACEOF 61432 cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 61433 :t 61434 /@[a-zA-Z_][a-zA-Z_0-9]*@/!b 61435 s|@configure_input@|$ac_sed_conf_input|;t t 61436 s&@top_builddir@&$ac_top_builddir_sub&;t t 61437 s&@top_build_prefix@&$ac_top_build_prefix&;t t 61438 s&@srcdir@&$ac_srcdir&;t t 61439 s&@abs_srcdir@&$ac_abs_srcdir&;t t 61440 s&@top_srcdir@&$ac_top_srcdir&;t t 61441 s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t 61442 s&@builddir@&$ac_builddir&;t t 61443 s&@abs_builddir@&$ac_abs_builddir&;t t 61444 s&@abs_top_builddir@&$ac_abs_top_builddir&;t t 61445 $ac_datarootdir_hack 61446 " 61447 eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ 61448 >$ac_tmp/out || as_fn_error $? "could not create $ac_file" "$LINENO" 5 61449 61450 test -z "$ac_datarootdir_hack$ac_datarootdir_seen" && 61451 { ac_out=`sed -n '/\${datarootdir}/p' "$ac_tmp/out"`; test -n "$ac_out"; } && 61452 { ac_out=`sed -n '/^[ ]*datarootdir[ ]*:*=/p' \ 61453 "$ac_tmp/out"`; test -z "$ac_out"; } && 61454 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: $ac_file contains a reference to the variable \`datarootdir' 61455 which seems to be undefined. Please make sure it is defined" >&5 61456 $as_echo "$as_me: WARNING: $ac_file contains a reference to the variable \`datarootdir' 61457 which seems to be undefined. Please make sure it is defined" >&2;} 61458 61459 rm -f "$ac_tmp/stdin" 61460 case $ac_file in 61461 -) cat "$ac_tmp/out" && rm -f "$ac_tmp/out";; 61462 *) rm -f "$ac_file" && mv "$ac_tmp/out" "$ac_file";; 61463 esac \ 61464 || as_fn_error $? "could not create $ac_file" "$LINENO" 5 61465 ;; 61466 61467 61468 61469 esac 61470 61471 done # for ac_tag 61472 61473 61474 as_fn_exit 0 61475 _ACEOF 61476 ac_clean_files=$ac_clean_files_save 61477 61478 test $ac_write_fail = 0 || 61479 as_fn_error $? "write failure creating $CONFIG_STATUS" "$LINENO" 5 61480 61481 61482 # configure is writing to config.log, and then calls config.status. 61483 # config.status does its own redirection, appending to config.log. 61484 # Unfortunately, on DOS this fails, as config.log is still kept open 61485 # by configure, so config.status won't be able to write to it; its 61486 # output is simply discarded. So we exec the FD to /dev/null, 61487 # effectively closing config.log, so it can be properly (re)opened and 61488 # appended to by config.status. When coming back to configure, we 61489 # need to make the FD available again. 61490 if test "$no_create" != yes; then 61491 ac_cs_success=: 61492 ac_config_status_args= 61493 test "$silent" = yes && 61494 ac_config_status_args="$ac_config_status_args --quiet" 61495 exec 5>/dev/null 61496 $SHELL $CONFIG_STATUS $ac_config_status_args || ac_cs_success=false 61497 exec 5>>config.log 61498 # Use ||, not &&, to avoid exiting from the if with $? = 1, which 61499 # would make configure fail if this is the last instruction. 61500 $ac_cs_success || as_fn_exit 1 61501 fi 61502 if test -n "$ac_unrecognized_opts" && test "$enable_option_checking" != no; then 61503 { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: unrecognized options: $ac_unrecognized_opts" >&5 61504 $as_echo "$as_me: WARNING: unrecognized options: $ac_unrecognized_opts" >&2;} 61505 fi 61506 61507 61508 # After AC_OUTPUT, we need to do final work 61509 61510 61511 # Try to move config.log (generated by autoconf) to the configure-support directory. 61512 if test -e ./config.log; then 61513 $MV -f ./config.log "$CONFIGURESUPPORT_OUTPUTDIR/config.log" 2> /dev/null 61514 fi 61515 61516 # Rotate our log file (configure.log) 61517 if test -e "$OUTPUT_ROOT/configure.log.old"; then 61518 $RM -f "$OUTPUT_ROOT/configure.log.old" 61519 fi 61520 if test -e "$OUTPUT_ROOT/configure.log"; then 61521 $MV -f "$OUTPUT_ROOT/configure.log" "$OUTPUT_ROOT/configure.log.old" 2> /dev/null 61522 fi 61523 61524 # Move configure.log from current directory to the build output root 61525 if test -e ./configure.log; then 61526 echo found it 61527 $MV -f ./configure.log "$OUTPUT_ROOT/configure.log" 2> /dev/null 61528 fi 61529 61530 # Make the compare script executable 61531 $CHMOD +x $OUTPUT_ROOT/compare.sh 61532 61533 61534 # Finally output some useful information to the user 61535 61536 # Finally output some useful information to the user 61537 61538 printf "\n" 61539 printf "====================================================\n" 61540 if test "x$no_create" != "xyes"; then 61541 if test "x$IS_RECONFIGURE" != "xyes"; then 61542 printf "A new configuration has been successfully created in\n%s\n" "$OUTPUT_ROOT" 61543 else 61544 printf "The existing configuration has been successfully updated in\n%s\n" "$OUTPUT_ROOT" 61545 fi 61546 else 61547 if test "x$IS_RECONFIGURE" != "xyes"; then 61548 printf "A configuration has been successfully checked but not created\n" 61549 else 61550 printf "The existing configuration has been successfully checked in\n%s\n" "$OUTPUT_ROOT" 61551 fi 61552 fi 61553 if test "x$CONFIGURE_COMMAND_LINE" != x; then 61554 printf "using configure arguments '$CONFIGURE_COMMAND_LINE'.\n" 61555 else 61556 printf "using default settings.\n" 61557 fi 61558 61559 printf "\n" 61560 printf "Configuration summary:\n" 61561 printf "* Debug level: $DEBUG_LEVEL\n" 61562 printf "* HS debug level: $HOTSPOT_DEBUG_LEVEL\n" 61563 printf "* JDK variant: $JDK_VARIANT\n" 61564 printf "* JVM variants: $with_jvm_variants\n" 61565 printf "* OpenJDK target: OS: $OPENJDK_TARGET_OS, CPU architecture: $OPENJDK_TARGET_CPU_ARCH, address length: $OPENJDK_TARGET_CPU_BITS\n" 61566 printf "* Version string: $VERSION_STRING ($VERSION_SHORT)\n" 61567 61568 printf "\n" 61569 printf "Tools summary:\n" 61570 if test "x$OPENJDK_BUILD_OS" = "xwindows"; then 61571 printf "* Environment: $WINDOWS_ENV_VENDOR version $WINDOWS_ENV_VERSION (root at $WINDOWS_ENV_ROOT_PATH)\n" 61572 fi 61573 printf "* Boot JDK: $BOOT_JDK_VERSION (at $BOOT_JDK)\n" 61574 if test "x$TOOLCHAIN_VERSION" != "x"; then 61575 print_version=" $TOOLCHAIN_VERSION" 61576 fi 61577 printf "* Toolchain: $TOOLCHAIN_TYPE ($TOOLCHAIN_DESCRIPTION$print_version)\n" 61578 printf "* C Compiler: Version $CC_VERSION_NUMBER (at $CC)\n" 61579 printf "* C++ Compiler: Version $CXX_VERSION_NUMBER (at $CXX)\n" 61580 61581 printf "\n" 61582 printf "Build performance summary:\n" 61583 printf "* Cores to use: $JOBS\n" 61584 printf "* Memory limit: $MEMORY_SIZE MB\n" 61585 if test "x$CCACHE_STATUS" != "x"; then 61586 printf "* ccache status: $CCACHE_STATUS\n" 61587 fi 61588 printf "\n" 61589 61590 if test "x$BUILDING_MULTIPLE_JVM_VARIANTS" = "xyes"; then 61591 printf "NOTE: You have requested to build more than one version of the JVM, which\n" 61592 printf "will result in longer build times.\n" 61593 printf "\n" 61594 fi 61595 61596 if test "x$FOUND_ALT_VARIABLES" != "x"; then 61597 printf "WARNING: You have old-style ALT_ environment variables set.\n" 61598 printf "These are not respected, and will be ignored. It is recommended\n" 61599 printf "that you clean your environment. The following variables are set:\n" 61600 printf "$FOUND_ALT_VARIABLES\n" 61601 printf "\n" 61602 fi 61603 61604 if test "x$OUTPUT_DIR_IS_LOCAL" != "xyes"; then 61605 printf "WARNING: Your build output directory is not on a local disk.\n" 61606 printf "This will severely degrade build performance!\n" 61607 printf "It is recommended that you create an output directory on a local disk,\n" 61608 printf "and run the configure script again from that directory.\n" 61609 printf "\n" 61610 fi 61611 61612 if test "x$IS_RECONFIGURE" = "xyes" && test "x$no_create" != "xyes"; then 61613 printf "WARNING: The result of this configuration has overridden an older\n" 61614 printf "configuration. You *should* run 'make clean' to make sure you get a\n" 61615 printf "proper build. Failure to do so might result in strange build problems.\n" 61616 printf "\n" 61617 fi 61618 61619 if test "x$IS_RECONFIGURE" != "xyes" && test "x$no_create" = "xyes"; then 61620 printf "WARNING: The result of this configuration was not saved.\n" 61621 printf "You should run without '--no-create | -n' to create the configuration.\n" 61622 printf "\n" 61623 fi 61624 61625 61626 61627 # Locate config.log. 61628 if test -e "$CONFIGURESUPPORT_OUTPUTDIR/config.log"; then 61629 CONFIG_LOG_PATH="$CONFIGURESUPPORT_OUTPUTDIR" 61630 elif test -e "./config.log"; then 61631 CONFIG_LOG_PATH="." 61632 fi 61633 61634 if test -e "$CONFIG_LOG_PATH/config.log"; then 61635 $GREP '^configure:.*: WARNING:' "$CONFIG_LOG_PATH/config.log" > /dev/null 2>&1 61636 if test $? -eq 0; then 61637 printf "The following warnings were produced. Repeated here for convenience:\n" 61638 # We must quote sed expression (using []) to stop m4 from eating the []. 61639 $GREP '^configure:.*: WARNING:' "$CONFIG_LOG_PATH/config.log" | $SED -e 's/^configure:[0-9]*: //' 61640 printf "\n" 61641 fi 61642 fi 61643