1# Copyright (c) 2021-2024 Huawei Device Co., Ltd. 2# Licensed under the Apache License, Version 2.0 (the "License"); 3# you may not use this file except in compliance with the License. 4# You may obtain a copy of the License at 5# 6# http://www.apache.org/licenses/LICENSE-2.0 7# 8# Unless required by applicable law or agreed to in writing, software 9# distributed under the License is distributed on an "AS IS" BASIS, 10# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 11# See the License for the specific language governing permissions and 12# limitations under the License. 13 14VENDOR_CONFIG_PATH = rebase_path( 15 "//vendor/${product_company}/${product_name}/foundation/bundlemanager/bundle_framework/appexecfwk_impl.gni") 16CMD = "if [ -f ${VENDOR_CONFIG_PATH} ]; then echo true; else echo false; fi" 17 18vendor_config_exist = 19 exec_script("//build/lite/run_shell_cmd.py", [ CMD ], "value") 20if (vendor_config_exist) { 21 import( 22 "//vendor/${product_company}/${product_name}/foundation/bundlemanager/bundle_framework/appexecfwk_impl.gni") 23} else { 24 bundle_mgr_impl_sources = [] 25 bundle_mgr_impl_include_dirs = [] 26} 27 28bundle_framework_path = "//foundation/bundlemanager/bundle_framework" 29ecological_rule_mgr_path = "//foundation/bundlemanager/ecological_rule_mgr/interfaces/innerkits/include" 30common_path = "${bundle_framework_path}/common" 31fuzz_test_path = "bundle_framework/bundle_framework" 32services_path = "${bundle_framework_path}/services" 33kits_path = "${bundle_framework_path}/interfaces/kits" 34inner_api_path = "${bundle_framework_path}/interfaces/inner_api" 35tools_path = "${bundle_framework_path}/tools" 36base_path = "${bundle_framework_path}/interfaces/inner_api/appexecfwk_base" 37core_path = "${bundle_framework_path}/interfaces/inner_api/appexecfwk_core" 38extension_path = 39 "${bundle_framework_path}/interfaces/inner_api/bundlemgr_extension" 40 41declare_args() { 42 bundle_framework_power_mgr_enable = true 43 bundle_framework_graphics = true 44 bundle_framework_free_install = true 45 bundle_framework_default_app = true 46 bundle_framework_launcher = true 47 bundle_framework_sandbox_app = true 48 bundle_framework_quick_fix = true 49 bundle_framework_app_control = true 50 distributed_bundle_framework = true 51 bundle_framework_overlay_install = true 52 bundle_framework_bundle_resource = true 53 bundle_framework_form_dimension_2_3 = false 54 bundle_framework_form_dimension_3_3 = false 55 56 ability_runtime_enable = true 57 account_enable = true 58 configpolicy_enable = true 59 global_resmgr_enable = true 60 global_i18n_enable = true 61 hicollie_enable = true 62 hisysevent_enable = true 63 storage_service_enable = true 64 use_pre_bundle_profile = true 65 window_enable = true 66 dlp_permission_enable = true 67 code_signature_enable = true 68 code_encryption_enable = true 69 verify_abc_enabled = true 70 check_eldir_enabled = true 71 udmf_enabled = true 72 bms_device_info_manager_part_enabled = true 73 app_domain_verify_enabled = true 74 device_usage_statistics_enabled = true 75 dfx_sigdump_handler_enabled = true 76 webview_enable = true 77 user_auth_framework_impl_enabled = true 78 79 if (defined(global_parts_info) && 80 !defined(global_parts_info.resourceschedule_device_usage_statistics)) { 81 device_usage_statistics_enabled = false 82 bundle_framework_free_install = false 83 } 84 85 if (defined(global_parts_info) && 86 !defined(global_parts_info.ability_ability_runtime)) { 87 ability_runtime_enable = false 88 bundle_framework_free_install = false 89 } 90 91 if (defined(global_parts_info) && 92 !defined(global_parts_info.account_os_account)) { 93 account_enable = false 94 bundle_framework_free_install = false 95 } 96 97 if (defined(global_parts_info) && 98 !defined(global_parts_info.bundlemanager_distributed_bundle_framework)) { 99 distributed_bundle_framework = false 100 } 101 102 if (defined(global_parts_info) && 103 !defined(global_parts_info.customization_config_policy)) { 104 configpolicy_enable = false 105 } 106 107 if (defined(global_parts_info) && 108 !defined(global_parts_info.global_resource_management)) { 109 global_resmgr_enable = false 110 bundle_framework_bundle_resource = false 111 } 112 113 if (defined(global_parts_info) && !defined(global_parts_info.global_i18n)) { 114 global_i18n_enable = false 115 } 116 117 if (defined(global_parts_info) && 118 !defined(global_parts_info.hiviewdfx_hicollie)) { 119 hicollie_enable = false 120 } 121 122 if (defined(global_parts_info) && 123 (!defined(global_parts_info.powermgr_power_manager) || 124 !defined(global_parts_info.powermgr_battery_manager) || 125 !defined(global_parts_info.powermgr_display_manager) || 126 !defined(global_parts_info.resourceschedule_device_usage_statistics))) { 127 bundle_framework_free_install = false 128 } 129 130 if (defined(global_parts_info) && 131 (!defined(global_parts_info.powermgr_power_manager) || 132 !defined(global_parts_info.powermgr_battery_manager) || 133 !defined(global_parts_info.powermgr_display_manager))) { 134 bundle_framework_power_mgr_enable = false 135 } 136 137 if (defined(global_parts_info) && 138 !defined(global_parts_info.hiviewdfx_hisysevent)) { 139 hisysevent_enable = false 140 } 141 142 if (defined(global_parts_info) && 143 !defined(global_parts_info.window_window_manager)) { 144 window_enable = false 145 } 146 147 if (defined(global_parts_info) && 148 !defined(global_parts_info.filemanagement_storage_service)) { 149 storage_service_enable = false 150 } 151 152 if (defined(global_parts_info) && 153 !defined(global_parts_info.security_dlp_permission_service)) { 154 dlp_permission_enable = false 155 } 156 157 if (defined(global_parts_info) && 158 !defined(global_parts_info.security_code_signature)) { 159 code_signature_enable = false 160 } 161 162 if (defined(global_parts_info) && 163 !defined(global_parts_info.security_code_crypto_metadata_process)) { 164 code_encryption_enable = false 165 } 166 167 if (defined(global_parts_info) && 168 !defined(global_parts_info.multimedia_image_framework)) { 169 bundle_framework_graphics = false 170 } 171 172 if (defined(global_parts_info) && 173 !defined(global_parts_info.arkcompiler_runtime_core)) { 174 verify_abc_enabled = false 175 } 176 if (defined(global_parts_info) && 177 !defined(global_parts_info.distributeddatamgr_udmf)) { 178 udmf_enabled = false 179 } 180 181 if (defined(global_parts_info) && 182 !defined(global_parts_info.deviceprofile_device_info_manager)) { 183 bms_device_info_manager_part_enabled = false 184 } 185 186 if (defined(global_parts_info) && 187 !defined(global_parts_info.bundlemanager_app_domain_verify)) { 188 app_domain_verify_enabled = false 189 } 190 191 if (defined(global_parts_info) && 192 !defined(global_parts_info.hiviewdfx_faultloggerd)) { 193 dfx_sigdump_handler_enabled = false 194 } 195 196 if (defined(global_parts_info) && !defined(global_parts_info.web_webview)) { 197 webview_enable = false 198 } 199 200 if (defined(global_parts_info) && 201 !defined(global_parts_info.useriam_user_auth_framework)) { 202 user_auth_framework_impl_enabled = false 203 } 204} 205 206print("bundle_framework_power_mgr_enable = " + 207 "$bundle_framework_power_mgr_enable") 208print("bundle_framework_graphics = " + "$bundle_framework_graphics") 209print("bundle_framework_free_install = " + "$bundle_framework_free_install") 210print("bundle_framework_default_app = " + "$bundle_framework_default_app") 211print("bundle_framework_launcher = " + "$bundle_framework_launcher") 212print("bundle_framework_sandbox_app = " + "$bundle_framework_sandbox_app") 213print("bundle_framework_quick_fix = " + "$bundle_framework_quick_fix") 214print("bundle_framework_app_control = " + "$bundle_framework_app_control") 215print("distributed_bundle_framework = " + "$distributed_bundle_framework") 216print("ability_runtime_enable = " + "$ability_runtime_enable") 217print("account_enable = " + "$account_enable") 218print("configpolicy_enable = " + "$configpolicy_enable") 219print("global_resmgr_enable = " + "$global_resmgr_enable") 220print("hicollie_enable = " + "$hicollie_enable") 221print("support_jsapi = " + "$support_jsapi") 222print("hisysevent_enable = " + "$hisysevent_enable") 223print( 224 "bundle_framework_overlay_install = " + "$bundle_framework_overlay_install") 225print( 226 "bundle_framework_bundle_resource = " + "$bundle_framework_bundle_resource") 227print("verify_abc_enabled = " + "$verify_abc_enabled") 228print( 229 "user_auth_framework_impl_enabled = " + "$user_auth_framework_impl_enabled") 230