jdk-rules.gmk 3.4 KB
Newer Older
D
duke 已提交
1
#
2
# Copyright (c) 2001, 2011, Oracle and/or its affiliates. All rights reserved.
D
duke 已提交
3 4 5 6
# 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
7
# published by the Free Software Foundation.  Oracle designates this
D
duke 已提交
8
# particular file as subject to the "Classpath" exception as provided
9
# by Oracle in the LICENSE file that accompanied this code.
D
duke 已提交
10 11 12 13 14 15 16 17 18 19 20
#
# 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.
#
21 22 23
# 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.
D
duke 已提交
24 25 26 27 28 29 30 31 32
#

################################################################
# JDK TARGETS
################################################################

JDK_JAVA_EXE = $(OUTPUTDIR)/bin/java$(EXE_SUFFIX)

# NO_IMAGES may be set in conjunction with DEV_ONLY
33 34 35 36 37
IMAGES_TARGET = images
ifdef DEV_ONLY
  ifdef NO_IMAGES
    IMAGES_TARGET =
  endif
D
duke 已提交
38 39
endif

40 41 42
# GENERATE_DOCS determines if we ask for the docs target
DOCS_TARGET = docs
ifeq ($(GENERATE_DOCS),false)
D
duke 已提交
43 44
  DOCS_TARGET =
endif
45 46
  
JDK_BUILD_TARGETS = sanity all $(DOCS_TARGET) $(IMAGES_TARGET)
D
duke 已提交
47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77

JDK_CLOBBER_TARGETS = clobber

JDK_BUILD_ARGUMENTS = $(COMMON_BUILD_ARGUMENTS) \
    ALT_OUTPUTDIR=$(ABS_OUTPUTDIR)

ifeq ($(BUILD_LANGTOOLS), true)
  JDK_BUILD_ARGUMENTS += ALT_LANGTOOLS_DIST=$(ABS_LANGTOOLS_DIST)
endif
ifeq ($(BUILD_CORBA), true)
  JDK_BUILD_ARGUMENTS += ALT_CORBA_DIST=$(ABS_CORBA_DIST)
endif
ifeq ($(BUILD_JAXP), true)
  JDK_BUILD_ARGUMENTS += ALT_JAXP_DIST=$(ABS_JAXP_DIST)
endif
ifeq ($(BUILD_JAXWS), true)
  JDK_BUILD_ARGUMENTS += ALT_JAXWS_DIST=$(ABS_JAXWS_DIST)
endif

ifeq ($(BUILD_HOTSPOT), true)
  JDK_BUILD_ARGUMENTS += ALT_HOTSPOT_IMPORT_PATH=$(HOTSPOT_DIR)/import
endif

JDK_BUILD_ARGUMENTS += \
        BUILD_HOTSPOT=$(BUILD_HOTSPOT)


$(JDK_JAVA_EXE):: jdk-build

jdk: jdk-build
jdk-build:
O
ohrstrom 已提交
78
	@$(call MakeStart,jdk,$(JDK_BUILD_TARGETS))
D
duke 已提交
79 80
	( $(CD) $(JDK_TOPDIR)/make && \
	  $(MAKE) $(JDK_BUILD_TARGETS) $(JDK_BUILD_ARGUMENTS) ; )
O
ohrstrom 已提交
81
	@$(call MakeFinish,jdk,$(JDK_BUILD_TARGETS))
D
duke 已提交
82 83

jdk-clobber::
O
ohrstrom 已提交
84
	@$(call MakeStart,jdk,$(JDK_CLOBBER_TARGETS))
D
duke 已提交
85 86
	( $(CD) $(JDK_TOPDIR)/make && \
	  $(MAKE) $(JDK_CLOBBER_TARGETS) $(JDK_BUILD_ARGUMENTS) ; )
O
ohrstrom 已提交
87
	@$(call MakeFinish,jdk,$(JDK_CLOBBER_TARGETS))
D
duke 已提交
88 89

jdk-sanity::
90
	( $(CD) $(JDK_TOPDIR)/make && \
D
duke 已提交
91 92 93 94
	  $(MAKE) sanity HOTSPOT_IMPORT_CHECK=false $(JDK_BUILD_ARGUMENTS) ; )

compare-images: compare-image
compare-image:
O
ohrstrom 已提交
95
	@$(call MakeStart,jdk,compare-image)
D
duke 已提交
96 97
	( $(CD) $(JDK_TOPDIR)/make && \
	  $(MAKE) ALT_OUTPUTDIR=$(ABS_OUTPUTDIR) compare-image )
O
ohrstrom 已提交
98
	@$(call MakeFinish,jdk,compare-image)
D
duke 已提交
99 100 101

compare-images-clobber: compare-image-clobber
compare-image-clobber:
O
ohrstrom 已提交
102
	@$(call MakeStart,jdk,compare-image-clobber)
D
duke 已提交
103 104
	( $(CD) $(JDK_TOPDIR)/make && \
	  $(MAKE) ALT_OUTPUTDIR=$(ABS_OUTPUTDIR) compare-image-clobber )
O
ohrstrom 已提交
105
	@$(call MakeFinish,jdk,compare-image-clobber)
D
duke 已提交
106 107 108

.PHONY: jdk jdk-build jdk-clobber jdk-sanity