|
9 | 9 | push:
|
10 | 10 | branches: [master]
|
11 | 11 |
|
| 12 | + workflow_dispatch: |
| 13 | + |
12 | 14 | jobs:
|
13 | 15 | cabal:
|
14 |
| - name: ${{ matrix.os }} / ghc ${{ matrix.ghc }} |
15 |
| - runs-on: ${{ matrix.os }} |
| 16 | + name: ${{ matrix.plat }} / ghc ${{ matrix.ghc }} |
| 17 | + runs-on: "${{ fromJSON('{\"x86_64-linux\": \"ubuntu-24.04\", \"aarch64-linux\": \"ubuntu-24.04-arm\", \"x86_64-darwin\": \"macos-latest\", \"aarch64-darwin\": \"macos-latest\"}')[matrix.plat] }}" |
| 18 | + |
16 | 19 | strategy:
|
17 | 20 | fail-fast: false
|
18 | 21 | matrix:
|
19 |
| - os: [ubuntu-latest] |
20 |
| - ghc: ['9.6.5'] # bootstrapping compiler |
| 22 | + plat: [x86_64-linux, aarch64-linux, x86_64-darwin, aarch64-darwin] |
| 23 | + ghc: ['98'] # bootstrapping compiler |
21 | 24 |
|
22 | 25 | steps:
|
23 | 26 | - uses: actions/checkout@v4
|
24 | 27 | with:
|
25 | 28 | submodules: "recursive"
|
26 | 29 |
|
27 |
| - - uses: haskell-actions/setup@v2 |
28 |
| - id: setup |
29 |
| - name: Setup Haskell tools |
| 30 | + - uses: input-output-hk/actions/devx@latest |
30 | 31 | with:
|
31 |
| - ghc-version: ${{ matrix.ghc }} |
32 |
| - cabal-version: "latest" |
33 |
| - cabal-update: true |
| 32 | + platform: ${{ matrix.plat }} |
| 33 | + compiler-nix-name: 'ghc98' |
| 34 | + minimal: true |
| 35 | + ghc: true |
34 | 36 |
|
35 |
| - - name: Install Alex and Happy |
36 |
| - run: | |
37 |
| - cabal install alex |
38 |
| - cabal install happy |
| 37 | + - name: Update hackage |
| 38 | + shell: devx {0} |
| 39 | + run: cabal update |
39 | 40 |
|
40 | 41 | - name: Configure the build
|
41 |
| - run: | |
42 |
| - ./boot |
43 |
| - ./configure |
44 |
| -
|
45 |
| - - name: Build Hadrian |
46 |
| - run: | |
47 |
| - ./hadrian/build --version |
| 42 | + shell: devx {0} |
| 43 | + run: ./configure |
48 | 44 |
|
49 | 45 | - name: Build the bindist
|
50 |
| - run: | |
51 |
| - ./hadrian/build --flavour=release -j binary-dist-dir --docs=none |
| 46 | + shell: devx {0} |
| 47 | + run: make CABAL=$PWD/_build/stage0/bin/cabal |
| 48 | + |
| 49 | + - name: Upload artifacts |
| 50 | + uses: actions/upload-artifact@v4 |
| 51 | + with: |
| 52 | + name: ${{ matrix.plat }}-bindist |
| 53 | + path: _build/bindist |
| 54 | + |
| 55 | + - name: Run the testsuite |
| 56 | + shell: devx {0} |
| 57 | + run: make test CABAL=$PWD/_build/stage0/bin/cabal |
| 58 | + |
| 59 | + - name: Upload test results |
| 60 | + uses: actions/upload-artifact@v4 |
| 61 | + if: ${{ !cancelled() }} # upload test results even if the testsuite failed to pass |
| 62 | + with: |
| 63 | + name: testsuite-results |
| 64 | + path: | |
| 65 | + _build/test-perf.csv |
| 66 | + _build/test-summary.txt |
| 67 | + _build/test-junit.xml |
0 commit comments