From 018c6982807b83c7a309f2a2614addceb87249a9 Mon Sep 17 00:00:00 2001 From: Yifan Hong Date: Fri, 20 Nov 2020 11:58:44 -0800 Subject: [PATCH 1/2] Move virtual_ab makefiles to its own dir. Also add a readme file. Test: none Change-Id: Ia1e02d8fb0c6df13271f208b3ca1dc1f250b085b --- target/product/virtual_ab_ota/README.md | 14 ++++++++++++++ .../compression.mk} | 2 +- .../compression_retrofit.mk} | 0 .../launch.mk} | 0 .../plus_non_ab.mk} | 2 +- .../retrofit.mk} | 2 +- 6 files changed, 17 insertions(+), 3 deletions(-) create mode 100644 target/product/virtual_ab_ota/README.md rename target/product/{virtual_ab_ota_compression.mk => virtual_ab_ota/compression.mk} (98%) rename target/product/{virtual_ab_ota_compression_retrofit.mk => virtual_ab_ota/compression_retrofit.mk} (100%) rename target/product/{virtual_ab_ota.mk => virtual_ab_ota/launch.mk} (100%) rename target/product/{virtual_ab_ota_plus_non_ab.mk => virtual_ab_ota/plus_non_ab.mk} (98%) rename target/product/{virtual_ab_ota_retrofit.mk => virtual_ab_ota/retrofit.mk} (98%) diff --git a/target/product/virtual_ab_ota/README.md b/target/product/virtual_ab_ota/README.md new file mode 100644 index 0000000000..c1d0d7d8d6 --- /dev/null +++ b/target/product/virtual_ab_ota/README.md @@ -0,0 +1,14 @@ +# Virtual A/B makefiles + +Devices that uses Virtual A/B must inherit from one of the makefiles in this directory. + +## Structure + +``` +launch.mk + |- retrofit.mk + |- plus_non_ab.mk + |- compression.mk + +compression_retrofit.mk +``` diff --git a/target/product/virtual_ab_ota_compression.mk b/target/product/virtual_ab_ota/compression.mk similarity index 98% rename from target/product/virtual_ab_ota_compression.mk rename to target/product/virtual_ab_ota/compression.mk index 4bab55ed8c..2251187375 100644 --- a/target/product/virtual_ab_ota_compression.mk +++ b/target/product/virtual_ab_ota/compression.mk @@ -14,7 +14,7 @@ # limitations under the License. # -$(call inherit-product, $(SRC_TARGET_DIR)/product/virtual_ab_ota.mk) +$(call inherit-product, $(SRC_TARGET_DIR)/product/virtual_ab_ota/launch.mk) PRODUCT_VENDOR_PROPERTIES += ro.virtual_ab.compression.enabled=true diff --git a/target/product/virtual_ab_ota_compression_retrofit.mk b/target/product/virtual_ab_ota/compression_retrofit.mk similarity index 100% rename from target/product/virtual_ab_ota_compression_retrofit.mk rename to target/product/virtual_ab_ota/compression_retrofit.mk diff --git a/target/product/virtual_ab_ota.mk b/target/product/virtual_ab_ota/launch.mk similarity index 100% rename from target/product/virtual_ab_ota.mk rename to target/product/virtual_ab_ota/launch.mk diff --git a/target/product/virtual_ab_ota_plus_non_ab.mk b/target/product/virtual_ab_ota/plus_non_ab.mk similarity index 98% rename from target/product/virtual_ab_ota_plus_non_ab.mk rename to target/product/virtual_ab_ota/plus_non_ab.mk index 99a10ed9c3..820fa1ebe7 100644 --- a/target/product/virtual_ab_ota_plus_non_ab.mk +++ b/target/product/virtual_ab_ota/plus_non_ab.mk @@ -14,7 +14,7 @@ # limitations under the License. # -$(call inherit-product, $(SRC_TARGET_DIR)/product/virtual_ab_ota.mk) +$(call inherit-product, $(SRC_TARGET_DIR)/product/virtual_ab_ota/launch.mk) PRODUCT_OTA_FORCE_NON_AB_PACKAGE := true diff --git a/target/product/virtual_ab_ota_retrofit.mk b/target/product/virtual_ab_ota/retrofit.mk similarity index 98% rename from target/product/virtual_ab_ota_retrofit.mk rename to target/product/virtual_ab_ota/retrofit.mk index 3416a4fd81..93b42b7acb 100644 --- a/target/product/virtual_ab_ota_retrofit.mk +++ b/target/product/virtual_ab_ota/retrofit.mk @@ -14,7 +14,7 @@ # limitations under the License. # -$(call inherit-product, $(SRC_TARGET_DIR)/product/virtual_ab_ota.mk) +$(call inherit-product, $(SRC_TARGET_DIR)/product/virtual_ab_ota/launch.mk) PRODUCT_VIRTUAL_AB_OTA_RETROFIT := true From 942987d116983a5991207e8c55a6ec99af41f763 Mon Sep 17 00:00:00 2001 From: Yifan Hong Date: Fri, 20 Nov 2020 11:59:50 -0800 Subject: [PATCH 2/2] Add symlinks to legacy Virtual A/B makefiles. For Virtual A/B makefiles that is created before S, add symlinks so that existing devices don't break. Test: pass Change-Id: Ie04c4a8a2375edc673a8a7a2adcd162b21178f68 --- target/product/virtual_ab_ota.mk | 1 + target/product/virtual_ab_ota_plus_non_ab.mk | 1 + target/product/virtual_ab_ota_retrofit.mk | 1 + 3 files changed, 3 insertions(+) create mode 120000 target/product/virtual_ab_ota.mk create mode 120000 target/product/virtual_ab_ota_plus_non_ab.mk create mode 120000 target/product/virtual_ab_ota_retrofit.mk diff --git a/target/product/virtual_ab_ota.mk b/target/product/virtual_ab_ota.mk new file mode 120000 index 0000000000..16f73290b9 --- /dev/null +++ b/target/product/virtual_ab_ota.mk @@ -0,0 +1 @@ +virtual_ab_ota/launch.mk \ No newline at end of file diff --git a/target/product/virtual_ab_ota_plus_non_ab.mk b/target/product/virtual_ab_ota_plus_non_ab.mk new file mode 120000 index 0000000000..4979957cc4 --- /dev/null +++ b/target/product/virtual_ab_ota_plus_non_ab.mk @@ -0,0 +1 @@ +virtual_ab_ota/plus_non_ab.mk \ No newline at end of file diff --git a/target/product/virtual_ab_ota_retrofit.mk b/target/product/virtual_ab_ota_retrofit.mk new file mode 120000 index 0000000000..1e16ca8b62 --- /dev/null +++ b/target/product/virtual_ab_ota_retrofit.mk @@ -0,0 +1 @@ +virtual_ab_ota/retrofit.mk \ No newline at end of file