• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright (c) 2022-2023 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
14access_token_path = "//base/security/access_token"
15audio_framework_path = "//foundation/multimedia/audio_framework"
16module_output_path_interface_privacy =
17    "access_token/access_token/interface_privacy"
18module_output_path_interface_access_token =
19    "access_token/access_token/interface_access_token"
20module_output_path_service_privacy = "access_token/access_token/service_privacy"
21module_output_path_service_access_token =
22    "access_token/access_token/service_access_token"
23VENDOR_CONFIG_PATH = rebase_path(
24        "//vendor/${product_company}/${product_name}/base/security/access_token/access_token_impl.gni")
25CMD = "if [ -f ${VENDOR_CONFIG_PATH} ]; then echo true; else echo false; fi"
26
27vendor_config_exist =
28    exec_script("//build/lite/run_shell_cmd.py", [ CMD ], "value")
29if (vendor_config_exist) {
30  import(
31      "//vendor/${product_company}/${product_name}/base/security/access_token/access_token_impl.gni")
32} else {
33  access_token_impl_sources = []
34  access_token_impl_include_dirs = []
35}
36
37if (!defined(global_parts_info) ||
38    defined(global_parts_info.distributedhardware_device_manager)) {
39  token_sync_enable = true
40} else {
41  token_sync_enable = false
42}
43
44if (!defined(global_parts_info) ||
45    defined(global_parts_info.security_dlp_permission_service)) {
46  dlp_permission_enable = true
47} else {
48  dlp_permission_enable = false
49}
50
51if (!defined(global_parts_info) ||
52    defined(global_parts_info.ability_ability_base)) {
53  ability_base_enable = true
54} else {
55  ability_base_enable = false
56}
57
58if (!defined(global_parts_info) ||
59    defined(global_parts_info.hiviewdfx_hicollie)) {
60  hicollie_enable = true
61} else {
62  hicollie_enable = false
63}
64
65if (!defined(global_parts_info) ||
66    defined(global_parts_info.hiviewdfx_hitrace_native)) {
67  hiviewdfx_hitrace_native_enable = true
68} else {
69  hiviewdfx_hitrace_native_enable = false
70}
71
72if (!defined(global_parts_info) ||
73    defined(global_parts_info.multimedia_audio_framework)) {
74  audio_framework_enable = true
75} else {
76  audio_framework_enable = false
77}
78
79if (!defined(global_parts_info) ||
80    defined(global_parts_info.multimedia_camera_framework)) {
81  camera_framework_enable = true
82} else {
83  camera_framework_enable = false
84}
85
86if (!defined(global_parts_info) ||
87    defined(global_parts_info.ability_ability_runtime)) {
88  ability_runtime_enable = true
89} else {
90  ability_runtime_enable = false
91}
92
93if (!defined(global_parts_info) ||
94    defined(global_parts_info.security_security_component_enhance)) {
95  security_component_enhance_enable = true
96} else {
97  security_component_enhance_enable = false
98}
99
100if (!defined(global_parts_info) ||
101    defined(global_parts_info.resourceschedule_ffrt)) {
102  resourceschedule_ffrt_enable = true
103} else {
104  resourceschedule_ffrt_enable = false
105}
106
107if (!defined(global_parts_info) ||
108    defined(global_parts_info.customization_config_policy)) {
109  customization_config_policy_enable = true
110} else {
111  customization_config_policy_enable = false
112}
113
114if (!defined(global_parts_info) ||
115    defined(global_parts_info.theme_screenlock_mgr)) {
116  theme_screenlock_mgr_enable = true
117} else {
118  theme_screenlock_mgr_enable = false
119}
120
121if (!defined(global_parts_info) ||
122    defined(global_parts_info.notification_common_event_service)) {
123  common_event_service_enable = true
124} else {
125  common_event_service_enable = false
126}
127
128if (!defined(global_parts_info) ||
129    defined(global_parts_info.notification_eventhandler)) {
130  eventhandler_enable = true
131} else {
132  eventhandler_enable = false
133}
134
135if (!defined(global_parts_info) ||
136    defined(global_parts_info.resourceschedule_background_task_mgr)) {
137  access_token_background_task_mgr_continuous_task_enable = true
138} else {
139  access_token_background_task_mgr_continuous_task_enable = false
140}
141
142declare_args() {
143  access_token_camera_float_window_enable = true
144  access_token_feature_dtmf_tone = true
145}
146
147if (!defined(global_parts_info) ||
148    defined(global_parts_info.window_window_manager)) {
149  window_manager_enable = true
150} else {
151  window_manager_enable = false
152}
153
154if (!defined(global_parts_info) ||
155    defined(global_parts_info.powermgr_power_manager)) {
156  power_manager_enable = true
157} else {
158  power_manager_enable = false
159}
160