uboot: (firmwareOdroidC2/C4) don't invoke patch tool, use patches = [] instead
https://github.com/NixOS/nixpkgs/blob/master/pkgs/stdenv/generic/setup.sh#L948 this can do it nicely. Signed-off-by: Anton Arapov <anton@deadbeef.mx>
This commit is contained in:
commit
56de2bcd43
30691 changed files with 3076956 additions and 0 deletions
22
pkgs/development/ocaml-modules/ocaml-lsp/default.nix
Normal file
22
pkgs/development/ocaml-modules/ocaml-lsp/default.nix
Normal file
|
|
@ -0,0 +1,22 @@
|
|||
{ lib, buildDunePackage, lsp, xdg, re, fiber, makeWrapper, dot-merlin-reader, spawn }:
|
||||
|
||||
buildDunePackage rec {
|
||||
pname = "ocaml-lsp-server";
|
||||
inherit (lsp) version src preBuild;
|
||||
duneVersion = if lib.versionAtLeast version "1.10.0" then "3" else "2";
|
||||
|
||||
buildInputs = lsp.buildInputs ++ [ lsp re ]
|
||||
++ lib.optional (lib.versionAtLeast version "1.9") spawn
|
||||
++ lib.optionals (lib.versionAtLeast version "1.10") [ fiber xdg ];
|
||||
|
||||
nativeBuildInputs = [ makeWrapper ];
|
||||
|
||||
postInstall = ''
|
||||
wrapProgram $out/bin/ocamllsp --prefix PATH : ${dot-merlin-reader}/bin
|
||||
'';
|
||||
|
||||
meta = lsp.meta // {
|
||||
description = "OCaml Language Server Protocol implementation";
|
||||
mainProgram = "ocamllsp";
|
||||
};
|
||||
}
|
||||
60
pkgs/development/ocaml-modules/ocaml-lsp/jsonrpc.nix
Normal file
60
pkgs/development/ocaml-modules/ocaml-lsp/jsonrpc.nix
Normal file
|
|
@ -0,0 +1,60 @@
|
|||
{ buildDunePackage
|
||||
, stdlib-shims
|
||||
, ppx_yojson_conv_lib
|
||||
, ocaml-syntax-shims
|
||||
, yojson
|
||||
, result
|
||||
, fetchurl
|
||||
, lib
|
||||
, ocaml
|
||||
}:
|
||||
|
||||
let params =
|
||||
if lib.versionAtLeast ocaml.version "4.14"
|
||||
then {
|
||||
version = "1.11.3";
|
||||
sha256 = "sha256-KlMFh05O04I0Xil2B+nL2hUxZw0jaDMUnI23oUwGyhs=";
|
||||
} else if lib.versionAtLeast ocaml.version "4.13"
|
||||
then {
|
||||
version = "1.10.5";
|
||||
sha256 = "sha256-TeJS6t1ruWhWPvWNatrnSUWI6T17XKiosHLYizBDDcw=";
|
||||
} else if lib.versionAtLeast ocaml.version "4.12"
|
||||
then {
|
||||
version = "1.9.0";
|
||||
sha256 = "sha256:1ac44n6g3rf84gvhcca545avgf9vpkwkkkm0s8ipshfhp4g4jikh";
|
||||
} else {
|
||||
version = "1.4.1";
|
||||
sha256 = "1ssyazc0yrdng98cypwa9m3nzfisdzpp7hqnx684rqj8f0g3gs6f";
|
||||
}
|
||||
; in
|
||||
|
||||
buildDunePackage rec {
|
||||
pname = "jsonrpc";
|
||||
inherit (params) version;
|
||||
src = fetchurl {
|
||||
url = "https://github.com/ocaml/ocaml-lsp/releases/download/${version}/jsonrpc-${version}.tbz";
|
||||
inherit (params) sha256;
|
||||
};
|
||||
|
||||
duneVersion = if lib.versionAtLeast version "1.10.0" then "3" else "2";
|
||||
minimalOCamlVersion = "4.06";
|
||||
|
||||
buildInputs =
|
||||
if lib.versionAtLeast version "1.7.0" then
|
||||
[ ]
|
||||
else
|
||||
[ yojson stdlib-shims ocaml-syntax-shims ];
|
||||
|
||||
propagatedBuildInputs =
|
||||
if lib.versionAtLeast version "1.7.0" then
|
||||
[ ]
|
||||
else
|
||||
[ ppx_yojson_conv_lib result ];
|
||||
|
||||
meta = with lib; {
|
||||
description = "Jsonrpc protocol implementation in OCaml";
|
||||
license = licenses.isc;
|
||||
platforms = platforms.unix;
|
||||
maintainers = with maintainers; [ symphorien marsam ];
|
||||
};
|
||||
}
|
||||
79
pkgs/development/ocaml-modules/ocaml-lsp/lsp.nix
Normal file
79
pkgs/development/ocaml-modules/ocaml-lsp/lsp.nix
Normal file
|
|
@ -0,0 +1,79 @@
|
|||
{ buildDunePackage
|
||||
, lib
|
||||
, cppo
|
||||
, stdlib-shims
|
||||
, ppx_yojson_conv_lib
|
||||
, ocaml-syntax-shims
|
||||
, jsonrpc
|
||||
, omd
|
||||
, octavius
|
||||
, dune-build-info
|
||||
, dune-rpc
|
||||
, uutf
|
||||
, dyn
|
||||
, re
|
||||
, stdune
|
||||
, dune_3
|
||||
, csexp
|
||||
, pp
|
||||
, cmdliner
|
||||
, ordering
|
||||
, ocamlformat-rpc-lib
|
||||
}:
|
||||
|
||||
buildDunePackage rec {
|
||||
pname = "lsp";
|
||||
inherit (jsonrpc) version src;
|
||||
duneVersion = if lib.versionAtLeast version "1.10.0" then "3" else "2";
|
||||
minimumOCamlVersion =
|
||||
if lib.versionAtLeast version "1.7.0" then
|
||||
"4.12"
|
||||
else
|
||||
"4.06";
|
||||
|
||||
# unvendor some (not all) dependencies.
|
||||
# They are vendored by upstream only because it is then easier to install
|
||||
# ocaml-lsp without messing with your opam switch, but nix should prevent
|
||||
# this type of problems without resorting to vendoring.
|
||||
preBuild = lib.optionalString (lib.versionOlder version "1.10.4") ''
|
||||
rm -r ocaml-lsp-server/vendor/{octavius,uutf,omd,cmdliner}
|
||||
'';
|
||||
|
||||
buildInputs =
|
||||
if lib.versionAtLeast version "1.10.0" then
|
||||
[
|
||||
pp
|
||||
re
|
||||
ppx_yojson_conv_lib
|
||||
octavius
|
||||
dune-build-info
|
||||
dune-rpc
|
||||
omd
|
||||
cmdliner
|
||||
ocamlformat-rpc-lib
|
||||
dyn
|
||||
stdune
|
||||
]
|
||||
else if lib.versionAtLeast version "1.7.0" then
|
||||
[ pp re ppx_yojson_conv_lib octavius dune-build-info omd cmdliner ocamlformat-rpc-lib ]
|
||||
else
|
||||
[
|
||||
cppo
|
||||
ppx_yojson_conv_lib
|
||||
ocaml-syntax-shims
|
||||
octavius
|
||||
dune-build-info
|
||||
omd
|
||||
cmdliner
|
||||
];
|
||||
|
||||
propagatedBuildInputs = [
|
||||
csexp
|
||||
jsonrpc
|
||||
uutf
|
||||
] ++ lib.optional (lib.versionOlder version "1.7.0") stdlib-shims;
|
||||
|
||||
meta = jsonrpc.meta // {
|
||||
description = "LSP protocol implementation in OCaml";
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue