Changes in tools/mkarray.py [94c05b89:bc6cdc4] in mainline
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
tools/mkarray.py
r94c05b89 rbc6cdc4 70 70 section = sys.argv[4] 71 71 72 timestamp = (1980, 1, 1, 0, 0, 0) 73 72 74 header_ctx = [] 73 75 desc_ctx = [] … … 79 81 archive = zipfile.ZipFile("%s.zip" % dest, "w", zipfile.ZIP_STORED) 80 82 81 for src in s ys.argv[5:]:83 for src in sorted(sys.argv[5:]): 82 84 basename = os.path.basename(src) 83 85 plainname = os.path.splitext(basename)[0] … … 95 97 src_data = deflate(src_data) 96 98 src_fname = os.path.basename("%s.deflate" % src) 97 archive.writestr(src_fname, src_data) 99 zipinfo = zipfile.ZipInfo(src_fname, timestamp) 100 archive.writestr(zipinfo, src_data) 98 101 else: 99 102 src_fname = src … … 155 158 data += "\n\n" 156 159 data += "#endif\n" 157 archive.writestr("%s.h" % dest, data) 160 zipinfo = zipfile.ZipInfo("%s.h" % dest, timestamp) 161 archive.writestr(zipinfo, data) 158 162 159 163 data = '' … … 166 170 data += "\n".join(data_ctx) 167 171 data += "\n" 168 archive.writestr("%s.s" % dest, data) 172 zipinfo = zipfile.ZipInfo("%s.s" % dest, timestamp) 173 archive.writestr(zipinfo, data) 169 174 170 175 data = '' … … 180 185 data += "\n".join(size_ctx) 181 186 data += "\n" 182 archive.writestr("%s_desc.c" % dest, data) 187 zipinfo = zipfile.ZipInfo("%s_desc.c" % dest, timestamp) 188 archive.writestr(zipinfo, data) 183 189 184 190 archive.close()
Note:
See TracChangeset
for help on using the changeset viewer.