common/autoconf/generated-configure.sh

Print this page




 647 LLVM_CFLAGS
 648 LLVM_CONFIG
 649 LIBFFI_LIBS
 650 LIBFFI_CFLAGS
 651 STATIC_CXX_SETTING
 652 LIBDL
 653 LIBM
 654 LIBZIP_CAN_USE_MMAP
 655 USE_EXTERNAL_LIBZ
 656 USE_EXTERNAL_LIBPNG
 657 PNG_LIBS
 658 PNG_CFLAGS
 659 USE_EXTERNAL_LIBGIF
 660 USE_EXTERNAL_LIBJPEG
 661 ALSA_LIBS
 662 ALSA_CFLAGS
 663 FREETYPE_BUNDLE_LIB_PATH
 664 FREETYPE_LIBS
 665 FREETYPE_CFLAGS
 666 CUPS_CFLAGS
 667 OPENWIN_HOME
 668 X_EXTRA_LIBS
 669 X_LIBS
 670 X_PRE_LIBS
 671 X_CFLAGS
 672 XMKMF
 673 FIXPATH
 674 ZIP_DEBUGINFO_FILES
 675 ENABLE_DEBUG_SYMBOLS
 676 CFLAGS_WARNINGS_ARE_ERRORS
 677 COMPILER_SUPPORTS_TARGET_BITS_FLAG
 678 ZERO_ARCHFLAG
 679 LDFLAGS_CXX_JDK
 680 LDFLAGS_JDKEXE_SUFFIX
 681 LDFLAGS_JDKLIB_SUFFIX
 682 LDFLAGS_JDKEXE
 683 LDFLAGS_JDKLIB
 684 CXXFLAGS_JDKEXE
 685 CXXFLAGS_JDKLIB
 686 CFLAGS_JDKEXE
 687 CFLAGS_JDKLIB


 691 LEGACY_EXTRA_CFLAGS
 692 CXX_O_FLAG_NONE
 693 CXX_O_FLAG_NORM
 694 CXX_O_FLAG_HI
 695 CXX_O_FLAG_HIGHEST
 696 C_O_FLAG_NONE
 697 C_O_FLAG_NORM
 698 C_O_FLAG_HI
 699 C_O_FLAG_HIGHEST
 700 CXXFLAGS_DEBUG_SYMBOLS
 701 CFLAGS_DEBUG_SYMBOLS
 702 CXX_FLAG_DEPS
 703 C_FLAG_DEPS
 704 SET_SHARED_LIBRARY_MAPFILE
 705 SET_SHARED_LIBRARY_NAME
 706 SET_SHARED_LIBRARY_ORIGIN
 707 SET_EXECUTABLE_ORIGIN
 708 SHARED_LIBRARY_FLAGS
 709 CXX_FLAG_REORDER
 710 C_FLAG_REORDER


 711 RC_FLAGS
 712 AR_OUT_OPTION
 713 LD_OUT_OPTION
 714 EXE_OUT_OPTION
 715 CC_OUT_OPTION
 716 POST_MCS_CMD
 717 POST_STRIP_CMD
 718 ARFLAGS
 719 COMPILER_TARGET_BITS_FLAG
 720 JT_HOME
 721 JTREGEXE
 722 USING_BROKEN_SUSE_LD
 723 PACKAGE_PATH
 724 LDEXECXX
 725 LDEXE
 726 USE_CLANG
 727 HOTSPOT_LD
 728 HOTSPOT_CXX
 729 HOTSPOT_RC
 730 HOTSPOT_MT


 743 STRIP
 744 DUMPBIN
 745 RC
 746 MT
 747 LIPO
 748 ac_ct_OBJC
 749 OBJCFLAGS
 750 OBJC
 751 ac_ct_AR
 752 AR
 753 AS
 754 LDCXX
 755 LD
 756 CXXCPP
 757 CPP
 758 ac_ct_CXX
 759 CXXFLAGS
 760 CXX
 761 ac_ct_PROPER_COMPILER_CXX
 762 PROPER_COMPILER_CXX
 763 TOOLS_DIR_CXX
 764 POTENTIAL_CXX
 765 OBJEXT
 766 EXEEXT
 767 ac_ct_CC
 768 CPPFLAGS
 769 LDFLAGS
 770 CFLAGS
 771 CC
 772 ac_ct_PROPER_COMPILER_CC
 773 PROPER_COMPILER_CC
 774 TOOLS_DIR_CC
 775 POTENTIAL_CC
 776 VS_PATH
 777 VS_LIB
 778 VS_INCLUDE
 779 CYGWIN_LINK
 780 EXE_SUFFIX
 781 OBJ_SUFFIX
 782 STATIC_LIBRARY
 783 SHARED_LIBRARY
 784 STATIC_LIBRARY_SUFFIX
 785 SHARED_LIBRARY_SUFFIX
 786 LIBRARY_PREFIX
 787 TOOLCHAIN_TYPE
 788 BUILD_HOTSPOT
 789 HOTSPOT_DIST
 790 BUILD_OUTPUT
 791 OVERRIDE_SRC_ROOT
 792 ADD_SRC_ROOT
 793 JDK_TOPDIR
 794 NASHORN_TOPDIR


 870 DEBUG_CLASSFILES
 871 FASTDEBUG
 872 VARIANT
 873 DEBUG_LEVEL
 874 MACOSX_UNIVERSAL
 875 INCLUDE_SA
 876 JVM_VARIANT_CORE
 877 JVM_VARIANT_ZEROSHARK
 878 JVM_VARIANT_ZERO
 879 JVM_VARIANT_KERNEL
 880 JVM_VARIANT_MINIMAL1
 881 JVM_VARIANT_CLIENT
 882 JVM_VARIANT_SERVER
 883 JVM_VARIANTS
 884 JVM_INTERPRETER
 885 JDK_VARIANT
 886 SET_OPENJDK
 887 BUILD_LOG_WRAPPER
 888 BUILD_LOG_PREVIOUS
 889 BUILD_LOG
 890 SYS_ROOT
 891 TOPDIR
 892 PATH_SEP
 893 ZERO_ARCHDEF
 894 DEFINE_CROSS_COMPILE_ARCH
 895 LP64
 896 OPENJDK_TARGET_OS_EXPORT_DIR
 897 OPENJDK_TARGET_OS_API_DIR
 898 OPENJDK_TARGET_CPU_JLI_CFLAGS
 899 OPENJDK_TARGET_CPU_OSARCH
 900 OPENJDK_TARGET_CPU_ISADIR
 901 OPENJDK_TARGET_CPU_LIBDIR
 902 OPENJDK_TARGET_CPU_LEGACY_LIB
 903 OPENJDK_TARGET_CPU_LEGACY
 904 REQUIRED_OS_VERSION
 905 REQUIRED_OS_NAME
 906 COMPILE_TYPE
 907 OPENJDK_TARGET_CPU_ENDIAN
 908 OPENJDK_TARGET_CPU_BITS
 909 OPENJDK_TARGET_CPU_ARCH
 910 OPENJDK_TARGET_CPU


1003 datadir
1004 datarootdir
1005 libexecdir
1006 sbindir
1007 bindir
1008 program_transform_name
1009 prefix
1010 exec_prefix
1011 PACKAGE_URL
1012 PACKAGE_BUGREPORT
1013 PACKAGE_STRING
1014 PACKAGE_VERSION
1015 PACKAGE_TARNAME
1016 PACKAGE_NAME
1017 PATH_SEPARATOR
1018 SHELL'
1019 ac_subst_files=''
1020 ac_user_opts='
1021 enable_option_checking
1022 with_target_bits

1023 with_sys_root

1024 with_tools_dir
1025 with_devkit

1026 enable_openjdk_only
1027 with_custom_make_dir
1028 with_jdk_variant
1029 with_jvm_interpreter
1030 with_jvm_variants
1031 enable_debug
1032 with_debug_level
1033 with_conf_name
1034 with_builddeps_conf
1035 with_builddeps_server
1036 with_builddeps_dir
1037 with_builddeps_group
1038 enable_headful
1039 enable_hotspot_test_in_build
1040 with_cacerts_file
1041 enable_unlimited_crypto
1042 enable_rmiconnector_iiop
1043 with_milestone
1044 with_update_version
1045 with_user_release_suffix


1831   --enable-macosx-runtime-support
1832                           Deprecated. Option is kept for backwards
1833                           compatibility and is ignored
1834   --disable-freetype-bundling
1835                           disable bundling of the freetype library with the
1836                           build result [enabled on Windows or when using
1837                           --with-freetype, disabled otherwise]
1838   --enable-sjavac         use sjavac to do fast incremental compiles
1839                           [disabled]
1840   --disable-precompiled-headers
1841                           disable using precompiled headers when compiling C++
1842                           [enabled]
1843   --enable-ccache         enable using ccache to speed up recompilations
1844                           [disabled]
1845 
1846 Optional Packages:
1847   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
1848   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
1849   --with-target-bits      build 32-bit or 64-bit binaries (for platforms that
1850                           support it), e.g. --with-target-bits=32 [guessed]
1851   --with-sys-root         pass this sys-root to the compilers and tools (for
1852                           cross-compiling)
1853   --with-tools-dir        search this directory for compilers and tools (for
1854                           cross-compiling)
1855   --with-devkit           use this directory as base for tools-dir and
1856                           sys-root (for cross-compiling)







1857   --with-custom-make-dir  Deprecated. Option is kept for backwards
1858                           compatibility and is ignored
1859   --with-jdk-variant      JDK variant to build (normal) [normal]
1860   --with-jvm-interpreter  JVM interpreter to build (template, cpp) [template]
1861   --with-jvm-variants     JVM variants (separated by commas) to build (server,
1862                           client, minimal1, kernel, zero, zeroshark, core)
1863                           [server]
1864   --with-debug-level      set the debug level (release, fastdebug, slowdebug,
1865                           optimized (HotSpot build only)) [release]
1866   --with-conf-name        use this as the name of the configuration [generated
1867                           from important configuration options]
1868   --with-builddeps-conf   use this configuration file for the builddeps
1869   --with-builddeps-server download and use build dependencies from this server
1870                           url
1871   --with-builddeps-dir    store downloaded build dependencies here
1872                           [/localhome/builddeps]
1873   --with-builddeps-group  chgrp the downloaded build dependencies to this
1874                           group
1875   --with-cacerts-file     specify alternative cacerts file
1876   --with-milestone        Set milestone value for build [internal]


3308 # version 2 for more details (a copy is included in the LICENSE file that
3309 # accompanied this code).
3310 #
3311 # You should have received a copy of the GNU General Public License version
3312 # 2 along with this work; if not, write to the Free Software Foundation,
3313 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3314 #
3315 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3316 # or visit www.oracle.com if you need additional information or have any
3317 # questions.
3318 #
3319 
3320 # Test if $1 is a valid argument to $3 (often is $JAVA passed as $3)
3321 # If so, then append $1 to $2 \
3322 # Also set JVM_ARG_OK to true/false depending on outcome.
3323 
3324 
3325 # Appends a string to a path variable, only adding the : when needed.
3326 
3327 



3328 # This will make sure the given variable points to a full and proper
3329 # path. This means:
3330 # 1) There will be no spaces in the path. On posix platforms,
3331 #    spaces in the path will result in an error. On Windows,
3332 #    the path will be rewritten using short-style to be space-free.
3333 # 2) The path will be absolute, and it will be in unix-style (on
3334 #     cygwin).
3335 # $1: The name of the variable to fix
3336 
3337 
3338 # This will make sure the given variable points to a executable
3339 # with a full and proper path. This means:
3340 # 1) There will be no spaces in the path. On posix platforms,
3341 #    spaces in the path will result in an error. On Windows,
3342 #    the path will be rewritten using short-style to be space-free.
3343 # 2) The path will be absolute, and it will be in unix-style (on
3344 #     cygwin).
3345 # Any arguments given to the executable is preserved.
3346 # If the input variable does not have a directory specification, then
3347 # it need to be in the PATH.


4216 
4217 # Check if the VS env variables were setup prior to running configure.
4218 # If not, then find vcvarsall.bat and run it automatically, and integrate
4219 # the set env variables into the spec file.
4220 
4221 
4222 
4223 
4224 
4225 
4226 
4227 
4228 
4229 
4230 # This line needs to be here, verbatim, after all includes and the dummy hook
4231 # definitions. It is replaced with custom functionality when building
4232 # custom sources.
4233 #CUSTOM_AUTOCONF_INCLUDE
4234 
4235 # Do not change or remove the following line, it is needed for consistency checks:
4236 DATE_WHEN_GENERATED=1395652496
4237 
4238 ###############################################################################
4239 #
4240 # Initialization / Boot-strapping
4241 #
4242 # The bootstrapping process needs to solve the "chicken or the egg" problem,
4243 # thus it jumps back and forth, each time gaining something needed later on.
4244 #
4245 ###############################################################################
4246 
4247 # If we are requested to print additional help, do that and then exit.
4248 # This must be the very first call.
4249 
4250   if test "x$CONFIGURE_PRINT_TOOLCHAIN_LIST" != x; then
4251     $PRINTF "The following toolchains are available as arguments to --with-toolchain-type.\n"
4252     $PRINTF "Which are valid to use depends on the build platform.\n"
4253     for toolchain in $VALID_TOOLCHAINS_all; do
4254       # Use indirect variable referencing
4255       toolchain_var_name=TOOLCHAIN_DESCRIPTION_$toolchain
4256       TOOLCHAIN_DESCRIPTION=${!toolchain_var_name}


14223       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of TOPDIR, which resolves as \"$path\", is invalid." >&5
14224 $as_echo "$as_me: The path of TOPDIR, which resolves as \"$path\", is invalid." >&6;}
14225       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
14226     fi
14227 
14228     # Use eval to expand a potential ~
14229     eval path="$path"
14230     if test ! -f "$path" && test ! -d "$path"; then
14231       as_fn_error $? "The path of TOPDIR, which resolves as \"$path\", is not found." "$LINENO" 5
14232     fi
14233 
14234     TOPDIR="`cd "$path"; $THEPWDCMD -L`"
14235   fi
14236 
14237   # SRC_ROOT is a traditional alias for TOPDIR.
14238   SRC_ROOT=$TOPDIR
14239 
14240   # Locate the directory of this script.
14241   AUTOCONF_DIR=$TOPDIR/common/autoconf
14242 
14243   if test "x$OPENJDK_BUILD_OS" = "xsolaris"; then
14244     # Add extra search paths on solaris for utilities like ar and as etc...
14245     PATH="$PATH:/usr/ccs/bin:/usr/sfw/bin:/opt/csw/bin"
14246   fi
14247 
14248   # You can force the sys-root if the sys-root encoded into the cross compiler tools
14249   # is not correct.
14250 
14251 # Check whether --with-sys-root was given.
14252 if test "${with_sys_root+set}" = set; then :
14253   withval=$with_sys_root;
14254 fi
14255 
14256 
14257   if test "x$with_sys_root" != x; then
14258     SYS_ROOT=$with_sys_root
14259   else
14260     SYS_ROOT=/
14261   fi
14262 
14263 
14264 
14265 # Check whether --with-tools-dir was given.
14266 if test "${with_tools_dir+set}" = set; then :
14267   withval=$with_tools_dir; TOOLS_DIR=$with_tools_dir
14268 
14269 fi
14270 
14271 
14272 
14273 # Check whether --with-devkit was given.
14274 if test "${with_devkit+set}" = set; then :
14275   withval=$with_devkit;
14276         if test "x$with_sys_root" != x; then
14277           as_fn_error $? "Cannot specify both --with-devkit and --with-sys-root at the same time" "$LINENO" 5
14278         fi
14279 
14280   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
14281 
14282   # Input might be given as Windows format, start by converting to
14283   # unix format.
14284   path="$with_devkit"
14285   new_path=`$CYGPATH -u "$path"`
14286 
14287   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
14288   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
14289   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
14290   # "foo.exe" is OK but "foo" is an error.
14291   #
14292   # This test is therefore slightly more accurate than "test -f" to check for file precense.
14293   # It is also a way to make sure we got the proper file name for the real test later on.
14294   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
14295   if test "x$test_shortpath" = x; then
14296     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_devkit, which resolves as \"$path\", is invalid." >&5
14297 $as_echo "$as_me: The path of with_devkit, which resolves as \"$path\", is invalid." >&6;}
14298     as_fn_error $? "Cannot locate the the path of with_devkit" "$LINENO" 5


14381 
14382   else
14383     # We're on a posix platform. Hooray! :)
14384     path="$with_devkit"
14385     has_space=`$ECHO "$path" | $GREP " "`
14386     if test "x$has_space" != x; then
14387       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_devkit, which resolves as \"$path\", is invalid." >&5
14388 $as_echo "$as_me: The path of with_devkit, which resolves as \"$path\", is invalid." >&6;}
14389       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
14390     fi
14391 
14392     # Use eval to expand a potential ~
14393     eval path="$path"
14394     if test ! -f "$path" && test ! -d "$path"; then
14395       as_fn_error $? "The path of with_devkit, which resolves as \"$path\", is not found." "$LINENO" 5
14396     fi
14397 
14398     with_devkit="`cd "$path"; $THEPWDCMD -L`"
14399   fi
14400 






















14401 
14402   if test "x$TOOLS_DIR" = x; then
14403     TOOLS_DIR="$with_devkit/bin"

14404   else
14405     TOOLS_DIR="$TOOLS_DIR:$with_devkit/bin"



14406   fi
14407 
14408         if test -d "$with_devkit/$host_alias/libc"; then
14409           SYS_ROOT=$with_devkit/$host_alias/libc
14410         elif test -d "$with_devkit/$host/sys-root"; then
14411           SYS_ROOT=$with_devkit/$host/sys-root
14412         fi
14413 





























14414 fi
14415 
14416 
14417 





















































































