2

I try to generate documentation for my executable using cabal haddock. My project structure looks like this:

~/.../project_name
project_name.cabal
Setup.hs
src/
    Main.hs
    Data/
    ...
 test/
    MainTestSuite
    ...

When I run cabal haddock --executable it fails with the following error message:

module ‘projects-0.1.0.0:Main’ is defined in multiple files: dist/build/tmp-8215/src/Main.hs
                                                             dist/build/tmp-8215/./Setup.hs

The Source.hs file has these contents:

import Distribution.Simple
main = defaultMain

The ghc Version is 7.8.3 and the haddock version is 2.14.3.

sclv
  • 38,665
  • 7
  • 99
  • 204
jules
  • 1,897
  • 2
  • 16
  • 19

0 Answers0