From 334af50107f0a91cb1713623208872a5ba73833e Mon Sep 17 00:00:00 2001 From: Kate Date: Tue, 2 Jul 2024 19:19:51 +0100 Subject: [PATCH 1/4] release: Fix the creation of the opam-full-.tar.gz archive (mccs was missing) --- master_changes.md | 2 ++ release/Makefile | 6 +----- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/master_changes.md b/master_changes.md index 64a9c92b24c..57d027a1bda 100644 --- a/master_changes.md +++ b/master_changes.md @@ -79,6 +79,8 @@ users) ## Infrastructure ## Release scripts + * Add the missing mccs archive to the opam-full-.tar.gz archive [#6066 @kit-ty-kate] + * Ensure the configure file stays as it is in the tag, in the opam-full-.tar.gz archive [#6066 @kit-ty-kate] ## Install script * Provide a shell/install.ps1 PowerShell script to install opam on Windows [#5906 @kit-ty-kate @dra27] diff --git a/release/Makefile b/release/Makefile index e55d57e48d5..dc18a76a451 100644 --- a/release/Makefile +++ b/release/Makefile @@ -26,11 +26,7 @@ s390x-linux: $(OUTDIR)/opam-$(VERSION)-s390x-linux $(OUTDIR)/opam-full-$(VERSION).tar.gz: mkdir -p "$(OUTDIR)" git clone $(GIT_URL) -b $(TAG) "$(OUTDIR)/opam-full-$(VERSION)" - sed 's/^AC_INIT(\[opam\],\[.*\])/AC_INIT([opam],[$(OPAM_VERSION)])/' "$(OUTDIR)/opam-full-$(VERSION)/configure.ac" > \ - "$(OUTDIR)/opam-full-$(VERSION)/configure.ac.tmp" - mv "$(OUTDIR)/opam-full-$(VERSION)/configure.ac.tmp" \ - "$(OUTDIR)/opam-full-$(VERSION)/configure.ac" - $(MAKE) -C "$(OUTDIR)/opam-full-$(VERSION)" OCAML=$(call pathsearch,ocaml) configure download-ext + $(MAKE) -C "$(OUTDIR)/opam-full-$(VERSION)" OCAML=$(call pathsearch,ocaml) MCCS_ENABLED=true download-ext cd "$(OUTDIR)" && tar cz -f $(notdir $@) --exclude .git/ opam-full-$(VERSION) rm -rf "$(OUTDIR)/opam-full-$(VERSION)" From f85b051424c32ac674b3b443b773c21023937091 Mon Sep 17 00:00:00 2001 From: Kate Date: Wed, 3 Jul 2024 13:22:41 +0100 Subject: [PATCH 2/4] Add the missing dune tarball --- master_changes.md | 2 +- release/Makefile | 2 +- src_ext/Makefile | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/master_changes.md b/master_changes.md index 57d027a1bda..7fe8eff30ad 100644 --- a/master_changes.md +++ b/master_changes.md @@ -79,7 +79,7 @@ users) ## Infrastructure ## Release scripts - * Add the missing mccs archive to the opam-full-.tar.gz archive [#6066 @kit-ty-kate] + * Add the missing mccs and dune archives to the opam-full-.tar.gz archive [#6066 @kit-ty-kate] * Ensure the configure file stays as it is in the tag, in the opam-full-.tar.gz archive [#6066 @kit-ty-kate] ## Install script diff --git a/release/Makefile b/release/Makefile index dc18a76a451..7bd664e1bb7 100644 --- a/release/Makefile +++ b/release/Makefile @@ -26,7 +26,7 @@ s390x-linux: $(OUTDIR)/opam-$(VERSION)-s390x-linux $(OUTDIR)/opam-full-$(VERSION).tar.gz: mkdir -p "$(OUTDIR)" git clone $(GIT_URL) -b $(TAG) "$(OUTDIR)/opam-full-$(VERSION)" - $(MAKE) -C "$(OUTDIR)/opam-full-$(VERSION)" OCAML=$(call pathsearch,ocaml) MCCS_ENABLED=true download-ext + $(MAKE) -C "$(OUTDIR)/opam-full-$(VERSION)" OCAML=$(call pathsearch,ocaml) download-ext cd "$(OUTDIR)" && tar cz -f $(notdir $@) --exclude .git/ opam-full-$(VERSION) rm -rf "$(OUTDIR)/opam-full-$(VERSION)" diff --git a/src_ext/Makefile b/src_ext/Makefile index f652c0352c3..637f4946a7d 100644 --- a/src_ext/Makefile +++ b/src_ext/Makefile @@ -95,7 +95,7 @@ clone: $(DUNE_CLONE) $(SRC_EXTS:=.stamp) | ext-ignore archives: $(DUNE_CLONE:.stamp=.download) $(SRC_EXTS:=.download) @true -cache-archives: $(SRC_EXTS:=.cache) ocaml.cache flexdll.cache +cache-archives: $(SRC_EXTS:=.cache) mccs.cache dune-local.cache ocaml.cache flexdll.cache @ has-archives: $(addprefix archives/, $(notdir $(URL_ocaml)) $(notdir $(URL_flexdll)) $(ARCHIVES)) From d2f7c80d23aa48b8fae9369df798cde32ddaee9a Mon Sep 17 00:00:00 2001 From: Kate Date: Wed, 3 Jul 2024 13:49:05 +0100 Subject: [PATCH 3/4] Exclude the .git directory from the release archive when using GNU tar --- master_changes.md | 1 + release/Makefile | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/master_changes.md b/master_changes.md index 7fe8eff30ad..b40c0081269 100644 --- a/master_changes.md +++ b/master_changes.md @@ -81,6 +81,7 @@ users) ## Release scripts * Add the missing mccs and dune archives to the opam-full-.tar.gz archive [#6066 @kit-ty-kate] * Ensure the configure file stays as it is in the tag, in the opam-full-.tar.gz archive [#6066 @kit-ty-kate] + * Exclude the .git directory from the release archive when using GNU tar [#6066 @kit-ty-kate] ## Install script * Provide a shell/install.ps1 PowerShell script to install opam on Windows [#5906 @kit-ty-kate @dra27] diff --git a/release/Makefile b/release/Makefile index 7bd664e1bb7..cad1160861c 100644 --- a/release/Makefile +++ b/release/Makefile @@ -27,7 +27,7 @@ $(OUTDIR)/opam-full-$(VERSION).tar.gz: mkdir -p "$(OUTDIR)" git clone $(GIT_URL) -b $(TAG) "$(OUTDIR)/opam-full-$(VERSION)" $(MAKE) -C "$(OUTDIR)/opam-full-$(VERSION)" OCAML=$(call pathsearch,ocaml) download-ext - cd "$(OUTDIR)" && tar cz -f $(notdir $@) --exclude .git/ opam-full-$(VERSION) + cd "$(OUTDIR)" && tar cz -f $(notdir $@) --exclude .git opam-full-$(VERSION) rm -rf "$(OUTDIR)/opam-full-$(VERSION)" build/Dockerfile.x86_64-linux: Dockerfile.in From 22d94578951043d6b9752d24f8a90432494f00fc Mon Sep 17 00:00:00 2001 From: Kate Date: Wed, 3 Jul 2024 13:55:58 +0100 Subject: [PATCH 4/4] Ensure non-existing %.cache target fail with a fatal error --- master_changes.md | 1 + src_ext/Makefile | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/master_changes.md b/master_changes.md index b40c0081269..b47573903f1 100644 --- a/master_changes.md +++ b/master_changes.md @@ -82,6 +82,7 @@ users) * Add the missing mccs and dune archives to the opam-full-.tar.gz archive [#6066 @kit-ty-kate] * Ensure the configure file stays as it is in the tag, in the opam-full-.tar.gz archive [#6066 @kit-ty-kate] * Exclude the .git directory from the release archive when using GNU tar [#6066 @kit-ty-kate] + * Ensure non-existing %.cache target fail with a fatal error [#6066 @kit-ty-kate] ## Install script * Provide a shell/install.ps1 PowerShell script to install opam on Windows [#5906 @kit-ty-kate @dra27] diff --git a/src_ext/Makefile b/src_ext/Makefile index 637f4946a7d..0238d81e416 100644 --- a/src_ext/Makefile +++ b/src_ext/Makefile @@ -114,7 +114,7 @@ GET_ARCHIVE=\ %.cache: @mkdir -p archives - @test -e archives/$(notdir $(URL_$*)) || \ + @test -f archives/$(notdir $(URL_$*)) || \ { $(call GET_ARCHIVE,$*) && mv $(call ARCHIVE_FILE,$*) archives/$(notdir $(URL_$*)); } .PRECIOUS: %.download