1

I've got a project where I'm trying out the lens library. I'm trying to generate haddock docs so I can see the functions produced by the makeClassy TemplateHaskell function. cabal build works fine, but cabal haddock fails with

$ cabal haddock
Running Haddock for myproject-0.0.1...
Warning: The documentation for the following packages are not installed. No
links will be generated to these packages: rts-1.0
Preprocessing library myproject-0.0.1...
<command line>: cannot satisfy -package-id lens-3.7.1-a40583cdc124338f52ab40ebbf747e8f
    (use -v for more information)

What am I missing?

purefn
  • 836
  • 4
  • 14
  • Does `cabal haddock -v` give more information? Which package id does `ghc-pkg describe lens` report? – Daniel Fischer Dec 22 '12 at 20:18
  • @DanielFischer `cabal haddock -v` doesn't give any more information, just dumps the `haddock` command it runs. I running that directly and increasing the verbosity, but it didn't offer any additional information. `ghc-pkg describe lens` reports `name: lens version: 3.7.1 id: lens-3.7.1-a40583cdc124338f52ab40ebbf747e8f license: BSD3` – purefn Dec 23 '12 at 00:14
  • 1
    Pity. Normally something like `cannot satisfy -package-id lens-3.7.1-a40583cdc124338f52ab40ebbf747e8f` indicates a missing or broken dependency. But if `cabal build` works, that doesn't seem to be the case. Nevertheless, checking for broken packages with `ghc-pkg check` or `ghc -v` is never a bad idea. You can try whether `cabal install` works, though I don't know why it should pass different options to haddock. – Daniel Fischer Dec 23 '12 at 00:31

0 Answers0