Standalone recovery build system, intentionally independent from Soong/manifests and the Peacock package graph.
- lk2nd-like local workflow (
make, shell scripts) - deterministic artifacts in
prp/out/<target> - no direct dependency on Android build system
configs/*.env: device-specific boot image parameters and flash methodscripts/build-initramfs.sh: packsinitramfs/rootfsintoinitramfs.cpio.gzscripts/build-bootimg.sh: builds Android boot/recovery image withmkbootimgscripts/backup-recovery.sh: dumps current recovery partitionscripts/flash-recovery.sh: flashes built image and verifies byte-for-byte
cd prp
make sync-assets TARGET=jflte
make check-kernel TARGET=jflte
make initramfs TARGET=jflte
make bootimg TARGET=jflte
make backup-recovery TARGET=jflte
make flash-recovery TARGET=jflteFor Xiaomi Mi A2 Lite:
cd prp
make initramfs TARGET=xiaomi-daisy
make bootimg TARGET=xiaomi-daisy
make flash-recovery TARGET=xiaomi-daisyFor A/B devices using lk2nd split-boot layout, set these in the device config:
FASTBOOT_AB_LK2ND_SPLIT_BOOT=1FASTBOOT_BOOT_PARTITION=bootFASTBOOT_LK2ND_PARTITION=lk2nd
Device profiles should keep Qualcomm/MSM quirks explicit:
IS_MSM=1for Qualcomm/MSM-based targetsIS_MSM_FB_REFRESHER=1only whenmsm-fb-refresheris applicableIS_MSM_LK2ND_SPLIT_BOOT=1only when the device actually uses the lk2nd split-boot layout
These flags let the generic PRP paths stay platform-neutral while still enabling MSM-specific helpers from the profile.
In this mode flash-recovery requires lk2nd fastboot (must expose partition-size:lk2nd).
Headless debug boot (skip display/UI, bring up RNDIS shell early):
cd prp
make initramfs TARGET=xiaomi-daisy DEBUG_BOOT=1
make bootimg TARGET=xiaomi-daisy DEBUG_BOOT=1- Start SSH from the PRP GUI (
Start SSH) or run/usr/bin/prp-svc-sshon device. - For file transfer from host, use:
prp/scripts/prp-scp.sh ./local.file /tmp/remote.file
prp/scripts/prp-scp.sh root@172.16.42.1:/tmp/remote.file ./local.file- The wrapper forces legacy SCP mode (
-O), which is required when PRP uses Dropbear.
- This flow builds a unique PRP ramdisk from
initramfs/rootfs, not Peacock's initramfs. make sync-assetspulls:adbdruntime from connected TWRP (/sbin/adbdand required bionic pieces)- partition-management tools (
dmsetup,partx,e2fs*, etc.) from the local jflte rootfs image.
make check-kernelvalidates key options for nested subpartition handling:CONFIG_EFI_PARTITION,CONFIG_BLK_DEV_LOOP,CONFIG_BLK_DEV_DM,CONFIG_EXT4_FS.