[英]When I try to install hlint I get errors surrounding old-time-1.1.0.3
I first tried to install Hlint. 我首先尝试安装Hlint。
cabal install hlint
but then I got the error: cabal install hlint
然后我得到了错误:
cabal: Error: some packages failed to install:
cpphs-1.20.2 depends on old-time-1.1.0.3 which failed to install.
haskell-src-exts-1.18.2 depends on old-time-1.1.0.3 which failed to install.
hlint-1.9.37 depends on old-time-1.1.0.3 which failed to install.
old-time-1.1.0.3 failed during the configure step. The exception was:
ExitFailure 77
Then I tried to install ghc-mod since I read that hlint is a dependency of that package(?). 然后我尝试安装ghc-mod,因为我读到hlint是该包的依赖项(?)。 Thinking that it might resolve the problem.
认为它可以解决问题。 So i did
cabal install ghc-mod
which gave me the error. 所以我做了
cabal install ghc-mod
,这给了我错误。
cabal: Error: some packages failed to install:
cpphs-1.20.2 depends on old-time-1.1.0.3 which failed to install.
ghc-mod-5.6.0.0 depends on old-time-1.1.0.3 which failed to install.
haskell-src-exts-1.17.1 depends on old-time-1.1.0.3 which failed to install.
hlint-1.9.35 depends on old-time-1.1.0.3 which failed to install.
old-time-1.1.0.3 failed during the configure step. The exception was:
ExitFailure 77
So it seems to be the same problem, around my the package old-time-1.1.0.3
. 所以它似乎是同样的问题,围绕我的包
old-time-1.1.0.3
。
The best way to know where it fails is to go through each failed package and install them one after the other. 知道失败的最佳方法是遍历每个失败的包并一个接一个地安装它们。
I had issue with haskell-src-exts
in which showed up in hlint
and when I tried to cabal install haskell-src-exts
it was happy
that wasn't properly installed. 我有问题
haskell-src-exts
hlint
出现在hlint
,当我尝试cabal install haskell-src-exts
hlint
时很happy
没有正确安装。
There are lots of variables that could be at play to explain what's going on, including cabal-install
and ghc
versions. 有很多变量可以解释发生了什么,包括
cabal-install
和ghc
版本。 It would be useful if you included the cabal --version
and ghc --version
output in your question. 如果你在你的问题中包含
cabal --version
和ghc --version
输出会很有用。
That said: I'd recommend trying out the installation using Stack . 那说:我建议使用Stack尝试安装。 Once you have Stack installed (on POSIX systems, usually sufficient to run
curl -sSL https://get.haskellstack.org/ | sh
), you can install with stack --resolver lts-6.16 --install-ghc --no-system-ghc install hlint
. 一旦你安装了堆栈(在POSIX系统上,通常足以运行
curl -sSL https://get.haskellstack.org/ | sh
),你可以用stack --resolver lts-6.16 --install-ghc --no-system-ghc install hlint
安装stack --resolver lts-6.16 --install-ghc --no-system-ghc install hlint
。
Are you on Windows or Linux? 你在Windows或Linux上吗? What does
ghc --version
say? ghc --version
说什么? What about ghc-pkg old-time
? ghc-pkg old-time
怎么样? I recommend trying to run cabal install old-time
directly, which should reproduce the error directly. 我建议尝试直接运行
cabal install old-time
,这应该直接重现错误。
Solution by OP. OP解决方案。
Modify your cabal config file (you can verify the location by running "cabal user-config init") to contain the following lines: 修改您的cabal配置文件(您可以通过运行“cabal user-config init”来验证位置)以包含以下行:
extra-prog-path: C:\Program Files\Haskell Platform\8.0.1\msys\usr\bin
extra-lib-dirs: C:\Program Files\Haskell Platform\8.0.1\mingw\lib
extra-include-dirs: C:\Program Files\Haskell Platform\8.0.1\mingw\include
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.