build: make the release driver and Debian changelogs dependable

- The container release driver wrote rv=fail but returned success to
  CI. Run every selected target, keep its report line, and exit
  nonzero if any target fails or its builder can't run. A missing
  podman during --cleanup is reported per target instead of aborting
  the run. Reject a target name that matches no containerfile.
- --branch silently defaulted to master, and the tarball containerfile
  did too, so a release could package a moving branch instead of the
  intended tag. Require --branch and --git-repo for direct calls.
- Remove the static installer target. Its makeself command printed
  "foo", and it copied whatever static archives the output directory
  held, possibly from an older release or missing one built later in
  the same run. The static archives themselves are unchanged.
- git2debcl enumerated every tag and used symmetric differences, so a
  private tag could become a package version and commits from another
  branch could be listed. Take release and release-candidate tags
  reachable from the requested revision, ordered by version with each
  final after its candidates, with one-sided ranges between ancestor
  boundaries. Keep the requested version when tags share a revision or
  a range is empty. A tagless snapshot gets 0~git.<count>.<hash>; a
  shallow tagless checkout must give --version.
- Debian versions for candidates are printed as 2.42.0~~rc1, so dpkg
  orders them below the 2.42.0 final. The raw -rc1 form sorted above
  it, making the final release look like a downgrade.
- TEST_release_metadata covers the driver's results and arguments,
  sibling and merged histories, non-release tags, candidates,
  tagless and shallow checkouts, and dpkg version ordering.
- Document the static and release targets and the driver's arguments.
This commit is contained in:
Antonio SJ Musumeci 2026-11-25 13:36:10 -05:00
parent 181371d84c
commit 036246140b
6 changed files with 548 additions and 68 deletions

View file

@ -72,6 +72,22 @@ Fedora 45 on `amd64` and `arm64`, and Ubuntu 26.10 on `amd64`, `arm64`,
`armhf`, and `riscv64`. Foreign-architecture builds require QEMU/binfmt
support.
Standalone static archives (`mergerfs-<version>-static-linux_<arch>.tar.gz`)
are built with `make release-static`, which selects every `static.<arch>`
containerfile: `amd64`, `arm64`, `armhf`, `i386`, and `riscv64`.
`make release-all` builds every containerfile in the directory. A target
name that matches no containerfile (exact or substring) makes
`buildtools/build-release` fail with `no package targets match '<name>'`;
there is no installer target.
For a release, pass the intended tag to the Makefile (`GITREF=<tag>`)
or call `buildtools/build-release` directly with both `--git-repo` (the
repository for the container to clone) and `--branch` (the intended
tag); the script fails when either is missing. The named ref must be
available in that repository. A failed target gives the driver a
nonzero exit status; `build-report.txt` in the output directory lists
each target's result.
## Generic Linux
Have git, g++ or clang, make, python installed.