[Q] Can anyone spot where I'm going wrong - Nexus One Q&A, Help & Troubleshooting

Ok I need some help with update-script for a theme I have in metamorph format. I'm really lost with this don't know how to do it the correct way. I keep getting can't find update-script when I flash through recovery. If anyone can please help me or poke me in the right direction that would be nice.

I always follow this guide to create update zip file:
http://www.londatiga.net/it/how-to-create-android-update-zip-package/
But remember, when you create "update-script" file, make sure you:
1. put an extra line in its end
2. all line breaks must be in Unix format
To sign the zip package, either you may use the way in the tutorial, or you can use ZipSigner on your Android to sign a zip.

Can you spot where I'm going wrong.
show_progress 0.1 0
delete SYSTEM:app/Facebook.apk
delete SYSTEM:app/GenieWidget.apk
delete SYSTEM:app/GoogleSearch.apk
delete SYSTEM:app/ADWLauncher.apk
delete SYSTEM:app/Contacts.apk
delete SYSTEM:app/Music.apk
delete SYSTEM:app/LatinIME.apk
delete SYSTEM:app/Browser.apk
copy_dir PACKAGE:system SYSTEM:
show_progress 0.2 50
set_perm_recursive 0 0 0755 0644 SYSTEM:app
show_progress 0.2 600
copy_dir PACKAGE:sdcard SDCARD:
show_progress 0.3 100

If the error you're getting says it can't find the update script, the error is likely to be the name or location of the script, and not the script content...
Sent from my Nexus One using XDA App

danger-rat said:
If the error you're getting says it can't find the update script, the error is likely to be the name or location of the script, and not the script content...
Sent from my Nexus One using XDA App
Click to expand...
Click to collapse
right ok this is the structure:-
update.zip
META-INF=
com
CERT.RSA
CERT.SF
MANIFEST.MF
com=
google
google=
android
android=
update-script
Is there any thing wrong?

Do you have the update binary in the android folder?
Sent from my Nexus One using XDA App

Thank you for your help. I've found out what was the problem was, it was me being a fool and making a beginners mistake. Too little sleep and rushing to get it ready for gingerbread. Well thats what I'm saying and i'm going to stick to it
Everything was perfect from the start just me double zipping the update folder, how stupid do I feel? Very

Related

Almost Done - Rom building questions

