[Hackage] #729: Support generated modules better

Hackage cvs-ghc at haskell.org
Sat Aug 21 10:44:02 EDT 2010

#729: Support generated modules better
  Reporter:  duncan         |        Owner:      
      Type:  enhancement    |       Status:  new 
  Priority:  normal         |    Milestone:      
 Component:  Cabal library  |      Version:  HEAD
  Severity:  normal         |     Keywords:      
Difficulty:  unknown        |   Ghcversion:      
  Platform:                 |  
 Currently Cabal's simple build system expects that all modules listed in
 the `exposed-modules` and `other-modules` have some original source file
 (possibly one that needs a preprocessor). There is a built-in hack for the
 generated Paths_pkgname module.

 Adding other generated modules is rather tricky because of the assumption
 that an original source file can be found. This should not be too hard to
 fix for build, since we can just look for the generated source file in the
 build location, but it affects sdist more severely. There is no way for
 sdist to know if a file is generated or not, so if a source file is not
 found then currently it just fails. Unlike at build time, it's reasonable
 to run sdist in a clean build tree.

 People can hack around it in the Setup.hs by filtering out the module name
 for various stages, but that is still tricky due to the combination of
 #410 and #627.

 This affects some core ghc components and also darcs.

Ticket URL: <http://hackage.haskell.org/trac/hackage/ticket/729>
Hackage <http://haskell.org/cabal/>
Hackage: Cabal and related projects

More information about the cabal-devel mailing list