Skip to content

Commit db74b8a

Browse files
committed
Add GHC-8.10.1 job. Only tests Cabal-the-lib part atm.
Also add validate-8.10.1 make rule
1 parent cf25742 commit db74b8a

File tree

6 files changed

+109
-3
lines changed

6 files changed

+109
-3
lines changed

.docker/validate-8.10.1.dockerfile

Lines changed: 60 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,60 @@
1+
FROM phadej/ghc:8.10.1-bionic
2+
3+
# Install cabal-plan
4+
RUN mkdir -p /root/.cabal/bin && \
5+
curl -L 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 && \
6+
echo "de73600b1836d3f55e32d80385acc055fd97f60eaa0ab68a755302685f5d81bc cabal-plan.xz" | sha256sum -c - && \
7+
xz -d < cabal-plan.xz > /root/.cabal/bin/cabal-plan && \
8+
rm -f cabal-plan.xz && \
9+
chmod a+x /root/.cabal/bin/cabal-plan
10+
11+
# Update index
12+
RUN cabal v2-update
13+
14+
# We install happy, so it's in the store; we (hopefully) don't use it directly.
15+
RUN cabal v2-install happy --constraint 'happy ^>=1.19.12'
16+
17+
# Install some other dependencies
18+
# Remove $HOME/.ghc so there aren't any environments
19+
RUN cabal v2-install -w ghc-8.10.1 --lib \
20+
aeson \
21+
async \
22+
base-compat \
23+
base16-bytestring \
24+
base64-bytestring \
25+
cryptohash-sha256 \
26+
Diff \
27+
echo \
28+
ed25519 \
29+
edit-distance \
30+
haskell-lexer \
31+
HTTP \
32+
network \
33+
optparse-applicative \
34+
pretty-show \
35+
regex-compat-tdfa \
36+
regex-tdfa \
37+
statistics \
38+
tar \
39+
tasty \
40+
tasty-golden \
41+
tasty-hunit \
42+
tasty-quickcheck \
43+
tree-diff \
44+
zlib \
45+
--constraint="bytestring installed" \
46+
--constraint="binary installed" \
47+
--constraint="containers installed" \
48+
--constraint="deepseq installed" \
49+
--constraint="directory installed" \
50+
--constraint="filepath installed" \
51+
--constraint="pretty installed" \
52+
--constraint="process installed" \
53+
--constraint="time installed" \
54+
--constraint="unix installed" \
55+
&& rm -rf $HOME/.ghc
56+
57+
# Validate
58+
WORKDIR /build
59+
COPY . /build
60+
RUN sh ./validate.sh --lib-only -w ghc-8.10.1 -v

.github/workflows/linux.yml

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,44 @@ on:
1818
- created
1919

2020
jobs:
21+
validate-8_10_1:
22+
name: validate.sh ghc-8.10.1
23+
runs-on: ubuntu-18.04
24+
needs: validate-8_8_3
25+
container:
26+
image: phadej/ghc:8.10.1-bionic
27+
steps:
28+
# https://help.github.com/en/actions/automating-your-workflow-with-github-actions/development-tools-for-github-actions#add-a-system-path-add-path
29+
- name: Set PATH
30+
run: |
31+
echo "::add-path::$HOME/.cabal/bin"
32+
- name: Install cabal-plan
33+
run: |
34+
mkdir -p $HOME/.cabal/bin
35+
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
36+
echo "de73600b1836d3f55e32d80385acc055fd97f60eaa0ab68a755302685f5d81bc cabal-plan.xz" | sha256sum -c -
37+
xz -d < cabal-plan.xz > $HOME/.cabal/bin/cabal-plan
38+
rm -f cabal-plan.xz
39+
chmod a+x $HOME/.cabal/bin/cabal-plan
40+
- name: Update Hackage index
41+
run: cabal v2-update
42+
# https://github.com/actions/checkout/issues/170
43+
# - uses: actions/checkout@v2
44+
- name: Checkout
45+
run: |
46+
git clone --depth 1 https://github.com/$GITHUB_REPOSITORY.git .
47+
git fetch origin $GITHUB_REF:temporary-ci-branch
48+
git checkout $GITHUB_SHA
49+
- name: Validate print-config
50+
run: sh validate.sh -j 2 -w ghc-8.10.1 -v --lib-only -s print-config
51+
- name: Validate print-tool-versions
52+
run: sh validate.sh -j 2 -w ghc-8.10.1 -v --lib-only -s print-tool-versions
53+
- name: Validate build
54+
run: sh validate.sh -j 2 -w ghc-8.10.1 -v --lib-only -s build
55+
- name: Validate lib-tests
56+
run: sh validate.sh -j 2 -w ghc-8.10.1 -v --lib-only -s lib-tests
57+
- name: Validate lib-suite
58+
run: sh validate.sh -j 2 -w ghc-8.10.1 -v --lib-only -s lib-suite
2159
validate-8_8_3:
2260
name: validate.sh ghc-8.8.3
2361
runs-on: ubuntu-18.04

Makefile

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -172,5 +172,9 @@ validate-via-docker-8.6.5:
172172
validate-via-docker-8.8.1:
173173
docker build -t cabal-validate -f .docker/validate-8.8.1.dockerfile .
174174

175+
# Only library ATM
176+
validate-via-docker-8.10.1:
177+
docker build -t cabal-validate -f .docker/validate-8.10.1.dockerfile .
178+
175179
validate-via-docker-old:
176180
docker build -t cabal-validate -f .docker/validate-old.dockerfile .

cabal-dev-scripts/src/GenValidate.hs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,8 @@ main = do
2121
-- this shouldn't fail (run-time errors are due bugs in zinza)
2222
w <- run Z
2323
{ zJobs =
24-
[ GhcJob "8.8.3" False "--solver-benchmarks" False [] defSteps
24+
[ GhcJob "8.10.1" False "--lib-only" False ["8.8.3"] libSteps -- Note: only library atm.
25+
, GhcJob "8.8.3" False "--solver-benchmarks" False [] defSteps
2526
, GhcJob "8.6.5" False "" False ["8.8.3"] defSteps
2627
, GhcJob "8.4.4" False "" False ["8.8.3"] defSteps
2728
, GhcJob "8.2.2" False "" False ["8.8.3"] defSteps

cabal-install/Distribution/Client/CmdSdist.hs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -237,7 +237,10 @@ packageToSdist verbosity projectRootDir format outputFile pkg = do
237237
(norm NoExec -> nonexec, norm Exec -> exec) <-
238238
listPackageSources verbosity (flattenPackageDescription $ packageDescription pkg) knownSuffixHandlers
239239

240+
print $ map snd exec
241+
print $ map snd nonexec
240242
let files = nub . sortOn snd $ nonexec ++ exec
243+
print files
241244

242245
case format of
243246
SourceList nulSep -> do

cabal-testsuite/cabal-testsuite.cabal

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ common shared
2626
default-language: Haskell2010
2727

2828
build-depends:
29-
, base >= 4.6 && <4.14
29+
, base >= 4.6 && <4.15
3030
-- this needs to match the in-tree lib:Cabal version
3131
, Cabal == 3.3.0.0
3232

@@ -107,5 +107,5 @@ executable setup
107107

108108
custom-setup
109109
-- we only depend on even stable releases of lib:Cabal
110-
setup-depends: Cabal == 2.2.* || == 2.4.* || == 3.0.*,
110+
setup-depends: Cabal == 2.2.* || == 2.4.* || == 3.0.* || ==3.2.*,
111111
base, filepath, directory

0 commit comments

Comments
 (0)