Skip to content

Commit

Permalink
haskellPackages: update hackage and stackage (#346720)
Browse files Browse the repository at this point in the history
  • Loading branch information
sternenseemann authored Oct 21, 2024
2 parents f2d7c52 + 4279643 commit 9ddc331
Show file tree
Hide file tree
Showing 19 changed files with 2,591 additions and 2,674 deletions.
2 changes: 1 addition & 1 deletion doc/languages-frameworks/haskell.section.md
Original file line number Diff line number Diff line change
Expand Up @@ -760,7 +760,7 @@ that depend on that library, you may want to use:
```nix
haskellPackages.haskell-ci.overrideScope (self: super: {
Cabal = self.Cabal_3_6_2_0;
Cabal = self.Cabal_3_14_0_0;
})
```
Expand Down
8 changes: 4 additions & 4 deletions pkgs/data/misc/hackage/pin.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"commit": "5d97d9c05e76d8cecb68f1e9063afb39ca0fb26b",
"url": "https://github.com/commercialhaskell/all-cabal-hashes/archive/5d97d9c05e76d8cecb68f1e9063afb39ca0fb26b.tar.gz",
"sha256": "1ic4wn5immv06m1m2cq6mzrrgrxbidxmj39licxlkmnm9jlwzjwr",
"msg": "Update from Hackage at 2024-09-03T10:29:19Z"
"commit": "750067bc36e810a96c066c8800438e0ce9ced327",
"url": "https://github.com/commercialhaskell/all-cabal-hashes/archive/750067bc36e810a96c066c8800438e0ce9ced327.tar.gz",
"sha256": "1bfr8r14rkisjp1f3iln12h4f5n66k8wkk09jvk7adal4grlpjny",
"msg": "Update from Hackage at 2024-10-05T14:46:54Z"
}
14 changes: 14 additions & 0 deletions pkgs/development/compilers/ghc/8.10.7.nix
Original file line number Diff line number Diff line change
Expand Up @@ -298,6 +298,20 @@ stdenv.mkDerivation (rec {
url = "https://gitlab.haskell.org/ghc/ghc/-/commit/8f7dd5710b80906ea7a3e15b7bb56a883a49fed8.patch";
hash = "sha256-C636Nq2U8YOG/av7XQmG3L1rU0bmC9/7m7Hty5pm5+s=";
})

# Backport part of <https://gitlab.haskell.org/ghc/ghc/-/merge_requests/7111> to 8.10.7
# The change we are interested in is that Cabal no longer sets include-dirs
# for the GHCi library delegating to the system search path or (in our case)
# cc-wrapper. Without this patch, the target libffi ends up in there (which
# we provide via --with-ffi-includes) which breaks bootstrapping e.g. when
# cross compiling GHC. Without include-dirs, cc-wrapper and splicing will
# correctly pick the suitable libffi out of the build environment.
(fetchpatch {
name = "ghci-no-libffi-include.patch";
url = "https://gitlab.haskell.org/ghc/ghc/-/commit/b2721819f391ab49871271283f32df54810c4387.patch";
sha256 = "1rmv3132xhxbka97v0rx7r6larx5f5nnvs4mgm9q3rmgpjyd1vf9";
includes = [ "libraries/ghci/ghci.cabal.in" ];
})
] ++ lib.optionals stdenv.hostPlatform.isDarwin [
# Make Block.h compile with c++ compilers. Remove with the next release
(fetchpatch {
Expand Down
4 changes: 4 additions & 0 deletions pkgs/development/compilers/ghc/9.8.3.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
import ./common-hadrian.nix rec {
version = "9.8.3";
sha256 = "99e40d729ec8831a633b75fd85d65dd10e31a0133dec9d198d686a273679ab70";
}
12 changes: 3 additions & 9 deletions pkgs/development/compilers/ghc/head.nix
Original file line number Diff line number Diff line change
@@ -1,11 +1,5 @@
import ./common-hadrian.nix {
version = "9.11.20240410";
rev = "1b1a92bd25c3f7249cf922c5dbf4415d2de44a36";
sha256 = "sha256-2HdhxhVrKn8c/ZOGYoYThqXpod2OPiGXgH+mAV69Ip0=";
# The STM benchmark contains chanbench.hs and ChanBench.hs causing a hash
# mismatch on case insensitive filesystems. See also
# https://gitlab.haskell.org/ghc/packages/stm/-/issues/2
postFetch = ''
rm -rf "$out/libraries/stm/bench"
'';
version = "9.11.20240423";
rev = "dddc9dff0547733a10e7f505612ab9df3a7c21b6";
sha256 = "0993sdmzzyymllck8mcpa1zgrjqjfxcvk1ykvfc18bvbs4145cm9";
}
6 changes: 3 additions & 3 deletions pkgs/development/haskell-modules/cabal2nix-unstable.nix
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,10 @@
}:
mkDerivation {
pname = "cabal2nix";
version = "unstable-2024-05-20";
version = "unstable-2024-10-17";
src = fetchzip {
url = "https://github.com/NixOS/cabal2nix/archive/79b73778680e2ae27302dce430beee302299f496.tar.gz";
sha256 = "0xjrnf9x1f4jl4bsxc6kv5q7rsbn3vs0ddidj9qf6mzzzqxq14p3";
url = "https://github.com/NixOS/cabal2nix/archive/b8eb82f8bc907b42dfb463cab62e49fbe2fff997.tar.gz";
sha256 = "1fxqigr002ssgz1l62rc7k04q4q0hwcl2wqy7l2shylxqf7yfcd6";
};
postUnpack = "sourceRoot+=/cabal2nix; echo source root reset to $sourceRoot";
isLibrary = true;
Expand Down
79 changes: 36 additions & 43 deletions pkgs/development/haskell-modules/configuration-common.nix
Original file line number Diff line number Diff line change
Expand Up @@ -27,14 +27,14 @@ self: super: {
Cabal-syntax = self.Cabal-syntax_3_10_3_0;
} // lib.optionalAttrs (lib.versionOlder self.ghc.version "9.2.5") {
# Use process core package when possible
process = self.process_1_6_22_0;
process = self.process_1_6_24_0;
}));