1. Additional apps in /data/app/ will not install. I've read that this has to do with the update-script. I've based mine off Fresh and unofficial Modaco 1.3 and believe my script to be fine but here it is anyway.
Code:
show_progress 0.1 0
delete_recursive DATA:dalvik-cache/
delete_recursive DATA:boot-cache/
format SYSTEM:
copy_dir PACKAGE:system SYSTEM:
set_perm_recursive 0 0 0755 0644 SYSTEM:
set_perm_recursive 0 2000 0755 0755 SYSTEM:bin
set_perm 1014 2000 0550 SYSTEM:etc/dhcpcd/dhcpcd-run-hooks
set_perm 0 2000 0550 SYSTEM:etc/init.goldfish.sh
set_perm 1002 1002 0440 SYSTEM:etc/dbus.conf
set_perm_recursive 1002 1002 0755 0440 SYSTEM:etc/bluez
set_perm 0 0 0755 SYSTEM:etc/bluez
set_perm 0 3003 02755 SYSTEM:bin/netcfg
set_perm 0 3004 02755 SYSTEM:bin/ping
set_perm 0 0 04755 SYSTEM:bin/su
delete DATA:app
delete DATA:init.sh
delete DATA:local
delete DATA:dalvik-cache
copy_dir PACKAGE:data DATA:
set_perm 1000 10000771 DATA:app
show_progress 0.1 10
show_progress 0.2 0
write_raw_image PACKAGE:boot.img BOOT:
show_progress 0.2 10
2. Is there anything extra I need to add to the rom to get wifi tethering working once the /data/app actually does work? I remember when root first occured wifi tether wouldn't work on the stock rom.
3. What do I need to do so people have already done apps2sd do not experience any FC issues?
4. I have png optimized many apks (ie framework-res, com.htc.resources). I took it a step further and recompressed them but the recompressed versions caused the phone to stay stuck on boot HTC logo. I tried a rom with original framework apks and a few recompressed apks from system and they suffered FC.
I am using Ubuntu 9.10 (Karmic)'s built in archiver for these compressions. I may try transferring them to Win7 and use 7zip but I don't see why that should make a difference. A zip is a zip right?
Hope to hear something back soon even though it's christmas eve. I'd like this rom to be my xmas gift to this forum.
Please help someone?
theresthatguy said:
1. Additional apps in /data/app/ will not install. I've read that this has to do with the update-script. I've based mine off Fresh and unofficial Modaco 1.3 and believe my script to be fine but here it is anyway.
Click to expand...
Click to collapse
That update script looks very familiar. Everything looks fine in your script. It should be copying /data/app over just fine.
2. Is there anything extra I need to add to the rom to get wifi tethering working once the /data/app actually does work? I remember when root first occured wifi tether wouldn't work on the stock rom.
Click to expand...
Click to collapse
That was just a matter of wifi tether not supporting our phones at first. You don't need to do anything special.
3. What do I need to do so people have already done apps2sd do not experience any FC issues?
Click to expand...
Click to collapse
If you are using my boot.img or unofficial modaco's boot.img and you have the script in /system/bin/a2sd then you don't need to do anything extra. You already have the commands in the update script to prevent FC's. Just an FYI that my boot.img has changes beyond the stock one.
4. I have png optimized many apks (ie framework-res, com.htc.resources). I took it a step further and recompressed them but the recompressed versions caused the phone to stay stuck on boot HTC logo. I tried a rom with original framework apks and a few recompressed apks from system and they suffered FC.
Click to expand...
Click to collapse
I'm a little confused by what you are asking here. But the /framework/ files can be very sensitive to compressing and zipaligning. If you are receiving FC's after doing it then they were just likely pushed past their breaking point.
I hope that helps you. Good luck!
Hey flipz thanks for the reply.
1. I wonder why the /data/apps aren't copying if they should be?
2. Cool, good to know
3. I have added that apps2sd script to my boot image but I can't figure how to get it back together. Keeping same error. Maybe I'll borrow yours if that's okay until I can figure it out.
4. Im using ubuntu and was dragging and dropping tyrant new pngs into the apks. I decided to recompress and zipalign any apk that I "optimized". This caused the frameworks to not let the phone boot. So I replaced those with my backup non-recompressed versions that's when I found out all the other apks were force closing.
I guess I'm asking if theirs a specific procedure for rezipping an apk.
Some good info here. I've been wanting to learn how to make apps and roms and have been bookmarking threads like this. Thanks to everyone for being so helpful.
FWIW - I'm not using Ubuntu, but FileRoller 2.28.1 on Slackware works fine to extract and compress zips. It's just a front end for gzip.
Look at your content or path for the FC issues. It's not the compressor program you're using on the .apks.
incogneato said:
FWIW - I'm not using Ubuntu, but FileRoller 2.28.1 on Slackware works fine to extract and compress zips. It's just a front end for gzip.
Look at your content or path for the FC issues. It's not the compressor program you're using on the .apks.
Click to expand...
Click to collapse
Okay so I have the optimized non-recompressed versions of apks let's say maps for example. Then I decide to extract it, compress it for smaller file. Now as the new compressed version if FCs. Doesn't make sense to me?
Are you re-signing the apks ?
theresthatguy said:
Okay so I have the optimized non-recompressed versions of apks let's say maps for example. Then I decide to extract it, compress it for smaller file. Now as the new compressed version if FCs. Doesn't make sense to me?
Click to expand...
Click to collapse
obelisk79 said:
Are you re-signing the apks ?
Click to expand...
Click to collapse
^this.
Also, maybe I'm missing something, but using the standard *.zip function in file roller the only options available are password/encrypt. How exactly are you trying to change the compression?

Help please

i get failure at line 9 symlink dumpstate SYSTEM: bin/dumpcrash on both of these wtf am i doing wrong? i've been flashing roms and wanted an easy way to get the apps that are usually left out i like and the rosie i like with any rom.
http://www.4shared.com/file/ZqqLR1uw/sdotapps-signed.html
http://www.4shared.com/file/hTObX773/sdotrosie-signed.html
i'll take a look for you. downloading now. i know i've created a few of these myself, but i'm very limited, hopefully it will be something simple!
EDIT:
You have to update your update-script in the META-INF folder.
This is from my customization zip.
Code:
assert compatible_with("0.2") == "true"
assert getprop("ro.product.device") == "heroc"
show_progress 0.1 0
delete SYSTEM:app/htcbookmarkwidget.apk
delete SYSTEM:app/com.htc.TwitterWidget.apk
delete SYSTEM:app/com.htc.MusicWidget.apk
delete SYSTEM:app/HtcTwitter.apk
delete SYSTEM:app/Flickr.apk
delete SYSTEM:app/LiveWallpapers.apk
delete SYSTEM:app/Sprint_Nscar.apk
delete SYSTEM:app/Sprint_Core.apk
delete SYSTEM:app/HtcLockScreen.apk
delete SYSTEM:app/Calculator.apk
delete SYSTEM:app/Browser.apk
delete SYSTEM:app/Sprint_Navigation.apk
delete SYSTEM:media/bootanimation.zip
show_progress 0.1 10
show_progress 0.2 0
copy_dir PACKAGE:system SYSTEM:
show_progress 0.2 10
My update script adds my theme, customized bootscreen, some other JChiSurf's mods and removes those apps listed.
I think you should be able to combine your two zips into one if you'd like.
riggsandroid said:
i'll take a look for you. downloading now. i know i've created a few of these myself, but i'm very limited, hopefully it will be something simple!
EDIT:
You have to update your update-script in the META-INF folder.
This is from my customization zip.
Code:
assert compatible_with("0.2") == "true"
assert getprop("ro.product.device") == "heroc"
show_progress 0.1 0
delete SYSTEM:app/htcbookmarkwidget.apk
delete SYSTEM:app/com.htc.TwitterWidget.apk
delete SYSTEM:app/com.htc.MusicWidget.apk
delete SYSTEM:app/HtcTwitter.apk
delete SYSTEM:app/Flickr.apk
delete SYSTEM:app/LiveWallpapers.apk
delete SYSTEM:app/Sprint_Nscar.apk
delete SYSTEM:app/Sprint_Core.apk
delete SYSTEM:app/HtcLockScreen.apk
delete SYSTEM:app/Calculator.apk
delete SYSTEM:app/Browser.apk
delete SYSTEM:app/Sprint_Navigation.apk
delete SYSTEM:media/bootanimation.zip
show_progress 0.1 10
show_progress 0.2 0
copy_dir PACKAGE:system SYSTEM:
show_progress 0.2 10
My update script adds my theme, customized bootscreen, some other JChiSurf's mods and removes those apps listed.
I think you should be able to combine your two zips into one if you'd like.
Click to expand...
Click to collapse
thanks man, i shouldnt have borrowed an update script and not looked at it. grrr at me. yea i know i can combine the two but i may not what the rosie sometimes lol. thanks again
edit: i may pm you... i see what you did with your update script and me likey but not that smarty lol.
sdotcarlisle said:
thanks man, i shouldnt have borrowed an update script and not looked at it. grrr at me. yea i know i can combine the two but i may not what the rosie sometimes lol. thanks again
edit: i may pm you... i see what you did with your update script and me likey but not that smarty lol.
Click to expand...
Click to collapse
alright, well i'm usually flying by the seat of my pants and just learn as i go, after many mistakes, but if i can be of any help, i'll try.
will be at work for another hour or so, and then will be back on later tonight, depending on the mrs.
riggsandroid said:
alright, well i'm usually flying by the seat of my pants and just learn as i go, after many mistakes, but if i can be of any help, i'll try.
will be at work for another hour or so, and then will be back on later tonight, depending on the mrs.
Click to expand...
Click to collapse
Right on thanks again.

