Hi,
I have the following project structure .
- My App -- common -- dune -- mylib.ml -- mylib.mli -- downloader -- dune -- main.ml -- decoder -- dune -- main.ml
How could i tell dune to use “common/mylib” from /downloader/main.ml and decoder/main.ml? Thanks.
Just add (libraries mylib) to the stanzas defining downloader and decoder.
(libraries mylib)
downloader
decoder
Cheers, Nicolas
In common/dune, what is the name you give the common library? If you define it as (name common), you’ll want to do (libraries common) in the other dune files, and then reference the Mylib module in your OCaml code as Common.Mylib.
common/dune
common
(name common)
(libraries common)
Common.Mylib