无法安装happstack-hsp

时间:2012-11-24 09:48:18

标签: haskell haskell-platform happstack

我也在使用Windows 7和cygwin。

我从二月份开始在Haskell平台上安装了happstack-hsp。

我刚刚从四月开始安装了Haskell平台。我尝试通过cabal安装happstack-hsp包,并收到以下错误:

$cabal install happstack-hsp
Resolving dependencies...
Configuring hsp-0.7.1...
Building hsp-0.7.1...
Preprocessing library hsp-0.7.1...
ghc.exe: could not execute: trhsx
cabal.exe: Error: some packages failed to install:
happstack-hsp-7.1.1 depends on hsp-0.7.1 which failed to install.
hsp-0.7.1 failed during the building phase. The exception was:
ExitFailure 1

我试图安装trhsx,并收到此错误:

$cabal install trhsx
Resolving dependencies...
Configuring trhsx-0.2.2...
Building trhsx-0.2.2...
Preprocessing library trhsx-0.2.2...

Trhsx.hs:1:1:
    Could not find module `Prelude'
    It is a member of the hidden package `base'.
    Perhaps you need to add `base' to the build-depends in your .cabal file.
    It is a member of the hidden package `haskell2010-1.1.0.1'.
    Perhaps you need to add `haskell2010' to the build-depends in your .cabal file.
    It is a member of the hidden package `haskell98-2.0.0.1'.
    Perhaps you need to add `haskell98' to the build-depends in your .cabal file.
    Use -v to see a list of the files searched for.
cabal.exe: Error: some packages failed to install:
trhsx-0.2.2 failed during the building phase. The exception was:
ExitFailure 1

我也在cmd中尝试了这个,并得到了相同的结果。自从我使用haskell以来已经很多年了,而且它改变了很多,有什么想法吗?

1 个答案:

答案 0 :(得分:1)

trhsx现在来自hsx包。出错的原因是cabal默认情况下会在$HOME/.cabal/bin中安装可执行文件。但是,$HOME/.cabal/bin默认情况下不在$PATH

如果您将其添加到$PATH,那么一切都应该没问题。