cabal posix build-depends issue

Isaac Jones ijones at
Sat Jan 15 19:31:58 EST 2005


I have a bit of a problem with Cabal's need to build-depend on posix.
I'm building cabal with itself, and I think this is what's happening:

If it depends on posix, on a non-posix system, the user will get an
error because the posix package doesn't exist.

If it doesn't depend on posix on a posix-based system, then ghc won't
get the -package posix flag, and so cabal will fail to link.

On the other hand, "depends" in the cabal sense is meant to be a
static value; not dependent on what kind of system you are
using... it's kinda funny to say "if you're on a posix system, then
cabal depends on posix."

Cabal doesn't _really_ depend on POSIX... it only does in its Compat
libraries, and we could get rid of all the POSIX code.

I think another ugly workaround is to have cabal depend on "util" or
something, since that package depends on posix on a posix system, and
presumably it doesn't depend on posix on a non-posix system.

Any ideas?  Should we just delete the Posix code in cabal?



More information about the Libraries mailing list