Updater-script

I put together a theme that I want to be able to install on my phone. Issue is I am not 100% what updater-script to use nor how to have it setup so that it will put the files in the correct place...do I have to have a command to delete the .apk files that I am theming? Any help would be appreciated. I have attached my file. I am getting a status 6 error so I know that it cannot read something. Not sure what is wrong.
Hatman41 said:
I put together a theme that I want to be able to install on my phone. Issue is I am not 100% what updater-script to use nor how to have it setup so that it will put the files in the correct place...do I have to have a command to delete the .apk files that I am theming? Any help would be appreciated. I have attached my file. I am getting a status 6 error so I know that it cannot read something. Not sure what is wrong.
Click to expand...
Click to collapse
I use update-scripts mainly because if you do something wrong in the script it tells you what line you failed on and you can fix it. Also it's just what I learned on and what I'm comfortable with. If you're flashing a theme good rule of thumb is to make sure you wipe the dalvik cache you can do this with your script.
If you're working with windows don't use note pad it doesn't format the script properly. Try notepad++ if you're on linux just use gedit mac text wrangler.
Make sure you have the correct directory structure set up ie
META-INF/com/google/android/update-script then system/app and or framework.
Here's a simple script that will do the trick for you.....
Code:
show_progress 0.1 0
delete_recursive DATA:dalvik-cache
copy_dir PACKAGE:system SYSTEM:
show_progress 0.2 100
Hope this helps.
Thanks Lou, but I am still getting the error Status 6...that means that it cannot read the file...I am using notepad ++ to edit it. I used only what you provided in the file and the path to the file is Themename\META-INF\com\google\android I also have an update-binary in that dir...do I delete that file?
Try this one.
touchpro247 said:
Try this one.
Click to expand...
Click to collapse
I did not get any error this time and it said that it installed but when I boots up nothing was actually installed.
Hatman41 said:
I did not get any error this time and it said that it installed but when I boots up nothing was actually installed.
Click to expand...
Click to collapse
You don't need an update-binary if you're using an update-script. When you zip up your folders make sure you only have at minimum to folders on your desktop that your compressing the META-INF and it's sub directories and the system folder and it's sub directories don't put those inside anything just select and compress them. Once they're zipped make sure to sign the folder.
If the script didn't give you any errors it sounds like you may have put the META-INF and the system folders inside another folder before you zipped it which may be why nothing installed.
HeyItsLou said:
I use update-scripts mainly because if you do something wrong in the script it tells you what line you failed on and you can fix it. Also it's just what I learned on and what I'm comfortable with. If you're flashing a theme good rule of thumb is to make sure you wipe the dalvik cache you can do this with your script.
If you're working with windows don't use note pad it doesn't format the script properly. Try notepad++ if you're on linux just use gedit mac text wrangler.
Make sure you have the correct directory structure set up ie
META-INF/com/google/android/update-script then system/app and or framework.
Here's a simple script that will do the trick for you.....
Code:
show_progress 0.1 0
delete_recursive DATA:dalvik-cache
copy_dir PACKAGE:system SYSTEM:
show_progress 0.2 100
Hope this helps.
Click to expand...
Click to collapse
+1 I had the error 6 when I made one in notepad and switched to notepadd++. I think I also had to stop using windows explorer to copy it to my phone, but rather adb pushed it. Windows is kinda quirky like that, sometimes.
HeyItsLou said:
You don't need an update-binary if you're using an update-script. When you zip up your folders make sure you only have at minimum to folders on your desktop that your compressing the META-INF and it's sub directories and the system folder and it's sub directories don't put those inside anything just select and compress them. Once they're zipped make sure to sign the folder.
If the script didn't give you any errors it sounds like you may have put the META-INF and the system folders inside another folder before you zipped it which may be why nothing installed.
Click to expand...
Click to collapse
Ok so I took both the META-INF folder and the system folder and moved them both to the root of C and then I zipped both and then signed the zip...now it does nothing...I go into recovery....then I select the zip file and the screen just flashes and nothing happens.
If you want to see what I have done you can get the theme file here. This is for SkyRaider 3.3.3 with the Ucommon pack and all credit for the .png files goes to RUJELUS22, Riptide9, Defitism, Jascias and of course to Ihtfp69 for making the ROM
Download --->> http://bit.ly/aGP66D
Hatman41 said:
I did not get any error this time and it said that it installed but when I boots up nothing was actually installed.
Click to expand...
Click to collapse
I'll try flashing your theme and let you know.
touchpro247 said:
I'll try flashing your theme and let you know.
Click to expand...
Click to collapse
Ok...i forgot to include that it is for the uncommon theme pack for SkyRaider 3.3.3 as it has a custom Rosie that is themed.
Hatman41 said:
Ok...i forgot to include that it is for the uncommon theme pack for SkyRaider 3.3.3 as it has a custom Rosie that is themed.
Click to expand...
Click to collapse
To late lol...
Worked, use this one. Just add the files to the zip.
touchpro247 said:
To late lol...
Worked, use this one. Just add the files to the zip.
Click to expand...
Click to collapse
So I took your file and added it to mine...took both directories and moved them to my C drive...then zipped them up and signed them...went to recovery and installed it...says it was installing...when phone boots back up...no theme installed.
Hatman41 said:
So I took your file and added it to mine...took both directories and moved them to my C drive...then zipped them up and signed them...went to recovery and installed it...says it was installing...when phone boots back up...no theme installed.
Click to expand...
Click to collapse
Don't do that. Just drag your app and framework folders to my zip.
Or
Copy and paste your apps/framework where you see the placeholders.
The reason you can't add it to your file is in your file where it saids "services" it should say "system". And a few other things is wrong w/ your file that I will list when I get a chance.
touchpro247 said:
Don't do that. Just drag your app and framework folders to my zip.
Or
Copy and paste your apps/framework where you see the placeholders.
The reason you can't add it to your file is in your file where it saids "services" it should say "system". And a few other things is wrong w/ your file that I will list when I get a chance.
Click to expand...
Click to collapse
Woot...worked perfect...thanks alot touchpro247!!!!
Hatman41 said:
Woot...worked perfect...thanks alot touchpro247!!!!
Click to expand...
Click to collapse
Np...
This theme is badas* btw
touchpro247 said:
Np...
This theme is badas* btw
Click to expand...
Click to collapse
Thanks...soon as I figure out why my Rosie is not working as it should I will post the theme for peeps to dl. I only put the theme together...I took 2 EVO themes and took the .png files that I liked and made this one. I am using the uncommon Rosie. I will prob also pull the clock as you can see in this screen shot you can see some of the other numbers in it...it only does this for the flip clock...the regular non-flip clock it does not do that.
***Edit*** Ok have the Rosie fixed...I forgot to include the services.jar from the uncommon pack.
Ok I have everything working correctly now have I have posted it here http://forum.xda-developers.com/showthread.php?p=9034373#post9034373

