Hacker News new | ask | show | jobs
by dredmorbius 1402 days ago
Termux is a godsend on Android, and remains The Only App Which Does Not Specifically and Precisely Suck (though EinkBro is giving it a good run for its money).

Termux still has a host of limitations and weaknesses which are imposed by the Android environment itself, including being capriciously killed by the OS, lack of multiple users, blocked access to most of the filesystem, and a relatively limited (though impressively growing, I have to admit) set of utilities. At last check, this includes X11 utilities and at least some of TeX, both quite formidable.

2 comments

Yes it's pretty amazing. But the latest versions of Android are killing it. It's now not even possible anymore to update or install packages inside it if it's targeting the Android 10 SDK which is now required to publish to the app store. So the developer had to stop pushing updates. Which limits him to F-Droid or sideload users of which there are a lot less. I am worried he might not deem it worthwhile to continue. I understand they're looking for a way to do this within the new framework but I'm sure Google will keep clamping this down because 99% of apps don't need this.

Eventually I'm sure even AOSP will stop supporting the older Android SDKs too.

https://wiki.termux.com/wiki/Termux_Google_Play

It just worries me because I love termux so much and it casts a shadow over its future.

FDroid still provides access.

My most recent Android device (purchased under protest) is an Onyx BOOX e-book reader running Android 11.

I have Google Play entirely disabled, rely on FDroid for most app installs, another 2--3 from Aurora.

(In general, I avoid installing apps at all.)

Termux is installed, runs, and updates. I just completed a package update a few minutes ago.

They need to embrace how Android works instead of pretending to be a Linux distribution, if not, well that is what happens.
But this is just not feasible for something like termux. Termux is the equivalent of a Linux distribution on Android. If they would let that go there would be no reason for it to exist.

The Android way would be to publish all packages individually on the app store. Termux has tens of thousands of packages. This would simply be insane and Google wouldn't permit it.

It is, there are Java APIs for most of the stuff they want to do, use JNI instead of Linux syscalls.
That was one of the issues yes. The execve() thing.

But a bigger problem is that an app is not allowed to modify its own files anymore, and is not allowed to run executables from 'data' storage. This is much harder to work around:

https://wiki.termux.com/wiki/FAQ

Even if they work around the execve thing, Google will probably refuse them in the store when they run executables not included in the APK. And the question is what will be locked down in future Android versions. Android 12 is already iffy according to the above FAQ. That's why I'm worried about it

Fwiw: I don't think Google is actively trying to kill it, no. But it's just not something needed for most apps so they don't want to facilitate it.

Except execve() isn't part of public APIs, people keep mixing up ISO C with POSIX, and only the former is a public NDK API.
Termux is awesome but the native environment is suffocating. I didn't even bother with Termux utilities after one hour of messing around. I went straight for the Arch Linux ARM proot environment and it contains ALL of the Arch Linux utilities. For example you will never get scipy to compile in normal Termux because you can't reasonably get a compatible Fortran compiler built and configured. Arch Linux ARM is the best "distro" within Termux and the installation script is seamless and supports multiple users!
Suffocating for lack of packages?

I'll note that Termux has about 1/3 the package count of RHEL / CentOS. It's not everything, but for a mobile distro, it's quite good.

That said:

1. Thanks for the Arch suggestion. I'll take a look at that. Root required?

2. Even with a full-fledged distro installed, if you're running unrooted Android you're still grossly crippled by the overarching (so to speak) Android system in terms of filesystem and process management and interference.

Since they mentioned proot, that won't require a rooted device, see: https://proot-me.github.io/

I was also able to get a decent Ubuntu distribution including a desktop environment running on a non-rooted device, even got Blender to render the popular BMW demo, though that took a while.