author | coleenp |
Mon, 08 Oct 2012 09:18:54 -0400 | |
changeset 13958 | f5598a86c223 |
parent 12503 | 9df71f999005 |
child 14815 | 41114a74463a |
permissions | -rw-r--r-- |
1 | 1 |
# |
12501
ea7feae692ae
7102323: RFE: enable Full Debug Symbols Phase 1 on Solaris
dcubed
parents:
11593
diff
changeset
|
2 |
# Copyright (c) 2000, 2012, 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:
781
diff
changeset
|
19 |
# Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA |
f4b087cbb361
6941466: Oracle rebranding changes for Hotspot repositories
trims
parents:
781
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:
781
diff
changeset
|
21 |
# questions. |
1 | 22 |
# |
23 |
# |
|
24 |
||
25 |
# Usage: |
|
26 |
# |
|
27 |
# $(MAKE) -f buildtree.make ARCH=arch BUILDARCH=buildarch LIBARCH=libarch |
|
28 |
# GAMMADIR=dir OS_FAMILY=os VARIANT=variant |
|
29 |
# |
|
30 |
# The macros ARCH, GAMMADIR, OS_FAMILY and VARIANT must be defined in the |
|
31 |
# environment or on the command-line: |
|
32 |
# |
|
33 |
# ARCH - sparc, i486, ... HotSpot cpu and os_cpu source directory |
|
34 |
# BUILDARCH - build directory |
|
35 |
# LIBARCH - the corresponding directory in JDK/JRE |
|
36 |
# GAMMADIR - top of workspace |
|
37 |
# OS_FAMILY - operating system |
|
38 |
# VARIANT - core, compiler1, compiler2, or tiered |
|
39 |
# HOTSPOT_RELEASE_VERSION - <major>.<minor>-b<nn> (11.0-b07) |
|
7402
554c8ae9c3e0
6987107: Add variable to add to but not modify non-fcs version string
ohair
parents:
5547
diff
changeset
|
40 |
# HOTSPOT_BUILD_VERSION - internal, internal-$(USER_RELEASE_SUFFIX) or empty |
1 | 41 |
# JRE_RELEASE_VERSION - <major>.<minor>.<micro> (1.7.0) |
42 |
# |
|
43 |
# Builds the directory trees with makefiles plus some convenience files in |
|
44 |
# each directory: |
|
45 |
# |
|
46 |
# Makefile - for "make foo" |
|
47 |
# flags.make - with macro settings |
|
48 |
# vm.make - to support making "$(MAKE) -v vm.make" in makefiles |
|
49 |
# adlc.make - |
|
50 |
# jvmti.make - generate JVMTI bindings from the spec (JSR-163) |
|
51 |
# sa.make - generate SA jar file and natives |
|
52 |
# env.[ck]sh - environment settings |
|
53 |
# test_gamma - script to run the Queens program |
|
54 |
# |
|
55 |
# The makefiles are split this way so that "make foo" will run faster by not |
|
56 |
# having to read the dependency files for the vm. |
|
57 |
||
11955
aeca8151886e
7141244: build-infra merge: Include $(SPEC) in makefiles and make variables overridable
erikj
parents:
11593
diff
changeset
|
58 |
-include $(SPEC) |
1 | 59 |
include $(GAMMADIR)/make/scm.make |
8114
340b5b8b544b
7003401: Implement VM error-reporting functionality on erroneous termination
kamg
parents:
7718
diff
changeset
|
60 |
include $(GAMMADIR)/make/altsrc.make |
1 | 61 |
|
62 |
# 'gmake MAKE_VERBOSE=y' or 'gmake QUIETLY=' gives all the gory details. |
|
63 |
QUIETLY$(MAKE_VERBOSE) = @ |
|
64 |
||
65 |
# For now, until the compiler is less wobbly: |
|
7704 | 66 |
TESTFLAGS = -Xbatch -Xmx32m -showversion |
1 | 67 |
|
68 |
### maye ARCH_XXX instead? |
|
69 |
ifdef USE_GCC |
|
338
5cf9f61d76f4
6583644: Move all managed/SCCS files out of 'build' into 'make' directory
kamg
parents:
1
diff
changeset
|
70 |
PLATFORM_FILE = $(GAMMADIR)/make/$(OS_FAMILY)/platform_$(BUILDARCH).gcc |
1 | 71 |
GCC_LIB = /usr/local/lib |
72 |
else |
|
338
5cf9f61d76f4
6583644: Move all managed/SCCS files out of 'build' into 'make' directory
kamg
parents:
1
diff
changeset
|
73 |
PLATFORM_FILE = $(GAMMADIR)/make/$(OS_FAMILY)/platform_$(BUILDARCH) |
1 | 74 |
GCC_LIB = |
75 |
endif |
|
76 |
||
77 |
ifdef FORCE_TIERED |
|
78 |
ifeq ($(VARIANT),tiered) |
|
79 |
PLATFORM_DIR = $(OS_FAMILY)_$(BUILDARCH)_compiler2 |
|
80 |
else |
|
81 |
PLATFORM_DIR = $(OS_FAMILY)_$(BUILDARCH)_$(VARIANT) |
|
82 |
endif |
|
83 |
else |
|
84 |
PLATFORM_DIR = $(OS_FAMILY)_$(BUILDARCH)_$(VARIANT) |
|
85 |
endif |
|
86 |
||
87 |
# |
|
88 |
# We do two levels of exclusion in the shared directory. |
|
89 |
# TOPLEVEL excludes are pruned, they are not recursively searched, |
|
90 |
# but lower level directories can be named without fear of collision. |
|
91 |
# ALWAYS excludes are excluded at any level in the directory tree. |
|
92 |
# |
|
93 |
||
94 |
ALWAYS_EXCLUDE_DIRS = $(SCM_DIRS) |
|
95 |
||
96 |
ifeq ($(VARIANT),tiered) |
|
97 |
TOPLEVEL_EXCLUDE_DIRS = $(ALWAYS_EXCLUDE_DIRS) -o -name adlc -o -name agent |
|
98 |
else |
|
99 |
ifeq ($(VARIANT),compiler2) |
|
100 |
TOPLEVEL_EXCLUDE_DIRS = $(ALWAYS_EXCLUDE_DIRS) -o -name adlc -o -name c1 -o -name agent |
|
101 |
else |
|
102 |
# compiler1 and core use the same exclude list |
|
103 |
TOPLEVEL_EXCLUDE_DIRS = $(ALWAYS_EXCLUDE_DIRS) -o -name adlc -o -name opto -o -name libadt -o -name agent |
|
104 |
endif |
|
105 |
endif |
|
106 |
||
107 |
# Get things from the platform file. |
|
108 |
COMPILER = $(shell sed -n 's/^compiler[ ]*=[ ]*//p' $(PLATFORM_FILE)) |
|
109 |
||
110 |
SIMPLE_DIRS = \ |
|
7397 | 111 |
$(PLATFORM_DIR)/generated/dependencies \ |
1 | 112 |
$(PLATFORM_DIR)/generated/adfiles \ |
113 |
$(PLATFORM_DIR)/generated/jvmtifiles |
|
114 |
||
115 |
TARGETS = debug fastdebug jvmg optimized product profiled |
|
116 |
SUBMAKE_DIRS = $(addprefix $(PLATFORM_DIR)/,$(TARGETS)) |
|
117 |
||
118 |
# For dependencies and recursive makes. |
|
338
5cf9f61d76f4
6583644: Move all managed/SCCS files out of 'build' into 'make' directory
kamg
parents:
1
diff
changeset
|
119 |
BUILDTREE_MAKE = $(GAMMADIR)/make/$(OS_FAMILY)/makefiles/buildtree.make |
1 | 120 |
|
121 |
BUILDTREE_TARGETS = Makefile flags.make flags_vm.make vm.make adlc.make jvmti.make sa.make \ |
|
11593 | 122 |
env.sh env.csh jdkpath.sh .dbxrc test_gamma |
1 | 123 |
|
124 |
BUILDTREE_VARS = GAMMADIR=$(GAMMADIR) OS_FAMILY=$(OS_FAMILY) \ |
|
125 |
ARCH=$(ARCH) BUILDARCH=$(BUILDARCH) LIBARCH=$(LIBARCH) VARIANT=$(VARIANT) |
|
126 |
||
127 |
# Define variables to be set in flags.make. |
|
128 |
# Default values are set in make/defs.make. |
|
129 |
ifeq ($(HOTSPOT_BUILD_VERSION),) |
|
130 |
HS_BUILD_VER=$(HOTSPOT_RELEASE_VERSION) |
|
131 |
else |
|
132 |
HS_BUILD_VER=$(HOTSPOT_RELEASE_VERSION)-$(HOTSPOT_BUILD_VERSION) |
|
133 |
endif |
|
134 |
# Set BUILD_USER from system-dependent hints: $LOGNAME, $(whoami) |
|
135 |
ifndef HOTSPOT_BUILD_USER |
|
136 |
HOTSPOT_BUILD_USER := $(shell echo $$LOGNAME) |
|
137 |
endif |
|
138 |
ifndef HOTSPOT_BUILD_USER |
|
139 |
HOTSPOT_BUILD_USER := $(shell whoami) |
|
140 |
endif |
|
338
5cf9f61d76f4
6583644: Move all managed/SCCS files out of 'build' into 'make' directory
kamg
parents:
1
diff
changeset
|
141 |
# Define HOTSPOT_VM_DISTRO based on settings in make/openjdk_distro |
5cf9f61d76f4
6583644: Move all managed/SCCS files out of 'build' into 'make' directory
kamg
parents:
1
diff
changeset
|
142 |
# or make/hotspot_distro. |
1 | 143 |
ifndef HOTSPOT_VM_DISTRO |
8114
340b5b8b544b
7003401: Implement VM error-reporting functionality on erroneous termination
kamg
parents:
7718
diff
changeset
|
144 |
ifeq ($(call if-has-altsrc,$(HS_COMMON_SRC)/,true,false),true) |
338
5cf9f61d76f4
6583644: Move all managed/SCCS files out of 'build' into 'make' directory
kamg
parents:
1
diff
changeset
|
145 |
include $(GAMMADIR)/make/hotspot_distro |
1 | 146 |
else |
338
5cf9f61d76f4
6583644: Move all managed/SCCS files out of 'build' into 'make' directory
kamg
parents:
1
diff
changeset
|
147 |
include $(GAMMADIR)/make/openjdk_distro |
1 | 148 |
endif |
149 |
endif |
|
150 |
||
13958
f5598a86c223
7170638: Use DTRACE_PROBE[N] in JNI Set and SetStatic Field.
coleenp
parents:
12503
diff
changeset
|
151 |
# if hotspot-only build and/or OPENJDK isn't passed down, need to set OPENJDK |
f5598a86c223
7170638: Use DTRACE_PROBE[N] in JNI Set and SetStatic Field.
coleenp
parents:
12503
diff
changeset
|
152 |
ifndef OPENJDK |
f5598a86c223
7170638: Use DTRACE_PROBE[N] in JNI Set and SetStatic Field.
coleenp
parents:
12503
diff
changeset
|
153 |
ifneq ($(call if-has-altsrc,$(HS_COMMON_SRC)/,true,false),true) |
f5598a86c223
7170638: Use DTRACE_PROBE[N] in JNI Set and SetStatic Field.
coleenp
parents:
12503
diff
changeset
|
154 |
OPENJDK=true |
f5598a86c223
7170638: Use DTRACE_PROBE[N] in JNI Set and SetStatic Field.
coleenp
parents:
12503
diff
changeset
|
155 |
endif |
f5598a86c223
7170638: Use DTRACE_PROBE[N] in JNI Set and SetStatic Field.
coleenp
parents:
12503
diff
changeset
|
156 |
endif |
f5598a86c223
7170638: Use DTRACE_PROBE[N] in JNI Set and SetStatic Field.
coleenp
parents:
12503
diff
changeset
|
157 |
|
1 | 158 |
BUILDTREE_VARS += HOTSPOT_RELEASE_VERSION=$(HS_BUILD_VER) HOTSPOT_BUILD_VERSION= JRE_RELEASE_VERSION=$(JRE_RELEASE_VERSION) |
159 |
||
160 |
BUILDTREE = \ |
|
161 |
$(MAKE) -f $(BUILDTREE_MAKE) $(BUILDTREE_TARGETS) $(BUILDTREE_VARS) |
|
162 |
||
163 |
BUILDTREE_COMMENT = echo "\# Generated by $(BUILDTREE_MAKE)" |
|
164 |
||
165 |
all: $(SUBMAKE_DIRS) |
|
166 |
||
167 |
# Run make in each subdirectory recursively. |
|
168 |
$(SUBMAKE_DIRS): $(SIMPLE_DIRS) FORCE |
|
169 |
$(QUIETLY) [ -d $@ ] || { mkdir -p $@; } |
|
170 |
$(QUIETLY) cd $@ && $(BUILDTREE) TARGET=$(@F) |
|
171 |
$(QUIETLY) touch $@ |
|
172 |
||
173 |
$(SIMPLE_DIRS): |
|
174 |
$(QUIETLY) mkdir -p $@ |
|
175 |
||
8114
340b5b8b544b
7003401: Implement VM error-reporting functionality on erroneous termination
kamg
parents:
7718
diff
changeset
|
176 |
# Convenience macro which takes a source relative path, applies $(1) to the |
340b5b8b544b
7003401: Implement VM error-reporting functionality on erroneous termination
kamg
parents:
7718
diff
changeset
|
177 |
# absolute path, and then replaces $(GAMMADIR) in the result with a |
340b5b8b544b
7003401: Implement VM error-reporting functionality on erroneous termination
kamg
parents:
7718
diff
changeset
|
178 |
# literal "$(GAMMADIR)/" suitable for inclusion in a Makefile. |
340b5b8b544b
7003401: Implement VM error-reporting functionality on erroneous termination
kamg
parents:
7718
diff
changeset
|
179 |
gamma-path=$(subst $(GAMMADIR),\$$(GAMMADIR),$(call $(1),$(HS_COMMON_SRC)/$(2))) |
340b5b8b544b
7003401: Implement VM error-reporting functionality on erroneous termination
kamg
parents:
7718
diff
changeset
|
180 |
|
1 | 181 |
flags.make: $(BUILDTREE_MAKE) ../shared_dirs.lst |
182 |
@echo Creating $@ ... |
|
183 |
$(QUIETLY) ( \ |
|
184 |
$(BUILDTREE_COMMENT); \ |
|
185 |
echo; \ |
|
186 |
echo "Platform_file = $(PLATFORM_FILE)" | sed 's|$(GAMMADIR)|$$(GAMMADIR)|'; \ |
|
187 |
sed -n '/=/s/^ */Platform_/p' < $(PLATFORM_FILE); \ |
|
188 |
echo; \ |
|
189 |
echo "GAMMADIR = $(GAMMADIR)"; \ |
|
190 |
echo "SYSDEFS = \$$(Platform_sysdefs)"; \ |
|
191 |
echo "SRCARCH = $(ARCH)"; \ |
|
192 |
echo "BUILDARCH = $(BUILDARCH)"; \ |
|
193 |
echo "LIBARCH = $(LIBARCH)"; \ |
|
194 |
echo "TARGET = $(TARGET)"; \ |
|
195 |
echo "HS_BUILD_VER = $(HS_BUILD_VER)"; \ |
|
196 |
echo "JRE_RELEASE_VER = $(JRE_RELEASE_VERSION)"; \ |
|
197 |
echo "SA_BUILD_VERSION = $(HS_BUILD_VER)"; \ |
|
198 |
echo "HOTSPOT_BUILD_USER = $(HOTSPOT_BUILD_USER)"; \ |
|
199 |
echo "HOTSPOT_VM_DISTRO = $(HOTSPOT_VM_DISTRO)"; \ |
|
13958
f5598a86c223
7170638: Use DTRACE_PROBE[N] in JNI Set and SetStatic Field.
coleenp
parents:
12503
diff
changeset
|
200 |
echo "OPENJDK = $(OPENJDK)"; \ |
1 | 201 |
echo "$(LP64_SETTING/$(DATA_MODE))"; \ |
202 |
echo; \ |
|
7397 | 203 |
echo "# Used for platform dispatching"; \ |
204 |
echo "TARGET_DEFINES = -DTARGET_OS_FAMILY_\$$(Platform_os_family)"; \ |
|
205 |
echo "TARGET_DEFINES += -DTARGET_ARCH_\$$(Platform_arch)"; \ |
|
206 |
echo "TARGET_DEFINES += -DTARGET_ARCH_MODEL_\$$(Platform_arch_model)"; \ |
|
207 |
echo "TARGET_DEFINES += -DTARGET_OS_ARCH_\$$(Platform_os_arch)"; \ |
|
208 |
echo "TARGET_DEFINES += -DTARGET_OS_ARCH_MODEL_\$$(Platform_os_arch_model)"; \ |
|
209 |
echo "TARGET_DEFINES += -DTARGET_COMPILER_\$$(Platform_compiler)"; \ |
|
210 |
echo "CFLAGS += \$$(TARGET_DEFINES)"; \ |
|
211 |
echo; \ |
|
212 |
echo "Src_Dirs_V = \\"; \ |
|
1 | 213 |
sed 's/$$/ \\/;s|$(GAMMADIR)|$$(GAMMADIR)|' ../shared_dirs.lst; \ |
8114
340b5b8b544b
7003401: Implement VM error-reporting functionality on erroneous termination
kamg
parents:
7718
diff
changeset
|
214 |
echo "$(call gamma-path,altsrc,cpu/$(ARCH)/vm) \\"; \ |
340b5b8b544b
7003401: Implement VM error-reporting functionality on erroneous termination
kamg
parents:
7718
diff
changeset
|
215 |
echo "$(call gamma-path,commonsrc,cpu/$(ARCH)/vm) \\"; \ |
340b5b8b544b
7003401: Implement VM error-reporting functionality on erroneous termination
kamg
parents:
7718
diff
changeset
|
216 |
echo "$(call gamma-path,altsrc,os_cpu/$(OS_FAMILY)_$(ARCH)/vm) \\"; \ |
340b5b8b544b
7003401: Implement VM error-reporting functionality on erroneous termination
kamg
parents:
7718
diff
changeset
|
217 |
echo "$(call gamma-path,commonsrc,os_cpu/$(OS_FAMILY)_$(ARCH)/vm) \\"; \ |
340b5b8b544b
7003401: Implement VM error-reporting functionality on erroneous termination
kamg
parents:
7718
diff
changeset
|
218 |
echo "$(call gamma-path,altsrc,os/$(OS_FAMILY)/vm) \\"; \ |
340b5b8b544b
7003401: Implement VM error-reporting functionality on erroneous termination
kamg
parents:
7718
diff
changeset
|
219 |
echo "$(call gamma-path,commonsrc,os/$(OS_FAMILY)/vm) \\"; \ |
340b5b8b544b
7003401: Implement VM error-reporting functionality on erroneous termination
kamg
parents:
7718
diff
changeset
|
220 |
echo "$(call gamma-path,altsrc,os/posix/vm) \\"; \ |
340b5b8b544b
7003401: Implement VM error-reporting functionality on erroneous termination
kamg
parents:
7718
diff
changeset
|
221 |
echo "$(call gamma-path,commonsrc,os/posix/vm)"; \ |
7397 | 222 |
echo; \ |
223 |
echo "Src_Dirs_I = \\"; \ |
|
8114
340b5b8b544b
7003401: Implement VM error-reporting functionality on erroneous termination
kamg
parents:
7718
diff
changeset
|
224 |
echo "$(call gamma-path,altsrc,share/vm/prims) \\"; \ |
340b5b8b544b
7003401: Implement VM error-reporting functionality on erroneous termination
kamg
parents:
7718
diff
changeset
|
225 |
echo "$(call gamma-path,commonsrc,share/vm/prims) \\"; \ |
340b5b8b544b
7003401: Implement VM error-reporting functionality on erroneous termination
kamg
parents:
7718
diff
changeset
|
226 |
echo "$(call gamma-path,altsrc,share/vm) \\"; \ |
340b5b8b544b
7003401: Implement VM error-reporting functionality on erroneous termination
kamg
parents:
7718
diff
changeset
|
227 |
echo "$(call gamma-path,commonsrc,share/vm) \\"; \ |
10830
f3fedfa29811
7106766: Move the precompiled header from the src/share/vm directory
brutisso
parents:
10559
diff
changeset
|
228 |
echo "$(call gamma-path,altsrc,share/vm/precompiled) \\"; \ |
f3fedfa29811
7106766: Move the precompiled header from the src/share/vm directory
brutisso
parents:
10559
diff
changeset
|
229 |
echo "$(call gamma-path,commonsrc,share/vm/precompiled) \\"; \ |
8114
340b5b8b544b
7003401: Implement VM error-reporting functionality on erroneous termination
kamg
parents:
7718
diff
changeset
|
230 |
echo "$(call gamma-path,altsrc,cpu/$(ARCH)/vm) \\"; \ |
340b5b8b544b
7003401: Implement VM error-reporting functionality on erroneous termination
kamg
parents:
7718
diff
changeset
|
231 |
echo "$(call gamma-path,commonsrc,cpu/$(ARCH)/vm) \\"; \ |
340b5b8b544b
7003401: Implement VM error-reporting functionality on erroneous termination
kamg
parents:
7718
diff
changeset
|
232 |
echo "$(call gamma-path,altsrc,os_cpu/$(OS_FAMILY)_$(ARCH)/vm) \\"; \ |
340b5b8b544b
7003401: Implement VM error-reporting functionality on erroneous termination
kamg
parents:
7718
diff
changeset
|
233 |
echo "$(call gamma-path,commonsrc,os_cpu/$(OS_FAMILY)_$(ARCH)/vm) \\"; \ |
340b5b8b544b
7003401: Implement VM error-reporting functionality on erroneous termination
kamg
parents:
7718
diff
changeset
|
234 |
echo "$(call gamma-path,altsrc,os/$(OS_FAMILY)/vm) \\"; \ |
340b5b8b544b
7003401: Implement VM error-reporting functionality on erroneous termination
kamg
parents:
7718
diff
changeset
|
235 |
echo "$(call gamma-path,commonsrc,os/$(OS_FAMILY)/vm) \\"; \ |
340b5b8b544b
7003401: Implement VM error-reporting functionality on erroneous termination
kamg
parents:
7718
diff
changeset
|
236 |
echo "$(call gamma-path,altsrc,os/posix/vm) \\"; \ |
340b5b8b544b
7003401: Implement VM error-reporting functionality on erroneous termination
kamg
parents:
7718
diff
changeset
|
237 |
echo "$(call gamma-path,commonsrc,os/posix/vm)"; \ |
1 | 238 |
[ -n "$(CFLAGS_BROWSE)" ] && \ |
239 |
echo && echo "CFLAGS_BROWSE = $(CFLAGS_BROWSE)"; \ |
|
12501
ea7feae692ae
7102323: RFE: enable Full Debug Symbols Phase 1 on Solaris
dcubed
parents:
11593
diff
changeset
|
240 |
[ -n "$(ENABLE_FULL_DEBUG_SYMBOLS)" ] && \ |
ea7feae692ae
7102323: RFE: enable Full Debug Symbols Phase 1 on Solaris
dcubed
parents:
11593
diff
changeset
|
241 |
echo && echo "ENABLE_FULL_DEBUG_SYMBOLS = $(ENABLE_FULL_DEBUG_SYMBOLS)"; \ |
10559 | 242 |
[ -n "$(OBJCOPY)" ] && \ |
243 |
echo && echo "OBJCOPY = $(OBJCOPY)"; \ |
|
244 |
[ -n "$(STRIP_POLICY)" ] && \ |
|
245 |
echo && echo "STRIP_POLICY = $(STRIP_POLICY)"; \ |
|
12501
ea7feae692ae
7102323: RFE: enable Full Debug Symbols Phase 1 on Solaris
dcubed
parents:
11593
diff
changeset
|
246 |
[ -n "$(ZIP_DEBUGINFO_FILES)" ] && \ |
ea7feae692ae
7102323: RFE: enable Full Debug Symbols Phase 1 on Solaris
dcubed
parents:
11593
diff
changeset
|
247 |
echo && echo "ZIP_DEBUGINFO_FILES = $(ZIP_DEBUGINFO_FILES)"; \ |
ea7feae692ae
7102323: RFE: enable Full Debug Symbols Phase 1 on Solaris
dcubed
parents:
11593
diff
changeset
|
248 |
[ -n "$(ZIPEXE)" ] && \ |
ea7feae692ae
7102323: RFE: enable Full Debug Symbols Phase 1 on Solaris
dcubed
parents:
11593
diff
changeset
|
249 |
echo && echo "ZIPEXE = $(ZIPEXE)"; \ |
1 | 250 |
[ -n "$(HOTSPOT_EXTRA_SYSDEFS)" ] && \ |
251 |
echo && \ |
|
252 |
echo "HOTSPOT_EXTRA_SYSDEFS\$$(HOTSPOT_EXTRA_SYSDEFS) = $(HOTSPOT_EXTRA_SYSDEFS)" && \ |
|
253 |
echo "SYSDEFS += \$$(HOTSPOT_EXTRA_SYSDEFS)"; \ |
|
254 |
echo; \ |
|
11955
aeca8151886e
7141244: build-infra merge: Include $(SPEC) in makefiles and make variables overridable
erikj
parents:
11593
diff
changeset
|
255 |
[ -n "$(SPEC)" ] && \ |
aeca8151886e
7141244: build-infra merge: Include $(SPEC) in makefiles and make variables overridable
erikj
parents:
11593
diff
changeset
|
256 |
echo "include $(SPEC)"; \ |
338
5cf9f61d76f4
6583644: Move all managed/SCCS files out of 'build' into 'make' directory
kamg
parents:
1
diff
changeset
|
257 |
echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/$(VARIANT).make"; \ |
5cf9f61d76f4
6583644: Move all managed/SCCS files out of 'build' into 'make' directory
kamg
parents:
1
diff
changeset
|
258 |
echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/$(COMPILER).make"; \ |
1 | 259 |
) > $@ |
260 |
||
261 |
flags_vm.make: $(BUILDTREE_MAKE) ../shared_dirs.lst |
|
262 |
@echo Creating $@ ... |
|
263 |
$(QUIETLY) ( \ |
|
264 |
$(BUILDTREE_COMMENT); \ |
|
265 |
echo; \ |
|
266 |
[ "$(TARGET)" = profiled ] && \ |
|
338
5cf9f61d76f4
6583644: Move all managed/SCCS files out of 'build' into 'make' directory
kamg
parents:
1
diff
changeset
|
267 |
echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/optimized.make"; \ |
5cf9f61d76f4
6583644: Move all managed/SCCS files out of 'build' into 'make' directory
kamg
parents:
1
diff
changeset
|
268 |
echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/$(TARGET).make"; \ |
1 | 269 |
) > $@ |
270 |
||
271 |
../shared_dirs.lst: $(BUILDTREE_MAKE) $(GAMMADIR)/src/share/vm |
|
272 |
@echo Creating directory list $@ |
|
8114
340b5b8b544b
7003401: Implement VM error-reporting functionality on erroneous termination
kamg
parents:
7718
diff
changeset
|
273 |
$(QUIETLY) if [ -d $(HS_ALT_SRC)/share/vm ]; then \ |
340b5b8b544b
7003401: Implement VM error-reporting functionality on erroneous termination
kamg
parents:
7718
diff
changeset
|
274 |
find $(HS_ALT_SRC)/share/vm/* -prune \ |
340b5b8b544b
7003401: Implement VM error-reporting functionality on erroneous termination
kamg
parents:
7718
diff
changeset
|
275 |
-type d \! \( $(TOPLEVEL_EXCLUDE_DIRS) \) -exec find {} \ |
340b5b8b544b
7003401: Implement VM error-reporting functionality on erroneous termination
kamg
parents:
7718
diff
changeset
|
276 |
\( $(ALWAYS_EXCLUDE_DIRS) \) -prune -o -type d -print \; > $@; \ |
340b5b8b544b
7003401: Implement VM error-reporting functionality on erroneous termination
kamg
parents:
7718
diff
changeset
|
277 |
fi; |
340b5b8b544b
7003401: Implement VM error-reporting functionality on erroneous termination
kamg
parents:
7718
diff
changeset
|
278 |
$(QUIETLY) find $(HS_COMMON_SRC)/share/vm/* -prune \ |
1 | 279 |
-type d \! \( $(TOPLEVEL_EXCLUDE_DIRS) \) -exec find {} \ |
8114
340b5b8b544b
7003401: Implement VM error-reporting functionality on erroneous termination
kamg
parents:
7718
diff
changeset
|
280 |
\( $(ALWAYS_EXCLUDE_DIRS) \) -prune -o -type d -print \; >> $@ |
1 | 281 |
|
282 |
Makefile: $(BUILDTREE_MAKE) |
|
283 |
@echo Creating $@ ... |
|
284 |
$(QUIETLY) ( \ |
|
285 |
$(BUILDTREE_COMMENT); \ |
|
286 |
echo; \ |
|
287 |
echo include flags.make; \ |
|
288 |
echo; \ |
|
338
5cf9f61d76f4
6583644: Move all managed/SCCS files out of 'build' into 'make' directory
kamg
parents:
1
diff
changeset
|
289 |
echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/top.make"; \ |
1 | 290 |
) > $@ |
291 |
||
292 |
vm.make: $(BUILDTREE_MAKE) |
|
293 |
@echo Creating $@ ... |
|
294 |
$(QUIETLY) ( \ |
|
295 |
$(BUILDTREE_COMMENT); \ |
|
296 |
echo; \ |
|
297 |
echo include flags.make; \ |
|
298 |
echo include flags_vm.make; \ |
|
299 |
echo; \ |
|
338
5cf9f61d76f4
6583644: Move all managed/SCCS files out of 'build' into 'make' directory
kamg
parents:
1
diff
changeset
|
300 |
echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/$(@F)"; \ |
1 | 301 |
) > $@ |
302 |
||
303 |
adlc.make: $(BUILDTREE_MAKE) |
|
304 |
@echo Creating $@ ... |
|
305 |
$(QUIETLY) ( \ |
|
306 |
$(BUILDTREE_COMMENT); \ |
|
307 |
echo; \ |
|
308 |
echo include flags.make; \ |
|
309 |
echo; \ |
|
338
5cf9f61d76f4
6583644: Move all managed/SCCS files out of 'build' into 'make' directory
kamg
parents:
1
diff
changeset
|
310 |
echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/$(@F)"; \ |
1 | 311 |
) > $@ |
312 |
||
313 |
jvmti.make: $(BUILDTREE_MAKE) |
|
314 |
@echo Creating $@ ... |
|
315 |
$(QUIETLY) ( \ |
|
316 |
$(BUILDTREE_COMMENT); \ |
|
317 |
echo; \ |
|
318 |
echo include flags.make; \ |
|
319 |
echo; \ |
|
338
5cf9f61d76f4
6583644: Move all managed/SCCS files out of 'build' into 'make' directory
kamg
parents:
1
diff
changeset
|
320 |
echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/$(@F)"; \ |
1 | 321 |
) > $@ |
322 |
||
323 |
sa.make: $(BUILDTREE_MAKE) |
|
324 |
@echo Creating $@ ... |
|
325 |
$(QUIETLY) ( \ |
|
326 |
$(BUILDTREE_COMMENT); \ |
|
327 |
echo; \ |
|
328 |
echo include flags.make; \ |
|
329 |
echo; \ |
|
338
5cf9f61d76f4
6583644: Move all managed/SCCS files out of 'build' into 'make' directory
kamg
parents:
1
diff
changeset
|
330 |
echo "include \$$(GAMMADIR)/make/$(OS_FAMILY)/makefiles/$(@F)"; \ |
1 | 331 |
) > $@ |
332 |
||
11593 | 333 |
env.sh: $(BUILDTREE_MAKE) |
1 | 334 |
@echo Creating $@ ... |
335 |
$(QUIETLY) ( \ |
|
336 |
$(BUILDTREE_COMMENT); \ |
|
337 |
[ -n "$$JAVA_HOME" ] && { echo ": \$${JAVA_HOME:=$${JAVA_HOME}}"; }; \ |
|
338 |
{ \ |
|
339 |
echo "CLASSPATH=$${CLASSPATH:+$$CLASSPATH:}.:\$${JAVA_HOME}/jre/lib/rt.jar:\$${JAVA_HOME}/jre/lib/i18n.jar"; \ |
|
340 |
} | sed s:$${JAVA_HOME:--------}:\$${JAVA_HOME}:g; \ |
|
341 |
echo "HOTSPOT_BUILD_USER=\"$${LOGNAME:-$$USER} in `basename $(GAMMADIR)`\""; \ |
|
342 |
echo "export JAVA_HOME LD_LIBRARY_PATH CLASSPATH HOTSPOT_BUILD_USER"; \ |
|
343 |
) > $@ |
|
344 |
||
11593 | 345 |
env.csh: env.sh |
1 | 346 |
@echo Creating $@ ... |
347 |
$(QUIETLY) ( \ |
|
348 |
$(BUILDTREE_COMMENT); \ |
|
349 |
[ -n "$$JAVA_HOME" ] && \ |
|
350 |
{ echo "if (! \$$?JAVA_HOME) setenv JAVA_HOME \"$$JAVA_HOME\""; }; \ |
|
351 |
sed -n 's/^\([A-Za-z_][A-Za-z0-9_]*\)=/setenv \1 /p' $?; \ |
|
352 |
) > $@ |
|
353 |
||
7452
b3fa838286de
7006354: Updates to Visual Studio project creation and development launcher
sla
parents:
7403
diff
changeset
|
354 |
jdkpath.sh: $(BUILDTREE_MAKE) |
b3fa838286de
7006354: Updates to Visual Studio project creation and development launcher
sla
parents:
7403
diff
changeset
|
355 |
@echo Creating $@ ... |
b3fa838286de
7006354: Updates to Visual Studio project creation and development launcher
sla
parents:
7403
diff
changeset
|
356 |
$(QUIETLY) ( \ |
b3fa838286de
7006354: Updates to Visual Studio project creation and development launcher
sla
parents:
7403
diff
changeset
|
357 |
$(BUILDTREE_COMMENT); \ |
b3fa838286de
7006354: Updates to Visual Studio project creation and development launcher
sla
parents:
7403
diff
changeset
|
358 |
echo "JDK=${JAVA_HOME}"; \ |
b3fa838286de
7006354: Updates to Visual Studio project creation and development launcher
sla
parents:
7403
diff
changeset
|
359 |
) > $@ |
b3fa838286de
7006354: Updates to Visual Studio project creation and development launcher
sla
parents:
7403
diff
changeset
|
360 |
|
1 | 361 |
.dbxrc: $(BUILDTREE_MAKE) |
362 |
@echo Creating $@ ... |
|
363 |
$(QUIETLY) ( \ |
|
364 |
echo "echo '# Loading $(PLATFORM_DIR)/$(TARGET)/.dbxrc'"; \ |
|
365 |
echo "if [ -f \"\$${HOTSPOT_DBXWARE}\" ]"; \ |
|
366 |
echo "then"; \ |
|
367 |
echo " source \"\$${HOTSPOT_DBXWARE}\""; \ |
|
368 |
echo "elif [ -f \"\$$HOME/.dbxrc\" ]"; \ |
|
369 |
echo "then"; \ |
|
370 |
echo " source \"\$$HOME/.dbxrc\""; \ |
|
371 |
echo "fi"; \ |
|
372 |
) > $@ |
|
373 |
||
374 |
# Skip the test for product builds (which only work when installed in a JDK), to |
|
375 |
# avoid exiting with an error and causing make to halt. |
|
376 |
NO_TEST_MSG = \ |
|
377 |
echo "$@: skipping the test--this build must be tested in a JDK." |
|
378 |
||
379 |
NO_JAVA_HOME_MSG = \ |
|
380 |
echo "JAVA_HOME must be set to run this test." |
|
381 |
||
382 |
DATA_MODE = $(DATA_MODE/$(BUILDARCH)) |
|
383 |
JAVA_FLAG = $(JAVA_FLAG/$(DATA_MODE)) |
|
384 |
||
385 |
DATA_MODE/i486 = 32 |
|
386 |
DATA_MODE/sparc = 32 |
|
387 |
DATA_MODE/sparcv9 = 64 |
|
388 |
DATA_MODE/amd64 = 64 |
|
389 |
DATA_MODE/ia64 = 64 |
|
390 |
||
391 |
# This bit is needed to enable local rebuilds. |
|
392 |
# Unless the makefile itself sets LP64, any environmental |
|
393 |
# setting of LP64 will interfere with the build. |
|
394 |
LP64_SETTING/32 = LP64 = \#empty |
|
395 |
LP64_SETTING/64 = LP64 = 1 |
|
396 |
||
397 |
JAVA_FLAG/32 = -d32 |
|
398 |
JAVA_FLAG/64 = -d64 |
|
399 |
||
400 |
WRONG_DATA_MODE_MSG = \ |
|
11593 | 401 |
echo "JAVA_HOME must point to a $(DATA_MODE)-bit OpenJDK." |
402 |
||
403 |
CROSS_COMPILING_MSG = \ |
|
404 |
echo "Cross compiling for ARCH $(CROSS_COMPILE_ARCH), skipping gamma run." |
|
1 | 405 |
|
778
574c011e95e3
6695777: Queens.class should be built from source, not put in source repo
ohair
parents:
338
diff
changeset
|
406 |
test_gamma: $(BUILDTREE_MAKE) $(GAMMADIR)/make/test/Queens.java |
1 | 407 |
@echo Creating $@ ... |
408 |
$(QUIETLY) ( \ |
|
11593 | 409 |
echo "#!/bin/sh"; \ |
410 |
echo ""; \ |
|
1 | 411 |
$(BUILDTREE_COMMENT); \ |
11593 | 412 |
echo ""; \ |
413 |
echo "# Include environment settings for gamma run"; \ |
|
414 |
echo ""; \ |
|
415 |
echo ". ./env.sh"; \ |
|
416 |
echo ""; \ |
|
417 |
echo "# Do not run gamma test for cross compiles"; \ |
|
418 |
echo ""; \ |
|
419 |
echo "if [ -n \"$(CROSS_COMPILE_ARCH)\" ]; then "; \ |
|
420 |
echo " $(CROSS_COMPILING_MSG)"; \ |
|
421 |
echo " exit 0"; \ |
|
422 |
echo "fi"; \ |
|
423 |
echo ""; \ |
|
424 |
echo "# Make sure JAVA_HOME is set as it is required for gamma"; \ |
|
425 |
echo ""; \ |
|
426 |
echo "if [ -z \"\$${JAVA_HOME}\" ]; then "; \ |
|
427 |
echo " $(NO_JAVA_HOME_MSG)"; \ |
|
428 |
echo " exit 0"; \ |
|
429 |
echo "fi"; \ |
|
430 |
echo ""; \ |
|
431 |
echo "# Check JAVA_HOME version to be used for the test"; \ |
|
432 |
echo ""; \ |
|
433 |
echo "\$${JAVA_HOME}/bin/java $(JAVA_FLAG) -fullversion > /dev/null 2>&1"; \ |
|
434 |
echo "if [ \$$? -ne 0 ]; then "; \ |
|
435 |
echo " $(WRONG_DATA_MODE_MSG)"; \ |
|
436 |
echo " exit 0"; \ |
|
1 | 437 |
echo "fi"; \ |
11593 | 438 |
echo ""; \ |
439 |
echo "# Use gamma_g if it exists"; \ |
|
440 |
echo ""; \ |
|
441 |
echo "GAMMA_PROG=gamma"; \ |
|
442 |
echo "if [ -f gamma_g ]; then "; \ |
|
443 |
echo " GAMMA_PROG=gamma_g"; \ |
|
444 |
echo "fi"; \ |
|
445 |
echo ""; \ |
|
446 |
echo "if [ \"$(OS_VENDOR)\" = \"Darwin\" ]; then "; \ |
|
447 |
echo " # Ensure architecture for gamma and JAVA_HOME is the same."; \ |
|
448 |
echo " # NOTE: gamma assumes the OpenJDK directory layout."; \ |
|
449 |
echo ""; \ |
|
450 |
echo " GAMMA_ARCH=\"\`file \$${GAMMA_PROG} | awk '{print \$$NF}'\`\""; \ |
|
451 |
echo " JVM_LIB=\"\$${JAVA_HOME}/jre/lib/libjava.$(LIBRARY_SUFFIX)\""; \ |
|
452 |
echo " if [ ! -f \$${JVM_LIB} ]; then"; \ |
|
453 |
echo " JVM_LIB=\"\$${JAVA_HOME}/jre/lib/$${LIBARCH}/libjava.$(LIBRARY_SUFFIX)\""; \ |
|
454 |
echo " fi"; \ |
|
455 |
echo " if [ ! -f \$${JVM_LIB} ] || [ -z \"\`file \$${JVM_LIB} | grep \$${GAMMA_ARCH}\`\" ]; then "; \ |
|
456 |
echo " $(WRONG_DATA_MODE_MSG)"; \ |
|
457 |
echo " exit 0"; \ |
|
458 |
echo " fi"; \ |
|
459 |
echo "fi"; \ |
|
460 |
echo ""; \ |
|
461 |
echo "# Compile Queens program for test"; \ |
|
462 |
echo ""; \ |
|
778
574c011e95e3
6695777: Queens.class should be built from source, not put in source repo
ohair
parents:
338
diff
changeset
|
463 |
echo "rm -f Queens.class"; \ |
574c011e95e3
6695777: Queens.class should be built from source, not put in source repo
ohair
parents:
338
diff
changeset
|
464 |
echo "\$${JAVA_HOME}/bin/javac -d . $(GAMMADIR)/make/test/Queens.java"; \ |
11593 | 465 |
echo ""; \ |
466 |
echo "# Set library path solely for gamma launcher test run"; \ |
|
467 |
echo ""; \ |
|
468 |
echo "LD_LIBRARY_PATH=.:$${LD_LIBRARY_PATH:+$$LD_LIBRARY_PATH:}\$${JAVA_HOME}/jre/lib/${LIBARCH}/native_threads:\$${JAVA_HOME}/jre/lib/${LIBARCH}:${GCC_LIB}"; \ |
|
469 |
echo "export LD_LIBRARY_PATH"; \ |
|
470 |
echo "unset LD_LIBRARY_PATH_32"; \ |
|
471 |
echo "unset LD_LIBRARY_PATH_64"; \ |
|
472 |
echo ""; \ |
|
473 |
echo "if [ \"$(OS_VENDOR)\" = \"Darwin\" ]; then "; \ |
|
474 |
echo " DYLD_LIBRARY_PATH=.:$${DYLD_LIBRARY_PATH:+$$DYLD_LIBRARY_PATH:}\$${JAVA_HOME}/jre/lib/native_threads:\$${JAVA_HOME}/jre/lib:$${DYLD_LIBRARY_PATH:+$$DYLD_LIBRARY_PATH:}\$${JAVA_HOME}/jre/lib/${LIBARCH}/native_threads:\$${JAVA_HOME}/jre/lib/${LIBARCH}:${GCC_LIB}"; \ |
|
475 |
echo " export DYLD_LIBRARY_PATH"; \ |
|
476 |
echo "fi"; \ |
|
477 |
echo ""; \ |
|
478 |
echo "# Use the gamma launcher and JAVA_HOME to run the test"; \ |
|
479 |
echo ""; \ |
|
480 |
echo "./\$${GAMMA_PROG} $(TESTFLAGS) Queens < /dev/null"; \ |
|
1 | 481 |
) > $@ |
482 |
$(QUIETLY) chmod +x $@ |
|
483 |
||
484 |
FORCE: |
|
485 |
||
486 |
.PHONY: all FORCE |