1# Copyright (c) 2023 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("../../../../os_account.gni") 16 17config("domain_account_napi_kit_config") { 18 include_dirs = [ "include" ] 19 20 cflags = [] 21 22 if (target_cpu == "arm") { 23 cflags += [ "-DBINDER_IPC_32BIT" ] 24 } 25 26 cflags += [ "-pipe" ] 27 28 cflags_cc = [ 29 "-Wdate-time", 30 "-Wformat=2", 31 "-Wfloat-equal", 32 "-Wshadow", 33 ] 34} 35 36ohos_shared_library("domain_account_napi") { 37 branch_protector_ret = "pac_ret" 38 39 sanitize = { 40 cfi = true 41 cfi_cross_dso = true 42 debug = false 43 } 44 45 include_dirs = [] 46 47 configs = [ ":domain_account_napi_kit_config" ] 48 49 public_configs = [ ":domain_account_napi_kit_config" ] 50 51 sources = [ 52 "src/napi_domain_account_manager.cpp", 53 "src/napi_domain_account_module.cpp", 54 "src/napi_domain_auth_callback.cpp", 55 ] 56 57 defines = [ 58 "ACCOUNT_LOG_TAG = \"DomainAccount\"", 59 "LOG_DOMAIN = 0xD001B00", 60 ] 61 62 deps = [ 63 "${account_napi_common_path}:account_napi_common", 64 "${domain_account_framework_path}:domain_account_innerkits", 65 ] 66 67 external_deps = [ 68 "ability_base:want", 69 "ability_runtime:abilitykit_native", 70 "ability_runtime:wantagent_innerkits", 71 "c_utils:utils", 72 "hilog:libhilog", 73 "napi:ace_napi", 74 ] 75 76 subsystem_name = "account" 77 78 innerapi_tags = [ "platformsdk" ] 79 part_name = "os_account" 80} 81