[Gtk2hs-devel] move Gtk2HsSetup.hs to gtk2hs-buildtools

Duncan Coutts duncan.coutts at googlemail.com
Wed Dec 1 00:43:14 CET 2010


On Thu, 2010-11-25 at 11:16 +0100, Axel Simon wrote:
> Dear Libraries,
> 
> this message is on shortcomings of cabal with respect to automatically  
> installing the gtk package which (a) depends on a package that  
> contains only build tools (i.e. only binaries) and (b) has a big  
> custom Haskell file Gtk2HsSetup.hs that Setup.hs has to import (and  
> which is required in any package in the Gtk2Hs suite). This file is  
> copied into every package of the Gtk2Hs suite which is a pain to  
> maintain.

I don't have any easy answers.

The "right solution" for (a) is for cabal-install to track build tools
(and C libs and all other dependencies, not just Haskell libs).

For dependencies of Setup.hs, this is also hard. The original Cabal spec
envisioned Setup.hs scripts being self-contained having no deps other
than the base libs and Cabal itself, since this was intended as the
primary user interface, so it must compile without a lot of fuss. In
principle for some future Cabal spec revision we could add some way to
declare that the build system itself requires certain dependencies.

I also hope that the size of the Gtk2Hs Setup.hs can eventually be
reduced by supporting c2hs in Cabal properly (i.e. including .chs
dependencies).

Duncan




More information about the Libraries mailing list