|
1 # |
|
2 # Copyright (c) 2016, Oracle and/or its affiliates. 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. Oracle designates this |
|
8 # particular file as subject to the "Classpath" exception as provided |
|
9 # by Oracle 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 Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA |
|
22 # or visit www.oracle.com if you need additional information or have any |
|
23 # questions. |
|
24 # |
|
25 |
|
26 # This must be the first rule |
|
27 default: all |
|
28 |
|
29 include $(SPEC) |
|
30 include MakeBase.gmk |
|
31 |
|
32 include JavaCompilation.gmk |
|
33 include SetupJavaCompilers.gmk |
|
34 |
|
35 TARGETS := |
|
36 |
|
37 # Hook to include the corresponding custom file, if present. |
|
38 $(eval $(call IncludeCustomExtension, hotspot, CompileTools.gmk)) |
|
39 |
|
40 ifeq ($(INCLUDE_GRAAL), true) |
|
41 VM_CI_SRC_DIR := $(HOTSPOT_TOPDIR)/src/jdk.vm.ci/share/classes |
|
42 |
|
43 SRC_DIR := $(HOTSPOT_TOPDIR)/src/jdk.vm.compiler/share/classes |
|
44 |
|
45 ############################################################################## |
|
46 # Compile the annotation processors |
|
47 $(eval $(call SetupJavaCompilation, BUILD_VM_COMPILER_MATCH_PROCESSOR, \ |
|
48 SETUP := GENERATE_OLDBYTECODE, \ |
|
49 SRC := \ |
|
50 $(SRC_DIR)/org.graalvm.compiler.common/src \ |
|
51 $(SRC_DIR)/org.graalvm.compiler.core/src \ |
|
52 $(SRC_DIR)/org.graalvm.compiler.core.common/src \ |
|
53 $(SRC_DIR)/org.graalvm.compiler.core.match.processor/src \ |
|
54 $(SRC_DIR)/org.graalvm.compiler.api.collections/src \ |
|
55 $(SRC_DIR)/org.graalvm.compiler.api.replacements/src \ |
|
56 $(SRC_DIR)/org.graalvm.compiler.asm/src \ |
|
57 $(SRC_DIR)/org.graalvm.compiler.bytecode/src \ |
|
58 $(SRC_DIR)/org.graalvm.compiler.code/src \ |
|
59 $(SRC_DIR)/org.graalvm.compiler.debug/src \ |
|
60 $(SRC_DIR)/org.graalvm.compiler.graph/src \ |
|
61 $(SRC_DIR)/org.graalvm.compiler.lir/src \ |
|
62 $(SRC_DIR)/org.graalvm.compiler.loop/src \ |
|
63 $(SRC_DIR)/org.graalvm.compiler.loop.phases/src \ |
|
64 $(SRC_DIR)/org.graalvm.compiler.nodeinfo/src \ |
|
65 $(SRC_DIR)/org.graalvm.compiler.nodes/src \ |
|
66 $(SRC_DIR)/org.graalvm.compiler.options/src \ |
|
67 $(SRC_DIR)/org.graalvm.compiler.phases/src \ |
|
68 $(SRC_DIR)/org.graalvm.compiler.phases.common/src \ |
|
69 $(SRC_DIR)/org.graalvm.compiler.serviceprovider/src \ |
|
70 $(SRC_DIR)/org.graalvm.compiler.virtual/src \ |
|
71 $(VM_CI_SRC_DIR)/jdk.vm.ci.code/src \ |
|
72 $(VM_CI_SRC_DIR)/jdk.vm.ci.common/src \ |
|
73 $(VM_CI_SRC_DIR)/jdk.vm.ci.meta/src \ |
|
74 $(VM_CI_SRC_DIR)/jdk.vm.ci.runtime/src \ |
|
75 $(VM_CI_SRC_DIR)/jdk.vm.ci.services/src \ |
|
76 , \ |
|
77 EXCLUDE_FILES := $(EXCLUDE_FILES), \ |
|
78 BIN := $(BUILDTOOLS_OUTPUTDIR)/jdk.vm.compiler.match.processor, \ |
|
79 JAR := $(BUILDTOOLS_OUTPUTDIR)/jdk.vm.compiler.match.processor.jar, \ |
|
80 )) |
|
81 |
|
82 TARGETS += $(BUILD_VM_COMPILER_MATCH_PROCESSOR) |
|
83 |
|
84 ############################################################################## |
|
85 |
|
86 $(eval $(call SetupJavaCompilation, BUILD_VM_COMPILER_NODEINFO_PROCESSOR, \ |
|
87 SETUP := GENERATE_OLDBYTECODE, \ |
|
88 SRC := \ |
|
89 $(SRC_DIR)/org.graalvm.compiler.nodeinfo/src \ |
|
90 $(SRC_DIR)/org.graalvm.compiler.nodeinfo.processor/src \ |
|
91 , \ |
|
92 BIN := $(BUILDTOOLS_OUTPUTDIR)/jdk.vm.compiler.nodeinfo.processor, \ |
|
93 JAR := $(BUILDTOOLS_OUTPUTDIR)/jdk.vm.compiler.nodeinfo.processor.jar, \ |
|
94 )) |
|
95 |
|
96 TARGETS += $(BUILD_VM_COMPILER_NODEINFO_PROCESSOR) |
|
97 |
|
98 ############################################################################## |
|
99 |
|
100 $(eval $(call SetupJavaCompilation, BUILD_VM_COMPILER_OPTIONS_PROCESSOR, \ |
|
101 SETUP := GENERATE_OLDBYTECODE, \ |
|
102 SRC := \ |
|
103 $(SRC_DIR)/org.graalvm.compiler.options/src \ |
|
104 $(SRC_DIR)/org.graalvm.compiler.options.processor/src \ |
|
105 , \ |
|
106 BIN := $(BUILDTOOLS_OUTPUTDIR)/jdk.vm.compiler.options.processor, \ |
|
107 JAR := $(BUILDTOOLS_OUTPUTDIR)/jdk.vm.compiler.options.processor.jar, \ |
|
108 )) |
|
109 |
|
110 TARGETS += $(BUILD_VM_COMPILER_OPTIONS_PROCESSOR) |
|
111 |
|
112 ############################################################################## |
|
113 |
|
114 $(eval $(call SetupJavaCompilation, BUILD_VM_COMPILER_REPLACEMENTS_VERIFIER, \ |
|
115 SETUP := GENERATE_OLDBYTECODE, \ |
|
116 SRC := \ |
|
117 $(SRC_DIR)/org.graalvm.compiler.common/src \ |
|
118 $(SRC_DIR)/org.graalvm.compiler.replacements.verifier/src \ |
|
119 $(SRC_DIR)/org.graalvm.compiler.api.collections/src \ |
|
120 $(SRC_DIR)/org.graalvm.compiler.api.replacements/src \ |
|
121 $(SRC_DIR)/org.graalvm.compiler.code/src \ |
|
122 $(SRC_DIR)/org.graalvm.compiler.core.common/src \ |
|
123 $(SRC_DIR)/org.graalvm.compiler.debug/src \ |
|
124 $(SRC_DIR)/org.graalvm.compiler.graph/src \ |
|
125 $(SRC_DIR)/org.graalvm.compiler.nodeinfo/src \ |
|
126 $(SRC_DIR)/org.graalvm.compiler.options/src \ |
|
127 $(SRC_DIR)/org.graalvm.compiler.serviceprovider/src \ |
|
128 $(VM_CI_SRC_DIR)/jdk.vm.ci.code/src \ |
|
129 $(VM_CI_SRC_DIR)/jdk.vm.ci.common/src \ |
|
130 $(VM_CI_SRC_DIR)/jdk.vm.ci.meta/src \ |
|
131 $(VM_CI_SRC_DIR)/jdk.vm.ci.runtime/src \ |
|
132 $(VM_CI_SRC_DIR)/jdk.vm.ci.services/src \ |
|
133 , \ |
|
134 EXCLUDE_FILES := $(EXCLUDE_FILES), \ |
|
135 BIN := $(BUILDTOOLS_OUTPUTDIR)/jdk.vm.compiler.replacements.verifier, \ |
|
136 JAR := $(BUILDTOOLS_OUTPUTDIR)/jdk.vm.compiler.replacements.verifier.jar, \ |
|
137 )) |
|
138 |
|
139 TARGETS += $(BUILD_VM_COMPILER_REPLACEMENTS_VERIFIER) |
|
140 |
|
141 ############################################################################## |
|
142 |
|
143 $(eval $(call SetupJavaCompilation, BUILD_VM_COMPILER_SERVICEPROVIDER_PROCESSOR, \ |
|
144 SETUP := GENERATE_OLDBYTECODE, \ |
|
145 SRC := \ |
|
146 $(SRC_DIR)/org.graalvm.compiler.serviceprovider/src \ |
|
147 $(SRC_DIR)/org.graalvm.compiler.serviceprovider.processor/src \ |
|
148 $(VM_CI_SRC_DIR)/jdk.vm.ci.services/src \ |
|
149 , \ |
|
150 EXCLUDE_FILES := $(EXCLUDE_FILES), \ |
|
151 BIN := $(BUILDTOOLS_OUTPUTDIR)/jdk.vm.compiler.serviceprovider.processor, \ |
|
152 JAR := $(BUILDTOOLS_OUTPUTDIR)/jdk.vm.compiler.serviceprovider.processor.jar, \ |
|
153 )) |
|
154 |
|
155 TARGETS += $(BUILD_VM_COMPILER_SERVICEPROVIDER_PROCESSOR) |
|
156 |
|
157 ############################################################################## |
|
158 endif |
|
159 |
|
160 all: $(TARGETS) |
|
161 |
|
162 .PHONY: all |