• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright (c) 2021-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/security/access_token/access_token.gni")
15import("//build/ohos.gni")
16
17config("accesstoken") {
18  visibility = [ ":*" ]
19  include_dirs = [ "include" ]
20}
21
22ohos_shared_library("libaccesstoken_sdk") {
23  subsystem_name = "security"
24  part_name = "access_token"
25
26  output_name = "libaccesstoken_sdk"
27
28  public_configs = [ ":accesstoken" ]
29
30  include_dirs = [
31    "//utils/native/base/include",
32    "include",
33    "src",
34    "//base/security/access_token/frameworks/accesstoken/include",
35    "//base/security/access_token/frameworks/common/include",
36    "//base/security/access_token/interfaces/innerkits/accesstoken/include",
37  ]
38
39  sources = [
40    "src/accesstoken_death_recipient.cpp",
41    "src/accesstoken_kit.cpp",
42    "src/accesstoken_manager_client.cpp",
43    "src/accesstoken_manager_proxy.cpp",
44  ]
45
46  deps = [
47    "//base/security/access_token/frameworks/accesstoken:accesstoken_communication_adapter_cxx",
48    "//base/security/access_token/frameworks/common:accesstoken_common_cxx",
49    "//utils/native/base:utils",
50  ]
51
52  external_deps = [
53    "hiviewdfx_hilog_native:libhilog",
54    "ipc:ipc_core",
55    "samgr_standard:samgr_proxy",
56  ]
57
58  cflags_cc = [
59    "-DHILOG_ENABLE",
60    "-DDEBUG_API_PERFORMANCE",
61  ]
62  if (token_sync_enable == true) {
63    cflags_cc += [ "-DTOKEN_SYNC_ENABLE" ]
64  }
65}
66