blob: 7c3e791e782fe95ac9e963c630d18eca11df3664 [file] [log] [blame]
Brian Carlstrom16192862011-09-12 17:50:06 -07001#
2# Copyright (C) 2011 The Android Open Source Project
3#
4# Licensed under the Apache License, Version 2.0 (the "License");
5# you may not use this file except in compliance with the License.
6# You may obtain a copy of the License at
7#
8# http://www.apache.org/licenses/LICENSE-2.0
9#
10# Unless required by applicable law or agreed to in writing, software
11# distributed under the License is distributed on an "AS IS" BASIS,
12# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13# See the License for the specific language governing permissions and
14# limitations under the License.
15#
16
Brian Carlstrom27ec9612011-09-19 20:20:38 -070017########################################################################
Brian Carlstrom7ab763c2013-12-09 00:38:02 -080018# Rules to build a smaller "core" image to support core libraries
19# (that is, non-Android frameworks) testing on the host and target
20#
21# The main rules to build the default "boot" image are in
22# build/core/dex_preopt_libart.mk
Brian Carlstrom16192862011-09-12 17:50:06 -070023
Nicolas Geoffray611e1db2014-10-09 17:34:45 +010024include art/build/Android.common_build.mk
Dave Allison70202782013-10-22 17:52:19 -070025
Andreas Gampe4d2ef332015-08-05 09:24:45 -070026LOCAL_DEX2OAT_HOST_INSTRUCTION_SET_FEATURES_OPTION :=
Ian Rogersd582fa42014-11-05 23:46:43 -080027ifeq ($(DEX2OAT_HOST_INSTRUCTION_SET_FEATURES),)
Andreas Gampe4d2ef332015-08-05 09:24:45 -070028 LOCAL_DEX2OAT_HOST_INSTRUCTION_SET_FEATURES_OPTION := --instruction-set-features=default
29else
30 LOCAL_DEX2OAT_HOST_INSTRUCTION_SET_FEATURES_OPTION := --instruction-set-features=$(DEX2OAT_HOST_INSTRUCTION_SET_FEATURES)
Ian Rogersd582fa42014-11-05 23:46:43 -080031endif
Andreas Gampe4d2ef332015-08-05 09:24:45 -070032LOCAL_$(HOST_2ND_ARCH_VAR_PREFIX)DEX2OAT_HOST_INSTRUCTION_SET_FEATURES_OPTION :=
Ian Rogersd582fa42014-11-05 23:46:43 -080033ifeq ($($(HOST_2ND_ARCH_VAR_PREFIX)DEX2OAT_HOST_INSTRUCTION_SET_FEATURES),)
Andreas Gampe4d2ef332015-08-05 09:24:45 -070034 LOCAL_$(HOST_2ND_ARCH_VAR_PREFIX)DEX2OAT_HOST_INSTRUCTION_SET_FEATURES_OPTION := --instruction-set-features=default
35else
36 LOCAL_$(HOST_2ND_ARCH_VAR_PREFIX)DEX2OAT_HOST_INSTRUCTION_SET_FEATURES_OPTION := --instruction-set-features=$($(HOST_2ND_ARCH_VAR_PREFIX)DEX2OAT_HOST_INSTRUCTION_SET_FEATURES)
Ian Rogersd582fa42014-11-05 23:46:43 -080037endif
38
Nicolas Geoffray1db132d2014-03-26 10:56:24 +000039# Use dex2oat debug version for better error reporting
Roland Levillain05e34f42018-05-24 13:19:05 +000040# $(1): compiler - optimizing, interpreter or interp-ac (interpreter-access-checks).
Richard Uhlerbb00f812017-02-16 14:21:10 +000041# $(2): 2ND_ or undefined, 2ND_ for 32-bit host builds.
Ian Rogersafd9acc2014-06-17 08:21:54 -070042define create-core-oat-host-rules
Andreas Gampe63fc30e2014-10-24 21:58:16 -070043 core_compile_options :=
44 core_image_name :=
45 core_oat_name :=
46 core_infix :=
Nicolas Geoffraya136ab52014-10-31 10:48:25 +000047 core_dex2oat_dependency := $(DEX2OAT_DEPENDENCY)
Andreas Gampe63fc30e2014-10-24 21:58:16 -070048
49 ifeq ($(1),optimizing)
Nicolas Geoffraya136ab52014-10-31 10:48:25 +000050 core_compile_options += --compiler-backend=Optimizing
Nicolas Geoffrayc13f13a2015-10-06 12:39:17 +010051 core_dex2oat_dependency := $(DEX2OAT)
Andreas Gampe63fc30e2014-10-24 21:58:16 -070052 endif
53 ifeq ($(1),interpreter)
Nicolas Geoffray49cda062017-04-21 13:08:25 +010054 core_compile_options += --compiler-filter=quicken
Andreas Gampe63fc30e2014-10-24 21:58:16 -070055 core_infix := -interpreter
56 endif
Andreas Gampe825570c2015-07-26 10:26:03 -070057 ifeq ($(1),interp-ac)
Nicolas Geoffray49cda062017-04-21 13:08:25 +010058 core_compile_options += --compiler-filter=extract --runtime-arg -Xverify:softfail
Andreas Gampe825570c2015-07-26 10:26:03 -070059 core_infix := -interp-ac
Igor Murashkin7617abd2015-07-10 18:27:47 -070060 endif
Nicolas Geoffrayb76bc782016-09-14 12:33:34 +000061 ifneq ($(filter-out interpreter interp-ac optimizing,$(1)),)
Andreas Gampe63fc30e2014-10-24 21:58:16 -070062 #Technically this test is not precise, but hopefully good enough.
Roland Levillain05e34f42018-05-24 13:19:05 +000063 $$(error found $(1) expected interpreter, interp-ac, or optimizing)
Andreas Gampe63fc30e2014-10-24 21:58:16 -070064 endif
Andreas Gampec23c9c92014-10-28 14:47:25 -070065
Vladimir Marko21910692019-11-06 13:27:03 +000066 core_image_location := $(HOST_OUT_JAVA_LIBRARIES)/core$$(core_infix)$(CORE_IMG_SUFFIX)
Vladimir Marko4519b9d2018-10-10 15:21:21 +010067 core_image_name := $($(2)HOST_CORE_IMG_OUT_BASE)$$(core_infix)$(CORE_IMG_SUFFIX)
68 core_oat_name := $($(2)HOST_CORE_OAT_OUT_BASE)$$(core_infix)$(CORE_OAT_SUFFIX)
Andreas Gampe63fc30e2014-10-24 21:58:16 -070069
70 # Using the bitness suffix makes it easier to add as a dependency for the run-test mk.
Richard Uhlerbb00f812017-02-16 14:21:10 +000071 ifeq ($(2),)
Vladimir Marko4519b9d2018-10-10 15:21:21 +010072 HOST_CORE_IMAGE_$(1)_64 := $$(core_image_name)
Andreas Gampe63fc30e2014-10-24 21:58:16 -070073 else
Vladimir Marko4519b9d2018-10-10 15:21:21 +010074 HOST_CORE_IMAGE_$(1)_32 := $$(core_image_name)
Andreas Gampe63fc30e2014-10-24 21:58:16 -070075 endif
Roland Levillain05e34f42018-05-24 13:19:05 +000076 HOST_CORE_IMG_OUTS += $$(core_image_name)
77 HOST_CORE_OAT_OUTS += $$(core_oat_name)
Andreas Gampe63fc30e2014-10-24 21:58:16 -070078
79$$(core_image_name): PRIVATE_CORE_COMPILE_OPTIONS := $$(core_compile_options)
Vladimir Marko21910692019-11-06 13:27:03 +000080$$(core_image_name): PRIVATE_CORE_IMAGE_LOCATION := $$(core_image_location)
Andreas Gampe63fc30e2014-10-24 21:58:16 -070081$$(core_image_name): PRIVATE_CORE_IMG_NAME := $$(core_image_name)
82$$(core_image_name): PRIVATE_CORE_OAT_NAME := $$(core_oat_name)
Vladimir Marko21910692019-11-06 13:27:03 +000083# In addition to the primary core image containing HOST_CORE_IMG_DEX_FILES,
84# also build a boot image extension for the remaining HOST_CORE_DEX_FILES.
85$$(core_image_name): $$(HOST_CORE_DEX_LOCATIONS) $$(core_dex2oat_dependency)
Shinichiro Hamajic5d29052015-12-18 15:51:51 +090086 @echo "host dex2oat: $$@"
Ian Rogersafd9acc2014-06-17 08:21:54 -070087 @mkdir -p $$(dir $$@)
Vladimir Marko21910692019-11-06 13:27:03 +000088 $$(hide) ANDROID_LOG_TAGS="*:e" $$(DEX2OAT) \
89 --runtime-arg -Xms$(DEX2OAT_IMAGE_XMS) \
Andreas Gampe088b16e2014-12-03 21:59:27 -080090 --runtime-arg -Xmx$(DEX2OAT_IMAGE_XMX) \
Vladimir Marko0ace5632018-12-14 11:11:47 +000091 $$(addprefix --dex-file=,$$(HOST_CORE_IMG_DEX_FILES)) \
92 $$(addprefix --dex-location=,$$(HOST_CORE_IMG_DEX_LOCATIONS)) \
93 --oat-file=$$(PRIVATE_CORE_OAT_NAME) \
Vladimir Marko21910692019-11-06 13:27:03 +000094 --oat-location=$$(PRIVATE_CORE_OAT_NAME) \
95 --image=$$(PRIVATE_CORE_IMG_NAME) \
96 --base=$$(LIBART_IMG_HOST_BASE_ADDRESS) \
97 --instruction-set=$$($(2)ART_HOST_ARCH) \
98 $$(LOCAL_$(2)DEX2OAT_HOST_INSTRUCTION_SET_FEATURES_OPTION) \
99 --host --android-root=$$(HOST_OUT) \
100 --generate-debug-info --generate-build-id \
101 --runtime-arg -XX:SlowDebug=true \
102 --no-inline-from=core-oj-hostdex.jar \
103 $$(PRIVATE_CORE_COMPILE_OPTIONS) && \
104 ANDROID_LOG_TAGS="*:e" $$(DEX2OAT) \
105 --runtime-arg -Xms$(DEX2OAT_IMAGE_XMS) \
106 --runtime-arg -Xmx$(DEX2OAT_IMAGE_XMX) \
107 --runtime-arg -Xbootclasspath:$$(subst $$(space),:,$$(strip \
108 $$(HOST_CORE_DEX_FILES))) \
109 --runtime-arg -Xbootclasspath-locations:$$(subst $$(space),:,$$(strip \
110 $$(HOST_CORE_DEX_LOCATIONS))) \
111 $$(addprefix --dex-file=, \
112 $$(filter-out $$(HOST_CORE_IMG_DEX_FILES),$$(HOST_CORE_DEX_FILES))) \
113 $$(addprefix --dex-location=, \
114 $$(filter-out $$(HOST_CORE_IMG_DEX_LOCATIONS),$$(HOST_CORE_DEX_LOCATIONS))) \
115 --oat-file=$$(PRIVATE_CORE_OAT_NAME) \
116 --oat-location=$$(PRIVATE_CORE_OAT_NAME) \
117 --boot-image=$$(PRIVATE_CORE_IMAGE_LOCATION) \
118 --image=$$(PRIVATE_CORE_IMG_NAME) \
119 --instruction-set=$$($(2)ART_HOST_ARCH) \
Richard Uhlerbb00f812017-02-16 14:21:10 +0000120 $$(LOCAL_$(2)DEX2OAT_HOST_INSTRUCTION_SET_FEATURES_OPTION) \
Richard Uhler556cba02017-02-28 17:06:29 +0000121 --host --android-root=$$(HOST_OUT) \
Vladimir Markoa2da9b92018-10-10 14:21:55 +0100122 --generate-debug-info --generate-build-id \
Andreas Gampee8f74ca2018-01-02 09:26:16 -0800123 --runtime-arg -XX:SlowDebug=true \
Vladimir Marko4519b9d2018-10-10 15:21:21 +0100124 --no-inline-from=core-oj-hostdex.jar \
125 $$(PRIVATE_CORE_COMPILE_OPTIONS)
Brian Carlstrom27ec9612011-09-19 20:20:38 -0700126
Andreas Gampe63fc30e2014-10-24 21:58:16 -0700127$$(core_oat_name): $$(core_image_name)
Ian Rogersafd9acc2014-06-17 08:21:54 -0700128
Andreas Gampe63fc30e2014-10-24 21:58:16 -0700129 # Clean up locally used variables.
Nicolas Geoffraya136ab52014-10-31 10:48:25 +0000130 core_dex2oat_dependency :=
Andreas Gampe63fc30e2014-10-24 21:58:16 -0700131 core_compile_options :=
132 core_image_name :=
133 core_oat_name :=
134 core_infix :=
Ian Rogersafd9acc2014-06-17 08:21:54 -0700135endef # create-core-oat-host-rules
136
Roland Levillain05e34f42018-05-24 13:19:05 +0000137# $(1): compiler - optimizing, interpreter or interp-ac (interpreter-access-checks).
Andreas Gampec23c9c92014-10-28 14:47:25 -0700138define create-core-oat-host-rule-combination
Vladimir Marko4519b9d2018-10-10 15:21:21 +0100139 $(call create-core-oat-host-rules,$(1),)
Andreas Gampec23c9c92014-10-28 14:47:25 -0700140
141 ifneq ($(HOST_PREFER_32_BIT),true)
Vladimir Marko4519b9d2018-10-10 15:21:21 +0100142 $(call create-core-oat-host-rules,$(1),2ND_)
Andreas Gampec23c9c92014-10-28 14:47:25 -0700143 endif
144endef
145
Vladimir Marko4519b9d2018-10-10 15:21:21 +0100146$(eval $(call create-core-oat-host-rule-combination,optimizing))
147$(eval $(call create-core-oat-host-rule-combination,interpreter))
148$(eval $(call create-core-oat-host-rule-combination,interp-ac))
Brian Carlstrom2b7cdf42011-10-13 11:18:28 -0700149
Dan Willemsend60f5a22018-07-24 14:45:33 -0700150.PHONY: test-art-host-dex2oat-host
Jeff Haodcdc85b2015-12-04 14:06:18 -0800151test-art-host-dex2oat-host: $(HOST_CORE_IMG_OUTS)
152
Roland Levillain05e34f42018-05-24 13:19:05 +0000153# $(1): compiler - optimizing, interpreter or interp-ac (interpreter-access-checks).
154# $(2): 2ND_ or undefined
Ian Rogersafd9acc2014-06-17 08:21:54 -0700155define create-core-oat-target-rules
Andreas Gampe63fc30e2014-10-24 21:58:16 -0700156 core_compile_options :=
157 core_image_name :=
158 core_oat_name :=
159 core_infix :=
Nicolas Geoffraya136ab52014-10-31 10:48:25 +0000160 core_dex2oat_dependency := $(DEX2OAT_DEPENDENCY)
Andreas Gampe63fc30e2014-10-24 21:58:16 -0700161
162 ifeq ($(1),optimizing)
Serban Constantinescu010cf912014-12-04 18:12:21 +0000163 core_compile_options += --compiler-backend=Optimizing
Nicolas Geoffray7701d102015-10-05 09:51:36 +0100164 # With the optimizing compiler, we want to rerun dex2oat whenever there is
165 # a dex2oat change to catch regressions early.
166 core_dex2oat_dependency := $(DEX2OAT)
Andreas Gampe63fc30e2014-10-24 21:58:16 -0700167 endif
168 ifeq ($(1),interpreter)
Nicolas Geoffray49cda062017-04-21 13:08:25 +0100169 core_compile_options += --compiler-filter=quicken
Andreas Gampe63fc30e2014-10-24 21:58:16 -0700170 core_infix := -interpreter
171 endif
Andreas Gampe825570c2015-07-26 10:26:03 -0700172 ifeq ($(1),interp-ac)
Nicolas Geoffray49cda062017-04-21 13:08:25 +0100173 core_compile_options += --compiler-filter=extract --runtime-arg -Xverify:softfail
Andreas Gampe825570c2015-07-26 10:26:03 -0700174 core_infix := -interp-ac
Igor Murashkin7617abd2015-07-10 18:27:47 -0700175 endif
Nicolas Geoffrayb76bc782016-09-14 12:33:34 +0000176 ifneq ($(filter-out interpreter interp-ac optimizing,$(1)),)
Andreas Gampec23c9c92014-10-28 14:47:25 -0700177 # Technically this test is not precise, but hopefully good enough.
Roland Levillain05e34f42018-05-24 13:19:05 +0000178 $$(error found $(1) expected interpreter, interp-ac, or optimizing)
Andreas Gampe63fc30e2014-10-24 21:58:16 -0700179 endif
Andreas Gampec23c9c92014-10-28 14:47:25 -0700180
Vladimir Marko21910692019-11-06 13:27:03 +0000181 core_image_location := $(ART_TARGET_TEST_OUT)/core$$(core_infix)$(CORE_IMG_SUFFIX)
Roland Levillain05e34f42018-05-24 13:19:05 +0000182 core_image_name := $($(2)TARGET_CORE_IMG_OUT_BASE)$$(core_infix)$(CORE_IMG_SUFFIX)
183 core_oat_name := $($(2)TARGET_CORE_OAT_OUT_BASE)$$(core_infix)$(CORE_OAT_SUFFIX)
Andreas Gampe63fc30e2014-10-24 21:58:16 -0700184
185 # Using the bitness suffix makes it easier to add as a dependency for the run-test mk.
Richard Uhlerbb00f812017-02-16 14:21:10 +0000186 ifeq ($(2),)
Andreas Gampec23c9c92014-10-28 14:47:25 -0700187 ifdef TARGET_2ND_ARCH
Roland Levillain05e34f42018-05-24 13:19:05 +0000188 TARGET_CORE_IMAGE_$(1)_64 := $$(core_image_name)
Andreas Gampec23c9c92014-10-28 14:47:25 -0700189 else
Roland Levillain05e34f42018-05-24 13:19:05 +0000190 TARGET_CORE_IMAGE_$(1)_32 := $$(core_image_name)
Andreas Gampec23c9c92014-10-28 14:47:25 -0700191 endif
Andreas Gampe63fc30e2014-10-24 21:58:16 -0700192 else
Roland Levillain05e34f42018-05-24 13:19:05 +0000193 TARGET_CORE_IMAGE_$(1)_32 := $$(core_image_name)
Andreas Gampe63fc30e2014-10-24 21:58:16 -0700194 endif
Roland Levillain05e34f42018-05-24 13:19:05 +0000195 TARGET_CORE_IMG_OUTS += $$(core_image_name)
196 TARGET_CORE_OAT_OUTS += $$(core_oat_name)
Andreas Gampe63fc30e2014-10-24 21:58:16 -0700197
198$$(core_image_name): PRIVATE_CORE_COMPILE_OPTIONS := $$(core_compile_options)
Vladimir Marko21910692019-11-06 13:27:03 +0000199$$(core_image_name): PRIVATE_CORE_IMAGE_LOCATION := $$(core_image_location)
Andreas Gampe63fc30e2014-10-24 21:58:16 -0700200$$(core_image_name): PRIVATE_CORE_IMG_NAME := $$(core_image_name)
201$$(core_image_name): PRIVATE_CORE_OAT_NAME := $$(core_oat_name)
Vladimir Marko21910692019-11-06 13:27:03 +0000202# In addition to the primary core image containing TARGET_CORE_IMG_DEX_FILES,
203# also build a boot image extension for the remaining TARGET_CORE_DEX_FILES.
204$$(core_image_name): $$(TARGET_CORE_DEX_FILES) $$(core_dex2oat_dependency)
Shinichiro Hamajic5d29052015-12-18 15:51:51 +0900205 @echo "target dex2oat: $$@"
Andreas Gampeafbaa1a2014-03-25 18:09:32 -0700206 @mkdir -p $$(dir $$@)
Vladimir Marko21910692019-11-06 13:27:03 +0000207 $$(hide) $$(DEX2OAT) \
208 --runtime-arg -Xms$(DEX2OAT_IMAGE_XMS) \
Andreas Gampe088b16e2014-12-03 21:59:27 -0800209 --runtime-arg -Xmx$(DEX2OAT_IMAGE_XMX) \
Vladimir Marko0ace5632018-12-14 11:11:47 +0000210 $$(addprefix --dex-file=,$$(TARGET_CORE_IMG_DEX_FILES)) \
211 $$(addprefix --dex-location=,$$(TARGET_CORE_IMG_DEX_LOCATIONS)) \
212 --oat-file=$$(PRIVATE_CORE_OAT_NAME) \
Vladimir Marko21910692019-11-06 13:27:03 +0000213 --oat-location=$$(PRIVATE_CORE_OAT_NAME) \
214 --image=$$(PRIVATE_CORE_IMG_NAME) \
215 --base=$$(LIBART_IMG_TARGET_BASE_ADDRESS) \
216 --instruction-set=$$($(2)TARGET_ARCH) \
Richard Uhlerbb00f812017-02-16 14:21:10 +0000217 --instruction-set-variant=$$($(2)DEX2OAT_TARGET_CPU_VARIANT) \
218 --instruction-set-features=$$($(2)DEX2OAT_TARGET_INSTRUCTION_SET_FEATURES) \
Richard Uhler556cba02017-02-28 17:06:29 +0000219 --android-root=$$(PRODUCT_OUT)/system \
Vladimir Markoa2da9b92018-10-10 14:21:55 +0100220 --generate-debug-info --generate-build-id \
Andreas Gampee8f74ca2018-01-02 09:26:16 -0800221 --runtime-arg -XX:SlowDebug=true \
Vladimir Marko21910692019-11-06 13:27:03 +0000222 $$(PRIVATE_CORE_COMPILE_OPTIONS) && \
223 $$(DEX2OAT) \
224 --runtime-arg -Xms$(DEX2OAT_IMAGE_XMS) \
225 --runtime-arg -Xmx$(DEX2OAT_IMAGE_XMX) \
226 --runtime-arg -Xbootclasspath:$$(subst $$(space),:,$$(strip \
227 $$(TARGET_CORE_DEX_FILES))) \
228 --runtime-arg -Xbootclasspath-locations:$$(subst $$(space),:,$$(strip \
229 $$(TARGET_CORE_DEX_LOCATIONS))) \
230 $$(addprefix --dex-file=, \
231 $$(filter-out $$(TARGET_CORE_IMG_DEX_FILES),$$(TARGET_CORE_DEX_FILES))) \
232 $$(addprefix --dex-location=, \
233 $$(filter-out $$(TARGET_CORE_IMG_DEX_LOCATIONS),$$(TARGET_CORE_DEX_LOCATIONS))) \
234 --oat-file=$$(PRIVATE_CORE_OAT_NAME) \
235 --oat-location=$$(PRIVATE_CORE_OAT_NAME) \
236 --boot-image=$$(PRIVATE_CORE_IMAGE_LOCATION) \
237 --image=$$(PRIVATE_CORE_IMG_NAME) \
238 --instruction-set=$$($(2)TARGET_ARCH) \
239 --instruction-set-variant=$$($(2)DEX2OAT_TARGET_CPU_VARIANT) \
240 --instruction-set-features=$$($(2)DEX2OAT_TARGET_INSTRUCTION_SET_FEATURES) \
241 --android-root=$$(PRODUCT_OUT)/system \
242 --generate-debug-info --generate-build-id \
243 --runtime-arg -XX:SlowDebug=true \
244 $$(PRIVATE_CORE_COMPILE_OPTIONS) || \
245 (rm $$(PRIVATE_CORE_OAT_NAME); exit 1)
Andreas Gampeafbaa1a2014-03-25 18:09:32 -0700246
Andreas Gampe63fc30e2014-10-24 21:58:16 -0700247$$(core_oat_name): $$(core_image_name)
Andreas Gampe2fe07922014-04-21 07:50:39 -0700248
Andreas Gampe63fc30e2014-10-24 21:58:16 -0700249 # Clean up locally used variables.
Nicolas Geoffraya136ab52014-10-31 10:48:25 +0000250 core_dex2oat_dependency :=
Andreas Gampe63fc30e2014-10-24 21:58:16 -0700251 core_compile_options :=
252 core_image_name :=
253 core_oat_name :=
254 core_infix :=
Ian Rogersafd9acc2014-06-17 08:21:54 -0700255endef # create-core-oat-target-rules
Andreas Gampeafbaa1a2014-03-25 18:09:32 -0700256
Roland Levillain05e34f42018-05-24 13:19:05 +0000257# $(1): compiler - optimizing, interpreter or interp-ac (interpreter-access-checks).
Andreas Gampec23c9c92014-10-28 14:47:25 -0700258define create-core-oat-target-rule-combination
Roland Levillain05e34f42018-05-24 13:19:05 +0000259 $(call create-core-oat-target-rules,$(1),)
Andreas Gampec23c9c92014-10-28 14:47:25 -0700260
261 ifdef TARGET_2ND_ARCH
Roland Levillain05e34f42018-05-24 13:19:05 +0000262 $(call create-core-oat-target-rules,$(1),2ND_)
Andreas Gampec23c9c92014-10-28 14:47:25 -0700263 endif
264endef
265
Roland Levillain05e34f42018-05-24 13:19:05 +0000266$(eval $(call create-core-oat-target-rule-combination,optimizing))
267$(eval $(call create-core-oat-target-rule-combination,interpreter))
268$(eval $(call create-core-oat-target-rule-combination,interp-ac))
Richard Uhler67e1dc52017-02-06 16:50:17 +0000269
270# Define a default core image that can be used for things like gtests that
271# need some image to run, but don't otherwise care which image is used.
Richard Uhlerbb00f812017-02-16 14:21:10 +0000272HOST_CORE_IMAGE_DEFAULT_32 := $(HOST_CORE_IMAGE_optimizing_32)
273HOST_CORE_IMAGE_DEFAULT_64 := $(HOST_CORE_IMAGE_optimizing_64)
274TARGET_CORE_IMAGE_DEFAULT_32 := $(TARGET_CORE_IMAGE_optimizing_32)
275TARGET_CORE_IMAGE_DEFAULT_64 := $(TARGET_CORE_IMAGE_optimizing_64)