From f5b43160034a66e94823a427be477dfe1129b37d Mon Sep 17 00:00:00 2001 From: Oleg Grenrus Date: Sun, 19 Nov 2023 21:37:58 +0200 Subject: [PATCH] GHC-9.8 support --- .github/workflows/haskell-ci.yml | 37 +++++++++++++++++++------------- .github/workflows/simple.yml | 4 ++-- postgresql-simple.cabal | 14 ++++++------ 3 files changed, 32 insertions(+), 23 deletions(-) diff --git a/.github/workflows/haskell-ci.yml b/.github/workflows/haskell-ci.yml index ad67bd4..0accd8d 100644 --- a/.github/workflows/haskell-ci.yml +++ b/.github/workflows/haskell-ci.yml @@ -8,9 +8,9 @@ # # For more information, see https://github.com/haskell-CI/haskell-ci # -# version: 0.16.6 +# version: 0.17.20231110 # -# REGENDATA ("0.16.6",["github","cabal.project"]) +# REGENDATA ("0.17.20231110",["github","cabal.project"]) # name: Haskell-CI on: @@ -38,14 +38,19 @@ jobs: strategy: matrix: include: - - compiler: ghc-9.6.2 + - compiler: ghc-9.8.1 compilerKind: ghc - compilerVersion: 9.6.2 + compilerVersion: 9.8.1 setup-method: ghcup allow-failure: false - - compiler: ghc-9.4.5 + - compiler: ghc-9.6.3 compilerKind: ghc - compilerVersion: 9.4.5 + compilerVersion: 9.6.3 + setup-method: ghcup + allow-failure: false + - compiler: ghc-9.4.8 + compilerKind: ghc + compilerVersion: 9.4.8 setup-method: ghcup allow-failure: false - compiler: ghc-9.2.8 @@ -81,18 +86,18 @@ jobs: apt-get install -y --no-install-recommends gnupg ca-certificates dirmngr curl git software-properties-common libtinfo5 if [ "${{ matrix.setup-method }}" = ghcup ]; then mkdir -p "$HOME/.ghcup/bin" - curl -sL https://downloads.haskell.org/ghcup/0.1.19.2/x86_64-linux-ghcup-0.1.19.2 > "$HOME/.ghcup/bin/ghcup" + curl -sL https://downloads.haskell.org/ghcup/0.1.20.0/x86_64-linux-ghcup-0.1.20.0 > "$HOME/.ghcup/bin/ghcup" chmod a+x "$HOME/.ghcup/bin/ghcup" "$HOME/.ghcup/bin/ghcup" install ghc "$HCVER" || (cat "$HOME"/.ghcup/logs/*.* && false) - "$HOME/.ghcup/bin/ghcup" install cabal 3.10.1.0 || (cat "$HOME"/.ghcup/logs/*.* && false) + "$HOME/.ghcup/bin/ghcup" install cabal 3.10.2.0 || (cat "$HOME"/.ghcup/logs/*.* && false) else apt-add-repository -y 'ppa:hvr/ghc' apt-get update apt-get install -y "$HCNAME" mkdir -p "$HOME/.ghcup/bin" - curl -sL https://downloads.haskell.org/ghcup/0.1.19.2/x86_64-linux-ghcup-0.1.19.2 > "$HOME/.ghcup/bin/ghcup" + curl -sL https://downloads.haskell.org/ghcup/0.1.20.0/x86_64-linux-ghcup-0.1.20.0 > "$HOME/.ghcup/bin/ghcup" chmod a+x "$HOME/.ghcup/bin/ghcup" - "$HOME/.ghcup/bin/ghcup" install cabal 3.10.1.0 || (cat "$HOME"/.ghcup/logs/*.* && false) + "$HOME/.ghcup/bin/ghcup" install cabal 3.10.2.0 || (cat "$HOME"/.ghcup/logs/*.* && false) fi env: HCKIND: ${{ matrix.compilerKind }} @@ -106,17 +111,19 @@ jobs: echo "CABAL_CONFIG=$HOME/.cabal/config" >> "$GITHUB_ENV" HCDIR=/opt/$HCKIND/$HCVER if [ "${{ matrix.setup-method }}" = ghcup ]; then - HC=$HOME/.ghcup/bin/$HCKIND-$HCVER + HC=$("$HOME/.ghcup/bin/ghcup" whereis ghc "$HCVER") + HCPKG=$(echo "$HC" | sed 's#ghc$#ghc-pkg#') + HADDOCK=$(echo "$HC" | sed 's#ghc$#haddock#') echo "HC=$HC" >> "$GITHUB_ENV" - echo "HCPKG=$HOME/.ghcup/bin/$HCKIND-pkg-$HCVER" >> "$GITHUB_ENV" - echo "HADDOCK=$HOME/.ghcup/bin/haddock-$HCVER" >> "$GITHUB_ENV" - echo "CABAL=$HOME/.ghcup/bin/cabal-3.10.1.0 -vnormal+nowrap" >> "$GITHUB_ENV" + echo "HCPKG=$HCPKG" >> "$GITHUB_ENV" + echo "HADDOCK=$HADDOCK" >> "$GITHUB_ENV" + echo "CABAL=$HOME/.ghcup/bin/cabal-3.10.2.0 -vnormal+nowrap" >> "$GITHUB_ENV" else HC=$HCDIR/bin/$HCKIND echo "HC=$HC" >> "$GITHUB_ENV" echo "HCPKG=$HCDIR/bin/$HCKIND-pkg" >> "$GITHUB_ENV" echo "HADDOCK=$HCDIR/bin/haddock" >> "$GITHUB_ENV" - echo "CABAL=$HOME/.ghcup/bin/cabal-3.10.1.0 -vnormal+nowrap" >> "$GITHUB_ENV" + echo "CABAL=$HOME/.ghcup/bin/cabal-3.10.2.0 -vnormal+nowrap" >> "$GITHUB_ENV" fi HCNUMVER=$(${HC} --numeric-version|perl -ne '/^(\d+)\.(\d+)\.(\d+)(\.(\d+))?$/; print(10000 * $1 + 100 * $2 + ($3 == 0 ? $5 != 1 : $3))') diff --git a/.github/workflows/simple.yml b/.github/workflows/simple.yml index 1b064cd..db98743 100644 --- a/.github/workflows/simple.yml +++ b/.github/workflows/simple.yml @@ -14,7 +14,7 @@ jobs: strategy: matrix: os: [macos-latest, windows-latest] - ghc: ['8.10','9.0','9.2','9.4.5','9.6.2'] + ghc: ['8.10','9.0','9.2','9.4.8','9.6.3','9.8.1'] fail-fast: false timeout-minutes: 60 @@ -29,7 +29,7 @@ jobs: uses: haskell/actions/setup@v2 with: ghc-version: ${{ matrix.ghc }} - cabal-version: '3.10.1.0' + cabal-version: '3.10.2.0' - name: Set up PostgreSQL uses: ikalnytskyi/action-setup-postgres@v3 diff --git a/postgresql-simple.cabal b/postgresql-simple.cabal index b9ade5d..ca47515 100644 --- a/postgresql-simple.cabal +++ b/postgresql-simple.cabal @@ -1,6 +1,7 @@ cabal-version: 1.12 name: postgresql-simple version: 0.7.0.0 +x-revision: 1 synopsis: Mid-Level PostgreSQL client library description: Mid-Level PostgreSQL client library, forked from mysql-simple. @@ -28,8 +29,9 @@ tested-with: || ==8.10.7 || ==9.0.2 || ==9.2.8 - || ==9.4.5 - || ==9.6.2 + || ==9.4.8 + || ==9.6.3 + || ==9.8.1 library default-language: Haskell2010 @@ -75,11 +77,11 @@ library -- GHC bundled libs build-depends: - base >=4.12.0.0 && <4.19 - , bytestring >=0.10.8.2 && <0.12 + base >=4.12.0.0 && <4.20 + , bytestring >=0.10.8.2 && <0.13 , containers >=0.6.0.1 && <0.7 - , template-haskell >=2.14.0.0 && <2.21 - , text >=1.2.3.0 && <1.3 || >=2.0 && <2.1 + , template-haskell >=2.14.0.0 && <2.22 + , text >=1.2.3.0 && <1.3 || >=2.0 && <2.2 , time-compat >=1.9.5 && <1.12 , transformers >=0.5.6.2 && <0.7