• 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/location/config.gni")
15import("//build/ohos.gni")
16
17if (location_feature_with_network) {
18  ohos_shared_library("lbsservice_network") {
19    sources = [
20      "$LOCATION_LOCATOR_ROOT/source/location_config_manager.cpp",
21      "$LOCATION_LOCATOR_ROOT/source/subability_common.cpp",
22      "$LOCATION_LOCATOR_ROOT/source/work_record.cpp",
23      "$LOCATION_NETWORK_ROOT/source/network_ability.cpp",
24      "$LOCATION_NETWORK_ROOT/source/network_ability_skeleton.cpp",
25      "$LOCATION_NETWORK_ROOT/source/network_callback_host.cpp",
26    ]
27
28    include_dirs = [
29      "$LOCATION_ROOT_DIR/interfaces/inner_api/include",
30      "$LOCATION_LOCATOR_ROOT/include",
31      "$LOCATION_NETWORK_ROOT/include",
32    ]
33
34    deps = [
35      "$LOCATION_ROOT_DIR/frameworks/location_common/common:lbsservice_common",
36    ]
37
38    external_deps = [
39      "ability_base:want",
40      "ability_runtime:ability_manager",
41      "access_token:libaccesstoken_sdk",
42      "bundle_framework:appexecfwk_core",
43      "c_utils:utils",
44      "common_event_service:cesfwk_innerkits",
45      "eventhandler:libeventhandler",
46      "hilog:libhilog",
47      "init:libbegetutil",
48      "ipc:ipc_core",
49      "safwk:system_ability_fwk",
50      "samgr:samgr_proxy",
51    ]
52
53    defines = []
54    if (location_feature_with_network) {
55      defines += [ "FEATURE_NETWORK_SUPPORT" ]
56    }
57
58    if (location_feature_with_passive) {
59      defines += [ "FEATURE_PASSIVE_SUPPORT" ]
60    }
61
62    part_name = "location"
63    subsystem_name = "location"
64  }
65} else {
66  ohos_shared_library("lbsservice_network") {
67    part_name = "location"
68    subsystem_name = "location"
69  }
70}
71