Merge "releasetools: Use int value of FIXED_FILE_TIMESTAMP."
This commit is contained in:
commit
71142ea2c9
|
@ -77,8 +77,9 @@ PARTITIONS_WITH_CARE_MAP = ('system', 'vendor', 'product', 'product_services',
|
||||||
'odm')
|
'odm')
|
||||||
# Use a fixed timestamp (01/01/2009 00:00:00 UTC) for files when packaging
|
# Use a fixed timestamp (01/01/2009 00:00:00 UTC) for files when packaging
|
||||||
# images. (b/24377993, b/80600931)
|
# images. (b/24377993, b/80600931)
|
||||||
FIXED_FILE_TIMESTAMP = (datetime.datetime(2009, 1, 1, 0, 0, 0, 0, None)
|
FIXED_FILE_TIMESTAMP = int((
|
||||||
- datetime.datetime.utcfromtimestamp(0)).total_seconds()
|
datetime.datetime(2009, 1, 1, 0, 0, 0, 0, None) -
|
||||||
|
datetime.datetime.utcfromtimestamp(0)).total_seconds())
|
||||||
|
|
||||||
|
|
||||||
class OutputFile(object):
|
class OutputFile(object):
|
||||||
|
@ -98,6 +99,7 @@ class OutputFile(object):
|
||||||
if self._output_zip:
|
if self._output_zip:
|
||||||
common.ZipWrite(self._output_zip, self.name, self._zip_name)
|
common.ZipWrite(self._output_zip, self.name, self._zip_name)
|
||||||
|
|
||||||
|
|
||||||
def GetCareMap(which, imgname):
|
def GetCareMap(which, imgname):
|
||||||
"""Returns the care_map string for the given partition.
|
"""Returns the care_map string for the given partition.
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue