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}/common/include", 22 "${inputmethod_path}/frameworks/common", 23 "${inputmethod_path}/frameworks/native/inputmethod_controller/include", 24 "${inputmethod_path}/interfaces/inner_api/inputmethod_controller/include", 25 "${inputmethod_path}/services/include", 26 ] 27} 28 29config("inputmethod_client_native_public_config") { 30 visibility = [ "./*" ] 31 include_dirs = [ 32 "include", 33 "${inputmethod_path}/common/include", 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}/interfaces/inner_api/inputmethod_controller/include", 39 "${inputmethod_path}/services/include", 40 ] 41} 42 43ohos_shared_library("inputmethod_client") { 44 branch_protector_ret = "pac_ret" 45 sources = [ 46 "${inputmethod_path}/frameworks/native/inputmethod_ability/src/input_method_agent_proxy.cpp", 47 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/ime_event_monitor_manager.cpp", 48 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/ime_event_monitor_manager_impl.cpp", 49 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/ime_system_channel.cpp", 50 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/input_client_stub.cpp", 51 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/input_data_channel_stub.cpp", 52 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/input_method_controller.cpp", 53 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/input_method_system_ability_proxy.cpp", 54 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/input_method_utils.cpp", 55 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/keyevent_consumer_stub.cpp", 56 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/system_cmd_channel_stub.cpp", 57 ] 58 59 cflags_cc = [ 60 "-fvisibility=hidden", 61 "-fvisibility-inlines-hidden", 62 "-fdata-sections", 63 "-ffunction-sections", 64 "-Os", 65 "-Wno-c99-designator", 66 ] 67 68 version_script = "inputmethod_client.versionscript" 69 70 innerapi_tags = [ "platformsdk" ] 71 72 deps = [ "${inputmethod_path}/common:inputmethod_common" ] 73 74 external_deps = [ 75 "bundle_framework:appexecfwk_base", 76 "bundle_framework:appexecfwk_core", 77 "c_utils:utils", 78 "eventhandler:libeventhandler", 79 "hilog:libhilog", 80 "input:libmmi-client", 81 "ipc:ipc_single", 82 "samgr:samgr_proxy", 83 ] 84 public_external_deps = [ "ability_base:want" ] 85 86 configs = [ ":inputmethod_client_native_config" ] 87 88 public_configs = [ ":inputmethod_client_native_public_config" ] 89 90 subsystem_name = "inputmethod" 91 part_name = "imf" 92} 93 94ohos_static_library("inputmethod_client_static") { 95 testonly = true 96 branch_protector_ret = "pac_ret" 97 sanitize = { 98 cfi = true 99 cfi_cross_dso = true 100 debug = false 101 } 102 sources = [ 103 "${inputmethod_path}/frameworks/native/inputmethod_ability/src/input_method_agent_proxy.cpp", 104 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/ime_event_monitor_manager.cpp", 105 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/ime_event_monitor_manager_impl.cpp", 106 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/ime_system_channel.cpp", 107 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/input_client_stub.cpp", 108 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/input_data_channel_stub.cpp", 109 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/input_method_controller.cpp", 110 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/input_method_system_ability_proxy.cpp", 111 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/input_method_utils.cpp", 112 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/keyevent_consumer_stub.cpp", 113 "${inputmethod_path}/frameworks/native/inputmethod_controller/src/system_cmd_channel_stub.cpp", 114 ] 115 116 public_configs = [ ":inputmethod_client_native_public_config" ] 117 118 deps = [ "${inputmethod_path}/common:inputmethod_common" ] 119 120 external_deps = [ 121 "bundle_framework:appexecfwk_base", 122 "bundle_framework:appexecfwk_core", 123 "c_utils:utils", 124 "eventhandler:libeventhandler", 125 "hilog:libhilog", 126 "input:libmmi-client", 127 "ipc:ipc_single", 128 "samgr:samgr_proxy", 129 ] 130 131 public_external_deps = [ "ability_base:want" ] 132 133 subsystem_name = "inputmethod" 134 part_name = "imf" 135} 136