How to generate Menhir .automaton files with dune in OCaml?

23 Views Asked by At

I'm trying to generate .automaton files I added this to the dune file inside lib/ folder

(menhir
  (flags --explain --dump)
  (modules parser))

Then I run dune build, if I do find . -name '*.automaton', it finds no file, I was expecting the automaton file. What I'm missing?

I set up the project here: https://github.com/dhilst/pfpy, to reproduce

git clone https://github.com/dhilst/pfpy.git && cd pfpy
opam install --deps-only .
dune build

--- update ---

After running dune build --verbose I caught the menhir being executed: Running[23]: (cd _build/.sandbox/740f245a4e0ba91f52e6ab53118b4542/default && /home/me/.opam/4.14.1/bin/menhir --explain --inspection --table --dump lib/parser.mly --base lib/parser --infer-read-reply lib/parser__mock.mli.inferred)

The problem is that the .sandbox folder is empty after the build

$ ls -l _build/.sandbox 
total 0
0

There are 0 best solutions below