Search code examples
androidandroid-source

AOSP - Building custom images and running them with Android emulator on SDK


I am currently building custom images using the Android Open Source Project. I would like to send these custom images (system.img, ramdisk.img, cache.img, etc.) to a friend so that he/she can run them without having to compile the entire AOSP branch. Note that they "do" have the latest official Android SDK (not AOSP).

Is there a way to do this? Ideally, I was hoping for some make target that already exists where I can simply run it (make avd-package) and an "avd" (or something close to it) would pop out so that I can just send it to my friend and have them type:

emulator -avd

Also, from my research, the fact that I want these images to be runnable by the normal Android SDK (not AOSP) might present a problem since the tools in the Android SDK are different than the ones in AOSP (e.g. qemu versions, etc.). Would I also need to send my friend the emulator binaries as well?

Thanks!


Solution

  • Yes, it is doable. You need to create some metadata and upload it to a public server so that your users can get the URL. This is the URL they can then enter in Android Studio for using it with the SDK Manager tool.

    For full instructions follow the official docs here: https://source.android.com/setup/create/avd