Search code examples
android-source

Android AOSP quickly rebuild system.img only


For Android AOSP build system. is it possible rebuild system.img from out/target/prodcut/xx/ only?

I am studying Android AOSP, and build system. However the rebuild time is too long for me. .for for example

mm <module>

Then the output should be like as out/target/product/<xxx>/<vendor/system>/...

Finally, I want to regenerate images from out/target/product/<xxx>/ only to save time.


Solution

  • You can use the following targets to only build the images (including the modules on which they are dependent).

    • systemimage for system.img
    • vendorimage for vendor.img
    • vbmetaimage for vbmeta.img

    and many more

    Example:

    m systemimage
    

    Note: This is only an incremental build and not a full rebuild. For a full rebuild you have to call m clean first.