Replies: 4 comments 10 replies
-
Requiring ghc to compile it does not prevent cabal from being a framework for packaging haskell software in general. The framework consists of a file specification (cabal files), a packaging format (a cabal package as a tgz) as well as tools (Setup.hs files, cabal-install) for building such packages and repositories for storing such packages. The fact that the tools -- Setup.hs and cabal-install require ghc to build does not prevent cabal from being used to package and build arbitrary haskell software. I'm writing the above not to be pedantic, but to (hopefully) point out a potential way forward, even if partial. Let us call an example compiler That's pretty ugly though! Instead, we can extend the known compiler flavors with There's examples of doing this with ghcjs and HaskellSuite among others, and some relevant code is e.g. here cabal/Cabal/src/Distribution/Simple/Build.hs Line 846 in 3c06125 With such extensions, we can use There remains the problem that I don't think its feasible to remove all extensions beyond H2010, but I would hope a fair number can be, and I think the cabal team would be open to that. I suspect things may just be too far for the |
Beta Was this translation helpful? Give feedback.
-
Data point, actual number of extensions in
|
Beta Was this translation helpful? Give feedback.
-
@augustss we really tried for many years to remain agnostic, but it's very difficult to do in practice when there are no other actually supported Haskell implementations (i.e. releases that work on current platforms). Cabal for years had supposed support for hugs, nhc, jhc, etc etc. But in practice none of these compilers existed, and so support could not be tested. And we need to rely on the (non-existent) people supporting those compilers to also co-maintain the Cabal support for their compiler. Eventually this becomes impossible to justify. The overall architecture of Cabal is still designed to allow for multiple Haskell compilers, though bit-rot has probably eaten away at that somewhat. The way I would suggest you approach this initially is this:
|
Beta Was this translation helpful? Give feedback.
-
Since I have now written my own Cabal (MicroCabal) I will close this discussion, unless someone has something to add. |
Beta Was this translation helpful? Give feedback.
-
Cabal claims to be "A framework for packaging Haskell software". But after some minor inspection, it looks like it's a tool for ghc, requiring ghc.
If Cabal wants to be for Haskell, shouldn't it be written in Haskell2010? It looks very difficult to use Cabal without a long list of GHC features.
Not even the package that just deals with the syntax looks simple. (It seems I will have to write my own.) It's a pity that Cabal gave up Hugs support.
Beta Was this translation helpful? Give feedback.
All reactions