haskell-language-server: Fix build for 1.9.0.0 for all ghc versions
This commit is contained in:
parent
0c761f74f0
commit
3b14e60bab
@ -1365,7 +1365,6 @@ self: super: {
|
||||
(disableCabalFlag "callHierarchy") # Disabled temporarily: https://github.com/haskell/haskell-language-server/pull/3431
|
||||
]).overrideScope (lself: lsuper: {
|
||||
hls-call-hierarchy-plugin = null;
|
||||
hlint = enableCabalFlag "ghc-lib" lsuper.hlint;
|
||||
# For most ghc versions, we overrideScope Cabal in the configuration-ghc-???.nix,
|
||||
# because some packages, like ormolu, need a newer Cabal version.
|
||||
# ghc-paths is special because it depends on Cabal for building
|
||||
@ -1378,11 +1377,11 @@ self: super: {
|
||||
ghc-paths = lsuper.ghc-paths.override { Cabal = null; };
|
||||
});
|
||||
|
||||
hls-hlint-plugin = super.hls-hlint-plugin.overrideScope (lself: lsuper: {
|
||||
hls-hlint-plugin = super.hls-hlint-plugin.override {
|
||||
# For "ghc-lib" flag see https://github.com/haskell/haskell-language-server/issues/3185#issuecomment-1250264515
|
||||
hlint = enableCabalFlag "ghc-lib" lsuper.hlint;
|
||||
apply-refact = lsuper.apply-refact_0_11_0_0;
|
||||
});
|
||||
hlint = enableCabalFlag "ghc-lib" super.hlint;
|
||||
apply-refact = self.apply-refact_0_11_0_0;
|
||||
};
|
||||
|
||||
# For -f-auto see cabal.project in haskell-language-server.
|
||||
ghc-lib-parser-ex = addBuildDepend self.ghc-lib-parser (disableCabalFlag "auto" super.ghc-lib-parser-ex);
|
||||
@ -1393,9 +1392,6 @@ self: super: {
|
||||
# 2021-06-20: Tests fail: https://github.com/haskell/haskell-language-server/issues/1949
|
||||
hls-refine-imports-plugin = dontCheck super.hls-refine-imports-plugin;
|
||||
|
||||
# 2021-09-14: Tests are broken because of undeterministic variable names
|
||||
hls-tactics-plugin = dontCheck super.hls-tactics-plugin;
|
||||
|
||||
# 2021-11-20: https://github.com/haskell/haskell-language-server/pull/2373
|
||||
hls-explicit-imports-plugin = dontCheck super.hls-explicit-imports-plugin;
|
||||
|
||||
@ -1915,6 +1911,9 @@ self: super: {
|
||||
# https://github.com/haskell/haskell-language-server/pull/2887
|
||||
hls-change-type-signature-plugin = dontCheck super.hls-change-type-signature-plugin;
|
||||
|
||||
# 2022-12-30: Restrictive upper bound on optparse-applicative
|
||||
retrie = doJailbreak super.retrie;
|
||||
|
||||
# Fixes https://github.com/NixOS/nixpkgs/issues/140613
|
||||
# https://github.com/recursion-schemes/recursion-schemes/issues/128
|
||||
recursion-schemes = overrideCabal (drv: {
|
||||
|
@ -109,7 +109,7 @@ self: super: {
|
||||
hls-brittany-plugin
|
||||
hls-haddock-comments-plugin
|
||||
(unmarkBroken hls-splice-plugin)
|
||||
(unmarkBroken hls-tactics-plugin)
|
||||
hls-tactics-plugin
|
||||
];
|
||||
in addBuildDepends additionalDeps (super.haskell-language-server.overrideScope (lself: lsuper: {
|
||||
Cabal = lself.Cabal_3_6_3_0;
|
||||
@ -118,6 +118,12 @@ self: super: {
|
||||
lsp-types = doJailbreak lsuper.lsp-types; # Checks require aeson >= 2.0
|
||||
}));
|
||||
|
||||
hls-tactics-plugin = unmarkBroken (addBuildDepends (with self.hls-tactics-plugin.scope; [
|
||||
aeson extra fingertree generic-lens ghc-exactprint ghc-source-gen ghcide
|
||||
hls-graph hls-plugin-api hls-refactor-plugin hyphenation lens lsp megaparsec
|
||||
parser-combinators prettyprinter refinery retrie syb unagi-chan unordered-containers
|
||||
]) super.hls-tactics-plugin);
|
||||
|
||||
hls-brittany-plugin = unmarkBroken (addBuildDepends (with self.hls-brittany-plugin.scope; [
|
||||
brittany czipwith extra ghc-exactprint ghcide hls-plugin-api hls-test-utils lens lsp-types
|
||||
]) (super.hls-brittany-plugin.overrideScope (lself: lsuper: {
|
||||
@ -173,10 +179,17 @@ self: super: {
|
||||
# https://github.com/mrkkrp/megaparsec/pull/485#issuecomment-1250051823
|
||||
megaparsec = doJailbreak super.megaparsec;
|
||||
|
||||
retrie = dontCheck self.retrie_1_1_0_0;
|
||||
|
||||
# Later versions only support GHC >= 9.2
|
||||
ghc-exactprint = self.ghc-exactprint_0_6_4;
|
||||
|
||||
apply-refact = self.apply-refact_0_9_3_0;
|
||||
|
||||
hls-hlint-plugin = super.hls-hlint-plugin.override {
|
||||
inherit (self) apply-refact;
|
||||
};
|
||||
|
||||
# Needs OneTuple for ghc < 9.2
|
||||
binary-orphans = addBuildDepends [ self.OneTuple ] super.binary-orphans;
|
||||
}
|
||||
|
@ -137,24 +137,7 @@ self: super: {
|
||||
|
||||
mime-string = disableOptimization super.mime-string;
|
||||
|
||||
haskell-language-server = let
|
||||
# These aren't included in hackage-packages.nix because hackage2nix is configured for GHC 9.2, under which these plugins aren't supported.
|
||||
# See https://github.com/NixOS/nixpkgs/pull/205902 for why we use `self.<package>.scope`
|
||||
additionalDeps = with self.haskell-language-server.scope; [
|
||||
hls-brittany-plugin
|
||||
hls-haddock-comments-plugin
|
||||
(unmarkBroken hls-splice-plugin)
|
||||
(unmarkBroken hls-tactics-plugin)
|
||||
];
|
||||
in addBuildDepends additionalDeps (super.haskell-language-server.overrideScope (lself: lsuper: {
|
||||
# Pick old ormolu and fourmolu because ghc-lib-parser is not compatible
|
||||
ormolu = doJailbreak lself.ormolu_0_1_4_1;
|
||||
fourmolu = doJailbreak lself.fourmolu_0_3_0_0;
|
||||
aeson = lself.aeson_1_5_6_0;
|
||||
lens-aeson = lself.lens-aeson_1_1_3;
|
||||
stylish-haskell = doJailbreak lself.stylish-haskell_0_13_0_0;
|
||||
lsp-types = doJailbreak lsuper.lsp-types;
|
||||
}));
|
||||
haskell-language-server = throw "haskell-language-server dropped support for ghc 8.8 in version 1.9.0.0 please use a newer ghc version or an older nixpkgs version";
|
||||
|
||||
hlint = self.hlint_3_2_8;
|
||||
|
||||
@ -164,19 +147,6 @@ self: super: {
|
||||
# additional dependency to compile successfully.
|
||||
ghc-lib-parser-ex = addBuildDepend self.ghc-lib-parser self.ghc-lib-parser-ex_8_10_0_24;
|
||||
|
||||
hls-brittany-plugin = unmarkBroken (addBuildDepends (with self.hls-brittany-plugin.scope; [
|
||||
brittany czipwith extra ghc-exactprint ghcide hls-plugin-api hls-test-utils lens lsp-types
|
||||
]) (super.hls-brittany-plugin.overrideScope (lself: lsuper: {
|
||||
brittany = doJailbreak lself.brittany_0_13_1_2;
|
||||
lsp-types = doJailbreak lsuper.lsp-types; # Checks require aeson >= 2.0
|
||||
})));
|
||||
|
||||
# This package is marked as unbuildable on GHC 9.2, so hackage2nix doesn't include any dependencies.
|
||||
# See https://github.com/NixOS/nixpkgs/pull/205902 for why we use `self.<package>.scope`
|
||||
hls-haddock-comments-plugin = unmarkBroken (addBuildDepends (with self.hls-haddock-comments-plugin.scope; [
|
||||
ghc-exactprint ghcide hls-plugin-api hls-refactor-plugin lsp-types unordered-containers
|
||||
]) super.hls-haddock-comments-plugin);
|
||||
|
||||
# has a restrictive lower bound on Cabal
|
||||
fourmolu = doJailbreak super.fourmolu;
|
||||
|
||||
|
@ -113,7 +113,7 @@ self: super: {
|
||||
additionalDeps = with self.haskell-language-server.scope; [
|
||||
hls-haddock-comments-plugin
|
||||
(unmarkBroken hls-splice-plugin)
|
||||
(unmarkBroken hls-tactics-plugin)
|
||||
hls-tactics-plugin
|
||||
];
|
||||
in addBuildDepends additionalDeps (super.haskell-language-server.overrideScope (lself: lsuper: {
|
||||
# Needed for modern ormolu and fourmolu.
|
||||
@ -127,6 +127,12 @@ self: super: {
|
||||
ghc-exactprint ghcide hls-plugin-api hls-refactor-plugin lsp-types unordered-containers
|
||||
]) super.hls-haddock-comments-plugin);
|
||||
|
||||
hls-tactics-plugin = unmarkBroken (addBuildDepends (with self.hls-tactics-plugin.scope; [
|
||||
aeson extra fingertree generic-lens ghc-exactprint ghc-source-gen ghcide
|
||||
hls-graph hls-plugin-api hls-refactor-plugin hyphenation lens lsp megaparsec
|
||||
parser-combinators prettyprinter refinery retrie syb unagi-chan unordered-containers
|
||||
]) super.hls-tactics-plugin);
|
||||
|
||||
# The test suite depends on ChasingBottoms, which is broken with ghc-9.0.x.
|
||||
unordered-containers = dontCheck super.unordered-containers;
|
||||
|
||||
@ -174,8 +180,15 @@ self: super: {
|
||||
|
||||
# Later versions only support GHC >= 9.2
|
||||
ghc-exactprint = self.ghc-exactprint_0_6_4;
|
||||
|
||||
retrie = dontCheck self.retrie_1_1_0_0;
|
||||
|
||||
apply-refact = self.apply-refact_0_9_3_0;
|
||||
|
||||
hls-hlint-plugin = super.hls-hlint-plugin.override {
|
||||
inherit (self) apply-refact;
|
||||
};
|
||||
|
||||
# Needs OneTuple for ghc < 9.2
|
||||
binary-orphans = addBuildDepends [ self.OneTuple ] super.binary-orphans;
|
||||
}
|
||||
|
@ -63,7 +63,6 @@ self: super: {
|
||||
|
||||
# Jailbreaks & Version Updates
|
||||
hashable-time = doJailbreak super.hashable-time;
|
||||
retrie = doJailbreak super.retrie_1_2_1_1;
|
||||
|
||||
# Depends on utf8-light which isn't maintained / doesn't support base >= 4.16
|
||||
# https://github.com/haskell-infra/hackage-trustees/issues/347
|
||||
|
@ -172,23 +172,28 @@ in {
|
||||
# 2022-08-01: Tests are broken on ghc 9.2.4: https://github.com/wz1000/HieDb/issues/46
|
||||
hiedb = dontCheck super.hiedb;
|
||||
|
||||
hlint = self.hlint_3_5;
|
||||
hls-hlint-plugin = super.hls-hlint-plugin.override {
|
||||
inherit (self) hlint;
|
||||
};
|
||||
|
||||
# 2022-10-06: https://gitlab.haskell.org/ghc/ghc/-/issues/22260
|
||||
ghc-check = dontHaddock super.ghc-check;
|
||||
|
||||
ghc-exactprint = overrideCabal (drv: {
|
||||
libraryHaskellDepends = with self; [ HUnit data-default fail filemanip free ghc-paths ordered-containers silently syb Diff ];
|
||||
})
|
||||
self.ghc-exactprint_1_6_1;
|
||||
|
||||
# 2022-10-06: plugins disabled for hls 1.8.0.0 based on
|
||||
# https://haskell-language-server.readthedocs.io/en/latest/support/plugin-support.html#current-plugin-support-tiers
|
||||
haskell-language-server = super.haskell-language-server.override {
|
||||
hls-refactor-plugin = null;
|
||||
hls-class-plugin = null;
|
||||
hls-eval-plugin = null;
|
||||
hls-floskell-plugin = null;
|
||||
hls-fourmolu-plugin = null;
|
||||
hls-gadt-plugin = null;
|
||||
hls-hlint-plugin = null;
|
||||
hls-ormolu-plugin = null;
|
||||
hls-rename-plugin = null;
|
||||
hls-stylish-haskell-plugin = null;
|
||||
hls-retrie-plugin = null;
|
||||
};
|
||||
|
||||
# https://github.com/tweag/ormolu/issues/941
|
||||
@ -197,5 +202,5 @@ in {
|
||||
}) (disableCabalFlag "fixity-th" super.ormolu);
|
||||
fourmolu = overrideCabal (drv: {
|
||||
libraryHaskellDepends = drv.libraryHaskellDepends ++ [ self.file-embed ];
|
||||
}) (disableCabalFlag "fixity-th" super.fourmolu);
|
||||
}) (disableCabalFlag "fixity-th" super.fourmolu_0_10_1_0);
|
||||
}
|
||||
|
@ -70,12 +70,8 @@ core-packages:
|
||||
default-package-overrides:
|
||||
# gi-gdkx11-4.x requires gtk-4.x, but stackage still restricts gi-gtk to 3.*
|
||||
- gi-gdkx11 < 4
|
||||
# 2022-02-18: pin to our current GHC version
|
||||
- ghc-api-compat == 9.0.*
|
||||
# 2021-11-09: ghc-bignum is bundled starting with 9.0.1; only 1.0 builds with GHCs prior to 9.2.1
|
||||
- ghc-bignum == 1.0
|
||||
# 1.2.0.0: “Dropped support for GHC <9.2 (might readd it later)”
|
||||
- retrie < 1.2.0.0
|
||||
# needs http-client >= 0.7.11 which isn't part of Stackage LTS 18
|
||||
- http-client-restricted < 0.0.5
|
||||
# Downgrade hasql-dynamic-statements until hasql 1.6 is in Stackage
|
||||
@ -162,6 +158,7 @@ extra-packages:
|
||||
- weeder == 2.3.* # 2022-05-31: preserve for GHC 9.0.2
|
||||
- commonmark-extensions < 0.2.3.3 # 2022-12-17: required by emanote 1.0.0.0 (to avoid a bug in 0.2.3.3)
|
||||
- ShellCheck == 0.8.0 # 2022-12-28: required by haskell-ci 0.14.3
|
||||
- retrie < 1.2.0.0 # 2022-12-30: required for hls on ghc < 9.2
|
||||
|
||||
package-maintainers:
|
||||
abbradar:
|
||||
|
@ -941,6 +941,13 @@ self: super: builtins.intersectAttrs super {
|
||||
'';
|
||||
}) super.fourmolu;
|
||||
|
||||
# Test suite wants to run main executable
|
||||
fourmolu_0_10_1_0 = overrideCabal (drv: {
|
||||
preCheck = drv.preCheck or "" + ''
|
||||
export PATH="$PWD/dist/build/fourmolu:$PATH"
|
||||
'';
|
||||
}) super.fourmolu_0_10_1_0;
|
||||
|
||||
# Test suite needs to execute 'disco' binary
|
||||
disco = overrideCabal (drv: {
|
||||
preCheck = drv.preCheck or "" + ''
|
||||
|
@ -243902,7 +243902,7 @@ self: {
|
||||
hydraPlatforms = lib.platforms.none;
|
||||
}) {};
|
||||
|
||||
"retrie" = callPackage
|
||||
"retrie_1_1_0_0" = callPackage
|
||||
({ mkDerivation, ansi-terminal, async, base, bytestring, containers
|
||||
, data-default, deepseq, directory, filepath, ghc, ghc-exactprint
|
||||
, ghc-paths, haskell-src-exts, HUnit, list-t, mtl
|
||||
@ -243931,9 +243931,10 @@ self: {
|
||||
];
|
||||
description = "A powerful, easy-to-use codemodding tool for Haskell";
|
||||
license = lib.licenses.mit;
|
||||
hydraPlatforms = lib.platforms.none;
|
||||
}) {};
|
||||
|
||||
"retrie_1_2_1_1" = callPackage
|
||||
"retrie" = callPackage
|
||||
({ mkDerivation, ansi-terminal, async, base, bytestring, containers
|
||||
, data-default, deepseq, directory, exceptions, filepath, ghc
|
||||
, ghc-exactprint, ghc-paths, haskell-src-exts, HUnit, list-t, mtl
|
||||
@ -243961,7 +243962,6 @@ self: {
|
||||
];
|
||||
description = "A powerful, easy-to-use codemodding tool for Haskell";
|
||||
license = lib.licenses.mit;
|
||||
hydraPlatforms = lib.platforms.none;
|
||||
}) {};
|
||||
|
||||
"retroclash-lib" = callPackage
|
||||
|
Loading…
Reference in New Issue
Block a user