stack: get building
This commit is contained in:
parent
b049eee840
commit
84627b0594
|
@ -1090,17 +1090,39 @@ self: super: {
|
|||
}) super.dhall-nixpkgs);
|
||||
|
||||
stack =
|
||||
self.generateOptparseApplicativeCompletions
|
||||
[ "stack" ]
|
||||
lib.pipe
|
||||
(super.stack.override {
|
||||
# stack needs to use an exact hpack version. When changing or removing
|
||||
# this override, double-check the upstream stack release to confirm
|
||||
# that we are using the correct hpack version. See
|
||||
# https://github.com/NixOS/nixpkgs/issues/223390 for more information.
|
||||
#
|
||||
# hpack tests fail because of https://github.com/sol/hpack/issues/528
|
||||
hpack = dontCheck self.hpack_0_35_0;
|
||||
});
|
||||
hpack = assert self.hpack.version == "0.35.2"; self.hpack;
|
||||
})
|
||||
[
|
||||
(self.generateOptparseApplicativeCompletions [ "stack" ])
|
||||
|
||||
# Seems to be an unnecessarily strict dep on ansi-terminal
|
||||
doJailbreak
|
||||
|
||||
# The below patch has unix line endings, but the actual file
|
||||
# has CRLF line endings. The following override changes the
|
||||
# file to unix line endings before applying the patch.
|
||||
(overrideCabal (oldAttrs: {
|
||||
prePatch = oldAttrs.prePatch or "" + ''
|
||||
"${lib.getBin pkgs.buildPackages.dos2unix}/bin/dos2unix" src/main/BuildInfo.hs
|
||||
'';
|
||||
}))
|
||||
# stack-2.11.1 has a bug when building without git.
|
||||
# https://github.com/commercialhaskell/stack/pull/6127
|
||||
(appendPatch
|
||||
(fetchpatch {
|
||||
name = "stack-fix-building-without-git.patch";
|
||||
url = "https://github.com/commercialhaskell/stack/pull/6127/commits/086f93933d547736a7007fc4110f7816ef21f691.patch";
|
||||
hash = "sha256-1nwzMoumWceVu8RNnH2mmSxYT24G1FAnFRJvUMeD3po=";
|
||||
includes = [ "src/main/BuildInfo.hs" ];
|
||||
})
|
||||
)
|
||||
];
|
||||
|
||||
# Too strict version bound on hashable-time.
|
||||
# Tests require newer package version.
|
||||
|
|
|
@ -104,7 +104,6 @@ extra-packages:
|
|||
- hinotify == 0.3.9 # for xmonad-0.26: https://github.com/kolmodin/hinotify/issues/29
|
||||
- hlint == 3.2.8 # 2022-09-21: needed for hls on ghc 8.8
|
||||
- hlint == 3.4.1 # 2022-09-21: needed for hls with ghc-lib-parser 9.2
|
||||
- hpack == 0.35.0 # 2022-09-29: Needed for stack-2.9.1
|
||||
- hspec < 2.8 # 2022-04-07: Needed for tasty-hspec 1.1.6
|
||||
- hspec-core < 2.8 # 2022-04-07: Needed for tasty-hspec 1.1.6
|
||||
- hspec-discover < 2.8 # 2022-04-07: Needed for tasty-hspec 1.1.6
|
||||
|
|
|
@ -147219,48 +147219,6 @@ self: {
|
|||
mainProgram = "hp2pretty";
|
||||
}) {};
|
||||
|
||||
"hpack_0_35_0" = callPackage
|
||||
({ mkDerivation, aeson, base, bifunctors, bytestring, Cabal
|
||||
, containers, cryptonite, deepseq, directory, filepath, Glob, hspec
|
||||
, hspec-discover, http-client, http-client-tls, http-types, HUnit
|
||||
, infer-license, interpolate, mockery, pretty, QuickCheck
|
||||
, scientific, template-haskell, temporary, text, transformers
|
||||
, unordered-containers, vector, yaml
|
||||
}:
|
||||
mkDerivation {
|
||||
pname = "hpack";
|
||||
version = "0.35.0";
|
||||
sha256 = "1cii4bdn4rm2l3yw9vsv4ygn61zmalaa282iqg9rihys90nvrgf6";
|
||||
revision = "1";
|
||||
editedCabalFile = "1x0rmra2fpfzmhhw090iila2drfdmb1y28ybypmgbi0asa1zl751";
|
||||
isLibrary = true;
|
||||
isExecutable = true;
|
||||
libraryHaskellDepends = [
|
||||
aeson base bifunctors bytestring Cabal containers cryptonite
|
||||
deepseq directory filepath Glob http-client http-client-tls
|
||||
http-types infer-license pretty scientific text transformers
|
||||
unordered-containers vector yaml
|
||||
];
|
||||
executableHaskellDepends = [
|
||||
aeson base bifunctors bytestring Cabal containers cryptonite
|
||||
deepseq directory filepath Glob http-client http-client-tls
|
||||
http-types infer-license pretty scientific text transformers
|
||||
unordered-containers vector yaml
|
||||
];
|
||||
testHaskellDepends = [
|
||||
aeson base bifunctors bytestring Cabal containers cryptonite
|
||||
deepseq directory filepath Glob hspec http-client http-client-tls
|
||||
http-types HUnit infer-license interpolate mockery pretty
|
||||
QuickCheck scientific template-haskell temporary text transformers
|
||||
unordered-containers vector yaml
|
||||
];
|
||||
testToolDepends = [ hspec-discover ];
|
||||
description = "A modern format for Haskell packages";
|
||||
license = lib.licenses.mit;
|
||||
hydraPlatforms = lib.platforms.none;
|
||||
mainProgram = "hpack";
|
||||
}) {};
|
||||
|
||||
"hpack" = callPackage
|
||||
({ mkDerivation, aeson, base, bifunctors, bytestring, Cabal
|
||||
, containers, cryptonite, deepseq, directory, filepath, Glob, hspec
|
||||
|
|
Loading…
Reference in a new issue