Skip to content

Commit 3d94dde

Browse files
committed
Replace i386 with emulated arm. The i386 is too unstable and could go away soon anyway
1 parent a17f372 commit 3d94dde

File tree

1 file changed

+23
-55
lines changed

1 file changed

+23
-55
lines changed

.github/workflows/haskell-ci.yaml

Lines changed: 23 additions & 55 deletions
Original file line numberDiff line numberDiff line change
@@ -86,65 +86,33 @@ jobs:
8686
cd ../vector-quicksort-*/
8787
cabal check
8888
89-
i386:
89+
emulated:
9090
runs-on: ubuntu-latest
91-
container:
92-
image: i386/ubuntu:bionic
93-
9491
strategy:
9592
fail-fast: false
9693
matrix:
97-
os: [ubuntu-latest]
98-
ghc:
99-
- "9.2"
100-
- "9.4"
101-
- "9.6"
102-
94+
arch: ['armv7', 'aarch64']
10395
steps:
104-
- name: Install
105-
run: |
106-
apt-get update -y
107-
apt-get install -y autoconf build-essential zlib1g-dev libgmp-dev curl libncurses5 libtinfo5 libncurses5-dev libtinfo-dev
108-
109-
curl --proto '=https' --tlsv1.2 -sSf https://get-ghcup.haskell.org | BOOTSTRAP_HASKELL_NONINTERACTIVE=1 BOOTSTRAP_HASKELL_MINIMAL=1 sh
110-
111-
source ~/.ghcup/env
112-
ghcup install ghc --set ${{ matrix.ghc }}
113-
ghcup install cabal latest
114-
115-
# This version must stay old enough to remain compatible with the container image.
116-
- uses: actions/checkout@v1
117-
118-
- name: Cabal update
119-
run: |
120-
source ~/.ghcup/env
121-
cabal --version
122-
123-
- name: Unpack
124-
run: |
125-
source ~/.ghcup/env
126-
cabal update
127-
128-
cabal sdist --ignore-project --output-directory ..
129-
cd ..
130-
cabal get vector-quicksort-*.tar.gz
131-
132-
- name: Build
133-
run: |
134-
source ~/.ghcup/env
135-
136-
project_file="$(pwd)/cabal.project.test"
137-
cd ../vector-quicksort-*/
138-
cabal build --project-file "$project_file" --enable-tests --enable-benchmarks all
139-
140-
- name: Test
141-
run: |
142-
export LANG="C.UTF-8"
143-
source ~/.ghcup/env
144-
145-
project_file="$(pwd)/cabal.project.test"
146-
cd ../vector-quicksort-*/
96+
- uses: actions/checkout@v4
14797

148-
cabal run --project-file "$project_file" test -- --quickcheck-tests=10000 --quickcheck-max-size=256
98+
- uses: actions/cache@v4
99+
name: Cache cabal store
100+
with:
101+
path: ~/.cabal/store
102+
key: ${{ runner.os }}-arm-${{ matrix.arch }}-${{ github.sha }}
103+
restore-keys: ${{ runner.os }}-arm-${{ matrix.arch }}-
149104

150-
cabal bench --project-file "$project_file" --benchmark-options='--stdev 100 --timeout 600' all
105+
- uses: uraimo/run-on-arch-action@v2
106+
with:
107+
arch: ${{ matrix.arch }}
108+
distro: ubuntu_rolling
109+
githubToken: ${{ github.token }}
110+
install: |
111+
apt-get update -y
112+
apt-get install -y curl ghc cabal-install libghc-tasty-quickcheck-dev libghc-tasty-hunit-dev g++
113+
run: |
114+
project_file="$(pwd)/cabal.project.test"
115+
cabal update
116+
cabal build --project-file "$project_file" --enable-tests --enable-benchmarks all
117+
cabal run --project-file "$project_file" test -- --quickcheck-tests=10000 --quickcheck-max-size=256
118+
cabal run --project-file "$project_file" bench -- --stdev 100 --timeout 600

0 commit comments

Comments
 (0)