[Q] problem installing a modded rom - General Questions and Answers

I am having hard time to install a ROM after I modded it a bit.
The ROM itself had been installed already and works perfectly.
I was trying to change a few things like icons, bootanimation, default launcher and other stuff but the phone keep giving me an error and fail to install the file.
my phone is HTC HD2 t-mobile version, the ROM is android 2.3.4 with CM7, I am installing ROMs using MAGLDR 1.13 + clk 3.1.0.1.
I modified the zip file using 2 methods - both led to the error
1. unpack the zip file, replace the files, repack the folders back together into zip
2. swapping the files without extracting the folders out of the zip file
in both cases I used winrar (my computer runs 64bit win7).
am I missing something?
any help will be much appreciated

This is strange... I basically use the same method to mod minor stuff (like icons)... And it works for me without problems.
Are you sure your repackaged file has the same structure? Maybe unpack both original package and your modified one and compare folders and files using WinDiff or something?

I ran a check with "Beyond Compare 3" and it appeared to be the same except the files I've replaced.
What archiving software are you using?
There is no need to sign the zip or anything like it, right?

I'm using Total Commander which has zip functionality built-in.
No, I don't need to sign anything either (although I don't know, maybe it requires setting development options in android's settings).

Related

Question about modifying signed Rom zip files

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

Custom clockworkmod compatible update.zip

Hello, I would like to create my own update.zip that would be compatible with clockwork mod. I have several files in several locations that I manually copy over after new installs like multicolored bash nano iwconfig iwlist etc. And I think it would be much easier to create a installable package for that, I also delete a number of built I. Apps like tweeter amazon etc. And I have seen the scripts inside oyhers update.zip's that I could add the bash commands to remove those things as well.unfortunately I know nothing about what clockworkmod wants and I see binarys inside these zips dont know if those are customized for each zip or the same in all of them, I dont know what files or information is absolutely required. The best possible solution is if I had a blank update.zip that held all of the required files settings and all I needed to do was add my files and asd a few lines to a preexisting script to remove sum stock apps.thinking back I might have seen a file containing all the files names and md5 chucksums for each as well which if necessary I can do. Is there something like this available for download sumwhere? If not ajy resources to learn the required information and find the required binarys.thank you in advance.
Sent from my Droid using Tapatalk
Hi,
I've been trying to learn the same thing. I'm curious if you found anything useful since posting this.
Of course, if I find anything, i'll post back here too.
Thanks.
Same problem here
Good to hear someone with same problems. I want to create a generic ROM for myself and I want to use ClockworkMod to help flash it instead of using fastboot.
Well, I have found no documentation about what ClockworkMod may need for a zip file.
But I guess it could be possible to just replace them with your own by downloading an existing zip file created by someone else.
I'll try it to see if that works or not. Of course, a documentation would be better.
I regularly flash a new CM7 Nightly as they are released and I have to manually modify some things each time a new rom is flashed. I change screen density and add a notification ringtone that CM7 does not have. I wanted to automate that. Since I have to reflash the Google Apps each time anyway, I thought why not modify the gapps zip to include my changes. After searching the web I found a little info about how to do it. I just modify the zip on my computer using WinRar, copy the file to my device and re-sign the package using signapktic which is free on the market. Then flash using CWM. It worked great. No more manual adjustments. There are some instructions here which helped me:
http://forum.cyanogenmod.com/topic/15030-moving-apps-to-system/
I been getting into the kitchen
http://forum.xda-developers.com/showthread.php?t=633246
So far i`ve managed to integrate a few apps , ringtone should be easy
next the fonts from utmost rom
thanks to the kitchen, Im now running at script kiddie level

[Q] How to add custom APK files to a zip ROM?

Hi all,
I'm trying to add APK files to custom rom (my last try was Pyramid3D v7.3.0 ROM).
In each ROM file (ZIP file), I noticed APK files were installed in two folders:
data\app: which, as far as I understand, contains applications which can be unistalled after flashing
system\app: for applications which cannot be deleted after flashing (except using ADB commands or tools such as Titanium Backup)
I tried both to add my apk files to each of those folders using WinRAR without unzipping the ROM (simply using Drag N Drop). Then flashed (with signature verification disable), but among all APK files I put, only one is successfully installed (french apk file called "Page Jaune").
Of course, I can install remaining APK files after flashing but I really don't understand why some are installed and some not...
Any idea?
Try this thread http://forum.xda-developers.com/showthread.php?t=1198035
lol google search sent me to this page, thanks for the link it's exactly what I was looking for

[Q] Editing zip before flashing a ROM

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?

[Q] (Stock Deodexing) -- boot.img failure on update.zip flash? Fix, Replace? Re-Zip?

I have a ZTE990 avail.
Currently I'm rooted with no other roms installed, simply stock, and odexed.
I've tried to manually de-odex using baksmali, Xultimate, etc. All were a pain, all wouldn't work properly.
I found someone and downloaded someone who just simply uploaded a Stock_Deodex.zip rom. Sounded perfect.
So I boot into CWM, try to update and...
assert failed: write_raw_image("/tmp/boot.img","boot" android
Click to expand...
Click to collapse
Since I have stock.. and am just trying to De-Odex.
Can I just unzip the Stock_Deodex.zip, delete the current (apparently faulty) boot.img, and replace it with one of the ones created with the cwm recovery, re-zip and attempt to update as usual?
Or since (if my understanding is correct), the only thing necessary for a system to become deodex is the files in /system/app and /system/restore.
Obviously when I un-zip stock_deodex.zip I have access to them. Could I possibly just replace the two folders (somehow?) and be properly de-odexed?
Any other options that I could use that'd be best?
Much appreciated to anyone who helps, thanks!

Categories

Resources