1

I'm using Windows 7 with cygwin too.

I'd installed happstack-hsp fine with the Haskell Platform from February.

I just installed the Haskell Platform from April. I tried installing happstack-hsp package, through cabal and get the following error:

$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

I tried to to then install trhsx, and got this error:

$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

I tried this in cmd too, and got the same outcome. It's been many years since I used haskell, and it's changed quite a bit, any ideas?

3
  • I would re-install the Haskell platform. This looks to me as if you have a problem in the environment (variables) or in the path.
    – J Fritsch
    Commented Nov 24, 2012 at 11:47
  • According to Cabal, trhsx is obsolete, and you should use hsx instead. There's a four year(!) gap between those packages, so these errors are probably due to bitrot in trhsx.
    – user824425
    Commented Nov 24, 2012 at 12:29
  • Specifically, trhsx predates specification of the base version. You can probably fix it by downloading the source and adding haskell98 to the dependencies, but using hsx is the proper way.
    – isturdy
    Commented Nov 24, 2012 at 14:29

1 Answer 1

1

trhsx comes from the hsx package now. The reason for the error is that cabal installs the executable in $HOME/.cabal/bin by default. But, $HOME/.cabal/bin is not in your $PATH by default.

If you add that to your $PATH, then everything should be ok.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.