blob: 1ccc3e2a31b51f87545ae37d1bd1ddaca919b1f5 [file] [log] [blame]
Doug Simon3ef35612016-12-11 12:05:57 -08001#
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
27default: all
28
29include $(SPEC)
30include MakeBase.gmk
31
32include JavaCompilation.gmk
33include SetupJavaCompilers.gmk
34
35TARGETS :=
36
37# Hook to include the corresponding custom file, if present.
Magnus Ihse Bursie5f7dcca2017-10-05 12:41:06 +020038$(eval $(call IncludeCustomExtension, hotspot/CompileTools.gmk))
Doug Simon3ef35612016-12-11 12:05:57 -080039
40ifeq ($(INCLUDE_GRAAL), true)
Erik Joelsson72c4ec52017-09-12 19:03:56 +020041 VM_CI_SRC_DIR := $(TOPDIR)/src/jdk.internal.vm.ci/share/classes
Doug Simon3ef35612016-12-11 12:05:57 -080042
Erik Joelsson72c4ec52017-09-12 19:03:56 +020043 SRC_DIR := $(TOPDIR)/src/jdk.internal.vm.compiler/share/classes
Doug Simon3ef35612016-12-11 12:05:57 -080044
45 ##############################################################################
46 # Compile the annotation processors
47 $(eval $(call SetupJavaCompilation, BUILD_VM_COMPILER_MATCH_PROCESSOR, \
48 SETUP := GENERATE_OLDBYTECODE, \
49 SRC := \
Igor Veresovbd2038752017-06-19 16:31:43 -070050 $(SRC_DIR)/org.graalvm.word/src \
Doug Simon3ef35612016-12-11 12:05:57 -080051 $(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 \
Doug Simon3ef35612016-12-11 12:05:57 -080054 $(SRC_DIR)/org.graalvm.compiler.api.replacements/src \
55 $(SRC_DIR)/org.graalvm.compiler.asm/src \
56 $(SRC_DIR)/org.graalvm.compiler.bytecode/src \
57 $(SRC_DIR)/org.graalvm.compiler.code/src \
58 $(SRC_DIR)/org.graalvm.compiler.debug/src \
59 $(SRC_DIR)/org.graalvm.compiler.graph/src \
60 $(SRC_DIR)/org.graalvm.compiler.lir/src \
61 $(SRC_DIR)/org.graalvm.compiler.loop/src \
62 $(SRC_DIR)/org.graalvm.compiler.loop.phases/src \
63 $(SRC_DIR)/org.graalvm.compiler.nodeinfo/src \
64 $(SRC_DIR)/org.graalvm.compiler.nodes/src \
65 $(SRC_DIR)/org.graalvm.compiler.options/src \
66 $(SRC_DIR)/org.graalvm.compiler.phases/src \
67 $(SRC_DIR)/org.graalvm.compiler.phases.common/src \
68 $(SRC_DIR)/org.graalvm.compiler.serviceprovider/src \
69 $(SRC_DIR)/org.graalvm.compiler.virtual/src \
Dean Longc8aacd32017-11-06 20:29:49 -080070 $(SRC_DIR)/org.graalvm.graphio/src \
Igor Veresovd405f162017-03-22 13:42:45 -070071 $(SRC_DIR)/org.graalvm.util/src \
Doug Simon3ef35612016-12-11 12:05:57 -080072 $(VM_CI_SRC_DIR)/jdk.vm.ci.code/src \
73 $(VM_CI_SRC_DIR)/jdk.vm.ci.common/src \
74 $(VM_CI_SRC_DIR)/jdk.vm.ci.meta/src \
75 $(VM_CI_SRC_DIR)/jdk.vm.ci.runtime/src \
76 $(VM_CI_SRC_DIR)/jdk.vm.ci.services/src \
77 , \
78 EXCLUDE_FILES := $(EXCLUDE_FILES), \
79 BIN := $(BUILDTOOLS_OUTPUTDIR)/jdk.vm.compiler.match.processor, \
80 JAR := $(BUILDTOOLS_OUTPUTDIR)/jdk.vm.compiler.match.processor.jar, \
81 ))
82
83 TARGETS += $(BUILD_VM_COMPILER_MATCH_PROCESSOR)
84
85 ##############################################################################
86
87 $(eval $(call SetupJavaCompilation, BUILD_VM_COMPILER_NODEINFO_PROCESSOR, \
88 SETUP := GENERATE_OLDBYTECODE, \
89 SRC := \
90 $(SRC_DIR)/org.graalvm.compiler.nodeinfo/src \
91 $(SRC_DIR)/org.graalvm.compiler.nodeinfo.processor/src \
92 , \
93 BIN := $(BUILDTOOLS_OUTPUTDIR)/jdk.vm.compiler.nodeinfo.processor, \
94 JAR := $(BUILDTOOLS_OUTPUTDIR)/jdk.vm.compiler.nodeinfo.processor.jar, \
95 ))
96
97 TARGETS += $(BUILD_VM_COMPILER_NODEINFO_PROCESSOR)
98
99 ##############################################################################
100
101 $(eval $(call SetupJavaCompilation, BUILD_VM_COMPILER_OPTIONS_PROCESSOR, \
102 SETUP := GENERATE_OLDBYTECODE, \
103 SRC := \
104 $(SRC_DIR)/org.graalvm.compiler.options/src \
105 $(SRC_DIR)/org.graalvm.compiler.options.processor/src \
Igor Veresovd405f162017-03-22 13:42:45 -0700106 $(SRC_DIR)/org.graalvm.util/src \
Doug Simon3ef35612016-12-11 12:05:57 -0800107 , \
108 BIN := $(BUILDTOOLS_OUTPUTDIR)/jdk.vm.compiler.options.processor, \
109 JAR := $(BUILDTOOLS_OUTPUTDIR)/jdk.vm.compiler.options.processor.jar, \
110 ))
111
112 TARGETS += $(BUILD_VM_COMPILER_OPTIONS_PROCESSOR)
113
114 ##############################################################################
115
116 $(eval $(call SetupJavaCompilation, BUILD_VM_COMPILER_REPLACEMENTS_VERIFIER, \
117 SETUP := GENERATE_OLDBYTECODE, \
118 SRC := \
Igor Veresovbd2038752017-06-19 16:31:43 -0700119 $(SRC_DIR)/org.graalvm.word/src \
Doug Simon3ef35612016-12-11 12:05:57 -0800120 $(SRC_DIR)/org.graalvm.compiler.replacements.verifier/src \
Doug Simon3ef35612016-12-11 12:05:57 -0800121 $(SRC_DIR)/org.graalvm.compiler.api.replacements/src \
122 $(SRC_DIR)/org.graalvm.compiler.code/src \
123 $(SRC_DIR)/org.graalvm.compiler.core.common/src \
124 $(SRC_DIR)/org.graalvm.compiler.debug/src \
125 $(SRC_DIR)/org.graalvm.compiler.graph/src \
126 $(SRC_DIR)/org.graalvm.compiler.nodeinfo/src \
127 $(SRC_DIR)/org.graalvm.compiler.options/src \
128 $(SRC_DIR)/org.graalvm.compiler.serviceprovider/src \
Dean Longc8aacd32017-11-06 20:29:49 -0800129 $(SRC_DIR)/org.graalvm.graphio/src \
Igor Veresovd405f162017-03-22 13:42:45 -0700130 $(SRC_DIR)/org.graalvm.util/src \
Doug Simon3ef35612016-12-11 12:05:57 -0800131 $(VM_CI_SRC_DIR)/jdk.vm.ci.code/src \
132 $(VM_CI_SRC_DIR)/jdk.vm.ci.common/src \
133 $(VM_CI_SRC_DIR)/jdk.vm.ci.meta/src \
134 $(VM_CI_SRC_DIR)/jdk.vm.ci.runtime/src \
135 $(VM_CI_SRC_DIR)/jdk.vm.ci.services/src \
136 , \
137 EXCLUDE_FILES := $(EXCLUDE_FILES), \
138 BIN := $(BUILDTOOLS_OUTPUTDIR)/jdk.vm.compiler.replacements.verifier, \
139 JAR := $(BUILDTOOLS_OUTPUTDIR)/jdk.vm.compiler.replacements.verifier.jar, \
140 ))
141
142 TARGETS += $(BUILD_VM_COMPILER_REPLACEMENTS_VERIFIER)
143
144 ##############################################################################
145
146 $(eval $(call SetupJavaCompilation, BUILD_VM_COMPILER_SERVICEPROVIDER_PROCESSOR, \
147 SETUP := GENERATE_OLDBYTECODE, \
148 SRC := \
149 $(SRC_DIR)/org.graalvm.compiler.serviceprovider/src \
150 $(SRC_DIR)/org.graalvm.compiler.serviceprovider.processor/src \
151 $(VM_CI_SRC_DIR)/jdk.vm.ci.services/src \
152 , \
153 EXCLUDE_FILES := $(EXCLUDE_FILES), \
154 BIN := $(BUILDTOOLS_OUTPUTDIR)/jdk.vm.compiler.serviceprovider.processor, \
155 JAR := $(BUILDTOOLS_OUTPUTDIR)/jdk.vm.compiler.serviceprovider.processor.jar, \
156 ))
157
158 TARGETS += $(BUILD_VM_COMPILER_SERVICEPROVIDER_PROCESSOR)
159
160 ##############################################################################
161endif
162
163all: $(TARGETS)
164
165.PHONY: all