14418   # Setup default logging of stdout and stderr to build.log in the output root.
14419   BUILD_LOG='$(OUTPUT_ROOT)/build.log'
14420   BUILD_LOG_PREVIOUS='$(OUTPUT_ROOT)/build.log.old'
14421   BUILD_LOG_WRAPPER='$(BASH) $(SRC_ROOT)/common/bin/logger.sh $(BUILD_LOG)'
14422 
14423 
14424 
14425 
14426 
14427 # Check if it's a pure open build or if custom sources are to be used.
14428 
14429   # Check whether --enable-openjdk-only was given.
14430 if test "${enable_openjdk_only+set}" = set; then :
14431   enableval=$enable_openjdk_only;
14432 else
14433   enable_openjdk_only="no"
14434 fi
14435 
14436 
14437   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for presence of closed sources" >&5


16090   if test "x$arguments" != xEOL; then
16091     new_complete="$new_path ${arguments% *}"
16092   else
16093     new_complete="$new_path"
16094   fi
16095 
16096   if test "x$complete" != "x$new_complete"; then
16097     FOUND_MAKE="$new_complete"
16098     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5
16099 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;}
16100   fi
16101 
16102         fi
16103       fi
16104     fi
16105   fi
16106 
16107     fi
16108 
16109     if test "x$FOUND_MAKE" = x; then
16110       if test "x$TOOLS_DIR" != x; then
16111         # We have a tools-dir, check that as well before giving up.
16112         OLD_PATH=$PATH
16113         PATH=$TOOLS_DIR:$PATH
16114         for ac_prog in gmake
16115 do
16116   # Extract the first word of "$ac_prog", so it can be a program name with args.
16117 set dummy $ac_prog; ac_word=$2
16118 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16119 $as_echo_n "checking for $ac_word... " >&6; }
16120 if ${ac_cv_path_CHECK_TOOLSDIR_GMAKE+:} false; then :
16121   $as_echo_n "(cached) " >&6
16122 else
16123   case $CHECK_TOOLSDIR_GMAKE in
16124   [\\/]* | ?:[\\/]*)
16125   ac_cv_path_CHECK_TOOLSDIR_GMAKE="$CHECK_TOOLSDIR_GMAKE" # Let the user override the test with a path.
16126   ;;
16127   *)
16128   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16129 for as_dir in $PATH
16130 do
16131   IFS=$as_save_IFS
16132   test -z "$as_dir" && as_dir=.
16133     for ac_exec_ext in '' $ac_executable_extensions; do


27328       { $as_echo "$as_me:${as_lineno-$LINENO}: Running the extraction script failed." >&5
27329 $as_echo "$as_me: Running the extraction script failed." >&6;}
27330     fi
27331     { $as_echo "$as_me:${as_lineno-$LINENO}: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&5
27332 $as_echo "$as_me: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&6;}
27333     { $as_echo "$as_me:${as_lineno-$LINENO}: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&5
27334 $as_echo "$as_me: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&6;}
27335     as_fn_error $? "Cannot continue" "$LINENO" 5
27336   fi
27337 
27338   fi
27339 
27340   # autoconf magic only relies on PATH, so update it if tools dir is specified
27341   OLD_PATH="$PATH"
27342 
27343   # For solaris we really need solaris tools, and not the GNU equivalent.
27344   # The build tools on Solaris reside in /usr/ccs (C Compilation System),
27345   # so add that to path before starting to probe.
27346   # FIXME: This was originally only done for AS,NM,GNM,STRIP,MCS,OBJCOPY,OBJDUMP.
27347   if test "x$OPENJDK_BUILD_OS" = xsolaris; then

27348     PATH="/usr/ccs/bin:$PATH"
27349   fi
27350 
27351   # Finally add TOOLS_DIR at the beginning, to allow --with-tools-dir to
27352   # override all other locations.
27353   if test "x$TOOLS_DIR" != x; then
27354     PATH=$TOOLS_DIR:$PATH
27355   fi
27356 
27357   # If a devkit is found on the builddeps server, then prepend its path to the
27358   # PATH variable. If there are cross compilers available in the devkit, these
27359   # will be found by AC_PROG_CC et al.
27360   DEVKIT=
27361 
27362 
27363   if test "x$with_builddeps_server" != x || test "x$with_builddeps_conf" != x; then
27364     # Source the builddeps file again, to make sure it uses the latest variables!
27365     . $builddepsfile
27366     # Look for a target and build machine specific resource!
27367     eval resource=\${builddep_devkit_BUILD_${rewritten_build_var}_TARGET_${rewritten_target_var}}
27368     if test "x$resource" = x; then
27369       # Ok, lets instead look for a target specific resource
27370       eval resource=\${builddep_devkit_TARGET_${rewritten_target_var}}
27371     fi
27372     if test "x$resource" = x; then
27373       # Ok, lets instead look for a build specific resource
27374       eval resource=\${builddep_devkit_BUILD_${rewritten_build_var}}
27375     fi
27376     if test "x$resource" = x; then
27377       # Ok, lets instead look for a generic resource
27378       # (The devkit comes from M4 and not the shell, thus no need for eval here.)
27379       resource=${builddep_devkit}
27380     fi
27381     if test "x$resource" != x; then
27382       { $as_echo "$as_me:${as_lineno-$LINENO}: Using builddeps $resource for devkit" >&5
27383 $as_echo "$as_me: Using builddeps $resource for devkit" >&6;}
27384       # If the resource in the builddeps.conf file is an existing directory,
27385       # for example /java/linux/cups
27386       if test -d ${resource}; then
27387         depdir=${resource}
27388       else
27389 
27390   # devkit is for example mymodule
27391   # $resource is for example libs/general/libmymod_1_2_3.zip
27392   # $with_builddeps_server is for example ftp://mybuilddeps.myserver.com/builddeps
27393   # $with_builddeps_dir is for example /localhome/builddeps
27394   # depdir is the name of the variable into which we store the depdir, eg MYMOD
27395   # Will download ftp://mybuilddeps.myserver.com/builddeps/libs/general/libmymod_1_2_3.zip and
27396   # unzip into the directory: /localhome/builddeps/libmymod_1_2_3
27397   filename=`basename $resource`
27398   filebase=`echo $filename | sed 's/\.[^\.]*$//'`
27399   filebase=${filename%%.*}
27400   extension=${filename#*.}
27401   installdir=$with_builddeps_dir/$filebase
27402   if test ! -f $installdir/$filename.unpacked; then
27403     { $as_echo "$as_me:${as_lineno-$LINENO}: Downloading build dependency devkit from $with_builddeps_server/$resource and installing into $installdir" >&5
27404 $as_echo "$as_me: Downloading build dependency devkit from $with_builddeps_server/$resource and installing into $installdir" >&6;}
27405     if test ! -d $installdir; then
27406       mkdir -p $installdir
27407     fi
27408     if test ! -d $installdir; then
27409       as_fn_error $? "Could not create directory $installdir" "$LINENO" 5
27410     fi
27411     tmpfile=`mktemp $installdir/devkit.XXXXXXXXX`
27412     touch $tmpfile
27413     if test ! -f $tmpfile; then
27414       as_fn_error $? "Could not create files in directory $installdir" "$LINENO" 5
27415     fi
27416 
27417   # $with_builddeps_server/$resource  is the ftp://abuilddeps.server.com/libs/cups.zip
27418   # $tmpfile is the local file name for the downloaded file.
27419   VALID_TOOL=no
27420   if test "x$BDEPS_FTP" = xwget; then
27421     VALID_TOOL=yes
27422     wget -O $tmpfile $with_builddeps_server/$resource
27423   fi
27424   if test "x$BDEPS_FTP" = xlftp; then
27425     VALID_TOOL=yes
27426     lftp -c "get $with_builddeps_server/$resource  -o $tmpfile"
27427   fi
27428   if test "x$BDEPS_FTP" = xftp; then
27429     VALID_TOOL=yes
27430     FTPSERVER=`echo $with_builddeps_server/$resource  | cut -f 3 -d '/'`
27431     FTPPATH=`echo $with_builddeps_server/$resource  | cut -f 4- -d '/'`
27432     FTPUSERPWD=${FTPSERVER%%@*}
27433     if test "x$FTPSERVER" != "x$FTPUSERPWD"; then
27434       FTPUSER=${userpwd%%:*}
27435       FTPPWD=${userpwd#*@}
27436       FTPSERVER=${FTPSERVER#*@}
27437     else
27438       FTPUSER=ftp
27439       FTPPWD=ftp
27440     fi
27441     # the "pass" command does not work on some
27442     # ftp clients (read ftp.exe) but if it works,
27443     # passive mode is better!
27444     ( \
27445         echo "user $FTPUSER $FTPPWD"        ; \
27446         echo "pass"                         ; \
27447         echo "bin"                          ; \
27448         echo "get $FTPPATH $tmpfile"              ; \
27449     ) | ftp -in $FTPSERVER
27450   fi
27451   if test "x$VALID_TOOL" != xyes; then
27452     as_fn_error $? "I do not know how to use the tool: $BDEPS_FTP" "$LINENO" 5
27453   fi
27454 
27455     mv $tmpfile $installdir/$filename
27456     if test ! -s $installdir/$filename; then
27457       as_fn_error $? "Could not download $with_builddeps_server/$resource" "$LINENO" 5
27458     fi
27459     case "$extension" in
27460       zip)  echo "Unzipping $installdir/$filename..."
27461         (cd $installdir ; rm -f $installdir/$filename.unpacked ; $BDEPS_UNZIP $installdir/$filename > /dev/null && touch $installdir/$filename.unpacked)
27462         ;;
27463       tar.gz) echo "Untaring $installdir/$filename..."
27464         (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
27465         ;;
27466       tgz) echo "Untaring $installdir/$filename..."
27467         (cd $installdir ; rm -f $installdir/$filename.unpacked ; tar xzf $installdir/$filename && touch $installdir/$filename.unpacked)
27468         ;;
27469       *) as_fn_error $? "Cannot handle build depency archive with extension $extension" "$LINENO" 5
27470         ;;
27471     esac
27472   fi
27473   if test -f $installdir/$filename.unpacked; then
27474     depdir=$installdir
27475   fi
27476 
27477       fi
27478       # Source the builddeps file again, because in the previous command, the depdir
27479       # was updated to point at the current build dependency install directory.
27480       . $builddepsfile
27481       # Now extract variables from the builddeps.conf files.
27482       theroot=${builddep_devkit_ROOT}
27483       thecflags=${builddep_devkit_CFLAGS}
27484       thelibs=${builddep_devkit_LIBS}
27485       if test "x$depdir" = x; then
27486         as_fn_error $? "Could not download build dependency devkit" "$LINENO" 5
27487       fi
27488       DEVKIT=$depdir
27489       if test "x$theroot" != x; then
27490         DEVKIT="$theroot"
27491       fi
27492       if test "x$thecflags" != x; then
27493         DEVKIT_CFLAGS="$thecflags"
27494       fi
27495       if test "x$thelibs" != x; then
27496         DEVKIT_LIBS="$thelibs"
27497       fi
27498 
27499         # Found devkit
27500         PATH="$DEVKIT/bin:$PATH"
27501         SYS_ROOT="$DEVKIT/${rewritten_target}/sys-root"
27502         if test "x$x_includes" = "xNONE"; then
27503           x_includes="$SYS_ROOT/usr/include/X11"
27504         fi
27505         if test "x$x_libraries" = "xNONE"; then
27506           x_libraries="$SYS_ROOT/usr/lib"
27507         fi
27508 
27509 
27510     fi
27511 




27512   fi
27513 
27514 
27515 
27516   #
27517   # Setup the compilers (CC and CXX)
27518   #
27519 
27520   COMPILER_NAME=C
27521   SEARCH_LIST="$TOOLCHAIN_CC_BINARY"
27522 
27523   if test "x$CC" != x; then
27524     # User has supplied compiler name already, always let that override.
27525     { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied compiler CC=$CC" >&5
27526 $as_echo "$as_me: Will use user supplied compiler CC=$CC" >&6;}
27527     if test "x`basename $CC`" = "x$CC"; then
27528       # A command without a complete path is provided, search $PATH.
27529 
27530       for ac_prog in $CC
27531 do
27532   # Extract the first word of "$ac_prog", so it can be a program name with args.
27533 set dummy $ac_prog; ac_word=$2
27534 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27535 $as_echo_n "checking for $ac_word... " >&6; }


27577       else
27578         as_fn_error $? "User supplied compiler CC=$CC could not be found" "$LINENO" 5
27579       fi
27580     else
27581       # Otherwise it might already be a complete path
27582       if test ! -x "$CC"; then
27583         as_fn_error $? "User supplied compiler CC=$CC does not exist" "$LINENO" 5
27584       fi
27585     fi
27586   else
27587     # No user supplied value. Locate compiler ourselves.
27588 
27589     # If we are cross compiling, assume cross compilation tools follows the
27590     # cross compilation standard where they are prefixed with the autoconf
27591     # standard name for the target. For example the binary
27592     # i686-sun-solaris2.10-gcc will cross compile for i686-sun-solaris2.10.
27593     # If we are not cross compiling, then the default compiler name will be
27594     # used.
27595 
27596     CC=
27597     # If TOOLS_DIR is set, check for all compiler names in there first
27598     # before checking the rest of the PATH.
27599     # FIXME: Now that we prefix the TOOLS_DIR to the PATH in the PRE_DETECTION
27600     # step, this should not be necessary.
27601     if test -n "$TOOLS_DIR"; then
27602       PATH_save="$PATH"
27603       PATH="$TOOLS_DIR"
27604       for ac_prog in $SEARCH_LIST
27605 do
27606   # Extract the first word of "$ac_prog", so it can be a program name with args.
27607 set dummy $ac_prog; ac_word=$2
27608 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27609 $as_echo_n "checking for $ac_word... " >&6; }
27610 if ${ac_cv_path_TOOLS_DIR_CC+:} false; then :
27611   $as_echo_n "(cached) " >&6
27612 else
27613   case $TOOLS_DIR_CC in
27614   [\\/]* | ?:[\\/]*)
27615   ac_cv_path_TOOLS_DIR_CC="$TOOLS_DIR_CC" # Let the user override the test with a path.
27616   ;;
27617   *)
27618   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27619 for as_dir in $PATH
27620 do
27621   IFS=$as_save_IFS
27622   test -z "$as_dir" && as_dir=.
27623     for ac_exec_ext in '' $ac_executable_extensions; do
27624   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
27625     ac_cv_path_TOOLS_DIR_CC="$as_dir/$ac_word$ac_exec_ext"
27626     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
27627     break 2
27628   fi
27629 done
27630   done
27631 IFS=$as_save_IFS
27632 
27633   ;;
27634 esac
27635 fi
27636 TOOLS_DIR_CC=$ac_cv_path_TOOLS_DIR_CC
27637 if test -n "$TOOLS_DIR_CC"; then
27638   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLS_DIR_CC" >&5
27639 $as_echo "$TOOLS_DIR_CC" >&6; }
27640 else
27641   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27642 $as_echo "no" >&6; }
27643 fi
27644 
27645 
27646   test -n "$TOOLS_DIR_CC" && break
27647 done
27648 
27649       CC=$TOOLS_DIR_CC
27650       PATH="$PATH_save"
27651     fi
27652 
27653     # AC_PATH_PROGS can't be run multiple times with the same variable,
27654     # so create a new name for this run.
27655     if test "x$CC" = x; then
27656       for ac_prog in $SEARCH_LIST
27657 do
27658   # Extract the first word of "$ac_prog", so it can be a program name with args.
27659 set dummy $ac_prog; ac_word=$2
27660 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27661 $as_echo_n "checking for $ac_word... " >&6; }
27662 if ${ac_cv_path_POTENTIAL_CC+:} false; then :
27663   $as_echo_n "(cached) " >&6
27664 else
27665   case $POTENTIAL_CC in
27666   [\\/]* | ?:[\\/]*)
27667   ac_cv_path_POTENTIAL_CC="$POTENTIAL_CC" # Let the user override the test with a path.
27668   ;;
27669   *)


29283       else
29284         as_fn_error $? "User supplied compiler CXX=$CXX could not be found" "$LINENO" 5
29285       fi
29286     else
29287       # Otherwise it might already be a complete path
29288       if test ! -x "$CXX"; then
29289         as_fn_error $? "User supplied compiler CXX=$CXX does not exist" "$LINENO" 5
29290       fi
29291     fi
29292   else
29293     # No user supplied value. Locate compiler ourselves.
29294 
29295     # If we are cross compiling, assume cross compilation tools follows the
29296     # cross compilation standard where they are prefixed with the autoconf
29297     # standard name for the target. For example the binary
29298     # i686-sun-solaris2.10-gcc will cross compile for i686-sun-solaris2.10.
29299     # If we are not cross compiling, then the default compiler name will be
29300     # used.
29301 
29302     CXX=
29303     # If TOOLS_DIR is set, check for all compiler names in there first
29304     # before checking the rest of the PATH.
29305     # FIXME: Now that we prefix the TOOLS_DIR to the PATH in the PRE_DETECTION
29306     # step, this should not be necessary.
29307     if test -n "$TOOLS_DIR"; then
29308       PATH_save="$PATH"
29309       PATH="$TOOLS_DIR"
29310       for ac_prog in $SEARCH_LIST
29311 do
29312   # Extract the first word of "$ac_prog", so it can be a program name with args.
29313 set dummy $ac_prog; ac_word=$2
29314 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
29315 $as_echo_n "checking for $ac_word... " >&6; }
29316 if ${ac_cv_path_TOOLS_DIR_CXX+:} false; then :
29317   $as_echo_n "(cached) " >&6
29318 else
29319   case $TOOLS_DIR_CXX in
29320   [\\/]* | ?:[\\/]*)
29321   ac_cv_path_TOOLS_DIR_CXX="$TOOLS_DIR_CXX" # Let the user override the test with a path.
29322   ;;
29323   *)
29324   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29325 for as_dir in $PATH
29326 do
29327   IFS=$as_save_IFS
29328   test -z "$as_dir" && as_dir=.
29329     for ac_exec_ext in '' $ac_executable_extensions; do
29330   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
29331     ac_cv_path_TOOLS_DIR_CXX="$as_dir/$ac_word$ac_exec_ext"
29332     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
29333     break 2
29334   fi
29335 done
29336   done
29337 IFS=$as_save_IFS
29338 
29339   ;;
29340 esac
29341 fi
29342 TOOLS_DIR_CXX=$ac_cv_path_TOOLS_DIR_CXX
29343 if test -n "$TOOLS_DIR_CXX"; then
29344   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLS_DIR_CXX" >&5
29345 $as_echo "$TOOLS_DIR_CXX" >&6; }
29346 else
29347   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
29348 $as_echo "no" >&6; }
29349 fi
29350 
29351 
29352   test -n "$TOOLS_DIR_CXX" && break
29353 done
29354 
29355       CXX=$TOOLS_DIR_CXX
29356       PATH="$PATH_save"
29357     fi
29358 
29359     # AC_PATH_PROGS can't be run multiple times with the same variable,
29360     # so create a new name for this run.
29361     if test "x$CXX" = x; then
29362       for ac_prog in $SEARCH_LIST
29363 do
29364   # Extract the first word of "$ac_prog", so it can be a program name with args.
29365 set dummy $ac_prog; ac_word=$2
29366 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
29367 $as_echo_n "checking for $ac_word... " >&6; }
29368 if ${ac_cv_path_POTENTIAL_CXX+:} false; then :
29369   $as_echo_n "(cached) " >&6
29370 else
29371   case $POTENTIAL_CXX in
29372   [\\/]* | ?:[\\/]*)
29373   ac_cv_path_POTENTIAL_CXX="$POTENTIAL_CXX" # Let the user override the test with a path.
29374   ;;
29375   *)


40743     # in a custom configure script, or possibly the command line.
40744     # Let those variables be expanded at make time in spec.gmk.
40745     # The \$ are escaped to the shell, and the $(...) variables
40746     # are evaluated by make.
40747     RC_FLAGS="$RC_FLAGS \
40748         -d \"JDK_BUILD_ID=\$(FULL_VERSION)\" \
40749         -d \"JDK_COMPANY=\$(COMPANY_NAME)\" \
40750         -d \"JDK_COMPONENT=\$(PRODUCT_NAME) \$(JDK_RC_PLATFORM_NAME) binary\" \
40751         -d \"JDK_VER=\$(JDK_MINOR_VERSION).\$(JDK_MICRO_VERSION).\$(if \$(JDK_UPDATE_VERSION),\$(JDK_UPDATE_VERSION),0).\$(COOKED_BUILD_NUMBER)\" \
40752         -d \"JDK_COPYRIGHT=Copyright \xA9 $COPYRIGHT_YEAR\" \
40753         -d \"JDK_NAME=\$(PRODUCT_NAME) \$(JDK_RC_PLATFORM_NAME) \$(JDK_MINOR_VERSION) \$(JDK_UPDATE_META_TAG)\" \
40754         -d \"JDK_FVER=\$(JDK_MINOR_VERSION),\$(JDK_MICRO_VERSION),\$(if \$(JDK_UPDATE_VERSION),\$(JDK_UPDATE_VERSION),0),\$(COOKED_BUILD_NUMBER)\""
40755   fi
40756 
40757 
40758   if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
40759     # FIXME: likely bug, should be CCXXFLAGS_JDK? or one for C or CXX.
40760     CCXXFLAGS="$CCXXFLAGS -nologo"
40761   fi
40762 
























40763 
40764 # FIXME: Currently we must test this after toolchain but before flags. Fix!
40765 
40766 # Now we can test some aspects on the target using configure macros.
40767 
40768 
40769 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
40770 $as_echo_n "checking for ANSI C header files... " >&6; }
40771 if ${ac_cv_header_stdc+:} false; then :
40772   $as_echo_n "(cached) " >&6
40773 else
40774   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40775 /* end confdefs.h.  */
40776 #include <stdlib.h>
40777 #include <stdarg.h>
40778 #include <string.h>
40779 #include <float.h>
40780 
40781 int
40782 main ()


41591 
41592 
41593 # Check whether --with-extra-cxxflags was given.
41594 if test "${with_extra_cxxflags+set}" = set; then :
41595   withval=$with_extra_cxxflags;
41596 fi
41597 
41598 
41599 
41600 # Check whether --with-extra-ldflags was given.
41601 if test "${with_extra_ldflags+set}" = set; then :
41602   withval=$with_extra_ldflags;
41603 fi
41604 
41605 
41606   CFLAGS_JDK="${CFLAGS_JDK} $with_extra_cflags"
41607   CXXFLAGS_JDK="${CXXFLAGS_JDK} $with_extra_cxxflags"
41608   LDFLAGS_JDK="${LDFLAGS_JDK} $with_extra_ldflags"
41609 
41610   # Hotspot needs these set in their legacy form
41611   LEGACY_EXTRA_CFLAGS=$with_extra_cflags
41612   LEGACY_EXTRA_CXXFLAGS=$with_extra_cxxflags
41613   LEGACY_EXTRA_LDFLAGS=$with_extra_ldflags
41614 
41615 
41616 
41617 
41618 
41619   ###############################################################################
41620   #
41621   # Now setup the CFLAGS and LDFLAGS for the JDK build.
41622   # Later we will also have CFLAGS and LDFLAGS for the hotspot subrepo build.
41623   #
41624 
41625   # Setup compiler/platform specific flags to CFLAGS_JDK,
41626   # CXXFLAGS_JDK and CCXXFLAGS_JDK (common to C and CXX?)
41627   if test "x$TOOLCHAIN_TYPE" = xgcc; then
41628     # these options are used for both C and C++ compiles
41629     CCXXFLAGS_JDK="$CCXXFLAGS $CCXXFLAGS_JDK -Wall -Wno-parentheses -Wextra -Wno-unused -Wno-unused-parameter -Wformat=2 \
41630         -pipe -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE"
41631     case $OPENJDK_TARGET_CPU_ARCH in
41632       arm )
41633         # on arm we don't prevent gcc to omit frame pointer but do prevent strict aliasing


41691 
41692   # Setup LP64
41693   CCXXFLAGS_JDK="$CCXXFLAGS_JDK $ADD_LP64"
41694 
41695   # Set some common defines. These works for all compilers, but assume
41696   # -D is universally accepted.
41697 
41698   # Setup endianness
41699   if test "x$OPENJDK_TARGET_CPU_ENDIAN" = xlittle; then
41700     # The macro _LITTLE_ENDIAN needs to be defined the same to avoid the
41701     #   Sun C compiler warning message: warning: macro redefined: _LITTLE_ENDIAN
41702     #   (The Solaris X86 system defines this in file /usr/include/sys/isa_defs.h).
41703     #   Note: -Dmacro         is the same as    #define macro 1
41704     #         -Dmacro=        is the same as    #define macro
41705     if test "x$OPENJDK_TARGET_OS" = xsolaris; then
41706       CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_LITTLE_ENDIAN="
41707     else
41708       CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_LITTLE_ENDIAN"
41709     fi
41710   else





41711     CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_BIG_ENDIAN"
41712   fi

41713 
41714   # Setup target OS define. Use OS target name but in upper case.
41715   OPENJDK_TARGET_OS_UPPERCASE=`$ECHO $OPENJDK_TARGET_OS | $TR 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
41716   CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D$OPENJDK_TARGET_OS_UPPERCASE"
41717 
41718   # Setup target CPU
41719   CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DARCH='\"$OPENJDK_TARGET_CPU_LEGACY\"' -D$OPENJDK_TARGET_CPU_LEGACY"
41720 
41721   # Setup debug/release defines
41722   if test "x$DEBUG_LEVEL" = xrelease; then
41723     CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DNDEBUG"
41724     if test "x$OPENJDK_TARGET_OS" = xsolaris; then
41725       CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DTRIMMED"
41726     fi
41727   else
41728     CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DDEBUG"
41729   fi
41730 
41731   # Setup release name
41732   CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DRELEASE='\"\$(RELEASE)\"'"


42254   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Mac OS X Java Framework" >&5
42255 $as_echo_n "checking for Mac OS X Java Framework... " >&6; }
42256   if test -f /System/Library/Frameworks/JavaVM.framework/Frameworks/JavaRuntimeSupport.framework/Headers/JavaRuntimeSupport.h; then
42257     { $as_echo "$as_me:${as_lineno-$LINENO}: result: /System/Library/Frameworks/JavaVM.framework" >&5
42258 $as_echo "/System/Library/Frameworks/JavaVM.framework" >&6; }
42259   else
42260     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
42261 $as_echo "no" >&6; }
42262   fi
42263 
42264 
42265 
42266   ###############################################################################
42267   #
42268   # Check for X Windows
42269   #
42270 
42271   # Check if the user has specified sysroot, but not --x-includes or --x-libraries.
42272   # Make a simple check for the libraries at the sysroot, and setup --x-includes and
42273   # --x-libraries for the sysroot, if that seems to be correct.
42274   if test "x$SYS_ROOT" != "x/"; then

42275     if test "x$x_includes" = xNONE; then
42276       if test -f "$SYS_ROOT/usr/X11R6/include/X11/Xlib.h"; then
42277         x_includes="$SYS_ROOT/usr/X11R6/include"
42278       elif test -f "$SYS_ROOT/usr/include/X11/Xlib.h"; then
42279         x_includes="$SYS_ROOT/usr/include"
42280       fi
42281     fi
42282     if test "x$x_libraries" = xNONE; then
42283       if test -f "$SYS_ROOT/usr/X11R6/lib/libX11.so"; then
42284         x_libraries="$SYS_ROOT/usr/X11R6/lib"
42285       elif test "$SYS_ROOT/usr/lib64/libX11.so" && test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
42286         x_libraries="$SYS_ROOT/usr/lib64"
42287       elif test -f "$SYS_ROOT/usr/lib/libX11.so"; then
42288         x_libraries="$SYS_ROOT/usr/lib"

42289       fi
42290     fi
42291   fi
42292 
42293   # Now let autoconf do it's magic
42294   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5
42295 $as_echo_n "checking for X... " >&6; }
42296 
42297 
42298 # Check whether --with-x was given.
42299 if test "${with_x+set}" = set; then :
42300   withval=$with_x;
42301 fi
42302 
42303 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
42304 if test "x$with_x" = xno; then
42305   # The user explicitly disabled X.
42306   have_x=disabled
42307 else
42308   case $x_includes,$x_libraries in #(


42999         apt_help     $MISSING_DEPENDENCY ;;
43000       yum)
43001         yum_help     $MISSING_DEPENDENCY ;;
43002       port)
43003         port_help    $MISSING_DEPENDENCY ;;
43004       pkgutil)
43005         pkgutil_help $MISSING_DEPENDENCY ;;
43006       pkgadd)
43007         pkgadd_help  $MISSING_DEPENDENCY ;;
43008     esac
43009 
43010     if test "x$PKGHANDLER_COMMAND" != x; then
43011       HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
43012     fi
43013   fi
43014 
43015     as_fn_error $? "Could not find X11 libraries. $HELP_MSG" "$LINENO" 5
43016   fi
43017 
43018   if test "x$OPENJDK_TARGET_OS" = xsolaris; then
43019     OPENWIN_HOME="/usr/openwin"





43020   fi
43021 
43022 
43023 
43024   #
43025   # Weird Sol10 something check...TODO change to try compile
43026   #
43027   if test "x${OPENJDK_TARGET_OS}" = xsolaris; then
43028     if test "`uname -r`" = "5.10"; then
43029       if test "`${EGREP} -c XLinearGradient ${OPENWIN_HOME}/share/include/X11/extensions/Xrender.h`" = "0"; then
43030         X_CFLAGS="${X_CFLAGS} -DSOLARIS10_NO_XRENDER_STRUCTS"
43031       fi
43032     fi
43033   fi
43034 
43035   ac_ext=c
43036 ac_cpp='$CPP $CPPFLAGS'
43037 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
43038 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
43039 ac_compiler_gnu=$ac_cv_c_compiler_gnu
43040 
43041   OLD_CFLAGS="$CFLAGS"
43042   CFLAGS="$CFLAGS $X_CFLAGS"
43043 


43302 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
43303   cat >>confdefs.h <<_ACEOF
43304 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
43305 _ACEOF
43306 
43307             CUPS_FOUND=yes
43308             CUPS_CFLAGS=
43309             DEFAULT_CUPS=yes
43310 
43311 
43312 fi
43313 
43314 done
43315 
43316     fi
43317     if test "x$CUPS_FOUND" = xno; then
43318       # Getting nervous now? Lets poke around for standard Solaris third-party
43319       # package installation locations.
43320       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cups headers" >&5
43321 $as_echo_n "checking for cups headers... " >&6; }
43322       if test -s /opt/sfw/cups/include/cups/cups.h; then
43323         # An SFW package seems to be installed!
43324         CUPS_FOUND=yes
43325         CUPS_CFLAGS="-I/opt/sfw/cups/include"
43326       elif test -s /opt/csw/include/cups/cups.h; then
43327         # A CSW package seems to be installed!
43328         CUPS_FOUND=yes
43329         CUPS_CFLAGS="-I/opt/csw/include"
43330       fi
43331       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUPS_FOUND" >&5
43332 $as_echo "$CUPS_FOUND" >&6; }
43333     fi
43334     if test "x$CUPS_FOUND" = xno; then
43335 
43336   # Print a helpful message on how to acquire the necessary build dependency.
43337   # cups is the help tag: freetype, cups, pulse, alsa etc
43338   MISSING_DEPENDENCY=cups
43339 
43340   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
43341     cygwin_help $MISSING_DEPENDENCY
43342   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
43343     msys_help $MISSING_DEPENDENCY
43344   else
43345     PKGHANDLER_COMMAND=
43346 
43347     case $PKGHANDLER in
43348       apt-get)
43349         apt_help     $MISSING_DEPENDENCY ;;


43902     fi
43903     else FOUND_FREETYPE=no
43904 
43905   fi
43906 
43907         # BDEPS_CHECK_MODULE will set FREETYPE_CFLAGS and _LIBS, but we don't get a lib path for bundling.
43908         if test "x$FOUND_FREETYPE" = xyes; then
43909           if test "x$BUNDLE_FREETYPE" = xyes; then
43910             { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype using builddeps, but ignoring since we can not bundle that" >&5
43911 $as_echo "$as_me: Found freetype using builddeps, but ignoring since we can not bundle that" >&6;}
43912             FOUND_FREETYPE=no
43913           else
43914             { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype" >&5
43915 $as_echo_n "checking for freetype... " >&6; }
43916             { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (using builddeps)" >&5
43917 $as_echo "yes (using builddeps)" >&6; }
43918           fi
43919         fi
43920       fi
43921 


43922       if test "x$FOUND_FREETYPE" != xyes; then
43923         # Check modules using pkg-config, but only if we have it (ugly output results otherwise)
43924         if test "x$PKG_CONFIG" != x; then
43925 
43926 pkg_failed=no
43927 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FREETYPE" >&5
43928 $as_echo_n "checking for FREETYPE... " >&6; }
43929 
43930 if test -n "$FREETYPE_CFLAGS"; then
43931     pkg_cv_FREETYPE_CFLAGS="$FREETYPE_CFLAGS"
43932  elif test -n "$PKG_CONFIG"; then
43933     if test -n "$PKG_CONFIG" && \
43934     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"freetype2\""; } >&5
43935   ($PKG_CONFIG --exists --print-errors "freetype2") 2>&5
43936   ac_status=$?
43937   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
43938   test $ac_status = 0; }; then
43939   pkg_cv_FREETYPE_CFLAGS=`$PKG_CONFIG --cflags "freetype2" 2>/dev/null`
43940 else
43941   pkg_failed=yes


43993             # On solaris, pkg_check adds -lz to freetype libs, which isn't necessary for us.
43994             FREETYPE_LIBS=`$ECHO $FREETYPE_LIBS | $SED 's/-lz//g'`
43995             # 64-bit libs for Solaris x86 are installed in the amd64 subdirectory, change lib to lib/amd64
43996             if test "x$OPENJDK_TARGET_OS" = xsolaris && test "x$OPENJDK_TARGET_CPU" = xx86_64; then
43997               FREETYPE_LIBS=`$ECHO $FREETYPE_LIBS | $SED 's?/lib?/lib/amd64?g'`
43998             fi
43999             # BDEPS_CHECK_MODULE will set FREETYPE_CFLAGS and _LIBS, but we don't get a lib path for bundling.
44000             if test "x$BUNDLE_FREETYPE" = xyes; then
44001               { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype using pkg-config, but ignoring since we can not bundle that" >&5
44002 $as_echo "$as_me: Found freetype using pkg-config, but ignoring since we can not bundle that" >&6;}
44003               FOUND_FREETYPE=no
44004             else
44005               { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype" >&5
44006 $as_echo_n "checking for freetype... " >&6; }
44007               { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (using pkg-config)" >&5
44008 $as_echo "yes (using pkg-config)" >&6; }
44009             fi
44010           fi
44011         fi
44012       fi

44013 
44014       if test "x$FOUND_FREETYPE" != xyes; then
44015         # Check in well-known locations
44016         if test "x$OPENJDK_TARGET_OS" = xwindows; then
44017           FREETYPE_BASE_DIR="$PROGRAMFILES/GnuWin32"
44018 
44019   windows_path="$FREETYPE_BASE_DIR"
44020   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44021     unix_path=`$CYGPATH -u "$windows_path"`
44022     FREETYPE_BASE_DIR="$unix_path"
44023   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44024     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44025     FREETYPE_BASE_DIR="$unix_path"
44026   fi
44027 
44028 
44029   POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
44030   POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib"
44031   METHOD="well-known location"
44032 


44602     fi
44603 
44604     POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
44605   fi
44606 
44607 
44608     FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44609     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
44610 $as_echo_n "checking for freetype includes... " >&6; }
44611     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
44612 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
44613     FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
44614     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
44615 $as_echo_n "checking for freetype libraries... " >&6; }
44616     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
44617 $as_echo "$FREETYPE_LIB_PATH" >&6; }
44618   fi
44619 
44620           fi
44621         else
44622           if test "x$SYS_ROOT" = "x/"; then
44623             FREETYPE_ROOT=

































































































































































































































































44624           else
44625             FREETYPE_ROOT="$SYS_ROOT"






44626           fi
44627           FREETYPE_BASE_DIR="$FREETYPE_ROOT/usr"

























44628 
44629   POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
44630   POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib"
44631   METHOD="well-known location"
44632 
44633   # First check if the files exists.
44634   if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
44635     # We found an arbitrary include file. That's a good sign.
44636     { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
44637 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
44638     FOUND_FREETYPE=yes
44639 
44640     FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
44641     if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
44642       { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
44643 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
44644       FOUND_FREETYPE=no
44645     else
44646       if test "x$OPENJDK_TARGET_OS" = xwindows; then
44647         # On Windows, we will need both .lib and .dll file.


44898     if test ! -f "$path" && test ! -d "$path"; then
44899       as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
44900     fi
44901 
44902     POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
44903   fi
44904 
44905 
44906     FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44907     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
44908 $as_echo_n "checking for freetype includes... " >&6; }
44909     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
44910 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
44911     FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
44912     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
44913 $as_echo_n "checking for freetype libraries... " >&6; }
44914     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
44915 $as_echo "$FREETYPE_LIB_PATH" >&6; }
44916   fi
44917 

44918 
44919           if test "x$FOUND_FREETYPE" != xyes; then
44920             FREETYPE_BASE_DIR="$FREETYPE_ROOT/usr/X11"
44921 
44922   POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
44923   POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib"
44924   METHOD="well-known location"
44925 
44926   # First check if the files exists.
44927   if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
44928     # We found an arbitrary include file. That's a good sign.
44929     { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
44930 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
44931     FOUND_FREETYPE=yes
44932 
44933     FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
44934     if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
44935       { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
44936 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
44937       FOUND_FREETYPE=no
44938     else
44939       if test "x$OPENJDK_TARGET_OS" = xwindows; then
44940         # On Windows, we will need both .lib and .dll file.


45194 
45195     POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
45196   fi
45197 
45198 
45199     FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45200     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
45201 $as_echo_n "checking for freetype includes... " >&6; }
45202     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
45203 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
45204     FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
45205     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
45206 $as_echo_n "checking for freetype libraries... " >&6; }
45207     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
45208 $as_echo "$FREETYPE_LIB_PATH" >&6; }
45209   fi
45210 
45211           fi
45212 
45213           if test "x$FOUND_FREETYPE" != xyes; then
45214             FREETYPE_BASE_DIR="$FREETYPE_ROOT/usr"
45215             if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
45216 
45217   POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
45218   POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib/x86_64-linux-gnu"
45219   METHOD="well-known location"
45220 
45221   # First check if the files exists.
45222   if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
45223     # We found an arbitrary include file. That's a good sign.
45224     { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
45225 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
45226     FOUND_FREETYPE=yes
45227 
45228     FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
45229     if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
45230       { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
45231 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
45232       FOUND_FREETYPE=no
45233     else
45234       if test "x$OPENJDK_TARGET_OS" = xwindows; then


46670       fi
46671       ALSA=$depdir
46672       if test "x$theroot" != x; then
46673         ALSA="$theroot"
46674       fi
46675       if test "x$thecflags" != x; then
46676         ALSA_CFLAGS="$thecflags"
46677       fi
46678       if test "x$thelibs" != x; then
46679         ALSA_LIBS="$thelibs"
46680       fi
46681       ALSA_FOUND=yes
46682       else ALSA_FOUND=no
46683 
46684     fi
46685     else ALSA_FOUND=no
46686 
46687   fi
46688 
46689     fi


46690     if test "x$ALSA_FOUND" = xno; then
46691 
46692 pkg_failed=no
46693 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ALSA" >&5
46694 $as_echo_n "checking for ALSA... " >&6; }
46695 
46696 if test -n "$ALSA_CFLAGS"; then
46697     pkg_cv_ALSA_CFLAGS="$ALSA_CFLAGS"
46698  elif test -n "$PKG_CONFIG"; then
46699     if test -n "$PKG_CONFIG" && \
46700     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"alsa\""; } >&5
46701   ($PKG_CONFIG --exists --print-errors "alsa") 2>&5
46702   ac_status=$?
46703   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
46704   test $ac_status = 0; }; then
46705   pkg_cv_ALSA_CFLAGS=`$PKG_CONFIG --cflags "alsa" 2>/dev/null`
46706 else
46707   pkg_failed=yes
46708 fi
46709  else


46739                 ALSA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "alsa" 2>&1`
46740         else
46741                 ALSA_PKG_ERRORS=`$PKG_CONFIG --print-errors "alsa" 2>&1`
46742         fi
46743         # Put the nasty error message in config.log where it belongs
46744         echo "$ALSA_PKG_ERRORS" >&5
46745 
46746         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
46747 $as_echo "no" >&6; }
46748                 ALSA_FOUND=no
46749 elif test $pkg_failed = untried; then
46750         ALSA_FOUND=no
46751 else
46752         ALSA_CFLAGS=$pkg_cv_ALSA_CFLAGS
46753         ALSA_LIBS=$pkg_cv_ALSA_LIBS
46754         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
46755 $as_echo "yes" >&6; }
46756         ALSA_FOUND=yes
46757 fi
46758     fi

