17

Since Android is a forked Linux kernel plus software stack I am wondering whether there are any projects or ideas regarding creating a version of Android that can be added to a Linux system to allow a Linux system to run Android applications (compiled for, say, x86).

Does anything like that exist or would it be possible?

(I don't mean the emulator that comes with the SDK.)

  • 2
    The Android Player for the BlackBerry Playbook is close, though of course it runs on QNX and not Linux. – Matthew Read Aug 5 '11 at 13:22
2

Things have changed a little bit in the years since this was posted.

There are now several (though none of them perfect yet) ways to run Android apps on Linux without an emulator or VM.

  1. Shashlik features pretty nice integration with your GNU desktop environment. Lacks Google Play Services, though.
  2. ARChon utilizes Google Chrome, and lets you install Android apps as if they were Chrome apps. It's pretty neat, though here too, compatibility is not perfect.
  3. Finally, Google are officially bringing the Play Store to Chrome OS. Since this is an official project developed by Google, I believe it should have the best compatibility of the lot. Chrome OS is a Linux distro, based on Gentoo. The bulk of its source code is made available through the Chromium OS project. This source code being available, it shouldn't be too hard to port this compatibility to popular GNU/Linux distributions. Google are relatively friendly to open source (at least compared to Apple/Microsoft), and I don't think they'll be throwing up any roadblocks to such porting. If anything, they seem keen on the Play Store hitting as many devices as possible. They may even build this functionality into future versions of Google Chrome for Linux, or release a separate package. They release most of the source code for both Android and Chrome OS, and they use Linux internally.

By the way, there is no need to compile APKs separately for x86. The apps you write are compiled into Dalvik Executable (DEX) code, which is finally converted into assembly code (according to the required architecture) by the kernel to send to the processor. (This last part is taken from this answer.)

12

Nothing like that exists yet since the apps are not run natively in the OS, but they use Dalvik Virtual Machine instead (Wikipedia). It's somewhat comparable to Java in the sense that it uses bytecode and creates a separated environment for each app. So unless the Dalvik environment is ported to other platforms, they can't be run on normal hardware.

There is a project called Alien Dalvik by Myriad that tries to run Android apps in different environments, but there's not much info on it. Myriad Alien Dalvik

1

Things have changed again since Revetahw posted.

Shashlik seems to be an inactive project, but Anbox seems to be gaining ground. The advantage with Anbox is that it doesn't emulate the Android kernel, but rather uses Linux kernel features to share the kernel between your Linux system and the Android system.

Also, Chrome OS now has stable Android app support on several devices, but unfortunately, this integration is closed-source with no plans to open-source it announced.

0

I don't know whether there are projects of this kind. What comes nearest probably is the android-x86 projects that is a port of an android environment on desktop workstations: http://www.android-x86.org/

  • 1
    This doesn't emulate an Android environment on desktop workstations, it's a port of Android to normal PCs. – Andrew J. Brehm Aug 9 '11 at 21:22
  • Sure, my formulation was not very suitable. Fixed it, thx. – Juri Aug 10 '11 at 6:25

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.