reflex - 无法将软件包安装到 nix-build 项目
问题描述
在为 obelist 项目运行后nix-build -o frontend-result -A ghcjs.frontend
,它会出现几个导入错误,其中之一是:
src/Frontend.hs:10:1: error:
Could not find module ‘Control.Monad.Trans’
Perhaps you meant
Control.Monad.Fail (from base-4.11.1.0)
Control.Monad.Fix (from base-4.11.1.0)
Control.Monad.ST (from base-4.11.1.0)
Use -v to see a list of the files searched for.
之后我尝试安装包cabal new-install Control
cabal: Could not resolve dependencies:
[__0] trying: backend-0.1 (user goal)
[__1] unknown package: obelisk-route (dependency of backend)
[__1] fail (backjumping, conflict set: backend, obelisk-route)
解决方案
reflex 和 obelix 都使用 cabal 来声明依赖关系,但实际上是通过 nix 安装它们。因此,您假设将 mtl 包(如上例)添加到 field build-depends 下的 frontend.cabal 中。
推荐阅读
- c++ - 无法将 QButtonGroup::idClicked 连接到函数
- angular - Angular / Firebase - 从时间戳中提取日期和时间
- python - VScode python上下文颜色主题——修改模块和方法的颜色
- c++11 - 我们如何在集合的地图中添加一个元素...例如.map
>mp; 在 C++14 中 - python - 当我尝试将我的 Django 项目部署到 Heroku 时,它没有检测到 buildpack。有人可以帮我吗?
- javascript - 如何提取2 个标签之间的内容并将该内容放在单独的数组中
- python - Python循环中的内存错误
- php - 递归不会继续下一项
- javascript - 如何使用 ID 或 Class 在一个 amp HTML 文档的不同位置调用一个 Javascript 函数?
- python - 为什么在 Django 中运行 PostgreSQL UPDATE 时出现错误“不是在字符串格式化期间转换的所有参数”?