fix archive files being created with perms 000
In python 2.5 and earlier, ZipFile.writestr(filename, data) results in
the file being added to the archive with permissions 000. (See
http://svn.python.org/view?view=rev&revision=65235.) Work around this
by creating a ZipInfo object and setting the permissions explicitly.
diff --git a/tools/releasetools/img_from_target_files b/tools/releasetools/img_from_target_files
index 3451352..1d154b9 100755
--- a/tools/releasetools/img_from_target_files
+++ b/tools/releasetools/img_from_target_files
@@ -96,7 +96,7 @@
img.close()
common.CheckSize(data, "system.img")
- output_zip.writestr("system.img", data)
+ common.ZipWriteStr(output_zip, "system.img", data)
def CopyInfo(output_zip):