问题描述
我正在尝试在堆栈项目中安装 readline 包。我已经在 stack 文件夹和 package.yaml 中安装了 ghc-8.10.4 我在依赖项中得到了“readline”,我得到了这个错误
readline needed,but the stack configuration has no specified version (latest matching version is 1.0.3.0)
needed since EasyTime is a build target.
Some different approaches to resolving this:
* Recommended action: try adding the following to your extra-deps in /home/lucas/FACULTAD/ALP/DSLEasyTime/EasyTime/stack.yaml:
- readline-1.0.3.0@sha256:db011062b90fbfbbc8b02666d835742c1d4de1f990a89fc056ef8082f3e3cba0,912
所以我在 stack.yaml、extra-deps 中添加了这个建议,当 stack 构建库时它会抛出以下错误
readline>
readline> /tmp/stack-5e6b18c39fb4dc96/readline-1.0.3.0/Setup.hs:6:29: error:
readline> Variable not in scope: defaultUserHooks :: UserHooks
readline> |
readline> 6 | main = defaultMainWithHooks defaultUserHooks
readline> |
我不知道会是什么。我没有在互联网上找到任何解决方案。你能帮忙吗?
谢谢
解决方法
Haskell 软件包“readline”非常旧(7 年)并且与当前版本的 Cabal 不兼容。
对于当前维护的包中的类似功能,请查看 "haskeline"。