For the full documentation, please visit the Bazel documentation page.
- Launch emulator
- Run
bazel mobile-install //app/src/main:app --fat_apk_cpu=x86 --start_app --android_crosstool_top=@androidndk//:toolchain
- JNI/C++ sources goes into the
cc_library
target,//app/src/main:jni_lib
. - Java sources, resource files, and assets go into the
android_library
target,//app/src/main:lib
. This target depends on thecc_library
target. - The APK is built from the
android_binary
target,//app/src/main:app
. This target depends on theandroid_library
target.
NOTE: This graph omits the Google Maven AAR dependencies.