Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

release: Fix the creation of the opam-full-<version>.tar.gz archive #6066

Merged
merged 4 commits into from
Jul 3, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions master_changes.md
Original file line number Diff line number Diff line change
Expand Up @@ -79,6 +79,10 @@ users)
## Infrastructure

## Release scripts
* Add the missing mccs and dune archives to the opam-full-<version>.tar.gz archive [#6066 @kit-ty-kate]
* Ensure the configure file stays as it is in the tag, in the opam-full-<version>.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]
Expand Down
8 changes: 2 additions & 6 deletions release/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,8 @@ 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
cd "$(OUTDIR)" && tar cz -f $(notdir $@) --exclude .git/ 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)
rm -rf "$(OUTDIR)/opam-full-$(VERSION)"

build/Dockerfile.x86_64-linux: Dockerfile.in
Expand Down
4 changes: 2 additions & 2 deletions src_ext/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -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))
Expand All @@ -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
Expand Down
Loading