health: convert to apex
This commit is contained in:
@@ -198,7 +198,7 @@ PRODUCT_COPY_FILES += \
|
|||||||
|
|
||||||
# Health
|
# Health
|
||||||
PRODUCT_PACKAGES += \
|
PRODUCT_PACKAGES += \
|
||||||
android.hardware.health-service.rpi
|
com.android.hardware.health.rpi5
|
||||||
|
|
||||||
# Kernel
|
# Kernel
|
||||||
PRODUCT_COPY_FILES += \
|
PRODUCT_COPY_FILES += \
|
||||||
|
@@ -7,26 +7,52 @@ cc_binary {
|
|||||||
name: "android.hardware.health-service.rpi",
|
name: "android.hardware.health-service.rpi",
|
||||||
relative_install_path: "hw",
|
relative_install_path: "hw",
|
||||||
vendor: true,
|
vendor: true,
|
||||||
init_rc: ["android.hardware.health-service.rpi.rc"],
|
|
||||||
vintf_fragments: ["android.hardware.health-service.rpi.xml"],
|
|
||||||
srcs: [
|
srcs: [
|
||||||
"HealthImpl.cpp",
|
"HealthImpl.cpp",
|
||||||
"main.cpp",
|
"main.cpp",
|
||||||
],
|
],
|
||||||
static_libs: [
|
static_libs: [
|
||||||
"android.hardware.health-translate-ndk",
|
|
||||||
"libbatterymonitor",
|
"libbatterymonitor",
|
||||||
"libhealthloop",
|
|
||||||
"libhealth_aidl_impl",
|
"libhealth_aidl_impl",
|
||||||
|
"libhealthloop",
|
||||||
],
|
],
|
||||||
shared_libs: [
|
shared_libs: [
|
||||||
|
"android.hardware.health-V4-ndk",
|
||||||
"libbase",
|
"libbase",
|
||||||
"libbinder_ndk",
|
"libbinder_ndk",
|
||||||
"libcutils",
|
"libcutils",
|
||||||
"libhidlbase",
|
|
||||||
"liblog",
|
"liblog",
|
||||||
"libutils",
|
"libutils",
|
||||||
"android.hardware.health-V4-ndk",
|
|
||||||
],
|
],
|
||||||
overrides: ["charger"],
|
overrides: ["charger"],
|
||||||
|
installable: false,
|
||||||
|
}
|
||||||
|
|
||||||
|
prebuilt_etc {
|
||||||
|
name: "android.hardware.health-service.rpi.rc",
|
||||||
|
src: "android.hardware.health-service.rpi.rc",
|
||||||
|
installable: false,
|
||||||
|
}
|
||||||
|
|
||||||
|
prebuilt_etc {
|
||||||
|
name: "android.hardware.health-service.rpi.xml",
|
||||||
|
src: "android.hardware.health-service.rpi.xml",
|
||||||
|
sub_dir: "vintf",
|
||||||
|
installable: false,
|
||||||
|
}
|
||||||
|
|
||||||
|
apex {
|
||||||
|
name: "com.android.hardware.health.rpi5",
|
||||||
|
manifest: "apex_manifest.json",
|
||||||
|
file_contexts: "apex_file_contexts",
|
||||||
|
key: "com.android.hardware.key",
|
||||||
|
certificate: ":com.android.hardware.certificate",
|
||||||
|
updatable: false,
|
||||||
|
vendor: true,
|
||||||
|
|
||||||
|
binaries: ["android.hardware.health-service.rpi"],
|
||||||
|
prebuilts: [
|
||||||
|
"android.hardware.health-service.rpi.rc",
|
||||||
|
"android.hardware.health-service.rpi.xml",
|
||||||
|
],
|
||||||
}
|
}
|
||||||
|
@@ -1,4 +1,4 @@
|
|||||||
service vendor.health-default /vendor/bin/hw/android.hardware.health-service.rpi
|
service vendor.health-rpi /apex/com.android.hardware.health.rpi5/bin/hw/android.hardware.health-service.rpi
|
||||||
class hal
|
class hal
|
||||||
user system
|
user system
|
||||||
group system
|
group system
|
||||||
|
3
health/apex_file_contexts
Normal file
3
health/apex_file_contexts
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
(/.*)? u:object_r:vendor_file:s0
|
||||||
|
/etc(/.*)? u:object_r:vendor_configs_file:s0
|
||||||
|
/bin/hw/android\.hardware\.health-service\.rpi u:object_r:hal_health_default_exec:s0
|
4
health/apex_manifest.json
Normal file
4
health/apex_manifest.json
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
{
|
||||||
|
"name": "com.android.hardware.health.rpi5",
|
||||||
|
"version": 1
|
||||||
|
}
|
@@ -28,9 +28,6 @@
|
|||||||
/vendor/lib(64)?/libminigbm_gralloc_gbm_mesa\.so u:object_r:same_process_hal_file:s0
|
/vendor/lib(64)?/libminigbm_gralloc_gbm_mesa\.so u:object_r:same_process_hal_file:s0
|
||||||
/vendor/lib(64)?/libminigbm_gralloc4_utils_gbm_mesa\.so u:object_r:same_process_hal_file:s0
|
/vendor/lib(64)?/libminigbm_gralloc4_utils_gbm_mesa\.so u:object_r:same_process_hal_file:s0
|
||||||
|
|
||||||
# Health
|
|
||||||
/vendor/bin/hw/android\.hardware\.health-service\.rpi u:object_r:hal_health_default_exec:s0
|
|
||||||
|
|
||||||
# Lights
|
# Lights
|
||||||
/sys/class/backlight/11-0045/brightness u:object_r:sysfs_leds:s0
|
/sys/class/backlight/11-0045/brightness u:object_r:sysfs_leds:s0
|
||||||
/sys/class/backlight/11-0045/max_brightness u:object_r:sysfs_leds:s0
|
/sys/class/backlight/11-0045/max_brightness u:object_r:sysfs_leds:s0
|
||||||
|
Reference in New Issue
Block a user