git.iko.soy/typeable/nixpkgs
on master help sign in
dune_3: init at 3.0.2
commit3994eb975a2b48123007632a649022a1133bcd8c authorMario Rodas <marsam@users.noreply.github.com> dateFri 18 Feb 2022, 04:20 (5 years ago) parent8adc765
3 files changed+43−1
pkgs/development/tools/ocaml/dune/3.nix+40 pkgs/top-level/all-packages.nix+1−1 pkgs/top-level/ocaml-packages.nix+2
pkgs/development/tools/ocaml/dune/3.nixnew file+40
@@ -0,0 +1,40 @@
1+{ lib, stdenv, fetchurl, ocaml, findlib, darwin }:
2+
3+if lib.versionOlder ocaml.version "4.08"
4+then throw "dune 3 is not available for OCaml ${ocaml.version}"
5+else
6+
7+stdenv.mkDerivation rec {
8+ pname = "dune";
9+ version = "3.0.2";
10+
11+ src = fetchurl {
12+ url = "https://github.com/ocaml/dune/releases/download/${version}/fiber-${version}.tbz";
13+ sha256 = "sha256-o108qIeWMOX0VU/wWdc5bg/UDCT2CCcw/Xx3nFiDbes=";
14+ };
15+
16+ nativeBuildInputs = [ ocaml findlib ];
17+
18+ buildInputs = lib.optionals stdenv.isDarwin [
19+ darwin.apple_sdk.frameworks.Foundation
20+ ];
21+
22+ strictDeps = true;
23+
24+ buildFlags = "release";
25+
26+ dontAddPrefix = true;
27+ dontAddStaticConfigureFlags = true;
28+ configurePlatforms = [];
29+
30+ installFlags = [ "PREFIX=${placeholder "out"}" "LIBDIR=$(OCAMLFIND_DESTDIR)" ];
31+
32+ meta = {
33+ homepage = "https://dune.build/";
34+ description = "A composable build system";
35+ changelog = "https://github.com/ocaml/dune/raw/${version}/CHANGES.md";
36+ maintainers = [ lib.maintainers.vbgl lib.maintainers.marsam ];
37+ license = lib.licenses.mit;
38+ inherit (ocaml.meta) platforms;
39+ };
40+}
pkgs/top-level/all-packages.nix+1−1
@@ -2921,7 +2921,7 @@ with pkgs;
29212921 duf = callPackage ../tools/misc/duf { };
29222922
29232923 inherit (ocaml-ng.ocamlPackages_4_10) dune_1;
2924− inherit (ocamlPackages) dune_2 dune-release;
2924+ inherit (ocamlPackages) dune_2 dune_3 dune-release;
29252925
29262926 duperemove = callPackage ../tools/filesystems/duperemove { };
29272927
pkgs/top-level/ocaml-packages.nix+2
@@ -310,6 +310,8 @@ let
310310 then pkgs.dune_2
311311 else throw "dune_2 is not available for OCaml ${ocaml.version}";
312312
313+ dune_3 = callPackage ../development/tools/ocaml/dune/3.nix { };
314+
313315 dune-action-plugin = callPackage ../development/ocaml-modules/dune-action-plugin { };
314316
315317 dune-build-info = callPackage ../development/ocaml-modules/dune-build-info { };