diff --git a/sensors/aidl/default/Android.bp b/sensors/aidl/default/Android.bp index 16b4d3558a..384ee97f3a 100644 --- a/sensors/aidl/default/Android.bp +++ b/sensors/aidl/default/Android.bp @@ -28,9 +28,11 @@ filegroup { srcs: ["sensors-default.rc"], } -filegroup { +prebuilt_etc { name: "sensors-default.xml", - srcs: ["sensors-default.xml"], + src: "sensors-default.xml", + sub_dir: "vintf", + installable: false, } cc_library_static { diff --git a/sensors/aidl/default/apex/Android.bp b/sensors/aidl/default/apex/Android.bp index ceb428b5da..54820863d1 100644 --- a/sensors/aidl/default/apex/Android.bp +++ b/sensors/aidl/default/apex/Android.bp @@ -2,17 +2,6 @@ package { default_applicable_licenses: ["hardware_interfaces_license"], } -apex_key { - name: "com.android.hardware.sensors.key", - public_key: "com.android.hardware.sensors.avbpubkey", - private_key: "com.android.hardware.sensors.pem", -} - -android_app_certificate { - name: "com.android.hardware.sensors.certificate", - certificate: "com.android.hardware.sensors", -} - genrule { name: "com.android.hardware.sensors.rc-gen", srcs: [":sensors-default.rc"], @@ -31,16 +20,16 @@ prebuilt_etc { apex { name: "com.android.hardware.sensors", manifest: "apex_manifest.json", - key: "com.android.hardware.sensors.key", - certificate: ":com.android.hardware.sensors.certificate", + key: "com.android.hardware.key", + certificate: ":com.android.hardware.certificate", file_contexts: "file_contexts", - use_vndk_as_stable: true, updatable: false, - // Install the apex in /vendor/apex - soc_specific: true, + vendor: true, + binaries: ["android.hardware.sensors-service.example"], prebuilts: [ - "com.android.hardware.sensors.rc", + "com.android.hardware.sensors.rc", // init rc + "sensors-default.xml", // vintf fragment "android.hardware.sensor.ambient_temperature.prebuilt.xml", "android.hardware.sensor.barometer.prebuilt.xml", "android.hardware.sensor.gyroscope.prebuilt.xml", @@ -49,5 +38,4 @@ apex { "android.hardware.sensor.proximity.prebuilt.xml", "android.hardware.sensor.relative_humidity.prebuilt.xml", ], - vintf_fragments: [":sensors-default.xml"], } diff --git a/sensors/aidl/default/apex/file_contexts b/sensors/aidl/default/apex/file_contexts index 27be16b14e..6d231f81c0 100644 --- a/sensors/aidl/default/apex/file_contexts +++ b/sensors/aidl/default/apex/file_contexts @@ -1,5 +1,3 @@ -(/.*)? u:object_r:vendor_file:s0 -# Permission XMLs -/etc/permissions(/.*)? u:object_r:vendor_configs_file:s0 -# Service binary -/bin/hw/android\.hardware\.sensors-service\.example u:object_r:hal_sensors_default_exec:s0 \ No newline at end of file +(/.*)? u:object_r:vendor_file:s0 +/etc(/.*)? u:object_r:vendor_configs_file:s0 +/bin/hw/android\.hardware\.sensors-service\.example u:object_r:hal_sensors_default_exec:s0 \ No newline at end of file