interplane-forge
INTERPLANE Forge
Brought by drakestapleton
interplane-forge / research / build-tools.sh
| 1 | #!/bin/sh |
| 2 | # Compile the offline metadata and queue filters. No network, no installed files. |
| 3 | set -eu |
| 4 | cd "$(dirname "$0")/.." |
| 5 | OMV=${OMV:-$HOME/work/flux/omega-mv} |
| 6 | OMC=${OMC:-$OMV/seed/out/omc} |
| 7 | PIN=3ad9f10f64309e7acf8a725082b28e23a2a4aeb07e98322fb4dc0fcd8fc93194 |
| 8 | [ "$(sha256sum "$OMC" | cut -d ' ' -f1)" = "$PIN" ] || { echo 'research tools: compiler is not the pin' >&2; exit 2; } |
| 9 | [ "$(sha256sum "$OMV/om/tls/sha2.om" | cut -d ' ' -f1)" = 5cf0f98116def6917d3a373f2bd4c3932d46e3ff84d9567bbae9e720366fdb33 ] || { echo 'research tools: sha2 differs' >&2; exit 2; } |
| 10 | OUT=${1:?give an output folder} |
| 11 | mkdir -p "$OUT" |
| 12 | { echo om2; cat "$OMV/om/tls/sha2.om" research/sync.om; } | "$OMC" > "$OUT/research-sync" |
| 13 | "$OMC" < research/lib/jflat.om > "$OUT/research-jflat" |
| 14 | chmod 700 "$OUT/research-sync" "$OUT/research-jflat" |