Source: php-nesbot-carbon
Version: 3.10.3-3
Severity: wishlist
Tags: patch
User: [email protected]
Usertags: nocheck
X-Debbugs-Cc: [email protected]
Hi,
Whilst working on the Reproducible Builds effort [0], we noticed that
php-nesbot-carbon could not be built reproducibly.
This is because the testsuite bumps the modification time of the
src/Carbon/Lang directory to the current time (which later gets clamped
*back* to SOURCE_DATE_EPOCH), so if the tests are skipped via nocheck,
then this directory will retain its original, upstream timestamp.
Patch attached that ensures this directory always has the same
timestamp, regardless of whether the tests are run.
[0] https://reproducible-builds.org/
Regards,
--
,''`.
: :' : Chris Lamb
`. `'` [email protected] / chris-lamb.co.uk
`-
--- a/debian/rules 2026-10-08 10:14:01.330491395 -0700
--- b/debian/rules 2026-10-08 10:29:11.906670562 -0700
@@ -35,3 +35,8 @@
else
@echo 'The PHPUnit test suite requires a 64-bit system.' >&2
endif
+
+execute_before_dh_auto_install:
+ # If we ran the tests, we adjusted the mtimes of this dir, so force it
+ # to a fixed time for reproducibility
+ touch -d@$(SOURCE_DATE_EPOCH) src/Carbon/Lang