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

Opam file generation: support with-doc and post #3770

Closed
craigfe opened this issue Sep 5, 2020 · 2 comments · Fixed by #5949
Closed

Opam file generation: support with-doc and post #3770

craigfe opened this issue Sep 5, 2020 · 2 comments · Fixed by #5949
Assignees
Labels
docs Documentation improvements

Comments

@craigfe
Copy link
Contributor

craigfe commented Sep 5, 2020

Opam currently supports five "package depends variables"1:

  1. dev
  2. build
  3. with-test
  4. with-doc
  5. post

Dune supports generating opam files with the first three, but not the last two. I've recently found post necessary when writing PPXs, so it'd be nice to see it supported by Dune.

This change could probably be folded in alongside solutions for #3653 and #3497.

Footnotes

  1. Relevant opam code

@dra27
Copy link
Member

dra27 commented Mar 24, 2021

Note that global variables are also valid at this point (https://github.com/ocaml/opam/blob/master/src/state/opamPackageVar.ml#L20-L26) - in particular, opam-version, which I need for ocurrent/opam-dune-lint#26.

@emillon
Copy link
Collaborator

emillon commented Jul 8, 2022

I'm not sure when this was fixed, but (depends (a :post)) is supported as of dune 3.3 - or any variable using the :name syntax. I just checked and this has been the case since the 1.10.0. But the docs suggest that only the first 3 are supported, so I'm tagging as such and will fix this.

@emillon emillon added docs Documentation improvements and removed enhancement help wanted labels Jul 8, 2022
@emillon emillon self-assigned this Jul 8, 2022
emillon added a commit to emillon/dune that referenced this issue Jul 8, 2022
Not just `with-test`, `build` and `dev`.

Closes ocaml#3770

Signed-off-by: Etienne Millon <me@emillon.org>
emillon added a commit that referenced this issue Jul 11, 2022
Not just `with-test`, `build` and `dev`.

Closes #3770

Signed-off-by: Etienne Millon <me@emillon.org>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs Documentation improvements
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants