blob: 21c0ef0a8166fe5994b0770c6b1dc6d9b9ac8e02 [file] [log] [blame]
Steven Moreland1b13eea2017-07-10 16:05:51 -07001cc_library_headers {
2 name: "libhealthd_headers",
3 vendor_available: true,
4 export_include_dirs: ["include"],
5 header_libs: ["libbatteryservice_headers"],
6 export_header_lib_headers: ["libbatteryservice_headers"],
7}
Yifan Hongffff9aa2017-06-01 14:34:29 -07008
9cc_library_static {
10 name: "libbatterymonitor",
11 srcs: ["BatteryMonitor.cpp"],
12 vendor_available: true,
13 export_include_dirs: ["include"],
14 shared_libs: [
15 "libutils",
16 "libbase",
17 ],
18 header_libs: ["libhealthd_headers"],
19 export_header_lib_headers: ["libhealthd_headers"],
20}
Yifan Hong2763df82017-09-19 17:57:50 -070021
22cc_library_static {
23 name: "android.hardware.health@2.0-impl",
24 vendor_available: true,
25 srcs: [
26 "Health.cpp",
27 "healthd_common.cpp",
28 ],
29
30 cflags: ["-DHEALTHD_USE_HEALTH_2_0"],
31
32 export_include_dirs: ["include"],
33
34 shared_libs: [
35 "libbase",
36 "libhidlbase",
37 "libhidltransport",
38 "libhwbinder",
39 "liblog",
40 "libutils",
41 "libcutils",
42 "android.hardware.health@2.0",
43 ],
44
45 static_libs: [
46 "libbatterymonitor",
47 "android.hardware.health@1.0-convert",
48 ],
49}
50
51cc_binary {
52 name: "android.hardware.health@2.0-service",
53 init_rc: ["android.hardware.health@2.0-service.rc"],
54 vendor: true,
55 relative_install_path: "hw",
Yifan Hongcded9002017-11-06 16:47:54 -080056 srcs: [
57 "HealthServiceCommon.cpp",
58 "HealthServiceDefault.cpp",
59 ],
Yifan Hong2763df82017-09-19 17:57:50 -070060
61 cflags: ["-DHEALTH_INSTANCE_NAME=\"default\""],
62
63 static_libs: [
64 "android.hardware.health@2.0-impl",
65 "android.hardware.health@1.0-convert",
66 "libbatterymonitor",
67 ],
68
69 shared_libs: [
70 "libbase",
71 "libcutils",
72 "libhidlbase",
73 "libhidltransport",
74 "libhwbinder",
75 "liblog",
76 "libutils",
77 "android.hardware.health@2.0",
78 ],
79}
Yifan Hong12df1b92017-09-25 17:25:00 -070080
81cc_binary {
82 name: "healthd",
Yifan Hongcded9002017-11-06 16:47:54 -080083 srcs: [
84 "HealthServiceCommon.cpp",
85 "HealthServiceHealthd.cpp",
86 ],
Yifan Hong12df1b92017-09-25 17:25:00 -070087 local_include_dirs: ["include"],
88
89 cflags: ["-DHEALTH_INSTANCE_NAME=\"backup\""],
90
91 static_libs: [
92 "android.hardware.health@2.0-impl",
93 "android.hardware.health@1.0-convert",
94 "libbatterymonitor",
95 ],
96
97 shared_libs: [
98 "libbase",
99 "libcutils",
100 "libhidlbase",
101 "libhidltransport",
102 "libhwbinder",
103 "liblog",
104 "libutils",
105 "android.hardware.health@2.0",
106 ],
107
108}