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("./multimodalinput_mini.gni") 16 17config("coverage_flags") { 18 if (input_feature_coverage) { 19 cflags = [ "--coverage" ] 20 ldflags = [ "--coverage" ] 21 cflags_cc = [ "--coverage" ] 22 } 23} 24 25ohos_prebuilt_etc("mmi_uinput.rc") { 26 source = "mmi_uinput.rc" 27 relative_install_dir = "init" 28 part_name = "input" 29 subsystem_name = "multimodalinput" 30} 31 32ohos_prebuilt_etc("multimodalinput.rc") { 33 source = "multimodalinput.cfg" 34 relative_install_dir = "init" 35 part_name = "input" 36 subsystem_name = "multimodalinput" 37} 38 39ohos_executable("uinput_inject") { 40 install_enable = true 41 42 sources = uinput_inject_sources 43 stack_protector_ret = true 44 sanitize = { 45 cfi = true 46 cfi_cross_dso = true 47 debug = false 48 } 49 50 include_dirs = [ 51 "${mmi_path}/service/nap_process/include", 52 "${mmi_path}/util/common/include", 53 "${mmi_path}/interfaces/native/innerkits/common/include", 54 ] 55 56 external_deps = [ 57 "c_utils:utils", 58 "drivers_interface_input:libinput_proxy_1.0", 59 "hilog:libhilog", 60 ] 61 62 part_name = "input" 63 subsystem_name = "multimodalinput" 64} 65 66group("multimodalinput_mmi_base") { 67 deps = [] 68} 69 70group("multimodalinput_mmi_frameworks") { 71 deps = [ "frameworks/proxy:libmmi-client" ] 72} 73 74group("multimodalinput_mmi_service") { 75 deps = [ 76 "service:libmmi-server", 77 "tools/inject_event:uinput", 78 ] 79} 80 81group("input_jsapi_group") { 82 deps = [] 83 if (support_jsapi) { 84 deps += [ 85 "frameworks/napi/gesture_event:gestureevent", 86 "frameworks/napi/intention_code:intentioncode", 87 "frameworks/napi/key_code:keycode", 88 "frameworks/napi/key_event:keyevent", 89 "frameworks/napi/mouse_event:mouseevent", 90 "frameworks/napi/touch_event:touchevent", 91 ] 92 if (input_feature_monitor) { 93 deps += [ "frameworks/napi/input_monitor:inputmonitor" ] 94 } 95 if (input_feature_mouse) { 96 deps += [ "frameworks/napi/pointer:pointer" ] 97 } 98 if (input_feature_keyboard) { 99 deps += [ 100 "frameworks/napi/input_consumer:inputconsumer", 101 "frameworks/napi/input_event_client:inputeventclient", 102 ] 103 } 104 if (input_feature_input_device) { 105 deps += [ "frameworks/napi/input_device:inputdevice" ] 106 } 107 if (input_feature_short_key) { 108 deps += [ "frameworks/napi/short_key:shortkey" ] 109 } 110 } 111} 112 113group("mmi_debug_tools") { 114 deps = [ 115 "patch/diff_libinput_mmi:libinput-analyze-mmi", 116 "patch/diff_libinput_mmi:libinput-debug-mmi", 117 "patch/diff_libinput_mmi:libinput-list-mmi", 118 "patch/diff_libinput_mmi:libinput-measure-mmi", 119 "patch/diff_libinput_mmi:libinput-quirks-mmi", 120 "patch/diff_libinput_mmi:libinput-record-mmi", 121 "patch/diff_libinput_mmi:libinput-tablet-mmi", 122 "tools/event_inject:mmi-event-injection", 123 "tools/vuinput:vuinput", 124 ] 125} 126 127group("ut_mmi_debug_tools") { 128 testonly = true 129 deps = [ 130 "tools/event_inject:ut-event-injection-out", 131 "tools/vuinput:ut-virtual-device-out", 132 ] 133} 134 135group("mmi_tests") { 136 testonly = true 137 deps = [ 138 "frameworks/proxy:InputManagerFilterManualTest", 139 "frameworks/proxy:InputManagerManualTest", 140 "frameworks/proxy:InputManagerTest", 141 "frameworks/proxy:KeyEventTest", 142 "frameworks/proxy:PointerEventTest", 143 "frameworks/proxy:ut-mmi-proxy-out", 144 "libudev:test", 145 "service:TransformPointTest", 146 "service:TwoFingerLongTouchTest", 147 "service:event_resample_test", 148 "service:mmi-service-tests", 149 "service:rust_mmi_test", 150 "service:ut-mmi-service-out", 151 "test/fuzztest:test", 152 "tools/inject_event:InjectEventTest", 153 "util:rust_mmi_key_config_test", 154 "util:ut-mmi-util-out", 155 ] 156} 157 158group("examples_group") { 159 deps = [ "examples/input_device_display_bind:input_device_display_bind" ] 160} 161