• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright (C) 2024 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("../../../config.gni")
16
17SUBSYSTEM_DIR = "../../.."
18IPC_CORE_ROOT = "$SUBSYSTEM_DIR/ipc/native"
19
20config("libipc_capi_private_config") {
21  cflags_cc = [ "-O2" ]
22}
23
24config("libipc_capi_public_config") {
25  include_dirs = [ "$SUBSYSTEM_DIR/interfaces/innerkits/c_api/include" ]
26}
27
28ohos_shared_library("ipc_capi") {
29  branch_protector_ret = "pac_ret"
30  include_dirs = [
31    "$SUBSYSTEM_DIR/interfaces/innerkits/ipc_core/include",
32    "$SUBSYSTEM_DIR/interfaces/innerkits/c_api/include",
33    "$SUBSYSTEM_DIR/ipc/native/src/core/dbinder/include",
34    "$SUBSYSTEM_DIR/ipc/native/src/core/framework/include",
35    "$SUBSYSTEM_DIR/ipc/native/src/core/invoker/include",
36    "$IPC_CORE_ROOT/src/c_api/include",
37    "$SUBSYSTEM_DIR/utils/include",
38  ]
39
40  sources = [
41    "$IPC_CORE_ROOT/src/c_api/source/ipc_cparcel.cpp",
42    "$IPC_CORE_ROOT/src/c_api/source/ipc_cremote_object.cpp",
43    "$IPC_CORE_ROOT/src/c_api/source/ipc_cskeleton.cpp",
44    "$IPC_CORE_ROOT/src/c_api/source/ipc_inner_object.cpp",
45    "$IPC_CORE_ROOT/src/c_api/source/ipc_internal_utils.cpp",
46    "$IPC_CORE_ROOT/src/c_api/source/ipc_remote_object_internal.cpp",
47  ]
48
49  configs = [
50    "$SUBSYSTEM_DIR/config:ipc_util_config",
51    ":libipc_capi_private_config",
52  ]
53
54  public_configs = [ ":libipc_capi_public_config" ]
55
56  deps = [
57    "$IPC_CORE_ROOT/src/core:ipc_common",
58    "$SUBSYSTEM_DIR/interfaces/innerkits/ipc_core:ipc_core",
59  ]
60
61  external_deps = [
62    "c_utils:utils",
63    "hilog:libhilog",
64  ]
65
66  innerapi_tags = [
67    "platformsdk",
68    "sasdk",
69  ]
70
71  symlink_target_name = [ "libipc_capi.so" ]
72
73  relative_install_dir = "./ndk/"
74
75  install_images = [ system_base_dir ]
76
77  subsystem_name = "communication"
78  part_name = "ipc"
79}
80