46759     if test "x$ALSA_FOUND" = xno; then
46760       for ac_header in alsa/asoundlib.h
46761 do :
46762   ac_fn_cxx_check_header_mongrel "$LINENO" "alsa/asoundlib.h" "ac_cv_header_alsa_asoundlib_h" "$ac_includes_default"
46763 if test "x$ac_cv_header_alsa_asoundlib_h" = xyes; then :
46764   cat >>confdefs.h <<_ACEOF
46765 #define HAVE_ALSA_ASOUNDLIB_H 1
46766 _ACEOF
46767 
46768             ALSA_FOUND=yes
46769             ALSA_CFLAGS=-Iignoreme
46770             ALSA_LIBS=-lasound
46771             DEFAULT_ALSA=yes
46772 
46773 else
46774   ALSA_FOUND=no
46775 fi
46776 
46777 done
46778 


47617       fi
47618     done
47619 
47620     unset LLVM_LIBS
47621     for flag in $("${LLVM_CONFIG}" --libs ${llvm_components}); do
47622       if echo "${flag}" | grep -q '^-l'; then
47623         if test "${LLVM_LIBS}" != ""; then
47624           LLVM_LIBS="${LLVM_LIBS} "
47625         fi
47626         LLVM_LIBS="${LLVM_LIBS}${flag}"
47627       fi
47628     done
47629 
47630 
47631 
47632 
47633   fi
47634 
47635   # libCrun is the c++ runtime-library with SunStudio (roughly the equivalent of gcc's libstdc++.so)
47636   if test "x$TOOLCHAIN_TYPE" = xsolstudio && test "x$LIBCXX" = x; then
47637     LIBCXX="/usr/lib${OPENJDK_TARGET_CPU_ISADIR}/libCrun.so.1"
47638   fi
47639 
47640   # TODO better (platform agnostic) test
47641   if test "x$OPENJDK_TARGET_OS" = xmacosx && test "x$LIBCXX" = x && test "x$TOOLCHAIN_TYPE" = xgcc; then
47642     LIBCXX="-lstdc++"
47643   fi
47644 
47645 
47646 
47647 
47648   if test "x$OPENJDK_TARGET_OS" = "xwindows"; then
47649 
47650 
47651 # Check whether --with-msvcr-dll was given.
47652 if test "${with_msvcr_dll+set}" = set; then :
47653   withval=$with_msvcr_dll;
47654 fi
47655 
47656 
47657   if test "x$with_msvcr_dll" != x; then


48542 
48543 
48544 
48545 
48546 # Setup use of ccache, if available
48547 
48548   # Check whether --enable-ccache was given.
48549 if test "${enable_ccache+set}" = set; then :
48550   enableval=$enable_ccache;
48551 fi
48552 
48553 
48554   CCACHE=
48555   { $as_echo "$as_me:${as_lineno-$LINENO}: checking is ccache enabled" >&5
48556 $as_echo_n "checking is ccache enabled... " >&6; }
48557   ENABLE_CCACHE=$enable_ccache
48558   if test "x$enable_ccache" = xyes; then
48559     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
48560 $as_echo "yes" >&6; }
48561     OLD_PATH="$PATH"
48562     if test "x$TOOLS_DIR" != x; then
48563       PATH=$TOOLS_DIR:$PATH
48564     fi
48565 
48566 
48567 
48568   # Publish this variable in the help.
48569 
48570 
48571   if test "x$CCACHE" = x; then
48572     # The variable is not set by user, try to locate tool using the code snippet
48573     for ac_prog in ccache
48574 do
48575   # Extract the first word of "$ac_prog", so it can be a program name with args.
48576 set dummy $ac_prog; ac_word=$2
48577 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
48578 $as_echo_n "checking for $ac_word... " >&6; }
48579 if ${ac_cv_path_CCACHE+:} false; then :
48580   $as_echo_n "(cached) " >&6
48581 else
48582   case $CCACHE in
48583   [\\/]* | ?:[\\/]*)




 647 LLVM_CFLAGS
 648 LLVM_CONFIG
 649 LIBFFI_LIBS
 650 LIBFFI_CFLAGS
 651 STATIC_CXX_SETTING
 652 LIBDL
 653 LIBM
 654 LIBZIP_CAN_USE_MMAP
 655 USE_EXTERNAL_LIBZ
 656 USE_EXTERNAL_LIBPNG
 657 PNG_LIBS
 658 PNG_CFLAGS
 659 USE_EXTERNAL_LIBGIF
 660 USE_EXTERNAL_LIBJPEG
 661 ALSA_LIBS
 662 ALSA_CFLAGS
 663 FREETYPE_BUNDLE_LIB_PATH
 664 FREETYPE_LIBS
 665 FREETYPE_CFLAGS
 666 CUPS_CFLAGS

 667 X_EXTRA_LIBS
 668 X_LIBS
 669 X_PRE_LIBS
 670 X_CFLAGS
 671 XMKMF
 672 FIXPATH
 673 ZIP_DEBUGINFO_FILES
 674 ENABLE_DEBUG_SYMBOLS
 675 CFLAGS_WARNINGS_ARE_ERRORS
 676 COMPILER_SUPPORTS_TARGET_BITS_FLAG
 677 ZERO_ARCHFLAG
 678 LDFLAGS_CXX_JDK
 679 LDFLAGS_JDKEXE_SUFFIX
 680 LDFLAGS_JDKLIB_SUFFIX
 681 LDFLAGS_JDKEXE
 682 LDFLAGS_JDKLIB
 683 CXXFLAGS_JDKEXE
 684 CXXFLAGS_JDKLIB
 685 CFLAGS_JDKEXE
 686 CFLAGS_JDKLIB


 690 LEGACY_EXTRA_CFLAGS
 691 CXX_O_FLAG_NONE
 692 CXX_O_FLAG_NORM
 693 CXX_O_FLAG_HI
 694 CXX_O_FLAG_HIGHEST
 695 C_O_FLAG_NONE
 696 C_O_FLAG_NORM
 697 C_O_FLAG_HI
 698 C_O_FLAG_HIGHEST
 699 CXXFLAGS_DEBUG_SYMBOLS
 700 CFLAGS_DEBUG_SYMBOLS
 701 CXX_FLAG_DEPS
 702 C_FLAG_DEPS
 703 SET_SHARED_LIBRARY_MAPFILE
 704 SET_SHARED_LIBRARY_NAME
 705 SET_SHARED_LIBRARY_ORIGIN
 706 SET_EXECUTABLE_ORIGIN
 707 SHARED_LIBRARY_FLAGS
 708 CXX_FLAG_REORDER
 709 C_FLAG_REORDER
 710 SYSROOT_LDFLAGS
 711 SYSROOT_CFLAGS
 712 RC_FLAGS
 713 AR_OUT_OPTION
 714 LD_OUT_OPTION
 715 EXE_OUT_OPTION
 716 CC_OUT_OPTION
 717 POST_MCS_CMD
 718 POST_STRIP_CMD
 719 ARFLAGS
 720 COMPILER_TARGET_BITS_FLAG
 721 JT_HOME
 722 JTREGEXE
 723 USING_BROKEN_SUSE_LD
 724 PACKAGE_PATH
 725 LDEXECXX
 726 LDEXE
 727 USE_CLANG
 728 HOTSPOT_LD
 729 HOTSPOT_CXX
 730 HOTSPOT_RC
 731 HOTSPOT_MT


 744 STRIP
 745 DUMPBIN
 746 RC
 747 MT
 748 LIPO
 749 ac_ct_OBJC
 750 OBJCFLAGS
 751 OBJC
 752 ac_ct_AR
 753 AR
 754 AS
 755 LDCXX
 756 LD
 757 CXXCPP
 758 CPP
 759 ac_ct_CXX
 760 CXXFLAGS
 761 CXX
 762 ac_ct_PROPER_COMPILER_CXX
 763 PROPER_COMPILER_CXX
 764 TOOLCHAIN_PATH_CXX
 765 POTENTIAL_CXX
 766 OBJEXT
 767 EXEEXT
 768 ac_ct_CC
 769 CPPFLAGS
 770 LDFLAGS
 771 CFLAGS
 772 CC
 773 ac_ct_PROPER_COMPILER_CC
 774 PROPER_COMPILER_CC
 775 TOOLCHAIN_PATH_CC
 776 POTENTIAL_CC
 777 VS_PATH
 778 VS_LIB
 779 VS_INCLUDE
 780 CYGWIN_LINK
 781 EXE_SUFFIX
 782 OBJ_SUFFIX
 783 STATIC_LIBRARY
 784 SHARED_LIBRARY
 785 STATIC_LIBRARY_SUFFIX
 786 SHARED_LIBRARY_SUFFIX
 787 LIBRARY_PREFIX
 788 TOOLCHAIN_TYPE
 789 BUILD_HOTSPOT
 790 HOTSPOT_DIST
 791 BUILD_OUTPUT
 792 OVERRIDE_SRC_ROOT
 793 ADD_SRC_ROOT
 794 JDK_TOPDIR
 795 NASHORN_TOPDIR


 871 DEBUG_CLASSFILES
 872 FASTDEBUG
 873 VARIANT
 874 DEBUG_LEVEL
 875 MACOSX_UNIVERSAL
 876 INCLUDE_SA
 877 JVM_VARIANT_CORE
 878 JVM_VARIANT_ZEROSHARK
 879 JVM_VARIANT_ZERO
 880 JVM_VARIANT_KERNEL
 881 JVM_VARIANT_MINIMAL1
 882 JVM_VARIANT_CLIENT
 883 JVM_VARIANT_SERVER
 884 JVM_VARIANTS
 885 JVM_INTERPRETER
 886 JDK_VARIANT
 887 SET_OPENJDK
 888 BUILD_LOG_WRAPPER
 889 BUILD_LOG_PREVIOUS
 890 BUILD_LOG

 891 TOPDIR
 892 PATH_SEP
 893 ZERO_ARCHDEF
 894 DEFINE_CROSS_COMPILE_ARCH
 895 LP64
 896 OPENJDK_TARGET_OS_EXPORT_DIR
 897 OPENJDK_TARGET_OS_API_DIR
 898 OPENJDK_TARGET_CPU_JLI_CFLAGS
 899 OPENJDK_TARGET_CPU_OSARCH
 900 OPENJDK_TARGET_CPU_ISADIR
 901 OPENJDK_TARGET_CPU_LIBDIR
 902 OPENJDK_TARGET_CPU_LEGACY_LIB
 903 OPENJDK_TARGET_CPU_LEGACY
 904 REQUIRED_OS_VERSION
 905 REQUIRED_OS_NAME
 906 COMPILE_TYPE
 907 OPENJDK_TARGET_CPU_ENDIAN
 908 OPENJDK_TARGET_CPU_BITS
 909 OPENJDK_TARGET_CPU_ARCH
 910 OPENJDK_TARGET_CPU


1003 datadir
1004 datarootdir
1005 libexecdir
1006 sbindir
1007 bindir
1008 program_transform_name
1009 prefix
1010 exec_prefix
1011 PACKAGE_URL
1012 PACKAGE_BUGREPORT
1013 PACKAGE_STRING
1014 PACKAGE_VERSION
1015 PACKAGE_TARNAME
1016 PACKAGE_NAME
1017 PATH_SEPARATOR
1018 SHELL'
1019 ac_subst_files=''
1020 ac_user_opts='
1021 enable_option_checking
1022 with_target_bits
1023 with_devkit
1024 with_sys_root
1025 with_sysroot
1026 with_tools_dir
1027 with_toolchain_path
1028 with_extra_path
1029 enable_openjdk_only
1030 with_custom_make_dir
1031 with_jdk_variant
1032 with_jvm_interpreter
1033 with_jvm_variants
1034 enable_debug
1035 with_debug_level
1036 with_conf_name
1037 with_builddeps_conf
1038 with_builddeps_server
1039 with_builddeps_dir
1040 with_builddeps_group
1041 enable_headful
1042 enable_hotspot_test_in_build
1043 with_cacerts_file
1044 enable_unlimited_crypto
1045 enable_rmiconnector_iiop
1046 with_milestone
1047 with_update_version
1048 with_user_release_suffix


