[guide][how to port roms][snapdragon][windows/linux] - Android Software Development

HOW TO PORT ROMS IN WINDOWS​
WARNING :- I AM NOT RESPONSIBLE FOR BRICKED DEVICES, DEAD SD CARDS OR ANY OTHER STUFFS HAPPEN WITH YOU.
WARNING:- THIS IS FOR SNAPDRAGON DEVICES ONLY.
YOU NEED A WORKING A PC AND SOME SOFTWARES LIKE:-​
WINRAR (https://www.win-rar.com/download.html?&L=0)
NOTEPAD++ (https://notepad-plus-plus.org/)
ANDROID IMAGE KITCHEN (https://mega.nz/#F!P5AA3azC!AijFT4S-dAwbt88eKkTIMA)
EXTRACTOR 4.0 (https://mega.nz/#F!y0YhwT5D!SX6cQ7lPv7XGiH7GLDXLyw)
MELD (https://download.gnome.org/binaries/win32/meld/?_e_pi_=7,PAGE_ID10,4038285101)
SO HERE WE GO,
STEP 1
EXTRACT YOUR BASE ROM AND PORT ROM IN TWO DIFFERENT FOLDER.
STEP 2
MAKE TWO DIFFERENT FOLDER AND NAME THEM PORT BOOT IMAGE AND BASE BOOT IMAGE.
(NOT INSIDE THE ROM FOLDER)
STEP 3
COPY THE BASE BOOT IMAGE IN BASE BOOT IMAGE FOLDER
AND COPY THE PORT BOOT IMAGE IN PORT BOOT IMAGE FOLDER
STEP 4
USING ANDROID IMAGE KITCHEN
EXTRACT BOTH BOOT IMAGE (BASE AND PORT)
STEP 5
REPLACE [/SPLIT_IMG/boot.img-zImage](AFTER EXTRACTION )
REPLACE [/SPLIT_IMG/boot.img-dtb](AFTER EXTRACTION )
(FROM BASE BOOT IMAGE TO PORT BOOT IMAGE)
STEP 6
USING MELD,
COMPARE FILES [RAMDISK/INIT.RC]
COMPARE FILES [RAMDISK/FSTAB.QCOM]
(FROM BASE BOOT IMAGE TO PORT BOOT IMAGE)
STEP 7
USING ANDROID IMAGE KITCHEN
REPACK YOUR BOOT IMAGE.
FINALLY WE HAVE PORTED BOOT IMAGE !!!​STEP 8
EDIT YOUR UPDATE SCRIPT PRESENT IN [PORT ROM/META-INF/COM/GOOGLE/ANDROID/UPDATE SCRIPT]
ERASE
getprop("ro.product.device") == "XXXXXXX" || abort("This package is for "XXXXXX"" devices; this is a "" + getprop("ro.product.device")
FROM THE UPDATE SCRIPT
STEP 9
EDIT YOUR BUILD.PROP USING NOTEPAD++
COMPARE LCD DENSITY IN BUILD.PROP [PORT ROM/SYSTEM][WITH BASE ROM/SYSTEM/BUILD.PROP]
CHANGE YOUR MODEL NO. IN THESE LINES [IN PORT ROM'S BUILD.PROP]
ro.product.model=
ro.product.brand=
ro.product.name=
ro.product.device=
STEP 10
REPACK YOUR PORT ROM USING WINRAR
DONE !!!
HOW TO PORT ROM IN LINUX​
FIRST STEP :-- INSTALL PACKAGES
ZIP, UNZIP, PYTHON,ADB, FASTBOOT, MELD
FOR DEBIAN BASED LINUX
Code:
sudo apt update; sudo apt install zip adb meld fastboot python unzip zip
DOWNLOAD THESE AND EXTRACT IT IN SEPERATE FOLDER
SUPERR 'S KITCHEN (https://forum.xda-developers.com/ap...chen-superr-s-kitchen-v1-1-50-v2-1-6-t3597434)
AIK-LINUX (https://forum.xda-developers.com/showthread.php?t=2073775) EXTRACT THIS 2 TIME AND NAME IT PORT BOOT AND STOCK BOOT
IF YOU HAVE SYSTEM FOLDER THEN
MAKE TWO FOLDER NAME STOCK AND PORT
FOR MAKING FOLDER
Code:
mkdir stock port
(YOU CAN REPLACE THE NAME)
HERE WE GOT TWO FOLDERS, COPY YOUR STOCK ROM IN STOCK FOLDER AND PORT IN PORT FOLDER
THEN EXTRACT BOTH FILES BY UNZIP LIKE
Code:
[email protected]:~/path/to/your/rom/stock$ unzip *.zip
SAME FOR PORT ROM
Code:
[email protected]:~/path/to/your/rom/port$ unzip *.zip
NOW WE HAVE TO PORT THE BOOT IMAGE
GO TO WHERE YOU HAVE EXTRACTED AIK-LINUX , COPY THE STOCK BOOT IMAGE IN STOCK BOOT FOLDER AND PORT IN PORT BOOT FOLDER
NOW EXTRACT BOOT IMAGE
Code:
[email protected]:~/path/to/your/aik-linux/stock boot$ ./unpackimg.sh
AND SAME WITH PORT
Code:
[email protected]:~/path/to/your/aik-linux/port boot$ ./unpackimg.sh
NOW REPLACE, (FROM STOCK TO PORT
Code:
/SPLIT_IMG/BOOT.IMG-ZIMAGE
/SPLIT_IMG/BOOT.IMG-DTB
AFTER THAT USE MELD FOR COMPARING RAMDISK FILES, FOR MELD WRITE THIS IN TERMINAL
Code:
sudo meld
COMPARE,(FROM STOCK TO PORT
Code:
/ramdisk/fstab.qcom
/ramdisk/init.rc
/ramdisk/uneventd.rc
/ramdisk/uneventd.qcom.rc
NOW REPACK THE PORT BOOT IMAGE BY
Code:
[email protected]:~/path/to/your/aik-linux/port boot$ ./repackimg.sh
NOW WE HAVE SUCCESSFULLY PORTED THE BOOT IMAGE
PLACE IT IN YOUR PORT ROM
NOW THROUGH MELD, COMPARE YOUR BUILD.PROP FOR LCD DENSITY AND DEVICE NAME AND BRAND (FROM STOCK TO PORT
NOW OPEN YOUR UPDATER-SCRIPT PATH:- PORT ROM/META-INF/COM/GOOGLE/ANDROID
REMOVE THESE LINES IF IT HAVE
Code:
getprop("ro.product.device") == "XXXXXXX" || abort("This package is for "XXXXXX"" devices; this is a "" + getprop("ro.product.device")
AND REPLACE YOUR MOUNT SYSTEM,FORMAT SYSTEM AND BOOT.IMG FLASHING LINE FROM YOUR STOCK UPDATER-SCRIPT
REPACK YOUR ROM BY
Code:
[email protected]:~/path/to/your/port rom$ zip -r $ROMNAME meta-inf system boot.img
REPLACE $ROMNAME WITH YOUR ROM ZIP NAME AND IF YOU HAVE FOLDER TO COMPRESS JUST ADD THOSE AFTER META-INF WITH SPACE BETWEEN EACH FOLDER
DONE !!!
IF YOU HAVE SYSTEM.IMG OR SYSTEM.NEW.DAT.BR OR SYSTEM.NEW.DAT
USE SUPERR KITCHEN TO EXTRACT THOSE AND USE METHOD WRITTEN A BIT ABOVE​

bro i am totally new in porting field....however i tried porting MIUI 9 for yu yunique.....but no succeed....can you plz tell is it possible to port miui 9 custom rom for yu yunique... i Take port rom for redmi 2 and base rom MIUI 8 by Xinid for yu yunique........however i tried all the tuitorial on xda but not even single was helped... i soft bricked my deice more than 15 times....Is it compatible for yu yunique?? i found both devices has almost same configuration and android version also same.... Whats wrong??/

@AYUSH KUMAR
Hi,
Can you make a video for that? I can't do it because I don't speak English. I'm thinking of uploading the Miui 10 to Asus Ze552kl.
Bye.

Chakari said:
@AYUSH KUMAR
Hi,
Can you make a video for that? I can't do it because I don't speak English. I'm thinking of uploading the Miui 10 to Asus Ze552kl.
Bye.
Click to expand...
Click to collapse
Sorry I dont have a youtube video

@KumarAyush after Porting twrp shows this message
help me to port rom

sarthak darshan said:
@KumarAyush after Porting twrp shows this message
help me to port rom
Click to expand...
Click to collapse
That's Mount line in updater-script change it according to stock

can i port lineageos 15.1 from xperia v with msm8960 1gb ram to samsung s3 d2 with 14.1 and same chipset but 2 gb ram?

hi help me to port oneplus 5 rom to zenfone 4 pro(ZS551KL) thank you

Hi, first i want to thank you because making this tutorial, however because i'm new to this porting world, i'm stuck on a problem, the problem is, after following your steps, zipped it and flashed it on my phone, it goes to recovery back again and again when i press the reboot button, and i don't know how to solve this. can you help me? here some details about my port ROM:
ROM i want to Port: RR 5.8.5 [7.1.2_r29] [N] [OFFICIAL][LENOVO A6000]
ROM i use as Base: AOSP_RRO_Rev3 [6.0.1] [M] [UNOFFICIAL][C46B2G] (an Indonesian Phone, i think you don't know about it)
plis reply bro i'm stuck

hi,
I'm trying to port an Android 10 rom to an original that is Android 7 based. I don't see a vendor partition on this Nubia N3 original scripts (just a bunch of others).
Any idea how to fix that?
Do I need to repartition?
It's not treble ready. I am trying to port Redmi Note Pro 6 Android 10 pixel experience to an NX608J.
Any tips are greatly appreciated.

It working well i ported from Galaxy On7 to J5 2015 on miui 9 rom But touch screen not working : ( i flashed again and my phone is really dead : ( after flashed the rom!

Hey guys please suggest me similar devices to lenovo tab 10 tbx-103f. 1gb ram and 16 GB storage. Please. Anyone.

kumarayush2104 said:
HOW TO PORT ROMS IN WINDOWS​
WARNING :- I AM NOT RESPONSIBLE FOR BRICKED DEVICES, DEAD SD CARDS OR ANY OTHER STUFFS HAPPEN WITH YOU.
WARNING:- THIS IS FOR SNAPDRAGON DEVICES ONLY.
YOU NEED A WORKING A PC AND SOME SOFTWARES LIKE:-​
WINRAR (https://www.win-rar.com/download.html?&L=0)
NOTEPAD++ (https://notepad-plus-plus.org/)
ANDROID IMAGE KITCHEN (https://mega.nz/#F!P5AA3azC!AijFT4S-dAwbt88eKkTIMA)
EXTRACTOR 4.0 (https://mega.nz/#F!y0YhwT5D!SX6cQ7lPv7XGiH7GLDXLyw)
MELD (https://download.gnome.org/binaries/win32/meld/?_e_pi_=7,PAGE_ID10,4038285101)
SO HERE WE GO,
STEP 1
EXTRACT YOUR BASE ROM AND PORT ROM IN TWO DIFFERENT FOLDER.
STEP 2
MAKE TWO DIFFERENT FOLDER AND NAME THEM PORT BOOT IMAGE AND BASE BOOT IMAGE.
(NOT INSIDE THE ROM FOLDER)
STEP 3
COPY THE BASE BOOT IMAGE IN BASE BOOT IMAGE FOLDER
AND COPY THE PORT BOOT IMAGE IN PORT BOOT IMAGE FOLDER
STEP 4
USING ANDROID IMAGE KITCHEN
EXTRACT BOTH BOOT IMAGE (BASE AND PORT)
STEP 5
REPLACE [/SPLIT_IMG/boot.img-zImage](AFTER EXTRACTION )
REPLACE [/SPLIT_IMG/boot.img-dtb](AFTER EXTRACTION )
(FROM BASE BOOT IMAGE TO PORT BOOT IMAGE)
STEP 6
USING MELD,
COMPARE FILES [RAMDISK/INIT.RC]
COMPARE FILES [RAMDISK/FSTAB.QCOM]
(FROM BASE BOOT IMAGE TO PORT BOOT IMAGE)
STEP 7
USING ANDROID IMAGE KITCHEN
REPACK YOUR BOOT IMAGE.
FINALLY WE HAVE PORTED BOOT IMAGE !!!
​STEP 8
EDIT YOUR UPDATE SCRIPT PRESENT IN [PORT ROM/META-INF/COM/GOOGLE/ANDROID/UPDATE SCRIPT]
ERASE
getprop("ro.product.device") == "XXXXXXX" || abort("This package is for "XXXXXX"" devices; this is a "" + getprop("ro.product.device")
FROM THE UPDATE SCRIPT
STEP 9
EDIT YOUR BUILD.PROP USING NOTEPAD++
COMPARE LCD DENSITY IN BUILD.PROP [PORT ROM/SYSTEM][WITH BASE ROM/SYSTEM/BUILD.PROP]
CHANGE YOUR MODEL NO. IN THESE LINES [IN PORT ROM'S BUILD.PROP]
ro.product.model=
ro.product.brand=
ro.product.name=
ro.product.device=
STEP 10
REPACK YOUR PORT ROM USING WINRAR
DONE !!!
HOW TO PORT ROM IN LINUX
FIRST STEP :-- INSTALL PACKAGES
ZIP, UNZIP, PYTHON,ADB, FASTBOOT, MELD
FOR DEBIAN BASED LINUX
Code:
sudo apt update; sudo apt install zip adb meld fastboot python unzip zip
DOWNLOAD THESE AND EXTRACT IT IN SEPERATE FOLDER
SUPERR 'S KITCHEN (https://forum.xda-developers.com/ap...chen-superr-s-kitchen-v1-1-50-v2-1-6-t3597434)
AIK-LINUX (https://forum.xda-developers.com/showthread.php?t=2073775) EXTRACT THIS 2 TIME AND NAME IT PORT BOOT AND STOCK BOOT
IF YOU HAVE SYSTEM FOLDER THEN
MAKE TWO FOLDER NAME STOCK AND PORT
FOR MAKING FOLDER
Code:
mkdir stock port
(YOU CAN REPLACE THE NAME)
HERE WE GOT TWO FOLDERS, COPY YOUR STOCK ROM IN STOCK FOLDER AND PORT IN PORT FOLDER
THEN EXTRACT BOTH FILES BY UNZIP LIKE
Code:
[email protected]:~/path/to/your/rom/stock$ unzip *.zip
SAME FOR PORT ROM
Code:
[email protected]:~/path/to/your/rom/port$ unzip *.zip
NOW WE HAVE TO PORT THE BOOT IMAGE
GO TO WHERE YOU HAVE EXTRACTED AIK-LINUX , COPY THE STOCK BOOT IMAGE IN STOCK BOOT FOLDER AND PORT IN PORT BOOT FOLDER
NOW EXTRACT BOOT IMAGE
Code:
[email protected]:~/path/to/your/aik-linux/stock boot$ ./unpackimg.sh
AND SAME WITH PORT
Code:
[email protected]:~/path/to/your/aik-linux/port boot$ ./unpackimg.sh
NOW REPLACE, (FROM STOCK TO PORT
Code:
/SPLIT_IMG/BOOT.IMG-ZIMAGE
/SPLIT_IMG/BOOT.IMG-DTB
AFTER THAT USE MELD FOR COMPARING RAMDISK FILES, FOR MELD WRITE THIS IN TERMINAL
Code:
sudo meld
COMPARE,(FROM STOCK TO PORT
Code:
/ramdisk/fstab.qcom
/ramdisk/init.rc
/ramdisk/uneventd.rc
/ramdisk/uneventd.qcom.rc
NOW REPACK THE PORT BOOT IMAGE BY
Code:
[email protected]:~/path/to/your/aik-linux/port boot$ ./repackimg.sh
NOW WE HAVE SUCCESSFULLY PORTED THE BOOT IMAGE
PLACE IT IN YOUR PORT ROM
NOW THROUGH MELD, COMPARE YOUR BUILD.PROP FOR LCD DENSITY AND DEVICE NAME AND BRAND (FROM STOCK TO PORT
NOW OPEN YOUR UPDATER-SCRIPT PATH:- PORT ROM/META-INF/COM/GOOGLE/ANDROID
REMOVE THESE LINES IF IT HAVE
Code:
getprop("ro.product.device") == "XXXXXXX" || abort("This package is for "XXXXXX"" devices; this is a "" + getprop("ro.product.device")
AND REPLACE YOUR MOUNT SYSTEM,FORMAT SYSTEM AND BOOT.IMG FLASHING LINE FROM YOUR STOCK UPDATER-SCRIPT
REPACK YOUR ROM BY
Code:
[email protected]:~/path/to/your/port rom$ zip -r $ROMNAME meta-inf system boot.img
REPLACE $ROMNAME WITH YOUR ROM ZIP NAME AND IF YOU HAVE FOLDER TO COMPRESS JUST ADD THOSE AFTER META-INF WITH SPACE BETWEEN EACH FOLDER
DONE !!!
IF YOU HAVE SYSTEM.IMG OR SYSTEM.NEW.DAT.BR OR SYSTEM.NEW.DAT
USE SUPERR KITCHEN TO EXTRACT THOSE AND USE METHOD WRITTEN A BIT ABOVE​
Click to expand...
Click to collapse
I am stuck at this here:
"
REPLACE [/SPLIT_IMG/boot.img-zImage](AFTER EXTRACTION )
REPLACE [/SPLIT_IMG/boot.img-dtb](AFTER EXTRACTION )"
those two files aren't there when i try to extract the boot image for the galaxy s5

Related

[Q] [Help] Problem with NAND Kitchen

Hello
I would like to use Android on my HD2. I was searching and testing many ROMS but I didn´t find any rom which is usable for me. I would like to have a ROM that is without Sense, has Multilanguage support and is on Android 2.2 version.
So I decided that I would make my own.
0) I was reading
HTML:
http://forum.xda-developers.com/showpost.php?p=10291851&postcount=1
and made this procedure.
1)downloaded some ROM from here
2)unpacked this rom in linux with :
Code:
unyaffs system.img
then I got this directories:
Code:
app bin build.prop etc fonts framework lib media usr xbin
3)I downloaded update-cm-6.1.1-N1-signed.zip from CyanogenMod Forum > Downloads > Stable Mod > Nexus One and unpacked. I got : META-INF system boot.img.
4)I copied everything what was described step 0 from directories from step 2 to directory system from step 3
5)I downloaded and copied build.prop from step 0 to system
6) I updated permition like it is described in step 0
7) I created system.img with command : mkyaffs2image . ../system.img
Then I copied this system.img from linux to my windows and put this file in directory in which was different NAND rom. (replaced system.img). After that I flashed my phone and it did not work. Screen was frozen after booting and only green HTC was on display.
Can somebody please help me and give me some advice or some small howto. Does anybody know what can be wrong?
UPDATE: If I unpacking any nand roms and packing back everything is ok They must by any problem in me procedure of creating.
Thank you
Michal Fichtner

[Tutorial] Add TWRP to AOSP LP 5.0 boot.img

I've updated the boot.img for paxb build 504 with TWRP to replace CWM. Some were asking how to do this.
Always keep a backup of a file known as working. If your device doesn't boot after flashing a modified file, just reflash that backup.
To perform this mod on your own follow these steps:
1. Download and unpack the Android Image Kitchen
2. Extract the boot.img from the downloaded ROM to the kitchen directory
3. Unpack the image:
Code:
unpackimg.bat boot_cwm_pabx_504.img
Output:
Code:
Android Image Kitchen - UnpackImg Script by osm0sis @ xda-developers
Supplied image: boot_cwm_pabx_504.img
Removing old work folders and files . . .
Setting up work folders . . .
Splitting image to "/split_img/" . . .
BOARD_KERNEL_CMDLINE androidboot.hardware=sony user_debug=31 msm_rtb.filter=0x3F ehci-hcd.park=3 vmalloc=400M
BOARD_KERNEL_BASE 80200000
BOARD_NAME
BOARD_PAGE_SIZE 2048
BOARD_KERNEL_OFFSET 00008000
BOARD_RAMDISK_OFFSET 02000000
BOARD_TAGS_OFFSET 00000100
Unpacking ramdisk to "/ramdisk/" . . .
Compression used: gzip
9694 blocks
Done!
This process will overwrite previously extracted contents!!!
4. Create a directory for the original image content, e.g. "boot_cwm_pabx_504" and COPY the created directories "ramdisk" and "split_img" into it. This ensures you can recreate it if necessary or access its original contents
5. Repeat step 4 for a downloaded TWRP (or any other recovery) image, e.g. "openrecovery-twrp-2.8.0.1-yuga.img".
6. Locate the "*-ramdisk.cpio.gz" file in the dirs from step 5, most likely in "split_img".
7. Ensure the "ramdisk" and "split_img" directories in the kitchen root dir are those from the image you want to modify (i.e. copy back from the folder created in step 4. Then remove the "*.cpio" from the "ramdisk\recovery" directory
8. Extract the TWRP "*.cpio" file from the "*-ramdisk.cpio.gz" in step 6 to "ramdisk\recovery" and rename it to "ramdisk-recovery.cpio"
9. rebuilt the image with the updated content:
Code:
repackimg.bat
Output:
Code:
Android Image Kitchen - RepackImg Script
by osm0sis @ xda-developers
Packing ramdisk . . .
Using compression: gzip
Getting build information . . .
kernel = boot_cwm_pabx_504.img-zImage
cmdline = androidboot.hardware=sony user_debug=31 msm_rtb.filter=0x3F ehci-hcd.park=3 vmalloc=400M
board =
base = 80200000
pagesize = 2048
kernel_offset = 00008000
ramdisk_offset = 02000000
tags_offset = 00000100
Building image . . .
10. Step 9 creates a file called "image-new.img". Rename it to something more self-explanatory, i.e. "boot_twrp_2.8.0.1_pabx_504.img"
11. To flash the file flash it like any other file using the new name:
Code:
adb reboot bootloader
fastboot flash boot boot_twrp_2.8.0.1_pabx_504.img
fastboot reboot
That's it, enjoy your new recovery.
Note: I had issues getting TWRP 2.8.1.0 working, so I'm still using the predecessor 2.8.0.1.
The latest pabx "boot.img" modified with TWRP is attached.
Known issues
after restoring a Nandroid backup access to the internal storage isn't allowed anymore
Open a terminal or run through a adb shell:
Code:
restorecon -FR /data/media/0
Thank works dobře.TWRP I like long ....
cant understand what you mean in step 7 and 8..... i just unpacked boot.img (the img that i want to put a recovery on it) and then i created a folder and i copied split_img and ramdisk into it.....then i unpacked twrp.img and it replaced the previous split_img and ramdisk folders with the twrp ones..... i still have the folder i created with the original split_img and ramdisk folders from boot.img but i can understand what to do next....
well, sorry for that,...i think i got it now that i read it about 20 times..... one question though :
i copy ramdisk.cpio.gz from the twrp and i move it to the recovery folder of the boot img without extracting? just renaming it from ramdisk.cpio.gz to ramdisk-recovery.cpio ???
arismelachrinos said:
cant understand what you mean in step 7 and 8..... i just unpacked boot.img (the img that i want to put a recovery on it) and then i created a folder and i copied split_img and ramdisk into it.....then i unpacked twrp.img and it replaced the previous split_img and ramdisk folders with the twrp ones..... i still have the folder i created with the original split_img and ramdisk folders from boot.img but i can understand what to do next....
well, sorry for that,...i think i got it now that i read it about 20 times..... one question though :
i copy ramdisk.cpio.gz from the twrp and i move it to the recovery folder of the boot img without extracting? just renaming it from ramdisk.cpio.gz to ramdisk-recovery.cpio ???
Click to expand...
Click to collapse
Yeah I didn't fully understand that either, but i just tried it.
You delete ramdisk-recovery.cpio from /ramdisk.
You extract ramdisk.cpio.gz to the /ramdisk folder.
You rename it to ramdisk-recovery.cpio.
Repack image.
(note that when the kernel you use is already a dualrecovery kernel -lightning for example, cwm philz+twrp- and u want it to be multirom twrp, u need to edit init.sh also found in /ramdisk folder somewhere)
BTW thanks for this guide! I was messing with this a few days ago and I couldn't get it to work, thanks to you I now understand why!:thumbup:
I tried to put latest twrp into latest boot.IMG of Thomas lollipop 23/11/14 build and I thought it worked but I press volume up and down to enter the recovery and it does nothing....it doesn't boot,it just freezes with the led lighting.... please help I really want twrp to work with lollipop
arismelachrinos said:
I tried to put latest twrp into latest boot.IMG of Thomas lollipop 23/11/14 build and I thought it worked but I press volume up and down to enter the recovery and it does nothing....it doesn't boot,it just freezes with the led lighting.... please help I really want twrp to work with lollipop
Click to expand...
Click to collapse
Reread what I wrote.
You probably didn't extract ramdisk.cpio.gz, or you putted it into /split_img I think. Cuz I had that too, but if you follow the exact steps it will work!
no I did exactly what you said... I fully understood the instructions,I extracted it , I named it right and I moved it right... well, I will try again tomorrow but I don't think it will boot into it... Thomas boot.img has a cwm recovery ,does this have smthg to do with it?
arismelachrinos said:
no I did exactly what you said... I fully understood the instructions,I extracted it , I named it right and I moved it right... well, I will try again tomorrow but I don't think it will boot into it... Thomas boot.img has a cwm recovery ,does this have smthg to do with it?
Click to expand...
Click to collapse
What version of TWRP did you use? 2.8.1.0 will likely not work, use an older one instead.
arismelachrinos said:
cant understand what you mean in step 7 and 8..... i just unpacked boot.img (the img that i want to put a recovery on it) and then i created a folder and i copied split_img and ramdisk into it.....then i unpacked twrp.img and it replaced the previous split_img and ramdisk folders with the twrp ones..... i still have the folder i created with the original split_img and ramdisk folders from boot.img but i can understand what to do next....
well, sorry for that,...i think i got it now that i read it about 20 times..... one question though :
i copy ramdisk.cpio.gz from the twrp and i move it to the recovery folder of the boot img without extracting? just renaming it from ramdisk.cpio.gz to ramdisk-recovery.cpio ???
Click to expand...
Click to collapse
Adjusted the description of step 8, should be more clear now what to do.
I've also added a note to point out explicitly that each run of "unpackimg.bat" will overwrite existing data.
Thank you so much for the guide! Really appreciate it =D
mcfisch said:
What version of TWRP did you use? 2.8.1.0 will likely not work, use an older one instead.
Click to expand...
Click to collapse
I used the latest twrp...maybe that's why....I will try again and I will post here
thank you sooooo much.... i did it with the second try...the only thing i changed was that i downoaded a previous version of twrp because it wont work with the latest one...thanks a lot.... what about cwm? is it the same proccess?
CWM is included already. But you could split the latest cm boot.img and grab ramdisk-recovery.cpio from ramdisk/sbin to get the most up to date version
is this mean can add TWRP into .FTF files ?
that will be awesome
Can anyone share their twrp included boot.img for the latest thomas release?
i tried to do this on the cm12 expirimental build and the boot.img of that zip doesnt have a recovery folder inside ramdisk folder... i did create one just to see if it works and it didnt
arismelachrinos said:
i tried to do this on the cm12 expirimental build and the boot.img of that zip doesnt have a recovery folder inside ramdisk folder... i did create one just to see if it works and it didnt
Click to expand...
Click to collapse
Look for a *.cpio or *.cpio.gz file and replace that accordingly. The place doesn't really matter for you, the ROM knows where to find it. CM might expect it respectively at another place. Will take a look later if I can find something...
mcfisch said:
Look for a *.cpio or *.cpio.gz file and replace that accordingly. The place doesn't really matter for you, the ROM knows where to find it. CM might expect it respectively at another place. Will take a look later if I can find something...
Click to expand...
Click to collapse
can you please take look at this?because i did search all the ramdisk folder and i found nothing.... i uploaded the boot.img so that you dont have to download the rom zip
https://www.mediafire.com/?5d6swrdegr53iel
mcfisch said:
Look for a *.cpio or *.cpio.gz file and replace that accordingly. The place doesn't really matter for you, the ROM knows where to find it. CM might expect it respectively at another place. Will take a look later if I can find something...
Click to expand...
Click to collapse
Won't work like that. Needs a script to be inserted into the ramdisk, @pabx style, plus the recovery folder with ramdisk-recovery.cpio inside.
was thinking why the latest TWRP was not working, then realized that the TWRP is written to be loaded into the FotaKernal.
then it worked with TWRP flashed into FotaKernal.
have pabx_aosp_yuga-509 installed
1. Followed your steps exactly to create a new boot_pabx_aosp_yuga-509.img (with the latest TWRP image "recovery-twrp-2.8.4.1-yuga.img").
2. Flashed recovery-twrp-2.8.4.1-yuga.img into the FotaKernal.
3. Flashed the new boot_pabx_aosp_yuga-509.img
it works
Edit: On my Xperia Z c6002 (yuga)

[HOW TO] Flash PAC-ROM to Cricket / AIO (jflteaio) running I337ZTUUBND3

Hello all,
Using TWRP, I successfully flashed PAC-ROM to my Cricket 'jflteaio' or SGH-i337z ... I337ZTUUBND3, Galaxy S4.
A bit of helpful info for noobs: I rooted with 'towelroot' app --- Google it
And installed TWRP 2.7 from here
At this point...MAKE A BACKUP in TWRP!!! I AM NOT LIABLE FOR BRICKED DEVICES!
Now on to the real fun stuff! Follow these steps to flash Pac-Man ROM:
1. Download the GENERAL jflte rom 'zip' file and not the 'md5sum' from the PAC ROM website:
Download the zip HERE
2. Extract the zipped jflte pac rom into a new folder anywhere in Windows. In the new folder, navigate to this location:
\META-INF\com\google\android\
3. Download and install the free Windows program, NotePad++ --- Google it
4. Right-click on 'updater-script' in the folder \META-INF\com\google\android\
(IMPORTANT: Leave the 'update-binary' file alone; only modify the 'updater-script')
5. click on "Edit with NotePad++".
6. In NotePad++, Under the first word/command "assert" you will see a bunch of commands that start with 'getprop'. Find a spot where it reads '||' and make a new line directly after this. you will see many jflte codenames, so making your new line after you see 2 of the same codename and '||' will do.
7. Make sure the new line you made does not cut any commands in half and copy/paste in these lines of code:
Code:
getprop("ro.product.device") == "jflteaio" ||
getprop("ro.build.product") == "jflteaio" ||
(NOTE: This code will allow install of PAC-ROM on jflteaio)
8. Make sure to save the changes in the file. Close NotePad++.
9. Zip all the files you extracted from the original back up with 7zip or winrar... make sure the file extention is not '.7z' or '.rar'. Must be '.zip' to work. And the files you just zipped have to be in the root location of the zip file. In other words, make sure when you open your new zip, the first folder you see is 'META-INF'... for example in 7zip, you have to select all the elements(there are 5 in total...3 folders and 2 files) in the new folder you created earlier, and right-click and choose 7zip and 'add to archive'.
10. You can now flash the rom in TWRP from an sdcard by following the instructions HERE on XDA
(FINAL NOTE: By the way, make sure NOT to install the AT&T SafeStrap Kernel during the flash, as it may cause the ROM not to boot, and as always, make a TWRP BACKUP before you attempt flashing!)
I do not own any of the software in this guide. A special thanks to all the devs out there who make our lives better!
Best of skill (and luck) to you all!
raydantheman

How to modify boot.img for MIUI?

Hello guys,i was trying porting MIUI for Zenfone (I used Mi Pad 2's rom).I am following this guide :http://http://forum.xda-developers.com/android/software/guide-build-port-miui-rom-to-device-t3250984
I prepared the rom,now i am trying modifying boot.img but with Android Kitchen at guide it is impossible,so i googled and found this:http://github.com/shakalaca/ZenFone-boot-tools
and this:http://github.com/sndnvaps/intel-boot-tools
but i couldn't extract ramdisk and split_img files.
So how can i extract ramdisk and split_img files or is it possible?
Thanks!
Yeap its possible!
You should look this : https://github.com/xiaolu/intel-boot-tools
Yeah,i saw that,tried but when i drag boot.img top of the unpack.exe nothing happens
My recommendation is for you to use AndImgTool, download it here: https://basketbuild.com/filedl/devs?dev=dgadelha&dl=dgadelha/Tools/AndImgTool.exe
Me and tank use it to [un]pack the kernels.
Also you can use mboot.py by quanganh2627 .This script was made for Linux and it is working good.
- unpack: mboot.py -u boot.img
- repack: mboot.py new-boot.img
https://drive.google.com/file/d/0BwEWY6gMvYOedDV1LVJUVkN2dms/view
I think that you can use AOSP kernel for miui but maybe few changes in ramdisk will be needed.
Do you have space between ur computer's user account's username???If it is there,it won't work......
Try moving that unpacking software folder to Root C drive and then from there try perform dragging the img on to the unpack.exe file....
and for other ported roms ? can by port rom unbootable duo to non ported kernoel ?

[Guide] Unpack Update.app in phone

So there's threads about how to unpack UPDATE.APP on windows/PC/OS X so i decided why not do it on android too, this apps requires some additional tools to be downloaded just as OS X/Windows and linux needs as well. but process is otherwise similar. this tutorial doesn't need root!
NOTE THIS TUTORIAL isn't fully working on OREO on Huawei devices, it has some issues and i haven't found a workaround for it yet!​
Needed apps
Termux https://play.google.com/store/apps/details?id=com.termux
Recommended apps
Hacker keyboard
Needed files
https://github.com/atarii/split_updata.pl/blob/master/splitupdate
@Atarii 's modification of splitupdate to manually enter the partitions you want to unpack
The desired FW you wan't to unpack
Unpack process:
Download Termux
Open termux and type
termux-setup-storage This will allow termux to access your /sdcard
pkg install perl (this will install perl which the update.app process is using) once asked press y and enter.
copy the downloaded files to root of your SDCARD *We keep this simple*
Once copied type: cd storage
perl splitupdate UPDATE.APP partitionyouwanttoextract if everything goes well you should be good to go and having the selected files in a folder called output where selected files should be stored.
The unpack tutorial is done. But wait! If you want to browse the files you need to do one more thing or two.
Download android image kitchen
https://play.google.com/store/apps/details?id=com.redlee90.imagekitchenforandroid
This will allow you to *unpack boot/recovery and convert system image (also vendor, product, cust and version)
*in order to unpack a boot or recovery file you'll need to remove all code using a hex edit file until you see ANDROID text. Else it won't unpack. You can unpack aosp images easily with this tool and modify what you want and repack to flash it on your device tested with twrp image for honor 8.
I would suggest to not unpack/repack boot using this tool since it'll cause problem.
There's a python script that works to unpack boot and recovery which can be found https://github.com/liudongmiao/bootimg/blob/master/bootimg.py
For this you'll need to install python.
pkg install python and hit y and enter
Now you just do as the splitupdate part where you extract the file.
Command to unpack
python bootimg.py --unpack-bootimg similar is for ramdisk but you replace bootimg with ramdisk.
To repack just simply python bootimg.py --repack-bootimg
Please note if you repack ramdisk the boot might not work (it's a while since I tested this) now this covers up how you unpack boot and extract update.app from phone.
Credits to @Atarii for telling how to unpack boot on phone and for his custom splipupdate script
Sent from my FRD-L09 using Tapatalk
Known Issues:
If you get Killed when trying to extract system.img this is most likely because the image size is too big, this isn't due to small space available i guess its due to all ram is being taken yet i can't tell.
i get permission issues. yeah this can happen sometimes try chmod +x or chmod 0777 with root, it might help.
when typing termux-setup-storage i get lots of errors and i'm on 8.0 EMUI
This is not your fault it's a bug caused by android i'd guess, or app isn't adopted completely for 8.0

Categories

Resources