blob: ccb8773ed0b94c9729561213d73655e8dd711d01 [file] [log] [blame]
Prabir Pradhanda7c00c2019-08-29 14:12:42 -07001// Copyright (C) 2019 The Android Open Source Project
2//
3// Licensed under the Apache License, Version 2.0 (the "License");
4// you may not use this file except in compliance with the License.
5// You may obtain a copy of the License at
6//
7// http://www.apache.org/licenses/LICENSE-2.0
8//
9// Unless required by applicable law or agreed to in writing, software
10// distributed under the License is distributed on an "AS IS" BASIS,
11// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12// See the License for the specific language governing permissions and
13// limitations under the License.
14
Bob Badour3306e492021-02-25 15:35:37 -080015package {
16 // See: http://go/android-license-faq
17 // A large-scale-change added 'default_applicable_licenses' to import
18 // all of the 'license_kinds' from "frameworks_native_license"
19 // to get the below license kinds:
20 // SPDX-license-identifier-Apache-2.0
21 default_applicable_licenses: ["frameworks_native_license"],
22}
23
Prabir Pradhanda7c00c2019-08-29 14:12:42 -070024cc_library_headers {
25 name: "libinputreader_headers",
Siarhei Vishniakou31977182022-09-30 08:51:23 -070026 host_supported: true,
Prabir Pradhan2770d242019-09-02 18:07:11 -070027 export_include_dirs: [
Chris Yee2b1e5c2021-03-10 22:45:12 -080028 "controller",
Prabir Pradhan2770d242019-09-02 18:07:11 -070029 "include",
30 "mapper",
31 "mapper/accumulator",
Harry Cutts47db1c72022-12-13 19:20:47 +000032 "mapper/gestures",
Prabir Pradhan2770d242019-09-02 18:07:11 -070033 ],
Prabir Pradhanda7c00c2019-08-29 14:12:42 -070034}
35
Prabir Pradhan9244aea2020-02-05 20:31:40 -080036filegroup {
37 name: "libinputreader_sources",
Prabir Pradhanda7c00c2019-08-29 14:12:42 -070038 srcs: [
39 "EventHub.cpp",
Prabir Pradhanbaa5c822019-08-30 15:27:05 -070040 "InputDevice.cpp",
Siarhei Vishniakou31977182022-09-30 08:51:23 -070041 "InputReader.cpp",
Prabir Pradhan011ca3d2023-02-22 21:31:39 +000042 "Macros.cpp",
Siarhei Vishniakou31977182022-09-30 08:51:23 -070043 "TouchVideoDevice.cpp",
Chris Ye1dd2e5c2021-04-04 23:12:41 -070044 "controller/PeripheralController.cpp",
Harry Cuttsbb24e272023-03-21 10:49:47 +000045 "mapper/CapturedTouchpadEventConverter.cpp",
Prabir Pradhan2770d242019-09-02 18:07:11 -070046 "mapper/CursorInputMapper.cpp",
47 "mapper/ExternalStylusInputMapper.cpp",
48 "mapper/InputMapper.cpp",
49 "mapper/JoystickInputMapper.cpp",
50 "mapper/KeyboardInputMapper.cpp",
51 "mapper/MultiTouchInputMapper.cpp",
52 "mapper/RotaryEncoderInputMapper.cpp",
Chris Yef59a2f42020-10-16 12:55:26 -070053 "mapper/SensorInputMapper.cpp",
Prabir Pradhan2770d242019-09-02 18:07:11 -070054 "mapper/SingleTouchInputMapper.cpp",
55 "mapper/SwitchInputMapper.cpp",
Harry Cuttsb1a00842022-12-06 16:20:29 +000056 "mapper/TouchCursorInputMapperCommon.cpp",
Prabir Pradhan2770d242019-09-02 18:07:11 -070057 "mapper/TouchInputMapper.cpp",
Harry Cutts79cc9fa2022-10-28 15:32:39 +000058 "mapper/TouchpadInputMapper.cpp",
Prabir Pradhan2770d242019-09-02 18:07:11 -070059 "mapper/VibratorInputMapper.cpp",
Siarhei Vishniakou31977182022-09-30 08:51:23 -070060 "mapper/accumulator/CursorButtonAccumulator.cpp",
61 "mapper/accumulator/CursorScrollAccumulator.cpp",
Prabir Pradhan84395e62022-10-26 19:52:00 +000062 "mapper/accumulator/HidUsageAccumulator.cpp",
Harry Cutts2d77f552022-11-07 12:10:56 +000063 "mapper/accumulator/MultiTouchMotionAccumulator.cpp",
Siarhei Vishniakou31977182022-09-30 08:51:23 -070064 "mapper/accumulator/SingleTouchMotionAccumulator.cpp",
65 "mapper/accumulator/TouchButtonAccumulator.cpp",
Harry Cutts4fb941a2022-12-14 19:14:04 +000066 "mapper/gestures/GestureConverter.cpp",
Ben Murdoch50244822022-10-31 10:41:01 +000067 "mapper/gestures/GesturesLogging.cpp",
Harry Cutts47db1c72022-12-13 19:20:47 +000068 "mapper/gestures/HardwareStateConverter.cpp",
Harry Cutts1b217912023-01-03 17:13:19 +000069 "mapper/gestures/PropertyProvider.cpp",
Prabir Pradhanda7c00c2019-08-29 14:12:42 -070070 ],
Prabir Pradhan9244aea2020-02-05 20:31:40 -080071}
Prabir Pradhanda7c00c2019-08-29 14:12:42 -070072
Prabir Pradhan9244aea2020-02-05 20:31:40 -080073cc_defaults {
74 name: "libinputreader_defaults",
75 srcs: [":libinputreader_sources"],
Prabir Pradhanda7c00c2019-08-29 14:12:42 -070076 shared_libs: [
77 "libbase",
Siarhei Vishniakou7a522bf2019-09-24 12:46:29 +010078 "libcap",
Prabir Pradhanda7c00c2019-08-29 14:12:42 -070079 "libcrypto",
80 "libcutils",
Ben Murdoch50244822022-10-31 10:41:01 +000081 "libjsoncpp",
Prabir Pradhanda7c00c2019-08-29 14:12:42 -070082 "liblog",
Siarhei Vishniakou9faa4462022-12-06 11:45:04 -080083 "libPlatformProperties",
Chris Yed3fef462021-03-07 17:10:08 -080084 "libstatslog",
Prabir Pradhanda7c00c2019-08-29 14:12:42 -070085 "libutils",
Prabir Pradhanda7c00c2019-08-29 14:12:42 -070086 ],
Kim Low03ea0352020-11-06 12:45:07 -080087 static_libs: [
88 "libc++fs",
Ben Murdoch50244822022-10-31 10:41:01 +000089 "libchrome-gestures",
Siarhei Vishniakou862ae212022-09-28 15:17:28 -070090 "libui-types",
Kim Low03ea0352020-11-06 12:45:07 -080091 ],
Prabir Pradhanda7c00c2019-08-29 14:12:42 -070092 header_libs: [
Kim Low03ea0352020-11-06 12:45:07 -080093 "libbatteryservice_headers",
Prabir Pradhanc5e1ca42022-11-28 22:01:56 +000094 "libchrome-gestures_headers",
Prabir Pradhanda7c00c2019-08-29 14:12:42 -070095 "libinputreader_headers",
96 ],
Siarhei Vishniakou31977182022-09-30 08:51:23 -070097 target: {
98 android: {
99 shared_libs: [
Siarhei Vishniakou31977182022-09-30 08:51:23 -0700100 "libinput",
Harry Cuttsa34de522023-06-06 15:52:54 +0000101 "libstatspull",
Siarhei Vishniakou31977182022-09-30 08:51:23 -0700102 ],
103 },
104 host: {
105 static_libs: [
106 "libinput",
Colin Cross5b799302022-10-18 21:52:41 -0700107 "libbinder",
Harry Cuttsa34de522023-06-06 15:52:54 +0000108 "libstatspull",
Siarhei Vishniakou31977182022-09-30 08:51:23 -0700109 ],
110 },
111 },
Prabir Pradhan9244aea2020-02-05 20:31:40 -0800112}
Prabir Pradhanda7c00c2019-08-29 14:12:42 -0700113
Prabir Pradhanc5e1ca42022-11-28 22:01:56 +0000114cc_library_static {
115 name: "libinputreader_static",
116 defaults: [
117 "inputflinger_defaults",
118 "libinputreader_defaults",
119 ],
120 shared_libs: [
121 "libinputflinger_base",
122 ],
123 export_header_lib_headers: [
124 "libbatteryservice_headers",
125 "libchrome-gestures_headers",
126 "libinputreader_headers",
127 ],
Harry Cuttse23e22d2022-12-06 17:00:57 +0000128 whole_static_libs: [
129 "libchrome-gestures",
130 ],
Prabir Pradhanc5e1ca42022-11-28 22:01:56 +0000131}
132
Prabir Pradhan9244aea2020-02-05 20:31:40 -0800133cc_library_shared {
134 name: "libinputreader",
Siarhei Vishniakou31977182022-09-30 08:51:23 -0700135 host_supported: true,
Prabir Pradhan9244aea2020-02-05 20:31:40 -0800136 defaults: [
137 "inputflinger_defaults",
Prabir Pradhan8b89c2f2021-07-29 16:30:14 +0000138 "libinputreader_defaults",
Prabir Pradhan9244aea2020-02-05 20:31:40 -0800139 ],
140 srcs: [
141 "InputReaderFactory.cpp",
142 ],
143 shared_libs: [
144 // This should consist only of dependencies from inputflinger. Other dependencies should be
145 // in cc_defaults so that they are included in the tests.
146 "libinputflinger_base",
Harry Cutts1f48a442022-11-15 17:38:36 +0000147 "libjsoncpp",
Prabir Pradhan9244aea2020-02-05 20:31:40 -0800148 ],
Prabir Pradhanda7c00c2019-08-29 14:12:42 -0700149 export_header_lib_headers: [
Prabir Pradhan9244aea2020-02-05 20:31:40 -0800150 "libinputreader_headers",
Prabir Pradhanda7c00c2019-08-29 14:12:42 -0700151 ],
Siarhei Vishniakou31977182022-09-30 08:51:23 -0700152 target: {
153 host: {
154 include_dirs: [
155 "bionic/libc/kernel/android/uapi/",
156 "bionic/libc/kernel/uapi",
157 ],
158 },
159 },
Chris Ye8594e192020-07-14 10:34:06 -0700160 static_libs: [
Prabir Pradhan8b89c2f2021-07-29 16:30:14 +0000161 "libc++fs",
Harry Cutts1f48a442022-11-15 17:38:36 +0000162 "libchrome-gestures",
Chris Ye8594e192020-07-14 10:34:06 -0700163 ],
Prabir Pradhanda7c00c2019-08-29 14:12:42 -0700164}