BUILD.gn 1.9 KB
Newer Older
L
liangshenglin1 已提交
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23
# Copyright (c) 2021 Huawei Device Co., Ltd.
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

import("//build/ohos.gni")

SUBSYSTEM_DIR = "//foundation/communication/ipc"

config("rpc_public_config") {
  visibility = [ ":*" ]
  include_dirs = [ "$SUBSYSTEM_DIR/ipc/native/src/napi/include" ]
}

ohos_shared_library("rpc") {
W
wanderer-dl122 已提交
24 25 26
  sanitize = {
    integer_overflow = true
  }
W
wangqilong2 已提交
27
  version_script = "librpc_map"
L
liangshenglin1 已提交
28 29
  include_dirs = [
    "$SUBSYSTEM_DIR/utils/include",
30
    "//foundation/arkui/napi/interfaces/kits",
31
    "//foundation/arkui/napi/native_engine",
L
liangshenglin1 已提交
32
    "//utils/system/safwk/native/include",
Z
zhou-liting125 已提交
33
    "$SUBSYSTEM_DIR/ipc/native/c/adapter/include",
34
    "$SUBSYSTEM_DIR/ipc/native/c/adapter/access_token/include",
S
shufewhx 已提交
35
    "$SUBSYSTEM_DIR/ipc/native/src/napi_common/include",
L
liangshenglin1 已提交
36 37 38 39
  ]
  public_configs = [ ":rpc_public_config" ]

  sources = [
S
shufewhx 已提交
40
    "$SUBSYSTEM_DIR/ipc/native/src/napi/src/napi_ipc_skeleton.cpp",
L
liangshenglin1 已提交
41
    "$SUBSYSTEM_DIR/ipc/native/src/napi/src/napi_message_option.cpp",
42
    "$SUBSYSTEM_DIR/ipc/native/src/napi/src/napi_remote_proxy.cpp",
L
liangshenglin1 已提交
43 44 45 46
    "$SUBSYSTEM_DIR/ipc/native/src/napi/src/napi_rpc_native_module.cpp",
  ]

  deps = [
47
    "//foundation/arkui/napi:ace_napi",
48
    "//third_party/libuv:uv",
L
liangshenglin1 已提交
49 50 51
  ]

  external_deps = [
H
hongtao 已提交
52
    "c_utils:utils",
W
wenlong12 已提交
53
    "hitrace_native:hitrace_meter",
L
liangshenglin1 已提交
54 55
    "hiviewdfx_hilog_native:libhilog",
    "ipc:ipc_core",
S
shufewhx 已提交
56
    "ipc:ipc_napi_common",
L
liangshenglin1 已提交
57 58 59 60 61 62 63
  ]

  relative_install_dir = "module"

  subsystem_name = "communication"
  part_name = "ipc_js"
}