author | emcmanus |
Fri, 16 May 2008 11:34:34 +0200 | |
changeset 527 | a33264d48a84 |
parent 20 | 41658053480c |
child 668 | 982030fabc32 |
permissions | -rw-r--r-- |
0 | 1 |
# |
2 |
# Copyright 1995-2007 Sun Microsystems, Inc. All Rights Reserved. |
|
3 |
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
|
4 |
# |
|
5 |
# This code is free software; you can redistribute it and/or modify it |
|
6 |
# under the terms of the GNU General Public License version 2 only, as |
|
7 |
# published by the Free Software Foundation. Sun designates this |
|
8 |
# particular file as subject to the "Classpath" exception as provided |
|
9 |
# by Sun in the LICENSE file that accompanied this code. |
|
10 |
# |
|
11 |
# This code is distributed in the hope that it will be useful, but WITHOUT |
|
12 |
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
|
13 |
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License |
|
14 |
# version 2 for more details (a copy is included in the LICENSE file that |
|
15 |
# accompanied this code). |
|
16 |
# |
|
17 |
# You should have received a copy of the GNU General Public License version |
|
18 |
# 2 along with this work; if not, write to the Free Software Foundation, |
|
19 |
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. |
|
20 |
# |
|
21 |
# Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara, |
|
22 |
# CA 95054 USA or visit www.sun.com if you need additional information or |
|
23 |
# have any questions. |
|
24 |
# |
|
25 |
||
17
bb9f330cd95a
6649672: Adjustments to OUTPUTDIR default and mkdirs to avoid empty directory clutter
ohair
parents:
16
diff
changeset
|
26 |
BUILD_PARENT_DIRECTORY=. |
bb9f330cd95a
6649672: Adjustments to OUTPUTDIR default and mkdirs to avoid empty directory clutter
ohair
parents:
16
diff
changeset
|
27 |
|
0 | 28 |
ifndef TOPDIR |
20 | 29 |
TOPDIR:=. |
0 | 30 |
endif |
31 |
||
32 |
ifndef CONTROL_TOPDIR |
|
20 | 33 |
CONTROL_TOPDIR=$(TOPDIR) |
0 | 34 |
endif |
35 |
||
16
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
36 |
# Openjdk sources (only used if SKIP_OPENJDK_BUILD!=true) |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
37 |
OPENJDK_SOURCETREE=$(TOPDIR)/openjdk |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
38 |
OPENJDK_BUILDDIR:=$(shell \ |
20 | 39 |
if [ -r $(OPENJDK_SOURCETREE)/Makefile ]; then \ |
16
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
40 |
echo "$(OPENJDK_SOURCETREE)"; \ |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
41 |
else \ |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
42 |
echo "."; \ |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
43 |
fi) |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
44 |
|
0 | 45 |
ifndef JDK_TOPDIR |
46 |
JDK_TOPDIR=$(TOPDIR)/jdk |
|
47 |
endif |
|
48 |
ifndef JDK_MAKE_SHARED_DIR |
|
49 |
JDK_MAKE_SHARED_DIR=$(JDK_TOPDIR)/make/common/shared |
|
50 |
endif |
|
51 |
||
52 |
include $(JDK_MAKE_SHARED_DIR)/Defs-control.gmk |
|
53 |
||
54 |
include ./make/Defs-internal.gmk |
|
55 |
||
56 |
all:: |
|
57 |
@$(ECHO) $(PLATFORM) $(ARCH) $(RELEASE) build started: `$(DATE) '+%y-%m-%d %H:%M'` |
|
17
bb9f330cd95a
6649672: Adjustments to OUTPUTDIR default and mkdirs to avoid empty directory clutter
ohair
parents:
16
diff
changeset
|
58 |
$(MKDIR) -p $(OUTPUTDIR) |
0 | 59 |
|
60 |
# Rules for sanity checks |
|
61 |
include ./make/sanity-rules.gmk |
|
62 |
||
63 |
dev : dev-build |
|
64 |
||
65 |
dev-build: |
|
66 |
$(MAKE) DEV_ONLY=true all |
|
67 |
dev-sanity: |
|
68 |
$(MAKE) DEV_ONLY=true sanity |
|
69 |
dev-clobber: |
|
70 |
$(MAKE) DEV_ONLY=true clobber |
|
71 |
||
72 |
# Rules for various components |
|
73 |
include ./make/hotspot-rules.gmk |
|
74 |
include ./make/langtools-rules.gmk |
|
75 |
include ./make/corba-rules.gmk |
|
76 |
include ./make/jaxp-rules.gmk |
|
77 |
include ./make/jaxws-rules.gmk |
|
78 |
include ./make/jdk-rules.gmk |
|
79 |
include ./make/install-rules.gmk |
|
80 |
include ./make/sponsors-rules.gmk |
|
81 |
include ./make/deploy-rules.gmk |
|
82 |
||
83 |
all:: setup build |
|
84 |
||
16
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
85 |
setup: openjdk_check |
0 | 86 |
$(MKDIR) -p $(OUTPUTDIR)/j2sdk-image |
87 |
||
16
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
88 |
# Check on whether we really can build the openjdk, need source etc. |
17
bb9f330cd95a
6649672: Adjustments to OUTPUTDIR default and mkdirs to avoid empty directory clutter
ohair
parents:
16
diff
changeset
|
89 |
openjdk_check: FRC |
16
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
90 |
ifneq ($(SKIP_OPENJDK_BUILD), true) |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
91 |
@$(ECHO) " " |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
92 |
@$(ECHO) "=================================================" |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
93 |
@if [ ! -r $(OPENJDK_BUILDDIR)/Makefile ] ; then \ |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
94 |
$(ECHO) "ERROR: No openjdk source tree available at: $(OPENJDK_BUILDDIR)"; \ |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
95 |
exit 1; \ |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
96 |
else \ |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
97 |
$(ECHO) "OpenJDK will be built after JDK is built"; \ |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
98 |
$(ECHO) " OPENJDK_BUILDDIR=$(OPENJDK_BUILDDIR)"; \ |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
99 |
fi |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
100 |
@$(ECHO) "=================================================" |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
101 |
@$(ECHO) " " |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
102 |
endif |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
103 |
|
0 | 104 |
build:: sanity |
105 |
||
106 |
clobber:: |
|
107 |
||
108 |
ifeq ($(BUILD_LANGTOOLS), true) |
|
109 |
build:: langtools |
|
110 |
clobber:: langtools-clobber |
|
111 |
endif |
|
112 |
||
113 |
ifeq ($(BUILD_CORBA), true) |
|
114 |
build:: corba |
|
115 |
clobber:: corba-clobber |
|
116 |
endif |
|
117 |
||
118 |
ifeq ($(BUILD_JAXP), true) |
|
119 |
build:: jaxp |
|
120 |
clobber:: jaxp-clobber |
|
121 |
endif |
|
122 |
||
123 |
ifeq ($(BUILD_JAXWS), true) |
|
124 |
build:: jaxws |
|
125 |
clobber:: jaxws-clobber |
|
126 |
endif |
|
127 |
||
128 |
ifeq ($(BUILD_HOTSPOT), true) |
|
129 |
build:: $(HOTSPOT) |
|
130 |
clobber:: hotspot-clobber |
|
131 |
endif |
|
132 |
||
133 |
ifeq ($(BUILD_JDK), true) |
|
134 |
build:: $(JDK_JAVA_EXE) |
|
135 |
clobber:: jdk-clobber |
|
136 |
endif |
|
137 |
||
138 |
ifeq ($(BUILD_DEPLOY), true) |
|
139 |
build:: $(DEPLOY) |
|
140 |
clobber:: deploy-clobber |
|
141 |
endif |
|
142 |
||
143 |
# |
|
144 |
# Generic debug build, fastdebug or debug. Needs special handling. |
|
145 |
# Note that debug builds do NOT do INSTALL steps, but must be done |
|
146 |
# after the product build and before the INSTALL step of the product build. |
|
147 |
# |
|
148 |
# DEBUG_NAME is fastdebug or debug |
|
149 |
# ALT_OUTPUTDIR is changed to have -debug or -fastdebug suffix |
|
150 |
# The resulting j2sdk-image is used by the install makefiles to create a |
|
151 |
# debug install bundle jdk-*-debug-** bundle (tar or zip) |
|
152 |
# which will install in the debug or fastdebug subdirectory of the |
|
153 |
# normal product install area. |
|
154 |
# The install process needs to know what the DEBUG_NAME is, so |
|
155 |
# look for INSTALL_DEBUG_NAME in the install rules. |
|
156 |
# |
|
157 |
||
158 |
COMMON_DEBUG_FLAGS= \ |
|
159 |
DEBUG_NAME=$(DEBUG_NAME) \ |
|
17
bb9f330cd95a
6649672: Adjustments to OUTPUTDIR default and mkdirs to avoid empty directory clutter
ohair
parents:
16
diff
changeset
|
160 |
ALT_OUTPUTDIR=$(ABS_OUTPUTDIR)-$(DEBUG_NAME) \ |
0 | 161 |
NO_DOCS=true |
162 |
||
163 |
product_build: setup |
|
164 |
@$(ECHO) $@ build started: `$(DATE) '+%y-%m-%d %H:%M'` |
|
165 |
$(MAKE) SKIP_FASTDEBUG_BUILD=true SKIP_DEBUG_BUILD=true all |
|
166 |
@$(ECHO) $@ build finished: `$(DATE) '+%y-%m-%d %H:%M'` |
|
167 |
||
168 |
generic_debug_build: |
|
169 |
@$(ECHO) $@ build started: `$(DATE) '+%y-%m-%d %H:%M'` |
|
170 |
$(MAKE) $(COMMON_DEBUG_FLAGS) setup build |
|
171 |
@$(ECHO) $@ build finished: `$(DATE) '+%y-%m-%d %H:%M'` |
|
172 |
||
173 |
debug_build: setup |
|
174 |
$(MAKE) DEBUG_NAME=debug generic_debug_build |
|
175 |
||
176 |
fastdebug_build: setup |
|
177 |
$(MAKE) DEBUG_NAME=fastdebug generic_debug_build |
|
178 |
||
179 |
ifeq ($(SKIP_FASTDEBUG_BUILD), false) |
|
180 |
all:: fastdebug_build |
|
181 |
endif |
|
182 |
||
183 |
ifeq ($(SKIP_DEBUG_BUILD), false) |
|
184 |
all:: debug_build |
|
185 |
endif |
|
186 |
||
187 |
ifeq ($(BUILD_JDK), true) |
|
188 |
ifeq ($(BUNDLE_RULES_AVAILABLE), true) |
|
189 |
all:: openjdk-binary-plugs-bundles |
|
190 |
endif |
|
191 |
endif |
|
192 |
||
193 |
ifeq ($(BUILD_INSTALL), true) |
|
194 |
all :: $(INSTALL) |
|
195 |
clobber:: install-clobber |
|
196 |
endif |
|
197 |
||
198 |
ifeq ($(BUILD_SPONSORS), true) |
|
199 |
all :: $(SPONSORS) |
|
200 |
clobber:: sponsors-clobber |
|
201 |
endif |
|
202 |
||
203 |
ifneq ($(SKIP_COMPARE_IMAGES), true) |
|
204 |
all :: compare-image |
|
205 |
endif |
|
206 |
||
16
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
207 |
ifneq ($(SKIP_OPENJDK_BUILD), true) |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
208 |
all :: openjdk_build |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
209 |
endif |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
210 |
|
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
211 |
# If we have bundle rules, we have a chance here to do a complete cycle |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
212 |
# build, of production and open build. |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
213 |
# FIXUP: We should create the openjdk source bundle and build that? |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
214 |
# But how do we reliable create or get at a formal openjdk source tree? |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
215 |
# The one we have needs to be trimmed of built bits and closed dirs. |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
216 |
# The repositories might not be available. |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
217 |
# The openjdk source bundle is probably not available. |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
218 |
|
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
219 |
ifneq ($(SKIP_OPENJDK_BUILD), true) |
0 | 220 |
ifeq ($(BUILD_JDK), true) |
221 |
ifeq ($(BUNDLE_RULES_AVAILABLE), true) |
|
16
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
222 |
|
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
223 |
OPENJDK_PLUGS=$(ABS_OUTPUTDIR)/$(OPENJDK_BINARY_PLUGS_INAME) |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
224 |
OPENJDK_OUTPUTDIR=$(ABS_OUTPUTDIR)/open-output |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
225 |
OPENJDK_BUILD_NAME \ |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
226 |
= openjdk-$(JDK_MINOR_VERSION)-$(BUILD_NUMBER)-$(PLATFORM)-$(ARCH)-$(BUNDLE_DATE) |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
227 |
OPENJDK_BUILD_BINARY_ZIP=$(ABS_BIN_BUNDLEDIR)/$(OPENJDK_BUILD_NAME).zip |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
228 |
BUILT_IMAGE=$(ABS_OUTPUTDIR)/j2sdk-image |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
229 |
ifeq ($(PLATFORM)$(ARCH_DATA_MODEL),solaris64) |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
230 |
OPENJDK_BOOTDIR=$(BOOTDIR) |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
231 |
OPENJDK_IMPORTJDK=$(JDK_IMPORT_PATH) |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
232 |
else |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
233 |
OPENJDK_BOOTDIR=$(BUILT_IMAGE) |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
234 |
OPENJDK_IMPORTJDK=$(BUILT_IMAGE) |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
235 |
endif |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
236 |
|
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
237 |
openjdk_build: |
0 | 238 |
@$(ECHO) " " |
239 |
@$(ECHO) "=================================================" |
|
240 |
@$(ECHO) "Starting openjdk build" |
|
16
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
241 |
@$(ECHO) " Using: ALT_JDK_DEVTOOLS_DIR=$(JDK_DEVTOOLS_DIR)" |
0 | 242 |
@$(ECHO) "=================================================" |
243 |
@$(ECHO) " " |
|
16
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
244 |
$(RM) -r $(OPENJDK_OUTPUTDIR) |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
245 |
$(MKDIR) -p $(OPENJDK_OUTPUTDIR) |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
246 |
($(CD) $(OPENJDK_BUILDDIR) && $(MAKE) \ |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
247 |
OPENJDK=true \ |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
248 |
ALT_JDK_DEVTOOLS_DIR=$(JDK_DEVTOOLS_DIR) \ |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
249 |
ALT_OUTPUTDIR=$(OPENJDK_OUTPUTDIR) \ |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
250 |
ALT_BINARY_PLUGS_PATH=$(OPENJDK_PLUGS) \ |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
251 |
ALT_BOOTDIR=$(OPENJDK_BOOTDIR) \ |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
252 |
ALT_JDK_IMPORT_PATH=$(OPENJDK_IMPORTJDK) \ |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
253 |
product_build ) |
0 | 254 |
$(RM) $(OPENJDK_BUILD_BINARY_ZIP) |
16
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
255 |
( $(CD) $(OPENJDK_OUTPUTDIR)/j2sdk-image && \ |
0 | 256 |
$(ZIPEXE) -q -r $(OPENJDK_BUILD_BINARY_ZIP) .) |
16
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
257 |
$(RM) -r $(OPENJDK_OUTPUTDIR) |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
258 |
@$(ECHO) " " |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
259 |
@$(ECHO) "=================================================" |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
260 |
@$(ECHO) "Finished openjdk build" |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
261 |
@$(ECHO) " Binary Bundle: $(OPENJDK_BUILD_BINARY_ZIP)" |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
262 |
@$(ECHO) "=================================================" |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
263 |
@$(ECHO) " " |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
264 |
|
0 | 265 |
endif |
266 |
endif |
|
267 |
endif |
|
268 |
||
269 |
clobber:: |
|
270 |
$(RM) -r $(OUTPUTDIR)/* |
|
271 |
$(RM) -r $(OUTPUTDIR)-debug/* |
|
272 |
$(RM) -r $(OUTPUTDIR)-fastdebug/* |
|
273 |
-($(RMDIR) -p $(OUTPUTDIR) > $(DEV_NULL) 2>&1; $(TRUE)) |
|
274 |
||
275 |
clean: clobber |
|
276 |
||
277 |
all:: |
|
278 |
@$(ECHO) Control build finished: `$(DATE) '+%y-%m-%d %H:%M'` |
|
279 |
||
280 |
# |
|
281 |
# Quick jdk verification build |
|
282 |
# |
|
283 |
jdk_only: |
|
284 |
$(MAKE) SKIP_FASTDEBUG_BUILD=true BUILD_HOTSPOT=false all |
|
285 |
||
286 |
||
287 |
# |
|
288 |
# Quick jdk verification fastdebug build |
|
289 |
# |
|
290 |
jdk_fastdebug_only: |
|
291 |
$(MAKE) DEBUG_NAME=fastdebug BUILD_HOTSPOT=false BUILD_DEPLOY=false \ |
|
292 |
BUILD_INSTALL=false BUILD_SPONSORS=false generic_debug_build |
|
293 |
||
294 |
# |
|
295 |
# Quick deploy verification fastdebug build |
|
296 |
# |
|
297 |
deploy_fastdebug_only: |
|
298 |
$(MAKE) \ |
|
299 |
DEBUG_NAME=fastdebug \ |
|
300 |
BUILD_HOTSPOT=false \ |
|
301 |
BUILD_JDK=false \ |
|
302 |
BUILD_LANGTOOLS=false \ |
|
303 |
BUILD_CORBA=false \ |
|
304 |
BUILD_JAXP=false \ |
|
305 |
BUILD_JAXWS=false \ |
|
306 |
BUILD_INSTALL=false \ |
|
307 |
BUILD_SPONSORS=false \ |
|
308 |
generic_debug_build |
|
309 |
||
310 |
# |
|
311 |
# Product build (skip debug builds) |
|
312 |
# |
|
313 |
product_only: |
|
314 |
$(MAKE) SKIP_FASTDEBUG_BUILD=true all |
|
315 |
||
316 |
# |
|
317 |
# Check target |
|
318 |
# |
|
319 |
||
320 |
check: variable_check |
|
321 |
||
322 |
# |
|
323 |
# Help target |
|
324 |
# |
|
325 |
help: intro_help target_help variable_help notes_help examples_help |
|
326 |
||
327 |
# Intro help message |
|
328 |
intro_help: |
|
329 |
@$(ECHO) "\ |
|
330 |
Makefile for the JDK builds (all the JDK). \n\ |
|
331 |
" |
|
332 |
||
333 |
# Target help |
|
334 |
target_help: |
|
335 |
@$(ECHO) "\ |
|
336 |
--- Common Targets --- \n\ |
|
337 |
all -- build the core JDK (default target) \n\ |
|
338 |
help -- Print out help information \n\ |
|
339 |
check -- Check make variable values for correctness \n\ |
|
340 |
sanity -- Perform detailed sanity checks on system and settings \n\ |
|
341 |
fastdebug_build -- build the core JDK in 'fastdebug' mode (-g -O) \n\ |
|
342 |
debug_build -- build the core JDK in 'debug' mode (-g) \n\ |
|
343 |
clean -- remove all built and imported files \n\ |
|
344 |
clobber -- same as clean \n\ |
|
345 |
" |
|
346 |
||
347 |
# Variable help (only common ones used by this Makefile) |
|
348 |
variable_help: variable_help_intro variable_list variable_help_end |
|
349 |
variable_help_intro: |
|
350 |
@$(ECHO) "--- Common Variables ---" |
|
351 |
variable_help_end: |
|
352 |
@$(ECHO) " " |
|
353 |
||
354 |
# One line descriptions for the variables |
|
355 |
OUTPUTDIR.desc = Output directory |
|
356 |
PARALLEL_COMPILE_JOBS.desc = Solaris/Linux parallel compile run count |
|
357 |
SLASH_JAVA.desc = Root of all build tools, e.g. /java or J: |
|
358 |
BOOTDIR.desc = JDK used to boot the build |
|
359 |
JDK_IMPORT_PATH.desc = JDK used to import components of the build |
|
360 |
COMPILER_PATH.desc = Compiler install directory |
|
361 |
CACERTS_FILE.desc = Location of certificates file |
|
362 |
DEVTOOLS_PATH.desc = Directory containing zip and gnumake |
|
363 |
CUPS_HEADERS_PATH.desc = Include directory location for CUPS header files |
|
364 |
DXSDK_PATH.desc = Root directory of DirectX SDK |
|
365 |
MSDEVTOOLS_PATH.desc = Root directory of VC++ tools (e.g. rc.exe) |
|
366 |
MSVCRT_DLL_PATH.desc = Directory containing mscvrt.dll |
|
367 |
||
368 |
# Make variables to print out (description and value) |
|
369 |
VARIABLE_PRINTVAL_LIST += \ |
|
370 |
OUTPUTDIR \ |
|
371 |
PARALLEL_COMPILE_JOBS \ |
|
372 |
SLASH_JAVA \ |
|
373 |
BOOTDIR \ |
|
374 |
JDK_IMPORT_PATH \ |
|
375 |
COMPILER_PATH \ |
|
376 |
CACERTS_FILE \ |
|
377 |
DEVTOOLS_PATH |
|
378 |
||
379 |
# Make variables that should refer to directories that exist |
|
380 |
VARIABLE_CHECKDIR_LIST += \ |
|
381 |
SLASH_JAVA \ |
|
382 |
BOOTDIR \ |
|
383 |
JDK_IMPORT_PATH \ |
|
384 |
COMPILER_PATH \ |
|
385 |
DEVTOOLS_PATH |
|
386 |
||
387 |
# Make variables that should refer to files that exist |
|
388 |
VARIABLE_CHECKFIL_LIST += \ |
|
389 |
CACERTS_FILE |
|
390 |
||
391 |
# Some are windows specific |
|
392 |
ifeq ($(PLATFORM), windows) |
|
393 |
||
394 |
VARIABLE_PRINTVAL_LIST += \ |
|
395 |
DXSDK_PATH \ |
|
396 |
MSDEVTOOLS_PATH \ |
|
397 |
MSVCRT_DLL_PATH |
|
398 |
||
399 |
VARIABLE_CHECKDIR_LIST += \ |
|
400 |
DXSDK_PATH \ |
|
401 |
MSDEVTOOLS_PATH \ |
|
402 |
MSVCRT_DLL_PATH |
|
403 |
||
404 |
endif |
|
405 |
||
406 |
# For pattern rules below, so all are treated the same |
|
407 |
DO_PRINTVAL_LIST=$(VARIABLE_PRINTVAL_LIST:%=%.printval) |
|
408 |
DO_CHECKDIR_LIST=$(VARIABLE_CHECKDIR_LIST:%=%.checkdir) |
|
409 |
DO_CHECKFIL_LIST=$(VARIABLE_CHECKFIL_LIST:%=%.checkfil) |
|
410 |
||
411 |
# Complete variable check |
|
412 |
variable_check: $(DO_CHECKDIR_LIST) $(DO_CHECKFIL_LIST) |
|
413 |
variable_list: $(DO_PRINTVAL_LIST) variable_check |
|
414 |
||
415 |
# Pattern rule for printing out a variable |
|
416 |
%.printval: |
|
417 |
@$(ECHO) " ALT_$* - $($*.desc)" |
|
418 |
@$(ECHO) " \t $*=$($*)" |
|
419 |
||
420 |
# Pattern rule for checking to see if a variable with a directory exists |
|
421 |
%.checkdir: |
|
422 |
@if [ ! -d $($*) ] ; then \ |
|
423 |
$(ECHO) "WARNING: $* does not exist, try $(MAKE) sanity"; \ |
|
424 |
fi |
|
425 |
||
426 |
# Pattern rule for checking to see if a variable with a file exists |
|
427 |
%.checkfil: |
|
428 |
@if [ ! -f $($*) ] ; then \ |
|
429 |
$(ECHO) "WARNING: $* does not exist, try $(MAKE) sanity"; \ |
|
430 |
fi |
|
431 |
||
432 |
# Misc notes on help |
|
433 |
notes_help: |
|
434 |
@$(ECHO) "\ |
|
435 |
--- Notes --- \n\ |
|
436 |
- All builds use same output directory unless overridden with \n\ |
|
437 |
\t ALT_OUTPUTDIR=<dir>, changing from product to fastdebug you may want \n\ |
|
438 |
\t to use the clean target first. \n\ |
|
439 |
- JDK_IMPORT_PATH must refer to a compatible build, not all past promoted \n\ |
|
440 |
\t builds or previous release JDK builds will work. \n\ |
|
441 |
- The fastest builds have been when the sources and the BOOTDIR are on \n\ |
|
442 |
\t local disk. \n\ |
|
443 |
" |
|
444 |
||
445 |
examples_help: |
|
446 |
@$(ECHO) "\ |
|
447 |
--- Examples --- \n\ |
|
448 |
$(MAKE) fastdebug_build \n\ |
|
449 |
$(MAKE) ALT_OUTPUTDIR=/tmp/foobar all \n\ |
|
450 |
$(MAKE) ALT_OUTPUTDIR=/tmp/foobar fastdebug_build \n\ |
|
451 |
$(MAKE) ALT_OUTPUTDIR=/tmp/foobar all \n\ |
|
452 |
$(MAKE) ALT_BOOTDIR=/opt/java/jdk1.5.0 \n\ |
|
453 |
$(MAKE) ALT_JDK_IMPORT_PATH=/opt/java/jdk1.6.0 \n\ |
|
454 |
" |
|
455 |
||
456 |
################################################################ |
|
457 |
# Source and binary plug bundling |
|
458 |
################################################################ |
|
459 |
ifeq ($(BUNDLE_RULES_AVAILABLE), true) |
|
460 |
include $(BUNDLE_RULES) |
|
461 |
endif |
|
462 |
||
463 |
################################################################ |
|
464 |
# Cycle build. Build the jdk, use it to build the jdk again. |
|
465 |
################################################################ |
|
466 |
||
16
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
467 |
ABS_BOOTDIR_OUTPUTDIR=$(ABS_OUTPUTDIR)/bootjdk |
0 | 468 |
|
469 |
boot_cycle: |
|
16
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
470 |
$(MAKE) ALT_OUTPUTDIR=$(ABS_BOOTDIR_OUTPUTDIR) product_build |
13adabd0ff72
6649270: Change by-default openjdk building in control/make/makefile to use open source tree
ohair
parents:
0
diff
changeset
|
471 |
$(MAKE) ALT_BOOTDIR=$(ABS_BOOTDIR_OUTPUTDIR)/j2sdk-image product_build |
0 | 472 |
|
473 |
################################################################ |
|
474 |
# JPRT rule to build |
|
475 |
################################################################ |
|
476 |
||
477 |
include ./make/jprt.gmk |
|
478 |
||
479 |
################################################################ |
|
480 |
# PHONY |
|
481 |
################################################################ |
|
482 |
||
483 |
.PHONY: all build what clobber insane \ |
|
484 |
fastdebug_build debug_build product_build setup \ |
|
485 |
dev dev-build dev-sanity dev-clobber |
|
486 |
||
17
bb9f330cd95a
6649672: Adjustments to OUTPUTDIR default and mkdirs to avoid empty directory clutter
ohair
parents:
16
diff
changeset
|
487 |
# Force target |
bb9f330cd95a
6649672: Adjustments to OUTPUTDIR default and mkdirs to avoid empty directory clutter
ohair
parents:
16
diff
changeset
|
488 |
FRC: |
bb9f330cd95a
6649672: Adjustments to OUTPUTDIR default and mkdirs to avoid empty directory clutter
ohair
parents:
16
diff
changeset
|
489 |