Build libinputflinger for host
We don't have a usecase for it today, but the main motivation here is to
unify the target and host build parameters.
Also, this exposed an issue where ::write wasn't wrapped.
The host build produced an error:
frameworks/native/services/inputflinger/InputManager.cpp:189:5: error: ignoring return value of function declared with 'warn_unused_result' attribute [-Werror,-Wunused-result]
::write(fd, dump.c_str(), dump.size());
Bug: 271455682
Test: m libinputflinger
Change-Id: If1abc85b230f8e928422dab4c6bb33834b6393ee
diff --git a/libs/input/Android.bp b/libs/input/Android.bp
index f777f2f..6db7b47 100644
--- a/libs/input/Android.bp
+++ b/libs/input/Android.bp
@@ -120,9 +120,11 @@
"-Wno-unused-parameter",
],
srcs: [
+ "android/os/IInputFlinger.aidl",
"Input.cpp",
"InputDevice.cpp",
"InputEventLabels.cpp",
+ "InputTransport.cpp",
"InputVerifier.cpp",
"Keyboard.cpp",
"KeyCharacterMap.cpp",
@@ -153,6 +155,7 @@
shared_libs: [
"libbase",
+ "libbinder",
"libcutils",
"liblog",
"libPlatformProperties",
@@ -172,6 +175,7 @@
static_libs: [
"inputconstants-cpp",
+ "libgui_window_info_static",
"libui-types",
"libtflite_static",
],
@@ -181,6 +185,7 @@
],
export_static_lib_headers: [
+ "libgui_window_info_static",
"libui-types",
],
@@ -191,24 +196,10 @@
target: {
android: {
- srcs: [
- "InputTransport.cpp",
- "android/os/IInputFlinger.aidl",
- ],
-
export_shared_lib_headers: ["libbinder"],
shared_libs: [
"libutils",
- "libbinder",
- ],
-
- static_libs: [
- "libgui_window_info_static",
- ],
-
- export_static_lib_headers: [
- "libgui_window_info_static",
],
required: [
@@ -223,21 +214,6 @@
"frameworks/native/libs/arect/include",
],
},
- host_linux: {
- srcs: [
- "InputTransport.cpp",
- ],
- static_libs: [
- "libgui_window_info_static",
- ],
- shared_libs: [
- "libbinder",
- ],
-
- export_static_lib_headers: [
- "libgui_window_info_static",
- ],
- },
},
aidl: {