aboutsummaryrefslogtreecommitdiff
path: root/Makefile.am
diff options
context:
space:
mode:
Diffstat (limited to 'Makefile.am')
-rw-r--r--Makefile.am57
1 files changed, 51 insertions, 6 deletions
diff --git a/Makefile.am b/Makefile.am
index cef972880c..25b3eb3378 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -7,7 +7,7 @@
# Copyright © 2017 Mathieu Othacehe <m.othacehe@gmail.com>
# Copyright © 2017 Leo Famulari <leo@famulari.name>
# Copyright © 2017 Ricardo Wurmus <rekado@elephly.net>
-# Copyright © 2017, 2020, 2023 Janneke Nieuwenhuizen <janneke@gnu.org>
+# Copyright © 2017, 2020, 2023, 2024 Janneke Nieuwenhuizen <janneke@gnu.org>
# Copyright © 2017 Arun Isaac <arunisaac@systemreboot.net>
# Copyright © 2018 Nikita <nikita@n0.is>
# Copyright © 2018 Julien Lepiller <julien@lepiller.eu>
@@ -144,6 +144,7 @@ MODULES = \
guix/platforms/powerpc.scm \
guix/platforms/riscv.scm \
guix/platforms/x86.scm \
+ guix/platforms/xtensa.scm \
guix/build-system.scm \
guix/build-system/agda.scm \
guix/build-system/android-ndk.scm \
@@ -422,9 +423,14 @@ dist_noinst_DATA = \
# Auxiliary files for packages.
AUX_FILES = \
gnu/packages/aux-files/chromium/master-preferences.json \
+ gnu/packages/aux-files/emacs/comp-integrity.el \
gnu/packages/aux-files/emacs/guix-emacs.el \
gnu/packages/aux-files/findclass.php \
gnu/packages/aux-files/guix.vim \
+ gnu/packages/aux-files/linux-libre/6.8-arm.conf \
+ gnu/packages/aux-files/linux-libre/6.8-arm64.conf \
+ gnu/packages/aux-files/linux-libre/6.8-i686.conf \
+ gnu/packages/aux-files/linux-libre/6.8-x86_64.conf \
gnu/packages/aux-files/linux-libre/6.7-arm.conf \
gnu/packages/aux-files/linux-libre/6.7-arm64.conf \
gnu/packages/aux-files/linux-libre/6.7-i686.conf \
@@ -949,9 +955,31 @@ guix-binary.%.tar.xz:
cp "$$tarball" "$@.tmp" ; mv "$@.tmp" "$@"
-# The dependency on doc-pot-update is to generate the .pot files, which are
-# not checked in.
-dist: doc-pot-update
+# Assert that Autotools cache is up to date with Git, by checking
+# PACKAGE_VERSION against HEAD. Indented to get past Automake.
+ ifeq ($(MAKECMDGOALS),dist)
+ git_version = $(shell build-aux/git-version-gen .tarball-version)
+ ifneq ($(PACKAGE_VERSION),$(git_version))
+ $(warning Autotools cache out of date.)
+ $(info Autotools cache version: $(PACKAGE_VERSION).)
+ $(info Git version: $(git_version).)
+ $(info Please run ./bootstrap && ./configure $(DIST_CONFIGURE_FLAGS))
+ ifneq ($(GUIX_ALLOW_IRREPRODUCIBLE_TARBALL),yes)
+ $(error Cannot create reproducible tarball)
+ else
+ $(warning Tarball will be irreproducible; distdir will not get removed!)
+ endif
+ endif
+ endif
+
+# The dependency on dist-doc-pot-update is to clean possibly stale doc and po
+# files and only then generate the .pot files, which are not checked in.
+dist: dist-doc-pot-update
+dist-doc-pot-update: auto-clean
+ $(MAKE) guile$(EXEEXT)
+ $(MAKE) -C po/guix all
+ $(MAKE) -C po/packages all
+ $(MAKE) doc-pot-update
dist-hook: gen-ChangeLog gen-AUTHORS gen-tarball-version
dist-hook: assert-no-store-file-names
@@ -965,9 +993,12 @@ $(top_srcdir)/.version: config.status
gen-tarball-version:
echo $(VERSION) > "$(distdir)/.tarball-version"
+ git show HEAD --format=%ct --no-patch > $(distdir)/.tarball-timestamp
gen-ChangeLog:
- $(AM_V_GEN)if test -d .git; then \
+ $(AM_V_GEN)if test -e .git; then \
+ export LC_ALL=en_US.UTF-8; \
+ export TZ=UTC0; \
$(top_srcdir)/build-aux/gitlog-to-changelog \
> $(distdir)/ChangeLog.tmp; \
rm -f $(distdir)/ChangeLog; \
@@ -975,8 +1006,10 @@ gen-ChangeLog:
fi
gen-AUTHORS:
- $(AM_V_GEN)if test -d .git; then \
+ $(AM_V_GEN)if test -e .git; then \
rm -f "$(distdir)/AUTHORS"; \
+ export LC_ALL=en_US.UTF-8; \
+ export TZ=UTC0; \
$(top_builddir)/pre-inst-env "$(GUILE)" \
"$(top_srcdir)/build-aux/generate-authors.scm" \
"$(top_srcdir)" "$(distdir)/AUTHORS"; \
@@ -997,6 +1030,18 @@ dist-with-updated-version:
# Release management.
#
+# Reproducible tarball
+override GZIP_ENV = --best --no-name
+# Be friendly to Debian; avoid using EPOCH
+override am__tar = $${TAR-tar} \
+ --format=ustar \
+ --sort=name \
+ --mode=go=rX,u+rw,a-s \
+ --mtime=@$$(cat "$$tardir"/.tarball-timestamp) \
+ --owner=0 --group=0 --numeric-owner \
+ -cf - \
+ "$$tardir"
+
releasedir = release-$(PACKAGE_VERSION)
PACKAGE_FULL_TARNAME = $(PACKAGE_TARNAME)-$(PACKAGE_VERSION)