Build Android use Shell

Build fastboot Rom shell

1
mka updatepackage # this will all threads build fastboot rom

Build recovery Rom shell

1
mka bacon -j$(nproc --all) # -jx is number of thread   ,$(nproc --all) is all thread

flash rom

if fastboot rom

1
2
fastboot -w # clean data and cache
fastboot update <rom.zip> # flash

if recovery rom

1
2
fastboot reboot recovery # reboot to recovery
adb sideload <rom.zip> # sideload rom