ocamllex -------- ``(ocamllex )`` is essentially a shorthand for: .. code:: dune (rule (target .ml) (deps .mll) (action (chdir %{workspace_root} (run %{bin:ocamllex} -q -o %{target} %{deps})))) To use a different rule mode, use the long form: .. code:: dune (ocamllex (modules ) (mode ))