Skip to content

Don't introduce dependency in case of using copy from DSL for building stubs. #2006

@XVilka

Description

@XVilka

For example if you have something like

(library
 (name mylib_c)
 (public_name mylib.c)
 (modules)
 (self_stubs_build_archive mylib_c_stubs)

(rule
 (deps (source_tree c))
 (targets libmylib_c_stubs.a dllmylib_c_stubs.so)
 (action (progn
          (chdir c (run make)))
          (copy c/libmylib.a libmylib_c_stubs.a)
          (copy c/libmylib.so dllmylib_c_stubs.so)))

then it introduces dependency to mylib/c/libmylib.a
See https://discuss.ocaml.org/t/dune-depend-on-non-dune-libraries-in-the-workspace/3150/7 and https://discuss.ocaml.org/t/strange-error-in-dune-building/2979/3 for more context.

Opening an issue, since I wasn't able to find anything in the issue tracker about this. Would be awesome to fix this one day and we have to remove make -C c before calling dune in our buildscripts.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions