Skip to content

Commit

Permalink
Preparation to add support for GHC versions newer than 9.2
Browse files Browse the repository at this point in the history
  • Loading branch information
LaurentRDC committed Dec 8, 2024
1 parent d42ce09 commit 9b61e4f
Show file tree
Hide file tree
Showing 7 changed files with 138 additions and 39 deletions.
55 changes: 55 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
name: Continuous Integration

on:
push:

jobs:
continuous-integration:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
ghc-version:
- "8.10.7"
- "9.0.2"
- "9.2.8"
- "9.4.8"
- "9.6.6"
- "9.8.2"
- "9.10.1"

steps:
- uses: actions/checkout@v4

- name: Install cabal/ghc
uses: haskell-actions/setup@v2
id: setup-haskell
with:
ghc-version: ${{ matrix.ghc-version }}
cabal-version: '3.10.3.0'

- name: Generate freeze file
run: |
cabal update
cabal configure --disable-optimization --enable-tests
cabal freeze
- name: Cache cabal work
uses: actions/cache@v4
with:
path: |
dist-newstyle
${{ steps.setup-haskell.outputs.cabal-store }}
key: ${{ runner.os }}-${{ hashFiles('cabal.project.freeze', 'cabal.project.local') }}-cabal-install

- name: Build dependencies
run: |
cabal build all --only-dependencies
- name: Build packages
run: |
cabal build all
- name: Run tests
run: |
cabal test all
22 changes: 22 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,2 +1,24 @@
.stack-work
/stack.yaml
dist
dist-*
cabal-dev
*.o
*.hi
*.hie
*.chi
*.chs.h
*.dyn_o
*.dyn_hi
.hpc
.hsenv
.cabal-sandbox/
cabal.sandbox.config
*.prof
*.aux
*.hp
*.eventlog
cabal.project.local
cabal.project.local~
.HTF/
.ghc.environment.*
22 changes: 22 additions & 0 deletions cabal.project
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
packages: repa/repa.cabal
repa-algorithms/repa-algorithms.cabal
repa-examples/repa-examples.cabal
repa-io/repa-io.cabal

-- Packages below are ignored until they can be updated
-- to support newer GHCs
-- repa-convert/repa-convert.cabal
-- repa-eval/repa-eval.cabal
-- repa-scalar/repa-scalar.cabal
-- repa-stream/repa-stream.cabal

-- We ignore some packages which depend on repa-array rather than repa
-- repa-array/repa-array.cabal
-- repa-flow/repa-flow.cabal
-- repa-query/repa-query.cabal
-- repa-tools/repa-tools.cabal
-- repa-store/repa-store.cabal
-- repa-machine/repa-machine.cabal


minimize-conflict-set: true
2 changes: 1 addition & 1 deletion repa-algorithms/repa-algorithms.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ Library
Build-Depends:
base >= 4.8 && < 5
, vector >= 0.11 && < 0.13
, repa == 3.4.1.*
, repa >= 3.4 && <3.5

ghc-options:
-Wall
Expand Down
66 changes: 33 additions & 33 deletions repa-examples/repa-examples.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,9 @@ Flag llvm

Executable repa-canny
Build-depends:
base >= 4.8 && < 4.15
, repa == 3.4.1.*
, repa-algorithms == 3.4.1.*
base >= 4.8 && < 4.17
, repa >= 3.4 && < 3.5
, repa-algorithms >= 3.4 && < 3.5

Main-is: examples/Canny/src-repa/Main.hs
hs-source-dirs: examples/Canny/src-repa .
Expand All @@ -46,11 +46,11 @@ Executable repa-canny

Executable repa-mmult
Build-depends:
base >= 4.8 && < 4.15
base >= 4.8 && < 4.17
, random == 1.1.*
, repa == 3.4.1.*
, repa-algorithms == 3.4.1.*
, repa-io == 3.4.1.*
, repa >= 3.4 && < 3.5
, repa-algorithms >= 3.4 && < 3.5
, repa-io >= 3.4 && < 3.5

Main-is: examples/MMult/src-repa/Main.hs
other-modules: Solver
Expand All @@ -72,9 +72,9 @@ Executable repa-mmult

Executable repa-laplace
Build-depends:
base >= 4.8 && < 4.15
, repa == 3.4.1.*
, repa-io == 3.4.1.*
base >= 4.8 && < 4.17
, repa >= 3.4 && < 3.5
, repa-io >= 3.4 && < 3.5
, template-haskell

Main-is: examples/Laplace/src-repa/Main.hs
Expand All @@ -95,10 +95,10 @@ Executable repa-laplace

Executable repa-fft2d
Build-depends:
base >= 4.8 && < 4.15
, repa == 3.4.1.*
, repa-algorithms == 3.4.1.*
, repa-io == 3.4.1.*
base >= 4.8 && < 4.17
, repa >= 3.4 && < 3.5
, repa-algorithms >= 3.4 && < 3.5
, repa-io >= 3.4 && < 3.5

Main-is: examples/FFT/FFT2d/src-repa/Main.hs
hs-source-dirs: examples/FFT/FFT2d/src-repa .
Expand All @@ -119,10 +119,10 @@ Executable repa-fft2d

Executable repa-fft2d-highpass
Build-depends:
base >= 4.8 && < 4.15
, repa == 3.4.1.*
, repa-algorithms == 3.4.1.*
, repa-io == 3.4.1.*
base >= 4.8 && < 4.17
, repa >= 3.4 && < 3.5
, repa-algorithms >= 3.4 && < 3.5
, repa-io >= 3.4 && < 3.5

Main-is: examples/FFT/HighPass2d/src-repa/Main.hs
hs-source-dirs: examples/FFT/HighPass2d/src-repa .
Expand All @@ -143,9 +143,9 @@ Executable repa-fft2d-highpass

Executable repa-fft3d-highpass
Build-depends:
base >= 4.8 && < 4.15
, repa == 3.4.1.*
, repa-algorithms == 3.4.1.*
base >= 4.8 && < 4.17
, repa >= 3.4 && < 3.5
, repa-algorithms >= 3.4 && < 3.5

Main-is: examples/FFT/HighPass3d/src-repa/Main.hs
hs-source-dirs: examples/FFT/HighPass3d/src-repa .
Expand All @@ -166,9 +166,9 @@ Executable repa-fft3d-highpass

Executable repa-blur
Build-depends:
base >= 4.8 && < 4.15
, repa == 3.4.1.*
, repa-algorithms == 3.4.1.*
base >= 4.8 && < 4.17
, repa >= 3.4 && < 3.5
, repa-algorithms >= 3.4 && < 3.5
, vector >= 0.11 && < 0.13

Main-is: examples/Blur/src-repa/Main.hs
Expand All @@ -190,9 +190,9 @@ Executable repa-blur

Executable repa-sobel
Build-depends:
base >= 4.8 && < 4.15
, repa == 3.4.1.*
, repa-algorithms == 3.4.1.*
base >= 4.8 && < 4.17
, repa >= 3.4 && < 3.5
, repa-algorithms >= 3.4 && < 3.5

Main-is: examples/Sobel/src-repa/Main.hs
other-modules: Solver
Expand All @@ -214,9 +214,9 @@ Executable repa-sobel

Executable repa-volume
Build-depends:
base >= 4.8 && < 4.15
, repa == 3.4.1.*
, repa-io == 3.4.1.*
base >= 4.8 && < 4.17
, repa >= 3.4 && < 3.5
, repa-io >= 3.4 && < 3.5

Main-is: examples/Volume/Main.hs
ghc-options:
Expand All @@ -236,9 +236,9 @@ Executable repa-volume

Executable repa-unit-test
Build-depends:
base >= 4.8 && < 4.15
, repa == 3.4.1.*
, QuickCheck >= 2.8 && < 2.14
base >= 4.8 && < 4.17
, repa >= 3.4 && < 3.5
, QuickCheck >= 2.8 && < 2.16

Main-is: examples/UnitTesting/UnitTesting.hs
hs-source-dirs: examples/UnitTesting .
Expand Down
8 changes: 4 additions & 4 deletions repa-io/repa-io.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,11 @@ Library
Build-Depends:
base >= 4.8 && < 5
, binary >= 0.7 && < 0.9
, bmp == 1.2.*
, bytestring >= 0.10 && < 0.12
, bmp >= 1.2 && <1.3
, bytestring >= 0.10 && < 0.13
, old-time == 1.1.*
, repa == 3.4.*
, vector >= 0.11 && < 0.13
, repa >= 3.4 && <3.5
, vector >= 0.11 && < 0.14

ghc-options:
-O2
Expand Down
2 changes: 1 addition & 1 deletion repa/repa.cabal
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ Library
, ghc-prim
, vector >= 0.11 && < 0.13
, bytestring >= 0.10 && < 0.12
, QuickCheck >= 2.8 && < 2.15
, QuickCheck >= 2.8 && < 2.16

ghc-options:
-Wall
Expand Down

0 comments on commit 9b61e4f

Please sign in to comment.