简体   繁体   English

Cabal 无法安装 ghc-mod

[英]Cabal can't install ghc-mod

I'm trying to install ghc-mod to use with Atom-Haskell (the ide-haskell package) in Atom, but for some reason my Cabal doesn't want to.我正在尝试在 Atom 中安装 ghc-mod 以与 Atom-Haskell(ide-haskell 包)一起使用,但出于某种原因,我的 Cabal 不想这样做。

When I enter the command cabal install ghc-mod , I get the following errors in my terminal:当我输入命令cabal install ghc-mod ,我的终端出现以下错误:

Resolving dependencies...
cabal.exe: Could not resolve dependencies:
[__0] trying: ghc-mod-5.8.0.0 (user goal)
[__1] trying: syb-0.7.1 (dependency of ghc-mod)
[__2] next goal: base (dependency of ghc-mod)
[__2] rejecting: base-4.14.1.0/installed-4.14.1.0 (conflict: ghc-mod =>
base<4.10 && >=4.6.0.1)
[__2] skipping: base-4.14.0.0, base-4.13.0.0, base-4.12.0.0, base-4.11.1.0,
base-4.11.0.0, base-4.10.1.0, base-4.10.0.0 (has the same characteristics that
caused the previous version to fail: excluded by constraint '<4.10 &&
>=4.6.0.1' from 'ghc-mod')
[__2] rejecting: base-4.9.1.0, base-4.9.0.0, base-4.8.2.0, base-4.8.1.0,
base-4.8.0.0, base-4.7.0.2, base-4.7.0.1, base-4.7.0.0, base-4.6.0.1,
base-4.6.0.0, base-4.5.1.0, base-4.5.0.0, base-4.4.1.0, base-4.4.0.0,
base-4.3.1.0, base-4.3.0.0, base-4.2.0.2, base-4.2.0.1, base-4.2.0.0,
base-4.1.0.0, base-4.0.0.0, base-3.0.3.2, base-3.0.3.1 (constraint from
non-upgradeable package requires installed instance)
[__2] fail (backjumping, conflict set: base, ghc-mod)
After searching the rest of the dependency tree exhaustively, these were the
goals I've had most trouble fulfilling: base, ghc-mod, syb

I installed Cabal as part of the Haskell Platform, so to my understanding, it's a bit unusually configured.我安装了 Cabal 作为 Haskell 平台的一部分,所以据我所知,它的配置有点不寻常。 I don't have a %HOME%.cabal folder, and I don't know if that could be part of the issue?我没有 %HOME%.cabal 文件夹,我不知道这是否可能是问题的一部分?

I don't know a lot about how Cabal or ghc-mod work, so please let me know if you need any more info!我不太了解 Cabal 或 ghc-mod 的工作原理,所以如果您需要更多信息,请告诉我! Thanks for any help!谢谢你的帮助!

You probably have a new version of base, ( https://wiki.haskell.org/Base_package ) where ghc-mod is only compatible with versions >=4.6.0.1 && <4.10 ( https://hackage.haskell.org/package/ghc-mod ).您可能有一个新版本的 base,( https://wiki.haskell.org/Base_package ),其中 ghc-mod 仅与版本兼容 >=4.6.0.1 && <4.10 ( https://hackage.haskell.org/包/ghc-mod )。 You'd have to downgrade.你必须降级。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM