Split compat and contexts part in Android.bp

Because Android.bp is getting bigger and bigger.

Test: build and boot
Test: set OVERRIDE_TARGET_FLATTEN_APEX=true and build
Change-Id: I397ce084bfbc98449d177dd553ff73fdfbdddcaf
diff --git a/Android.bp b/Android.bp
index 0e85944..f22a1ac 100644
--- a/Android.bp
+++ b/Android.bp
@@ -149,253 +149,6 @@
     ],
 }
 
-se_cil_compat_map {
-    name: "plat_28.0.cil",
-    stem: "28.0.cil",
-    bottom_half: [":28.0.board.compat.map"],
-    top_half: "plat_29.0.cil",
-}
-
-se_cil_compat_map {
-    name: "plat_29.0.cil",
-    stem: "29.0.cil",
-    bottom_half: [":29.0.board.compat.map"],
-    top_half: "plat_30.0.cil",
-}
-
-se_cil_compat_map {
-    name: "plat_30.0.cil",
-    stem: "30.0.cil",
-    bottom_half: [":30.0.board.compat.map"],
-    top_half: "plat_31.0.cil",
-}
-
-se_cil_compat_map {
-    name: "plat_31.0.cil",
-    stem: "31.0.cil",
-    bottom_half: [":31.0.board.compat.map"],
-    top_half: "plat_32.0.cil",
-}
-
-se_cil_compat_map {
-    name: "plat_32.0.cil",
-    stem: "32.0.cil",
-    bottom_half: [":32.0.board.compat.map"],
-    // top_half: "plat_33.0.cil",
-}
-
-se_cil_compat_map {
-    name: "system_ext_28.0.cil",
-    stem: "28.0.cil",
-    bottom_half: [":28.0.board.compat.map"],
-    top_half: "system_ext_29.0.cil",
-    system_ext_specific: true,
-}
-
-se_cil_compat_map {
-    name: "system_ext_29.0.cil",
-    stem: "29.0.cil",
-    bottom_half: [":29.0.board.compat.map"],
-    top_half: "system_ext_30.0.cil",
-    system_ext_specific: true,
-}
-
-se_cil_compat_map {
-    name: "system_ext_30.0.cil",
-    stem: "30.0.cil",
-    bottom_half: [":30.0.board.compat.map"],
-    top_half: "system_ext_31.0.cil",
-    system_ext_specific: true,
-}
-
-se_cil_compat_map {
-    name: "system_ext_31.0.cil",
-    stem: "31.0.cil",
-    bottom_half: [":31.0.board.compat.map"],
-    top_half: "system_ext_32.0.cil",
-    system_ext_specific: true,
-}
-
-se_cil_compat_map {
-    name: "system_ext_32.0.cil",
-    stem: "32.0.cil",
-    bottom_half: [":32.0.board.compat.map"],
-    // top_half: "system_ext_33.0.cil",
-    system_ext_specific: true,
-}
-
-se_cil_compat_map {
-    name: "product_28.0.cil",
-    stem: "28.0.cil",
-    bottom_half: [":28.0.board.compat.map"],
-    top_half: "product_29.0.cil",
-    product_specific: true,
-}
-
-se_cil_compat_map {
-    name: "product_29.0.cil",
-    stem: "29.0.cil",
-    bottom_half: [":29.0.board.compat.map"],
-    top_half: "product_30.0.cil",
-    product_specific: true,
-}
-
-se_cil_compat_map {
-    name: "product_30.0.cil",
-    stem: "30.0.cil",
-    bottom_half: [":30.0.board.compat.map"],
-    top_half: "product_31.0.cil",
-    product_specific: true,
-}
-
-se_cil_compat_map {
-    name: "product_31.0.cil",
-    stem: "31.0.cil",
-    bottom_half: [":31.0.board.compat.map"],
-    top_half: "product_32.0.cil",
-    product_specific: true,
-}
-
-se_cil_compat_map {
-    name: "product_32.0.cil",
-    stem: "32.0.cil",
-    bottom_half: [":32.0.board.compat.map"],
-    // top_half: "product_33.0.cil",
-    product_specific: true,
-}
-
-se_cil_compat_map {
-    name: "28.0.ignore.cil",
-    bottom_half: [":28.0.board.ignore.map"],
-    top_half: "29.0.ignore.cil",
-}
-
-se_cil_compat_map {
-    name: "29.0.ignore.cil",
-    bottom_half: [":29.0.board.ignore.map"],
-    top_half: "30.0.ignore.cil",
-}
-
-se_cil_compat_map {
-    name: "30.0.ignore.cil",
-    bottom_half: [":30.0.board.ignore.map"],
-    top_half: "31.0.ignore.cil",
-}
-
-se_cil_compat_map {
-    name: "31.0.ignore.cil",
-    bottom_half: [":31.0.board.ignore.map"],
-    top_half: "32.0.ignore.cil",
-}
-
-se_cil_compat_map {
-    name: "32.0.ignore.cil",
-    bottom_half: [":32.0.board.ignore.map"],
-    // top_half: "33.0.ignore.cil",
-}
-
-se_cil_compat_map {
-    name: "system_ext_30.0.ignore.cil",
-    bottom_half: [":30.0.board.ignore.map"],
-    top_half: "system_ext_31.0.ignore.cil",
-    system_ext_specific: true,
-}
-
-se_cil_compat_map {
-    name: "system_ext_31.0.ignore.cil",
-    bottom_half: [":31.0.board.ignore.map"],
-    top_half: "system_ext_32.0.ignore.cil",
-    system_ext_specific: true,
-}
-
-se_cil_compat_map {
-    name: "system_ext_32.0.ignore.cil",
-    bottom_half: [":32.0.board.ignore.map"],
-    // top_half: "system_ext_33.0.ignore.cil",
-    system_ext_specific: true,
-}
-
-se_cil_compat_map {
-    name: "product_30.0.ignore.cil",
-    bottom_half: [":30.0.board.ignore.map"],
-    top_half: "product_31.0.ignore.cil",
-    product_specific: true,
-}
-
-se_cil_compat_map {
-    name: "product_31.0.ignore.cil",
-    bottom_half: [":31.0.board.ignore.map"],
-    top_half: "product_32.0.ignore.cil",
-    product_specific: true,
-}
-
-se_cil_compat_map {
-    name: "product_32.0.ignore.cil",
-    bottom_half: [":32.0.board.ignore.map"],
-    // top_half: "product_33.0.ignore.cil",
-    product_specific: true,
-}
-
-se_compat_cil {
-    name: "28.0.compat.cil",
-    srcs: [":28.0.board.compat.cil"],
-}
-
-se_compat_cil {
-    name: "29.0.compat.cil",
-    srcs: [":29.0.board.compat.cil"],
-}
-
-se_compat_cil {
-    name: "30.0.compat.cil",
-    srcs: [":30.0.board.compat.cil"],
-}
-
-se_compat_cil {
-    name: "31.0.compat.cil",
-    srcs: [":31.0.board.compat.cil"],
-}
-
-se_compat_cil {
-    name: "32.0.compat.cil",
-    srcs: [":32.0.board.compat.cil"],
-}
-
-se_compat_cil {
-    name: "system_ext_28.0.compat.cil",
-    srcs: [":28.0.board.compat.cil"],
-    stem: "28.0.compat.cil",
-    system_ext_specific: true,
-}
-
-se_compat_cil {
-    name: "system_ext_29.0.compat.cil",
-    srcs: [":29.0.board.compat.cil"],
-    stem: "29.0.compat.cil",
-    system_ext_specific: true,
-}
-
-se_compat_cil {
-    name: "system_ext_30.0.compat.cil",
-    srcs: [":30.0.board.compat.cil"],
-    stem: "30.0.compat.cil",
-    system_ext_specific: true,
-}
-
-se_compat_cil {
-    name: "system_ext_31.0.compat.cil",
-    srcs: [":31.0.board.compat.cil"],
-    stem: "31.0.compat.cil",
-    system_ext_specific: true,
-}
-
-se_compat_cil {
-    name: "system_ext_32.0.compat.cil",
-    srcs: [":32.0.board.compat.cil"],
-    stem: "32.0.compat.cil",
-    system_ext_specific: true,
-}
-
 se_build_files {
     name: "file_contexts_files",
     srcs: ["file_contexts"],
@@ -431,215 +184,6 @@
     srcs: ["keystore2_key_contexts"],
 }
 
