15b8fca66Sopenharmony_ci# Copyright (C) 2024 Huawei Device Co., Ltd.
25b8fca66Sopenharmony_ci# Licensed under the Apache License, Version 2.0 (the "License");
35b8fca66Sopenharmony_ci# you may not use this file except in compliance with the License.
45b8fca66Sopenharmony_ci# You may obtain a copy of the License at
55b8fca66Sopenharmony_ci#
65b8fca66Sopenharmony_ci#     http://www.apache.org/licenses/LICENSE-2.0
75b8fca66Sopenharmony_ci#
85b8fca66Sopenharmony_ci# Unless required by applicable law or agreed to in writing, software
95b8fca66Sopenharmony_ci# distributed under the License is distributed on an "AS IS" BASIS,
105b8fca66Sopenharmony_ci# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
115b8fca66Sopenharmony_ci# See the License for the specific language governing permissions and
125b8fca66Sopenharmony_ci# limitations under the License.
135b8fca66Sopenharmony_ci
145b8fca66Sopenharmony_ciimport("//build/ohos.gni")
155b8fca66Sopenharmony_ciSUBSYSTEM_DIR = "../../.."
165b8fca66Sopenharmony_ci
175b8fca66Sopenharmony_ciohos_shared_library("cj_observer_ffi") {
185b8fca66Sopenharmony_ci  sanitize = {
195b8fca66Sopenharmony_ci    cfi = true
205b8fca66Sopenharmony_ci    cfi_cross_dso = true
215b8fca66Sopenharmony_ci    debug = false
225b8fca66Sopenharmony_ci  }
235b8fca66Sopenharmony_ci
245b8fca66Sopenharmony_ci  branch_protector_ret = "pac_ret"
255b8fca66Sopenharmony_ci  include_dirs =
265b8fca66Sopenharmony_ci      [ "$SUBSYSTEM_DIR/state_registry/frameworks/native/observer/include" ]
275b8fca66Sopenharmony_ci
285b8fca66Sopenharmony_ci  sources = [
295b8fca66Sopenharmony_ci    "src/observer_event_handler.cpp",
305b8fca66Sopenharmony_ci    "src/telephony_observer_ffi.cpp",
315b8fca66Sopenharmony_ci    "src/telephony_observer_impl.cpp",
325b8fca66Sopenharmony_ci    "src/telephony_observer_utils.cpp",
335b8fca66Sopenharmony_ci  ]
345b8fca66Sopenharmony_ci
355b8fca66Sopenharmony_ci  deps = [ "$SUBSYSTEM_DIR/state_registry/frameworks/native/observer:tel_state_registry_api" ]
365b8fca66Sopenharmony_ci
375b8fca66Sopenharmony_ci  external_deps = [
385b8fca66Sopenharmony_ci    "c_utils:utils",
395b8fca66Sopenharmony_ci    "core_service:libtel_common",
405b8fca66Sopenharmony_ci    "core_service:tel_core_service_api",
415b8fca66Sopenharmony_ci    "eventhandler:libeventhandler",
425b8fca66Sopenharmony_ci    "hilog:libhilog",
435b8fca66Sopenharmony_ci    "init:libbegetutil",
445b8fca66Sopenharmony_ci    "ipc:ipc_core",
455b8fca66Sopenharmony_ci    "libuv:uv",
465b8fca66Sopenharmony_ci    "napi:ace_napi",
475b8fca66Sopenharmony_ci    "napi:cj_bind_ffi",
485b8fca66Sopenharmony_ci    "napi:cj_bind_native",
495b8fca66Sopenharmony_ci  ]
505b8fca66Sopenharmony_ci
515b8fca66Sopenharmony_ci  innerapi_tags = [ "platformsdk" ]
525b8fca66Sopenharmony_ci  part_name = "state_registry"
535b8fca66Sopenharmony_ci  subsystem_name = "telephony"
545b8fca66Sopenharmony_ci}
55