1# Copyright (c) 2021-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/inputmethod/imf/inputmethod.gni") 15import("//build/ohos.gni") 16 17config("inputmethod_client_native_config") { 18 visibility = [ ":*" ] 19 include_dirs = [ 20 "include", 21 "${inputmethod_path}/frameworks/common", 22 "${inputmethod_path}/frameworks/native/inputmethod_controller/include", 23 "${inputmethod_path}/services/dfx/include", 24 "${inputmethod_path}/services/include", 25 "${resourceschedule_ffrt_path}/interfaces/kits", 26 ] 27} 28 29config("inputmethod_client_native_public_config") { 30 visibility = [ "./*" ] 31 include_dirs = [ 32 "include", 33 "${inputmethod_path}/common", 34 "${inputmethod_path}/frameworks/common", 35 "${inputmethod_path}/frameworks/native/inputmethod_controller/include", 36 "${inputmethod_path}/frameworks/native/inputmethod_ability/include", 37 "${inputmethod_path}/interfaces/inner_api/inputmethod_ability/include", 38 "${inputmethod_path}/services/include", 39 "${inputmethod_path}/services/dfx/include", 40 "${resourceschedule_ffrt_path}/interfaces/kits", 41 ] 42} 43 44ohos_shared_library("inputmethod_client") { 45 branch_protector_ret = "pac_ret" 46 sanitize = { 47 cfi = true 48 cfi_cross_dso = true 49 debug = false 50 } 51 sources = [ 52 "${inputmethod_path}/frameworks/native/inputmethod_ability/src/input_method_agent_proxy.cpp", 53 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/input_client_proxy.cpp", 54 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/input_client_stub.cpp", 55 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/input_data_channel_proxy.cpp", 56 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/input_data_channel_stub.cpp", 57 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/input_death_recipient.cpp", 58 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/input_method_controller.cpp", 59 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/input_method_system_ability_proxy.cpp", 60 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/input_method_utils.cpp", 61 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/itypes_util.cpp", 62 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/keyevent_consumer_proxy.cpp", 63 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/keyevent_consumer_stub.cpp", 64 "${inputmethod_path}/services/src/message.cpp", 65 "${inputmethod_path}/services/src/message_handler.cpp", 66 ] 67 68 cflags = [ 69 "-fdata-sections", 70 "-ffunction-sections", 71 "-fvisibility=hidden", 72 "-Os", 73 ] 74 75 version_script = "inputmethod_client.versionscript" 76 77 innerapi_tags = [ "platformsdk" ] 78 79 deps = [ "${inputmethod_path}/services/dfx:inputmethod_dfx_static" ] 80 81 public_deps = [ "${inputmethod_path}/services/dfx:inputmethod_dfx_static" ] 82 83 external_deps = [ 84 "ability_base:want", 85 "c_utils:utils", 86 "eventhandler:libeventhandler", 87 "ffrt:libffrt", 88 "hilog:libhilog", 89 "input:libmmi-client", 90 "ipc:ipc_single", 91 "samgr:samgr_proxy", 92 ] 93 94 configs = [ ":inputmethod_client_native_config" ] 95 96 public_configs = [ ":inputmethod_client_native_public_config" ] 97 98 subsystem_name = "inputmethod" 99 part_name = "imf" 100} 101 102ohos_static_library("inputmethod_client_static") { 103 testonly = true 104 branch_protector_ret = "pac_ret" 105 sanitize = { 106 cfi = true 107 cfi_cross_dso = true 108 debug = false 109 } 110 sources = [ 111 "${inputmethod_path}/frameworks/native/inputmethod_ability/src/input_method_agent_proxy.cpp", 112 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/input_client_proxy.cpp", 113 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/input_client_stub.cpp", 114 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/input_data_channel_proxy.cpp", 115 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/input_data_channel_stub.cpp", 116 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/input_death_recipient.cpp", 117 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/input_method_controller.cpp", 118 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/input_method_system_ability_proxy.cpp", 119 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/input_method_utils.cpp", 120 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/itypes_util.cpp", 121 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/keyevent_consumer_proxy.cpp", 122 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/keyevent_consumer_stub.cpp", 123 "${inputmethod_path}/services/src/message.cpp", 124 "${inputmethod_path}/services/src/message_handler.cpp", 125 ] 126 127 public_configs = [ ":inputmethod_client_native_public_config" ] 128 129 public_deps = [ "${inputmethod_path}/services/dfx:inputmethod_dfx_static" ] 130 131 external_deps = [ 132 "ability_base:want", 133 "c_utils:utils", 134 "eventhandler:libeventhandler", 135 "ffrt:libffrt", 136 "hilog:libhilog", 137 "input:libmmi-client", 138 "ipc:ipc_single", 139 "samgr:samgr_proxy", 140 ] 141 142 subsystem_name = "inputmethod" 143 part_name = "imf" 144} 145