how to create galaxy s update script

hi every body
can any one explain how to creat update script for galaxy s , im trying to cook rom based on xxjpy but usually i have problem with update script , i need to know how to create it incompatible with rom files and arrangment , whats the code and its functions we will write it in script and depend on what , finally in detail so i can create my own
thanksssssssssss
Well, the best thing to do is to google for some update scripts and modify ,but if you really want to write your own script from scratch don`t use notepad, use notepad++ or something like that.
here is an example and please try to understand it, follow line by line and see what it does :
show_progress 0.1 0 >this fills the progress bar
copy_dir PACKAGE:ghost TMP:/ghost > copy from your .zip (/ directory) to internal TMP folder which is in the ramdisk (all folders that are CAPITALISED are located in ramdisk)
set_perm 0 0 755 TMP:/ghost/test > setting permission to execute the test file
show_progress 0.1 10
copy_dir PACKAGE:system SYSTEM: this copies from /zip/system directory to that SYSTEM in ramdisk
show_progress 0.2 0
format CACHE: formats cache folder
delete_recursive SYSTEM: this deletes SYSTEM folder
symlink toolbox SYSTEM:bin/cat this creates virtual shortcuts google it for more
symlink toolbox SYSTEM:bin/chmod
what i`ve told you here is how i understand it... best for you is to try to download an update.zip and see what it does(opening that update script and see where it leads to)
Thanks my dear to reply me but is there web site that if i open it i will know and study and understand how to write it and create command to complete the script
yeah . google : how to make android update scripts
try to make some simple update.zips like adding an app to your phone via recovery .... put some print_ui in it so you can debug it...and furthermore try to flash your phone with another firmware...with a custom update script made by you.

Making flashable zip help!

Hello, I am trying to make a flashable zip that replaces framework-res.apk in CM9. I have searched and read a bunch of other threads on this, but they all seem to be out of date and none of them actually address the update-binary. Whenever I flash my zip, it aborts due to "error 4" or sometimes "error 0." I have been just copying and pasting the update-binary from other zips, but it seems to give me these errors.
I've attached the .zip in case someone wants to look at it. I'm almost positive my script is solid. Thanks
Script (written in notepad++):
ui_print("Modified framework for CM9 nightly 04/02/2012");
ui_print("by korockinout13");
show_progress(1, 1.5);
ui_print("Installing now...");
run_program("/sbin/busybox", "mount", "/system");
package_extract_dir("system", "/system");
set_perm(0,0,0644, "/system/framework/framework-res.apk");
run_program("/sbin/busybox", "unmount", "/system");
ui_print("Happy didling!!!");
Try taking out the commas between the 0 0 0644 (per this).
jmtheiss said:
Try taking out the commas between the 0 0 0644 (per this).
Click to expand...
Click to collapse
That guide isn't in edify though, so those guidelines are out of date. I also think that the script would fail once it got to that step, but mine fails instantly and nothing from the script shows up at all.
in notepad ++ is it a UNIX file or Dos/Windows?
do you have a update binary compatible with ICS ? (this one took me a whole night)
sometimes its just best to start with someone elses script, erase everything and start yours, working these files on windows can be a pain.
I have also used D4 update zip maker to proof my scripts and re-save them in correct format, when i run into odd issues.
korockinout13 said:
That guide isn't in edify though, so those guidelines are out of date. I also think that the script would fail once it got to that step, but mine fails instantly and nothing from the script shows up at all.
Click to expand...
Click to collapse
cwm usually proof reads the script to make sure there are no errors and it can complete the task before it starts. if you have an error at the end of the script, nothing will happen.
error 4 isnt familiar but 0 is.
TRusselo said:
in notepad ++ is it a UNIX file or Dos/Windows?
do you have a update binary compatible with ICS ? (this one took me a whole night)
sometimes its just best to start with someone elses script, erase everything and start yours, working these files on windows can be a pain.
I have also used D4 update zip maker to proof my scripts and re-save them in correct format, when i run into odd issues.
Click to expand...
Click to collapse
Under the edit menu, for EOL conversion, I chose UNIX format after I read an article somewhere. I think that's the right place?
For the update-binary, I used one from Glitch, CM9, and also another framework.zip but it seems to fail.
I agree, I'll try using somebody else's again
Edit: Well, apparently the command for unmount is umount! I still get the same status 4 error though. I got it to work eventually by copying somebody else's script, but I have no freaking clue how it was in any way different from mine.
Click sig links at the bottom of my sig and you will find a cwm flash pack creator.

Categories

Resources