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") 15import("//foundation/communication/netmanager_base/netmanager_base_config.gni") 16 17config("statistics_config") { 18 visibility = [ ":statistics" ] 19 20 include_dirs = [ 21 "include", 22 "include/context", 23 "$NETMANAGER_BASE_ROOT/utils/log/include", 24 ] 25} 26 27ohos_shared_library("statistics") { 28 sources = [ 29 "src/context/get_cellular_rxbeytes_contex.cpp", 30 "src/context/get_iface_rxbeytes_context.cpp", 31 "src/context/get_iface_stats_context.cpp", 32 "src/context/get_iface_uid_stats_context.cpp", 33 "src/context/get_uid_rxbeytes_context.cpp", 34 "src/context/update_iface_stats_context.cpp", 35 "src/statistics_async_work.cpp", 36 "src/statistics_callback_observer.cpp", 37 "src/statistics_exec.cpp", 38 "src/statistics_module.cpp", 39 "src/statistics_observer_wrapper.cpp", 40 ] 41 42 configs = [ ":statistics_config" ] 43 44 deps = [ 45 "$ARKUI_ROOT/napi:ace_napi", 46 "$INNERKITS_ROOT/netstatsclient:net_stats_manager_if", 47 "$NETMANAGER_BASE_ROOT/utils/napi_utils:napi_utils", 48 "$THIRD_PARTY_ROOT/libuv:uv", 49 ] 50 51 external_deps = [ 52 "c_utils:utils", 53 "hiviewdfx_hilog_native:libhilog", 54 "ipc:ipc_core", 55 ] 56 57 relative_install_dir = "module/net" 58 part_name = "netmanager_base" 59 subsystem_name = "communication" 60} 61