Prabir Pradhan | da7c00c | 2019-08-29 14:12:42 -0700 | [diff] [blame] | 1 | // 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 Badour | 3306e49 | 2021-02-25 15:35:37 -0800 | [diff] [blame] | 15 | package { |
| 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 Pradhan | da7c00c | 2019-08-29 14:12:42 -0700 | [diff] [blame] | 24 | cc_library_headers { |
| 25 | name: "libinputreader_headers", |
Siarhei Vishniakou | 3197718 | 2022-09-30 08:51:23 -0700 | [diff] [blame] | 26 | host_supported: true, |
Prabir Pradhan | 2770d24 | 2019-09-02 18:07:11 -0700 | [diff] [blame] | 27 | export_include_dirs: [ |
Chris Ye | e2b1e5c | 2021-03-10 22:45:12 -0800 | [diff] [blame] | 28 | "controller", |
Prabir Pradhan | 2770d24 | 2019-09-02 18:07:11 -0700 | [diff] [blame] | 29 | "include", |
| 30 | "mapper", |
| 31 | "mapper/accumulator", |
| 32 | ], |
Prabir Pradhan | da7c00c | 2019-08-29 14:12:42 -0700 | [diff] [blame] | 33 | } |
| 34 | |
Prabir Pradhan | 9244aea | 2020-02-05 20:31:40 -0800 | [diff] [blame] | 35 | filegroup { |
| 36 | name: "libinputreader_sources", |
Prabir Pradhan | da7c00c | 2019-08-29 14:12:42 -0700 | [diff] [blame] | 37 | srcs: [ |
| 38 | "EventHub.cpp", |
Prabir Pradhan | baa5c82 | 2019-08-30 15:27:05 -0700 | [diff] [blame] | 39 | "InputDevice.cpp", |
Siarhei Vishniakou | 3197718 | 2022-09-30 08:51:23 -0700 | [diff] [blame] | 40 | "InputReader.cpp", |
| 41 | "TouchVideoDevice.cpp", |
Chris Ye | 1dd2e5c | 2021-04-04 23:12:41 -0700 | [diff] [blame] | 42 | "controller/PeripheralController.cpp", |
Prabir Pradhan | 2770d24 | 2019-09-02 18:07:11 -0700 | [diff] [blame] | 43 | "mapper/CursorInputMapper.cpp", |
| 44 | "mapper/ExternalStylusInputMapper.cpp", |
| 45 | "mapper/InputMapper.cpp", |
| 46 | "mapper/JoystickInputMapper.cpp", |
| 47 | "mapper/KeyboardInputMapper.cpp", |
| 48 | "mapper/MultiTouchInputMapper.cpp", |
| 49 | "mapper/RotaryEncoderInputMapper.cpp", |
Chris Ye | f59a2f4 | 2020-10-16 12:55:26 -0700 | [diff] [blame] | 50 | "mapper/SensorInputMapper.cpp", |
Prabir Pradhan | 2770d24 | 2019-09-02 18:07:11 -0700 | [diff] [blame] | 51 | "mapper/SingleTouchInputMapper.cpp", |
| 52 | "mapper/SwitchInputMapper.cpp", |
| 53 | "mapper/TouchInputMapper.cpp", |
Harry Cutts | 79cc9fa | 2022-10-28 15:32:39 +0000 | [diff] [blame] | 54 | "mapper/TouchpadInputMapper.cpp", |
Prabir Pradhan | 2770d24 | 2019-09-02 18:07:11 -0700 | [diff] [blame] | 55 | "mapper/VibratorInputMapper.cpp", |
Siarhei Vishniakou | 3197718 | 2022-09-30 08:51:23 -0700 | [diff] [blame] | 56 | "mapper/accumulator/CursorButtonAccumulator.cpp", |
| 57 | "mapper/accumulator/CursorScrollAccumulator.cpp", |
Prabir Pradhan | 84395e6 | 2022-10-26 19:52:00 +0000 | [diff] [blame] | 58 | "mapper/accumulator/HidUsageAccumulator.cpp", |
Harry Cutts | 2d77f55 | 2022-11-07 12:10:56 +0000 | [diff] [blame] | 59 | "mapper/accumulator/MultiTouchMotionAccumulator.cpp", |
Siarhei Vishniakou | 3197718 | 2022-09-30 08:51:23 -0700 | [diff] [blame] | 60 | "mapper/accumulator/SingleTouchMotionAccumulator.cpp", |
| 61 | "mapper/accumulator/TouchButtonAccumulator.cpp", |
Ben Murdoch | 5024482 | 2022-10-31 10:41:01 +0000 | [diff] [blame] | 62 | "mapper/gestures/GesturesLogging.cpp", |
Prabir Pradhan | da7c00c | 2019-08-29 14:12:42 -0700 | [diff] [blame] | 63 | ], |
Prabir Pradhan | 9244aea | 2020-02-05 20:31:40 -0800 | [diff] [blame] | 64 | } |
Prabir Pradhan | da7c00c | 2019-08-29 14:12:42 -0700 | [diff] [blame] | 65 | |
Prabir Pradhan | 9244aea | 2020-02-05 20:31:40 -0800 | [diff] [blame] | 66 | cc_defaults { |
| 67 | name: "libinputreader_defaults", |
| 68 | srcs: [":libinputreader_sources"], |
Prabir Pradhan | da7c00c | 2019-08-29 14:12:42 -0700 | [diff] [blame] | 69 | shared_libs: [ |
| 70 | "libbase", |
Siarhei Vishniakou | 7a522bf | 2019-09-24 12:46:29 +0100 | [diff] [blame] | 71 | "libcap", |
Prabir Pradhan | da7c00c | 2019-08-29 14:12:42 -0700 | [diff] [blame] | 72 | "libcrypto", |
| 73 | "libcutils", |
Ben Murdoch | 5024482 | 2022-10-31 10:41:01 +0000 | [diff] [blame] | 74 | "libjsoncpp", |
Prabir Pradhan | da7c00c | 2019-08-29 14:12:42 -0700 | [diff] [blame] | 75 | "liblog", |
Chris Ye | d3fef46 | 2021-03-07 17:10:08 -0800 | [diff] [blame] | 76 | "libstatslog", |
Prabir Pradhan | da7c00c | 2019-08-29 14:12:42 -0700 | [diff] [blame] | 77 | "libutils", |
Prabir Pradhan | da7c00c | 2019-08-29 14:12:42 -0700 | [diff] [blame] | 78 | ], |
Kim Low | 03ea035 | 2020-11-06 12:45:07 -0800 | [diff] [blame] | 79 | static_libs: [ |
| 80 | "libc++fs", |
Ben Murdoch | 5024482 | 2022-10-31 10:41:01 +0000 | [diff] [blame] | 81 | "libchrome-gestures", |
Siarhei Vishniakou | 862ae21 | 2022-09-28 15:17:28 -0700 | [diff] [blame] | 82 | "libui-types", |
Kim Low | 03ea035 | 2020-11-06 12:45:07 -0800 | [diff] [blame] | 83 | ], |
Prabir Pradhan | da7c00c | 2019-08-29 14:12:42 -0700 | [diff] [blame] | 84 | header_libs: [ |
Kim Low | 03ea035 | 2020-11-06 12:45:07 -0800 | [diff] [blame] | 85 | "libbatteryservice_headers", |
Prabir Pradhan | c5e1ca4 | 2022-11-28 22:01:56 +0000 | [diff] [blame] | 86 | "libchrome-gestures_headers", |
Prabir Pradhan | da7c00c | 2019-08-29 14:12:42 -0700 | [diff] [blame] | 87 | "libinputreader_headers", |
| 88 | ], |
Siarhei Vishniakou | 3197718 | 2022-09-30 08:51:23 -0700 | [diff] [blame] | 89 | target: { |
| 90 | android: { |
| 91 | shared_libs: [ |
| 92 | "libPlatformProperties", |
| 93 | "libinput", |
| 94 | ], |
| 95 | }, |
| 96 | host: { |
| 97 | static_libs: [ |
| 98 | "libinput", |
Colin Cross | 5b79930 | 2022-10-18 21:52:41 -0700 | [diff] [blame] | 99 | "libbinder", |
Siarhei Vishniakou | 3197718 | 2022-09-30 08:51:23 -0700 | [diff] [blame] | 100 | ], |
| 101 | }, |
| 102 | }, |
Prabir Pradhan | 9244aea | 2020-02-05 20:31:40 -0800 | [diff] [blame] | 103 | } |
Prabir Pradhan | da7c00c | 2019-08-29 14:12:42 -0700 | [diff] [blame] | 104 | |
Prabir Pradhan | c5e1ca4 | 2022-11-28 22:01:56 +0000 | [diff] [blame] | 105 | cc_library_static { |
| 106 | name: "libinputreader_static", |
| 107 | defaults: [ |
| 108 | "inputflinger_defaults", |
| 109 | "libinputreader_defaults", |
| 110 | ], |
| 111 | shared_libs: [ |
| 112 | "libinputflinger_base", |
| 113 | ], |
| 114 | export_header_lib_headers: [ |
| 115 | "libbatteryservice_headers", |
| 116 | "libchrome-gestures_headers", |
| 117 | "libinputreader_headers", |
| 118 | ], |
Harry Cutts | e23e22d | 2022-12-06 17:00:57 +0000 | [diff] [blame] | 119 | whole_static_libs: [ |
| 120 | "libchrome-gestures", |
| 121 | ], |
Prabir Pradhan | c5e1ca4 | 2022-11-28 22:01:56 +0000 | [diff] [blame] | 122 | } |
| 123 | |
Prabir Pradhan | 9244aea | 2020-02-05 20:31:40 -0800 | [diff] [blame] | 124 | cc_library_shared { |
| 125 | name: "libinputreader", |
Siarhei Vishniakou | 3197718 | 2022-09-30 08:51:23 -0700 | [diff] [blame] | 126 | host_supported: true, |
Prabir Pradhan | 9244aea | 2020-02-05 20:31:40 -0800 | [diff] [blame] | 127 | defaults: [ |
| 128 | "inputflinger_defaults", |
Prabir Pradhan | 8b89c2f | 2021-07-29 16:30:14 +0000 | [diff] [blame] | 129 | "libinputreader_defaults", |
Prabir Pradhan | 9244aea | 2020-02-05 20:31:40 -0800 | [diff] [blame] | 130 | ], |
| 131 | srcs: [ |
| 132 | "InputReaderFactory.cpp", |
| 133 | ], |
| 134 | shared_libs: [ |
| 135 | // This should consist only of dependencies from inputflinger. Other dependencies should be |
| 136 | // in cc_defaults so that they are included in the tests. |
| 137 | "libinputflinger_base", |
Harry Cutts | 1f48a44 | 2022-11-15 17:38:36 +0000 | [diff] [blame] | 138 | "libjsoncpp", |
Prabir Pradhan | 9244aea | 2020-02-05 20:31:40 -0800 | [diff] [blame] | 139 | ], |
Prabir Pradhan | da7c00c | 2019-08-29 14:12:42 -0700 | [diff] [blame] | 140 | export_header_lib_headers: [ |
Prabir Pradhan | 9244aea | 2020-02-05 20:31:40 -0800 | [diff] [blame] | 141 | "libinputreader_headers", |
Prabir Pradhan | da7c00c | 2019-08-29 14:12:42 -0700 | [diff] [blame] | 142 | ], |
Siarhei Vishniakou | 3197718 | 2022-09-30 08:51:23 -0700 | [diff] [blame] | 143 | target: { |
| 144 | host: { |
| 145 | include_dirs: [ |
| 146 | "bionic/libc/kernel/android/uapi/", |
| 147 | "bionic/libc/kernel/uapi", |
| 148 | ], |
| 149 | }, |
| 150 | }, |
Chris Ye | 8594e19 | 2020-07-14 10:34:06 -0700 | [diff] [blame] | 151 | static_libs: [ |
Prabir Pradhan | 8b89c2f | 2021-07-29 16:30:14 +0000 | [diff] [blame] | 152 | "libc++fs", |
Harry Cutts | 1f48a44 | 2022-11-15 17:38:36 +0000 | [diff] [blame] | 153 | "libchrome-gestures", |
Chris Ye | 8594e19 | 2020-07-14 10:34:06 -0700 | [diff] [blame] | 154 | ], |
Prabir Pradhan | da7c00c | 2019-08-29 14:12:42 -0700 | [diff] [blame] | 155 | } |