platform_system_core/healthd/Android.bp
Yifan Hong dbaa477a70 healthd: Convert libhealthd_{draw,charger} to Soong.
Converting charger to Soong, one step at a time.

In the meantime, drop the use of BOARD_*/TARGET_* variables
in Android.mk because runtime sysprops will be used instead.
Libraries / binaries will always link to libminui / libpng /
libsuspend.

charger{.recovery,} can't be converted to Soong yet because
of the use of HAL_STATIC_LIBRARIES (Bug 127677771).

charger_test isn't converted because of the shared list
of CHARGER_{STATIC,SHARED}_LIBRARIES.

Bug: 124118169
Test: run charger on walleye

Change-Id: I355deda14e5b5c9938256ff0b778590ac0191095
2019-07-24 17:01:40 -07:00

164 lines
3.3 KiB
Text

cc_library_headers {
name: "libhealthd_headers",
vendor_available: true,
recovery_available: true,
export_include_dirs: ["include"],
header_libs: ["libbatteryservice_headers"],
export_header_lib_headers: ["libbatteryservice_headers"],
}
cc_library_static {
name: "libbatterymonitor",
srcs: ["BatteryMonitor.cpp"],
cflags: ["-Wall", "-Werror"],
vendor_available: true,
recovery_available: true,
export_include_dirs: ["include"],
shared_libs: [
"libutils",
"libbase",
],
header_libs: ["libhealthd_headers"],
export_header_lib_headers: ["libhealthd_headers"],
}
cc_defaults {
name: "android.hardware.health@2.0-service_defaults",
cflags: [
"-Wall",
"-Werror",
],
static_libs: [
"android.hardware.health@2.0-impl",
"android.hardware.health@1.0-convert",
"libhealthservice",
"libhealthstoragedefault",
"libbatterymonitor",
],
shared_libs: [
"libbase",
"libcutils",
"libhidlbase",
"libhidltransport",
"libhwbinder",
"liblog",
"libutils",
"android.hardware.health@2.0",
],
}
cc_binary {
name: "android.hardware.health@2.0-service",
defaults: ["android.hardware.health@2.0-service_defaults"],
vendor: true,
relative_install_path: "hw",
init_rc: ["android.hardware.health@2.0-service.rc"],
srcs: [
"HealthServiceDefault.cpp",
],
overrides: [
"healthd",
]
}
cc_binary {
name: "healthd",
defaults: ["android.hardware.health@2.0-service_defaults"],
init_rc: ["healthd.rc"],
srcs: [
"HealthServiceHealthd.cpp",
],
local_include_dirs: ["include"],
shared_libs: [
"android.hardware.health@1.0",
],
vintf_fragments: [
"manifest_healthd.xml"
],
}
cc_library_static {
name: "libhealthd_charger_nops",
srcs: [
"healthd_mode_charger_nops.cpp",
],
cflags: [
"-Wall",
"-Werror",
],
header_libs: [
"libhealthd_headers",
],
static_libs: [
"android.hardware.health@2.0-impl",
],
shared_libs: [
"android.hardware.health@2.0",
"libutils",
],
}
sysprop_library {
name: "charger_sysprop",
srcs: ["charger.sysprop"],
property_owner: "Platform",
api_packages: ["android.sysprop"],
}
cc_library_static {
name: "libhealthd_draw",
export_include_dirs: ["."],
static_libs: [
"libcharger_sysprop",
"libminui",
],
shared_libs: [
"libbase",
],
header_libs: ["libbatteryservice_headers"],
srcs: ["healthd_draw.cpp"],
}
cc_library_static {
name: "libhealthd_charger",
local_include_dirs: ["include"],
export_include_dirs: [".", "include"],
static_libs: [
"android.hardware.health@2.0-impl",
"android.hardware.health@1.0-convert",
"libcharger_sysprop",
"libhealthstoragedefault",
"libhealthd_draw",
"libminui",
],
shared_libs: [
"android.hardware.health@2.0",
"libbase",
"libcutils",
"liblog",
"libpng",
"libsuspend",
"libutils",
],
srcs: [
"healthd_mode_charger.cpp",
"AnimationParser.cpp",
],
}