I wondered if it is possible to run a Linux executable on Android so I made a simple console application in Code::Blocks in C++ (I am using Ubuntu Linux), built it in release mode and copied it into a virtual device in GenyMotion (because I don't have a real x86 Android device).

I installed the app called material terminal on the virtual device and moved the executable into /data/local/tmp.

I gave it execute permissions by typing: chmod 777 hwrel.

Then I tried to run it by typing ./hwrel ,but it said sh: ./hwrel: no such file or directory.

Is it even possible to run Linux executables on Android?


1 Answer 1


Yes it is possible but due to Android using a different libc and architecture you'll need to compile your program with android-ndk.

  • 1
    But the architecture is the same since I am using a GenyMotion for this purpose.
    – xuwenbuwer
    Commented Nov 3, 2017 at 10:11

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .