Source: node-egjs-hammerjs Version: 2.0.17-1 Severity: wishlist Tags: patch User: [email protected] Usertags: timestamps X-Debbugs-Cc: [email protected]
Hi, Whilst working on the Reproducible Builds effort [0], we noticed that node-egjs-hammerjs could not be built reproducibly. Patch attached. [0] https://reproducible-builds.org/ Regards, -- ,''`. : :' : Chris Lamb `. `'` [email protected] / chris-lamb.co.uk `-
--- a/debian/patches/reproducible-build.patch 1969-12-31 16:00:00.000000000 -0800 --- b/debian/patches/reproducible-build.patch 2026-06-10 09:27:47.984382789 -0700 @@ -0,0 +1,17 @@ +Description: Make the build reproducible +Author: Chris Lamb <[email protected]> +Last-Update: 2026-06-10 + +--- node-egjs-hammerjs-2.0.17.orig/banner.js ++++ node-egjs-hammerjs-2.0.17/banner.js +@@ -1,7 +1,8 @@ + var pkg = require("./package.json"); +-var date = new Date(); ++var epoch = Number(process.env["SOURCE_DATE_EPOCH"]); ++var date = Number.isInteger(epoch) ? new Date(epoch * 1000) : new Date(); + +-module.exports = `/*! ${pkg.title || pkg.name} - v${pkg.version} - ${[ date.getFullYear(), ('0' + (date.getMonth() + 1)).slice(-2), ('0' + date.getDate()).slice(-2)].join('-')} ++module.exports = `/*! ${pkg.title || pkg.name} - v${pkg.version} - ${[ date.getUTCFullYear(), ('0' + (date.getUTCMonth() + 1)).slice(-2), ('0' + date.getUTCDate()).slice(-2)].join('-')} + * ${pkg.homepage} + * + * Forked By Naver egjs --- a/debian/patches/series 1969-12-31 16:00:00.000000000 -0800 --- b/debian/patches/series 2026-06-10 09:16:34.871252168 -0700 @@ -0,0 +1 @@ +reproducible-build.patch