1834   --enable-macosx-runtime-support
1835                           Deprecated. Option is kept for backwards
1836                           compatibility and is ignored
1837   --disable-freetype-bundling
1838                           disable bundling of the freetype library with the
1839                           build result [enabled on Windows or when using
1840                           --with-freetype, disabled otherwise]
1841   --enable-sjavac         use sjavac to do fast incremental compiles
1842                           [disabled]
1843   --disable-precompiled-headers
1844                           disable using precompiled headers when compiling C++
1845                           [enabled]
1846   --enable-ccache         enable using ccache to speed up recompilations
1847                           [disabled]
1848 
1849 Optional Packages:
1850   --with-PACKAGE[=ARG]    use PACKAGE [ARG=yes]
1851   --without-PACKAGE       do not use PACKAGE (same as --with-PACKAGE=no)
1852   --with-target-bits      build 32-bit or 64-bit binaries (for platforms that
1853                           support it), e.g. --with-target-bits=32 [guessed]




1854   --with-devkit           use this directory as base for tools-dir and
1855                           sys-root (for cross-compiling)
1856   --with-sys-root         alias for --with-sysroot for backwards compatability
1857   --with-sysroot          use this directory as sysroot)
1858   --with-tools-dir        alias for --with-toolchain-path for backwards
1859                           compatibility
1860   --with-toolchain-path   prepend these directories when searching for
1861                           toolchain binaries (compilers etc)
1862   --with-extra-path       prepend these directories to the default path
1863   --with-custom-make-dir  Deprecated. Option is kept for backwards
1864                           compatibility and is ignored
1865   --with-jdk-variant      JDK variant to build (normal) [normal]
1866   --with-jvm-interpreter  JVM interpreter to build (template, cpp) [template]
1867   --with-jvm-variants     JVM variants (separated by commas) to build (server,
1868                           client, minimal1, kernel, zero, zeroshark, core)
1869                           [server]
1870   --with-debug-level      set the debug level (release, fastdebug, slowdebug,
1871                           optimized (HotSpot build only)) [release]
1872   --with-conf-name        use this as the name of the configuration [generated
1873                           from important configuration options]
1874   --with-builddeps-conf   use this configuration file for the builddeps
1875   --with-builddeps-server download and use build dependencies from this server
1876                           url
1877   --with-builddeps-dir    store downloaded build dependencies here
1878                           [/localhome/builddeps]
1879   --with-builddeps-group  chgrp the downloaded build dependencies to this
1880                           group
1881   --with-cacerts-file     specify alternative cacerts file
1882   --with-milestone        Set milestone value for build [internal]


3314 # version 2 for more details (a copy is included in the LICENSE file that
3315 # accompanied this code).
3316 #
3317 # You should have received a copy of the GNU General Public License version
3318 # 2 along with this work; if not, write to the Free Software Foundation,
3319 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
3320 #
3321 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
3322 # or visit www.oracle.com if you need additional information or have any
3323 # questions.
3324 #
3325 
3326 # Test if $1 is a valid argument to $3 (often is $JAVA passed as $3)
3327 # If so, then append $1 to $2 \
3328 # Also set JVM_ARG_OK to true/false depending on outcome.
3329 
3330 
3331 # Appends a string to a path variable, only adding the : when needed.
3332 
3333 
3334 # Appends a string to a path variable, only adding the : when needed.
3335 
3336 
3337 # This will make sure the given variable points to a full and proper
3338 # path. This means:
3339 # 1) There will be no spaces in the path. On posix platforms,
3340 #    spaces in the path will result in an error. On Windows,
3341 #    the path will be rewritten using short-style to be space-free.
3342 # 2) The path will be absolute, and it will be in unix-style (on
3343 #     cygwin).
3344 # $1: The name of the variable to fix
3345 
3346 
3347 # This will make sure the given variable points to a executable
3348 # with a full and proper path. This means:
3349 # 1) There will be no spaces in the path. On posix platforms,
3350 #    spaces in the path will result in an error. On Windows,
3351 #    the path will be rewritten using short-style to be space-free.
3352 # 2) The path will be absolute, and it will be in unix-style (on
3353 #     cygwin).
3354 # Any arguments given to the executable is preserved.
3355 # If the input variable does not have a directory specification, then
3356 # it need to be in the PATH.


4225 
4226 # Check if the VS env variables were setup prior to running configure.
4227 # If not, then find vcvarsall.bat and run it automatically, and integrate
4228 # the set env variables into the spec file.
4229 
4230 
4231 
4232 
4233 
4234 
4235 
4236 
4237 
4238 
4239 # This line needs to be here, verbatim, after all includes and the dummy hook
4240 # definitions. It is replaced with custom functionality when building
4241 # custom sources.
4242 #CUSTOM_AUTOCONF_INCLUDE
4243 
4244 # Do not change or remove the following line, it is needed for consistency checks:
4245 DATE_WHEN_GENERATED=1395753263
4246 
4247 ###############################################################################
4248 #
4249 # Initialization / Boot-strapping
4250 #
4251 # The bootstrapping process needs to solve the "chicken or the egg" problem,
4252 # thus it jumps back and forth, each time gaining something needed later on.
4253 #
4254 ###############################################################################
4255 
4256 # If we are requested to print additional help, do that and then exit.
4257 # This must be the very first call.
4258 
4259   if test "x$CONFIGURE_PRINT_TOOLCHAIN_LIST" != x; then
4260     $PRINTF "The following toolchains are available as arguments to --with-toolchain-type.\n"
4261     $PRINTF "Which are valid to use depends on the build platform.\n"
4262     for toolchain in $VALID_TOOLCHAINS_all; do
4263       # Use indirect variable referencing
4264       toolchain_var_name=TOOLCHAIN_DESCRIPTION_$toolchain
4265       TOOLCHAIN_DESCRIPTION=${!toolchain_var_name}


14232       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of TOPDIR, which resolves as \"$path\", is invalid." >&5
14233 $as_echo "$as_me: The path of TOPDIR, which resolves as \"$path\", is invalid." >&6;}
14234       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
14235     fi
14236 
14237     # Use eval to expand a potential ~
14238     eval path="$path"
14239     if test ! -f "$path" && test ! -d "$path"; then
14240       as_fn_error $? "The path of TOPDIR, which resolves as \"$path\", is not found." "$LINENO" 5
14241     fi
14242 
14243     TOPDIR="`cd "$path"; $THEPWDCMD -L`"
14244   fi
14245 
14246   # SRC_ROOT is a traditional alias for TOPDIR.
14247   SRC_ROOT=$TOPDIR
14248 
14249   # Locate the directory of this script.
14250   AUTOCONF_DIR=$TOPDIR/common/autoconf
14251 





























14252 
14253 # Check whether --with-devkit was given.
14254 if test "${with_devkit+set}" = set; then :
14255   withval=$with_devkit;



14256 
14257   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
14258 
14259   # Input might be given as Windows format, start by converting to
14260   # unix format.
14261   path="$with_devkit"
14262   new_path=`$CYGPATH -u "$path"`
14263 
14264   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
14265   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
14266   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
14267   # "foo.exe" is OK but "foo" is an error.
14268   #
14269   # This test is therefore slightly more accurate than "test -f" to check for file precense.
14270   # It is also a way to make sure we got the proper file name for the real test later on.
14271   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
14272   if test "x$test_shortpath" = x; then
14273     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_devkit, which resolves as \"$path\", is invalid." >&5
14274 $as_echo "$as_me: The path of with_devkit, which resolves as \"$path\", is invalid." >&6;}
14275     as_fn_error $? "Cannot locate the the path of with_devkit" "$LINENO" 5


14358 
14359   else
14360     # We're on a posix platform. Hooray! :)
14361     path="$with_devkit"
14362     has_space=`$ECHO "$path" | $GREP " "`
14363     if test "x$has_space" != x; then
14364       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of with_devkit, which resolves as \"$path\", is invalid." >&5
14365 $as_echo "$as_me: The path of with_devkit, which resolves as \"$path\", is invalid." >&6;}
14366       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
14367     fi
14368 
14369     # Use eval to expand a potential ~
14370     eval path="$path"
14371     if test ! -f "$path" && test ! -d "$path"; then
14372       as_fn_error $? "The path of with_devkit, which resolves as \"$path\", is not found." "$LINENO" 5
14373     fi
14374 
14375     with_devkit="`cd "$path"; $THEPWDCMD -L`"
14376   fi
14377 
14378         DEVKIT_ROOT="$with_devkit"
14379         # Check for a meta data info file in the root of the devkit
14380         if test -f "$DEVKIT_ROOT/devkit.info"; then
14381           # This potentially sets the following:
14382           # DEVKIT_NAME: A descriptive name of the devkit
14383           # DEVKIT_TOOLCHAIN_PATH: Corresponds to --with-toolchain-path
14384           # DEVKIT_EXTRA_PATH: Corresponds to --with-extra-path
14385           # DEVKIT_SYSROOT: Corresponds to --with-sysroot
14386           . $DEVKIT_ROOT/devkit.info
14387         fi
14388 
14389         { $as_echo "$as_me:${as_lineno-$LINENO}: checking for devkit" >&5
14390 $as_echo_n "checking for devkit... " >&6; }
14391         if test "x$DEVKIT_NAME" != x; then
14392           { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEVKIT_NAME in $DEVKIT_ROOT" >&5
14393 $as_echo "$DEVKIT_NAME in $DEVKIT_ROOT" >&6; }
14394         else
14395           { $as_echo "$as_me:${as_lineno-$LINENO}: result: $DEVKIT_ROOT" >&5
14396 $as_echo "$DEVKIT_ROOT" >&6; }
14397         fi
14398 
14399         if test "x$DEVKIT_EXTRA_PATH" != x; then
14400 
14401   if test "x$DEVKIT_EXTRA_PATH" != x; then
14402     if test "x$EXTRA_PATH" = x; then
14403       EXTRA_PATH="$DEVKIT_EXTRA_PATH"
14404     else
14405       EXTRA_PATH="$DEVKIT_EXTRA_PATH:$EXTRA_PATH"
14406     fi
14407   fi
14408 
14409         fi
14410 
14411         # Fallback default of just /bin if DEVKIT_PATH is not defined
14412         if test "x$DEVKIT_TOOLCHAIN_PATH" = x; then
14413           DEVKIT_TOOLCHAIN_PATH="$DEVKIT_ROOT/bin"

14414         fi
14415 
14416   if test "x$DEVKIT_TOOLCHAIN_PATH" != x; then
14417     if test "x$TOOLCHAIN_PATH" = x; then
14418       TOOLCHAIN_PATH="$DEVKIT_TOOLCHAIN_PATH"
14419     else
14420       TOOLCHAIN_PATH="$DEVKIT_TOOLCHAIN_PATH:$TOOLCHAIN_PATH"
14421     fi
14422   fi
14423 
14424 
14425         # If a separate sysroot has not been defined, use the one in the devkit
14426         if test "x$DEVKIT_SYSROOT" != x; then
14427           SYSROOT="$DEVKIT_SYSROOT"
14428         elif test -d "$DEVKIT_ROOT/$host_alias/libc"; then
14429           SYSROOT="$DEVKIT_ROOT/$host_alias/libc"
14430         elif test -d "$DEVKIT_ROOT/$host/sys-root"; then
14431           SYSROOT="$DEVKIT_ROOT/$host/sys-root"
14432         fi
14433 
14434 
14435 fi
14436 
14437 
14438   # You can force the sysroot if the sysroot encoded into the cross compiler tools
14439   # is not correct.
14440 
14441 # Check whether --with-sys-root was given.
14442 if test "${with_sys_root+set}" = set; then :
14443   withval=$with_sys_root; SYSROOT=$with_sys_root
14444 
14445 fi
14446 
14447 
14448 
14449 # Check whether --with-sysroot was given.
14450 if test "${with_sysroot+set}" = set; then :
14451   withval=$with_sysroot; SYSROOT=$with_sysroot
14452 
14453 fi
14454 
14455 
14456 
14457 # Check whether --with-tools-dir was given.
14458 if test "${with_tools_dir+set}" = set; then :
14459   withval=$with_tools_dir;
14460   if test "x$with_tools_dir" != x; then
14461     if test "x$TOOLCHAIN_PATH" = x; then
14462       TOOLCHAIN_PATH="$with_tools_dir"
14463     else
14464       TOOLCHAIN_PATH="$with_tools_dir:$TOOLCHAIN_PATH"
14465     fi
14466   fi
14467 
14468 
14469 fi
14470 
14471 
14472 
14473 # Check whether --with-toolchain-path was given.
14474 if test "${with_toolchain_path+set}" = set; then :
14475   withval=$with_toolchain_path;
14476   if test "x$with_toolchain_path" != x; then
14477     if test "x$TOOLCHAIN_PATH" = x; then
14478       TOOLCHAIN_PATH="$with_toolchain_path"
14479     else
14480       TOOLCHAIN_PATH="$with_toolchain_path:$TOOLCHAIN_PATH"
14481     fi
14482   fi
14483 
14484 
14485 fi
14486 
14487 
14488 
14489 # Check whether --with-extra-path was given.
14490 if test "${with_extra_path+set}" = set; then :
14491   withval=$with_extra_path;
14492   if test "x$with_extra_path" != x; then
14493     if test "x$EXTRA_PATH" = x; then
14494       EXTRA_PATH="$with_extra_path"
14495     else
14496       EXTRA_PATH="$with_extra_path:$EXTRA_PATH"
14497     fi
14498   fi
14499 
14500 
14501 fi
14502 
14503 
14504   # Prepend the extra path to the global path
14505 
14506   if test "x$EXTRA_PATH" != x; then
14507     if test "x$PATH" = x; then
14508       PATH="$EXTRA_PATH"
14509     else
14510       PATH="$EXTRA_PATH:$PATH"
14511     fi
14512   fi
14513 
14514 
14515   if test "x$OPENJDK_BUILD_OS" = "xsolaris"; then
14516     # Add extra search paths on solaris for utilities like ar and as etc...
14517     PATH="$PATH:/usr/ccs/bin:/usr/sfw/bin:/opt/csw/bin"
14518   fi
14519 
14520   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for sysroot" >&5
14521 $as_echo_n "checking for sysroot... " >&6; }
14522   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $SYSROOT" >&5
14523 $as_echo "$SYSROOT" >&6; }
14524   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for toolchain path" >&5
14525 $as_echo_n "checking for toolchain path... " >&6; }
14526   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLCHAIN_PATH" >&5
14527 $as_echo "$TOOLCHAIN_PATH" >&6; }
14528   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for extra path" >&5
14529 $as_echo_n "checking for extra path... " >&6; }
14530   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $EXTRA_PATH" >&5
14531 $as_echo "$EXTRA_PATH" >&6; }
14532 
14533 
14534   # Setup default logging of stdout and stderr to build.log in the output root.
14535   BUILD_LOG='$(OUTPUT_ROOT)/build.log'
14536   BUILD_LOG_PREVIOUS='$(OUTPUT_ROOT)/build.log.old'
14537   BUILD_LOG_WRAPPER='$(BASH) $(SRC_ROOT)/common/bin/logger.sh $(BUILD_LOG)'
14538 
14539 
14540 
14541 
14542 
14543 # Check if it's a pure open build or if custom sources are to be used.
14544 
14545   # Check whether --enable-openjdk-only was given.
14546 if test "${enable_openjdk_only+set}" = set; then :
14547   enableval=$enable_openjdk_only;
14548 else
14549   enable_openjdk_only="no"
14550 fi
14551 
14552 
14553   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for presence of closed sources" >&5


16206   if test "x$arguments" != xEOL; then
16207     new_complete="$new_path ${arguments% *}"
16208   else
16209     new_complete="$new_path"
16210   fi
16211 
16212   if test "x$complete" != "x$new_complete"; then
16213     FOUND_MAKE="$new_complete"
16214     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting FOUND_MAKE to \"$new_complete\"" >&5
16215 $as_echo "$as_me: Rewriting FOUND_MAKE to \"$new_complete\"" >&6;}
16216   fi
16217 
16218         fi
16219       fi
16220     fi
16221   fi
16222 
16223     fi
16224 
16225     if test "x$FOUND_MAKE" = x; then
16226       if test "x$TOOLCHAIN_PATH" != x; then
16227         # We have a toolchain path, check that as well before giving up.
16228         OLD_PATH=$PATH
16229         PATH=$TOOLCHAIN_PATH:$PATH
16230         for ac_prog in gmake
16231 do
16232   # Extract the first word of "$ac_prog", so it can be a program name with args.
16233 set dummy $ac_prog; ac_word=$2
16234 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
16235 $as_echo_n "checking for $ac_word... " >&6; }
16236 if ${ac_cv_path_CHECK_TOOLSDIR_GMAKE+:} false; then :
16237   $as_echo_n "(cached) " >&6
16238 else
16239   case $CHECK_TOOLSDIR_GMAKE in
16240   [\\/]* | ?:[\\/]*)
16241   ac_cv_path_CHECK_TOOLSDIR_GMAKE="$CHECK_TOOLSDIR_GMAKE" # Let the user override the test with a path.
16242   ;;
16243   *)
16244   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
16245 for as_dir in $PATH
16246 do
16247   IFS=$as_save_IFS
16248   test -z "$as_dir" && as_dir=.
16249     for ac_exec_ext in '' $ac_executable_extensions; do


