Skip to content

feat: add native Android (Termux) support - #25

Open
xprobo wants to merge 2 commits into
octra-labs:mainfrom
xprobo:main
Open

feat: add native Android (Termux) support#25
xprobo wants to merge 2 commits into
octra-labs:mainfrom
xprobo:main

Conversation

@xprobo

@xprobo xprobo commented May 31, 2026

Copy link
Copy Markdown

Summary

This PR adds seamless Android build and compilation support via Termux while preserving compatibility with existing macOS, Linux, and Windows environments.

Changes

Makefile

  • Added architecture detection for aarch64 and armv7 to enable hardware cryptographic extensions where available.
  • Added support for $PREFIX paths to improve dependency detection in Termux environments.

setup.sh

  • Added environment detection for Termux.
  • Uses pkg natively when running under Termux while retaining existing package manager behavior on other platforms.

random.hpp

  • Added Android-specific handling using the __ANDROID__ macro.
  • Bypasses the Bionic libc getrandom() wrapper by calling syscall(SYS_getrandom) directly when building on Android.
  • Preserves the existing implementation and behavior for standard Linux distributions.

README.md

  • Added installation and build instructions for Termux.
  • Included Android-specific setup steps and required dependencies.

Compatibility

This change is fully backward compatible and does not modify the build process for existing macOS, Linux, or Windows users.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant