diff --git a/.github/workflows/haskell-ci.yml b/.github/workflows/haskell-ci.yml index 56f55e9..90432fa 100644 --- a/.github/workflows/haskell-ci.yml +++ b/.github/workflows/haskell-ci.yml @@ -233,6 +233,7 @@ jobs: if [ $((HCNUMVER >= 80200)) -ne 0 ] ; then echo "package io-streams" >> cabal.project ; fi if [ $((HCNUMVER >= 80200)) -ne 0 ] ; then echo " ghc-options: -Werror=missing-methods" >> cabal.project ; fi cat >> cabal.project <> cabal.project.local cat cabal.project @@ -271,6 +272,14 @@ jobs: run: | rm -f cabal.project.local $CABAL v2-build $ARG_COMPILER --disable-tests --disable-benchmarks all + - name: prepare for constraint sets + run: | + rm -f cabal.project.local + - name: constraint set bytestring-0.12 + run: | + if [ $((HCNUMVER >= 80000)) -ne 0 ] ; then $CABAL v2-build $ARG_COMPILER --enable-tests --disable-benchmarks --constraint='bytestring >= 0.12' --dependencies-only -j2 all ; fi + if [ $((HCNUMVER >= 80000)) -ne 0 ] ; then $CABAL v2-build $ARG_COMPILER --enable-tests --disable-benchmarks --constraint='bytestring >= 0.12' all ; fi + if [ $((HCNUMVER >= 80000)) -ne 0 ] ; then $CABAL v2-test $ARG_COMPILER --enable-tests --disable-benchmarks --constraint='bytestring >= 0.12' all ; fi - name: save cache uses: actions/cache/save@v3 if: always() diff --git a/cabal.haskell-ci b/cabal.haskell-ci index 3ad392c..4409cb0 100644 --- a/cabal.haskell-ci +++ b/cabal.haskell-ci @@ -1 +1,25 @@ branches: master ci* + +constraint-set bytestring-0.12 + -- bytestring-0.12 requires base >=4.9 (GHC 8.0) + ghc: >= 8.0 + constraints: bytestring >= 0.12 + -- + -- The following is silently ignored here: + -- + -- raw-project + -- allow-newer: bytestring + -- + tests: True + run-tests: True + +-- The following is meant to be for constraint-set bytestring-0.12 only, +-- but there is currently no way to enable `allow-newer: bytestring` +-- just for the constraint set. +-- +-- Since core library `bytestring` is constrained to `installed`, +-- it is not harmful to allow newer `bytestring` in the default runs +-- as well---it will have no effect there. +-- +raw-project + allow-newer: bytestring diff --git a/io-streams.cabal b/io-streams.cabal index e08156d..d621b72 100644 --- a/io-streams.cabal +++ b/io-streams.cabal @@ -141,7 +141,7 @@ Library Build-depends: base >= 4 && <5, attoparsec >= 0.10 && <0.15, - bytestring >= 0.9 && <0.12, + bytestring >= 0.9 && <0.13, primitive >= 0.2 && <0.9, process >= 1.1 && <1.7, text >=0.10 && <1.3 || >= 2.0 && <2.1,