[Samsung Galaxy Nexus] 7175:
Alright, I'm pretty sure I figured it out. It turns out the binary was compiled dynamically instead of statically, even though I specified static like 4 times when compiling and the -static flag was fed to gcc and g++. So it's looking for the linker upon execution, specifically /lib/ld-linux-armhf.so.3. I've gathered together the linker and any other libs it may look for and made a package of them. I'm gonna see if I can manipulate how the source is compiled some more and see if I can force out a purely static binary since configuring the libs is a huge hassle to run it. That's weird it's been working on my phone though.

EDIT: I eventually did get a static aria2c built, but it was calling some shared libraries on execution which breaks it. :( The axel I posted seems to work pretty well though with links. I'm not sure what the issue I had before was, something with /etc/resolv.conf or other, but it's been working for me now, using split connections and such.

Also the reason the dynamic aria2c was working on my phone was because I've modified my whole system to include various standard linux libraries and directories, ie. /usr, /bin, /lib, etc. I might eventually make an installer that includes the bare minimal linked libraries for dynamic aria2c once I get this python project I'm working on to where I want it.

EDIT2: Found a dynamically linked aria2 build for android. Check it out. Attached.

Also here's the readme file for Android aria2:

aria2 for Android devices
=========================

aria2 is a lightweight multi-protocol & multi-source download utility
operated in command-line. It supports HTTP/HTTPS, FTP, BitTorrent and
Metalink.

Install
-------

aria2 is not an ordinary Android Java application. It is a C++ native
application and operates in command-line. You don't have to 'root'
your device to use aria2. Because aria2 is a command-line program,
you need a terminal emulator. First install Android Terminal Emulator
from Android Market (or build it from source and install. See
https://github.com/jackpal/Android-Terminal-Emulator/).

1. Copy aria2c executable to ``/mnt/sdcard`` on your device.
2. Run Android Terminal Emulator.
3. ``mkdir /data/data/jackpal.androidterm/aria2``
4. ``cat /mnt/sdcard/aria2c > /data/data/jackpal.androidterm/aria2/aria2c``
5. ``chmod 744 /data/data/jackpal.androidterm/aria2/aria2c``
6. Add the following commands to the initial command of Android
Terminal Emulator::

export HOME=/data/data/jackpal.androidterm/aria2; cd $HOME

----------

See `the online manual
<http://aria2.sourceforge.net/manual/en/html/>`_.

Notes
-----

aria2c executable was generated using android-ndk-r10b.

The following libraries were statically linked.

* openssl 1.0.1i
* expat 2.1.0
* c-ares 1.10.0

Since Android does not have ``/etc/resolv.conf``, c-ares (asynchronous
DNS resolver) is disabled by default. But name resolution is sometimes
a little bit slow, so I recommend to enable c-ares. You can enable it
using ``--async-dns`` and specify DNS servers using
``--async-dns-server`` option, like this::

--async-dns --async-dns-server=`getprop net.dns1`,`getprop net.dns2`

Because it is tedious to type these long parameters every time you use
aria2c, the following wrapper shell script would be handy::

#!/system/bin/sh
/data/data/jackpal.androidterm/aria2c \
--async-dns \
--async-dns-server=`getprop net.dns1`,`getprop net.dns2` \
"$@"

Please note that you need to add executable file mode bit to this
wrapper script too. (e.g., ``chmod 744 /PATH/TO/SCRIPT``)

Known Issues
------------

* Since Android does not have ``/dev/stdout``, ``-l-`` does not work.

* Android Terminal Emulator sometimes stops updating console. It looks
like aria2c hangs, but aria2c continues to run.

To use this binary with lollipop, replace /system/bin/linker with the no-pie version that zzpianoman cooked up: http://xdaforums.com/showpost.php?p=57554982&postcount=321