-
Notifications
You must be signed in to change notification settings - Fork 414
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
Allow targets in subdirectories #3374
Comments
I think this should be doable with #3268 |
I haven't found a way to make it work with |
(also if I try to copy the files at the root in the |
We’re (at For example we have these rules that're generated as a result of generated dune files concept by the help of include stanza.
And what we want is for dune to be able to generate the But
(There is a RFC on this topic though) |
I hit the same issue trying to gradually port configure+Makefile to dune. Eventually I came up with the following hacky workaround. In (rule
(alias configure)
(deps
; ...
)
(targets
; ...
; HACK: workaround for https://github.com/ocaml/dune/issues/3374
src__machdep-ml.c
src__cilversion.ml
lib__perl5__App__Cilly__CilConfig.pm)
(action (progn
(run ./configure)
; HACK: workaround for https://github.com/ocaml/dune/issues/3374
; HACK: use "run cp" instead of "copy" to avoid implicit unsupported subdir deps
(run cp src/machdep-ml.c src__machdep-ml.c)
(run cp src/cilversion.ml src__cilversion.ml)
(run cp lib/perl5/App/Cilly/CilConfig.pm lib__perl5__App__Cilly__CilConfig.pm)))) In ; HACK: workaround for https://github.com/ocaml/dune/issues/3374
(rule (action (copy ../src__machdep-ml.c machdep-ml.c)))
(rule (action (copy ../src__cilversion.ml cilversion.ml))) |
There's now an experimental directory targets feature that you can try out. See |
When trying to wrap existing complex projects, it would be very convenient to write something like:
Unfortunately
dune
complains with:The text was updated successfully, but these errors were encountered: