[Android] Unpack and edit boot.img

1) Get abootimg:

sudo aptitude install abootimg

2)Extract boot.img

abootimg -x boot.img

3)Extract initrd.img to initrdorg folder

mkd initrdorg
cp initrd.img initrdorg
cd initrdorg
gunzip -c ../initrd.img | cpio -i

4) Edit and repack
find . | cpio -o -H newc | gzip > ../newramdisk.cpio.gz
cp newramdisk.cpio.gz ../
cd ..
abootimg -u boot.img -r newramdisk.cpio.gz

You are done!
Tip: Remember to delete any *~ files gedit might have create before repacking!

Advertisements

#android, #boot-img, #computer, #edit, #initrd-img, #technology, #unpack