100% ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 1.1/1.1 MB • 00:01 • 118.3 MB/s
WARNING Error during upload. Retry with the --verbose option for more details.
ERROR HTTPError: 400 Bad Request from upload.pypi.org · PyPI
Binary wheel ‘astyle-3.3-cp311-cp311-linux_aarch64.whl’ has an unsupported platform tag ‘linux_aarch64’.
So how can user pip install a wheel in android termux?
As the error message tells you, those are not standardized and supported platform tag on PyPI. For building for Linux in general, you should build in a manylinux container; the easiest and best way to do that (and build all your other wheels too) is to build your wheels in CI with cibuildwheel and upload those, plus a sdist. If the termux is a manylinux compatible environment, then your manylinux-tagged wheels will work natively on it. Otherwise, it’ll fall back to the sdist.
I build in my PC and I get *-manylinux_*.whl, not -linux_*.whl. And in termux, pip install *-linux_*.whl can success, pip install *-manylinux_*.whl will fail. So it means termux is not a manylinux compatible environment? How can we distribute the wheel which termux supports?
PyPI doesn’t accept non-standard binary types, so you’ll need to create your own index server for this. https://www.piwheels.org/ does something similar for Raspberry Pi, you might be able to take inspiration from them.