27444       { $as_echo "$as_me:${as_lineno-$LINENO}: Running the extraction script failed." >&5
27445 $as_echo "$as_me: Running the extraction script failed." >&6;}
27446     fi
27447     { $as_echo "$as_me:${as_lineno-$LINENO}: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&5
27448 $as_echo "$as_me: Try setting --with-tools-dir to the VC/bin directory within the VS installation" >&6;}
27449     { $as_echo "$as_me:${as_lineno-$LINENO}: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&5
27450 $as_echo "$as_me: or run \"bash.exe -l\" from a VS command prompt and then run configure from there." >&6;}
27451     as_fn_error $? "Cannot continue" "$LINENO" 5
27452   fi
27453 
27454   fi
27455 
27456   # autoconf magic only relies on PATH, so update it if tools dir is specified
27457   OLD_PATH="$PATH"
27458 
27459   # For solaris we really need solaris tools, and not the GNU equivalent.
27460   # The build tools on Solaris reside in /usr/ccs (C Compilation System),
27461   # so add that to path before starting to probe.
27462   # FIXME: This was originally only done for AS,NM,GNM,STRIP,MCS,OBJCOPY,OBJDUMP.
27463   if test "x$OPENJDK_BUILD_OS" = xsolaris; then
27464     if test "x$TOOLCHAIN_PATH" = x; then
27465       PATH="/usr/ccs/bin:$PATH"
27466     fi
































































































































































27467   fi
27468 
27469   # Finally add TOOLCHAIN_PATH at the beginning, to allow --with-tools-dir to
27470   # override all other locations.
27471   if test "x$TOOLCHAIN_PATH" != x; then
27472     PATH=$TOOLCHAIN_PATH:$PATH
27473   fi
27474 
27475 

27476   #
27477   # Setup the compilers (CC and CXX)
27478   #
27479 
27480   COMPILER_NAME=C
27481   SEARCH_LIST="$TOOLCHAIN_CC_BINARY"
27482 
27483   if test "x$CC" != x; then
27484     # User has supplied compiler name already, always let that override.
27485     { $as_echo "$as_me:${as_lineno-$LINENO}: Will use user supplied compiler CC=$CC" >&5
27486 $as_echo "$as_me: Will use user supplied compiler CC=$CC" >&6;}
27487     if test "x`basename $CC`" = "x$CC"; then
27488       # A command without a complete path is provided, search $PATH.
27489 
27490       for ac_prog in $CC
27491 do
27492   # Extract the first word of "$ac_prog", so it can be a program name with args.
27493 set dummy $ac_prog; ac_word=$2
27494 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27495 $as_echo_n "checking for $ac_word... " >&6; }


27537       else
27538         as_fn_error $? "User supplied compiler CC=$CC could not be found" "$LINENO" 5
27539       fi
27540     else
27541       # Otherwise it might already be a complete path
27542       if test ! -x "$CC"; then
27543         as_fn_error $? "User supplied compiler CC=$CC does not exist" "$LINENO" 5
27544       fi
27545     fi
27546   else
27547     # No user supplied value. Locate compiler ourselves.
27548 
27549     # If we are cross compiling, assume cross compilation tools follows the
27550     # cross compilation standard where they are prefixed with the autoconf
27551     # standard name for the target. For example the binary
27552     # i686-sun-solaris2.10-gcc will cross compile for i686-sun-solaris2.10.
27553     # If we are not cross compiling, then the default compiler name will be
27554     # used.
27555 
27556     CC=
27557     # If TOOLCHAIN_PATH is set, check for all compiler names in there first
27558     # before checking the rest of the PATH.
27559     # FIXME: Now that we prefix the TOOLCHAIN_PATH to the PATH in the PRE_DETECTION
27560     # step, this should not be necessary.
27561     if test -n "$TOOLCHAIN_PATH"; then
27562       PATH_save="$PATH"
27563       PATH="$TOOLCHAIN_PATH"
27564       for ac_prog in $SEARCH_LIST
27565 do
27566   # Extract the first word of "$ac_prog", so it can be a program name with args.
27567 set dummy $ac_prog; ac_word=$2
27568 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27569 $as_echo_n "checking for $ac_word... " >&6; }
27570 if ${ac_cv_path_TOOLCHAIN_PATH_CC+:} false; then :
27571   $as_echo_n "(cached) " >&6
27572 else
27573   case $TOOLCHAIN_PATH_CC in
27574   [\\/]* | ?:[\\/]*)
27575   ac_cv_path_TOOLCHAIN_PATH_CC="$TOOLCHAIN_PATH_CC" # Let the user override the test with a path.
27576   ;;
27577   *)
27578   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
27579 for as_dir in $PATH
27580 do
27581   IFS=$as_save_IFS
27582   test -z "$as_dir" && as_dir=.
27583     for ac_exec_ext in '' $ac_executable_extensions; do
27584   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
27585     ac_cv_path_TOOLCHAIN_PATH_CC="$as_dir/$ac_word$ac_exec_ext"
27586     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
27587     break 2
27588   fi
27589 done
27590   done
27591 IFS=$as_save_IFS
27592 
27593   ;;
27594 esac
27595 fi
27596 TOOLCHAIN_PATH_CC=$ac_cv_path_TOOLCHAIN_PATH_CC
27597 if test -n "$TOOLCHAIN_PATH_CC"; then
27598   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLCHAIN_PATH_CC" >&5
27599 $as_echo "$TOOLCHAIN_PATH_CC" >&6; }
27600 else
27601   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
27602 $as_echo "no" >&6; }
27603 fi
27604 
27605 
27606   test -n "$TOOLCHAIN_PATH_CC" && break
27607 done
27608 
27609       CC=$TOOLCHAIN_PATH_CC
27610       PATH="$PATH_save"
27611     fi
27612 
27613     # AC_PATH_PROGS can't be run multiple times with the same variable,
27614     # so create a new name for this run.
27615     if test "x$CC" = x; then
27616       for ac_prog in $SEARCH_LIST
27617 do
27618   # Extract the first word of "$ac_prog", so it can be a program name with args.
27619 set dummy $ac_prog; ac_word=$2
27620 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
27621 $as_echo_n "checking for $ac_word... " >&6; }
27622 if ${ac_cv_path_POTENTIAL_CC+:} false; then :
27623   $as_echo_n "(cached) " >&6
27624 else
27625   case $POTENTIAL_CC in
27626   [\\/]* | ?:[\\/]*)
27627   ac_cv_path_POTENTIAL_CC="$POTENTIAL_CC" # Let the user override the test with a path.
27628   ;;
27629   *)


29243       else
29244         as_fn_error $? "User supplied compiler CXX=$CXX could not be found" "$LINENO" 5
29245       fi
29246     else
29247       # Otherwise it might already be a complete path
29248       if test ! -x "$CXX"; then
29249         as_fn_error $? "User supplied compiler CXX=$CXX does not exist" "$LINENO" 5
29250       fi
29251     fi
29252   else
29253     # No user supplied value. Locate compiler ourselves.
29254 
29255     # If we are cross compiling, assume cross compilation tools follows the
29256     # cross compilation standard where they are prefixed with the autoconf
29257     # standard name for the target. For example the binary
29258     # i686-sun-solaris2.10-gcc will cross compile for i686-sun-solaris2.10.
29259     # If we are not cross compiling, then the default compiler name will be
29260     # used.
29261 
29262     CXX=
29263     # If TOOLCHAIN_PATH is set, check for all compiler names in there first
29264     # before checking the rest of the PATH.
29265     # FIXME: Now that we prefix the TOOLCHAIN_PATH to the PATH in the PRE_DETECTION
29266     # step, this should not be necessary.
29267     if test -n "$TOOLCHAIN_PATH"; then
29268       PATH_save="$PATH"
29269       PATH="$TOOLCHAIN_PATH"
29270       for ac_prog in $SEARCH_LIST
29271 do
29272   # Extract the first word of "$ac_prog", so it can be a program name with args.
29273 set dummy $ac_prog; ac_word=$2
29274 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
29275 $as_echo_n "checking for $ac_word... " >&6; }
29276 if ${ac_cv_path_TOOLCHAIN_PATH_CXX+:} false; then :
29277   $as_echo_n "(cached) " >&6
29278 else
29279   case $TOOLCHAIN_PATH_CXX in
29280   [\\/]* | ?:[\\/]*)
29281   ac_cv_path_TOOLCHAIN_PATH_CXX="$TOOLCHAIN_PATH_CXX" # Let the user override the test with a path.
29282   ;;
29283   *)
29284   as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
29285 for as_dir in $PATH
29286 do
29287   IFS=$as_save_IFS
29288   test -z "$as_dir" && as_dir=.
29289     for ac_exec_ext in '' $ac_executable_extensions; do
29290   if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then
29291     ac_cv_path_TOOLCHAIN_PATH_CXX="$as_dir/$ac_word$ac_exec_ext"
29292     $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5
29293     break 2
29294   fi
29295 done
29296   done
29297 IFS=$as_save_IFS
29298 
29299   ;;
29300 esac
29301 fi
29302 TOOLCHAIN_PATH_CXX=$ac_cv_path_TOOLCHAIN_PATH_CXX
29303 if test -n "$TOOLCHAIN_PATH_CXX"; then
29304   { $as_echo "$as_me:${as_lineno-$LINENO}: result: $TOOLCHAIN_PATH_CXX" >&5
29305 $as_echo "$TOOLCHAIN_PATH_CXX" >&6; }
29306 else
29307   { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
29308 $as_echo "no" >&6; }
29309 fi
29310 
29311 
29312   test -n "$TOOLCHAIN_PATH_CXX" && break
29313 done
29314 
29315       CXX=$TOOLCHAIN_PATH_CXX
29316       PATH="$PATH_save"
29317     fi
29318 
29319     # AC_PATH_PROGS can't be run multiple times with the same variable,
29320     # so create a new name for this run.
29321     if test "x$CXX" = x; then
29322       for ac_prog in $SEARCH_LIST
29323 do
29324   # Extract the first word of "$ac_prog", so it can be a program name with args.
29325 set dummy $ac_prog; ac_word=$2
29326 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
29327 $as_echo_n "checking for $ac_word... " >&6; }
29328 if ${ac_cv_path_POTENTIAL_CXX+:} false; then :
29329   $as_echo_n "(cached) " >&6
29330 else
29331   case $POTENTIAL_CXX in
29332   [\\/]* | ?:[\\/]*)
29333   ac_cv_path_POTENTIAL_CXX="$POTENTIAL_CXX" # Let the user override the test with a path.
29334   ;;
29335   *)


40703     # in a custom configure script, or possibly the command line.
40704     # Let those variables be expanded at make time in spec.gmk.
40705     # The \$ are escaped to the shell, and the $(...) variables
40706     # are evaluated by make.
40707     RC_FLAGS="$RC_FLAGS \
40708         -d \"JDK_BUILD_ID=\$(FULL_VERSION)\" \
40709         -d \"JDK_COMPANY=\$(COMPANY_NAME)\" \
40710         -d \"JDK_COMPONENT=\$(PRODUCT_NAME) \$(JDK_RC_PLATFORM_NAME) binary\" \
40711         -d \"JDK_VER=\$(JDK_MINOR_VERSION).\$(JDK_MICRO_VERSION).\$(if \$(JDK_UPDATE_VERSION),\$(JDK_UPDATE_VERSION),0).\$(COOKED_BUILD_NUMBER)\" \
40712         -d \"JDK_COPYRIGHT=Copyright \xA9 $COPYRIGHT_YEAR\" \
40713         -d \"JDK_NAME=\$(PRODUCT_NAME) \$(JDK_RC_PLATFORM_NAME) \$(JDK_MINOR_VERSION) \$(JDK_UPDATE_META_TAG)\" \
40714         -d \"JDK_FVER=\$(JDK_MINOR_VERSION),\$(JDK_MICRO_VERSION),\$(if \$(JDK_UPDATE_VERSION),\$(JDK_UPDATE_VERSION),0),\$(COOKED_BUILD_NUMBER)\""
40715   fi
40716 
40717 
40718   if test "x$TOOLCHAIN_TYPE" = xmicrosoft; then
40719     # FIXME: likely bug, should be CCXXFLAGS_JDK? or one for C or CXX.
40720     CCXXFLAGS="$CCXXFLAGS -nologo"
40721   fi
40722 
40723   if test "x$SYSROOT" != "x"; then
40724     if test "x$TOOLCHAIN_TYPE" = xsolstudio; then
40725       if test "x$OPENJDK_TARGET_OS" = xsolaris; then
40726         # When using a sysroot on Solaris with Solaris Studio, make sure the
40727         # /usr/include dir in it is added to all compile lines.
40728         SYSROOT_CFLAGS="-I$SYSROOT/usr/include"
40729         SYSROOT_LDFLAGS="-L$SYSROOT/usr/lib$OPENJDK_TARGET_CPU_ISADIR \
40730             -L$SYSROOT/lib$OPENJDK_TARGET_CPU_ISADIR"
40731       fi
40732     elif test "x$TOOLCHAIN_TYPE" = xgcc; then
40733       SYSROOT_CFLAGS="--sysroot=\"$SYSROOT\""
40734       SYSROOT_LDFLAGS="--sysroot=\"$SYSROOT\""
40735     elif test "x$TOOLCHAIN_TYPE" = xclang; then
40736       SYSROOT_CFLAGS="-isysroot \"$SYSROOT\""
40737       SYSROOT_LDFLAGS="-isysroot \"$SYSROOT\""
40738     fi
40739     # Propagate the sysroot args to hotspot
40740     LEGACY_EXTRA_CFLAGS="$LEGACY_EXTRA_CFLAGS $SYSROOT_CFLAGS"
40741     LEGACY_EXTRA_CXXFLAGS="$LEGACY_EXTRA_CXXFLAGS $SYSROOT_CFLAGS"
40742     LEGACY_EXTRA_LDFLAGS="$LEGACY_EXTRA_LDFLAGS $SYSROOT_LDFLAGS"
40743   fi
40744 
40745 
40746 
40747 
40748 # FIXME: Currently we must test this after toolchain but before flags. Fix!
40749 
40750 # Now we can test some aspects on the target using configure macros.
40751 
40752 
40753 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ANSI C header files" >&5
40754 $as_echo_n "checking for ANSI C header files... " >&6; }
40755 if ${ac_cv_header_stdc+:} false; then :
40756   $as_echo_n "(cached) " >&6
40757 else
40758   cat confdefs.h - <<_ACEOF >conftest.$ac_ext
40759 /* end confdefs.h.  */
40760 #include <stdlib.h>
40761 #include <stdarg.h>
40762 #include <string.h>
40763 #include <float.h>
40764 
40765 int
40766 main ()


41575 
41576 
41577 # Check whether --with-extra-cxxflags was given.
41578 if test "${with_extra_cxxflags+set}" = set; then :
41579   withval=$with_extra_cxxflags;
41580 fi
41581 
41582 
41583 
41584 # Check whether --with-extra-ldflags was given.
41585 if test "${with_extra_ldflags+set}" = set; then :
41586   withval=$with_extra_ldflags;
41587 fi
41588 
41589 
41590   CFLAGS_JDK="${CFLAGS_JDK} $with_extra_cflags"
41591   CXXFLAGS_JDK="${CXXFLAGS_JDK} $with_extra_cxxflags"
41592   LDFLAGS_JDK="${LDFLAGS_JDK} $with_extra_ldflags"
41593 
41594   # Hotspot needs these set in their legacy form
41595   LEGACY_EXTRA_CFLAGS="$LEGACY_EXTRA_CFLAGS $with_extra_cflags"
41596   LEGACY_EXTRA_CXXFLAGS="$LEGACY_EXTRA_CXXFLAGS $with_extra_cxxflags"
41597   LEGACY_EXTRA_LDFLAGS="$LEGACY_EXTRA_LDFLAGS $with_extra_ldflags"
41598 
41599 
41600 
41601 
41602 
41603   ###############################################################################
41604   #
41605   # Now setup the CFLAGS and LDFLAGS for the JDK build.
41606   # Later we will also have CFLAGS and LDFLAGS for the hotspot subrepo build.
41607   #
41608 
41609   # Setup compiler/platform specific flags to CFLAGS_JDK,
41610   # CXXFLAGS_JDK and CCXXFLAGS_JDK (common to C and CXX?)
41611   if test "x$TOOLCHAIN_TYPE" = xgcc; then
41612     # these options are used for both C and C++ compiles
41613     CCXXFLAGS_JDK="$CCXXFLAGS $CCXXFLAGS_JDK -Wall -Wno-parentheses -Wextra -Wno-unused -Wno-unused-parameter -Wformat=2 \
41614         -pipe -D_GNU_SOURCE -D_REENTRANT -D_LARGEFILE64_SOURCE"
41615     case $OPENJDK_TARGET_CPU_ARCH in
41616       arm )
41617         # on arm we don't prevent gcc to omit frame pointer but do prevent strict aliasing


41675 
41676   # Setup LP64
41677   CCXXFLAGS_JDK="$CCXXFLAGS_JDK $ADD_LP64"
41678 
41679   # Set some common defines. These works for all compilers, but assume
41680   # -D is universally accepted.
41681 
41682   # Setup endianness
41683   if test "x$OPENJDK_TARGET_CPU_ENDIAN" = xlittle; then
41684     # The macro _LITTLE_ENDIAN needs to be defined the same to avoid the
41685     #   Sun C compiler warning message: warning: macro redefined: _LITTLE_ENDIAN
41686     #   (The Solaris X86 system defines this in file /usr/include/sys/isa_defs.h).
41687     #   Note: -Dmacro         is the same as    #define macro 1
41688     #         -Dmacro=        is the same as    #define macro
41689     if test "x$OPENJDK_TARGET_OS" = xsolaris; then
41690       CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_LITTLE_ENDIAN="
41691     else
41692       CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_LITTLE_ENDIAN"
41693     fi
41694   else
41695     # Same goes for _BIG_ENDIAN. Do we really need to set *ENDIAN on Solaris if they
41696     # are defined in the system?
41697     if test "x$OPENJDK_TARGET_OS" = xsolaris; then
41698       CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_BIG_ENDIAN="
41699     else
41700       CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D_BIG_ENDIAN"
41701     fi
41702   fi
41703 
41704   # Setup target OS define. Use OS target name but in upper case.
41705   OPENJDK_TARGET_OS_UPPERCASE=`$ECHO $OPENJDK_TARGET_OS | $TR 'abcdefghijklmnopqrstuvwxyz' 'ABCDEFGHIJKLMNOPQRSTUVWXYZ'`
41706   CCXXFLAGS_JDK="$CCXXFLAGS_JDK -D$OPENJDK_TARGET_OS_UPPERCASE"
41707 
41708   # Setup target CPU
41709   CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DARCH='\"$OPENJDK_TARGET_CPU_LEGACY\"' -D$OPENJDK_TARGET_CPU_LEGACY"
41710 
41711   # Setup debug/release defines
41712   if test "x$DEBUG_LEVEL" = xrelease; then
41713     CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DNDEBUG"
41714     if test "x$OPENJDK_TARGET_OS" = xsolaris; then
41715       CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DTRIMMED"
41716     fi
41717   else
41718     CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DDEBUG"
41719   fi
41720 
41721   # Setup release name
41722   CCXXFLAGS_JDK="$CCXXFLAGS_JDK -DRELEASE='\"\$(RELEASE)\"'"


42244   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for Mac OS X Java Framework" >&5
42245 $as_echo_n "checking for Mac OS X Java Framework... " >&6; }
42246   if test -f /System/Library/Frameworks/JavaVM.framework/Frameworks/JavaRuntimeSupport.framework/Headers/JavaRuntimeSupport.h; then
42247     { $as_echo "$as_me:${as_lineno-$LINENO}: result: /System/Library/Frameworks/JavaVM.framework" >&5
42248 $as_echo "/System/Library/Frameworks/JavaVM.framework" >&6; }
42249   else
42250     { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
42251 $as_echo "no" >&6; }
42252   fi
42253 
42254 
42255 
42256   ###############################################################################
42257   #
42258   # Check for X Windows
42259   #
42260 
42261   # Check if the user has specified sysroot, but not --x-includes or --x-libraries.
42262   # Make a simple check for the libraries at the sysroot, and setup --x-includes and
42263   # --x-libraries for the sysroot, if that seems to be correct.
42264   if test "x$OPENJDK_TARGET_OS" = "xlinux"; then
42265     if test "x$SYSROOT" != "x"; then
42266       if test "x$x_includes" = xNONE; then
42267         if test -f "$SYSROOT/usr/X11R6/include/X11/Xlib.h"; then
42268           x_includes="$SYSROOT/usr/X11R6/include"
42269         elif test -f "$SYSROOT/usr/include/X11/Xlib.h"; then
42270           x_includes="$SYSROOT/usr/include"
42271         fi
42272       fi
42273       if test "x$x_libraries" = xNONE; then
42274         if test -f "$SYSROOT/usr/X11R6/lib/libX11.so"; then
42275           x_libraries="$SYSROOT/usr/X11R6/lib"
42276         elif test "$SYSROOT/usr/lib64/libX11.so" && test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
42277           x_libraries="$SYSROOT/usr/lib64"
42278         elif test -f "$SYSROOT/usr/lib/libX11.so"; then
42279           x_libraries="$SYSROOT/usr/lib"
42280         fi
42281       fi
42282     fi
42283   fi
42284 
42285   # Now let autoconf do it's magic
42286   { $as_echo "$as_me:${as_lineno-$LINENO}: checking for X" >&5
42287 $as_echo_n "checking for X... " >&6; }
42288 
42289 
42290 # Check whether --with-x was given.
42291 if test "${with_x+set}" = set; then :
42292   withval=$with_x;
42293 fi
42294 
42295 # $have_x is `yes', `no', `disabled', or empty when we do not yet know.
42296 if test "x$with_x" = xno; then
42297   # The user explicitly disabled X.
42298   have_x=disabled
42299 else
42300   case $x_includes,$x_libraries in #(


42991         apt_help     $MISSING_DEPENDENCY ;;
42992       yum)
42993         yum_help     $MISSING_DEPENDENCY ;;
42994       port)
42995         port_help    $MISSING_DEPENDENCY ;;
42996       pkgutil)
42997         pkgutil_help $MISSING_DEPENDENCY ;;
42998       pkgadd)
42999         pkgadd_help  $MISSING_DEPENDENCY ;;
43000     esac
43001 
43002     if test "x$PKGHANDLER_COMMAND" != x; then
43003       HELP_MSG="You might be able to fix this by running '$PKGHANDLER_COMMAND'."
43004     fi
43005   fi
43006 
43007     as_fn_error $? "Could not find X11 libraries. $HELP_MSG" "$LINENO" 5
43008   fi
43009 
43010   if test "x$OPENJDK_TARGET_OS" = xsolaris; then
43011     OPENWIN_HOME="$SYSROOT/usr/openwin"
43012     X_CFLAGS="-I$OPENWIN_HOME/include -I$OPENWIN_HOME/include/X11/extensions"
43013     X_LIBS="-L$OPENWIN_HOME/sfw/lib$OPENJDK_TARGET_CPU_ISADIR \
43014         -L$OPENWIN_HOME/lib$OPENJDK_TARGET_CPU_ISADIR \
43015         -R/usr/openwin/sfw/lib$OPENJDK_TARGET_CPU_ISADIR \
43016         -R/usr/openwin/lib$OPENJDK_TARGET_CPU_ISADIR"
43017   fi
43018 


43019   #
43020   # Weird Sol10 something check...TODO change to try compile
43021   #
43022   if test "x${OPENJDK_TARGET_OS}" = xsolaris; then
43023     if test "`uname -r`" = "5.10"; then
43024       if test "`${EGREP} -c XLinearGradient ${OPENWIN_HOME}/share/include/X11/extensions/Xrender.h`" = "0"; then
43025         X_CFLAGS="${X_CFLAGS} -DSOLARIS10_NO_XRENDER_STRUCTS"
43026       fi
43027     fi
43028   fi
43029 
43030   ac_ext=c
43031 ac_cpp='$CPP $CPPFLAGS'
43032 ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5'
43033 ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5'
43034 ac_compiler_gnu=$ac_cv_c_compiler_gnu
43035 
43036   OLD_CFLAGS="$CFLAGS"
43037   CFLAGS="$CFLAGS $X_CFLAGS"
43038 


43297 if eval test \"x\$"$as_ac_Header"\" = x"yes"; then :
43298   cat >>confdefs.h <<_ACEOF
43299 #define `$as_echo "HAVE_$ac_header" | $as_tr_cpp` 1
43300 _ACEOF
43301 
43302             CUPS_FOUND=yes
43303             CUPS_CFLAGS=
43304             DEFAULT_CUPS=yes
43305 
43306 
43307 fi
43308 
43309 done
43310 
43311     fi
43312     if test "x$CUPS_FOUND" = xno; then
43313       # Getting nervous now? Lets poke around for standard Solaris third-party
43314       # package installation locations.
43315       { $as_echo "$as_me:${as_lineno-$LINENO}: checking for cups headers" >&5
43316 $as_echo_n "checking for cups headers... " >&6; }
43317       if test -s $SYSROOT/opt/sfw/cups/include/cups/cups.h; then
43318         # An SFW package seems to be installed!
43319         CUPS_FOUND=yes
43320         CUPS_CFLAGS="-I$SYSROOT/opt/sfw/cups/include"
43321       elif test -s $SYSROOT/opt/csw/include/cups/cups.h; then
43322         # A CSW package seems to be installed!
43323         CUPS_FOUND=yes
43324         CUPS_CFLAGS="-I$SYSROOT/opt/csw/include"
43325       fi
43326       { $as_echo "$as_me:${as_lineno-$LINENO}: result: $CUPS_FOUND" >&5
43327 $as_echo "$CUPS_FOUND" >&6; }
43328     fi
43329     if test "x$CUPS_FOUND" = xno; then
43330 
43331   # Print a helpful message on how to acquire the necessary build dependency.
43332   # cups is the help tag: freetype, cups, pulse, alsa etc
43333   MISSING_DEPENDENCY=cups
43334 
43335   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
43336     cygwin_help $MISSING_DEPENDENCY
43337   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
43338     msys_help $MISSING_DEPENDENCY
43339   else
43340     PKGHANDLER_COMMAND=
43341 
43342     case $PKGHANDLER in
43343       apt-get)
43344         apt_help     $MISSING_DEPENDENCY ;;


43897     fi
43898     else FOUND_FREETYPE=no
43899 
43900   fi
43901 
43902         # BDEPS_CHECK_MODULE will set FREETYPE_CFLAGS and _LIBS, but we don't get a lib path for bundling.
43903         if test "x$FOUND_FREETYPE" = xyes; then
43904           if test "x$BUNDLE_FREETYPE" = xyes; then
43905             { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype using builddeps, but ignoring since we can not bundle that" >&5
43906 $as_echo "$as_me: Found freetype using builddeps, but ignoring since we can not bundle that" >&6;}
43907             FOUND_FREETYPE=no
43908           else
43909             { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype" >&5
43910 $as_echo_n "checking for freetype... " >&6; }
43911             { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (using builddeps)" >&5
43912 $as_echo "yes (using builddeps)" >&6; }
43913           fi
43914         fi
43915       fi
43916 
43917       # If we have a sys-root, assume that's where we are supposed to look and skip pkg-config.
43918       if test "x$SYSROOT" = x; then
43919         if test "x$FOUND_FREETYPE" != xyes; then
43920           # Check modules using pkg-config, but only if we have it (ugly output results otherwise)
43921           if test "x$PKG_CONFIG" != x; then
43922 
43923 pkg_failed=no
43924 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for FREETYPE" >&5
43925 $as_echo_n "checking for FREETYPE... " >&6; }
43926 
43927 if test -n "$FREETYPE_CFLAGS"; then
43928     pkg_cv_FREETYPE_CFLAGS="$FREETYPE_CFLAGS"
43929  elif test -n "$PKG_CONFIG"; then
43930     if test -n "$PKG_CONFIG" && \
43931     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"freetype2\""; } >&5
43932   ($PKG_CONFIG --exists --print-errors "freetype2") 2>&5
43933   ac_status=$?
43934   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
43935   test $ac_status = 0; }; then
43936   pkg_cv_FREETYPE_CFLAGS=`$PKG_CONFIG --cflags "freetype2" 2>/dev/null`
43937 else
43938   pkg_failed=yes


43990               # On solaris, pkg_check adds -lz to freetype libs, which isn't necessary for us.
43991               FREETYPE_LIBS=`$ECHO $FREETYPE_LIBS | $SED 's/-lz//g'`
43992               # 64-bit libs for Solaris x86 are installed in the amd64 subdirectory, change lib to lib/amd64
43993               if test "x$OPENJDK_TARGET_OS" = xsolaris && test "x$OPENJDK_TARGET_CPU" = xx86_64; then
43994                 FREETYPE_LIBS=`$ECHO $FREETYPE_LIBS | $SED 's?/lib?/lib/amd64?g'`
43995               fi
43996               # BDEPS_CHECK_MODULE will set FREETYPE_CFLAGS and _LIBS, but we don't get a lib path for bundling.
43997               if test "x$BUNDLE_FREETYPE" = xyes; then
43998                 { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype using pkg-config, but ignoring since we can not bundle that" >&5
43999 $as_echo "$as_me: Found freetype using pkg-config, but ignoring since we can not bundle that" >&6;}
44000                 FOUND_FREETYPE=no
44001               else
44002                 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype" >&5
44003 $as_echo_n "checking for freetype... " >&6; }
44004                 { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes (using pkg-config)" >&5
44005 $as_echo "yes (using pkg-config)" >&6; }
44006               fi
44007             fi
44008           fi
44009         fi
44010       fi
44011 
44012       if test "x$FOUND_FREETYPE" != xyes; then
44013         # Check in well-known locations
44014         if test "x$OPENJDK_TARGET_OS" = xwindows; then
44015           FREETYPE_BASE_DIR="$PROGRAMFILES/GnuWin32"
44016 
44017   windows_path="$FREETYPE_BASE_DIR"
44018   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44019     unix_path=`$CYGPATH -u "$windows_path"`
44020     FREETYPE_BASE_DIR="$unix_path"
44021   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44022     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44023     FREETYPE_BASE_DIR="$unix_path"
44024   fi
44025 
44026 
44027   POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
44028   POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib"
44029   METHOD="well-known location"
44030 


