on d68e23e help sign in
stackage/Stackage/Config.hs
273 lines 9.9 kB history raw
1{-# LANGUAGE CPP #-}
2module Stackage.Config where
4import Control.Monad (when)
5import Control.Monad.Trans.Writer (execWriter, tell)
6import qualified Data.Map as Map
7import Data.Set (fromList)
8import Distribution.Text (simpleParse)
9import Stackage.Types
11-- | Packages which are shipped with GHC but are not included in the
12-- Haskell Platform list of core packages.
13defaultExtraCore :: GhcMajorVersion -> Set PackageName
14defaultExtraCore _ = fromList $ map PackageName $ words
15 "binary Win32"
17-- | Test suites which are expected to fail for some reason. The test suite
18-- will still be run and logs kept, but a failure will not indicate an
19-- error in our package combination.
20defaultExpectedFailures :: GhcMajorVersion
21 -> Set PackageName
22defaultExpectedFailures _ = fromList $ map PackageName
23 [ -- Requires an old version of WAI and Warp for tests
24 "HTTP"
26 -- text and setenv have recursive dependencies in their tests, which
27 -- cabal can't (yet) handle
28 , "text"
29 , "setenv"
31 -- The version of GLUT included with the HP does not generate
32 -- documentation correctly.
33 , "GLUT"
35 -- https://github.com/bos/statistics/issues/42
36 , "statistics"
38 -- https://github.com/kazu-yamamoto/simple-sendfile/pull/10
39 , "simple-sendfile"
41 -- http://hackage.haskell.org/trac/hackage/ticket/954
42 , "diagrams"
44 -- https://github.com/fpco/stackage/issues/24
45 , "unix-time"
47 -- With transformers 0.3, it doesn't provide any modules
48 , "transformers-compat"
50 -- Tests require shell script and are incompatible with sandboxed package
51 -- databases
52 , "HTF"
54 -- https://github.com/simonmar/monad-par/issues/28
55 , "monad-par"
57 -- Unfortunately network failures seem to happen haphazardly
58 , "network"
60 -- https://github.com/ekmett/hyphenation/issues/1
61 , "hyphenation"
63 -- Test suite takes too long to run on some systems
64 , "punycode"
66 -- http://hub.darcs.net/stepcut/happstack/issue/1
67 , "happstack-server"
69 -- Requires a Facebook app.
70 , "fb"
72 -- https://github.com/tibbe/hashable/issues/64
73 , "hashable"
75 -- https://github.com/vincenthz/language-java/issues/10
76 , "language-java"
78 , "threads"
79 , "crypto-conduit"
80 , "pandoc"
81 , "language-ecmascript"
82 , "hspec"
83 , "alex"
85 -- https://github.com/basvandijk/concurrent-extra/issues/
86 , "concurrent-extra"
88 -- https://github.com/rrnewton/haskell-lockfree-queue/issues/7
89 , "abstract-deque"
91 -- https://github.com/skogsbaer/xmlgen/issues/2
92 , "xmlgen"
94 -- Something very strange going on with the test suite, I can't figure
95 -- out how to fix it
96 , "bson"
98 -- Requires a locally running PostgreSQL server with appropriate users
99 , "postgresql-simple"
101 -- https://github.com/IreneKnapp/direct-sqlite/issues/32
102 , "direct-sqlite"
104 -- Missing files
105 , "websockets"
107 -- Some kind of Cabal bug when trying to run tests
108 , "thyme"
109 ]
111-- | List of packages for our stable Hackage. All dependencies will be
112-- included as well. Please indicate who will be maintaining the package
113-- via comments.
114defaultStablePackages :: GhcMajorVersion -> Map PackageName (VersionRange, Maintainer)
115defaultStablePackages ghcVer = unPackageMap $ execWriter $ do
116 mapM_ (add "michael@snoyman.com") $ words =<<
117 [ "yesod yesod-newsfeed yesod-sitemap yesod-static yesod-test yesod-bin"
118 , "markdown filesystem-conduit mime-mail-ses"
119 , "persistent persistent-template persistent-sqlite"
120 , "network-conduit-tls yackage warp-tls keter"
121 , "shakespeare-text process-conduit stm-conduit"
122 , "classy-prelude-yesod yesod-fay yesod-eventsource wai-websockets"
123 , "random-shuffle safe-failure"
124 ]
126 mapM_ (add "FP Complete <michael@fpcomplete.com>") $ words =<<
127 [ "web-fpco th-expand-syns configurator compdata smtLib unification-fd"
128 , "fixed-list indents language-c pretty-class"
129 , "aws yesod-auth-oauth csv-conduit cassava"
130 , "async shelly thyme"
131 , "hxt hxt-relaxng dimensional"
132 , "cairo diagrams-cairo"
133 , "persistent-mongoDB"
134 ]
135 when (ghcVer < GhcMajorVersion 7 6) $ do
136 addRange "FP Complete <michael@fpcomplete.com>" "hxt" "<= 9.3.0.1"
137 addRange "FP Complete <michael@fpcomplete.com>" "shelly" "<= 1.0"
139 -- https://github.com/fpco/stackage/issues/120
140 addRange "FP Complete <michael@fpcomplete.com>" "fay" "< 0.18"
141 addRange "FP Complete <michael@fpcomplete.com>" "fay-base" "< 0.18"
142 when (ghcVer >= GhcMajorVersion 7 6) $ do
143 add "FP Complete <michael@fpcomplete.com>" "repa-devil"
144 addRange "FP Complete <michael@fpcomplete.com>" "kure" "<= 2.4.10"
146 mapM_ (add "Neil Mitchell") $ words
147 "hlint hoogle shake derive"
149 mapM_ (add "Alan Zimmerman") $ words
150 "hjsmin language-javascript"
152 mapM_ (add "Jasper Van der Jeugt") $ words
153 "blaze-html blaze-markup stylish-haskell"
155 mapM_ (add "Antoine Latter") $ words
156 "uuid byteorder"
158 mapM_ (add "Stefan Wehr <wehr@factisresearch.com>") $ words
159 "HTF hscurses xmlgen stm-stats"
161 mapM_ (add "Bart Massey <bart.massey+stackage@gmail.com>") $ words
162 "parseargs"
164 mapM_ (add "Vincent Hanquez") $ words =<<
165 [ "asn1-data bytedump certificate cipher-aes cipher-rc4 connection"
166 , "cprng-aes cpu crypto-pubkey-types crypto-random-api cryptocipher"
167 , "cryptohash hit language-java libgit pem siphash socks tls"
168 , "tls-debug tls-extra vhd"
169 ]
170 addRange "Vincent Hanquez" "language-java" "< 0.2.5"
172#if !defined(mingw32_HOST_OS) && !defined(__MINGW32__)
173 -- Does not compile on Windows
174 mapM_ (add "Vincent Hanquez") $ words "udbus xenstore"
175#endif
177 mapM_ (add "Alberto G. Corona <agocorona@gmail.com>") $ words
178 "RefSerialize TCache Workflow MFlow"
180 mapM_ (add "Edward Kmett <ekmett@gmail.com>") $ words =<<
181 [ "ad adjunctions bifunctors bound categories charset comonad comonad-transformers"
182 , "comonads-fd comonad-extras compressed concurrent-supply constraints contravariant"
183 , "distributive either eq free groupoids heaps hyphenation"
184 , "integration intervals kan-extensions lca lens linear monadic-arrays machines"
185 , "mtl profunctors profunctor-extras reducers reflection"
186 , "representable-functors representable-tries"
187 , "semigroups semigroupoids semigroupoid-extras speculation tagged void"
188 , "graphs monad-products monad-st wl-pprint-extras wl-pprint-terminfo"
189 , "numeric-extras parsers pointed prelude-extras recursion-schemes reducers"
190 , "streams syb-extras vector-instances"
191 ]
193 mapM_ (add "Simon Hengel <sol@typeful.net>") $ words
194 "hspec doctest base-compat"
196 mapM_ (add "Brent Yorgey <byorgey@gmail.com>") $ words =<<
197 [ "monoid-extras dual-tree vector-space-points active force-layout"
198 , "diagrams diagrams-contrib diagrams-core diagrams-lib diagrams-svg"
199 , "diagrams-postscript diagrams-builder diagrams-haddock haxr"
200 , "BlogLiterately BlogLiterately-diagrams"
201 ]
203 mapM_ (add "Patrick Brisbin") $ words "gravatar"
205 mapM_ (add "Felipe Lessa <felipe.lessa@gmail.com>") $ words
206 "esqueleto fb fb-persistent yesod-fb yesod-auth-fb"
208 mapM_ (add "Alexander Altman <alexanderaltman@me.com>") $ words
209 "base-unicode-symbols containers-unicode-symbols"
211 mapM_ (add "Ryan Newton <ryan.newton@alum.mit.edu>") $ words
212 "accelerate"
214 mapM_ (add "Dan Burton <danburton.email@gmail.com>") $ words =<<
215 [ "basic-prelude composition io-memoize numbers rev-state runmemo"
216 , "tardis"
217 ]
219 mapM_ (add "Daniel Díaz <dhelta.diaz@gmail.com>") $ words
220 "HaTeX"
222 mapM_ (add "Adam Bergmark <adam@edea.se>") $ words
223 "fay fay-base"
225 mapM_ (add "Boris Lykah <lykahb@gmail.com>") $ words
226 "groundhog groundhog-th groundhog-sqlite groundhog-postgresql groundhog-mysql"
228 -- https://github.com/fpco/stackage/issues/46
229 addRange "Michael Snoyman" "QuickCheck" "< 2.6"
231 -- https://github.com/fpco/stackage/issues/68
232 addRange "Michael Snoyman" "criterion" "< 0.8"
234 -- https://github.com/fpco/stackage/issues/72
235 addRange "Michael Snoyman" "HaXml" "< 1.24"
237 -- Due to binary package dep
238 addRange "Michael Snoyman" "statistics" "< 0.10.4"
240 -- https://github.com/fpco/stackage/issues/97
241 addRange "Michael Snoyman" "tagsoup" "< 0.13"
243 -- https://github.com/fpco/stackage/issues/107
244 addRange "Michael Snoyman" "split" "< 0.2.2"
246 -- https://github.com/fpco/stackage/issues/113
247 addRange "Michael Snoyman" "pandoc-types" "< 1.12"
249 -- https://github.com/fpco/stackage/issues/115
250 addRange "Michael Snoyman" "pandoc" "< 1.12"
252 -- https://github.com/fpco/stackage/issues/116
253 addRange "Michael Snoyman" "semigroups" "< 0.10"
255 -- https://github.com/fpco/stackage/issues/118
256 addRange "Michael Snoyman" "pem" "< 0.2"
258 -- https://github.com/fpco/stackage/issues/121
259 addRange "Michael Snoyman" "cereal" "< 0.4"
261 addRange "Michael Snoyman" "hashable" "< 1.2"
263 -- Requires binary 0.7
264 addRange "FP Complete <michael@fpcomplete.com>" "bson" "< 0.2.3"
266 -- unknown symbol `utf8_table4'
267 addRange "Michael Snoyman" "regex-pcre-builtin" "< 0.94.4.6.8.31"
268 where
269 add maintainer package = addRange maintainer package "-any"
270 addRange maintainer package range =
271 case simpleParse range of
272 Nothing -> error $ "Invalid range " ++ show range ++ " for " ++ package
273 Just range' -> tell $ PackageMap $ Map.singleton (PackageName package) (range', Maintainer maintainer)