• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright (c) 2021 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
14hispark_pegasus_sdk_path = "//device/soc/hisilicon/hi3861v100/sdk_liteos"
15dsoftbus_root_path = rebase_path(".")
16dsoftbus_sdk_path = "${dsoftbus_root_path}/sdk"
17dsoftbus_core_path = "${dsoftbus_root_path}/core"
18dsoftbus_test_path = "${dsoftbus_root_path}/tests"
19dsoftbus_fuzz_out_path = "dsoftbus/soft_bus"
20
21declare_args() {
22  softbus_adapter_common = "${dsoftbus_root_path}/adapter/common"
23  softbus_adapter_config = "${dsoftbus_root_path}/adapter/default_config"
24  dsoftbus_feature_product_config_path =
25      "${dsoftbus_root_path}/adapter/default_config"
26}
27
28declare_args() {
29  dsoftbus_get_devicename = true
30  softbus_communication_wifi_feature = true
31  softbus_os_account = true
32}
33
34if (defined(global_parts_info) &&
35    !defined(global_parts_info.communication_wifi)) {
36  softbus_communication_wifi_feature = false
37}
38
39if (defined(global_parts_info) &&
40    !defined(global_parts_info.ability_ability_runtime)) {
41  dsoftbus_get_devicename = false
42}
43
44if (defined(global_parts_info) &&
45    !defined(global_parts_info.account_os_account)) {
46  softbus_os_account = false
47}
48
49if (defined(global_parts_info) &&
50    !defined(global_parts_info.communication_bluetooth)) {
51  support_bluetooth = false
52} else {
53  support_bluetooth = true
54}
55
56if (defined(ohos_lite)) {
57  import("//build/lite/config/component/lite_component.gni")
58  if (ohos_kernel_type == "liteos_m") {
59    defines = [ "SOFTBUS_LITEOS_M" ]
60    import("$softbus_adapter_config/feature_config/mini/config.gni")
61  } else {
62    defines = [ "SOFTBUS_LITEOS_A" ]
63    import("$softbus_adapter_config/feature_config/small/config.gni")
64  }
65} else {
66  if (defined(os_win)) {
67    os_type = "windows"
68  } else {
69    os_type = "standard"
70  }
71  defines = [ "SOFTBUS_LINUX" ]
72  import("//build/ohos.gni")
73  import(
74      "$dsoftbus_feature_product_config_path/feature_config/standard/config.gni")
75}
76