1# Copyright (c) 2022-2024 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/proxy_authorization_uri_config.cpp", 32 "src/rdb/ability_rdb_open_callback.cpp", 33 "src/rdb/rdb_data_manager.cpp", 34 "src/rdb/uri_permission_rdb.cpp", 35 "src/uri_permission_manager_service.cpp", 36 "src/uri_permission_manager_stub_impl.cpp", 37] 38 39#build so 40ohos_shared_library("libupms") { 41 shlib_type = "sa" 42 configs = [ 43 "${ability_runtime_innerkits_path}/app_manager:appmgr_sdk_config", 44 "${ability_runtime_services_path}/common:common_config", 45 ] 46 public_configs = [ ":upms_config" ] 47 48 include_dirs = [ "${ability_runtime_path}/interfaces/kits/native/appkit/ability_bundle_manager_helper" ] 49 50 sources = libupms_sources 51 52 deps = [ 53 "${ability_runtime_innerkits_path}/deps_wrapper:ability_deps_wrapper", 54 "${ability_runtime_innerkits_path}/uri_permission:uri_permission_mgr", 55 "${ability_runtime_native_path}/appkit:appkit_manager_helper", 56 "${ability_runtime_services_path}/common:app_util", 57 "${ability_runtime_services_path}/common:event_report", 58 "${ability_runtime_services_path}/common:perm_verification", 59 ] 60 61 external_deps = [ 62 "ability_base:want", 63 "ability_base:zuri", 64 "access_token:libaccesstoken_sdk", 65 "access_token:libtokenid_sdk", 66 "bundle_framework:appexecfwk_base", 67 "bundle_framework:appexecfwk_core", 68 "c_utils:utils", 69 "common_event_service:cesfwk_core", 70 "common_event_service:cesfwk_innerkits", 71 "eventhandler:libeventhandler", 72 "hilog:libhilog", 73 "hisysevent:libhisysevent", 74 "init:libbeget_proxy", 75 "init:libbegetutil", 76 "ipc:ipc_core", 77 "relational_store:native_rdb", 78 "safwk:system_ability_fwk", 79 "samgr:samgr_proxy", 80 "storage_service:storage_manager_sa_proxy", 81 ] 82 83 subsystem_name = "ability" 84 part_name = "ability_runtime" 85} 86 87# Note: Just for test 88ohos_static_library("libupms_static") { 89 configs = [ 90 "${ability_runtime_innerkits_path}/app_manager:appmgr_sdk_config", 91 "${ability_runtime_services_path}/common:common_config", 92 ] 93 public_configs = [ ":upms_config" ] 94 95 include_dirs = [ "${ability_runtime_path}/interfaces/kits/native/appkit/ability_bundle_manager_helper" ] 96 97 sources = libupms_sources 98 99 deps = [ 100 "${ability_runtime_innerkits_path}/uri_permission:uri_permission_mgr", 101 "${ability_runtime_services_path}/common:app_util", 102 "${ability_runtime_services_path}/common:perm_verification", 103 ] 104 105 external_deps = [ 106 "ability_base:want", 107 "ability_base:zuri", 108 "ability_runtime:ability_deps_wrapper", 109 "access_token:libaccesstoken_sdk", 110 "bundle_framework:appexecfwk_base", 111 "bundle_framework:appexecfwk_core", 112 "c_utils:utils", 113 "common_event_service:cesfwk_core", 114 "common_event_service:cesfwk_innerkits", 115 "hilog:libhilog", 116 "init:libbeget_proxy", 117 "init:libbegetutil", 118 "ipc:ipc_core", 119 "relational_store:native_rdb", 120 "safwk:system_ability_fwk", 121 "samgr:samgr_proxy", 122 "storage_service:storage_manager_sa_proxy", 123 ] 124 125 subsystem_name = "ability" 126 part_name = "ability_runtime" 127} 128