Skip to content
Android Build Script For Various GNU Binaries
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Type Name Latest commit message Commit time
Failed to load latest commit information.

GNU Utils for Android Build Script

This will build any of the following static GNU binaries:
bash, bc (also includes dc), coreutils (includes advanced cp/mv - progress bar functionality), cpio, diffutils (includes cmp, diff, diff3, sdiff), ed, findutils (includes find, locate, updatedb, xargs), gawk (GNU awk), grep (also includes egrep and fgrep), gzip (also includes gunzip and gzexe), ncurses (includes capconvert, clear, infocmp, tabs, tic, toe, tput, tset), patch, sed, tar

Build instructions

sudo apt install build-essential gcc-multilib libgnutls28-dev lzip # For debian/ubuntu based distributions - install equivalent dev tools and dependencies for yours
./build.bash --help # For more info on usage


The below table notes if the binary is compatible with android ndk, linaro, or gcc compilers. If static or dynamic is listed, then only that link method is working

NDK? Linaro? GCC?
bash Static Yes Yes
bc Yes Yes Yes
coreutils No Static Static
cpio Yes Yes Yes
diffutils Static Yes Yes
ed Yes Yes Yes
findutils No Yes Yes
gawk Static Yes Yes
grep Yes Yes Yes
gzip Yes Yes Yes
ncurses Yes Yes Yes
patch Yes Yes Yes
sed Yes Yes Yes
tar Yes Yes Yes

Coreutils won't accept fPIE and related args for dynamic compile


Credits for Bash and Patches



You can’t perform that action at this time.