blob: 875dbabed6c6382f4749dbb4090db39c63be9378 [file] [log] [blame]
Yu Liu6a7940c2023-05-09 17:12:22 -07001// Copyright 2023 Google Inc. All rights reserved.
2//
3// Licensed under the Apache License, Version 2.0 (the "License");
4// you may not use this file except in compliance with the License.
5// You may obtain a copy of the License at
6//
7// http://www.apache.org/licenses/LICENSE-2.0
8//
9// Unless required by applicable law or agreed to in writing, software
10// distributed under the License is distributed on an "AS IS" BASIS,
11// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12// See the License for the specific language governing permissions and
13// limitations under the License.
14
15package genrule
16
17import (
18 "android/soong/android"
19)
20
21var (
22 DepfileAllowList = []string{
23 "depfile_allowed_for_test",
24 "tflite_support_spm_config",
25 "tflite_support_spm_encoder_config",
26 "gen_uwb_core_proto",
27 "libtextclassifier_fbgen_utils_flatbuffers_flatbuffers_test",
28 "libtextclassifier_fbgen_utils_lua_utils_tests",
29 "libtextclassifier_fbgen_lang_id_common_flatbuffers_model",
30 "libtextclassifier_fbgen_lang_id_common_flatbuffers_embedding-network",
31 "libtextclassifier_fbgen_annotator_datetime_datetime",
32 "libtextclassifier_fbgen_annotator_model",
33 "libtextclassifier_fbgen_annotator_experimental_experimental",
34 "libtextclassifier_fbgen_annotator_entity-data",
35 "libtextclassifier_fbgen_annotator_person_name_person_name_model",
36 "libtextclassifier_fbgen_utils_tflite_text_encoder_config",
37 "libtextclassifier_fbgen_utils_codepoint-range",
38 "libtextclassifier_fbgen_utils_intents_intent-config",
39 "libtextclassifier_fbgen_utils_flatbuffers_flatbuffers",
40 "libtextclassifier_fbgen_utils_zlib_buffer",
41 "libtextclassifier_fbgen_utils_tokenizer",
42 "libtextclassifier_fbgen_utils_grammar_rules",
43 "libtextclassifier_fbgen_utils_grammar_semantics_expression",
44 "libtextclassifier_fbgen_utils_resources",
45 "libtextclassifier_fbgen_utils_i18n_language-tag",
46 "libtextclassifier_fbgen_utils_normalization",
47 "libtextclassifier_fbgen_utils_container_bit-vector",
48 "libtextclassifier_fbgen_actions_actions-entity-data",
49 "libtextclassifier_fbgen_actions_actions_model",
50 "libtextclassifier_fbgen_utils_grammar_testing_value",
51 }
52
53 SandboxingDenyModuleList = []string{
54 "framework-javastream-protos",
55 "RsBalls-rscript",
56 "CtsRsBlasTestCases-rscript",
57 "pvmfw_fdt_template_rs",
58 "RSTest_v14-rscript",
59 "com.android.apex.test.bar_stripped",
60 "com.android.apex.test.sharedlibs_secondary_generated",
61 "ImageProcessingJB-rscript",
62 "RSTest-rscript",
63 "BluetoothGeneratedDumpsysBinarySchema_bfbs",
64 "WmediumdServerProto_h",
65 "TracingVMProtoStub_h",
66 "FrontendStub_h",
67 "VehicleServerProtoStub_cc",
68 "AudioFocusControlProtoStub_cc",
69 "AudioFocusControlProtoStub_h",
70 "TracingVMProtoStub_cc",
71 "VehicleServerProtoStub_h",
72 "hidl2aidl_translate_cpp_test_gen_headers",
73 "hidl2aidl_translate_cpp_test_gen_src",
74 "hidl2aidl_translate_java_test_gen_src",
75 "hidl2aidl_translate_ndk_test_gen_headers",
76 "hidl2aidl_translate_ndk_test_gen_src",
77 "hidl_hash_test_gen",
78 "nos_app_avb_service_genc++",
79 "nos_app_avb_service_genc++_headers",
80 "nos_app_avb_service_genc++_mock",
81 "nos_app_identity_service_genc++",
82 "nos_app_keymaster_service_genc++",
83 "nos_generator_test_service_genc++_headers",
84 "nos_generator_test_service_genc++_mock",
85 "r8retrace-run-retrace",
86 "ltp_config_arm",
87 "ltp_config_arm_64_hwasan",
88 "ltp_config_arm_lowmem",
89 "ltp_config_arm_64",
90 "ltp_config_riscv_64",
91 "ltp_config_x86_64",
92 "vm-tests-tf-lib",
93 "hidl_cpp_impl_test_gen-headers",
94 "pandora_experimental-python-gen-src",
95 "framework-cppstream-protos",
96 "Refocus-rscript",
97 "RSTest_v11-rscript",
98 "RSTest_v16-rscript",
99 "ScriptGroupTest-rscript",
100 "ImageProcessing2-rscript",
101 "ImageProcessing-rscript",
102 "com.android.apex.test.pony_stripped",
103 "com.android.apex.test.baz_stripped",
104 "com.android.apex.test.foo_stripped",
105 "com.android.apex.test.sharedlibs_generated",
106 "CtsRenderscriptTestCases-rscript",
107 "BlueberryFacadeAndCertGeneratedStub_py",
108 "BlueberryFacadeGeneratedStub_cc",
109 "BlueberryFacadeGeneratedStub_h",
110 "BluetoothGeneratedDumpsysDataSchema_h",
111 "FrontendStub_cc",
112 "OpenwrtControlServerProto_cc",
113 "OpenwrtControlServerProto_h",
114 "WmediumdServerProto_cc",
115 "c2hal_test_genc++",
116 "c2hal_test_genc++_headers",
117 "hidl2aidl_test_gen_aidl",
118 "hidl_error_test_gen",
119 "hidl_export_test_gen-headers",
120 "hidl_format_test_diff",
121 "hidl_hash_version_gen",
122 "libbt_topshim_facade_py_proto",
123 "nos_app_identity_service_genc++_headers",
124 "nos_app_identity_service_genc++_mock",
125 "nos_app_keymaster_service_genc++_headers",
126 "nos_app_keymaster_service_genc++_mock",
127 "nos_app_weaver_service_genc++",
128 "nos_app_weaver_service_genc++_headers",
129 "nos_app_weaver_service_genc++_mock",
130 "nos_generator_test_service_genc++",
131 "pandora-python-gen-src",
132 }
133
134 SandboxingDenyPathList = []string{
135 "art/test",
136 "external/perfetto",
137 }
138)
139var DepfileAllowSet = map[string]bool{}
140var SandboxingDenyModuleSet = map[string]bool{}
141var SandboxingDenyPathSet = map[string]bool{}
142
143func init() {
144 android.AddToStringSet(DepfileAllowSet, DepfileAllowList)
145 android.AddToStringSet(SandboxingDenyModuleSet, append(DepfileAllowList, SandboxingDenyModuleList...))
146 android.AddToStringSet(SandboxingDenyPathSet, SandboxingDenyPathList)
147}