1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

make-snapshot: touch updated files after prepared

Align mtime of files updated by `make prepare-package` to make
packages reproducible.
This commit is contained in:
Nobuyoshi Nakada 2019-10-03 19:13:05 +09:00
parent 8142a9b43d
commit 8f7fca784a
No known key found for this signature in database
GPG key ID: 4BC7D6DF58D8DF60

View file

@ -483,6 +483,8 @@ touch-unicode-files:
FileUtils.cp_r(orig, dest)
end
File.utime(modified, modified, *Dir.glob(["tool/config.{guess,sub}", "gems/*.gem", "tool"]))
return unless make.run("prepare-package")
return unless make.run("clean-cache")
if modified
new_time = modified + 2
touch_all(new_time, "**/*", File::FNM_DOTMATCH) do |name, stat|
@ -490,8 +492,6 @@ touch-unicode-files:
end
modified = new_time
end
return unless make.run("prepare-package")
return unless make.run("clean-cache")
print "prerequisites"
else
system(*%W"#{YACC} -o parse.c parse.y")