Skip to content

Commit 53c6a5d

Browse files
authored
Merge pull request #152 from haskell/ghc-9.8
v4000.4.1-r3: Support GHC 9.8
2 parents f23d148 + 52b876d commit 53c6a5d

File tree

4 files changed

+69
-210
lines changed

4 files changed

+69
-210
lines changed

.github/workflows/haskell-ci.yml

Lines changed: 49 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -6,41 +6,50 @@
66
#
77
# haskell-ci regenerate
88
#
9-
# For more information, see https://github.com/haskell-CI/haskell-ci
9+
# For more information, see https://github.com/andreasabel/haskell-ci
1010
#
11-
# version: 0.15.20230321
11+
# version: 0.17.20231002
1212
#
13-
# REGENDATA ("0.15.20230321",["github","HTTP.cabal"])
13+
# REGENDATA ("0.17.20231002",["github","HTTP.cabal"])
1414
#
1515
name: Haskell-CI
1616
on:
17-
- push
18-
- pull_request
17+
push:
18+
branches:
19+
- master
20+
pull_request:
21+
branches:
22+
- master
1923
jobs:
2024
linux:
2125
name: Haskell-CI - Linux - ${{ matrix.compiler }}
2226
runs-on: ubuntu-20.04
2327
timeout-minutes:
2428
60
2529
container:
26-
image: buildpack-deps:bionic
30+
image: buildpack-deps:focal
2731
continue-on-error: ${{ matrix.allow-failure }}
2832
strategy:
2933
matrix:
3034
include:
31-
- compiler: ghc-9.6.1
35+
- compiler: ghc-9.8.0.20230929
3236
compilerKind: ghc
33-
compilerVersion: 9.6.1
37+
compilerVersion: 9.8.0.20230929
38+
setup-method: ghcup
39+
allow-failure: true
40+
- compiler: ghc-9.6.3
41+
compilerKind: ghc
42+
compilerVersion: 9.6.3
3443
setup-method: ghcup
3544
allow-failure: false
36-
- compiler: ghc-9.4.4
45+
- compiler: ghc-9.4.7
3746
compilerKind: ghc
38-
compilerVersion: 9.4.4
47+
compilerVersion: 9.4.7
3948
setup-method: ghcup
4049
allow-failure: false
41-
- compiler: ghc-9.2.7
50+
- compiler: ghc-9.2.8
4251
compilerKind: ghc
43-
compilerVersion: 9.2.7
52+
compilerVersion: 9.2.8
4453
setup-method: ghcup
4554
allow-failure: false
4655
- compiler: ghc-9.0.2
@@ -83,16 +92,6 @@ jobs:
8392
compilerVersion: 7.10.3
8493
setup-method: hvr-ppa
8594
allow-failure: false
86-
- compiler: ghc-7.8.4
87-
compilerKind: ghc
88-
compilerVersion: 7.8.4
89-
setup-method: hvr-ppa
90-
allow-failure: false
91-
- compiler: ghc-7.6.3
92-
compilerKind: ghc
93-
compilerVersion: 7.6.3
94-
setup-method: hvr-ppa
95-
allow-failure: false
9695
fail-fast: false
9796
steps:
9897
- name: apt
@@ -101,17 +100,19 @@ jobs:
101100
apt-get install -y --no-install-recommends gnupg ca-certificates dirmngr curl git software-properties-common libtinfo5
102101
if [ "${{ matrix.setup-method }}" = ghcup ]; then
103102
mkdir -p "$HOME/.ghcup/bin"
104-
curl -sL https://downloads.haskell.org/ghcup/0.1.19.2/x86_64-linux-ghcup-0.1.19.2 > "$HOME/.ghcup/bin/ghcup"
103+
curl -sL https://downloads.haskell.org/ghcup/0.1.19.5/x86_64-linux-ghcup-0.1.19.5 > "$HOME/.ghcup/bin/ghcup"
105104
chmod a+x "$HOME/.ghcup/bin/ghcup"
105+
"$HOME/.ghcup/bin/ghcup" config add-release-channel https://raw.githubusercontent.com/haskell/ghcup-metadata/master/ghcup-prereleases-0.0.7.yaml;
106106
"$HOME/.ghcup/bin/ghcup" install ghc "$HCVER" || (cat "$HOME"/.ghcup/logs/*.* && false)
107107
"$HOME/.ghcup/bin/ghcup" install cabal 3.10.1.0 || (cat "$HOME"/.ghcup/logs/*.* && false)
108108
else
109109
apt-add-repository -y 'ppa:hvr/ghc'
110110
apt-get update
111111
apt-get install -y "$HCNAME"
112112
mkdir -p "$HOME/.ghcup/bin"
113-
curl -sL https://downloads.haskell.org/ghcup/0.1.19.2/x86_64-linux-ghcup-0.1.19.2 > "$HOME/.ghcup/bin/ghcup"
113+
curl -sL https://downloads.haskell.org/ghcup/0.1.19.5/x86_64-linux-ghcup-0.1.19.5 > "$HOME/.ghcup/bin/ghcup"
114114
chmod a+x "$HOME/.ghcup/bin/ghcup"
115+
"$HOME/.ghcup/bin/ghcup" config add-release-channel https://raw.githubusercontent.com/haskell/ghcup-metadata/master/ghcup-prereleases-0.0.7.yaml;
115116
"$HOME/.ghcup/bin/ghcup" install cabal 3.10.1.0 || (cat "$HOME"/.ghcup/logs/*.* && false)
116117
fi
117118
env:
@@ -126,10 +127,12 @@ jobs:
126127
echo "CABAL_CONFIG=$HOME/.cabal/config" >> "$GITHUB_ENV"
127128
HCDIR=/opt/$HCKIND/$HCVER
128129
if [ "${{ matrix.setup-method }}" = ghcup ]; then
129-
HC=$HOME/.ghcup/bin/$HCKIND-$HCVER
130+
HC=$("$HOME/.ghcup/bin/ghcup" whereis ghc "$HCVER")
131+
HCPKG=$(echo "$HC" | sed 's#ghc$#ghc-pkg#')
132+
HADDOCK=$(echo "$HC" | sed 's#ghc$#haddock#')
130133
echo "HC=$HC" >> "$GITHUB_ENV"
131-
echo "HCPKG=$HOME/.ghcup/bin/$HCKIND-pkg-$HCVER" >> "$GITHUB_ENV"
132-
echo "HADDOCK=$HOME/.ghcup/bin/haddock-$HCVER" >> "$GITHUB_ENV"
134+
echo "HCPKG=$HCPKG" >> "$GITHUB_ENV"
135+
echo "HADDOCK=$HADDOCK" >> "$GITHUB_ENV"
133136
echo "CABAL=$HOME/.ghcup/bin/cabal-3.10.1.0 -vnormal+nowrap" >> "$GITHUB_ENV"
134137
else
135138
HC=$HCDIR/bin/$HCKIND
@@ -143,7 +146,7 @@ jobs:
143146
echo "HCNUMVER=$HCNUMVER" >> "$GITHUB_ENV"
144147
echo "ARG_TESTS=--enable-tests" >> "$GITHUB_ENV"
145148
echo "ARG_BENCH=--enable-benchmarks" >> "$GITHUB_ENV"
146-
echo "HEADHACKAGE=false" >> "$GITHUB_ENV"
149+
if [ $((HCNUMVER >= 90800)) -ne 0 ] ; then echo "HEADHACKAGE=true" >> "$GITHUB_ENV" ; else echo "HEADHACKAGE=false" >> "$GITHUB_ENV" ; fi
147150
echo "ARG_COMPILER=--$HCKIND --with-compiler=$HC" >> "$GITHUB_ENV"
148151
echo "GHCJSARITH=0" >> "$GITHUB_ENV"
149152
env:
@@ -172,6 +175,18 @@ jobs:
172175
repository hackage.haskell.org
173176
url: http://hackage.haskell.org/
174177
EOF
178+
if $HEADHACKAGE; then
179+
cat >> $CABAL_CONFIG <<EOF
180+
repository head.hackage.ghc.haskell.org
181+
url: https://ghc.gitlab.haskell.org/head.hackage/
182+
secure: True
183+
root-keys: 7541f32a4ccca4f97aea3b22f5e593ba2c0267546016b992dfadcd2fe944e55d
184+
26021a13b401500c8eb2761ca95c61f2d625bfef951b939a8124ed12ecf07329
185+
f76d08be13e9a61a377a85e2fb63f4c5435d40f8feb3e12eb05905edb8cdea89
186+
key-threshold: 3
187+
active-repositories: hackage.haskell.org, head.hackage.ghc.haskell.org:override
188+
EOF
189+
fi
175190
cat >> $CABAL_CONFIG <<EOF
176191
program-default-options
177192
ghc-options: $GHCJOBS +RTS -M3G -RTS
@@ -188,14 +203,14 @@ jobs:
188203
- name: install cabal-plan
189204
run: |
190205
mkdir -p $HOME/.cabal/bin
191-
curl -sL https://github.com/haskell-hvr/cabal-plan/releases/download/v0.6.2.0/cabal-plan-0.6.2.0-x86_64-linux.xz > cabal-plan.xz
192-
echo 'de73600b1836d3f55e32d80385acc055fd97f60eaa0ab68a755302685f5d81bc cabal-plan.xz' | sha256sum -c -
206+
curl -sL https://github.com/haskell-hvr/cabal-plan/releases/download/v0.7.3.0/cabal-plan-0.7.3.0-x86_64-linux.xz > cabal-plan.xz
207+
echo 'f62ccb2971567a5f638f2005ad3173dba14693a45154c1508645c52289714cb2 cabal-plan.xz' | sha256sum -c -
193208
xz -d < cabal-plan.xz > $HOME/.cabal/bin/cabal-plan
194209
rm -f cabal-plan.xz
195210
chmod a+x $HOME/.cabal/bin/cabal-plan
196211
cabal-plan --version
197212
- name: checkout
198-
uses: actions/checkout@v3
213+
uses: actions/checkout@v4
199214
with:
200215
path: source
201216
- name: initial cabal.project for sdist
@@ -223,6 +238,9 @@ jobs:
223238
if [ $((HCNUMVER >= 80200)) -ne 0 ] ; then echo " ghc-options: -Werror=missing-methods" >> cabal.project ; fi
224239
cat >> cabal.project <<EOF
225240
EOF
241+
if $HEADHACKAGE; then
242+
echo "allow-newer: $($HCPKG list --simple-output | sed -E 's/([a-zA-Z-]+)-[0-9.]+/*:\1,/g')" >> cabal.project
243+
fi
226244
$HCPKG list --simple-output --names-only | perl -ne 'for (split /\s+/) { print "constraints: $_ installed\n" unless /^(HTTP)$/; }' >> cabal.project.local
227245
cat cabal.project
228246
cat cabal.project.local

.travis.yml

Lines changed: 0 additions & 173 deletions
This file was deleted.

HTTP.cabal

Lines changed: 19 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -58,9 +58,22 @@ Description:
5858
Extra-Source-Files: CHANGES
5959

6060
tested-with:
61-
GHC==9.2.1, GHC==9.0.1,
62-
GHC==8.10.7, GHC==8.8.4, GHC==8.6.5, GHC==8.4.4, GHC==8.2.2, GHC==8.0.2,
63-
GHC==7.10.3, GHC==7.8.4, GHC==7.6.3
61+
GHC == 9.8.0
62+
GHC == 9.6.3
63+
GHC == 9.4.7
64+
GHC == 9.2.8
65+
GHC == 9.0.2
66+
GHC == 8.10.7
67+
GHC == 8.8.4
68+
GHC == 8.6.5
69+
GHC == 8.4.4
70+
GHC == 8.2.2
71+
GHC == 8.0.2
72+
GHC == 7.10.3
73+
-- 2023-10-04: Dropping GHC < 7.10 from CI
74+
-- because they need the ubuntu-18.04 image incompatible with latest 'node'
75+
-- GHC == 7.8.4
76+
-- GHC == 7.6.3
6477

6578
Source-Repository head
6679
type: git
@@ -110,9 +123,9 @@ Library
110123
-- note the test harness constraints should be kept in sync with these
111124
-- where dependencies are shared
112125
build-depends:
113-
base >= 4.6.0.0 && < 4.19
126+
base >= 4.6.0.0 && < 4.20
114127
, array >= 0.3.0.2 && < 0.6
115-
, bytestring >= 0.9.1.5 && < 0.12
128+
, bytestring >= 0.9.1.5 && < 0.13
116129
, parsec >= 2.0 && < 3.2
117130
, time >= 1.1.2.3 && < 1.13
118131
, transformers >= 0.2.0.0 && < 0.7
@@ -157,7 +170,7 @@ Test-Suite test
157170
, mtl
158171
, network
159172
-- extra dependencies
160-
, deepseq >= 1.3.0.0 && < 1.5
173+
, deepseq >= 1.3.0.0 && < 1.6
161174
, httpd-shed >= 0.4 && < 0.5
162175
, HUnit >= 1.2.0.1 && < 1.7
163176
, pureMD5 >= 0.2.4 && < 2.2

cabal.haskell-ci

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
branches: master

0 commit comments

Comments
 (0)