| Write the build in babashka, and pin the babashka 34832a8 nandi 18d ago | 1 | #!/bin/sh |
| 2 | #_( |
| 3 | exec "$(dirname "$0")/bb" "$0" "$@" |
| 4 | ) |
| 5 | |
| 6 | ;; The app. The native libraries are wherever jolt-native is — a sibling |
| 7 | ;; checkout, or the clone `just lib` leaves under .jolt-native. |
| 8 | (require '[babashka.classpath :as cp]) |
| 9 | (cp/add-classpath (str (babashka.fs/parent *file*))) |
| 10 | (require '[frq.paths :as paths] |
| 11 | '[babashka.fs :as fs] |
| 12 | '[babashka.process :as p]) |
| 13 | |
| 14 | (def root (str (fs/canonicalize (fs/path (fs/parent *file*) "..")))) |
| 15 | |
| 16 | (System/exit |
| 17 | (:exit @(apply p/process |
| 18 | {:inherit true |
| 19 | :extra-env {"LD_LIBRARY_PATH" |
| 20 | (str (fs/path (paths/jolt-native root) "target" "release"))}} |
| 21 | "jolt" "-M:frq" *command-line-args*))) |