Makefile revision 180:412712f77af6
14Srgrimes# 24Srgrimes# Copyright (c) 1995, 2009, Oracle and/or its affiliates. All rights reserved. 34Srgrimes# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 44Srgrimes# 54Srgrimes# This code is free software; you can redistribute it and/or modify it 64Srgrimes# under the terms of the GNU General Public License version 2 only, as 74Srgrimes# published by the Free Software Foundation. Oracle designates this 84Srgrimes# particular file as subject to the "Classpath" exception as provided 94Srgrimes# by Oracle in the LICENSE file that accompanied this code. 104Srgrimes# 114Srgrimes# This code is distributed in the hope that it will be useful, but WITHOUT 124Srgrimes# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 134Srgrimes# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 144Srgrimes# version 2 for more details (a copy is included in the LICENSE file that 154Srgrimes# accompanied this code). 164Srgrimes# 174Srgrimes# You should have received a copy of the GNU General Public License version 184Srgrimes# 2 along with this work; if not, write to the Free Software Foundation, 194Srgrimes# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 204Srgrimes# 214Srgrimes# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 224Srgrimes# or visit www.oracle.com if you need additional information or have any 234Srgrimes# questions. 244Srgrimes# 254Srgrimes 264SrgrimesBUILD_PARENT_DIRECTORY=. 274Srgrimes 284Srgrimesifndef TOPDIR 294Srgrimes TOPDIR:=. 304Srgrimesendif 314Srgrimes 324Srgrimesifndef CONTROL_TOPDIR 334Srgrimes CONTROL_TOPDIR=$(TOPDIR) 34593Srgrimesendif 3550477Speter 364Srgrimes# Openjdk sources (only used if SKIP_OPENJDK_BUILD!=true) 374SrgrimesOPENJDK_SOURCETREE=$(TOPDIR)/openjdk 3879609SpeterOPENJDK_BUILDDIR:=$(shell \ 3932929Seivind if [ -r $(OPENJDK_SOURCETREE)/Makefile ]; then \ 4089980Sbde echo "$(OPENJDK_SOURCETREE)"; \ 4113290Speter else \ 4285268Sbde echo "."; \ 4313225Swollman fi) 442056Swollman 452056Swollmanifndef JDK_TOPDIR 4645720Speter JDK_TOPDIR=$(TOPDIR)/jdk 4711865Sphkendif 4876166Smarkmifndef JDK_MAKE_SHARED_DIR 4933281Sbde JDK_MAKE_SHARED_DIR=$(JDK_TOPDIR)/make/common/shared 5045720Speterendif 5176166Smarkm 5276166Smarkm# For start and finish echo lines 5376166SmarkmTITLE_TEXT = Control $(PLATFORM) $(ARCH) $(RELEASE) 5411865SphkDATE_STAMP = `$(DATE) '+%y-%m-%d %H:%M'` 5545720SpeterSTART_ECHO = echo "$(TITLE_TEXT) $@ build started: $(DATE_STAMP)" 5645720SpeterFINISH_ECHO = echo "$(TITLE_TEXT) $@ build finished: $(DATE_STAMP)" 5722093Sbde 584478Sbdedefault: all 5922093Sbde 604478Sbdeinclude $(JDK_MAKE_SHARED_DIR)/Defs-control.gmk 6176906Sbdeinclude ./make/Defs-internal.gmk 623816Swollmaninclude ./make/sanity-rules.gmk 6331255Sbdeinclude ./make/hotspot-rules.gmk 6425083Sjdpinclude ./make/langtools-rules.gmk 6531255Sbdeinclude ./make/corba-rules.gmk 6630805Sbdeinclude ./make/jaxp-rules.gmk 6730805Sbdeinclude ./make/jaxws-rules.gmk 6826309Speterinclude ./make/jdk-rules.gmk 692056Swollmaninclude ./make/install-rules.gmk 7030805Sbdeinclude ./make/sponsors-rules.gmk 7131255Sbdeinclude ./make/deploy-rules.gmk 724478Sbde 7331255Sbde# What "all" means 7445720Speterall:: 752056Swollman @$(START_ECHO) 7630805Sbde 773816Swollmanall:: openjdk_check sanity 7831255Sbde 792056Swollmanifeq ($(SKIP_FASTDEBUG_BUILD), false) 8085270Sbde all:: fastdebug_build 8185270Sbdeendif 8285270Sbde 832056Swollmanifeq ($(SKIP_DEBUG_BUILD), false) 8431255Sbde all:: debug_build 8585270Sbdeendif 8688322Sjhb 8789980Sbdeifneq ($(SKIP_OPENJDK_BUILD), true) 8860008Swollman all:: openjdk_build 8989980Sbdeendif 904Srgrimes 914Srgrimesall:: all_product_build 924Srgrimes 934Srgrimesall:: 944Srgrimes @$(FINISH_ECHO) 9519653Sbde 9619653Sbde# Everything for a full product build 9719653Sbdeall_product_build:: 9819653Sbde @$(START_ECHO) 9949081Scracauer 10019653Sbdeifeq ($(SKIP_PRODUCT_BUILD), false) 1014Srgrimes 1024Srgrimes all_product_build:: product_build 1035351Sbde 1044Srgrimes ifeq ($(BUILD_INSTALL), true) 1054Srgrimes all_product_build:: $(INSTALL) 10635215Sbde clobber:: install-clobber 10735215Sbde endif 10835215Sbde 1095351Sbde ifeq ($(BUILD_SPONSORS), true) 1105351Sbde all_product_build:: $(SPONSORS) 11182154Speter clobber:: sponsors-clobber 11279609Speter endif 11379609Speter 11482154Speter ifneq ($(SKIP_COMPARE_IMAGES), true) 1154Srgrimes all_product_build:: compare-image 1164Srgrimes endif 1174Srgrimes 1184Srgrimesendif 1194Srgrimes 1204Srgrimesall_product_build:: 1214Srgrimes @$(FINISH_ECHO) 1224Srgrimes 1234Srgrimes# Generis build of basic repo series 1244Srgrimesgeneric_build_repo_series:: 1254Srgrimes $(MKDIR) -p $(OUTPUTDIR) 1264Srgrimes $(MKDIR) -p $(OUTPUTDIR)/j2sdk-image 1274Srgrimes 1284Srgrimesifeq ($(BUILD_LANGTOOLS), true) 12982154Speter generic_build_repo_series:: langtools 13079609Speter clobber:: langtools-clobber 13179609Speterendif 13282154Speter 1334Srgrimesifeq ($(BUILD_CORBA), true) 1344Srgrimes generic_build_repo_series:: corba 1354Srgrimes clobber:: corba-clobber 1364Srgrimesendif 1374Srgrimes 13879609Speterifeq ($(BUILD_JAXP), true) 13983366Sjulian generic_build_repo_series:: jaxp 14079609Speter clobber:: jaxp-clobber 14183366Sjulianendif 14283366Sjulian 14383366Sjulianifeq ($(BUILD_JAXWS), true) 14479609Speter generic_build_repo_series:: jaxws 14583366Sjulian clobber:: jaxws-clobber 14683366Sjulianendif 14779609Speter 14879609Speterifeq ($(BUILD_HOTSPOT), true) 14979609Speter generic_build_repo_series:: $(HOTSPOT) 15079609Speter clobber:: hotspot-clobber 15179609Speterendif 15283366Sjulian 15383366Sjulianifeq ($(BUILD_JDK), true) 15483366Sjulian generic_build_repo_series:: $(JDK_JAVA_EXE) 15583366Sjulian clobber:: jdk-clobber 15679609Speterendif 15779609Speter 15879609Speterifeq ($(BUILD_DEPLOY), true) 15979609Speter generic_build_repo_series:: $(DEPLOY) 1604Srgrimes clobber:: deploy-clobber 1614Srgrimesendif 16245720Speter 16350181Speterifeq ($(BUILD_JDK), true) 16477015Sbde ifeq ($(BUNDLE_RULES_AVAILABLE), true) 16577015Sbde generic_build_repo_series:: openjdk-binary-plugs-bundles 16677015Sbde endif 16745720Speterendif 16879781Stegge 16979781Stegge# The debug build, fastdebug or debug. Needs special handling. 17078260Speter# Note that debug builds do NOT do INSTALL steps, but must be done 17133281Sbde# after the product build and before the INSTALL step of the product build. 17233281Sbde# 17345100Sdt# DEBUG_NAME is fastdebug or debug 1744Srgrimes# ALT_OUTPUTDIR is changed to have -debug or -fastdebug suffix 1755351Sbde# The resulting j2sdk-image is used by the install makefiles to create a 17611865Sphk# debug install bundle jdk-*-debug-** bundle (tar or zip) 17711865Sphk# which will install in the debug or fastdebug subdirectory of the 17811865Sphk# normal product install area. 17911865Sphk# The install process needs to know what the DEBUG_NAME is, so 18011865Sphk# look for INSTALL_DEBUG_NAME in the install rules. 18141591Sarchie# 18241591Sarchie 18341591Sarchie# Location of fresh bootdir output 18441591SarchieABS_BOOTDIR_OUTPUTDIR=$(ABS_OUTPUTDIR)/bootjdk 18526812SpeterFRESH_BOOTDIR=$(ABS_BOOTDIR_OUTPUTDIR)/j2sdk-image 1864SrgrimesFRESH_DEBUG_BOOTDIR=$(ABS_BOOTDIR_OUTPUTDIR)-$(DEBUG_NAME)/j2sdk-image 1874Srgrimes 1884Srgrimescreate_fresh_product_bootdir: FRC 1894Srgrimes @$(START_ECHO) 19027567Sfsmp $(MAKE) ALT_OUTPUTDIR=$(ABS_BOOTDIR_OUTPUTDIR) \ 19185029Sbde GENERATE_DOCS=false \ 19235302Sbde BOOT_CYCLE_SETTINGS= \ 19335302Sbde build_product_image 19435302Sbde @$(FINISH_ECHO) 19546548Sbde 19635302Sbdecreate_fresh_debug_bootdir: FRC 19735302Sbde @$(START_ECHO) 19835302Sbde $(MAKE) ALT_OUTPUTDIR=$(ABS_BOOTDIR_OUTPUTDIR) \ 19935302Sbde GENERATE_DOCS=false \ 20035302Sbde BOOT_CYCLE_DEBUG_SETTINGS= \ 2014Srgrimes build_debug_image 20227567Sfsmp @$(FINISH_ECHO) 2034Srgrimes 2044Srgrimescreate_fresh_fastdebug_bootdir: FRC 20550181Speter @$(START_ECHO) 20650181Speter $(MAKE) ALT_OUTPUTDIR=$(ABS_BOOTDIR_OUTPUTDIR) \ 20750181Speter GENERATE_DOCS=false \ 20850181Speter BOOT_CYCLE_DEBUG_SETTINGS= \ 20950181Speter build_fastdebug_image 21050181Speter @$(FINISH_ECHO) 21150181Speter 21250181Speter# Create boot image? 21350181Speterifeq ($(SKIP_BOOT_CYCLE),false) 21450181Speter ifneq ($(PLATFORM)$(ARCH_DATA_MODEL),solaris64) 21550181Speter DO_BOOT_CYCLE=true 21650181Speter endif 21750181Speterendif 21850181Speter 21977015Sbdeifeq ($(DO_BOOT_CYCLE),true) 22050181Speter 22177015Sbde # Create the bootdir to use in the build 22277015Sbde product_build:: create_fresh_product_bootdir 22377015Sbde debug_build:: create_fresh_debug_bootdir 22477015Sbde fastdebug_build:: create_fresh_fastdebug_bootdir 22577015Sbde 22677015Sbde # Define variables to be used now for the boot jdk 22783366Sjulian BOOT_CYCLE_SETTINGS= \ 22877015Sbde ALT_BOOTDIR=$(FRESH_BOOTDIR) \ 22985029Sbde ALT_JDK_IMPORT_PATH=$(FRESH_BOOTDIR) 23085029Sbde BOOT_CYCLE_DEBUG_SETTINGS= \ 23185029Sbde ALT_BOOTDIR=$(FRESH_DEBUG_BOOTDIR) \ 23285029Sbde ALT_JDK_IMPORT_PATH=$(FRESH_DEBUG_BOOTDIR) 23377015Sbde 23477015Sbdeelse 23577015Sbde 23677015Sbde # Use the supplied ALT_BOOTDIR as the boot 23785270Sbde BOOT_CYCLE_SETTINGS= 23885270Sbde BOOT_CYCLE_DEBUG_SETTINGS= 23985270Sbde 24077015Sbdeendif 24185270Sbde 24277015Sbdebuild_product_image: 24377015Sbde @$(START_ECHO) 24487702Sjhb $(MAKE) \ 24577015Sbde SKIP_FASTDEBUG_BUILD=true \ 24683366Sjulian SKIP_DEBUG_BUILD=true \ 24777015Sbde $(BOOT_CYCLE_SETTINGS) \ 24883366Sjulian generic_build_repo_series 24983428Simp @$(FINISH_ECHO) 25077015Sbde 25177015Sbdegeneric_debug_build: 25277015Sbde @$(START_ECHO) 25377015Sbde $(MAKE) \ 25477015Sbde ALT_OUTPUTDIR=$(ABS_OUTPUTDIR)-$(DEBUG_NAME) \ 25587702Sjhb DEBUG_NAME=$(DEBUG_NAME) \ 25683366Sjulian GENERATE_DOCS=false \ 25783366Sjulian $(BOOT_CYCLE_DEBUG_SETTINGS) \ 25877015Sbde generic_build_repo_series 25983366Sjulian @$(FINISH_ECHO) 26077015Sbde 26177015Sbdebuild_debug_image: 26277015Sbde $(MAKE) DEBUG_NAME=debug generic_debug_build 26377015Sbde 26477015Sbdebuild_fastdebug_image: 26577015Sbde $(MAKE) DEBUG_NAME=fastdebug generic_debug_build 2664Srgrimes 2674Srgrimes# Build final image 2684Srgrimesproduct_build:: build_product_image 26985029Sbdedebug_build:: build_debug_image 2704Srgrimesfastdebug_build:: build_fastdebug_image 2714Srgrimes 27245720Speter# Check on whether we really can build the openjdk, need source etc. 27345720Speteropenjdk_check: FRC 2744Srgrimesifneq ($(SKIP_OPENJDK_BUILD), true) 27585029Sbde @$(ECHO) " " 27685029Sbde @$(ECHO) "=================================================" 27785029Sbde @if [ ! -r $(OPENJDK_BUILDDIR)/Makefile ] ; then \ 27885029Sbde $(ECHO) "ERROR: No openjdk source tree available at: $(OPENJDK_BUILDDIR)"; \ 27985029Sbde exit 1; \ 28085029Sbde else \ 28185029Sbde $(ECHO) "OpenJDK will be built after JDK is built"; \ 28227567Sfsmp $(ECHO) " OPENJDK_BUILDDIR=$(OPENJDK_BUILDDIR)"; \ 2834Srgrimes fi 28412929Sdg @$(ECHO) "=================================================" 28585029Sbde @$(ECHO) " " 28685029Sbdeendif 28785029Sbde 28885029Sbde# If we have bundle rules, we have a chance here to do a complete cycle 28985029Sbde# build, of production and open build. 29085270Sbde# FIXUP: We should create the openjdk source bundle and build that? 29185029Sbde# But how do we reliable create or get at a formal openjdk source tree? 29285270Sbde# The one we have needs to be trimmed of built bits and closed dirs. 29385270Sbde# The repositories might not be available. 29485270Sbde# The openjdk source bundle is probably not available. 29585029Sbde 29685270Sbdeifneq ($(SKIP_OPENJDK_BUILD), true) 29785029Sbde ifeq ($(BUILD_JDK), true) 29885029Sbde ifeq ($(BUNDLE_RULES_AVAILABLE), true) 29985029Sbde 30085029SbdeOPENJDK_PLUGS=$(ABS_OUTPUTDIR)/$(OPENJDK_BINARY_PLUGS_INAME) 30185029SbdeOPENJDK_OUTPUTDIR=$(ABS_OUTPUTDIR)/open-output 30285029SbdeOPENJDK_BUILD_NAME \ 30385029Sbde = openjdk-$(JDK_MINOR_VERSION)-$(BUILD_NUMBER)-$(PLATFORM)-$(ARCH)-$(BUNDLE_DATE) 30485029SbdeOPENJDK_BUILD_BINARY_ZIP=$(ABS_BIN_BUNDLEDIR)/$(OPENJDK_BUILD_NAME).zip 30585029SbdeBUILT_IMAGE=$(ABS_OUTPUTDIR)/j2sdk-image 30627567Sfsmpifeq ($(PLATFORM)$(ARCH_DATA_MODEL),solaris64) 3074Srgrimes OPENJDK_BOOTDIR=$(BOOTDIR) 3084Srgrimes OPENJDK_IMPORTJDK=$(JDK_IMPORT_PATH) 3094Srgrimeselse 3104Srgrimes OPENJDK_BOOTDIR=$(BUILT_IMAGE) 31185270Sbde OPENJDK_IMPORTJDK=$(BUILT_IMAGE) 31285270Sbdeendif 31385270Sbde 3144Srgrimesopenjdk_build: 3154Srgrimes @$(START_ECHO) 31685270Sbde @$(ECHO) " " 3174Srgrimes @$(ECHO) "=================================================" 3184Srgrimes @$(ECHO) "Starting openjdk build" 3194Srgrimes @$(ECHO) " Using: ALT_JDK_DEVTOOLS_DIR=$(JDK_DEVTOOLS_DIR)" 3204Srgrimes @$(ECHO) "=================================================" 3214Srgrimes @$(ECHO) " " 3224Srgrimes $(RM) -r $(OPENJDK_OUTPUTDIR) 3234Srgrimes $(MKDIR) -p $(OPENJDK_OUTPUTDIR) 3244Srgrimes ($(CD) $(OPENJDK_BUILDDIR) && $(MAKE) \ 3254Srgrimes OPENJDK=true \ 3264Srgrimes GENERATE_DOCS=false \ 3274Srgrimes ALT_JDK_DEVTOOLS_DIR=$(JDK_DEVTOOLS_DIR) \ 3284Srgrimes ALT_OUTPUTDIR=$(OPENJDK_OUTPUTDIR) \ 3294Srgrimes ALT_BINARY_PLUGS_PATH=$(OPENJDK_PLUGS) \ 3304Srgrimes ALT_BOOTDIR=$(OPENJDK_BOOTDIR) \ 3314Srgrimes ALT_JDK_IMPORT_PATH=$(OPENJDK_IMPORTJDK) \ 3324Srgrimes product_build ) 3334Srgrimes $(RM) $(OPENJDK_BUILD_BINARY_ZIP) 3344Srgrimes ( $(CD) $(OPENJDK_OUTPUTDIR)/j2sdk-image && \ 3354Srgrimes $(ZIPEXE) -q -r $(OPENJDK_BUILD_BINARY_ZIP) .) 3364Srgrimes $(RM) -r $(OPENJDK_OUTPUTDIR) 3374Srgrimes @$(ECHO) " " 33885029Sbde @$(ECHO) "=================================================" 3394Srgrimes @$(ECHO) "Finished openjdk build" 3404Srgrimes @$(ECHO) " Binary Bundle: $(OPENJDK_BUILD_BINARY_ZIP)" 3414Srgrimes @$(ECHO) "=================================================" 3424Srgrimes @$(ECHO) " " 34327567Sfsmp @$(FINISH_ECHO) 34485029Sbde 34585029Sbde endif 34646555Speter endif 34785029Sbdeendif 3486664Sbde 34927567Sfsmpclobber:: 35027567Sfsmp $(RM) -r $(OUTPUTDIR)/* 35127567Sfsmp $(RM) -r $(OUTPUTDIR)-debug/* 35245720Speter $(RM) -r $(OUTPUTDIR)-fastdebug/* 35327567Sfsmp -($(RMDIR) -p $(OUTPUTDIR) > $(DEV_NULL) 2>&1; $(TRUE)) 35445720Speter 35527567Sfsmpclean: clobber 35627567Sfsmp 3576664Sbde# 3586664Sbde# Dev builds 3596664Sbde# 3605351Sbde 3614Srgrimesdev : dev-build 3624Srgrimes 3634Srgrimesdev-build: 3644Srgrimes $(MAKE) DEV_ONLY=true all 3654Srgrimesdev-sanity: 3664Srgrimes $(MAKE) DEV_ONLY=true sanity 3674Srgrimesdev-clobber: 3684Srgrimes $(MAKE) DEV_ONLY=true clobber 3694Srgrimes 3704Srgrimes# 3714Srgrimes# Quick jdk verification build 3724Srgrimes# 3734Srgrimesjdk_only: 3744Srgrimes $(MAKE) SKIP_FASTDEBUG_BUILD=true BUILD_HOTSPOT=false all 3754Srgrimes 3764Srgrimes 3774Srgrimes# 3788876Srgrimes# Quick jdk verification fastdebug build 3794Srgrimes# 3804Srgrimesjdk_fastdebug_only: 3812631Swollman $(MAKE) DEBUG_NAME=fastdebug BUILD_HOTSPOT=false BUILD_DEPLOY=false \ 3824Srgrimes BUILD_INSTALL=false BUILD_SPONSORS=false generic_debug_build 3834Srgrimes 3844Srgrimes# 3854Srgrimes# Quick deploy verification fastdebug build 3864Srgrimes# 3874Srgrimesdeploy_fastdebug_only: 38885268Sbde $(MAKE) \ 38985268Sbde DEBUG_NAME=fastdebug \ 39085268Sbde BUILD_HOTSPOT=false \ 39185268Sbde BUILD_JDK=false \ 39285268Sbde BUILD_LANGTOOLS=false \ 39385268Sbde BUILD_CORBA=false \ 39485268Sbde BUILD_JAXP=false \ 39585268Sbde BUILD_JAXWS=false \ 3964Srgrimes BUILD_INSTALL=false \ 3974Srgrimes BUILD_SPONSORS=false \ 3984Srgrimes generic_debug_build 3994Srgrimes 4004Srgrimes# 4014Srgrimes# Product build (skip debug builds) 4024Srgrimes# 40385029Sbdeproduct_only: 4044Srgrimes $(MAKE) SKIP_FASTDEBUG_BUILD=true all 4054Srgrimes 4064Srgrimes# 4074Srgrimes# Check target 4084Srgrimes# 4094Srgrimes 41085029Sbdecheck: variable_check 41145720Speter 4124Srgrimes# 4134Srgrimes# Help target 4144Srgrimes# 4154Srgrimeshelp: intro_help target_help variable_help notes_help examples_help 4164Srgrimes 4174Srgrimes# Intro help message 4184Srgrimesintro_help: 4194Srgrimes @$(ECHO) "\ 4204SrgrimesMakefile for the JDK builds (all the JDK). \n\ 4214Srgrimes" 4224Srgrimes 42385029Sbde# Target help 42485029Sbdetarget_help: 42585029Sbde @$(ECHO) "\ 42685029Sbde--- Common Targets --- \n\ 42785029Sbdeall -- build the core JDK (default target) \n\ 42885029Sbdehelp -- Print out help information \n\ 42985029Sbdecheck -- Check make variable values for correctness \n\ 43085029Sbdesanity -- Perform detailed sanity checks on system and settings \n\ 43185029Sbdefastdebug_build -- build the core JDK in 'fastdebug' mode (-g -O) \n\ 43288322Sjhbdebug_build -- build the core JDK in 'debug' mode (-g) \n\ 43385029Sbdeclean -- remove all built and imported files \n\ 43488322Sjhbclobber -- same as clean \n\ 43585029Sbde" 43685029Sbde 43785029Sbde# Variable help (only common ones used by this Makefile) 43845720Spetervariable_help: variable_help_intro variable_list variable_help_end 43985029Sbdevariable_help_intro: 44027567Sfsmp @$(ECHO) "--- Common Variables ---" 4414Srgrimesvariable_help_end: 4424Srgrimes @$(ECHO) " " 4434Srgrimes 4444Srgrimes# One line descriptions for the variables 4454SrgrimesOUTPUTDIR.desc = Output directory 4464SrgrimesPARALLEL_COMPILE_JOBS.desc = Solaris/Linux parallel compile run count 44745720SpeterSLASH_JAVA.desc = Root of all build tools, e.g. /java or J: 44845720SpeterBOOTDIR.desc = JDK used to boot the build 4494SrgrimesJDK_IMPORT_PATH.desc = JDK used to import components of the build 45045720SpeterCOMPILER_PATH.desc = Compiler install directory 45140565SbdeCACERTS_FILE.desc = Location of certificates file 45249081ScracauerDEVTOOLS_PATH.desc = Directory containing zip and gnumake 45349081ScracauerCUPS_HEADERS_PATH.desc = Include directory location for CUPS header files 45449081ScracauerDXSDK_PATH.desc = Root directory of DirectX SDK 45551498SphkMSDEVTOOLS_PATH.desc = Root directory of VC++ tools (e.g. rc.exe) 45656615SdfrMSVCRT_DLL_PATH.desc = Directory containing mscvrt.dll 45745720Speter 45856615Sdfr# Make variables to print out (description and value) 45945720SpeterVARIABLE_PRINTVAL_LIST += \ 4608876Srgrimes OUTPUTDIR \ 46149081Scracauer PARALLEL_COMPILE_JOBS \ 46249081Scracauer SLASH_JAVA \ 46356615Sdfr BOOTDIR \ 46449081Scracauer JDK_IMPORT_PATH \ 46556615Sdfr COMPILER_PATH \ 46649081Scracauer CACERTS_FILE \ 46749081Scracauer DEVTOOLS_PATH 46849081Scracauer 46949081Scracauer# Make variables that should refer to directories that exist 47056615SdfrVARIABLE_CHECKDIR_LIST += \ 47119653Sbde SLASH_JAVA \ 47219653Sbde BOOTDIR \ 47356615Sdfr JDK_IMPORT_PATH \ 4745351Sbde COMPILER_PATH \ 47549081Scracauer DEVTOOLS_PATH 47656615Sdfr 47749081Scracauer# Make variables that should refer to files that exist 47856615SdfrVARIABLE_CHECKFIL_LIST += \ 47949081Scracauer CACERTS_FILE 48049081Scracauer 48149081Scracauer# Some are windows specific 48256615Sdfrifeq ($(PLATFORM), windows) 4835351Sbde 48419653SbdeVARIABLE_PRINTVAL_LIST += \ 4854Srgrimes DXSDK_PATH \ 48619653Sbde MSDEVTOOLS_PATH \ 48775488Sjhb MSVCRT_DLL_PATH 48849081Scracauer 48933281SbdeVARIABLE_CHECKDIR_LIST += \ 49033281Sbde DXSDK_PATH \ 49145720Speter MSDEVTOOLS_PATH \ 49219653Sbde MSVCRT_DLL_PATH 49319653Sbde 49419653Sbdeendif 49545720Speter 49619653Sbde# For pattern rules below, so all are treated the same 49745720SpeterDO_PRINTVAL_LIST=$(VARIABLE_PRINTVAL_LIST:%=%.printval) 49819653SbdeDO_CHECKDIR_LIST=$(VARIABLE_CHECKDIR_LIST:%=%.checkdir) 49919653SbdeDO_CHECKFIL_LIST=$(VARIABLE_CHECKFIL_LIST:%=%.checkfil) 50019653Sbde 50119653Sbde# Complete variable check 50219653Sbdevariable_check: $(DO_CHECKDIR_LIST) $(DO_CHECKFIL_LIST) 50319653Sbdevariable_list: $(DO_PRINTVAL_LIST) variable_check 50445720Speter 5054Srgrimes# Pattern rule for printing out a variable 5064Srgrimes%.printval: 5074Srgrimes @$(ECHO) " ALT_$* - $($*.desc)" 5084Srgrimes @$(ECHO) " \t $*=$($*)" 5094Srgrimes 5104Srgrimes# Pattern rule for checking to see if a variable with a directory exists 5114Srgrimes%.checkdir: 5125351Sbde @if [ ! -d $($*) ] ; then \ 5134Srgrimes $(ECHO) "WARNING: $* does not exist, try $(MAKE) sanity"; \ 51479824Stegge fi 51576905Sbde 5164Srgrimes# Pattern rule for checking to see if a variable with a file exists 5174Srgrimes%.checkfil: 5184Srgrimes @if [ ! -f $($*) ] ; then \ 5194Srgrimes $(ECHO) "WARNING: $* does not exist, try $(MAKE) sanity"; \ 5204Srgrimes fi 5215351Sbde 52287702Sjhb# Misc notes on help 5234Srgrimesnotes_help: 52488088Sjhb @$(ECHO) "\ 5254Srgrimes--- Notes --- \n\ 5264Srgrimes- All builds use same output directory unless overridden with \n\ 52785009Stegge \t ALT_OUTPUTDIR=<dir>, changing from product to fastdebug you may want \n\ 52885009Stegge \t to use the clean target first. \n\ 52985009Stegge- JDK_IMPORT_PATH must refer to a compatible build, not all past promoted \n\ 53085009Stegge \t builds or previous release JDK builds will work. \n\ 53185009Stegge- The fastest builds have been when the sources and the BOOTDIR are on \n\ 5324Srgrimes \t local disk. \n\ 53370861Sjake" 53479781Stegge 5354Srgrimesexamples_help: 53688088Sjhb @$(ECHO) "\ 5374Srgrimes--- Examples --- \n\ 5384Srgrimes $(MAKE) fastdebug_build \n\ 5394Srgrimes $(MAKE) ALT_OUTPUTDIR=/tmp/foobar all \n\ 5404Srgrimes $(MAKE) ALT_OUTPUTDIR=/tmp/foobar fastdebug_build \n\ 5414Srgrimes $(MAKE) ALT_OUTPUTDIR=/tmp/foobar all \n\ 5424Srgrimes $(MAKE) ALT_BOOTDIR=/opt/java/jdk1.5.0 \n\ 54383366Sjulian $(MAKE) ALT_JDK_IMPORT_PATH=/opt/java/jdk1.6.0 \n\ 54483366Sjulian" 5454Srgrimes 54676905Sbde################################################################ 5474Srgrimes# Source and binary plug bundling 54888088Sjhb################################################################ 54987702Sjhbifeq ($(BUNDLE_RULES_AVAILABLE), true) 55079609Speter include $(BUNDLE_RULES) 55188088Sjhbendif 55222093Sbde 5534478Sbde################################################################ 5544478Sbde# JPRT rule to build 5554478Sbde################################################################ 55679628Speter 55779628Speterinclude ./make/jprt.gmk 5584478Sbde 55922093Sbde################################################################ 56022093Sbde# PHONY 5614478Sbde################################################################ 5624478Sbde 5634478Sbde.PHONY: all \ 56483640Sjhb generic_build_repo_series \ 56583640Sjhb what clobber insane \ 56683640Sjhb dev dev-build dev-sanity dev-clobber \ 5674Srgrimes product_build \ 56822093Sbde fastdebug_build \ 5694Srgrimes debug_build \ 5704Srgrimes build_product_image \ 57149081Scracauer build_debug_image \ 57249081Scracauer build_fastdebug_image \ 57349081Scracauer create_fresh_product_bootdir \ 57449081Scracauer create_fresh_debug_bootdir \ 57549081Scracauer create_fresh_fastdebug_bootdir \ 57649081Scracauer generic_debug_build 57749098Scracauer 57849081Scracauer# Force target 57949081ScracauerFRC: 58049081Scracauer 58149081Scracauer