build: image: use UTC for zip timestamp

Zip uses DOS timestamp for mtime which is stored in local time and hence
depends on the timezone of the build system. Force zip to use UTC timezone
to make image builds more reproducible.

Signed-off-by: Sungbo Eo <mans0n@gorani.run>
(cherry picked from commit e42764cc5f)
This commit is contained in:
Sungbo Eo 2022-02-12 17:01:31 +09:00 committed by Tianling Shen
parent 51c26f0c97
commit 5b5a34737c
No known key found for this signature in database
GPG Key ID: 6850B6345C862176

View File

@ -183,7 +183,7 @@ define Build/zip
mkdir $@.tmp
mv $@ $@.tmp/$(1)
zip -j -X \
TZ=UTC zip -j -X \
$@ $@.tmp/$(if $(1),$(1),$@)
rm -rf $@.tmp
endef