blob: bb16c0909ce2251094cb0da79615973976e8211a [file] [log] [blame]
Stephen Kiazyke77dce22017-03-14 15:38:12 -07001
2
3// Touchpad implementation.
4
5src = [
6 "EvdevInjector.cpp",
7 "VirtualTouchpadEvdev.cpp",
8]
9
10shared_libs = [
11 "libbase",
12 "liblog",
13 "libutils",
14]
15
John Bates14bc55a2017-05-26 09:00:08 -070016header_libraries = [
Logan Chien3e60b392018-02-27 16:00:11 +080017 "libdvr_headers",
John Bates14bc55a2017-05-26 09:00:08 -070018]
19
Stephen Kiazyke77dce22017-03-14 15:38:12 -070020cc_library {
21 srcs: src,
22 export_include_dirs: ["include"],
23 shared_libs: shared_libs,
John Bates14bc55a2017-05-26 09:00:08 -070024 header_libs: header_libraries,
Stephen Kiazyke77dce22017-03-14 15:38:12 -070025 cppflags: ["-std=c++11"],
Chih-Hung Hsiehe27d5eb2017-10-31 15:39:40 -070026 cflags: [
27 "-DLOG_TAG=\"VrVirtualTouchpad\"",
28 "-Wall",
29 "-Werror",
30 ],
Stephen Kiazyke77dce22017-03-14 15:38:12 -070031 name: "libvirtualtouchpad",
Stephen Kiazyke77dce22017-03-14 15:38:12 -070032}
33
34// Touchpad unit tests.
35
36test_static_libs = [
37 "libcutils",
38 "libvirtualtouchpad",
Stephen Kiazyke77dce22017-03-14 15:38:12 -070039 "libbase",
40 "liblog",
41 "libutils",
42]
43
44test_src_files = ["tests/VirtualTouchpad_test.cpp"]
45
46cc_test {
47 srcs: test_src_files,
48 static_libs: test_static_libs,
John Bates14bc55a2017-05-26 09:00:08 -070049 header_libs: header_libraries,
Logan Chien3e60b392018-02-27 16:00:11 +080050 cflags: [
Chih-Hung Hsiehe27d5eb2017-10-31 15:39:40 -070051 "-Wall",
52 "-Werror",
53 ],
Logan Chien3e60b392018-02-27 16:00:11 +080054 cppflags: [
Stephen Kiazyke77dce22017-03-14 15:38:12 -070055 "-std=c++11",
56 ],
Logan Chien3e60b392018-02-27 16:00:11 +080057 host_ldlibs: [
Stephen Kiazyke77dce22017-03-14 15:38:12 -070058 "-llog",
59 ],
60 name: "VirtualTouchpad_test",
61 stl: "libc++_static",
Stephen Kiazyke77dce22017-03-14 15:38:12 -070062}
63
64// Service.
65
66service_src = [
67 "main.cpp",
68 "VirtualTouchpadService.cpp",
69 "aidl/android/dvr/VirtualTouchpadService.aidl",
70]
71
72service_static_libs = [
73 "libcutils",
74 "libvirtualtouchpad",
75]
76
77service_shared_libs = [
78 "libbase",
79 "libbinder",
80 "liblog",
81 "libutils",
82]
83
84cc_binary {
85 srcs: service_src,
86 static_libs: service_static_libs,
87 shared_libs: service_shared_libs,
John Bates14bc55a2017-05-26 09:00:08 -070088 header_libs: header_libraries,
Stephen Kiazyke77dce22017-03-14 15:38:12 -070089 cppflags: ["-std=c++11"],
90 cflags: [
91 "-DLOG_TAG=\"VrVirtualTouchpad\"",
Chih-Hung Hsiehe27d5eb2017-10-31 15:39:40 -070092 "-Wall",
93 "-Werror",
Stephen Kiazyke77dce22017-03-14 15:38:12 -070094 ],
95 host_ldlibs: ["-llog"],
96 name: "virtual_touchpad",
Stephen Kiazyke77dce22017-03-14 15:38:12 -070097 init_rc: ["virtual_touchpad.rc"],
98 compile_multilib: "64",
99 stl: "libc++_static",
100}
101
102// Touchpad client library.
103
104client_src = [
105 "VirtualTouchpadClient.cpp",
Kevin Schoedelde1cdae2017-03-17 11:07:06 -0400106 "DvrVirtualTouchpadClient.cpp",
Stephen Kiazyke77dce22017-03-14 15:38:12 -0700107 "aidl/android/dvr/VirtualTouchpadService.aidl",
108]
109
110client_shared_libs = [
111 "libbase",
112 "libbinder",
113 "liblog",
114 "libutils",
115]
116
117cc_library {
118 srcs: client_src,
119 shared_libs: client_shared_libs,
John Bates14bc55a2017-05-26 09:00:08 -0700120 header_libs: header_libraries,
Stephen Kiazyke77dce22017-03-14 15:38:12 -0700121 cppflags: ["-std=c++11"],
Chih-Hung Hsiehe27d5eb2017-10-31 15:39:40 -0700122 cflags: [
123 "-DLOG_TAG=\"VirtualTouchpadClient\"",
124 "-Wall",
125 "-Werror",
126 ],
Stephen Kiazyke77dce22017-03-14 15:38:12 -0700127 host_ldlibs: ["-llog"],
128 name: "libvirtualtouchpadclient",
Stephen Kiazyke77dce22017-03-14 15:38:12 -0700129 export_include_dirs: ["include"],
130}