Trying to install diagrams on OS X

126 Views Asked by At

I'm trying to install diagrams on OS X. While downloading it, I get this kind of error message:

Building linear-1.20.4...
Failed to install linear-1.20.4
Build log ( /Users/Max/.cabal-sandbox/logs/linear-1.20.4.log ):

then some time later after some successful linked package:

[ 5 of 22] Compiling Linear.V0        ( src/Linear/V0.hs, dist/dist-sandbox-9f82d52a/build/Linear/V0.o )

src/Linear/V0.hs:318:25:
    ‘eq1’ is not a (visible) method of class ‘Eq1’

src/Linear/V0.hs:319:25:
    ‘compare1’ is not a (visible) method of class ‘Ord1’

src/Linear/V0.hs:320:25:
    ‘showsPrec1’ is not a (visible) method of class ‘Show1’

src/Linear/V0.hs:321:25:
    ‘readsPrec1’ is not a (visible) method of class ‘Read1’

cabal: Error: some packages failed to install:
active-0.2.0.8 depends on linear-1.20.4 which failed to install.
diagrams-1.3 depends on linear-1.20.4 which failed to install.
diagrams-contrib-1.3.0.8 depends on linear-1.20.4 which failed to install.
diagrams-core-1.3.0.5 depends on linear-1.20.4 which failed to install.
diagrams-lib-1.3.0.9 depends on linear-1.20.4 which failed to install.
diagrams-svg-1.3.1.10 depends on linear-1.20.4 which failed to install.
force-layout-0.4.0.3 depends on linear-1.20.4 which failed to install.
linear-1.20.4 failed during the building phase. The exception was:
ExitFailure 1

Does anyone know how to solve it?

My gtk and cabal are all up-to-date.

Thank you :)

1

There are 1 best solutions below

0
On

You ran into a bug in that version of linear, relating to certain versions of the transformers library.

See the following ticket:

https://github.com/ekmett/linear/issues/97

The comment notes: "Already fixed in 4a2aab7, not yet on Hackage. In the meantime, use transformers > 0.3 or transformers-compat < 0.5"