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") 15 16config("pricacy") { 17 visibility = [ ":*" ] 18 include_dirs = [ "include" ] 19} 20 21if (is_standard_system) { 22 ohos_shared_library("libprivacy_sdk") { 23 subsystem_name = "security" 24 part_name = "access_token" 25 26 output_name = "libprivacy_sdk" 27 28 public_configs = [ ":pricacy" ] 29 30 include_dirs = [ 31 "//commonlibrary/c_utils/base/include", 32 "include", 33 "src", 34 "//base/security/access_token/frameworks/privacy/include", 35 "//base/security/access_token/frameworks/common/include", 36 "//base/security/access_token/interfaces/innerkits/accesstoken/include", 37 "//base/security/access_token/interfaces/innerkits/privacy/include", 38 ] 39 40 sources = [ 41 "src/on_permission_used_record_callback_stub.cpp", 42 "src/perm_active_status_change_callback.cpp", 43 "src/perm_active_status_change_callback_stub.cpp", 44 "src/perm_active_status_customized_cbk.cpp", 45 "src/privacy_death_recipient.cpp", 46 "src/privacy_kit.cpp", 47 "src/privacy_manager_client.cpp", 48 "src/privacy_manager_proxy.cpp", 49 "src/state_change_callback.cpp", 50 "src/state_change_callback_stub.cpp", 51 "src/state_customized_cbk.cpp", 52 ] 53 54 deps = [ 55 "//base/security/access_token/frameworks/common:accesstoken_common_cxx", 56 "//base/security/access_token/frameworks/privacy:privacy_communication_adapter_cxx", 57 ] 58 59 configs = [ "//base/security/access_token/config:coverage_flags" ] 60 61 external_deps = [ 62 "c_utils:utils", 63 "hiviewdfx_hilog_native:libhilog", 64 "ipc:ipc_core", 65 "samgr:samgr_proxy", 66 ] 67 68 cflags_cc = [ 69 "-DHILOG_ENABLE", 70 "-DDEBUG_API_PERFORMANCE", 71 ] 72 } 73} 74