Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[new release] dune (1.10.0) #14215

Closed
wants to merge 1 commit into from

Conversation

rgrinberg
Copy link
Member

Fast, portable and opinionated build system

CHANGES:

CHANGES:

- Restricted the set of variables available for expansion in the destination
  filename of `install` stanza to simplify implementation and avoid dependency
  cycles. (ocaml/dune#2073, @aalekseyev, @diml)

- [menhir] call menhir from context root build_dir (ocaml/dune#2067, @ejgallego,
  review by @diml, @rgrinberg)

- [coq] Add `coq.pp` stanza to help with pre-processing of grammar
  files (ocaml/dune#2054, @ejgallego, review by @rgrinberg)

- Add a new more generic form for the *promote* mode: `(promote
  (until-clean) (into <dir>))` (ocaml/dune#2068, @diml)

- Allow to promote only a subset of the targets via `(promote (only
  <pred>))`. For instance: `(promote (only *.mli))` (ocaml/dune#2068, @diml)

- Improve the behavior when a strict subset of the targets of a rule is already
  in the source tree for projects using the dune language < 1.10 (ocaml/dune#2068, fixes
  ocaml/dune#2061, @diml)

- With lang dune >= 1.10, rules in standard mode are no longer allowed to
  produce targets that are present in the source tree. This has been a warning
  for long enough (ocaml/dune#2068, @diml)

- Allow %{...} variables in pps flags (ocaml/dune#2076, @mlasson review by @diml and
  @aalekseyev).

- Add a 'cookies' option to ppx_rewriter/deriver flags in library stanzas. This
  allow to specify cookie requests from variables expanded at each invocation of
  the preprocessor. (ocaml/dune#2106, @mlasson @diml)

- Add more opam metadata and use it to generate `.opam` files. In particular, a
  `package` field has been added to specify package specific information.
  (ocaml/dune#2017, ocaml/dune#2091, @avsm, @jonludlam, @rgrinberg)

- Clean up the special support for `findlib.dynload`. Before, Dune would simply
  match on the library name. Now, we only match on the findlib package name when
  the library doesn't come from Dune. Someone writing a library called
  `findlib.dynload` with Dune would have to add `(special_builtin_support
  findlib_dynload)` to trigger the special behavior. (ocaml/dune#2115, @diml)

- Install the `future_syntax` preprocessor as `ocaml-syntax-shims.exe` (ocaml/dune#2125,
  @rgrinberg)

- Hide full command on errors and warnings in development and show them in CI.
  (detected using the `CI` environment variable). Commands for which the
  invocation might be omitted must output an error prefixed with `File `. Add an
  `--always-show-command-line` option to disable this behavior and always show
  the full command. (ocaml/dune#2120, fixes ocaml/dune#1733, @rgrinberg)

- In `dune-workspace` files, add the ability to choose the host context and to
  create duplicates of the default context with different settings. (ocaml/dune#2098,
  @TheLortex, review by @diml, @rgrinberg and @aalekseyev)

- Add support for hg in `dune subst` (ocaml/dune#2135, @diml)

- Don't build documentation for implementations of virtual libraries (ocaml/dune#2141,
  fixes ocaml/dune#2138, @jonludlam)

- Fix generation of the `-pp` flag in .merlin (ocaml/dune#2142, @rgrinberg)

- Make `dune subst` add a `(version ...)` field to the `dune-project`
  file (ocaml/dune#2148, @diml)

- Add the `%{os_type}` variable, which is a short-hand for
  `%{ocaml-config:os_type}` (ocaml/dune#1764, @diml)

- Allow `enabled_if` fields in `library` stanzas, restricted to the
  `%{os_type}`, `%{model}`, `%{architecture}`, `%{system}` variables (ocaml/dune#1764,
  ocaml/dune#2164 @diml, @rgrinberg)

- Fix `chdir` on external and source paths. Dune will also fail gracefully if
  the external or source path does not exist (ocaml/dune#2165, fixes ocaml/dune#2158, @rgrinberg)

- Support the `.cc` extension fro C++ sources (ocaml/dune#2195, fixes ocaml/dune#83, @rgrinberg)

- Run `ocamlformat` relative to the context root. This improves the locations of
  errors. (ocaml/dune#2196, fixes ocaml/dune#1370, @rgrinberg)

- Fix detection of `README`, `LICENSE`, `CHANGE`, and `HISTORY` files. These
  would be undetected whenever the project was nested in another workspace.
  (ocaml/dune#2194, @rgrinberg)

- Fix generation of `.merlin` whenever there's more than one stanza with the
  same ppx preprocessing specification (ocaml/dune#2209 ,fixes ocaml/dune#2206, @rgrinberg)

- Fix generation of `.meriln` in the presence of the `copy_files` stanza and
  preprocessing specifications of other stanazs. (ocaml/dune#2211, fixes ocaml/dune#2206,
  @rgrinberg)
@camelus
Copy link
Contributor

camelus commented May 30, 2019

☀️ All lint checks passed 31f7a06
  • These packages passed lint tests: dune.1.10.0

☀️ Installability check (11261 → 11262)
  • new installable packages (1): dune.1.10.0

@rgrinberg
Copy link
Member Author

I've looked over the failures and they can be explained by:

  • The usual failing suspects.
  • Packages with missing dependencies. Some of those are opam deps which means that that metadata is faulty. Others are missing external deps, those need depext fields likely.

@kit-ty-kate
Copy link
Member

Is this a related failure? I don't see it using dune 1.9.1

#=== ERROR while installing checkseum.0.0.3 ===================================#
Some files in /home/opam/.opam/4.07/.opam-switch/install/checkseum.install couldn't be installed:
  - /home/opam/.opam/4.07/.opam-switch/build/checkseum.0.0.3/_build/install/default/lib/checkseum/ocaml/gin_crc32c.ml to /home/opam/.opam/4.07/lib/checkseum
  - /home/opam/.opam/4.07/.opam-switch/build/checkseum.0.0.3/_build/install/default/lib/checkseum/ocaml/gin_crc32c.cmx to /home/opam/.opam/4.07/lib/checkseum
  - /home/opam/.opam/4.07/.opam-switch/build/checkseum.0.0.3/_build/install/default/lib/checkseum/ocaml/gin_crc32c.cmt to /home/opam/.opam/4.07/lib/checkseum
  - /home/opam/.opam/4.07/.opam-switch/build/checkseum.0.0.3/_build/install/default/lib/checkseum/ocaml/gin_crc32c.cmi to /home/opam/.opam/4.07/lib/checkseum
  - /home/opam/.opam/4.07/.opam-switch/build/checkseum.0.0.3/_build/install/default/lib/checkseum/ocaml/gin_crc32.ml to /home/opam/.opam/4.07/lib/checkseum
  - /home/opam/.opam/4.07/.opam-switch/build/checkseum.0.0.3/_build/install/default/lib/checkseum/ocaml/gin_crc32.cmx to /home/opam/.opam/4.07/lib/checkseum
  - /home/opam/.opam/4.07/.opam-switch/build/checkseum.0.0.3/_build/install/default/lib/checkseum/ocaml/gin_crc32.cmt to /home/opam/.opam/4.07/lib/checkseum
  - /home/opam/.opam/4.07/.opam-switch/build/checkseum.0.0.3/_build/install/default/lib/checkseum/ocaml/gin_crc32.cmi to /home/opam/.opam/4.07/lib/checkseum
  - /home/opam/.opam/4.07/.opam-switch/build/checkseum.0.0.3/_build/install/default/lib/checkseum/ocaml/gin_adler32.ml to /home/opam/.opam/4.07/lib/checkseum
  - /home/opam/.opam/4.07/.opam-switch/build/checkseum.0.0.3/_build/install/default/lib/checkseum/ocaml/gin_adler32.cmx to /home/opam/.opam/4.07/lib/checkseum
  - /home/opam/.opam/4.07/.opam-switch/build/checkseum.0.0.3/_build/install/default/lib/checkseum/ocaml/gin_adler32.cmt to /home/opam/.opam/4.07/lib/checkseum
  - /home/opam/.opam/4.07/.opam-switch/build/checkseum.0.0.3/_build/install/default/lib/checkseum/ocaml/gin_adler32.cmi to /home/opam/.opam/4.07/lib/checkseum
  - /home/opam/.opam/4.07/.opam-switch/build/checkseum.0.0.3/_build/install/default/lib/checkseum/ocaml/checkseum_ocaml.cmxs to /home/opam/.opam/4.07/lib/checkseum
  - /home/opam/.opam/4.07/.opam-switch/build/checkseum.0.0.3/_build/install/default/lib/checkseum/ocaml/checkseum_ocaml.cmxa to /home/opam/.opam/4.07/lib/checkseum
  - /home/opam/.opam/4.07/.opam-switch/build/checkseum.0.0.3/_build/install/default/lib/checkseum/ocaml/checkseum_ocaml.cma to /home/opam/.opam/4.07/lib/checkseum
  - /home/opam/.opam/4.07/.opam-switch/build/checkseum.0.0.3/_build/install/default/lib/checkseum/ocaml/checkseum_ocaml.a to /home/opam/.opam/4.07/lib/checkseum
  - /home/opam/.opam/4.07/.opam-switch/build/checkseum.0.0.3/_build/install/default/lib/checkseum/ocaml/checkseum.mli to /home/opam/.opam/4.07/lib/checkseum
  - /home/opam/.opam/4.07/.opam-switch/build/checkseum.0.0.3/_build/install/default/lib/checkseum/ocaml/checkseum.ml to /home/opam/.opam/4.07/lib/checkseum
  - /home/opam/.opam/4.07/.opam-switch/build/checkseum.0.0.3/_build/install/default/lib/checkseum/ocaml/checkseum.cmx to /home/opam/.opam/4.07/lib/checkseum
  - /home/opam/.opam/4.07/.opam-switch/build/checkseum.0.0.3/_build/install/default/lib/checkseum/ocaml/checkseum.cmti to /home/opam/.opam/4.07/lib/checkseum
  - /home/opam/.opam/4.07/.opam-switch/build/checkseum.0.0.3/_build/install/default/lib/checkseum/ocaml/checkseum.cmt to /home/opam/.opam/4.07/lib/checkseum
  - /home/opam/.opam/4.07/.opam-switch/build/checkseum.0.0.3/_build/install/default/lib/checkseum/ocaml/checkseum.cmi to /home/opam/.opam/4.07/lib/checkseum
  - /home/opam/.opam/4.07/.opam-switch/build/checkseum.0.0.3/_build/install/default/lib/checkseum/laolao/liblaolao_stubs.a to /home/opam/.opam/4.07/lib/checkseum
  - /home/opam/.opam/4.07/.opam-switch/build/checkseum.0.0.3/_build/install/default/lib/checkseum/laolao/laolao.ml to /home/opam/.opam/4.07/lib/checkseum
  - /home/opam/.opam/4.07/.opam-switch/build/checkseum.0.0.3/_build/install/default/lib/checkseum/laolao/laolao.cmxs to /home/opam/.opam/4.07/lib/checkseum
  - /home/opam/.opam/4.07/.opam-switch/build/checkseum.0.0.3/_build/install/default/lib/checkseum/laolao/laolao.cmxa to /home/opam/.opam/4.07/lib/checkseum
  - /home/opam/.opam/4.07/.opam-switch/build/checkseum.0.0.3/_build/install/default/lib/checkseum/laolao/laolao.cmx to /home/opam/.opam/4.07/lib/checkseum
  - /home/opam/.opam/4.07/.opam-switch/build/checkseum.0.0.3/_build/install/default/lib/checkseum/laolao/laolao.cmt to /home/opam/.opam/4.07/lib/checkseum
  - /home/opam/.opam/4.07/.opam-switch/build/checkseum.0.0.3/_build/install/default/lib/checkseum/laolao/laolao.cmi to /home/opam/.opam/4.07/lib/checkseum
  - /home/opam/.opam/4.07/.opam-switch/build/checkseum.0.0.3/_build/install/default/lib/checkseum/laolao/laolao.cma to /home/opam/.opam/4.07/lib/checkseum
  - /home/opam/.opam/4.07/.opam-switch/build/checkseum.0.0.3/_build/install/default/lib/checkseum/laolao/laolao.a to /home/opam/.opam/4.07/lib/checkseum
  - /home/opam/.opam/4.07/.opam-switch/build/checkseum.0.0.3/_build/install/default/lib/checkseum/c/checkseum_c.cmxs to /home/opam/.opam/4.07/lib/checkseum
  - /home/opam/.opam/4.07/.opam-switch/build/checkseum.0.0.3/_build/install/default/lib/checkseum/c/checkseum_c.cmxa to /home/opam/.opam/4.07/lib/checkseum
  - /home/opam/.opam/4.07/.opam-switch/build/checkseum.0.0.3/_build/install/default/lib/checkseum/c/checkseum_c.cma to /home/opam/.opam/4.07/lib/checkseum
  - /home/opam/.opam/4.07/.opam-switch/build/checkseum.0.0.3/_build/install/default/lib/checkseum/c/checkseum_c.a to /home/opam/.opam/4.07/lib/checkseum
  - /home/opam/.opam/4.07/.opam-switch/build/checkseum.0.0.3/_build/install/default/lib/checkseum/c/checkseum.mli to /home/opam/.opam/4.07/lib/checkseum
  - /home/opam/.opam/4.07/.opam-switch/build/checkseum.0.0.3/_build/install/default/lib/checkseum/c/checkseum.ml to /home/opam/.opam/4.07/lib/checkseum
  - /home/opam/.opam/4.07/.opam-switch/build/checkseum.0.0.3/_build/install/default/lib/checkseum/c/checkseum.cmx to /home/opam/.opam/4.07/lib/checkseum
  - /home/opam/.opam/4.07/.opam-switch/build/checkseum.0.0.3/_build/install/default/lib/checkseum/c/checkseum.cmti to /home/opam/.opam/4.07/lib/checkseum
  - /home/opam/.opam/4.07/.opam-switch/build/checkseum.0.0.3/_build/install/default/lib/checkseum/c/checkseum.cmt to /home/opam/.opam/4.07/lib/checkseum
  - /home/opam/.opam/4.07/.opam-switch/build/checkseum.0.0.3/_build/install/default/lib/checkseum/c/checkseum.cmi to /home/opam/.opam/4.07/lib/checkseum

@rgrinberg
Copy link
Member Author

I'm not sure how this is a dune problem. Dune only generates the .install file and the contents of .install looks right to me. opam-installer failed to install the artifacts for some reason. Unfortunately, I cannot help in explaining why opam-installer failed.

@kit-ty-kate
Copy link
Member

I'm not sure how this is a dune problem. Dune only generates the .install file and the contents of .install looks right to me. opam-installer failed to install the artifacts for some reason. Unfortunately, I cannot help in explaining why opam-installer failed.

It is a dune bug. I tested it locally with dune 1.9.1 and dune 1.10.0 and after calling dune runtest the files that opam has trouble installing are not present anymore in the _build directory with dune 1.10.0 but not with dune 1.9.1.

@avsm
Copy link
Member

avsm commented Jun 1, 2019

Confirmed regression here with a dune 1.10 switch and opam install -t checkseum.0.0.3. It doesn't happen with checkseum.0.1.0 which uses library_variants 0.1, so it's something to do with the funky -no-keep-locs and copy_files rules which we used before variants. Worth tracking down before merging dune 1.10 to ensure it isn't a more serious underlying bug.

@rgrinberg
Copy link
Member Author

Yeah, this is indeed a regression. I've made an appropriate ticket in dune.

@rgrinberg rgrinberg closed this Jun 2, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment