Commit Graph
4 Commits
Author SHA1 Message Date
lotherk 5982a0ddde build: lock cdtest and the native MCDE builds; tools refuse outside the lock
- cdtest takes one lock around release, iso and the VM test; the nested
  make calls reuse it through BUILD_LOCK_HELD (re-entrant).  MAKE_CMD keeps
  make -n cdtest from executing the recipe: GNU make runs a recipe with
  $(MAKE) even under -n, and the rest of the line starts a VM.
- mcde-linux and mcde-host take the lock too; they read ext/src/mcde and
  the distfiles a release reads.
- build-lock.sh: --held for the tools, --check for read-only callers, pid
  plus process start time for stale locks, the child is killed on INT/TERM,
  and nested calls reuse the outer lock.
- build-stamp, cd2, cd3, cd-source, images, srctree-stage, userland,
  mcde-linux and mcde-host refuse to run outside the lock (the file and the
  message name the way in: make or tools/build-lock.sh).
2026-11-16 12:10:23 +00:00
lotherk 6d0c92ae38 signify: sign the release automatically, verify it before an upgrade
- make sourcesets signs RELEASEDIR/source/sets/SHA512 inside the build lock
  when SIGNIFY_SECKEY is set (tools/sign-release.sh auto); a build without
  the key says so and stays unsigned.
- make iso signs the package summary first; tools/cd3.sh puts
  pkg_summary.gz.sig next to the summary on the DVD and on every package CD.
- tools/cd-source.sh carries SHA512.sig on the source DVD and the README
  names the two verification commands.
- tools/upgrade-verify.sh: verifies root key -> release key -> SHA512 and
  then the SHA512 of the set files; the upgrade command (tasksd t0055) calls
  it before sysupgrade/pkg_add run as root.

Measured 2026-11-16: the source SHA512 signed with the release key verifies
through the chain ("signed by the root key", "good signature"), the copy
extracted from the source DVD too, the package summary verifies, and
upgrade-verify checks src.tgz (5.8 GB) against SHA512.  `make iso` itself
was not run to the end: a commit in another session changed src/ during the
release, so build-stamp refused the packaging
(build/logs/release-iso-2026-11-16-signed.log).
2026-11-16 10:38:59 +00:00
lotherk 5fc42ec1ac source DVD: 5.8 GB in parts, the installer cats them
The source set is 5.8 GB; one ISO 9660 file can hold 4 GB (the size field
is 32 bits) and makefs truncated src.tgz to 1.5 GB (measured 2026-11-15:
the installer's gzip stopped with "unexpected end of file").  UDF would
hold the single file, but NetBSD rejected the makefs image with EINVAL
(measured 2026-11-16 on a dvdrom image and on a small test image).

- tools/cd-source.sh splits src.tgz into 2 GiB parts (src.tgz.aa, .ab,
  ...) and writes ISO 9660 with Rock Ridge; the README gives the
  `cat ... | tar` command.
- sysinst: set_file_exists_p() accepts the first part, and the source set
  is extracted with `sh -c 'cat .../src.tgz.* | tar --chroot -xzpf -'`.
  run_program() splits its command into argv and has no shell: without
  `sh -c`, cat wrote the parts to the terminal and tar never ran (measured
  2026-11-16, build/logs/install-simple-source-2026-11-16f.log).
- tools/install-simple.sh: the -S test swaps in the source DVD for the
  source prompt and back to the install DVD for the makronix set that
  follows it; DVDISO/CDSRC can name copies outside RELEASEDIR, because a
  release in another session removes images (measured 2026-11-15).

Measured (build/logs/install-simple-source-2026-11-16h.log): the full
profile asked for the source DVD, the parts were extracted, the installed
system passes "/usr/src holds the tree", "/usr/src has PINS and pkgsrc",
"all 1569 Makronix distfiles are in /usr/src/distfiles", and PINS names the
base.  The run exits 1 on dbus and cupsd not enabled/running, unrelated to
the source set.
2026-11-16 03:09:27 +00:00
lotherk 76b17bef76 source DVD: its own medium
The sources are one set (src.tgz, 5.5 GB) and they get their own data DVD
instead of riding on the install DVD: `make isosrc' now runs
tools/cd-source.sh, which writes
RELEASEDIR/images/Makronix-<version>-amd64-source.iso with
source/sets/src.tgz, MD5, SHA512 and a README that names the commands
(ISO 9660 with Rock Ridge, the same nbmakefs the other media use).

The install DVD and the CDs carry no sources.  The installer side --
selecting the source set for the full profile and asking for this disc when
it is not in the drive (MSG_nextcd_source, cd_has_sets accepts
source/sets) -- is in the working tree with the sysinst profile work
(tasksd t0260) and not in this commit.

Measured: make isosrc -> Makronix-0.99.10-amd64-source.iso, 5.5 GB, 3m49s;
the image lists README, source/sets/src.tgz, MD5, SHA512
(build/logs/isosrc-2026-11-15b.log).  docs/OFFLINE-BUILD.md has the size and
the DVD class (dual layer).
2026-11-15 22:36:39 +00:00