Cabal_3_12_1_0 = doDistribute (super.Cabal_3_12_1_0.override ({
Cabal-syntax = self.Cabal-syntax_3_12_1_0;
} // lib.optionalAttrs (lib.versionOlder self.ghc.version "9.2.5") {
# Use process core package when possible
process = self.process_1_6_22_0;
process = self.process_1_6_24_0;
}));

# hackage-security == 0.6.2.6 has a wider support range in theory, but it only
Expand Down Expand Up @@ -411,7 +411,7 @@ self: super: {
name = "git-annex-${super.git-annex.version}-src";
url = "git://git-annex.branchable.com/";
rev = "refs/tags/" + super.git-annex.version;
sha256 = "0j037sis64gnrll7ajg48cvzzvxqsrhj7vnhiwcqv8wbmbfv0avn";
sha256 = "sha256-hPZTcl3kWeUnSVYOE1W+FDwR3LYg6gaJfEBIY6VSfxY=";
# delete android and Android directories which cause issues on
# darwin (case insensitive directory). Since we don't need them
# during the build process, we can delete it to prevent a hash
Expand Down Expand Up @@ -724,7 +724,6 @@ self: super: {
nats-queue = dontCheck super.nats-queue;
netpbm = dontCheck super.netpbm;
network = dontCheck super.network;
network_2_6_3_1 = dontCheck super.network_2_6_3_1; # package is missing files for test
network-dbus = dontCheck super.network-dbus;
notcpp = dontCheck super.notcpp;
ntp-control = dontCheck super.ntp-control;
Expand Down Expand Up @@ -1811,10 +1810,6 @@ self: super: {
# tests seem to require a different version of hspec-core
hspec-contrib = dontCheck super.hspec-contrib;

# github.com/ucsd-progsys/liquidhaskell/issues/1729
liquidhaskell-boot = super.liquidhaskell-boot.override { Diff = self.Diff_0_3_4; };
Diff_0_3_4 = dontCheck super.Diff_0_3_4;

# The test suite attempts to read `/etc/resolv.conf`, which doesn't work in the sandbox.
domain-auth = dontCheck super.domain-auth;

Expand Down Expand Up @@ -1865,6 +1860,12 @@ self: super: {
# 2024-03-02: vty <5.39 - https://github.com/reflex-frp/reflex-ghci/pull/33
reflex-ghci = assert super.reflex-ghci.version == "0.2.0.1"; doJailbreak super.reflex-ghci;

# 2024-09-18: transformers <0.5 https://github.com/reflex-frp/reflex-gloss/issues/6
reflex-gloss = assert super.reflex-gloss.version == "0.2"; doJailbreak super.reflex-gloss;

# 2024-09-18: primitive <0.8 https://gitlab.com/Kritzefitz/reflex-gi-gtk/-/merge_requests/20
reflex-gi-gtk = assert super.reflex-gi-gtk.version == "0.2.0.1"; doJailbreak super.reflex-gi-gtk;

# Due to tests restricting base in 0.8.0.0 release
http-media = doJailbreak super.http-media;

Expand Down Expand Up @@ -1914,9 +1915,8 @@ self: super: {
sha256 = "sha256-kFV6CcwKdMq+qSgyc+eIApnaycq5A++pEEVr2A9xvts=";
}) super.pipes-aeson;

# Needs bytestring 0.11
# https://github.com/Gabriella439/Haskell-Pipes-HTTP-Library/pull/17
pipes-http = doJailbreak super.pipes-http;
# 2024-09-18: transformers <0.6 https://github.com/Gabriella439/Haskell-Pipes-Extras-Library/pull/19
pipes-extras = assert super.pipes-extras.version == "1.0.15"; doJailbreak super.pipes-extras;

moto-postgresql = appendPatches [
# https://gitlab.com/k0001/moto/-/merge_requests/3
Expand Down Expand Up @@ -2002,6 +2002,14 @@ self: super: {
# Test suite fails, upstream not reachable for simple fix (not responsive on github)
vivid-osc = dontCheck super.vivid-osc;
vivid-supercollider = dontCheck super.vivid-supercollider;
vivid = overrideCabal (drv: assert drv.version == "0.5.2.0"; {
# 2024-10-18: Some library dependency must have stopped
# re-exporting 'void', so now it needs an extra import line.
# Fixed in 0.5.2.1.
postPatch = ''
sed -i '/) where/a import Control.Monad (void)' Vivid/GlobalState.hs
'';
}) super.vivid;

# Test suite does not compile.
feed = dontCheck super.feed;
Expand Down Expand Up @@ -2109,12 +2117,6 @@ self: super: {
# https://github.com/serokell/haskell-crypto/issues/25
crypto-sodium = dontCheck super.crypto-sodium;

taskell = super.taskell.override {
# Does not support brick >= 1.0
# https://github.com/smallhadroncollider/taskell/issues/125
brick = self.brick_0_70_1;
};

# Polyfill for GHCs from the integer-simple days that don't bundle ghc-bignum
ghc-bignum = super.ghc-bignum or self.mkDerivation {
pname = "ghc-bignum";
Expand Down Expand Up @@ -2220,17 +2222,6 @@ self: super: {
revision = null;
} super.llvm-hs-pure);

# * Fix build failure by picking patch from 8.5, we need
# this version of sbv for petrinizer
# * Pin version of crackNum that still exposes its library
sbv_7_13 = appendPatch (fetchpatch {
url = "https://github.com/LeventErkok/sbv/commit/57014b9c7c67dd9b63619a996e2c66e32c33c958.patch";
sha256 = "10npa8nh2413n6p6qld795qfkbld08icm02bspmk93y0kabpgmgm";
})
(super.sbv_7_13.override {
crackNum = self.crackNum_2_4;
});

# Too strict bounds on dimensional
# https://github.com/enomsg/science-constants-dimensional/pull/1
science-constants-dimensional = doJailbreak super.science-constants-dimensional;
Expand All @@ -2239,17 +2230,23 @@ self: super: {
# https://github.com/merijn/paramtree/issues/4
paramtree = dontCheck super.paramtree;

# Too strict version bounds on haskell-gi
# https://github.com/owickstrom/gi-gtk-declarative/issues/100
gi-gtk-declarative = doJailbreak super.gi-gtk-declarative;
# 2024-09-18: Make compatible with haskell-gi 0.26.10
# https://github.com/owickstrom/gi-gtk-declarative/pull/118
gi-gtk-declarative = overrideCabal (drv: assert drv.version == "0.7.1"; {
jailbreak = true;
postPatch = ''
sed -i '1 i {-# LANGUAGE FlexibleContexts #-}' \
src/GI/Gtk/Declarative/Widget/Conversions.hs
'';
}) super.gi-gtk-declarative;
gi-gtk-declarative-app-simple = doJailbreak super.gi-gtk-declarative-app-simple;

gi-gtk_4 = self.gi-gtk_4_0_9;
gi-gtk_4_0_9 = doDistribute (super.gi-gtk_4_0_9.override {
gi-gdk = self.gi-gdk_4;
});
gi-gdk_4 = self.gi-gdk_4_0_8;
gi-gdk_4_0_8 = doDistribute super.gi-gdk_4_0_8;
gi-gdk_4 = self.gi-gdk_4_0_9;
gi-gdk_4_0_9 = doDistribute super.gi-gdk_4_0_9;
# GSK is only used for GTK 4.
gi-gsk = super.gi-gsk.override {
gi-gdk = self.gi-gdk_4;
Expand Down Expand Up @@ -2531,9 +2528,12 @@ self: super: {
# 2024-03-02: base <=4.18.0.0 https://github.com/srid/url-slug/pull/2
url-slug = doJailbreak super.url-slug;

glirc = doJailbreak (super.glirc.override {
vty = self.vty_5_35_1;
});
glirc = super.glirc.override {
vty = self.vty_6_2;
vty-unix = super.vty-unix.override {
vty = self.vty_6_2;
};
};

# Too strict bounds on text and tls
# https://github.com/barrucadu/irc-conduit/issues/54
Expand Down Expand Up @@ -2942,13 +2942,6 @@ self: super: {
hash = "sha256-zugyUpEq/iVkxghrvguL95+lJDEpE8MLvZivken0p24=";
}) super.nix-serve-ng;

# Needs a matching version of ipython-kernel and a
# ghc-syntax-highlighter compatible with a newer ghc-lib-parser it
# transitively pulls in
ihaskell = super.ihaskell.overrideScope (self: super: {
ghc-syntax-highlighter = self.ghc-syntax-highlighter_0_0_10_0;
});

# 2024-01-24: support optparse-applicative 0.18
niv = appendPatches [
(fetchpatch {
Expand Down
6 changes: 0 additions & 6 deletions pkgs/development/haskell-modules/configuration-ghc-8.6.x.nix
Original file line number Diff line number Diff line change
Expand Up @@ -86,10 +86,6 @@ self: super: {
# cabal2spec needs a recent version of Cabal
cabal2spec = super.cabal2spec.overrideScope (self: super: { Cabal = self.Cabal_3_2_1_0; });

# https://github.com/pikajude/stylish-cabal/issues/12
stylish-cabal = doDistribute (markUnbroken (super.stylish-cabal.override { haddock-library = self.haddock-library_1_7_0; }));
haddock-library_1_7_0 = dontCheck super.haddock-library_1_7_0;

# ghc versions prior to 8.8.x needs additional dependency to compile successfully.
ghc-lib-parser-ex = addBuildDepend self.ghc-lib-parser super.ghc-lib-parser-ex;

Expand All @@ -99,8 +95,6 @@ self: super: {
# vector 0.12.2 indroduced doctest checks that don’t work on older compilers
vector = dontCheck super.vector;

mmorph = super.mmorph_1_1_3;

# https://github.com/haskellari/time-compat/issues/23
time-compat = dontCheck super.time-compat;

Expand Down
8 changes: 3 additions & 5 deletions pkgs/development/haskell-modules/configuration-ghc-9.10.x.nix
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,6 @@ self: super: {
# Upgrade to accommodate new core library versions, where the authors have
# already made the relevant changes.
aeson = doDistribute self.aeson_2_2_3_0;
apply-refact = doDistribute self.apply-refact_0_14_0_0;
attoparsec-aeson = doDistribute self.attoparsec-aeson_2_2_2_0;
auto-update = super.auto-update_0_2_1;
extensions = doDistribute self.extensions_0_1_0_2;
Expand Down Expand Up @@ -112,12 +111,11 @@ self: super: {

bitvec = doJailbreak super.bitvec; # primitive <0.9

apply-refact_0_14_0_0 = doJailbreak super.apply-refact_0_14_0_0; # ghc-exactprint <1.9
retrie = doJailbreak super.retrie; # base <4.20, ghc<9.9, ghc-exactprint<1.9

hashable_1_4_7_0 = doJailbreak super.hashable_1_4_7_0; # relax bounds for QuickCheck, tasty, and tasty-quickcheck
hashable_1_5_0_0 = doJailbreak super.hashable_1_5_0_0; # relax bounds for QuickCheck, tasty, and tasty-quickcheck

broadcast-chan = doJailbreak super.broadcast-chan; # base <4.19 https://github.com/merijn/broadcast-chan/pull/19

#
# Test suite issues
#
Expand All @@ -128,7 +126,7 @@ self: super: {
primitive-unlifted = dontCheck super.primitive-unlifted; # doesn't compile with primitive ==0.9.*
bsb-http-chunked = pkgs.haskell.lib.dontCheck super.bsb-http-chunked; # https://github.com/sjakobi/bsb-http-chunked/issues/45
hinotify = pkgs.haskell.lib.dontCheck super.hinotify; # https://github.com/kolmodin/hinotify/issues/38
warp = pkgs.haskell.lib.dontCheck super.warp_3_4_1; # test suite assumes it can freely call curl
warp = pkgs.haskell.lib.dontCheck super.warp_3_4_2; # test suite assumes it can freely call curl

haskell-language-server = disableCabalFlag "retrie" (disableCabalFlag "hlint" (disableCabalFlag "stylishhaskel" (super.haskell-language-server.override {stylish-haskell = null;retrie = null;apply-refact=null;hlint = null;})));

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,7 @@ self: super: {
string-random = doJailbreak super.string-random; # text >=1.2.2.1 && <2.1
inflections = doJailbreak super.inflections; # text >=0.2 && <2.1
universe-some = doJailbreak super.universe-some; # th-abstraction < 0.7
broadcast-chan = doJailbreak super.broadcast-chan; # base <4.19 https://github.com/merijn/broadcast-chan/pull/19

#
# Test suite issues
Expand Down
Loading

0 comments on commit 9ddc331

Please sign in to comment.