• 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("//base/msdp/device_status/device_status.gni")
15
16config("devicestatus_private_config") {
17  include_dirs = [ "//utils/system/safwk/native/include" ]
18}
19
20config("devicestatus_srv_public_config") {
21  include_dirs = [
22    "include",
23    "interface",
24    "include/datahub",
25    "include/algorithm",
26    "${device_status_interfaces_path}/innerkits/include",
27    "//foundation/distributedhardware/device_manager/interfaces/inner_kits/native_cpp/include/",
28    "${ability_runtime_path}/interfaces/kits/native/ability/native/",
29    "//base/sensors/sensor/interfaces/native/include/",
30    "//third_party/cJSON",
31  ]
32}
33
34ohos_shared_library("devicestatus_sensorhdi") {
35  sources = [ "src/devicestatus_data_parse.cpp" ]
36
37  configs = [
38    "${device_status_utils_path}:devicestatus_utils_config",
39    ":devicestatus_private_config",
40  ]
41
42  public_configs = [ ":devicestatus_srv_public_config" ]
43
44  deps = [ "//third_party/cJSON:cjson" ]
45
46  external_deps = [ "hiviewdfx_hilog_native:libhilog" ]
47
48  part_name = "${device_status_part_name}"
49}
50
51ohos_shared_library("devicestatus_msdp") {
52  sources = [
53    "src/devicestatus_data_parse.cpp",
54    "src/devicestatus_msdp_mock.cpp",
55  ]
56
57  configs = [
58    "${device_status_utils_path}:devicestatus_utils_config",
59    ":devicestatus_private_config",
60  ]
61
62  public_configs = [ ":devicestatus_srv_public_config" ]
63
64  deps = [ "//third_party/cJSON:cjson" ]
65
66  external_deps = [ "hiviewdfx_hilog_native:libhilog" ]
67
68  part_name = "${device_status_part_name}"
69}
70
71ohos_shared_library("devicestatus_algo") {
72  sources = [
73    "src/datahub/sensor_data_callback.cpp",
74    "src/algorithm/algo_absolute_still.cpp",
75    "src/algorithm/algo_relative_still.cpp",
76    "src/algorithm/algo_base.cpp",
77    "src/devicestatus_algorithm_manager.cpp",
78  ]
79
80  configs = [
81    "${device_status_utils_path}:devicestatus_utils_config",
82    ":devicestatus_private_config",
83  ]
84
85  public_configs = [ ":devicestatus_srv_public_config" ]
86
87  deps = [
88    "${device_status_interfaces_path}/innerkits:devicestatus_client",
89    "//commonlibrary/c_utils/base:utils",
90    "//drivers/peripheral/sensor/hal:hdi_sensor",
91    "//foundation/multimodalinput/input/util:libmmi-util",
92    "//third_party/cJSON:cjson_static",
93    "//third_party/jsoncpp",
94  ]
95
96  external_deps = [
97    "ability_base:base",
98    "hiviewdfx_hilog_native:libhilog",
99    "input:libmmi-client",
100    "ipc:ipc_core",
101    "safwk:system_ability_fwk",
102    "samgr:samgr_proxy",
103    "sensor:sensor_interface_native",
104  ]
105
106  part_name = "${device_status_part_name}"
107}
108
109