• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
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("//base/hiviewdfx/faultloggerd/faultloggerd.gni")
15
16if (defined(ohos_lite)) {
17  shared_library("libdfx_procinfo") {
18    visibility = [ "*:*" ]
19
20    include_dirs = [
21      ".",
22      "include",
23      "$c_utils_include_path",
24      "$faultloggerd_path/common",
25      "$faultloggerd_path/common/dfxutil",
26      "$hilog_lite_include_path",
27    ]
28
29    sources = [ "procinfo.cpp" ]
30    sources += [ "$c_utils_src_path/directory_ex.cpp" ]
31
32    deps = [
33      "$faultloggerd_path/common/dfxutil:dfx_util",
34      "$hilog_lite_deps_path",
35      "//third_party/bounds_checking_function:libsec_shared",
36    ]
37  }
38} else {
39  config("dfx_procinfo_config") {
40    visibility = [ "*:*" ]
41
42    include_dirs = [ "include" ]
43  }
44
45  ohos_shared_library("libdfx_procinfo") {
46    public_configs = [
47      ":dfx_procinfo_config",
48      "$faultloggerd_path/common/build:coverage_flags",
49    ]
50    sources = [ "procinfo.cpp" ]
51
52    deps = [
53      "$faultloggerd_path/common/dfxutil:dfx_util",
54      "//third_party/bounds_checking_function:libsec_shared",
55    ]
56    version_script = "libprocinfo.map"
57    external_deps = [
58      "c_utils:utils",
59      "hilog:libhilog",
60    ]
61    install_images = [
62      "system",
63      "updater",
64    ]
65    innerapi_tags = [
66      "chipsetsdk_indirect",
67      "platformsdk_indirect",
68    ]
69    part_name = "faultloggerd"
70    subsystem_name = "hiviewdfx"
71  }
72
73  ohos_static_library("dfx_procinfo_static") {
74    public_configs = [ ":dfx_procinfo_config" ]
75
76    sources = [ "procinfo.cpp" ]
77
78    deps = [
79      "$faultloggerd_path/common/dfxlog:static_hilog_base",
80      "$faultloggerd_path/common/dfxutil:dfx_util_static",
81      "//third_party/bounds_checking_function:libsec_static",
82    ]
83
84    external_deps = [
85      "c_utils:utils",
86      "hilog:libhilog_base",
87    ]
88
89    part_name = "faultloggerd"
90    subsystem_name = "hiviewdfx"
91  }
92}
93