
On Wed, 2008-07-02 at 10:50 -0500, Alfonso Acosta wrote:
On Wed, Jul 2, 2008 at 8:57 AM, Duncan Coutts
wrote: Do not hard code the path. It can change (via a command line flag).
It's not necessary to hard code anything anyway, just using:
other-modules: Paths_ForSyDe
I tried to avoid doing it, but without adding dist/build/autogen to hs-source-dirs (that is, leaving it as "hs-source-dirs: src") I get the following error:
Setup.hs: can't find source for Paths_ForSyDe in ["src"]
Ah, sorry, that bug was only fixed in Cabal-1.4 so yes it will not work in Cabal-1.2.x. The reason not that many people have run into this issue is that typically it is executables not libraries that use data files and thus use the Paths_pkgname module and for executables it's possible to get away without listing all modules in the extra/other-modules fields. Duncan