Skip to content

Commit ab5ec10

Browse files
authored
Merge pull request #8 from phadej/ghc-8.10
Allow base-4.14
2 parents a3f1fcd + ce186d2 commit ab5ec10

File tree

3 files changed

+58
-52
lines changed

3 files changed

+58
-52
lines changed

.travis.yml

Lines changed: 52 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,11 @@
44
#
55
# For more information, see https://github.com/haskell-CI/haskell-ci
66
#
7-
# version: 0.5.20190916
7+
# version: 0.9.20200326
88
#
9+
version: ~> 1.0
910
language: c
11+
os: linux
1012
dist: xenial
1113
git:
1214
# whether to recursively clone submodules
@@ -15,6 +17,7 @@ cache:
1517
directories:
1618
- $HOME/.cabal/packages
1719
- $HOME/.cabal/store
20+
- $HOME/.hlint
1821
before_cache:
1922
- rm -fv $CABALHOME/packages/hackage.haskell.org/build-reports.log
2023
# remove files that are regenerated by 'cabal update'
@@ -24,32 +27,47 @@ before_cache:
2427
- rm -fv $CABALHOME/packages/hackage.haskell.org/01-index.tar
2528
- rm -fv $CABALHOME/packages/hackage.haskell.org/01-index.tar.idx
2629
- rm -rfv $CABALHOME/packages/head.hackage
27-
matrix:
30+
jobs:
2831
include:
29-
- compiler: ghc-8.8.1
30-
addons: {"apt":{"sources":["hvr-ghc"],"packages":["ghc-8.8.1","cabal-install-3.0"]}}
32+
- compiler: ghc-8.10.1
33+
addons: {"apt":{"sources":[{"sourceline":"deb http://ppa.launchpad.net/hvr/ghc/ubuntu xenial main","key_url":"https://keyserver.ubuntu.com/pks/lookup?op=get&search=0x063dab2bdc0b3f9fcebc378bff3aeacef6f88286"}],"packages":["ghc-8.10.1","cabal-install-3.2"]}}
34+
os: linux
35+
- compiler: ghc-8.8.3
36+
addons: {"apt":{"sources":[{"sourceline":"deb http://ppa.launchpad.net/hvr/ghc/ubuntu xenial main","key_url":"https://keyserver.ubuntu.com/pks/lookup?op=get&search=0x063dab2bdc0b3f9fcebc378bff3aeacef6f88286"}],"packages":["ghc-8.8.3","cabal-install-3.0"]}}
37+
os: linux
3138
- compiler: ghc-8.6.5
32-
addons: {"apt":{"sources":["hvr-ghc"],"packages":["ghc-8.6.5","cabal-install-3.0"]}}
39+
addons: {"apt":{"sources":[{"sourceline":"deb http://ppa.launchpad.net/hvr/ghc/ubuntu xenial main","key_url":"https://keyserver.ubuntu.com/pks/lookup?op=get&search=0x063dab2bdc0b3f9fcebc378bff3aeacef6f88286"}],"packages":["ghc-8.6.5","cabal-install-3.0"]}}
40+
os: linux
3341
- compiler: ghc-8.4.4
34-
addons: {"apt":{"sources":["hvr-ghc"],"packages":["ghc-8.4.4","cabal-install-3.0"]}}
42+
addons: {"apt":{"sources":[{"sourceline":"deb http://ppa.launchpad.net/hvr/ghc/ubuntu xenial main","key_url":"https://keyserver.ubuntu.com/pks/lookup?op=get&search=0x063dab2bdc0b3f9fcebc378bff3aeacef6f88286"}],"packages":["ghc-8.4.4","cabal-install-3.0"]}}
43+
os: linux
3544
- compiler: ghc-8.2.2
36-
addons: {"apt":{"sources":["hvr-ghc"],"packages":["ghc-8.2.2","cabal-install-3.0"]}}
45+
addons: {"apt":{"sources":[{"sourceline":"deb http://ppa.launchpad.net/hvr/ghc/ubuntu xenial main","key_url":"https://keyserver.ubuntu.com/pks/lookup?op=get&search=0x063dab2bdc0b3f9fcebc378bff3aeacef6f88286"}],"packages":["ghc-8.2.2","cabal-install-3.0"]}}
46+
os: linux
3747
- compiler: ghc-8.0.2
38-
addons: {"apt":{"sources":["hvr-ghc"],"packages":["ghc-8.0.2","cabal-install-3.0"]}}
48+
addons: {"apt":{"sources":[{"sourceline":"deb http://ppa.launchpad.net/hvr/ghc/ubuntu xenial main","key_url":"https://keyserver.ubuntu.com/pks/lookup?op=get&search=0x063dab2bdc0b3f9fcebc378bff3aeacef6f88286"}],"packages":["ghc-8.0.2","cabal-install-3.0"]}}
49+
os: linux
3950
- compiler: ghc-7.10.3
40-
addons: {"apt":{"sources":["hvr-ghc"],"packages":["ghc-7.10.3","cabal-install-3.0"]}}
51+
addons: {"apt":{"sources":[{"sourceline":"deb http://ppa.launchpad.net/hvr/ghc/ubuntu xenial main","key_url":"https://keyserver.ubuntu.com/pks/lookup?op=get&search=0x063dab2bdc0b3f9fcebc378bff3aeacef6f88286"}],"packages":["ghc-7.10.3","cabal-install-3.0"]}}
52+
os: linux
4153
- compiler: ghc-7.8.4
42-
addons: {"apt":{"sources":["hvr-ghc"],"packages":["ghc-7.8.4","cabal-install-3.0"]}}
54+
addons: {"apt":{"sources":[{"sourceline":"deb http://ppa.launchpad.net/hvr/ghc/ubuntu xenial main","key_url":"https://keyserver.ubuntu.com/pks/lookup?op=get&search=0x063dab2bdc0b3f9fcebc378bff3aeacef6f88286"}],"packages":["ghc-7.8.4","cabal-install-3.0"]}}
55+
os: linux
4356
- compiler: ghc-7.6.3
44-
addons: {"apt":{"sources":["hvr-ghc"],"packages":["ghc-7.6.3","cabal-install-3.0"]}}
57+
addons: {"apt":{"sources":[{"sourceline":"deb http://ppa.launchpad.net/hvr/ghc/ubuntu xenial main","key_url":"https://keyserver.ubuntu.com/pks/lookup?op=get&search=0x063dab2bdc0b3f9fcebc378bff3aeacef6f88286"}],"packages":["ghc-7.6.3","cabal-install-3.0"]}}
58+
os: linux
4559
- compiler: ghc-7.4.2
46-
addons: {"apt":{"sources":["hvr-ghc"],"packages":["ghc-7.4.2","cabal-install-3.0"]}}
60+
addons: {"apt":{"sources":[{"sourceline":"deb http://ppa.launchpad.net/hvr/ghc/ubuntu xenial main","key_url":"https://keyserver.ubuntu.com/pks/lookup?op=get&search=0x063dab2bdc0b3f9fcebc378bff3aeacef6f88286"}],"packages":["ghc-7.4.2","cabal-install-3.0"]}}
61+
os: linux
4762
- compiler: ghc-7.2.2
48-
addons: {"apt":{"sources":["hvr-ghc"],"packages":["ghc-7.2.2","cabal-install-3.0"]}}
63+
addons: {"apt":{"sources":[{"sourceline":"deb http://ppa.launchpad.net/hvr/ghc/ubuntu xenial main","key_url":"https://keyserver.ubuntu.com/pks/lookup?op=get&search=0x063dab2bdc0b3f9fcebc378bff3aeacef6f88286"}],"packages":["ghc-7.2.2","cabal-install-3.0"]}}
64+
os: linux
4965
- compiler: ghc-7.0.4
50-
addons: {"apt":{"sources":["hvr-ghc"],"packages":["ghc-7.0.4","cabal-install-3.0"]}}
66+
addons: {"apt":{"sources":[{"sourceline":"deb http://ppa.launchpad.net/hvr/ghc/ubuntu xenial main","key_url":"https://keyserver.ubuntu.com/pks/lookup?op=get&search=0x063dab2bdc0b3f9fcebc378bff3aeacef6f88286"}],"packages":["ghc-7.0.4","cabal-install-3.0"]}}
67+
os: linux
5168
- compiler: ghc-head
52-
addons: {"apt":{"sources":["hvr-ghc"],"packages":["ghc-head","cabal-install-head"]}}
69+
addons: {"apt":{"sources":[{"sourceline":"deb http://ppa.launchpad.net/hvr/ghc/ubuntu xenial main","key_url":"https://keyserver.ubuntu.com/pks/lookup?op=get&search=0x063dab2bdc0b3f9fcebc378bff3aeacef6f88286"}],"packages":["ghc-head","cabal-install-head"]}}
70+
os: linux
5371
allow_failures:
5472
- compiler: ghc-head
5573
before_install:
@@ -64,33 +82,12 @@ before_install:
6482
- TOP=$(pwd)
6583
- "HCNUMVER=$(${HC} --numeric-version|perl -ne '/^(\\d+)\\.(\\d+)\\.(\\d+)(\\.(\\d+))?$/; print(10000 * $1 + 100 * $2 + ($3 == 0 ? $5 != 1 : $3))')"
6684
- echo $HCNUMVER
67-
- CABAL="$CABAL -vnormal+nowrap+markoutput"
85+
- CABAL="$CABAL -vnormal+nowrap"
6886
- set -o pipefail
69-
- |
70-
echo 'function blue(s) { printf "\033[0;34m" s "\033[0m " }' >> .colorful.awk
71-
echo 'BEGIN { state = "output"; }' >> .colorful.awk
72-
echo '/^-----BEGIN CABAL OUTPUT-----$/ { state = "cabal" }' >> .colorful.awk
73-
echo '/^-----END CABAL OUTPUT-----$/ { state = "output" }' >> .colorful.awk
74-
echo '!/^(-----BEGIN CABAL OUTPUT-----|-----END CABAL OUTPUT-----)/ {' >> .colorful.awk
75-
echo ' if (state == "cabal") {' >> .colorful.awk
76-
echo ' print blue($0)' >> .colorful.awk
77-
echo ' } else {' >> .colorful.awk
78-
echo ' print $0' >> .colorful.awk
79-
echo ' }' >> .colorful.awk
80-
echo '}' >> .colorful.awk
81-
- cat .colorful.awk
82-
- |
83-
color_cabal_output () {
84-
awk -f $TOP/.colorful.awk
85-
}
86-
- echo text | color_cabal_output
87-
install:
88-
- ${CABAL} --version
89-
- echo "$(${HC} --version) [$(${HC} --print-project-git-commit-id 2> /dev/null || echo '?')]"
9087
- TEST=--enable-tests
9188
- BENCH=--enable-benchmarks
9289
- HEADHACKAGE=false
93-
- if [ $HCNUMVER -gt 80801 ] ; then HEADHACKAGE=true ; fi
90+
- if [ $HCNUMVER -gt 81001 ] ; then HEADHACKAGE=true ; fi
9491
- rm -f $CABALHOME/config
9592
- |
9693
echo "verbose: normal +nowrap +markoutput" >> $CABALHOME/config
@@ -119,6 +116,9 @@ install:
119116
echo " f76d08be13e9a61a377a85e2fb63f4c5435d40f8feb3e12eb05905edb8cdea89" >> $CABALHOME/config
120117
echo " key-threshold: 3" >> $CABALHOME/config
121118
fi
119+
install:
120+
- ${CABAL} --version
121+
- echo "$(${HC} --version) [$(${HC} --print-project-git-commit-id 2> /dev/null || echo '?')]"
122122
- |
123123
echo "program-default-options" >> $CABALHOME/config
124124
echo " ghc-options: $GHCJOBS +RTS -M6G -RTS" >> $CABALHOME/config
@@ -130,20 +130,22 @@ install:
130130
- touch cabal.project
131131
- |
132132
echo "packages: ." >> cabal.project
133+
- if [ $HCNUMVER -ge 80000 ] ; then echo 'package postgresql-libpq' >> cabal.project ; fi
134+
- "if [ $HCNUMVER -ge 80000 ] ; then echo ' ghc-options: -Werror=missing-methods' >> cabal.project ; fi"
133135
- |
134136
- "for pkg in $($HCPKG list --simple-output); do echo $pkg | sed 's/-[^-]*$//' | (grep -vE -- '^(postgresql-libpq)$' || true) | sed 's/^/constraints: /' | sed 's/$/ installed/' >> cabal.project.local; done"
135137
- cat cabal.project || true
136138
- cat cabal.project.local || true
137139
- if [ -f "./configure.ac" ]; then (cd "." && autoreconf -i); fi
138-
- ${CABAL} v2-freeze $WITHCOMPILER ${TEST} ${BENCH} | color_cabal_output
140+
- ${CABAL} v2-freeze $WITHCOMPILER ${TEST} ${BENCH}
139141
- "cat cabal.project.freeze | sed -E 's/^(constraints: *| *)//' | sed 's/any.//'"
140142
- rm cabal.project.freeze
141-
- ${CABAL} v2-build $WITHCOMPILER ${TEST} ${BENCH} --dep -j2 all | color_cabal_output
142-
- ${CABAL} v2-build $WITHCOMPILER --disable-tests --disable-benchmarks --dep -j2 all | color_cabal_output
143+
- travis_wait 40 ${CABAL} v2-build $WITHCOMPILER ${TEST} ${BENCH} --dep -j2 all
144+
- travis_wait 40 ${CABAL} v2-build $WITHCOMPILER --disable-tests --disable-benchmarks --dep -j2 all
143145
script:
144146
- DISTDIR=$(mktemp -d /tmp/dist-test.XXXX)
145147
# Packaging...
146-
- ${CABAL} v2-sdist all | color_cabal_output
148+
- ${CABAL} v2-sdist all
147149
# Unpacking...
148150
- mv dist-newstyle/sdist/*.tar.gz ${DISTDIR}/
149151
- cd ${DISTDIR} || false
@@ -155,25 +157,27 @@ script:
155157
- touch cabal.project
156158
- |
157159
echo "packages: ${PKGDIR_postgresql_libpq}" >> cabal.project
160+
- if [ $HCNUMVER -ge 80000 ] ; then echo 'package postgresql-libpq' >> cabal.project ; fi
161+
- "if [ $HCNUMVER -ge 80000 ] ; then echo ' ghc-options: -Werror=missing-methods' >> cabal.project ; fi"
158162
- |
159163
- "for pkg in $($HCPKG list --simple-output); do echo $pkg | sed 's/-[^-]*$//' | (grep -vE -- '^(postgresql-libpq)$' || true) | sed 's/^/constraints: /' | sed 's/$/ installed/' >> cabal.project.local; done"
160164
- cat cabal.project || true
161165
- cat cabal.project.local || true
162166
# Building...
163167
# this builds all libraries and executables (without tests/benchmarks)
164-
- ${CABAL} v2-build $WITHCOMPILER --disable-tests --disable-benchmarks all | color_cabal_output
168+
- ${CABAL} v2-build $WITHCOMPILER --disable-tests --disable-benchmarks all
165169
# Building with tests and benchmarks...
166170
# build & run tests, build benchmarks
167-
- ${CABAL} v2-build $WITHCOMPILER ${TEST} ${BENCH} all | color_cabal_output
171+
- ${CABAL} v2-build $WITHCOMPILER ${TEST} ${BENCH} all
168172
# Testing...
169-
- ${CABAL} v2-test $WITHCOMPILER ${TEST} ${BENCH} all | color_cabal_output
173+
- ${CABAL} v2-test $WITHCOMPILER ${TEST} ${BENCH} all
170174
# cabal check...
171175
- (cd ${PKGDIR_postgresql_libpq} && ${CABAL} -vnormal check)
172176
# haddock...
173-
- ${CABAL} v2-haddock $WITHCOMPILER --with-haddock $HADDOCK ${TEST} ${BENCH} all | color_cabal_output
177+
- ${CABAL} v2-haddock $WITHCOMPILER --with-haddock $HADDOCK ${TEST} ${BENCH} all
174178
# Building without installed constraints for packages in global-db...
175179
- rm -f cabal.project.local
176-
- ${CABAL} v2-build $WITHCOMPILER --disable-tests --disable-benchmarks all | color_cabal_output
180+
- ${CABAL} v2-build $WITHCOMPILER --disable-tests --disable-benchmarks all
177181

178-
# REGENDATA ["--output",".travis.yml","--ghc-head","postgresql-libpq.cabal"]
182+
# REGENDATA ("0.9.20200326",["--output",".travis.yml","--ghc-head","postgresql-libpq.cabal"])
179183
# EOF

CONTRIBUTING.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ Patches welcome!
77
- Regenerate `.travis.yml` with `haskell-ci regenerate` (get the latest from [GitHub haskell-ci/haskell-ci](https://github.com/haskell-ci/haskell-ci))
88

99
- Don't edit `CHANGELOG.md`, rather include a copyable entry in your pull request description. I often process pull requests in bulk, and everyone editing the `CHANGELOG.md` causes unnecessary conflicts.
10+
- For the same reason, do not edit `version` or `x-revision`
1011

1112
- I use [`stylish-haskell`](https://github.com/jaspervdj/stylish-haskell) to format imports. I encourage you to use it too, when contributing.
1213
- General code style is 4 spaces, just look around how it looks, it's not so strict.

postgresql-libpq.cabal

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
name: postgresql-libpq
22
version: 0.9.4.2
3-
x-revision: 1
3+
x-revision: 2
44
synopsis: low-level binding to libpq
55
description:
66
This is a binding to libpq: the C application
@@ -34,14 +34,15 @@ tested-with:
3434
|| ==8.2.2
3535
|| ==8.4.4
3636
|| ==8.6.5
37-
|| ==8.8.1
37+
|| ==8.8.3
38+
|| ==8.10.1
3839

3940
extra-source-files: CHANGELOG.md
4041

4142
custom-setup
4243
setup-depends:
4344
base >=4.3 && <5
44-
, Cabal >=1.10 && <3.1
45+
, Cabal >=1.10 && <3.3
4546

4647
-- If true, use pkg-config, otherwise use the pg_config based build
4748
-- configuration
@@ -58,7 +59,7 @@ library
5859
Database.PostgreSQL.LibPQ.Internal
5960

6061
build-depends:
61-
base >=4.3 && <4.14
62+
base >=4.3 && <4.15
6263
, bytestring >=0.9.1.0 && <0.11
6364

6465
if !os(windows)

0 commit comments

Comments
 (0)