So i am some what of a noob but not an idiot. I have googled and feel that i have turned up with nothing. besides the updater-script what else do i have to change in META-INF folder to make my rom flashable. if someone could help point me in the right way that be great. My zip consists of a data folder, a system folder and a boot.img. i already know how to sign the zip. i just need help with the code to flash it.i keep getting error 6 in cwm
Related
Can I modify an existing one by simply dropping in updated bootscreen files, rosie.apk, etc.. and signing the existing rom zip?
Any good guides on how to do one if not, and/or how to use Flipz kitchen tool to create a rom?
Ceger
I am pretty sure if you sign the file and you modify it after that you will have to resign it. At least thats how it goes for other things that are similar that I deal with.
Kcarpenter said:
I am pretty sure if you sign the file and you modify it after that you will have to resign it. At least thats how it goes for other things that are similar that I deal with.
Click to expand...
Click to collapse
I understand that, just wondering if I can add new files and they will move or does some master script need to be updated to know to move the files. In other words, is it done by directory or by file?
For example, if I add some apps to /data/app in the zip will they be there on the phone when I install the ROM zip, etc.. More specifically, I have added an alternate boot sequence. The rom does not have a boot1.gif. If I add the new sequence with XML, will the boot1.gif be installed as well or do I need to update something that directs the install of the ROM to move that file or is it automatic as the folder is moved over?
Ceger
Ceger said:
I understand that, just wondering if I can add new files and they will move or does some master script need to be updated to know to move the files. In other words, is it done by directory or by file?
For example, if I add some apps to /data/app in the zip will they be there on the phone when I install the ROM zip, etc.. More specifically, I have added an alternate boot sequence. The rom does not have a boot1.gif. If I add the new sequence with XML, will the boot1.gif be installed as well or do I need to update something that directs the install of the ROM to move that file or is it automatic as the folder is moved over?
Ceger
Click to expand...
Click to collapse
I have found that the easiest thing to do is just put the files that you want to use to replace the old ones into a signed zip and then flash just those files I have tried altering a rom file with no success
wtphoto said:
I have found that the easiest thing to do is just put the files that you want to use to replace the old ones into a signed zip and then flash just those files I have tried altering a rom file with no success
Click to expand...
Click to collapse
Oh well, was trying to have a one step zip. I guess I can make at least have a 2 step process which is better than 4-5.
Thanks,
Ceger
Yes you can modify just about anything in the rom and flash your zip as long as it is signed and the update script is correct. I always make all my changes to a rom before flashing it so i do not have to flash several different things etc.
The update script is located in RomName\META-INF\com\google\android\
Lets look at a very simple update script to show you what i mean.
In this update script it is to write something to /system
example:
show_progress 0.1 0
copy_dir PACKAGE:system SYSTEM:
show_progress 0.1 10
We see here that whatever is in the system folder within the signed zip will be written to the phone
in this case i am writing /system/app/mobiledefense.apk
That will be the only file written to the phone and will be written to /system/app
The update script is not specific to every file so you can have 1 thing in the system folder or 100 and it will write everything in there.
One thing that many people mess up on is not using a update-script file when they sign a .zip file. The recovery has to know what to flash or it will not flash anything.
So the answer is yes you can change many things and then flash the signed update.zip file.
Not everything can be done this way but most things will work.
But for example changing the boot sceen can be done even if the file names are different as long as the folder structure stays the same and the .XML file is the correct one for the boot screen. I opened the .zip of a rom deleted everything out of the boot screen folder and dropped in all the files from the nexus one hero hybrid boot screen re signed the zip and everything flashed perfect. I changed many other things as well in the .zip like rosie.apk, sound files, lockscreen files, busybox files, added apps to /system/app and just resigned the zip and everything flashed the way i wanted it to and works perfect.
The way to correctly zip a file is to extract the zip modify what you want then select everything inside the zip right after you open the folder and the highlight everything select add to archive and then zip it up now sign that .zip
so say you extract the ROM and it is named Rom123 now you will have a folder named Rom123 open that folder and select everything file or folder in there and then hit add to archive that will make another zip right there called Rom123.zip pull that zip out to the desktop and sign that zip file and thats it.
I Know that is confusing as it is late as hell and i am tired but wanted to answer this real quick.
zippy-man said:
Yes you can modify just about anything in the rom and flash your zip as long as it is signed and the update script is correct. I always make all my changes to a rom before flashing it so i do not have to flash several different things etc.
The update script is located in RomName\META-INF\com\google\android\
Lets look at a very simple update script to show you what i mean.
In this update script it is to write something to /system
example:
show_progress 0.1 0
copy_dir PACKAGE:system SYSTEM:
show_progress 0.1 10
We see here that whatever is in the system folder within the signed zip will be written to the phone
in this case i am writing /system/app/mobiledefense.apk
That will be the only file written to the phone and will be written to /system/app
The update script is not specific to every file so you can have 1 thing in the system folder or 100 and it will write everything in there.
One thing that many people mess up on is not using a update-script file when they sign a .zip file. The recovery has to know what to flash or it will not flash anything.
So the answer is yes you can change many things and then flash the signed update.zip file.
Not everything can be done this way but most things will work.
But for example changing the boot sceen can be done even if the file names are different as long as the folder structure stays the same and the .XML file is the correct one for the boot screen. I opened the .zip of a rom deleted everything out of the boot screen folder and dropped in all the files from the nexus one hero hybrid boot screen re signed the zip and everything flashed perfect. I changed many other things as well in the .zip like rosie.apk, sound files, lockscreen files, busybox files, added apps to /system/app and just resigned the zip and everything flashed the way i wanted it to and works perfect.
The way to correctly zip a file is to extract the zip modify what you want then select everything inside the zip right after you open the folder and the highlight everything select add to archive and then zip it up now sign that .zip
so say you extract the ROM and it is named Rom123 now you will have a folder named Rom123 open that folder and select everything file or folder in there and then hit add to archive that will make another zip right there called Rom123.zip pull that zip out to the desktop and sign that zip file and thats it.
I Know that is confusing as it is late as hell and i am tired but wanted to answer this real quick.
Click to expand...
Click to collapse
Perfect, just what I was looking for.
Thank you, just made my day!
Ceger
i got a question for someone obviously brighter than me.... i made some higher level mod's to my framework-res.apk utilizing apkmanager... i was able to decompile and compile with no errors but i need it signed so i can push it .... i used apkmanagers signing utiliy but i get fc's like crazy.. i got the same result using android kitchen signing utility... i can copy over the res folder into another apk but its the resources.arsc i need too and when i copy it over i get a bootloop aswell..
before you respond... i need this file to be able to be pushed .. i know i can create and update.zip and sign the zip but that isnt going to work for what i'm trying to do
any help would be greatly appreciated
Copying resources.arsc to original apk and using update.zip gives me bootloop aswell. Just not funny, I can't flash my phone to test every possible combination.
Too bad you can't use AVD to flash roms... hmmm
I know I have done this before and this is a noob question, but lately I've been having trouble with this.
If I make changes to the zip file of a ROM (eg replace a few existing files, and remove some unwanted system APKs, but not add anything new), do I need to sign the zip before flashing or just flash straight after editing? Also what's the best tool to use to replace the files within the zip? I trust WinRAR will do the trick...
djsubtronic said:
I know I have done this before and this is a noob question, but lately I've been having trouble with this.
If I make changes to the zip file of a ROM (eg replace a few existing files, and remove some unwanted system APKs, but not add anything new), do I need to sign the zip before flashing or just flash straight after editing? Also what's the best tool to use to replace the files within the zip? I trust WinRAR will do the trick...
Click to expand...
Click to collapse
I've never added anything (yet!), just deleted un-wanted APK's and altered some system files (ie build,prop etc). I've never signed anything and I used IZArc although only as that's what's installed on my XP system.
This is something that I too would like to do more so that I can further personalize and tweak some of these already great ROMS, so I'm also curious for some pointers from more the experienced.
Check the portal, there's an app to create flashable zips there.
PS - POST QUESTIONS IN THE GENERAL SECTION !!!!!!!!
You can set a flag in recovery to check for signatures or not. When it is not set you can flash any zip file
Sent from my HTC Desire S using XDA App
jorgen2009 said:
You can set a flag in recovery to check for signatures or not. When it is not set you can flash any zip file
Sent from my HTC Desire S using XDA App
Click to expand...
Click to collapse
I tried this once, and then I flashed the zip. It was a CM7 zip which would normally take at least 20-30 seconds to complete, but this modified zip flashed in less than ten seconds. It said successfully flashed but when I rebooted nothing had actually happened. Hence I was wondering what went wrong?
hi all i've been trying to deodex my stock 28 rom i have deodexed system/app & system/framework but i cant use adb to push them into my rom so i tried to make a flashable zip to flash them in cwm. but ive never made one before i have the file structure right i think but cant get the update-script right could some one please tell me where ive gone wrong or write it for me. if it gets done then it will also be an easy way for other users to deodex aswell. heres my atempt: https://dl.dropbox.com/u/90938124/deodex_xj-signed.zip
Edit: i tried to learn from here: http://forum.xda-developers.com/showthread.php?t=732957
Hello guys,
caus ive less than 10 posts, i cant reply in the developers section.
I downloaded this rom - zNXT
there is an addon zip. i flashd both.
now i will make my own "addon" file only with these thinks i like to have.
( lockscreen,bootscreen, the scerren (i dont now wich name it is) in the attachments, ... )
can i copy the files i want in my zip and flash it ? .. and for what is the META-INF folder ?
soooo. i want to learn that all and some answers are very helpful ^^
GreeZ
Slluxx
you can edit the zip you have to make sure the folder structure is right to where you want the files to flash to and you need to digitaly sign the zip for it to flash. META-INF is where the update-binary and the updater-script are. The update-binary updates the su binary (i think) and the updater-script tells CWM what goes where out of the signd zip to the android system and mount & unmounts the partitions you want to flash files to it is writen in edify scripting which you can learn or borrow one out of someone elses zip and edit as you want instead of writing a whole one your self. The digital signature you sign the zip with is in there to. There is a certain structure to the folders aswell which must be right or you will get flashing error.
so thats a thing that i cant do without intensive learning ?
easy said. i cant drag n drop into the zip and flash.
i have to write data where whatever has to go and id has to be in the right folder structure ... ,..., ...
hm.
anyway thanks for your help
if the files are just replacing others in the zip then all you have to do is extract the zip change the files you want then re-zip then download android auto signer to sign the zip then your good to go. oh and make sure you delete the old signature files out of META-INF folder there will be 3 files as soon as you open META-INF delete them
yeah ..
i dont know wich data is exactlx for what and where it is ..
i want to flash the stock rom with a few datas of the custom rom and a few from the "addon" zip ..
so i dont know if it works. and what i have to edit/delete
before this i only followd the flashing instuctions. i dont made any from these things from my own so sorry that im a noob