-file_contexts {
-    name: "plat_file_contexts",
-    srcs: [":file_contexts_files{.plat_private}"],
-    product_variables: {
-        address_sanitize: {
-            srcs: [":file_contexts_asan_files{.plat_private}"],
-        },
-        debuggable: {
-            srcs: [":file_contexts_overlayfs_files{.plat_private}"],
-        },
-    },
-
-    flatten_apex: {
-        srcs: [":apex_file_contexts_files"],
-    },
-}
-
-file_contexts {
-    name: "plat_file_contexts.recovery",
-    srcs: [":file_contexts_files{.plat_private}"],
-    stem: "plat_file_contexts",
-    product_variables: {
-        address_sanitize: {
-            srcs: [":file_contexts_asan_files{.plat_private}"],
-        },
-        debuggable: {
-            srcs: [":file_contexts_overlayfs_files{.plat_private}"],
-        },
-    },
-
-    flatten_apex: {
-        srcs: [":apex_file_contexts_files"],
-    },
-
-    recovery: true,
-}
-
-file_contexts {
-    name: "vendor_file_contexts",
-    srcs: [
-        ":file_contexts_files{.plat_vendor_for_vendor}",
-        ":file_contexts_files{.vendor}",
-    ],
-    soc_specific: true,
-    recovery_available: true,
-}
-
-file_contexts {
-    name: "system_ext_file_contexts",
-    srcs: [":file_contexts_files{.system_ext_private}"],
-    system_ext_specific: true,
-    recovery_available: true,
-}
-
-file_contexts {
-    name: "product_file_contexts",
-    srcs: [":file_contexts_files{.product_private}"],
-    product_specific: true,
-    recovery_available: true,
-}
-
-file_contexts {
-    name: "odm_file_contexts",
-    srcs: [":file_contexts_files{.odm}"],
-    device_specific: true,
-    recovery_available: true,
-}
-
-hwservice_contexts {
-    name: "plat_hwservice_contexts",
-    srcs: [":hwservice_contexts_files{.plat_private}"],
-}
-
-hwservice_contexts {
-    name: "system_ext_hwservice_contexts",
-    srcs: [":hwservice_contexts_files{.system_ext_private}"],
-    system_ext_specific: true,
-}
-
-hwservice_contexts {
-    name: "product_hwservice_contexts",
-    srcs: [":hwservice_contexts_files{.product_private}"],
-    product_specific: true,
-}
-
-hwservice_contexts {
-    name: "vendor_hwservice_contexts",
-    srcs: [
-        ":hwservice_contexts_files{.plat_vendor_for_vendor}",
-        ":hwservice_contexts_files{.vendor}",
-        ":hwservice_contexts_files{.reqd_mask_for_vendor}",
-    ],
-    soc_specific: true,
-}
-
-hwservice_contexts {
-    name: "odm_hwservice_contexts",
-    srcs: [":hwservice_contexts_files{.odm}"],
-    device_specific: true,
-}
-
-property_contexts {
-    name: "plat_property_contexts",
-    srcs: [":property_contexts_files{.plat_private}"],
-}
-
-property_contexts {
-    name: "plat_property_contexts.recovery",
-    srcs: [":property_contexts_files{.plat_private}"],
-    stem: "plat_property_contexts",
-    recovery: true,
-}
-
-property_contexts {
-    name: "system_ext_property_contexts",
-    srcs: [":property_contexts_files{.system_ext_private}"],
-    system_ext_specific: true,
-    recovery_available: true,
-}
-
-property_contexts {
-    name: "product_property_contexts",
-    srcs: [":property_contexts_files{.product_private}"],
-    product_specific: true,
-    recovery_available: true,
-}
-
-property_contexts {
-    name: "vendor_property_contexts",
-    srcs: [
-        ":property_contexts_files{.plat_vendor_for_vendor}",
-        ":property_contexts_files{.vendor}",
-        ":property_contexts_files{.reqd_mask_for_vendor}",
-    ],
-    soc_specific: true,
-    recovery_available: true,
-}
-
-property_contexts {
-    name: "odm_property_contexts",
-    srcs: [":property_contexts_files{.odm}"],
-    device_specific: true,
-    recovery_available: true,
-}
-
-service_contexts {
-    name: "plat_service_contexts",
-    srcs: [":service_contexts_files{.plat_private}"],
-}
-
-service_contexts {
-    name: "plat_service_contexts.recovery",
-    srcs: [":service_contexts_files{.plat_private}"],
-    stem: "plat_service_contexts",
-    recovery: true,
-}
-
-service_contexts {
-    name: "system_ext_service_contexts",
-    srcs: [":service_contexts_files{.system_ext_private}"],
-    system_ext_specific: true,
-    recovery_available: true,
-}
-
-service_contexts {
-    name: "product_service_contexts",
-    srcs: [":service_contexts_files{.product_private}"],
-    product_specific: true,
-    recovery_available: true,
-}
-
-service_contexts {
-    name: "vendor_service_contexts",
-    srcs: [
-        ":service_contexts_files{.plat_vendor_for_vendor}",
-        ":service_contexts_files{.vendor}",
-        ":service_contexts_files{.reqd_mask_for_vendor}",
-    ],
-    soc_specific: true,
-    recovery_available: true,
-}
-
-keystore2_key_contexts {
-    name: "plat_keystore2_key_contexts",
-    srcs: [":keystore2_key_contexts_files{.plat_private}"],
-}
-
-keystore2_key_contexts {
-    name: "system_keystore2_key_contexts",
-    srcs: [":keystore2_key_contexts_files{.system_ext_private}"],
-    system_ext_specific: true,
-}
-
-keystore2_key_contexts {
-    name: "product_keystore2_key_contexts",
-    srcs: [":keystore2_key_contexts_files{.product_private}"],
-    product_specific: true,
-}
-
-keystore2_key_contexts {
-    name: "vendor_keystore2_key_contexts",
-    srcs: [
-        ":keystore2_key_contexts_files{.plat_vendor_for_vendor}",
-        ":keystore2_key_contexts_files{.vendor}",
-        ":keystore2_key_contexts_files{.reqd_mask_for_vendor}",
-    ],
-    soc_specific: true,
-}
-
 // For vts_treble_sys_prop_test
 filegroup {
     name: "private_property_contexts",
diff --git a/compat/Android.bp b/compat/Android.bp
new file mode 100644
index 0000000..715e4b3
--- /dev/null
+++ b/compat/Android.bp
@@ -0,0 +1,262 @@
+// Copyright (C) 2021 The Android Open Source Project
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+// This file contains module definitions for compatibility files.
+
+se_cil_compat_map {
+    name: "plat_28.0.cil",
+    stem: "28.0.cil",
+    bottom_half: [":28.0.board.compat.map"],
+    top_half: "plat_29.0.cil",
+}
+
+se_cil_compat_map {
+    name: "plat_29.0.cil",
+    stem: "29.0.cil",
+    bottom_half: [":29.0.board.compat.map"],
+    top_half: "plat_30.0.cil",
+}
+
+se_cil_compat_map {
+    name: "plat_30.0.cil",
+    stem: "30.0.cil",
+    bottom_half: [":30.0.board.compat.map"],
+    top_half: "plat_31.0.cil",
+}
+
+se_cil_compat_map {
+    name: "plat_31.0.cil",
+    stem: "31.0.cil",
+    bottom_half: [":31.0.board.compat.map"],
+    top_half: "plat_32.0.cil",
+}
+
+se_cil_compat_map {
+    name: "plat_32.0.cil",
+    stem: "32.0.cil",
+    bottom_half: [":32.0.board.compat.map"],
+    // top_half: "plat_33.0.cil",
+}
+
+se_cil_compat_map {
+    name: "system_ext_28.0.cil",
+    stem: "28.0.cil",
+    bottom_half: [":28.0.board.compat.map"],
+    top_half: "system_ext_29.0.cil",
+    system_ext_specific: true,
+}
+
+se_cil_compat_map {
+    name: "system_ext_29.0.cil",
+    stem: "29.0.cil",
+    bottom_half: [":29.0.board.compat.map"],
+    top_half: "system_ext_30.0.cil",
+    system_ext_specific: true,
+}
+
+se_cil_compat_map {
+    name: "system_ext_30.0.cil",
+    stem: "30.0.cil",
+    bottom_half: [":30.0.board.compat.map"],
+    top_half: "system_ext_31.0.cil",
+    system_ext_specific: true,
+}
+
+se_cil_compat_map {
+    name: "system_ext_31.0.cil",
+    stem: "31.0.cil",
+    bottom_half: [":31.0.board.compat.map"],
+    top_half: "system_ext_32.0.cil",
+    system_ext_specific: true,
+}
+
+se_cil_compat_map {
+    name: "system_ext_32.0.cil",
+    stem: "32.0.cil",
+    bottom_half: [":32.0.board.compat.map"],
+    // top_half: "system_ext_33.0.cil",
+    system_ext_specific: true,
+}
+
+se_cil_compat_map {
+    name: "product_28.0.cil",
+    stem: "28.0.cil",
+    bottom_half: [":28.0.board.compat.map"],
+    top_half: "product_29.0.cil",
+    product_specific: true,
+}
+
+se_cil_compat_map {
+    name: "product_29.0.cil",
+    stem: "29.0.cil",
+    bottom_half: [":29.0.board.compat.map"],
+    top_half: "product_30.0.cil",
+    product_specific: true,
+}
+
+se_cil_compat_map {
+    name: "product_30.0.cil",
+    stem: "30.0.cil",
+    bottom_half: [":30.0.board.compat.map"],
+    top_half: "product_31.0.cil",
+    product_specific: true,
+}
+
+se_cil_compat_map {
+    name: "product_31.0.cil",
+    stem: "31.0.cil",
+    bottom_half: [":31.0.board.compat.map"],
+    top_half: "product_32.0.cil",
+    product_specific: true,
+}
+
+se_cil_compat_map {
+    name: "product_32.0.cil",
+    stem: "32.0.cil",
+    bottom_half: [":32.0.board.compat.map"],
+    // top_half: "product_33.0.cil",
+    product_specific: true,
+}
+
+se_cil_compat_map {
+    name: "28.0.ignore.cil",
+    bottom_half: [":28.0.board.ignore.map"],
+    top_half: "29.0.ignore.cil",
+}
+
+se_cil_compat_map {
+    name: "29.0.ignore.cil",
+    bottom_half: [":29.0.board.ignore.map"],
+    top_half: "30.0.ignore.cil",
+}
+
+se_cil_compat_map {
+    name: "30.0.ignore.cil",
+    bottom_half: [":30.0.board.ignore.map"],
+    top_half: "31.0.ignore.cil",
+}
+
+se_cil_compat_map {
+    name: "31.0.ignore.cil",
+    bottom_half: [":31.0.board.ignore.map"],
+    top_half: "32.0.ignore.cil",
+}
+
+se_cil_compat_map {
+    name: "32.0.ignore.cil",
+    bottom_half: [":32.0.board.ignore.map"],
+    // top_half: "33.0.ignore.cil",
+}
+
+se_cil_compat_map {
+    name: "system_ext_30.0.ignore.cil",
+    bottom_half: [":30.0.board.ignore.map"],
+    top_half: "system_ext_31.0.ignore.cil",
+    system_ext_specific: true,
+}
+
+se_cil_compat_map {
+    name: "system_ext_31.0.ignore.cil",
+    bottom_half: [":31.0.board.ignore.map"],
+    top_half: "system_ext_32.0.ignore.cil",
+    system_ext_specific: true,
+}
+
+se_cil_compat_map {
+    name: "system_ext_32.0.ignore.cil",
+    bottom_half: [":32.0.board.ignore.map"],
+    // top_half: "system_ext_33.0.ignore.cil",
+    system_ext_specific: true,
+}
+
+se_cil_compat_map {
+    name: "product_30.0.ignore.cil",
+    bottom_half: [":30.0.board.ignore.map"],
+    top_half: "product_31.0.ignore.cil",
+    product_specific: true,
+}
+
+se_cil_compat_map {
+    name: "product_31.0.ignore.cil",
+    bottom_half: [":31.0.board.ignore.map"],
+    top_half: "product_32.0.ignore.cil",
+    product_specific: true,
+}
+
+se_cil_compat_map {
+    name: "product_32.0.ignore.cil",
+    bottom_half: [":32.0.board.ignore.map"],
+    // top_half: "product_33.0.ignore.cil",
+    product_specific: true,
+}
+
+se_compat_cil {
+    name: "28.0.compat.cil",
+    srcs: [":28.0.board.compat.cil"],
+}
+
+se_compat_cil {
+    name: "29.0.compat.cil",
+    srcs: [":29.0.board.compat.cil"],
+}
+
+se_compat_cil {
+    name: "30.0.compat.cil",
+    srcs: [":30.0.board.compat.cil"],
+}
+
+se_compat_cil {
+    name: "31.0.compat.cil",
+    srcs: [":31.0.board.compat.cil"],
+}
+
+se_compat_cil {
+    name: "32.0.compat.cil",
+    srcs: [":32.0.board.compat.cil"],
+}
+
+se_compat_cil {
+    name: "system_ext_28.0.compat.cil",
+    srcs: [":28.0.board.compat.cil"],
+    stem: "28.0.compat.cil",
+    system_ext_specific: true,
+}
+
+se_compat_cil {
+    name: "system_ext_29.0.compat.cil",
+    srcs: [":29.0.board.compat.cil"],
+    stem: "29.0.compat.cil",
+    system_ext_specific: true,
+}
+
+se_compat_cil {
+    name: "system_ext_30.0.compat.cil",
+    srcs: [":30.0.board.compat.cil"],
+    stem: "30.0.compat.cil",
+    system_ext_specific: true,
+}
+
+se_compat_cil {
+    name: "system_ext_31.0.compat.cil",
+    srcs: [":31.0.board.compat.cil"],
+    stem: "31.0.compat.cil",
+    system_ext_specific: true,
+}
+
+se_compat_cil {
+    name: "system_ext_32.0.compat.cil",
+    srcs: [":32.0.board.compat.cil"],
+    stem: "32.0.compat.cil",
+    system_ext_specific: true,
+}
diff --git a/contexts/Android.bp b/contexts/Android.bp
new file mode 100644
index 0000000..ed98683
--- /dev/null
+++ b/contexts/Android.bp
@@ -0,0 +1,224 @@
+// Copyright (C) 2021 The Android Open Source Project
+//
+// Licensed under the Apache License, Version 2.0 (the "License");
+// you may not use this file except in compliance with the License.
+// You may obtain a copy of the License at
+//
+//     http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing, software
+// distributed under the License is distributed on an "AS IS" BASIS,
+// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+// See the License for the specific language governing permissions and
+// limitations under the License.
+
+// This file contains module definitions for various contexts files.
+
+file_contexts {
+    name: "plat_file_contexts",
+    srcs: [":file_contexts_files{.plat_private}"],
+    product_variables: {
+        address_sanitize: {
+            srcs: [":file_contexts_asan_files{.plat_private}"],
+        },
+        debuggable: {
+            srcs: [":file_contexts_overlayfs_files{.plat_private}"],
+        },
+    },
+
+    flatten_apex: {
+        srcs: [":apex_file_contexts_files"],
+    },
+}
+
+file_contexts {
+    name: "plat_file_contexts.recovery",
+    srcs: [":file_contexts_files{.plat_private}"],
+    stem: "plat_file_contexts",
+    product_variables: {
+        address_sanitize: {
+            srcs: [":file_contexts_asan_files{.plat_private}"],
+        },
+        debuggable: {
+            srcs: [":file_contexts_overlayfs_files{.plat_private}"],
+        },
+    },
+
+    flatten_apex: {
+        srcs: [":apex_file_contexts_files"],
+    },
+
+    recovery: true,
+}
+
+file_contexts {
+    name: "vendor_file_contexts",
+    srcs: [
+        ":file_contexts_files{.plat_vendor_for_vendor}",
+        ":file_contexts_files{.vendor}",
+    ],
+    soc_specific: true,
+    recovery_available: true,
+}
+
+file_contexts {
+    name: "system_ext_file_contexts",
+    srcs: [":file_contexts_files{.system_ext_private}"],
+    system_ext_specific: true,
+    recovery_available: true,
+}
+
+file_contexts {
+    name: "product_file_contexts",
+    srcs: [":file_contexts_files{.product_private}"],
+    product_specific: true,
+    recovery_available: true,
+}
+
+file_contexts {
+    name: "odm_file_contexts",
+    srcs: [":file_contexts_files{.odm}"],
+    device_specific: true,
+    recovery_available: true,
+}
+
+hwservice_contexts {
+    name: "plat_hwservice_contexts",
+    srcs: [":hwservice_contexts_files{.plat_private}"],
+}
+
+hwservice_contexts {
+    name: "system_ext_hwservice_contexts",
+    srcs: [":hwservice_contexts_files{.system_ext_private}"],
+    system_ext_specific: true,
+}
+
+hwservice_contexts {
+    name: "product_hwservice_contexts",
+    srcs: [":hwservice_contexts_files{.product_private}"],
+    product_specific: true,
+}
+
+hwservice_contexts {
+    name: "vendor_hwservice_contexts",
+    srcs: [
+        ":hwservice_contexts_files{.plat_vendor_for_vendor}",
+        ":hwservice_contexts_files{.vendor}",
+        ":hwservice_contexts_files{.reqd_mask_for_vendor}",
+    ],
+    soc_specific: true,
+}
+
+hwservice_contexts {
+    name: "odm_hwservice_contexts",
+    srcs: [":hwservice_contexts_files{.odm}"],
+    device_specific: true,
+}
+
+property_contexts {
+    name: "plat_property_contexts",
+    srcs: [":property_contexts_files{.plat_private}"],
+}
+
+property_contexts {
+    name: "plat_property_contexts.recovery",
+    srcs: [":property_contexts_files{.plat_private}"],
+    stem: "plat_property_contexts",
+    recovery: true,
+}
+
+property_contexts {
+    name: "system_ext_property_contexts",
+    srcs: [":property_contexts_files{.system_ext_private}"],
+    system_ext_specific: true,
+    recovery_available: true,
+}
+
+property_contexts {
+    name: "product_property_contexts",
+    srcs: [":property_contexts_files{.product_private}"],
+    product_specific: true,
+    recovery_available: true,
+}
+
+property_contexts {
+    name: "vendor_property_contexts",
+    srcs: [
+        ":property_contexts_files{.plat_vendor_for_vendor}",
+        ":property_contexts_files{.vendor}",
+        ":property_contexts_files{.reqd_mask_for_vendor}",
+    ],
+    soc_specific: true,
+    recovery_available: true,
+}
+
+property_contexts {
+    name: "odm_property_contexts",
+    srcs: [":property_contexts_files{.odm}"],
+    device_specific: true,
+    recovery_available: true,
+}
+
+service_contexts {
+    name: "plat_service_contexts",
+    srcs: [":service_contexts_files{.plat_private}"],
+}
+
+service_contexts {
+    name: "plat_service_contexts.recovery",
+    srcs: [":service_contexts_files{.plat_private}"],
+    stem: "plat_service_contexts",
+    recovery: true,
+}
+
+service_contexts {
+    name: "system_ext_service_contexts",
+    srcs: [":service_contexts_files{.system_ext_private}"],
+    system_ext_specific: true,
+    recovery_available: true,
+}
+
+service_contexts {
+    name: "product_service_contexts",
+    srcs: [":service_contexts_files{.product_private}"],
+    product_specific: true,
+    recovery_available: true,
+}
+
+service_contexts {
+    name: "vendor_service_contexts",
+    srcs: [
+        ":service_contexts_files{.plat_vendor_for_vendor}",
+        ":service_contexts_files{.vendor}",
+        ":service_contexts_files{.reqd_mask_for_vendor}",
+    ],
+    soc_specific: true,
+    recovery_available: true,
+}
+
+keystore2_key_contexts {
+    name: "plat_keystore2_key_contexts",
+    srcs: [":keystore2_key_contexts_files{.plat_private}"],
+}
+
+keystore2_key_contexts {
+    name: "system_keystore2_key_contexts",
+    srcs: [":keystore2_key_contexts_files{.system_ext_private}"],
+    system_ext_specific: true,
+}
+
+keystore2_key_contexts {
+    name: "product_keystore2_key_contexts",
+    srcs: [":keystore2_key_contexts_files{.product_private}"],
+    product_specific: true,
+}
+
+keystore2_key_contexts {
+    name: "vendor_keystore2_key_contexts",
+    srcs: [
+        ":keystore2_key_contexts_files{.plat_vendor_for_vendor}",
+        ":keystore2_key_contexts_files{.vendor}",
+        ":keystore2_key_contexts_files{.reqd_mask_for_vendor}",
+    ],
+    soc_specific: true,
+}