2module Stackage.Config where
4import Control.Monad (when)
5import Control.Monad.Trans.Writer (execWriter, tell)
6import Data.Char (toLower)
7import qualified Data.Map as Map
8import Data.Maybe (fromMaybe)
9import Data.Set (fromList, singleton)
10import Distribution.Text (simpleParse)
13-- | Packages which are shipped with GHC but are not included in the
14-- Haskell Platform list of core packages.
15defaultExtraCore :: GhcMajorVersion -> Set PackageName
16defaultExtraCore _ = fromList $ map PackageName $ words
17 "binary Win32 ghc-prim integer-gmp"
19-- | Test suites which are expected to fail for some reason. The test suite
20-- will still be run and logs kept, but a failure will not indicate an
21-- error in our package combination.
22defaultExpectedFailures :: GhcMajorVersion
24defaultExpectedFailures ghcVer = execWriter $ do
25 -- Requires an old version of WAI and Warp for tests
28 -- text and setenv have recursive dependencies in their tests, which
29 -- cabal can't (yet) handle
33 -- The version of GLUT included with the HP does not generate
34 -- documentation correctly.
37 -- https://github.com/bos/statistics/issues/42
40 -- https://github.com/kazu-yamamoto/simple-sendfile/pull/10
43 -- http://hackage.haskell.org/trac/hackage/ticket/954
46 -- https://github.com/fpco/stackage/issues/24
49 -- With transformers 0.3, it doesn't provide any modules
50 add "transformers-compat"
52 -- Tests require shell script and are incompatible with sandboxed package
56 -- https://github.com/simonmar/monad-par/issues/28
59 -- Unfortunately network failures seem to happen haphazardly
62 -- https://github.com/ekmett/hyphenation/issues/1
65 -- Test suite takes too long to run on some systems
68 -- http://hub.darcs.net/stepcut/happstack/issue/1
69 add "happstack-server"
71 -- Requires a Facebook app.
74 -- https://github.com/tibbe/hashable/issues/64
77 -- https://github.com/vincenthz/language-java/issues/10
83 add "language-ecmascript"
87 -- https://github.com/basvandijk/concurrent-extra/issues/
88 add "concurrent-extra"
90 -- https://github.com/skogsbaer/xmlgen/issues/2
93 -- Something very strange going on with the test suite, I can't figure
97 -- Requires a locally running PostgreSQL server with appropriate users
98 add "postgresql-simple"
103 -- Some kind of Cabal bug when trying to run tests
106 when (ghcVer < GhcMajorVersion 7 6) $ do
107 -- https://github.com/haskell-suite/haskell-names/issues/39
112 -- https://github.com/jgm/pandoc-citeproc/issues/5
113 add "pandoc-citeproc"
115 -- Problems with doctest and sandboxing
119 -- https://github.com/fpco/stackage/issues/163
123 -- FIXME the test suite fails fairly regularly in builds, though I haven't
124 -- discovered why yet
127 -- Test suite is currently failing regularly, needs to be worked out still.
130 -- Requires too old a version of test-framework
133 -- No code included any more, therefore Haddock fails
134 mapM_ add $ words =<<
135 [ "comonad-transformers comonads-fd groupoids"
136 , "profunctor-extras semigroupoid-extras"
137 , "hamlet shakespeare-css shakespeare-i18n"
138 , "shakespeare-js shakespeare-text"
139 , "attoparsec-conduit blaze-builder-conduit http-client-conduit"
140 , "network-conduit zlib-conduit http-client-multipart"
141 , "wai-eventsource wai-test"
144 -- Cloud Haskell tests seem to be unreliable
145 mapM_ add $ words =<<
146 [ "distributed-process lockfree-queue network-transport-tcp"
149 -- Pulls in monad-peel which does not compile
150 when (ghcVer >= GhcMajorVersion 7 8) $ add "monad-control"
152 -- issues with pthread
153 mapM_ add $ words "hlibgit2 gitlib-s3 gitlib-libgit2"
155 -- https://github.com/fpco/stackage/issues/226
158 -- Requires too high a bytestring
159 when (ghcVer <= GhcMajorVersion 7 4) $ add "scientific"
161 -- https://github.com/gtk2hs/gtk2hs/issues/36
165 -- https://github.com/acw/bytestring-progress/issues/3
166 add "bytestring-progress"
168 -- Seems to require 32-bit functions
171 -- Depends on a missing graphviz executable
174 -- https://github.com/silkapp/json-schema/issues/8
175 when (ghcVer <= GhcMajorVersion 7 6) $
179 add = tell . singleton . PackageName
181-- | List of packages for our stable Hackage. All dependencies will be
182-- included as well. Please indicate who will be maintaining the package
184defaultStablePackages :: GhcMajorVersion
185 -> Bool -- ^ using haskell platform?
186 -> Map PackageName (VersionRange, Maintainer)
187defaultStablePackages ghcVer requireHP = unPackageMap $ execWriter $ do
188 mapM_ (add "michael@snoyman.com") $ words =<<
189 [ "yesod yesod-newsfeed yesod-sitemap yesod-static yesod-test yesod-bin"
190 , "markdown mime-mail-ses"
191 , "persistent persistent-template persistent-sqlite"
192 , "network-conduit-tls yackage warp-tls keter"
193 , "process-conduit stm-conduit"
194 , "classy-prelude-yesod yesod-fay yesod-eventsource wai-websockets"
195 , "random-shuffle hebrew-time"
196 , "bzlib-conduit case-insensitive"
197 , "conduit-extra conduit-combinators yesod-websockets"
200 -- https://github.com/fpco/stackage/issues/261
201 addRange "Michael Snoyman" "cabal-install" $
204 | ghcVer <= GhcMajorVersion 7 4 -> "< 1.15"
205 | ghcVer <= GhcMajorVersion 7 6 -> "< 1.17"
206 | ghcVer <= GhcMajorVersion 7 8 -> "< 1.19"
207 | otherwise -> "-any"
209 when (ghcVer >= GhcMajorVersion 7 6) $ add "michael@snoyman.com" "cabal-src"
210#if !defined(mingw32_HOST_OS) && !defined(__MINGW32__)
211 -- Does not compile on Windows
212 mapM_ (add "michael@snoyman.com") $ words "judy"
215 mapM_ (add "FP Complete <michael@fpcomplete.com>") $ words =<<
216 [ "web-fpco th-expand-syns configurator smtLib"
217 , "fixed-list indents language-c pretty-class"
218 , "aws csv-conduit cassava"
219 , "async shelly thyme"
220 , "hxt hxt-relaxng dimensional"
221 , "cairo diagrams-cairo gtk2hs-buildtools"
222 , "persistent-mongoDB fpco-api"
223 , "base16-bytestring convertible"
224 , "compdata hybrid-vectors"
225 , "executable-path formatting quandl-api"
228 when (ghcVer < GhcMajorVersion 7 8) $ do -- No GHC 7.8 support
229 mapM_ (add "FP Complete <michael@fpcomplete.com>") $ words =<<
230 [ "" -- too unreliable for the moment "distributed-process distributed-process-simplelocalnet"
231 , "threepenny-gui unification-fd"
233 addRange "FP Complete <michael@fpcomplete.com>" "compdata" "< 0.8"
234 when (ghcVer >= GhcMajorVersion 7 8) $
235 mapM_ (add "FP Complete <michael@fpcomplete.com>") $ words =<<
239 -- Deprecated version
240 addRange "FP Complete <michael@fpcomplete.com>" "persistent-mongoDB" "< 1.3.1 || > 1.3.1"
241 when (ghcVer < GhcMajorVersion 7 6) $ do
243 addRange "FP Complete <michael@fpcomplete.com>" "hxt" "<= 9.3.0.1"
244 addRange "FP Complete <michael@fpcomplete.com>" "shelly" "<= 1.0"
245 addRange "FP Complete <michael@fpcomplete.com>" "lockfree-queue" "== 0.2"
246 -- when (ghcVer == GhcMajorVersion 7 6) $ do -- No GHC 7.8 support
247 -- add "FP Complete <michael@fpcomplete.com>" "repa-devil"
248 addRange "FP Complete <michael@fpcomplete.com>" "kure" "<= 2.4.10"
250 mapM_ (add "Neil Mitchell") $ words
251 "hlint hoogle shake derive tagsoup cmdargs safe uniplate nsis"
253 mapM_ (add "Alan Zimmerman") $ words
254 "hjsmin language-javascript"
255 -- Requires newer alex than provided with HP
256 when (ghcVer == GhcMajorVersion 7 4 && requireHP) $
257 addRange "Alan Zimmerman" "language-javascript" "== 0.5.9"
259 mapM_ (add "Jasper Van der Jeugt") $ words
260 "blaze-html blaze-markup stylish-haskell"
262 mapM_ (add "Antoine Latter") $ words
265 mapM_ (add "Stefan Wehr <wehr@factisresearch.com>") $ words
266 "HTF xmlgen stm-stats"
267 when (ghcVer < GhcMajorVersion 7 8) $ add "Stefan Wehr <wehr@factisresearch.com>" "hscurses"
269 mapM_ (add "Bart Massey <bart.massey+stackage@gmail.com>") $ words
272 mapM_ (add "Vincent Hanquez") $ words =<<
273 [ "bytedump certificate cipher-aes cipher-rc4 connection"
274 , "cprng-aes cpu crypto-pubkey-types crypto-random-api cryptocipher"
275 , "cryptohash hit language-java libgit pem siphash socks tls"
276 , "tls-debug vhd language-java"
279 mapM_ (add "Chris Done") $ words
282#if !defined(mingw32_HOST_OS) && !defined(__MINGW32__)
283 -- Does not compile on Windows
284 mapM_ (add "Vincent Hanquez") $ words "udbus xenstore"
287 when (ghcVer < GhcMajorVersion 7 8) $
288 mapM_ (add "Alberto G. Corona <agocorona@gmail.com>") $ words
289 "RefSerialize TCache Workflow MFlow"
291 mapM_ (add "Edward Kmett <ekmett@gmail.com>") $ words =<<
292 [ "ad adjunctions bifunctors bound charset comonad comonad-transformers"
293 , "comonads-fd compressed concurrent-supply constraints contravariant"
294 , "distributive either eq free groupoids heaps hyphenation"
295 , "integration intervals kan-extensions lca lens linear monadic-arrays machines"
296 , "mtl profunctors profunctor-extras reducers reflection"
297 , "semigroups semigroupoids semigroupoid-extras speculation tagged void"
298 , "graphs monad-products monad-st wl-pprint-extras wl-pprint-terminfo"
299 , "numeric-extras parsers pointed prelude-extras reducers"
300 , "streams vector-instances"
302 when (ghcVer < GhcMajorVersion 7 8) $
303 mapM_ (add "Edward Kmett <ekmett@gmail.com>") $ words =<<
304 [ "categories comonad-extras recursion-schemes syb-extras"
307 when (ghcVer >= GhcMajorVersion 7 6) $
308 mapM_ (add "Andrew Farmer <afarmer@ittc.ku.edu>") $ words
309 "scotty wai-middleware-static"
311 mapM_ (add "Simon Hengel <sol@typeful.net>") $ words
312 "hspec doctest base-compat"
314 mapM_ (add "Mario Blazevic <blamario@yahoo.com>") $ words
315 "monad-parallel monad-coroutine"
316 -- https://github.com/blamario/monoid-subclasses/issues/3
317 when (ghcVer >= GhcMajorVersion 7 6) $ do
318 mapM_ (add "Mario Blazevic <blamario@yahoo.com>") $ words
319 "incremental-parser monoid-subclasses"
321 mapM_ (add "Brent Yorgey <byorgey@gmail.com>") $ words =<<
322 [ "monoid-extras dual-tree vector-space-points active force-layout"
323 , "diagrams diagrams-contrib diagrams-core diagrams-lib diagrams-svg"
324 , "diagrams-postscript diagrams-builder diagrams-haddock haxr"
325 , "BlogLiterately BlogLiterately-diagrams"
328 mapM_ (add "Vincent Berthoux <vincent.berthoux@gmail.com>") $ words
331 mapM_ (add "Patrick Brisbin") $ words "gravatar"
333 mapM_ (add "Felipe Lessa <felipe.lessa@gmail.com>") $ words
334 "esqueleto fb fb-persistent yesod-fb yesod-auth-fb"
336 mapM_ (add "Alexander Altman <alexanderaltman@me.com>") $ words
337 "base-unicode-symbols containers-unicode-symbols"
339 -- NOTE: accelerate not yet supported on GHC 7.8
340 when (ghcVer == GhcMajorVersion 7 6) $ do
341 mapM_ (add "Ryan Newton <ryan.newton@alum.mit.edu>") $ words
343 when (ghcVer < GhcMajorVersion 7 6) $ do
344 addRange "Ryan Newton <ryan.newton@alum.mit.edu>" "accelerate" "< 0.14"
345 addRange "Ryan Newton <ryan.newton@alum.mit.edu>" "fclabels" "< 2.0"
347 mapM_ (add "Dan Burton <danburton.email@gmail.com>") $ words =<<
348 [ "basic-prelude composition io-memoize numbers rev-state runmemo"
349 , "tardis lens-family-th"
352 mapM_ (add "Daniel Díaz <dhelta.diaz@gmail.com>") $ words
355 mapM_ (add "Gabriel Gonzalez <Gabriel439@gmail.com>")
356 ["pipes", "pipes-parse", "pipes-concurrency"]
358 mapM_ (add "Adam Bergmark <adam@bergmark.nl>") $ words
359 "fay fay-base fay-dom fay-jquery fay-text fay-uri snaplet-fay"
361 mapM_ (add "Boris Lykah <lykahb@gmail.com>") $ words
362 "groundhog groundhog-th groundhog-sqlite groundhog-postgresql groundhog-mysql"
364 mapM_ (add "Janne Hellsten <jjhellst@gmail.com>") $ words
367 mapM_ (add "Michal J. Gajda") $ words
368 "iterable Octree FenwickTree hPDB"
369 when (ghcVer == GhcMajorVersion 7 6) $ do -- No GHC 7.8 support
370 mapM_ (add "Michal J. Gajda") $ words
373 mapM_ (add "Roman Cheplyaka <roma@ro-che.info>") $ words =<<
374 [ "smallcheck tasty tasty-smallcheck tasty-quickcheck tasty-hunit tasty-golden"
375 , "traverse-with-class regex-applicative time-lens"
376 , "haskell-names haskell-packages hse-cpp"
379 mapM_ (add "George Giorgidze <giorgidze@gmail.com>") $ words
382 when (ghcVer >= GhcMajorVersion 7 6) $ do -- No GHC 7.4 support
383 mapM_ (add "Phil Hargett <phil@haphazardhouse.net>") $ words
386#if !defined(mingw32_HOST_OS) && !defined(__MINGW32__)
387 mapM_ (add "Aycan iRiCAN <iricanaycan@gmail.com>") $ words
388 "hdaemonize hsyslog hweblib"
390 mapM_ (add "Aycan iRiCAN <iricanaycan@gmail.com>") $ words
394 mapM_ (add "Joachim Breitner <mail@joachim-breitner.de>") $ words
395 "circle-packing arbtt"
397 when (ghcVer < GhcMajorVersion 7 8) $
398 mapM_ (add "John Wiegley") $ words =<<
399 -- Removed these: bad semigroups upper bound
400 [ "bindings-DSL github monad-extras numbers hlibgit2"
401 , "gitlib gitlib-cmdline gitlib-test"
403 -- https://github.com/jwiegley/gitlib/issues/31
407 mapM_ (add "Ben Ford <ben@dlstartup.com") $ words
410 mapM_ (add "Clint Adams <clint@debian.org>") $ words
411 "DAV hOpenPGP hopenpgp-tools openpgp-asciiarmor MusicBrainz"
413 -- https://github.com/fpco/stackage/issues/160
414 when (ghcVer >= GhcMajorVersion 7 6) $ do
415 mapM_ (add "Ketil Malde") $ words =<<
416 [ "biocore biofasta biofastq biosff"
417 , "blastxml bioace biophd"
418 , "biopsl" -- https://github.com/ingolia/SamTools/issues/3 samtools
419 , "seqloc bioalign BlastHTTP"
420 -- The following have out-of-date dependencies currently
421 -- biostockholm memexml RNAwolf
422 -- , "Biobase BiobaseDotP BiobaseFR3D BiobaseInfernal BiobaseMAF"
423 -- , "BiobaseTrainingData BiobaseTurner BiobaseXNA BiobaseVienna"
424 -- , "BiobaseTypes BiobaseFasta"
427 -- https://github.com/fpco/stackage/issues/163
428 addRange "Michael Snoyman" "biophd" "< 0.0.6 || > 0.0.6"
429 when (ghcVer == GhcMajorVersion 7 6) $ do
430 mapM_ (add "Ketil Malde") $ words =<<
435 mapM_ (add "Silk <code@silk.co>") $ words =<<
436 [ "aeson-utils arrow-list attoparsec-expr bumper code-builder fay-builder"
437 , "generic-aeson hxt-pickle-utils json-schema multipart regular-xmlpickler"
438 , "rest-client rest-core rest-gen rest-happstack rest-snap rest-stringmap"
439 , "rest-types rest-wai tostring uri-encode imagesize-conduit"
442 mapM_ (add "Simon Michael <simon@joyful.com>") $ words
445 mapM_ (add "Mihai Maruseac <mihai.maruseac@gmail.com>") $ words
448 -- Newest hxt requires network 2.4 or newest
449 when (ghcVer == GhcMajorVersion 7 4 && requireHP) $ do
450 addRange "Michael Snoyman" "hxt" "< 9.3.1"
451 addRange "Michael Snoyman" "network" "< 2.4"
453 -- https://github.com/fpco/stackage/issues/197
454 when (ghcVer == GhcMajorVersion 7 6 && requireHP) $
455 addRange "Michael Snoyman" "parsers" "< 0.11"
457 -- https://github.com/fpco/stackage/issues/216
458 -- QuickCheck constraint
459 -- when (ghcVer == GhcMajorVersion 7 6) $
460 -- addRange "Michael Snoyman" "repa" "< 3.2.5.1"
462 -- https://github.com/fpco/stackage/issues/217
463 addRange "Michael Snoyman" "transformers" "< 0.4"
464 addRange "Michael Snoyman" "mtl" "< 2.2"
465 addRange "Michael Snoyman" "lifted-base" "< 0.2.2.2"
467 -- https://github.com/fpco/stackage/issues/224
468 when (ghcVer <= GhcMajorVersion 7 6) $ do
469 addRange "Michael Snoyman" "zip-archive" "== 0.2.2.1"
471 -- https://github.com/fpco/stackage/issues/231
472 addRange "Michael Snoyman" "optparse-applicative" "< 0.9"
474 -- https://github.com/fpco/stackage/issues/242
475 addRange "Michael Snoyman" "mongoDB" "< 1.6"
477 -- https://github.com/jgm/pandoc/issues/1442
478 addRange "Michael Snoyman" "texmath" "<= 0.6.6.3"
480 -- Requires too new a version of text
481 when (ghcVer == GhcMajorVersion 7 4 && requireHP) $ do
482 addRange "Michael Snoyman" "attoparsec" "< 0.11.2.1"
483 addRange "Michael Snoyman" "parsers" "< 0.11"
486 addRange "Michael Snoyman" "bson" "== 0.2.4"
488 -- 0.16.2 fixes dependency issues with different version of GHC
489 -- and Haskell Platform. Now builds on GHC 7.4-7.8. Version 1.0 is
490 -- guaranteed to break the API. See
491 -- https://travis-ci.org/jswebtools/language-ecmascript for
492 -- current build status.
493 addRange "Andrey Chudnov <oss@chudnov.com>" "language-ecmascript" ">= 0.16.2 && < 1.0"
495 -- https://github.com/fpco/stackage/issues/269
496 addRange "Michael Snoyman" "tasty-hunit" "< 0.9"
498 -- https://github.com/fpco/stackage/issues/271
499 when (ghcVer < GhcMajorVersion 7 8) $
500 addRange "Michael Snoyman" "aeson" "< 0.8"
502 -- https://github.com/fpco/stackage/issues/274
503 addRange "Michael Snoyman" "pandoc-citeproc" "< 0.4"
505 -- https://github.com/fpco/stackage/issues/276
506 addRange "Michael Snoyman" "network" "< 2.6"
508 -- https://github.com/fpco/stackage/issues/277
509 addRange "Michael Snoyman" "pandoc" "< 1.13"
511 add maintainer package = addRange maintainer package "-any"
512 addRange maintainer package range =
513 case simpleParse range of
514 Nothing -> error $ "Invalid range " ++ show range ++ " for " ++ package
515 Just range' -> tell $ PackageMap $ Map.singleton (PackageName package) (range', Maintainer maintainer)
517-- | Replacement Github users. This is useful when a project is owned by an
518-- organization. It also lets you ping multiple users.
520-- Note that cross organization team mentions aren't allowed by Github.
521convertGithubUser :: String -> [String]
523 fromMaybe [x] $ Map.lookup (map toLower x) pairs
526 [ ("diagrams", ["byorgey", "fryguybob", "jeffreyrosenbluth", "bergey"])
527 , ("yesodweb", ["snoyberg"])
528 , ("fpco", ["snoyberg"])
529 , ("faylang", ["bergmark"])
530 , ("silkapp", ["bergmark"])
531 , ("snapframework",["mightybyte"])
532 , ("haskell-ro", ["mihaimaruseac"])
keysesc to close
- j k
- move down, up
- enter
- open
- esc
- back, or up a level
- 1 2 3 4
- readme, files, commits, refs
- /
- filter
- y
- copy the clone command
- c
- compare the chosen commit with another (or shift-click both)
- ?
- show or hide this list