fix(tirith): detect Android/Termux as Linux ABI-compatible

In _detect_target(), platform.system() returns "Android" on Termux,
not "Linux". Without this change tirith's auto-installer skips
Android even though the Linux GNU binaries are ABI-compatible.
This commit is contained in:
VantHoff 2026-04-16 13:55:56 +08:00 committed by Teknium
parent f347315e07
commit 99af222ecf

View file

@ -186,9 +186,10 @@ def _detect_target() -> str | None:
system = platform.system()
machine = platform.machine().lower()
# Android (Termux) is ABI-compatible with Linux — reuse Linux binaries.
if system == "Darwin":
plat = "apple-darwin"
elif system == "Linux":
elif system in ("Linux", "Android"):
plat = "unknown-linux-gnu"
else:
return None