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?


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

| improve this answer | |
  • But the architecture is the same since I am using a GenyMotion for this purpose. – IronPig Nov 3 '17 at 10:11

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.