Semigroup installation is not performed using cabal

I would like to install Snap, but I'm new to Haskell and its platform.

I use cabal to install Snap and cannot install the semigroups:

% cabal install snap
Resolving dependencies...
Configuring semigroups-0.8.3...
Preprocessing library semigroups-0.8.3...
Building semigroups-0.8.3...
[1 of 4] Compiling Numeric.Natural.Internal ( Numeric/Natural/Internal.hs, dist/build/Numeric/Natural/Internal.o )
[2 of 4] Compiling Numeric.Natural  ( Numeric/Natural.hs, dist/build/Numeric/Natural.o )
[3 of 4] Compiling Data.List.NonEmpty ( Data/List/NonEmpty.hs, dist/build/Data/List/NonEmpty.o )

Data/List/NonEmpty.hs:115:4:
    Can't make a derived instance of `Data (NonEmpty a)'
      (You need -XDeriveDataTypeable to derive an instance for this class)
    In the data type declaration for `NonEmpty'

Data/List/NonEmpty.hs:115:10:
    Can't make a derived instance of `Typeable (NonEmpty a)'
      (You need -XDeriveDataTypeable to derive an instance for this class)
    In the data type declaration for `NonEmpty'

This is my version of cabal:

% cabal --version
cabal-install version 0.10.2
using version 1.10.2.0 of the Cabal library 

I saw that the semigroups are dependent on many Snap dependencies, how can I fix this installation?

I run ubuntu with gnome "Vous utilizez actuellement Ubuntu 10.04 LTS - le Lynx Lucide - sortie en avril 2010 version"

Changes:

In the semigroups.cabal file in the package, I saw this:

  if !impl(hugs)
    other-extensions: DeriveDataTypeable
    cpp-options: -DLANGUAGE_DeriveDataTypeable

May I have to do "impl (hugs)" to return something fake? (but I have no idea what it is :))

thank

+3
source share
1 answer

ghc cabal

cabal install snap --ghc-option=-XDeriveDataTypeable

", " Cabal.

+2

All Articles