• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright (c) 2022 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
14import("//build/ohos.gni")
15
16service_dslm_sources = [
17  "dslm_core_process.c",
18  "dslm_credential.c",
19  "dslm_device_list.c",
20  "dslm_dfx_default.c",
21  "dslm_fsm_process.c",
22  "dslm_hievent.c",
23  "dslm_inner_process.c",
24  "dslm_msg_utils.c",
25]
26
27service_dslm_include_dirs = [
28  "../include",
29  "../../common/include",
30  "../../interfaces/inner_api/include",
31]
32
33# service_dslm object
34ohos_source_set("service_dslm_obj") {
35  sources = service_dslm_sources
36  include_dirs = service_dslm_include_dirs
37  deps = [ "../../baselib/utils:utils_static" ]
38
39  if (defined(ohos_lite)) {
40    if (ohos_kernel_type == "liteos_m") {
41      deps += [ "//base/hiviewdfx/hilog_lite/frameworks/mini:hilog_lite" ]
42    } else {
43      deps += [ "//base/hiviewdfx/hilog_lite/frameworks/featured:hilog_shared" ]
44    }
45  } else {
46    external_deps = [
47      "c_utils:utils",
48      "hilog:libhilog",
49    ]
50  }
51
52  defines = [
53    "MAX_SEND_TIMES=5",
54    "SEND_MSG_TIMEOUT_LEN=40000",
55  ]
56
57  configs = [
58    "../../common:common_configs",
59    "../../common:common_lite_configs",
60  ]
61
62  part_name = "device_security_level"
63  subsystem_name = "security"
64}
65
66# service_dslm object, only for test
67ohos_source_set("service_dslm_test_obj") {
68  testonly = true
69  sources = service_dslm_sources
70  include_dirs = service_dslm_include_dirs
71  deps = [ "../../baselib/utils:utils_static" ]
72
73  if (defined(ohos_lite)) {
74    if (ohos_kernel_type == "liteos_m") {
75      deps += [ "//base/hiviewdfx/hilog_lite/frameworks/mini:hilog_lite" ]
76    } else {
77      deps += [ "//base/hiviewdfx/hilog_lite/frameworks/featured:hilog_shared" ]
78    }
79  } else {
80    external_deps = [
81      "c_utils:utils",
82      "hilog:libhilog",
83    ]
84  }
85
86  defines = [
87    "MAX_SEND_TIMES=5",
88    "SEND_MSG_TIMEOUT_LEN=500",
89  ]
90
91  configs = [ "../../common:common_configs" ]
92
93  part_name = "device_security_level"
94  subsystem_name = "security"
95}
96