Wednesday, November 2, 2011

How To Make a Flashable ZIP Package (Update.zip)


Thanks to daktah@XDA for the tutorial..

before we start, grab ppcgeeks auto signer here, or nothing will flash anyway. its the easiest method since its drag, drop, and click.
also i recommend 7-zip but its not necessarily needed.

first step, make the folder structure.
ive included prebuilt updates to make it a little faster for you. they contain no actual files, just the appropriate folder structure and update script. they must be resigned if you add files and expect to flash them.

Update zip-Apps
Update zip-Notifications
Update zip-Ringtones
Update zip-Wallpaper

if what your looking for isnt included, make a folder and name it "workdir". this will contain your work.
this is just to make it easier to organize all your stuff. if you feel so inclined you can name it whatever you want, it doesnt really matter.
next youll need to make folders inside the workdir according to where your flashing stuff, ie if your flashing wallpapers youd need to make a structure that looks like this: "workdir/system/customize/resource"

next to make the update-script. this tells the system what to do.
first make this folder structure: "workdir/META-INF/com/google/android"
make sure you capitalize "META-INF"
now put a text file into the "android" folder and call it "update-script"
the easiest way to code it would be to copy this into it:

show_progress 0.1 0
copy_dir PACKAGE:(x) (X):
set_perm_recursive 0 0 0755 0644 (X):(y)
show_progress 0.1 10
replace the (x) with the directory in the root your flashing to in lowercase, ie system or data or sdcard.
replace the (X)'s with the same thing as (x) except in UPPERCASE such as SYSTEM or DATA or SDCARD.
replace the (y) with the next directory in lowercase like media or app or customize.
note: if your adding to the root of (X) folder then leave this blank, no spaces or anything.

if your flashing an app it should look something like this:


show_progress 0.1 0
copy_dir PACKAGE:system SYSTEM:
set_perm_recursive 0 0 0755 0644 SYSTEM:app
show_progress 0.1 10

after youve done that, save and close the file. now you need to take the extension off of the text file. simply delete the .txt at the end of the file.
if there is no extension showing, make sure you have "hide extensions for known file types" unchecked in tools> folder options> "view" tab.

second to last step! compress the workdir contents into a zip file, not the actual workdir though. it should look like this inside the zip: "update.zip/(folders)" not "update.zip/workdir/(folders)"

finally, sign the zip with the auto signer and put it into the root of the sd card.
boot into recovery and flash it up! with a bit of luck, it should work.

if you have any questions, problems, or concerns just post them.

0 comments:

Post a Comment

Twitter Delicious Facebook Digg Stumbleupon Favorites More