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
64
pkgs/development/tools/ocaml/ocamlformat/generic.nix
Normal file
64
pkgs/development/tools/ocaml/ocamlformat/generic.nix
Normal file
|
|
@ -0,0 +1,64 @@
|
|||
{ lib, fetchurl, fetchzip, ocaml-ng
|
||||
, version
|
||||
, tarballName ? "ocamlformat-${version}.tbz",
|
||||
}:
|
||||
|
||||
let src =
|
||||
fetchurl {
|
||||
url = "https://github.com/ocaml-ppx/ocamlformat/releases/download/${version}/${tarballName}";
|
||||
sha256 = {
|
||||
"0.19.0" = "0ihgwl7d489g938m1jvgx8azdgq9f5np5mzqwwya797hx2m4dz32";
|
||||
"0.20.0" = "sha256-JtmNCgwjbCyUE4bWqdH5Nc2YSit+rekwS43DcviIfgk=";
|
||||
"0.20.1" = "sha256-fTpRZFQW+ngoc0T6A69reEUAZ6GmHkeQvxspd5zRAjU=";
|
||||
"0.21.0" = "sha256-KhgX9rxYH/DM6fCqloe4l7AnJuKrdXSe6Y1XY3BXMy0=";
|
||||
"0.22.4" = "sha256-61TeK4GsfMLmjYGn3ICzkagbc3/Po++Wnqkb2tbJwGA=";
|
||||
}."${version}";
|
||||
};
|
||||
ocamlPackages = ocaml-ng.ocamlPackages;
|
||||
in
|
||||
|
||||
with ocamlPackages;
|
||||
|
||||
buildDunePackage {
|
||||
pname = "ocamlformat";
|
||||
inherit src version;
|
||||
|
||||
minimumOCamlVersion = "4.08";
|
||||
|
||||
useDune2 = true;
|
||||
|
||||
strictDeps = true;
|
||||
|
||||
nativeBuildInputs = [
|
||||
menhir
|
||||
];
|
||||
|
||||
buildInputs = [
|
||||
base
|
||||
dune-build-info
|
||||
fix
|
||||
fpath
|
||||
menhirLib
|
||||
menhirSdk
|
||||
ocp-indent
|
||||
re
|
||||
stdio
|
||||
uuseg
|
||||
uutf
|
||||
]
|
||||
++ lib.optionals (lib.versionAtLeast version "0.20.0") [ ocaml-version either ]
|
||||
++ (if lib.versionAtLeast version "0.20.1"
|
||||
then [ odoc-parser ]
|
||||
else [ (odoc-parser.override { version = "0.9.0"; }) ])
|
||||
++ (if lib.versionAtLeast version "0.21.0"
|
||||
then [ cmdliner_1_1 ]
|
||||
else [ cmdliner_1_0 ])
|
||||
++ lib.optionals (lib.versionAtLeast version "0.22.4") [ csexp ];
|
||||
|
||||
meta = {
|
||||
homepage = "https://github.com/ocaml-ppx/ocamlformat";
|
||||
description = "Auto-formatter for OCaml code";
|
||||
maintainers = [ lib.maintainers.Zimmi48 lib.maintainers.marsam ];
|
||||
license = lib.licenses.mit;
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue