1. Compile the Souce code of the entire android system. After compilation, three image files ramdisk. IMG, system. IMG, and userdata. IMG will be generated.
2. Unzip ramdisk. IMG:
MV ramdisk. IMG ramdisk.gz
Mkdir out
CD out & cpio-I-f ../ramdisk.gz
3. Cross-compile busybox. You only need to compile tar. Can it be from http://blog.chinaunix.net/u/20947/showart.php? Id = 1913228 download.
4. Install busybox
ADB Shell
ADB push busybox/data/busybox
CD/data/busybox;./busybox -- install
Chmod 555/system/bin/busybox
5. Copy the system and data directory
/Data/busybox tar CVF/data/data.tar/Data
/Data/busybox tar CVF/data/system.tar/System
ADB pull/data/system.tar
ADB pull/data/data.tar
6. Copy the contents of system.tar and data.tar to the system and Data Directories decompressed by ramdisk.
7. Create/dev directory
7. generation tools mkyaffs2image and mkyaffs
Http://www.aleph1.co.uk/cgi-bin/viewcvs.cgi/yaffs2/
./Mkyaffs2image system/system. img
8. Use mkyaffs2image to create the entire root file system