Our great sponsors
-
WorkOS
The modern identity platform for B2B SaaS. The APIs are flexible and easy-to-use, supporting authentication, user identity, and complex enterprise features like SSO and SCIM provisioning.
The core steps are to compile CPython (well, or something else but CPython is most obvious) for the Android environment, work out how to pack it into your apk, then call it either via its C API or as a separate process. For the former you can read the python-for-android source code for an example. For the latter I'm not sure what the current state of things is as child process limitations have changed over time, but I think it's still possible one way or another. That's what termux probably does, I don't know if it has source available that you could look at.