Cabal Compatibility
Cabal developers have
implemented great improvements over recent years! My open source
software does not yet make use of many of the improvements, however. The
reason for this is that I try to increase the extent of open source software in
an attempt to make it more easy to use across a wide range of
environments. I have to do without features such as internal
sub-libraries and common
stanzas, but the software can be built using older versions of
cabal-install
.
Cabal Versions
I currently try to make my open source software compatible with the following versions.
GHC Version | Release Date | Minimum Cabal Version |
---|---|---|
GHC 8.2.2 | 2017-07-22 | Cabal 1.24 |
GHC 8.4.4 | 2018-10-14 | Cabal 2.2 |
GHC 8.6.5 | 2019-04-23 | Cabal 2.4 |
GHC 8.8.4 | 2020-07-15 | Cabal 3.0 |
GHC 8.10.4 | 2021-02-05 | Cabal 3.2 |
GHC 9.0.1 | 2021-02-04 | Cabal 3.4 |
Different programming communities have different feelings toward compatibility. In the Haskell community, core library maintainers tend to take compatibility seriously while many other community members tend to promote use of bleeding-edge releases over compatibility.
For open source Haskell software, I would like to maintain compatibility with systems that are five years old. I look forward to using features introduced in Cabal 2 in late 2023!
Haskell GitHub Actions
I use GitHub Actions for running continuous integration tests, using Haskell GitHub Actions. A variety of GHC and Cabal versions are available for use.
Currently, I configure three types of jobs:
latest-cabal
jobs build and test software using various versions of GHC with the latestcabal-install
release.stack
jobs build and test software using Stack configurations for various versions of GHC.cabal
jobs build and test software using various versions ofcabal-install
with a fixed version of GHC.
For example, see the current CI
configuration for TTC
(Textual Type Classes). The latest-cabal
jobs test all
of the above GHC versions. The stack
jobs do not test GHC
9.0.1 because there is not an LTS release for that version yet. The
cabal
jobs do not test Cabal 1.24 because that version is
not available or Cabal 2.2 because that version fails to install in the
GitHub Actions environment. Note that the cabal
jobs use
the oldest supported version of GHC.