[Android] How to Create Android ICS .vdi File for VirtualBox?

Because the Android Emulator is running on simulated ARM instruction set on x86-platform so that the emulator is too slowly generally. You can choose the Android-x86 or build Android with “vbox” version, then it can be executed in the VirtualBox. The Android running on VirtualBox should provide the better performance than the original Android Emulator, because it executes based on x86 instruction set.

Here we show the build-procedure for you to compile the .vdi file for adding into VirtualBox.

Step 1: You should prepare the Android ICS source code, you can reference to the Android Open Source Project.

Step 2: Choice the appropriate build version,
   $ ANDROID_TOP_PATH/> source build/envsetup.sh
   $ ANDROID_TOP_PATH/> lunch vbox_x86-eng

Step 3: Compile
   $ ANDROID_TOP_PATH/> make -j8

Step 4: Make the .vdi file for VirtualBox
   $ ANDROID_TOP_PATH/> make android_disk_vdi

When you finish the above steps, you can obtain the android_disk.vdi file in the “out/target/product/vbox_x86-eng/”.

How to use the Android in VirtualBox?

The Android’s key mapping is listed below,
[Back]:ESC
[Menu]:F1
[End]:F4
Shutdown:Press and Hold F4

3 comments

  1. I was happy to see your post, because I am playing with ICS, but couldn't find the emulator, so running in VirtualBox seemed like an even better alternative. I followed your directions, and got a clean build, but when I tried to load the .vdi in VirtualBox I got this error:

    —————
    Failed to open a session for the virtual machine Android_ICS.
    Failed to load VMMR0.ro (VERR_SUPLIB_OWNER_NOT_ROOT).
    Unknown error creating VM (VERR_SUPLIB_OWNER_NOT_ROOT).
    Details:
    Result Code: NS_ERROR_FAILURE (0x80004005)
    Component: Console
    Interface: IConsole [515e8e8d-f932-4d8e-9f32-79aead882}
    —————-

    I tried running as root, in case that was the problem, but the result was the same.

    Any thoughts?

    Dana Good

  2. i really like your post, in light of the fact that I am playing with ICS, however couldn't discover the emulator, so running in VirtualBox appeared like a far and away superior option. I took after your headings, and got a spotless form, yet when I attempted to stack the .vdi in VirtualBox I got this blunder:

發佈留言