comparison make/bsd/makefiles/vm.make @ 10405:f2110083203d

8005849: JEP 167: Event-Based JVM Tracing Reviewed-by: acorn, coleenp, sla Contributed-by: Karen Kinnear <karen.kinnear@oracle.com>, Bengt Rutisson <bengt.rutisson@oracle.com>, Calvin Cheung <calvin.cheung@oracle.com>, Erik Gahlin <erik.gahlin@oracle.com>, Erik Helin <erik.helin@oracle.com>, Jesper Wilhelmsson <jesper.wilhelmsson@oracle.com>, Keith McGuigan <keith.mcguigan@oracle.com>, Mattias Tobiasson <mattias.tobiasson@oracle.com>, Markus Gronlund <markus.gronlund@oracle.com>, Mikael Auno <mikael.auno@oracle.com>, Nils Eliasson <nils.eliasson@oracle.com>, Nils Loodin <nils.loodin@oracle.com>, Rickard Backman <rickard.backman@oracle.com>, Staffan Larsen <staffan.larsen@oracle.com>, Stefan Karlsson <stefan.karlsson@oracle.com>, Yekaterina Kantserova <yekaterina.kantserova@oracle.com>
author sla
date Mon, 10 Jun 2013 11:30:51 +0200
parents 2cb5d5f6d5e5
children 836a62f43af9 f509b8f4699b
comparison
equal deleted inserted replaced
10404:d0add7016434 10405:f2110083203d
1 # 1 #
2 # Copyright (c) 1999, 2012, Oracle and/or its affiliates. All rights reserved. 2 # Copyright (c) 1999, 2013, Oracle and/or its affiliates. All rights reserved.
3 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3 # DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4 # 4 #
5 # This code is free software; you can redistribute it and/or modify it 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 6 # under the terms of the GNU General Public License version 2 only, as
7 # published by the Free Software Foundation. 7 # published by the Free Software Foundation.
17 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 17 # Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
18 # 18 #
19 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 19 # Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
20 # or visit www.oracle.com if you need additional information or have any 20 # or visit www.oracle.com if you need additional information or have any
21 # questions. 21 # questions.
22 # 22 #
23 # 23 #
24 24
25 # Rules to build JVM and related libraries, included from vm.make in the build 25 # Rules to build JVM and related libraries, included from vm.make in the build
26 # directory. 26 # directory.
27 27
50 50
51 # set VPATH so make knows where to look for source files 51 # set VPATH so make knows where to look for source files
52 # Src_Dirs_V is everything in src/share/vm/*, plus the right os/*/vm and cpu/*/vm 52 # Src_Dirs_V is everything in src/share/vm/*, plus the right os/*/vm and cpu/*/vm
53 # The adfiles directory contains ad_<arch>.[ch]pp. 53 # The adfiles directory contains ad_<arch>.[ch]pp.
54 # The jvmtifiles directory contains jvmti*.[ch]pp 54 # The jvmtifiles directory contains jvmti*.[ch]pp
55 Src_Dirs_V += $(GENERATED)/adfiles $(GENERATED)/jvmtifiles 55 Src_Dirs_V += $(GENERATED)/adfiles $(GENERATED)/jvmtifiles $(GENERATED)/tracefiles
56 VPATH += $(Src_Dirs_V:%=%:) 56 VPATH += $(Src_Dirs_V:%=%:)
57 57
58 # set INCLUDES for C preprocessor. 58 # set INCLUDES for C preprocessor.
59 Src_Dirs_I += $(GENERATED) 59 Src_Dirs_I += $(GENERATED)
60 # The order is important for the precompiled headers to work. 60 # The order is important for the precompiled headers to work.
64 SYMFLAG = -g 64 SYMFLAG = -g
65 else 65 else
66 SYMFLAG = 66 SYMFLAG =
67 endif 67 endif
68 68
69 # HOTSPOT_RELEASE_VERSION and HOTSPOT_BUILD_VERSION are defined 69 # HOTSPOT_RELEASE_VERSION and HOTSPOT_BUILD_VERSION are defined
70 # in $(GAMMADIR)/make/defs.make 70 # in $(GAMMADIR)/make/defs.make
71 ifeq ($(HOTSPOT_BUILD_VERSION),) 71 ifeq ($(HOTSPOT_BUILD_VERSION),)
72 BUILD_VERSION = -DHOTSPOT_RELEASE_VERSION="\"$(HOTSPOT_RELEASE_VERSION)\"" 72 BUILD_VERSION = -DHOTSPOT_RELEASE_VERSION="\"$(HOTSPOT_RELEASE_VERSION)\""
73 else 73 else
74 BUILD_VERSION = -DHOTSPOT_RELEASE_VERSION="\"$(HOTSPOT_RELEASE_VERSION)-$(HOTSPOT_BUILD_VERSION)\"" 74 BUILD_VERSION = -DHOTSPOT_RELEASE_VERSION="\"$(HOTSPOT_RELEASE_VERSION)-$(HOTSPOT_BUILD_VERSION)\""
91 ${HS_LIB_ARCH} \ 91 ${HS_LIB_ARCH} \
92 ${VM_DISTRO} 92 ${VM_DISTRO}
93 93
94 # This is VERY important! The version define must only be supplied to vm_version.o 94 # This is VERY important! The version define must only be supplied to vm_version.o
95 # If not, ccache will not re-use the cache at all, since the version string might contain 95 # If not, ccache will not re-use the cache at all, since the version string might contain
96 # a time and date. 96 # a time and date.
97 CXXFLAGS/vm_version.o += ${JRE_VERSION} 97 CXXFLAGS/vm_version.o += ${JRE_VERSION}
98 98
99 CXXFLAGS/BYFILE = $(CXXFLAGS/$@) 99 CXXFLAGS/BYFILE = $(CXXFLAGS/$@)
100 100
101 # File specific flags 101 # File specific flags
102 CXXFLAGS += $(CXXFLAGS/BYFILE) 102 CXXFLAGS += $(CXXFLAGS/BYFILE)
103 103
104 ifdef DEFAULT_LIBPATH 104 ifdef DEFAULT_LIBPATH
105 CXXFLAGS += -DDEFAULT_LIBPATH="\"$(DEFAULT_LIBPATH)\"" 105 CXXFLAGS += -DDEFAULT_LIBPATH="\"$(DEFAULT_LIBPATH)\""
106 endif
107
108 ifndef JAVASE_EMBEDDED
109 CFLAGS += -DINCLUDE_TRACE
110 endif 106 endif
111 107
112 # CFLAGS_WARN holds compiler options to suppress/enable warnings. 108 # CFLAGS_WARN holds compiler options to suppress/enable warnings.
113 CFLAGS += $(CFLAGS_WARN/BYFILE) 109 CFLAGS += $(CFLAGS_WARN/BYFILE)
114 110
163 SOURCE_PATHS+=$(HS_COMMON_SRC)/os/$(Platform_os_family)/vm 159 SOURCE_PATHS+=$(HS_COMMON_SRC)/os/$(Platform_os_family)/vm
164 SOURCE_PATHS+=$(HS_COMMON_SRC)/os/posix/vm 160 SOURCE_PATHS+=$(HS_COMMON_SRC)/os/posix/vm
165 SOURCE_PATHS+=$(HS_COMMON_SRC)/cpu/$(Platform_arch)/vm 161 SOURCE_PATHS+=$(HS_COMMON_SRC)/cpu/$(Platform_arch)/vm
166 SOURCE_PATHS+=$(HS_COMMON_SRC)/os_cpu/$(Platform_os_arch)/vm 162 SOURCE_PATHS+=$(HS_COMMON_SRC)/os_cpu/$(Platform_os_arch)/vm
167 163
168 ifndef JAVASE_EMBEDDED 164 CORE_PATHS=$(foreach path,$(SOURCE_PATHS),$(call altsrc,$(path)) $(path))
169 SOURCE_PATHS+=$(shell if [ -d $(HS_ALT_SRC)/share/vm/jfr ]; then \ 165 CORE_PATHS+=$(GENERATED)/jvmtifiles $(GENERATED)/tracefiles
166
167 ifneq ($(INCLUDE_TRACE), false)
168 CORE_PATHS+=$(shell if [ -d $(HS_ALT_SRC)/share/vm/jfr ]; then \
170 find $(HS_ALT_SRC)/share/vm/jfr -type d; \ 169 find $(HS_ALT_SRC)/share/vm/jfr -type d; \
171 fi) 170 fi)
172 endif 171 endif
173
174 CORE_PATHS=$(foreach path,$(SOURCE_PATHS),$(call altsrc,$(path)) $(path))
175 CORE_PATHS+=$(GENERATED)/jvmtifiles
176 172
177 COMPILER1_PATHS := $(call altsrc,$(HS_COMMON_SRC)/share/vm/c1) 173 COMPILER1_PATHS := $(call altsrc,$(HS_COMMON_SRC)/share/vm/c1)
178 COMPILER1_PATHS += $(HS_COMMON_SRC)/share/vm/c1 174 COMPILER1_PATHS += $(HS_COMMON_SRC)/share/vm/c1
179 175
180 COMPILER2_PATHS := $(call altsrc,$(HS_COMMON_SRC)/share/vm/opto) 176 COMPILER2_PATHS := $(call altsrc,$(HS_COMMON_SRC)/share/vm/opto)