From 3fc5d821eba04059525c07b737ecc4ab5cf7d50d Mon Sep 17 00:00:00 2001 From: Peter Korsgaard Date: Tue, 12 Aug 2025 09:36:43 +0200 Subject: [PATCH] Makefile: release: make manual build reproducible The manual contains build timestamps like: Buildroot 2025.08-rc1 manual generated on 2025-08-12 06:43:37 UTC Making it not reproducible. Luckily asciidoc respects SOURCE_DATE_EPOCH, so use that to use the timestamp of the latest git commit instead. Notice: The release and manual targets are marked as noconfig targets (and need to stay like that for make release), so we cannot use the BR2_REPRODUCIBLE logic. Instead manually set SOURCE_DATE_EPOCH. Signed-off-by: Peter Korsgaard Signed-off-by: Julien Olivain --- Makefile | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 203d90510d..33e8563e93 100644 --- a/Makefile +++ b/Makefile @@ -1250,7 +1250,8 @@ release: OUT = buildroot-$(BR2_VERSION) # documentation to the git output release: git archive --format=tar --prefix=$(OUT)/ HEAD > $(OUT).tar - $(MAKE) O=$(OUT) manual-html manual-text manual-pdf + SOURCE_DATE_EPOCH=$$(git log -1 --format=%at 2> /dev/null) \ + $(MAKE) O=$(OUT) manual-html manual-text manual-pdf $(MAKE) O=$(OUT) distclean tar rf $(OUT).tar $(OUT) gzip -9 -c < $(OUT).tar > $(OUT).tar.gz