Sanity.gmk revision 3603
2362N/A# Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved. 0N/A# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 0N/A# This code is free software; you can redistribute it and/or modify it 0N/A# under the terms of the GNU General Public License version 2 only, as 2362N/A# published by the Free Software Foundation. Oracle designates this 0N/A# particular file as subject to the "Classpath" exception as provided 2362N/A# by Oracle in the LICENSE file that accompanied this code. 0N/A# This code is distributed in the hope that it will be useful, but WITHOUT 0N/A# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 0N/A# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 0N/A# version 2 for more details (a copy is included in the LICENSE file that 0N/A# accompanied this code). 0N/A# You should have received a copy of the GNU General Public License version 0N/A# 2 along with this work; if not, write to the Free Software Foundation, 0N/A# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 2362N/A# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 0N/A# WARNING: This file is shared with other workspaces. 0N/A# Shared sanity rules for the JDK builds. 0N/A# All files created during sanity checking 0N/A# How to say "The Release Engineering people use this" 0N/A# How to say "You are using:" 914N/A# Official version error message: name version required_version 914N/A# Official version warning message: name version required_version 0N/A# Settings and rules to validate the JDK build environment. 914N/A # What kind of system we are using (Variations are Solaris and OpenSolaris) 914N/A # What kind of system we are using (Variation is the Linux vendor) 914N/A # Windows 2000 is 5.0, Windows XP is 5.1, Windows 2003 is 5.2 914N/A # Assume 5.0 (Windows 2000) if systeminfo does not help 914N/A # What kind of system we are using (Variation is the common name) 0N/A# Get the version numbers of what we are using 0N/A# Get ALL_SETTINGS defined 0N/A###################################################### 0N/A# check for COPYRIGHT_YEAR variable 0N/A###################################################### 0N/A @
$(ECHO) "WARNING: ALT_COPYRIGHT_YEAR but not the current year\n" \
0N/A " will be used for copyright year.\n " \
0N/A###################################################### 0N/A# check for INSANE variable 0N/A###################################################### 0N/A @
$(ECHO) "WARNING: You are building in 'INSANE' mode. You \n" \
0N/A " should not use this mode, and in fact, \n" \
0N/A " it may be removed at any time. If you \n" \
0N/A " have build problems as a result of using \n" \
0N/A " INSANE mode, then you should not expect \n" \
0N/A " assistance from anyone with the problems \n" \
0N/A " or consequences you experience. \n" \
0N/A###################################################### 0N/A# check for GNU Make version 0N/A###################################################### 3436N/A $(ECHO) "ERROR: The version of make being used is older than \n" \
0N/A###################################################### 0N/A# Check the BUILD_NUMBER to make sure it contains bNN 0N/A###################################################### 0N/A $(ECHO) "WARNING: The BUILD_NUMBER needs to contain b[0-9][0-9]*. Currently BUILD_NUMBER=$(BUILD_NUMBER). \n" \
0N/A " This has been known to cause build failures. \n" \
0N/A###################################################### 0N/A# Check the ARCH_DATA_MODEL setting 0N/A###################################################### 0N/A $(ECHO) "ERROR: The setting of ARCH_DATA_MODEL must be 32 or 64.\n" \
0N/A###################################################### 3218N/A# Check the OS version (windows and linux have release name checks) 0N/A# NOTE: OPENJDK explicitly does not check for OS release information. 0N/A# Unless we know for sure that it will not build somewhere, we cannot 0N/A# generate a fatal sanity error, and a warning about the official 0N/A# build platform just becomes clutter. 0N/A###################################################### 0N/A###################################################### 0N/A# Check the memory available on this machine 0N/A###################################################### 0N/A $(ECHO) "WARNING: This machine appears to only have $(MB_OF_MEMORY)Mb of physical memory, \n" \
0N/A " builds on this machine could be slow. \n" \
0N/A###################################################### 0N/A# Check the locale (value of LC_ALL, not being empty or ==C can be a problem) 0N/A###################################################### 0N/A $(ECHO) "WARNING: LC_ALL has been set to $(LC_ALL), this can cause build failures. \n" \
0N/A " Try setting LC_ALL to \"C\". \n" \
0N/A $(ECHO) "WARNING: LANG has been set to $(LANG), this can cause build failures. \n" \
0N/A " Try setting LANG to \"C\". \n" \
0N/A###################################################### 0N/A# Check the Windows cygwin version 0N/A###################################################### 0N/A###################################################### 0N/A###################################################### 0N/A @
if [
"$(SHLVL)" =
"" -a
"$(_)" =
"" ];
then \
0N/A $(ECHO) "ERROR: You are using an unsupported shell. \n" \
0N/A " Use either sh, bash, ksh, zsh, or tcsh. \n" \
0N/A " Using the cmd.exe utility is not supported. \n" \
0N/A " If you still want to try your current shell, \n" \
0N/A " please export SHLVL=1 when running $(MAKE). \n" \
0N/A###################################################### 0N/A# Check the Windows mks version 0N/A###################################################### 0N/A###################################################### 0N/A# Get list of installed patches (this file has a particular format) 0N/A###################################################### 0N/A###################################################### 0N/A# Check list of Solaris patches 0N/A###################################################### 0N/A readingInstallPatches = 0; \ 0N/A requiredCount = 0; \ 0N/A if (readingInstallPatches) { \ 0N/A if ($$1=="Patch:") { \ 0N/A ns = split($$2,parts,"-"); \ 0N/A installPatchNo[installCount]=parts[1]; \ 0N/A installPatchRev[installCount]=parts[2]; \ 0N/A if (!readingInstallPatches) { \ 0N/A if (index($$1,"#") != 0) continue; \ 0N/A if (match($$1,"BUILD") > 0 \ 0N/A && $$2 == $(OS_VERSION) \ 0N/A && ($$7 == "REQ" || $$7 == "req") \ 0N/A && $(PATCH_POSITION) != "none" \ 0N/A && $(PATCH_POSITION) != "NONE") { \ 0N/A ns = split($(PATCH_POSITION),parts,"-"); \ 0N/A requiredPatchNo[requiredCount]=parts[1]; \ 0N/A requiredPatchRev[requiredCount]=parts[2]; \ 0N/A for (i=0; i<requiredCount; i++) { \ 0N/A for (j=0; j<installCount; j++) { \ 0N/A if (installPatchNo[j] == requiredPatchNo[i] \ 0N/A && installPatchRev[j] >= requiredPatchRev[i]) { \ 0N/A if ( foundMatch == 0) { \ 0N/A printf("WARNING: Your solaris install is missing the required patch %s-%s\n", requiredPatchNo[i], requiredPatchRev[i] ); \ 0N/A printf(" Please update your your system patches or build on a different machine.\n\n" ); \ 0N/A###################################################### 0N/A# CLASSPATH cannot be set, unless you are insane. 0N/A###################################################### 0N/A @
$(ECHO) "ERROR: Your CLASSPATH environment variable is set. This will \n" \
0N/A " most likely cause the build to fail. Please unset it \n" \
0N/A " and start your build again. \n" \
0N/A###################################################### 0N/A# JAVA_HOME cannot be set, unless you are insane. 0N/A###################################################### 0N/A @
$(ECHO) "ERROR: Your JAVA_HOME environment variable is set. This will \n" \
0N/A " most likely cause the build to fail. Please unset it \n" \
0N/A " and start your build again. \n" \
0N/A###################################################### 0N/A# Make sure the fonts are there 0N/A# Exceptions are when explicitly building OPENJDK, or 0N/A# when the entire CLOSED_SRC dir is excluded, so we are 0N/A# implicitly building OPENJDK 0N/A###################################################### 0N/A " Verify you have downloaded and overlayed on the source area all the binary files. \n" \
0N/A###################################################### 0N/A# VARIANT must be set to DBG or OPT 0N/A###################################################### 0N/A $(ECHO) "ERROR: Your VARIANT environment variable is set to $(VARIANT). \n" \
0N/A " Needs to be set to DBG or OPT \n" \
0N/A###################################################### 0N/A# LD_LIBRARY_PATH should not be set, unless you are insane. 0N/A###################################################### 0N/A @
$(ECHO) "ERROR: Your LD_LIBRARY_PATH environment variable is set. This may \n" \
0N/A " produce binaries binaries incorrectly. Please unset it \n" \
0N/A " and start your build again. \n" \
0N/A###################################################### 0N/A# LD_LIBRARY_PATH_64 should not be set, unless you are insane. 0N/A###################################################### 0N/A @
$(ECHO) "ERROR: Your LD_LIBRARY_PATH_64 environment variable is set. This may \n" \
0N/A " produce binaries binaries incorrectly. Please unset it \n" \
0N/A " and start your build again. \n" \
0N/A###################################################### 0N/A# LD_OPTIONS should not be set, unless you are insane. 0N/A###################################################### 0N/A @
$(ECHO) "ERROR: Your LD_OPTIONS environment variable is set. This may \n" \
0N/A " produce binaries binaries incorrectly. Please unset it \n" \
0N/A " and start your build again. \n" \
0N/A###################################################### 0N/A# LD_RUN_PATH should not be set, unless you are insane. 0N/A###################################################### 0N/A @
$(ECHO) "ERROR: Your LD_RUN_PATH environment variable is set. This may \n" \
0N/A " produce binaries binaries incorrectly. Please unset it \n" \
0N/A " produce binaries binaries incorrectly. Please unset it \n" \
0N/A " and start your build again. \n" \
0N/A###################################################### 0N/A# MAKEFLAGS cannot be set, unless you are insane. 0N/A###################################################### 0N/A# ifneq ($(strip $(REAL_MAKEFLAGS)),) 0N/A @
# it is unacceptable to have the-e or --environment-overrides value in MAKEFLAGS 0N/A $(ECHO) "ERROR: Either the build was started with the flag -e or \n" \
0N/A " --environment-overrides, or the MAKEFLAGS environment \n" \
0N/A " variable has this value set. This will cause any \n" \
0N/A " environment variables you have defined to override \n" \
0N/A " the values defined by the makefiles. This practice is \n" \
0N/A " not recommemded by the authors of GNU Make, and \n" \
0N/A " will lead to an improper build. \n" \
0N/A " Please fix and restart the build. \n" \
0N/A @
# it is unacceptable to havethe -i or --ignore-errors value in MAKEFLAGS 0N/A $(ECHO) "ERROR: Either the build was started with the flag -i or \n" \
0N/A " --ignore-errors, or the MAKEFLAGS environment \n" \
0N/A " variable has this value set. 1111 You will be unable \n" \
0N/A " to determine if the build is broken or not. \n" \
0N/A " Please fix and restart the build. \n" \
0N/A @
# it is unacceptable to have the -I or --include-dir value in MAKEFLAGS 0N/A $(ECHO) "ERROR: Either the build was started with the flag -I or \n" \
0N/A " --include-dir, or the MAKEFLAGS environment \n" \
0N/A " variable has this value set. This will render your \n" \
0N/A " build questionable as not all the rules and depenencies \n" \
0N/A " are captured by the build. \n" \
0N/A " Please fix and restart the build. \n" \
0N/A @
# it is unacceptable to have the -k or --keep-going value in MAKEFLAGS: 0N/A $(ECHO) "ERROR: Either the build was started with the flag -k or \n" \
0N/A " --keep-going, or the MAKEFLAGS environment \n" \
0N/A " variable has this value set. 222 You will be unable \n" \
0N/A " to determine if the build is broken or not. \n" \
0N/A " Please fix and restart the build. \n" \
0N/A @
# it is unacceptable to have the -o or --assume-old or --old-filevalue in MAKEFLAGS: 0N/A @
# Note - this rule never gets invoked because it is processed out 0N/A @
# in GNU Make startup 0N/A $(ECHO) "ERROR: Either the build was started with the flag -o or \n" \
0N/A " --assume-old or --old-file, or the MAKEFLAGS environment \n" \
0N/A " variable has this value set. This could prevent the \n" \
0N/A " build from executing rules it should, thus rendering a \n" \
0N/A " questionable result. \n" \
0N/A " Please fix and restart the build. \n" \
0N/A @
# it is unacceptable to have the -r or --nobuiltin-rules value in MAKEFLAGS 0N/A $(ECHO) "ERROR: Either the build was started with the flag -r or \n" \
0N/A " --no-builtin-rules, or the MAKEFLAGS environment \n" \
0N/A " variable has this value set. This may break the build \n" \
0N/A " by not allowing builtin rules that may be required. \n" \
0N/A " Please fix and restart the build. \n" \
0N/A @
# it is unacceptable to have the -t or --touch value in MAKEFLAGS 0N/A @
# Note - this rule never gets invoked because it is processed out 0N/A @
# in GNU Make startup 0N/A $(ECHO) "ERROR: Either the build was started with the flag -t or \n" \
0N/A " --touch, or the MAKEFLAGS environment \n" \
0N/A " variable has this value set. This will leave the \n" \
0N/A " build in a unclear state and could lead to not executing \n" \
0N/A " rules which should be executed. \n" \
0N/A " Please fix and restart the build. \n" \
0N/A @
# show what is in MAKEFLAGS so the user is aware... 0N/A @
$(ECHO) "WARNING: Your MAKEFLAGS environment variable is set. \n" \
0N/A " You should be very careful about the values set here. \n" \
0N/A###################################################### 0N/A# if specified, ALT_OUTPUTDIR must point to non-relative path if set 0N/A###################################################### 0N/A $(ECHO) "ERROR: ALT_OUTPUTDIR must be an Absolute Path Name, \n" \
0N/A " not a Relative Path Name. \n" \
0N/A $(ECHO) "ERROR: On windows, ALT_OUTPUTDIR must contain the drive letter. \n" \
0N/A###################################################### 0N/A###################################################### 0N/A @
# OUTPUTDIR must be a directory... 0N/A $(ECHO) "ERROR: OUTPUTDIR must be an existing directory. The current \n" \
0N/A " value of OUTPUTDIR is \n" \
0N/A " Please check your value of ALT_OUTPUTDIR. \n" \
0N/A @
# OUTPUTDIR must be writeable by user... 0N/A $(ECHO) "ERROR: You must have write permissions to OUTPUTDIR. The \n" \
0N/A " current value of OUTPUTDIR is \n" \
0N/A " Either obtain these permissions or set ALT_OUTPUTDIR. \n" \
0N/A @
# OUTPUTDIR must have enough free space... 0N/A $(ECHO) "WARNING: You may not have enough free space in your OUTPUTDIR. The \n" \
0N/A " current value of OUTPUTDIR is \n" \
0N/A " and it appears that only "$(FREE_SPACE)" Kbytes are free. \n" \
0N/A " Either obtain more space or set ALT_OUTPUTDIR to a larger disk. \n" \
0N/A###################################################### 0N/A# if specified, ALT_BOOTDIR must point to non-relative path if set 0N/A###################################################### 0N/A $(ECHO) "ERROR: ALT_BOOTDIR must be an Absolute Path Name, \n" \
0N/A " not a Relative Path Name. \n" \
0N/A " The current value of ALT_BOOTDIR is \n" \
0N/A " Please fix this and continue your build. \n" \
0N/A###################################################### 0N/A# BOOTDIR must point to a valid JDK. 0N/A###################################################### 0N/A $(ECHO) "ERROR: Your BOOTDIR environment variable does not point \n" \
0N/A " to a valid JDK for bootstrapping this build. \n" \
0N/A " Apparently, your bootstrap JDK is version $(BOOT_VER) \n" \
0N/A " Please update your ALT_BOOTDIR setting and start your build again. \n" \
0N/A###################################################### 1220N/A# BOOTDIR is recommended to reside on a local drive 1220N/A###################################################### 1220N/A $(ECHO) "WARNING: Your BOOTDIR is located on the J: drive. Often the J:\n" \
1220N/A " drive is mapped over a network. Using a mapped drive for\n" \
1220N/A " the BOOTDIR may significantly slow down the build process.\n" \
1220N/A " You may want to consider using the ALT_BOOTDIR variable\n" \
1220N/A " to point the build to another location for the BOOTDIR instead. \n" \
1220N/A " Your current BOOTDIR is:\n" \
1220N/A###################################################### 0N/A# CACERTS_FILE must be absoulte path and readable 0N/A###################################################### 0N/A $(ECHO) "ERROR: ALT_CACERTS_FILE must be an Absolute Path Name, \n" \
0N/A " not a Relative Path Name. \n" \
0N/A " The current value of ALT_CACERTS_FILE is \n" \
0N/A " Please fix this and continue your build. \n" \
0N/A @
# CACERTS_FILE must be readable 0N/A $(ECHO) "ERROR: You do not have access to a valid cacerts file. \n" \
0N/A " Please check your access to \n" \
0N/A " and/or check your value of ALT_CACERTS_FILE. \n" \
0N/A @
# CACERTS_FILE must be a file 0N/A $(ECHO) "ERROR: You do not have access to a valid cacerts file.\n" \
0N/A " The value of CACERTS_FILE must point to a normal file.\n" \
0N/A " Please check your access to \n" \
0N/A " and/or check your value of ALT_CACERTS_FILE. \n" \
0N/A###################################################### 0N/A# Check for availability of FreeType (OpenJDK specific) 0N/A###################################################### 165N/A# The freetypecheck Makefile prints out "Failed" if not good enough 165N/A $(ECHO) "Failed to build freetypecheck." ) > $@
165N/A " or higher is required. \n" \
0N/A#do nothing (not OpenJDK) 0N/A###################################################### 2157N/A# if specified, BUILD_MODULES must contain valid values. 2157N/A###################################################### 2157N/A $(ECHO) "ERROR: $$m set in the BUILD_MODULES variable is invalid.\n" \
2157N/A###################################################### 0N/A# CUPS_HEADERS_PATH must be valid 0N/A###################################################### 0N/A $(ECHO) "ERROR: You do not have access to valid Cups header files. \n" \
0N/A " Please check your access to \n" \
0N/A " and/or check your value of ALT_CUPS_HEADERS_PATH, \n" \
0N/A " CUPS is frequently pre-installed on many systems, \n" \
0N/A###################################################### 0N/A# Check for existence of DEVTOOLS_PATH 0N/A###################################################### 0N/A $(ECHO) "ERROR: You do not have a valid DEVTOOLS_PATH setting. \n" \
0N/A " Please check your access to \n" \
0N/A " and/or check your value of ALT_DEVTOOLS_PATH. \n" \
0N/A###################################################### 0N/A# Check for existence of MS_RUNTIME_LIBRARIES 0N/A###################################################### 0N/A " Please check your access to \n" \
795N/A " and/or check your value of ALT_MSVCRNN_DLL_PATH. \n" \
0N/A###################################################### 0N/A# Check for existence of COMPILER_PATH 0N/A###################################################### 0N/A $(ECHO) "ERROR: You do not have a valid COMPILER_PATH setting. \n" \
0N/A " Please check your access to \n" \
0N/A " and/or check your value of ALT_COMPILER_PATH. \n" \
0N/A###################################################### 0N/A# Check for existence of UNIXCOMMAND_PATH 0N/A###################################################### 0N/A $(ECHO) "ERROR: You do not have a valid UNIXCOMMAND_PATH setting. \n" \
0N/A " Please check your access to \n" \
0N/A " and/or check your value of ALT_UNIXCOMMAND_PATH. \n" \
0N/A $(ECHO) "WARNING: You do not have the utility $${utility} in the \n" \
0N/A " The utilities cpio, ar, file, and m4 are required. \n" \
0N/A###################################################### 0N/A# Check for existence of USRBIN_PATH on linux 0N/A###################################################### 0N/A $(ECHO) "ERROR: You do not have a valid USRBIN_PATH setting. \n" \
0N/A " Please check your access to \n" \
0N/A " and/or check your value of ALT_USRBIN_PATH. \n" \
0N/A###################################################### 0N/A# Check for existence of UNIXCCS_PATH on solaris 0N/A###################################################### 0N/A $(ECHO) "ERROR: You do not have a valid UNIXCCS_PATH setting. \n" \
0N/A " Please check your access to \n" \
0N/A " and/or check your value of ALT_UNIXCCS_PATH. \n" \
0N/A###################################################### 0N/A# Verify the docs directory exists 0N/A###################################################### 0N/A " does not exist, check your value of ALT_HOTSPOT_DOCS_IMPORT_PATH. \n" \
0N/A###################################################### 0N/A# Check for possible problem regarding __fabsf, math_iso.h and the libm patch. 0N/A# Hotspot should have been changed in Mustang 6.0 Build 47 to not depend 0N/A# on __fabsf, this is just checking that fact now. 0N/A###################################################### 0N/A $(ECHO) "WARNING: This version of hotspot relies on __fabsf \n" \
0N/A " which is not always available on Solaris 8 and 9 machines \n" \
0N/A " unless they have the latest libm patch and the file \n" \
0N/A " Hotspot should NOT be dependent on this extern, check the \n" \
0N/A " version of the hotspot library you are using. \n" \
0N/A###################################################### 0N/A###################################################### 0N/A " __1c2n6FIpv_0_ which indicates that the system is missing \n" \
0N/A " a required Solaris patch, or you are using a pre-FCS release \n" \
0N/A " which comes with the FCS release of Solaris 10 and available \n" \
0N/A " through the latest Solaris 8 or 9 C++ runtime patches. \n" \
0N/A###################################################### 3258N/A# Check for existence of the extra tools on windows 0N/A###################################################### 0N/A $(ECHO) "ERROR: You do not have a valid MSDEVTOOLS_PATH setting. \n" \
0N/A " Please check your access to \n" \
0N/A " and/or check your value of ALT_MSDEVTOOLS_PATH. \n" \
3419N/A @
$(ECHO) "ERROR: Cannot find the RC utility from path: $(RC)\n" \
3419N/A " This is normally obtained from the WINDOWSSDKDIR." \
3603N/A " This is normally obtained from the COMPILER_PATH." \
0N/A###################################################### 0N/A# Check for existence of Hotspot binaries 0N/A###################################################### 0N/A $(ECHO) "ERROR: HOTSPOT_CLIENT_PATH does not point to a valid HotSpot VM. \n" \
0N/A " Please check your access to \n" \
0N/A " and/or check your value of ALT_HOTSPOT_CLIENT_PATH. \n" \
0N/A $(ECHO) "ERROR: HOTSPOT_SERVER_PATH does not point to a valid HotSpot VM. \n" \
0N/A " Please check your access to \n" \
0N/A " and/or check your value of ALT_HOTSPOT_SERVER_PATH. \n" \
0N/A @
# Check value of HOTSPOT_LIB_PATH 0N/A $(ECHO) "ERROR: HOTSPOT_LIB_PATH does not point to a valid HotSpot library. \n" \
0N/A " Please check your access to \n" \
0N/A " and/or check your value of ALT_HOTSPOT_LIB_PATH. \n" \
0N/A @
# Check for the .map files - its OK if they are not there.. 0N/A @
# There is no 64-bit HotSpot client VM 0N/A $(ECHO) "WARNING: HOTSPOT_CLIENT_PATH does not point to valid HotSpot .map files. \n" \
0N/A " These files are optional and aid in the debugging of the JVM. \n" \
0N/A " Please check your access to \n" \
0N/A " and/or check your value of ALT_HOTSPOT_CLIENT_PATH. \n" \
0N/A $(ECHO) "WARNING: HOTSPOT_CLIENT_PATH does not point to valid HotSpot .pdb files. \n" \
0N/A " These files are optional and aid in the debugging of the JVM. \n" \
0N/A " Please check your access to \n" \
0N/A " and/or check your value of ALT_HOTSPOT_CLIENT_PATH. \n" \
0N/A $(ECHO) "WARNING: HOTSPOT_SERVER_PATH does not point to valid HotSpot .map files. \n" \
0N/A " These files are optional and aid in the debugging of the JVM. \n" \
0N/A " Please check your access to \n" \
0N/A " and/or check your value of ALT_HOTSPOT_SERVER_PATH. \n" \
0N/A $(ECHO) "WARNING: HOTSPOT_SERVER_PATH does not point to valid HotSpot .pdb files. \n" \
0N/A " These files are optional and aid in the debugging of the JVM. \n" \
0N/A " Please check your access to \n" \
0N/A " and/or check your value of ALT_HOTSPOT_SERVER_PATH. \n" \
0N/A###################################################### 0N/A# Check for existence of misc Hotspot imported files 0N/A###################################################### 0N/A# where MACRO, MINOR, and MICRO are numbers, e.g. 1.0.1, 0.2.90, etc. 0N/A# The critical version we are checking is MAJOR.MINOR, we print all three 0N/A# when we detect an error. 0N/A $(SED) -e
's@.*\([0-9][0-9]*\.[0-9][0-9]*\)\.[0-9].*@\1@' 0N/A $(SED) -e
's@.*\([0-9][0-9]*\.[0-9][0-9]*\.[0-9][0-9]*\).*@\1@' 0N/A# Compare an interface file (Rule creates 2 temp files: %.h and %.h.IMPORT) 0N/A# exported but do represent VM interfaces used by the rest of the jdk. 0N/A# So these 3 will not be found in a promoted build and can only 0N/A# be checked when this represents a full control build (i.e. the 0N/A# HOTSPOT_IMPORT_PATH includes these files in it's 'include' directory). 0N/A $(ECHO) "WARNING: HOTSPOT_IMPORT_PATH does not contain the interface file $(@F). \n" \
0N/A " Check your value of ALT_HOTSPOT_IMPORT_PATH. \n" \
0N/A $(ECHO) "WARNING: HOTSPOT_IMPORT_PATH does not contain the interface file $(@F). \n" \
0N/A " Check your value of ALT_HOTSPOT_IMPORT_PATH. \n" \
0N/A# Compares the two tempfiles: %.h and %.h.IMPORT, answer in %.hdiffs 0N/A# Note: Putting anything into the hdiffs file will trigger generic IMPORT 0N/A# warning message in hotspot_import_include. 0N/A# Second checks the full version. 0N/A# Lastly does a full diff if the full version differs or it has no version 0N/A $(ECHO) "WARNING: The file $(<F) is not the same interface as the VM version.\n " \
0N/A $(ECHO) "Version mis-match" > $@ ; \
0N/A# Verify all imported hotspot files 0N/A# Verify the base directory exists 0N/A " does not exist, check your value of ALT_HOTSPOT_IMPORT_PATH. \n" \
0N/A# Verify hotspot include files 0N/A $(ECHO) "WARNING: Possible HotSpot VM interface conflict. \n" \
0N/A " HOTSPOT_IMPORT_PATH is used to import files from the VM build. \n" \
0N/A " It is also used to verify that any copied files are consistent between \n" \
0N/A " these two components. It has been detected that one or more of the \n" \
0N/A " VM interface files inside this workspace may not match the interfaces \n" \
0N/A " exported by the VM, or the VM versions could not be found. \n" \
0N/A " The list of VM interface files is: \n" \
0N/A " This workspace has copies of these files at: \n" \
0N/A " for build purposes, and they should contain the same interfaces \n" \
0N/A " as the VM versions imported from: \n" \
0N/A " If an interface indeed doesn't match, then the use of this interface \n" \
0N/A " at JDK runtime could cause serious errors. \n" \
0N/A if [ -s $$i ] ;
then \
0N/A# The JDI-SA feature is not currently released on some platforms. 0N/A# See the Defs-<arch>.gmk files. 0N/A# Verify that hotspot Serviceability Agent files are present. To keep 0N/A# it simple, we will just check for one of them. The others have arch 0N/A " The JDI binding for the Serviceability Agent will not be included in the build.\n" \
0N/A " Please check your access to\n" \
0N/A " and/or check your value of ALT_HOTSPOT_IMPORT_PATH.\n" \
0N/A###################################################### 0N/A# Check the ant version 0N/A###################################################### 3435N/A $(ECHO) "ERROR: The version of ant being used is older than \n" \
0N/A " The version of ant found was '$(ANT_VER)'. \n" \
0N/A###################################################### 0N/A# Check the zip file version 0N/A###################################################### 0N/A $(ECHO) "WARNING: The version of zip being used is older than \n" \
0N/A " The version of zip found was '$(ZIP_VER)'. \n" \
0N/A###################################################### 0N/A# Check the unzip file version 0N/A###################################################### 0N/A $(ECHO) "WARNING: The version of unzip being used is older than \n" \
0N/A###################################################### 0N/A# Check for windows DirectX sdk directory 0N/A###################################################### 0N/A $(ECHO) "ERROR: You do not have access to a valid DirectX SDK Include dir.\n" \
0N/A " The value of DXSDK_INCLUDE_PATH must point a valid DX SDK dir.\n" \
0N/A " Please check your access to \n" \
0N/A " and/or check your value of ALT_DXSDK_PATH or ALT_DXSDK_INCLUDE_PATH.\n" \
0N/A " Microsoft DirectX 9 SDK (Summer 2004 Update or newer) can be downloaded from the following location:\n" \
0N/A " The DirectX SDK was obtained from the following location: \n" \
0N/A " Please change your DirectX SDK. \n" \
0N/A " Microsoft DirectX 9 SDK (Summer 2004 Update or newer) can be downloaded from the following location:\n" \
0N/A $(ECHO) "WARNING: The DirectX SDK Include directory contains a newer basetsd.h,\n" \
0N/A " which may indicate that you're using an incorrect version of DirectX SDK.\n" \
0N/A " This may result in a build failure.\n" \
0N/A " The DirectX SDK Include dir was obtained from the following location:\n" \
430N/A " Please change your DirectX SDK to version 9 (Summer 2004 Update or newer).\n" \
0N/A " Microsoft DirectX 9 SDK can be downloaded from the following location:\n" \
0N/A###################################################### 0N/A# Check the linker version(s) 0N/A###################################################### 0N/A $(ECHO) "ERROR: The Linker version is undefined. \n" \
0N/A###################################################### 0N/A# Check the compiler version(s) 0N/A###################################################### 0N/A $(ECHO) "ERROR: The Compiler version is undefined. \n" \
0N/A " The compiler was obtained from the following location: \n" \
0N/A###################################################### 0N/A# Check that ALSA headers and libs are installed and 0N/A# that the header has the right version. We only 0N/A###################################################### 3147N/A " You have the following ALSA version installed: $${alsa_version} \n" \
3147N/A " Please reinstall ALSA (drivers and lib). You can download \n" \
3147N/A " Please install ALSA (drivers and lib). You can download the \n" \
0N/A# If a sanity file doesn't exist, just make sure it's dir exists 0N/A###################################################### 0N/A# dump out the variable settings... 0N/A###################################################### 0N/A###################################################### 0N/A# Check for existence of DEPLOY_MSSDK on windows 0N/A###################################################### 0N/A $(ECHO) "WARNING: Your DEPLOY_MSSDK setting is empty.\n" \
0N/A " It is recommended to set ALT_DEPLOY_MSSDK.\n" \
0N/A $(ECHO) "ERROR: You do not have a valid DEPLOY_MSSDK setting. \n" \
0N/A " Please check your access to \n" \
0N/A " and/or check your value of ALT_DEPLOY_MSSDK. \n" \
0N/A###################################################### 3258N/A# Check for existence of the MSSDK on windows 0N/A###################################################### 3258N/A $(ECHO) "WARNING: Your WINDOWSSDKDIR setting is empty.\n" \
3258N/A " It is recommended to set ALT_WINDOWSSDKDIR.\n" \
3258N/A $(ECHO) "ERROR: You do not have a valid WINDOWSSDKDIR setting. \n" \
3258N/A " Please check your access to \n" \
3258N/A " and/or check your value of ALT_WINDOWSSDKDIR. \n" \
0N/A $(ECHO) "WARNING: Your INSTALL_MSSDK setting is empty.\n" \
0N/A " It is recommended to set ALT_INSTALL_MSSDK.\n" \
0N/A $(ECHO) "ERROR: You do not have a valid INSTALL_MSSDK setting. \n" \
0N/A " Please check your access to \n" \
0N/A " and/or check your value of ALT_INSTALL_MSSDK. \n" \
0N/A###################################################### 3218N/A# Check the GNU C++ compiler for OJI plugin 0N/A###################################################### 0N/A " You are using the following compiler version: $(GCC_VER) \n" \
0N/A " The compiler was obtained from the following location: \n" \
0N/A " Please change your compiler. \n" \
0N/A $(ECHO) "ERROR: You do not have a valid GCC_COMPILER_PATH setting. \n" \
0N/A " Please check your access to \n" \
0N/A " and/or check your value of ALT_GCC_COMPILER_PATH. \n" \
0N/A " This will affect you if you build the plugin target. \n" \
3218N/A $(ECHO) "ERROR: You do not have a valid ALT_GCC29_COMPILER_PATH setting. \n" \
0N/A " Please check your access to \n" \
0N/A " This will affect you if you build the plugin target. \n" \
0N/A $(ECHO) "Error: You do not have a valid ALT_GCC29_PLUGIN_LIB_PATH setting. \n" \
0N/A " Please check your access to \n" \
0N/A " This will affect you if you build the plugin target, specifically for gcc 2.9 version of OJI plugin library. \n" \
0N/A $(ECHO) "ERROR: You do not have a valid GCC29_COMPILER_PATH setting. \n" \
0N/A " Please check your access to \n" \
3218N/A " and/or check your value of ALT_GCC29_COMPILER_PATH or ALT_GCC29_PLUGIN_LIB_PATH \n" \
0N/A " This will affect you if you build the plugin target. \n" \
0N/A###################################################### 0N/A# MOZILLA_HEADERS_PATH must be valid 0N/A###################################################### 0N/A $(ECHO) "ERROR: ALT_MOZILLA_HEADERS_PATH must be an Absolute Path Name, \n" \
0N/A " not a Relative Path Name. \n" \
0N/A " The current value of ALT_MOZILLA_HEADERS_PATH is \n" \
0N/A " Please fix this and continue your build. \n" \
0N/A @
# MOZILLA_HEADERS_PATH must be valid.... 0N/A $(ECHO) "ERROR: You do not have access to valid Mozilla header files. \n" \
0N/A " Please check your access to \n" \
0N/A " and/or check your value of ALT_JDK_DEVTOOLS_DIR, ALT_MOZILLA_HEADERS_PATH, \n" \
0N/A " and on Windows, ALT_JDK_JAVA_DRIVE. \n" \
0N/A $(ECHO) "ERROR: You do not have access to valid Mozilla header files. \n" \
0N/A " Please check your access to \n" \
0N/A " and/or check your value of ALT_JDK_DEVTOOLS_DIR, ALT_MOZILLA_HEADERS_PATH, \n" \
1365N/A @
# Check for presence of headers required for new Java Plug-In ("plugin2") 1365N/A $(ECHO) "ERROR: You do not have access to valid Mozilla header files for the new Java Plug-In. \n" \
1365N/A " Please check your access to \n" \
1365N/A " and/or check your value of ALT_JDK_DEVTOOLS_DIR, ALT_MOZILLA_HEADERS_PATH, \n" \
119N/A###################################################### 1365N/A# Make sure Java Kernel VM is accessible 1365N/A###################################################### 1367N/A $(ECHO) "WARNING: Your HOTSPOT_IMPORT_PATH does not include a Kernel VM... \n" \
1367N/A " The kernel installer may not be built (unless hotspot is also). \n" \
1365N/A " Please check the value of ALT_HOTSPOT_IMPORT_PATH. \n" \
1365N/A###################################################### 1365N/A# SECURITY_BASELINE_131 test 1365N/A###################################################### 1365N/A $(ECHO) "WARNING: Your SECURITY_BASELINE_131 setting is empty.\n" \
1365N/A " Setting it to the default value of 1.3.1_20.\n" \
1365N/A " It is recommended to set SECURITY_BASELINE_131.\n" \
1365N/A###################################################### 119N/A# SECURITY_BASELINE_142 test 119N/A###################################################### 119N/A $(ECHO) "WARNING: Your SECURITY_BASELINE_142 setting is empty.\n" \
119N/A " Setting it to the default value of 1.4.2_10.\n" \
119N/A " It is recommended to set SECURITY_BASELINE_142.\n" \
119N/A###################################################### 119N/A# SECURITY_BASELINE_150 test 119N/A###################################################### 119N/A $(ECHO) "WARNING: Your SECURITY_BASELINE_150 setting is empty.\n" \
119N/A " Setting it to the default value of 1.5.0_07.\n" \
119N/A " It is recommended to set SECURITY_BASELINE_150.\n" \
1365N/A###################################################### 1365N/A# SECURITY_BASELINE_160 test 1365N/A###################################################### 1365N/A $(ECHO) "WARNING: Your SECURITY_BASELINE_160 setting is empty.\n" \
1365N/A " Setting it to the default value of 1.6.0_11.\n" \
1365N/A " It is recommended to set SECURITY_BASELINE_160.\n" \
0N/A###################################################### 0N/A# this should be the last rule in any target's sanity rule. 0N/A###################################################### 0N/A $(ECHO) "INSANE mode requested. \n" \
0N/A "Sanity will not force a build termination, even with errors.\n" \
0N/A $(ECHO) "Exiting because of the above error(s). \n" \
0N/A $(ECHO) "PEDANTIC mode requested. \n" \
0N/A "Exiting because of the above warning(s). \n" \