0

According to the iHaskell page it should be possible to install from Hackage

cabal install ihaskell

However, when I do so it fails to install certain packages:

...
[ 7 of 44] Compiling HsColour         ( src/HsColour.hs, dist/build/HsColour.o )

src/HsColour.hs:25:16:
    Couldn't match type `Int' with `[Char]'
    Expected type: String -> String
      Actual type: Int -> String -> String
    In the return type of a call of `CSS.hscolour'
    Probable cause: `CSS.hscolour' is applied to too few arguments
    In the expression: CSS.hscolour False
    In an equation for `hsColourHTML':
        hsColourHTML = CSS.hscolour False
Failed to install hlint-1.9.10
cabal: Error: some packages failed to install:
hlint-1.9.10 failed during the building phase. The exception was:
ExitFailure 1
ihaskell-0.5.0.0 depends on hlint-1.9.10 which failed to install.

Suggesting something about hlint-1.9.10. However, hlint-1.9.17 is in fact present.

ubuntu:~$ hlint -V
HLint v1.9.17, (C) Neil Mitchell 2006-2015
john mangual
  • 7,718
  • 13
  • 56
  • 95
  • similar issue on Github https://github.com/ndmitchell/hlint/issues/116 – john mangual Mar 14 '15 at 12:47
  • Looks like IHaskell depends on a version of hlint which may have an incompatibility with an API change in some versions of hscolour. Are you installing IHaskell from GitHub? If so, try eliminating the [version of hlint causing the bug](https://github.com/ndmitchell/hlint/issues/116) by changing the ihaskell.cabal lower bound of hlint to 1.9.17, which fixes that incompatibility with hscolour ([here](https://github.com/gibiansky/IHaskell/blob/master/ihaskell.cabal#L74) and [here](https://github.com/gibiansky/IHaskell/blob/master/ihaskell.cabal#L173), change the `>=1.9` to `>=1.9.17`). – Justin Leitgeb Mar 14 '15 at 13:06
  • @JustinLeitgeb I am installing using cabal install, which may be [a little behind](https://hackage.haskell.org/package/ihaskell). When I install from github I get `could not resolve dependency` errors. – john mangual Mar 14 '15 at 14:09
  • I installed IHaskell from Hackage in a new sandbox and everything went smoothly. The installed version of `hlint` is `1.9.17`. – Stefan Mar 14 '15 at 15:37
  • @Stefan Good for you unfortunately I am having difficulty. Sandbox doesn't even work for me. `cabal: unrecognised command: sandbox (try --help)` – john mangual Mar 14 '15 at 17:56
  • What version of `cabal` do you use? I'm using version 1.22, which is almost the latest. – Stefan Mar 14 '15 at 18:48
  • @johnmangual if sandbox is an unrecognized command, you'll need to upgrade cabal. Do cabal `update && cabal install cabal-install` and you should be able to use sandboxes. – Justin Leitgeb Mar 14 '15 at 22:25
  • @JustinLeitgeb still unable – john mangual Mar 14 '15 at 23:21
  • You might have to add the installation path of the updated cabal (iirc, somewhere in `~/.cabal`) to your `$PATH` variable. – Stefan Mar 15 '15 at 15:26
  • @Stefan see http://stackoverflow.com/questions/29052530/difficulties-installing-ihaskell – john mangual Mar 16 '15 at 03:15

0 Answers0