2017-08-01 17:44:08 +01:00
|
|
|
{ pkgs, haskellLib }:
|
2015-01-07 19:31:32 +00:00
|
|
|
|
2017-08-01 17:44:08 +01:00
|
|
|
with haskellLib;
|
2015-01-07 19:31:32 +00:00
|
|
|
|
2021-12-24 20:12:56 +00:00
|
|
|
let
|
|
|
|
inherit (pkgs.stdenv.hostPlatform) isDarwin;
|
|
|
|
in
|
|
|
|
|
2015-01-07 19:31:32 +00:00
|
|
|
self: super: {
|
|
|
|
|
2021-11-23 15:11:37 +00:00
|
|
|
llvmPackages = pkgs.lib.dontRecurseIntoAttrs self.ghc.llvmPackages;
|
2015-03-09 19:11:23 +00:00
|
|
|
|
2022-04-08 14:13:52 +01:00
|
|
|
# Disable GHC core libraries.
|
2015-01-07 19:31:32 +00:00
|
|
|
array = null;
|
|
|
|
base = null;
|
|
|
|
binary = null;
|
|
|
|
bytestring = null;
|
|
|
|
Cabal = null;
|
2022-04-08 14:13:52 +01:00
|
|
|
Cabal-syntax = null;
|
2015-01-07 19:31:32 +00:00
|
|
|
containers = null;
|
|
|
|
deepseq = null;
|
|
|
|
directory = null;
|
2022-04-08 14:13:52 +01:00
|
|
|
exceptions = null;
|
2015-01-07 19:31:32 +00:00
|
|
|
filepath = null;
|
2022-04-08 14:13:52 +01:00
|
|
|
ghc-bignum = null;
|
2017-09-01 14:48:53 +01:00
|
|
|
ghc-boot = null;
|
|
|
|
ghc-boot-th = null;
|
|
|
|
ghc-compact = null;
|
2019-01-23 21:56:15 +00:00
|
|
|
ghc-heap = null;
|
|
|
|
ghc-prim = null;
|
2022-04-08 14:13:52 +01:00
|
|
|
ghci = null;
|
2015-01-07 19:31:32 +00:00
|
|
|
haskeline = null;
|
|
|
|
hpc = null;
|
|
|
|
integer-gmp = null;
|
2019-01-23 21:56:15 +00:00
|
|
|
libiserv = null;
|
2018-07-10 00:23:50 +01:00
|
|
|
mtl = null;
|
|
|
|
parsec = null;
|
2015-01-07 19:31:32 +00:00
|
|
|
pretty = null;
|
|
|
|
process = null;
|
|
|
|
rts = null;
|
2018-07-10 00:23:50 +01:00
|
|
|
stm = null;
|
2023-12-18 17:11:54 +00:00
|
|
|
system-cxx-std-lib = null;
|
2015-01-07 19:31:32 +00:00
|
|
|
template-haskell = null;
|
2022-07-25 22:42:29 +01:00
|
|
|
# GHC only builds terminfo if it is a native compiler
|
2023-12-20 09:50:28 +00:00
|
|
|
terminfo = if pkgs.stdenv.hostPlatform == pkgs.stdenv.buildPlatform then null else doDistribute self.terminfo_0_4_1_6;
|
2018-07-10 00:23:50 +01:00
|
|
|
text = null;
|
2015-01-07 19:31:32 +00:00
|
|
|
time = null;
|
|
|
|
transformers = null;
|
|
|
|
unix = null;
|
2023-01-15 20:36:26 +00:00
|
|
|
xhtml = null;
|
2015-01-07 19:31:32 +00:00
|
|
|
|
2024-01-11 14:22:18 +00:00
|
|
|
#
|
2024-01-07 00:42:06 +00:00
|
|
|
# Version upgrades
|
2024-01-11 14:22:18 +00:00
|
|
|
#
|
2024-03-31 17:18:15 +01:00
|
|
|
th-abstraction = doDistribute self.th-abstraction_0_7_0_0;
|
2024-05-17 18:34:43 +01:00
|
|
|
ghc-lib-parser = doDistribute self.ghc-lib-parser_9_10_1_20240511;
|
2024-05-19 12:43:03 +01:00
|
|
|
ghc-lib-parser-ex = doDistribute self.ghc-lib-parser-ex_9_10_0_0;
|
2024-05-17 18:34:43 +01:00
|
|
|
ghc-lib = doDistribute self.ghc-lib_9_10_1_20240511;
|
2024-01-07 00:42:06 +00:00
|
|
|
megaparsec = doDistribute self.megaparsec_9_6_1;
|
2024-03-31 17:18:15 +01:00
|
|
|
# TODO: remove when aeson updates or launches a revision
|
|
|
|
# see https://github.com/haskell/aeson/issues/1089 and https://github.com/haskell/aeson/pulls/1088
|
|
|
|
aeson = doJailbreak (doDistribute self.aeson_2_2_1_0);
|
2024-01-07 00:42:06 +00:00
|
|
|
attoparsec-aeson = doDistribute self.attoparsec-aeson_2_2_0_1;
|
2024-02-26 07:18:32 +00:00
|
|
|
xmonad = doDistribute self.xmonad_0_18_0;
|
2024-03-19 12:34:22 +00:00
|
|
|
apply-refact = self.apply-refact_0_14_0_0;
|
|
|
|
ormolu = self.ormolu_0_7_4_0;
|
|
|
|
fourmolu = self.fourmolu_0_15_0_0;
|
|
|
|
stylish-haskell = self.stylish-haskell_0_14_6_0;
|
|
|
|
hlint = self.hlint_3_8;
|
2024-03-23 11:15:00 +00:00
|
|
|
ghc-syntax-highlighter = self.ghc-syntax-highlighter_0_0_11_0;
|
2019-01-23 21:56:15 +00:00
|
|
|
|
2024-03-19 10:34:44 +00:00
|
|
|
# A given major version of ghc-exactprint only supports one version of GHC.
|
|
|
|
ghc-exactprint = self.ghc-exactprint_1_8_0_0;
|
|
|
|
ghc-exactprint_1_8_0_0 = addBuildDepends [
|
|
|
|
self.Diff
|
|
|
|
self.HUnit
|
|
|
|
self.data-default
|
|
|
|
self.extra
|
|
|
|
self.free
|
|
|
|
self.ghc-paths
|
|
|
|
self.ordered-containers
|
|
|
|
self.silently
|
|
|
|
self.syb
|
|
|
|
] super.ghc-exactprint_1_8_0_0;
|
|
|
|
|
2024-01-11 15:15:33 +00:00
|
|
|
#
|
2024-01-07 00:42:06 +00:00
|
|
|
# Jailbreaks
|
2024-01-11 15:15:33 +00:00
|
|
|
#
|
|
|
|
blaze-svg = doJailbreak super.blaze-svg; # base <4.19
|
2024-01-07 00:42:06 +00:00
|
|
|
commutative-semigroups = doJailbreak super.commutative-semigroups; # base < 4.19
|
2024-05-13 00:23:43 +01:00
|
|
|
dependent-sum-template = doJailbreak super.dependent-sum-template_0_2_0_1; # template-haskell < 2.21
|
2024-01-11 15:15:33 +00:00
|
|
|
diagrams-lib = doJailbreak super.diagrams-lib; # base <4.19, text <2.1
|
|
|
|
diagrams-postscript = doJailbreak super.diagrams-postscript; # base <4.19, bytestring <0.12
|
|
|
|
diagrams-svg = doJailbreak super.diagrams-svg; # base <4.19, text <2.1
|
2024-05-03 16:18:30 +01:00
|
|
|
generics-sop = doJailbreak super.generics-sop_0_5_1_4; # th-abstraction >=0.6 && <0.7
|
2024-01-07 00:42:06 +00:00
|
|
|
ghc-trace-events = doJailbreak super.ghc-trace-events; # text < 2.1, bytestring < 0.12, base < 4.19
|
2024-05-13 01:49:59 +01:00
|
|
|
hashing = doJailbreak super.hashing; # bytestring <0.12
|
2024-05-04 00:16:26 +01:00
|
|
|
json-sop = doJailbreak super.json-sop; # aeson <2.2, base <4.19, text <2.1
|
2024-01-07 00:42:06 +00:00
|
|
|
primitive-unlifted = doJailbreak super.primitive-unlifted; # bytestring < 0.12
|
2024-01-11 15:15:33 +00:00
|
|
|
statestack = doJailbreak super.statestack; # base < 4.19
|
2024-01-07 00:42:06 +00:00
|
|
|
newtype-generics = doJailbreak super.newtype-generics; # base < 4.19
|
|
|
|
hw-prim = doJailbreak super.hw-prim; # doctest < 0.22, ghc-prim < 0.11, hedgehog < 1.4
|
2024-01-11 15:15:33 +00:00
|
|
|
svg-builder = doJailbreak super.svg-builder; # base <4.19, bytestring <0.12, text <2.1
|
2024-01-04 10:54:08 +00:00
|
|
|
# Too strict bound on base, believe it or not.
|
|
|
|
# https://github.com/judah/terminfo/pull/55#issuecomment-1876894232
|
|
|
|
terminfo_0_4_1_6 = doJailbreak super.terminfo_0_4_1_6;
|
2024-03-19 11:09:28 +00:00
|
|
|
HaskellNet-SSL = doJailbreak super.HaskellNet-SSL; # bytestring >=0.9 && <0.12
|
2024-03-19 09:53:42 +00:00
|
|
|
raven-haskell = doJailbreak super.raven-haskell; # aeson <2.2
|
2024-05-13 01:49:35 +01:00
|
|
|
saltine = doJailbreak super.saltine; # bytestring && <0.12, deepseq <1.5, text > 1.2 && <1.3 || >=2.0 && <2.1
|
2024-03-26 09:05:53 +00:00
|
|
|
stripe-concepts = doJailbreak super.stripe-concepts; # text >=1.2.5 && <1.3 || >=2.0 && <2.1
|
2024-03-26 09:06:54 +00:00
|
|
|
stripe-signature = doJailbreak super.stripe-signature; # text >=1.2.5 && <1.3 || >=2.0 && <2.1
|
2024-03-26 08:58:59 +00:00
|
|
|
string-random = doJailbreak super.string-random; # text >=1.2.2.1 && <2.1
|
2024-03-23 11:39:50 +00:00
|
|
|
inflections = doJailbreak super.inflections; # text >=0.2 && <2.1
|
2024-05-01 22:29:35 +01:00
|
|
|
universe-some = doJailbreak super.universe-some; # th-abstraction < 0.7
|
2024-01-07 00:42:06 +00:00
|
|
|
|
2024-01-11 14:22:18 +00:00
|
|
|
#
|
2024-01-07 00:42:06 +00:00
|
|
|
# Test suite issues
|
2024-01-11 14:22:18 +00:00
|
|
|
#
|
2024-01-07 00:42:06 +00:00
|
|
|
unordered-containers = dontCheck super.unordered-containers; # ChasingBottoms doesn't support base 4.20
|
|
|
|
lifted-base = dontCheck super.lifted-base; # doesn't compile with transformers == 0.6.*
|
2024-01-13 19:13:09 +00:00
|
|
|
hourglass = dontCheck super.hourglass; # umaintained, test suite doesn't compile anymore
|
2024-02-26 07:44:37 +00:00
|
|
|
bsb-http-chunked = dontCheck super.bsb-http-chunked; # umaintained, test suite doesn't compile anymore
|
2024-03-26 08:53:08 +00:00
|
|
|
pcre-heavy = dontCheck super.pcre-heavy; # GHC warnings cause the tests to fail
|
2024-01-11 14:22:18 +00:00
|
|
|
|
|
|
|
#
|
|
|
|
# Other build fixes
|
|
|
|
#
|
|
|
|
|
|
|
|
# 2023-12-23: It needs this to build under ghc-9.6.3.
|
|
|
|
# A factor of 100 is insufficent, 200 seems seems to work.
|
|
|
|
hip = appendConfigureFlag "--ghc-options=-fsimpl-tick-factor=200" super.hip;
|
2024-02-26 07:21:06 +00:00
|
|
|
|
|
|
|
# Fix build with text-2.x.
|
|
|
|
libmpd = appendPatch (pkgs.fetchpatch
|
|
|
|
{ url = "https://github.com/vimus/libmpd-haskell/pull/138.patch";
|
|
|
|
sha256 = "Q4fA2J/Tq+WernBo+UIMdj604ILOMlIYkG4Pr046DfM=";
|
|
|
|
})
|
|
|
|
super.libmpd;
|
|
|
|
|
2024-05-01 20:37:52 +01:00
|
|
|
# Loosen bounds
|
|
|
|
patch = appendPatch (pkgs.fetchpatch {
|
|
|
|
url = "https://github.com/reflex-frp/patch/commit/91fed138483a7bf2b098d45b9e5cc36191776320.patch";
|
|
|
|
sha256 = "sha256-/KLfIshia88lU5G/hA7ild7+a2mqc7qgSa9AEBqEqkQ=";
|
|
|
|
}) super.patch;
|
2024-05-01 20:59:33 +01:00
|
|
|
reflex = appendPatch (pkgs.fetchpatch {
|
|
|
|
url = "https://github.com/reflex-frp/reflex/commit/0ac53ca3eab2649dd3f3edc585e10af8d13b28cd.patch";
|
|
|
|
sha256 = "sha256-umjwgdSKebJdRrXjwHhsi8HBqotx1vFibY9ttLkyT/0=";
|
|
|
|
}) super.reflex;
|
2024-05-01 20:37:52 +01:00
|
|
|
|
2015-01-10 10:02:37 +00:00
|
|
|
}
|