Merge "Update code coverage filtering"
diff --git a/core/clear_vars.mk b/core/clear_vars.mk
index 9adb09c..8de365c 100644
--- a/core/clear_vars.mk
+++ b/core/clear_vars.mk
@@ -109,6 +109,8 @@
# full or incremental
LOCAL_JACK_ENABLED:=full
LOCAL_JACK_FLAGS:=
+LOCAL_JACK_COVERAGE_INCLUDE_FILTER:=
+LOCAL_JACK_COVERAGE_EXCLUDE_FILTER:=
LOCAL_CERTIFICATE:=
LOCAL_SDK_VERSION:=
LOCAL_SDK_RES_VERSION:=
diff --git a/core/java.mk b/core/java.mk
index 7781799..a070d20 100644
--- a/core/java.mk
+++ b/core/java.mk
@@ -638,9 +638,11 @@
ifeq ($(LOCAL_EMMA_INSTRUMENT),true)
$(built_dex_intermediate): PRIVATE_JACK_COVERAGE_OPTIONS := \
- -D jack.coverage="true" \
+ -D jack.coverage=true \
-D jack.coverage.metadata.file=$(intermediates.COMMON)/coverage.em \
- -D jack.coverage.jacoco.package=$(JACOCO_PACKAGE_NAME)
+ -D jack.coverage.jacoco.package=$(JACOCO_PACKAGE_NAME) \
+ $(addprefix -D jack.coverage.jacoco.include=,$(LOCAL_JACK_COVERAGE_INCLUDE_FILTER)) \
+ $(addprefix -D jack.coverage.jacoco.exclude=,$(LOCAL_JACK_COVERAGE_EXCLUDE_FILTER))
else
$(built_dex_intermediate): PRIVATE_JACK_COVERAGE_OPTIONS :=
endif