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("//build/ohos.gni")
15
16config("screenlock_utils_config") {
17  visibility = [ ":*" ]
18  include_dirs = [ "include" ]
19
20  cflags_cc = []
21}
22
23ohos_shared_library("screenlock_utils") {
24  if (is_standard_system) {
25    sanitize = {
26      cfi = true
27      cfi_cross_dso = true
28      debug = false
29      integer_overflow = true
30      boundary_sanitize = true
31      ubsan = true
32    }
33    branch_protector_ret = "pac_ret"
34    sources = [
35      "src/preferences_util.cpp",
36      "src/screenlock_appinfo.cpp",
37    ]
38
39    version_script = "screenlock_utils.versionscript"
40
41    public_configs = [ ":screenlock_utils_config" ]
42
43    external_deps = [
44      "access_token:libaccesstoken_sdk",
45      "hilog:libhilog",
46      "preferences:native_preferences",
47    ]
48    innerapi_tags = [ "platformsdk_indirect" ]
49    subsystem_name = "theme"
50    part_name = "screenlock_mgr"
51  }
52}
53