collect emm meta files for emma instrumented build

when doing 'make dist', with EMMA_INSTRUMENT on the coverage.em files
generated for each module will be collected into one emma_meta.zip file

Change-Id: I382c39a97005e6cae5c79ad7eaef1c8857f658af
diff --git a/core/Makefile b/core/Makefile
index 361d190..78d1c32 100644
--- a/core/Makefile
+++ b/core/Makefile
@@ -1064,6 +1064,17 @@
 	$(hide) mkdir -p $(dir $@)
 	$(hide) zip -qj $@ $(TARGET_OUT_APPS)/*
 
+
+#------------------------------------------------------------------
+# A zip of emma code coverage meta files. Generated for fully emma
+# instrumented build.
+#
+EMMA_META_ZIP := $(PRODUCT_OUT)/emma_meta.zip
+$(EMMA_META_ZIP): $(INSTALLED_SYSTEMIMAGE)
+	@echo "Collecting Emma coverage meta files."
+	$(hide) find $(TARGET_COMMON_OUT_ROOT) -name "coverage.em" | \
+		zip -@ -q $@
+
 endif	# TARGET_SIMULATOR != true
 
 # -----------------------------------------------------------------