Stephen Kiazyk | e77dce2 | 2017-03-14 15:38:12 -0700 | [diff] [blame] | 1 | |
| 2 | |
| 3 | // Touchpad implementation. |
| 4 | |
| 5 | src = [ |
| 6 | "EvdevInjector.cpp", |
| 7 | "VirtualTouchpadEvdev.cpp", |
| 8 | ] |
| 9 | |
| 10 | shared_libs = [ |
| 11 | "libbase", |
| 12 | "liblog", |
| 13 | "libutils", |
| 14 | ] |
| 15 | |
| 16 | cc_library { |
| 17 | srcs: src, |
| 18 | export_include_dirs: ["include"], |
| 19 | shared_libs: shared_libs, |
| 20 | cppflags: ["-std=c++11"], |
Chih-Hung Hsieh | 38a1192 | 2017-10-05 14:27:38 -0700 | [diff] [blame^] | 21 | cflags: [ |
| 22 | "-DLOG_TAG=\"VrVirtualTouchpad\"", |
| 23 | "-Wall", |
| 24 | "-Werror", |
| 25 | ], |
Stephen Kiazyk | e77dce2 | 2017-03-14 15:38:12 -0700 | [diff] [blame] | 26 | name: "libvirtualtouchpad", |
| 27 | tags: ["optional"], |
| 28 | } |
| 29 | |
| 30 | // Touchpad unit tests. |
| 31 | |
| 32 | test_static_libs = [ |
| 33 | "libcutils", |
| 34 | "libvirtualtouchpad", |
| 35 | ] |
| 36 | |
| 37 | test_shared_libs = [ |
| 38 | "libbase", |
| 39 | "liblog", |
| 40 | "libutils", |
| 41 | ] |
| 42 | |
| 43 | test_src_files = ["tests/VirtualTouchpad_test.cpp"] |
| 44 | |
| 45 | cc_test { |
| 46 | srcs: test_src_files, |
| 47 | static_libs: test_static_libs, |
| 48 | shared_libs: test_shared_libs, |
| 49 | cppflags = [ |
| 50 | "-std=c++11", |
| 51 | ], |
| 52 | host_ldlibs = [ |
| 53 | "-llog", |
| 54 | ], |
| 55 | name: "VirtualTouchpad_test", |
| 56 | stl: "libc++_static", |
| 57 | tags: [ "optional" ], |
Chih-Hung Hsieh | 38a1192 | 2017-10-05 14:27:38 -0700 | [diff] [blame^] | 58 | cflags: [ |
| 59 | "-Wall", |
| 60 | "-Werror", |
| 61 | "-Wno-unused-function", |
| 62 | "-Wno-unused-variable", |
| 63 | ], |
Stephen Kiazyk | e77dce2 | 2017-03-14 15:38:12 -0700 | [diff] [blame] | 64 | } |
| 65 | |
| 66 | // Service. |
| 67 | |
| 68 | service_src = [ |
| 69 | "main.cpp", |
| 70 | "VirtualTouchpadService.cpp", |
| 71 | "aidl/android/dvr/VirtualTouchpadService.aidl", |
| 72 | ] |
| 73 | |
| 74 | service_static_libs = [ |
| 75 | "libcutils", |
| 76 | "libvirtualtouchpad", |
| 77 | ] |
| 78 | |
| 79 | service_shared_libs = [ |
| 80 | "libbase", |
| 81 | "libbinder", |
| 82 | "liblog", |
| 83 | "libutils", |
| 84 | ] |
| 85 | |
| 86 | cc_binary { |
| 87 | srcs: service_src, |
| 88 | static_libs: service_static_libs, |
| 89 | shared_libs: service_shared_libs, |
| 90 | cppflags: ["-std=c++11"], |
| 91 | cflags: [ |
| 92 | "-DLOG_TAG=\"VrVirtualTouchpad\"", |
Chih-Hung Hsieh | 38a1192 | 2017-10-05 14:27:38 -0700 | [diff] [blame^] | 93 | "-Wall", |
| 94 | "-Werror", |
Stephen Kiazyk | e77dce2 | 2017-03-14 15:38:12 -0700 | [diff] [blame] | 95 | ], |
| 96 | host_ldlibs: ["-llog"], |
| 97 | name: "virtual_touchpad", |
| 98 | tags: ["optional"], |
| 99 | init_rc: ["virtual_touchpad.rc"], |
| 100 | compile_multilib: "64", |
| 101 | stl: "libc++_static", |
| 102 | } |
| 103 | |
| 104 | // Touchpad client library. |
| 105 | |
| 106 | client_src = [ |
| 107 | "VirtualTouchpadClient.cpp", |
Kevin Schoedel | de1cdae | 2017-03-17 11:07:06 -0400 | [diff] [blame] | 108 | "DvrVirtualTouchpadClient.cpp", |
Stephen Kiazyk | e77dce2 | 2017-03-14 15:38:12 -0700 | [diff] [blame] | 109 | "aidl/android/dvr/VirtualTouchpadService.aidl", |
| 110 | ] |
| 111 | |
| 112 | client_shared_libs = [ |
| 113 | "libbase", |
| 114 | "libbinder", |
| 115 | "liblog", |
| 116 | "libutils", |
| 117 | ] |
| 118 | |
| 119 | cc_library { |
| 120 | srcs: client_src, |
| 121 | shared_libs: client_shared_libs, |
| 122 | cppflags: ["-std=c++11"], |
Chih-Hung Hsieh | 38a1192 | 2017-10-05 14:27:38 -0700 | [diff] [blame^] | 123 | cflags: [ |
| 124 | "-DLOG_TAG=\"VirtualTouchpadClient\"", |
| 125 | "-Wall", |
| 126 | "-Werror", |
| 127 | ], |
Stephen Kiazyk | e77dce2 | 2017-03-14 15:38:12 -0700 | [diff] [blame] | 128 | host_ldlibs: ["-llog"], |
| 129 | name: "libvirtualtouchpadclient", |
| 130 | tags: ["optional"], |
| 131 | export_include_dirs: ["include"], |
| 132 | } |