Add new System service giving compile errors ( lint error)

210 views
Skip to first unread message

sachin verma

unread,
Mar 7, 2021, 10:08:55 PM3/7/21
to android-...@googlegroups.com
Hi All,
I am adding one system service in AOSP 11. I am working on Qualcomm RB3 plateform. So checkout the code from repo init -u https://android.googlesource.com/platform/manifest -b master and
Build:
. ./build/envsetup.sh
lunch db845c-userdebug
make -j4
but getting many lint errors(please check attached screen)

Modified these files to register and add new service
    modified: Android.bp //add the path of aidl in filegroup
    modified: core/java/android/app/ContextImpl.java
    modified: core/java/android/app/SystemServiceRegistry.java
    modified: core/java/android/content/Context.java
    modified: services/java/com/android/server/SystemServer.java

my dummy AIDL is as below
package android.os;

interface IWeightSensor{

/**
* {@hide}
*/
@nullable String setWeight(in int val);
int getWeight();
}
I unable to try what is emitted in the terminal, (method 1 is not possible, since autogenerated file; method 1 is not possible, since mentioned folder is not available ). Please check the screen shot attached for the reference.

Thanks,
Sachin

sachin verma

unread,
Mar 10, 2021, 11:09:04 AM3/10/21
to android-platform
Hi All,
I am stuck at this point from week, Can some body please reply on the issue. It will be very helpful to me.

Thanks,
Sachin

sachin verma

unread,
Mar 15, 2021, 10:45:03 AM3/15/21
to android-...@googlegroups.com, android-d...@googlegroups.com
Hi All,
I have resolved the issue by writing my service in different packages and apply lint ignore on the package in Android.bp

Thanks,
Sachin
Reply all
Reply to author
Forward
0 new messages