News for hackers. Stuff that matters.
Re:Bare-metal Rust in Android by okanat on Monday October 09, 2023 @08:48PM (#37827330)
In theory it is possible to write raw Binder calls to various Android services, skipping JNI in many places. However, it is basically rewriting the entire OS API and structure from scratch.
Re:Bare-metal Rust in Android by defer on Monday October 09, 2023 @09:18PM (#37827524)
You can generate binder wrappers from aidl, that would work. This is fairly common when doing platform work (for those like me who work on the operating system rather than on apps).

However, this would be a terrible idea because usually the android api is stable at the Java wrappers (I.e. ActivityManager), not at the aidl level, which would make this very fragile for app development across a multitude of devices and platform versions.

Re:Bare-metal Rust in Android by izacus on Tuesday October 10, 2023 @02:46AM (#37829190)
Sure, and some NDK APIs do exactly that. But you're still just using IPC to call into services written in Java, just using a different approach.