summaryrefslogtreecommitdiff
path: root/Makefile.am
diff options
context:
space:
mode:
Diffstat (limited to 'Makefile.am')
-rw-r--r--Makefile.am55
1 files changed, 13 insertions, 42 deletions
diff --git a/Makefile.am b/Makefile.am
index cca120baa1c..dabceddf2ac 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -1177,49 +1177,20 @@ prepare-release: dist-with-updated-version all
@echo "Now push the resulting commit and run `make release`."
@echo
+# Make sure you've ran prepare-release prior to running release and pushed
+# the commit to Guix. It might be pushed to any branch, such as version-X.Y.Z.
release: all
-# Generate the binary release tarballs.
- rm -f $(BINARY_TARBALLS)
- $(MAKE) $(BINARY_TARBALLS)
- for system in $(SUPPORTED_SYSTEMS) ; do \
- mv "guix-binary.$$system.tar.xz" \
- "$(releasedir)/guix-binary-$(PACKAGE_VERSION).$$system.tar.xz" ; \
- done
-# Build 'current-guix' to speed things up for the next step.
- $(top_builddir)/pre-inst-env guix build \
- -e '((@ (gnu packages package-management) current-guix))' \
- $(call system_flags,$(GUIX_SYSTEM_INSTALLER_SYSTEMS)) \
- -v1 --no-grafts --fallback
-# Generate the ISO installation images.
- for system in $(GUIX_SYSTEM_INSTALLER_SYSTEMS) ; do \
- GUIX_DISPLAYED_VERSION="`git describe --match=v* | sed -'es/^v//'`" ; \
- image=`$(top_builddir)/pre-inst-env \
- guix system image -t iso9660 \
- --label="GUIX_$${system}_$(VERSION)" \
- --system=$$system --fallback \
- gnu/system/install.scm` ; \
- if [ ! -f "$$image" ] ; then \
- echo "failed to produce Guix installation image for $$system" >&2 ; \
- exit 1 ; \
- fi ; \
- cp "$$image" "$(releasedir)/$(GUIX_SYSTEM_IMAGE_BASE).$$system.iso.tmp" ; \
- mv "$(releasedir)/$(GUIX_SYSTEM_IMAGE_BASE).$$system.iso.tmp" \
- "$(releasedir)/$(GUIX_SYSTEM_IMAGE_BASE).$$system.iso" ; \
- done
-# Generate the VM images.
- for system in $(GUIX_SYSTEM_VM_SYSTEMS) ; do \
- GUIX_DISPLAYED_VERSION="`git describe --match=v* | sed -'es/^v//'`" ; \
- image=`$(top_builddir)/pre-inst-env \
- guix system image -t qcow2 $(GUIX_SYSTEM_VM_IMAGE_FLAGS) \
- --save-provenance \
- --system=$$system --fallback \
- gnu/system/examples/vm-image.tmpl` ; \
- if [ ! -f "$$image" ] ; then \
- echo "failed to produce Guix VM image for $$system" >&2 ; \
- exit 1 ; \
- fi ; \
- cp "$$image" "$(releasedir)/$(GUIX_SYSTEM_VM_IMAGE_BASE).$$system.qcow2"; \
- done
+# Build the artifacts for current commit.
+# Use time-machine for provenance.
+ $(MKDIR_P) "$(releasedir)"
+ @echo "Building guix inferior for current commit."
+ COMMIT="$$(git rev-parse HEAD)" && \
+ GUIX="$$(guix time-machine --commit=$$COMMIT)/bin/guix" && \
+ echo "Building artifacts for current commit: $$COMMIT." && \
+ ARTIFACTS="$$($$GUIX build --no-grafts \
+ -f ./etc/teams/release/artifacts.scm)" && \
+ echo "Artifacts built! Copying to $(releasedir)" && \
+ cp -f "$$ARTIFACTS"/* "$(releasedir)"
@echo
@echo "Congratulations! All the release files are now in $(releasedir)."
@echo