From 450197e2655785547f8a7b6bb9f327c7e21a6b53 Mon Sep 17 00:00:00 2001 From: Yike Date: Mon, 19 Sep 2022 16:02:48 +0800 Subject: [PATCH] Export the `target_required` property to module-info Some host test modules such as `python_test_host` use the `target_required` attribute to declare target dependencies that will be pushed to device. For example, `aidl_integration_test` references several target dependencies in the `target_required` attribute since those output files will be searched and pushed to device at runtime. Besides, those target dependencies can't be declared in the `data` attribute instead, since some modules' `data` attribute doesn't support multi-arch. So that, this information needs to present in module_info.json and exported to properly generate Bazel targets that include these dependencies. Test: m out/target/product/coral/module-info.json Bug: 222438068 Change-Id: Ia5ee103be1e7a811e1fdbd2b39252912b1a35c18 --- core/tasks/module-info.mk | 1 + 1 file changed, 1 insertion(+) diff --git a/core/tasks/module-info.mk b/core/tasks/module-info.mk index 7e7abd22e9..dbd1e847ea 100644 --- a/core/tasks/module-info.mk +++ b/core/tasks/module-info.mk @@ -31,6 +31,7 @@ $(MODULE_INFO_JSON): '"data_dependencies": [$(foreach w,$(sort $(ALL_MODULES.$(m).TEST_DATA_BINS)),"$(w)", )], ' \ '"supported_variants": [$(foreach w,$(sort $(ALL_MODULES.$(m).SUPPORTED_VARIANTS)),"$(w)", )], ' \ '"host_dependencies": [$(foreach w,$(sort $(ALL_MODULES.$(m).HOST_REQUIRED_FROM_TARGET)),"$(w)", )], ' \ + '"target_dependencies": [$(foreach w,$(sort $(ALL_MODULES.$(m).TARGET_REQUIRED_FROM_HOST)),"$(w)", )], ' \ '},\n' \ ) | sed -e 's/, *\]/]/g' -e 's/, *\}/ }/g' -e '$$s/,$$//' >> $@ $(hide) echo '}' >> $@