• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1# Copyright (C) 2022 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/security/crypto_framework/common/common.gni")
15import("//base/security/crypto_framework/frameworks/frameworks.gni")
16import("//build/ohos.gni")
17
18config("framework_config") {
19  include_dirs = [
20    "//base/security/crypto_framework/interfaces/innerkits/algorithm_parameter",
21    "//base/security/crypto_framework/interfaces/innerkits/certificate",
22    "//base/security/crypto_framework/interfaces/innerkits/common",
23    "//base/security/crypto_framework/interfaces/innerkits/crypto_operation",
24    "//base/security/crypto_framework/interfaces/innerkits/key",
25    "//base/security/crypto_framework/interfaces/innerkits/rand",
26  ]
27}
28
29ohos_shared_library("crypto_framework_lib") {
30  subsystem_name = "security"
31  part_name = "crypto_framework"
32  public_configs = [ ":framework_config" ]
33  include_dirs = [
34    "//commonlibrary/c_utils/base/include",
35    "//base/hiviewdfx/hilog/interfaces/native/innerkits/include",
36  ]
37  include_dirs += framework_inc_path + crypto_framwork_common_inc_path
38
39  sources = framework_files
40
41  if (os_level == "standard") {
42    sanitize = {
43      cfi = true
44      debug = false
45      blocklist = "//base/security/crypto_framework/cfi_blocklist.txt"
46    }
47  }
48
49  cflags = [
50    "-DHILOG_ENABLE",
51    "-fPIC",
52    "-Wall",
53  ]
54
55  deps = [
56    "//base/security/crypto_framework:crypto_openssl_plugin_lib",
57    "//base/security/crypto_framework/common:crypto_plugin_common",
58    "//third_party/openssl:libcrypto_shared",
59  ]
60
61  external_deps = [
62    "c_utils:utils",
63    "hiviewdfx_hilog_native:libhilog",
64  ]
65}
66