Skip to content

Commit d658b88

Browse files
authored
Merge pull request #223 from Shimuuar/CI-mac
Update GHC versions in CI and macos runners
2 parents a70b38e + 14fbd7b commit d658b88

3 files changed

Lines changed: 32 additions & 18 deletions

File tree

.github/workflows/ci.yml

Lines changed: 24 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -18,18 +18,22 @@ jobs:
1818
matrix:
1919
include:
2020
# Linux
21-
- { cabal: "3.12", os: ubuntu-latest, ghc: "8.4.4" }
22-
- { cabal: "3.12", os: ubuntu-latest, ghc: "8.6.5" }
23-
- { cabal: "3.12", os: ubuntu-latest, ghc: "8.8.4" }
24-
- { cabal: "3.12", os: ubuntu-latest, ghc: "8.10.7" }
25-
- { cabal: "3.12", os: ubuntu-latest, ghc: "9.0.2" }
26-
- { cabal: "3.12", os: ubuntu-latest, ghc: "9.2.8" }
27-
- { cabal: "3.12", os: ubuntu-latest, ghc: "9.4.8" }
28-
- { cabal: "3.12", os: ubuntu-latest, ghc: "9.6.6" }
29-
- { cabal: "3.12", os: ubuntu-latest, ghc: "9.8.4" }
30-
- { cabal: "3.12", os: ubuntu-latest, ghc: "9.10.1" }
31-
# Fails to resolve aeson [2025.01.14]
32-
# - { cabal: "3.12", os: ubuntu-latest, ghc: "9.12.1" }
21+
- { cabal: "3.14", os: ubuntu-latest, ghc: "8.4.4" }
22+
- { cabal: "3.14", os: ubuntu-latest, ghc: "8.6.5" }
23+
- { cabal: "3.14", os: ubuntu-latest, ghc: "8.8.4" }
24+
- { cabal: "3.14", os: ubuntu-latest, ghc: "8.10.7" }
25+
- { cabal: "3.14", os: ubuntu-latest, ghc: "9.0.2" }
26+
- { cabal: "3.14", os: ubuntu-latest, ghc: "9.2.8" }
27+
- { cabal: "3.14", os: ubuntu-latest, ghc: "9.4.8" }
28+
- { cabal: "3.14", os: ubuntu-latest, ghc: "9.6.7" }
29+
- { cabal: "3.14", os: ubuntu-latest, ghc: "9.8.4" }
30+
- { cabal: "3.14", os: ubuntu-latest, ghc: "9.10.2" }
31+
- { cabal: "3.14", os: ubuntu-latest, ghc: "9.12.2" }
32+
# Macos
33+
- { cabal: "3.14", os: macos-latest, ghc: "9.6.7" }
34+
- { cabal: "3.14", os: macos-latest, ghc: "9.8.4" }
35+
- { cabal: "3.14", os: macos-latest, ghc: "9.10.2" }
36+
- { cabal: "3.14", os: macos-latest, ghc: "9.12.2" }
3337
fail-fast: false
3438

3539
steps:
@@ -52,6 +56,8 @@ jobs:
5256
- name: "Install PAPI"
5357
run: |
5458
sudo apt-get install -y libpapi-dev
59+
echo FLAG_PAPI=-fBenchPAPI >> "$GITHUB_ENV"
60+
if: matrix.os == 'ubuntu-latest'
5561
# ----------------
5662
- name: Versions
5763
run: |
@@ -74,11 +80,16 @@ jobs:
7480
# ----------------
7581
- name: Build
7682
run: |
83+
echo FLAG_PAPI=$FLAG_PAPI
7784
cd unpacked/statistics-*
78-
cabal configure --haddock-all --enable-tests --enable-benchmarks
85+
cabal configure $FLAG_PAPI --haddock-all --enable-tests --enable-benchmarks --benchmark-option=-l
7986
cabal build all --write-ghc-environment-files=always
8087
# ----------------
8188
- name: Test
8289
run: |
8390
cd unpacked/statistics-*
8491
cabal test all
92+
# ----------------
93+
- name: Bench
94+
run: |
95+
cabal bench all
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
module Main where
2+
13
import Data.Complex
24
import Statistics.Sample
35
import Statistics.Transform

statistics.cabal

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -54,9 +54,10 @@ tested-with:
5454
|| ==9.0.2
5555
|| ==9.2.8
5656
|| ==9.4.8
57-
|| ==9.6.6
57+
|| ==9.6.7
5858
|| ==9.8.4
59-
|| ==9.10.1
59+
|| ==9.10.2
60+
|| ==9.12.2
6061

6162
source-repository head
6263
type: git
@@ -205,7 +206,7 @@ test-suite statistics-doctests
205206
build-depends:
206207
base -any
207208
, statistics -any
208-
, doctest >=0.15 && <0.24
209+
, doctest >=0.15 && <0.25
209210

210211
-- We want to be able to build benchmarks using both tasty-bench and tasty-papi.
211212
-- They have similar API so we just create two shim modules which reexport
@@ -223,7 +224,7 @@ benchmark statistics-bench
223224
import: bench-stanza
224225
type: exitcode-stdio-1.0
225226
hs-source-dirs: benchmark bench-time
226-
main-is: bench.hs
227+
main-is: Main.hs
227228
Other-modules: Bench
228229
build-depends: tasty-bench >= 0.3
229230

@@ -233,6 +234,6 @@ benchmark statistics-bench-papi
233234
if impl(ghcjs) || !flag(BenchPAPI)
234235
buildable: False
235236
hs-source-dirs: benchmark bench-papi
236-
main-is: bench.hs
237+
main-is: Main.hs
237238
Other-modules: Bench
238239
build-depends: tasty-papi >= 0.1.2

0 commit comments

Comments
 (0)