Atoms can now be constructed and pretty printed with a syntax = Jbuild | Dune.
The syntax controls validation that will be used to make sure we are printing
something/reading valid
Signed-off-by: Rudi Grinberg <rudi.grinberg@gmail.com>
In some cases, the linking step requires some dependencies. For example,
passing a version script to the linker. The new `(link_deps)` field
uses the dependency DSL already used in other places.
Closes#852
Signed-off-by: Etienne Millon <etienne@cryptosense.com>
Things like \a are no longer allowed. Before they would be interpreted
as a literal \a. This will allow to introduce new escape sequences in
the future if needed.
Signed-off-by: Jeremie Dimino <jeremie@dimino.org>
If an executable is only available as a shared object for example,
Dune cannot install it. In that case, it displays an error message.
However, it is still possible to build a private one explicitly.
Signed-off-by: Etienne Millon <etienne@cryptosense.com>
When the root is not the cwd, print a relative path for the "Entering
..." line rather than an absolute one.
Signed-off-by: Jeremie Dimino <jdimino@janestreet.com>
- remove hard-coded knowledge of ocaml-migrate-parsetree and ppx_driver
- get the exact driver parameters directly from the driver itself
Signed-off-by: Jeremie Dimino <jdimino@janestreet.com>
They are almost never used and they complicate the language. The
parsing of jbuild files in unchanged.
Signed-off-by: Jeremie Dimino <jdimino@janestreet.com>
The motivation for this change is implement the --build-dir feature. This
feature lets us control the build directory which previously always defaulted to
_build. To accomplish this, Path.t had to be modified to be:
External of External.t | In_source_tree of Local.t | In_build_dir of Local.t
To represent the 3 kinds of paths dune is dealing with. The In_build_dir
constructor in particular, is relative to Path.root or some external path.
A few other refactorings had to be done to support this transition:
* The workspace is now "settable". This means that we no longer have to pass it
explicitly when converting local to absolute paths.
* Path.is_local no longer makes sense and is renamed to Path.is_managed.
Roughly, is_managed identifies paths in the build and source directories.
* Path.absoulte has been renamed of_filename_relative_to_initial_cwd
* Path.Local.root is now "." (as opposed to "")
Signed-off-by: Rudi Grinberg <rudi.grinberg@gmail.com>
Replace the current generated parser by an ocamllex lexer + a simple
parser.
The new code is:
- much simpler and smaller
- shouldn't cause ocamlopt to stack overflow anymore on BSD systems
- slightly slower but not that much
Signed-off-by: Jeremie Dimino <jdimino@janestreet.com>