1afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers# 2afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers# Copyright (C) 2011 The Android Open Source Project 3afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers# 4afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers# Licensed under the Apache License, Version 2.0 (the "License"); 5afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers# you may not use this file except in compliance with the License. 6afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers# You may obtain a copy of the License at 7afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers# 8afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers# http://www.apache.org/licenses/LICENSE-2.0 9afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers# 10afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers# Unless required by applicable law or agreed to in writing, software 11afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers# distributed under the License is distributed on an "AS IS" BASIS, 12afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers# See the License for the specific language governing permissions and 14afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers# limitations under the License. 15afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers# 16afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers 173774335b08076117d6950cd472cdd59a167470b5Igor Murashkinifndef ART_ANDROID_COMMON_TEST_MK 183774335b08076117d6950cd472cdd59a167470b5Igor MurashkinART_ANDROID_COMMON_TEST_MK = true 19afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers 20afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogersinclude art/build/Android.common_path.mk 21afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers 221fe5e5cce85a3cdc64a8d226a8ef4e6134c2b9ebAndreas Gampe# We need to set a define for the nativetest dir so that common_runtime_test will know the right 231fe5e5cce85a3cdc64a8d226a8ef4e6134c2b9ebAndreas Gampe# path. (The problem is being a 32b test on 64b device, which is still located in nativetest64). 241fe5e5cce85a3cdc64a8d226a8ef4e6134c2b9ebAndreas GampeART_TARGET_CFLAGS += -DART_TARGET_NATIVETEST_DIR=${ART_TARGET_NATIVETEST_DIR} 251fe5e5cce85a3cdc64a8d226a8ef4e6134c2b9ebAndreas Gampe 26afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers# List of known broken tests that we won't attempt to execute. The test name must be the full 27afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers# rule name such as test-art-host-oat-optimizing-HelloWorld64. 28bdeb9b7030d30a94bddbb84f4a8bf2f92da9fdddMathieu ChartierART_TEST_KNOWN_BROKEN := 29afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers 30928f72bd75c385ba2708c58521171a77264d4486Andreas Gampe# Failing valgrind tests. 31928f72bd75c385ba2708c58521171a77264d4486Andreas Gampe# Note: *all* 64b tests involving the runtime do not work currently. b/15170219. 32928f72bd75c385ba2708c58521171a77264d4486Andreas Gampe 33f61b5377068f22c0be7b2f6e62961e620408beb2Nicolas Geoffray# List of known failing tests that when executed won't cause test execution to not finish. 34f61b5377068f22c0be7b2f6e62961e620408beb2Nicolas Geoffray# The test name must be the full rule name such as test-art-host-oat-optimizing-HelloWorld64. 35f61b5377068f22c0be7b2f6e62961e620408beb2Nicolas GeoffrayART_TEST_KNOWN_FAILING := 36afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers 37afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers# Keep going after encountering a test failure? 38e7655c554403dbac5110b7e3aa875116814a8dc3Andreas GampeART_TEST_KEEP_GOING ?= true 39afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers 405242c0ab0505f0f038b15c3d934a79a6b4e5ef17Ian Rogers# Do you want all tests, even those that are time consuming? 41f5c44b37131e7c54675db7d4446cfb256f6bd0f7Ian RogersART_TEST_FULL ?= false 42f5c44b37131e7c54675db7d4446cfb256f6bd0f7Ian Rogers 43f5c44b37131e7c54675db7d4446cfb256f6bd0f7Ian Rogers# Do you want default compiler tests run? 44f5c44b37131e7c54675db7d4446cfb256f6bd0f7Ian RogersART_TEST_DEFAULT_COMPILER ?= true 45f5c44b37131e7c54675db7d4446cfb256f6bd0f7Ian Rogers 46f5c44b37131e7c54675db7d4446cfb256f6bd0f7Ian Rogers# Do you want interpreter tests run? 47f5c44b37131e7c54675db7d4446cfb256f6bd0f7Ian RogersART_TEST_INTERPRETER ?= $(ART_TEST_FULL) 485242c0ab0505f0f038b15c3d934a79a6b4e5ef17Ian Rogers 493fc1b12a2308e39a0c9b1cdcf4eb0b5770081e51Mathieu Chartier# Do you want JIT tests run? 503fc1b12a2308e39a0c9b1cdcf4eb0b5770081e51Mathieu ChartierART_TEST_JIT ?= $(ART_TEST_FULL) 513fc1b12a2308e39a0c9b1cdcf4eb0b5770081e51Mathieu Chartier 525242c0ab0505f0f038b15c3d934a79a6b4e5ef17Ian Rogers# Do you want optimizing compiler tests run? 535242c0ab0505f0f038b15c3d934a79a6b4e5ef17Ian RogersART_TEST_OPTIMIZING ?= $(ART_TEST_FULL) 545242c0ab0505f0f038b15c3d934a79a6b4e5ef17Ian Rogers 55c23c9c93aade8dd99d23ad796888cbf2f7f96a47Andreas Gampe# Do we want to test a PIC-compiled core image? 56c23c9c93aade8dd99d23ad796888cbf2f7f96a47Andreas GampeART_TEST_PIC_IMAGE ?= $(ART_TEST_FULL) 57c23c9c93aade8dd99d23ad796888cbf2f7f96a47Andreas Gampe 58c23c9c93aade8dd99d23ad796888cbf2f7f96a47Andreas Gampe# Do we want to test PIC-compiled tests ("apps")? 59c23c9c93aade8dd99d23ad796888cbf2f7f96a47Andreas GampeART_TEST_PIC_TEST ?= $(ART_TEST_FULL) 60c23c9c93aade8dd99d23ad796888cbf2f7f96a47Andreas Gampe 615242c0ab0505f0f038b15c3d934a79a6b4e5ef17Ian Rogers# Do you want tracing tests run? 625242c0ab0505f0f038b15c3d934a79a6b4e5ef17Ian RogersART_TEST_TRACE ?= $(ART_TEST_FULL) 635242c0ab0505f0f038b15c3d934a79a6b4e5ef17Ian Rogers 64b91205e40fe692061edde19ecb87d51414a7fceeAndreas Gampe# Do you want tracing tests (streaming mode) run? 65b91205e40fe692061edde19ecb87d51414a7fceeAndreas GampeART_TEST_TRACE_STREAM ?= $(ART_TEST_FULL) 66b91205e40fe692061edde19ecb87d51414a7fceeAndreas Gampe 67701aa645a3e61fe8866000bb66b1287196a5536aIan Rogers# Do you want tests with GC verification enabled run? 68701aa645a3e61fe8866000bb66b1287196a5536aIan RogersART_TEST_GC_VERIFY ?= $(ART_TEST_FULL) 69701aa645a3e61fe8866000bb66b1287196a5536aIan Rogers 708a14b75d876ad20f08087664070354fa6f65a029Ian Rogers# Do you want tests with the GC stress mode enabled run? 718a14b75d876ad20f08087664070354fa6f65a029Ian RogersART_TEST_GC_STRESS ?= $(ART_TEST_FULL) 728a14b75d876ad20f08087664070354fa6f65a029Ian Rogers 73f5c44b37131e7c54675db7d4446cfb256f6bd0f7Ian Rogers# Do you want tests with the JNI forcecopy mode enabled run? 74f5c44b37131e7c54675db7d4446cfb256f6bd0f7Ian RogersART_TEST_JNI_FORCECOPY ?= $(ART_TEST_FULL) 75a59dd80f9f48cb750d329d4d4af2d99d72b484d1Alex Light 76f5c44b37131e7c54675db7d4446cfb256f6bd0f7Ian Rogers# Do you want run-tests with relocation disabled run? 77a59dd80f9f48cb750d329d4d4af2d99d72b484d1Alex LightART_TEST_RUN_TEST_NO_RELOCATE ?= $(ART_TEST_FULL) 78a59dd80f9f48cb750d329d4d4af2d99d72b484d1Alex Light 7941bb331ff93a8e54d0fafaaccfddd791a8ddf430Nicolas Geoffray# Do you want run-tests with prebuilding? 8041bb331ff93a8e54d0fafaaccfddd791a8ddf430Nicolas GeoffrayART_TEST_RUN_TEST_PREBUILD ?= true 8141bb331ff93a8e54d0fafaaccfddd791a8ddf430Nicolas Geoffray 82f5c44b37131e7c54675db7d4446cfb256f6bd0f7Ian Rogers# Do you want run-tests with no prebuilding enabled run? 839d722533b0ef6547ee0ab5286f65af98451c36e4Alex LightART_TEST_RUN_TEST_NO_PREBUILD ?= $(ART_TEST_FULL) 84a59dd80f9f48cb750d329d4d4af2d99d72b484d1Alex Light 8503a112d23694afffe9808082e7144b7e8744a4bdAlex Light# Do you want run-tests without a pregenerated core.art? 8603a112d23694afffe9808082e7144b7e8744a4bdAlex LightART_TEST_RUN_TEST_NO_IMAGE ?= $(ART_TEST_FULL) 8703a112d23694afffe9808082e7144b7e8744a4bdAlex Light 8803a112d23694afffe9808082e7144b7e8744a4bdAlex Light# Do you want run-tests with relocation enabled but patchoat failing? 8903a112d23694afffe9808082e7144b7e8744a4bdAlex LightART_TEST_RUN_TEST_RELOCATE_NO_PATCHOAT ?= $(ART_TEST_FULL) 9003a112d23694afffe9808082e7144b7e8744a4bdAlex Light 9103a112d23694afffe9808082e7144b7e8744a4bdAlex Light# Do you want run-tests without a dex2oat? 9203a112d23694afffe9808082e7144b7e8744a4bdAlex LightART_TEST_RUN_TEST_NO_DEX2OAT ?= $(ART_TEST_FULL) 9303a112d23694afffe9808082e7144b7e8744a4bdAlex Light 94bd2c63ca277a6f7659bc0821e0af1521ce45928eNicolas Geoffray# Do you want run-tests with libartd.so? 95bd2c63ca277a6f7659bc0821e0af1521ce45928eNicolas GeoffrayART_TEST_RUN_TEST_DEBUG ?= true 96bd2c63ca277a6f7659bc0821e0af1521ce45928eNicolas Geoffray 97bd2c63ca277a6f7659bc0821e0af1521ce45928eNicolas Geoffray# Do you want run-tests with libart.so? 98bd2c63ca277a6f7659bc0821e0af1521ce45928eNicolas GeoffrayART_TEST_RUN_TEST_NDEBUG ?= $(ART_TEST_FULL) 99bd2c63ca277a6f7659bc0821e0af1521ce45928eNicolas Geoffray 10041bb331ff93a8e54d0fafaaccfddd791a8ddf430Nicolas Geoffray# Do you want run-tests with the host/target's second arch? 10141bb331ff93a8e54d0fafaaccfddd791a8ddf430Nicolas GeoffrayART_TEST_RUN_TEST_2ND_ARCH ?= true 10241bb331ff93a8e54d0fafaaccfddd791a8ddf430Nicolas Geoffray 103bfac14acef0c2327ef8c28f146dd17d009aa8669Alex Light# Do you want failed tests to have their artifacts cleaned up? 104bfac14acef0c2327ef8c28f146dd17d009aa8669Alex LightART_TEST_RUN_TEST_ALWAYS_CLEAN ?= true 105bfac14acef0c2327ef8c28f146dd17d009aa8669Alex Light 10643c162f059e6463119aa1efd0841374ca7b4f789Nicolas Geoffray# Do you want run-tests with the --debuggable flag 10743c162f059e6463119aa1efd0841374ca7b4f789Nicolas GeoffrayART_TEST_RUN_TEST_DEBUGGABLE ?= $(ART_TEST_FULL) 10843c162f059e6463119aa1efd0841374ca7b4f789Nicolas Geoffray 109afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers# Define the command run on test failure. $(1) is the name of the test. Executed by the shell. 110afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogersdefine ART_TEST_FAILED 111afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers ( [ -f $(ART_HOST_TEST_DIR)/skipped/$(1) ] || \ 112afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers (mkdir -p $(ART_HOST_TEST_DIR)/failed/ && touch $(ART_HOST_TEST_DIR)/failed/$(1) && \ 113afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers echo $(ART_TEST_KNOWN_FAILING) | grep -q $(1) \ 114afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers && (echo -e "$(1) \e[91mKNOWN FAILURE\e[0m") \ 115d2c0b097261f8c55139bfb6426c89f3d0f8deb8aIan Rogers || (echo -e "$(1) \e[91mFAILED\e[0m" >&2 ))) 116afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogersendef 117afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers 118afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers# Define the command run on test success. $(1) is the name of the test. Executed by the shell. 119afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers# The command checks prints "PASSED" then checks to see if this was a top-level make target (e.g. 120afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers# "mm test-art-host-oat-HelloWorld32"), if it was then it does nothing, otherwise it creates a file 121afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers# to be printed in the passing test summary. 122afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogersdefine ART_TEST_PASSED 123afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers ( echo -e "$(1) \e[92mPASSED\e[0m" && \ 124afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers (echo $(MAKECMDGOALS) | grep -q $(1) || \ 125afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers (mkdir -p $(ART_HOST_TEST_DIR)/passed/ && touch $(ART_HOST_TEST_DIR)/passed/$(1)))) 126afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogersendef 127afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers 128afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers# Define the command run on test success of multiple prerequisites. $(1) is the name of the test. 129afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers# When the test is a top-level make target then a summary of the ran tests is produced. Executed by 130afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers# the shell. 131afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogersdefine ART_TEST_PREREQ_FINISHED 132afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers (echo -e "$(1) \e[32mCOMPLETE\e[0m" && \ 133afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers (echo $(MAKECMDGOALS) | grep -q -v $(1) || \ 134afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers (([ -d $(ART_HOST_TEST_DIR)/passed/ ] \ 135afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers && (echo -e "\e[92mPASSING TESTS\e[0m" && ls -1 $(ART_HOST_TEST_DIR)/passed/) \ 136afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers || (echo -e "\e[91mNO TESTS PASSED\e[0m")) && \ 137afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers ([ -d $(ART_HOST_TEST_DIR)/skipped/ ] \ 138afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers && (echo -e "\e[93mSKIPPED TESTS\e[0m" && ls -1 $(ART_HOST_TEST_DIR)/skipped/) \ 139afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers || (echo -e "\e[92mNO TESTS SKIPPED\e[0m")) && \ 140afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers ([ -d $(ART_HOST_TEST_DIR)/failed/ ] \ 1415182915657a6002672c6e1b421043f1ae6a4186aIan Rogers && (echo -e "\e[91mFAILING TESTS\e[0m" >&2 && ls -1 $(ART_HOST_TEST_DIR)/failed/ >&2) \ 142afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers || (echo -e "\e[92mNO TESTS FAILED\e[0m")) \ 143afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers && ([ ! -d $(ART_HOST_TEST_DIR)/failed/ ] && rm -r $(ART_HOST_TEST_DIR) \ 144afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers || (rm -r $(ART_HOST_TEST_DIR) && false))))) 145afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogersendef 146afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers 147afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers# Define the command executed by the shell ahead of running an art test. $(1) is the name of the 148afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers# test. 149afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogersdefine ART_TEST_SKIP 150afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers ((echo $(ART_TEST_KNOWN_BROKEN) | grep -q -v $(1) \ 151afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers && ([ ! -d $(ART_HOST_TEST_DIR)/failed/ ] || [ $(ART_TEST_KEEP_GOING) = true ])\ 152afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers && echo -e "$(1) \e[95mRUNNING\e[0m") \ 153afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers || ((mkdir -p $(ART_HOST_TEST_DIR)/skipped/ && touch $(ART_HOST_TEST_DIR)/skipped/$(1) \ 154afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers && ([ -d $(ART_HOST_TEST_DIR)/failed/ ] \ 155afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers && echo -e "$(1) \e[93mSKIPPING DUE TO EARLIER FAILURE\e[0m") \ 156afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers || echo -e "$(1) \e[93mSKIPPING BROKEN TEST\e[0m") && false)) 157afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogersendef 158afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers 159afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers# Create a build rule to create the dex file for a test. 160afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers# $(1): module prefix, e.g. art-test-dex 161afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers# $(2): input test directory in art/test, e.g. HelloWorld 162afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers# $(3): target output module path (default module path is used on host) 163afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers# $(4): additional dependencies 1641a2f84e80e852b1e210ed54fa995f3d781a23bd3Ian Rogers# $(5): a make variable used to collate target dependencies, e.g ART_TEST_TARGET_OAT_HelloWorld_DEX 1651a2f84e80e852b1e210ed54fa995f3d781a23bd3Ian Rogers# $(6): a make variable used to collate host dependencies, e.g ART_TEST_HOST_OAT_HelloWorld_DEX 16666d874d96d5699bb090c59f47a5a528956ca053eRichard Uhler# 1674d57ecf4c8e873017496c7f7aa51c3771dc70969Richard Uhler# If the input test directory contains a file called main.list and main.jpp, 1684d57ecf4c8e873017496c7f7aa51c3771dc70969Richard Uhler# then a multi-dex file is created passing main.list as the --main-dex-list 1694d57ecf4c8e873017496c7f7aa51c3771dc70969Richard Uhler# argument to dx and main.jpp for Jack. 170afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogersdefine build-art-test-dex 171afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers ifeq ($(ART_BUILD_TARGET),true) 172afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers include $(CLEAR_VARS) 173afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers LOCAL_MODULE := $(1)-$(2) 174afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers LOCAL_SRC_FILES := $(call all-java-files-under, $(2)) 175afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers LOCAL_NO_STANDARD_LIBRARIES := true 176afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers LOCAL_DEX_PREOPT := false 177afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers LOCAL_ADDITIONAL_DEPENDENCIES := art/build/Android.common_test.mk $(4) 178afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers LOCAL_MODULE_TAGS := tests 179afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers LOCAL_JAVA_LIBRARIES := $(TARGET_CORE_JARS) 180afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers LOCAL_MODULE_PATH := $(3) 181afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers LOCAL_DEX_PREOPT_IMAGE_LOCATION := $(TARGET_CORE_IMG_OUT) 18266d874d96d5699bb090c59f47a5a528956ca053eRichard Uhler ifneq ($(wildcard $(LOCAL_PATH)/$(2)/main.list),) 18366d874d96d5699bb090c59f47a5a528956ca053eRichard Uhler LOCAL_DX_FLAGS := --multi-dex --main-dex-list=$(LOCAL_PATH)/$(2)/main.list --minimal-main-dex 1844d57ecf4c8e873017496c7f7aa51c3771dc70969Richard Uhler LOCAL_JACK_FLAGS := -D jack.dex.output.policy=minimal-multidex -D jack.preprocessor=true -D jack.preprocessor.file=$(LOCAL_PATH)/$(2)/main.jpp 18566d874d96d5699bb090c59f47a5a528956ca053eRichard Uhler endif 186afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers include $(BUILD_JAVA_LIBRARY) 187532714abd50c547f0fdbe830f811d99e621e2d34Brian Carlstrom $(5) := $$(LOCAL_INSTALLED_MODULE) 188afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers endif 189afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers ifeq ($(ART_BUILD_HOST),true) 190afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers include $(CLEAR_VARS) 191afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers LOCAL_MODULE := $(1)-$(2) 192afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers LOCAL_SRC_FILES := $(call all-java-files-under, $(2)) 193afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers LOCAL_NO_STANDARD_LIBRARIES := true 194afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers LOCAL_DEX_PREOPT := false 195afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers LOCAL_ADDITIONAL_DEPENDENCIES := art/build/Android.common_test.mk $(4) 196afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers LOCAL_JAVA_LIBRARIES := $(HOST_CORE_JARS) 197afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers LOCAL_DEX_PREOPT_IMAGE := $(HOST_CORE_IMG_LOCATION) 19866d874d96d5699bb090c59f47a5a528956ca053eRichard Uhler ifneq ($(wildcard $(LOCAL_PATH)/$(2)/main.list),) 19966d874d96d5699bb090c59f47a5a528956ca053eRichard Uhler LOCAL_DX_FLAGS := --multi-dex --main-dex-list=$(LOCAL_PATH)/$(2)/main.list --minimal-main-dex 2004d57ecf4c8e873017496c7f7aa51c3771dc70969Richard Uhler LOCAL_JACK_FLAGS := -D jack.dex.output.policy=minimal-multidex -D jack.preprocessor=true -D jack.preprocessor.file=$(LOCAL_PATH)/$(2)/main.jpp 20166d874d96d5699bb090c59f47a5a528956ca053eRichard Uhler endif 202afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers include $(BUILD_HOST_DALVIK_JAVA_LIBRARY) 2031a2f84e80e852b1e210ed54fa995f3d781a23bd3Ian Rogers $(6) := $$(LOCAL_INSTALLED_MODULE) 204afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers endif 205afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogersendef 206afd9acc30bdd11cdd12d8209eb994cb371c65e33Ian Rogers 2073774335b08076117d6950cd472cdd59a167470b5Igor Murashkinendif # ART_ANDROID_COMMON_TEST_MK 208