64c2502a16
Add new license files to demos and samples, new directory for bundling Reviewed-by: katleman, ohair, billyh
144 lines
4.6 KiB
Plaintext
144 lines
4.6 KiB
Plaintext
#
|
|
# Copyright (c) 1995, 2011, Oracle and/or its affiliates. All rights reserved.
|
|
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
|
|
#
|
|
# This code is free software; you can redistribute it and/or modify it
|
|
# under the terms of the GNU General Public License version 2 only, as
|
|
# published by the Free Software Foundation. Oracle designates this
|
|
# particular file as subject to the "Classpath" exception as provided
|
|
# by Oracle in the LICENSE file that accompanied this code.
|
|
#
|
|
# This code is distributed in the hope that it will be useful, but WITHOUT
|
|
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
|
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
|
# version 2 for more details (a copy is included in the LICENSE file that
|
|
# accompanied this code).
|
|
#
|
|
# You should have received a copy of the GNU General Public License version
|
|
# 2 along with this work; if not, write to the Free Software Foundation,
|
|
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
|
|
#
|
|
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
|
|
# or visit www.oracle.com if you need additional information or have any
|
|
# questions.
|
|
#
|
|
|
|
#
|
|
# Common variables used by all the Java makefiles. This file should
|
|
# not contain rules.
|
|
#
|
|
|
|
# WARNING: This file is shared with other components.
|
|
#
|
|
|
|
ifndef JDK_MAKE_SHARED_DIR
|
|
JDK_MAKE_SHARED_DIR = $(JDK_TOPDIR)/make/common/shared
|
|
endif
|
|
|
|
ifndef HOTSPOT_TOPDIR
|
|
HOTSPOT_TOPDIR=$(TOPDIR)/hotspot
|
|
endif
|
|
ifndef LANGTOOLS_TOPDIR
|
|
LANGTOOLS_TOPDIR=$(TOPDIR)/langtools
|
|
endif
|
|
ifndef CORBA_TOPDIR
|
|
CORBA_TOPDIR=$(TOPDIR)/corba
|
|
endif
|
|
ifndef JAXP_TOPDIR
|
|
JAXP_TOPDIR=$(TOPDIR)/jaxp
|
|
endif
|
|
ifndef JAXWS_TOPDIR
|
|
JAXWS_TOPDIR=$(TOPDIR)/jaxws
|
|
endif
|
|
ifndef JDK_TOPDIR
|
|
JDK_TOPDIR=$(TOPDIR)/jdk
|
|
endif
|
|
ifndef INSTALL_TOPDIR
|
|
INSTALL_TOPDIR=$(TOPDIR)/install
|
|
endif
|
|
ifndef SPONSORS_TOPDIR
|
|
SPONSORS_TOPDIR=$(TOPDIR)/sponsors
|
|
endif
|
|
ifndef DEPLOY_TOPDIR
|
|
DEPLOY_TOPDIR=$(TOPDIR)/deploy
|
|
endif
|
|
|
|
# Get shared platform settings
|
|
include $(JDK_MAKE_SHARED_DIR)/Platform.gmk
|
|
|
|
# Default directory immediately above the "build" output directory (OUTPUTDIR)
|
|
BUILD_PARENT_DIRECTORY=$(TOPDIR)
|
|
|
|
# Get platform specific settings
|
|
include $(JDK_MAKE_SHARED_DIR)/Defs.gmk
|
|
|
|
SRC_BUNDLEDIR = $(OUTPUTDIR)/source-bundles
|
|
ABS_SRC_BUNDLEDIR = $(ABS_OUTPUTDIR)/source-bundles
|
|
BIN_BUNDLEDIR = $(OUTPUTDIR)/bundles
|
|
BIN_DEMOS_BUNDLEDIR = $(OUTPUTDIR)/demos-bundles
|
|
ABS_BIN_BUNDLEDIR = $(ABS_OUTPUTDIR)/bundles
|
|
|
|
dummy := $(shell $(MKDIR) -p $(BIN_BUNDLEDIR))
|
|
dummy := $(shell $(MKDIR) -p $(BIN_DEMOS_BUNDLEDIR) )
|
|
dummy := $(shell $(MKDIR) -p $(SRC_BUNDLEDIR) )
|
|
|
|
TEMP_DIR = $(OUTPUTDIR)/tmp
|
|
ABS_TEMP_DIR = $(ABS_OUTPUTDIR)/tmp
|
|
|
|
dummy := $(shell $(MKDIR) -p $(TEMP_DIR))
|
|
|
|
# The language version we want for this jdk build
|
|
SOURCE_LANGUAGE_VERSION=7
|
|
# The class version we want for this jdk build
|
|
TARGET_CLASS_VERSION=7
|
|
|
|
# The MESSAGE, WARNING and ERROR files are used to store sanity check and
|
|
# source check messages, warnings and errors.
|
|
export ERROR_FILE := $(ABS_OUTPUTDIR)/sanityCheckErrors.txt
|
|
export WARNING_FILE := $(ABS_OUTPUTDIR)/sanityCheckWarnings.txt
|
|
export MESSAGE_FILE := $(ABS_OUTPUTDIR)/sanityCheckMessages.txt
|
|
|
|
# source bundle generation definitions
|
|
BUNDLE_DATE := $(shell $(DATE) '+%d_%b_%Y' | $(TR) "[A-Z]" "[a-z]")
|
|
ifdef ALT_BUNDLE_DATE
|
|
BUNDLE_DATE := $(ALT_BUNDLE_DATE)
|
|
endif
|
|
|
|
# If the update version contains non-numeric characters, we need
|
|
# to massage it into a numeric format. Unfortunately, the
|
|
# Windows VERSIONINFO resource that we stick in jvm.dll cannot
|
|
# handle non-numeric characters. We have to do this here because
|
|
# Hotspot (nmake) cannot handle calculations. So we use the
|
|
# following formula:
|
|
# COOKED_JDK_UPDATE_VERSION = JDK_UPDATE_VERSION * 10 + EXCEPTION_VERSION
|
|
#
|
|
# Here are some examples:
|
|
# 1.5.0 b01 -> 5,0,0,1
|
|
# 1.5.0_10 b01 -> 5,0,100,1
|
|
# 1.4.2 b01 -> 4,2,0,1
|
|
# 1.4.2_02 b01 -> 4,2,20,1
|
|
# 1.4.2_02a b01 -> 4,2,21,1
|
|
# 1.4.2_02b b01 -> 4,2,22,1
|
|
ifdef JDK_UPDATE_VERSION
|
|
VTMP := $(shell $(ECHO) $(JDK_UPDATE_VERSION) | $(TR) "abcde" "12345")
|
|
CHAR1 := $(shell $(ECHO) $(VTMP) | $(NAWK) '{print substr($$1, 1, 1);}')
|
|
CHAR2 := $(shell $(ECHO) $(VTMP) | $(NAWK) '{print substr($$1, 2, 1);}')
|
|
CHAR3 := $(shell $(ECHO) $(VTMP) | $(NAWK) '{print substr($$1, 3, 1);}')
|
|
ifeq ($(CHAR3),)
|
|
CHAR3 := 0
|
|
endif
|
|
ifeq ($(CHAR1), 0)
|
|
COOKED_JDK_UPDATE_VERSION := $(CHAR2)$(CHAR3)
|
|
else
|
|
COOKED_JDK_UPDATE_VERSION := $(CHAR1)$(CHAR2)$(CHAR3)
|
|
endif
|
|
endif
|
|
|
|
ifneq ($(JDK_BUILD_NUMBER),)
|
|
COOKED_BUILD_NUMBER = $(shell $(ECHO) $(JDK_BUILD_NUMBER) \
|
|
| $(SED) -e 's/^b//' | $(SED) -e 's/^0//')
|
|
else
|
|
COOKED_BUILD_NUMBER = 0
|
|
endif
|
|
|