Add a Janet-free gate so correctness can be judged with only Chez + Clojure: - host/chez/run-corpus.ss: corpus.edn vs JVM expecteds, lifting the per-case ns isolation from the old Janet driver; reads corpus.edn via the jolt reader. - host/chez/run-unit.ss + test/chez/unit.edn: the host-specific unit cases, evaluated in-process and compared to baked expecteds. - host/chez/selfcheck.sh: self-host fixpoint (bootstrap.ss rebuild == checked-in seed). - host/chez/smoke.sh: real bin/joltc CLI smoke. - host/chez/remint.sh: re-mint the seed to a byte-fixpoint after a source change. - Makefile: 'make test' runs the lot; 'make remint' rebuilds the seed. Numbers match the Janet gate: corpus 2679/2757 0 new div, unit 450/450, certify 0 new/0 stale. jolt-cf1q.6
18 lines
790 B
Bash
Executable file
18 lines
790 B
Bash
Executable file
#!/bin/sh
|
|
# self-host fixpoint gate: bootstrap.ss rebuilds the prelude + compiler image from
|
|
# source on pure Chez; the rebuild must equal the checked-in seed byte-for-byte. If
|
|
# it doesn't, a seed source changed without a re-mint — run `make remint`.
|
|
set -e
|
|
root="$(CDPATH= cd -- "$(dirname -- "$0")/../.." && pwd)"
|
|
cd "$root"
|
|
tmp="$(mktemp -d)"
|
|
trap 'rm -rf "$tmp"' EXIT
|
|
chez --script host/chez/bootstrap.ss \
|
|
host/chez/seed/prelude.ss host/chez/seed/image.ss "$tmp/p.ss" "$tmp/i.ss" >/dev/null
|
|
if diff -q host/chez/seed/prelude.ss "$tmp/p.ss" >/dev/null \
|
|
&& diff -q host/chez/seed/image.ss "$tmp/i.ss" >/dev/null; then
|
|
echo "self-host fixpoint: rebuild == checked-in seed"
|
|
else
|
|
echo "self-host FAILED: bootstrap rebuild != checked-in seed; run 'make remint'" >&2
|
|
exit 1
|
|
fi
|