Build system idea

Iavor Diatchki iavor.diatchki at
Thu Sep 4 12:59:44 EDT 2008


On Thu, Aug 28, 2008 at 6:59 AM, Simon Marlow <marlowsd at> wrote:
> Because if you *can* use Cabal, you get a lot of value-adds for free (distro
> packages, cabal-install, Haddock, source distributions, Hackage). What's
> more, it's really cheap to use Cabal: a .cabal file is typically less than a
> screenful, so it's no big deal to switch to something else later if you need
> to.

Well, I think this illustrates the current thinking of the Haskell
community, where emphasis has been on making things either easy to do,
or really hard/impossible to do (a kind of Mac approach to software
development! :-).  It has the benefit that it makes things seem really
easy occasionally, but is it really honest?  Concretely:

cabal-install: it does not work well with packages that have flags
because it does not know what flags to use when building dependencies.
 Really, packages with conditionals are different packages in one
cabal file.

Haddock:  something seems wrong, if I need to use a specific build
system to document my code!

source distributions:  cabal is really of very little help here as one
has to enumerate everything that should be in the distribution.

Hackage:  Again, something is wrong if I should have to use a specific
build system to distribute my code.

distro-packages: I have not used these, but the only ones that I have
heard about are Don's Arch packages, which are not binary packages, so
there the problem is a bit simpler (still nice that it works though).

In summary, it seems to me that there are two or three components that
are tangled in the term "cabal":
1) a machine readable format for describing the meta-data associated
with a package/application (+ a library that can process this meta
2) a build tool that has support for interacting with Haskell
compilers and other tools that it knows about, to build a package.

It seems to me that most of the benefits of cabal come from (1), and
for most "simple" cases, (2) is just a way to avoid writing a
completely mundane Makefile, while for more complex cases (2)
basically doesn't work.


More information about the Glasgow-haskell-users mailing list