Enable `-sha256` feature to some Soong built zip files
Enable the new soong_zip feature to general-tests.zip,
host-unit-tests.zip, android-cts.zip, android-mts.zip etc. This is a
following change of https://r.android.com/2395452. With `-sha256` flag,
file header of generated zip files contains SHA256 checksum for each
file, which can then be used by downstream systems.
Bug: 259513199
Test: run `m dist host-unit-tests general-tests cts mts` and check zip
files under `out/dist/`
Change-Id: I726b5261d177beadcd8f707e2cd2cb5cdef20273
diff --git a/core/tasks/host-unit-tests.mk b/core/tasks/host-unit-tests.mk
index ed2f2a6..733a2e2 100644
--- a/core/tasks/host-unit-tests.mk
+++ b/core/tasks/host-unit-tests.mk
@@ -41,7 +41,7 @@
grep $(TARGET_OUT_TESTCASES) $@.list > $@-target.list || true
$(hide) $(SOONG_ZIP) -d -o $@ -P host -C $(HOST_OUT) -l $@-host.list \
-P target -C $(PRODUCT_OUT) -l $@-target.list \
- -P host/testcases -C $(HOST_OUT) -l $@-host-libs.list
+ -P host/testcases -C $(HOST_OUT) -l $@-host-libs.list -sha256
rm -f $@.list $@-host.list $@-target.list $@-host-libs.list
host-unit-tests: $(host_unit_tests_zip)