Search code examples
androidandroid-sourceandroid-soong

Add own module/library to AOSP in separate Android.bp file


I would like to build my own library during the AOSP build process and I'd like to be able to build the library with a stand-alone command, i.e., without building complete AOSP.

I've put the source files of my library into a separate folder and created an Android.bp file in there, but executing

mmm path_to_folder/

gives the error

FAILED: ninja: unknown target 'MODULES-IN-my-module'

Solution

  • You can use mm MODULE_NAME -j$(nproc) or mm -j$(nproc) inside your module folder.