[Haskell-cafe] Re: ANN: Takusen 0.8

Don Stewart dons at galois.com
Wed Mar 5 18:08:56 EST 2008

> > ross:
> >
> > > If you want to use your own Setup.hs, you need to specify a Build-Type of
> >  > Custom, not Simple.  Some tools will ignore your Setup.hs if you specify
> >  > Simple.  I guess the message "If possible use 'build-type: Simple'" is
> >  > a bit confusing.
> >
> > Yes, cabal-setup found this confusing.
> >
> >  I wonder if its possible to just use flags for building the different
> >  takusen backends, rather than this automagic uber-discovery?
> Mebbe... are you suggesting command-line flags, or cabal flags? I'm
> certainly open to suggestions for improving the install.
> Part of the motivation for discovery is that for PostgreSQL, you need
> to run a program (with various flags) which spits out the locations
> for include files, libs, etc (presumably because they can vary on
> different platforms? I'm not really sure why, being a Windows chimp
> myself). Once you do this, it's not much more effort to extend it to
> detect other DBMS installations, assuming they have standard layouts
> (Oracle certainly does).
> The alternative approach is what HSQL did (and I think HDBC, too),
> which is to have a base package, and then a separate package for each
> back-end. I considered this, but I much prefer to have the library
> available as a single download-build-install process. This makes for a
> nicer user experience (at the expense of more work for the package
> maintainer).

Yeah, I really like the single package model. And the Setup.hs does work
-- I just can't use cabal 1.2.x or 1.3.x or 1.4.x with it :)

So I was imagining cabal flags to select things, but again, this may not
work for all backends.

> Isn't this partly the point of cabal's Setup.hs i.e. to accommodate
> more complex build processes than cabal provides out-of-the-box?
> Obviously there's some pain, because the cabal API is not stable, but
> c'est la vie...

That's right. It's all some give and take.

More information about the Libraries mailing list