1f16e0440Sopenharmony_ci# Copyright (c) 2021 Huawei Device Co., Ltd. 2f16e0440Sopenharmony_ci# Licensed under the Apache License, Version 2.0 (the "License"); 3f16e0440Sopenharmony_ci# you may not use this file except in compliance with the License. 4f16e0440Sopenharmony_ci# You may obtain a copy of the License at 5f16e0440Sopenharmony_ci# 6f16e0440Sopenharmony_ci# http://www.apache.org/licenses/LICENSE-2.0 7f16e0440Sopenharmony_ci# 8f16e0440Sopenharmony_ci# Unless required by applicable law or agreed to in writing, software 9f16e0440Sopenharmony_ci# distributed under the License is distributed on an "AS IS" BASIS, 10f16e0440Sopenharmony_ci# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 11f16e0440Sopenharmony_ci# See the License for the specific language governing permissions and 12f16e0440Sopenharmony_ci# limitations under the License. 13f16e0440Sopenharmony_ci 14f16e0440Sopenharmony_ciimport("//build/ohos.gni") 15f16e0440Sopenharmony_ci 16f16e0440Sopenharmony_cideclare_args() { 17f16e0440Sopenharmony_ci battery_manager_feature_set_low_capacity_threshold = false 18f16e0440Sopenharmony_ci battery_manager_feature_enable_charger = false 19f16e0440Sopenharmony_ci} 20f16e0440Sopenharmony_ci 21f16e0440Sopenharmony_cidefines = [] 22f16e0440Sopenharmony_ciif (!defined(global_parts_info) || 23f16e0440Sopenharmony_ci defined(global_parts_info.hiviewdfx_hisysevent)) { 24f16e0440Sopenharmony_ci has_hiviewdfx_hisysevent_part = true 25f16e0440Sopenharmony_ci defines += [ "HAS_HIVIEWDFX_HISYSEVENT_PART" ] 26f16e0440Sopenharmony_ci} else { 27f16e0440Sopenharmony_ci has_hiviewdfx_hisysevent_part = false 28f16e0440Sopenharmony_ci} 29f16e0440Sopenharmony_ci 30f16e0440Sopenharmony_ciif (!defined(global_parts_info) || 31f16e0440Sopenharmony_ci defined(global_parts_info.sensors_miscdevice)) { 32f16e0440Sopenharmony_ci has_sensors_miscdevice_part = true 33f16e0440Sopenharmony_ci defines += [ "HAS_SENSORS_MISCDEVICE_PART" ] 34f16e0440Sopenharmony_ci} else { 35f16e0440Sopenharmony_ci has_sensors_miscdevice_part = false 36f16e0440Sopenharmony_ci} 37f16e0440Sopenharmony_ci 38f16e0440Sopenharmony_ciif (!defined(global_parts_info) || 39f16e0440Sopenharmony_ci defined(global_parts_info.hdf_drivers_interface_display)) { 40f16e0440Sopenharmony_ci has_drivers_interface_display_part = true 41f16e0440Sopenharmony_ci} else { 42f16e0440Sopenharmony_ci has_drivers_interface_display_part = false 43f16e0440Sopenharmony_ci} 44f16e0440Sopenharmony_ci 45f16e0440Sopenharmony_ciif (!defined(global_parts_info) || 46f16e0440Sopenharmony_ci defined(global_parts_info.hdf_drivers_interface_light)) { 47f16e0440Sopenharmony_ci has_drivers_interface_light_part = true 48f16e0440Sopenharmony_ci} else { 49f16e0440Sopenharmony_ci has_drivers_interface_light_part = false 50f16e0440Sopenharmony_ci} 51f16e0440Sopenharmony_ci 52f16e0440Sopenharmony_ciif (!defined(global_parts_info) || 53f16e0440Sopenharmony_ci defined(global_parts_info.graphic_graphic_surface)) { 54f16e0440Sopenharmony_ci has_graphic_surface_part = true 55f16e0440Sopenharmony_ci} else { 56f16e0440Sopenharmony_ci has_graphic_surface_part = false 57f16e0440Sopenharmony_ci} 58f16e0440Sopenharmony_ci 59f16e0440Sopenharmony_ciif (!defined(global_parts_info) || defined(global_parts_info.arkui_ui_lite)) { 60f16e0440Sopenharmony_ci has_ui_lite_part = true 61f16e0440Sopenharmony_ci} else { 62f16e0440Sopenharmony_ci has_ui_lite_part = false 63f16e0440Sopenharmony_ci} 64f16e0440Sopenharmony_ci 65f16e0440Sopenharmony_ciif (!defined(global_parts_info) || 66f16e0440Sopenharmony_ci defined(global_parts_info.customization_config_policy)) { 67f16e0440Sopenharmony_ci has_battery_config_policy_part = true 68f16e0440Sopenharmony_ci} else { 69f16e0440Sopenharmony_ci has_battery_config_policy_part = false 70f16e0440Sopenharmony_ci} 71f16e0440Sopenharmony_ci 72f16e0440Sopenharmony_ciability_runtime_path = "//foundation/ability/ability_runtime" 73f16e0440Sopenharmony_ciability_runtime_napi_path = "${ability_runtime_path}/frameworks/js/napi" 74f16e0440Sopenharmony_ciability_runtime_inner_api_path = "${ability_runtime_path}/interfaces/inner_api" 75f16e0440Sopenharmony_ciability_runtime_services_path = "${ability_runtime_path}/services" 76f16e0440Sopenharmony_cibatterymgr_native_part_name = "battery_manager" 77f16e0440Sopenharmony_cimodule_output_path = "${batterymgr_native_part_name}/battery_manager" 78f16e0440Sopenharmony_cibattery_manager_path = "//base/powermgr/battery_manager" 79f16e0440Sopenharmony_cibattery_inner_api = "${battery_manager_path}/interfaces/inner_api" 80f16e0440Sopenharmony_cibattery_frameworks = "${battery_manager_path}/frameworks" 81f16e0440Sopenharmony_cibattery_service = "${battery_manager_path}/services" 82f16e0440Sopenharmony_cibattery_service_native = "${battery_service}/native" 83f16e0440Sopenharmony_cibattery_service_zidl = "${battery_service}/zidl" 84f16e0440Sopenharmony_cibattery_utils = "${battery_manager_path}/utils" 85