Wednesday, 16 August 2017

How to port CM12/CM12.1 lollipop based Rom for Kitkat


How to port CM12/CM12.1 lollipop based Rom for Kitkat 

Unpack both boot.img Stock & cm12/cm12.1
  • Use Stock zImage(Kernel) With Cm12 ramdisk
  • stock/ramdisk/ueventd.rc
  • compare lines of both ramdisk/default.prop then
    Replace those line from stock boot.img/ramdisk/default.prop to cm12 boot.img/ramdisk/default.prop........
    1. ro.secure=*
    2. ro.allow.mock.location=*
    3. ro.debuggable=*


Now, port system folder...
replace stock to port...
  • firmware from system/etc
  • libMali.so from system/lib
  • libcamdrv.so from system/lib
  • libcamalgo.so from system/lib
  • libcameracustom.so from system/lib

Edit build.prop by notepad++..

  • Change dpi,
    ro.sf.lcd_density=*** (as ur Stock build.prop)
  • Rotation as ur device.
    ro.sf.hwrotation=*** (use 0 or 180 as ur device)
META-INF folder:

Open meta-inf folder & locate updater-script META-INF\com\google\android, then open it with Notepad++
just change system & data (if available) block mounting point as ur device,
Compare mmcblk0p* with ur stock Rom Zip
  • format("ext4", "EMMC", "/dev/block/mmcblk0p5", "0", "/system");
  • format("ext4", "EMMC", "/dev/block/mmcblk0p7", "0", "/data");
  • mount("ext4", "EMMC", "/dev/block/mmcblk0p5", "/system");
#Now zip it & flash with Philz recovery 6.59
Best of luck,, Happy Porting

No comments:

Post a Comment