Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for Termux API #38

Open
mikeslattery opened this issue Apr 14, 2021 · 0 comments
Open

Support for Termux API #38

mikeslattery opened this issue Apr 14, 2021 · 0 comments

Comments

@mikeslattery
Copy link

mikeslattery commented Apr 14, 2021

Include script to install termux-api in the alpine environment.

One way to do this is supply an optional script, install-termux-api:

#!/bin/sh
set -eu
apk info 2>/dev/null > apk-before.txt

apk -q add git gcc make libc-dev
ln -sfn /bin/sh /usr/bin/sh
git clone -q --depth 1 https://github.com/termux/termux-api-package.git
cd termux-api-package
sed -i 's/arc4random/rand/g' termux-api.c
sed -i 's|PREFIX ?= .*$|PREFIX = /usr|' Makefile
make --silent install
cd ..

# Clean up.   Remove repo and packages that weren't previously installed.
apk info | grep -vxf apk-before.txt | xargs -r apk -q del
apk cache --purge || true
rm -rf termux-api-package apk-before.txt

This builds on Alpine x86, but is untested in TermuxAlpine.

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

No branches or pull requests

1 participant