After hunting around and not finding any dynamically linked Bash executable created using the NDK, I (as usual) decided to do it myself.
Here I give you dynamically linked bash 4.2 compiled using Crystax NDK r8, along with patches from http://dan.drown.org/android/src/bash/. The process to build it is documented on this page. The API version used was Android-8 (Froyo and upwards) and the toolchain used was gcc-4.7.
To use, place in any location where executables can run from (eg. /data/local/tmp or /data/data/jackpal.androidterm/app_HOME), gunzip it
, change permissions
and run.
Please note that if you run it without root, it will give the following error message intermittently:
This is because without root "/data" is inaccessible (Default permissions 771 with owner:group as "system:system").
As alternatives, there are statically linked bash binaries available from multiple sources, for example this by mzet.
Here I give you dynamically linked bash 4.2 compiled using Crystax NDK r8, along with patches from http://dan.drown.org/android/src/bash/. The process to build it is documented on this page. The API version used was Android-8 (Froyo and upwards) and the toolchain used was gcc-4.7.
To use, place in any location where executables can run from (eg. /data/local/tmp or /data/data/jackpal.androidterm/app_HOME), gunzip it
Code:
gunzip bash.gzCode:
chmod 755 bashPlease note that if you run it without root, it will give the following error message intermittently:
Code:
chdir: error retrieving current directory: getcwd: cannot access parent directories: Permission deniedAs alternatives, there are statically linked bash binaries available from multiple sources, for example this by mzet.