• 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")
15import("//foundation/ability/ability_runtime/ability_runtime.gni")
16
17config("upms_config") {
18  visibility = [ ":*" ]
19  visibility += [ "${ability_runtime_test_path}/unittest/*" ]
20  include_dirs = [
21    "include",
22    "include/rdb",
23  ]
24  cflags = []
25  if (target_cpu == "arm") {
26    cflags += [ "-DBINDER_IPC_32BIT" ]
27  }
28}
29
30libupms_sources = [
31  "src/rdb/ability_rdb_open_callback.cpp",
32  "src/rdb/rdb_data_manager.cpp",
33  "src/rdb/uri_permission_rdb.cpp",
34  "src/uri_permission_manager_service.cpp",
35  "src/uri_permission_manager_stub_impl.cpp",
36]
37
38#build so
39ohos_shared_library("libupms") {
40  shlib_type = "sa"
41  configs = [
42    "${ability_runtime_innerkits_path}/app_manager:appmgr_sdk_config",
43    "${ability_runtime_services_path}/common:common_config",
44  ]
45  public_configs = [ ":upms_config" ]
46
47  sources = libupms_sources
48
49  deps = [
50    "${ability_runtime_innerkits_path}/deps_wrapper:ability_deps_wrapper",
51    "${ability_runtime_innerkits_path}/uri_permission:uri_permission_mgr",
52    "${ability_runtime_services_path}/common:event_report",
53    "${ability_runtime_services_path}/common:perm_verification",
54  ]
55
56  external_deps = [
57    "ability_base:want",
58    "ability_base:zuri",
59    "access_token:libaccesstoken_sdk",
60    "bundle_framework:appexecfwk_base",
61    "bundle_framework:appexecfwk_core",
62    "c_utils:utils",
63    "common_event_service:cesfwk_core",
64    "common_event_service:cesfwk_innerkits",
65    "eventhandler:libeventhandler",
66    "hilog:libhilog",
67    "hisysevent:libhisysevent",
68    "init:libbeget_proxy",
69    "init:libbegetutil",
70    "ipc:ipc_core",
71    "relational_store:native_rdb",
72    "safwk:system_ability_fwk",
73    "samgr:samgr_proxy",
74    "storage_service:storage_manager_sa_proxy",
75  ]
76
77  subsystem_name = "ability"
78  part_name = "ability_runtime"
79}
80
81# Note: Just for test
82ohos_static_library("libupms_static") {
83  configs = [
84    "${ability_runtime_innerkits_path}/app_manager:appmgr_sdk_config",
85    "${ability_runtime_services_path}/common:common_config",
86  ]
87  public_configs = [ ":upms_config" ]
88
89  sources = libupms_sources
90
91  deps = [
92    "${ability_runtime_innerkits_path}/uri_permission:uri_permission_mgr",
93    "${ability_runtime_services_path}/common:perm_verification",
94  ]
95
96  external_deps = [
97    "ability_base:want",
98    "ability_base:zuri",
99    "ability_runtime:ability_deps_wrapper",
100    "access_token:libaccesstoken_sdk",
101    "bundle_framework:appexecfwk_base",
102    "bundle_framework:appexecfwk_core",
103    "c_utils:utils",
104    "common_event_service:cesfwk_core",
105    "common_event_service:cesfwk_innerkits",
106    "hilog:libhilog",
107    "init:libbeget_proxy",
108    "init:libbegetutil",
109    "ipc:ipc_core",
110    "relational_store:native_rdb",
111    "safwk:system_ability_fwk",
112    "samgr:samgr_proxy",
113    "storage_service:storage_manager_sa_proxy",
114  ]
115
116  subsystem_name = "ability"
117  part_name = "ability_runtime"
118}
119