A generated buildscript.sh
can be found at tests/MlFront_Boot/basic.t/run.t · 78dc21aa605ff41bece36cca16e6ebd2b6b503dd · DkML / Build Tools / MlFront · GitLab. In fact, that is running inside Dune as a cram test so that shows a primitive integration with Dune.
Yes, Dune does a zillion things that MlFront_Boot
doesn’t, including parallelism (and C, out-of-date checks, Merlin, etc.). That is why for DkCoder I generate dune
and dune-project
files rather than POSIX/DOS scripts … and that still uses MlFront as a library. But change to existing tools requires convincing and time, so I can suggest that if someone is motivated they could add a MlFront_Toplevel
to generate a script file that can be run with ocaml scriptfile.ml
, and also embed something like moonpool into scriptfile.ml
to add parallelism. And if it isn’t clear to a motivated OCaml-er how to build that Edit: I need MlFront_Toplevel
build system, that is a signal I haven’t documented MlFront_Boot
enough.MlFront_Toplevel
for an unrelated reason, so I’ll build it myself.
Ultimately, I’d like to keep MlFront_Boot
capable of producing simple-to-audit POSIX/DOS scripts. I may even add comments and section breaks so it is more readable. So, no background jobs and no wait
commands in the scripts. A nice side-benefit of the “simple-to-audit” is that MlFront_Boot
should be ideal for a student learning OCaml after a semester of Java: they can focus on their source code (no configuration needed), and the ocamlc/ocamlopt
compiler is not hidden from them.