From 3e73817588025539cb5c9beaba751a74518bf948 Mon Sep 17 00:00:00 2001 From: Arindam Mondal Date: Wed, 5 Jun 2024 11:09:05 +0000 Subject: [PATCH] Convert tegu/preloaded_nanoapps.json's .mk file to Android.bp. Since `preloaded_nanoapps.json` has different configurations for `factory` products and `non-factory` products, `soong_namespace {}` needs to be added to the converted Android.bp file to avoid misuse. Additionally, due to ag/27690356 and ag/27683070 a common inheritance layer has been added to all `non-factory` products for `tegu`. Therefore, setting different `PRODUCT_SOONG_NAMESPACES` in the corresponding `tegu_generic.mk` and `factory_tegu.mk` files will allow factory products and non-factory products of tegu to use different preloaded_nanoapps.json. FLAG: EXEMPT Mechanical refactoring Bug: 336452008 Bug: 313835597 Test: 1. lunch tegu-trunk_staging-userdebug && \ m -j preloaded_nanoapps.json 2. Check ./out/target/product/tegu/.../preloaded_nanoapps.json It should be the tegu version. 3. lunch factory_tegu-trunk_staging-userdebug && \ m -j preloaded_nanoapps.json 4. Check ./out/target/product/tegu/.../preloaded_nanoapps.json It should be the factory version. Change-Id: I483043ce3c55dc08b54699f332d654d18eedebd2 --- factory_tegu.mk | 3 +++ tegu_generic.mk | 3 +++ 2 files changed, 6 insertions(+) diff --git a/factory_tegu.mk b/factory_tegu.mk index a64ef18..79e5ba7 100644 --- a/factory_tegu.mk +++ b/factory_tegu.mk @@ -37,3 +37,6 @@ PRODUCT_PROPERTY_OVERRIDES += \ PRODUCT_PACKAGES += fatp_tg4_wide_hat_tool PRODUCT_WITHOUT_TTS_VOICE_PACKS := true + +# preloaded_nanoapps.json +PRODUCT_SOONG_NAMESPACES += vendor/google_contexthub/devices/factory diff --git a/tegu_generic.mk b/tegu_generic.mk index 0c85062..fc03ac5 100644 --- a/tegu_generic.mk +++ b/tegu_generic.mk @@ -15,3 +15,6 @@ # $(call inherit-product, device/google/tegu/device-tegu.mk) +# preloaded_nanoapps.json +PRODUCT_SOONG_NAMESPACES += vendor/google_contexthub/devices/p24_common +