
Think of it like this: a collection of Haskell source files often share common dependencies. Those dependencies include packages, but also things like what C libraries and header files are required by the code, and what extra GHC flags might be required to compile it. We find it convenient to put all this information in one place: the .cabal file. You can think of .cabal as part of the source if that helps. It really is part of the source - but implemented and specified as a layer on top of existing language and compiler technology, for convenience and so that we can share the tools. When all the dependencies are explicit, the code is portable. That's what you're arguing for - but we're already there. All you have to do is write a .cabal file, cut-and-paste a 3-line Setup.lhs file, and you're done. And for free, we'll throw in a multi-compiler, multi-platform build system and automated installation. But that's not all! Get Cabal, and later we'll also give you automated dependency download and installation, automated binary package generation in a variety of formats, automated publishing and lots more. Cheers, Simon