#!/bin/sh # tested in a debian VM # packages installed by root: build-essential git opam xdot zstd # this script is run by an unprivileged user # this script uses a modified version of holtrace_restore to print each named theorem # warnings: # * even when a trace is correct, maybe it isn't proving what you expect # recommendations: # * audit the definitions and theorems printed in restore.out # * review https://github.com/hol-light-family/Poincare/blob/main/doc/REPORT.md set -e export HOLLIGHT_DIR=`pwd`/hol-light git clone https://github.com/jrh13/hol-light cd hol-light git checkout e5236a5839b4d08dc2536b325cea0af855e6c379 # 20261110 wget https://cr.yp.to/2026/20261119-holtrace-save-mini.ml sed -i '/nets.ml/ iloads "20261119-holtrace-save-mini.ml";;' hol_lib.ml opam init -a --disable-sandboxing make switch-5 eval `opam env` make HOLLIGHT_USE_MODULE=1 make wget https://cr.yp.to/2026/20261119-holtrace-restore-print.ml cat > restore.ml << 'EOF' needs "database.ml";; needs "20261119-holtrace-restore-print.ml";; holtrace_restore_allownew [] (try Sys.getenv "HOLTRACE_RESTORE" with Not_found -> "restore.50");; EOF ocaml inline_load.ml restore.ml restore_inlined.ml ocamlfind ocamlopt -package zarith -linkpkg -pp "`./hol.sh -pp`" -I . bignum.cmx hol_loader.cmx hol_lib.cmx restore_inlined.ml -o restore curl -O https://holtrace.cr.yp.to/poincare.50.zst unzstd poincare.50.zst env HOLTRACE_RESTORE=poincare.50 ./restore > restore.out 2>&1