【问题标题】:Alternative dependencies error when switch from dune 1.1 to dune 2.0从沙丘 1.1 切换到沙丘 2.0 时出现替代依赖错误
【发布时间】:2021-01-09 12:16:55
【问题描述】:

我将 dune 项目版本从 (lang dune 1.1) 切换到 (lang dune 2.0),这在处理备用依赖项时产生了错误。

我在使用 dune 1.1 的沙丘文件中遇到了错误:

(select vpl_domain.ml from
  (vpl -> domains/numeric/vpl_domain.ok.ml)
  (!vpl -> domains/numeric/vpl_domain.ko.ml))

但是用dune 2.0会产生错误

此选择分支中的文件格式必须为 vpl_domain.{name}.ml

我试图像这样删除文件名之前的路径:

(select vpl_domain.ml from
  (vpl -> vpl_domain.ok.ml)
  (!vpl -> vpl_domain.ko.ml)))

这似乎让沙丘对格式感到满意,但给出了错误

没有为 vpl_domain.ko.ml 找到规则

我做错了什么,这是沙丘的错误还是他们自愿做出重大改变?

【问题讨论】:

    标签: ocaml ocaml-dune


    【解决方案1】:

    我终于在documentation发现了:

    Dune 官方只支持目标在当前目录的用户规则

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2021-06-23
      • 1970-01-01
      • 2022-08-22
      • 1970-01-01
      • 2019-10-25
      相关资源
      最近更新 更多