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("../../../device_status.gni") 15 16config("intention_service_config") { 17 include_dirs = [ 18 "include", 19 "${device_status_root_path}/intention/cooperate/server/include", 20 "${device_status_root_path}/intention/drag/server/include", 21 "${device_status_root_path}/intention/stationary/server/include", 22 "${device_status_root_path}/interfaces/innerkits/interaction/include", 23 "${device_status_root_path}/intention/prototype/include", 24 "${device_status_root_path}/intention/boomerang/server/include", 25 "${device_status_root_path}/intention/onscreen/server/include", 26 ] 27} 28 29ohos_shared_library("intention_service") { 30 sanitize = { 31 integer_overflow = true 32 ubsan = true 33 boundary_sanitize = true 34 cfi = true 35 cfi_cross_dso = true 36 debug = false 37 } 38 39 branch_protector_ret = "pac_ret" 40 41 defines = device_status_default_defines 42 43 include_dirs = [ 44 "include", 45 "${device_status_root_path}/interfaces/innerkits/interaction/include", 46 ] 47 48 if (device_status_enable_universal_drag) { 49 include_dirs += 50 [ "${device_status_root_path}/services/interaction/drag/include" ] 51 } 52 53 sources = [ 54 "src/boomerang_dumper.cpp", 55 "src/intention_dumper.cpp", 56 "src/intention_service.cpp", 57 ] 58 59 public_configs = [ ":intention_service_config" ] 60 61 deps = [ 62 "${device_status_root_path}/intention/boomerang/server:intention_boomerang_server", 63 "${device_status_root_path}/intention/cooperate/server:intention_cooperate_server", 64 "${device_status_root_path}/intention/drag/server:intention_drag_server", 65 "${device_status_root_path}/intention/ipc/socket:intention_socket_server", 66 "${device_status_root_path}/intention/ipc/tunnel:intention_server_stub", 67 "${device_status_root_path}/intention/prototype:intention_prototype", 68 "${device_status_root_path}/intention/stationary/server:intention_stationary_server", 69 "${device_status_root_path}/utils/common:devicestatus_util", 70 "${device_status_root_path}/utils/ipc:devicestatus_ipc", 71 "${device_status_root_path}/intention/onscreen/server:intention_on_screen_server" 72 ] 73 74 external_deps = [ 75 "access_token:libaccesstoken_sdk", 76 "bundle_framework:appexecfwk_core", 77 "eventhandler:libeventhandler", 78 "graphic_2d:librender_service_client", 79 "graphic_2d:librender_service_base", 80 "hicollie:libhicollie", 81 "hilog:libhilog", 82 "image_framework:image_native", 83 "input:libmmi-client", 84 "samgr:samgr_proxy", 85 "window_manager:libdm", 86 ] 87 88 if (device_status_motion_enable) { 89 defines += [ "MOTION_ENABLE" ] 90 external_deps += [ "motion:motion_interface_native" ] 91 } 92 93 if (device_status_sensor_enable) { 94 defines += [ "DEVICE_STATUS_SENSOR_ENABLE" ] 95 external_deps += [ "sensor:sensor_interface_native" ] 96 } 97 98 if (device_status_boomerang_onestep) { 99 defines += [ "BOOMERANG_ONESTEP" ] 100 external_deps += [ 101 "window_manager:libwm", 102 ] 103 } 104 105 subsystem_name = "${device_status_subsystem_name}" 106 part_name = "${device_status_part_name}" 107} 108