1

I'm a beginner starting with Haskell and I'm struggling with cabal install of the dependencies I need. I'm specifically trying to use Data.YAML which is part of yaml. Here is the error message I'm getting:

cabal sandbox init
cabal install --only-dependencies --enable-tests

[1 of 1] Compiling Main             ( /var/folders/4c/hs_zlv716_z8b25hd8_z60cm0000gn/T/exceptions-0.8.0.2-7178/exceptions-0.8.0.2/dist/dist-sandbox-f7008b70/setup/setup.hs, /var/folders/4c/hs_zlv716_z8b25hd8_z60cm0000gn/T/exceptions-0.8.0.2-7178/exceptions-0.8.0.2/dist/dist-sandbox-f7008b70/setup/Main.o )
Linking /var/folders/4c/hs_zlv716_z8b25hd8_z60cm0000gn/T/exceptions-0.8.0.2-7178/exceptions-0.8.0.2/dist/dist-sandbox-f7008b70/setup/setup ...
Configuring exceptions-0.8.0.2...
Building exceptions-0.8.0.2...
Preprocessing library exceptions-0.8.0.2...

src/Control/Monad/Catch.hs:87:8:
    Could not find module ‘Control.Monad.STM’
    There are files missing in the ‘stm-2.4.4’ package,
    try running 'ghc-pkg check'.
    Use -v to see a list of the files searched for.

src/Control/Monad/Catch.hs:91:8:
    Could not find module ‘Control.Monad.Trans.Except’
    There are files missing in the ‘transformers-compat-0.4.0.3’ package,
    try running 'ghc-pkg check'.
    Use -v to see a list of the files searched for.

src/Control/Monad/Catch.hs:94:8:
    Could not find module ‘Control.Monad.Reader’
    There are files missing in the ‘mtl-2.1.3.1’ package,
    try running 'ghc-pkg check'.
    Use -v to see a list of the files searched for.

src/Control/Monad/Catch/Pure.hs:58:8:
    Could not find module ‘Control.Monad.RWS’
    There are files missing in the ‘mtl-2.1.3.1’ package,
    try running 'ghc-pkg check'.
    Use -v to see a list of the files searched for.

Here are my system details:

uname -a
Darwin mbarton-lm.local 13.4.0 Darwin Kernel Version 13.4.0: Wed Mar 18 16:20:14 PDT 2015; root:xnu-2422.115.14~1/RELEASE_X86_64 x86_64 i386 MacBookPro9,1 Darwin

ghc -v
Glasgow Haskell Compiler, Version 7.8.4, stage 2 booted by GHC version 7.8.3
Using binary package database: /usr/local/Cellar/ghc/7.8.4/lib/ghc-7.8.4/package.conf.d/package.cache
wired-in package ghc-prim mapped to ghc-prim-0.3.1.0 a24f9c14c632d75b683d0f93283aea37
wired-in package integer-gmp mapped to integer-gmp-0.5.1.0-26579559b3647acf4f01d5edd9491a46
wired-in package base mapped to base-4.7.0.2-99f2b20e2491b27225d4c673401d826f
wired-in package rts mapped to builtin_rts
wired-in package template-haskell mapped to template-haskell-2.9.0.0-c0be869a24cf2c4fa8e8cbf52d0324ff
wired-in package dph-seq not found.
wired-in package dph-par not found.

cabal -V
cabal-install version 1.22.0.0
using version 1.22.0.0 of the Cabal library
Michael Barton
  • 8,868
  • 9
  • 35
  • 43
  • 2
    Did you run `ghc-pkg` check as the log suggests? That being said, I have no experience with GHC on Mac. Did you follow the installation guide at https://www.haskell.org/downloads/osx? – Zeta Apr 26 '15 at 19:38

0 Answers0