1# Copyright (c) 2021-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") 15import("//build/ohos_var.gni") 16 17config("samgr_proxy_config") { 18 include_dirs = [ "include" ] 19} 20 21config("lsamgr_proxy_config") { 22 include_dirs = 23 [ "//foundation/systemabilitymgr/samgr/services/lsamgr/include" ] 24} 25 26config("samgr_proxy_private_config") { 27 include_dirs = [ 28 "include", 29 "//foundation/systemabilitymgr/samgr/interfaces/innerkits/lsamgr", 30 "//foundation/systemabilitymgr/samgr/interfaces/innerkits/samgr_proxy/include", 31 "//foundation/systemabilitymgr/samgr/services/lsamgr/include", 32 "//foundation/systemabilitymgr/samgr/services/samgr/native/include", 33 "//foundation/systemabilitymgr/samgr/interfaces/innerkits/dynamic_cache/include", 34 "//foundation/systemabilitymgr/samgr/utils/native/include", 35 ] 36} 37 38ohos_shared_library("samgr_proxy") { 39 sanitize = { 40 cfi = true 41 cfi_cross_dso = true 42 debug = false 43 cfi_no_nvcall = true 44 blocklist = "../../../cfi_blocklist.txt" 45 } 46 branch_protector_ret = "pac_ret" 47 48 version_script = "libsamgr_proxy.versionscript" 49 defines = [ "SAMGR_PROXY" ] 50 sources = [ 51 "//foundation/systemabilitymgr/samgr/frameworks/native/source/system_ability_load_callback_stub.cpp", 52 "//foundation/systemabilitymgr/samgr/frameworks/native/source/system_ability_manager_proxy.cpp", 53 "//foundation/systemabilitymgr/samgr/frameworks/native/source/system_ability_on_demand_event.cpp", 54 "//foundation/systemabilitymgr/samgr/frameworks/native/source/system_ability_status_change_stub.cpp", 55 "//foundation/systemabilitymgr/samgr/frameworks/native/source/system_process_status_change_stub.cpp", 56 "//foundation/systemabilitymgr/samgr/services/lsamgr/src/local_ability_manager_proxy.cpp", 57 "//foundation/systemabilitymgr/samgr/services/lsamgr/src/local_abilitys.cpp", 58 "//foundation/systemabilitymgr/samgr/services/samgr/native/source/service_registry.cpp", 59 ] 60 configs = [ 61 ":samgr_proxy_private_config", 62 "//foundation/systemabilitymgr/samgr/test/resource:coverage_flags", 63 ] 64 65 deps = [ "//foundation/systemabilitymgr/samgr/interfaces/innerkits/dynamic_cache:dynamic_cache" ] 66 67 public_configs = [ 68 ":lsamgr_proxy_config", 69 ":samgr_proxy_config", 70 ] 71 all_dependent_configs = [ ":samgr_proxy_config" ] 72 73 if (is_standard_system) { 74 external_deps = [ 75 "c_utils:utils", 76 "hilog:libhilog", 77 "init:libbegetutil", 78 "ipc:ipc_single", 79 "json:nlohmann_json_static", 80 ] 81 82 part_name = "samgr" 83 } 84 85 innerapi_tags = [ 86 "chipsetsdk", 87 "platformsdk", 88 "sasdk", 89 ] 90 install_images = [ 91 system_base_dir, 92 updater_base_dir, 93 ] 94 subsystem_name = "systemabilitymgr" 95} 96