make/Defs-internal.gmk

changeset 2
cfeea66a3fa8
child 6
d83470fdf495
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/make/Defs-internal.gmk	Sat Dec 01 00:00:00 2007 +0000
     1.3 @@ -0,0 +1,254 @@
     1.4 +#
     1.5 +# Copyright 1995-2007 Sun Microsystems, Inc.  All Rights Reserved.
     1.6 +# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     1.7 +#
     1.8 +# This code is free software; you can redistribute it and/or modify it
     1.9 +# under the terms of the GNU General Public License version 2 only, as
    1.10 +# published by the Free Software Foundation.  Sun designates this
    1.11 +# particular file as subject to the "Classpath" exception as provided
    1.12 +# by Sun in the LICENSE file that accompanied this code.
    1.13 +#
    1.14 +# This code is distributed in the hope that it will be useful, but WITHOUT
    1.15 +# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
    1.16 +# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
    1.17 +# version 2 for more details (a copy is included in the LICENSE file that
    1.18 +# accompanied this code).
    1.19 +#
    1.20 +# You should have received a copy of the GNU General Public License version
    1.21 +# 2 along with this work; if not, write to the Free Software Foundation,
    1.22 +# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
    1.23 +#
    1.24 +# Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
    1.25 +# CA 95054 USA or visit www.sun.com if you need additional information or
    1.26 +# have any questions.
    1.27 +#
    1.28 +
    1.29 +#
    1.30 +# Common variables used by all the Java makefiles.  This file should
    1.31 +# not contain rules.
    1.32 +#
    1.33 +
    1.34 +# Define absolute paths to TOPDIRs
    1.35 +ABS_CONTROL_TOPDIR:=$(call OptFullPath,"$(CONTROL_TOPDIR)")
    1.36 +ABS_LANGTOOLS_TOPDIR:=$(call OptFullPath,"$(LANGTOOLS_TOPDIR)")
    1.37 +ABS_CORBA_TOPDIR:=$(call OptFullPath,"$(CORBA_TOPDIR)")
    1.38 +ABS_JAXP_TOPDIR:=$(call OptFullPath,"$(JAXP_TOPDIR)")
    1.39 +ABS_JAXWS_TOPDIR:=$(call OptFullPath,"$(JAXWS_TOPDIR)")
    1.40 +ABS_JDK_TOPDIR:=$(call OptFullPath,"$(JDK_TOPDIR)")
    1.41 +ABS_HOTSPOT_TOPDIR:=$(call OptFullPath,"$(HOTSPOT_TOPDIR)")
    1.42 +ABS_INSTALL_TOPDIR:=$(call OptFullPath,"$(INSTALL_TOPDIR)")
    1.43 +ABS_SPONSORS_TOPDIR:=$(call OptFullPath,"$(SPONSORS_TOPDIR)")
    1.44 +ABS_DEPLOY_TOPDIR:=$(call OptFullPath,"$(DEPLOY_TOPDIR)")
    1.45 +
    1.46 +# Macro to return true or false if a file exists and is readable
    1.47 +define MkExists
    1.48 +$(shell if [ -r $1 ]; then $(ECHO) true; else $(ECHO) false; fi)
    1.49 +endef
    1.50 +
    1.51 +HOTSPOT_SRC_AVAILABLE := $(call MkExists,$(HOTSPOT_TOPDIR)/make/Makefile)
    1.52 +ifndef BUILD_HOTSPOT
    1.53 +  ifdef ALT_HOTSPOT_IMPORT_PATH
    1.54 +    BUILD_HOTSPOT := false
    1.55 +  else
    1.56 +    BUILD_HOTSPOT := $(HOTSPOT_SRC_AVAILABLE)
    1.57 +  endif
    1.58 +endif
    1.59 +
    1.60 +LANGTOOLS_SRC_AVAILABLE := $(call MkExists,$(LANGTOOLS_TOPDIR)/make/Makefile)
    1.61 +ifndef BUILD_LANGTOOLS
    1.62 +  ifdef ALT_LANGTOOLS_DIST
    1.63 +    BUILD_LANGTOOLS := false
    1.64 +  else
    1.65 +    BUILD_LANGTOOLS := $(LANGTOOLS_SRC_AVAILABLE)
    1.66 +  endif
    1.67 +endif
    1.68 +
    1.69 +CORBA_SRC_AVAILABLE := $(call MkExists,$(CORBA_TOPDIR)/make/Makefile)
    1.70 +ifndef BUILD_CORBA
    1.71 +  ifdef ALT_CORBA_DIST
    1.72 +    BUILD_CORBA := false
    1.73 +  else
    1.74 +    BUILD_CORBA := $(CORBA_SRC_AVAILABLE)
    1.75 +  endif
    1.76 +endif
    1.77 +
    1.78 +JAXP_SRC_AVAILABLE := $(call MkExists,$(JAXP_TOPDIR)/make/Makefile)
    1.79 +ifndef BUILD_JAXP
    1.80 +  ifdef ALT_JAXP_DIST
    1.81 +    BUILD_JAXP := false
    1.82 +  else
    1.83 +    BUILD_JAXP := $(JAXP_SRC_AVAILABLE)
    1.84 +  endif
    1.85 +endif
    1.86 +
    1.87 +JAXWS_SRC_AVAILABLE := $(call MkExists,$(JAXWS_TOPDIR)/make/Makefile)
    1.88 +ifndef BUILD_JAXWS
    1.89 +  ifdef ALT_JAXWS_DIST
    1.90 +    BUILD_JAXWS := false
    1.91 +  else
    1.92 +    BUILD_JAXWS := $(JAXWS_SRC_AVAILABLE)
    1.93 +  endif
    1.94 +endif
    1.95 +
    1.96 +JDK_SRC_AVAILABLE := $(call MkExists,$(JDK_TOPDIR)/make/Makefile)
    1.97 +ifndef BUILD_JDK
    1.98 +  BUILD_JDK := $(JDK_SRC_AVAILABLE)
    1.99 +endif
   1.100 +ifeq ($(JDK_SRC_AVAILABLE),true)
   1.101 +  JDK_CLOSED_SRC_AVAILABLE := $(call MkExists,$(JDK_TOPDIR)/src/closed)
   1.102 +  ifndef OPENJDK
   1.103 +    ifeq ($(JDK_CLOSED_SRC_AVAILABLE),false)
   1.104 +      OPENJDK = true
   1.105 +    endif
   1.106 +  endif
   1.107 +endif
   1.108 +
   1.109 +DEPLOY_SRC_AVAILABLE := $(call MkExists,$(DEPLOY_TOPDIR)/make/Makefile)
   1.110 +ifndef BUILD_DEPLOY
   1.111 +  BUILD_DEPLOY := $(DEPLOY_SRC_AVAILABLE)
   1.112 +endif
   1.113 +
   1.114 +INSTALL_SRC_AVAILABLE := $(call MkExists,$(INSTALL_TOPDIR)/make/Makefile)
   1.115 +ifndef BUILD_INSTALL
   1.116 +  ifdef DEV_ONLY
   1.117 +    BUILD_INSTALL := false
   1.118 +  else
   1.119 +    BUILD_INSTALL := $(INSTALL_SRC_AVAILABLE)
   1.120 +  endif
   1.121 +endif
   1.122 +
   1.123 +SPONSORS_SRC_AVAILABLE := $(call MkExists,$(SPONSORS_TOPDIR)/make/Makefile)
   1.124 +ifndef BUILD_SPONSORS
   1.125 +  ifdef DEV_ONLY
   1.126 +    BUILD_SPONSORS := false
   1.127 +  else
   1.128 +    BUILD_SPONSORS := $(SPONSORS_SRC_AVAILABLE)
   1.129 +  endif
   1.130 +endif
   1.131 +
   1.132 +
   1.133 +# Do we build the source and openjdk binary plug bundles?
   1.134 +BUNDLE_RULES = $(JDK_TOPDIR)/make/closed/bundles.gmk
   1.135 +BUNDLE_RULES_AVAILABLE := $(call MkExists,$(BUNDLE_RULES))
   1.136 +
   1.137 +# Current things we do NOT build for OPENJDK
   1.138 +ifdef OPENJDK
   1.139 +  BUILD_DEPLOY = false
   1.140 +  BUILD_INSTALL = false
   1.141 +  BUILD_SPONSORS = false
   1.142 +  BUNDLE_RULES_AVAILABLE := false
   1.143 +  # These could be over-ridden on the command line or in environment
   1.144 +  ifndef SKIP_FASTDEBUG_BUILD
   1.145 +    SKIP_FASTDEBUG_BUILD = true
   1.146 +  endif
   1.147 +  ifndef SKIP_DEBUG_BUILD
   1.148 +    SKIP_DEBUG_BUILD = true
   1.149 +  endif
   1.150 +  ifndef SKIP_COMPARE_IMAGES
   1.151 +    SKIP_COMPARE_IMAGES = true
   1.152 +  endif
   1.153 +  SKIP_OPENJDK_BUILD = true
   1.154 +else
   1.155 +  ifndef SKIP_OPENJDK_BUILD
   1.156 +    SKIP_OPENJDK_BUILD = false
   1.157 +    # FIXUP: until freetype fixed on linux and solaris rmi build fixed
   1.158 +    SKIP_OPENJDK_BUILD = true
   1.159 +  endif
   1.160 +endif
   1.161 +
   1.162 +# Solaris 64 bit builds are not complete enough to ever do this
   1.163 +ifeq ($(PLATFORM)$(ARCH_DATA_MODEL),solaris64)
   1.164 +  SKIP_OPENJDK_BUILD = true
   1.165 +endif
   1.166 +
   1.167 +# Many reasons why we would want to skip the comparison to previous jdk
   1.168 +ifndef SKIP_COMPARE_IMAGES
   1.169 +  ifeq ($(BUILD_JDK), false)
   1.170 +    SKIP_COMPARE_IMAGES = true
   1.171 +  endif
   1.172 +  ifeq ($(BUILD_DEPLOY), false)
   1.173 +    SKIP_COMPARE_IMAGES = true
   1.174 +  endif
   1.175 +  ifeq ($(BUILD_INSTALL), false)
   1.176 +    SKIP_COMPARE_IMAGES = true
   1.177 +  endif
   1.178 +  ifdef DEV_ONLY
   1.179 +    SKIP_COMPARE_IMAGES = true
   1.180 +  endif
   1.181 +endif
   1.182 +
   1.183 +# Select defaults if these are not set to true or false
   1.184 +ifndef SKIP_DEBUG_BUILD
   1.185 +  SKIP_DEBUG_BUILD=true
   1.186 +endif
   1.187 +ifndef SKIP_FASTDEBUG_BUILD
   1.188 +  SKIP_FASTDEBUG_BUILD=false
   1.189 +endif
   1.190 +
   1.191 +# Output directory for hotspot build
   1.192 +HOTSPOT_DIR = $(ABS_OUTPUTDIR)/hotspot
   1.193 +
   1.194 +# If we are building components
   1.195 +ifndef ALT_LANGTOOLS_DIST
   1.196 +  LANGTOOLS_OUTPUTDIR = $(ABS_OUTPUTDIR)/langtools
   1.197 +  ABS_LANGTOOLS_DIST = $(LANGTOOLS_OUTPUTDIR)/dist
   1.198 +endif
   1.199 +ifndef ALT_CORBA_DIST
   1.200 +  CORBA_OUTPUTDIR = $(ABS_OUTPUTDIR)/corba
   1.201 +  ABS_CORBA_DIST = $(CORBA_OUTPUTDIR)/dist
   1.202 +endif
   1.203 +ifndef ALT_JAXP_DIST
   1.204 +  JAXP_OUTPUTDIR = $(ABS_OUTPUTDIR)/jaxp
   1.205 +  ABS_JAXP_DIST = $(JAXP_OUTPUTDIR)/dist
   1.206 +endif
   1.207 +ifndef ALT_JAXWS_DIST
   1.208 +  JAXWS_OUTPUTDIR = $(ABS_OUTPUTDIR)/jaxws
   1.209 +  ABS_JAXWS_DIST = $(JAXWS_OUTPUTDIR)/dist
   1.210 +endif
   1.211 +
   1.212 +# Common make arguments (supplied to all component builds)
   1.213 +COMMON_BUILD_ARGUMENTS = \
   1.214 +    JDK_TOPDIR=$(ABS_JDK_TOPDIR) \
   1.215 +    JDK_MAKE_SHARED_DIR=$(ABS_JDK_TOPDIR)/make/common/shared \
   1.216 +    EXTERNALSANITYCONTROL=true \
   1.217 +    TARGET_CLASS_VERSION=$(TARGET_CLASS_VERSION) \
   1.218 +    MILESTONE=$(MILESTONE) \
   1.219 +    BUILD_NUMBER=$(BUILD_NUMBER) \
   1.220 +    JDK_BUILD_NUMBER=$(JDK_BUILD_NUMBER) \
   1.221 +    FULL_VERSION=$(FULL_VERSION) \
   1.222 +    PREVIOUS_JDK_VERSION=$(PREVIOUS_JDK_VERSION) \
   1.223 +    JDK_VERSION=$(JDK_VERSION) \
   1.224 +    JDK_MKTG_VERSION=$(JDK_MKTG_VERSION) \
   1.225 +    JDK_MAJOR_VERSION=$(JDK_MAJOR_VERSION) \
   1.226 +    JDK_MINOR_VERSION=$(JDK_MINOR_VERSION) \
   1.227 +    JDK_MICRO_VERSION=$(JDK_MICRO_VERSION)
   1.228 +
   1.229 +ifdef ARCH_DATA_MODEL
   1.230 +  COMMON_BUILD_ARGUMENTS += ARCH_DATA_MODEL=$(ARCH_DATA_MODEL)
   1.231 +endif
   1.232 +
   1.233 +ifeq ($(DEBUG_NAME), debug)
   1.234 +  COMMON_BUILD_ARGUMENTS += VARIANT=DBG DEBUG_CLASSFILES=true
   1.235 +endif
   1.236 +
   1.237 +ifeq ($(DEBUG_NAME), fastdebug)
   1.238 +  COMMON_BUILD_ARGUMENTS += VARIANT=DBG FASTDEBUG=true DEBUG_CLASSFILES=true
   1.239 +endif
   1.240 +
   1.241 +ifdef COOKED_JDK_UPDATE_VERSION
   1.242 +  COMMON_BUILD_ARGUMENTS += COOKED_JDK_UPDATE_VERSION=$(COOKED_JDK_UPDATE_VERSION)
   1.243 +endif
   1.244 +
   1.245 +ifdef COOKED_BUILD_NUMBER
   1.246 +  COMMON_BUILD_ARGUMENTS += COOKED_BUILD_NUMBER=$(COOKED_BUILD_NUMBER)
   1.247 +endif
   1.248 +
   1.249 +ifdef ANT_HOME
   1.250 +  COMMON_BUILD_ARGUMENTS += ANT_HOME="$(ANT_HOME)"
   1.251 +endif
   1.252 +
   1.253 +ifdef FINDBUGS_HOME
   1.254 +  COMMON_BUILD_ARGUMENTS += FINDBUGS_HOME="$(FINDBUGS_HOME)"
   1.255 +endif
   1.256 +
   1.257 +

mercurial