44600     fi
44601 
44602     POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
44603   fi
44604 
44605 
44606     FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44607     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
44608 $as_echo_n "checking for freetype includes... " >&6; }
44609     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
44610 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
44611     FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
44612     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
44613 $as_echo_n "checking for freetype libraries... " >&6; }
44614     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
44615 $as_echo "$FREETYPE_LIB_PATH" >&6; }
44616   fi
44617 
44618           fi
44619         else
44620           FREETYPE_BASE_DIR="$SYSROOT/usr"
44621 
44622   POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
44623   POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib"
44624   METHOD="well-known location"
44625 
44626   # First check if the files exists.
44627   if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
44628     # We found an arbitrary include file. That's a good sign.
44629     { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
44630 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
44631     FOUND_FREETYPE=yes
44632 
44633     FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
44634     if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
44635       { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
44636 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
44637       FOUND_FREETYPE=no
44638     else
44639       if test "x$OPENJDK_TARGET_OS" = xwindows; then
44640         # On Windows, we will need both .lib and .dll file.
44641         if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/freetype.lib"; then
44642           { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&5
44643 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/freetype.lib. Ignoring location." >&6;}
44644           FOUND_FREETYPE=no
44645         fi
44646       elif test "x$OPENJDK_TARGET_OS" = xsolaris && test "x$OPENJDK_TARGET_CPU" = xx86_64 && test -s "$POTENTIAL_FREETYPE_LIB_PATH/amd64/$FREETYPE_LIB_NAME"; then
44647         # On solaris-x86_86, default is (normally) PATH/lib/amd64. Update our guess!
44648         POTENTIAL_FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH/amd64"
44649       fi
44650     fi
44651   fi
44652 
44653   if test "x$FOUND_FREETYPE" = xyes; then
44654 
44655   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44656 
44657   # Input might be given as Windows format, start by converting to
44658   # unix format.
44659   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44660   new_path=`$CYGPATH -u "$path"`
44661 
44662   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
44663   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
44664   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
44665   # "foo.exe" is OK but "foo" is an error.
44666   #
44667   # This test is therefore slightly more accurate than "test -f" to check for file precense.
44668   # It is also a way to make sure we got the proper file name for the real test later on.
44669   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
44670   if test "x$test_shortpath" = x; then
44671     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
44672 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
44673     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_INCLUDE_PATH" "$LINENO" 5
44674   fi
44675 
44676   # Call helper function which possibly converts this using DOS-style short mode.
44677   # If so, the updated path is stored in $new_path.
44678 
44679   input_path="$new_path"
44680   # Check if we need to convert this using DOS-style short mode. If the path
44681   # contains just simple characters, use it. Otherwise (spaces, weird characters),
44682   # take no chances and rewrite it.
44683   # Note: m4 eats our [], so we need to use [ and ] instead.
44684   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
44685   if test "x$has_forbidden_chars" != x; then
44686     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44687     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
44688     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
44689     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
44690       # Going to short mode and back again did indeed matter. Since short mode is
44691       # case insensitive, let's make it lowercase to improve readability.
44692       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44693       # Now convert it back to Unix-stile (cygpath)
44694       input_path=`$CYGPATH -u "$shortmode_path"`
44695       new_path="$input_path"
44696     fi
44697   fi
44698 
44699   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
44700   if test "x$test_cygdrive_prefix" = x; then
44701     # As a simple fix, exclude /usr/bin since it's not a real path.
44702     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
44703       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
44704       # a path prefixed by /cygdrive for fixpath to work.
44705       new_path="$CYGWIN_ROOT_PATH$input_path"
44706     fi
44707   fi
44708 
44709 
44710   if test "x$path" != "x$new_path"; then
44711     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
44712     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
44713 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
44714   fi
44715 
44716   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44717 
44718   path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44719   has_colon=`$ECHO $path | $GREP ^.:`
44720   new_path="$path"
44721   if test "x$has_colon" = x; then
44722     # Not in mixed or Windows style, start by that.
44723     new_path=`cmd //c echo $path`
44724   fi
44725 
44726 
44727   input_path="$new_path"
44728   # Check if we need to convert this using DOS-style short mode. If the path
44729   # contains just simple characters, use it. Otherwise (spaces, weird characters),
44730   # take no chances and rewrite it.
44731   # Note: m4 eats our [], so we need to use [ and ] instead.
44732   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
44733   if test "x$has_forbidden_chars" != x; then
44734     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44735     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44736   fi
44737 
44738 
44739   windows_path="$new_path"
44740   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44741     unix_path=`$CYGPATH -u "$windows_path"`
44742     new_path="$unix_path"
44743   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44744     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44745     new_path="$unix_path"
44746   fi
44747 
44748   if test "x$path" != "x$new_path"; then
44749     POTENTIAL_FREETYPE_INCLUDE_PATH="$new_path"
44750     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&5
44751 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_INCLUDE_PATH to \"$new_path\"" >&6;}
44752   fi
44753 
44754   # Save the first 10 bytes of this path to the storage, so fixpath can work.
44755   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
44756 
44757   else
44758     # We're on a posix platform. Hooray! :)
44759     path="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44760     has_space=`$ECHO "$path" | $GREP " "`
44761     if test "x$has_space" != x; then
44762       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&5
44763 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is invalid." >&6;}
44764       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
44765     fi
44766 
44767     # Use eval to expand a potential ~
44768     eval path="$path"
44769     if test ! -f "$path" && test ! -d "$path"; then
44770       as_fn_error $? "The path of POTENTIAL_FREETYPE_INCLUDE_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
44771     fi
44772 
44773     POTENTIAL_FREETYPE_INCLUDE_PATH="`cd "$path"; $THEPWDCMD -L`"
44774   fi
44775 
44776 
44777   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44778 
44779   # Input might be given as Windows format, start by converting to
44780   # unix format.
44781   path="$POTENTIAL_FREETYPE_LIB_PATH"
44782   new_path=`$CYGPATH -u "$path"`
44783 
44784   # Cygwin tries to hide some aspects of the Windows file system, such that binaries are
44785   # named .exe but called without that suffix. Therefore, "foo" and "foo.exe" are considered
44786   # the same file, most of the time (as in "test -f"). But not when running cygpath -s, then
44787   # "foo.exe" is OK but "foo" is an error.
44788   #
44789   # This test is therefore slightly more accurate than "test -f" to check for file precense.
44790   # It is also a way to make sure we got the proper file name for the real test later on.
44791   test_shortpath=`$CYGPATH -s -m "$new_path" 2> /dev/null`
44792   if test "x$test_shortpath" = x; then
44793     { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
44794 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
44795     as_fn_error $? "Cannot locate the the path of POTENTIAL_FREETYPE_LIB_PATH" "$LINENO" 5
44796   fi
44797 
44798   # Call helper function which possibly converts this using DOS-style short mode.
44799   # If so, the updated path is stored in $new_path.
44800 
44801   input_path="$new_path"
44802   # Check if we need to convert this using DOS-style short mode. If the path
44803   # contains just simple characters, use it. Otherwise (spaces, weird characters),
44804   # take no chances and rewrite it.
44805   # Note: m4 eats our [], so we need to use [ and ] instead.
44806   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-._/a-zA-Z0-9]`
44807   if test "x$has_forbidden_chars" != x; then
44808     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44809     shortmode_path=`$CYGPATH -s -m -a "$input_path"`
44810     path_after_shortmode=`$CYGPATH -u "$shortmode_path"`
44811     if test "x$path_after_shortmode" != "x$input_to_shortpath"; then
44812       # Going to short mode and back again did indeed matter. Since short mode is
44813       # case insensitive, let's make it lowercase to improve readability.
44814       shortmode_path=`$ECHO "$shortmode_path" | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44815       # Now convert it back to Unix-stile (cygpath)
44816       input_path=`$CYGPATH -u "$shortmode_path"`
44817       new_path="$input_path"
44818     fi
44819   fi
44820 
44821   test_cygdrive_prefix=`$ECHO $input_path | $GREP ^/cygdrive/`
44822   if test "x$test_cygdrive_prefix" = x; then
44823     # As a simple fix, exclude /usr/bin since it's not a real path.
44824     if test "x`$ECHO $new_path | $GREP ^/usr/bin/`" = x; then
44825       # The path is in a Cygwin special directory (e.g. /home). We need this converted to
44826       # a path prefixed by /cygdrive for fixpath to work.
44827       new_path="$CYGWIN_ROOT_PATH$input_path"
44828     fi
44829   fi
44830 
44831 
44832   if test "x$path" != "x$new_path"; then
44833     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
44834     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
44835 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
44836   fi
44837 
44838   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44839 
44840   path="$POTENTIAL_FREETYPE_LIB_PATH"
44841   has_colon=`$ECHO $path | $GREP ^.:`
44842   new_path="$path"
44843   if test "x$has_colon" = x; then
44844     # Not in mixed or Windows style, start by that.
44845     new_path=`cmd //c echo $path`
44846   fi
44847 
44848 
44849   input_path="$new_path"
44850   # Check if we need to convert this using DOS-style short mode. If the path
44851   # contains just simple characters, use it. Otherwise (spaces, weird characters),
44852   # take no chances and rewrite it.
44853   # Note: m4 eats our [], so we need to use [ and ] instead.
44854   has_forbidden_chars=`$ECHO "$input_path" | $GREP [^-_/:a-zA-Z0-9]`
44855   if test "x$has_forbidden_chars" != x; then
44856     # Now convert it to mixed DOS-style, short mode (no spaces, and / instead of \)
44857     new_path=`cmd /c "for %A in (\"$input_path\") do @echo %~sA"|$TR \\\\\\\\ / | $TR 'ABCDEFGHIJKLMNOPQRSTUVWXYZ' 'abcdefghijklmnopqrstuvwxyz'`
44858   fi
44859 
44860 
44861   windows_path="$new_path"
44862   if test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.cygwin"; then
44863     unix_path=`$CYGPATH -u "$windows_path"`
44864     new_path="$unix_path"
44865   elif test "x$OPENJDK_BUILD_OS_ENV" = "xwindows.msys"; then
44866     unix_path=`$ECHO "$windows_path" | $SED -e 's,^\\(.\\):,/\\1,g' -e 's,\\\\,/,g'`
44867     new_path="$unix_path"
44868   fi
44869 
44870   if test "x$path" != "x$new_path"; then
44871     POTENTIAL_FREETYPE_LIB_PATH="$new_path"
44872     { $as_echo "$as_me:${as_lineno-$LINENO}: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&5
44873 $as_echo "$as_me: Rewriting POTENTIAL_FREETYPE_LIB_PATH to \"$new_path\"" >&6;}
44874   fi
44875 
44876   # Save the first 10 bytes of this path to the storage, so fixpath can work.
44877   all_fixpath_prefixes=("${all_fixpath_prefixes[@]}" "${new_path:0:10}")
44878 
44879   else
44880     # We're on a posix platform. Hooray! :)
44881     path="$POTENTIAL_FREETYPE_LIB_PATH"
44882     has_space=`$ECHO "$path" | $GREP " "`
44883     if test "x$has_space" != x; then
44884       { $as_echo "$as_me:${as_lineno-$LINENO}: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&5
44885 $as_echo "$as_me: The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is invalid." >&6;}
44886       as_fn_error $? "Spaces are not allowed in this path." "$LINENO" 5
44887     fi
44888 
44889     # Use eval to expand a potential ~
44890     eval path="$path"
44891     if test ! -f "$path" && test ! -d "$path"; then
44892       as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
44893     fi
44894 
44895     POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
44896   fi
44897 
44898 
44899     FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
44900     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
44901 $as_echo_n "checking for freetype includes... " >&6; }
44902     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
44903 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
44904     FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
44905     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
44906 $as_echo_n "checking for freetype libraries... " >&6; }
44907     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
44908 $as_echo "$FREETYPE_LIB_PATH" >&6; }
44909   fi
44910 
44911 
44912           if test "x$FOUND_FREETYPE" != xyes; then
44913             FREETYPE_BASE_DIR="$SYSROOT/usr/X11"
44914 
44915   POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
44916   POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib"
44917   METHOD="well-known location"
44918 
44919   # First check if the files exists.
44920   if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
44921     # We found an arbitrary include file. That's a good sign.
44922     { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
44923 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
44924     FOUND_FREETYPE=yes
44925 
44926     FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
44927     if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
44928       { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
44929 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
44930       FOUND_FREETYPE=no
44931     else
44932       if test "x$OPENJDK_TARGET_OS" = xwindows; then
44933         # On Windows, we will need both .lib and .dll file.


45184     if test ! -f "$path" && test ! -d "$path"; then
45185       as_fn_error $? "The path of POTENTIAL_FREETYPE_LIB_PATH, which resolves as \"$path\", is not found." "$LINENO" 5
45186     fi
45187 
45188     POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
45189   fi
45190 
45191 
45192     FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45193     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
45194 $as_echo_n "checking for freetype includes... " >&6; }
45195     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
45196 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
45197     FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
45198     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
45199 $as_echo_n "checking for freetype libraries... " >&6; }
45200     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
45201 $as_echo "$FREETYPE_LIB_PATH" >&6; }
45202   fi
45203 
45204           fi
45205 
45206           if test "x$FOUND_FREETYPE" != xyes; then
45207             FREETYPE_BASE_DIR="$SYSROOT/usr/sfw"
45208 
45209   POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
45210   POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib"
45211   METHOD="well-known location"
45212 
45213   # First check if the files exists.
45214   if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
45215     # We found an arbitrary include file. That's a good sign.
45216     { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
45217 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
45218     FOUND_FREETYPE=yes
45219 
45220     FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
45221     if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
45222       { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
45223 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
45224       FOUND_FREETYPE=no
45225     else
45226       if test "x$OPENJDK_TARGET_OS" = xwindows; then
45227         # On Windows, we will need both .lib and .dll file.


45481 
45482     POTENTIAL_FREETYPE_LIB_PATH="`cd "$path"; $THEPWDCMD -L`"
45483   fi
45484 
45485 
45486     FREETYPE_INCLUDE_PATH="$POTENTIAL_FREETYPE_INCLUDE_PATH"
45487     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype includes" >&5
45488 $as_echo_n "checking for freetype includes... " >&6; }
45489     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_INCLUDE_PATH" >&5
45490 $as_echo "$FREETYPE_INCLUDE_PATH" >&6; }
45491     FREETYPE_LIB_PATH="$POTENTIAL_FREETYPE_LIB_PATH"
45492     { $as_echo "$as_me:${as_lineno-$LINENO}: checking for freetype libraries" >&5
45493 $as_echo_n "checking for freetype libraries... " >&6; }
45494     { $as_echo "$as_me:${as_lineno-$LINENO}: result: $FREETYPE_LIB_PATH" >&5
45495 $as_echo "$FREETYPE_LIB_PATH" >&6; }
45496   fi
45497 
45498           fi
45499 
45500           if test "x$FOUND_FREETYPE" != xyes; then
45501             FREETYPE_BASE_DIR="$SYSROOT/usr"
45502             if test "x$OPENJDK_TARGET_CPU_BITS" = x64; then
45503 
45504   POTENTIAL_FREETYPE_INCLUDE_PATH="$FREETYPE_BASE_DIR/include"
45505   POTENTIAL_FREETYPE_LIB_PATH="$FREETYPE_BASE_DIR/lib/x86_64-linux-gnu"
45506   METHOD="well-known location"
45507 
45508   # First check if the files exists.
45509   if test -s "$POTENTIAL_FREETYPE_INCLUDE_PATH/ft2build.h"; then
45510     # We found an arbitrary include file. That's a good sign.
45511     { $as_echo "$as_me:${as_lineno-$LINENO}: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&5
45512 $as_echo "$as_me: Found freetype include files at $POTENTIAL_FREETYPE_INCLUDE_PATH using $METHOD" >&6;}
45513     FOUND_FREETYPE=yes
45514 
45515     FREETYPE_LIB_NAME="${LIBRARY_PREFIX}freetype${SHARED_LIBRARY_SUFFIX}"
45516     if ! test -s "$POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME"; then
45517       { $as_echo "$as_me:${as_lineno-$LINENO}: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&5
45518 $as_echo "$as_me: Could not find $POTENTIAL_FREETYPE_LIB_PATH/$FREETYPE_LIB_NAME. Ignoring location." >&6;}
45519       FOUND_FREETYPE=no
45520     else
45521       if test "x$OPENJDK_TARGET_OS" = xwindows; then


46957       fi
46958       ALSA=$depdir
46959       if test "x$theroot" != x; then
46960         ALSA="$theroot"
46961       fi
46962       if test "x$thecflags" != x; then
46963         ALSA_CFLAGS="$thecflags"
46964       fi
46965       if test "x$thelibs" != x; then
46966         ALSA_LIBS="$thelibs"
46967       fi
46968       ALSA_FOUND=yes
46969       else ALSA_FOUND=no
46970 
46971     fi
46972     else ALSA_FOUND=no
46973 
46974   fi
46975 
46976     fi
46977     # Do not try pkg-config if we have a sysroot set.
46978     if test "x$SYSROOT" = x; then
46979       if test "x$ALSA_FOUND" = xno; then
46980 
46981 pkg_failed=no
46982 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for ALSA" >&5
46983 $as_echo_n "checking for ALSA... " >&6; }
46984 
46985 if test -n "$ALSA_CFLAGS"; then
46986     pkg_cv_ALSA_CFLAGS="$ALSA_CFLAGS"
46987  elif test -n "$PKG_CONFIG"; then
46988     if test -n "$PKG_CONFIG" && \
46989     { { $as_echo "$as_me:${as_lineno-$LINENO}: \$PKG_CONFIG --exists --print-errors \"alsa\""; } >&5
46990   ($PKG_CONFIG --exists --print-errors "alsa") 2>&5
46991   ac_status=$?
46992   $as_echo "$as_me:${as_lineno-$LINENO}: \$? = $ac_status" >&5
46993   test $ac_status = 0; }; then
46994   pkg_cv_ALSA_CFLAGS=`$PKG_CONFIG --cflags "alsa" 2>/dev/null`
46995 else
46996   pkg_failed=yes
46997 fi
46998  else


47028                 ALSA_PKG_ERRORS=`$PKG_CONFIG --short-errors --print-errors "alsa" 2>&1`
47029         else
47030                 ALSA_PKG_ERRORS=`$PKG_CONFIG --print-errors "alsa" 2>&1`
47031         fi
47032         # Put the nasty error message in config.log where it belongs
47033         echo "$ALSA_PKG_ERRORS" >&5
47034 
47035         { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5
47036 $as_echo "no" >&6; }
47037                 ALSA_FOUND=no
47038 elif test $pkg_failed = untried; then
47039         ALSA_FOUND=no
47040 else
47041         ALSA_CFLAGS=$pkg_cv_ALSA_CFLAGS
47042         ALSA_LIBS=$pkg_cv_ALSA_LIBS
47043         { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
47044 $as_echo "yes" >&6; }
47045         ALSA_FOUND=yes
47046 fi
47047       fi
47048     fi
47049     if test "x$ALSA_FOUND" = xno; then
47050       for ac_header in alsa/asoundlib.h
47051 do :
47052   ac_fn_cxx_check_header_mongrel "$LINENO" "alsa/asoundlib.h" "ac_cv_header_alsa_asoundlib_h" "$ac_includes_default"
47053 if test "x$ac_cv_header_alsa_asoundlib_h" = xyes; then :
47054   cat >>confdefs.h <<_ACEOF
47055 #define HAVE_ALSA_ASOUNDLIB_H 1
47056 _ACEOF
47057 
47058             ALSA_FOUND=yes
47059             ALSA_CFLAGS=-Iignoreme
47060             ALSA_LIBS=-lasound
47061             DEFAULT_ALSA=yes
47062 
47063 else
47064   ALSA_FOUND=no
47065 fi
47066 
47067 done
47068 


47907       fi
47908     done
47909 
47910     unset LLVM_LIBS
47911     for flag in $("${LLVM_CONFIG}" --libs ${llvm_components}); do
47912       if echo "${flag}" | grep -q '^-l'; then
47913         if test "${LLVM_LIBS}" != ""; then
47914           LLVM_LIBS="${LLVM_LIBS} "
47915         fi
47916         LLVM_LIBS="${LLVM_LIBS}${flag}"
47917       fi
47918     done
47919 
47920 
47921 
47922 
47923   fi
47924 
47925   # libCrun is the c++ runtime-library with SunStudio (roughly the equivalent of gcc's libstdc++.so)
47926   if test "x$TOOLCHAIN_TYPE" = xsolstudio && test "x$LIBCXX" = x; then
47927     LIBCXX="${SYSROOT}/usr/lib${OPENJDK_TARGET_CPU_ISADIR}/libCrun.so.1"
47928   fi
47929 
47930   # TODO better (platform agnostic) test
47931   if test "x$OPENJDK_TARGET_OS" = xmacosx && test "x$LIBCXX" = x && test "x$TOOLCHAIN_TYPE" = xgcc; then
47932     LIBCXX="-lstdc++"
47933   fi
47934 
47935 
47936 
47937 
47938   if test "x$OPENJDK_TARGET_OS" = "xwindows"; then
47939 
47940 
47941 # Check whether --with-msvcr-dll was given.
47942 if test "${with_msvcr_dll+set}" = set; then :
47943   withval=$with_msvcr_dll;
47944 fi
47945 
47946 
47947   if test "x$with_msvcr_dll" != x; then


48832 
48833 
48834 
48835 
48836 # Setup use of ccache, if available
48837 
48838   # Check whether --enable-ccache was given.
48839 if test "${enable_ccache+set}" = set; then :
48840   enableval=$enable_ccache;
48841 fi
48842 
48843 
48844   CCACHE=
48845   { $as_echo "$as_me:${as_lineno-$LINENO}: checking is ccache enabled" >&5
48846 $as_echo_n "checking is ccache enabled... " >&6; }
48847   ENABLE_CCACHE=$enable_ccache
48848   if test "x$enable_ccache" = xyes; then
48849     { $as_echo "$as_me:${as_lineno-$LINENO}: result: yes" >&5
48850 $as_echo "yes" >&6; }
48851     OLD_PATH="$PATH"
48852     if test "x$TOOLCHAIN_PATH" != x; then
48853       PATH=$TOOLCHAIN_PATH:$PATH
48854     fi
48855 
48856 
48857 
48858   # Publish this variable in the help.
48859 
48860 
48861   if test "x$CCACHE" = x; then
48862     # The variable is not set by user, try to locate tool using the code snippet
48863     for ac_prog in ccache
48864 do
48865   # Extract the first word of "$ac_prog", so it can be a program name with args.
48866 set dummy $ac_prog; ac_word=$2
48867 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
48868 $as_echo_n "checking for $ac_word... " >&6; }
48869 if ${ac_cv_path_CCACHE+:} false; then :
48870   $as_echo_n "(cached) " >&6
48871 else
48872   case $CCACHE in
48873   [\\/]* | ?:[\\/]*)