Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit a750fad0 authored by Ray Chin's avatar Ray Chin
Browse files

Add soong config to build core service without vibrator

Not all Android devices have a vibrator. The VibratorControlService
should be an optional service for Android devices. We create a new
manifest without the VibratorControlService to avoid running VTS of
VibratorControlService for those devices. Devices only need to set the
soong config "without_vibrator" to exclude from the VTS test.

Flag: EXEMPT bugfix
Bug: 351256023
Test: Test on a TV device and the VTS test is ignored.
Change-Id: I396d3b1cb558e297ea9fb001e1a014efeeb0bf77
parent 377c55aa
Loading
Loading
Loading
Loading
+22 −4
Original line number Diff line number Diff line
@@ -186,7 +186,15 @@ art_profile_java_defaults {

// merge all required services into one jar
// ============================================================
java_library {
soong_config_module_type {
    name: "system_java_library",
    module_type: "java_library",
    config_namespace: "system_services",
    bool_variables: ["without_vibrator"],
    properties: ["vintf_fragments"],
}

system_java_library {
    name: "services",
    defaults: [
        "services_java_defaults",
@@ -248,9 +256,19 @@ java_library {
        "service-sdksandbox.stubs.system_server",
    ],

    soong_config_variables: {
        without_vibrator: {
            vintf_fragments: [
                "manifest_services.xml",
            ],
            conditions_default: {
                vintf_fragments: [
                    "manifest_services.xml",
                    "manifest_services_android.frameworks.vibrator.xml",
                ],
            },
        },
    },

    required: [
        "libukey2_jni_shared",
+0 −5
Original line number Diff line number Diff line
@@ -4,9 +4,4 @@
        <version>2</version>
        <fqname>IAltitudeService/default</fqname>
    </hal>
    <hal format="aidl">
        <name>android.frameworks.vibrator</name>
        <version>1</version>
        <fqname>IVibratorControlService/default</fqname>
    </hal>
</manifest>
+7 −0
Original line number Diff line number Diff line
<manifest version="1.0" type="framework">
    <hal format="aidl">
        <name>android.frameworks.vibrator</name>
        <version>1</version>
        <fqname>IVibratorControlService/default</fqname>
    </hal>
</manifest>