ci: add Termux Android release targets#56
Conversation
There was a problem hiding this comment.
4 issues found across 4 files
Prompt for AI agents (unresolved issues)
Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.
<file name="install.sh">
<violation number="1" location="install.sh:20">
P1: Termux install support is incomplete: script still defaults to /usr/local/bin and sudo, which are unavailable/invalid in Termux</violation>
<violation number="2" location="install.sh:33">
P2: armv7l/armv8l is treated as supported on all Linux platforms, but only an Android armv7 release artifact is built. On regular Linux ARMv7 systems this produces `armv7-unknown-linux-gnu`, which doesn't exist in releases, causing a confusing download failure instead of the previous clear unsupported-architecture error.</violation>
<violation number="3" location="install.sh:33">
P0: ARMv7 Android release asset name mismatch: script produces `armv7-linux-android` but CI builds `armv7-linux-androideabi`, causing download to fail with 404 on Termux armv7 devices</violation>
</file>
<file name=".github/workflows/release.yml">
<violation number="1" location=".github/workflows/release.yml:121">
P1: Android NDK clang targets are hardcoded to API 35 (Android 15), making Termux release binaries incompatible with the vast majority of Android devices</violation>
</file>
Reply with feedback, questions, or to request a fix. Tag @cubic-dev-ai to re-run a review.
| case "$arch" in | ||
| x86_64|amd64) arch="x86_64" ;; | ||
| aarch64|arm64) arch="aarch64" ;; | ||
| armv7l|armv8l) arch="armv7" ;; |
There was a problem hiding this comment.
P0: ARMv7 Android release asset name mismatch: script produces armv7-linux-android but CI builds armv7-linux-androideabi, causing download to fail with 404 on Termux armv7 devices
Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At install.sh, line 33:
<comment>ARMv7 Android release asset name mismatch: script produces `armv7-linux-android` but CI builds `armv7-linux-androideabi`, causing download to fail with 404 on Termux armv7 devices</comment>
<file context>
@@ -16,14 +16,21 @@ detect_platform() {
case "$arch" in
x86_64|amd64) arch="x86_64" ;;
aarch64|arm64) arch="aarch64" ;;
+ armv7l|armv8l) arch="armv7" ;;
*) error "Unsupported architecture: $arch" ;;
esac
</file context>
| case "$os" in | ||
| Linux) os="unknown-linux-gnu" ;; | ||
| Linux) | ||
| if [ -n "${TERMUX_VERSION:-}" ] || [ -d "/data/data/com.termux/files/usr" ]; then |
There was a problem hiding this comment.
P1: Termux install support is incomplete: script still defaults to /usr/local/bin and sudo, which are unavailable/invalid in Termux
Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At install.sh, line 20:
<comment>Termux install support is incomplete: script still defaults to /usr/local/bin and sudo, which are unavailable/invalid in Termux</comment>
<file context>
@@ -16,14 +16,21 @@ detect_platform() {
case "$os" in
- Linux) os="unknown-linux-gnu" ;;
+ Linux)
+ if [ -n "${TERMUX_VERSION:-}" ] || [ -d "/data/data/com.termux/files/usr" ]; then
+ os="linux-android"
+ else
</file context>
| @@ -84,6 +84,14 @@ jobs: | |||
| - target: aarch64-apple-darwin | |||
There was a problem hiding this comment.
P1: Android NDK clang targets are hardcoded to API 35 (Android 15), making Termux release binaries incompatible with the vast majority of Android devices
Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At .github/workflows/release.yml, line 121:
<comment>Android NDK clang targets are hardcoded to API 35 (Android 15), making Termux release binaries incompatible with the vast majority of Android devices</comment>
<file context>
@@ -94,12 +102,27 @@ jobs:
+ if: matrix.android == true
+ shell: bash
+ run: |
+ echo "CC_aarch64_linux_android=$ANDROID_NDK_HOME/toolchains/llvm/prebuilt/linux-x86_64/bin/aarch64-linux-android35-clang" >> "$GITHUB_ENV"
+ echo "CARGO_TARGET_AARCH64_LINUX_ANDROID_LINKER=$ANDROID_NDK_HOME/toolchains/llvm/prebuilt/linux-x86_64/bin/aarch64-linux-android35-clang" >> "$GITHUB_ENV"
+ echo "CC_armv7_linux_androideabi=$ANDROID_NDK_HOME/toolchains/llvm/prebuilt/linux-x86_64/bin/armv7a-linux-androideabi35-clang" >> "$GITHUB_ENV"
</file context>
| - target: aarch64-apple-darwin | |
| echo "CC_aarch64_linux_android=$ANDROID_NDK_HOME/toolchains/llvm/prebuilt/linux-x86_64/bin/aarch64-linux-android24-clang" >> "$GITHUB_ENV" | |
| echo "CARGO_TARGET_AARCH64_LINUX_ANDROID_LINKER=$ANDROID_NDK_HOME/toolchains/llvm/prebuilt/linux-x86_64/bin/aarch64-linux-android24-clang" >> "$GITHUB_ENV" | |
| echo "CC_armv7_linux_androideabi=$ANDROID_NDK_HOME/toolchains/llvm/prebuilt/linux-x86_64/bin/armv7a-linux-androideabi24-clang" >> "$GITHUB_ENV" | |
| echo "CARGO_TARGET_ARMV7_LINUX_ANDROIDEABI_LINKER=$ANDROID_NDK_HOME/toolchains/llvm/prebuilt/linux-x86_64/bin/armv7a-linux-androideabi24-clang" >> "$GITHUB_ENV" |
| case "$arch" in | ||
| x86_64|amd64) arch="x86_64" ;; | ||
| aarch64|arm64) arch="aarch64" ;; | ||
| armv7l|armv8l) arch="armv7" ;; |
There was a problem hiding this comment.
P2: armv7l/armv8l is treated as supported on all Linux platforms, but only an Android armv7 release artifact is built. On regular Linux ARMv7 systems this produces armv7-unknown-linux-gnu, which doesn't exist in releases, causing a confusing download failure instead of the previous clear unsupported-architecture error.
Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. At install.sh, line 33:
<comment>armv7l/armv8l is treated as supported on all Linux platforms, but only an Android armv7 release artifact is built. On regular Linux ARMv7 systems this produces `armv7-unknown-linux-gnu`, which doesn't exist in releases, causing a confusing download failure instead of the previous clear unsupported-architecture error.</comment>
<file context>
@@ -16,14 +16,21 @@ detect_platform() {
case "$arch" in
x86_64|amd64) arch="x86_64" ;;
aarch64|arm64) arch="aarch64" ;;
+ armv7l|armv8l) arch="armv7" ;;
*) error "Unsupported architecture: $arch" ;;
esac
</file context>
| armv7l|armv8l) arch="armv7" ;; | |
| armv7l|armv8l) | |
| if [ "$os" = "linux-android" ]; then | |
| arch="armv7" | |
| else | |
| error "Unsupported architecture: $arch" | |
| fi | |
| ;; |
Adds Android release targets for Termux: aarch64-linux-android and armv7-linux-androideabi. Updates install.sh to detect Termux and download linux-android release assets. Switches nca-core reqwest to rustls-only and removes unused mcpr dependency to avoid native OpenSSL during Android builds.
Summary by cubic
Add Android Termux release targets and a Termux-aware installer, and gate CLI clipboard behind a
clipboardfeature for Android. Switch HTTP toreqwestwithrustlsand dropmcprto avoid OpenSSL.New Features
aarch64-linux-androidandarmv7-linux-androideabi; CI installs NDK r27c and sets LLVM linkers.install.shdetects Termux and downloadslinux-androidassets; mapsarmv7. CLI clipboard is feature-gated (clipboard, default on) with a no-clipboard fallback.Dependencies
reqwesttodefault-features = falsewithrustls-tlsto remove OpenSSL/native-tls.mcprcrate and its transitive TLS dependencies.Written for commit e83d0aa. Summary will update on new commits.