On 4/28/07, Joel Reymont <joelr1@gmail.com> wrote:
> This is what I came up with:
>
> flag ["ocaml"; "parser"; "mehir" ] (A"--explain");
> flag ["ocaml"; "menhir_ocamldep" ] (A"easy_tokens.mly");
> flag ["ocaml"; "menhir_ocamldep" ] (A"--base");
> flag ["ocaml"; "menhir_ocamldep" ] (A"easy_parser");
>
> Can the 3 different (A"..")s be combined?
flag ["ocaml"; "menhir_ocamldep" ] (S[A"easy_tokens.mly"; A"--base";
A"easy_parser"]);
> This works but ocamlbuild doesn't know anything about easy_tokens and
> doesn't copy it to _build which results in a "file not found" error.
>
> Is there a way to say that this token file should always go on the
> command line with this mly file? Hardcoding like above only works if
> there's one parser in the project.
>
> I tried the following off of the top of my head but it doesn't work.
>
> dep ["ocaml"; "parser"; "menhir"; "tokens"] ["easy_tokens.mly"];
>
> in _tags
>
> "easy_parser.mly": tokens
Hum this is supposed to works.
Can you try these one
dep ["ocaml"; "parser"; "menhir"] ["easy_tokens.mly"];
dep ["ocaml"; "parser"; "menhir"; "file:easy_parser.mly"] ["easy_tokens.mly"];
--
Nicolas Pouillard