author | mduigou |
Thu, 17 Mar 2011 13:13:08 -0700 | |
changeset 8800 | e658ae923d53 |
parent 8307 | edbc4c94fd00 |
child 10565 | dc90c239f4ec |
child 10559 | a94d067da388 |
permissions | -rw-r--r-- |
1 | 1 |
# |
8307
edbc4c94fd00
7018429: JPRT: Update Makefile to use ALT_JDK_TARGET_IMPORT_PATH for copying JDK
dholmes
parents:
8114
diff
changeset
|
2 |
# Copyright (c) 2005, 2011, Oracle and/or its affiliates. All rights reserved. |
1 | 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. |
|
8 |
# |
|
9 |
# This code is distributed in the hope that it will be useful, but WITHOUT |
|
10 |
# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or |
|
11 |
# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License |
|
12 |
# version 2 for more details (a copy is included in the LICENSE file that |
|
13 |
# accompanied this code). |
|
14 |
# |
|
15 |
# You should have received a copy of the GNU General Public License version |
|
16 |
# 2 along with this work; if not, write to the Free Software Foundation, |
|
17 |
# Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. |
|
18 |
# |
|
5547
f4b087cbb361
6941466: Oracle rebranding changes for Hotspot repositories
trims
parents:
4733
diff
changeset
|
19 |
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA |
f4b087cbb361
6941466: Oracle rebranding changes for Hotspot repositories
trims
parents:
4733
diff
changeset
|
20 |
# or visit www.oracle.com if you need additional information or have any |
f4b087cbb361
6941466: Oracle rebranding changes for Hotspot repositories
trims
parents:
4733
diff
changeset
|
21 |
# questions. |
1 | 22 |
# |
23 |
# |
|
24 |
||
25 |
# Top level gnumake file for hotspot builds |
|
26 |
# |
|
27 |
# Default is to build the both product images and construct an export dir. |
|
28 |
# The default export directory name is `pwd`/export-$(PLATFORM). |
|
29 |
# |
|
30 |
# Use: 'gnumake help' for more information. |
|
31 |
# |
|
32 |
# This makefile uses the default settings for where to find compilers and |
|
33 |
# tools, and obeys the ALT_* variable settings used by the other JDK |
|
34 |
# workspaces. |
|
35 |
# |
|
36 |
||
37 |
# Expected/optional make variables defined on make command line: |
|
38 |
# LP64=1 or ARCH_DATA_MODEL=64 for 64bit build |
|
39 |
# |
|
40 |
# Expected/optional make variables or environment variables: |
|
41 |
# ALT_SLASH_JAVA Location of /java or J: |
|
42 |
# ALT_BOOTDIR Previous JDK home directory for javac compiler |
|
43 |
# ALT_OUTPUTDIR Output directory to use for hotspot build |
|
44 |
# ALT_EXPORT_PATH Directory to export hotspot build to |
|
45 |
# ALT_JDK_IMPORT_PATH Current JDK build (only for create_jdk rules) |
|
8307
edbc4c94fd00
7018429: JPRT: Update Makefile to use ALT_JDK_TARGET_IMPORT_PATH for copying JDK
dholmes
parents:
8114
diff
changeset
|
46 |
# ALT_JDK_TARGET_IMPORT_PATH Current JDK build when cross-compiling |
1 | 47 |
# ALT_BUILD_WIN_SA Building SA on Windows is disabled by default. |
48 |
# Set ALT_BUILD_WIN_SA=1 to enable building SA on |
|
49 |
# Windows. |
|
50 |
# Version strings and numbers: |
|
51 |
# JDK_VERSION Current JDK version (e.g. 1.6.0) |
|
52 |
# PREVIOUS_JDK_VERSION Previous (bootdir) JDK version (e.g. 1.5.0) |
|
53 |
# FULL_VERSION Full version string to use (e.g. "1.6.0-ea-b42") |
|
54 |
# |
|
55 |
# Version strings and numbers especially needed on Windows: |
|
56 |
# COOKED_JDK_UPDATE_VERSION Just the update release number (e.g. 02) |
|
57 |
# COOKED_BUILD_NUMBER Just the build number (e.g. 42) |
|
58 |
# JDK_MKTG_VERSION Marketing JDK version (e.g. 6.0) |
|
59 |
# JDK_MAJOR_VERSION Major number for version (e.g. 1) always 1? |
|
60 |
# JDK_MINOR_VERSION Minor number for version (e.g. 6) |
|
61 |
# JDK_MICRO_VERSION Micro number for version (e.g. 0) |
|
62 |
# |
|
63 |
||
64 |
# Default is build both product fastdebug and create export area |
|
65 |
||
66 |
# Allow to build HotSpot in local directory from sources specified by GAMMADIR. |
|
67 |
# After make/defs.make GAMMADIR is defined. |
|
68 |
ifdef GAMMADIR |
|
69 |
ifndef ALT_OUTPUTDIR |
|
70 |
ALT_OUTPUTDIR := $(shell pwd) |
|
71 |
endif |
|
72 |
include $(GAMMADIR)/make/defs.make |
|
73 |
else |
|
74 |
include defs.make |
|
75 |
endif |
|
76 |
||
8114
340b5b8b544b
7003401: Implement VM error-reporting functionality on erroneous termination
kamg
parents:
8107
diff
changeset
|
77 |
include $(GAMMADIR)/make/altsrc.make |
1 | 78 |
|
79 |
ifneq ($(ALT_OUTPUTDIR),) |
|
80 |
ALT_OUT=ALT_OUTPUTDIR=$(ALT_OUTPUTDIR) |
|
81 |
else |
|
82 |
ALT_OUT= |
|
83 |
endif |
|
84 |
||
85 |
# Typical C1/C2 targets made available with this Makefile |
|
86 |
C1_VM_TARGETS=product1 fastdebug1 optimized1 jvmg1 |
|
87 |
C2_VM_TARGETS=product fastdebug optimized jvmg |
|
88 |
KERNEL_VM_TARGETS=productkernel fastdebugkernel optimizedkernel jvmgkernel |
|
4013 | 89 |
ZERO_VM_TARGETS=productzero fastdebugzero optimizedzero jvmgzero |
6187 | 90 |
SHARK_VM_TARGETS=productshark fastdebugshark optimizedshark jvmgshark |
1 | 91 |
|
360
21d113ecbf6a
6420645: Create a vm that uses compressed oops for up to 32gb heapsizes
coleenp
parents:
1
diff
changeset
|
92 |
# JDK directory list |
21d113ecbf6a
6420645: Create a vm that uses compressed oops for up to 32gb heapsizes
coleenp
parents:
1
diff
changeset
|
93 |
JDK_DIRS=bin include jre lib demo |
21d113ecbf6a
6420645: Create a vm that uses compressed oops for up to 32gb heapsizes
coleenp
parents:
1
diff
changeset
|
94 |
|
1 | 95 |
all: all_product all_fastdebug |
6176
4d9030fe341f
6953477: Increase portability and flexibility of building Hotspot
bobv
parents:
5547
diff
changeset
|
96 |
ifndef BUILD_CLIENT_ONLY |
1 | 97 |
all_product: product product1 productkernel docs export_product |
98 |
all_fastdebug: fastdebug fastdebug1 fastdebugkernel docs export_fastdebug |
|
99 |
all_debug: jvmg jvmg1 jvmgkernel docs export_debug |
|
6176
4d9030fe341f
6953477: Increase portability and flexibility of building Hotspot
bobv
parents:
5547
diff
changeset
|
100 |
else |
4d9030fe341f
6953477: Increase portability and flexibility of building Hotspot
bobv
parents:
5547
diff
changeset
|
101 |
all_product: product1 docs export_product |
4d9030fe341f
6953477: Increase portability and flexibility of building Hotspot
bobv
parents:
5547
diff
changeset
|
102 |
all_fastdebug: fastdebug1 docs export_fastdebug |
4d9030fe341f
6953477: Increase portability and flexibility of building Hotspot
bobv
parents:
5547
diff
changeset
|
103 |
all_debug: jvmg1 docs export_debug |
4d9030fe341f
6953477: Increase portability and flexibility of building Hotspot
bobv
parents:
5547
diff
changeset
|
104 |
endif |
1 | 105 |
all_optimized: optimized optimized1 optimizedkernel docs export_optimized |
106 |
||
4013 | 107 |
allzero: all_productzero all_fastdebugzero |
108 |
all_productzero: productzero docs export_product |
|
109 |
all_fastdebugzero: fastdebugzero docs export_fastdebug |
|
110 |
all_debugzero: jvmgzero docs export_debug |
|
111 |
all_optimizedzero: optimizedzero docs export_optimized |
|
112 |
||
6187 | 113 |
allshark: all_productshark all_fastdebugshark |
114 |
all_productshark: productshark docs export_product |
|
115 |
all_fastdebugshark: fastdebugshark docs export_fastdebug |
|
116 |
all_debugshark: jvmgshark docs export_debug |
|
117 |
all_optimizedshark: optimizedshark docs export_optimized |
|
118 |
||
1 | 119 |
# Do everything |
120 |
world: all create_jdk |
|
121 |
||
122 |
# Build or export docs |
|
123 |
docs: |
|
124 |
ifeq ($(OSNAME),windows) |
|
125 |
@$(ECHO) "No docs ($(VM_TARGET)) for windows" |
|
126 |
else |
|
127 |
$(CD) $(OUTPUTDIR); \ |
|
128 |
$(MAKE) -f $(ABS_OS_MAKEFILE) \ |
|
129 |
$(MAKE_ARGS) docs |
|
130 |
endif |
|
131 |
||
132 |
# Build variation of hotspot |
|
133 |
$(C1_VM_TARGETS): |
|
134 |
$(CD) $(GAMMADIR)/make; \ |
|
135 |
$(MAKE) VM_TARGET=$@ generic_build1 $(ALT_OUT) |
|
136 |
||
137 |
$(C2_VM_TARGETS): |
|
138 |
$(CD) $(GAMMADIR)/make; \ |
|
139 |
$(MAKE) VM_TARGET=$@ generic_build2 $(ALT_OUT) |
|
140 |
||
141 |
$(KERNEL_VM_TARGETS): |
|
142 |
$(CD) $(GAMMADIR)/make; \ |
|
143 |
$(MAKE) VM_TARGET=$@ generic_buildkernel $(ALT_OUT) |
|
144 |
||
4013 | 145 |
$(ZERO_VM_TARGETS): |
146 |
$(CD) $(GAMMADIR)/make; \ |
|
147 |
$(MAKE) VM_TARGET=$@ generic_buildzero $(ALT_OUT) |
|
148 |
||
6187 | 149 |
$(SHARK_VM_TARGETS): |
150 |
$(CD) $(GAMMADIR)/make; \ |
|
151 |
$(MAKE) VM_TARGET=$@ generic_buildshark $(ALT_OUT) |
|
152 |
||
1 | 153 |
# Build compiler1 (client) rule, different for platforms |
154 |
generic_build1: |
|
155 |
$(MKDIR) -p $(OUTPUTDIR) |
|
156 |
ifeq ($(OSNAME),windows) |
|
157 |
ifeq ($(ARCH_DATA_MODEL), 32) |
|
158 |
$(CD) $(OUTPUTDIR); \ |
|
159 |
$(NMAKE) -f $(ABS_OS_MAKEFILE) \ |
|
160 |
Variant=compiler1 \ |
|
161 |
WorkSpace=$(ABS_GAMMADIR) \ |
|
162 |
BootStrapDir=$(ABS_BOOTDIR) \ |
|
163 |
BuildUser=$(USERNAME) \ |
|
164 |
$(MAKE_ARGS) $(VM_TARGET:%1=%) |
|
165 |
else |
|
166 |
@$(ECHO) "No compiler1 ($(VM_TARGET)) for ARCH_DATA_MODEL=$(ARCH_DATA_MODEL)" |
|
167 |
endif |
|
168 |
else |
|
169 |
ifeq ($(ARCH_DATA_MODEL), 32) |
|
170 |
$(CD) $(OUTPUTDIR); \ |
|
171 |
$(MAKE) -f $(ABS_OS_MAKEFILE) \ |
|
172 |
$(MAKE_ARGS) $(VM_TARGET) |
|
173 |
else |
|
174 |
@$(ECHO) "No compiler1 ($(VM_TARGET)) for ARCH_DATA_MODEL=$(ARCH_DATA_MODEL)" |
|
175 |
endif |
|
176 |
endif |
|
177 |
||
178 |
# Build compiler2 (server) rule, different for platforms |
|
179 |
generic_build2: |
|
180 |
$(MKDIR) -p $(OUTPUTDIR) |
|
181 |
ifeq ($(OSNAME),windows) |
|
182 |
$(CD) $(OUTPUTDIR); \ |
|
183 |
$(NMAKE) -f $(ABS_OS_MAKEFILE) \ |
|
184 |
Variant=compiler2 \ |
|
185 |
WorkSpace=$(ABS_GAMMADIR) \ |
|
186 |
BootStrapDir=$(ABS_BOOTDIR) \ |
|
187 |
BuildUser=$(USERNAME) \ |
|
188 |
$(MAKE_ARGS) $(VM_TARGET) |
|
189 |
else |
|
190 |
$(CD) $(OUTPUTDIR); \ |
|
191 |
$(MAKE) -f $(ABS_OS_MAKEFILE) \ |
|
192 |
$(MAKE_ARGS) $(VM_TARGET) |
|
193 |
endif |
|
194 |
||
195 |
generic_buildkernel: |
|
196 |
$(MKDIR) -p $(OUTPUTDIR) |
|
197 |
ifeq ($(OSNAME),windows) |
|
198 |
ifeq ($(ARCH_DATA_MODEL), 32) |
|
199 |
$(CD) $(OUTPUTDIR); \ |
|
200 |
$(NMAKE) -f $(ABS_OS_MAKEFILE) \ |
|
201 |
Variant=kernel \ |
|
202 |
WorkSpace=$(ABS_GAMMADIR) \ |
|
203 |
BootStrapDir=$(ABS_BOOTDIR) \ |
|
204 |
BuildUser=$(USERNAME) \ |
|
205 |
$(MAKE_ARGS) $(VM_TARGET:%kernel=%) |
|
206 |
else |
|
207 |
@$(ECHO) "No kernel ($(VM_TARGET)) for ARCH_DATA_MODEL=$(ARCH_DATA_MODEL)" |
|
208 |
endif |
|
209 |
else |
|
210 |
@$(ECHO) "No kernel ($(VM_TARGET)) for OS_NAME=$(OSNAME)" |
|
211 |
endif |
|
212 |
||
4013 | 213 |
generic_buildzero: |
214 |
$(MKDIR) -p $(OUTPUTDIR) |
|
215 |
$(CD) $(OUTPUTDIR); \ |
|
216 |
$(MAKE) -f $(ABS_OS_MAKEFILE) \ |
|
217 |
$(MAKE_ARGS) $(VM_TARGET) |
|
218 |
||
6187 | 219 |
generic_buildshark: |
220 |
$(MKDIR) -p $(OUTPUTDIR) |
|
221 |
$(CD) $(OUTPUTDIR); \ |
|
222 |
$(MAKE) -f $(ABS_OS_MAKEFILE) \ |
|
223 |
$(MAKE_ARGS) $(VM_TARGET) |
|
224 |
||
1 | 225 |
# Export file rule |
226 |
generic_export: $(EXPORT_LIST) |
|
227 |
export_product: |
|
228 |
$(MAKE) VM_SUBDIR=product generic_export |
|
229 |
export_fastdebug: |
|
230 |
$(MAKE) VM_SUBDIR=fastdebug EXPORT_SUBDIR=/fastdebug generic_export |
|
231 |
export_debug: |
|
232 |
$(MAKE) VM_SUBDIR=${VM_DEBUG} EXPORT_SUBDIR=/debug generic_export |
|
233 |
export_optimized: |
|
234 |
$(MAKE) VM_SUBDIR=optimized EXPORT_SUBDIR=/optimized generic_export |
|
235 |
export_product_jdk: |
|
236 |
$(MAKE) ALT_EXPORT_PATH=$(JDK_IMAGE_DIR) \ |
|
237 |
VM_SUBDIR=product generic_export |
|
238 |
export_optimized_jdk: |
|
239 |
$(MAKE) ALT_EXPORT_PATH=$(JDK_IMAGE_DIR) \ |
|
240 |
VM_SUBDIR=optimized generic_export |
|
241 |
export_fastdebug_jdk: |
|
242 |
$(MAKE) ALT_EXPORT_PATH=$(JDK_IMAGE_DIR)/fastdebug \ |
|
243 |
VM_SUBDIR=fastdebug generic_export |
|
244 |
export_debug_jdk: |
|
245 |
$(MAKE) ALT_EXPORT_PATH=$(JDK_IMAGE_DIR)/debug \ |
|
246 |
VM_SUBDIR=${VM_DEBUG} generic_export |
|
247 |
||
248 |
||
249 |
# Export file copy rules |
|
250 |
XUSAGE=$(HS_SRC_DIR)/share/vm/Xusage.txt |
|
251 |
DOCS_DIR=$(OUTPUTDIR)/$(VM_PLATFORM)_docs |
|
252 |
C1_BASE_DIR=$(OUTPUTDIR)/$(VM_PLATFORM)_compiler1 |
|
253 |
C2_BASE_DIR=$(OUTPUTDIR)/$(VM_PLATFORM)_compiler2 |
|
254 |
KERNEL_BASE_DIR=$(OUTPUTDIR)/$(VM_PLATFORM)_kernel |
|
4013 | 255 |
ZERO_BASE_DIR=$(OUTPUTDIR)/$(VM_PLATFORM)_zero |
6187 | 256 |
SHARK_BASE_DIR=$(OUTPUTDIR)/$(VM_PLATFORM)_shark |
1 | 257 |
C1_DIR=$(C1_BASE_DIR)/$(VM_SUBDIR) |
258 |
C2_DIR=$(C2_BASE_DIR)/$(VM_SUBDIR) |
|
259 |
KERNEL_DIR=$(KERNEL_BASE_DIR)/$(VM_SUBDIR) |
|
4013 | 260 |
ZERO_DIR=$(ZERO_BASE_DIR)/$(VM_SUBDIR) |
6187 | 261 |
SHARK_DIR=$(SHARK_BASE_DIR)/$(VM_SUBDIR) |
1 | 262 |
|
263 |
# Misc files and generated files need to come from C1 or C2 area |
|
4013 | 264 |
ifeq ($(ZERO_BUILD), true) |
6187 | 265 |
ifeq ($(SHARK_BUILD), true) |
266 |
MISC_DIR=$(SHARK_DIR) |
|
267 |
GEN_DIR=$(SHARK_BASE_DIR)/generated |
|
268 |
else |
|
4013 | 269 |
MISC_DIR=$(ZERO_DIR) |
270 |
GEN_DIR=$(ZERO_BASE_DIR)/generated |
|
6187 | 271 |
endif |
4013 | 272 |
else |
1 | 273 |
ifeq ($(ARCH_DATA_MODEL), 32) |
274 |
MISC_DIR=$(C1_DIR) |
|
275 |
GEN_DIR=$(C1_BASE_DIR)/generated |
|
276 |
else |
|
277 |
MISC_DIR=$(C2_DIR) |
|
278 |
GEN_DIR=$(C2_BASE_DIR)/generated |
|
279 |
endif |
|
4013 | 280 |
endif |
1 | 281 |
|
282 |
# Bin files (windows) |
|
283 |
ifeq ($(OSNAME),windows) |
|
284 |
||
285 |
# Get jvm.lib |
|
286 |
$(EXPORT_LIB_DIR)/%.lib: $(MISC_DIR)/%.lib |
|
287 |
$(install-file) |
|
288 |
||
289 |
# Other libraries (like SA) |
|
290 |
$(EXPORT_JRE_BIN_DIR)/%.dll: $(MISC_DIR)/%.dll |
|
291 |
$(install-file) |
|
292 |
$(EXPORT_JRE_BIN_DIR)/%.pdb: $(MISC_DIR)/%.pdb |
|
293 |
$(install-file) |
|
294 |
$(EXPORT_JRE_BIN_DIR)/%.map: $(MISC_DIR)/%.map |
|
295 |
$(install-file) |
|
296 |
||
297 |
# Client files always come from C1 area |
|
298 |
$(EXPORT_CLIENT_DIR)/%.dll: $(C1_DIR)/%.dll |
|
299 |
$(install-file) |
|
300 |
$(EXPORT_CLIENT_DIR)/%.pdb: $(C1_DIR)/%.pdb |
|
301 |
$(install-file) |
|
302 |
$(EXPORT_CLIENT_DIR)/%.map: $(C1_DIR)/%.map |
|
303 |
$(install-file) |
|
304 |
||
305 |
# Server files always come from C2 area |
|
306 |
$(EXPORT_SERVER_DIR)/%.dll: $(C2_DIR)/%.dll |
|
307 |
$(install-file) |
|
308 |
$(EXPORT_SERVER_DIR)/%.pdb: $(C2_DIR)/%.pdb |
|
309 |
$(install-file) |
|
310 |
$(EXPORT_SERVER_DIR)/%.map: $(C2_DIR)/%.map |
|
311 |
$(install-file) |
|
312 |
||
313 |
# Kernel files always come from kernel area |
|
314 |
$(EXPORT_KERNEL_DIR)/%.dll: $(KERNEL_DIR)/%.dll |
|
315 |
$(install-file) |
|
316 |
$(EXPORT_KERNEL_DIR)/%.pdb: $(KERNEL_DIR)/%.pdb |
|
317 |
$(install-file) |
|
318 |
$(EXPORT_KERNEL_DIR)/%.map: $(KERNEL_DIR)/%.map |
|
319 |
$(install-file) |
|
320 |
endif |
|
321 |
||
322 |
# Shared Library |
|
323 |
ifneq ($(OSNAME),windows) |
|
4013 | 324 |
ifeq ($(ZERO_BUILD), true) |
6187 | 325 |
ifeq ($(SHARK_BUILD), true) |
326 |
$(EXPORT_JRE_LIB_ARCH_DIR)/%.so: $(SHARK_DIR)/%.so |
|
327 |
$(install-file) |
|
328 |
$(EXPORT_SERVER_DIR)/%.so: $(SHARK_DIR)/%.so |
|
329 |
$(install-file) |
|
330 |
else |
|
4013 | 331 |
$(EXPORT_JRE_LIB_ARCH_DIR)/%.so: $(ZERO_DIR)/%.so |
332 |
$(install-file) |
|
333 |
$(EXPORT_SERVER_DIR)/%.so: $(ZERO_DIR)/%.so |
|
334 |
$(install-file) |
|
6187 | 335 |
endif |
4013 | 336 |
else |
6176
4d9030fe341f
6953477: Increase portability and flexibility of building Hotspot
bobv
parents:
5547
diff
changeset
|
337 |
$(EXPORT_JRE_LIB_ARCH_DIR)/%.so: $(C1_DIR)/%.so |
4d9030fe341f
6953477: Increase portability and flexibility of building Hotspot
bobv
parents:
5547
diff
changeset
|
338 |
$(install-file) |
1 | 339 |
$(EXPORT_JRE_LIB_ARCH_DIR)/%.so: $(C2_DIR)/%.so |
340 |
$(install-file) |
|
341 |
$(EXPORT_CLIENT_DIR)/%.so: $(C1_DIR)/%.so |
|
342 |
$(install-file) |
|
343 |
$(EXPORT_CLIENT_DIR)/64/%.so: $(C1_DIR)/%.so |
|
344 |
$(install-file) |
|
345 |
$(EXPORT_SERVER_DIR)/%.so: $(C2_DIR)/%.so |
|
346 |
$(install-file) |
|
347 |
$(EXPORT_SERVER_DIR)/64/%.so: $(C2_DIR)/%.so |
|
348 |
$(install-file) |
|
4013 | 349 |
endif |
1 | 350 |
endif |
351 |
||
352 |
# Jar file (sa-jdi.jar) |
|
353 |
$(EXPORT_LIB_DIR)/%.jar: $(GEN_DIR)/%.jar |
|
354 |
$(install-file) |
|
355 |
||
4732
a70548606f73
6580131: 3/4 CompiledMethodLoad events don't produce the expected extra notifications to describe inlining
dcubed
parents:
670
diff
changeset
|
356 |
# Include files (jvmti.h, jvmticmlr.h, jni.h, $(JDK_INCLUDE_SUBDIR)/jni_md.h, jmm.h) |
1 | 357 |
$(EXPORT_INCLUDE_DIR)/%: $(GEN_DIR)/jvmtifiles/% |
358 |
$(install-file) |
|
359 |
||
4732
a70548606f73
6580131: 3/4 CompiledMethodLoad events don't produce the expected extra notifications to describe inlining
dcubed
parents:
670
diff
changeset
|
360 |
$(EXPORT_INCLUDE_DIR)/%: $(HS_SRC_DIR)/share/vm/code/% |
a70548606f73
6580131: 3/4 CompiledMethodLoad events don't produce the expected extra notifications to describe inlining
dcubed
parents:
670
diff
changeset
|
361 |
$(install-file) |
a70548606f73
6580131: 3/4 CompiledMethodLoad events don't produce the expected extra notifications to describe inlining
dcubed
parents:
670
diff
changeset
|
362 |
|
1 | 363 |
$(EXPORT_INCLUDE_DIR)/%: $(HS_SRC_DIR)/share/vm/prims/% |
364 |
$(install-file) |
|
365 |
||
8114
340b5b8b544b
7003401: Implement VM error-reporting functionality on erroneous termination
kamg
parents:
8107
diff
changeset
|
366 |
HS_JNI_ARCH_SRC=$(call altsrc-replace,$(HS_COMMON_SRC)/cpu/$(HS_ARCH)/vm/jni_$(HS_ARCH).h) |
340b5b8b544b
7003401: Implement VM error-reporting functionality on erroneous termination
kamg
parents:
8107
diff
changeset
|
367 |
$(EXPORT_INCLUDE_DIR)/$(JDK_INCLUDE_SUBDIR)/jni_md.h: $(HS_JNI_ARCH_SRC) |
1 | 368 |
$(install-file) |
369 |
||
370 |
$(EXPORT_INCLUDE_DIR)/%: $(HS_SRC_DIR)/share/vm/services/% |
|
371 |
$(install-file) |
|
372 |
||
373 |
# Doc files (jvmti.html) |
|
374 |
$(EXPORT_DOCS_DIR)/platform/jvmti/%: $(DOCS_DIR)/% |
|
375 |
$(install-file) |
|
376 |
||
377 |
# Xusage file |
|
378 |
$(EXPORT_SERVER_DIR)/Xusage.txt $(EXPORT_CLIENT_DIR)/Xusage.txt $(EXPORT_KERNEL_DIR)/Xusage.txt: $(XUSAGE) |
|
379 |
$(prep-target) |
|
380 |
$(RM) $@.temp |
|
381 |
$(SED) 's/\(separated by \)[;:]/\1$(PATH_SEP)/g' $< > $@.temp |
|
382 |
$(MV) $@.temp $@ |
|
383 |
||
384 |
# |
|
385 |
# Clean rules |
|
386 |
# |
|
387 |
clobber clean: clean_build clean_export clean_jdk |
|
388 |
clean_build: |
|
389 |
$(RM) -r $(C1_DIR) |
|
390 |
$(RM) -r $(C2_DIR) |
|
391 |
$(RM) -r $(KERNEL_DIR) |
|
4013 | 392 |
$(RM) -r $(ZERO_DIR) |
6187 | 393 |
$(RM) -r $(SHARK_DIR) |
1 | 394 |
clean_export: |
395 |
$(RM) -r $(EXPORT_PATH) |
|
396 |
clean_jdk: |
|
397 |
$(RM) -r $(JDK_IMAGE_DIR) |
|
398 |
||
399 |
# |
|
400 |
# Create JDK and place this build into it |
|
401 |
# |
|
402 |
create_jdk: copy_jdk update_jdk |
|
403 |
||
404 |
update_jdk: export_product_jdk export_fastdebug_jdk test_jdk |
|
405 |
||
406 |
copy_jdk: $(JDK_IMAGE_DIR)/jre/lib/rt.jar |
|
407 |
||
408 |
$(JDK_IMAGE_DIR)/jre/lib/rt.jar: |
|
409 |
$(RM) -r $(JDK_IMAGE_DIR) |
|
410 |
$(MKDIR) -p $(JDK_IMAGE_DIR) |
|
411 |
($(CD) $(JDK_IMPORT_PATH) && \ |
|
412 |
$(TAR) -cf - *) | \ |
|
413 |
($(CD) $(JDK_IMAGE_DIR) && $(TAR) -xf -) |
|
414 |
||
415 |
test_jdk: |
|
4013 | 416 |
ifneq ($(ZERO_BUILD), true) |
417 |
ifeq ($(ARCH_DATA_MODEL), 32) |
|
1 | 418 |
$(JDK_IMAGE_DIR)/bin/java -client -version |
4013 | 419 |
endif |
1 | 420 |
endif |
421 |
$(JDK_IMAGE_DIR)/bin/java -server -version |
|
422 |
||
423 |
copy_product_jdk: |
|
424 |
$(RM) -r $(JDK_IMAGE_DIR) |
|
425 |
$(MKDIR) -p $(JDK_IMAGE_DIR) |
|
426 |
($(CD) $(JDK_IMPORT_PATH) && \ |
|
360
21d113ecbf6a
6420645: Create a vm that uses compressed oops for up to 32gb heapsizes
coleenp
parents:
1
diff
changeset
|
427 |
$(TAR) -cf - $(JDK_DIRS)) | \ |
1 | 428 |
($(CD) $(JDK_IMAGE_DIR) && $(TAR) -xf -) |
429 |
||
430 |
copy_fastdebug_jdk: |
|
431 |
$(RM) -r $(JDK_IMAGE_DIR)/fastdebug |
|
432 |
$(MKDIR) -p $(JDK_IMAGE_DIR)/fastdebug |
|
433 |
if [ -d $(JDK_IMPORT_PATH)/fastdebug ] ; then \ |
|
434 |
($(CD) $(JDK_IMPORT_PATH)/fastdebug && \ |
|
360
21d113ecbf6a
6420645: Create a vm that uses compressed oops for up to 32gb heapsizes
coleenp
parents:
1
diff
changeset
|
435 |
$(TAR) -cf - $(JDK_DIRS)) | \ |
1 | 436 |
($(CD) $(JDK_IMAGE_DIR)/fastdebug && $(TAR) -xf -) ; \ |
437 |
else \ |
|
438 |
($(CD) $(JDK_IMPORT_PATH) && \ |
|
360
21d113ecbf6a
6420645: Create a vm that uses compressed oops for up to 32gb heapsizes
coleenp
parents:
1
diff
changeset
|
439 |
$(TAR) -cf - $(JDK_DIRS)) | \ |
1 | 440 |
($(CD) $(JDK_IMAGE_DIR)/fastdebug && $(TAR) -xf -) ; \ |
441 |
fi |
|
442 |
||
443 |
copy_debug_jdk: |
|
444 |
$(RM) -r $(JDK_IMAGE_DIR)/debug |
|
445 |
$(MKDIR) -p $(JDK_IMAGE_DIR)/debug |
|
446 |
if [ -d $(JDK_IMPORT_PATH)/debug ] ; then \ |
|
447 |
($(CD) $(JDK_IMPORT_PATH)/debug && \ |
|
360
21d113ecbf6a
6420645: Create a vm that uses compressed oops for up to 32gb heapsizes
coleenp
parents:
1
diff
changeset
|
448 |
$(TAR) -cf - $(JDK_DIRS)) | \ |
1 | 449 |
($(CD) $(JDK_IMAGE_DIR)/debug && $(TAR) -xf -) ; \ |
450 |
elif [ -d $(JDK_IMPORT_PATH)/fastdebug ] ; then \ |
|
451 |
($(CD) $(JDK_IMPORT_PATH)/fastdebug && \ |
|
360
21d113ecbf6a
6420645: Create a vm that uses compressed oops for up to 32gb heapsizes
coleenp
parents:
1
diff
changeset
|
452 |
$(TAR) -cf - $(JDK_DIRS)) | \ |
1 | 453 |
($(CD) $(JDK_IMAGE_DIR)/debug && $(TAR) -xf -) ; \ |
454 |
else \ |
|
455 |
($(CD) $(JDK_IMPORT_PATH) && \ |
|
360
21d113ecbf6a
6420645: Create a vm that uses compressed oops for up to 32gb heapsizes
coleenp
parents:
1
diff
changeset
|
456 |
$(TAR) -cf - $(JDK_DIRS)) | \ |
1 | 457 |
($(CD) $(JDK_IMAGE_DIR)/debug && $(TAR) -xf -) ; \ |
458 |
fi |
|
459 |
||
460 |
# |
|
461 |
# Check target |
|
462 |
# |
|
463 |
check: variable_check |
|
464 |
||
465 |
# |
|
466 |
# Help target |
|
467 |
# |
|
468 |
help: intro_help target_help variable_help notes_help examples_help |
|
469 |
||
470 |
# Intro help message |
|
471 |
intro_help: |
|
472 |
@$(ECHO) \ |
|
473 |
"Makefile for the Hotspot workspace." |
|
474 |
@$(ECHO) \ |
|
475 |
"Default behavior is to build and create an export area for the j2se builds." |
|
476 |
||
477 |
# Target help |
|
478 |
target_help: |
|
479 |
@$(ECHO) "help: This help message" |
|
480 |
@$(ECHO) "all: Same as: all_product all_fastdebug" |
|
481 |
@$(ECHO) "world: Same as: all create_jdk" |
|
482 |
@$(ECHO) "all_product: Same as: product product1 export_product" |
|
483 |
@$(ECHO) "all_fastdebug: Same as: fastdebug fastdebug1 export_fastdebug" |
|
484 |
@$(ECHO) "all_debug: Same as: jvmg jvmg1 export_debug" |
|
485 |
@$(ECHO) "all_optimized: Same as: optimized optimized1 export_optimized" |
|
486 |
@$(ECHO) "clean: Clean all areas" |
|
487 |
@$(ECHO) "export_product: Export product files to EXPORT_PATH" |
|
488 |
@$(ECHO) "export_fastdebug: Export fastdebug files to EXPORT_PATH" |
|
489 |
@$(ECHO) "export_debug: Export debug files to EXPORT_PATH" |
|
490 |
@$(ECHO) "export_optimized: Export optimized files to EXPORT_PATH" |
|
491 |
@$(ECHO) "create_jdk: Create JDK image, export all files into it" |
|
492 |
@$(ECHO) "update_jdk: Update JDK image with fresh exported files" |
|
493 |
@$(ECHO) " " |
|
494 |
@$(ECHO) "Others targets are:" |
|
495 |
@$(ECHO) " $(C1_VM_TARGETS)" |
|
496 |
@$(ECHO) " $(C2_VM_TARGETS)" |
|
497 |
@$(ECHO) " $(KERNEL_VM_TARGETS)" |
|
498 |
||
499 |
# Variable help (only common ones used by this workspace) |
|
500 |
variable_help: variable_help_intro variable_list variable_help_end |
|
501 |
variable_help_intro: |
|
502 |
@$(ECHO) "--- Common Variables ---" |
|
503 |
variable_help_end: |
|
504 |
@$(ECHO) " " |
|
505 |
@$(ECHO) "--- Make Arguments ---" |
|
506 |
@$(ECHO) "MAKE_ARGS=$(MAKE_ARGS)" |
|
507 |
||
508 |
# One line descriptions for the variables |
|
509 |
SLASH_JAVA.desc = Root of all build tools, e.g. /java or J: |
|
510 |
OUTPUTDIR.desc = Output directory, default is build/<osname> |
|
511 |
BOOTDIR.desc = JDK used to compile agent java source and test with |
|
512 |
JDK_IMPORT_PATH.desc = Promoted JDK to copy for 'create_jdk' |
|
513 |
EXPORT_PATH.desc = Directory to place files to export for JDK build |
|
514 |
||
515 |
# Make variables to print out (description and value) |
|
516 |
VARIABLE_PRINTVAL_LIST += \ |
|
517 |
SLASH_JAVA \ |
|
518 |
OUTPUTDIR \ |
|
519 |
BOOTDIR \ |
|
520 |
JDK_IMPORT_PATH \ |
|
521 |
EXPORT_PATH |
|
522 |
||
523 |
# Make variables that should refer to directories that exist |
|
524 |
VARIABLE_CHECKDIR_LIST += \ |
|
525 |
SLASH_JAVA \ |
|
526 |
BOOTDIR \ |
|
527 |
JDK_IMPORT_PATH |
|
528 |
||
529 |
# For pattern rules below, so all are treated the same |
|
530 |
DO_PRINTVAL_LIST=$(VARIABLE_PRINTVAL_LIST:%=%.printval) |
|
531 |
DO_CHECKDIR_LIST=$(VARIABLE_CHECKDIR_LIST:%=%.checkdir) |
|
532 |
||
533 |
# Complete variable check |
|
534 |
variable_check: $(DO_CHECKDIR_LIST) |
|
535 |
variable_list: $(DO_PRINTVAL_LIST) variable_check |
|
536 |
||
537 |
# Pattern rule for printing out a variable |
|
538 |
%.printval: |
|
539 |
@$(ECHO) " ALT_$* - $($*.desc)" |
|
540 |
@$(ECHO) " $*=$($*)" |
|
541 |
||
542 |
# Pattern rule for checking to see if a variable with a directory exists |
|
543 |
%.checkdir: |
|
544 |
@if [ ! -d $($*) ] ; then \ |
|
545 |
$(ECHO) "WARNING: $* does not exist, try $(MAKE) sanity"; \ |
|
546 |
fi |
|
547 |
||
548 |
# Pattern rule for checking to see if a variable with a file exists |
|
549 |
%.checkfil: |
|
550 |
@if [ ! -f $($*) ] ; then \ |
|
551 |
$(ECHO) "WARNING: $* does not exist, try $(MAKE) sanity"; \ |
|
552 |
fi |
|
553 |
||
554 |
# Misc notes on help |
|
555 |
notes_help: |
|
556 |
@$(ECHO) \ |
|
557 |
"--- Notes --- " |
|
558 |
@$(ECHO) \ |
|
559 |
"- JDK_IMPORT_PATH must refer to a compatible build, not all past promoted" |
|
560 |
@$(ECHO) \ |
|
561 |
" builds or previous release JDK builds will work." |
|
562 |
@$(ECHO) \ |
|
563 |
"- The fastest builds have been when the workspace and the BOOTDIR are on" |
|
564 |
@$(ECHO) \ |
|
565 |
" local disk." |
|
566 |
||
567 |
examples_help: |
|
568 |
@$(ECHO) \ |
|
569 |
"--- Examples --- " |
|
570 |
@$(ECHO) \ |
|
571 |
" $(MAKE) all" |
|
572 |
@$(ECHO) \ |
|
573 |
" $(MAKE) world" |
|
574 |
@$(ECHO) \ |
|
575 |
" $(MAKE) ALT_BOOTDIR=/opt/java/jdk$(PREVIOUS_JDK_VERSION)" |
|
576 |
@$(ECHO) \ |
|
577 |
" $(MAKE) ALT_JDK_IMPORT_PATH=/opt/java/jdk$(JDK_VERSION)" |
|
578 |
||
579 |
# JPRT rule to build this workspace |
|
580 |
include $(GAMMADIR)/make/jprt.gmk |
|
581 |
||
582 |
.PHONY: all world clobber clean help $(C1_VM_TARGETS) $(C2_VM_TARGETS) \ |
|
583 |
$(KERNEL_VM_TARGETS) \ |
|
584 |
generic_build1 generic_build2 generic_buildkernel generic_export \ |
|
585 |
export_product export_fastdebug export_debug export_optimized \ |
|
586 |
export_jdk_product export_jdk_fastdebug export_jdk_debug \ |
|
587 |
create_jdk copy_jdk update_jdk test_jdk \ |
|
588 |
copy_product_jdk copy_fastdebug_jdk copy_debug_jdk |
|
589 |